Select

Picker that opens in a bottom sheet.

A picker that opens its options in a bottom sheet — the right choice when the list is long or the surrounding layout cannot grow.

Installation

Select ships with the library — no separate install.

import { Select } from 'panelui-native';

Usage

<Select
  value={fruit}
  onValueChange={setFruit}
  placeholder="Select a fruit"
  title="Favorite fruit"
>
  <Select.Item value="apple" label="Apple" />
  <Select.Item value="banana" label="Banana" />
</Select>

Composition

<Select>
  <Select.Item value="…" label="…" />
</Select>
  • Select.Item — One option. value identifies it, label is what is shown.

API Reference

Select.Item

PropTypeDefaultDescription
valuestring
labelstring

Select

PropTypeDefaultDescription
classNamestring
valuestring
onValueChange(value: string) => void
placeholderstring
titlestringSheet title shown above the options.
disabledboolean

Every part also accepts the underlying React Native props (ViewProps or TextProps) and a className for Tailwind utilities.

Notes

Use InlineSelect instead when the option list is short enough to expand in place.

On this page