{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "notice-svelte",
  "title": "Notice (Svelte)",
  "description": "A calm callout for info, success, a warning or an error, with optional actions and Dismiss.",
  "dependencies": [
    "@kind-ui/agent-ui@0.9.0",
    "@ui-sdk/core@0.1.0-beta.17",
    "@ui-sdk/svelte@0.1.0-beta.17"
  ],
  "registryDependencies": [
    "@kind-ui/agent-ui-setup"
  ],
  "files": [
    {
      "path": "packages/agent-ui/src/svelte/notice/Notice.svelte",
      "content": "<!--\n  A calm callout: its mark, its `label` as the title, the reset line with `resetsAt`, `children` as its text, then\n  `actions` and Dismiss while `onDismiss` is set and it's `dismissible`. To arrange the parts yourself, use\n  `NoticeRoot`.\n-->\n<script lang=\"ts\">\n  import type { ComponentProps, Snippet } from \"svelte\";\n  import { NoticeActions, NoticeDescription, NoticeDismiss, NoticeIcon, NoticeReset, NoticeTitle, parts } from \"./index\";\n\n  // `Omit` would drop the options: part props carry an index signature for attributes.\n  type RootProps = ComponentProps<typeof parts.Root>;\n\n  let {\n    children,\n    actions,\n    ...props\n  }: { [Key in keyof RootProps as Key extends \"children\" ? never : Key]: RootProps[Key] } & {\n    /** The notice's text. */\n    children?: Snippet;\n    /** Buttons that act on the notice, like \"Retry\". */\n    actions?: Snippet;\n  } = $props();\n</script>\n\n<parts.Root {...props}>\n  <NoticeIcon\n  /><NoticeTitle\n  /><NoticeReset\n  /><NoticeDescription>{@render children?.()}</NoticeDescription\n  ><NoticeActions>{@render actions?.()}</NoticeActions\n  ><NoticeDismiss />\n</parts.Root>\n",
      "type": "registry:ui",
      "target": "@ui/svelte/notice/Notice.svelte"
    },
    {
      "path": "packages/agent-ui/src/svelte/notice/NoticeReset.svelte",
      "content": "<!-- When the limit resets, like \"Resets Tuesday at 9:00 AM.\", unless you pass a `children` snippet. Rendered only with `resetsAt`. -->\n<script lang=\"ts\">\n  import type { ComponentProps } from \"svelte\";\n  import { parts } from \"./index\";\n\n  let { children, ...props }: ComponentProps<typeof parts.Reset> = $props();\n</script>\n\n{#snippet text(state: { text: string })}{state.text}{/snippet}\n\n<parts.Reset {...props} children={children ?? text} />\n",
      "type": "registry:ui",
      "target": "@ui/svelte/notice/NoticeReset.svelte"
    },
    {
      "path": "packages/agent-ui/src/svelte/notice/NoticeTitle.svelte",
      "content": "<!-- The `label`, unless you pass a `children` snippet. Rendered only with a `label`. -->\n<script lang=\"ts\">\n  import type { ComponentProps } from \"svelte\";\n  import { parts } from \"./index\";\n\n  let { children, ...props }: ComponentProps<typeof parts.Title> = $props();\n</script>\n\n{#snippet label({ label }: { label: string })}{label}{/snippet}\n\n<parts.Title {...props} children={children ?? label} />\n",
      "type": "registry:ui",
      "target": "@ui/svelte/notice/NoticeTitle.svelte"
    },
    {
      "path": "packages/agent-ui/src/svelte/notice/index.ts",
      "content": "import { noticePrimitive } from \"@kind-ui/agent-ui/core\";\nimport { createParts } from \"@ui-sdk/svelte/primitive\";\n\nexport const parts = createParts(noticePrimitive, {\n  root: \"div\",\n  icon: \"span\",\n  title: \"p\",\n  description: \"div\",\n  reset: \"p\",\n  actions: \"div\",\n  dismiss: \"button\",\n});\n\nexport { default as Notice } from \"./Notice.svelte\";\n/** The bare root, for arranging the parts yourself. */\nexport const NoticeRoot = parts.Root;\nexport const NoticeIcon = parts.Icon;\nexport const NoticeDescription = parts.Description;\nexport const NoticeActions = parts.Actions;\nexport const NoticeDismiss = parts.Dismiss;\nexport { default as NoticeReset } from \"./NoticeReset.svelte\";\nexport { default as NoticeTitle } from \"./NoticeTitle.svelte\";\n",
      "type": "registry:ui",
      "target": "@ui/svelte/notice/index.ts"
    }
  ],
  "meta": {
    "layer": "svelte"
  },
  "type": "registry:ui"
}
