-
Notifications
You must be signed in to change notification settings - Fork 1
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] #38 - Snap carousel view에서 cd 선택 방식 수정 #56
Conversation
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.
안나님 덕분에 더욱 부드러운 애니메이션이 추가된 것 같아요!! 좋아요 〰 !!
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.
전체적으로 코드가 깔끔해졌네요~!
안나 덕분에 사용자들이 더 편하게 앱을 사용할 수 있을 것 같아요 🔥
@@ -73,13 +73,13 @@ struct Carousel<Items : View> : View { | |||
}.onEnded { value in | |||
self.UIState.screenDrag = 0 | |||
// 뒤로 스크롤 | |||
if (value.translation.width < -10 && CGFloat(self.UIState.activeCard) < numberOfItems - 1) { | |||
if (value.translation.width < -5 && CGFloat(self.UIState.activeCard) < numberOfItems - 1) { |
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.
if 문에 소괄호를 생략할 수 있어요!
VStack { | ||
Carousel( | ||
numberOfItems: CGFloat(items.count), | ||
spacing: spacing, | ||
widthOfHiddenCds: widthOfHiddenCds | ||
){ | ||
) { |
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.
깔끔한 코드~! 너무 좋네요🔥
@@ -46,138 +44,106 @@ struct SnapCarousel: View { | |||
Text(items[content].artist!) | |||
.foregroundColor(Color.titleDarkgray) | |||
.font(Font.customBody2()) | |||
.padding(.bottom, 30) | |||
.padding(.bottom, UIScreen.getHeight(20)) |
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.
바로 적용해주시는 센스~!
} | ||
.transition(AnyTransition.slide) | ||
.animation(.spring()) | ||
.animation(.spring(), value: UIState.activeCard) |
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.
버전 대응이 되었군요~!
덕분에 더 좋은 앱이 되었네요ㅎㅎ
VStack { | ||
Text("CD를 선택하고 플레이어를 재생해보세요") | ||
.foregroundColor(.titleGray) | ||
.font(.customBody2()) | ||
.frame(width: 300) | ||
.padding(.bottom, -20) | ||
.padding(.top, UIScreen.getHeight(45)) | ||
ZStack { | ||
Image("ListViewCdPlayer") | ||
.offset(y: 30) | ||
|
||
//MARK: - cdPlayer 안의 CD | ||
ForEach(items.indices, id: \.self) { content in | ||
if content == UIState.activeCard { | ||
NavigationLink(destination: | ||
RecordDetailView(item: items[content]), | ||
isActive: $showDetailView) { // 상세 뷰로 이동 | ||
URLImage(urlString: items[content].albumArt!) | ||
.clipShape(Circle()) | ||
.frame(width: 110, height: 110) | ||
.rotationEffect(.degrees(self.angle)) | ||
.animation(.timingCurve(0, 0.8, 0.2, 1, duration: 10), value: angle) | ||
.onTapGesture { | ||
self.angle += Double.random(in: 1000..<1980) | ||
timeCount() | ||
} | ||
.padding(.bottom, 120) | ||
.padding(.leading, 2) // CdPlayer를 그림자 포함해서 뽑아서 전체 CdPlayer와 정렬 맞추기 위함 | ||
} |
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.
frame, padding에 기기대응 코드를 설정하면 좋을 것 같아요~
Keychanges
Screenshots
To Reviewer