mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-15 05:37:32 +00:00
chore: bump bs with new extension api (#8042)
This commit is contained in:
@@ -130,14 +130,23 @@ const DetailPageImpl = () => {
|
||||
|
||||
// provide page mode and updated date to blocksuite
|
||||
const pageService =
|
||||
editorHost?.std.spec.getService<PageRootService>('affine:page');
|
||||
editorHost?.std.getService<PageRootService>('affine:page');
|
||||
const disposable = new DisposableGroup();
|
||||
if (pageService) {
|
||||
disposable.add(
|
||||
pageService.slots.docLinkClicked.on(({ docId, blockId }) => {
|
||||
return blockId
|
||||
? jumpToPageBlock(docCollection.id, docId, blockId)
|
||||
: openPage(docCollection.id, docId);
|
||||
pageService.slots.docLinkClicked.on(({ pageId, params }) => {
|
||||
if (params) {
|
||||
const { mode, blockIds, elementIds } = params;
|
||||
return jumpToPageBlock(
|
||||
docCollection.id,
|
||||
pageId,
|
||||
mode,
|
||||
blockIds,
|
||||
elementIds
|
||||
);
|
||||
}
|
||||
|
||||
return openPage(docCollection.id, pageId);
|
||||
})
|
||||
);
|
||||
disposable.add(
|
||||
|
||||
Reference in New Issue
Block a user