import { jsx } from 'react/jsx-runtime';
import { c as cva } from '../index-D7Zy7P05.js';
import { c as cn } from '../utils-DdHUxIdC.js';

const alertVariants = cva("group/alert relative grid w-full gap-0.5 rounded-lg border px-2.5 py-2 text-start text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pe-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4", {
    variants: {
        variant: {
            default: "bg-card text-card-foreground",
            destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current",
        },
    },
    defaultVariants: {
        variant: "default",
    },
});
function Alert$1({ className, variant, ...props }) {
    return (jsx("div", { "data-slot": "alert", role: "alert", className: cn(alertVariants({ variant }), className), ...props }));
}
function AlertTitle$1({ className, ...props }) {
    return (jsx("div", { "data-slot": "alert-title", className: cn("font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground", className), ...props }));
}
function AlertDescription$1({ className, ...props }) {
    return (jsx("div", { "data-slot": "alert-description", className: cn("text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4", className), ...props }));
}
function AlertAction$1({ className, ...props }) {
    return (jsx("div", { "data-slot": "alert-action", className: cn("absolute top-2 end-2", className), ...props }));
}

const Alert = (props) => (jsx(Alert$1, { ...props }));
const AlertTitle = (props) => (jsx(AlertTitle$1, { ...props }));
const AlertDescription = (props) => jsx(AlertDescription$1, { ...props });
const AlertAction = (props) => (jsx(AlertAction$1, { ...props }));

export { Alert, AlertAction, AlertDescription, AlertTitle };
//# sourceMappingURL=Alert.js.map
