diff --git a/README.md b/README.md deleted file mode 100644 index 012bf85..0000000 --- a/README.md +++ /dev/null @@ -1,2 +0,0 @@ -# 안녕하세요! SOPO 프론트팀 나즌기대치 입니다. 🙋🏻‍♂️ - diff --git a/SOPOLAST/src/Components/common/Auth/Login/login.tsx b/SOPOLAST/src/Components/Auth/Login/login.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Auth/Login/login.tsx rename to SOPOLAST/src/Components/Auth/Login/login.tsx diff --git a/SOPOLAST/src/Components/common/Auth/Signup/signup.tsx b/SOPOLAST/src/Components/Auth/Signup/signup.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Auth/Signup/signup.tsx rename to SOPOLAST/src/Components/Auth/Signup/signup.tsx diff --git a/SOPOLAST/src/Components/common/Auth/style/Auth.style.tsx b/SOPOLAST/src/Components/Auth/style/Auth.style.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Auth/style/Auth.style.tsx rename to SOPOLAST/src/Components/Auth/style/Auth.style.tsx diff --git a/SOPOLAST/src/Components/common/Competition/Competition.css b/SOPOLAST/src/Components/Competition/Competition.css similarity index 100% rename from SOPOLAST/src/Components/common/Competition/Competition.css rename to SOPOLAST/src/Components/Competition/Competition.css diff --git a/SOPOLAST/src/Components/common/Competition/Competition.tsx b/SOPOLAST/src/Components/Competition/Competition.tsx similarity index 99% rename from SOPOLAST/src/Components/common/Competition/Competition.tsx rename to SOPOLAST/src/Components/Competition/Competition.tsx index 0bea568..9666fe5 100644 --- a/SOPOLAST/src/Components/common/Competition/Competition.tsx +++ b/SOPOLAST/src/Components/Competition/Competition.tsx @@ -1,6 +1,6 @@ import React from "react"; import { Link } from "react-router-dom"; -import Sidname from "../../Sidebar/Side/side"; +import Sidname from "../Sidebar/Side/side"; import Head from "src/Components/head/Head/head"; import "./Competition.css"; import { useNavigate } from "react-router-dom"; diff --git a/SOPOLAST/src/Components/common/Competition/competiton.sytle.ts b/SOPOLAST/src/Components/Competition/competiton.sytle.ts similarity index 100% rename from SOPOLAST/src/Components/common/Competition/competiton.sytle.ts rename to SOPOLAST/src/Components/Competition/competiton.sytle.ts diff --git a/SOPOLAST/src/Components/common/Home/Card/Maincard.tsx b/SOPOLAST/src/Components/Home/Card/Maincard.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Home/Card/Maincard.tsx rename to SOPOLAST/src/Components/Home/Card/Maincard.tsx diff --git a/SOPOLAST/src/Components/common/Home/Footer/Fotter.tsx b/SOPOLAST/src/Components/Home/Footer/Fotter.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Home/Footer/Fotter.tsx rename to SOPOLAST/src/Components/Home/Footer/Fotter.tsx diff --git a/SOPOLAST/src/Components/common/Home/Post/post.tsx b/SOPOLAST/src/Components/Home/Post/post.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Home/Post/post.tsx rename to SOPOLAST/src/Components/Home/Post/post.tsx diff --git a/SOPOLAST/src/Components/common/Home/SideName/sidename.tsx b/SOPOLAST/src/Components/Home/SideName/sidename.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Home/SideName/sidename.tsx rename to SOPOLAST/src/Components/Home/SideName/sidename.tsx diff --git a/SOPOLAST/src/Components/common/Home/Style/Footer.style.tsx b/SOPOLAST/src/Components/Home/Style/Footer.style.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Home/Style/Footer.style.tsx rename to SOPOLAST/src/Components/Home/Style/Footer.style.tsx diff --git a/SOPOLAST/src/Components/common/Home/Style/Main.style.tsx b/SOPOLAST/src/Components/Home/Style/Main.style.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Home/Style/Main.style.tsx rename to SOPOLAST/src/Components/Home/Style/Main.style.tsx diff --git a/SOPOLAST/src/Components/common/Home/Style/Post.style.tsx b/SOPOLAST/src/Components/Home/Style/Post.style.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Home/Style/Post.style.tsx rename to SOPOLAST/src/Components/Home/Style/Post.style.tsx diff --git a/SOPOLAST/src/Components/common/Home/Style/Sidename.style.tsx b/SOPOLAST/src/Components/Home/Style/Sidename.style.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Home/Style/Sidename.style.tsx rename to SOPOLAST/src/Components/Home/Style/Sidename.style.tsx diff --git a/SOPOLAST/src/Components/common/Mypage/mypage.css b/SOPOLAST/src/Components/Mypage/mypage.css similarity index 100% rename from SOPOLAST/src/Components/common/Mypage/mypage.css rename to SOPOLAST/src/Components/Mypage/mypage.css diff --git a/SOPOLAST/src/Components/common/Mypage/mypage.tsx b/SOPOLAST/src/Components/Mypage/mypage.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Mypage/mypage.tsx rename to SOPOLAST/src/Components/Mypage/mypage.tsx diff --git a/SOPOLAST/src/Components/common/Portfolio/portfolioMain.style.ts b/SOPOLAST/src/Components/Portfolio/portfolioMain.style.ts similarity index 100% rename from SOPOLAST/src/Components/common/Portfolio/portfolioMain.style.ts rename to SOPOLAST/src/Components/Portfolio/portfolioMain.style.ts diff --git a/SOPOLAST/src/Components/Portfolio/portfolioMain.tsx b/SOPOLAST/src/Components/Portfolio/portfolioMain.tsx new file mode 100644 index 0000000..0a0ce62 --- /dev/null +++ b/SOPOLAST/src/Components/Portfolio/portfolioMain.tsx @@ -0,0 +1,64 @@ +import React, { useState, useEffect } from "react"; +import { useNavigate } from "react-router-dom"; +import Sidename from "src/constants/Sidebar/Side/side"; +import "./protfolio.css"; +import Head from "../../constants/head/Head/head" +import MajorLine from "../../constants/MajorLine/Major" +import axios from "axios"; + +import * as S from "./portfolioMain.style"; + +export default function Portfolio() { + const [users, setUsers] = useState([]); + const [activeUser, setActiveUser] = useState(null); + const navigate = useNavigate(); + + useEffect(() => { + const fetchUsers = async () => { + try { + const response = await axios.get("히ㅣㅎ api"); + setUsers(response.data); + } catch (error) { + console.error("Error fetching users:", error); + } + }; + + fetchUsers(); + }, []); + + const handleNameCardClick = (user) => { + setActiveUser(user); + }; + + return ( +
+
+ + + + + + + + + + + + + + {users.map((user) => ( + handleNameCardClick(user)} + > + {user.name} + {user.grade} + {user.mail} + + ))} + +
+
+ ); +} diff --git a/SOPOLAST/src/Components/common/Portfoliosub/portfolioSub.style.ts b/SOPOLAST/src/Components/Portfoliosub/portfolioSub.style.ts similarity index 100% rename from SOPOLAST/src/Components/common/Portfoliosub/portfolioSub.style.ts rename to SOPOLAST/src/Components/Portfoliosub/portfolioSub.style.ts diff --git a/SOPOLAST/src/Components/common/Portfoliosub/portfolioSub.tsx b/SOPOLAST/src/Components/Portfoliosub/portfolioSub.tsx similarity index 98% rename from SOPOLAST/src/Components/common/Portfoliosub/portfolioSub.tsx rename to SOPOLAST/src/Components/Portfoliosub/portfolioSub.tsx index 52e7d9a..ba034b7 100644 --- a/SOPOLAST/src/Components/common/Portfoliosub/portfolioSub.tsx +++ b/SOPOLAST/src/Components/Portfoliosub/portfolioSub.tsx @@ -2,7 +2,7 @@ import React from "react"; import yogiyo from "src/Assets/image/1.png"; import comment from "src/Assets/image/comment.png"; import Head from "src/Components/head/Head/head"; -import Sidebar from "../../Sidebar/Side/side"; +import Sidebar from "../Sidebar/Side/side"; import * as S from "./portfolioSub.style"; diff --git a/SOPOLAST/src/Components/Router/index.tsx b/SOPOLAST/src/Components/Router/index.tsx index 087a240..5d843d7 100644 --- a/SOPOLAST/src/Components/Router/index.tsx +++ b/SOPOLAST/src/Components/Router/index.tsx @@ -1,15 +1,15 @@ import GlobalStyles from "src/Style/global"; -import Updown from "src/Components/common/Updown/updownmain"; -import Login from "src/Components/common/Auth/Login/login"; -import Portfolio from "src/Components/common/Portfolio/portfolioMain"; +import Updown from "@src/Components/Updown/updownmain"; +import Login from "@src/Components/Auth/Login/login"; +import Portfolio from "@src/Components/Portfolio/portfolioMain"; import Main from "src/Pages/MainPage/mainpage"; -import Write from "src/Components/common/Sidewrite/write"; -import Signup from "src/Components/common/Auth/Signup/signup"; -import Mypage from "src/Components/common/Mypage/mypage"; -import Competition from "src/Components/common/Competition/Competition"; -import Portfoliosub from "src/Components/common/Portfoliosub/portfolioSub"; -import Updownsub from "src/Components/common/Updownsub/postshow"; -import CompetitionSub from "src/Components/common/compsub/competitionsub"; +import Write from "@src/Components/Sidewrite/write"; +import Signup from "@src/Components/Auth/Signup/signup"; +import Mypage from "@src/Components/Mypage/mypage"; +import Competition from "@src/Components/Competition/Competition"; +import Portfoliosub from "@src/Components/Portfoliosub/portfolioSub"; +import Updownsub from "@src/Components/Updownsub/postshow"; +import CompetitionSub from "@src/Components/compsub/competitionsub"; import { BrowserRouter, Route, Routes } from "react-router-dom"; import { RecoilRoot } from "recoil"; diff --git a/SOPOLAST/src/Components/common/Sidewrite/Write.style.tsx b/SOPOLAST/src/Components/Sidewrite/Write.style.tsx similarity index 89% rename from SOPOLAST/src/Components/common/Sidewrite/Write.style.tsx rename to SOPOLAST/src/Components/Sidewrite/Write.style.tsx index 4bd91e9..ae73d89 100644 --- a/SOPOLAST/src/Components/common/Sidewrite/Write.style.tsx +++ b/SOPOLAST/src/Components/Sidewrite/Write.style.tsx @@ -3,7 +3,7 @@ import styled from "styled-components"; export const Main = styled.div` display: flex; width: 100vw; - height: 100vh; + height: 150vh; `; export const Write_Main = styled.div` display: flex; @@ -47,7 +47,9 @@ export const CategorySelect = styled.select` background-color: rgb(241, 241, 241); appearance: none; `; -export const SubmitButton = styled.button` + +export const SubmitButton = styled.input.attrs({ type: 'submit', value: "Submit" })` + z-index: 5; cursor: pointer; border: none; width: 100%; @@ -87,21 +89,24 @@ export const WriteTitlelMain = styled.div` justify-content: center; width: 100%; height: 100px; + `; export const WriteTitle = styled.input` display: flex; outline: none; border: none; width: 80%; - height: 100px; + height: 75%; flex-shrink: 0; font-size: 30px; padding-left: 10px; padding-top: 20px; + border-bottom: 1px solid #dbdbdb; `; export const WriteDetailMain = styled.div` display: flex; - justify-content: center; + flex-direction: column; + align-items: center; width: 100%; height: 100%; `; @@ -114,7 +119,6 @@ export const WriteDetail = styled.textarea` width: 80%; height: 100%; font-size: 30px; - border-top: 1px solid #dbdbdb; padding-top: 10px; padding-left: 10px; `; @@ -141,3 +145,8 @@ export const SubmitButtonMain = styled.button` cursor: pointer; background-color: white; `; +export const WriteImg = styled.img` + display: flex; + width: 70%; + height: 500px; +` \ No newline at end of file diff --git a/SOPOLAST/src/Components/Sidewrite/write.tsx b/SOPOLAST/src/Components/Sidewrite/write.tsx new file mode 100644 index 0000000..7da8156 --- /dev/null +++ b/SOPOLAST/src/Components/Sidewrite/write.tsx @@ -0,0 +1,110 @@ +import React from "react"; +import { useState, ChangeEvent, FormEvent } from "react"; +import axios from "axios"; +import Head from "src/Components/head/Head/head"; +import Side from "src/Components/Sidebar/Side/side"; +import ImgPlus from "src/Assets/image/imgplus.png"; +import SubmitImg from "src/Assets/image/submitimg.png"; +import * as s from "./Write.style"; +import { showToast } from "src/constants/Swal/Swal"; +import UseWrite from "src/hooks/Write/useWirte"; + +const Sidewrite = () => { + const { + title, + setTitle, + content, + setContent, + selectPlace, + setselectPlace, + Class, + setSelectClass, + selectedImg, + handleChangeImg, + onSubmitHandler, + } = UseWrite(); + return ( + + + + + + + + + 올릴곳 + setselectPlace(e.target.value)} + > + + + + + + 카테고리 + setSelectClass(e.target.value)} + > + + + + + + + + + + + 이미지추가 + + + + + + + + + + + + + + + + {/*
+ {imageSrc && Preview} +
*/} + + setTitle(e.target.value)} + /> + + + {selectedImg && } + setContent(e.target.value)} + > + + {/* {fileName &&
{fileName}
} */} +
+
+
+
+
+
+ ); +}; + +export default Sidewrite; diff --git a/SOPOLAST/src/Components/common/Updown/Post/Post.Style.tsx b/SOPOLAST/src/Components/Updown/Post/Post.Style.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Updown/Post/Post.Style.tsx rename to SOPOLAST/src/Components/Updown/Post/Post.Style.tsx diff --git a/SOPOLAST/src/Components/Updown/Post/Post.tsx b/SOPOLAST/src/Components/Updown/Post/Post.tsx new file mode 100644 index 0000000..85f3003 --- /dev/null +++ b/SOPOLAST/src/Components/Updown/Post/Post.tsx @@ -0,0 +1,92 @@ +import React, { useState, useEffect } from "react"; +import axios from "axios"; +import { useNavigate } from "react-router-dom"; +import Magnifying from "src/constants/magnifying/Magnifying/Magnifying"; +import * as s from "src/Components/Updown/Post/Post.Style"; +import SEOUL from "src/Assets/image/3.png"; +import { link } from "fs"; +import Pagination from "src/constants/Pagination/Pagination"; +interface Post { + id: number; + author: string; + title: string; + content: string; + date: string; + image: string; +} + +export default function UpdownPost() { + const navigate = useNavigate(); + const [currentPage, setCurrentPage] = useState(1); + const [postsPerPage] = useState(10); + const [posts, setPosts] = useState([]); + const [boardList, setBoardList] = useState([]); + + const getBoardList = async () => { + const resp = await (await axios.get('SERVER_URL')).data; // 2) 게시글 목록 데이터에 할당 + setBoardList(resp.data); // 3) boardList 변수에 할당 + console.log(boardList); + } + + useEffect(() => { + getBoardList(); // 1) 게시글 목록 조회 함수 호출 + }, []); + + //페이지네이션 변경 시 이벤트 처리 + const paginate = (pageNumber: number) => setCurrentPage(pageNumber); + return ( + + + + + { + navigate("/Updownsub"); + }} + > + + 김가영 + 4개교 연합 해커톤 프론트엔드 + + 2023년 08월 24일 4개교 연합 해커톤을 진행했다.고종현 님 + @manudeli 경력 요기요에서 -Merchant trine : 사장님 관련 서비스 + 사장 사이트, 사장 관리자 서비스 공통 요기요 디자인, FE 나의 + 이야기 제대 전, 수포자 고등학생에서 미대생(디자인전공)으로서의 + 삶... + + 2023.11.02 + + + 이미지 + + + + + { + navigate("/Updownsub"); + }} + > + {boardList.map((board) => ( + // 4) map 함수로 데이터 출력 + + {board.name} + {board.title} + {board.content} + {board.data} + + {board.image} + + + ))} + + + + + + ); +} diff --git a/SOPOLAST/src/Components/common/Updown/Updown.style.tsx b/SOPOLAST/src/Components/Updown/Updown.style.tsx similarity index 100% rename from SOPOLAST/src/Components/common/Updown/Updown.style.tsx rename to SOPOLAST/src/Components/Updown/Updown.style.tsx diff --git a/SOPOLAST/src/Components/common/Updown/updownmain.tsx b/SOPOLAST/src/Components/Updown/updownmain.tsx similarity index 74% rename from SOPOLAST/src/Components/common/Updown/updownmain.tsx rename to SOPOLAST/src/Components/Updown/updownmain.tsx index 94ee7b5..2ace9fb 100644 --- a/SOPOLAST/src/Components/common/Updown/updownmain.tsx +++ b/SOPOLAST/src/Components/Updown/updownmain.tsx @@ -2,9 +2,9 @@ import React from "react"; import { Link, useNavigate } from "react-router-dom"; import Sidename from "src/Components/Sidebar/Side/side"; import Head from "src/Components/head/Head/head"; -import UpdownPost from "src/Components/common/Updown/Post/Post"; +import UpdownPost from "@src/Components/Updown/Post/Post"; -import * as s from "src/Components/common/Updown/Updown.style"; +import * as s from "@src/Components/Updown/Updown.style"; export default function Updown() { const navigate = useNavigate(); diff --git a/SOPOLAST/src/Components/Updownsub/postshow.Style.tsx b/SOPOLAST/src/Components/Updownsub/postshow.Style.tsx new file mode 100644 index 0000000..0f6a10a --- /dev/null +++ b/SOPOLAST/src/Components/Updownsub/postshow.Style.tsx @@ -0,0 +1 @@ +import styled from "styled-components"; diff --git a/SOPOLAST/src/Components/common/Updownsub/postshow.css b/SOPOLAST/src/Components/Updownsub/postshow.css similarity index 100% rename from SOPOLAST/src/Components/common/Updownsub/postshow.css rename to SOPOLAST/src/Components/Updownsub/postshow.css diff --git a/SOPOLAST/src/Components/Updownsub/postshow.tsx b/SOPOLAST/src/Components/Updownsub/postshow.tsx new file mode 100644 index 0000000..3710755 --- /dev/null +++ b/SOPOLAST/src/Components/Updownsub/postshow.tsx @@ -0,0 +1,46 @@ +import React, { useState, useEffect } from "react"; +import { useParams } from 'react-router-dom'; +import axios from "axios"; +import * as s from "src/Components/Updownsub/postshow.Style"; +import Sidename from "src/constants/Sidebar/Side/side"; +import Head from "src/constants/head/Head/head"; + +interface Post { + id: number; + author: string; + title: string; + content: string; + date: string; + image: string; +} +const BoardDetail = () => { + const { idx } = useParams(); // /board/:idx와 동일한 변수명으로 데이터를 꺼낼 수 있습니다. + const [loading, setLoading] = useState(true); + const [board, setBoard] = useState([]); + const getBoard = async () => { + const resp = await (await axios.get('SERVER_URL')).data; // 2) 게시글 목록 데이터에 할당 + setBoard(resp.data); // 3) boardList 변수에 할당 + console.log(board); + } + + useEffect(() => { + getBoard(); // 1) 게시글 목록 조회 함수 호출 + }, []); + + return ( +
+ + +
+ {board.map((board) => ( +
+ {board.title} + {board.name} + {board.image} + {board.content} +
+ ))} +
+
+ ); +}; \ No newline at end of file diff --git a/SOPOLAST/src/Components/common/Portfolio/portfolioMain.tsx b/SOPOLAST/src/Components/common/Portfolio/portfolioMain.tsx deleted file mode 100644 index 577c3b4..0000000 --- a/SOPOLAST/src/Components/common/Portfolio/portfolioMain.tsx +++ /dev/null @@ -1,132 +0,0 @@ -import React from "react"; -import { useNavigate } from "react-router-dom"; -import cnsLogo from "../../Assets/image/cnsLogo.png"; -import b1nd from "../../Assets/image/b1nd.png"; -import Sidename from "src/Components/Sidebar/Side/side"; -import "./protfolio.css"; -import Head from "src/Components/head/Head/head"; - -import * as S from "./portfolioMain.style"; - -export default function Portfolio() { - const majorClick = (major) => { - console.log(`Clicked on ${major}`); - }; - - const majorbutton: HTMLElement | null = - document.getElementById("majorbutton"); - - if (majorbutton) { - majorbutton.addEventListener("click", function () { - if (majorbutton.classList.contains("clicked")) { - majorbutton.classList.remove("clicked"); - } else { - majorbutton.classList.add("clicked"); - } - }); - } - - const navigate = useNavigate(); - return ( -
-
- - - - - - - - - - - <> - - - - - - - - | - - majorClick("프론트엔드")}> - 프론트엔드 - - - majorClick("백엔드")}> - 백엔드 - - - majorClick("안드로이드")}> - 안드로이드 - - - majorClick("iOS")}> - iOS - - - majorClick("임베디드")}> - 임베디드 - - - majorClick("AI")}>AI - - majorClick("정보보안")}> - 정보보안 - - - majorClick("디자인")}> - 디자인 - - - - - - - - { - navigate("/52562893"); - }} - > - 배채희 - DGSW 8th - Mail - chaeeehui@gmail.com - - - { - navigate("/12362153"); - }} - > - 박규민 - DGSW 8th - Mail - kyumin7487@gmail.com - - - - 전우진 - DGSW 8th - Mail - woojin@gmail.com - - - - 이윤선 - DGSW 8th - Mail - younssun@gmail.com - - - - 이예진 - DGSW 8th - Mail - yejin@gmail.com - - -
-
- ); -} - -// export default portfolio(); diff --git a/SOPOLAST/src/Components/common/Portfolio/protfolio.css b/SOPOLAST/src/Components/common/Portfolio/protfolio.css deleted file mode 100644 index 02c4d70..0000000 --- a/SOPOLAST/src/Components/common/Portfolio/protfolio.css +++ /dev/null @@ -1,398 +0,0 @@ - .proBox_{ - position: relative; - - display: inline-block; - - width: 320px; - height: 640px; - flex-shrink: 0; - border-radius: 10px; - background: #F5F5F6; - box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25); - margin-left: 40px; - margin-top: 200px; - - color: #000; - font-family: Inter; - font-size: 25px; - font-style: normal; - font-weight: 800; - line-height: normal; - - overflow: hidden; - } - - .proBox_ > .proName{ - position: absolute; - - width: 70.318px; - height: 28.444px; - flex-shrink: 0; - margin: 46.46px 0 0 28.54px; - } - - .proHr{ - - border: #A7A7A7 solid 0.9px; - width: 320px;; - - margin-top: 30.34px; - margin-left: -28.4px; - } - - .proBio{ - margin-top: 30px; - - font-size: 17px; - font-style: normal; - font-weight: 700; - white-space: nowrap; - } - - .proBio > .firstBio{ - font-size: 18px; - font-weight: 800; - } - - .secondBio{ - margin-top: 10px; - } - - .skillTitle{ - margin-top: 20px; - font-size: 20px; - font-weight: 800; - } - - .awardTitle{ - margin-top: 20px; - font-size: 20px; - font-weight: 800; - } - - .bioInfo{ - margin-top: 20px; - } - - .bioInfo > .oddBio{ - margin-top: 10px; - } - - .imgBio{ - width: 20px; - height: 20px; - - vertical-align: middle; - } - - .perBio{ - font-weight: 600; - font-size: 15px; - - vertical-align: middle; - - margin-left: 10px; - } - - .searchBox{ - display: flex; - position: absolute; - left: 300px; - top: 100px; - width: 840px; - height: 150px; - flex-shrink: 0; - - /* border-radius: 50px; - border: 1px solid #178915; - background: #FFF; */ - } - .search{ - position: absolute; - display: inline-block; - top: 10px; - left: 180px; - width: 840px; - height: 50px; - flex-shrink: 0; - border-radius: 50px; - border: 1px solid #1A9A18; - background: #FFF; - } - .search_icon{ - position: absolute; - cursor: pointer; - background-color: #FFF; - top: 9px; - left: 790px; - width: 25px; - height: 25px; - flex-shrink: 0; - border: 1px solid #1A9A18; - border-radius: 50%; - } - .searcg_icon_line{ - position: absolute; - cursor: pointer; - top: 35px; - left: 809px; - background-color: #1A9A18; - transform: rotate( 50deg ); - width: 13px; - height: 1px; - flex-shrink: 0; - stroke-width: 1px; - stroke: #1A9A18; - } - .search_box{ - position: relative; - outline: none; - font-size: 20px; - left: 20px; - top: 4px; - border: none; - width: 750px; - height: 40px; - } - - .searchBox > .searchFito{ - margin-left: 797px; - margin-top: 11.5px; - } - - .gradeSelect{ - width: 80px; - height: 40px; - color: #000; - border: none; - - font-size: 30px; - font-weight: 600; - font-family: Inter; - - margin-top: 20px; - - display: inline; - - } - .gradeSelet::-ms-expand { - display: none; -} - - .gradegreen{ - color: green; - font-size: 30px; - - position: relative; - display: inline; - } - .stackLine{ - position: absolute; - width: 100%; - height: 100px; - bottom: 0px; - left: 200px; - display: inline-block; - } - .majorSelect{ - display: inline; - color: #A7A7A7; - font-family: Inter; - font-size: 20px; - font-style: normal; - font-weight: 600; - line-height: normal; - position: relative; - - } - - .majorbutton{ - border: none; - background-color: none; - - padding: 13px; - - display: inline; - color: #A7A7A7; - font-family: Inter; - font-size: 20px; - font-style: normal; - font-weight: 600; - line-height: normal; - position: relative; - - background: none; - } - - .majorbutton:hover, - .majorbutton.clicked { - color: #1A9A18 !important; - cursor: pointer; - - background-color: none; - } - - /* .majorSelect > .frontEnd{ - display: inline-block; - color: #1A9A18; - margin-top: 27px; - - } - .majorSelect > .frontEnd:active{ - cursor: pointer; - color: #178915; - } - .elseMajor{ - display: inline-block; - margin-left: 25px; - } - .elseMajor:active{ - cursor: pointer; - color: #178915; - } */ - - - .mo{ - position: absolute; - left: 460px; - top: 200px; - width: 900px; - height: 1000px; - - } - - .mo>.namecardBox:hover{ - cursor: pointer; - } - .mo>.namecardBox{ - width: 840px; - height: 130px; - flex-shrink: 0; - border-radius: 10px; - background: #FFF; - box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25); - - position: absolute; - margin-left: 22px; - margin-top: 30px; - - display: inline-block; - } - - .nameName{ - color: #000; - font-family: Inter; - font-size: 25px; - font-style: normal; - font-weight: 800; - line-height: normal; - - position: absolute; - - margin-top: 22px; - margin-left: 33px; - } - - .nameGrade{ - color: #8C8C8C; - font-family: Inter; - font-size: 20px; - font-style: normal; - font-weight: 700; - line-height: normal; - - position: absolute; - - margin-top: 55px; - margin-left: 33px; - } - - .nameMail{ - color: #8C8C8C; - font-family: Inter; - font-size: 15px; - font-style: normal; - font-weight: 500; - line-height: normal; - - position: absolute; - - margin-top: 99px; - margin-left: 33px; - } - - .cnsLogo{ - width: 73px; - height: 40px; - flex-shrink: 0; - margin-top: 10px; - margin-left: 747px; - } - - .mo>.namecardBox2{ - width: 840px; - height: 130px; - flex-shrink: 0; - border-radius: 10px; - background: #FFF; - box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25); - - position: absolute; - margin-left: 22px; - margin-top: 180px; - cursor: pointer; - display: inline-block; - } - - - .b1ndLogo{ - width: 70px; - height: 70px; - margin-top: 10px; - margin-left: 760px; - } - - .mo>.namecardBox3{ - width: 840px; - height: 130px; - flex-shrink: 0; - border-radius: 10px; - background: #FFF; - box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25); - - position: absolute; - margin-left: 22px; - margin-top: 330px; - - display: inline-block; - } - - .mo>.namecardBox4{ - width: 840px; - height: 130px; - flex-shrink: 0; - border-radius: 10px; - background: #FFF; - box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25); - - position: absolute; - margin-left: 22px; - margin-top: 480px; - - display: inline-block; - } - - .mo>.namecardBox5{ - width: 840px; - height: 130px; - flex-shrink: 0; - border-radius: 10px; - background: #FFF; - box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25); - - position: absolute; - margin-left: 22px; - margin-top: 640px; - - display: inline-block; - } \ No newline at end of file diff --git a/SOPOLAST/src/Components/common/Sidewrite/write.tsx b/SOPOLAST/src/Components/common/Sidewrite/write.tsx deleted file mode 100644 index 4ed8bcc..0000000 --- a/SOPOLAST/src/Components/common/Sidewrite/write.tsx +++ /dev/null @@ -1,174 +0,0 @@ -import React from "react"; -import { useState, ChangeEvent, FormEvent } from "react"; -import axios from "axios"; -import Head from "src/Components/head/Head/head"; -import Side from "../../Sidebar/Side/side"; -import ImgPlus from "src/Assets/image/imgplus.png"; -import SubmitImg from "src/Assets/image/submitimg.png"; -import * as s from "./Write.style"; -import { showToast } from "src/constants/Swal/Swal"; -import { ConfirmToast } from "src/constants/Swal/confirm"; - -const Sidewrite = () => { - const [title, setTitle] = useState(""); - const [selectPlace, setselectPlace] = useState(""); - const [selectedImg, setSelectedImg] = useState(null); - - const handleChangeImg = (e: React.ChangeEvent): void => { - const file = e.target.files?.[0]; - const reader = new FileReader(); - - reader.onload = () => { - setSelectedImg(reader.result as string); - }; - if (file) { - reader.readAsDataURL(file); - } - }; - const [content, setContent] = useState(""); - // const [imageSrc, setImageSrc] = useState(null); - // const [selectedImage, setSelectedImage] = useState(null); - // const [fileName, setFileName] = useState(null); - // const localStorageEmail = localStorage.getItem("sopo_id"); - // const SERVERURL = `${process.env.REACT_APP_SERVER_URL}`; - - const onSubmitHandler = async (e: FormEvent) => { - console.log("hello"); - - e.preventDefault(); - ConfirmToast("warning", "글을 올리겠습니까?", "", "success", "완료", ""); - if (ConfirmToast) { - console.log("hello"); - } - - // if (!title || !content) { - // showToast("error", "제목, 내용을 모두 입력해주세요."); - // return; - // } - - // const formData = new FormData(); - // const data = { - // title, - // content, - // email: localStorageEmail, - // }; - - // formData.append( - // "data", - // new Blob([JSON.stringify(data)], { type: "application/json" }) - // ); - - // if (selectPlace === "게시물" && selectedImage) { - // formData.append("image", selectedImage); - // } - - // try { - // let response; - // if (selectPlace === "게시물") { - // await axios.post(`${SERVERURL}/senior-to-junior/create`, formData, { - // headers: { - // "Content-Type": "multipart/form-data", - // }, - // }); - // } else if (selectPlace === "대회") { - // response = await axios.post(SERVERURL + "#", formData, { - // headers: {}, - // }); - // } - // } catch (error) { - // console.error("Error:", error); - // } - // }; - - // const handleImageChange = (e: ChangeEvent) => { - // const selectedImage = e.target.files?.[0]; - // setSelectedImage(selectedImage); - // setFileName(selectedImage ? selectedImage.name : null); - // setImageSrc(selectedImage ? URL.createObjectURL(selectedImage) : null); - // }; - }; - return ( - <> - - - - - - - - - 올릴곳 - setselectPlace(e.target.value)} - > - - - - - - 카테고리 - - - - - - - - - - - - 이미지추가 - - - - - - - - Submit - - - - - - - - {/*
- {imageSrc && Preview} -
*/} - - setTitle(e.target.value)} - /> - - - setContent(e.target.value)} - > - - - {/* {fileName &&
{fileName}
} */} -
-
-
-
-
-
- - ); -}; - -export default Sidewrite; diff --git a/SOPOLAST/src/Components/common/Updown/Post/Post.tsx b/SOPOLAST/src/Components/common/Updown/Post/Post.tsx deleted file mode 100644 index 3a9b829..0000000 --- a/SOPOLAST/src/Components/common/Updown/Post/Post.tsx +++ /dev/null @@ -1,212 +0,0 @@ -import React, { useState, useEffect } from "react"; -import axios from "axios"; -import { useNavigate } from "react-router-dom"; -import Magnifying from "src/Components/magnifying/Magnifying/Magnifying"; -import * as s from "src/Components/common/Updown/Post/Post.Style"; -import B1CODE from "src/Assets/img/B1CODE.png"; -import SEOUL from "src/Assets/image/3.png"; -import Yogiyo from "src/Assets/image/1.png"; -import KOREA from "src/Assets/image/2.png"; -import MAC from "src/Assets/img/MAC.JPG"; -import { link } from "fs"; -import Pagination from "src/Components/Pagination/Pagination"; -// const UpdownPost = () => { -// const SERVERURL = `${process.env.REACT_APP_SERVER_URL}`; -// const navigate = useNavigate(); -// const [Post, setPost] = useState([]); -// }; -// useEffect(() => { -// AddPosts(); -// }, []); -// const AddPosts = () => { -// axios -// .get(`${SERVERURL}/posts`) -// .then((response) => { -// const AddPosts = response.data; -// setPost(AddPosts); -// console.log("게시물 목록을 가져왔습니다", AddPosts); -// }) -// .catch((error) => { -// console.error("Error:",error); -// }); -// } -// const handlePostClick = (postId) => { -// axios -// .post(`${SERVERURL}/senior-to-junior/read`, { postId: postId }) -// .then((response) => { -// console.log("게시물 요청이 성공했습니다. 서버 응답:", response.data); -// window.location.href = response.data.redirectTo; -// }) -// .catch((error) => { -// console.error("Error:", error); -// }); -// GetPost(postId); -// } -// const GetPost = (postId) => { -// axios -// .get(`${SERVERURL}/read/${postId}`) -// .then((response) => { -// const postContent = response.data; -// console.log("게시물 내용을 가져옵니다:", postContent); -// }) -// .catch((error) => { -// console.error("Error:", error); -// }); -// }; -interface Post { - id: number; - author: string; - title: string; - content: string; - date: string; - image: string; -} - -export default function UpdownPost() { - const navigate = useNavigate(); - const [currentPage, setCurrentPage] = useState(1); - const [postsPerPage] = useState(10); - const [posts, setPosts] = useState([]); - //게시물 가져오기 - useEffect(() => { - axios.get("/api/posts").then((response) => { - setPosts(response.data); - }); - }, []); - //현재 페이지의 게시물 가져오기 - const indexOfLastPost: number = currentPage * postsPerPage; - const indexOfFirstPost: number = indexOfLastPost - postsPerPage; - const currentPosts: Post[] = posts.slice(indexOfFirstPost, indexOfLastPost); - //페이지네이션 변경 시 이벤트 처리 - const paginate = (pageNumber: number) => setCurrentPage(pageNumber); - return ( - - - - - { - navigate("/Updownsub"); - }} - > - - 김가영 - 4개교 연합 해커톤 프론트엔드 - - 2023년 08월 24일 4개교 연합 해커톤을 진행했다.고종현 님 - @manudeli 경력 요기요에서 -Merchant trine : 사장님 관련 서비스 - 사장 사이트, 사장 관리자 서비스 공통 요기요 디자인, FE 나의 - 이야기 제대 전, 수포자 고등학생에서 미대생(디자인전공)으로서의 - 삶... - - 2023.11.02 - - - 이미지 - - - - - - - - 배채희 - 4개교 연합 해커톤 - SW창업 알고보면 어렵지 않다 - - 스타트업 창업 상상을 현실로 이끄는 액션 플랜 온택트 코리아 - 최지연님

