Merge branch 'chat-refactor' into shigusegubu-themes3

This commit is contained in:
Henry Jameson 2026-08-02 22:38:02 +03:00
commit ee618296cd
3 changed files with 14 additions and 6 deletions

View file

@ -42,7 +42,9 @@ const Draft = {
if (this.draft.type === 'edit') { if (this.draft.type === 'edit') {
return { statusId: this.draft.refId } return { statusId: this.draft.refId }
} else if (this.draft.type === 'reply') { } else if (this.draft.type === 'reply') {
return { replyTo: this.draft.refId } return {
repliedStatus: this.refStatus
}
} else { } else {
return {} return {}
} }

View file

@ -983,8 +983,15 @@ const PostStatusForm = {
saveDraft() { saveDraft() {
if (!this.disableDraft && !this.saveInhibited) { if (!this.disableDraft && !this.saveInhibited) {
if (this.safeToSaveDraft) { if (this.safeToSaveDraft) {
return this.$store return this
.dispatch('addOrSaveDraft', { draft: this.newStatus }) .$store
.dispatch('addOrSaveDraft', {
draft: {
type: this.statusType,
refId: this.refId,
...this.newStatus
}
})
.then((id) => { .then((id) => {
if (this.newStatus.id !== id) { if (this.newStatus.id !== id) {
this.newStatus.id = id this.newStatus.id = id
@ -1016,7 +1023,7 @@ const PostStatusForm = {
} }
}, },
abandonDraft() { abandonDraft() {
return this.$store.dispatch('abandonDraft', { id: this.newStatus.id }) return this.$store.dispatch('abandonDraft', { id: this.draftId })
}, },
getDraft() { getDraft() {
const maybeDraft = this.$store.state.drafts.drafts[this.draftId] const maybeDraft = this.$store.state.drafts.drafts[this.draftId]

View file

@ -272,8 +272,7 @@
.drop-indicator { .drop-indicator {
position: absolute; position: absolute;
width: 100%; inset: 0;
height: 100%;
font-size: 5em; font-size: 5em;
display: flex; display: flex;
align-items: center; align-items: center;