mirror of
https://code.eliotberriot.com/funkwhale/funkwhale.git
synced 2025-10-04 11:59:18 +02:00
Hide and remove uneeded canvas object generated for the player background
This commit is contained in:
parent
9fd52afe56
commit
df01f62b01
3 changed files with 8 additions and 0 deletions
|
@ -221,6 +221,7 @@ import { mapState, mapGetters, mapActions } from "vuex"
|
|||
import GlobalEvents from "@/components/utils/global-events"
|
||||
import ColorThief from "@/vendor/color-thief"
|
||||
import { Howl } from "howler"
|
||||
import $ from 'jquery'
|
||||
|
||||
import AudioTrack from "@/components/audio/Track"
|
||||
import TrackFavoriteIcon from "@/components/favorites/TrackFavoriteIcon"
|
||||
|
@ -310,6 +311,8 @@ export default {
|
|||
this.$refs.currentAudio.setCurrentTime(time)
|
||||
},
|
||||
updateBackground() {
|
||||
// delete existing canvas, if any
|
||||
$('canvas.color-thief').remove()
|
||||
if (!this.currentTrack.album.cover) {
|
||||
this.ambiantColors = this.defaultAmbiantColors
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue