Skip to content
Eskais UI

Blocks

Hero

The top of a landing page: an eyebrow chip, a title with an optional muted second line, a description, actions, a copyable install command and an aside for a live demo, side by side or centered by container width, over a token-drawn grid or glow.

Example

Now in beta

Ship the page, not the layout.

Pass the copy, the actions and a live demo; the hero lays them out by its container's width.

npx shadcn@latest add @eskais/hero

Any node goes here

LiveInteractive

Installation

npx shadcn@latest add @eskais/hero
Brings alongcode-block

Usage

Import
import { Hero } from "@/components/ui/hero"

The first section of a landing page: eyebrow, title and a muted second line, description, actions, an install command and an aside for a live demo.

API reference

Hero

PropTypeDefault
eyebrowShown as a chip above the title.ReactNode–
titlerequiredReactNode–
titleMutedA second line of the title, in the muted colour.ReactNode–
titleBreak`false` lets the muted part continue the title's line instead of starting its own.booleantrue
descriptionReactNode–
actionsReactNode–
asideBeside the text on wide containers, below it on narrow ones.ReactNode–
installA shell command, shown in a copyable CodeBlock below the actions.string–
installLabelstring"Install command"
align"start" | "center""start"
decoration`grid` draws faint grid lines that fade out behind the hero; `glow` adds a wash from the link colour."grid" | "glow" | "none""grid"
headingLevel1 | 21

Also takes <section> attributes except title.

Other exports

type HeroProps

Accessibility

  • A section named by its heading (h1 by default, headingLevel for another level).
  • The decoration is aria-hidden and drawn with theme tokens, so it follows the palette and mode.

Agent actions

The install command is a CodeBlock with a copy action; actions are whatever controls you pass.

Runs agent.snapshot() from @ui-sdk/react/agent on the live preview above.