Skip to content

API reference ​

<ActionSheetPicker> ​

Data and value ​

PropTypeDefault
itemsT[]—Options (raw objects are fine with schema)
valueV | null · V[] with multiple—Controlled value
onChange(value, item) · (values, items) with multiple—
schema{ label, value, disabled, selectable, testID }'label', 'value', …Property names or functions
hierarchy{ type: 'nested', childrenKey? } · { type: 'flat', parentKey? }—Grouped options
selectableParentsbooleanfalseAllow picking groups
selectedItemsT[]—Labels for values not in items yet
multiplebooleanfalseMulti-select
min / maxnumber—Multi-select limits
onLimitReached(limit: 'min' | 'max') => void—
confirmMode'done' | 'instant''done'Multi-select: apply on Done, or on every tap
closeOnSelectbooleantrueSingle select
allowDeselectbooleanfalseSingle select: tap the selected row again to clear it

Search and paging ​

PropTypeDefault
searchableboolean | SearchConfigfalseSearch
pagination{ hasMore, loadingMore, onEndReached }—Infinite lists
loadingbooleanfalseSpinner in the trigger and empty list

Field ​

PropTypeDefault
labelstring—Also the sheet title
placeholderstringstrings.placeholder
titlestringlabelSheet title
requiredbooleanfalseShows * (no validation)
errorstring—Message under the field, red border
invalidbooleanfalseRed border only
disabledbooleanfalse
multipleDisplay'labels' | 'count' | 'chips''labels'
formatSelected(rows) => string—Custom trigger text
showParentLabelbooleanfalse"Group › Option"
parentLabelSeparatorstring' › '

Sheet ​

PropTypeDefault
presentation'sheet' | 'fullscreen''sheet'
swipeToClosebooleantrueNot available in fullscreen
closeOnBackdropPressbooleantrue
bottomInset / topInsetnumbersafe-area insets
autoScrollToSelectedbooleantrue
stickyHeadersbooleanfalseGrouped options
fixedRowHeightbooleantruefalse for multi-line labels
open / onOpenChangeboolean / (open) => void—Controlled open state
onOpen / onClose / onBlur / onDismiss() => void—onBlur fires on every close; onDismiss after the animation

Look and customization ​

PropType
colorScheme'auto' | 'light' | 'dark'
tokensDeepPartial<PickerTokens>
stylesPartial<PickerStyles>
stringsPartial<PickerStrings>
iconsPartial<{ chevron, check, close, search }>
SheetComponentType<SheetProps>
renderTrigger / renderItem / renderEmptyrender functions
listProps / modalProps / searchInputPropspassed to FlatList / Modal / TextInput
testID / itemTestIDstring / string | (row) => string

Ref (ActionSheetPickerHandle) ​

open(), close(), focus() (same as open), clear().

<PickerProvider> ​

App-wide defaults: colorScheme, tokens, darkTokens (applied in dark mode only), strings, icons, styles, Sheet. Props on a picker override the provider, and nested providers merge.

<RHFActionSheetPicker> ​

From actionsheet-picker/react-hook-form. Takes all picker props except value, onBlur and error (the form provides them, and onChange becomes optional), plus:

PropType
controlControlfrom useForm
namefield pathchecked against your form's fields
rulesRegisterOptionsrequired also shows the * marker
defaultValuefield valueprefer useForm({ defaultValues })
shouldUnregisterboolean
onChange(value, item) · (values, items)optional; runs after the form updates

useActionSheetPicker(options) ​

Takes the same data, value, search and paging options as the component, and returns:

Field
isOpen, open(), close(), toggle()Open state
query, setQuery(text), searchable, searchMode, searchingSearch
rows, allRowsFiltered and all rows
selectedKeys, isSelected(key), selectedRows, hasValueSelection
selectRow(row), removeValue(value), clear()Changes
commit(), requiresCommit, isDirty, draftCountMulti-select draft
resolveRow(key)Any row the picker has seen
onEndReached(), onMomentumScrollBegin()Wire to your list for pagination

Exports ​

ts
import {
  ActionSheetPicker,
  PickerProvider,
  useActionSheetPicker,
  ModalSheet,
  lightTokens,
  darkTokens,
  mergeTokens,
  defaultStrings,
  // core helpers
  buildRows,
  createAccessors,
  filterRows,
  keyOf,
} from 'actionsheet-picker';

import { RHFActionSheetPicker } from 'actionsheet-picker/react-hook-form';

Types include ActionSheetPickerProps, SingleActionSheetPickerProps, MultiActionSheetPickerProps, ActionSheetPickerHandle, PickerTokens, PickerStrings, PickerStyles, PickerIcons, SheetProps, Row, Hierarchy, ItemSchema and PickerState.

Released under the MIT License.