callout
Callout
An aside between paragraphs: a caveat, a tip or a warning. The body is regular Markdown. For something another person said, use Quote.
- use it
- Good for an aside the reader should not skip, like a caveat, a tip, or a breaking change.
warning
type sets the frame title and the glyph. The body is Markdown — write it like a paragraph.
The CLI copies files into registry/default. It does not add an npm dependency, so there is nothing to update later — edit the source.
import { Callout } from "@/registry/default/callout/callout"
<Callout type="warning">
The CLI copies files into registry/default. It does not add an npm
dependency, so there is nothing to update later — edit the source.
</Callout>install
command
tip with a title
title overrides the type on the frame. Lists work.
One accent is the default. Opt in when a second series needs its own hue:
- palette="duo" for two series
- palette="multi" for three
import { Callout } from "@/registry/default/callout/callout"
<Callout type="tip" title="Palette">
One accent is the default. Opt in when a second series needs its own hue:
- palette="duo" for two series
- palette="multi" for three
</Callout>| Prop | Type | Default | Description |
|---|---|---|---|
| type | "note" | "tip" | "warning" | "danger" | "note" | Sets the frame title and the glyph in the margin. |
| title | string | — | Overrides the frame title. Defaults to the type. |
| children | ReactNode | — | Markdown. Paragraphs, lists, inline code, links. |
| corner | string | "+" | Character at each corner of the frame. |
| frame | "box" | "corners" | "rule" | "none" | "box" | box draws the dashed border. corners keeps only the corner marks. rule draws dashed lines above and below. none drops the border and padding, and puts the title above the content. |
| className | string | — | Passed to the outer frame. |