fix(core): blocksuite editor runtime configs in correct timing (#10344)

This commit is contained in:
Peng Xiao
2025-02-21 17:16:53 +08:00
committed by GitHub
parent 09cc5c392b
commit dff68b9aae
5 changed files with 37 additions and 49 deletions

View File

@@ -96,12 +96,9 @@ function DocPeekPreviewEditor({
const handleOnEditorReady = useCallback(
(editorContainer: AffineEditorContainer) => {
if (!editorContainer.host) {
return;
}
const disposableGroup = new DisposableGroup();
const refNodeSlots =
editorContainer.host.std.getOptional(RefNodeSlotsProvider);
editorContainer.std.getOptional(RefNodeSlotsProvider);
if (!refNodeSlots) return;
// doc change event inside peek view should be handled by peek view
disposableGroup.add(