Add better information to media notifications
This commit is contained in:
parent
d82e89e982
commit
3d5ccdc4dc
|
@ -90,6 +90,10 @@ export default Vue.extend({
|
||||||
lengthSeconds: {
|
lengthSeconds: {
|
||||||
type: Number,
|
type: Number,
|
||||||
required: true
|
required: true
|
||||||
|
},
|
||||||
|
videoThumbnail: {
|
||||||
|
type: String,
|
||||||
|
required: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data: function () {
|
data: function () {
|
||||||
|
@ -223,6 +227,14 @@ export default Vue.extend({
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
mounted: function () {
|
||||||
|
/* eslint-disable-next-line */
|
||||||
|
navigator.mediaSession.metadata = new MediaMetadata({
|
||||||
|
title: this.title,
|
||||||
|
artist: this.channelName,
|
||||||
|
artwork: this.videoThumbnail
|
||||||
|
})
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
goToChannel: function () {
|
goToChannel: function () {
|
||||||
this.$router.push({ path: `/channel/${this.channelId}` })
|
this.$router.push({ path: `/channel/${this.channelId}` })
|
||||||
|
|
|
@ -82,6 +82,7 @@
|
||||||
:watching-playlist="watchingPlaylist"
|
:watching-playlist="watchingPlaylist"
|
||||||
:theatre-possible="theatrePossible"
|
:theatre-possible="theatrePossible"
|
||||||
:length-seconds="videoLengthSeconds"
|
:length-seconds="videoLengthSeconds"
|
||||||
|
:video-thumbnail="thumbnail"
|
||||||
class="watchVideo"
|
class="watchVideo"
|
||||||
:class="{ theatreWatchVideo: useTheatreMode }"
|
:class="{ theatreWatchVideo: useTheatreMode }"
|
||||||
@theatre-mode="toggleTheatreMode"
|
@theatre-mode="toggleTheatreMode"
|
||||||
|
|
Loading…
Reference in New Issue