Merge pull request '2-11-3-fixes' (#3546) from 2-11-3-fixes into develop

Reviewed-on: https://git.pleroma.social/pleroma/pleroma-fe/pulls/3546
This commit is contained in:
HJ 2026-08-11 21:40:54 +00:00
commit 35ea3a97dc
17 changed files with 35 additions and 15 deletions

View file

@ -0,0 +1 @@
fixed tapping "Mute..." and "Change visiblity" (admin action) in extra status actions closing the dropdown

View file

@ -0,0 +1 @@
domain mute fixedw

View file

@ -0,0 +1 @@
fix moderation tools button possibly not appearing for admins

View file

@ -0,0 +1 @@
Fixed moderation actions requiring confirmation closing user popover

View file

@ -0,0 +1 @@
Fix Themes 2.0 applying incorrect fonts

1
changelog.d/themes3.fix Normal file
View file

@ -0,0 +1 @@
Fixed themes 3 not loading in appearance tab

View file

@ -67,6 +67,7 @@ export const promisedRequest = async ({
url, url,
payload, payload,
formData, formData,
forceContentType,
cache, cache,
credentials, credentials,
headers = {}, headers = {},
@ -75,7 +76,7 @@ export const promisedRequest = async ({
method, method,
credentials: 'same-origin', credentials: 'same-origin',
headers: { headers: {
Accept: 'application/json', Accept: forceContentType ?? 'application/json',
...headers, ...headers,
}, },
} }
@ -110,7 +111,7 @@ export const promisedRequest = async ({
) )
if (contentLength === 0) return null if (contentLength === 0) return null
switch (contentType) { switch (forceContentType ?? contentType) {
case 'text/plain': case 'text/plain':
return await response.text() return await response.text()
case 'application/json': case 'application/json':

View file

@ -516,8 +516,7 @@ const ModerationTools = {
setOpen(value) { setOpen(value) {
this.open = value this.open = value
}, },
maybeShowConfirm(close, { group, name, action, value }) { maybeShowConfirm({ group, name, action, value }) {
close()
this.confirmDialogName = name this.confirmDialogName = name
this.confirmDialogGroup = group this.confirmDialogGroup = group
this.confirmDialogAction = () => action() this.confirmDialogAction = () => action()

View file

@ -9,7 +9,7 @@
@show="setOpen(true)" @show="setOpen(true)"
@close="setOpen(false)" @close="setOpen(false)"
> >
<template #content="{close}"> <template #content>
<div class="dropdown-menu"> <div class="dropdown-menu">
<template v-for="(entry, index) in entries"> <template v-for="(entry, index) in entries">
<div <div
@ -26,7 +26,7 @@
> >
<button <button
class="main-button" class="main-button"
@click="() => maybeShowConfirm(close, entry)" @click="() => maybeShowConfirm(entry)"
> >
<span <span
v-if="entry.checkbox" v-if="entry.checkbox"

View file

@ -78,8 +78,8 @@
v-model="expiryUnit" v-model="expiryUnit"
unstyled="true" unstyled="true"
class="expiry-unit" class="expiry-unit"
@change="expiryAmountChange"
:aria-label="$t('polls.expiry_unit')" :aria-label="$t('polls.expiry_unit')"
@change="expiryAmountChange"
> >
<option <option
v-for="unit in expiryUnits" v-for="unit in expiryUnits"

View file

@ -579,8 +579,11 @@ const PostStatusForm = {
}), }),
}, },
watch: { watch: {
isDirty(newVal, oldVal) { newStatus: {
this.statusChanged() deep: true,
handler() {
this.statusChanged()
},
}, },
saveable(val) { saveable(val) {
// https://developer.mozilla.org/en-US/docs/Web/API/Window/beforeunload_event#usage_notes // https://developer.mozilla.org/en-US/docs/Web/API/Window/beforeunload_event#usage_notes

View file

@ -168,7 +168,7 @@ export default {
setTimeout(() => { setTimeout(() => {
this.animationState = false this.animationState = false
}, 500) }, 500)
close() if (!this.button.dropdown) close()
} }
}, },
}, },

View file

@ -212,7 +212,7 @@ const api = {
if (state.mastoUserSocketStatus !== WSConnectionStatus.ERROR) { if (state.mastoUserSocketStatus !== WSConnectionStatus.ERROR) {
dispatch('startFetchingTimeline', { timeline: 'friends' }) dispatch('startFetchingTimeline', { timeline: 'friends' })
dispatch('startFetchingNotifications') dispatch('startFetchingNotifications')
dispatch('startFetchingChats') useChatsStore().startFetchingChats()
useInterfaceStore().pushGlobalNotice({ useInterfaceStore().pushGlobalNotice({
level: 'error', level: 'error',
messageKey: 'timeline.socket_broke', messageKey: 'timeline.socket_broke',
@ -234,7 +234,7 @@ const api = {
stopMastoUserSocket({ state, dispatch }) { stopMastoUserSocket({ state, dispatch }) {
dispatch('startFetchingTimeline', { timeline: 'friends' }) dispatch('startFetchingTimeline', { timeline: 'friends' })
dispatch('startFetchingNotifications') dispatch('startFetchingNotifications')
dispatch('startFetchingChats') useChatsStore().startFetchingChats()
state.mastoUserSocket.close() state.mastoUserSocket.close()
}, },

View file

@ -85,6 +85,11 @@ export const notifications = {
return true return true
}) })
commit(
'addNewUsers',
validNotifications.map((notification) => notification.from_profile),
)
const statusNotifications = validNotifications.filter( const statusNotifications = validNotifications.filter(
(notification) => (notification) =>
isStatusNotification(notification.type) && notification.status, isStatusNotification(notification.type) && notification.status,

View file

@ -881,7 +881,7 @@ const statuses = {
'addNewUsers', 'addNewUsers',
data.statuses.map((s) => s.user).filter(Boolean), data.statuses.map((s) => s.user).filter(Boolean),
) )
store.commit('addNewStatuses', { store.dispatch('addNewStatuses', {
statuses: data.statuses, statuses: data.statuses,
}) })

View file

@ -619,8 +619,11 @@ const users = {
addNewStatuses(store, { statuses }) { addNewStatuses(store, { statuses }) {
const users = map(statuses, 'user') const users = map(statuses, 'user')
const retweetedUsers = compact(map(statuses, 'retweeted_status.user')) const retweetedUsers = compact(map(statuses, 'retweeted_status.user'))
const quotedUsers = compact(map(statuses, 'quote.user'))
store.commit('addNewUsers', users) store.commit('addNewUsers', users)
store.commit('addNewUsers', retweetedUsers) store.commit('addNewUsers', retweetedUsers)
store.commit('addNewUsers', quotedUsers)
each(statuses, (status) => { each(statuses, (status) => {
// Reconnect users to statuses // Reconnect users to statuses
@ -795,7 +798,7 @@ const users = {
if (useInstanceCapabilitiesStore().pleromaChatMessagesAvailable) { if (useInstanceCapabilitiesStore().pleromaChatMessagesAvailable) {
// Start fetching chats // Start fetching chats
dispatch('startFetchingChats') useChatsStore().startFetchingChats()
} }
} }

View file

@ -313,7 +313,9 @@ export const applyStyleConfig = (input) => {
adoptStyleSheets() adoptStyleSheets()
} }
export const getResourcesIndex = async (url, parser = (x) => x) => { const noop = (x) => x
export const getResourcesIndex = async (url, parser = noop) => {
const cache = 'no-store' const cache = 'no-store'
const customUrl = url.replace(/\.(\w+)$/, '.custom.$1') const customUrl = url.replace(/\.(\w+)$/, '.custom.$1')
let builtin let builtin
@ -330,6 +332,7 @@ export const getResourcesIndex = async (url, parser = (x) => x) => {
promisedRequest({ promisedRequest({
url: v, url: v,
cache, cache,
forceContentType: parser === noop ? null : 'text/plain',
}) })
.then(({ data: text }) => parser(text)) .then(({ data: text }) => parser(text))
.catch((e) => { .catch((e) => {