mirror of
https://github.com/koel/koel
synced 2024-11-10 14:44:13 +00:00
Use computed for bio panel
This commit is contained in:
parent
f08f04f594
commit
6abc8431a4
1 changed files with 13 additions and 4 deletions
|
@ -12,11 +12,10 @@
|
|||
class="cool-guys-posing cover">
|
||||
|
||||
<div class="bio" v-if="artist.info.bio.summary">
|
||||
<div class="summary" v-show="mode !== 'full' && !showingFullBio" v-html="artist.info.bio.summary"/>
|
||||
<div class="full" v-show="mode === 'full' || showingFullBio" v-html="artist.info.bio.full"/>
|
||||
<div class="summary" v-show="showSummary" v-html="artist.info.bio.summary"/>
|
||||
<div class="full" v-show="showFull" v-html="artist.info.bio.full"/>
|
||||
|
||||
<button class="more" v-show="mode !== 'full' && !showingFullBio"
|
||||
@click.prevent="showingFullBio = !showingFullBio">
|
||||
<button class="more" v-show="showSummary" @click.prevent="showingFullBio = true">
|
||||
Full Bio
|
||||
</button>
|
||||
</div>
|
||||
|
@ -47,6 +46,16 @@ export default {
|
|||
},
|
||||
},
|
||||
|
||||
computed: {
|
||||
showSummary() {
|
||||
return this.mode !== 'full' && !this.showingFullBio;
|
||||
},
|
||||
|
||||
showFull() {
|
||||
return this.mode === 'full' || this.showingFullBio;
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
/**
|
||||
* Shuffle all songs performed by the current song's artist.
|
||||
|
|
Loading…
Reference in a new issue