2026-07-02 05:58:36 +07:00
|
|
|
/* ═══════════════════════════════════════════════════════════════════════════
|
|
|
|
|
* IMPHNEN Tabs — Radix-based, style sesuai Approachable Modernism
|
|
|
|
|
* ═══════════════════════════════════════════════════════════════════════════ */
|
|
|
|
|
|
2026-05-16 19:17:34 +07:00
|
|
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
|
|
|
|
import type * as React from "react";
|
2026-06-01 16:42:36 +07:00
|
|
|
import { cn } from "../lib/utils";
|
2026-05-16 19:17:34 +07:00
|
|
|
|
|
|
|
|
export const Tabs = TabsPrimitive.Root;
|
|
|
|
|
|
2026-06-01 21:44:29 +07:00
|
|
|
export function TabsList({
|
|
|
|
|
className,
|
|
|
|
|
...props
|
|
|
|
|
}: React.ComponentPropsWithoutRef<typeof TabsPrimitive.List>) {
|
2026-05-16 19:17:34 +07:00
|
|
|
return (
|
|
|
|
|
<TabsPrimitive.List
|
2026-06-01 21:44:29 +07:00
|
|
|
className={cn(
|
2026-07-02 05:58:36 +07:00
|
|
|
"inline-flex h-10 items-center justify-center",
|
|
|
|
|
"rounded-lg bg-[#f5f5f5] p-1",
|
|
|
|
|
"text-[#666666]",
|
2026-06-01 21:44:29 +07:00
|
|
|
className,
|
|
|
|
|
)}
|
2026-05-16 19:17:34 +07:00
|
|
|
{...props}
|
|
|
|
|
/>
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
2026-06-01 21:44:29 +07:00
|
|
|
export function TabsTrigger({
|
|
|
|
|
className,
|
|
|
|
|
...props
|
|
|
|
|
}: React.ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>) {
|
2026-05-16 19:17:34 +07:00
|
|
|
return (
|
|
|
|
|
<TabsPrimitive.Trigger
|
|
|
|
|
className={cn(
|
2026-07-02 05:58:36 +07:00
|
|
|
"inline-flex items-center justify-center whitespace-nowrap",
|
|
|
|
|
"rounded-lg px-3 py-1.5",
|
|
|
|
|
"font-sans text-sm font-medium",
|
|
|
|
|
"transition-all duration-[150ms] ease-[cubic-bezier(0.4,0,0.2,1)]",
|
|
|
|
|
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#23a1eb]/40",
|
|
|
|
|
"disabled:pointer-events-none disabled:opacity-50",
|
|
|
|
|
"data-[state=active]:bg-white data-[state=active]:text-[#1a1a1a] data-[state=active]:shadow-sm",
|
2026-05-16 19:17:34 +07:00
|
|
|
className,
|
|
|
|
|
)}
|
|
|
|
|
{...props}
|
|
|
|
|
/>
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
2026-06-01 21:44:29 +07:00
|
|
|
export function TabsContent({
|
|
|
|
|
className,
|
|
|
|
|
...props
|
|
|
|
|
}: React.ComponentPropsWithoutRef<typeof TabsPrimitive.Content>) {
|
2026-05-16 19:17:34 +07:00
|
|
|
return (
|
|
|
|
|
<TabsPrimitive.Content
|
2026-06-01 21:44:29 +07:00
|
|
|
className={cn(
|
2026-07-02 05:58:36 +07:00
|
|
|
"mt-6 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#23a1eb]/40",
|
2026-06-01 21:44:29 +07:00
|
|
|
className,
|
|
|
|
|
)}
|
2026-05-16 19:17:34 +07:00
|
|
|
{...props}
|
|
|
|
|
/>
|
|
|
|
|
);
|
|
|
|
|
}
|