Skip to content

components/Callout

import { … } from 'zidane-ui'ui/src/components/Callout.tsx

Components#

CalloutComponent#

Renders a note on a soft wash of its tone (or beside a bar of it), with a glyph and an optional title.

TypeScript
function Callout(props: CalloutProps): Element
Parameters
NameTypeDescription
propsCalloutProps

CalloutProps.

Element
Callout props
NameTypeDefaultDescription
children?ReactNode

The note.

className?string

Extra classes on the root element.

style?CSSProperties

Inline styles on the root element.

title?ReactNode

A bold first line.

tone?CalloutTone'neutral'

The color and the glyph.

variant?CalloutVariant'wash'

wash: a soft box of its tone. bar: flat, a bar of its tone on the left.

ui/src/components/Callout.tsx:45

Interfaces#

CalloutPropsInterface#

Props for Callout.

TypeScript
interface CalloutProps
CalloutProps properties
NameTypeDefaultDescription
children?ReactNode

The note.

className?string

Extra classes on the root element.

style?CSSProperties

Inline styles on the root element.

title?ReactNode

A bold first line.

tone?CalloutTone'neutral'

The color and the glyph.

variant?CalloutVariant'wash'

wash: a soft box of its tone. bar: flat, a bar of its tone on the left.

ui/src/components/Callout.tsx:17

Types#

CalloutToneType#

The tone of a Callout.

TypeScript
type CalloutTone = 'neutral' | 'info' | 'success' | 'warning' | 'danger'

ui/src/components/Callout.tsx:11

CalloutVariantType#

How a Callout sets itself apart: a soft wash of its tone, or a bar of its tone on the left.

TypeScript
type CalloutVariant = 'wash' | 'bar'

ui/src/components/Callout.tsx:14