Text
Text is the typographic atom. It renders a <span> and carries the whole style-prop catalogue —
every other text primitive is a Text with a semantic tag and a default style bag.
What it is
A <Box as="span">. TextProps is BoxProps unchanged — there is no separate text-only prop
set. Reach for the standard style props (fontSize, fontWeight, color, lineHeight,
letterSpacing) to vary the type.
Install
Text is exported from usemotif. No separate install.
API
Text
stablefunction Text(props: TextProps): JSX.Element
Element to render. Override for semantic block-level text — `as="p"`, `as="label"`, `as="strong"`.
Every prop Box accepts. `TextProps` is a direct alias of `BoxProps`.
Examples
Inline styled text:
Render as a semantic element:
Responsive font size:
Cross-platform notes
On web Text renders a <span> (or whatever as names). On native it renders a React Native
<Text>; the as prop is ignored, since native text has no tag variants. Style props resolve
through the same token tree on both platforms.