콘텐츠 상세
- 한정판이 매진된 경우 Player 가운데 Sold Out 표시
This commit is contained in:
		| @@ -36,6 +36,17 @@ struct ContentDetailInfoLimitedEditionView: View { | |||||||
|                     .font(.custom(Font.medium.rawValue, size: 13.3)) |                     .font(.custom(Font.medium.rawValue, size: 13.3)) | ||||||
|                     .foregroundColor(Color.grayd2) |                     .foregroundColor(Color.grayd2) | ||||||
|                     .padding(.leading, 2.3) |                     .padding(.leading, 2.3) | ||||||
|  |             } else if (remainingContentCount <= 0) { | ||||||
|  |                 Text("Sold Out") | ||||||
|  |                     .font(.custom(Font.medium.rawValue, size: 12)) | ||||||
|  |                     .foregroundColor(Color.grayd2) | ||||||
|  |                     .padding(.horizontal, 5.3) | ||||||
|  |                     .padding(.vertical, 3.3) | ||||||
|  |                     .overlay( | ||||||
|  |                         RoundedRectangle(cornerRadius: 2.6) | ||||||
|  |                             .stroke(lineWidth: 1) | ||||||
|  |                             .foregroundColor(Color.grayd2) | ||||||
|  |                     ) | ||||||
|             } else { |             } else { | ||||||
|                 Text("잔여수량") |                 Text("잔여수량") | ||||||
|                     .font(.custom(Font.medium.rawValue, size: 13.3)) |                     .font(.custom(Font.medium.rawValue, size: 13.3)) | ||||||
| @@ -59,7 +70,7 @@ struct ContentDetailInfoLimitedEditionView: View { | |||||||
| #Preview { | #Preview { | ||||||
|     ContentDetailInfoLimitedEditionView( |     ContentDetailInfoLimitedEditionView( | ||||||
|         totalContentCount: 10, |         totalContentCount: 10, | ||||||
|         remainingContentCount: 3, |         remainingContentCount: 0, | ||||||
|         orderSequence: 5 |         orderSequence: nil | ||||||
|     ) |     ) | ||||||
| } | } | ||||||
|   | |||||||
| @@ -35,7 +35,17 @@ struct ContentDetailPlayView: View { | |||||||
|                     ) |                     ) | ||||||
|                     .cornerRadius(10.7, corners: [.topLeft, .topRight]) |                     .cornerRadius(10.7, corners: [.topLeft, .topRight]) | ||||||
|                  |                  | ||||||
|                 if audioContent.releaseDate == nil && !isAlertPreview || (isAlertPreview && audioContent.isActivePreview) { |                 if let _ = audioContent.totalContentCount, let remainingContentCount = audioContent.remainingContentCount, remainingContentCount <= 0, audioContent.creator.creatorId != UserDefaults.int(forKey: .userId), !isShowPreviewAlert { | ||||||
|  |                     Text("Sold Out") | ||||||
|  |                         .font(.custom(Font.bold.rawValue, size: 36.7)) | ||||||
|  |                         .foregroundColor(.white) | ||||||
|  |                         .frame( | ||||||
|  |                             width: screenSize().width - 26.7, | ||||||
|  |                             height: screenSize().width - 26.7, | ||||||
|  |                             alignment: .center | ||||||
|  |                         ) | ||||||
|  |                         .background(Color.black.opacity(0.6)) | ||||||
|  |                 } else if audioContent.releaseDate == nil && !isAlertPreview || (audioContent.isActivePreview && !audioContent.contentUrl.trimmingCharacters(in: .whitespacesAndNewlines).isEmpty) { | ||||||
|                     Image(isPlaying() ? "btn_audio_content_pause" : isAlertPreview ? "btn_audio_content_preview_play" : "btn_audio_content_play") |                     Image(isPlaying() ? "btn_audio_content_pause" : isAlertPreview ? "btn_audio_content_preview_play" : "btn_audio_content_play") | ||||||
|                         .onTapGesture { |                         .onTapGesture { | ||||||
|                             if isPlaying() { |                             if isPlaying() { | ||||||
| @@ -56,7 +66,7 @@ struct ContentDetailPlayView: View { | |||||||
|                                 isShowPreviewAlert = true |                                 isShowPreviewAlert = true | ||||||
|                             } |                             } | ||||||
|                         } |                         } | ||||||
|                 } else { |                 } else if audioContent.releaseDate == nil { | ||||||
|                     Text("해당 콘텐츠는 크리에이터의 요청으로\n미리듣기를 제공하지 않습니다.") |                     Text("해당 콘텐츠는 크리에이터의 요청으로\n미리듣기를 제공하지 않습니다.") | ||||||
|                         .font(.custom(Font.medium.rawValue, size: 16.7)) |                         .font(.custom(Font.medium.rawValue, size: 16.7)) | ||||||
|                         .foregroundColor(Color.grayee) |                         .foregroundColor(Color.grayee) | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Yu Sung
					Yu Sung