"use client";

// src/components/ui/resizable.tsx
import { GripVertical } from "lucide-react";
import { Group, Panel, Separator } from "react-resizable-panels";

// src/lib/utils.ts
import { clsx } from "clsx";
import { twMerge } from "tailwind-merge";
function cn(...inputs) {
  return twMerge(clsx(inputs));
}

// src/components/ui/resizable.tsx
import { jsx } from "react/jsx-runtime";
function ResizablePanelGroup({
  direction = "horizontal",
  className,
  ...props
}) {
  return /* @__PURE__ */ jsx(
    Group,
    {
      orientation: direction,
      className: cn(
        "flex size-full",
        direction === "vertical" && "flex-col",
        className
      ),
      ...props
    }
  );
}
var ResizablePanel = Panel;
function ResizableHandle({ withHandle, className, ...props }) {
  return /* @__PURE__ */ jsx(
    Separator,
    {
      className: cn(
        // Base — horizontal handle (between side-by-side panels)
        "relative flex w-1 shrink-0 cursor-col-resize items-center justify-center bg-border/60",
        "transition-colors hover:bg-border active:bg-primary/30",
        "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-1",
        // Vertical handle (between stacked panels)
        "data-[orientation=vertical]:h-1 data-[orientation=vertical]:w-full data-[orientation=vertical]:cursor-row-resize data-[orientation=vertical]:flex-row",
        className
      ),
      ...props,
      children: withHandle && /* @__PURE__ */ jsx("div", { className: "z-10 flex h-5 w-3.5 items-center justify-center rounded-sm border border-border bg-background shadow-sm", children: /* @__PURE__ */ jsx(GripVertical, { className: "size-3 text-muted-foreground" }) })
    }
  );
}
export {
  ResizableHandle,
  ResizablePanel,
  ResizablePanelGroup
};
//# sourceMappingURL=resizable.js.map