Show different message if Upcoming text isn't available. Assume premiere date has passed
This commit is contained in:
parent
4f04eb7640
commit
8de0c5fef0
|
@ -281,8 +281,14 @@ export default Vue.extend({
|
||||||
this.activeSourceList = this.videoSourceList
|
this.activeSourceList = this.videoSourceList
|
||||||
}
|
}
|
||||||
} else if (this.isUpcoming) {
|
} else if (this.isUpcoming) {
|
||||||
const upcomingTimestamp = new Date(result.videoDetails.liveBroadcastDetails.startTimestamp)
|
const startTimestamp = result.videoDetails.liveBroadcastDetails.startTimestamp
|
||||||
this.upcomingTimestamp = upcomingTimestamp.toLocaleString()
|
|
||||||
|
if (typeof startTimestamp !== 'undefined') {
|
||||||
|
const upcomingTimestamp = new Date(result.videoDetails.liveBroadcastDetails.startTimestamp)
|
||||||
|
this.upcomingTimestamp = upcomingTimestamp.toLocaleString()
|
||||||
|
} else {
|
||||||
|
this.upcomingTimestamp = null
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
this.videoLengthSeconds = parseInt(result.videoDetails.lengthSeconds)
|
this.videoLengthSeconds = parseInt(result.videoDetails.lengthSeconds)
|
||||||
this.videoSourceList = result.player_response.streamingData.formats.reverse()
|
this.videoSourceList = result.player_response.streamingData.formats.reverse()
|
||||||
|
@ -672,7 +678,7 @@ export default Vue.extend({
|
||||||
handleRouteChange: function () {
|
handleRouteChange: function () {
|
||||||
clearTimeout(this.playNextTimeout)
|
clearTimeout(this.playNextTimeout)
|
||||||
|
|
||||||
if (this.rememberHistory && !this.isLoading && !this.isLive) {
|
if (this.rememberHistory && !this.isUpcoming && !this.isLoading && !this.isLive) {
|
||||||
const player = this.$refs.videoPlayer.player
|
const player = this.$refs.videoPlayer.player
|
||||||
|
|
||||||
if (player !== null && this.saveWatchedProgress) {
|
if (player !== null && this.saveWatchedProgress) {
|
||||||
|
|
|
@ -43,12 +43,19 @@
|
||||||
class="premiereIcon"
|
class="premiereIcon"
|
||||||
/>
|
/>
|
||||||
<p
|
<p
|
||||||
|
v-if="upcomingTimestamp !== null"
|
||||||
class="premiereText"
|
class="premiereText"
|
||||||
>
|
>
|
||||||
Premieres on:
|
Premieres on:
|
||||||
<br>
|
<br>
|
||||||
{{ upcomingTimestamp }}
|
{{ upcomingTimestamp }}
|
||||||
</p>
|
</p>
|
||||||
|
<p
|
||||||
|
v-else
|
||||||
|
class="premiereText"
|
||||||
|
>
|
||||||
|
{{ $t("Video.Starting soon, please refresh the page to check again") }}
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -377,6 +377,7 @@ Video:
|
||||||
Watching: Watching
|
Watching: Watching
|
||||||
Watched: Watched
|
Watched: Watched
|
||||||
Autoplay: Autoplay
|
Autoplay: Autoplay
|
||||||
|
Starting soon, please refresh the page to check again: Starting soon, please refresh the page to check again
|
||||||
# As in a Live Video
|
# As in a Live Video
|
||||||
Live: Live
|
Live: Live
|
||||||
Live Now: Live Now
|
Live Now: Live Now
|
||||||
|
|
Loading…
Reference in New Issue