From 5d023147c5e44d499247a5648ff42d7654c29aa0 Mon Sep 17 00:00:00 2001 From: heaven Date: Thu, 4 Jun 2026 12:27:10 +0300 Subject: [PATCH] fix(composer): reset the docked emoji board when crossing the breakpoint so it cannot silently re-open --- src/app/features/room/RoomInput.tsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/app/features/room/RoomInput.tsx b/src/app/features/room/RoomInput.tsx index 89169afc..ad3dbf60 100644 --- a/src/app/features/room/RoomInput.tsx +++ b/src/app/features/room/RoomInput.tsx @@ -222,6 +222,11 @@ export const RoomInput = forwardRef( // top of the composer instead of floating as a pop-out. const dockEmojiBoard = mobileOrTablet() || screenSize === ScreenSize.Mobile; const [emojiBoardTab, setEmojiBoardTab] = useState(undefined); + // Crossing the dock/pop-out breakpoint remounts the trigger; drop any open + // dock state so the board doesn't silently re-open after a resize round-trip. + useEffect(() => { + setEmojiBoardTab(undefined); + }, [dockEmojiBoard]); const roomToParents = useAtomValue(roomToParentsAtom); const powerLevels = usePowerLevelsContext(); const creators = useRoomCreators(room);