Skip to content

Select

Select triggers a modal bottom picker sheet for selecting items from an options list.

Usage

SelectExample.tsx
import { useState } from 'react';
import { Select } from '@masumdev/rn-ui';
export function SelectExample() {
const [selected, setSelected] = useState('expo');
return (
<Select
title="Choose Framework"
placeholder="Select mobile framework..."
value={selected}
onValueChange={setSelected}
options={[
{ value: 'expo', label: 'Expo React Native', description: 'Recommended managed workflow.' },
{ value: 'cli', label: 'React Native CLI', description: 'Bare React Native setup.' },
{ value: 'web', label: 'React Native Web', description: 'Cross-platform web target.', disabled: true },
]}
/>
);
}

Props API

PropTypeDefaultDescription
optionsSelectOption[]Array of option objects with value, label, description, and optional disabled state.
valuestringCurrently selected option value.
defaultValuestringInitial default selected value.
placeholderstring'Select option'Placeholder string when no option is selected.
titlestring'Select'Modal sheet header title string.
onValueChange(value: string) => voidCallback when an option is selected.
chevronIconRenderIconCustom trailing dropdown arrow icon renderer.
checkIconRenderIconCustom checkmark icon for active item.