diff --git a/app/src/protyle/upload/index.ts b/app/src/protyle/upload/index.ts index 0bf4575fc..747a8dc7a 100644 --- a/app/src/protyle/upload/index.ts +++ b/app/src/protyle/upload/index.ts @@ -106,7 +106,7 @@ const genUploadedLabel = (responseText: string, protyle: IProtyle) => { range.collapse(false); } // https://github.com/siyuan-note/siyuan/issues/7624 - const nodeElement = hasClosestBlock(range.startContainer) + const nodeElement = hasClosestBlock(range.startContainer); if (nodeElement) { if (nodeElement.classList.contains("table")) { insertBlock = false; diff --git a/app/src/search/util.ts b/app/src/search/util.ts index d0c5b6f52..361c12f65 100644 --- a/app/src/search/util.ts +++ b/app/src/search/util.ts @@ -1121,24 +1121,24 @@ const renderNextSearchMark = (options: { edit: Protyle, target: Element, }) => { - let matchElement + let matchElement; const allMatchElements = Array.from(options.edit.protyle.wysiwyg.element.querySelectorAll(`div[data-node-id="${options.id}"] span[data-type~="search-mark"]`)); allMatchElements.find((item, itemIndex) => { if (item.classList.contains("search-mark--hl")) { - item.classList.remove("search-mark--hl") - matchElement = allMatchElements[itemIndex + 1] + item.classList.remove("search-mark--hl"); + matchElement = allMatchElements[itemIndex + 1]; return; } - }) + }); if (!matchElement) { - matchElement = allMatchElements[0] + matchElement = allMatchElements[0]; } if (matchElement) { matchElement.classList.add("search-mark--hl"); const contentRect = options.edit.protyle.contentElement.getBoundingClientRect(); options.edit.protyle.contentElement.scrollTop = options.edit.protyle.contentElement.scrollTop + matchElement.getBoundingClientRect().top - contentRect.top - contentRect.height / 2; } -} +}; const getArticle = (options: { id: string, k: string, diff --git a/app/src/window/index.ts b/app/src/window/index.ts index c05b6ed5e..3a9897216 100644 --- a/app/src/window/index.ts +++ b/app/src/window/index.ts @@ -9,7 +9,6 @@ import {fetchGet, fetchPost} from "../util/fetch"; import {addBaseURL, setNoteBook} from "../util/pathName"; import {openFileById} from "../editor/util"; import { - downloadProgress, processSync, progressBackgroundTask, progressLoading, progressStatus,