profile page (for search for now)

This commit is contained in:
vapormusic 2022-07-11 18:21:26 +07:00
parent 123c6bc4d6
commit 6dd0c141bf
5 changed files with 44 additions and 42 deletions

View file

@ -1,5 +1,5 @@
<script type="text/x-template" id="cider-recordlabel">
<div class="content-inner profile-page">
<script type="text/x-template" id="cider-socialprofile">
<div class="content-inner artist-page profile-page">
<div class="artist-header" :style="getArtistPalette(data)">
<div class="row">
<div class="col-sm" style="width: auto;">
@ -10,56 +10,30 @@
size="220" type="artists"></mediaitem-artwork>
</div>
</div>
<div class="col flex-center"
>
<h1>{{ data.attributes.name }}</h1> -
<div class="col flex-center">
<h1>{{ data.attributes.name }}</h1>
</div>
</div>
</div>
<div class="artist-body">
<template v-if="data.views && data.views['latest-releases']">
<template v-if="data.relationships && data.relationships['shared-playlists']">
<div class="row">
<div class="col">
<h3>{{ data.views["latest-releases"].attributes.title ?? ""}}</h3>
<h3>{{ 'Shared Playlists' ?? ""}}</h3>
</div>
<div class="col-auto flex-center" v-if="data.views['latest-releases'].data.length >= 10">
<button class="cd-btn-seeall" @click="app.showRecordLabelView(data.id, data.attributes.name + ' - Latest Releases', 'latest-releases')">{{app.getLz('term.seeAll')}}</button>
<div class="col-auto flex-center" v-if="data.relationships['shared-playlists'].data.length >= 10">
<button class="cd-btn-seeall" @click="app.showCollection(data.relationships['shared-playlists'],'Shared Playlists' ?? '', 'default')">{{app.getLz('term.seeAll')}}</button>
</div>
</div>
<mediaitem-square :item="item" v-for="item in data.views['latest-releases'].data">
</mediaitem-square>
</template>
<template v-if="data.views && data.views['top-releases']">
<div class="row">
<div class="col">
<h3>{{ data.views["top-releases"].attributes.title ?? ""}}</h3>
</div>
<div class="col-auto flex-center" v-if="data.views['top-releases'].data.length >= 10">
<button class="cd-btn-seeall" @click="app.showRecordLabelView(data.id, data.attributes.name + ' - Top Releases', 'top-releases')">{{app.getLz('term.seeAll')}}</button>
</div>
</div>
<mediaitem-square :item="item" v-for="item in data.views['top-releases'].data">
</mediaitem-square>
</template>
<template v-if="data.relationships && data.relationships.playlists && data.relationships.playlists.data.length > 0">
<div class="row">
<div class="col">
<h3>Playlists</h3>
</div>
<div class="col-auto flex-center" v-if="data.relationships.playlists.data.length >= 5">
<button class="cd-btn-seeall" @click="app.showCollection(data.relationships.playlists, data.attributes.name + ' - Playlists', 'curator')">{{app.getLz('term.seeAll')}}</button>
</div>
</div>
<mediaitem-square :item="item" v-for="item in data.relationships.playlists.data.limit(5)">
<mediaitem-square :item="item" v-for="item in data.relationships['shared-playlists'].data.limit(10)">
</mediaitem-square>
</template>
</div>
</div>
</script>
<script>
Vue.component('cider-recordlabel', {
template: "#cider-recordlabel",
Vue.component('cider-socialprofile', {
template: "#cider-socialprofile",
props: ['data'],
data: function () {
return {