tr]:last:border-b-0",
+ className,
+ )}
+ {...props}
+ />
+ );
+}
+
+function TableRow({ className, ...props }: React.ComponentProps<"tr">) {
+ return (
+
+ );
+}
+
+function TableHead({ className, ...props }: React.ComponentProps<"th">) {
+ return (
+ [role=checkbox]]:translate-y-[2px]",
+ className,
+ )}
+ {...props}
+ />
+ );
+}
+
+function TableCell({ className, ...props }: React.ComponentProps<"td">) {
+ return (
+ | [role=checkbox]]:translate-y-[2px]",
+ className,
+ )}
+ {...props}
+ />
+ );
+}
+
+function TableCaption({
+ className,
+ ...props
+}: React.ComponentProps<"caption">) {
+ return (
+
+ );
+}
+
+export {
+ Table,
+ TableHeader,
+ TableBody,
+ TableFooter,
+ TableHead,
+ TableRow,
+ TableCell,
+ TableCaption,
+};
diff --git a/src/shared/ui/textarea.tsx b/src/shared/ui/textarea.tsx
new file mode 100644
index 0000000..8808070
--- /dev/null
+++ b/src/shared/ui/textarea.tsx
@@ -0,0 +1,18 @@
+import * as React from "react";
+
+import { cn } from "@/shared/lib/utils";
+
+function Textarea({ className, ...props }: React.ComponentProps<"textarea">) {
+ return (
+
+ );
+}
+
+export { Textarea };
diff --git a/src/shared/ui/tooltip.tsx b/src/shared/ui/tooltip.tsx
new file mode 100644
index 0000000..d0e1784
--- /dev/null
+++ b/src/shared/ui/tooltip.tsx
@@ -0,0 +1,59 @@
+import * as React from "react";
+import * as TooltipPrimitive from "@radix-ui/react-tooltip";
+
+import { cn } from "@/shared/lib/utils";
+
+function TooltipProvider({
+ delayDuration = 0,
+ ...props
+}: React.ComponentProps) {
+ return (
+
+ );
+}
+
+function Tooltip({
+ ...props
+}: React.ComponentProps) {
+ return (
+
+
+
+ );
+}
+
+function TooltipTrigger({
+ ...props
+}: React.ComponentProps) {
+ return ;
+}
+
+function TooltipContent({
+ className,
+ sideOffset = 0,
+ children,
+ ...props
+}: React.ComponentProps) {
+ return (
+
+
+ {children}
+
+
+
+ );
+}
+
+export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };
diff --git a/src/widgets/sidebar-layout/index.tsx b/src/widgets/sidebar-layout/index.tsx
new file mode 100644
index 0000000..8a544bc
--- /dev/null
+++ b/src/widgets/sidebar-layout/index.tsx
@@ -0,0 +1,158 @@
+import {
+ BriefcaseMedical,
+ Building2,
+ Calendar,
+ ClipboardList,
+ FileText,
+ Hospital,
+ ListChecks,
+ LogOut,
+ Map,
+ MapPin,
+ MapPinned,
+ Microscope,
+ Pill,
+ Users,
+} from "lucide-react";
+import { Link, useLocation, useNavigate } from "react-router-dom";
+
+import { Button } from "@/shared/ui/button";
+import {
+ Sidebar,
+ SidebarContent,
+ SidebarFooter,
+ SidebarGroup,
+ SidebarGroupContent,
+ SidebarGroupLabel,
+ SidebarMenu,
+ SidebarMenuButton,
+ SidebarMenuItem,
+} from "@/shared/ui/sidebar";
+
+const items = [
+ {
+ title: "Foydalanuvchilar",
+ url: "/dashboard",
+ icon: Users,
+ },
+ {
+ title: "Rejalar",
+ url: "/dashboard/plans",
+ icon: Calendar,
+ },
+ {
+ title: "Tumanlar",
+ url: "/dashboard/districts",
+ icon: Building2,
+ },
+ {
+ title: "Obyektlar",
+ url: "/dashboard/objects",
+ icon: MapPinned,
+ },
+ {
+ title: "Shifokorlar",
+ url: "/dashboard/doctors",
+ icon: BriefcaseMedical,
+ },
+ {
+ title: "Dorixonalar",
+ url: "/dashboard/pharmacies",
+ icon: Hospital,
+ },
+ {
+ title: "Hisobotlar",
+ url: "/dashboard/reports",
+ icon: ClipboardList,
+ },
+ {
+ title: "Jo'natilgan joylar",
+ url: "/dashboard/sent-locations",
+ icon: MapPin,
+ },
+ {
+ title: "Spesifikatsiyalar",
+ url: "/dashboard/specifications",
+ icon: FileText,
+ },
+ {
+ title: "Tur planlar",
+ url: "/dashboard/tour-plan",
+ icon: ListChecks,
+ },
+ {
+ title: "Hududlar",
+ url: "/dashboard/region",
+ icon: Map,
+ },
+ {
+ title: "Dorilar ro'yxati",
+ url: "/dashboard/pill",
+ icon: Pill,
+ },
+ {
+ title: "Farmasevtikalar",
+ url: "/dashboard/pharm",
+ icon: Microscope,
+ },
+];
+
+export function AppSidebar() {
+ const location = useLocation();
+ const navigate = useNavigate();
+
+ const isActive = (url: string) => {
+ if (url === "/dashboard") {
+ return location.pathname === "/dashboard";
+ }
+ return location.pathname.startsWith(url);
+ };
+
+ return (
+
+
+
+
+
+
+
+
+
+ {items.map((item) => (
+
+
+
+
+ {item.title}
+
+
+
+ ))}
+
+
+
+
+
+
+
+
+ );
+}
|