Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 46c9db9

Browse filesBrowse files
committed
fix(CSidebarNav): CNavGroup behavior
1 parent 60d84ee commit 46c9db9
Copy full SHA for 46c9db9

File tree

Expand file treeCollapse file tree

2 files changed

+3
-3
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+3
-3
lines changed

‎src/components/nav/CNavGroup.ts

Copy file name to clipboardExpand all lines: src/components/nav/CNavGroup.ts
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ const CNavGroup = defineComponent({
1212
*/
1313
visible: {
1414
type: Boolean,
15-
default: false,
15+
default: undefined,
1616
required: false,
1717
},
1818
},
@@ -127,7 +127,7 @@ const CNavGroup = defineComponent({
127127
return h(vnode, {
128128
onVisibleChange: (visible: boolean) =>
129129
handleVisibleChange(visible, index),
130-
visible: isVisible(index),
130+
...(visibleGroup.value && { visible: isVisible(index) }),
131131
})
132132
}
133133
return vnode

‎src/components/sidebar/CSidebarNav.ts

Copy file name to clipboardExpand all lines: src/components/sidebar/CSidebarNav.ts
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ const CSidebarNav = defineComponent({
2929
if (vnode.type.name === 'CNavGroup') {
3030
return h(vnode, {
3131
onVisibleChange: (visible: boolean) => handleVisibleChange(visible, index),
32-
visible: isVisible(index),
32+
...(visibleGroup.value && { visible: isVisible(index) }),
3333
})
3434
}
3535
return vnode

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.