{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "hero-split",
  "title": "Hero split",
  "description": "The top of a landing page, split: the words on the start side and the product beside them, running off the page’s edge. Each part arrives once, in order; the shot drifts up a little slower than the page as it scrolls past.",
  "dependencies": [],
  "registryDependencies": [
    "https://kinoui.com/r/avatar.json",
    "https://kinoui.com/r/badge.json",
    "https://kinoui.com/r/button.json",
    "https://kinoui.com/r/meter.json",
    "https://kinoui.com/r/sparkline.json",
    "https://kinoui.com/r/hero-parts.json",
    "https://kinoui.com/r/scroll.json"
  ],
  "files": [
    {
      "path": "registry/components/kino/hero-split/hero-split.tsx",
      "content": "'use client'\n\nimport {\n  HeroBackdrop,\n  heroEnter,\n  type HeroProps,\n  heroSectionClassName,\n  HeroWords,\n  pageColumnClassName,\n} from '@/registry/lib/hero-parts'\nimport { useScrollLinked } from '@/registry/lib/scroll'\nimport { useId, useRef } from 'react'\n\nimport { cn } from '@/lib/utils'\n\n/*\n * The top of a landing page, split: the words on the start side and the\n * product on the other, wider than its column and running off the hero's\n * edge. The shot arrives after the words, then drifts up a little slower\n * than the page as it scrolls past, so it reads as further away.\n *\n *   <HeroSplit\n *     title='Plan the cycle. Ship it on time.'\n *     description='Kino turns your issues into a plan you can trust.'\n *     actions={<a href='/signup' className={buttonVariants({ size: 'lg' })}>Start free</a>}\n *     shot={<HeroShot label='The cycle view'>…</HeroShot>}\n *   />\n */\n\nfunction HeroSplit({\n  title,\n  description,\n  announcement,\n  actions,\n  shot,\n  heading = 'h1',\n  className,\n  ...props\n}: HeroProps) {\n  const titleId = useId()\n  const drift = useRef<HTMLDivElement>(null)\n  useScrollLinked(drift, {\n    from: { transform: 'translateY(0px)' },\n    to: { transform: 'translateY(calc(var(--hero-drift,1.5rem) * -1))' },\n    // From where it sits at first to well past the top of the view.\n    range: [1, -0.5],\n    pace: 'even',\n  })\n\n  return (\n    <section\n      data-slot='hero-split'\n      aria-labelledby={titleId}\n      className={cn(heroSectionClassName, className)}\n      {...props}\n    >\n      <HeroBackdrop />\n      <div\n        className={cn(\n          pageColumnClassName,\n          'grid flex-1 items-center gap-12 pt-16 pb-16 @3xl/hero:grid-cols-[minmax(0,5fr)_minmax(0,7fr)] @3xl/hero:pt-24 @3xl/hero:pb-24',\n        )}\n      >\n        <HeroWords\n          titleId={titleId}\n          title={title}\n          description={description}\n          announcement={announcement}\n          actions={actions}\n          heading={heading}\n          align='start'\n          // Half the hero's width: a size smaller than a centred title.\n          titleClassName='@3xl/hero:text-4xl @5xl/hero:text-5xl @7xl/hero:text-6xl'\n        />\n        {shot ? (\n          <div className='min-w-0'>\n            {/* On a wide hero the shot is wider than its column, and never narrower than a laptop's window, so it runs off the edge. */}\n            <div className={cn('@3xl/hero:w-[max(140%,58rem)]', heroEnter('shot'))}>\n              <div ref={drift} className='will-change-transform'>\n                {shot}\n              </div>\n            </div>\n          </div>\n        ) : null}\n      </div>\n    </section>\n  )\n}\n\nexport { HeroSplit }\n",
      "type": "registry:component",
      "target": "@components/kino/hero-split/hero-split.tsx"
    }
  ],
  "type": "registry:block"
}