자신에게 구매욕구가 확실하게 작용하지 않으면 - 매출로 이어지지 않는다.

전화 - 고객접접 만들기 - 어려웠다. 현장 - 못들어오게 함. -
- 2023.10.28 -
- - 이미지 - -
-
- - - - 이해준 - 바인드 컨버런스를 듣고나서. - - 오늘은 팀 바인드에서 주최한 컨퍼런스 바코드에 대해 이야기 하려 - 한다.

​바코드? 작년겨울 시작 - 주로 일학년을 대상으로 - 새내기 개발자들에게 꼭 필요한 지식 전하는 컨퍼런스.

Git - & GitHub / 백엔드 이지민선배 -
- 2023.10.27 -
- - 이미지 - -
-
- - - - 박규민 - 경쟁 서비스 분석 및 비지니스 모델 이해 - - 경쟁서비스 분석 및 비지니스모델 이해 서울 신학대학교 이형주 - 교수님

- 독창성,시장성(경쟁서비스에 대한 분석 및 이해가 적절한가?), - 사업계획 완성도

- (제시한 서비스의 사업 모델이 설득력 있는가?) 경쟁서비스 이해 -
- 2023.10.27 -
- - 이미지 - -
-
- - - - 전우진 - 4개교 연합 해커톤 - SW창업 알고보면 어렵지 않다 - - 1학기, 3월부터 8월까지라는 짧지 않은 시간이 지났기에

