Types
The types of bar buttons.
NavigationButton
A button of the top bar or the toolbar, with what its press does.
type NavigationButton = Omit<OptionsTopBarButton, 'menu'> & {
onPress?: ButtonPressHandler;
menu?: NavigationButtonMenu;
}
| Member | Type | Description |
|---|---|---|
| pinned | boolean | Whether a right button stays out of the overflow menu. On iOS 16+ it goes to the pinned group at the trailing edge, behind the overflow button, in a capsule of its own (several pinned buttons share it); when space runs out iOS hides the title first. On Android it stays in the bar while other right buttons move to the overflow when they don't fit. No effect on left and center buttons. |
| selected | boolean | Whether the button is drawn as switched on: on iOS 26 filled with its color, with the icon or text on it. For a toggle this is the starting state, and |
| badgeColor | Color | (iOS 26+) The color of the badge. Without it, the system red. |
| fontFamily | FontFamily | The font family of the text. On iOS the font is built from all font options together, the size defaulting to 17. |
| fontStyle | FontStyle | The slant of the text. |
| fontWeight | FontWeight | The weight of the text. |
| fontSize | number | The size of the text: points on iOS (17 once any font option is set), sp on Android. |
| iconInsets | IconInsets | The space around the image of |
| disableIconTint | boolean | Whether the icon keeps its own colors instead of being tinted. On iOS an SF Symbol stays multicolor and a side color from |
| idRequired | string | The id of the button: the |
| allCaps | boolean | Whether the text is drawn in capitals. Without it, as the theme says (not in capitals in Material 3). |
| icon | ImageResource | The icon: an image, or an icon for each platform ( On iOS an SF Symbol without a On Android the icon is a drawable resource of the app or an image source, tinted with |
| component | OptionsTopBarButtonComponent | A React component as the button. The component handles its own touches: the bar sends no press for it, and |
| systemItem | SystemItemIcon | The system button. Only |
| text | string | The text of the button. A button with an icon keeps it as a label for the overflow menu, the customization panel and VoiceOver (iOS), or for TalkBack, the tooltip of a long press and the overflow menu (Android). |
| accessibilityLabel | string | The text a screen reader says for the button. |
| enabled | boolean | Whether the button reacts. A disabled button is dimmed (see |
| color | Color | The color of the text and of the icon; it beats the color of the side ( |
| disabledColor | Color | The color while the button is disabled; it beats the color of the side. Android defaults to light gray. |
| iconBackground | IconBackgroundOptions | A shape behind the icon. It works with an |
| style | 'plain' | 'prominent' |
|
| testID | string | The identifier tests find the button by: the accessibility identifier on iOS, the resource id and the view tag on Android (in the bar and in the overflow menu). A component button puts it on its slot; the component sets its own inside. |
| hideSharedBackground | boolean | (iOS 26+, glass design) Whether the button has no glass capsule under it; neighbors keep theirs. By default |
| showText | boolean | Whether a button with an |
| group | string | (iOS 26+, glass design) Buttons next to each other with the same group share one capsule; a button without a group has its own. Without the glass design it does nothing, on iOS 15 there are no groups. A side that has a group of several buttons doesn't animate button changes. The toolbar has no groups: only icons share a capsule there. For center buttons the group is a section of the overflow menu, and its name is the id the customization is saved under. |
| badge | number | string | boolean | null | (iOS 26+) A badge on the button: a number, a short text, or |
| badgeTextColor | Color | (iOS 26+) The color of the number or text of the badge. Without it, white. |
| toggle | boolean | Whether the button is a toggle: every press flips |
| menuOnLongPress | boolean | Whether a press does the button's own action (a press event, a toggle) and the menu opens on a long press. Without it the menu opens on a press. |
| customization | 'fixed' | 'movable' | 'optional' | (iOS 16+) For a center button, when |
| shownByDefault | boolean | (iOS 16+) Whether an |
| priority | 'high' | 'standard' | 'low' | Which buttons move to the overflow menu last: |
| vertical | boolean | (iOS 27.1+) Whether the button may move to the vertical bar of iPhone Duo: |
| onPress | ButtonPressHandler | |
| menu | NavigationButtonMenu |
ButtonPressHandler
Called when the button is pressed. The function stays in JavaScript; the native side gets the button's id. It gets the navigation of its screen, so the options need no import: onPress: ({ navigation }) => navigation.openMenu('left').
type ButtonPressHandler = (event: ButtonPressEvent) => void
NavigationButtonMenu
The menu of a button, whose items take onPress.
type NavigationButtonMenu = Omit<OptionsTopBarButtonMenu, 'items'> & {
items: (NavigationMenuItem | NavigationSubmenu)[];
}
| Member | Type | Description |
|---|---|---|
| title | string | The title above the items. (iOS) Android doesn't show it. |
| singleSelection | boolean | Whether only one item of the top level can be checked at a time: picking an item moves the check mark to it. On iOS this is the system's single-selection menu; on Android the items are checkable. |
| itemsRequired | (NavigationMenuItem | NavigationSubmenu)[] |
NavigationMenuItem
An item of a button menu, with what picking it does.
type NavigationMenuItem = OptionsTopBarButtonMenuItem & { onPress?: ButtonPressHandler }
| Member | Type | Description |
|---|---|---|
| id | string | The id of the item, sent as |
| title | string | The text of the item. Without it the item shows an empty string. |
| icon | ImageResource | The icon in front of the text. On iOS an SF Symbol or an image; on Android a drawable resource or an image source. On Android the icons show in the menu as soon as one item has one, tinted like the menu's other icons (the error color for a destructive item). An icon that fails to load leaves the item without one. |
| destructive | boolean | Whether the item is drawn as a destructive action: red on both platforms. |
| disabled | boolean | Whether the item is shown but can't be picked. |
| checked | boolean | Whether the item carries a check mark. On Android the item is checkable, also outside a |
| testID | string | The identifier tests find the item by: the accessibility identifier on iOS, the resource id and view tag of the item on Android. Where the system gives no way to set it, the item is found by its text. |
| onPress | ButtonPressHandler |
NavigationSubmenu
A submenu of a button menu.
type NavigationSubmenu = Omit<OptionsTopBarButtonSubmenu, 'items'> & {
items: (NavigationMenuItem | NavigationSubmenu)[];
}
| Member | Type | Description |
|---|---|---|
| icon | ImageResource | The icon of the submenu item, as for a menu item. |
| testID | string | The identifier tests find the submenu item by, as for a menu item. |
| title | string | The text of the submenu item. Without it the item shows an empty string. |
| singleSelection | boolean | Whether only one item of this submenu can be checked at a time. |
| itemsRequired | (NavigationMenuItem | NavigationSubmenu)[] |
OptionsTopBarButton
A button of the top bar (leftButtons, rightButtons, centerButtons) or of the toolbar (toolbar.buttons). The kinds are picked by the fields that are set. On iOS, the first that fits wins: a component, then an icon with text and showText, then an icon with iconBackground or iconInsets, then an SF Symbol, an image icon, a text, a systemItem; a button with none of them is not shown. On Android a button is a button of the bar's row: text, icon or a component. Lists of buttons are replaced as a whole and take nothing from the lists of lower layers.
Text, icon, color and similar fields are the same in all four places; where a place or a side differs, the field says so.
interface OptionsTopBarButton
| Member | Type | Description |
|---|---|---|
| idRequired | string | The id of the button: the |
| allCaps | boolean | Whether the text is drawn in capitals. Without it, as the theme says (not in capitals in Material 3). |
| icon | ImageResource | The icon: an image, or an icon for each platform ( On iOS an SF Symbol without a On Android the icon is a drawable resource of the app or an image source, tinted with |
| iconInsets | IconInsets | The space around the image of |
| component | OptionsTopBarButtonComponent | A React component as the button. The component handles its own touches: the bar sends no press for it, and |
| systemItem | SystemItemIcon | The system button. Only |
| text | string | The text of the button. A button with an icon keeps it as a label for the overflow menu, the customization panel and VoiceOver (iOS), or for TalkBack, the tooltip of a long press and the overflow menu (Android). |
| accessibilityLabel | string | The text a screen reader says for the button. |
| fontFamily | FontFamily | The font family of the text. On iOS the font is built from all font options together, the size defaulting to 17. |
| fontStyle | FontStyle | The slant of the text. |
| fontWeight | FontWeight | The weight of the text. |
| fontSize | number | The size of the text: points on iOS (17 once any font option is set), sp on Android. |
| enabled | boolean | Whether the button reacts. A disabled button is dimmed (see |
| disableIconTint | boolean | Whether the icon keeps its own colors instead of being tinted. On iOS an SF Symbol stays multicolor and a side color from |
| color | Color | The color of the text and of the icon; it beats the color of the side ( |
| disabledColor | Color | The color while the button is disabled; it beats the color of the side. Android defaults to light gray. |
| iconBackground | IconBackgroundOptions | A shape behind the icon. It works with an |
| style | 'plain' | 'prominent' |
|
| testID | string | The identifier tests find the button by: the accessibility identifier on iOS, the resource id and the view tag on Android (in the bar and in the overflow menu). A component button puts it on its slot; the component sets its own inside. |
| hideSharedBackground | boolean | (iOS 26+, glass design) Whether the button has no glass capsule under it; neighbors keep theirs. By default |
| showText | boolean | Whether a button with an |
| group | string | (iOS 26+, glass design) Buttons next to each other with the same group share one capsule; a button without a group has its own. Without the glass design it does nothing, on iOS 15 there are no groups. A side that has a group of several buttons doesn't animate button changes. The toolbar has no groups: only icons share a capsule there. For center buttons the group is a section of the overflow menu, and its name is the id the customization is saved under. |
| badge | number | string | boolean | null | (iOS 26+) A badge on the button: a number, a short text, or |
| badgeColor | Color | (iOS 26+) The color of the badge. Without it, the system red. |
| badgeTextColor | Color | (iOS 26+) The color of the number or text of the badge. Without it, white. |
| toggle | boolean | Whether the button is a toggle: every press flips |
| selected | boolean | Whether the button is drawn as switched on: on iOS 26 filled with its color, with the icon or text on it. For a toggle this is the starting state, and |
| menu | OptionsTopBarButtonMenu | The menu of the button. It opens on a press, or on a long press with |
| menuOnLongPress | boolean | Whether a press does the button's own action (a press event, a toggle) and the menu opens on a long press. Without it the menu opens on a press. |
| customization | 'fixed' | 'movable' | 'optional' | (iOS 16+) For a center button, when |
| shownByDefault | boolean | (iOS 16+) Whether an |
| pinned | boolean | Whether a right button stays out of the overflow menu. On iOS 16+ it goes to the pinned group at the trailing edge, behind the overflow button, in a capsule of its own (several pinned buttons share it); when space runs out iOS hides the title first. On Android it stays in the bar while other right buttons move to the overflow when they don't fit. No effect on left and center buttons. |
| priority | 'high' | 'standard' | 'low' | Which buttons move to the overflow menu last: |
| vertical | boolean | (iOS 27.1+) Whether the button may move to the vertical bar of iPhone Duo: |
OptionsTopBarButtonMenu
A menu of the top bar: the menu of a button, the overflow menu, the menu of the title. A list of items sent with mergeOptions replaces the earlier list as a whole, and items: [] removes the menu; title and singleSelection merge field by field (iOS). What the user picks in a singleSelection menu stays with the screen, through it showing again, a mergeOptions that sends the same items again and setDefaultOptions; a mergeOptions into the screen that changes the checks of that menu's level, or takes the item away, replaces it. A merge into the stack or the tabs around the screen doesn't.
interface OptionsTopBarButtonMenu
| Member | Type | Description |
|---|---|---|
| title | string | The title above the items. (iOS) Android doesn't show it. |
| singleSelection | boolean | Whether only one item of the top level can be checked at a time: picking an item moves the check mark to it. On iOS this is the system's single-selection menu; on Android the items are checkable. |
| items | OptionsTopBarButtonMenuElement[] | The items and submenus, in order. An empty list removes the menu. |
OptionsTopBarButtonMenuItem
An item of a menu. Picking it sends a button press with its id to the screen, and the screen runs the onPress of the item that has this id. Item ids and button ids of one screen must not repeat.
interface OptionsTopBarButtonMenuItem
| Member | Type | Description |
|---|---|---|
| id | string | The id of the item, sent as |
| title | string | The text of the item. Without it the item shows an empty string. |
| icon | ImageResource | The icon in front of the text. On iOS an SF Symbol or an image; on Android a drawable resource or an image source. On Android the icons show in the menu as soon as one item has one, tinted like the menu's other icons (the error color for a destructive item). An icon that fails to load leaves the item without one. |
| destructive | boolean | Whether the item is drawn as a destructive action: red on both platforms. |
| disabled | boolean | Whether the item is shown but can't be picked. |
| checked | boolean | Whether the item carries a check mark. On Android the item is checkable, also outside a |
| testID | string | The identifier tests find the item by: the accessibility identifier on iOS, the resource id and view tag of the item on Android. Where the system gives no way to set it, the item is found by its text. |
OptionsTopBarButtonSubmenu
A submenu: an item that opens a menu of its own, of any depth. Submenus carry no check mark.
interface OptionsTopBarButtonSubmenu
| Member | Type | Description |
|---|---|---|
| title | string | The text of the submenu item. Without it the item shows an empty string. |
| icon | ImageResource | The icon of the submenu item, as for a menu item. |
| singleSelection | boolean | Whether only one item of this submenu can be checked at a time. |
| itemsRequired | OptionsTopBarButtonMenuElement[] | The items and submenus, in order. |
| testID | string | The identifier tests find the submenu item by, as for a menu item. |
OptionsTopBarButtonMenuElement
An item or a submenu of a menu. An element with items is a submenu.
type OptionsTopBarButtonMenuElement =
OptionsTopBarButtonMenuItem | OptionsTopBarButtonSubmenu
| Member | Type | Description |
|---|---|---|
| id | string | The id of the item, sent as |
| title | string | The text of the item. Without it the item shows an empty string. |
| icon | ImageResource | The icon in front of the text. On iOS an SF Symbol or an image; on Android a drawable resource or an image source. On Android the icons show in the menu as soon as one item has one, tinted like the menu's other icons (the error color for a destructive item). An icon that fails to load leaves the item without one. |
| destructive | boolean | Whether the item is drawn as a destructive action: red on both platforms. |
| disabled | boolean | Whether the item is shown but can't be picked. |
| checked | boolean | Whether the item carries a check mark. On Android the item is checkable, also outside a |
| testID | string | The identifier tests find the item by: the accessibility identifier on iOS, the resource id and view tag of the item on Android. Where the system gives no way to set it, the item is found by its text. |
| singleSelection | boolean | Whether only one item of this submenu can be checked at a time. |
| itemsRequired | OptionsTopBarButtonMenuElement[] | The items and submenus, in order. |
SystemItemIcon
The system button a button shows. On iOS it is the system item of the same name, with the text of the user's language; a name the system doesn't know shows 'done'. On Android only 'close' is read: it draws the library's close icon when the button has no icon of its own, and every other name is ignored.
type SystemItemIcon =
| 'done'
| 'cancel'
| 'edit'
| 'save'
| 'add'
| 'flexibleSpace'
| 'fixedSpace'
| 'compose'
| 'reply'
| 'action'
| 'organize'
| 'bookmarks'
| 'search'
| 'refresh'
| 'stop'
| 'camera'
| 'trash'
| 'play'
| 'pause'
| 'rewind'
| 'fastForward'
| 'undo'
| 'redo'
| 'close'
IconInsets
The space around the image of an icon, in points.
interface IconInsets
| Member | Type | Description |
|---|---|---|
| top | number | The space above the image, in points. |
| left | number | The space left of the image, in points. |
| bottom | number | The space below the image, in points. |
| right | number | The space right of the image, in points. |
IconBackgroundOptions
A filled shape behind the icon of a button or of the back button. It takes effect only when color is set; without a color the other fields are ignored.
On iOS the icon is drawn onto the shape and the button becomes a button of its own (the back button keeps its history menu), without the glass capsule (glass design, iOS 26+) by default. On Android the icon sits on the shape, mirrored in a right-to-left layout. Layers merge differently: on iOS an object merges field by field like any other, on Android an iconBackground that has a color replaces the earlier one as a whole.
interface IconBackgroundOptions
| Member | Type | Description |
|---|---|---|
| color | Color | The color of the shape. Without it the whole |
| disabledColor | Color | The color of the shape while the button is disabled. Without it the shape keeps |
| cornerRadius | number | The radius of the corners of the shape, in points (iOS) or dp (Android). |
| width | number | The width of the shape, in points or dp. By default the width of the icon; on Android never less than that. |
| height | number | The height of the shape, in points or dp. By default the height of the icon; on Android never less than that. |
ButtonPressEvent
A press of a button or of an item of its menu, with the navigation of the screen whose button it is.
type ButtonPressEvent = ButtonPressedEvent & { navigation: ScreenNavigation }
| Member | Type | Description |
|---|---|---|
| selected | boolean | For a button with |
| buttonIdRequired | string | The id of the button or of the menu item. The back button has the id set in |
| screenRequired | ScreenRef | |
| navigationRequired | ScreenNavigation |
ButtonPressedEvent
type ButtonPressedEvent = NavigationEvents['buttonPressed']
| Member | Type | Description |
|---|---|---|
| selected | boolean | For a button with |
| buttonIdRequired | string | The id of the button or of the menu item. The back button has the id set in |
| screenRequired | ScreenRef |