Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:rotating_light:

Vanessadaf043bd0c6d
diff --git a/app/src/config/about.ts b/app/src/config/about.ts
index dfc9afa8b2..0600762177 100644
--- a/app/src/config/about.ts
+++ b/app/src/config/about.ts
@@ -204,7 +204,7 @@ export const about = {
tokenElement.addEventListener("change", () => {
fetchPost("/api/system/setAPIToken", {token: tokenElement.value}, () => {
window.siyuan.config.api.token = tokenElement.value;
- about.element.querySelector("#tokenTip").innerHTML = window.siyuan.languages.about14.replace("${token}", window.siyuan.config.api.token)
+ about.element.querySelector("#tokenTip").innerHTML = window.siyuan.languages.about14.replace("${token}", window.siyuan.config.api.token);
});
});
about.element.querySelector("#exportLog").addEventListener("click", () => {
diff --git a/app/src/layout/dock/Outline.ts b/app/src/layout/dock/Outline.ts
index a03ae76d06..76dd8c0ad9 100644
--- a/app/src/layout/dock/Outline.ts
+++ b/app/src/layout/dock/Outline.ts
@@ -279,10 +279,10 @@ export class Outline extends Model {
if (selectItem) {
getAllModels().editor.find(editItem => {
if (editItem.editor.protyle.block.rootID === this.blockId) {
- let previousID
- let parentID
- const undoPreviousID = item.previousElementSibling?.getAttribute("data-node-id")
- const undoParentID = item.parentElement.previousElementSibling?.getAttribute("data-node-id")
+ let previousID;
+ let parentID;
+ const undoPreviousID = item.previousElementSibling?.getAttribute("data-node-id");
+ const undoParentID = item.parentElement.previousElementSibling?.getAttribute("data-node-id");
if (selectItem.classList.contains("dragover")) {
parentID = selectItem.getAttribute("data-node-id");
if (selectItem.nextElementSibling && selectItem.nextElementSibling.tagName === "UL") {
diff --git a/app/src/menus/protyle.ts b/app/src/menus/protyle.ts
index 144f4a6e82..3f6eadc903 100644
--- a/app/src/menus/protyle.ts
+++ b/app/src/menus/protyle.ts
@@ -836,7 +836,7 @@ export const zoomOut = (options: {
const focusElement = options.protyle.wysiwyg.element.querySelector(`[data-node-id="${options.focusId}"]`);
if (focusElement) {
// 退出聚焦后块在折叠中 https://github.com/siyuan-note/siyuan/issues/10746
- let showElement = focusElement
+ let showElement = focusElement;
while (showElement.getBoundingClientRect().height === 0) {
showElement = showElement.parentElement;
}
diff --git a/app/src/mobile/settings/about.ts b/app/src/mobile/settings/about.ts
index a16c2458dd..58b5d50389 100644
--- a/app/src/mobile/settings/about.ts
+++ b/app/src/mobile/settings/about.ts
@@ -367,7 +367,7 @@ export const initAbout = () => {
tokenElement.addEventListener("change", () => {
fetchPost("/api/system/setAPIToken", {token: tokenElement.value}, () => {
window.siyuan.config.api.token = tokenElement.value;
- modelMainElement.querySelector("#tokenTip").innerHTML = window.siyuan.languages.about14.replace("${token}", window.siyuan.config.api.token)
+ modelMainElement.querySelector("#tokenTip").innerHTML = window.siyuan.languages.about14.replace("${token}", window.siyuan.config.api.token);
});
});
}
diff --git a/app/src/protyle/render/av/calc.ts b/app/src/protyle/render/av/calc.ts
index 559fee18a6..844ff9911f 100644
--- a/app/src/protyle/render/av/calc.ts
+++ b/app/src/protyle/render/av/calc.ts
@@ -251,11 +251,11 @@ export const openCalcMenu = async (protyle: IProtyle, calcElement: HTMLElement,
target: calcElement
});
}
- let rollupIsNumber = false
+ let rollupIsNumber = false;
if (type === "rollup") {
- let relationKeyID: string
- let keyID: string
- let avData = panelData?.data
+ let relationKeyID: string;
+ let keyID: string;
+ let avData = panelData?.data;
if (!avData) {
const avResponse = await fetchSyncPost("api/av/renderAttributeView", {id: avId});
avData = avResponse.data;
@@ -264,25 +264,25 @@ export const openCalcMenu = async (protyle: IProtyle, calcElement: HTMLElement,
if (item.id === colId) {
relationKeyID = item.rollup?.relationKeyID;
keyID = item.rollup?.keyID;
- return true
+ return true;
}
- })
+ });
if (relationKeyID && keyID) {
- let relationAvId: string
+ let relationAvId: string;
avData.view.columns.find((item) => {
if (item.id === relationKeyID) {
relationAvId = item.relation?.avID;
- return true
+ return true;
}
- })
+ });
if (relationAvId) {
- const colResponse = await fetchSyncPost("api/av/getAttributeView", {id: relationAvId})
+ const colResponse = await fetchSyncPost("api/av/getAttributeView", {id: relationAvId});
colResponse.data.av.keyValues.find((item: { key: { id: string, name: string, type: TAVCol } }) => {
if (item.key.id === keyID) {
- rollupIsNumber = item.key.type === "number"
- return true
+ rollupIsNumber = item.key.type === "number";
+ return true;
}
- })
+ });
}
}
}
diff --git a/app/src/protyle/upload/index.ts b/app/src/protyle/upload/index.ts
index cf512af77c..f62da2be8e 100644
--- a/app/src/protyle/upload/index.ts
+++ b/app/src/protyle/upload/index.ts
@@ -168,12 +168,12 @@ export const uploadLocalFiles = (files: string[], protyle: IProtyle, isUpload: b
id: protyle.block.rootID
}, (response) => {
hideMessage(msgId);
- let tip = ""
+ let tip = "";
Object.keys(response.data.succMap).forEach(name => {
if (response.data.succMap[name].startsWith("file:")) {
- tip += name + ", "
+ tip += name + ", ";
}
- })
+ });
if (tip) {
showMessage(window.siyuan.languages.dndFolderTip.replace("${x}", `<b>${tip.substring(0, tip.length - 2)}</b>`));
}