parent
9819f00d0d
commit
5fc0f1789a
|
@ -91,7 +91,34 @@ struct ContentListItemView: View {
|
||||||
|
|
||||||
Spacer()
|
Spacer()
|
||||||
|
|
||||||
if item.price > 0 {
|
if item.isOwned {
|
||||||
|
Text("소장중")
|
||||||
|
.font(.custom(Font.medium.rawValue, size: 13.3))
|
||||||
|
.foregroundColor(Color.gray11)
|
||||||
|
.padding(.horizontal, 5.3)
|
||||||
|
.padding(.vertical, 2.7)
|
||||||
|
.background(Color(hex: "b1ef2c"))
|
||||||
|
.cornerRadius(2.6)
|
||||||
|
} else if item.isRented {
|
||||||
|
Text("대여중")
|
||||||
|
.font(.custom(Font.medium.rawValue, size: 13.3))
|
||||||
|
.foregroundColor(Color.white)
|
||||||
|
.padding(.horizontal, 5.3)
|
||||||
|
.padding(.vertical, 2.7)
|
||||||
|
.background(Color(hex: "660fd4"))
|
||||||
|
.cornerRadius(2.6)
|
||||||
|
} else if item.isSoldOut {
|
||||||
|
Text("Sold Out")
|
||||||
|
.font(.custom(Font.medium.rawValue, size: 13.3))
|
||||||
|
.foregroundColor(Color.grayd2)
|
||||||
|
.padding(.horizontal, 5.3)
|
||||||
|
.padding(.vertical, 2.7)
|
||||||
|
.overlay(
|
||||||
|
RoundedRectangle(cornerRadius: 2.6)
|
||||||
|
.stroke(Color.grayd2, lineWidth: 1)
|
||||||
|
)
|
||||||
|
.cornerRadius(2.6)
|
||||||
|
} else if item.price > 0 {
|
||||||
HStack(spacing: 8) {
|
HStack(spacing: 8) {
|
||||||
Image("ic_can")
|
Image("ic_can")
|
||||||
.resizable()
|
.resizable()
|
||||||
|
@ -130,7 +157,10 @@ struct ContentListItemView_Previews: PreviewProvider {
|
||||||
commentCount: 0,
|
commentCount: 0,
|
||||||
isPin: true,
|
isPin: true,
|
||||||
isAdult: false,
|
isAdult: false,
|
||||||
isScheduledToOpen: true
|
isScheduledToOpen: true,
|
||||||
|
isRented: false,
|
||||||
|
isOwned: false,
|
||||||
|
isSoldOut: true
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
@ -81,6 +81,9 @@ struct GetAudioContentListItem: Decodable {
|
||||||
let isPin: Bool
|
let isPin: Bool
|
||||||
let isAdult: Bool
|
let isAdult: Bool
|
||||||
let isScheduledToOpen: Bool
|
let isScheduledToOpen: Bool
|
||||||
|
let isRented: Bool
|
||||||
|
let isOwned: Bool
|
||||||
|
let isSoldOut: Bool
|
||||||
}
|
}
|
||||||
|
|
||||||
struct GetCreatorActivitySummary: Decodable {
|
struct GetCreatorActivitySummary: Decodable {
|
||||||
|
|
|
@ -76,7 +76,10 @@ struct UserProfileContentView_Previews: PreviewProvider {
|
||||||
commentCount: 0,
|
commentCount: 0,
|
||||||
isPin: true,
|
isPin: true,
|
||||||
isAdult: false,
|
isAdult: false,
|
||||||
isScheduledToOpen: false
|
isScheduledToOpen: false,
|
||||||
|
isRented: false,
|
||||||
|
isOwned: false,
|
||||||
|
isSoldOut: false
|
||||||
)
|
)
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue