diff --git a/apps/app/src/components/Navigation.tsx b/apps/app/src/components/Navigation.tsx index 77f086c..f0cf21a 100644 --- a/apps/app/src/components/Navigation.tsx +++ b/apps/app/src/components/Navigation.tsx @@ -1,4 +1,8 @@ import { + Accordion, + AccordionContent, + AccordionItem, + AccordionTrigger, Button, Card, CardContent, @@ -24,18 +28,50 @@ export const Navigation = () => {
-
diff --git a/apps/app/src/components/NavigationMobile.tsx b/apps/app/src/components/NavigationMobile.tsx index 1562fd6..a4496dc 100644 --- a/apps/app/src/components/NavigationMobile.tsx +++ b/apps/app/src/components/NavigationMobile.tsx @@ -1,4 +1,8 @@ import { + Accordion, + AccordionContent, + AccordionItem, + AccordionTrigger, Button, Card, CardContent, @@ -30,19 +34,49 @@ export const NavigationMobile = () => { > boring.tools - {NavigationRoutes.map((route) => ( - - - {route.name} - - ))} + {NavigationRoutes.map((route) => { + if (!route.childrens) { + return ( + + + {route.name} + + ) + } + + return ( + + + Changelog + + {route.childrens.map((childRoute) => ( + + + {childRoute.name} + + ))} + + + + ) + })}
diff --git a/apps/app/src/utils/navigation-routes.ts b/apps/app/src/utils/navigation-routes.ts index eaeb012..769e691 100644 --- a/apps/app/src/utils/navigation-routes.ts +++ b/apps/app/src/utils/navigation-routes.ts @@ -1,9 +1,32 @@ -import { HouseIcon } from 'lucide-react' +import type { ReactNode } from '@tanstack/react-router' +import { FileStackIcon, HouseIcon, LayoutDashboardIcon } from 'lucide-react' -export const NavigationRoutes = [ +type Route = { + name: string + to?: string + icon?: ReactNode + childrens?: Route[] +} + +export const NavigationRoutes: Route[] = [ { name: 'Dashboard', to: '/', - icon: HouseIcon, + icon: LayoutDashboardIcon, + }, + { + name: 'Changelog', + childrens: [ + { + name: 'Overview', + to: '/changelog', + icon: HouseIcon, + }, + { + name: 'Versions', + to: '/changelog/version', + icon: FileStackIcon, + }, + ], }, ] diff --git a/bun.lockb b/bun.lockb index bb33ee3..90126cc 100755 Binary files a/bun.lockb and b/bun.lockb differ