{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "forms-18",
  "type": "registry:block",
  "description": "Notification preferences matrix of events by email, push and SMS checkboxes.",
  "dependencies": [
    "lucide-react"
  ],
  "registryDependencies": [
    "button",
    "checkbox"
  ],
  "files": [
    {
      "path": "registry/designali/blocks/forms/forms-18.tsx",
      "content": "import {\n  Bell,\n  Mail,\n  MessageSquare,\n} from \"@designali/icons\"\n\nimport { Button } from \"@workspace/ui/components/button\"\nimport { Checkbox } from \"@workspace/ui/components/checkbox\"\n\nconst channels = [\n  { id: \"email\", label: \"Email\", icon: Mail },\n  { id: \"push\", label: \"Push\", icon: Bell },\n  { id: \"sms\", label: \"SMS\", icon: MessageSquare },\n]\n\nconst groups = [\n  {\n    title: \"Activity\",\n    rows: [\n      { id: \"mentions\", label: \"Comments on my Designali projects\", defaults: [\"email\", \"push\"] },\n      { id: \"assigned\", label: \"Design reviews from Ali Imam\", defaults: [\"email\", \"push\", \"sms\"] },\n      { id: \"status\", label: \"Project status changes\", defaults: [\"push\"] },\n    ],\n  },\n  {\n    title: \"Workspace\",\n    rows: [\n      { id: \"invites\", label: \"New teammates join\", defaults: [\"email\"] },\n      { id: \"billing\", label: \"Billing and invoices\", defaults: [\"email\"] },\n      { id: \"security\", label: \"New sign-in from unknown device\", defaults: [\"email\", \"sms\"] },\n    ],\n  },\n  {\n    title: \"From Designali\",\n    rows: [\n      { id: \"product\", label: \"New templates and blocks\", defaults: [] as string[] },\n      { id: \"tips\", label: \"Design se code tak tips\", defaults: [] as string[] },\n    ],\n  },\n]\n\nexport default function Forms18() {\n  return (\n    <section className=\"w-full bg-background py-20\">\n      <div className=\"mx-auto max-w-4xl px-6\">\n        <h2 className=\"text-3xl font-semibold tracking-tight\">Notification preferences</h2>\n        <p className=\"mt-2 text-sm text-muted-foreground\">\n          Choose where each kind of update reaches you. Security alerts by email cannot be turned off.\n        </p>\n\n        <form className=\"mt-10\">\n          <div className=\"border border-border\">\n            <div className=\"grid grid-cols-[1fr_repeat(3,56px)] border-b border-border bg-muted/50 text-xs font-medium sm:grid-cols-[1fr_repeat(3,96px)]\">\n              <div className=\"p-3 sm:p-4\">Event</div>\n              {channels.map((channel) => (\n                <div key={channel.id} className=\"flex flex-col items-center justify-center gap-1 border-l border-border p-2 sm:flex-row sm:gap-2\">\n                  <channel.icon className=\"size-3.5 text-muted-foreground\" />\n                  <span className=\"hidden sm:inline\">{channel.label}</span>\n                  <span className=\"sr-only sm:hidden\">{channel.label}</span>\n                </div>\n              ))}\n            </div>\n            {groups.map((group) => (\n              <div key={group.title}>\n                <div className=\"border-b border-border px-3 py-2 font-sans text-[10px] tracking-wider text-muted-foreground uppercase sm:px-4\">\n                  {group.title}\n                </div>\n                {group.rows.map((row) => (\n                  <div\n                    key={row.id}\n                    className=\"grid grid-cols-[1fr_repeat(3,56px)] border-b border-border text-sm last:border-b-0 sm:grid-cols-[1fr_repeat(3,96px)]\"\n                  >\n                    <div className=\"p-3 leading-5 sm:p-4\">{row.label}</div>\n                    {channels.map((channel) => {\n                      const locked = row.id === \"security\" && channel.id === \"email\"\n                      return (\n                        <div key={channel.id} className=\"flex items-center justify-center border-l border-border\">\n                          <Checkbox\n                            defaultChecked={row.defaults.includes(channel.id)}\n                            disabled={locked}\n                            aria-label={`${row.label} via ${channel.label}`}\n                          />\n                        </div>\n                      )\n                    })}\n                  </div>\n                ))}\n              </div>\n            ))}\n          </div>\n\n          <div className=\"mt-6 flex flex-col-reverse gap-3 sm:flex-row sm:items-center sm:justify-between\">\n            <button type=\"button\" className=\"text-xs text-muted-foreground underline-offset-4 hover:text-foreground hover:underline\">\n              Pause all notifications for 24 hours\n            </button>\n            <Button type=\"submit\">Save preferences</Button>\n          </div>\n        </form>\n      </div>\n    </section>\n  )\n}\n",
      "type": "registry:component"
    }
  ],
  "meta": {
    "iframeHeight": "850px"
  },
  "categories": [
    "forms"
  ]
}