From 3311cd89ee117eec75308a0dabd247cfae4329f3 Mon Sep 17 00:00:00 2001 From: dididy Date: Fri, 19 Nov 2021 23:03:47 +0900 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20Landing=20=ED=8E=98=EC=9D=B4?= =?UTF-8?q?=EC=A7=80=EB=A5=BC=20=EC=82=AD=EC=A0=9C=ED=95=98=EA=B3=A0=20sid?= =?UTF-8?q?e=EB=A1=9C=20=EB=A6=AC=EB=8B=A4=EC=9D=B4=EB=A0=89=ED=8A=B8=20?= =?UTF-8?q?=EB=90=98=EB=8F=84=EB=A1=9D=20=EC=B2=98=EB=A6=AC=ED=95=9C?= =?UTF-8?q?=EB=8B=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/App.tsx | 5 +-- src/pages/LandingPage/LandingPage.module.scss | 6 --- src/pages/LandingPage/index.tsx | 41 ------------------- 3 files changed, 2 insertions(+), 50 deletions(-) delete mode 100644 src/pages/LandingPage/LandingPage.module.scss delete mode 100644 src/pages/LandingPage/index.tsx diff --git a/src/App.tsx b/src/App.tsx index e3cc1d1..98b4587 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1,7 +1,6 @@ import React, { useRef } from 'react'; -import { Route, Switch, useLocation } from 'react-router-dom'; +import { Route, Switch, useLocation, Redirect } from 'react-router-dom'; import styles from '@src/App.module.scss'; -import LandingPage from '@src/pages/LandingPage'; import LoginPage from '@src/pages/LoginPage'; import JoinPage from '@src/pages/JoinPage'; import IdeaPage from '@src/pages/IdeaPage'; @@ -38,7 +37,6 @@ const App = () => {
- { redirectPath="/login" render={(props) => } /> +
{isGlobalAlertVisible && ( { - const dispatch = useAppDispatch(); - const { isLoading } = useUiState(); - - return ( -
- - - -
- {isLoading ?

loading

:

break

} -
- - -
- ); -}; - -export default LandingPage; From c4f5318a5df976f3ce2625f4a27ff86ccab50aa8 Mon Sep 17 00:00:00 2001 From: dididy Date: Sat, 20 Nov 2021 00:48:00 +0900 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20=EC=98=AC=EB=B0=94=EB=A5=B8=20url?= =?UTF-8?q?=EB=8F=84=20=EB=A6=AC=EB=8B=A4=EC=9D=B4=EB=A0=89=ED=8A=B8=20?= =?UTF-8?q?=EB=90=98=EB=8D=98=20=EB=AC=B8=EC=A0=9C=EB=A5=BC=20=ED=95=B4?= =?UTF-8?q?=EA=B2=B0=ED=95=9C=EB=8B=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/App.tsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/App.tsx b/src/App.tsx index 98b4587..afcc81c 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -15,6 +15,8 @@ import SideReadPage from '@src/pages/SideReadPage'; import AlertModal from '@src/components/modals/AlertModal'; import { useAppDispatch, useUiState, hideGlobalAlert } from '@src/store'; +const PATH_CHECK = ['login', 'join', 'idea', 'side', 'mypage']; + const App = () => { const { isGlobalAlertVisible, globalAlertMessage } = useUiState(); const dispatch = useAppDispatch(); @@ -70,7 +72,9 @@ const App = () => { redirectPath="/login" render={(props) => } /> - + {pathname && !PATH_CHECK.some((each) => pathname.includes(each)) && ( + + )} {isGlobalAlertVisible && (