aboutsummaryrefslogtreecommitdiff
path: root/src/components/settings/settings.js
diff options
context:
space:
mode:
authorlambda <pleromagit@rogerbraun.net>2019-01-30 18:58:08 +0000
committerlambda <pleromagit@rogerbraun.net>2019-01-30 18:58:08 +0000
commit5b7b1dfebc37bd5db4e839973062b452b02c898d (patch)
treea517e4942725286b173b685cbe87bc6c7878b66e /src/components/settings/settings.js
parentb1facdf7ad54436c2afde7c28c917cda87a5b7e3 (diff)
parentc7cffbb6c70bbb21cf787d96e82e0261427b9234 (diff)
Merge branch 'feat/media-modal' into 'develop'
modal for viewing attachments in-tab See merge request pleroma/pleroma-fe!468
Diffstat (limited to 'src/components/settings/settings.js')
-rw-r--r--src/components/settings/settings.js16
1 files changed, 14 insertions, 2 deletions
diff --git a/src/components/settings/settings.js b/src/components/settings/settings.js
index d45ec72d..06011e7c 100644
--- a/src/components/settings/settings.js
+++ b/src/components/settings/settings.js
@@ -13,6 +13,7 @@ const settings = {
hideAttachmentsLocal: user.hideAttachments,
hideAttachmentsInConvLocal: user.hideAttachmentsInConv,
hideNsfwLocal: user.hideNsfw,
+ useOneClickNsfw: user.useOneClickNsfw,
hideISPLocal: user.hideISP,
preloadImage: user.preloadImage,
@@ -29,7 +30,6 @@ const settings = {
notificationVisibilityLocal: user.notificationVisibility,
replyVisibilityLocal: user.replyVisibility,
loopVideoLocal: user.loopVideo,
- loopVideoSilentOnlyLocal: user.loopVideoSilentOnly,
muteWordsString: user.muteWords.join('\n'),
autoLoadLocal: user.autoLoad,
streamingLocal: user.streaming,
@@ -58,13 +58,16 @@ const settings = {
stopGifs: user.stopGifs,
webPushNotificationsLocal: user.webPushNotifications,
+ loopVideoSilentOnlyLocal: user.loopVideosSilentOnly,
loopSilentAvailable:
// Firefox
Object.getOwnPropertyDescriptor(HTMLVideoElement.prototype, 'mozHasAudio') ||
// Chrome-likes
Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype, 'webkitAudioDecodedByteCount') ||
// Future spec, still not supported in Nightly 63 as of 08/2018
- Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype, 'audioTracks')
+ Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype, 'audioTracks'),
+ playVideosInline: user.playVideosInline,
+ useContainFit: user.useContainFit
}
},
components: {
@@ -96,6 +99,9 @@ const settings = {
hideNsfwLocal (value) {
this.$store.dispatch('setOption', { name: 'hideNsfw', value })
},
+ useOneClickNsfw (value) {
+ this.$store.dispatch('setOption', { name: 'useOneClickNsfw', value })
+ },
preloadImage (value) {
this.$store.dispatch('setOption', { name: 'preloadImage', value })
},
@@ -157,6 +163,12 @@ const settings = {
webPushNotificationsLocal (value) {
this.$store.dispatch('setOption', { name: 'webPushNotifications', value })
if (value) this.$store.dispatch('registerPushNotifications')
+ },
+ playVideosInline (value) {
+ this.$store.dispatch('setOption', { name: 'playVideosInline', value })
+ },
+ useContainFit (value) {
+ this.$store.dispatch('setOption', { name: 'useContainFit', value })
}
}
}