ttolbel UI

Component

Toolbar

A frosted bar of evenly-spaced icon-and-label actions, with an optional destructive style for the dangerous one.

The primitive

toolbar.tsx
<NativeToolbar
  items={[
    { key: "share", icon: <Share size={20} />, label: "Share", onPress: () => {} },
    { key: "star", icon: <Star size={20} />, label: "Save", onPress: () => {} },
    { key: "delete", icon: <Trash size={20} />, label: "Delete", onPress: () => {}, style: "destructive" },
  ]}
/>

Example

Anchored beneath a transaction's detail view, its actions specific to whatever that single transaction allows.

toolbar-example.tsx
<ReceiptDetail />
<NativeToolbar items={toolbarItems} />

Capabilities

PropTypeDescription
itemsrequiredNativeToolbarItem[]
position"fixed" | "inline"Position fixed to bottom or inline
classNamestring