Skip to content
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

RecordDetailView #8

Merged
merged 1 commit into from
Jun 15, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 63 additions & 14 deletions Recorder/RecordDetailView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
// Created by 김보승 on 2022/06/13.
//


import SwiftUI

struct RecordDetailView: View {
Expand All @@ -14,6 +15,25 @@ struct RecordDetailView: View {
ZStack {
Color.background.edgesIgnoringSafeArea(.all)
RecordBackground()
VStack {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

전체적으로 인텐트 맞춰주시면 가독성이 좋아질 것 같아요

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-Indent 완료했습니다

HStack{
Spacer()
Menu(content: {
Button(action: {}) { // TODO: antion내에 편집 기능 예정
Label("수정", systemImage: "pencil")
}
Button(action: {}) { // TODO: Soi코딩 중인 스크린샷 기능 예정
Label("이미지로 저장", systemImage: "square.and.arrow.down")
}
Button(role: .destructive, action: {}) { // TODO: action에 삭제 Alert띄우기 및 삭제 기능 예정
Label("삭제", systemImage: "trash")
}
}, label: {
Image(systemName: "ellipsis")
.foregroundColor(.pointBlue)
})
}.padding(.trailing)

HStack {
VStack(alignment: .leading) {
Text("일이삼사오육칠팔구십일이삼사오육") // TODO: "music.title"
Expand All @@ -29,38 +49,41 @@ struct RecordDetailView: View {
.foregroundColor(.titleDarkgray)
Spacer()
}// MusicInform VStack End
.padding(.leading, 5)
.padding(.top, 10)
Spacer()
} // MusicImform HStack End
.padding(.leading, 23)
VStack {

.padding(.leading, 28)
}

ZStack {
HStack(alignment: .center) {

Button(action: {}, // TODO: action 내에 클릭시 모달을 통해 이미지 띄우는 기능 추가 예정
label: {
Image("PhotoComp") // 이미지 삽입
.padding()
}).offset(y: -70)
}).offset(y: -110)
Spacer()

Button(action: {}, label: { // TODO: CD돌아가는 애니메이션 출력..?
Image("CdPlayer")
.padding(.trailing, 20.0)
})
}.offset(y: 110)
CDPlayerComp()
}).offset(y: -10)
}.offset(y: 80)
.padding()

VStack(alignment: .leading) {

Button(action: {}, label: { // TODO: action 내에 클릭시 모달을 통해 이미지 띄우는 기능 추가 예정
Image("LylicComp") // 가사 입력
}).offset(y: 130)

Spacer()

Button(action: {}, label: { // TODO: action 내에 클릭시 모달을 통해 StoryView 추가 예정
Image("StoryComp") // 스토리 입력
}).offset(x: 20,y: -50)
}).offset(x: 20,y: -100)


Button(action: {}, label: { // TODO: action 내에 클릭시 모달을 통해 이미지 띄우는 기능 추가 예정
Image("LylicComp") // 가사 입력
}).offset(y: -30)
}.offset(y: -20)
Spacer()

Expand All @@ -81,8 +104,34 @@ struct RecordBackground: View {
HStack {
Spacer()
Image("backwindow")
}.padding(.top, 70.0)
}.padding(.top, 60.0)
Spacer()
}
}
}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

다른 파일에서도 사용하는 뷰라면, 새로운 Swift파일을 만들어서 관리하는게 좋을 것 같아요

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

그럼 이부분은 이번 머지 이후 따로 UIView를 생성해서 코드를 옮겨놓도록 하겠습니다

struct CDPlayerComp: View {
var body: some View {
ZStack {
Image("CdPlayer")
.padding(.trailing, 20.0)



ZStack {
Circle()
.foregroundColor(.titleLightgray)
.frame(width: 30 , height: 30)
Circle()
.foregroundColor(.titleDarkgray)
.frame(width: 15 , height: 15)
.shadow(color: Color(.gray), radius: 4, x: 0, y: 4)
Circle()
.foregroundColor(.background)
.frame(width: 3 , height: 3)
}.offset(x: -9.5, y: -130)
// Z스택

}// ZStack End
}
}