{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "error-page",
  "type": "registry:block",
  "title": "Error page",
  "description": "A 404, 500 or maintenance page: status code, headline, explanation and two ways out.",
  "categories": [
    "error"
  ],
  "dependencies": [
    "zod@^4.6.5"
  ],
  "registryDependencies": [
    "https://ui.klarhimmel.com/r/block-kit.json",
    "https://ui.klarhimmel.com/r/editing.json"
  ],
  "files": [
    {
      "path": "src/blocks/error-page/spec.ts",
      "type": "registry:file",
      "target": "components/klarhimmel/blocks/error-page/spec.ts",
      "content": "import { z } from 'zod';\nimport { defineSpec, link, t } from '../_shared/schema';\n\nconst schema = z.object({\n  code: t(12),\n  title: t(100),\n  description: t(240),\n  primary: link,\n  secondary: link,\n});\n\nexport const spec = defineSpec({\n  type: 'error-page',\n  aliases: ['error/page'],\n  name: 'Error page',\n  category: 'error',\n  role: 'body',\n  description: 'A 404, 500 or maintenance page: status code, headline, explanation and two ways out.',\n  schema,\n  defaults: {\n    code: '404',\n    title: 'Say what went wrong in plain words',\n    description: 'Say in two sentences what likely happened, then point them home or to someone who can help.',\n    primary: { label: 'Main action', href: '/' },\n    secondary: { label: 'Second action', href: '#contact' },\n  },\n});\n"
    },
    {
      "path": "src/blocks/error-page/index.tsx",
      "type": "registry:file",
      "target": "components/klarhimmel/blocks/error-page/index.tsx",
      "content": "import { useId } from 'react';\nimport { Text, withHeadingLevel } from '../../editing';\nimport { ActionLink, Container, Section } from '../_shared/kit';\nimport { spec } from './spec';\nimport type { BlockProps } from '../types';\nimport type { z } from 'zod';\n\nexport { spec };\ntype Props = z.infer<typeof spec.schema>;\n\nfunction ErrorPage({ props }: BlockProps<Props>) {\n  const id = useId();\n  return (\n    <Section labelledBy={id} className=\"py-24 @3xl:py-36\">\n      <Container width=\"narrow\" className=\"text-center\">\n        <Text path={['code']} value={props.code} as=\"p\" className=\"text-kh-small font-medium tracking-widest text-kh-accent-ink\" />\n        <div id={id}>\n          <Text path={['title']} value={props.title} as=\"h1\" className=\"mt-4 text-kh-display font-semibold\" />\n        </div>\n        <Text path={['description']} value={props.description} as=\"p\" className=\"mx-auto mt-6 max-w-kh-lead text-kh-lead text-kh-muted\" />\n        <div className=\"mt-10 flex flex-wrap justify-center gap-3\">\n          <ActionLink path={['primary']} value={props.primary} />\n          <ActionLink path={['secondary']} value={props.secondary} variant=\"secondary\" />\n        </div>\n      </Container>\n    </Section>\n  );\n}\n\nexport default withHeadingLevel(ErrorPage);\n"
    }
  ]
}
