{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "sonner",
  "title": "Sonner",
  "description": "The Sonner toaster themed by next-themes, with Keyline icons.",
  "dependencies": [
    "@keyline-icons/react@^2.2.0",
    "next-themes@^0.4.6",
    "sonner@^2.0.8"
  ],
  "files": [
    {
      "path": "registry/khaeli/ui/sonner.tsx",
      "content": "\"use client\"\n\nimport { useTheme } from \"next-themes\"\nimport { Toaster as Sonner, type ToasterProps } from \"sonner\"\nimport { CircleAlertIcon, CircleCheckIcon, CircleXIcon, InfoIcon, LoaderCircleIcon } from \"@keyline-icons/react\"\n\nconst Toaster = ({ ...props }: ToasterProps) => {\n  const { theme = \"system\" } = useTheme()\n\n  return (\n    <Sonner\n      theme={theme as ToasterProps[\"theme\"]}\n      className=\"toaster group\"\n      icons={{\n        success: (\n          <CircleCheckIcon className=\"size-4\" />\n        ),\n        info: (\n          <InfoIcon className=\"size-4\" />\n        ),\n        warning: (\n          <CircleAlertIcon className=\"size-4\" />\n        ),\n        error: (\n          <CircleXIcon className=\"size-4\" />\n        ),\n        loading: (\n          <LoaderCircleIcon className=\"size-4 animate-spin\" />\n        ),\n      }}\n      style={\n        {\n          \"--normal-bg\": \"var(--popover)\",\n          \"--normal-text\": \"var(--popover-foreground)\",\n          \"--normal-border\": \"var(--border)\",\n          \"--border-radius\": \"var(--radius)\",\n        } as React.CSSProperties\n      }\n      toastOptions={{\n        classNames: {\n          toast: \"cn-toast\",\n        },\n      }}\n      {...props}\n    />\n  )\n}\n\nexport { Toaster }\n",
      "type": "registry:ui"
    }
  ],
  "css": {
    "@layer components": {
      "@media (max-width: 767px)": {
        ".cn-toast, [data-sonner-toast]": {
          "min-height": "48px !important",
          "padding": "12px 16px !important",
          "border-radius": "var(--radius-xl) !important",
          "border": "none !important",
          "background-color": "var(--popover) !important",
          "box-shadow": "var(--shadow-popover) !important",
          "color": "var(--foreground)",
          "font-size": "var(--type-footnote) !important",
          "font-weight": "500"
        },
        ".cn-toast [data-button], [data-sonner-toast] [data-button]": {
          "height": "32px !important",
          "padding-inline": "12px !important",
          "border-radius": "var(--radius-md) !important",
          "background-color": "var(--primary) !important",
          "color": "var(--primary-foreground) !important",
          "box-shadow": "none !important",
          "font-size": "var(--type-caption) !important",
          "font-weight": "500"
        }
      }
    }
  },
  "docs": "Install @khaeli/foundation first: this item's styling lives in its tokens and [data-slot] rules.",
  "type": "registry:ui"
}