From 1ce7f2c9b68d74df67321dc596f46208b3a45400 Mon Sep 17 00:00:00 2001 From: Daniel <845765@qq.com> Date: Mon, 22 Sep 2025 16:52:33 +0800 Subject: [PATCH 1/4] :bug: Outline drag function is abnormal https://github.com/siyuan-note/siyuan/issues/15909 Signed-off-by: Daniel <845765@qq.com> --- kernel/model/outline.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/kernel/model/outline.go b/kernel/model/outline.go index 4e819d511..d5f67f646 100644 --- a/kernel/model/outline.go +++ b/kernel/model/outline.go @@ -90,9 +90,9 @@ func (tx *Transaction) doMoveOutlineHeading(operation *Operation) (ret *TxErr) { } for _, h := range headingChildren { - if h.ID == targetNode.ID { - // 目标节点是当前标题的子节点,不需要移动 - return + if h.ID == targetNode.ID { // 目标节点是当前标题的子节点 + // 尝试重新计算目标节点:使用当前标题的前一个节点 + targetNode = heading.Previous } } From bba500508f1774442acd68b95857b6826709983c Mon Sep 17 00:00:00 2001 From: Daniel <845765@qq.com> Date: Mon, 22 Sep 2025 16:53:53 +0800 Subject: [PATCH 2/4] :bug: Outline drag function is abnormal https://github.com/siyuan-note/siyuan/issues/15909 Signed-off-by: Daniel <845765@qq.com> --- kernel/model/outline.go | 1 - 1 file changed, 1 deletion(-) diff --git a/kernel/model/outline.go b/kernel/model/outline.go index d5f67f646..b3ce1aa3c 100644 --- a/kernel/model/outline.go +++ b/kernel/model/outline.go @@ -91,7 +91,6 @@ func (tx *Transaction) doMoveOutlineHeading(operation *Operation) (ret *TxErr) { for _, h := range headingChildren { if h.ID == targetNode.ID { // 目标节点是当前标题的子节点 - // 尝试重新计算目标节点:使用当前标题的前一个节点 targetNode = heading.Previous } } From e2d0a0051df8ec04c1d4a80dffb90f1424d5ffb6 Mon Sep 17 00:00:00 2001 From: Daniel <845765@qq.com> Date: Mon, 22 Sep 2025 19:32:24 +0800 Subject: [PATCH 3/4] :memo: Update changelogs Signed-off-by: Daniel <845765@qq.com> --- app/changelogs/v3.3.3/v3.3.3.md | 2 ++ app/changelogs/v3.3.3/v3.3.3_zh_CHT.md | 2 ++ app/changelogs/v3.3.3/v3.3.3_zh_CN.md | 2 ++ 3 files changed, 6 insertions(+) diff --git a/app/changelogs/v3.3.3/v3.3.3.md b/app/changelogs/v3.3.3/v3.3.3.md index 46f61eb2f..29a0c63e0 100644 --- a/app/changelogs/v3.3.3/v3.3.3.md +++ b/app/changelogs/v3.3.3/v3.3.3.md @@ -36,6 +36,7 @@ Below are the detailed changes in this version. * [Improve font loading](https://github.com/siyuan-note/siyuan/issues/15879) * [Improve document opening compatibility](https://github.com/siyuan-note/siyuan/issues/15885) * [Improve dynamic loading to prevent continuous automatic loading in certain situations](https://github.com/siyuan-note/siyuan/issues/15889) +* [Improve the judgment of editable blocks and the escape processing of HTML blocks](https://github.com/siyuan-note/siyuan/issues/15904) ### Bugfix @@ -48,6 +49,7 @@ Below are the detailed changes in this version. * [`Optimize typography` exception when code block contains ```](https://github.com/siyuan-note/siyuan/issues/15843) * [`Add to Database` shows databases that are not in the document](https://github.com/siyuan-note/siyuan/issues/15847) * [An error occurs when inserting a tag using a mouse click](https://github.com/siyuan-note/siyuan/issues/15867) +* [Outline drag function is abnormal](https://github.com/siyuan-note/siyuan/issues/15909) ### Development diff --git a/app/changelogs/v3.3.3/v3.3.3_zh_CHT.md b/app/changelogs/v3.3.3/v3.3.3_zh_CHT.md index adc6bdcee..5dbe2bcfb 100644 --- a/app/changelogs/v3.3.3/v3.3.3_zh_CHT.md +++ b/app/changelogs/v3.3.3/v3.3.3_zh_CHT.md @@ -36,6 +36,7 @@ * [改進字體載入](https://github.com/siyuan-note/siyuan/issues/15879) * [改進開啟文件相容性](https://github.com/siyuan-note/siyuan/issues/15885) * [改進文件動態加載,防止在特定情況下持續自動加載](https://github.com/siyuan-note/siyuan/issues/15889) +* [改進可編輯區塊的判斷和 HTML 區塊的轉義處理](https://github.com/siyuan-note/siyuan/issues/15904) ### 修復缺陷 @@ -48,6 +49,7 @@ * [程式碼區塊包含 ``` 時「最佳化排版」異常](https://github.com/siyuan-note/siyuan/issues/15843) * [「新增至資料庫」會顯示不在文件中的資料庫](https://github.com/siyuan-note/siyuan/issues/15847) * [滑鼠點選插入標籤時報錯誤](https://github.com/siyuan-note/siyuan/issues/15867) +* [大綱拖曳功能異常](https://github.com/siyuan-note/siyuan/issues/15909) ### 開發者 diff --git a/app/changelogs/v3.3.3/v3.3.3_zh_CN.md b/app/changelogs/v3.3.3/v3.3.3_zh_CN.md index 22c06c7b8..07a62d86e 100644 --- a/app/changelogs/v3.3.3/v3.3.3_zh_CN.md +++ b/app/changelogs/v3.3.3/v3.3.3_zh_CN.md @@ -36,6 +36,7 @@ * [改进字体加载](https://github.com/siyuan-note/siyuan/issues/15879) * [改进打开文档兼容性](https://github.com/siyuan-note/siyuan/issues/15885) * [改进文档动态加载,防止特定情况下持续自动加载](https://github.com/siyuan-note/siyuan/issues/15889) +* [改进可编辑块的判断和 HTML 块的转义处理](https://github.com/siyuan-note/siyuan/issues/15904) ### 修复缺陷 @@ -48,6 +49,7 @@ * [代码块包含 ``` 时“优化排版”异常](https://github.com/siyuan-note/siyuan/issues/15843) * [“添加到数据库”会显示不在文档中的数据库](https://github.com/siyuan-note/siyuan/issues/15847) * [鼠标点击插入标签时报错](https://github.com/siyuan-note/siyuan/issues/15867) +* [大纲拖动功能异常](https://github.com/siyuan-note/siyuan/issues/15909) ### 开发者 From 6e9d474bbe87c33cc3c88152a531515924066592 Mon Sep 17 00:00:00 2001 From: Daniel <845765@qq.com> Date: Mon, 22 Sep 2025 19:54:12 +0800 Subject: [PATCH 4/4] :art: https://github.com/siyuan-note/siyuan/issues/15910 Signed-off-by: Daniel <845765@qq.com> --- kernel/av/filter.go | 12 +++++++++--- kernel/model/attribute_view.go | 9 +++++++++ 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/kernel/av/filter.go b/kernel/av/filter.go index c47dc17fd..61fd32293 100644 --- a/kernel/av/filter.go +++ b/kernel/av/filter.go @@ -287,9 +287,15 @@ func (value *Value) Filter(filter *ViewFilter, attrView *AttributeView, itemID s for _, asset := range value.MAsset { switch asset.Type { case AssetTypeFile: - if filterTextContent(filter.Operator, asset.Name, filter.Value.MAsset[0].Content) || - filterTextContent(filter.Operator, asset.Content, filter.Value.MAsset[0].Content) { - return false + if "" != strings.TrimSpace(asset.Name) { + if filterTextContent(filter.Operator, asset.Name, filter.Value.MAsset[0].Content) { + return false + } + } + if "" != strings.TrimSpace(asset.Content) { + if filterTextContent(filter.Operator, asset.Content, filter.Value.MAsset[0].Content) { + return false + } } case AssetTypeImage: if filterTextContent(filter.Operator, asset.Content, filter.Value.MAsset[0].Content) { diff --git a/kernel/model/attribute_view.go b/kernel/model/attribute_view.go index 86c79dfeb..64c308232 100644 --- a/kernel/model/attribute_view.go +++ b/kernel/model/attribute_view.go @@ -186,6 +186,15 @@ func getAttrViewAddingBlockDefaultValues(attrView *av.AttributeView, view, group continue } + if av.KeyTypeMAsset == keyValues.Key.Type { + if nil != nearItem { + if _, ok := ret[keyValues.Key.ID]; !ok { + ret[keyValues.Key.ID] = getNewValueByNearItem(nearItem, keyValues.Key, addingItemID) + } + } + return + } + newValue := filter.GetAffectValue(keyValues.Key, addingItemID) if nil == newValue { newValue = getNewValueByNearItem(nearItem, keyValues.Key, addingItemID)