client: add button to unrenote
All checks were successful
ci/woodpecker/push/lint-backend Pipeline was successful
ci/woodpecker/push/lint-client Pipeline was successful
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/lint-sw Pipeline was successful
ci/woodpecker/push/test Pipeline was successful

Changelog: Added
This commit is contained in:
Johann150 2022-12-15 17:52:19 +01:00
parent 16d091497a
commit 84d83d908a
Signed by: Johann150
GPG key ID: 9EE6577A2A06F8F1
2 changed files with 18 additions and 0 deletions

View file

@ -96,6 +96,8 @@ unfollow: "Unfollow"
followRequestPending: "Follow request pending"
renote: "Renote"
unrenote: "Take back renote"
unrenoteAll: "Take back all renotes"
unrenoteAllConfirm: "Are you sure that you want to take back all renotes of this note?"
quote: "Quote"
pinnedNote: "Pinned note"
you: "You"

View file

@ -61,6 +61,22 @@ function renote(viaKeyboard = false): void {
visibility: props.note.visibility,
});
},
}, {
text: i18n.ts.unrenoteAll,
icon: 'fas fa-trash-alt',
danger: true,
action: () => {
os.confirm({
type: 'warning',
text: i18n.ts.unrenoteAllConfirm,
}).then(({ canceled }) => {
if (canceled) return;
os.api('notes/unrenote', {
noteId: props.note.id,
});
});
},
}, {
text: i18n.ts.quote,
icon: 'fas fa-quote-right',