mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-18 14:56:59 +08:00
feat: improve document remove & title (#657)
* fix: cancel delete, do not show toast * feat: support document title sync page title
This commit is contained in:
@@ -87,7 +87,7 @@ const PopoverContent = () => {
|
|||||||
confirmType: 'danger',
|
confirmType: 'danger',
|
||||||
}).then(confirm => {
|
}).then(confirm => {
|
||||||
confirm && toggleDeletePage(id);
|
confirm && toggleDeletePage(id);
|
||||||
toast('Moved to Trash');
|
confirm && toast('Moved to Trash');
|
||||||
});
|
});
|
||||||
}}
|
}}
|
||||||
icon={<TrashIcon />}
|
icon={<TrashIcon />}
|
||||||
|
|||||||
@@ -68,6 +68,7 @@ const Page: NextPageWithLayout = () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
document.title = currentPage?.meta.title || 'Untitled';
|
||||||
return ret;
|
return ret;
|
||||||
}, [currentWorkspace, currentPage, createEditor, setEditor]);
|
}, [currentWorkspace, currentPage, createEditor, setEditor]);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user