mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 07:00:12 +01:00
parent
95a2bd0a83
commit
bf1172b05e
2 changed files with 15 additions and 2 deletions
|
|
@ -91,6 +91,17 @@ export const onGet = (options: {
|
||||||
isSyncing: options.data.data.isSyncing,
|
isSyncing: options.data.data.isSyncing,
|
||||||
afterCB: options.afterCB,
|
afterCB: options.afterCB,
|
||||||
}, options.protyle);
|
}, options.protyle);
|
||||||
|
|
||||||
|
// 如果需要渲染标题且包含 CB_GET_HTML,需要获取文档信息来更新标题
|
||||||
|
if (options.protyle.options.render.title && options.action.includes(Constants.CB_GET_HTML)) {
|
||||||
|
fetchPost("/api/block/getDocInfo", {
|
||||||
|
id: options.protyle.block.rootID
|
||||||
|
}, (response) => {
|
||||||
|
options.protyle.title.element.removeAttribute("data-render");
|
||||||
|
options.protyle.title.render(options.protyle, response);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
removeLoading(options.protyle);
|
removeLoading(options.protyle);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -239,7 +239,8 @@ export const genSearch = (app: App, config: Config.IUILayoutTabSearchConfig, ele
|
||||||
blockId: "",
|
blockId: "",
|
||||||
render: {
|
render: {
|
||||||
gutter: true,
|
gutter: true,
|
||||||
breadcrumbDocName: true
|
breadcrumbDocName: true,
|
||||||
|
title: true
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
edit.resize();
|
edit.resize();
|
||||||
|
|
@ -247,7 +248,8 @@ export const genSearch = (app: App, config: Config.IUILayoutTabSearchConfig, ele
|
||||||
blockId: "",
|
blockId: "",
|
||||||
render: {
|
render: {
|
||||||
gutter: true,
|
gutter: true,
|
||||||
breadcrumbDocName: true
|
breadcrumbDocName: true,
|
||||||
|
title: true
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
unRefEdit.resize();
|
unRefEdit.resize();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue