Merge branch '2-10-1-fixes' into 'develop'
Fixes for 2.10.1 See merge request pleroma/pleroma-fe!2195
This commit is contained in:
commit
127396d2af
12 changed files with 32 additions and 34 deletions
1
changelog.d/actor-type.fix
Normal file
1
changelog.d/actor-type.fix
Normal file
|
|
@ -0,0 +1 @@
|
|||
fixed being unable to set actor type from profile page
|
||||
1
changelog.d/error-mute.fix
Normal file
1
changelog.d/error-mute.fix
Normal file
|
|
@ -0,0 +1 @@
|
|||
fixed error when clicking mute menu itself (instead of submenu items)
|
||||
1
changelog.d/mute-domain.fix
Normal file
1
changelog.d/mute-domain.fix
Normal file
|
|
@ -0,0 +1 @@
|
|||
fixed mute -> domain status submenu not working
|
||||
|
|
@ -15,10 +15,10 @@ const BlockCard = {
|
|||
return this.relationship.blocking
|
||||
},
|
||||
blockExpiryAvailable() {
|
||||
return this.user.block_expires_at !== undefined
|
||||
return Object.hasOwn(this.user, 'block_expires_at')
|
||||
},
|
||||
blockExpiry() {
|
||||
return this.user.block_expires_at == null
|
||||
return this.user.block_expires_at === false
|
||||
? this.$t('user_card.block_expires_forever')
|
||||
: this.$t('user_card.block_expires_at', [
|
||||
new Date(this.user.mute_expires_at).toLocaleString(),
|
||||
|
|
|
|||
|
|
@ -19,9 +19,9 @@ export default {
|
|||
},
|
||||
keypath() {
|
||||
if (this.type === 'domain') {
|
||||
return 'status.mute_domain_confirm'
|
||||
return 'user_card.mute_domain_confirm'
|
||||
} else if (this.type === 'conversation') {
|
||||
return 'status.mute_conversation_confirm'
|
||||
return 'user_card.mute_conversation_confirm'
|
||||
}
|
||||
},
|
||||
conversationIsMuted() {
|
||||
|
|
@ -65,9 +65,9 @@ export default {
|
|||
switch (this.type) {
|
||||
case 'domain': {
|
||||
if (!this.domainIsMuted) {
|
||||
this.$store.dispatch('muteDomain', { id: this.domain })
|
||||
this.$store.dispatch('muteDomain', this.domain)
|
||||
} else {
|
||||
this.$store.dispatch('unmuteDomain', { id: this.domain })
|
||||
this.$store.dispatch('unmuteDomain', this.domain)
|
||||
}
|
||||
break
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,10 +14,10 @@ const MuteCard = {
|
|||
return this.relationship.muting
|
||||
},
|
||||
muteExpiryAvailable() {
|
||||
return this.user.mute_expires_at !== undefined
|
||||
return Object.hasOwn(this.user, 'mute_expires_at')
|
||||
},
|
||||
muteExpiry() {
|
||||
return this.user.mute_expires_at == null
|
||||
return this.user.mute_expires_at === false
|
||||
? this.$t('user_card.mute_expires_forever')
|
||||
: this.$t('user_card.mute_expires_at', [
|
||||
new Date(this.user.mute_expires_at).toLocaleString(),
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ export default {
|
|||
return this.$store.dispatch('unmuteConversation', { id: this.status.id })
|
||||
},
|
||||
unmuteDomain() {
|
||||
return this.$store.dispatch('unmuteDomain', this.user.id)
|
||||
return this.$store.dispatch('unmuteDomain', this.domain)
|
||||
},
|
||||
toggleUserMute() {
|
||||
if (this.userIsMuted) {
|
||||
|
|
|
|||
|
|
@ -98,7 +98,7 @@ const StatusActionButtons = {
|
|||
},
|
||||
doActionReal(button) {
|
||||
button
|
||||
.action(this.funcArg)
|
||||
.action?.(this.funcArg)
|
||||
.then(() => this.$emit('onSuccess'))
|
||||
.catch((err) => this.$emit('onError', err.error.error))
|
||||
},
|
||||
|
|
|
|||
|
|
@ -121,8 +121,6 @@ export default {
|
|||
|
||||
return {
|
||||
followRequestInProgress: false,
|
||||
muteExpiryAmount: 0,
|
||||
muteExpiryUnit: 'minutes',
|
||||
|
||||
// Editable stuff
|
||||
editImage: false,
|
||||
|
|
@ -158,7 +156,7 @@ export default {
|
|||
computed: {
|
||||
somethingToSave() {
|
||||
if (this.newName !== this.user.name_unescaped) return true
|
||||
if (this.newBio !== unescape(this.user.description)) return true
|
||||
if (this.newBio !== ldUnescape(this.user.description)) return true
|
||||
if (this.newAvatar !== null) return true
|
||||
if (this.newBanner !== null) return true
|
||||
if (this.newActorType !== this.user.actor_type) return true
|
||||
|
|
@ -288,17 +286,17 @@ export default {
|
|||
return 'note' in this.relationship
|
||||
},
|
||||
muteExpiryAvailable() {
|
||||
return this.user.mute_expires_at !== undefined
|
||||
return Object.hasOwn(this.user, 'mute_expires_at')
|
||||
},
|
||||
muteExpiry() {
|
||||
return this.user.mute_expires_at == null
|
||||
return this.user.mute_expires_at === false
|
||||
? this.$t('user_card.mute_expires_forever')
|
||||
: this.$t('user_card.mute_expires_at', [
|
||||
new Date(this.user.mute_expires_at).toLocaleString(),
|
||||
])
|
||||
},
|
||||
blockExpiryAvailable() {
|
||||
return this.user.block_expires_at !== undefined
|
||||
return Object.hasOwn(this.user, 'block_expires_at')
|
||||
},
|
||||
blockExpiry() {
|
||||
return this.user.block_expires_at == null
|
||||
|
|
@ -500,7 +498,7 @@ export default {
|
|||
const user = this.$store.state.users.currentUser
|
||||
|
||||
this.newName = user.name_unescaped
|
||||
this.newBio = unescape(user.description)
|
||||
this.newBio = ldUnescape(user.description)
|
||||
|
||||
this.newAvatar = null
|
||||
this.newAvatarFile = null
|
||||
|
|
@ -530,8 +528,8 @@ export default {
|
|||
show_birthday: !!this.newShowBirthday,
|
||||
}
|
||||
|
||||
if (this.actorType) {
|
||||
params.actor_type = this.actorType
|
||||
if (this.newActorType) {
|
||||
params.actor_type = this.newActorType
|
||||
}
|
||||
|
||||
if (this.newAvatarFile !== null) {
|
||||
|
|
|
|||
|
|
@ -208,22 +208,10 @@
|
|||
</span>
|
||||
<span
|
||||
v-if="user.actor_type === 'Group'"
|
||||
class="alert user-role"
|
||||
class="alert neutral user-role"
|
||||
>
|
||||
{{ $t('user_card.group') }}
|
||||
</span>
|
||||
<span
|
||||
v-if="relationship.muting && muteExpiryAvailable"
|
||||
class="alert neutral user-role"
|
||||
>
|
||||
{{ muteExpiry }}
|
||||
</span>
|
||||
<span
|
||||
v-if="relationship.blocking && blockExpiryAvailable"
|
||||
class="alert neutral user-role"
|
||||
>
|
||||
{{ blockExpiry }}
|
||||
</span>
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -1664,6 +1664,7 @@
|
|||
"muted": "Muted",
|
||||
"mute_confirm_title": "Mute confirmation",
|
||||
"mute_confirm": "Do you really want to mute {user}?",
|
||||
"mute_domain_confirm": "Do you really want to mute entire {domain}?",
|
||||
"mute_confirm_accept_button": "Mute",
|
||||
"mute_confirm_cancel_button": "Do not mute",
|
||||
"mute_or": "or",
|
||||
|
|
|
|||
|
|
@ -61,8 +61,16 @@ export const parseUser = (data) => {
|
|||
output.screen_name = data.acct
|
||||
output.fqn = data.fqn
|
||||
output.statusnet_profile_url = data.url
|
||||
output.mute_expires_at = data.mute_expires_at
|
||||
output.block_expires_at = data.block_expires_at
|
||||
|
||||
if (Object.hasOwn(data, 'mute_expires_at')) {
|
||||
output.mute_expires_at =
|
||||
data.mute_expires_at == null ? false : data.mute_expires_at
|
||||
}
|
||||
|
||||
if (Object.hasOwn(data, 'block_expires_at')) {
|
||||
output.block_expires_at =
|
||||
data.block_expires_at == null ? false : data.block_expires_at
|
||||
}
|
||||
|
||||
// There's nothing else to get
|
||||
if (mastoShort) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue