From efaff62028a671da48164338ae3f82e0a11a9736 Mon Sep 17 00:00:00 2001 From: BFlat Date: Fri, 23 Feb 2024 13:05:06 +0700 Subject: [PATCH] bug fix chevron not disappearing after window resize back to desktop --- .../common/SelectionBubbles/SelectionBubbles.tsx | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/fakeyou.com/src/components/common/SelectionBubbles/SelectionBubbles.tsx b/packages/fakeyou.com/src/components/common/SelectionBubbles/SelectionBubbles.tsx index 18213ba178..32097e5a59 100644 --- a/packages/fakeyou.com/src/components/common/SelectionBubbles/SelectionBubbles.tsx +++ b/packages/fakeyou.com/src/components/common/SelectionBubbles/SelectionBubbles.tsx @@ -59,6 +59,14 @@ export default function SelectionBubbles({ } }, [options]); + useEffect(() => { + const handleResize = () => { + handleScroll(); + }; + window.addEventListener("resize", handleResize); + return () => window.removeEventListener("resize", handleResize); + }, []); + return (