크리에이터 채널, 콘텐츠 상세 - 오픈예정 추가

This commit is contained in:
Yu Sung
2024-01-10 02:55:00 +09:00
parent a836215d37
commit 679783cc35
7 changed files with 57 additions and 22 deletions

View File

@@ -35,26 +35,28 @@ struct ContentDetailPlayView: View {
)
.cornerRadius(10.7, corners: [.topLeft, .topRight])
Image(isPlaying() ? "btn_audio_content_pause" : isAlertPreview ? "btn_audio_content_preview_play" : "btn_audio_content_play")
.onTapGesture {
if isPlaying() {
contentPlayManager.pauseAudio()
} else {
contentPlayManager.startTimer = startTimer
contentPlayManager.stopTimer = stopTimer
contentPlayManager.playAudio(
contentId: audioContent.contentId,
title: audioContent.title,
nickname: audioContent.creator.nickname,
coverImage: audioContent.coverImageUrl,
contentUrl: audioContent.contentUrl,
isFree: audioContent.price <= 0,
isPreview: !audioContent.existOrdered && audioContent.price > 0
)
isShowPreviewAlert = true
if audioContent.releaseDate == nil {
Image(isPlaying() ? "btn_audio_content_pause" : isAlertPreview ? "btn_audio_content_preview_play" : "btn_audio_content_play")
.onTapGesture {
if isPlaying() {
contentPlayManager.pauseAudio()
} else {
contentPlayManager.startTimer = startTimer
contentPlayManager.stopTimer = stopTimer
contentPlayManager.playAudio(
contentId: audioContent.contentId,
title: audioContent.title,
nickname: audioContent.creator.nickname,
coverImage: audioContent.coverImageUrl,
contentUrl: audioContent.contentUrl,
isFree: audioContent.price <= 0,
isPreview: !audioContent.existOrdered && audioContent.price > 0
)
isShowPreviewAlert = true
}
}
}
}
VStack(alignment: .leading, spacing: 13.3) {
Spacer()