Skip to content

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

:art: Improve exporting Markdown https://github.com/siyuan-note/siyuan/issues/13273

Danielda1b97f70c2a
diff --git a/kernel/model/export.go b/kernel/model/export.go
index f0fba8e5d0..8b58eb25af 100644
--- a/kernel/model/export.go
+++ b/kernel/model/export.go
@@ -1984,6 +1984,7 @@ func exportMarkdownContent0(tree *parse.Tree, cloudAssetsBase string, assetsDest
href += "#" + defID
}
}
+ href = util.FilterFilePath(href)
blockRefLink := &ast.Node{Type: ast.NodeTextMark, TextMarkType: "a", TextMarkTextContent: linkText, TextMarkAHref: href}
blockRefLink.KramdownIAL = n.KramdownIAL
n.InsertBefore(blockRefLink)