diff --git a/src/Components/AppShell/SideBar.tsx b/src/Components/AppShell/SideBar.tsx
index e79bf894..fe1f3662 100644
--- a/src/Components/AppShell/SideBar.tsx
+++ b/src/Components/AppShell/SideBar.tsx
@@ -17,7 +17,7 @@ type route = {
}
-export function SideBar({routes} : {routes : route[]}) {
+export function SideBar({ routes, bottomRoutes }: { routes: route[], bottomRoutes?: route[] }) {
// prevent react18 from calling useEffect twice
const init = useRef(false)
@@ -58,151 +58,72 @@ export function SideBar({routes} : {routes : route[]}) {
data-te-sidenav-slim="true"
data-te-sidenav-content="#app-content"
data-te-sidenav-slim-collapsed="true"
- data-te-sidenav-slim-width ="56"
- data-te-sidenav-width ="160">
-
-
- {
- routes.map((route, k) => {
- return (
- -
- {
- route.submenu ?
- :
- ( `${isActive ? 'tw-font-semibold tw-bg-base-200 !tw-rounded-none' : 'tw-font-normal !tw-rounded-none'}`} onClick={ () => {if(screen.width < 640 && !slim) instance.toggle();
- }}>
- {route.icon}{route.name}
+ data-te-sidenav-slim-width="56"
+ data-te-sidenav-width="160">
+
+
+ {
+ routes.map((route, k) => {
+ return (
+ -
+ {
+ route.submenu ?
+ :
+ ( `${isActive ? 'tw-font-semibold tw-bg-base-200 !tw-rounded-none' : 'tw-font-normal !tw-rounded-none'}`} onClick={() => {
+ if (screen.width < 640 && !slim) instance.toggle();
+ }}>
+ {route.icon}{route.name}
+ {
+ location.pathname.includes(route.path) && route.path.length > 1 || location.pathname === route.path ? () : null
+ }
+ )
+ }
+
+
+ )
+ })
+ }
+
+
+
+
+
+
+ {
+ bottomRoutes?.map((route, k) => {
+ return (
+ -
{
- location.pathname.includes(route.path) && route.path.length>1 || location.pathname === route.path? () : null
+ route.submenu ?
+ :
+ ( `${isActive ? 'tw-font-semibold tw-bg-base-200 !tw-rounded-none' : 'tw-font-normal !tw-rounded-none'}`} onClick={() => {
+ if (screen.width < 640 && !slim) instance.toggle();
+ }}>
+ {route.icon}{route.name}
+ {
+ location.pathname.includes(route.path) && route.path.length > 1 || location.pathname === route.path ? () : null
+ }
+ )
}
- )
- }
-
- )
- })
- }
+
+ )
+ })
+ }
+
- {/*
-
-
-
-
-
-
- Category 1
-
-
-
-
-
-
-
-
-
-
-
-
- Category 2
-
-
-
-
-
-
- */}
-
-
-
- toggleSlim()}/>
-
+
toggleSlim()} />
+
+
+
)