mirror of https://github.com/FreeTubeApp/FreeTube
Update to use listType setting for user playlist display type
This commit is contained in:
parent
db4b49f3a6
commit
1b65a7c298
|
@ -115,9 +115,6 @@ export default defineComponent({
|
|||
listType: function () {
|
||||
return this.$store.getters.getListType
|
||||
},
|
||||
userPlaylistListType: function () {
|
||||
return this.$store.getters.getUserPlaylistListType
|
||||
},
|
||||
thumbnailPreference: function () {
|
||||
return this.blurThumbnails ? 'blur' : this.$store.getters.getThumbnailPreference
|
||||
},
|
||||
|
@ -256,7 +253,6 @@ export default defineComponent({
|
|||
'updateLandingPage',
|
||||
'updateRegion',
|
||||
'updateListType',
|
||||
'updateUserPlaylistListType',
|
||||
'updateThumbnailPreference',
|
||||
'updateForceLocalBackendForLegacy',
|
||||
'updateCurrentLocale',
|
||||
|
|
|
@ -56,13 +56,6 @@
|
|||
:select-values="viewTypeValues"
|
||||
@change="updateListType"
|
||||
/>
|
||||
<ft-select
|
||||
:placeholder="$t('Settings.General Settings.User Playlist View Type')"
|
||||
:value="userPlaylistListType"
|
||||
:select-names="viewTypeNames"
|
||||
:select-values="viewTypeValues"
|
||||
@change="updateUserPlaylistListType"
|
||||
/>
|
||||
<ft-select
|
||||
:placeholder="$t('Settings.General Settings.Thumbnail Preference.Thumbnail Preference')"
|
||||
:value="thumbnailPreference"
|
||||
|
|
|
@ -231,7 +231,6 @@ const state = {
|
|||
showDistractionFreeTitles: false,
|
||||
landingPage: 'subscriptions',
|
||||
listType: 'grid',
|
||||
userPlaylistListType: 'grid',
|
||||
maxVideoPlaybackRate: 3,
|
||||
onlyShowLatestFromChannel: false,
|
||||
playNextVideo: false,
|
||||
|
|
|
@ -84,11 +84,8 @@ export default defineComponent({
|
|||
playlistId: function() {
|
||||
return this.$route.params.id
|
||||
},
|
||||
userPlaylistListType: function () {
|
||||
return this.$store.getters.getUserPlaylistListType
|
||||
},
|
||||
listType: function () {
|
||||
return this.isUserPlaylistRequested ? this.userPlaylistListType : 'list'
|
||||
return this.isUserPlaylistRequested ? this.$store.getters.getListType : 'list'
|
||||
},
|
||||
userPlaylistsReady: function () {
|
||||
return this.$store.getters.getPlaylistsReady
|
||||
|
|
|
@ -10,38 +10,38 @@
|
|||
|
||||
<div class="playlistInfoContainer">
|
||||
<playlist-info
|
||||
v-if="!isLoading"
|
||||
:id="playlistId"
|
||||
:first-video-id="firstVideoId"
|
||||
:first-video-playlist-item-id="firstVideoPlaylistItemId"
|
||||
:playlist-thumbnail="playlistThumbnail"
|
||||
:title="playlistTitle"
|
||||
:channel-name="channelName"
|
||||
:channel-thumbnail="channelThumbnail"
|
||||
:channel-id="channelId"
|
||||
:last-updated="lastUpdated"
|
||||
:description="playlistDescription"
|
||||
:video-count="videoCount"
|
||||
:videos="playlistItems"
|
||||
:view-count="viewCount"
|
||||
:info-source="infoSource"
|
||||
:theme="listType === 'list' ? 'base' : 'top-bar'"
|
||||
:more-video-data-available="moreVideoDataAvailable"
|
||||
:search-video-mode-allowed="searchVideoModeAllowed"
|
||||
:search-video-mode-enabled="playlistInVideoSearchMode"
|
||||
:search-query-text="searchQueryTextRequested"
|
||||
class="playlistInfo"
|
||||
:class="{
|
||||
promptOpen,
|
||||
}"
|
||||
@enter-edit-mode="playlistInEditMode = true"
|
||||
@exit-edit-mode="playlistInEditMode = false"
|
||||
@search-video-mode-on="playlistInVideoSearchMode = true"
|
||||
@search-video-mode-off="playlistInVideoSearchMode = false"
|
||||
@search-video-query-change="(v) => videoSearchQuery = v"
|
||||
@prompt-open="promptOpen = true"
|
||||
@prompt-close="promptOpen = false"
|
||||
/>
|
||||
v-if="!isLoading"
|
||||
:id="playlistId"
|
||||
:first-video-id="firstVideoId"
|
||||
:first-video-playlist-item-id="firstVideoPlaylistItemId"
|
||||
:playlist-thumbnail="playlistThumbnail"
|
||||
:title="playlistTitle"
|
||||
:channel-name="channelName"
|
||||
:channel-thumbnail="channelThumbnail"
|
||||
:channel-id="channelId"
|
||||
:last-updated="lastUpdated"
|
||||
:description="playlistDescription"
|
||||
:video-count="videoCount"
|
||||
:videos="playlistItems"
|
||||
:view-count="viewCount"
|
||||
:info-source="infoSource"
|
||||
:theme="listType === 'list' ? 'base' : 'top-bar'"
|
||||
:more-video-data-available="moreVideoDataAvailable"
|
||||
:search-video-mode-allowed="searchVideoModeAllowed"
|
||||
:search-video-mode-enabled="playlistInVideoSearchMode"
|
||||
:search-query-text="searchQueryTextRequested"
|
||||
class="playlistInfo"
|
||||
:class="{
|
||||
promptOpen,
|
||||
}"
|
||||
@enter-edit-mode="playlistInEditMode = true"
|
||||
@exit-edit-mode="playlistInEditMode = false"
|
||||
@search-video-mode-on="playlistInVideoSearchMode = true"
|
||||
@search-video-mode-off="playlistInVideoSearchMode = false"
|
||||
@search-video-query-change="(v) => videoSearchQuery = v"
|
||||
@prompt-open="promptOpen = true"
|
||||
@prompt-close="promptOpen = false"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<ft-card
|
||||
|
@ -55,9 +55,9 @@
|
|||
v-if="visiblePlaylistItems.length > 0"
|
||||
>
|
||||
<ft-element-list
|
||||
v-if="userPlaylistListType === 'grid'"
|
||||
v-if="listType === 'grid'"
|
||||
:data="visiblePlaylistItems"
|
||||
:display="userPlaylistListType"
|
||||
display="grid"
|
||||
:show-video-with-last-viewed-playlist="true"
|
||||
:use-channels-hidden-preference="false"
|
||||
:hide-forbidden-titles="false"
|
||||
|
|
Loading…
Reference in New Issue