{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "alert",
  "type": "registry:ui",
  "dependencies": [
    "@kobalte/core"
  ],
  "files": [
    {
      "path": "ui/alert.tsx",
      "content": "import type { ComponentProps, ValidComponent } from \"solid-js\"\nimport { splitProps } from \"solid-js\"\n\nimport type { PolymorphicProps } from \"@kobalte/core/polymorphic\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst alertVariants = cva(\"cn-alert group/alert relative w-full\", {\n  variants: {\n    variant: {\n      default: \"cn-alert-variant-default\",\n      destructive: \"cn-alert-variant-destructive\"\n    }\n  },\n  defaultVariants: {\n    variant: \"default\"\n  }\n})\n\ntype AlertProps<T extends ValidComponent = \"div\"> = ComponentProps<T> &\n  VariantProps<typeof alertVariants> & {\n    class?: string | undefined\n  }\n\nconst Alert = <T extends ValidComponent = \"div\">(props: PolymorphicProps<T, AlertProps<T>>) => {\n  const [local, others] = splitProps(props as AlertProps, [\"class\", \"variant\"])\n  return (\n    <div\n      class={cn(alertVariants({ variant: local.variant }), local.class)}\n      data-slot=\"alert\"\n      role=\"alert\"\n      {...others}\n    />\n  )\n}\n\ntype AlertTitleProps<T extends ValidComponent = \"div\"> = ComponentProps<T> & {\n  class?: string | undefined\n}\n\nconst AlertTitle = <T extends ValidComponent = \"div\">(\n  props: PolymorphicProps<T, AlertTitleProps<T>>\n) => {\n  const [local, others] = splitProps(props as AlertTitleProps, [\"class\"])\n  return (\n    <div\n      class={cn(\n        \"cn-alert-title [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground\",\n        local.class\n      )}\n      data-slot=\"alert-title\"\n      {...others}\n    />\n  )\n}\n\ntype AlertDescriptionProps<T extends ValidComponent = \"div\"> = ComponentProps<T> & {\n  class?: string | undefined\n}\n\nconst AlertDescription = <T extends ValidComponent = \"div\">(\n  props: PolymorphicProps<T, AlertDescriptionProps<T>>\n) => {\n  const [local, others] = splitProps(props as AlertDescriptionProps, [\"class\"])\n  return (\n    <div\n      class={cn(\n        \"cn-alert-description [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground\",\n        local.class\n      )}\n      data-slot=\"alert-description\"\n      {...others}\n    />\n  )\n}\n\ntype AlertActionProps<T extends ValidComponent = \"div\"> = ComponentProps<T> & {\n  class?: string | undefined\n}\n\nconst AlertAction = <T extends ValidComponent = \"div\">(\n  props: PolymorphicProps<T, AlertActionProps<T>>\n) => {\n  const [local, others] = splitProps(props as AlertActionProps, [\"class\"])\n  return <div class={cn(\"cn-alert-action\", local.class)} data-slot=\"alert-action\" {...others} />\n}\n\nexport { Alert, AlertTitle, AlertDescription, AlertAction, alertVariants }\n",
      "type": "registry:ui"
    }
  ]
}