Import
Basic Usage
Props
The
input value. Providing an empty string will select no options. Set to an empty string '' if you don’t want any of the available options to be selected.The default value. Use when the component is not controlled.
The variant to use.
If
true, value must be an array and the menu will support multiple selections.If
true, the component uses a native select element.If
true, the width of the popover will automatically be set according to the items inside the menu, otherwise it will be at least the width of the select input.If
true, a value is displayed even if no items are selected. When using this prop, make sure the label doesn’t overlap with the empty displayed value.If
true, the component is initially open. Use when the component open state is not controlled (i.e. the open prop is not defined). You can only use it when the native prop is false (default).If
true, the component is shown. You can only use it when the native prop is false (default).See OutlinedInput#label.
The ID of an element that acts as an additional label. The Select will be labelled by the additional label and the selected value.
Callback fired when a menu item is selected. You can pull out the new value by accessing
event.target.value (any).Callback fired when the component requests to be closed. Use it in either controlled (see the
open prop), or uncontrolled mode (to detect when the Select collapses).Callback fired when the component requests to be opened. Use it in either controlled (see the
open prop), or uncontrolled mode (to detect when the Select expands).Render the selected value. You can only use it when the
native prop is false (default).The icon that displays the arrow. Defaults to
ArrowDropDownIcon.Props applied to the Menu element.
The system prop that allows defining system overrides as well as additional CSS styles.
The option elements to populate the select with. Can be some
MenuItem when native is false and option when native is true. The MenuItem elements must be direct descendants when native is false.API Reference
- Select API
- Inherits OutlinedInput API