Merge remote-tracking branch 'origin/dev' into dev

This commit is contained in:
Vanessa 2024-01-12 20:09:10 +08:00
commit a92be962d4
5 changed files with 7 additions and 7 deletions

File diff suppressed because one or more lines are too long

View file

@ -489,7 +489,7 @@ func broadcastTransactions(transactions []*model.Transaction) {
func dataBlockDOM(data string, luteEngine *lute.Lute) (ret string, err error) {
luteEngine.SetHTMLTag2TextMark(true) // API `/api/block/**` 无法使用 `<u>foo</u>` 与 `<kbd>bar</kbd>` 插入/更新行内元素 https://github.com/siyuan-note/siyuan/issues/6039
ret, tree := luteEngine.Md2BlockDOM(data, true)
ret, tree := luteEngine.Md2BlockDOMTree(data, true)
if "" == ret {
// 使用 API 插入空字符串出现错误 https://github.com/siyuan-note/siyuan/issues/3931
blankParagraph := treenode.NewParagraph()

View file

@ -9,7 +9,7 @@ require (
github.com/88250/clipboard v0.1.5
github.com/88250/epub v0.0.0-20230830085737-c19055cd1f48
github.com/88250/gulu v1.2.3-0.20231209020950-b7b6994e395c
github.com/88250/lute v1.7.6-0.20240111024801-7e083278df4e
github.com/88250/lute v1.7.6-0.20240112115240-51ac39f8bb30
github.com/88250/pdfcpu v0.3.14-0.20230401044135-c7369a99720c
github.com/88250/vitess-sqlparser v0.0.0-20210205111146-56a2ded2aba1
github.com/ClarkThan/ahocorasick v0.0.0-20231011042242-30d1ef1347f4

View file

@ -10,8 +10,8 @@ github.com/88250/go-sqlite3 v1.14.13-0.20231214121541-e7f54c482950 h1:Pa5hMiBceT
github.com/88250/go-sqlite3 v1.14.13-0.20231214121541-e7f54c482950/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU=
github.com/88250/gulu v1.2.3-0.20231209020950-b7b6994e395c h1:Fas3hxqP33xA9KKDV50jUmppiiOukk5bdV00Hk5VSSk=
github.com/88250/gulu v1.2.3-0.20231209020950-b7b6994e395c/go.mod h1:pTWnjt+6qUqNnP9xltswsJxgCBVu3C7eW09u48LWX0k=
github.com/88250/lute v1.7.6-0.20240111024801-7e083278df4e h1:fN0BYXgu8iqPO705kesomO3E/5cENwVLerwbYmMnTps=
github.com/88250/lute v1.7.6-0.20240111024801-7e083278df4e/go.mod h1:+wUqx/1kdFDbWtxn9LYJlaCOAeol2pjSO6w+WJTVQsg=
github.com/88250/lute v1.7.6-0.20240112115240-51ac39f8bb30 h1:il3u207XuRGQw/Wf0QCzi3sl4Tj7TmnPAgDNLDmmas0=
github.com/88250/lute v1.7.6-0.20240112115240-51ac39f8bb30/go.mod h1:+wUqx/1kdFDbWtxn9LYJlaCOAeol2pjSO6w+WJTVQsg=
github.com/88250/pdfcpu v0.3.14-0.20230401044135-c7369a99720c h1:Dl/8S9iLyPMTElnWIBxmjaLiWrkI5P4a21ivwAn5pU0=
github.com/88250/pdfcpu v0.3.14-0.20230401044135-c7369a99720c/go.mod h1:S5YT38L/GCjVjmB4PB84PymA1qfopjEhfhTNQilLpv4=
github.com/88250/vitess-sqlparser v0.0.0-20210205111146-56a2ded2aba1 h1:48T899JQDwyyRu9yXHePYlPdHtpJfrJEUGBMH3SMBWY=

View file

@ -1009,7 +1009,7 @@ func CreateDocByMd(boxID, p, title, md string, sorts []string) (tree *parse.Tree
}
luteEngine := util.NewLute()
dom, _ := luteEngine.Md2BlockDOM(md, false)
dom := luteEngine.Md2BlockDOM(md, false)
tree, err = createDoc(box.ID, p, title, dom)
if nil != err {
return
@ -1032,7 +1032,7 @@ func CreateWithMarkdown(boxID, hPath, md, parentID, id string) (retID string, er
WaitForWritingFiles()
luteEngine := util.NewLute()
dom, _ := luteEngine.Md2BlockDOM(md, false)
dom := luteEngine.Md2BlockDOM(md, false)
retID, err = createDocsByHPath(box.ID, hPath, dom, parentID, id)
WaitForWritingFiles()
return