Merge branch 'fixes-roundup5' into shigusegubu-themes3
This commit is contained in:
commit
8ad1c4a3ff
13 changed files with 77 additions and 9 deletions
|
|
@ -1 +1 @@
|
||||||
18.20.6
|
18.20.7
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,7 @@
|
||||||
"click-outside-vue3": "4.0.1",
|
"click-outside-vue3": "4.0.1",
|
||||||
"cropperjs": "1.6.2",
|
"cropperjs": "1.6.2",
|
||||||
"escape-html": "1.0.3",
|
"escape-html": "1.0.3",
|
||||||
"globals": "^15.14.0",
|
"globals": "^16.0.0",
|
||||||
"hash-sum": "^2.0.0",
|
"hash-sum": "^2.0.0",
|
||||||
"js-cookie": "3.0.5",
|
"js-cookie": "3.0.5",
|
||||||
"localforage": "1.10.0",
|
"localforage": "1.10.0",
|
||||||
|
|
|
||||||
|
|
@ -129,6 +129,21 @@ PanelHeader {
|
||||||
background: --fg
|
background: --fg
|
||||||
}
|
}
|
||||||
|
|
||||||
|
PanelHeader ButtonUnstyled Icon {
|
||||||
|
textColor: --text;
|
||||||
|
textAuto: 'no-preserve'
|
||||||
|
}
|
||||||
|
|
||||||
|
PanelHeader Button Icon {
|
||||||
|
textColor: --text;
|
||||||
|
textAuto: 'no-preserve'
|
||||||
|
}
|
||||||
|
|
||||||
|
PanelHeader Button Text {
|
||||||
|
textColor: --text;
|
||||||
|
textAuto: 'no-preserve'
|
||||||
|
}
|
||||||
|
|
||||||
Tab:hover {
|
Tab:hover {
|
||||||
background: --bg;
|
background: --bg;
|
||||||
shadow: --buttonDefaultBevel
|
shadow: --buttonDefaultBevel
|
||||||
|
|
@ -172,6 +187,14 @@ MenuItem:hover {
|
||||||
background: --fg
|
background: --fg
|
||||||
}
|
}
|
||||||
|
|
||||||
|
MenuItem:active {
|
||||||
|
background: --fg
|
||||||
|
}
|
||||||
|
|
||||||
|
MenuItem:active:hover {
|
||||||
|
background: --fg
|
||||||
|
}
|
||||||
|
|
||||||
Popover {
|
Popover {
|
||||||
shadow: --buttonDefaultBevel, 5 5 0 0 #000000 / 0.2;
|
shadow: --buttonDefaultBevel, 5 5 0 0 #000000 / 0.2;
|
||||||
roundness: 0
|
roundness: 0
|
||||||
|
|
|
||||||
|
|
@ -540,6 +540,7 @@
|
||||||
:status="status"
|
:status="status"
|
||||||
:replying="replying"
|
:replying="replying"
|
||||||
@toggle-replying="toggleReplying"
|
@toggle-replying="toggleReplying"
|
||||||
|
@interacted="e => $emit('interacted')"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -67,6 +67,9 @@ export default {
|
||||||
'doAction',
|
'doAction',
|
||||||
'outerClose'
|
'outerClose'
|
||||||
],
|
],
|
||||||
|
emits: [
|
||||||
|
'interacted'
|
||||||
|
],
|
||||||
components: {
|
components: {
|
||||||
StatusBookmarkFolderMenu,
|
StatusBookmarkFolderMenu,
|
||||||
EmojiPicker,
|
EmojiPicker,
|
||||||
|
|
@ -120,7 +123,8 @@ export default {
|
||||||
this.$store.dispatch('reactWithEmoji', { id: this.status.id, emoji })
|
this.$store.dispatch('reactWithEmoji', { id: this.status.id, emoji })
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
doActionWrap (button, close) {
|
doActionWrap (button, close = () => {}) {
|
||||||
|
this.$emit('interacted')
|
||||||
if (button.name === 'emoji') {
|
if (button.name === 'emoji') {
|
||||||
this.$refs.picker.showPicker()
|
this.$refs.picker.showPicker()
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
|
|
@ -22,6 +22,7 @@ export default {
|
||||||
MuteConfirm
|
MuteConfirm
|
||||||
},
|
},
|
||||||
props: ['button', 'status'],
|
props: ['button', 'status'],
|
||||||
|
emits: ['interacted'],
|
||||||
mounted () {
|
mounted () {
|
||||||
if (this.button.name === 'mute') {
|
if (this.button.name === 'mute') {
|
||||||
this.$store.dispatch('fetchDomainMutes')
|
this.$store.dispatch('fetchDomainMutes')
|
||||||
|
|
|
||||||
|
|
@ -79,6 +79,7 @@
|
||||||
:button="button"
|
:button="button"
|
||||||
:status="status"
|
:status="status"
|
||||||
v-bind="$attrs"
|
v-bind="$attrs"
|
||||||
|
@interacted="e => $emit('interacted')"
|
||||||
/>
|
/>
|
||||||
<teleport to="#modal">
|
<teleport to="#modal">
|
||||||
<MuteConfirm
|
<MuteConfirm
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,7 @@
|
||||||
import { useEditStatusStore } from 'src/stores/editStatus.js'
|
import { useEditStatusStore } from 'src/stores/editStatus.js'
|
||||||
|
import { useReportsStore } from 'src/stores/reports.js'
|
||||||
|
import { useStatusHistoryStore } from 'src/stores/statusHistory.js'
|
||||||
|
|
||||||
const PRIVATE_SCOPES = new Set(['private', 'direct'])
|
const PRIVATE_SCOPES = new Set(['private', 'direct'])
|
||||||
const PUBLIC_SCOPES = new Set(['public', 'unlisted'])
|
const PUBLIC_SCOPES = new Set(['public', 'unlisted'])
|
||||||
export const BUTTONS = [{
|
export const BUTTONS = [{
|
||||||
|
|
@ -138,6 +141,34 @@ export const BUTTONS = [{
|
||||||
return dispatch('bookmark', { id: status.id })
|
return dispatch('bookmark', { id: status.id })
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}, {
|
||||||
|
// =========
|
||||||
|
// EDIT HISTORY
|
||||||
|
// =========
|
||||||
|
name: 'editHistory',
|
||||||
|
icon: 'history',
|
||||||
|
label: 'status.status_history',
|
||||||
|
if ({ status, state }) {
|
||||||
|
return state.instance.editingAvailable &&
|
||||||
|
status.edited_at !== null
|
||||||
|
},
|
||||||
|
action ({ status }) {
|
||||||
|
const originalStatus = { ...status }
|
||||||
|
const stripFieldsList = [
|
||||||
|
'attachments',
|
||||||
|
'created_at',
|
||||||
|
'emojis',
|
||||||
|
'text',
|
||||||
|
'raw_html',
|
||||||
|
'nsfw',
|
||||||
|
'poll',
|
||||||
|
'summary',
|
||||||
|
'summary_raw_html'
|
||||||
|
]
|
||||||
|
stripFieldsList.forEach(p => delete originalStatus[p])
|
||||||
|
useStatusHistoryStore().openStatusHistoryModal(originalStatus)
|
||||||
|
return Promise.resolve()
|
||||||
|
}
|
||||||
}, {
|
}, {
|
||||||
// =========
|
// =========
|
||||||
// EDIT
|
// EDIT
|
||||||
|
|
@ -216,8 +247,8 @@ export const BUTTONS = [{
|
||||||
icon: 'flag',
|
icon: 'flag',
|
||||||
label: 'user_card.report',
|
label: 'user_card.report',
|
||||||
if: ({ loggedIn }) => loggedIn,
|
if: ({ loggedIn }) => loggedIn,
|
||||||
action ({ dispatch, status }) {
|
action ({ status }) {
|
||||||
dispatch('openUserReportingModal', { userId: status.user.id, statusIds: [status.id] })
|
return useReportsStore().openUserReportingModal({ userId: status.user.id, statusIds: [status.id] })
|
||||||
}
|
}
|
||||||
}].map(button => {
|
}].map(button => {
|
||||||
return Object.fromEntries(
|
return Object.fromEntries(
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ library.add(
|
||||||
|
|
||||||
const StatusActionButtons = {
|
const StatusActionButtons = {
|
||||||
props: ['status', 'replying'],
|
props: ['status', 'replying'],
|
||||||
emits: ['toggleReplying'],
|
emits: ['toggleReplying', 'interacted'],
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
showPin: false,
|
showPin: false,
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,7 @@
|
||||||
:get-component="getComponent"
|
:get-component="getComponent"
|
||||||
:close="() => {}"
|
:close="() => {}"
|
||||||
:do-action="doAction"
|
:do-action="doAction"
|
||||||
|
@interacted="e => $emit('interacted')"
|
||||||
/>
|
/>
|
||||||
<button
|
<button
|
||||||
v-if="showPin && currentUser"
|
v-if="showPin && currentUser"
|
||||||
|
|
@ -88,6 +89,7 @@
|
||||||
:get-component="getComponent"
|
:get-component="getComponent"
|
||||||
:outerClose="close"
|
:outerClose="close"
|
||||||
:do-action="doAction"
|
:do-action="doAction"
|
||||||
|
@interacted="e => $emit('interacted')"
|
||||||
/>
|
/>
|
||||||
<button
|
<button
|
||||||
v-if="showPin && currentUser"
|
v-if="showPin && currentUser"
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ export const useReportsStore = defineStore('reports', {
|
||||||
this.reportModal.activated = false
|
this.reportModal.activated = false
|
||||||
},
|
},
|
||||||
setReportState ({ id, state }) {
|
setReportState ({ id, state }) {
|
||||||
const oldState = window.vuex.state.reports.reports[id].state
|
const oldState = this.reports[id].state
|
||||||
this.reports[id].state = state
|
this.reports[id].state = state
|
||||||
window.vuex.state.api.backendInteractor.setReportState({ id, state }).catch(e => {
|
window.vuex.state.api.backendInteractor.setReportState({ id, state }).catch(e => {
|
||||||
console.error('Failed to set report state', e)
|
console.error('Failed to set report state', e)
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// Existing emojis we have
|
// Existing emojis we have
|
||||||
const oldEmojiFilename = '../static/emoji.json'
|
const oldEmojiFilename = '../src/assets/emoji.json'
|
||||||
|
|
||||||
// The file downloaded from https://gist.github.com/oliveratgithub/0bf11a9aff0d6da7b46f1490f86a71eb
|
// The file downloaded from https://gist.github.com/oliveratgithub/0bf11a9aff0d6da7b46f1490f86a71eb
|
||||||
const newEmojiFilename = 'emojis.json'
|
const newEmojiFilename = 'emojis.json'
|
||||||
|
|
|
||||||
|
|
@ -4440,11 +4440,16 @@ globals@^14.0.0:
|
||||||
resolved "https://registry.yarnpkg.com/globals/-/globals-14.0.0.tgz#898d7413c29babcf6bafe56fcadded858ada724e"
|
resolved "https://registry.yarnpkg.com/globals/-/globals-14.0.0.tgz#898d7413c29babcf6bafe56fcadded858ada724e"
|
||||||
integrity sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==
|
integrity sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==
|
||||||
|
|
||||||
globals@^15.11.0, globals@^15.14.0:
|
globals@^15.11.0:
|
||||||
version "15.15.0"
|
version "15.15.0"
|
||||||
resolved "https://registry.yarnpkg.com/globals/-/globals-15.15.0.tgz#7c4761299d41c32b075715a4ce1ede7897ff72a8"
|
resolved "https://registry.yarnpkg.com/globals/-/globals-15.15.0.tgz#7c4761299d41c32b075715a4ce1ede7897ff72a8"
|
||||||
integrity sha512-7ACyT3wmyp3I61S4fG682L0VA2RGD9otkqGJIwNUMF1SWUombIIk+af1unuDYgMm082aHYwD+mzJvv9Iu8dsgg==
|
integrity sha512-7ACyT3wmyp3I61S4fG682L0VA2RGD9otkqGJIwNUMF1SWUombIIk+af1unuDYgMm082aHYwD+mzJvv9Iu8dsgg==
|
||||||
|
|
||||||
|
globals@^16.0.0:
|
||||||
|
version "16.0.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/globals/-/globals-16.0.0.tgz#3d7684652c5c4fbd086ec82f9448214da49382d8"
|
||||||
|
integrity sha512-iInW14XItCXET01CQFqudPOWP2jYMl7T+QRQT+UNcR/iQncN/F0UNpgd76iFkBPgNQb4+X3LV9tLJYzwh+Gl3A==
|
||||||
|
|
||||||
globalthis@^1.0.4:
|
globalthis@^1.0.4:
|
||||||
version "1.0.4"
|
version "1.0.4"
|
||||||
resolved "https://registry.yarnpkg.com/globalthis/-/globalthis-1.0.4.tgz#7430ed3a975d97bfb59bcce41f5cabbafa651236"
|
resolved "https://registry.yarnpkg.com/globalthis/-/globalthis-1.0.4.tgz#7430ed3a975d97bfb59bcce41f5cabbafa651236"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue