마이페이지

- 내 보관함 이동 버튼 추가
This commit is contained in:
Yu Sung
2025-01-08 01:40:41 +09:00
parent d060b8620a
commit 6c0ea9595c
9 changed files with 65 additions and 34 deletions

View File

@@ -71,11 +71,7 @@ struct CanCardView_Previews: PreviewProvider {
websiteUrl: "",
blogUrl: "",
liveReservationCount: 0,
isAuth: false,
orderList: GetAudioContentOrderListResponse(
totalCount: 0,
items: []
)
isAuth: false
),
refresh: {}
)

View File

@@ -95,11 +95,7 @@ struct MyInfoCardView_Previews: PreviewProvider {
websiteUrl: "",
blogUrl: "",
liveReservationCount: 0,
isAuth: false,
orderList: GetAudioContentOrderListResponse(
totalCount: 0,
items: []
)
isAuth: false
),
refresh: {}
)

View File

@@ -18,6 +18,5 @@ struct MyPageResponse: Decodable {
let blogUrl: String?
let liveReservationCount: Int
let isAuth: Bool
let orderList: GetAudioContentOrderListResponse
}

View File

@@ -81,16 +81,17 @@ struct MyPageView: View {
}
}
HStack(spacing: 8) {
HStack(spacing: 10.7) {
Text("팔로잉 리스트")
.font(.custom(Font.bold.rawValue, size: 14.7))
.foregroundColor(Color.button)
.frame(maxWidth: .infinity)
.padding(.vertical, 13.3)
.font(.custom(Font.bold.rawValue, size: 15.3))
.foregroundColor(Color.grayee)
.background(Color.bg)
.cornerRadius(6.7)
.overlay(
RoundedRectangle(cornerRadius: 6.7)
.stroke(Color.button, lineWidth: 1)
.stroke(Color.button, lineWidth: 1.3)
)
.contentShape(Rectangle())
.onTapGesture {
@@ -98,14 +99,15 @@ struct MyPageView: View {
}
Text("차단 리스트")
.font(.custom(Font.bold.rawValue, size: 14.7))
.foregroundColor(Color.button)
.frame(maxWidth: .infinity)
.padding(.vertical, 13.3)
.font(.custom(Font.bold.rawValue, size: 15.3))
.foregroundColor(Color.grayee)
.background(Color.bg)
.cornerRadius(6.7)
.overlay(
RoundedRectangle(cornerRadius: 6.7)
.stroke(Color.button, lineWidth: 1)
.stroke(Color.button, lineWidth: 1.3)
)
.contentShape(Rectangle())
.onTapGesture {
@@ -132,13 +134,50 @@ struct MyPageView: View {
}
}
ReservationStatusView(data: data)
.padding(.top, 33.3)
if data.orderList.totalCount > 0 {
OrderListView(items: data.orderList.items)
.padding(.top, 40)
VStack(alignment: .leading, spacing: 13.3) {
Text("내 보관함")
.font(.custom(Font.bold.rawValue, size: 18.3))
.foregroundColor(Color.grayee)
HStack(spacing: 10.7) {
Text("구매목록")
.font(.custom(Font.bold.rawValue, size: 14.7))
.foregroundColor(Color.button)
.frame(maxWidth: .infinity)
.padding(.vertical, 13.3)
.background(Color.bg)
.cornerRadius(6.7)
.overlay(
RoundedRectangle(cornerRadius: 6.7)
.stroke(Color.button, lineWidth: 1.3)
)
.contentShape(Rectangle())
.onTapGesture {
AppState.shared.setAppStep(step: .myBox(currentTab: .orderlist))
}
Text("재생목록")
.font(.custom(Font.bold.rawValue, size: 14.7))
.foregroundColor(Color.button)
.frame(maxWidth: .infinity)
.padding(.vertical, 13.3)
.background(Color.bg)
.cornerRadius(6.7)
.overlay(
RoundedRectangle(cornerRadius: 6.7)
.stroke(Color.button, lineWidth: 1.3)
)
.contentShape(Rectangle())
.onTapGesture {
AppState.shared.setAppStep(step: .myBox(currentTab: .playlist))
}
}
}
.padding(.top, 33)
.padding(.horizontal, 13.3)
ReservationStatusView(data: data)
.padding(.top, 40)
ServiceCenterButtonView()
.padding(.top, 40)

View File

@@ -61,11 +61,7 @@ struct ReservationStatusView_Previews: PreviewProvider {
websiteUrl: "",
blogUrl: "",
liveReservationCount: 0,
isAuth: false,
orderList: GetAudioContentOrderListResponse(
totalCount: 0,
items: []
)
isAuth: false
)
)
}