From 378b3b3b9d9fc9f0eb130e17ae899f70d0399d6f Mon Sep 17 00:00:00 2001 From: Jio Date: Wed, 28 Jan 2026 17:09:37 +0900 Subject: [PATCH 1/3] =?UTF-8?q?feat:=20=EB=B0=9B=EC=9D=80=20=EC=A0=9C?= =?UTF-8?q?=EC=95=88=20=EC=83=81=EC=84=B8=20=ED=8E=98=EC=9D=B4=EC=A7=80=20?= =?UTF-8?q?UI=20=EA=B5=AC=ED=98=84=20=EB=B0=8F=20=EB=9D=BC=EC=9A=B0?= =?UTF-8?q?=ED=8C=85=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../_business/calendar/calendar-content.tsx | 24 ++- .../proposal/received-proposal-content.tsx | 142 ++++++++++++++++++ src/routes/_main/_business/proposal/route.tsx | 28 +++- ...-content.tsx => sent-proposal-content.tsx} | 0 4 files changed, 186 insertions(+), 8 deletions(-) create mode 100644 src/routes/_main/_business/proposal/received-proposal-content.tsx rename src/routes/_main/_business/proposal/{proposal-content.tsx => sent-proposal-content.tsx} (100%) diff --git a/src/routes/_main/_business/calendar/calendar-content.tsx b/src/routes/_main/_business/calendar/calendar-content.tsx index 053faabc..305d100a 100644 --- a/src/routes/_main/_business/calendar/calendar-content.tsx +++ b/src/routes/_main/_business/calendar/calendar-content.tsx @@ -17,7 +17,7 @@ export default function CalendarContent() { const [isFilterOpen, setIsFilterOpen] = useState(false); const [activeFilter, setActiveFilter] = useState("전체"); - const hasData = matchingSubTab === "sent"; + const hasData = true; return (
@@ -86,7 +86,7 @@ export default function CalendarContent() { {hasData ? ( -
+

매칭 현황

- - - - + {matchingSubTab === "sent" ? ( + <> + + + + + + ) : ( + <> + + + + + + )}
+
) : (
diff --git a/src/routes/_main/_business/proposal/received-proposal-content.tsx b/src/routes/_main/_business/proposal/received-proposal-content.tsx new file mode 100644 index 00000000..76648c93 --- /dev/null +++ b/src/routes/_main/_business/proposal/received-proposal-content.tsx @@ -0,0 +1,142 @@ +import { useState } from "react"; + +import Header from "../../../../components/layout/Header"; +import CampaignBrandCard from "../components/CampaignBrandCard"; +import CampaignInfoGroup from "../components/CampaignInfoGroup"; + +import dropdownIcon from "../../../../assets/arrow-down.svg"; +import dropupIcon from "../../../../assets/arrow-up.svg"; +import arrowRightIcon from "../../../../assets/arrow-right.svg"; +import profileIcon from "../../../../assets/mini-logo.svg"; + +export default function ReceivedProposalContent() { + const [isContentOpen, setIsContentOpen] = useState(false); + + return ( +
+
+ +
+ {/* 1. 상단 섹션: 브랜드 카드 */} +
+ +
+

브랜드 제안 캠페인

+
+
+ + {/* 2. 상세 정보 섹션 */} +
+ {/* 캠페인명 */} + +
+ 비플레인 선크림 리뷰 콘텐츠 +
+
+ + {/* 캠페인 내용 */} + setIsContentOpen(prev => !prev)}> + toggle + + } + > +
+
+

설명

+
+ 안녕하세요 비플레인 입니다!
+ 크리에이터님과 이미지와 비플레인이 추구하는 가치가 잘 맞닿아 있다고 생각되어 협찬을 제안드립니다. +
+
+ + {/* 아코디언 상세 내용 */} + {isContentOpen && ( +
+
+ +
+ + + + +
+ )} +
+
+ + {/* 협찬품 / 원고료 */} +
+ +
+ 글로우 크림 1개 + arrow +
+
+ + +
+ 200,000 +
+
+
+ + {/* 제작 기간 */} + +
+
+ 2025년 1월 20일 +
+ ~ +
+ 2025년 1월 30일 +
+
+
+
+ + {/* 3. 하단 액션 버튼 (거절하기 / 제안 수락하기) */} +
+ + +
+
+
+ ); +} + +// 기존 ContentItem 재사용 +function ContentItem({ label, value }: { label: string; value: string }) { + return ( +
+

{label}

+
+ {value} + arrow +
+
+ ); +} \ No newline at end of file diff --git a/src/routes/_main/_business/proposal/route.tsx b/src/routes/_main/_business/proposal/route.tsx index 2ace6f05..3145bbd1 100644 --- a/src/routes/_main/_business/proposal/route.tsx +++ b/src/routes/_main/_business/proposal/route.tsx @@ -1,5 +1,29 @@ import { createFileRoute } from '@tanstack/react-router' -import ProposalContent from "./proposal-content"; +import ProposalContent from "./sent-proposal-content"; +import ReceivedProposalContent from "./received-proposal-content"; + +// 쿼리 파라미터 타입 정의 +type ProposalSearch = { + type: 'sent' | 'received' +} + export const Route = createFileRoute('/_main/_business/proposal')({ - component: ProposalContent, + // validateSearch를 통해 쿼리 파라미터를 검증하고 타입 안정성을 확보합니다. + validateSearch: (search: Record): ProposalSearch => { + return { + type: (search.type as 'sent' | 'received') || 'sent', // 기본값은 'sent' + } + }, + component: ProposalComponent, }) + +function ProposalComponent() { + const { type } = Route.useSearch(); + + // type 값에 따라 다른 컨텐츠를 보여줍니다. + if (type === 'received') { + return ; + } + + return ; +} \ No newline at end of file diff --git a/src/routes/_main/_business/proposal/proposal-content.tsx b/src/routes/_main/_business/proposal/sent-proposal-content.tsx similarity index 100% rename from src/routes/_main/_business/proposal/proposal-content.tsx rename to src/routes/_main/_business/proposal/sent-proposal-content.tsx From 07630e2e77fe76efd72a4b2165f3836bd6df995d Mon Sep 17 00:00:00 2001 From: seyun31 <2ne1jenna@naver.com> Date: Thu, 29 Jan 2026 23:33:05 +0900 Subject: [PATCH 2/3] chore: update routeTree.gen.ts --- src/routeTree.gen.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/routeTree.gen.ts b/src/routeTree.gen.ts index 2dcb809a..5ad65ced 100644 --- a/src/routeTree.gen.ts +++ b/src/routeTree.gen.ts @@ -133,6 +133,7 @@ const MainMatchingTestMatchingTestStep1RouteRoute = } as any) export interface FileRoutesByFullPath { + '/': typeof MainHomeIndexRoute '/chat': typeof MainChatRouteRouteWithChildren '/auth/login': typeof AuthLoginRouteRoute '/calendar': typeof MainBusinessCalendarRouteRoute @@ -147,7 +148,6 @@ export interface FileRoutesByFullPath { '/auth/signup/terms': typeof AuthSignupTermsRouteRoute '/auth/signup/type': typeof AuthSignupTypeRouteRoute '/chat/chatting-room': typeof MainChatChattingRoomRoute - '/': typeof MainHomeIndexRoute '/matching-test/matching-test/step1': typeof MainMatchingTestMatchingTestStep1RouteRoute '/matching-test/matching-test/step2': typeof MainMatchingTestMatchingTestStep2RouteRoute '/matching-test/matching-test/step3': typeof MainMatchingTestMatchingTestStep3RouteRoute @@ -197,6 +197,7 @@ export interface FileRoutesById { export interface FileRouteTypes { fileRoutesByFullPath: FileRoutesByFullPath fullPaths: + | '/' | '/chat' | '/auth/login' | '/calendar' @@ -211,7 +212,6 @@ export interface FileRouteTypes { | '/auth/signup/terms' | '/auth/signup/type' | '/chat/chatting-room' - | '/' | '/matching-test/matching-test/step1' | '/matching-test/matching-test/step2' | '/matching-test/matching-test/step3' @@ -274,7 +274,7 @@ declare module '@tanstack/react-router' { '/_main': { id: '/_main' path: '' - fullPath: '' + fullPath: '/' preLoaderRoute: typeof MainRouteImport parentRoute: typeof rootRouteImport } From 820c32f0c66b16e535660a3e353d80da08f6c536 Mon Sep 17 00:00:00 2001 From: seyun31 <2ne1jenna@naver.com> Date: Thu, 29 Jan 2026 23:41:58 +0900 Subject: [PATCH 3/3] =?UTF-8?q?feat:=20=EC=B2=AB=20=EC=A7=84=EC=9E=85=20?= =?UTF-8?q?=EC=8B=9C=20=EB=A1=9C=EA=B7=B8=EC=9D=B8=20=ED=8E=98=EC=9D=B4?= =?UTF-8?q?=EC=A7=80=EB=A1=9C=20=EB=A6=AC=EB=8B=A4=EC=9D=B4=EB=A0=89?= =?UTF-8?q?=ED=8A=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/routes/_main.tsx | 12 +++++++++++- .../_main/_business/components/MatchingCard.tsx | 2 +- .../_business/proposal/received-proposal-content.tsx | 4 ++-- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/src/routes/_main.tsx b/src/routes/_main.tsx index c94ff302..a0820755 100644 --- a/src/routes/_main.tsx +++ b/src/routes/_main.tsx @@ -1,10 +1,20 @@ -import { createFileRoute, Outlet } from "@tanstack/react-router"; +import { createFileRoute, Outlet, redirect } from "@tanstack/react-router"; import BottomTab from "./_main/components/BottomTab"; import { useState } from "react"; import { LayoutContext } from "./_main/layout-context"; import Logo from "../assets/logo/RealMatchLogo_ex.svg"; +import { useAuthStore } from "../stores/auth-store"; export const Route = createFileRoute("/_main")({ + beforeLoad: () => { + // 처음 진입 시 로그인 페이지로 + const { me } = useAuthStore.getState(); + if (!me) { + throw redirect({ + to: "/login", + }); + } + }, component: MainLayout, }); diff --git a/src/routes/_main/_business/components/MatchingCard.tsx b/src/routes/_main/_business/components/MatchingCard.tsx index f29280a7..2ebd1402 100644 --- a/src/routes/_main/_business/components/MatchingCard.tsx +++ b/src/routes/_main/_business/components/MatchingCard.tsx @@ -1,5 +1,5 @@ import chatIcon from "../../../../assets/chat-icon2.svg"; -import searchIcon from "../../../../assets/search.svg"; +import searchIcon from "../../../../assets/icon/search.svg"; interface MatchingCardProps { brand: string; diff --git a/src/routes/_main/_business/proposal/received-proposal-content.tsx b/src/routes/_main/_business/proposal/received-proposal-content.tsx index 76648c93..66d3396a 100644 --- a/src/routes/_main/_business/proposal/received-proposal-content.tsx +++ b/src/routes/_main/_business/proposal/received-proposal-content.tsx @@ -6,8 +6,8 @@ import CampaignInfoGroup from "../components/CampaignInfoGroup"; import dropdownIcon from "../../../../assets/arrow-down.svg"; import dropupIcon from "../../../../assets/arrow-up.svg"; -import arrowRightIcon from "../../../../assets/arrow-right.svg"; -import profileIcon from "../../../../assets/mini-logo.svg"; +import arrowRightIcon from "../../../../assets/icon/arrow-right.svg"; +import profileIcon from "../../../../assets/logo/mini-logo.svg"; export default function ReceivedProposalContent() { const [isContentOpen, setIsContentOpen] = useState(false);