feat: go to new status after redraftting

This commit is contained in:
三咲智子 2023-01-01 23:57:49 +08:00
parent d62292d219
commit 22fcc1d68b
No known key found for this signature in database
GPG key ID: 69992F2250DFD93E
5 changed files with 42 additions and 13 deletions

View file

@ -72,7 +72,11 @@ const deleteAndRedraft = async () => {
removeCachedStatus(status.id)
await masto.statuses.remove(status.id)
openPublishDialog('dialog', await getDraftFromStatus(status), true)
await openPublishDialog('dialog', await getDraftFromStatus(status), true)
// Go to the new status, if the page is the old status
if (lastPublishDialogStatus.value && route.matched.some(m => m.path === '/:server?/@:account/:status'))
router.push(getStatusRoute(lastPublishDialogStatus.value))
}
const reply = () => {