Unstyled Select
The Select components let you create lists of options for users to choose from.
useOption API
Import
import useOption from '@mui/base/useOption';
// or
import { useOption } from '@mui/base';
Parameters
Name | Type | Description |
---|---|---|
disabled* | boolean | |
value* | Value | |
optionRef | React.Ref<HTMLElement> |
Return value
Name | Type | Description |
---|---|---|
getRootProps | <Other extends EventHandlers>(otherHandlers?: Other) => UseOptionRootSlotProps<Other> | |
highlighted | boolean | |
index | number | |
selected | boolean |
useSelect API
Import
import useSelect from '@mui/base/useSelect';
// or
import { useSelect } from '@mui/base';
Parameters
Name | Type | Description |
---|
Return value
Name | Type | Description |
---|