This repository was archived by the owner on Jan 6, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +11
-9
lines changed
packages/client/components Expand file tree Collapse file tree 1 file changed +11
-9
lines changed Original file line number Diff line number Diff line change 2
2
import { getSortedTabs } from ' ~/store'
3
3
4
4
const groupedTabs = useGroupedTabs ()
5
+
6
+ const renderedGroupedTabs = computed (() => {
7
+ return groupedTabs .value .filter (([, { tabs , show }]) => tabs .length && show )
8
+ })
5
9
</script >
6
10
7
11
<template >
@@ -21,15 +25,13 @@ const groupedTabs = useGroupedTabs()
21
25
</div >
22
26
23
27
<div flex =" ~ auto col gap-0.5 items-center" of-auto class =" no-scrollbar" py1 >
24
- <template v-for =" [name , { tabs , show }], idx of groupedTabs " :key =" name " >
25
- <template v-if =" tabs .length && show " >
26
- <div v-if =" idx" my1 h-1px w-8 border =" b base" />
27
- <SideNavItem
28
- v-for =" tab of getSortedTabs(tabs)"
29
- :key =" tab.path"
30
- :tab =" tab"
31
- />
32
- </template >
28
+ <template v-for =" [name , { tabs }], idx of renderedGroupedTabs " :key =" name " >
29
+ <SideNavItem
30
+ v-for =" tab of getSortedTabs(tabs)"
31
+ :key =" tab.path"
32
+ :tab =" tab"
33
+ />
34
+ <div v-if =" idx !== renderedGroupedTabs.length - 1" my1 h-1px w-8 border =" b base" />
33
35
</template >
34
36
<div flex-auto />
35
37
</div >
You can’t perform that action at this time.
0 commit comments