From 084ddfd389232047ffb52d67f48cbd68116e2b7b Mon Sep 17 00:00:00 2001 From: Daniel <845765@qq.com> Date: Sat, 7 Jun 2025 10:26:20 +0800 Subject: [PATCH 1/2] :art: Add .cs file to assets search index https://github.com/siyuan-note/siyuan/issues/14983 --- app/src/constants.ts | 2 +- kernel/model/asset_content.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/constants.ts b/app/src/constants.ts index b028cb476..677b6131a 100644 --- a/app/src/constants.ts +++ b/app/src/constants.ts @@ -701,7 +701,7 @@ export abstract class Constants { public static readonly SIYUAN_ASSETS_EXTS: string[] = [".pdf"].concat(Constants.SIYUAN_ASSETS_IMAGE).concat(Constants.SIYUAN_ASSETS_AUDIO).concat(Constants.SIYUAN_ASSETS_VIDEO); public static readonly SIYUAN_ASSETS_SEARCH: string[] = [".txt", ".md", ".markdown", ".docx", ".xlsx", ".pptx", ".pdf", ".json", ".log", ".sql", ".html", ".xml", ".java", ".h", ".c", ".cpp", ".go", ".rs", ".swift", ".kt", ".py", ".php", ".js", ".css", ".ts", ".sh", ".bat", ".cmd", ".ini", ".yaml", - ".rst", ".adoc", ".textile", ".opml", ".org", ".wiki", ".epub"]; + ".rst", ".adoc", ".textile", ".opml", ".org", ".wiki", ".epub", ".cs"]; // protyle public static readonly SIYUAN_CONFIG_APPEARANCE_DARK_CODE: string[] = ["a11y-dark", "agate", "an-old-hope", "androidstudio", diff --git a/kernel/model/asset_content.go b/kernel/model/asset_content.go index ab52f6a7a..b6ad30f5c 100644 --- a/kernel/model/asset_content.go +++ b/kernel/model/asset_content.go @@ -475,6 +475,7 @@ func NewAssetsSearcher() *AssetsSearcher { ".opml": txtAssetParser, ".org": txtAssetParser, ".wiki": txtAssetParser, + ".cs": txtAssetParser, ".docx": &DocxAssetParser{}, ".pptx": &PptxAssetParser{}, ".xlsx": &XlsxAssetParser{}, From a37e23bf5f9870f6ad0e3f5e2a0583052270931f Mon Sep 17 00:00:00 2001 From: Daniel <845765@qq.com> Date: Sat, 7 Jun 2025 10:43:46 +0800 Subject: [PATCH 2/2] :art: The toolbar content cannot be slid on Android https://github.com/siyuan-note/siyuan/issues/14979 --- app/src/mobile/util/keyboardToolbar.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/src/mobile/util/keyboardToolbar.ts b/app/src/mobile/util/keyboardToolbar.ts index ee9089330..9847531b1 100644 --- a/app/src/mobile/util/keyboardToolbar.ts +++ b/app/src/mobile/util/keyboardToolbar.ts @@ -521,13 +521,15 @@ export const initKeyboardToolbar = () => {
`; let startY = 0; + let startX = 0; let moved = false; toolbarElement.addEventListener("touchstart", e => { startY = e.touches[0].clientY; + startX = e.touches[0].clientX; moved = false; }); toolbarElement.addEventListener("touchmove", e => { - if (Math.abs(e.touches[0].clientY - startY) > 10) { + if (Math.abs(e.touches[0].clientY - startY) > 10 || Math.abs(e.touches[0].clientX - startX) > 10) { moved = true; } });