@@ -3,45 +3,68 @@ import { getSortedTabs } from '~/store'
33
44const groupedTabs = useGroupedTabs ()
55
6+ const { sidebarExpanded } = useDevToolsSettings ()
7+
68const renderedGroupedTabs = computed (() => {
79 return groupedTabs .value .filter (([, { tabs , show }]) => tabs .length && show )
810})
911 </script >
1012
1113<template >
12- <div border =" r base" flex =" ~ col gap-0.5" z-100 h-full items-center bg-base class =" no-scrollbar" >
13- <div flex = " ~ col " sticky top-0 z-1 mb1 items-center pt3 bg-base >
14+ <div border =" r base" flex =" ~ col gap-0.5" z-100 h-full w-full items-center bg-base class =" no-scrollbar" >
15+ <div sticky top-0 z-1 w-full p1 bg-base border = " b base " >
1416 <VDropdown placement =" left-start" :distance =" 20" >
1517 <button
16- i-logos-vue h-6 w-6 text-lg
18+ flex =" ~ items-center justify-center gap-2"
19+ hover =" bg-active"
20+ relative h-10 select-none p2 text-secondary
21+ :class =" [
22+ sidebarExpanded ? 'w-full rounded pl2.5' : '',
23+ ]"
1724 title =" Vue DevTools"
18- />
25+ >
26+ <div class =" i-logos-vue h-6 w-6" />
27+ <template v-if =" sidebarExpanded " >
28+ <span text =" lg white" font-600 >
29+ Vue DevTools
30+ </span >
31+ <div flex-auto />
32+ <div i-carbon-overflow-menu-vertical />
33+ </template >
34+ </button >
1935 <template #popper >
2036 <DockingPanel />
2137 </template >
2238 </VDropdown >
2339
24- <div mt-2 h-1px w-8 border =" b base" />
40+ <div mt-2 h-1px w-full border =" b base" />
2541 </div >
2642
27- <div flex =" ~ auto col gap-0.5 items-center" of-auto class =" no-scrollbar" py1 >
43+ <div
44+ flex =" ~ auto col gap-0.5 items-center" w-full p1 class =" no-scrollbar"
45+ :class =" sidebarExpanded ? '' : 'of-x-hidden of-y-auto'"
46+ >
2847 <template v-for =" [name , { tabs }], idx of renderedGroupedTabs " :key =" name " >
2948 <SideNavItem
3049 v-for =" tab of getSortedTabs(tabs)"
3150 :key =" tab.path"
3251 :tab =" tab"
52+ :minimized =" !sidebarExpanded"
3353 />
34- <div v-if =" idx !== renderedGroupedTabs.length - 1" my1 h-1px w-8 border =" b base" />
54+ <div v-if =" idx !== renderedGroupedTabs.length - 1" my1 h-1px w-full border =" b base" />
3555 </template >
3656 <div flex-auto />
3757 </div >
3858
39- <div flex =" ~ none col items-center" >
40- <div h-1px w-8 border =" b base" />
59+ <div flex =" ~ none col items-center" :class = " { 'w-full': sidebarExpanded } " >
60+ <div h-1px w-full border =" b base" />
4161 <RouterLink
4262 replace
4363 to =" /settings"
44- flex =" ~ items-center justify-center"
64+ :flex =" `~ items-center ${!sidebarExpanded ? 'justify-center' : 'justify-start'}`"
65+ :w =" !sidebarExpanded ? '10' : 'full'"
66+ :rounded =" !sidebarExpanded ? 'xl' : ''"
67+ :p =" !sidebarExpanded ? '1' : 'x3'"
4568 hover =" bg-active"
4669 relative my1 block h-10 w-10 select-none rounded-xl p1 text-secondary
4770 exact-active-class =" !text-primary bg-active"
@@ -50,6 +73,9 @@ const renderedGroupedTabs = computed(() => {
5073 text-xl
5174 icon =" i-carbon-settings" title =" Settings" :show-title =" false"
5275 />
76+ <span v-if =" sidebarExpanded" ml-2 overflow-hidden text-ellipsis ws-nowrap >
77+ Settings
78+ </span >
5379 </RouterLink >
5480 </div >
5581 </div >
0 commit comments