[Feat] Dashboard 컴포넌트 제작#22
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthrough멘토링 대시보드용 요약 카드, 리뷰 행, 만족도 행을 추가했습니다. 각 컴포넌트의 테스트와 Storybook 스토리를 구성하고 공개 export를 연결했으며, CodeRabbit 지식 기반 설정을 확장했습니다. Changes멘토링 대시보드 컴포넌트
CodeRabbit 지식 기반 설정
Possibly related PRs
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
CI 결과
|
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/components/mentoring/MentoringReviewRow/MentoringReviewRow.tsx`:
- Around line 3-8: Update ParticipantMeta.role from a general string to a
literal union permitting only '멘토' or '멘티', so invalid role values are rejected
at compile time.
- Line 23: Correct the misspelled Tailwind token classes in MentoringReviewRow,
including text-label-netural, text-label-assitive, and bg-fill-netural, to use
the established neutral and assistive spellings so the intended styles apply.
In
`@src/components/mentoring/MentorSatisfactionRow/MentorSatisfactionRow.test.tsx`:
- Around line 20-24: Extend the MentorSatisfactionRow clamp test suite with a
lower-bound regression case: render MentorSatisfactionRow with
satisfactionRate={-1} and assert that 0% is displayed, while preserving the
existing 120 → 100% upper-bound test.
In `@src/components/mentoring/MentorSatisfactionRow/MentorSatisfactionRow.tsx`:
- Line 20: Update the clampedRate calculation in MentorSatisfactionRow to
normalize satisfactionRate with Number.isFinite before applying the existing
0–100 clamp. Use an appropriate finite fallback so NaN and other non-finite
values cannot produce an invalid percentage or width.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 42fc1ec4-cd99-45c4-823d-f27ed8dd7a44
⛔ Files ignored due to path filters (7)
src/assets/icons/generated/DashboardFigureIcon.tsxis excluded by!**/generated/**src/assets/icons/generated/DashboardGraphIcon.tsxis excluded by!**/generated/**src/assets/icons/generated/DashboardTimeIcon.tsxis excluded by!**/generated/**src/assets/icons/generated/index.tsis excluded by!**/generated/**src/assets/icons/svg-preserve/dashboard-figure.svgis excluded by!**/*.svg,!**/*.svgsrc/assets/icons/svg-preserve/dashboard-graph.svgis excluded by!**/*.svg,!**/*.svgsrc/assets/icons/svg-preserve/dashboard-time.svgis excluded by!**/*.svg,!**/*.svg
📒 Files selected for processing (15)
.coderabbit.yamlsrc/assets/icons/svg-preserve/.gitkeepsrc/components/mentoring/MentorSatisfactionRow/MentorSatisfactionRow.stories.tsxsrc/components/mentoring/MentorSatisfactionRow/MentorSatisfactionRow.test.tsxsrc/components/mentoring/MentorSatisfactionRow/MentorSatisfactionRow.tsxsrc/components/mentoring/MentorSatisfactionRow/index.tssrc/components/mentoring/MentoringReviewRow/MentoringReviewRow.stories.tsxsrc/components/mentoring/MentoringReviewRow/MentoringReviewRow.test.tsxsrc/components/mentoring/MentoringReviewRow/MentoringReviewRow.tsxsrc/components/mentoring/MentoringReviewRow/index.tssrc/components/mentoring/MentoringSummaryCard/MentoringSummaryCard.stories.tsxsrc/components/mentoring/MentoringSummaryCard/MentoringSummaryCard.test.tsxsrc/components/mentoring/MentoringSummaryCard/MentoringSummaryCard.tsxsrc/components/mentoring/MentoringSummaryCard/index.tssrc/components/mentoring/index.ts
💤 Files with no reviewable changes (1)
- src/assets/icons/svg-preserve/.gitkeep
|
|
||
| function ParticipantMetaLabel({ name, role, generation, part }: ParticipantMeta) { | ||
| return ( | ||
| <p className="text-label-14m text-label-netural flex items-center gap-1 whitespace-nowrap"> |
There was a problem hiding this comment.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
printf '%s\n' '--- target file ---'
git ls-files 'src/components/mentoring/MentoringReviewRow/MentoringReviewRow.tsx' 'src/components/mentoring/MentoringSummaryCard.tsx' \
'tailwind.config.*' 'src/**/tailwind.config.*' 'src/**/tokens*' 'src/**/theme*' | sed '/^$/d'
printf '\n%s\n' '--- MentoringReviewRow excerpt ---'
sed -n '1,120p' src/components/mentoring/MentoringReviewRow/MentoringReviewRow.tsx
printf '\n%s\n' '--- MentoringSummaryCard excerpt ---'
sed -n '1,140p' src/components/mentoring/MentoringSummaryCard.tsx
printf '\n%s\n' '--- search class names ---'
rg -n "text-label-(netural|neutral|assitive|assistive)|bg-fill-(netural|neutral)|border-line-(netural|neutral)|text-label-alternative" src tailwind.config.* 2>/dev/null || true
printf '\n%s\n' '--- possible tailwind config files ---'
fd -a 'tailwind.config.*|theme.*|tokens.*' . 2>/dev/null || trueRepository: kusitms-com/makers-admin-fe
Length of output: 3051
🏁 Script executed:
#!/bin/bash
set -euo pipefail
# Find the exact files and token definitions with minimal output.
git ls-files | rg '^(src/components/mentoring/(MentoringReviewRow|MentoringSummaryCard)/.*\.tsx|.*tailwind\.config\.(js|ts|cjs|mjs)|.*(tokens|theme).*\.(ts|js|tsx|json))$'
printf '\n[ReviewRow]\n'
sed -n '1,120p' src/components/mentoring/MentoringReviewRow/MentoringReviewRow.tsx
printf '\n[SummaryCard]\n'
sed -n '1,160p' src/components/mentoring/MentoringSummaryCard.tsx
printf '\n[Search]\n'
rg -n 'text-label-(netural|neutral|assitive|assistive)|bg-fill-(netural|neutral)|border-line-(netural|neutral)|text-label-alternative' src . -g '!node_modules' -g '!dist' -g '!build' || trueRepository: kusitms-com/makers-admin-fe
Length of output: 3358
text-label-netural/text-label-assitive/bg-fill-netural 오타 수정 23, 52, 57행의 클래스명이 토큰명과 달라 실제 스타일이 적용되지 않습니다. neutral/assistive로 맞춰 주세요.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@src/components/mentoring/MentoringReviewRow/MentoringReviewRow.tsx` at line
23, Correct the misspelled Tailwind token classes in MentoringReviewRow,
including text-label-netural, text-label-assitive, and bg-fill-netural, to use
the established neutral and assistive spellings so the intended styles apply.
CI 결과
|
leemanjae02
left a comment
There was a problem hiding this comment.
수고하셨습니다! 코멘트 남겨드렸으니 확인 부탁드려요 :)
| }: MentoringSummaryCardProps) { | ||
| const content = ( | ||
| <div className="flex w-full flex-1 flex-col gap-9"> | ||
| <div className="flex h-5 items-center justify-between"> | ||
| <p className="text-label-14sb text-label-alternative">{label}</p> | ||
| {onClick && ( | ||
| <ChevronRight className="text-label-alternative size-4 shrink-0" aria-hidden="true" /> | ||
| )} | ||
| </div> | ||
| <div className="flex items-end justify-between"> | ||
| <p className="text-pc-36b text-label-normal">{count}</p> | ||
| <div className="size-[58px] shrink-0">{icon}</div> | ||
| </div> |
There was a problem hiding this comment.
props로 넘겨받는 아이콘이 장식용인데 스크린리더 무시 처리가 빠져 있어서 추가해주시면 더 좋을 것 같습니다!
CI 결과
|
#️⃣ 연관된 이슈
🚧 Work in Progress
📌 주요 변경사항
📝 작업 내용
MentoringSummaryCard: 라벨/카운트/아이콘 slot을 받는 요약 카드,onClick유무에 따라 button/div로 렌더링하고 chevron 노출 여부를 연동MentorSatisfactionRow: 멘토 아바타·기수·파트와 만족도 진행바를 표시하는 목록 행,satisfactionRate를 0~100으로 clampMentoringReviewRow: 멘토링 후기 제목·작성 시점·멘토→멘티 메타·키워드 칩·자유 후기를 표시하는 목록 행, 추천 여부(isRecommended)에 따라 추천 칩 노출DashboardFigureIcon,DashboardGraphIcon,DashboardTimeIcon) SVG 원본과 생성 컴포넌트 추가, barrel 재생성.claude/rules,.claude/references등)를 리뷰 기준으로 참조하도록knowledge_base설정 추가eslint --quiet,tsc --noEmit,vitest run통과 (총 12개 테스트)📸 스크린샷 (선택)
💬 리뷰 요구사항(선택)
MentoringReviewRow의 키워드 칩은 이모지 포함 완성 문자열(keywords: string[])을 그대로 받는 구조입니다. 실제 API 응답 스키마가 정해지면 이 부분을 확인해주세요.Summary by CodeRabbit