{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "announcement-banner",
  "title": "Announcement banners",
  "description": "Two dismissible announcement banners — an inline bordered page banner and a full-bleed primary-color variant.",
  "registryDependencies": [
    "badge",
    "button",
    "https://www.quilldesignsystem.com/r/icon.json"
  ],
  "files": [
    {
      "path": "registry/blocks/announcement-banner.tsx",
      "content": "import { Badge } from '@/components/ui/badge'\nimport { Button } from '@/components/ui/button'\nimport { Icon } from '@/components/ui/icon'\n\n/** Two dismissible announcement banners — an inline bordered page banner and a full-bleed primary-color variant. */\nexport function AnnouncementBanner() {\n  return (\n    <div className=\"mx-auto flex w-full max-w-page flex-col gap-4\">\n      {/* Inline page banner */}\n      <div className=\"flex items-center justify-between gap-4 rounded-lg bg-card px-4 py-3 ring-1 ring-foreground/10 max-sm:flex-col max-sm:items-start\">\n        <div className=\"flex items-center gap-3\">\n          <Badge>New</Badge>\n          <p className=\"text-sm text-foreground\">\n            Issue 004 of The Brief just shipped — how we scope a design system engagement.\n          </p>\n        </div>\n        <div className=\"flex shrink-0 items-center gap-1\">\n          <Button variant=\"link\" size=\"sm\">\n            Read it <Icon name=\"arrow_forward\" />\n          </Button>\n          <Button variant=\"ghost\" size=\"icon-sm\" aria-label=\"Dismiss announcement\">\n            <Icon name=\"close\" />\n          </Button>\n        </div>\n      </div>\n      {/* Full-bleed ink banner */}\n      <div className=\"flex items-center justify-between gap-4 rounded-lg bg-primary px-4 py-3 text-primary-foreground max-sm:flex-col max-sm:items-start\">\n        <p className=\"text-sm\">\n          <span className=\"font-medium\">Workshop:</span> Design systems for product teams — Saturday,\n          July 26. Twelve seats.\n        </p>\n        <div className=\"flex shrink-0 items-center gap-1\">\n          <Button variant=\"secondary\" size=\"sm\">\n            Save a seat\n          </Button>\n          <Button\n            variant=\"ghost\"\n            size=\"icon-sm\"\n            aria-label=\"Dismiss workshop banner\"\n            className=\"text-primary-foreground hover:bg-primary-foreground/10 hover:text-primary-foreground\"\n          >\n            <Icon name=\"close\" />\n          </Button>\n        </div>\n      </div>\n    </div>\n  )\n}\n",
      "type": "registry:component",
      "target": "components/quill/announcement-banner.tsx"
    }
  ],
  "meta": {
    "intent": [
      "feedback",
      "marketing"
    ],
    "use_when": "You need to announce something site-wide with a dismissible banner, either inline or full-bleed.",
    "not_for": "the message is local to a page section and tied to system status, not a site-wide announcement → alerts; the banner requires an explicit choice (accept/reject), not just a dismiss → cookie-consent"
  },
  "docs": "Two dismissible announcement banners — an inline bordered page banner and a full-bleed primary-color variant. Do: Give every banner variant its own dismiss button with a specific aria-label (e.g. \"Dismiss workshop banner\"), not a generic one. Don't: Ship a banner with no way to dismiss it, or multiple banners sharing one ambiguous \"Dismiss\" label. Use alerts when the message is local to a page section and tied to system status, not a site-wide announcement. Use cookie-consent when the banner requires an explicit choice (accept/reject), not just a dismiss.",
  "categories": [
    "feedback",
    "marketing"
  ],
  "type": "registry:block"
}