{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "contact-overlap-card",
  "type": "registry:block",
  "title": "Contact, overlap card",
  "description": "A large picture across seven of twelve columns with a card overlapping its right edge, holding a label, heading, lead, address, phone and email lines, two buttons and a quiet third link. On a phone the card slides up over the picture's lower edge.",
  "categories": [
    "contact"
  ],
  "dependencies": [
    "lucide-react@^1.49.0",
    "zod@^4.6.5"
  ],
  "registryDependencies": [
    "https://ui.klarhimmel.com/r/block-kit.json",
    "https://ui.klarhimmel.com/r/button.json",
    "https://ui.klarhimmel.com/r/editing.json",
    "https://ui.klarhimmel.com/r/kit-c-proof.json"
  ],
  "files": [
    {
      "path": "src/blocks/contact-overlap-card/spec.ts",
      "type": "registry:file",
      "target": "components/klarhimmel/blocks/contact-overlap-card/spec.ts",
      "content": "import { z } from 'zod';\nimport { defineSpec, link, media, req, t } from '../_shared/schema';\n\nconst line = z.object({\n  /** Picks the small icon: a place, a phone or a mail. */\n  kind: z.enum(['address', 'phone', 'email']),\n  value: req(80),\n  /** Where the line goes (tel:, mailto:, a map link); without one it is plain text. */\n  href: t(300).optional(),\n});\n\nconst schema = z.object({\n  media,\n  eyebrow: t(60),\n  title: req(100),\n  description: t(240),\n  /** A list is an array field, never a slot. */\n  lines: z.array(line).min(1).max(5),\n  primary: link,\n  secondary: link.optional(),\n  textLink: link.optional(),\n});\n\nexport const spec = defineSpec({\n  type: 'contact-overlap-card',\n  aliases: ['contact/overlap-card'],\n  sourceRuns: ['rmwj0v8yj198991'],\n  name: 'Contact, overlap card',\n  category: 'contact',\n  role: 'body',\n  description: 'A large picture across seven of twelve columns with a card overlapping its right edge, holding a label, heading, lead, address, phone and email lines, two buttons and a quiet third link. On a phone the card slides up over the picture\\'s lower edge.',\n  schema,\n  defaults: {\n    media: { src: '', alt: 'Show the place or the people a visitor will meet' },\n    eyebrow: 'Name the section',\n    title: 'Say how a visitor reaches you',\n    description: 'Say in one or two sentences when you answer and what to bring up first.',\n    lines: [\n      { kind: 'address', value: 'Give the street and town', href: '#map' },\n      { kind: 'phone', value: 'Give the phone number', href: '#phone' },\n      { kind: 'email', value: 'Give the email address', href: '#email' },\n    ],\n    primary: { label: 'Main action', href: '#start' },\n    secondary: { label: 'Second action', href: '#contact' },\n    textLink: { label: 'Name the extra page', href: '#more' },\n  },\n});\n"
    },
    {
      "path": "src/blocks/contact-overlap-card/index.tsx",
      "type": "registry:file",
      "target": "components/klarhimmel/blocks/contact-overlap-card/index.tsx",
      "content": "import { Mail, MapPin, Phone } from 'lucide-react';\nimport { Media, Text, withHeadingLevel } from '../../editing';\nimport { safeHref } from '../../ui/button';\nimport { ActionLink, Opt, Section } from '../_shared/kit';\nimport { useHeadingId } from '../_shared/c-proof-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\nconst ICON = { address: MapPin, phone: Phone, email: Mail } as const;\n\n// A picture across seven of twelve columns with a card of contact lines lapping its right edge; on a phone the card rides up over the picture's foot.\nfunction ContactOverlapCard({ props }: BlockProps<Props>) {\n  const id = useHeadingId(props.title);\n  return (\n    <Section labelledBy={id}>\n      <div className=\"px-kh-gutter\">\n        <div className=\"mx-auto grid max-w-kh-page grid-cols-1 items-center @5xl:grid-cols-12\">\n          <div className=\"@5xl:col-span-7 @5xl:col-start-1 @5xl:row-start-1\">\n            <Media path={['media']} value={props.media} ratio=\"4 / 3\" className=\"w-full rounded-kh-xl @5xl:aspect-[5/4]\" />\n          </div>\n          <div className=\"relative z-10 -mt-16 rounded-kh-xl border border-kh-line bg-kh-surface p-8 shadow-kh-3 @3xl:p-12 @5xl:col-span-6 @5xl:col-start-7 @5xl:row-start-1 @5xl:-ml-24 @5xl:mt-0\">\n            <Opt path={['eyebrow']} value={props.eyebrow} className=\"font-kh-mono text-kh-caption uppercase tracking-wide text-kh-accent-ink\" placeholder=\"Eyebrow\" />\n            <div id={id}>\n              <Text path={['title']} value={props.title} as=\"h2\" className=\"mt-4 font-kh-display text-kh-heading text-kh-ink\" />\n            </div>\n            <Opt path={['description']} value={props.description} multiline className=\"mt-4 font-kh-sans text-kh-lead text-kh-ink-2\" placeholder=\"Description\" />\n            <ul className=\"mt-8 space-y-4\">\n              {props.lines.map((l, i) => {\n                const I = ICON[l.kind] ?? MapPin;\n                const text = <Text path={['lines', i, 'value']} value={l.value} as=\"span\" />;\n                return (\n                  <li key={i} className=\"flex items-center gap-3 font-kh-sans text-kh-body text-kh-ink\">\n                    <I className=\"size-5 shrink-0 text-kh-accent-ink\" strokeWidth={1.8} aria-hidden=\"true\" />\n                    {l.href ? <a href={safeHref(l.href)} className=\"transition-colors hover:text-kh-accent-ink focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-kh-accent\">{text}</a> : text}\n                  </li>\n                );\n              })}\n            </ul>\n            <div className=\"mt-8 flex flex-wrap items-center gap-3\">\n              <ActionLink path={['primary']} value={props.primary} size=\"md\" className=\"rounded-kh-pill\" />\n              {props.secondary && <ActionLink path={['secondary']} value={props.secondary} variant=\"secondary\" size=\"md\" className=\"rounded-kh-pill\" />}\n            </div>\n            {props.textLink && props.textLink.label && (\n              <a href={safeHref(props.textLink.href)} className=\"mt-6 inline-block font-kh-sans text-kh-small font-medium text-kh-accent-ink underline underline-offset-4 transition-colors hover:text-kh-accent focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-kh-accent\">\n                <Text path={['textLink', 'label']} value={props.textLink.label} as=\"span\" />\n              </a>\n            )}\n          </div>\n        </div>\n      </div>\n    </Section>\n  );\n}\n\nexport default withHeadingLevel(ContactOverlapCard);\n"
    }
  ]
}
