Call-to-action panel
The invitation at the end of a section or a page: a title, why it matters, the ways to answer — in the hue of the page.
- Domaine
- Blocs de page et gabarits
- Niveau de support
- Taille
- 0.7 kB gzip, budget 0.5 kB
- Qui l'utilise
- 5 fichiers des produits et sites en production l'importent (krizaka.com : 3) Compté dans l'inventaire daté du 2026-11-23.
import { CtaPanel } from "@krizaka/ui/cta-panel";Web uniquement — React, depuis @krizaka/ui/cta-panel. Bêta : son API peut encore changer à une version mineure.
- Mobile · n/a. A block of a public site's page; an app screen on a phone is built from Screen, Header and Card. → Button
- Bureau · n/a. A public site's page, not a window of the Mac app.
Pourquoi il est là. Used by Folioviv, krizaka.com.
Quand l’utiliser
- The end of a page that argued: discuss, propose, contact, get started.
- The end of a section that asks the reader for something.
Quand ne pas l’utiliser
Installation
Installer
npm install @krizaka/ui @krizaka/tailwind @krizaka/tokens tailwindcssStyles
@import "tailwindcss";
@import "@krizaka/tailwind";
@import "@krizaka/ui/tailwind.css";Importer
import { CtaPanel } from "@krizaka/ui/cta-panel";Exemples
Discuss
The end of a building block's page: discuss or propose.
Props
A call to act: title, why, the actions — the closing panel of a section or a page.
| Prop | Type | Défaut | Description |
|---|---|---|---|
titlerequis | ReactNode | — | The invitation: Something to say about it?. |
body | ReactNode | — | Why it matters, in one or two sentences. |
level | 2 | 3 | 2 | The title's level. |
reveal | boolean | — | Rises once into place ([data-reveal]). Never on the first screen. |
Accessibilité
- Its title is a real heading (
h2orh3): it appears in the page's outline. - The tint is decorative; text stays in the text roles (AA).
Bonnes pratiques
- One invitation per panel, one or two actions (an
ActionBar). - Say why answering matters to the reader, not to you.
- Give it an
idwhen other pages link to it (#discuss).
Composants liés
Générée depuis le code de @krizaka/ui 5.3.4 : son meta.ts, ses exemples et ses types.Modifier cette documentation sur GitHub