Some checks failed
tests / ci (pull_request) Has been cancelled
- Removed unnecessary "use client" directive from checkbox and select components. - Added new Drawer component with associated subcomponents (DrawerTrigger, DrawerClose, etc.) for better UI management. - Introduced Table component with TableHeader, TableBody, TableFooter, TableRow, TableHead, TableCell, and TableCaption for structured data display. - Added Tabs component with TabsList, TabsTrigger, and TabsContent for tabbed navigation. - Updated user-info component to use full_name instead of name for better clarity. - Modified user-menu-content to include translations for settings and logout options. - Added data.json file for mock data in the dashboard. - Updated dashboard page to utilize new components and improved layout. - Refactored User type to replace name with full_name for consistency across the application.
43 lines
916 B
TypeScript
43 lines
916 B
TypeScript
"use client"
|
|
|
|
import * as React from "react"
|
|
import { type Icon } from "@tabler/icons-react"
|
|
|
|
import {
|
|
SidebarGroup,
|
|
SidebarGroupContent,
|
|
SidebarMenu,
|
|
SidebarMenuButton,
|
|
SidebarMenuItem,
|
|
} from "@/components/ui/sidebar"
|
|
|
|
export function NavSecondary({
|
|
items,
|
|
...props
|
|
}: {
|
|
items: {
|
|
title: string
|
|
url: string
|
|
icon: Icon
|
|
}[]
|
|
} & React.ComponentPropsWithoutRef<typeof SidebarGroup>) {
|
|
return (
|
|
<SidebarGroup {...props}>
|
|
<SidebarGroupContent>
|
|
<SidebarMenu>
|
|
{items.map((item) => (
|
|
<SidebarMenuItem key={item.title}>
|
|
<SidebarMenuButton asChild>
|
|
<a href={item.url}>
|
|
<item.icon />
|
|
<span>{item.title}</span>
|
|
</a>
|
|
</SidebarMenuButton>
|
|
</SidebarMenuItem>
|
|
))}
|
|
</SidebarMenu>
|
|
</SidebarGroupContent>
|
|
</SidebarGroup>
|
|
)
|
|
}
|