This commit is contained in:
Vanessa 2023-03-13 10:53:42 +08:00
parent 41e8fe8c03
commit ffd94d6b51
9 changed files with 1124 additions and 825 deletions

View file

@ -10,7 +10,7 @@ export const fillContent = (protyle:IProtyle, data:string, elements:Element[]) =
setLastNodeRange(getContenteditableElement(elements[elements.length - 1]), protyle.toolbar.range);
protyle.toolbar.range.collapse(true);
insertHTML(data, protyle, true, true);
}
};
export const AIActions = (elements: Element[], protyle: IProtyle) => {
const ids: string[] = [];

View file

@ -11,7 +11,10 @@
<div id="loading" class="b3-dialog b3-dialog--open">
<div class="b3-dialog__scrim" style="background-color: #212224"></div>
<img style="position: absolute;width: 36vh;" src="../../icon.png">
<button onclick="window.location.reload()" id="loadingRefresh" style="display: none;position: absolute;bottom: 16px;background: transparent;border: 1px solid #4285f4;color: #4285f4;border-radius: 4px;line-height: 20px;padding: 4px 8px;">Click to Refresh<br>点 击 刷 新</button>
<button onclick="window.location.reload()" id="loadingRefresh"
style="display: none;position: absolute;bottom: 16px;background: transparent;border: 1px solid #4285f4;color: #4285f4;border-radius: 4px;line-height: 20px;padding: 4px 8px;">
Click to Refresh<br>点 击 刷 新
</button>
</div>
<div id="toolbar" class="toolbar fn__flex"></div>
<div class="fn__flex-1 fn__flex">
@ -24,12 +27,12 @@
<div id="commonMenu" class="b3-menu fn__none"></div>
<div id="message" class="b3-snackbars"></div>
<script>
setTimeout(() => {
const refreshElement = document.getElementById("loadingRefresh")
if (refreshElement) {
refreshElement.style.display = ""
}
}, 2000)
setTimeout(() => {
const refreshElement = document.getElementById("loadingRefresh")
if (refreshElement) {
refreshElement.style.display = ""
}
}, 2000)
</script>
</body>
</html>

View file

@ -18,7 +18,7 @@ import {needSubscribe} from "../util/needSubscribe";
export const lockScreen = () => {
if (window.siyuan.config.readonly) {
return
return;
}
/// #if BROWSER
fetchPost("/api/system/logoutAuth", {}, () => {

View file

@ -18,7 +18,7 @@ export const mermaidRender = (element: Element, cdn = Constants.PROTYLE_CDN) =>
if (mermaidElements.length === 0) {
return;
}
addScript(`${cdn}/js/mermaid/mermaid.min.js?v=9.3.0`, "protyleMermaidScript").then(() => {
addScript(`${cdn}/js/mermaid/mermaid.min.js?v=9.4.3`, "protyleMermaidScript").then(() => {
const config: any = {
securityLevel: "loose", // 升级后无 https://github.com/siyuan-note/siyuan/issues/3587可使用该选项
altFontFamily: "sans-serif",