11import React from 'react' ;
22import { BrowserRouter , Route , Routes , Navigate } from 'react-router-dom' ;
3- import Home from './pages/Home' ;
4- import Login from './pages/Login' ;
5- import SignUp from './pages/SignUp' ;
6- import LoginComplete from './pages/Login/LoginComplete' ;
7- import TermsAgreement from './pages/TermsAgreement' ;
8-
9- import Profile from './pages/Profile' ;
10- import ProfileEdit from './pages/ProfileEdit' ;
11- import AccountSetting from './pages/AccountSetting' ;
12- import AccountEdit from './pages/AccountEdit' ;
13- import AccountCancel from './pages/AccountCancel' ;
14- import Verification from './pages/verification' ;
15-
16- import Post from './pages/Post' ;
17- import PostUpload from './pages/PostUpload' ;
18- import PostImageSelect from './pages/PostImageSelect' ;
19- import PostInstaConnect from './pages/PostInstaConnect' ;
20- import PostInstaFeedSelect from './pages/PostInstaFeedSelect' ;
21-
22- import Chats from './pages/Chats' ;
23- import ChatRoom from './pages/Chats/ChatRoom' ;
24-
25- import NotFound from './pages/NotFound' ;
3+
4+ import Home from '@pages/Home' ;
5+ import Login from '@pages/Login' ;
6+ import LoginComplete from '@pages/Login/LoginComplete' ;
7+
8+ import SignUp from '@pages/SignUp' ;
9+ import TermsAgreement from '@pages/SignUp/TermsAgreement' ;
10+
11+ import Profile from '@pages/Profile' ;
12+ import ProfileEdit from '@pages/Profile/ProfileEdit' ;
13+
14+ import AccountSetting from '@pages/Account/AccountSetting' ;
15+ import AccountEdit from '@pages/Account/AccountEdit' ;
16+ import AccountCancel from '@pages/Account/AccountCancel' ;
17+ import Verification from '@pages/Account/Verification' ;
18+
19+ import Post from '@pages/Post' ;
20+ import PostUpload from '@pages/Post/PostUpload' ;
21+ import PostImageSelect from '@pages/Post/PostImageSelect' ;
22+ import PostInstaConnect from '@pages/Post/PostInstaConnect' ;
23+ import PostInstaFeedSelect from '@pages/Post/PostInstaFeedSelect' ;
24+
25+ import Chats from '@pages/Chats' ;
26+ import ChatRoom from '@pages/Chats/ChatRoom' ;
27+
28+ import NotFound from '@pages/NotFound' ;
2629
2730const ProtectedRoute = ( { children } : { children : JSX . Element } ) => {
2831 const isAuthenticated = Boolean ( localStorage . getItem ( 'new_jwt_token' ) ) ;
@@ -33,19 +36,21 @@ const ProtectedRoute = ({ children }: { children: JSX.Element }) => {
3336const protectedRoutes = [
3437 { path : '/' , element : < Home /> } ,
3538
36- // 사용자 프로필 및 계정 관리
39+ // profile
3740 { path : '/profile/:userId' , element : < Profile /> } ,
3841 { path : '/profile/edit' , element : < ProfileEdit /> } ,
39- { path : '/account-setting' , element : < AccountSetting /> } ,
40- { path : '/account-edit' , element : < AccountEdit /> } ,
41- { path : '/account-cancel' , element : < AccountCancel /> } ,
42- { path : '/verification' , element : < Verification /> } ,
42+
43+ // account
44+ { path : '/account/setting' , element : < AccountSetting /> } ,
45+ { path : '/account/edit' , element : < AccountEdit /> } ,
46+ { path : '/account/cancel' , element : < AccountCancel /> } ,
47+ { path : '/account/verification' , element : < Verification /> } ,
4348
4449 { path : '/post/:postId' , element : < Post /> } ,
45- { path : '/upload' , element : < PostUpload /> } ,
46- { path : '/image-select ' , element : < PostImageSelect /> } ,
47- { path : '/insta-connect ' , element : < PostInstaConnect /> } ,
48- { path : '/insta-feed-select ' , element : < PostInstaFeedSelect /> } ,
50+ { path : '/post/ upload/photo/select ' , element : < PostImageSelect /> } ,
51+ { path : '/post/upload/instagram/connect ' , element : < PostInstaConnect /> } ,
52+ { path : '/post/upload/instagram/select ' , element : < PostInstaFeedSelect /> } ,
53+ { path : '/post/upload/content ' , element : < PostUpload /> } ,
4954
5055 // 메시지/채팅
5156 { path : '/chats' , element : < Chats /> } ,
0 commit comments