From 38d016a910593b3c5dbaba57fe204d2adf8f75cc Mon Sep 17 00:00:00 2001 From: he2e2 Date: Mon, 9 Dec 2024 23:43:59 +0900 Subject: [PATCH] fix: userData -> myData --- src/widgets/UserContents/UserContents.tsx | 25 +++---------------- .../WriteArchive/WriteStep.module.scss | 4 +-- 2 files changed, 6 insertions(+), 23 deletions(-) diff --git a/src/widgets/UserContents/UserContents.tsx b/src/widgets/UserContents/UserContents.tsx index 456f5a5..0756be6 100644 --- a/src/widgets/UserContents/UserContents.tsx +++ b/src/widgets/UserContents/UserContents.tsx @@ -5,7 +5,7 @@ import { ContentsTab } from './ContentsTab'; import { useUserTab } from './hook/useUserTab'; import type { ColorCountDTO } from '@/features'; -import { ColorMap, useUserArchiveColors, useUserArchiveList } from '@/features'; +import { ColorMap, useMyArchiveList, useUserArchiveColors } from '@/features'; //import type { GatheringItemDto } from '@/features/gathering/model/gathering.dto'; import { Loader } from '@/shared/ui'; import { PieChart } from '@/shared/ui/Chart/PieChart'; @@ -15,10 +15,10 @@ interface ArchiveContentProps { } const ArchiveContent = ({ userId }: ArchiveContentProps) => { - const { items: archives, isFetchingNextPage, isPending, ref } = useUserArchiveList(userId); + const { data: archives, isPending } = useMyArchiveList(); const { data: colorData, isPending: isColorPending } = useUserArchiveColors(userId); - if (!colorData?.data || isColorPending || isPending) { + if (!colorData?.data || isColorPending || isPending || !archives?.data) { return ; } @@ -38,28 +38,11 @@ const ArchiveContent = ({ userId }: ArchiveContentProps) => { - -
{isFetchingNextPage && }
+ ); }; -// const dummyGatherings: GatheringItemDto<'프로젝트'>[] = Array.from({ length: 9 }, (_, i) => ({ -// gatheringId: i.toString(), -// title: `Sample Gathering ${i + 1}`, -// userId: `user_${i}`, -// username: '홍길동', -// sort: '프로젝트', -// subject: '개발', // ProjectSubjectType만 허용 -// tags: ['React', 'TypeScript', 'Next.js'], -// deadLine: '2024-11-28', -// position: ['개발자', '디자이너'], // 여러 포지션 가능 -// contactType: '온라인', -// period: '3개월', -// personnel: '3', -// })); -// const GatheringContent = () => ; - const ContentComponents = { gathering: ArchiveContent, archive: ArchiveContent, diff --git a/src/widgets/WriteArchive/WriteStep.module.scss b/src/widgets/WriteArchive/WriteStep.module.scss index 0acbe7f..e9c97a7 100644 --- a/src/widgets/WriteArchive/WriteStep.module.scss +++ b/src/widgets/WriteArchive/WriteStep.module.scss @@ -112,8 +112,8 @@ display: flex; align-items: center; justify-content: center; - width: 1.3rem; - height: 1.3rem; + width: 1rem; + height: 1rem; background-color: $primary-color; border-radius: 50%;