Skip to content

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

:rotating_light:

Vanessad1851255af76
diff --git a/app/src/layout/Wnd.ts b/app/src/layout/Wnd.ts
index e9473435bb..d0e79a5596 100644
--- a/app/src/layout/Wnd.ts
+++ b/app/src/layout/Wnd.ts
@@ -416,7 +416,7 @@ export class Wnd {
public switchTab(target: HTMLElement, pushBack = false, update = true, resize = true, isSaveLayout = true) {
let currentTab: Tab;
- let isInitActive = false
+ let isInitActive = false;
this.children.forEach((item) => {
if (target === item.headElement) {
if (item.headElement && item.headElement.classList.contains("fn__none")) {
diff --git a/app/src/layout/util.ts b/app/src/layout/util.ts
index 7ce24a0286..49298de7bc 100644
--- a/app/src/layout/util.ts
+++ b/app/src/layout/util.ts
@@ -493,13 +493,13 @@ export const JSONToLayout = (app: App, isStart: boolean) => {
zoomIn: idZoomIn.isZoomIn
});
} else {
- let latestTabHeaderElement:HTMLElement
+ let latestTabHeaderElement:HTMLElement;
document.querySelectorAll('li[data-type="tab-header"][data-init-active="true"]').forEach((item: HTMLElement) => {
if (!latestTabHeaderElement) {
- latestTabHeaderElement = item
+ latestTabHeaderElement = item;
} else {
if (item.dataset.activetime > latestTabHeaderElement.dataset.activetime) {
- latestTabHeaderElement = item
+ latestTabHeaderElement = item;
}
}
const tab = getInstanceById(item.getAttribute("data-id")) as Tab;
diff --git a/app/src/protyle/render/av/col.ts b/app/src/protyle/render/av/col.ts
index 99c8ff0f66..3b44e02bca 100644
--- a/app/src/protyle/render/av/col.ts
+++ b/app/src/protyle/render/av/col.ts
@@ -848,12 +848,12 @@ export const showColMenu = (protyle: IProtyle, blockElement: Element, cellElemen
label: window.siyuan.languages.delete,
async click() {
if (type === "relation") {
- const response = await fetchSyncPost("/api/av/getAttributeView", {id: avID})
+ const response = await fetchSyncPost("/api/av/getAttributeView", {id: avID});
const colData = response.data.av.keyValues.find((item: {
key: { id: string }
}) => item.key.id === colId);
if (colData.key.relation?.isTwoWay) {
- const relResponse = await fetchSyncPost("/api/av/getAttributeView", {id: colData.key.relation.avID})
+ const relResponse = await fetchSyncPost("/api/av/getAttributeView", {id: colData.key.relation.avID});
const dialog = new Dialog({
title: window.siyuan.languages.removeCol.replace("${x}", colData.key.name),
content: `<div class="b3-dialog__content">
@@ -880,7 +880,7 @@ export const showColMenu = (protyle: IProtyle, blockElement: Element, cellElemen
cellElement,
blockElement,
removeDest: true
- })
+ });
dialog.destroy();
break;
} else if (target.classList.contains("b3-button--warning")) {
@@ -894,7 +894,7 @@ export const showColMenu = (protyle: IProtyle, blockElement: Element, cellElemen
cellElement,
blockElement,
removeDest: false
- })
+ });
dialog.destroy();
break;
} else if (target.classList.contains("b3-button--info")) {
@@ -903,8 +903,8 @@ export const showColMenu = (protyle: IProtyle, blockElement: Element, cellElemen
}
target = target.parentElement;
}
- })
- return
+ });
+ return;
}
}
removeColByMenu({
@@ -917,7 +917,7 @@ export const showColMenu = (protyle: IProtyle, blockElement: Element, cellElemen
cellElement,
blockElement,
removeDest: false
- })
+ });
}
});
menu.addSeparator();
@@ -992,7 +992,7 @@ const removeColByMenu = (options: {
}]);
removeAttrViewColAnimation(options.blockElement, options.colId);
options.blockElement.setAttribute("updated", newUpdated);
-}
+};
export const removeCol = (options: {
protyle: IProtyle,
@@ -1048,7 +1048,7 @@ export const removeCol = (options: {
options.tabRect.right - options.menuElement.clientWidth, options.tabRect.bottom,
options.tabRect.height);
}
-}
+};
const genUpdateColItem = (type: TAVCol, oldType: TAVCol) => {
return `<button class="b3-menu__item" data-type="updateColType" data-old-type="${oldType}" data-new-type="${type}">
diff --git a/app/src/protyle/render/av/openMenuPanel.ts b/app/src/protyle/render/av/openMenuPanel.ts
index 1dbc8a0b4e..e13c0149da 100644
--- a/app/src/protyle/render/av/openMenuPanel.ts
+++ b/app/src/protyle/render/av/openMenuPanel.ts
@@ -1092,7 +1092,7 @@ export const openMenuPanel = (options: {
return true;
}
});
- const isTwoWay = colData.type === "relation" && colData.relation?.isTwoWay
+ const isTwoWay = colData.type === "relation" && colData.relation?.isTwoWay;
if (isCustomAttr || isTwoWay) {
const dialog = new Dialog({
title: isTwoWay ? window.siyuan.languages.removeCol.replace("${x}", menuElement.querySelector("input").value) : window.siyuan.languages.deleteOpConfirm,
@@ -1145,7 +1145,7 @@ export const openMenuPanel = (options: {
}
target = target.parentElement;
}
- })
+ });
} else {
removeCol({
protyle: options.protyle,