mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
🎨 Improve av https://github.com/siyuan-note/siyuan/issues/15643
This commit is contained in:
parent
f8bccc2d9f
commit
83af400f65
2 changed files with 11 additions and 4 deletions
|
|
@ -184,14 +184,16 @@ func hideEmptyGroupViews(view *av.View, viewable av.Viewable) {
|
|||
return
|
||||
}
|
||||
|
||||
groupHidden := viewable.GetGroupHidden()
|
||||
if !view.Group.HideEmpty {
|
||||
if 2 != viewable.GetGroupHidden() {
|
||||
if 2 != groupHidden {
|
||||
viewable.SetGroupHidden(0)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
if 1 == viewable.GetGroupHidden() && 0 < viewable.(av.Collection).CountItems() {
|
||||
itemCount := viewable.(av.Collection).CountItems()
|
||||
if 1 == groupHidden && 0 < itemCount {
|
||||
viewable.SetGroupHidden(0)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue