Conversation
* feat(MyCollection): 유저 정보 조회 API 세팅 및 적용 * feat(MyCollection): diary API 연동 및 내 피드 UI 추가 * feat(MyCollection): 유저 통계정보 API 연동 * feat(MyTab): 탭 UI 업데이트 * fix(MyTab): 중복된 여백 제거 * feat(profileCard): UI 업데이트 * refactor(profilecard): 프로필 카드 부분 컴포넌트 분리 및 UI 업데이트 * feat(feedCard): UI 업데이트 * refactor(MyCollection): FeedCard, ProfileCard 컴포넌트 분리 및 정리 * refactor(ProfileSettingSection): 컴포넌트 분리 및 애니메이션 방향 변경 * feat(1.0.5): 버전 업데이트
* feat(Add): Spotify api 구조 세팅 및 add페이지 연동 * refactor(Add): AddTabView 컴포넌트 분리 * feat(1.0.6): 버전 업데이트
There was a problem hiding this comment.
Pull request overview
This PR implements version 1.0.6 of the KillingPart app, introducing significant feature enhancements including user profile integration, personal music diary feeds, statistics display, and Spotify API integration for track search functionality.
Changes:
- Integrated user profile, statistics, and diary feed APIs with new service layers (UserService, DiaryService)
- Refactored "My Collection" UI with new component-based architecture for profile cards and feed displays
- Added Spotify API integration with token caching and search functionality for the Add tab
- Enhanced UI/UX with improved animations and transitions throughout My and Add tabs
Reviewed changes
Copilot reviewed 34 out of 34 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| MyTabView.swift | Replaced TabView with ZStack for custom tab transitions with matched geometry effects |
| MyCollectionView.swift | Refactored to use extracted components and integrated user/diary data loading |
| MyCollectionViewModel.swift | New view model implementing concurrent data loading for user profile, statistics, and feeds |
| MyCollectionProfile*.swift | New profile card and settings components extracted for better code organization |
| MyCollectionFeed*.swift | New feed card components for displaying user's music diary entries |
| AddTabView.swift | Transformed from placeholder to functional Spotify track search UI |
| AddTabViewModel.swift | New view model managing Spotify search state and debouncing |
| UserService.swift | New service layer for user-related API endpoints |
| DiaryService.swift | New service layer for diary/feed API endpoints |
| SpotifyService.swift | New service implementing Spotify API integration with token caching |
| UserModel.swift | New models for user data and statistics |
| DiaryModel.swift | New models for diary feeds and pagination |
| SpotifyModel.swift | New models for Spotify API responses |
| APIClient.swift | Enhanced to support query parameters in API requests |
| APIConfiguration.swift | Updated endpoint builder to handle query parameters |
| MainTabView.swift | Updated tab labels and icons |
| Info.plist | Added SPOTIFY_BASIC_AUTH configuration key |
| project.pbxproj | Bumped version from 1.0.4 to 1.0.6 |
| kpGray*.colorset | New color assets for UI styling |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
|
||
| var body: some View { | ||
| Button(action: action) { | ||
| HStack(alignment:.center,spacing: 6) { |
There was a problem hiding this comment.
There's inconsistent spacing in the HStack declaration. The alignment and spacing parameters should be separated by a space for better readability and consistency with Swift conventions.
| HStack(alignment:.center,spacing: 6) { | |
| HStack(alignment: .center, spacing: 6) { |
|
|
||
| VStack(alignment: .leading, spacing: AppSpacing.xs) { | ||
| Text(displayName) | ||
| .font(AppFont.paperlogy6SemiBold(size: 16)) | ||
| .foregroundStyle(Color.kpPrimary) | ||
| .lineLimit(1) | ||
|
|
||
| Text(displayTag) | ||
| .font(AppFont.paperlogy4Regular(size: 13)) | ||
| .foregroundStyle(Color.kpPrimary) | ||
| .lineLimit(1) | ||
| .truncationMode(.tail) | ||
| .minimumScaleFactor(0.85) | ||
| } | ||
|
|
||
| MyCollectionProfileStatItemView(value: killingPartStatText, title: "킬링파트") | ||
| MyCollectionProfileStatItemView(value: fanStatText, title: "팬덤") | ||
| MyCollectionProfileStatItemView(value: pickStatText, title: "PICKS") | ||
| } | ||
| MyCollectionEditProfileButton(action: onEditProfileTap) | ||
| } | ||
| } | ||
|
|
||
|
|
There was a problem hiding this comment.
There are empty lines with trailing whitespace. These lines should be removed or the whitespace should be cleaned up for code cleanliness.
| MyTabView(onLogout: onLogout) | ||
| .tabItem { | ||
| Label("마이", systemImage: "person.fill") | ||
| Label("MY", systemImage: "house") |
There was a problem hiding this comment.
The tab label was changed from "마이" (Korean) to "MY" (English), while the second tab remains "추가" (Korean). This creates an inconsistent language mix in the UI. Consider keeping both labels in the same language for consistency.
| Label("MY", systemImage: "house") | |
| Label("마이", systemImage: "house") |
| async let profileLoad: Void = loadMyProfileIfNeeded() | ||
| async let feedLoad: Void = loadMyFeedsIfNeeded() | ||
| _ = await (profileLoad, feedLoad) |
There was a problem hiding this comment.
When loading profile and feeds concurrently in loadInitialDataIfNeeded, if both operations fail, their error messages will race to set the errorMessage property. The last one to complete will overwrite the first error, potentially hiding important failure information. Consider either: 1) combining error messages from both operations, 2) prioritizing one error over the other, or 3) loading them sequentially if you need to show all errors.
| async let profileLoad: Void = loadMyProfileIfNeeded() | |
| async let feedLoad: Void = loadMyFeedsIfNeeded() | |
| _ = await (profileLoad, feedLoad) | |
| await loadMyProfileIfNeeded() | |
| await loadMyFeedsIfNeeded() |
| import SwiftUI | ||
|
|
||
| struct MyCollectionFeedLikeBadgeView: View { | ||
| let isLiked: Bool |
There was a problem hiding this comment.
The isLiked parameter is declared but never used in the view body. Consider either using it to conditionally style the heart icon (e.g., different colors or fill states for liked vs. not liked), or remove the parameter if it's not needed.
1.0.5~1.0.6 업데이트 내용