Banner
A line about what's in front of you, under a header: a soft wash with its icon leading, the words in ink, one optional action beside them.
Tones
neutral, the default, for how things are, the Inbox's hand-off reason among them. attention for something broken that needs fixing: red on the wash and the icon, while the words stay ink and keep AAA contrast. The icon sits centred on the words, one line or two.
Okami passed this to you: Asks whether there's parking near the studio.
Instagram is disconnected: Okami can't answer DMs until you reconnect it.
import { Banner } from "@/components/shared/banner";
<Banner>
Okami passed this to you: Asks whether there's parking near the studio.
</Banner>
<Banner tone="attention">
Instagram is disconnected: Okami can't answer DMs until you reconnect it.
</Banner>With an action
Waiting for your answer since 10:11.
<Banner
tone="attention"
action={<Button size="xs" variant="secondary">Reply</Button>}
>
Waiting for your answer since 10:11.
</Banner>Guidelines
- A Banner is the screen telling you; a Notice is Okami speaking in the thread. Use a Banner under a header, about the whole page.
- One at a time, a sentence or two. What needs the person goes in
attention; everything else is neutral.
API reference
| Prop | Type | Default | Description |
|---|---|---|---|
| tone | "neutral" | "attention" | "neutral" | attention: a red wash and icon, for what needs a person now. |
| action | ReactNode | — | The way forward: one small button. |
| children | ReactNode | — | The words, in ink. |