Skip to content

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

:bug: Export .sy.zip doc title image is not exported Fix https://github.com/siyuan-note/siyuan/issues/8748

Daniel19f233b5105d
diff --git a/kernel/model/export.go b/kernel/model/export.go
index 676f37e742..a2c7d4153f 100644
--- a/kernel/model/export.go
+++ b/kernel/model/export.go
@@ -1225,6 +1225,11 @@ func exportSYZip(boxID, rootDirPath, baseFolderName string, docPaths []string) (
for _, tree := range trees {
var assets []string
assets = append(assets, assetsLinkDestsInTree(tree)...)
+ titleImgPath := treenode.GetDocTitleImgPath(tree.Root) // Export .sy.zip doc title image is not exported https://github.com/siyuan-note/siyuan/issues/8748
+ if "" != titleImgPath {
+ assets = append(assets, titleImgPath)
+ }
+
for _, asset := range assets {
asset = string(html.DecodeDestination([]byte(asset)))
if strings.Contains(asset, "?") {