@@ -91,6 +91,77 @@ function generateTypeHelpersNav(): SidebarNavItem[] {
9191 return utilityNavItems ;
9292}
9393
94+ function generateOverviewNav ( ) : SidebarNavItem [ ] {
95+ return [
96+ {
97+ title : "Introduction" ,
98+ href : "/docs/introduction" ,
99+ items : [ ] ,
100+ icon : Sticker ,
101+ } ,
102+ {
103+ title : "Getting Started" ,
104+ href : "/docs/getting-started" ,
105+ items : [ ] ,
106+ icon : Compass ,
107+ } ,
108+ {
109+ title : "Child Snippet" ,
110+ href : "/docs/child-snippet" ,
111+ items : [ ] ,
112+ icon : CodeBlock ,
113+ } ,
114+ {
115+ title : "Ref" ,
116+ href : "/docs/ref" ,
117+ items : [ ] ,
118+ icon : Link ,
119+ } ,
120+ {
121+ title : "Transitions" ,
122+ href : "/docs/transitions" ,
123+ items : [ ] ,
124+ icon : Resize ,
125+ } ,
126+ {
127+ title : "Styling" ,
128+ href : "/docs/styling" ,
129+ items : [ ] ,
130+ icon : Palette ,
131+ } ,
132+ {
133+ title : "Dates" ,
134+ href : "/docs/dates" ,
135+ items : [ ] ,
136+ icon : CalendarBlank ,
137+ } ,
138+ {
139+ title : "State Management" ,
140+ href : "/docs/state-management" ,
141+ items : [ ] ,
142+ icon : CirclesThreePlus ,
143+ } ,
144+ {
145+ title : "Figma" ,
146+ href : "/docs/figma-file" ,
147+ items : [ ] ,
148+ icon : FigmaLogo ,
149+ } ,
150+ {
151+ title : "Migration Guide" ,
152+ href : "/docs/migration-guide" ,
153+ items : [ ] ,
154+ icon : Swap ,
155+ } ,
156+ {
157+ title : "LLMs" ,
158+ href : "/docs/llms" ,
159+ items : [ ] ,
160+ icon : Robot ,
161+ } ,
162+ ] ;
163+ }
164+
94165export const navigation : Navigation = {
95166 main : [
96167 {
@@ -101,74 +172,7 @@ export const navigation: Navigation = {
101172 sidebar : [
102173 {
103174 title : "Overview" ,
104- items : [
105- {
106- title : "Introduction" ,
107- href : "/docs/introduction" ,
108- items : [ ] ,
109- icon : Sticker ,
110- } ,
111- {
112- title : "Getting Started" ,
113- href : "/docs/getting-started" ,
114- items : [ ] ,
115- icon : Compass ,
116- } ,
117- {
118- title : "Child Snippet" ,
119- href : "/docs/child-snippet" ,
120- items : [ ] ,
121- icon : CodeBlock ,
122- } ,
123- {
124- title : "Ref" ,
125- href : "/docs/ref" ,
126- items : [ ] ,
127- icon : Link ,
128- } ,
129- {
130- title : "Transitions" ,
131- href : "/docs/transitions" ,
132- items : [ ] ,
133- icon : Resize ,
134- } ,
135- {
136- title : "Styling" ,
137- href : "/docs/styling" ,
138- items : [ ] ,
139- icon : Palette ,
140- } ,
141- {
142- title : "Dates" ,
143- href : "/docs/dates" ,
144- items : [ ] ,
145- icon : CalendarBlank ,
146- } ,
147- {
148- title : "State Management" ,
149- href : "/docs/state-management" ,
150- items : [ ] ,
151- icon : CirclesThreePlus ,
152- } ,
153- {
154- title : "Figma" ,
155- href : "/docs/figma-file" ,
156- items : [ ] ,
157- icon : FigmaLogo ,
158- } ,
159- {
160- title : "Migration Guide" ,
161- href : "/docs/migration-guide" ,
162- items : [ ] ,
163- icon : Swap ,
164- } ,
165- {
166- title : "LLMs" ,
167- href : "/docs/llms" ,
168- items : [ ] ,
169- icon : Robot ,
170- } ,
171- ] ,
175+ items : generateOverviewNav ( ) ,
172176 } ,
173177 {
174178 title : "Components" ,
@@ -184,3 +188,5 @@ export const navigation: Navigation = {
184188 } ,
185189 ] ,
186190} ;
191+
192+ export const flatNavigation = navigation . sidebar . flatMap ( ( item ) => item . items ) ;
0 commit comments