From 4b4c4209ae899aecebf742aa5cd60f79114f689e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E1=84=8B=E1=85=B5=E1=84=86=E1=85=B5=E1=86=AB=E1=84=92?= =?UTF-8?q?=E1=85=B4?= Date: Fri, 8 Nov 2024 23:51:56 +0900 Subject: [PATCH 1/3] =?UTF-8?q?chore:=20#420=20=EA=B3=B5=EC=A7=80=20?= =?UTF-8?q?=EC=BB=B4=ED=8F=AC=EB=84=8C=ED=8A=B8=20=EB=82=B4=EB=B6=80?= =?UTF-8?q?=EB=A1=9C=20=EB=B0=94=ED=85=80=EC=8B=9C=ED=8A=B8=20=EC=9D=B4?= =?UTF-8?q?=EB=8F=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../component/announcement/Announcement.tsx | 69 +++++++++++++++++++ .../common/announcement/Announcement.tsx | 48 ------------- 2 files changed, 69 insertions(+), 48 deletions(-) create mode 100644 apps/web/src/component/announcement/Announcement.tsx delete mode 100644 apps/web/src/component/common/announcement/Announcement.tsx diff --git a/apps/web/src/component/announcement/Announcement.tsx b/apps/web/src/component/announcement/Announcement.tsx new file mode 100644 index 00000000..b7103833 --- /dev/null +++ b/apps/web/src/component/announcement/Announcement.tsx @@ -0,0 +1,69 @@ +import { css } from "@emotion/react"; +import Cookies from "js-cookie"; + +import { BottomSheet } from "@/component/BottomSheet"; +import { ButtonProvider } from "@/component/common/button"; +import { Icon } from "@/component/common/Icon"; +import { Typography } from "@/component/common/typography"; + +type AnnouncementProps = { title: string; content: React.ReactNode; onConfirm: () => void; sheetId: string }; + +export function Announcement({ title, content, onConfirm, sheetId }: AnnouncementProps) { + const SHOW_ANNOUNCEMENT_KEY = "announcement-checked"; + + const hideAnnouncement = Cookies.get(SHOW_ANNOUNCEMENT_KEY); + + if (hideAnnouncement) return; + + return ( + +
+ + + {title} + +
+
+ {content} +
+ + { + Cookies.set(SHOW_ANNOUNCEMENT_KEY, new Date().toISOString(), { expires: 1 }); + onConfirm(); + }} + > + 확인 + + + } + /> + ); +} diff --git a/apps/web/src/component/common/announcement/Announcement.tsx b/apps/web/src/component/common/announcement/Announcement.tsx deleted file mode 100644 index 3e1f87e0..00000000 --- a/apps/web/src/component/common/announcement/Announcement.tsx +++ /dev/null @@ -1,48 +0,0 @@ -import { css } from "@emotion/react"; - -import { ButtonProvider } from "@/component/common/button"; -import { Icon } from "@/component/common/Icon"; -import { Typography } from "@/component/common/typography"; - -type AnnouncementProps = { title: string; content: React.ReactNode; onConfirm: () => void }; - -export function Announcement({ title, content, onConfirm }: AnnouncementProps) { - return ( -
-
- - - {title} - -
-
- {content} -
- - 확인 -
- ); -} From 6a325668562fcec6046fd43dbf57bbb951353d2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E1=84=8B=E1=85=B5=E1=84=86=E1=85=B5=E1=86=AB=E1=84=92?= =?UTF-8?q?=E1=85=B4?= Date: Fri, 8 Nov 2024 23:52:15 +0900 Subject: [PATCH 2/3] =?UTF-8?q?chore:=20#420=201109=20=EA=B3=B5=EC=A7=80?= =?UTF-8?q?=20(=EC=9D=B8=ED=94=84=EB=9D=BC=20=EC=9D=B4=EC=A0=84)=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/web/src/layout/GlobalLayout.tsx | 44 ++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/apps/web/src/layout/GlobalLayout.tsx b/apps/web/src/layout/GlobalLayout.tsx index 2faf45f6..801ffb5e 100644 --- a/apps/web/src/layout/GlobalLayout.tsx +++ b/apps/web/src/layout/GlobalLayout.tsx @@ -4,20 +4,26 @@ import { PATHS } from "@layer/shared"; import { useEffect } from "react"; import { Outlet, useLocation } from "react-router-dom"; +import { Announcement } from "@/component/announcement/Announcement"; import { Modal } from "@/component/common/Modal"; +import { Typography } from "@/component/common/typography"; import { PreventExternalBrowser } from "@/helper/preventExternalBrowser.tsx"; +import { useBottomSheet } from "@/hooks/useBottomSheet"; import ChannelService from "@/lib/channel-talk/service"; import { useBridge } from "@/lib/provider/bridge-provider"; const siteId = import.meta.env.VITE_HOTJAR_KEY as number; const hotjarVersion = import.meta.env.VITE_HOTJAR_VERSION as number; +const SHEET_ID = "announcement"; export default function GlobalLayout() { const { safeAreaHeight } = useBridge(); const location = useLocation(); + const { openBottomSheet, closeBottomSheet } = useBottomSheet(); useEffect(() => { Hotjar.init(siteId, hotjarVersion); + openBottomSheet({ id: SHEET_ID }); }, []); useEffect(() => { @@ -47,6 +53,44 @@ export default function GlobalLayout() { ${safeAreaHeight && { height: `calc(100dvh-${safeAreaHeight * 2}px)` }} `} > + + {`안녕하세요, 레이어 서비스입니다. +항상 저희 서비스를 이용해 주셔서 감사드립니다. + +서비스 품질 향상을 위한 인프라 이전을 진행하고자 하오니 잠시 양해를 부탁드립니다. +작업 진행 시간 동안 서비스가 접속이 되지 않거나 느려지는 현상이 있을 수 있으니 이용에 참고하시기 바랍니다. + +1. 점검 시간 + + 2024년 11월 10일(일) 13:00 ~ 22:00 + ※ 모든 시간은 한국시간 기준입니다. + ※ 작업 진행상황에 따라 일정은 변경될 수 있습니다. + +2. 대상 서비스 + + 레이어 서비스 + +해당 기간동안 궁금하신 점은 gentlemonster77@likelion.org 로 문의를 주시면 빠르게 확인 후 순차적으로 답변 드리겠습니다. + +이용에 불편을 드려 죄송합니다. +보다 안정적인 서비스를 제공하기 위해 노력하는 레이어가 되겠습니다. + +감사합니다.`} + + } + /> From 3aef83ca8b5503b7f6b49856243d550bd1a02ccd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E1=84=8B=E1=85=B5=E1=84=86=E1=85=B5=E1=86=AB=E1=84=92?= =?UTF-8?q?=E1=85=B4?= Date: Sat, 9 Nov 2024 00:07:37 +0900 Subject: [PATCH 3/3] =?UTF-8?q?chore:=20#420=20=EC=9D=B4=EB=A9=94=EC=9D=BC?= =?UTF-8?q?=20=EB=B3=B5=EC=82=AC=20=EA=B8=B0=EB=8A=A5=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/web/src/layout/GlobalLayout.tsx | 54 ++++++++++++++++++++++------ apps/web/src/style/global.css | 4 +++ 2 files changed, 47 insertions(+), 11 deletions(-) diff --git a/apps/web/src/layout/GlobalLayout.tsx b/apps/web/src/layout/GlobalLayout.tsx index 801ffb5e..41e1c716 100644 --- a/apps/web/src/layout/GlobalLayout.tsx +++ b/apps/web/src/layout/GlobalLayout.tsx @@ -9,6 +9,7 @@ import { Modal } from "@/component/common/Modal"; import { Typography } from "@/component/common/typography"; import { PreventExternalBrowser } from "@/helper/preventExternalBrowser.tsx"; import { useBottomSheet } from "@/hooks/useBottomSheet"; +import { useToast } from "@/hooks/useToast"; import ChannelService from "@/lib/channel-talk/service"; import { useBridge } from "@/lib/provider/bridge-provider"; @@ -20,6 +21,7 @@ export default function GlobalLayout() { const { safeAreaHeight } = useBridge(); const location = useLocation(); const { openBottomSheet, closeBottomSheet } = useBottomSheet(); + const { toast } = useToast(); useEffect(() => { Hotjar.init(siteId, hotjarVersion); @@ -58,15 +60,16 @@ export default function GlobalLayout() { onConfirm={closeBottomSheet} title="인프라 이전 안내" content={ - - {`안녕하세요, 레이어 서비스입니다. + <> + + {`안녕하세요, 레이어 서비스입니다. 항상 저희 서비스를 이용해 주셔서 감사드립니다. 서비스 품질 향상을 위한 인프라 이전을 진행하고자 하오니 잠시 양해를 부탁드립니다. @@ -82,13 +85,42 @@ export default function GlobalLayout() { 레이어 서비스 -해당 기간동안 궁금하신 점은 gentlemonster77@likelion.org 로 문의를 주시면 빠르게 확인 후 순차적으로 답변 드리겠습니다. +해당 기간동안 궁금하신 점은`} + + { + try { + await navigator.clipboard.writeText("gentlemonster77@likelion.org"); + toast.success("이메일이 클립보드에 복사되었습니다"); + } catch (e) { + toast.success("다시 시도해주세요"); + } + }} + > + gentlemonster77@likelion.org + + + {`로 문의를 주시면 빠르게 확인 후 순차적으로 답변 드리겠습니다. 이용에 불편을 드려 죄송합니다. 보다 안정적인 서비스를 제공하기 위해 노력하는 레이어가 되겠습니다. 감사합니다.`} - + + } /> diff --git a/apps/web/src/style/global.css b/apps/web/src/style/global.css index f9660061..d07c5bb4 100644 --- a/apps/web/src/style/global.css +++ b/apps/web/src/style/global.css @@ -63,6 +63,10 @@ textarea { resize: none; } +p { + margin: 0; +} + ::-webkit-scrollbar { border: none; width: 1rem;