- 나는 블로그의 첫글을 회고록으로 시작하고자 한다.

왜 - 회고록을 쓰는가? 라고 묻는다면 난 단연코 '성장' 하기 위해서라고 - 생각한다.

- 나는 그리 똑똑한 사람이 아니기에 어떤한 일의 모든 감정과, 그 - 당시 느낀 귀중한 생각을 -
- 2023.10.25 -
- - 이미지 - -
-
- - - - 김호준 - 바인드 컨퍼런스를 주최하며 느낀점 - - 연말을 맞이하며 바인드 컨퍼런스를 주최하게 되었습니다. - 컨퍼런스를 직접 듣고

- 처음 개최하는 컨퍼런스이기에 발표를 맞게 되어 너무 떨렸습니다. - 꽤나 부담감을 느끼는 시간

- 속에서 바인드 컨퍼런스를 하는 날이 밝았습니다. -
- 2023.10.18 -
- - 이미지 - -
-
- -
-
- ); -} diff --git a/SOPOLAST/src/Components/common/Updownsub/postshow.tsx b/SOPOLAST/src/Components/common/Updownsub/postshow.tsx deleted file mode 100644 index 23b23d2..0000000 --- a/SOPOLAST/src/Components/common/Updownsub/postshow.tsx +++ /dev/null @@ -1,55 +0,0 @@ -import React from "react"; -import "./postshow.css"; -import Sidename from "src/Components/Sidebar/Side/side"; -import TEST6 from "src/Assets/image/1.png"; -import Head from "src/Components/head/Head/head"; - -export default function Start() { - return ( -
-
- - -
-
-
- 4개교 연합 해커톤 프론트엔드 -

- 김가영 -

- - 이미지 - - -
경쟁서비스 이해
-

- 같은 고객층에게 비슷한 가격으로 공급하고 있는 자사 - 서비스와 시슷한 제품과 서비스

- 기업 관점의 경재자, 시장 - 관점의 경쟁자

-

- 기업관점 - (음료) 펩시, 코카콜라, 닥터펩시

- 시장관점 - (갈증해소) 생과일 주스, 물, 콜라, 이온음료

-

- 효율성 - 내 제춤 경쟁제품으로 자리매김, 차별성 위한 - 기준점 방향 제시

- 내가 공략라는 목표고객 제시, 문제 - 남겨준 선구자

- 큰 사업전개를 위해 필요한 파트너(유통, - 공급)를 개척해 공유하는 자

- 내가 돈 벌 수 있는 차별적인 - 사업 모델에 대해 기반을 제공해주는 개척자

- 내 사업의 - multiple을 만들어 나에게 기어가치 제공, 투자유치 용이 도우미 -

- 일정 시장 검봉 후 해당 제품과 서비스 및 기업을 - 인수하는 acquirer(사업인수자 등등)

-

-
작성가이드
-

- 우리팀 서비스에 대한 경쟁 서비스 3-5 선정

- 세계적인 - 서비스 보다 마켓 출시 5년 이내의 서비스 중 선정

-

- 선쟁 경쟁서비스를 직접 사용한 후 우리팀 서비스와 비교

- - 비교 할 요소는 개요, 주요기능, 강약점, 서비스 목표 및 전략, - 서비스 기술

-
-
-
-
-
-
- ); -} diff --git a/SOPOLAST/src/Components/common/compsub/cometitionsub.css b/SOPOLAST/src/Components/compsub/cometitionsub.css similarity index 100% rename from SOPOLAST/src/Components/common/compsub/cometitionsub.css rename to SOPOLAST/src/Components/compsub/cometitionsub.css diff --git a/SOPOLAST/src/Components/common/compsub/competitionsub.style.ts b/SOPOLAST/src/Components/compsub/competitionsub.style.ts similarity index 100% rename from SOPOLAST/src/Components/common/compsub/competitionsub.style.ts rename to SOPOLAST/src/Components/compsub/competitionsub.style.ts diff --git a/SOPOLAST/src/Components/common/compsub/competitionsub.tsx b/SOPOLAST/src/Components/compsub/competitionsub.tsx similarity index 100% rename from SOPOLAST/src/Components/common/compsub/competitionsub.tsx rename to SOPOLAST/src/Components/compsub/competitionsub.tsx diff --git a/SOPOLAST/src/Pages/MainPage/mainpage.tsx b/SOPOLAST/src/Pages/MainPage/mainpage.tsx index 618e95a..a6dd464 100644 --- a/SOPOLAST/src/Pages/MainPage/mainpage.tsx +++ b/SOPOLAST/src/Pages/MainPage/mainpage.tsx @@ -1,10 +1,10 @@ import React from "react"; -import * as S from "src/Components/common/Home/Style/Main.style"; -import Post from "src/Components/common/Home/Post/post"; +import * as S from "@src/Components/Home/Style/Main.style"; +import Post from "@src/Components/Home/Post/post"; import Head from "src/Components/head/Head/head"; -import SideName from "src/Components/common/Home/SideName/sidename"; -import Footer from "src/Components/common/Home/Footer/Fotter"; -import MainCard from "src/Components/common/Home/Card/Maincard"; +import SideName from "@src/Components/Home/SideName/sidename"; +import Footer from "@src/Components/Home/Footer/Fotter"; +import MainCard from "@src/Components/Home/Card/Maincard"; export default function Start() { return ( diff --git a/SOPOLAST/src/constants/MajorLine/Major.style.ts b/SOPOLAST/src/constants/MajorLine/Major.style.ts new file mode 100644 index 0000000..1afe2db --- /dev/null +++ b/SOPOLAST/src/constants/MajorLine/Major.style.ts @@ -0,0 +1,68 @@ +import styled, { css } from "styled-components"; +interface HeaderLiProps { + active: boolean; +} + +export const StackLine = styled.div` + position: absolute; + width: 100%; + height: 100px; + bottom: 0px; + left: 200px; + display: inline-block; +`; + +export const GradeSelect = styled.select` + width: 80px; + height: 40px; + color: #000; + border: none; + font-size: 30px; + font-weight: 600; + font-family: Inter; + margin-top: 20px; + display: inline; +`; + +export const GradeGreen = styled.div` + color: green; + font-size: 30px; + position: relative; + display: inline; +`; + +export const MajorSelect = styled.div` + display: inline; + color: #a7a7a7; + font-family: Inter; + font-size: 20px; + font-style: normal; + font-weight: 600; + line-height: normal; + position: relative; +`; + +export const MajorButton = styled.button` + border: none; + background-color: none; + color: #A7A7A7; + padding: 13px; + display: inline; + font-family: Inter; + font-size: 20px; + font-style: normal; + font-weight: 600; + line-height: normal; + position: relative; + background: none; + cursor: pointer; + + &:hover { + color: #1a9a18; + } + ${(props) => + props.active && + css` + color: #1a9a18; + `} +`; diff --git a/SOPOLAST/src/constants/MajorLine/Major.tsx b/SOPOLAST/src/constants/MajorLine/Major.tsx new file mode 100644 index 0000000..d3f8e92 --- /dev/null +++ b/SOPOLAST/src/constants/MajorLine/Major.tsx @@ -0,0 +1,123 @@ +import React, { useState, useEffect } from "react"; +import { useNavigate } from "react-router-dom"; +import * as S from "src/constants/MajorLine/Major.style"; +import axios from "axios"; + +export default function Major() { + const [activeIndex, setActiveIndex] = useState(null); + const [grades, setGrades] = useState([]); + const [selectedMajorInfo, setSelectedMajorInfo] = useState(null); + const navigate = useNavigate(); + + useEffect(() => { + const fetchData = async () => { + try { + const response = await axios.get("히히api자리지롱"); + setGrades(response.data); + } catch (error) { + console.error("Error fetching data:", error); + } + }; + + fetchData(); + }, []); + + const handleClick = async (grade: string) => { + setActiveIndex(grade); + try { + const response = await axios.get(`히히api자리/${grade}`); + setSelectedMajorInfo(response.data); + } catch (error) { + console.error("Error fetching major info:", error); + } + }; + + return ( +
+
+ + + {grades.map((grade) => ( + + ))} + + + + | + + + {grades.map((grade) => ( + handleClick(grade.id)} + > + {grade.name} + + ))} + + + + handleClick("프론트엔드")} + > + 프론트엔드 + + + handleClick("백엔드")} + > + 백엔드 + + + handleClick("안드로이드")} + > + 안드로이드 + + + handleClick("Ios")} + > + iOS + + + handleClick("임베디드")} + > + 임베디드 + + + handleClick("AI")} + > + AI + + + handleClick("정보보안")} + > + 정보보안 + + + handleClick("디자인")} + > + 디자인 + + + +
+
+ ); +} diff --git a/SOPOLAST/src/constants/Swal/confirm.ts b/SOPOLAST/src/constants/Swal/confirm.ts deleted file mode 100644 index 56e3f56..0000000 --- a/SOPOLAST/src/constants/Swal/confirm.ts +++ /dev/null @@ -1,24 +0,0 @@ -import Swal from "sweetalert2"; - -const Toast = Swal.mixin({ - showCancelButton: true, - confirmButtonColor: '#3085d6', - cancelButtonColor: '#d33', - confirmButtonText: 'Yes', - cancelButtonText: 'No', - reverseButtons: true, - -}); - -export const ConfirmToast = (icon, title, text, confirmIcon, confirmTitle, confirmText) => { - Toast.fire({ - icon, - title, - text, - }).then(result =>{ - if(result.isConfirmed){ - Swal.fire(confirmIcon, confirmTitle, confirmText); - return true - } - }) -}; diff --git a/SOPOLAST/src/hooks/Write/useWirte.ts b/SOPOLAST/src/hooks/Write/useWirte.ts new file mode 100644 index 0000000..962d178 --- /dev/null +++ b/SOPOLAST/src/hooks/Write/useWirte.ts @@ -0,0 +1,91 @@ +import { useState, ChangeEvent, FormEvent } from "react"; +import { showToast } from "src/constants/Swal/Swal"; +import axios from "axios"; + +const UseSidewrite = () => { + const [title, setTitle] = useState(""); + const [content, setContent] = useState(""); + const [selectPlace, setselectPlace] = useState(""); + const [selectedImg, setSelectedImg] = useState(null); + const [Class, setSelectClass] = useState(""); + + const handleChangeImg = (e: ChangeEvent): void => { + const file = e.target.files?.[0]; + const reader = new FileReader(); + + reader.onload = () => { + setSelectedImg(reader.result as string); + }; + + if (file) { + reader.readAsDataURL(file); + } + }; + + const onSubmitHandler = async (e: FormEvent) => { + e.preventDefault(); + + if (!title || !content) { + showToast("error", "제목과 내용을 모두 입력해주세요."); + return; + } + + const formData = new FormData(); + const data = { + title, + content, + selectPlace, // 추가: 선택한 카테고리 정보 + isContest: selectPlace === "대회", // 추가: 대회인지 게시물인지 여부 + }; + + formData.append( + "data", + new Blob([JSON.stringify(data)], { type: "application/json" }) + ); + + if (selectPlace === "게시물" && selectedImg) { + formData.append("image", selectedImg); + } + + try { + let response; + if (selectPlace === "게시물") { + response = await axios.post("#", formData, { + headers: { + "Content-Type": "multipart/form-data", + }, + }); + } else if (selectPlace === "대회") { + response = await axios.post("#", formData, { + headers: { "Content-Type": "multipart/form-data" }, + }); + } + + // 서버 응답 처리 + console.log(response); + + // 콘솔에 정보가 나오도록 추가 + console.log("서버로 정보를 보냈습니다."); + console.log("보낸 데이터:", data); + console.log("선택한 카테고리:", selectPlace); // 선택한 카테고리를 콘솔에 출력 + } catch (error) { + console.error("Error:", error); + } + }; + + return { + title, + setTitle, + content, + setContent, + selectPlace, + setselectPlace, + Class, + setSelectClass, + selectedImg, + handleChangeImg, + onSubmitHandler, + }; +}; + +export default UseSidewrite; diff --git a/SOPOLAST/src/lib/Token/token.ts b/SOPOLAST/src/lib/token/token.ts similarity index 100% rename from SOPOLAST/src/lib/Token/token.ts rename to SOPOLAST/src/lib/token/token.ts