From d02b113938e242188dd50068ff7155c570bd6126 Mon Sep 17 00:00:00 2001 From: Hyeonsu Kim <86764406+borimong@users.noreply.github.com> Date: Sun, 3 Nov 2024 17:38:14 +0900 Subject: [PATCH] Update FeedFormPresentation.tsx --- src/components/feed/Modal/FeedFormPresentation.tsx | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/components/feed/Modal/FeedFormPresentation.tsx b/src/components/feed/Modal/FeedFormPresentation.tsx index 187dcaa9..c563d665 100644 --- a/src/components/feed/Modal/FeedFormPresentation.tsx +++ b/src/components/feed/Modal/FeedFormPresentation.tsx @@ -59,13 +59,7 @@ function FeedFormPresentation({ const textAreaRef = useRef(null); const [remainingHeight, setRemainingHeight] = useState(100); const [selectedMeeting, setSelectedMeeting] = useState(undefined); - const [isMobileDevice, setIsMobileDevice] = useState(false); - const userAgent = navigator.userAgent; - - if (/android/i.test(userAgent) || /iPad|iPhone|iPod/.test(userAgent)) { - setIsMobileDevice(true); - } - + const handleWindowResize = () => { setTextareaHeightChangeFlag(flag => !flag); }; @@ -91,7 +85,7 @@ function FeedFormPresentation({ ); const availableHeight = window.innerHeight - allComponentHeights - BasicPadding; - setRemainingHeight(isMobileDevice ? availableHeight - 44 : availableHeight); + setRemainingHeight(availableHeight); } }, [textareaHeightChangeFlag]);