"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.EntityBox = EntityBox;
exports.EntityBoxCollapsible = EntityBoxCollapsible;
exports.EntityBoxCollapsibleTrigger = EntityBoxCollapsibleTrigger;
exports.EntityBoxCollapsibleContent = EntityBoxCollapsibleContent;
exports.EntityBoxHeaderTitle = EntityBoxHeaderTitle;
exports.EntityBoxBanner = EntityBoxBanner;
exports.EntityBoxActions = EntityBoxActions;
const jsx_runtime_1 = require("react/jsx-runtime");
const utils_1 = require("../../lib/utils");
const tooltip_1 = require("../ui/tooltip");
const lucide_react_1 = require("lucide-react");
const collapsible_1 = require("../ui/collapsible");
const button_1 = require("../ui/button");
const separator_1 = require("../ui/separator");
function EntityBox({ className, children, ...props }) {
    return ((0, jsx_runtime_1.jsx)("div", { "data-slot": "entity-box", className: (0, utils_1.cn)('shadow-entity-box bg-card mb-2 flex items-center justify-between rounded-lg p-6', className), ...props, children: children }));
}
function EntityBoxCollapsible({ className, ...props }) {
    return ((0, jsx_runtime_1.jsx)(collapsible_1.Collapsible, { className: (0, utils_1.cn)('shadow-entity-box bg-card mb-2 flex flex-col rounded-lg', className), ...props }));
}
function EntityBoxCollapsibleTrigger(props) {
    return ((0, jsx_runtime_1.jsx)(collapsible_1.CollapsibleTrigger, { ...props, asChild: true, children: (0, jsx_runtime_1.jsx)(button_1.Button, { variant: "secondary", className: "h-[34px] w-[34px] p-2", children: (0, jsx_runtime_1.jsx)(lucide_react_1.Settings2, { size: 16 }) }) }));
}
function EntityBoxCollapsibleContent({ children, ...props }) {
    return ((0, jsx_runtime_1.jsxs)(collapsible_1.CollapsibleContent, { ...props, children: [(0, jsx_runtime_1.jsx)(separator_1.Separator, { orientation: "horizontal" }), (0, jsx_runtime_1.jsx)("div", { className: "grid w-full grid-cols-3 p-6", children: children })] }));
}
function EntityBoxHeaderTitle({ title, subtitle, tooltip, tooltipWidth, className, ...props }) {
    return ((0, jsx_runtime_1.jsxs)("div", { "data-slot": "entity-box-header", className: (0, utils_1.cn)('flex flex-col items-start', className), ...props, children: [(0, jsx_runtime_1.jsxs)("div", { className: "flex items-center gap-[10px]", children: [(0, jsx_runtime_1.jsx)("h1", { className: "text-muted-foreground text-lg font-medium", children: title }), tooltip && ((0, jsx_runtime_1.jsx)(tooltip_1.TooltipProvider, { children: (0, jsx_runtime_1.jsxs)(tooltip_1.Tooltip, { children: [(0, jsx_runtime_1.jsx)(tooltip_1.TooltipTrigger, { asChild: true, children: (0, jsx_runtime_1.jsx)(lucide_react_1.CircleHelp, { className: "pointer text-shadcn-400 h-5 w-5" }) }), (0, jsx_runtime_1.jsx)(tooltip_1.TooltipContent, { side: "right", style: tooltipWidth
                                        ? { width: tooltipWidth, maxWidth: tooltipWidth }
                                        : undefined, children: tooltip })] }) }))] }), subtitle && (0, jsx_runtime_1.jsx)("p", { className: "text-shadcn-400 text-sm", children: subtitle })] }));
}
function EntityBoxBanner({ className, children, ...props }) {
    return ((0, jsx_runtime_1.jsx)("div", { "data-slot": "entity-box-banner", className: (0, utils_1.cn)('grid grid-cols-3 p-6', className), ...props, children: children }));
}
function EntityBoxActions({ className, children, ...props }) {
    return ((0, jsx_runtime_1.jsx)("div", { "data-slot": "entity-box-actions", className: (0, utils_1.cn)('col-start-3 flex flex-row items-center justify-end gap-4', className), ...props, children: children }));
}
