Hide active subscriptions (#918)
* Update distraction-settings.js * Update side-nav.js * added hiding subscription activity * Update distraction-settings.js * Update distraction-settings.js * Update side-nav.js * Update side-nav.vue * Update distraction-settings.vue * Update settings.js * Update side-nav.vue * Update distraction-settings.js * Update en-US.yaml * Update en_GB.yaml * Update distraction-settings.js * Update settings.js * Update side-nav.vue * Update side-nav.vue * Update side-nav.vue Co-authored-by: Pablo <8d1d1de7-176f-4d40-b5f0-5a552aabd433@4wrd.cc>
This commit is contained in:
parent
0f03cbc739
commit
f65377127d
|
@ -39,6 +39,9 @@ export default Vue.extend({
|
||||||
},
|
},
|
||||||
hideLiveChat: function () {
|
hideLiveChat: function () {
|
||||||
return this.$store.getters.getHideLiveChat
|
return this.$store.getters.getHideLiveChat
|
||||||
|
},
|
||||||
|
hideActiveSubscriptions: function () {
|
||||||
|
return this.$store.getters.getHideActiveSubscriptions
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
@ -60,6 +63,7 @@ export default Vue.extend({
|
||||||
'updateHideTrendingVideos',
|
'updateHideTrendingVideos',
|
||||||
'updateHidePopularVideos',
|
'updateHidePopularVideos',
|
||||||
'updateHideLiveChat',
|
'updateHideLiveChat',
|
||||||
|
'updateHideActiveSubscriptions',
|
||||||
'updatePlayNextVideo',
|
'updatePlayNextVideo',
|
||||||
'updateDefaultTheatreMode'
|
'updateDefaultTheatreMode'
|
||||||
])
|
])
|
||||||
|
|
|
@ -33,6 +33,12 @@
|
||||||
:default-value="hideCommentLikes"
|
:default-value="hideCommentLikes"
|
||||||
@change="updateHideCommentLikes"
|
@change="updateHideCommentLikes"
|
||||||
/>
|
/>
|
||||||
|
<ft-toggle-switch
|
||||||
|
:label="$t('Settings.Distraction Free Settings.Hide Active Subscriptions')"
|
||||||
|
:compact="true"
|
||||||
|
:default-value="hideActiveSubscriptions"
|
||||||
|
@change="updateHideActiveSubscriptions"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div class="switchColumn">
|
<div class="switchColumn">
|
||||||
<ft-toggle-switch
|
<ft-toggle-switch
|
||||||
|
|
|
@ -50,6 +50,9 @@ export default Vue.extend({
|
||||||
},
|
},
|
||||||
hideTrendingVideos: function () {
|
hideTrendingVideos: function () {
|
||||||
return this.$store.getters.getHideTrendingVideos
|
return this.$store.getters.getHideTrendingVideos
|
||||||
|
},
|
||||||
|
hideActiveSubscriptions: function () {
|
||||||
|
return this.$store.getters.getHideActiveSubscriptions
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
|
@ -97,26 +97,30 @@
|
||||||
</div>
|
</div>
|
||||||
<hr>
|
<hr>
|
||||||
<div
|
<div
|
||||||
v-for="(channel, index) in activeSubscriptions"
|
v-if="!hideActiveSubscriptions"
|
||||||
:key="index"
|
|
||||||
class="navChannel mobileHidden"
|
|
||||||
:title="channel.name"
|
|
||||||
@click="goToChannel(channel.id)"
|
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
class="thumbnailContainer"
|
v-for="(channel, index) in activeSubscriptions"
|
||||||
|
:key="index"
|
||||||
|
class="navChannel mobileHidden"
|
||||||
|
:title="channel.name"
|
||||||
|
@click="goToChannel(channel.id)"
|
||||||
>
|
>
|
||||||
<img
|
<div
|
||||||
class="channelThumbnail"
|
class="thumbnailContainer"
|
||||||
:src="channel.thumbnail"
|
|
||||||
>
|
>
|
||||||
|
<img
|
||||||
|
class="channelThumbnail"
|
||||||
|
:src="channel.thumbnail"
|
||||||
|
>
|
||||||
|
</div>
|
||||||
|
<p
|
||||||
|
v-if="isOpen"
|
||||||
|
class="navLabel"
|
||||||
|
>
|
||||||
|
{{ channel.name }}
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<p
|
|
||||||
v-if="isOpen"
|
|
||||||
class="navLabel"
|
|
||||||
>
|
|
||||||
{{ channel.name }}
|
|
||||||
</p>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</ft-flex-box>
|
</ft-flex-box>
|
||||||
|
|
|
@ -71,7 +71,8 @@ const state = {
|
||||||
hideRecommendedVideos: false,
|
hideRecommendedVideos: false,
|
||||||
hideTrendingVideos: false,
|
hideTrendingVideos: false,
|
||||||
hidePopularVideos: false,
|
hidePopularVideos: false,
|
||||||
hideLiveChat: false
|
hideLiveChat: false,
|
||||||
|
hideActiveSubscriptions: false
|
||||||
}
|
}
|
||||||
|
|
||||||
const getters = {
|
const getters = {
|
||||||
|
@ -224,6 +225,9 @@ const getters = {
|
||||||
},
|
},
|
||||||
getHideLiveChat: () => {
|
getHideLiveChat: () => {
|
||||||
return state.hideLiveChat
|
return state.hideLiveChat
|
||||||
|
},
|
||||||
|
getHideActiveSubscriptions: () => {
|
||||||
|
return state.hideActiveSubscriptions
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -351,6 +355,9 @@ const actions = {
|
||||||
case 'hideLiveChat':
|
case 'hideLiveChat':
|
||||||
commit('setHideLiveChat', result.value)
|
commit('setHideLiveChat', result.value)
|
||||||
break
|
break
|
||||||
|
case 'hideActiveSubscriptions':
|
||||||
|
commit('setHideActiveSubscriptions', result.value)
|
||||||
|
break
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -655,6 +662,14 @@ const actions = {
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
updateHideActiveSubscriptions ({ commit }, hideActiveSubscriptions) {
|
||||||
|
settingsDb.update({ _id: 'hideActiveSubscriptions' }, { _id: 'hideActiveSubscriptions', value: hideActiveSubscriptions }, { upsert: true }, (err, numReplaced) => {
|
||||||
|
if (!err) {
|
||||||
|
commit('setHideActiveSubscriptions', hideActiveSubscriptions)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
updateHideLiveChat ({ commit }, hideLiveChat) {
|
updateHideLiveChat ({ commit }, hideLiveChat) {
|
||||||
settingsDb.update({ _id: 'hideLiveChat' }, { _id: 'hideLiveChat', value: hideLiveChat }, { upsert: true }, (err, numReplaced) => {
|
settingsDb.update({ _id: 'hideLiveChat' }, { _id: 'hideLiveChat', value: hideLiveChat }, { upsert: true }, (err, numReplaced) => {
|
||||||
if (!err) {
|
if (!err) {
|
||||||
|
@ -796,6 +811,9 @@ const mutations = {
|
||||||
},
|
},
|
||||||
setHideLiveChat (state, hideLiveChat) {
|
setHideLiveChat (state, hideLiveChat) {
|
||||||
state.hideLiveChat = hideLiveChat
|
state.hideLiveChat = hideLiveChat
|
||||||
|
},
|
||||||
|
setHideActiveSubscriptions (state, hideActiveSubscriptions) {
|
||||||
|
state.hideActiveSubscriptions = hideActiveSubscriptions
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -213,6 +213,7 @@ Settings:
|
||||||
Hide Trending Videos: Hide Trending Videos
|
Hide Trending Videos: Hide Trending Videos
|
||||||
Hide Popular Videos: Hide Popular Videos
|
Hide Popular Videos: Hide Popular Videos
|
||||||
Hide Live Chat: Hide Live Chat
|
Hide Live Chat: Hide Live Chat
|
||||||
|
Hide Active Subscriptions: Hide Active Subscriptions
|
||||||
Data Settings:
|
Data Settings:
|
||||||
Data Settings: Data Settings
|
Data Settings: Data Settings
|
||||||
Select Import Type: Select Import Type
|
Select Import Type: Select Import Type
|
||||||
|
|
|
@ -275,6 +275,7 @@ Settings:
|
||||||
Hide Channel Subscribers: Hide Channel Subscribers
|
Hide Channel Subscribers: Hide Channel Subscribers
|
||||||
Hide Video Likes And Dislikes: Hide Video Likes And Dislikes
|
Hide Video Likes And Dislikes: Hide Video Likes And Dislikes
|
||||||
Hide Video Views: Hide Video Views
|
Hide Video Views: Hide Video Views
|
||||||
|
Hide Active Subscriptions: Hide Active Subscriptions
|
||||||
Distraction Free Settings: Distraction Free Settings
|
Distraction Free Settings: Distraction Free Settings
|
||||||
The app needs to restart for changes to take effect. Restart and apply change?: The
|
The app needs to restart for changes to take effect. Restart and apply change?: The
|
||||||
app needs to restart for changes to take effect. Do you want to restart and apply
|
app needs to restart for changes to take effect. Do you want to restart and apply
|
||||||
|
|
Loading…
Reference in New Issue