Scheduling infrastructure for absolutely everyone.
fix: It's hard to click on the last available Event Duration (#18462)
Amit Sharmaf9dc788007e4
diff --git a/packages/ui/components/apps/AllApps.tsx b/packages/ui/components/apps/AllApps.tsxindex 8543c7de451..02264aec24f 100644--- a/packages/ui/components/apps/AllApps.tsx+++ b/packages/ui/components/apps/AllApps.tsx@@ -32,14 +32,14 @@ export function useShouldShowArrows() {right: !isAtEnd,});}- }, []);+ }, [ref.current?.scrollWidth, ref.current?.clientWidth]);const calculateScroll = (e: UIEvent<HTMLUListElement>) => {+ const target = e.currentTarget;+ const isAtEnd = target.scrollWidth <= target.clientWidth + target.scrollLeft + 1;setShowArrowScroll({- left: e.currentTarget.scrollLeft > 0,- right:- Math.floor(e.currentTarget.scrollWidth) - Math.floor(e.currentTarget.offsetWidth) !==- Math.floor(e.currentTarget.scrollLeft),+ left: target.scrollLeft > 0,+ right: !isAtEnd,});};