{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "waitlist-header",
  "title": "Waitlist: Header",
  "description": "The top bar: the name, the press kit and Your place, which shows your place once you have one; one bar under the current page, in white over the colour field and on paper elsewhere.",
  "dependencies": [
    "motion"
  ],
  "registryDependencies": [
    "https://eased.dev/r/eased-tokens.json",
    "https://eased.dev/r/eased-motion.json",
    "https://eased.dev/r/waitlist-core.json",
    "https://eased.dev/r/template-core.json",
    "https://eased.dev/r/text-swap.json"
  ],
  "files": [
    {
      "path": "src/registry/eased/templates/waitlist/header.tsx",
      "content": "\"use client\";\n\nimport { TextSwap } from \"../../text-swap/text-swap\";\nimport { BaseLink } from \"../_shared/base\";\nimport { nav } from \"./content\";\nimport { COLUMN, formatPlace, Wordmark } from \"./kit\";\nimport { useLine } from \"./line\";\n\n/** The pages the top bar marks as current. */\nexport type Current = \"/\" | \"/press\" | \"/thanks\";\n\n/**\n * The top bar: the name (home), the press kit and Your place, which shows your place once you\n * have one. The current page is underlined by one bar and marked `aria-current`. Over the\n * colour field (home and the referral page) it sits on the field in white; elsewhere on paper.\n */\nexport function Header({ current, overField = false }: { current?: Current; overField?: boolean }) {\n  const { place, live } = useLine();\n  const action = place === null ? nav.join : nav.place;\n  return (\n    <header\n      data-wl-field={overField ? \"\" : undefined}\n      className={`z-20 text-text ${overField ? \"absolute inset-x-0 top-0 bg-transparent\" : \"relative border-b border-line-subtle\"}`}\n    >\n      <a\n        href=\"#main\"\n        className=\"focus-ring sr-only rounded-control bg-surface-raised px-3 py-2 text-ui focus:not-sr-only focus:absolute focus:top-3 focus:left-4\"\n      >\n        {nav.skip}\n      </a>\n      <nav aria-label={nav.label} className={`${COLUMN} flex h-(--wl-header) items-center justify-between gap-pad-sm`}>\n        <BaseLink href=\"/\" aria-label={nav.home} aria-current={current === \"/\" ? \"page\" : undefined} className={`${ITEM} -ms-2 h-11 px-2 text-ui-md`}>\n          <Wordmark />\n          <Bar on={current === \"/\"} />\n        </BaseLink>\n        <div className=\"flex items-center gap-1 sm:gap-2\">\n          <BaseLink href={nav.press.href} aria-current={current === \"/press\" ? \"page\" : undefined} className={`${ITEM} h-11 px-2 text-ui text-text-secondary hover-fine:text-text`}>\n            {nav.press.label}\n            <Bar on={current === \"/press\"} />\n          </BaseLink>\n          <BaseLink\n            href={action.href}\n            aria-current={current === \"/thanks\" && place !== null ? \"page\" : undefined}\n            data-wl-restore=\"\"\n            className={`${ITEM} hit-area h-control-md bg-surface-hover px-3 font-medium text-ui hover-fine:bg-surface-active`}\n          >\n            {live ? <TextSwap aria-hidden>{place === null ? action.label : formatPlace(place)}</TextSwap> : <span aria-hidden>{place === null ? action.label : formatPlace(place)}</span>}\n            <span className=\"sr-only\">{place === null ? action.label : `${nav.place.label}, ${formatPlace(place)}`}</span>\n            <Bar on={current === \"/thanks\" && place !== null} className=\"-bottom-1.5 inset-x-3\" />\n          </BaseLink>\n        </div>\n      </nav>\n    </header>\n  );\n}\n\n/** The items: the links 44px tall, the action 36px with a 44px target; the name is pulled out by its padding so its mark, not its box, sits on the column's edge. */\nconst ITEM =\n  \"focus-ring relative inline-flex items-center rounded-control whitespace-nowrap transition-colors duration-(--eased-duration-fast) ease-standard\";\n\n/** The current page's bar, under the item's text. */\nfunction Bar({ on, className = \"inset-x-2 bottom-1\" }: { on: boolean; className?: string }) {\n  return on ? <span aria-hidden className={`absolute h-0.5 rounded-full bg-text ${className}`} /> : null;\n}\n",
      "type": "registry:component",
      "target": "@components/eased/templates/waitlist/header.tsx"
    }
  ],
  "meta": {
    "template": "waitlist",
    "kind": "template-section",
    "industries": [
      "saas"
    ]
  },
  "type": "registry:block"
}