From 0707c91d41b59572b86c0460b4531741b6844052 Mon Sep 17 00:00:00 2001 From: kric_jspark Date: Thu, 13 Nov 2025 15:48:52 +0900 Subject: [PATCH] =?UTF-8?q?251113=5F03=5FENH=20:=20=EB=B2=A0=EC=9D=B4?= =?UTF-8?q?=EC=8A=A4=20=EC=95=84=ED=82=A4=ED=85=8D=EC=B2=98=EC=97=90=20log?= =?UTF-8?q?out,=20main=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/(main)/layout.tsx | 20 +++++++++++++++++++ src/app/(main)/list/page.tsx | 8 ++++++++ src/app/(main)/page.tsx | 8 ++++++++ src/app/(main)/user/page.tsx | 8 ++++++++ src/app/layout.tsx | 38 +++++++++++++++++------------------- src/app/logout/page.tsx | 7 +++++++ src/app/page.tsx | 7 ------- 7 files changed, 69 insertions(+), 27 deletions(-) create mode 100644 src/app/(main)/layout.tsx create mode 100644 src/app/(main)/list/page.tsx create mode 100644 src/app/(main)/page.tsx create mode 100644 src/app/(main)/user/page.tsx create mode 100644 src/app/logout/page.tsx delete mode 100644 src/app/page.tsx diff --git a/src/app/(main)/layout.tsx b/src/app/(main)/layout.tsx new file mode 100644 index 0000000..4d9def1 --- /dev/null +++ b/src/app/(main)/layout.tsx @@ -0,0 +1,20 @@ +const MainLayout = ({ children }: { children: React.ReactNode}) => { + return ( +
+ {/* 공통 헤더 */} +
+

Contact Admin

+
+ + {/* 메인 컨텐츠 영역 */} +
+ {/* 필요하면 사이드바 */} + {/* */} + +
{children}
+
+
+ ); +} + +export default MainLayout; \ No newline at end of file diff --git a/src/app/(main)/list/page.tsx b/src/app/(main)/list/page.tsx new file mode 100644 index 0000000..f698aec --- /dev/null +++ b/src/app/(main)/list/page.tsx @@ -0,0 +1,8 @@ +const ListPage = () => { + //const url = buildUrlWithParams("/login", searchParams, { ref: "root" }); + //redirect(url); + + return (
This is List Page
) +} + +export default ListPage; \ No newline at end of file diff --git a/src/app/(main)/page.tsx b/src/app/(main)/page.tsx new file mode 100644 index 0000000..31f8cfb --- /dev/null +++ b/src/app/(main)/page.tsx @@ -0,0 +1,8 @@ +const MainPage = () => { + //const url = buildUrlWithParams("/login", searchParams, { ref: "root" }); + //redirect(url); + + return (
Hello, Next.JS
) +} + +export default MainPage; \ No newline at end of file diff --git a/src/app/(main)/user/page.tsx b/src/app/(main)/user/page.tsx new file mode 100644 index 0000000..d8b794d --- /dev/null +++ b/src/app/(main)/user/page.tsx @@ -0,0 +1,8 @@ +const UserPage = () => { + //const url = buildUrlWithParams("/login", searchParams, { ref: "root" }); + //redirect(url); + + return (
This is User Page
) +} + +export default UserPage; \ No newline at end of file diff --git a/src/app/layout.tsx b/src/app/layout.tsx index f7fa87e..11179e9 100644 --- a/src/app/layout.tsx +++ b/src/app/layout.tsx @@ -1,34 +1,32 @@ import type { Metadata } from "next"; -import { Geist, Geist_Mono } from "next/font/google"; +import {Geist, Geist_Mono} from "next/font/google"; import "./globals.css"; const geistSans = Geist({ - variable: "--font-geist-sans", - subsets: ["latin"], + variable: "--font-geist-sans", + subsets: ["latin"], }); const geistMono = Geist_Mono({ - variable: "--font-geist-mono", - subsets: ["latin"], + variable: "--font-geist-mono", + subsets: ["latin"], }); export const metadata: Metadata = { - title: "Create Next App", - description: "Generated by create next app", + title: "Contact", + description: "Contact system", }; -export default function RootLayout({ - children, -}: Readonly<{ - children: React.ReactNode; -}>) { - return ( - - +const RootLayout = ({ children }: { children: React.ReactNode}) => { + return ( + + {children} - - - ); + + + ); } + +export default RootLayout; \ No newline at end of file diff --git a/src/app/logout/page.tsx b/src/app/logout/page.tsx new file mode 100644 index 0000000..c841d5a --- /dev/null +++ b/src/app/logout/page.tsx @@ -0,0 +1,7 @@ +import { redirect } from "next/navigation"; + +const LogoutPage = () => { + redirect("/login"); +} + +export default LogoutPage; \ No newline at end of file diff --git a/src/app/page.tsx b/src/app/page.tsx deleted file mode 100644 index 182a9b3..0000000 --- a/src/app/page.tsx +++ /dev/null @@ -1,7 +0,0 @@ -import { redirect } from "next/navigation"; -import { buildUrlWithParams } from "@/lib/utils"; - -export default function Page({ searchParams }: { searchParams: Record }) { - const url = buildUrlWithParams("/login", searchParams, { ref: "root" }); - redirect(url); -} \ No newline at end of file