Ir al contenido

Hero

La primera pantalla de una página de inicio: la promesa con la voz, una frase, la entrada y el producto funcionando.

import { Hero } from '@sypnia/ui/react'

En esta página
  1. En noche, con las luciérnagas
  2. Cuándo usarlo
  3. Para todos
  4. Props

En noche, con las luciérnagas

Open source, MIT

Every bug leaves a light on.

Sypnia follows it back to where it started: the tap, the page, the call that failed.

Run it yourself for free, or let us run it.

Failing nowCheckout fails for cards from Peru128 people · since 09:12
Código
import { Button, Hero, SiteHeader, Stage, Status } from '@sypnia/ui/react';

export default function Landing() {
  return (
    <div data-surface="night">
      <Hero fireflies
        header={<SiteHeader homeHref="#" links={[{ label: 'Product', href: '#' }, { label: 'Pricing', href: '#' }, { label: 'Docs', href: '#' }]} action={<Button variant="primary" size="sm" href="#">Start</Button>} />}
        kicker="Open source, MIT"
        title="Every bug leaves a light on."
        lead="Sypnia follows it back to where it started: the tap, the page, the call that failed."
        actions={<><Button variant="primary" size="lg" href="#">Start free</Button><Button variant="quiet" size="lg" href="#">Read the docs</Button></>}
        note="Run it yourself for free, or let us run it."
        stage={<Stage url="app.sypnia.com/problems/42" float label="A problem in the console"><div className="sy-stack" style={{ '--gap': 'var(--s-2)' } as React.CSSProperties}><Status tone="fail" live>Failing now</Status><strong>Checkout fails for cards from Peru</strong><span className="sy-text--sm sy-text--muted">128 people · since 09:12</span></div></Stage>} />
    </div>
  );
}

Cuándo usarlo

Úsalo cuando

  • La parte de arriba de una página de inicio o de producto.

No lo uses cuando

  • Dentro de una app.
  • Dos botones primarios: una entrada y una alternativa.

Para todos

  • Su título es el único encabezado de nivel 1 de la página; las luciérnagas están ocultas; el escenario tiene nombre.

Props

HeroTipoPor defecto
titleobligatorio

The promise, in the voice. The page's only level 1 heading.

ReactNode
actions

One primary button and at most one more.

ReactNode
after ReactNode
fireflies

The night field behind it.

boolean
header

The header, inside the hero so it shares its background.

ReactNode
kicker

A few words above the title, with the lit dot.

ReactNode
lead ReactNode
lit string
note

A line under the buttons: what it costs, what it needs.

ReactNode
stage

The product shown working, on the other side (a Stage, a Phone).

ReactNode
  1. En noche, con las luciérnagas
  2. Cuándo usarlo
  3. Para todos
  4. Props

    Busca páginas, secciones y términos