mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-09-22 00:20:47 +02:00
🎨 Improve exporting block ref https://github.com/siyuan-note/siyuan/issues/13283
This commit is contained in:
parent
855b1945de
commit
a7ee282044
2 changed files with 68 additions and 3 deletions
|
@ -103,6 +103,13 @@ func IsBlockRef(n *ast.Node) bool {
|
|||
return ast.NodeTextMark == n.Type && n.IsTextMarkType("block-ref")
|
||||
}
|
||||
|
||||
func IsBlockLink(n *ast.Node) bool {
|
||||
if nil == n {
|
||||
return false
|
||||
}
|
||||
return ast.NodeTextMark == n.Type && n.IsTextMarkType("a") && strings.HasPrefix(n.TextMarkAHref, "siyuan://blocks/")
|
||||
}
|
||||
|
||||
func IsFileAnnotationRef(n *ast.Node) bool {
|
||||
if nil == n {
|
||||
return false
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue