Mobile components
React Native components that draw iOS patterns on iPhone and Material 3 on Android, from one codebase.
npx expo install plankui-mobile react-native-safe-area-context expo-hapticsFoundations
- PlankProvider: Wraps your app once. Picks iOS or Material patterns, light or dark, and applies a PlankUI theme, accent, style and corner radius to every component.
Navigation
- NavBar: The bar at the top of a screen, in seven styles: standard, center, large, medium, search, transparent and modal. Large titles fold into the bar as you scroll.
- TabBar: Bottom tabs for an app's three to five main sections, with optional badges.
- Floating TabBar: TabBar with floating on: the bar lifts off the bottom edge and content scrolls under it, with an optional round action beside it.
- SearchField: A search input. Use it on its own, or pass search to a NavBar with variant="search".
Inputs
- Button: Four weights for a screen's actions, from the filled main action to a plain text button, with loading and danger states.
- TextField: A labelled text input with a hint and an error message. The label always stays visible.
- Checkbox: A yes-or-no choice with a label and an optional description. The whole row is the tap target.
- RadioGroup: One choice from a short list, each option with an optional description.
- Switch: An on-off toggle that takes effect straight away, usually at the end of a list row.
- Slider: Picks a value in a range by dragging. Arrow keys and screen-reader swipes adjust it too.
- Select: A field that opens a sheet of options and closes on a pick. It matches TextField, so a form keeps one look.
- Rating: Stars to rate something, or to show an average. Tap the chosen star again to clear it.
- Stepper: Minus and plus buttons for small counts, such as guests or quantity.
- SegmentedControl: Two to five equal options in one row, such as Day, Week and Month.
- Chip: Compact choices for filters and tags. Put several in a ChipRow, which scrolls sideways.
Lists and layout
- Screen: The frame of every page: safe areas, scrolling, a header bar, a footer and pull to refresh.
- ListSection and ListItem: Grouped rows for settings, menus and records, with icons, values, controls and chevrons.
- Carousel: Cards that snap one page at a time, showing the edge of the next, with page dots under them. PageControl is the dots on their own.
- Timeline: Steps down a line: order tracking, a history or an onboarding path. Done steps carry a check, the current one a ring.
- Card: A surface that groups related content. With onPress, the whole card is one button.
- Divider: A hairline between groups of content, across or upright.
Overlays
- Sheet: A panel that slides up from the bottom for a short task. Swipe down, tap outside or press back to close.
- Dialog: Asks the person to confirm before something they can't undo. Up to three buttons.
- Toast: A short message after an action, with an optional Undo. Wrap the app in ToastProvider and call useToast().
Feedback
- Banner: A message that stays on the screen until it is dealt with, with an optional action and close button.
- ProgressBar and Spinner: Show how far a task has got, or that something is loading.
- EmptyState: What a screen shows when there is nothing yet: what it is for and the one step to fill it.
Display
- Text: Text on the platform's own type scale, from largeTitle to caption. Font scaling stays on.
- Avatar: A person's photo, or their initials on a colour picked from their name so each person keeps one colour.
- AvatarGroup: Overlapping avatars with a +N count for the rest, for teams, attendees and shared items.
- Stat: One number on a card with its label and its change, for dashboards, health and money screens.
- Badge: A small status pill such as New, Paid or Failed.
- Glyph: The eight small icons the components draw themselves, so the library needs no icon package.