{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "site-header-headroom",
  "title": "Site header headroom",
  "description": "A marketing site’s header that steps aside: it slides away as the page scrolls down and comes back as soon as it scrolls up. On a phone the menus open in a sheet.",
  "dependencies": [],
  "registryDependencies": [
    "https://kinoui.com/r/badge.json",
    "https://kinoui.com/r/site-header-parts.json",
    "https://kinoui.com/r/skeleton.json",
    "https://kinoui.com/r/theme.json"
  ],
  "files": [
    {
      "path": "registry/components/kino/site-header-headroom/site-header-headroom.tsx",
      "content": "'use client'\n\nimport {\n  SiteHeaderNav,\n  siteHeaderActionsClassName,\n  siteHeaderColumnClassName,\n  siteHeaderMenuClassName,\n  siteHeaderNavClassName,\n  SiteHeaderPhoneMenu,\n  type SiteHeaderProps,\n  useHeaderFit,\n  useHeaderScroll,\n} from '@/registry/lib/site-header-parts'\nimport { useRef } from 'react'\n\nimport { cn } from '@/lib/utils'\n\n/*\n * A marketing site's header that steps aside while the visitor reads: it\n * slides up out of the way as the page scrolls down, and back the moment\n * they scroll up, or when focus comes into it. On a phone the menus open\n * in a sheet from the side.\n *\n *   <SiteHeaderHeadroom\n *     logo={<a href='/' aria-label='Kino, home'><Logo /></a>}\n *     items={[{ label: 'Product', links: [...] }, { label: 'Pricing', href: '/pricing' }]}\n *     actions={<a href='/signup' className={buttonVariants()}>Get started</a>}\n *   />\n */\nfunction SiteHeaderHeadroom({\n  logo,\n  items,\n  actions,\n  label = 'Main',\n  className,\n  ...props\n}: SiteHeaderProps) {\n  const header = useRef<HTMLElement>(null)\n  useHeaderScroll(header, { hides: true })\n  useHeaderFit(header)\n  return (\n    <header\n      ref={header}\n      data-slot='site-header'\n      className={cn(\n        '@container/site-header group/header bg-background/90 sticky top-0 z-40 w-full min-w-0 border-b backdrop-blur-lg',\n        // It slides up by its own height, its line included, and back down.\n        'transition-[translate] duration-(--motion-layout-duration) ease-(--motion-layout-easing) data-hidden:-translate-y-full data-hidden:duration-(--motion-exit-duration) data-hidden:ease-(--motion-exit-easing) motion-reduce:transition-none',\n        className,\n      )}\n      {...props}\n    >\n      <div className={cn(siteHeaderColumnClassName, 'flex h-16 items-center gap-6')}>\n        <div data-site-header-part='start' className='flex shrink-0 items-center'>\n          {logo}\n        </div>\n        <SiteHeaderNav items={items} label={label} className={siteHeaderNavClassName} />\n        <div className='ms-auto flex items-center gap-2'>\n          {actions ? (\n            <div data-site-header-part='actions' className={siteHeaderActionsClassName}>\n              {actions}\n            </div>\n          ) : null}\n          <div className={siteHeaderMenuClassName}>\n            <SiteHeaderPhoneMenu\n              logo={logo}\n              items={items}\n              actions={actions}\n              label={label}\n            />\n          </div>\n        </div>\n      </div>\n    </header>\n  )\n}\n\nexport { SiteHeaderHeadroom }\n",
      "type": "registry:component",
      "target": "@components/kino/site-header-headroom/site-header-headroom.tsx"
    }
  ],
  "type": "registry:block"
}