-
Notifications
You must be signed in to change notification settings - Fork 3
Feat/156/review list #158
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weโll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feat/156/review list #158
Conversation
Walkthrough์ด ๋ณ๊ฒฝ ์ฌํญ์ Changes
Possibly related PRs
Suggested labels
Suggested reviewers
Warning Rate limit exceeded@HaeJungg has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 16 minutes and 57 seconds before requesting another review. โ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. ๐ฆ How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. Warning There were issues while running some tools. Please review the errors and either fix the toolโs configuration or disable the tool if itโs a critical failure. ๐ง eslint
src/app/(crew)/my-page/my-review/page.tsxOops! Something went wrong! :( ESLint: 8.57.1 ESLint couldn't determine the plugin "react-hooks" uniquely.
Please remove the "plugins" setting from either config or remove either plugin installation. If you still can't figure out the problem, please stop by https://eslint.org/chat/help to chat with the team. Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? ๐ชง TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
|
๐storybook: https://67206cc6ff9d7a05a3528ff8-qsgzeebihr.chromatic.com/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 12
๐งน Outside diff range and nitpick comments (16)
src/_queries/review/my-review-queries.ts (1)
4-12: ํ์ ์์ ์ฑ ๊ฐ์ ์ ์ํ ์ ์๋ฐํ ํ์ ์ ๋ช ์์ ์ผ๋ก ์ง์ ํ๋ฉด ํ์ ์์ ์ฑ์ด ํฅ์๋ ๊ฒ ๊ฐ์ต๋๋ค.
-export function useGetMyReviewsQuery({ size }: { size: number }) { +export function useGetMyReviewsQuery({ size }: { size: number }): { + queryKey: ['myReviews']; + queryFn: ({ pageParam }: { pageParam?: number }) => Promise<MyReviewResponse>; + getNextPageParam: (lastPage: MyReviewResponse, allPages: MyReviewResponse[]) => number | undefined; +} {src/components/common/review-list/review-card-list.stories.tsx (1)
19-22: ๋ฆฌํฉํ ๋ง ์ ์: refetch ํจ์ ๊ตฌํ ๊ฐ์๋น ํจ์๋ฅผ ์ ๋ฌํ๋ ๋์ ์ค์ ๋์์ ๋ชจ์ฌํ๋ mock ํจ์๋ฅผ ์ฌ์ฉํ๋ ๊ฒ์ด ์ข์ต๋๋ค. ๋ํ Story ํ์ ์ ์๋ฅผ ์ธ๋ผ์ธ์ผ๋ก ์์ฑํ๋ ๊ฒ๋ณด๋ค ๋ณ๋์ ํ์ ํ์ผ๋ก ๋ถ๋ฆฌํ๋ ๊ฒ์ ๊ณ ๋ คํด๋ณด์ธ์.
๋ค์๊ณผ ๊ฐ์ด ๊ฐ์ ํด๋ณด์ธ์:
-type Story = StoryObj<typeof ReviewCardList>; +import { ReviewCardListStoryType } from './review-card-list.stories.types'; +type Story = ReviewCardListStoryType; export const MyReviewCardList: Story = { - render: () => <ReviewCardList data={MyReviewData} refetch={() => {}} />, + render: () => ( + <ReviewCardList + data={MyReviewData} + refetch={() => { + console.log('Mocked refetch called'); + return Promise.resolve(); + }} + /> + ), };src/types/review.d.ts (2)
6-8: API ์๋ต ํ์ ์ ์๋ฌ ์ฒ๋ฆฌ๋ฅผ ์ํ ํ๋ ์ถ๊ฐ๋ฅผ ๊ณ ๋ คํด๋ณด์ธ์.ํ์ฌ ๊ตฌ์กฐ๋ ์ฑ๊ณต ์ผ์ด์ค๋ง ์ฒ๋ฆฌํ๊ณ ์์ต๋๋ค. API ์ค๋ฅ ์ฒ๋ฆฌ๋ฅผ ์ํด ๋ค์๊ณผ ๊ฐ์ ํ๋๋ค์ ์ถ๊ฐ๋ฅผ ์ ์๋๋ฆฝ๋๋ค:
export interface ApiResponse<T> { data: T; + error?: { + code: string; + message: string; + }; + status: 'success' | 'error'; }
1-8: ์๋ต ๊ตฌ์กฐ์ ์ผ๊ด์ฑ ๊ฐ์ ์ด ํ์ํฉ๋๋ค.
MyReviewResponse์CrewReviewInformResponse๊ฐ ์๋ก ๋ค๋ฅธ ๊ตฌ์กฐ๋ฅผ ๊ฐ์ง๊ณ ์์ด ์ผ๊ด์ฑ์ด ๋จ์ด์ง๋๋ค.ApiResponse๋ฅผ ํ์ฉํ์ฌ ๋ค์๊ณผ ๊ฐ์ด ํต์ผ๋ ๊ตฌ์กฐ๋ก ๊ฐ์ ํ๋ ๊ฒ์ ์ถ์ฒ๋๋ฆฝ๋๋ค:export interface PaginatedResponse<T> { content: T[]; hasNext: boolean; totalItems: number; } // MyReviewResponse ์ฌ์ฉ ์์ type MyReviewResponse = ApiResponse<PaginatedResponse<MyReview>>; // CrewReviewResponse ์ฌ์ฉ ์์ type CrewReviewResponse = ApiResponse<PaginatedResponse<CrewReview>>;src/app/(crew)/my-page/my-review/page.tsx (1)
10-14: ํ์ด์ง ํฌ๊ธฐ ์์๋ฅผ ๋ณ๋ ํ์ผ๋ก ๋ถ๋ฆฌํ๋ ๊ฒ์ด ์ข์ต๋๋ค.ํ์ด์ง ํฌ๊ธฐ(size)๋ฅผ ์์ ํ์ผ๋ก ๋ถ๋ฆฌํ๋ฉด ๋ค๋ฅธ ์ปดํฌ๋ํธ์์๋ ์ฌ์ฌ์ฉํ ์ ์์ผ๋ฉฐ, ์ผ๊ด์ฑ ์๋ ๊ฐ ๊ด๋ฆฌ๊ฐ ๊ฐ๋ฅํฉ๋๋ค.
+// src/constants/pagination.ts +export const REVIEW_PAGE_SIZE = 6; - const size = 6; + const size = REVIEW_PAGE_SIZE;src/components/common/review-list/review-card-list.tsx (3)
6-11: ์ธํฐํ์ด์ค์ JSDoc ๋ฌธ์๋ฅผ ์ถ๊ฐํ๋ ๊ฒ์ด ์ข์ต๋๋ค์ธํฐํ์ด์ค์ ๋ชฉ์ ๊ณผ ๊ฐ ํ๋กํผํฐ์ ์ญํ ์ ๋ช ํํ ํ๊ธฐ ์ํด ๋ฌธ์ํ๋ฅผ ์ถ๊ฐํ๋ฉด ์ข์ ๊ฒ ๊ฐ์ต๋๋ค.
๋ค์๊ณผ ๊ฐ์ด JSDoc์ ์ถ๊ฐํด๋ณด์ธ์:
+/** + * ๋ฆฌ๋ทฐ ์นด๋ ๋ฆฌ์คํธ ์ปดํฌ๋ํธ์ ํ๋กํผํฐ + * @property {InfiniteData<{content: MyReview[]; hasNext: boolean;}>} data - ํ์ด์ง๋ค์ด์ ๋ ๋ฆฌ๋ทฐ ๋ฐ์ดํฐ + * @property {() => void} refetch - ๋ฐ์ดํฐ๋ฅผ ๋ค์ ๋ถ๋ฌ์ค๋ ํจ์ + */ interface ReviewCardListProps { data: InfiniteData<{ content: MyReview[]; hasNext: boolean; }>; refetch: () => void; }
15-15: ๋ฐ์ดํฐ ๋ณํ ๋ก์ง์ ํ์ ์์ ์ฑ ๊ฐ์ ์ด ํ์ํฉ๋๋คํ์ฌ ๊ตฌํ์ ์๋ํ์ง๋ง, ํ์ ์์ ์ฑ์ ๋์ด๊ธฐ ์ํด ํ์ ๊ฐ๋๋ฅผ ์ถ๊ฐํ๋ ๊ฒ์ด ์ข์ต๋๋ค.
๋ค์๊ณผ ๊ฐ์ด ๊ฐ์ ํด๋ณด์ธ์:
-const reviewDataList = data.pages.flatMap((page) => page.content || []); +const reviewDataList = data.pages.flatMap((page) => + Array.isArray(page.content) ? page.content : [] +);
14-14: ์ปดํฌ๋ํธ์ ์๋ฌ ์ฒ๋ฆฌ์ ๋ก๋ฉ ์ํ ์ฒ๋ฆฌ๊ฐ ํ์ํฉ๋๋คํ์ฌ ๊ตฌํ์๋ ์๋ฌ ์ํ๋ ๋ก๋ฉ ์ํ์ ๋ํ ์ฒ๋ฆฌ๊ฐ ์์ต๋๋ค. ์ฌ์ฉ์ ๊ฒฝํ ํฅ์์ ์ํด ์ด๋ฌํ ์ํ๋ค์ ์ฒ๋ฆฌํ๋ ๊ฒ์ด ์ข์ต๋๋ค.
๋ค์๊ณผ ๊ฐ์ ๊ฐ์ ์ ์ ์ํฉ๋๋ค:
- ์๋ฌ ๋ฐ์ด๋๋ฆฌ ์ถ๊ฐ
- ๋ก๋ฉ ์ํ ์ฒ๋ฆฌ
- ๋ฐ์ดํฐ ๊ฒ์ฆ ๋ก์ง ์ถ๊ฐ
์์ ๊ตฌํ:
export default function ReviewCardList({ data, refetch }: ReviewCardListProps) { if (!data) { return <div role="alert">๋ฐ์ดํฐ๋ฅผ ๋ถ๋ฌ์ค๋ ์ค ์ค๋ฅ๊ฐ ๋ฐ์ํ์ต๋๋ค.</div>; } try { const reviewDataList = data.pages.flatMap((page) => page.content || []); // ... ๋๋จธ์ง ๊ตฌํ } catch (error) { console.error('๋ฆฌ๋ทฐ ๋ฐ์ดํฐ ์ฒ๋ฆฌ ์ค ์ค๋ฅ ๋ฐ์:', error); return <div role="alert">๋ฆฌ๋ทฐ๋ฅผ ํ์ํ๋ ์ค ๋ฌธ์ ๊ฐ ๋ฐ์ํ์ต๋๋ค.</div>; } }src/utils/format-date.ts (1)
43-55: ๊ตฌํ์ด ๊น๋ํ๊ณ ์ผ๊ด์ฑ์ด ์์ต๋๋ค!์ฝ๋๊ฐ ์ ๊ตฌ์กฐํ๋์ด ์๊ณ ๊ธฐ์กด ํจ์๋ค๊ณผ ์ผ๊ด๋ ํจํด์ ๋ฐ๋ฅด๊ณ ์์ต๋๋ค. ๋ค๋ง, ๋ฐํ ํ์์ ๋ํ JSDoc ์ฃผ์์ ์ถ๊ฐํ๋ฉด ๋ ์ข์ ๊ฒ ๊ฐ์ต๋๋ค.
+/** + * ๋ ์ง ๋ฌธ์์ด์ "MM์ DD์ผใปHH:MM" ํ์์ผ๋ก ๋ณํํฉ๋๋ค. + * @param dateString - ISO 8601 ํ์์ ๋ ์ง ๋ฌธ์์ด + * @returns "MM์ DD์ผใปHH:MM" ํ์์ ๋ฌธ์์ด + * @example + * formatCompactDateTime24H("2024-01-01T15:30:00") + * // ๋ฐํ๊ฐ: "01์ 01์ผใป15:30" + */ export function formatCompactDateTime24H(dateString: string): string {src/app/(crew)/my-page/_components/profile-card/container.tsx (1)
53-53: ํ์ผ ํฌ๊ธฐ ์ ํ์ ์์๋ก ๋ถ๋ฆฌํ๋ ๊ฒ์ด ์ข๊ฒ ์ต๋๋ค.5MB ์ ํ์ ๋งค์ง ๋๋ฒ๋ก ํ๋์ฝ๋ฉํ๋ ๋์ ์๋ฏธ ์๋ ์ด๋ฆ์ ์์๋ก ๋ถ๋ฆฌํ๋ฉด ์ ์ง๋ณด์์ฑ์ด ํฅ์๋ ๊ฒ ๊ฐ์ต๋๋ค.
๋ค์๊ณผ ๊ฐ์ด ๋ณ๊ฒฝํ๋ ๊ฒ์ ์ ์๋๋ฆฝ๋๋ค:
+const MAX_PROFILE_IMAGE_SIZE = 5 * 1024 * 1024; // 5MB + export default function ProfileCard() { // ... input.onchange = async (event) => { const file = (event.target as HTMLInputElement)?.files?.[0]; if (file) { - if (file.size > 5 * 1024 * 1024) { + if (file.size > MAX_PROFILE_IMAGE_SIZE) { toast.error('5MB ์ดํ์ ํ์ผ๋ง ์ ๋ก๋ ๊ฐ๋ฅํฉ๋๋ค.'); return; }src/components/my-page/reviewable-gatherings/reviewable-gathering-card.tsx (1)
61-61: ๋ ์ง ํ์์ ๋ํ ์ ๊ทผ์ฑ ๊ฐ์ ์ ์์คํฌ๋ฆฐ ๋ฆฌ๋ ์ฌ์ฉ์๋ฅผ ์ํด ๋ ์ง ์ ๋ณด์ ์ ์ ํ ARIA ๋ ์ด๋ธ์ ์ถ๊ฐํ๋ ๊ฒ์ด ์ข์ต๋๋ค.
- <div className="text-sm font-medium text-gray-700">{formatDate}</div> + <div className="text-sm font-medium text-gray-700" aria-label={`๋ชจ์ ์ผ์: ${formatDate}`}>{formatDate}</div>src/mock/review-data.ts (2)
216-295: ๋ ์ง ํ์ ํต์ผ ๋ฐ ํ ์คํธ ๋ฐ์ดํฐ ํ์ง ๊ฐ์ ํ์๋ค์๊ณผ ๊ฐ์ ๊ฐ์ ์ด ํ์ํฉ๋๋ค:
createdAt๋ ์ง ํ์์ด ์ผ๊ด๋์ง ์์ต๋๋ค:
- ๋๋ถ๋ถ:
2024-10-31T10:09:12.306+09:00- 278์ค:
2024-10-31T00:56ํ ์คํธ ๋ฐ์ดํฐ์ ํ์ง:
- "ํฌ๋ฃจํฌ๋ฃจํฌ๋ฃจ..." ๊ฐ์ ๋ฐ๋ณต์ ์ธ ์ด๋ฆ
- "์ด๋๋"๊ณผ ๊ฐ์ ์์ ์์น ๋ฐ์ดํฐ
๋ ํ์ค์ ์ธ ํ ์คํธ ๋ฐ์ดํฐ๋ก ๊ฐ์ ํ๋ ๊ฒ์ ์ถ์ฒ๋๋ฆฝ๋๋ค:
- crewName: 'ํฌ๋ฃจํฌ๋ฃจํฌ๋ฃจํฌ๋ฃจํฌ๋ฃจํฌ๋ฃจ', - gatheringName: '๋ชจ์๋ชจ์๋ชจ์์ฝ์์ฝ์์ฝ์', - gatheringLocation: '์ด๋๋', + crewName: '์์ธ ๋ ์ ๋ชจ์', + gatheringName: '11์ ๋ ์ ํ ๋ก ํ', + gatheringLocation: '๊ฐ๋จ๊ตฌ ์ญ์ผ๋',
242-267: ํ์ด์ง๋ค์ด์ ๊ตฌ์กฐ์ ๋ํ ๋ฌธ์ํ ํ์ํ์ด์ง๋ค์ด์ ๊ตฌํ์ ๋ํ ์ค๋ช ์ด ๋ถ์กฑํฉ๋๋ค:
hasNextํ๋๊ทธ์ ์ฌ์ฉ ๋ชฉ์ - ๋น
pageParams๋ฐฐ์ด์ ์ฉ๋- ํ์ด์ง ํฌ๊ธฐ ์ ํ ์ฌ๋ถ
ํ์ผ ์๋จ์ ๋ค์๊ณผ ๊ฐ์ ์ฃผ์ ์ถ๊ฐ๋ฅผ ์ ์๋๋ฆฝ๋๋ค:
/** * ํ์ด์ง๋ค์ด์ ๊ตฌ์กฐ ์ค๋ช : * - content: ํ์ด์ง๋น ๋ฆฌ๋ทฐ ๋ชฉ๋ก * - hasNext: ๋ค์ ํ์ด์ง ์กด์ฌ ์ฌ๋ถ * - pageParams: ๋ฌดํ ์คํฌ๋กค ๊ตฌํ์ ์ํ ํ์ด์ง ํ๋ผ๋ฏธํฐ * * @example * // ํ์ด์ง๋ค์ด์ ์ฌ์ฉ ์์ * const { pages, pageParams } = MyReviewData; * const hasNextPage = pages[currentPage].hasNext; */src/components/common/review-list/review-card.tsx (3)
55-63: ์๋ฌ ์ฒ๋ฆฌ ๋ก๊น ์ถ๊ฐ ์ ์
handleDeleteํจ์์์ ์๋ฌ ๋ฐ์ ์ ํ ์คํธ ๋ฉ์์ง ์ธ์๋ ์๋ฌ๋ฅผ ์ฝ์์ ๋ก๊ทธ๋ก ๋จ๊ฒจ ๋๋ฒ๊น ์ด ์ฉ์ดํ๋๋ก ํ๋ฉด ์ข๊ฒ ์ต๋๋ค.๋ค์๊ณผ ๊ฐ์ด ์์ ํ ์ ์์ต๋๋ค:
} catch (error) { toast.error('๋ฆฌ๋ทฐ ์ญ์ ์ ์คํจํ์ต๋๋ค.'); + console.error('๋ฆฌ๋ทฐ ์ญ์ ์ค ์๋ฌ ๋ฐ์:', error); }
81-90:crewIdํ์ธ ํ ๋ฒํผ ๋ ๋๋ง
isMine์ดtrue์ฌ๋crewId๊ฐ ์๋ ๊ฒฝ์ฐ ๋ฒํผ ํด๋ฆญ ์ ์์์น ๋ชปํ ๋์์ด ๋ฐ์ํ ์ ์์ต๋๋ค.crewId๊ฐ ์กด์ฌํ ๋๋ง ๋ฒํผ์ด ๋ ๋๋ง๋๋๋ก ์กฐ๊ฑด์ ์ถ๊ฐํ๋ ๊ฒ์ด ์ข์ต๋๋ค.- {isMine && ( + {isMine && crewId && ( <button ... > {crewName} </button> )}
94-94: ๋์ ํด๋์ค ์ด๋ฆ ์์ฑ ๋ฐฉ์ ๊ฐ์
className์์ฑ์์ ์ผํญ ์ฐ์ฐ์๋ฅผ ์ฌ์ฉํ์ฌ ๊ฐ๋ ์ฑ์ด ๋จ์ด์ง ์ ์์ต๋๋ค.clsx๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ํ์ฉํ์ฌ ์กฐ๊ฑด๋ถ ํด๋์ค ์ด๋ฆ์ ๊ด๋ฆฌํ๋ฉด ์ฝ๋์ ๊ฐ๋ ์ฑ๊ณผ ์ ์ง๋ณด์์ฑ์ด ํฅ์๋ฉ๋๋ค.์ฐ์
clsx๋ฅผ ์ํฌํธํด ์ฃผ์ธ์:+ import clsx from 'clsx';๊ทธ๋ฐ ๋ค์
className์ ๋ค์๊ณผ ๊ฐ์ด ์์ ํฉ๋๋ค:- className={`flex h-full items-end gap-[15px] ${!isMine ? 'border-b-[2px] border-b-[#F3F4F6] py-4' : 'rounded-[12px] p-6 shadow-bg'} bg-white lg:gap-[40px]`} + className={clsx( + 'flex h-full items-end gap-[15px] bg-white lg:gap-[40px]', + { + 'border-b-[2px] border-b-[#F3F4F6] py-4': !isMine, + 'rounded-[12px] p-6 shadow-bg': isMine, + } + )}
๐ Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
โ Files ignored due to path filters (1)
package-lock.jsonis excluded by!**/package-lock.json
๐ Files selected for processing (17)
src/_apis/review/my-review-apis.ts(1 hunks)src/_queries/review/my-review-queries.ts(1 hunks)src/app/(crew)/crew/detail/[id]/_components/crew-review-list.tsx(2 hunks)src/app/(crew)/my-page/_components/profile-card/container.tsx(1 hunks)src/app/(crew)/my-page/_components/review-tabs.tsx(0 hunks)src/app/(crew)/my-page/layout.tsx(1 hunks)src/app/(crew)/my-page/my-review/page.tsx(1 hunks)src/app/(crew)/my-page/page.tsx(1 hunks)src/app/api/mock-api/review.ts(0 hunks)src/components/common/review-list/review-card-list.stories.tsx(1 hunks)src/components/common/review-list/review-card-list.tsx(1 hunks)src/components/common/review-list/review-card.tsx(4 hunks)src/components/my-page/reviewable-gatherings/reviewable-gathering-card.tsx(3 hunks)src/mock/review-data.ts(1 hunks)src/types/review.d.ts(1 hunks)src/utils/format-date.ts(1 hunks)tailwind.config.ts(0 hunks)
๐ค Files with no reviewable changes (3)
- src/app/(crew)/my-page/_components/review-tabs.tsx
- src/app/api/mock-api/review.ts
- tailwind.config.ts
โ Files skipped from review due to trivial changes (1)
- src/app/(crew)/crew/detail/[id]/_components/crew-review-list.tsx
๐ Additional comments (14)
src/_queries/review/my-review-queries.ts (2)
1-12: ๋ฌดํ ์คํฌ๋กค ๊ตฌํ์ด ์ ๋์ด์์ต๋๋ค!
React Query์ ํ์ค ํจํด์ ์ ๋ฐ๋ฅด๊ณ ์์ผ๋ฉฐ, ํ์ด์ง๋ค์ด์ ๋ก์ง์ด ๊น๋ํ๊ฒ ๊ตฌํ๋์ด ์์ต๋๋ค.
8-10: ํ์ด์ง๋ค์ด์
๋ก์ง ๊ฒ์ฆ ํ์
ํ์ฌ ๊ตฌํ๋ getNextPageParam ๋ก์ง์ด ๋ฐฑ์๋ API์ ํ์ด์ง๋ค์ด์
๊ตฌํ๊ณผ ์ผ์นํ๋์ง ํ์ธ์ด ํ์ํฉ๋๋ค.
โ Verification successful
ํ์ด์ง๋ค์ด์ ๋ก์ง์ด ์ฌ๋ฐ๋ฅด๊ฒ ๊ตฌํ๋์์ต๋๋ค
๊ฒ์ฆ ๊ฒฐ๊ณผ ํ์ฌ ๊ตฌํ๋ getNextPageParam ๋ก์ง์ด ๋ฐฑ์๋ API์ ํ์ด์ง๋ค์ด์
๊ตฌํ๊ณผ ์ผ์นํฉ๋๋ค:
MyReviewResponseํ์ ์hasNextํ๋๋ฅผ ํตํด ๋ค์ ํ์ด์ง ์กด์ฌ ์ฌ๋ถ๋ฅผ ํ์- API ํธ์ถ ์
page์sizeํ๋ผ๋ฏธํฐ๋ฅผ ์ฌ์ฉํ์ฌ ํ์ด์ง๋ค์ด์ ์ฒ๋ฆฌ getNextPageParam์์hasNext๊ฐ true์ผ ๊ฒฝ์ฐ ๋ค์ ํ์ด์ง ๋ฒํธ๋กallPages.length๋ฅผ ๋ฐํํ๋ ๊ฒ์ด ์ ์ ํจ
๐ Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# API ์๋ต ๊ตฌ์กฐ ํ์ธ์ ์ํด ๊ด๋ จ ํ์
์ ์ ๊ฒ์
rg -t typescript "interface.*MyReviewResponse" -A 5
Length of output: 88
Script:
#!/bin/bash
# ํ์
์คํฌ๋ฆฝํธ ํ์ผ์์ MyReviewResponse ํ์
์ ์ ๊ฒ์
rg "MyReviewResponse" -A 5 --type-add 'ts:*.ts' -t ts
# ํ์ด์ง๋ค์ด์
๊ด๋ จ ํ์
์ด๋ ์ธํฐํ์ด์ค ๊ฒ์
rg "interface.*Response.*\{" -A 10 --type-add 'ts:*.ts' -t ts
# API ํธ์ถ ๋ถ๋ถ ๊ฒ์
rg "useInfiniteQuery.*MyReview" -B 5 -A 10 --type-add 'ts:*.ts' -t ts
Length of output: 5047
src/app/(crew)/my-page/layout.tsx (2)
4-4: ์ปดํฌ๋ํธ ์๊ทธ๋์ฒ๊ฐ ์ ์ ํ ๊ตฌํ๋์์ต๋๋ค!
children prop์ ํ์ ์ด ๋ช ํํ๊ฒ ์ง์ ๋์ด ์์ผ๋ฉฐ, React์ ๋ ์ด์์ ์ปดํฌ๋ํธ ํจํด์ ์ ๋ฐ๋ฅด๊ณ ์์ต๋๋ค.
6-13: ๋ ์ด์์ ๊ตฌ์กฐ๊ฐ ์ ๊ตฌ์ฑ๋์ด ์์ต๋๋ค!
๋ฐ์ํ ๋์์ธ์ ์ํ ์ ์ ํ ํจ๋ฉ๊ณผ ์ปดํฌ๋ํธ ๊ณ์ธต ๊ตฌ์กฐ๊ฐ ์ ๊ตฌํ๋์ด ์์ต๋๋ค. ProfileCardContainer, ReviewTabs, ๊ทธ๋ฆฌ๊ณ children ์ปดํฌ๋ํธ์ ๋ฐฐ์น๊ฐ ๋ ผ๋ฆฌ์ ์ ๋๋ค.
src/components/common/review-list/review-card-list.stories.tsx (2)
9-9: ๋ ์ด์์ ๋ณ๊ฒฝ์ ์ํฅ ๊ฒํ ํ์
fullscreen ๋ ์ด์์์ผ๋ก ๋ณ๊ฒฝ๋จ์ ๋ฐ๋ผ ๋ค๋ฅธ ์คํ ๋ฆฌ๋ค๊ณผ์ ์ผ๊ด์ฑ์ด ์ ์ง๋๋์ง ํ์ธํด์ฃผ์ธ์.
๋ค์ ์คํฌ๋ฆฝํธ๋ก ๋ค๋ฅธ ์คํ ๋ฆฌ์ ๋ ์ด์์ ์ค์ ์ ํ์ธํ์ธ์:
2-2: Mock ๋ฐ์ดํฐ ์ฌ์ฉ์ด ์ ์ ํ์ง ํ์ธ ํ์
์ค์ API ์๋ต ํ์๊ณผ Mock ๋ฐ์ดํฐ์ ๊ตฌ์กฐ๊ฐ ์ผ์นํ๋์ง ํ์ธํด์ฃผ์ธ์. ํฅํ API ์๋ต ๊ตฌ์กฐ๊ฐ ๋ณ๊ฒฝ๋ ๊ฒฝ์ฐ Mock ๋ฐ์ดํฐ๋ ํจ๊ป ์ ๋ฐ์ดํธ๋์ด์ผ ํฉ๋๋ค.
๋ค์ ์คํฌ๋ฆฝํธ๋ฅผ ์คํํ์ฌ Mock ๋ฐ์ดํฐ ๊ตฌ์กฐ๋ฅผ ํ์ธํ์ธ์:
โ Verification successful
Mock ๋ฐ์ดํฐ ๊ตฌ์กฐ๊ฐ API ์๋ต ํ์ ๊ณผ ์ผ์นํจ์ ํ์ธํ์ต๋๋ค
MyReviewData์ ๊ตฌ์กฐ๊ฐ MyReviewResponse ์ธํฐํ์ด์ค์ ์ ํํ ์ผ์นํ๋ฉฐ, ์ปดํฌ๋ํธ์์ ์ฌ์ฉ๋๋ ReviewCardListProps์ ํ์
์ ์์๋ ํธํ๋ฉ๋๋ค:
MyReviewResponse๋content: MyReview[]์hasNext: boolean์ ํฌํจ- Mock ๋ฐ์ดํฐ๋ ๋์ผํ ๊ตฌ์กฐ๋ก
pages๋ฐฐ์ด ๋ด์content์hasNext๋ฅผ ํฌํจ MyReview์ธํฐํ์ด์ค์ ์ ์๋ ๋ชจ๋ ํ์ ํ๋(crewId, crewName, gatheringName, id, rate, comment ๋ฑ)๊ฐ Mock ๋ฐ์ดํฐ์ ์ฌ๋ฐ๋ฅด๊ฒ ๊ตฌํ๋์ด ์์
๐ Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Description: Mock ๋ฐ์ดํฐ์ ์ค์ API ์๋ต ๊ตฌ์กฐ ๋น๊ต
# Mock ๋ฐ์ดํฐ ๊ตฌ์กฐ ํ์ธ
rg -A 10 "export const MyReviewData" src/mock/review-data.ts
# API ํ์
์ ์ ํ์ธ
rg -A 10 "interface.*Review" "src/**/*.ts*"
Length of output: 412
Script:
#!/bin/bash
# Description: API ํ์
์ ์์ Mock ๋ฐ์ดํฐ ๊ตฌ์กฐ ๋น๊ต๋ฅผ ์ํ ์ถ๊ฐ ๊ฒ์
# API ํ์
์ ์ ๊ฒ์ (๋ฐ์ดํ ์ ๊ฑฐ)
rg -A 10 "interface.*Review" src
# Review ๊ด๋ จ ํ์
์ ์ ๊ฒ์
rg -A 10 "type.*Review" src
# Review ์ปดํฌ๋ํธ์ Props ํ์
ํ์ธ
ast-grep --pattern 'interface $_ {
$$$
}' src/components/common/review-list/review-card-list.tsx
Length of output: 17228
src/types/review.d.ts (1)
1-4: ๊ตฌ์กฐ๊ฐ ๋ช
ํํ๊ณ ์ ์ ์๋์ด ์์ต๋๋ค!
ํ์ด์ง๋ค์ด์
์ ์ํ hasNext ํ๋์ ๋ฆฌ๋ทฐ ๋ฐ์ดํฐ๋ฅผ ์ํ content ๋ฐฐ์ด์ด ์ ๊ตฌ์ฑ๋์ด ์์ต๋๋ค.
src/_apis/review/my-review-apis.ts (2)
1-2: ์ํฌํธ ๊ตฌ๋ฌธ์ด ๊น๋ํ๊ฒ ๊ตฌ์ฑ๋์ด ์์ต๋๋ค!
ํ์ ๊ณผ ์ ํธ๋ฆฌํฐ ํจ์๊ฐ ๋ช ํํ๊ฒ ์ํฌํธ๋์ด ์์ต๋๋ค.
6-6: API ์๋ํฌ์ธํธ ์ฌ์ฉ ํํฉ ํ์ธ์ด ํ์ํฉ๋๋ค.
์๋ก ์ถ๊ฐ๋ API ์๋ํฌ์ธํธ๋ค์ด ์ฝ๋๋ฒ ์ด์ค ์ ์ฒด์์ ์ผ๊ด๋๊ฒ ์ฌ์ฉ๋๋์ง ํ์ธ์ด ํ์ํฉ๋๋ค.
Also applies to: 19-19
โ Verification successful
API ์๋ํฌ์ธํธ๊ฐ ์ผ๊ด๋๊ฒ ์ฌ์ฉ๋๊ณ ์์์ ํ์ธํ์ต๋๋ค.
์ฝ๋๋ฒ ์ด์ค ๋ถ์ ๊ฒฐ๊ณผ:
/api/review/memberReviews์๋ํฌ์ธํธ๋src/_apis/review/my-review-apis.ts์์ ์ ์๋์ดsrc/_queries/review/my-review-queries.ts๋ฅผ ํตํด ์ผ๊ด๋๊ฒ ์ฌ์ฉ๋จ- ๋ฆฌ๋ทฐ ์ญ์ API
/api/review/${reviewId}๋ ๋์ผํ ํ์ผ์์ ์ ์๋์ดsrc/components/common/review-list/review-card.tsx์์ ์ ์ ํ ์ฌ์ฉ๋จ - ๋ชจ๋ ๋ฆฌ๋ทฐ ๊ด๋ จ API ํธ์ถ์ด ์ค์ํ๋ API ํด๋ผ์ด์ธํธ๋ฅผ ํตํด ์ฒ๋ฆฌ๋๊ณ ์์
๐ Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# API ์๋ํฌ์ธํธ ์ฌ์ฉ ํํฉ ํ์ธ
echo "๋ฆฌ๋ทฐ ๋ชฉ๋ก API ์ฌ์ฉ ํ์ธ:"
rg -l "/api/review/memberReviews\?page="
echo "\n๋ฆฌ๋ทฐ ์ญ์ API ์ฌ์ฉ ํ์ธ:"
rg -l "/api/review/\$\{reviewId\}"
Length of output: 203
Script:
#!/bin/bash
# API ์๋ํฌ์ธํธ ํจํด์ ๋ ์ ์ฐํ๊ฒ ๊ฒ์
echo "๋ฆฌ๋ทฐ ๊ด๋ จ API ์๋ํฌ์ธํธ ์ฌ์ฉ ํ์ธ:"
rg -A 2 "/api/review"
echo "\n๋ฆฌ๋ทฐ ๊ด๋ จ URL ์์๋ ์ค์ ํ์ธ:"
rg -A 2 "review.*api|api.*review" --type ts
echo "\nAPI ํด๋ผ์ด์ธํธ ์ค์ ์ด๋ ์ธํฐํ์ด์ค ํ์ธ:"
fd -e ts -e tsx -x grep -l "api.*review|review.*api" {} \;
Length of output: 2438
src/app/(crew)/my-page/my-review/page.tsx (2)
1-8: ์์กด์ฑ ๋ชจ๋์ด ์ ์ ํ๊ฒ ๊ตฌ์ฑ๋์ด ์์ต๋๋ค.
ํ์ํ ๋ชจ๋ ์์กด์ฑ์ด ๋ช ํํ๊ฒ ์ํฌํธ๋์ด ์์ผ๋ฉฐ, ํด๋ผ์ด์ธํธ ์ปดํฌ๋ํธ ์ง์์๊ฐ ์ฌ๋ฐ๋ฅด๊ฒ ์ค์ ๋์ด ์์ต๋๋ค.
16-22: ๋ก๋ฉ ์ํ ์ฒ๋ฆฌ๊ฐ ์ ๊ตฌํ๋์ด ์์ต๋๋ค.
๋ก๋ฉ ์ธ๋์ผ์ดํฐ๊ฐ ํ๋ฉด ์ค์์ ์ ์ ํ๊ฒ ๋ฐฐ์น๋์ด ์์ด ์ฌ์ฉ์ ๊ฒฝํ์ด ์ข์ต๋๋ค.
src/app/(crew)/my-page/_components/profile-card/container.tsx (1)
53-53: ํ ์คํธ ์๋ฆผ์ผ๋ก์ ์ ํ์ด ์ ์ ํฉ๋๋ค!
alert ๋์ toast.error๋ฅผ ์ฌ์ฉํ ๊ฒ์ ์ฌ์ฉ์ ๊ฒฝํ์ ๊ฐ์ ํ๋ ์ข์ ๋ณ๊ฒฝ์ฌํญ์ ๋๋ค.
src/components/my-page/reviewable-gatherings/reviewable-gathering-card.tsx (2)
5-5: ๋ ์ง ํฌ๋งทํ
์ ํธ๋ฆฌํฐ ํจ์ ์ฌ์ฉ ์น์ธ
๊ณตํต ์ ํธ๋ฆฌํฐ ํจ์๋ฅผ ์ฌ์ฉํ์ฌ ๋ ์ง ํฌ๋งทํ ๋ก์ง์ ์ค์ํํ ๊ฒ์ ์ข์ ์ ๊ทผ์ ๋๋ค.
32-32: ๋ ์ง ํฌ๋งท ๊ฒ์ฆ ํ์
์๋ก์ด ํฌ๋งทํ ํจ์๊ฐ ์๊ตฌ์ฌํญ์ ๋ง๋ ํ์์ ์ ๊ณตํ๋์ง ํ์ธ์ด ํ์ํฉ๋๋ค.
โ Verification successful
๋ ์ง ํฌ๋งทํ ๊ตฌํ์ด ์ ์ ํจ์ ํ์ธ
formatCompactDateTime24H ํจ์๋ ์, ์ผ, ์๊ฐ, ๋ถ์ 2์๋ฆฌ ์ซ์๋ก ํฌ๋งทํ
ํ์ฌ ๊ฐ๊ฒฐํ 24์๊ฐ์ ๋ ์ง/์๊ฐ ํ์์ ์ ๊ณตํฉ๋๋ค. ์ด๋ ๋ฆฌ๋ทฐ ๊ฐ๋ฅํ ๋ชจ์ ์นด๋์ ์ ํฉํ ํ์์
๋๋ค.
src/utils/format-date.ts์์ ๊ตฌํ๋ ํจ์๋ ๋ค์ ๊ธฐ๋ฅ์ ์ ๊ณตํฉ๋๋ค:- ์/์ผ์ 2์๋ฆฌ ์ซ์๋ก ํจ๋ฉ ์ฒ๋ฆฌ
- ์๊ฐ/๋ถ์ 24์๊ฐ์ ๋ก 2์๋ฆฌ ์ซ์ ํจ๋ฉ ์ฒ๋ฆฌ
- ISO ๋ฌธ์์ด์ ํ์ฑํ์ฌ ์ผ๊ด๋ ํฌ๋งท ๋ณด์ฅ
๐ Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Description: ๋ ์ง ํฌ๋งทํ
ํจ์์ ๊ตฌํ์ ํ์ธ
# formatCompactDateTime24H ํจ์์ ๊ตฌํ ํ์ธ
ast-grep --pattern 'export function formatCompactDateTime24H($_) {
$$$
}'
Length of output: 77
Script:
#!/bin/bash
# Search for formatCompactDateTime24H function implementation
rg -A 10 "formatCompactDateTime24H"
# Search for any test files related to date formatting
fd -e test.ts -e test.tsx -e spec.ts -e spec.tsx | xargs rg "formatCompactDateTime24H"
# Search for any documentation or type definitions
rg "formatCompactDateTime24H" -g "*.d.ts"
Length of output: 3745
|
|
||
| export default function MyPage() { | ||
| redirect('/my-page/reviewable'); | ||
| return null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
๋๋ฌํ ์ ์๋ ์ฝ๋๋ฅผ ์ ๊ฑฐํ์ธ์.
redirect() ํจ์๋ ๋ด๋ถ์ ์ผ๋ก ์๋ฌ๋ฅผ throwํ๊ธฐ ๋๋ฌธ์ return null ๊ตฌ๋ฌธ์ ์ ๋ ์คํ๋์ง ์์ต๋๋ค. ๋ถํ์ํ ์ฝ๋์ด๋ฏ๋ก ์ ๊ฑฐํ๋ ๊ฒ์ด ์ข์ต๋๋ค.
๋ค์๊ณผ ๊ฐ์ด ์์ ํ์ธ์:
export default function MyPage() {
redirect('/my-page/reviewable');
- return null;
}๐ Committable suggestion
โผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| return null; | |
| export default function MyPage() { | |
| redirect('/my-page/reviewable'); | |
| } |
| queryKey: ['myReviews'], | ||
| queryFn: ({ pageParam = 0 }: { pageParam?: number }) => getMyReviews(pageParam, size), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
์บ์ ํค ๊ตฌ์กฐ ๊ฒํ ํ์
ํ์ฌ ์บ์ ํค๊ฐ ['myReviews']๋ก๋ง ๋์ด์๋๋ฐ, size ํ๋ผ๋ฏธํฐ๋ ์บ์ ํค์ ํฌํจํ๋ ๊ฒ์ด ์ข์ ๊ฒ ๊ฐ์ต๋๋ค. ํ์ด์ง ํฌ๊ธฐ๊ฐ ๋ณ๊ฒฝ๋ ๋ ์บ์๋ฅผ ์ ์ ํ ๋ฌดํจํํ๊ธฐ ์ํจ์
๋๋ค.
- queryKey: ['myReviews'],
+ queryKey: ['myReviews', size],๐ Committable suggestion
โผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| queryKey: ['myReviews'], | |
| queryFn: ({ pageParam = 0 }: { pageParam?: number }) => getMyReviews(pageParam, size), | |
| queryKey: ['myReviews', size], | |
| queryFn: ({ pageParam = 0 }: { pageParam?: number }) => getMyReviews(pageParam, size), |
| </div> | ||
| <ReviewTabs /> | ||
| <div>{children}</div> | ||
| <div /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
๋ถํ์ํ ๋น div ์์๋ฅผ ์ ๊ฑฐํด์ฃผ์ธ์.
๋ง์ง๋ง ์ค์ ๋น div ์์๋ ์๋ฌด๋ฐ ์ญํ ์ ํ์ง ์์ผ๋ฏ๋ก ์ ๊ฑฐํ๋ ๊ฒ์ด ์ข์ต๋๋ค.
๋ค์๊ณผ ๊ฐ์ด ์์ ํด์ฃผ์ธ์:
<div>{children}</div>
- <div />Committable suggestion skipped: line range outside the PR's diff.
| // ๋ฆฌ๋ทฐ ์ญ์ API | ||
| export function deleteReview(reviewId: number): Promise<void> { | ||
| const url = `/api/review/${reviewId}`; | ||
| return fetchApi<void>(url, { | ||
| method: 'DELETE', | ||
| headers: { | ||
| 'Content-Type': 'application/json', | ||
| }, | ||
| }); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
์ ๋ ฅ๊ฐ ๊ฒ์ฆ๊ณผ ์๋ฌ ์ฒ๋ฆฌ๊ฐ ํ์ํฉ๋๋ค.
๋ฆฌ๋ทฐ ์ญ์ API์์ ๋ค์ ์ฌํญ๋ค์ด ๋ณด์๋๋ฉด ์ข๊ฒ ์ต๋๋ค:
- reviewId์ ์ ํจ์ฑ ๊ฒ์ฆ
- ์๋ฌ ์ฒ๋ฆฌ ๋ก์ง ์ถ๊ฐ
๋ค์๊ณผ ๊ฐ์ด ์์ ํ๋ ๊ฒ์ ์ ์๋๋ฆฝ๋๋ค:
export function deleteReview(reviewId: number): Promise<void> {
+ if (!Number.isInteger(reviewId) || reviewId <= 0) {
+ throw new Error('์ ํจํ์ง ์์ ๋ฆฌ๋ทฐ ID์
๋๋ค.');
+ }
const url = `/api/review/${reviewId}`;
return fetchApi<void>(url, {
method: 'DELETE',
headers: {
'Content-Type': 'application/json',
},
- });
+ }).catch((error) => {
+ throw new Error(`๋ฆฌ๋ทฐ ์ญ์ ์คํจ: ${error.message}`);
+ });
}๐ Committable suggestion
โผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| // ๋ฆฌ๋ทฐ ์ญ์ API | |
| export function deleteReview(reviewId: number): Promise<void> { | |
| const url = `/api/review/${reviewId}`; | |
| return fetchApi<void>(url, { | |
| method: 'DELETE', | |
| headers: { | |
| 'Content-Type': 'application/json', | |
| }, | |
| }); | |
| } | |
| // ๋ฆฌ๋ทฐ ์ญ์ API | |
| export function deleteReview(reviewId: number): Promise<void> { | |
| if (!Number.isInteger(reviewId) || reviewId <= 0) { | |
| throw new Error('์ ํจํ์ง ์์ ๋ฆฌ๋ทฐ ID์ ๋๋ค.'); | |
| } | |
| const url = `/api/review/${reviewId}`; | |
| return fetchApi<void>(url, { | |
| method: 'DELETE', | |
| headers: { | |
| 'Content-Type': 'application/json', | |
| }, | |
| }).catch((error) => { | |
| throw new Error(`๋ฆฌ๋ทฐ ์ญ์ ์คํจ: ${error.message}`); | |
| }); | |
| } |
| export function getMyReviews(page: number, size: number): Promise<MyReviewResponse> { | ||
| // ์ต์ข ๋ฐํ ํ์ | ||
| const url = `/api/review/memberReviews?page=${page}&size=${size}`; | ||
| return fetchApi<ApiResponse<MyReviewResponse>>(url, { | ||
| method: 'GET', | ||
| headers: { | ||
| 'Content-Type': 'application/json', | ||
| }, | ||
| }).then((response) => { | ||
| return response.data; | ||
| }); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
์๋ฌ ์ฒ๋ฆฌ ๋ก์ง ์ถ๊ฐ๊ฐ ํ์ํฉ๋๋ค.
ํ์ฌ ๊ตฌํ์์๋ API ํธ์ถ ์คํจ ์์ ์๋ฌ ์ฒ๋ฆฌ๊ฐ ๋๋ฝ๋์ด ์์ต๋๋ค. ์ฌ์ฉ์ ๊ฒฝํ ํฅ์์ ์ํด ์๋ฌ ์ฒ๋ฆฌ๋ฅผ ์ถ๊ฐํ๋ ๊ฒ์ด ์ข๊ฒ ์ต๋๋ค.
๋ค์๊ณผ ๊ฐ์ด ์์ ํ๋ ๊ฒ์ ์ ์๋๋ฆฝ๋๋ค:
export function getMyReviews(page: number, size: number): Promise<MyReviewResponse> {
- // ์ต์ข
๋ฐํ ํ์
+ // ํ์ด์ง๋ค์ด์
๋ ์ฌ์ฉ์ ๋ฆฌ๋ทฐ ๋ชฉ๋ก์ ์กฐํํฉ๋๋ค.
+ // @param page ์กฐํํ ํ์ด์ง ๋ฒํธ (0๋ถํฐ ์์)
+ // @param size ํ์ด์ง๋น ํญ๋ชฉ ์
+ // @throws Error API ํธ์ถ ์คํจ ์
const url = `/api/review/memberReviews?page=${page}&size=${size}`;
return fetchApi<ApiResponse<MyReviewResponse>>(url, {
method: 'GET',
headers: {
'Content-Type': 'application/json',
},
}).then((response) => {
return response.data;
+ }).catch((error) => {
+ throw new Error(`๋ฆฌ๋ทฐ ๋ชฉ๋ก ์กฐํ ์คํจ: ${error.message}`);
});
}๐ Committable suggestion
โผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| export function getMyReviews(page: number, size: number): Promise<MyReviewResponse> { | |
| // ์ต์ข ๋ฐํ ํ์ | |
| const url = `/api/review/memberReviews?page=${page}&size=${size}`; | |
| return fetchApi<ApiResponse<MyReviewResponse>>(url, { | |
| method: 'GET', | |
| headers: { | |
| 'Content-Type': 'application/json', | |
| }, | |
| }).then((response) => { | |
| return response.data; | |
| }); | |
| } | |
| export function getMyReviews(page: number, size: number): Promise<MyReviewResponse> { | |
| // ํ์ด์ง๋ค์ด์ ๋ ์ฌ์ฉ์ ๋ฆฌ๋ทฐ ๋ชฉ๋ก์ ์กฐํํฉ๋๋ค. | |
| // @param page ์กฐํํ ํ์ด์ง ๋ฒํธ (0๋ถํฐ ์์) | |
| // @param size ํ์ด์ง๋น ํญ๋ชฉ ์ | |
| // @throws Error API ํธ์ถ ์คํจ ์ | |
| const url = `/api/review/memberReviews?page=${page}&size=${size}`; | |
| return fetchApi<ApiResponse<MyReviewResponse>>(url, { | |
| method: 'GET', | |
| headers: { | |
| 'Content-Type': 'application/json', | |
| }, | |
| }).then((response) => { | |
| return response.data; | |
| }).catch((error) => { | |
| throw new Error(`๋ฆฌ๋ทฐ ๋ชฉ๋ก ์กฐํ ์คํจ: ${error.message}`); | |
| }); | |
| } |
| if (error) { | ||
| toast.error('๋ฆฌ๋ทฐ๋ฅผ ๋ถ๋ฌ์ค๋ ์ค ๋ฌธ์ ๊ฐ ๋ฐ์ํ์ต๋๋ค.'); | ||
| return null; | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
์๋ฌ ์ฒ๋ฆฌ๋ฅผ ๊ฐ์ ํ ์ ์์ต๋๋ค.
ํ์ฌ ๊ตฌํ๋ ์๋ฌ ์ฒ๋ฆฌ์ ๋ค์ ๊ธฐ๋ฅ์ ์ถ๊ฐํ๋ฉด ์ข์ ๊ฒ ๊ฐ์ต๋๋ค:
- ์ฌ์๋ ๋ฉ์ปค๋์ฆ
- ๊ตฌ์ฒด์ ์ธ ์๋ฌ ๋ฉ์์ง ํ์
- ์๋ฌ ๋ฐ์ ์ ๋์ฒด UI ์ ๊ณต
- if (error) {
- toast.error('๋ฆฌ๋ทฐ๋ฅผ ๋ถ๋ฌ์ค๋ ์ค ๋ฌธ์ ๊ฐ ๋ฐ์ํ์ต๋๋ค.');
- return null;
- }
+ if (error) {
+ const errorMessage = error instanceof Error
+ ? error.message
+ : '๋ฆฌ๋ทฐ๋ฅผ ๋ถ๋ฌ์ค๋ ์ค ๋ฌธ์ ๊ฐ ๋ฐ์ํ์ต๋๋ค.';
+
+ return (
+ <div className="flex flex-col items-center justify-center gap-4">
+ <p className="text-red-500">{errorMessage}</p>
+ <button
+ onClick={() => refetch()}
+ className="rounded bg-blue-500 px-4 py-2 text-white"
+ >
+ ๋ค์ ์๋
+ </button>
+ </div>
+ );
+ }Committable suggestion skipped: line range outside the PR's diff.
| return ( | ||
| <div> | ||
| <ReviewCardList data={data ?? { pages: [], pageParams: [] }} refetch={refetch} /> | ||
| {isFetchingNextPage && ( | ||
| <div className="mt-4 flex items-center justify-center"> | ||
| <Loader /> | ||
| </div> | ||
| )} | ||
| <div ref={ref} className="h-[1px]" /> | ||
| </div> | ||
| ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
๋น ์ํ ์ฒ๋ฆฌ๊ฐ ํ์ํฉ๋๋ค.
๋ฐ์ดํฐ๊ฐ ์๋ ๊ฒฝ์ฐ์ ๋ํ UI ์ฒ๋ฆฌ๊ฐ ๋๋ฝ๋์ด ์์ต๋๋ค. ์ฌ์ฉ์์๊ฒ ์ ์ ํ ๋ฉ์์ง๋ฅผ ๋ณด์ฌ์ฃผ๋ ๊ฒ์ด ์ข์ต๋๋ค.
return (
<div>
+ {data?.pages[0]?.content?.length === 0 ? (
+ <div className="flex h-40 items-center justify-center">
+ <p className="text-gray-500">์์ฑํ ๋ฆฌ๋ทฐ๊ฐ ์์ต๋๋ค.</p>
+ </div>
+ ) : (
<ReviewCardList data={data ?? { pages: [], pageParams: [] }} refetch={refetch} />
+ )}
{isFetchingNextPage && (
<div className="mt-4 flex items-center justify-center">
<Loader />
</div>
)}
<div ref={ref} className="h-[1px]" />
</div>
);๐ Committable suggestion
โผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| return ( | |
| <div> | |
| <ReviewCardList data={data ?? { pages: [], pageParams: [] }} refetch={refetch} /> | |
| {isFetchingNextPage && ( | |
| <div className="mt-4 flex items-center justify-center"> | |
| <Loader /> | |
| </div> | |
| )} | |
| <div ref={ref} className="h-[1px]" /> | |
| </div> | |
| ); | |
| return ( | |
| <div> | |
| {data?.pages[0]?.content?.length === 0 ? ( | |
| <div className="flex h-40 items-center justify-center"> | |
| <p className="text-gray-500">์์ฑํ ๋ฆฌ๋ทฐ๊ฐ ์์ต๋๋ค.</p> | |
| </div> | |
| ) : ( | |
| <ReviewCardList data={data ?? { pages: [], pageParams: [] }} refetch={refetch} /> | |
| )} | |
| {isFetchingNextPage && ( | |
| <div className="mt-4 flex items-center justify-center"> | |
| <Loader /> | |
| </div> | |
| )} | |
| <div ref={ref} className="h-[1px]" /> | |
| </div> | |
| ); |
| // ๋ฐ์ดํฐ๊ฐ ์์ ๊ฒฝ์ฐ ์ฒ๋ฆฌ | ||
| if (!reviewDataList.length) { | ||
| return ( | ||
| <div className="flex justify-center py-10"> | ||
| <p className="text-xl font-semibold">๋จ๊ธด ๋ฆฌ๋ทฐ๊ฐ ์์ต๋๋ค</p> | ||
| <p className="text-lg font-semibold">ํฌ๋ฃจ์ ๊ฐ์ ํ๊ณ ์ฝ์์ ์ก์๋ณด์ธ์!</p> | ||
| </div> | ||
| ); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
๋น ์ํ UI์ ์ฌ์ฌ์ฉ์ฑ๊ณผ ์ ๊ทผ์ฑ ๊ฐ์ ์ด ํ์ํฉ๋๋ค
ํ์ฌ ๊ตฌํ์ ๊ธฐ๋ฅ์ ์ผ๋ก๋ ๋ฌธ์ ๊ฐ ์์ง๋ง, ๋ค์๊ณผ ๊ฐ์ ๊ฐ์ ์ฌํญ์ด ์์ต๋๋ค:
- ํ ์คํธ๊ฐ ํ๋์ฝ๋ฉ๋์ด ์์ด ์ฌ์ฌ์ฉ์ด ์ด๋ ต์ต๋๋ค
- ๋ฉ์์ง๊ฐ ๋ ๊ฐ์
pํ๊ทธ๋ก ๋๋์ด ์์ด ์คํฌ๋ฆฐ ๋ฆฌ๋ ์ฌ์ฉ์์๊ฒ ํผ๋์ ์ค ์ ์์ต๋๋ค
๋ค์๊ณผ ๊ฐ์ด ๊ฐ์ ํด๋ณด์ธ์:
- <div className="flex justify-center py-10">
- <p className="text-xl font-semibold">๋จ๊ธด ๋ฆฌ๋ทฐ๊ฐ ์์ต๋๋ค</p>
- <p className="text-lg font-semibold">ํฌ๋ฃจ์ ๊ฐ์
ํ๊ณ ์ฝ์์ ์ก์๋ณด์ธ์!</p>
- </div>
+ <div className="flex flex-col items-center py-10" role="alert" aria-label="๋ฆฌ๋ทฐ ์์ ์๋ด">
+ <strong className="text-xl mb-2">๋จ๊ธด ๋ฆฌ๋ทฐ๊ฐ ์์ต๋๋ค</strong>
+ <span className="text-lg">ํฌ๋ฃจ์ ๊ฐ์
ํ๊ณ ์ฝ์์ ์ก์๋ณด์ธ์!</span>
+ </div>๐ Committable suggestion
โผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| // ๋ฐ์ดํฐ๊ฐ ์์ ๊ฒฝ์ฐ ์ฒ๋ฆฌ | |
| if (!reviewDataList.length) { | |
| return ( | |
| <div className="flex justify-center py-10"> | |
| <p className="text-xl font-semibold">๋จ๊ธด ๋ฆฌ๋ทฐ๊ฐ ์์ต๋๋ค</p> | |
| <p className="text-lg font-semibold">ํฌ๋ฃจ์ ๊ฐ์ ํ๊ณ ์ฝ์์ ์ก์๋ณด์ธ์!</p> | |
| </div> | |
| ); | |
| } | |
| // ๋ฐ์ดํฐ๊ฐ ์์ ๊ฒฝ์ฐ ์ฒ๋ฆฌ | |
| if (!reviewDataList.length) { | |
| return ( | |
| <div className="flex flex-col items-center py-10" role="alert" aria-label="๋ฆฌ๋ทฐ ์์ ์๋ด"> | |
| <strong className="text-xl mb-2">๋จ๊ธด ๋ฆฌ๋ทฐ๊ฐ ์์ต๋๋ค</strong> | |
| <span className="text-lg">ํฌ๋ฃจ์ ๊ฐ์ ํ๊ณ ์ฝ์์ ์ก์๋ณด์ธ์!</span> | |
| </div> | |
| ); | |
| } |
| const handleClick = (e: React.MouseEvent<HTMLElement>) => { | ||
| if (clickable && crewId) { | ||
| e.stopPropagation(); | ||
| router.push(`/detail/crew/${crewId}`); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
์ด๋ฒคํธ ์ ํ ์ค์ง ์์น ๊ฐ์
handleClick ํจ์์์ e.stopPropagation()์ด clickable๊ณผ crewId๊ฐ ์๋ ๊ฒฝ์ฐ์๋ง ํธ์ถ๋๊ณ ์์ต๋๋ค. ์ด๋ฒคํธ ์ ํ ์ค์ง๋ ํญ์ ํ์ํ ๊ฒฝ์ฐ๊ฐ ๋ง์ผ๋ฏ๋ก, ํจ์์ ์ฒซ ๋ถ๋ถ์ผ๋ก ์ด๋ํ์ฌ ํญ์ ํธ์ถ๋๋๋ก ์์ ํ๋ ๊ฒ์ด ์ข์ต๋๋ค.
const handleClick = (e: React.MouseEvent<HTMLElement>) => {
+ e.stopPropagation();
if (clickable && crewId) {
- e.stopPropagation();
router.push(`/detail/crew/${crewId}`);
}
};๐ Committable suggestion
โผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| const handleClick = (e: React.MouseEvent<HTMLElement>) => { | |
| if (clickable && crewId) { | |
| e.stopPropagation(); | |
| router.push(`/detail/crew/${crewId}`); | |
| } | |
| const handleClick = (e: React.MouseEvent<HTMLElement>) => { | |
| e.stopPropagation(); | |
| if (clickable && crewId) { | |
| router.push(`/detail/crew/${crewId}`); | |
| } |
| onClick={(e) => { | ||
| e.stopPropagation(); | ||
| handleClick(e); | ||
| }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
์ด๋ฒคํธ ์ ํ ์ค์ง ์ค๋ณต ์ ๊ฑฐ
onClick ํธ๋ค๋ฌ์ handleClick ํจ์์์ e.stopPropagation()์ด ์ค๋ณต์ผ๋ก ํธ์ถ๋๊ณ ์์ต๋๋ค. ์ค๋ณต์ ์ ๊ฑฐํ์ฌ ์ฝ๋์ ๊ฐ๊ฒฐ์ฑ๊ณผ ์ ์ง๋ณด์์ฑ์ ๋์ด๋ ๊ฒ์ด ์ข์ต๋๋ค.
onClick ํธ๋ค๋ฌ์์ e.stopPropagation()์ ์ ๊ฑฐํ๊ณ handleClick ํจ์์์๋ง ์ฒ๋ฆฌํ๋๋ก ์์ ํด์ฃผ์ธ์:
- onClick={(e) => {
- e.stopPropagation();
- handleClick(e);
- }}
+ onClick={handleClick}Committable suggestion skipped: line range outside the PR's diff.
|
๐storybook: https://67206cc6ff9d7a05a3528ff8-zsanydaxoo.chromatic.com/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
๐งน Outside diff range and nitpick comments (2)
src/components/common/review-list/review-card.tsx (2)
66-70: ๋ผ์ฐํ ๋ก์ง ๊ฐ์ ์ด ํ์ํฉ๋๋ค.ํ์ฌ ๊ตฌํ์ ๋ช ๊ฐ์ง ๊ฐ์ ์ด ํ์ํฉ๋๋ค:
- ํ ํ๋ฆฟ ๋ฆฌํฐ๋ด์ ์ฌ์ฉํ์ฌ URL์ ๋ ๋ช ํํ๊ฒ ํํํ ์ ์์ต๋๋ค.
- ๋ผ์ฐํ ๊ฒฝ๋ก๊ฐ ํ๋์ฝ๋ฉ๋์ด ์์ด ์ ์ง๋ณด์๊ฐ ์ด๋ ค์ธ ์ ์์ต๋๋ค.
๋ค์๊ณผ ๊ฐ์ด ๊ฐ์ ํด๋ณด์ธ์:
- router.push(`/crew/detail/${crewId}`); + const CREW_DETAIL_PATH = `/crew/detail/${crewId}` as const; + router.push(CREW_DETAIL_PATH);
Line range hint
117-122: ์ด๋ฒคํธ ์ ํ ์ค์ง ๋ก์ง ๊ฐ์ ์ด ํ์ํฉ๋๋ค.์ญ์ ๋ฒํผ์ ์ด๋ฒคํธ ์ ํ ์ค์ง ๋ก์ง์ด ์ธ๋ผ์ธ์ผ๋ก ๊ตฌํ๋์ด ์์ด ๊ฐ๋ ์ฑ์ด ๋จ์ด์ง๋๋ค.
๋ค์๊ณผ ๊ฐ์ด ๊ฐ์ ํด๋ณด์ธ์:
+ const handleDeleteClick = (e: React.MouseEvent<HTMLElement>) => { + e.stopPropagation(); + openConfirmDeleteModal(); + }; <Button className="btn-outlined flex-shrink-0 p-[6px_14px] text-base font-semibold" - onClick={(e) => { - e.stopPropagation(); - openConfirmDeleteModal(); - }} + onClick={handleDeleteClick} >
๐ Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
๐ Files selected for processing (1)
src/components/common/review-list/review-card.tsx(4 hunks)
๐ Additional comments (2)
src/components/common/review-list/review-card.tsx (2)
4-4: ์ธํฐํ์ด์ค ๋ณ๊ฒฝ์ด ์ ์ ํ ์ด๋ฃจ์ด์ก์ต๋๋ค.
ํ์ ์์ฑ์ธ id์ refetch๊ฐ ์ถ๊ฐ๋์๊ณ , crewId๊ฐ ์ ํ์ ์์ฑ์ผ๋ก ๋ณ๊ฒฝ๋ ๊ฒ์ด ์ ์ ํฉ๋๋ค. ์๋ก์ด ๊ธฐ๋ฅ์ ์ํ ์์กด์ฑ๋ ์ฌ๋ฐ๋ฅด๊ฒ ์ถ๊ฐ๋์์ต๋๋ค.
Also applies to: 7-7, 9-9, 25-25, 28-31
55-63: ์๋ฌ ์ฒ๋ฆฌ๊ฐ ์ ๊ตฌํ๋์์ต๋๋ค.
์ญ์ ๊ธฐ๋ฅ์ ์ฑ๊ณต/์คํจ์ ๋ํ ์ฌ์ฉ์ ํผ๋๋ฐฑ์ด ์ ์ ํ ๊ตฌํ๋์ด ์์ผ๋ฉฐ, ์๋ฌ ์ฒ๋ฆฌ๋ ์ ๋์ด ์์ต๋๋ค.
| <button | ||
| type="button" | ||
| className="mb-3 flex w-fit items-center gap-2 text-xl font-semibold text-gray-800" | ||
| onClick={handleClick} | ||
| > | ||
| {crewName} | ||
| </button> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๐ ๏ธ Refactor suggestion
์ ๊ทผ์ฑ ๊ฐ์ ์ด ํ์ํฉ๋๋ค.
๋ฒํผ ๊ตฌํ์ ๋ค์ ๊ฐ์ ์ฌํญ์ ์ ์ํฉ๋๋ค:
- aria-label ์ถ๊ฐ
- ํค๋ณด๋ ์ ๊ทผ์ฑ ๊ฐ์
๋ค์๊ณผ ๊ฐ์ด ์์ ํด๋ณด์ธ์:
<button
type="button"
- className="mb-3 flex w-fit items-center gap-2 text-xl font-semibold text-gray-800"
+ className="mb-3 flex w-fit items-center gap-2 text-xl font-semibold text-gray-800 focus:outline-none focus:ring-2 focus:ring-blue-500"
+ aria-label={`${crewName} ์์ธ ๋ณด๊ธฐ`}
onClick={handleClick}
>
{crewName}
</button>๐ Committable suggestion
โผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| <button | |
| type="button" | |
| className="mb-3 flex w-fit items-center gap-2 text-xl font-semibold text-gray-800" | |
| onClick={handleClick} | |
| > | |
| {crewName} | |
| </button> | |
| <button | |
| type="button" | |
| className="mb-3 flex w-fit items-center gap-2 text-xl font-semibold text-gray-800 focus:outline-none focus:ring-2 focus:ring-blue-500" | |
| aria-label={`${crewName} ์์ธ ๋ณด๊ธฐ`} | |
| onClick={handleClick} | |
| > | |
| {crewName} | |
| </button> |
|
๐storybook: https://67206cc6ff9d7a05a3528ff8-nahdakpmag.chromatic.com/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
๐งน Outside diff range and nitpick comments (2)
src/app/(crew)/my-page/my-review/page.tsx (2)
10-14: ํ์ด์ง ํฌ๊ธฐ๋ฅผ ์์ ํ์ผ๋ก ๋ถ๋ฆฌํ๋ ๊ฒ์ด ์ข์ต๋๋ค.ํ๋์ฝ๋ฉ๋ size ๊ฐ์ ์์ ํ์ผ๋ก ๋ถ๋ฆฌํ๋ฉด ์ ์ง๋ณด์์ฑ์ด ํฅ์๋ฉ๋๋ค.
๋ค์๊ณผ ๊ฐ์ด ๋ณ๊ฒฝํ๋ ๊ฒ์ ์ ์ํฉ๋๋ค:
+// src/constants/pagination.ts +export const REVIEW_PAGE_SIZE = 6; // src/app/(crew)/my-page/my-review/page.tsx - const size = 6; + const size = REVIEW_PAGE_SIZE;
31-31: ํ์ ์์ ์ฑ์ ๊ฐ์ ํ ์ ์์ต๋๋ค.
dataprop์ ๊ธฐ๋ณธ๊ฐ์ ๋ํ ํ์ ์์ ์ฑ์ ๊ฐํํ๋ฉด ์ข์ ๊ฒ ๊ฐ์ต๋๋ค.๋ค์๊ณผ ๊ฐ์ด ๋ณ๊ฒฝํ๋ ๊ฒ์ ์ ์ํฉ๋๋ค:
- <ReviewCardList data={data ?? { pages: [], pageParams: [] }} refetch={refetch} /> + <ReviewCardList + data={data ?? { pages: [{ content: [], hasNext: false }], pageParams: [] }} + refetch={refetch} + />
๐ Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
๐ Files selected for processing (1)
src/app/(crew)/my-page/my-review/page.tsx(1 hunks)
๐ Additional comments (2)
src/app/(crew)/my-page/my-review/page.tsx (2)
1-8: ์ฝ๋๊ฐ ๊น๋ํ๊ณ ์ ๊ตฌ์ฑ๋์ด ์์ต๋๋ค!
ํ์ํ ๋ชจ๋ ์์กด์ฑ์ด ์ ์ ํ๊ฒ ์ํฌํธ๋์ด ์์ต๋๋ค.
16-22: ๋ก๋ฉ ์ํ ์ฒ๋ฆฌ๊ฐ ์ ๊ตฌํ๋์ด ์์ต๋๋ค!
์ฌ์ฉ์ ๊ฒฝํ์ ๊ณ ๋ คํ ์ ์ ํ ๋ก๋ฉ ์ธ๋์ผ์ดํฐ ๊ตฌํ์ ๋๋ค.
ChoYenii
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์๊ณ ๋ง์ผ์ จ์ต๋๋ค!
yulrang
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์๊ณ ํ์ จ์ต๋๋ค~!
๐ Issue Ticket
#156
โ๏ธ Description
โ Checklist
PR
Test
Summary by CodeRabbit
๋ฆด๋ฆฌ์ค ๋ ธํธ
์๋ก์ด ๊ธฐ๋ฅ
getMyReviews๋ฐdeleteReviewAPI ๋ฉ์๋ ๋์ .MyReviewPage์ปดํฌ๋ํธ ๊ฐ์ , ๋ก๋ฉ ๋ฐ ์ค๋ฅ ์ํ ๊ด๋ฆฌ ๊ธฐ๋ฅ ์ถ๊ฐ.formatCompactDateTime24H๋์ .๋ฒ๊ทธ ์์
๋ฌธ์ํ
์คํ์ผ