Added check for missing preview tracks
This commit is contained in:
parent
76afeb2c17
commit
2b8801d49a
@ -79,6 +79,10 @@ img.circle {
|
|||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
i.disabled {
|
||||||
|
opacity: 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
span.tag {
|
span.tag {
|
||||||
background-color: var(--tag-background);
|
background-color: var(--tag-background);
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
|
@ -1000,9 +1000,12 @@ <h2 class="inline-flex"><span v-if="metadata">{{ metadata }}</span><span class="
|
|||||||
<template v-if="type!='Spotify Playlist'">
|
<template v-if="type!='Spotify Playlist'">
|
||||||
<template v-for="track in body">
|
<template v-for="track in body">
|
||||||
<tr v-if="track.type == 'track'">
|
<tr v-if="track.type == 'track'">
|
||||||
<td><i @click=playPausePreview
|
<td>
|
||||||
:class="'material-icons' + (track.preview ? ' preview_playlist_controls' : '')"
|
<i v-if="track.preview" @click=playPausePreview
|
||||||
:data-preview="track.preview">play_arrow</i></td>
|
:class="'material-icons' + (track.preview ? ' preview_playlist_controls' : '')"
|
||||||
|
:data-preview="track.preview">play_arrow</i>
|
||||||
|
<i v-else class="material-icons disabled">play_arrow</i>
|
||||||
|
</td>
|
||||||
<td>{{ track.track_position }}</td>
|
<td>{{ track.track_position }}</td>
|
||||||
<td class="inline-flex"><i v-if="track.explicit_lyrics"
|
<td class="inline-flex"><i v-if="track.explicit_lyrics"
|
||||||
class="material-icons">explicit</i>{{ track.title + (track.title_version && track.title.indexOf(track.title_version) == -1 ? ' '+ track.title_version : '') }}
|
class="material-icons">explicit</i>{{ track.title + (track.title_version && track.title.indexOf(track.title_version) == -1 ? ' '+ track.title_version : '') }}
|
||||||
@ -1022,9 +1025,11 @@ <h2 class="inline-flex"><span v-if="metadata">{{ metadata }}</span><span class="
|
|||||||
</template>
|
</template>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<tr v-for="(track, i) in body">
|
<tr v-for="(track, i) in body">
|
||||||
<td><i @click=playPausePreview
|
<td>
|
||||||
:class="'material-icons' + (track.preview_url ? ' preview_playlist_controls' : '')"
|
<i v-if="track.preview_url" @click=playPausePreview
|
||||||
:data-preview="track.preview_url">play_arrow</i></td>
|
:class="'material-icons' + (track.preview_url ? ' preview_playlist_controls' : '')"
|
||||||
|
:data-preview="track.preview_url">play_arrow</i></td>
|
||||||
|
<i v-else class="material-icons disabled">play_arrow</i>
|
||||||
<td>{{ i+1 }}</td>
|
<td>{{ i+1 }}</td>
|
||||||
<td class="inline-flex"><i v-if="track.explicit"
|
<td class="inline-flex"><i v-if="track.explicit"
|
||||||
class="material-icons">explicit</i>{{ track.name }}
|
class="material-icons">explicit</i>{{ track.name }}
|
||||||
@ -1083,4 +1088,4 @@ <h2 class="inline-flex"><span v-if="metadata">{{ metadata }}</span><span class="
|
|||||||
|
|
||||||
<script src="/public/js/bundle.js"></script>
|
<script src="/public/js/bundle.js"></script>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
|
Loading…
Reference in New Issue
Block a user