[web] Remove useless getters of the store

This commit is contained in:
Alain Nussbaumer 2024-02-21 12:29:16 +01:00
parent bb43de465f
commit 3cadee1d48
4 changed files with 3 additions and 7 deletions

View File

@ -100,7 +100,7 @@ export default {
} }
}, },
lyrics() { lyrics() {
const raw = this.$store.getters.lyrics const raw = this.$store.state.lyrics.content
const parsed = [] const parsed = []
if (raw) { if (raw) {
// Parse the lyrics // Parse the lyrics

View File

@ -22,7 +22,7 @@ export default {
computed: { computed: {
is_active() { is_active() {
return this.$store.getters.lyrics_pane return this.$store.state.lyrics.pane
}, },
icon_name() { icon_name() {
return this.is_active ? 'script-text-play' : 'script-text-outline' return this.is_active ? 'script-text-play' : 'script-text-outline'

View File

@ -91,7 +91,7 @@ export default {
}, },
lyrics_visible() { lyrics_visible() {
return this.$store.getters.lyrics_pane return this.$store.state.lyrics.pane
}, },
player() { player() {

View File

@ -70,10 +70,6 @@ export default createStore({
}, },
getters: { getters: {
lyrics: (state) => state.lyrics.content,
lyrics_pane: (state) => state.lyrics.pane,
now_playing: (state) => { now_playing: (state) => {
const item = state.queue.items.find((e) => e.id === state.player.item_id) const item = state.queue.items.find((e) => e.id === state.player.item_id)
return item === undefined ? {} : item return item === undefined ? {} : item