TrademarkTrademark
Docs
Ctrl k
Search docs...
Components

ToggleButton

Updated: October 18, 2026
View on GitHub
Soon
Not released yet. This is on main and is not in any published version yet. It will not install today.

ToggleButton is a quiet Pressable with a label and optional icons. While selected is true it keeps a highlighted background. It does not hold its own state: keep selected in your component and flip it in onPress. See the web ToggleButton page for more examples.

Selected state

Variants

ghost, the default, shows a border only while selected or pressed. outline always shows one. subtle never does.

Sizes, radius and width

size takes xs to xl, from 20 to 48 points tall. m is the default. The corner radius follows the size unless you set radius, and rounded makes it a pill. fillWidth with horizontal lays it out as a full-width row.

Differences from the web

  • Pressed, not hover. The pressed state takes the place of the web's hover state.
  • onPress or onClick. Both work. onPress wins when both are set.
  • One line. The label always stays on one line and ends in an ellipsis when it does not fit, so truncate has no extra effect.
  • No href. Navigate in onPress.

Props

ToggleButton also takes every React Native Pressable prop except children and style, which it replaces.

Prop
Type
Default
Description
labelReactNodeThe button's text.
childrenReactNodeUsed as the label when label is not set.
selectedbooleanfalseKeeps the highlighted background. Reported to screen readers.
variant"ghost" | "outline" | "subtle""ghost"Border style.
size"xs" | "s" | "m" | "l" | "xl""m"Height and padding.
radius"xs" | "s" | "m" | "l" | "xl" | "full" | "none"the sizeCorner radius.
roundedbooleanfalseFully rounded corners.
horizontal"start" | "center" | "end" | "between""center"Content alignment inside the button.
fillWidthbooleanfalseStretches to the parent's width.
weight"default" | "strong""default"Label weight.
truncatebooleanAccepted for the web's API. The label is always one line.
disabledbooleanfalseGreys the button out and blocks presses.
prefixIconIconName | ReactNodeIcon before the label.
suffixIconIconName | ReactNodeIcon after the label.
onPress(event) => voidCalled on tap.
onClick() => voidThe web's name for onPress.
styleViewStyleApplied after the button's own style.
Edit this page on GitHub
TrademarkTrademark
Built with curiosity by Lorant One and the Design Engineers Club