import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
import clsx from 'clsx';
import { VTooltip } from './shadcn/tooltip';
import { Info } from 'lucide-react';
export function FormItem({ description, required, label, className, direction = "column", children, disabled = false }) {
    return (_jsxs("div", { className: clsx("flex w-full space-y-1", className, direction === "row" ? "flex-row justify-between items-center gap-2" : "flex-col"), children: [_jsxs("div", { className: 'flex items-center gap-1', children: [_jsxs("label", { className: `text-sm font-medium mb-1 ${disabled ? "text-muted" : ""}`, children: [label, required ? _jsx("span", { className: 'text-destructive -mt-4 ml-1', children: "*" }) : ""] }), description &&
                        _jsx("div", { className: 'mx-2 flex w-4 items-center', children: _jsx(VTooltip, { description: description, children: _jsx(Info, { className: "size-3 text-muted" }) }) })] }), children] }));
}
//# sourceMappingURL=FormItem.js.map