From 5a64a12476b5dcd7a5cebd8352f1f83565951de7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9C=A1=EA=B8=B0=EC=A4=80?= Date: Mon, 9 Sep 2024 07:21:09 +0900 Subject: [PATCH] Delete packages/main/src/pages directory --- packages/main/src/pages/Error.tsx | 8 -- packages/main/src/pages/Landing/Button.tsx | 11 -- packages/main/src/pages/Landing/Modal.tsx | 110 ------------------ .../main/src/pages/Landing/Sections/First.tsx | 22 ---- .../src/pages/Landing/Sections/Fourth.tsx | 15 --- .../src/pages/Landing/Sections/Second.tsx | 36 ------ .../main/src/pages/Landing/Sections/Third.tsx | 28 ----- .../main/src/pages/Landing/Sections/Title.tsx | 24 ---- .../main/src/pages/Landing/Sections/index.tsx | 15 --- .../main/src/pages/Landing/SlideSection.tsx | 30 ----- packages/main/src/pages/Landing/index.tsx | 59 ---------- packages/main/src/pages/index.ts | 2 - 12 files changed, 360 deletions(-) delete mode 100644 packages/main/src/pages/Error.tsx delete mode 100644 packages/main/src/pages/Landing/Button.tsx delete mode 100644 packages/main/src/pages/Landing/Modal.tsx delete mode 100644 packages/main/src/pages/Landing/Sections/First.tsx delete mode 100644 packages/main/src/pages/Landing/Sections/Fourth.tsx delete mode 100644 packages/main/src/pages/Landing/Sections/Second.tsx delete mode 100644 packages/main/src/pages/Landing/Sections/Third.tsx delete mode 100644 packages/main/src/pages/Landing/Sections/Title.tsx delete mode 100644 packages/main/src/pages/Landing/Sections/index.tsx delete mode 100644 packages/main/src/pages/Landing/SlideSection.tsx delete mode 100644 packages/main/src/pages/Landing/index.tsx delete mode 100644 packages/main/src/pages/index.ts diff --git a/packages/main/src/pages/Error.tsx b/packages/main/src/pages/Error.tsx deleted file mode 100644 index 23525f1b..00000000 --- a/packages/main/src/pages/Error.tsx +++ /dev/null @@ -1,8 +0,0 @@ -export const NotFound = () => { - return ( -
- 404 - Not Found -
- ); -}; diff --git a/packages/main/src/pages/Landing/Button.tsx b/packages/main/src/pages/Landing/Button.tsx deleted file mode 100644 index 9cb83f57..00000000 --- a/packages/main/src/pages/Landing/Button.tsx +++ /dev/null @@ -1,11 +0,0 @@ -interface IProp { - children: string; -} - -export const Button = ({ children }: IProp) => { - return ( - - ); -}; diff --git a/packages/main/src/pages/Landing/Modal.tsx b/packages/main/src/pages/Landing/Modal.tsx deleted file mode 100644 index 19924cf6..00000000 --- a/packages/main/src/pages/Landing/Modal.tsx +++ /dev/null @@ -1,110 +0,0 @@ -import { useMyMutation, useAuth } from "@configs/util"; -import { Box, Button, Icon, Text } from "ui"; -import { useState } from "react"; - -interface IProp { - open: boolean; -} - -interface _ILogin { - account_id: string; - password: string; -} - -interface ILogin_ { - access_token: string; - refresh_token: string; - access_expired_at: number; - refresh_expired_at: number; -} - -export const Modal = ({ open }: IProp) => { - const { mutate: teacher } = useMyMutation<_ILogin, ILogin_>( - "post", - "auth", - "/teacher" - ); - const { mutate: student } = useMyMutation<_ILogin, ILogin_>( - "post", - "auth", - "/student" - ); - const { setToken } = useAuth(); - - const [data, setData] = useState({ - account_id: "", - password: "" - }); - - const handleChange = (e: React.ChangeEvent) => { - setData((prev) => ({ ...prev, [e.target.id]: e.target.value })); - }; - - const handleLogin = (type: "teacher" | "student") => { - if (type === "student") { - student(data, { - onSuccess: (res) => { - setToken({ ...res, role: "student" }); - window.location.replace(`${process.env.VITE_APP_URL_STUDENT}`); - } - }); - } else { - teacher(data, { - onSuccess: (res) => { - setToken({ ...res, role: "teacher" }); - window.location.replace(`${process.env.VITE_APP_URL_TEACHER}`); - } - }); - } - }; - - return ( -
- - - 로그인 -
- - -
- - -
-
-
-
- ); -}; diff --git a/packages/main/src/pages/Landing/Sections/First.tsx b/packages/main/src/pages/Landing/Sections/First.tsx deleted file mode 100644 index 1fded03d..00000000 --- a/packages/main/src/pages/Landing/Sections/First.tsx +++ /dev/null @@ -1,22 +0,0 @@ -import { Button } from "../Button"; - -export const First = () => { - return ( -
-
- - Repo - - - 이력서, 온라인으로 -
쉽고 간편하게. -
- -
-
- -
-
-
- ); -}; diff --git a/packages/main/src/pages/Landing/Sections/Fourth.tsx b/packages/main/src/pages/Landing/Sections/Fourth.tsx deleted file mode 100644 index 7bb331c9..00000000 --- a/packages/main/src/pages/Landing/Sections/Fourth.tsx +++ /dev/null @@ -1,15 +0,0 @@ -import { Title } from "./Title"; - -export const Fourth = () => { - return ( -
- -
- 이력서 도서관 - - 이전 기수 선배분들의 이력서를 도서관에서 참고해 볼 수 있어요. - -
-
- ); -}; diff --git a/packages/main/src/pages/Landing/Sections/Second.tsx b/packages/main/src/pages/Landing/Sections/Second.tsx deleted file mode 100644 index b594fa46..00000000 --- a/packages/main/src/pages/Landing/Sections/Second.tsx +++ /dev/null @@ -1,36 +0,0 @@ -import { Title } from "./Title"; - -export const Second = () => { - return ( -
- 손쉽게 작성하는 이력서 -
-
-
- -
- - 이력서 정보별 작성 - - - 정보별로 모아놓은 탭을 통해, 작성하고자 하는 곳을 -
- 빠르게 오가며 채워나갈 수 있어요. -
-
-
-
- -
- - 다양한 입력 - - - 이력서 정보들의 형식에 맞게, 다양한 종류의 입력을 제공해 드리고 - 있어요. - -
-
-
- ); -}; diff --git a/packages/main/src/pages/Landing/Sections/Third.tsx b/packages/main/src/pages/Landing/Sections/Third.tsx deleted file mode 100644 index 9bc45c49..00000000 --- a/packages/main/src/pages/Landing/Sections/Third.tsx +++ /dev/null @@ -1,28 +0,0 @@ -import { Title } from "./Title"; - -export const Third = () => { - return ( -
-
- 실시간 결과 확인 -
-
-
- - 작성하고 있는 정보가| - -
-
-
- - 실시간으로 반영되는 모습을 확인하며 작업할 수 있어요. - -
-
- -
- ); -}; diff --git a/packages/main/src/pages/Landing/Sections/Title.tsx b/packages/main/src/pages/Landing/Sections/Title.tsx deleted file mode 100644 index bc477990..00000000 --- a/packages/main/src/pages/Landing/Sections/Title.tsx +++ /dev/null @@ -1,24 +0,0 @@ -interface IProp { - direction: "left" | "center" | "right"; - children: string; -} - -export const Title = ({ direction, children }: IProp) => { - const direct = - direction === "center" - ? "items-center" - : direction === "left" - ? "self-start items-start" - : "self-end items-end"; - - return ( -
-
-
-
- - {children} - -
- ); -}; diff --git a/packages/main/src/pages/Landing/Sections/index.tsx b/packages/main/src/pages/Landing/Sections/index.tsx deleted file mode 100644 index e5432ff1..00000000 --- a/packages/main/src/pages/Landing/Sections/index.tsx +++ /dev/null @@ -1,15 +0,0 @@ -import { First } from "./First"; -import { Second } from "./Second"; -import { Third } from "./Third"; -import { Fourth } from "./Fourth"; - -export const Sections = () => { - return ( -
- - - - -
- ); -}; diff --git a/packages/main/src/pages/Landing/SlideSection.tsx b/packages/main/src/pages/Landing/SlideSection.tsx deleted file mode 100644 index 6a76cd13..00000000 --- a/packages/main/src/pages/Landing/SlideSection.tsx +++ /dev/null @@ -1,30 +0,0 @@ -import { Button } from "./Button"; -import { Title } from "./Sections/Title"; - -export const SlideSection = () => { - return ( -
-
-
- - - -
-
-
- 깔끔한 나만의 레주메 - - 로그인하여 바로 시작해 보세요. - - -
-
-
- - - -
-
-
- ); -}; diff --git a/packages/main/src/pages/Landing/index.tsx b/packages/main/src/pages/Landing/index.tsx deleted file mode 100644 index 102d13b6..00000000 --- a/packages/main/src/pages/Landing/index.tsx +++ /dev/null @@ -1,59 +0,0 @@ -import { useEffect, useState } from "react"; -import { Sections } from "./Sections"; -import { SlideSection } from "./SlideSection"; -import { Modal } from "./Modal"; -import { LogoFull } from "@/assets"; -import { Button } from "./Button"; - -export const Landing = () => { - const [open, setOpen] = useState(false); - - useEffect(() => { - const items = document.querySelectorAll("button"); - items.forEach((i) => - i.addEventListener("click", () => setOpen((prev) => !prev)) - ); - return () => { - const items = document.querySelectorAll("button"); - items.forEach((i) => - i.removeEventListener("click", () => setOpen((prev) => !prev)) - ); - }; - }, [setOpen]); - - return ( -
-
-
- - -
- - - - -
- ); -}; diff --git a/packages/main/src/pages/index.ts b/packages/main/src/pages/index.ts deleted file mode 100644 index ec19ee40..00000000 --- a/packages/main/src/pages/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * from "./Error"; -export * from "./Landing";