mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-26 19:38:48 +01:00
🐛 超级块内递归嵌入的嵌入块不应该显示面包屑 https://github.com/siyuan-note/siyuan/issues/7575
This commit is contained in:
parent
72ebcf3b98
commit
67014d2ada
1 changed files with 1 additions and 14 deletions
|
|
@ -547,20 +547,7 @@ func getEmbeddedBlock(embedBlockID string, trees map[string]*parse.Tree, sqlBloc
|
|||
block = &Block{Box: def.Box, Path: def.Path, HPath: b.HPath, ID: def.ID, Type: def.Type.String(), Content: dom, Markdown: content /* 这里使用 Markdown 字段来临时存储 content */}
|
||||
|
||||
if breadcrumb {
|
||||
// 位于超级块中的嵌入块不显示面包屑 https://github.com/siyuan-note/siyuan/issues/6258
|
||||
// 但是这里后端无法判断递归嵌入的情况,所以还是需要前端判断 breadcrumb
|
||||
// 超级块内递归嵌入的嵌入块不应该显示面包屑 https://github.com/siyuan-note/siyuan/issues/7575
|
||||
|
||||
inSuperBlock := false
|
||||
embedNodeTree, _ := loadTreeByBlockID(embedBlockID)
|
||||
if nil != embedNodeTree {
|
||||
embedNode := treenode.GetNodeInTree(embedNodeTree, embedBlockID)
|
||||
inSuperBlock = nil != embedNode && embedNode.ParentIs(ast.NodeSuperBlock)
|
||||
}
|
||||
|
||||
if !inSuperBlock {
|
||||
blockPaths = buildBlockBreadcrumb(def, nil)
|
||||
}
|
||||
blockPaths = buildBlockBreadcrumb(def, nil)
|
||||
}
|
||||
if 1 > len(blockPaths) {
|
||||
blockPaths = []*BlockPath{}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue