diff --git a/src/components/notification/notification.vue b/src/components/notification/notification.vue index 1c89cbb7..56791d45 100644 --- a/src/components/notification/notification.vue +++ b/src/components/notification/notification.vue @@ -33,10 +33,7 @@ diff --git a/src/components/notifications/notifications.scss b/src/components/notifications/notifications.scss index a6468e01..5c4ca1b9 100644 --- a/src/components/notifications/notifications.scss +++ b/src/components/notifications/notifications.scss @@ -36,16 +36,6 @@ border-color: $fallback--border; border-color: var(--border, $fallback--border); - .broken-favorite { - border-radius: $fallback--tooltipRadius; - border-radius: var(--tooltipRadius, $fallback--tooltipRadius); - color: $fallback--text; - color: var(--alertErrorText, $fallback--text); - background-color: $fallback--alertError; - background-color: var(--alertError, $fallback--alertError); - padding: 2px .5em - } - .avatar-compact { width: 32px; height: 32px; diff --git a/src/components/post_status_form/post_status_form.js b/src/components/post_status_form/post_status_form.js index 0ce2aff0..89091f8e 100644 --- a/src/components/post_status_form/post_status_form.js +++ b/src/components/post_status_form/post_status_form.js @@ -41,12 +41,16 @@ const PostStatusForm = { const preset = this.$route.query.message let statusText = preset || '' + const scopeCopy = typeof this.$store.state.config.scopeCopy === 'undefined' + ? this.$store.state.instance.scopeCopy + : this.$store.state.config.scopeCopy + if (this.replyTo) { const currentUser = this.$store.state.users.currentUser statusText = buildMentionsString({ user: this.repliedUser, attentions: this.attentions }, currentUser) } - const scope = (this.copyMessageScope && this.$store.state.config.scopeCopy || this.copyMessageScope === 'direct') + const scope = (this.copyMessageScope && scopeCopy || this.copyMessageScope === 'direct') ? this.copyMessageScope : this.$store.state.users.currentUser.default_scope diff --git a/src/components/registration/registration.js b/src/components/registration/registration.js index 65b2fb9b..dd8e6e5d 100644 --- a/src/components/registration/registration.js +++ b/src/components/registration/registration.js @@ -48,8 +48,10 @@ const registration = { async submit () { this.user.nickname = this.user.username this.user.token = this.token + this.user.captcha_solution = this.captcha.solution this.user.captcha_token = this.captcha.token + this.user.captcha_answer_data = this.captcha.answer_data this.$v.$touch() diff --git a/src/components/registration/registration.vue b/src/components/registration/registration.vue index f187e215..1455354e 100644 --- a/src/components/registration/registration.vue +++ b/src/components/registration/registration.vue @@ -76,15 +76,16 @@
+ +
diff --git a/src/components/settings/settings.js b/src/components/settings/settings.js index 681ccda8..d45ec72d 100644 --- a/src/components/settings/settings.js +++ b/src/components/settings/settings.js @@ -15,14 +15,17 @@ const settings = { hideNsfwLocal: user.hideNsfw, hideISPLocal: user.hideISP, preloadImage: user.preloadImage, + hidePostStatsLocal: typeof user.hidePostStats === 'undefined' ? instance.hidePostStats : user.hidePostStats, hidePostStatsDefault: this.$t('settings.values.' + instance.hidePostStats), + hideUserStatsLocal: typeof user.hideUserStats === 'undefined' ? instance.hideUserStats : user.hideUserStats, hideUserStatsDefault: this.$t('settings.values.' + instance.hideUserStats), + notificationVisibilityLocal: user.notificationVisibility, replyVisibilityLocal: user.replyVisibility, loopVideoLocal: user.loopVideo, @@ -32,20 +35,27 @@ const settings = { streamingLocal: user.streaming, pauseOnUnfocusedLocal: user.pauseOnUnfocused, hoverPreviewLocal: user.hoverPreview, + collapseMessageWithSubjectLocal: typeof user.collapseMessageWithSubject === 'undefined' ? instance.collapseMessageWithSubject : user.collapseMessageWithSubject, collapseMessageWithSubjectDefault: this.$t('settings.values.' + instance.collapseMessageWithSubject), + subjectLineBehaviorLocal: typeof user.subjectLineBehavior === 'undefined' ? instance.subjectLineBehavior : user.subjectLineBehavior, subjectLineBehaviorDefault: instance.subjectLineBehavior, + alwaysShowSubjectInputLocal: typeof user.alwaysShowSubjectInput === 'undefined' ? instance.alwaysShowSubjectInput : user.alwaysShowSubjectInput, alwaysShowSubjectInputDefault: instance.alwaysShowSubjectInput, - scopeCopyLocal: user.scopeCopy, + + scopeCopyLocal: typeof user.scopeCopy === 'undefined' + ? instance.scopeCopy + : user.scopeCopy, scopeCopyDefault: this.$t('settings.values.' + instance.scopeCopy), + stopGifs: user.stopGifs, webPushNotificationsLocal: user.webPushNotifications, loopSilentAvailable: diff --git a/src/components/status/status.js b/src/components/status/status.js index 47a62fdf..e683056f 100644 --- a/src/components/status/status.js +++ b/src/components/status/status.js @@ -188,7 +188,9 @@ const Status = { }, replySubject () { if (!this.status.summary) return '' - const behavior = this.$store.state.config.subjectLineBehavior + const behavior = typeof this.$store.state.config.subjectLineBehavior === 'undefined' + ? this.$store.state.instance.subjectLineBehavior + : this.$store.state.config.subjectLineBehavior const startsWithRe = this.status.summary.match(/^re[: ]/i) if (behavior !== 'noop' && startsWithRe || behavior === 'masto') { return this.status.summary diff --git a/src/components/user_profile/user_profile.js b/src/components/user_profile/user_profile.js index d8d0c532..77bb1835 100644 --- a/src/components/user_profile/user_profile.js +++ b/src/components/user_profile/user_profile.js @@ -18,18 +18,24 @@ const UserProfile = { return this.$store.state.statuses.timelines.user }, userId () { - return this.$route.params.id + return this.$route.params.id || this.user.id }, userName () { return this.$route.params.name }, + friends () { + return this.user.friends + }, + followers () { + return this.user.followers + }, user () { if (this.timeline.statuses[0]) { return this.timeline.statuses[0].user } else { return Object.values(this.$store.state.users.usersObject).filter(user => { return (this.isExternal ? user.id === this.userId : user.screen_name === this.userName) - })[0] || false + })[0] || {} } }, fetchBy () { @@ -67,7 +73,7 @@ const UserProfile = { this.$store.dispatch('startFetching', ['user', this.userId]) }, user () { - if (!this.user.followers) { + if (this.user.id && !this.user.followers) { this.fetchFollowers() this.fetchFriends() } diff --git a/src/components/user_profile/user_profile.vue b/src/components/user_profile/user_profile.vue index 5c823b3d..84fdba45 100644 --- a/src/components/user_profile/user_profile.vue +++ b/src/components/user_profile/user_profile.vue @@ -1,6 +1,6 @@