From 646e5fc7169f8d28236d27151a5fffbea8e79535 Mon Sep 17 00:00:00 2001 From: Yoonchulchung Date: Thu, 12 Feb 2026 14:21:11 +0900 Subject: [PATCH 1/8] =?UTF-8?q?fix:=20=EC=BC=90=ED=8E=98=EC=9D=B8=20?= =?UTF-8?q?=EC=83=81=EC=84=B8=20=ED=8E=98=EC=9D=B4=EC=A7=80=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/routes/campaign-detail/route.tsx | 8 ++++++++ app/routes/home/home-after-match.tsx | 3 ++- app/routes/matching/campaign/campaign-content.tsx | 2 +- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/app/routes/campaign-detail/route.tsx b/app/routes/campaign-detail/route.tsx index d8981442..919d626c 100644 --- a/app/routes/campaign-detail/route.tsx +++ b/app/routes/campaign-detail/route.tsx @@ -21,6 +21,7 @@ export default function CampaignDetailRoute() { const brandIdParam = searchParams.get("brandId"); const domainParam = searchParams.get("domain"); const campaignIdParam = searchParams.get("campaignId"); + const matchRateParam = searchParams.get("matchRate"); const campaignId = useMemo(() => { const n = campaignIdParam ? Number(campaignIdParam) : NaN; @@ -104,7 +105,14 @@ export default function CampaignDetailRoute() { brandId: String(resolvedBrandId), domain: resolvedDomain ?? undefined, }); + if (!alive) return; + + const paramRate = matchRateParam ? Number(matchRateParam) : NaN; + if (Number.isFinite(paramRate) && paramRate > 0) { + res.matchRate = paramRate; + } + setData(res); setError(null); } catch { diff --git a/app/routes/home/home-after-match.tsx b/app/routes/home/home-after-match.tsx index 54b24eca..8b30c287 100644 --- a/app/routes/home/home-after-match.tsx +++ b/app/routes/home/home-after-match.tsx @@ -231,8 +231,9 @@ export default function HomeAfterMatchPage() { const brandId = getBrandIdFromCampaign(c); if (!campaignId || !brandId) return; + const rate = c.matchRate || 0; navigate( - `/campaign?brandId=${brandId}&campaignId=${campaignId}&domain=${category}`, + `/campaign?brandId=${brandId}&campaignId=${campaignId}&domain=${category}&matchRate=${rate}`, ); }; diff --git a/app/routes/matching/campaign/campaign-content.tsx b/app/routes/matching/campaign/campaign-content.tsx index 52fe9264..40d48a31 100644 --- a/app/routes/matching/campaign/campaign-content.tsx +++ b/app/routes/matching/campaign/campaign-content.tsx @@ -205,7 +205,7 @@ export default function CampaignContent() { applicants={campaign.applicants} isLiked={campaign.isLiked} onLike={() => toggleLike(campaign.id)} - onClick={() => navigate(`/campaign?campaignId=${campaign.id}&brandId=${campaign.brandId}&domain=${category.toLowerCase()}`)} + onClick={() => navigate(`/campaign?campaignId=${campaign.id}&brandId=${campaign.brandId}&domain=${category.toLowerCase()}&matchRate=${campaign.matchingRatio || campaign.matchRate || 0}`)} logoUrl={campaign.logoUrl || `/dummy-logo-${campaign.id}.png`} dDay={campaign.dDay} /> From 4ca92e342856f5e514d83a0fcc265d404ff48ddb Mon Sep 17 00:00:00 2001 From: Yoonchulchung Date: Thu, 12 Feb 2026 15:14:22 +0900 Subject: [PATCH 2/8] =?UTF-8?q?fix:=20=EC=BC=90=ED=8E=98=EC=9D=B8=20?= =?UTF-8?q?=EC=83=81=EC=84=B8=20=ED=8E=98=EC=9D=B4=EC=A7=80=20UI?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../brand-detail/components/BrandHero.tsx | 4 +- .../brand-detail/components/BrandInfo.tsx | 4 +- .../components/OngoingCampaignSection.tsx | 4 +- .../campaign-detail/campaign-detail.tsx | 39 ++++++++++--------- .../components/CampaignActionBar.tsx | 7 +++- 5 files changed, 31 insertions(+), 27 deletions(-) diff --git a/app/routes/brand-detail/components/BrandHero.tsx b/app/routes/brand-detail/components/BrandHero.tsx index 6876ed8a..ccfc920b 100644 --- a/app/routes/brand-detail/components/BrandHero.tsx +++ b/app/routes/brand-detail/components/BrandHero.tsx @@ -35,8 +35,8 @@ export default function BrandHero({ 뒤로가기 -
-
+
+
{logoImageUrl ? ( +
{name}
@@ -25,7 +25,7 @@ export default function BrandInfo({
-
+
{hashtags .map((tag) => (tag.startsWith("#") ? tag : `#${tag}`)) .join(" ")} diff --git a/app/routes/brand-detail/components/OngoingCampaignSection.tsx b/app/routes/brand-detail/components/OngoingCampaignSection.tsx index 8dd42636..7f23ebb6 100644 --- a/app/routes/brand-detail/components/OngoingCampaignSection.tsx +++ b/app/routes/brand-detail/components/OngoingCampaignSection.tsx @@ -15,14 +15,14 @@ export default function OngoingCampaignSection({ campaigns, onMore }: Props) { {isEmpty ? (
- 캠페인 내역 + 진행 중인 다른 캠페인
- 진행한 캠페인이 없어요 + 진행 중인 다른 캠페인이 없어요
diff --git a/app/routes/campaign-detail/campaign-detail.tsx b/app/routes/campaign-detail/campaign-detail.tsx index 9db30e01..758a6bb5 100644 --- a/app/routes/campaign-detail/campaign-detail.tsx +++ b/app/routes/campaign-detail/campaign-detail.tsx @@ -84,6 +84,7 @@ export default function CampaignDetailContent({ } setCampaign(res.data.result); + setIsCampaignLiked(res.data.result.like ?? false); setCampaignError(null); } catch { if (!alive) return; @@ -103,14 +104,14 @@ export default function CampaignDetailContent({ { label: "모집인원", value: `${campaign.quota}명` }, { label: "우대사항", value: campaign.preferredSkills || "-" }, { label: "제품협찬", value: campaign.product || "-" }, - { label: "원고료", value: fmtMoney(campaign.rewardAmount) }, + { label: "원고료", value: `${fmtMoney(campaign.rewardAmount)} (VAT포함)` }, { label: "일정", value: campaign.schedule || "-" }, - { - label: "모집기간", - value: `${formatDateOnly(campaign.recruitStartDate)} ~ ${formatDateOnly( - campaign.recruitEndDate, - )}`, - }, + // { + // label: "모집기간", + // value: `${formatDateOnly(campaign.recruitStartDate)} ~ ${formatDateOnly( + // campaign.recruitEndDate, + // )}`, + // }, ]; }, [campaign]); @@ -254,7 +255,7 @@ export default function CampaignDetailContent({ const campaignImage = campaign.imageUrl ?? heroUrl; return ( -
+
-
+
} @@ -301,7 +302,7 @@ export default function CampaignDetailContent({
-
+
campaign
-
-
상세 설명
-
+
+
상세 설명
+
{detailRows.map((row) => (
-
+
-
+
콘텐츠
-
+
{contentRows.map((row) => (
@@ -366,7 +367,7 @@ export default function CampaignDetailContent({
-
+
@@ -26,7 +29,7 @@ export default function BrandActionBar({ From c1f7609edcb0023a672456a2eab4b07dbd99f59a Mon Sep 17 00:00:00 2001 From: Yoonchulchung Date: Thu, 12 Feb 2026 17:05:08 +0900 Subject: [PATCH 3/8] =?UTF-8?q?fix:=20=EC=BC=90=ED=8E=98=EC=9D=B8=20?= =?UTF-8?q?=EC=83=81=EC=84=B8=20=ED=8E=98=EC=9D=B4=EC=A7=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/OngoingCampaignSection.tsx | 64 ++++++++----------- .../campaign-detail/campaign-detail.tsx | 10 ++- 2 files changed, 35 insertions(+), 39 deletions(-) diff --git a/app/routes/brand-detail/components/OngoingCampaignSection.tsx b/app/routes/brand-detail/components/OngoingCampaignSection.tsx index 7f23ebb6..c2efbd99 100644 --- a/app/routes/brand-detail/components/OngoingCampaignSection.tsx +++ b/app/routes/brand-detail/components/OngoingCampaignSection.tsx @@ -11,50 +11,40 @@ export default function OngoingCampaignSection({ campaigns, onMore }: Props) { const isEmpty = campaigns.length === 0; return ( -
- {isEmpty ? ( -
-
- 진행 중인 다른 캠페인 -
+
+
+
진행 중인 다른 캠페인
+ + {!isEmpty && onMore ? ( + + ) : null} +
-
-
-
-
- 진행 중인 다른 캠페인이 없어요 -
+ {isEmpty ? ( +
+
+
+
+ 진행 중인 다른 캠페인이 없어요
) : ( - <> -
-
진행 중인 캠페인
- - {onMore ? ( - - ) : ( -
- )} +
+
+ {campaigns.map((c) => ( + + ))}
- -
-
- {campaigns.map((c) => ( - - ))} -
-
- +
)}
); diff --git a/app/routes/campaign-detail/campaign-detail.tsx b/app/routes/campaign-detail/campaign-detail.tsx index 758a6bb5..90d1dd7f 100644 --- a/app/routes/campaign-detail/campaign-detail.tsx +++ b/app/routes/campaign-detail/campaign-detail.tsx @@ -130,7 +130,13 @@ export default function CampaignDetailContent({ ]; }, [campaign]); - const ongoing = useMemo(() => brandData.ongoingCampaigns ?? [], [brandData]); + const ongoing = useMemo( + () => + (brandData.ongoingCampaigns ?? []).filter( + (c) => c.campaignId !== campaignId, + ), + [brandData, campaignId], + ); const handleChat = () => { const accessToken = tokenStorage.getAccessToken(); @@ -316,7 +322,7 @@ export default function CampaignDetailContent({
-
+
상세 설명
{detailRows.map((row) => ( From 54848223c0d361381265a48b91fec2d82706167f Mon Sep 17 00:00:00 2001 From: Yoonchulchung Date: Thu, 12 Feb 2026 17:26:46 +0900 Subject: [PATCH 4/8] =?UTF-8?q?fix:=20=EC=BC=90=ED=8E=98=EC=9D=B8=20?= =?UTF-8?q?=EC=83=81=EC=84=B8=20=ED=8E=98=EC=9D=B4=EC=A7=80=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/routes/_main.tsx | 2 +- .../components/OngoingCampaignSection.tsx | 4 +- .../components/toCampaignItem.tsx | 4 +- .../campaign-detail/campaign-detail.tsx | 85 ++++++++----------- 4 files changed, 42 insertions(+), 53 deletions(-) diff --git a/app/routes/_main.tsx b/app/routes/_main.tsx index 8d011e95..480140b4 100644 --- a/app/routes/_main.tsx +++ b/app/routes/_main.tsx @@ -29,7 +29,7 @@ export default function MainLayout() { useEffect(() => { mainRef.current?.scrollTo(0, 0); - }, [location.pathname]); + }, [location.pathname, location.search]); useEffect(() => { const accessToken = tokenStorage.getAccessToken(); diff --git a/app/routes/brand-detail/components/OngoingCampaignSection.tsx b/app/routes/brand-detail/components/OngoingCampaignSection.tsx index a66ec3ac..e5bcaf7d 100644 --- a/app/routes/brand-detail/components/OngoingCampaignSection.tsx +++ b/app/routes/brand-detail/components/OngoingCampaignSection.tsx @@ -4,6 +4,7 @@ import type { BrandOngoingCampaign } from "../types"; type Props = { campaigns: BrandOngoingCampaign[]; + brandLogoUrl?: string; onMore?: () => void; onCampaignClick?: (c: BrandOngoingCampaign) => void; onLikeToggle?: (id: string) => void; @@ -11,6 +12,7 @@ type Props = { export default function OngoingCampaignSection({ campaigns, + brandLogoUrl, onMore, onCampaignClick, onLikeToggle, @@ -62,7 +64,7 @@ export default function OngoingCampaignSection({ className="text-left" > onCampaignClick?.(c)} onLikeToggle={onLikeToggle} /> diff --git a/app/routes/brand-detail/components/toCampaignItem.tsx b/app/routes/brand-detail/components/toCampaignItem.tsx index 1b7f7472..f741f541 100644 --- a/app/routes/brand-detail/components/toCampaignItem.tsx +++ b/app/routes/brand-detail/components/toCampaignItem.tsx @@ -1,14 +1,14 @@ import type { CampaignItem } from "../../home/types"; import type { BrandOngoingCampaign } from "../types"; -export function toCampaignItem(campaign: BrandOngoingCampaign): CampaignItem { +export function toCampaignItem(campaign: BrandOngoingCampaign, brandLogoUrl?: string): CampaignItem { const ddayLabel = campaign.dday === 0 ? "D-DAY" : `D-${campaign.dday}`; const result: CampaignItem = { id: String(campaign.campaignId), brandName: campaign.brandName || "", - logoUrl: campaign.imageUrl || undefined, + logoUrl: brandLogoUrl || campaign.imageUrl || undefined, progressText: String(campaign.recruitQuota || 0), ddayLabel, descText: campaign.title || "", diff --git a/app/routes/campaign-detail/campaign-detail.tsx b/app/routes/campaign-detail/campaign-detail.tsx index 8479774b..06f3fe39 100644 --- a/app/routes/campaign-detail/campaign-detail.tsx +++ b/app/routes/campaign-detail/campaign-detail.tsx @@ -30,11 +30,6 @@ type OngoingCampaign = NonNullable[number]; const fmtMoney = (n?: number) => Number.isFinite(n) ? `${Number(n).toLocaleString()}원` : "-"; -const formatDateOnly = (iso?: string) => { - if (!iso) return "-"; - return iso.split("T")[0]; -}; - const joinTagNames = (items?: { name: string }[]) => (items ?? []).map((x) => x.name).filter(Boolean); @@ -90,6 +85,10 @@ export default function CampaignDetailContent({ const [searchParams] = useSearchParams(); const setProposalData = useCampaignProposalStore((s) => s.setProposalData); + useEffect(() => { + window.scrollTo(0, 0); + }, [campaignId]); + const heroUrl = brandData.brandImages?.[0] ?? brandData.heroImageUrl; const [isCampaignLiked, setIsCampaignLiked] = useState(false); @@ -175,21 +174,13 @@ export default function CampaignDetailContent({ { label: "설명", value: campaign.description || "-" }, { label: "개수 및 길이", value: campaign.videoSpec || "-" }, { label: "콘텐츠 형식", chips: joinTagNames(tags?.formats) }, - { label: "카테고리", chips: joinTagNames(tags?.categories) }, - { label: "톤", chips: joinTagNames(tags?.tones) }, - { label: "참여도", chips: joinTagNames(tags?.involvements) }, - { label: "사용 범위", chips: joinTagNames(tags?.usageRanges) }, + { label: "콘텐츠 종류", chips: joinTagNames(tags?.categories) }, + { label: "컨톤체 톤", chips: joinTagNames(tags?.tones) }, + { label: "콘텐츠 활용범위", chips: joinTagNames(tags?.usageRanges) }, + { label: "콘텐츠 관려도", chips: joinTagNames(tags?.involvements) }, ]; }, [campaign]); - const ongoing = useMemo( - () => - (brandData.ongoingCampaigns ?? []).filter( - (c) => c.campaignId !== campaignId, - ), - [brandData, campaignId], - ); - const handleChat = () => { const accessToken = tokenStorage.getAccessToken(); if (!accessToken) { @@ -483,35 +474,14 @@ export default function CampaignDetailContent({
콘텐츠
-
+
{contentRows.map((row) => ( -
-
- {row.label} -
- -
- {"value" in row && row.value ? ( -
- {row.value} -
- ) : ( -
- {(row.chips ?? []).map((c) => ( - - {c} - - ))} - {(!row.chips || row.chips.length === 0) && ( - - - )} -
- )} -
-
+ ))}
@@ -536,6 +506,7 @@ export default function CampaignDetailContent({ {}} onCampaignClick={goOngoingCampaignDetail} onLikeToggle={handleOngoingLikeToggle} @@ -546,12 +517,28 @@ export default function CampaignDetailContent({ ); } -function DetailRow({ label, value }: { label: string; value: string }) { +function DetailRow({ label, value, chips }: { label: string; value?: string; chips?: string[] }) { return (
-
{label}
-
- {value} +
{label}
+
+ {value ? ( +
+ {value} +
+ ) : ( +
+ {(chips ?? []).map((c) => ( + + {c} + + ))} + {(!chips || chips.length === 0) && -} +
+ )}
); From f44ace5f4874badc260f8719072609cc6b7f80b9 Mon Sep 17 00:00:00 2001 From: Yoonchulchung Date: Thu, 12 Feb 2026 17:29:41 +0900 Subject: [PATCH 5/8] =?UTF-8?q?fix:=20=EC=A2=8B=EC=95=84=EC=9A=94=20?= =?UTF-8?q?=EB=B2=84=ED=8A=BC=20=EB=B0=98=EC=98=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/routes/campaign-detail/campaign-detail.tsx | 9 --------- 1 file changed, 9 deletions(-) diff --git a/app/routes/campaign-detail/campaign-detail.tsx b/app/routes/campaign-detail/campaign-detail.tsx index 06f3fe39..cb0bbce0 100644 --- a/app/routes/campaign-detail/campaign-detail.tsx +++ b/app/routes/campaign-detail/campaign-detail.tsx @@ -128,15 +128,6 @@ export default function CampaignDetailContent({ setCampaign(res.data.result); setIsCampaignLiked(res.data.result.like ?? false); setCampaignError(null); - - const liked = (() => { - const r: unknown = res.data.result; - if (!r || typeof r !== "object") return false; - const rec = r as Record; - return rec["isLiked"] === true; - })(); - - setIsCampaignLiked(liked); } catch { if (!alive) return; setCampaignError("캠페인 정보를 불러오지 못했어요."); From 4c173b89dd277bef5a417cfcd907f9f4e2346242 Mon Sep 17 00:00:00 2001 From: Yoonchulchung Date: Thu, 12 Feb 2026 17:32:08 +0900 Subject: [PATCH 6/8] =?UTF-8?q?fix:=20=EC=B1=84=ED=8C=85,=20=EC=A0=9C?= =?UTF-8?q?=EC=95=88=ED=95=98=EA=B8=B0=20=EB=B2=84=ED=8A=BC=20=EC=82=AC?= =?UTF-8?q?=EC=9D=B4=EC=A6=88=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/routes/campaign-detail/campaign-detail.tsx | 2 +- app/routes/campaign-detail/components/CampaignActionBar.tsx | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/app/routes/campaign-detail/campaign-detail.tsx b/app/routes/campaign-detail/campaign-detail.tsx index cb0bbce0..d8aa612c 100644 --- a/app/routes/campaign-detail/campaign-detail.tsx +++ b/app/routes/campaign-detail/campaign-detail.tsx @@ -430,7 +430,7 @@ export default function CampaignDetailContent({ onToggleHeart={handleToggleHeart} /> -
+
diff --git a/app/routes/campaign-detail/components/CampaignActionBar.tsx b/app/routes/campaign-detail/components/CampaignActionBar.tsx index 1c636aff..cddbaf13 100644 --- a/app/routes/campaign-detail/components/CampaignActionBar.tsx +++ b/app/routes/campaign-detail/components/CampaignActionBar.tsx @@ -15,13 +15,11 @@ export default function CampaignActionBar({ }: Props) { return ( - // 피그마는 title3인데, 렌더링하면 작아 보여서 title2로 했습니다. -
@@ -29,7 +27,7 @@ export default function CampaignActionBar({ From ac178f7b09741912458a136dd67d7d12a447b2e2 Mon Sep 17 00:00:00 2001 From: Yoonchulchung Date: Thu, 12 Feb 2026 17:33:05 +0900 Subject: [PATCH 7/8] =?UTF-8?q?fix:=20=EC=B1=84=ED=8C=85=ED=95=98=EA=B8=B0?= =?UTF-8?q?,=20=EC=A0=9C=EC=95=88=ED=95=98=EA=B8=B0=20=EC=9C=84=EC=B9=98?= =?UTF-8?q?=20=EC=A1=B0=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/routes/campaign-detail/components/CampaignActionBar.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/routes/campaign-detail/components/CampaignActionBar.tsx b/app/routes/campaign-detail/components/CampaignActionBar.tsx index cddbaf13..3371a32b 100644 --- a/app/routes/campaign-detail/components/CampaignActionBar.tsx +++ b/app/routes/campaign-detail/components/CampaignActionBar.tsx @@ -15,7 +15,7 @@ export default function CampaignActionBar({ }: Props) { return ( -
+