[CHORE] 트랙 상세/수정 공통 데이터 모델 정비#25
Conversation
📝 WalkthroughWalkthrough트랙 모델에 마디별 코드 진행과 폴백 생성 로직을 추가하고, 난이도·모드 표시 매핑을 정리했다. 추천 및 전체 mock 트랙에는 creator와 코드 진행 데이터를 반영했으며 새 재즈 왈츠 트랙을 추가했다. Changes트랙 데이터 모델 및 mock 데이터
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
src/pages/practice/mockTracks.ts (1)
112-121: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valuetrack-3 진행의 코드 표기를
chords배열과 통일하는 것을 권장합니다.
chords배열은Gmaj7를 사용하지만chordProgression은GM7를 사용하고 있습니다. 같은 코드이나 표기법이 다르면 데이터 매칭 시 혼란이 발생할 수 있습니다.chords배열의 표기(maj7)에 맞추는 것을 권장합니다.♻️ 제안: 표기법 통일
chordProgression: [ - ['GM7', 'Em7', null], + ['Gmaj7', 'Em7', null], ['Em7', null, 'Em7'], - ['CM7', null, 'D7'], + ['Cmaj7', null, 'D7'], ['D7', null, null], - ['CM7', null, 'D7'], + ['Cmaj7', null, 'D7'], ['D7', null, null], - ['GM7', 'Em7', null], + ['Gmaj7', 'Em7', null], ['Em7', null, 'Em7'], ],🤖 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/pages/practice/mockTracks.ts` around lines 112 - 121, Update the track-3 chordProgression entries to use the same maj7 notation as the chords array, replacing each GM7 and CM7 symbol with the corresponding Gmaj7 and Cmaj7 representation while leaving all other progression values unchanged.
🤖 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/pages/practice/mockTracks.ts`:
- Around line 6-15: Update JAZZ_STANDARD_PROGRESSION to use the chord names
defined in the same track: replace each AM7 entry with Am7, add the missing Dm7
ii chord at the appropriate progression position, and align Cmaj7 notation with
the chords array instead of CM7.
---
Nitpick comments:
In `@src/pages/practice/mockTracks.ts`:
- Around line 112-121: Update the track-3 chordProgression entries to use the
same maj7 notation as the chords array, replacing each GM7 and CM7 symbol with
the corresponding Gmaj7 and Cmaj7 representation while leaving all other
progression values unchanged.
🪄 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: CHILL
Plan: Pro Plus
Run ID: 0a9c3e9a-27dc-4c3d-a49a-446c75a89f96
📒 Files selected for processing (3)
src/pages/practice/mockTracks.tssrc/pages/practice/trackDisplay.tssrc/types/track.ts
| const JAZZ_STANDARD_PROGRESSION: Track['chordProgression'] = [ | ||
| ['CM7', 'AM7', null, null], | ||
| ['AM7', null, 'AM7', null], | ||
| ['CM7', null, 'G7', null], | ||
| ['G7', null, null, null], | ||
| ['CM7', null, 'G7', null], | ||
| ['G7', null, null, null], | ||
| ['CM7', 'AM7', null, null], | ||
| ['AM7', null, 'AM7', null], | ||
| ]; |
There was a problem hiding this comment.
🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win
AM7(A 메이저 7)와 Am7(A 마이너 7) 코드가 혼용되어 있습니다.
JAZZ_STANDARD_PROGRESSION에서 AM7를 사용하지만, 같은 트랙의 chords 배열에는 Am7가 정의되어 있습니다. AM7(A, C♯, E, G♯)와 Am7(A, C, E, G)는 서로 다른 코드이며, C 메이저 키에서 Am7(vi 코드)가 다이아토닉 코드인 점을 고려하면 AM7는 Am7의 오타로 보입니다.
또한 chords 배열의 Dm7(ii 코드)가 진행에 누락되어 있고, 표기법(Cmaj7 vs CM7)이 chords와 chordProgression 간에 일치하지 않아 향후 혼동의 원인이 될 수 있습니다.
🔧 제안: 코드 표기 및 진행 수정
const JAZZ_STANDARD_PROGRESSION: Track['chordProgression'] = [
- ['CM7', 'AM7', null, null],
- ['AM7', null, 'AM7', null],
- ['CM7', null, 'G7', null],
+ ['Cmaj7', 'Am7', null, null],
+ ['Am7', null, 'Am7', null],
+ ['Cmaj7', null, 'Dm7', null],
['G7', null, null, null],
- ['CM7', null, 'G7', null],
+ ['Cmaj7', null, 'G7', null],
['G7', null, null, null],
- ['CM7', 'AM7', null, null],
- ['AM7', null, 'AM7', null],
+ ['Cmaj7', 'Am7', null, null],
+ ['Am7', null, 'Am7', 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.
| const JAZZ_STANDARD_PROGRESSION: Track['chordProgression'] = [ | |
| ['CM7', 'AM7', null, null], | |
| ['AM7', null, 'AM7', null], | |
| ['CM7', null, 'G7', null], | |
| ['G7', null, null, null], | |
| ['CM7', null, 'G7', null], | |
| ['G7', null, null, null], | |
| ['CM7', 'AM7', null, null], | |
| ['AM7', null, 'AM7', null], | |
| ]; | |
| const JAZZ_STANDARD_PROGRESSION: Track['chordProgression'] = [ | |
| ['Cmaj7', 'Am7', null, null], | |
| ['Am7', null, 'Am7', null], | |
| ['Cmaj7', null, 'Dm7', null], | |
| ['G7', null, null, null], | |
| ['Cmaj7', null, 'G7', null], | |
| ['G7', null, null, null], | |
| ['Cmaj7', 'Am7', null, null], | |
| ['Am7', null, 'Am7', null], | |
| ]; |
🤖 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/pages/practice/mockTracks.ts` around lines 6 - 15, Update
JAZZ_STANDARD_PROGRESSION to use the chord names defined in the same track:
replace each AM7 entry with Am7, add the missing Dm7 ii chord at the appropriate
progression position, and align Cmaj7 notation with the chords array instead of
CM7.
There was a problem hiding this comment.
AM7이랑 Am7은 다른게 맞습니다~ 지금 표기가 맞아요!
leeminsel
left a comment
There was a problem hiding this comment.
[CHORE] 트랙 상세/수정 공통 데이터 모델 정비
|
구현하느라 수고하셨습니다~!! |
#️⃣ 관련 이슈
📝 작업 요약
Track 타입에 소유자(creator)와 코드 진행(chordProgression) 필드 추가, 관련 mock 데이터 및 공용 표시 유틸 정비
🔧 변경 사항
💬 리뷰어 참고 사항
후속 PR(#8, #24)에서 사용할 데이터 기반 작업이라 UI 변화는 없습니다.
TrackCard 난이도 라벨 '전공'을 '고급'으로 통일한 것도 포함되어 있습니다.
✅ 체크리스트
Summary by CodeRabbit
새 기능
버그 수정