🐛 Copying blocks without copying attributes https://github.com/siyuan-note/siyuan/issues/15268

This commit is contained in:
Daniel 2025-07-15 17:22:00 +08:00
parent dda4634126
commit 62f0f05cef
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
4 changed files with 7 additions and 6 deletions

View file

@ -63,6 +63,7 @@ func html2BlockDOM(c *gin.Context) {
dom := arg["dom"].(string)
luteEngine := util.NewLute()
luteEngine.SetHTMLTag2TextMark(true)
luteEngine.SetHTML2MarkdownAttrs([]string{"name", "alias", "memo", "bookmark", "custom-*"})
markdown, withMath, err := model.HTML2Markdown(dom, luteEngine)
if err != nil {
ret.Data = "Failed to convert"