Add better information to media notifications
This commit is contained in:
parent
d82e89e982
commit
3d5ccdc4dc
|
@ -90,6 +90,10 @@ export default Vue.extend({
|
|||
lengthSeconds: {
|
||||
type: Number,
|
||||
required: true
|
||||
},
|
||||
videoThumbnail: {
|
||||
type: String,
|
||||
required: true
|
||||
}
|
||||
},
|
||||
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: {
|
||||
goToChannel: function () {
|
||||
this.$router.push({ path: `/channel/${this.channelId}` })
|
||||
|
|
|
@ -82,6 +82,7 @@
|
|||
:watching-playlist="watchingPlaylist"
|
||||
:theatre-possible="theatrePossible"
|
||||
:length-seconds="videoLengthSeconds"
|
||||
:video-thumbnail="thumbnail"
|
||||
class="watchVideo"
|
||||
:class="{ theatreWatchVideo: useTheatreMode }"
|
||||
@theatre-mode="toggleTheatreMode"
|
||||
|
|
Loading…
Reference in New Issue