CreatableSelectProps

Properties

Link copied to clipboard

Allow options to be created while the isLoading prop is true. Useful to prevent the "create new ..." option being displayed while async results are still being loaded.

Link copied to clipboard
abstract var autoFocus: Boolean?

Focus the control when it is mounted

Link copied to clipboard

Remove the currently focused option when the user presses backspace when Select isClearable or isMulti

Link copied to clipboard
abstract var blurInputOnSelect: Boolean?

Remove focus from the input when the user selects an option (handy for dismissing the keyboard on touch devices)

Link copied to clipboard
abstract var captureMenuScroll: Boolean?

When the user reaches the top/bottom of the menu, prevent scroll on the scroll-parent

Link copied to clipboard
abstract override var className: ClassName?

Sets a className attribute on the outer component

Link copied to clipboard
abstract var classNamePrefix: String?

If provided, all inner components will be given a prefixed className attribute.

Link copied to clipboard

If true, close the select menu when the user scrolls the document/body.

Link copied to clipboard
abstract var closeMenuOnSelect: Boolean?

Close the select menu when the user selects an option

Link copied to clipboard

This complex object includes all the compositional components that are used in react-select. If you wish to overwrite a component, pass in an object with the appropriate namespace.

Link copied to clipboard

Whether the value of the select, e.g. SingleValue, should be displayed in the control.

Link copied to clipboard

Sets the position of the createOption element in your options list. Defaults to 'last'

Link copied to clipboard
abstract var delimiter: String?

Delimiter used to join multiple values into a single HTML Input value

Link copied to clipboard
abstract var escapeClearsValue: Boolean?

Clear all values when the user presses escape AND the menu is closed

Link copied to clipboard

Custom method to filter whether an option should be displayed in the menu

Link copied to clipboard
abstract var form: String?

Sets the form attribute on the input

Link copied to clipboard
abstract var formatCreateLabel: (inputValue: String) -> ReactNode?

Gets the label for the "create new ..." option in the menu. Is given the current input value.

Link copied to clipboard
abstract var formatGroupLabel: (group: Group) -> ReactNode?

Formats group labels in the menu as React components

Link copied to clipboard
abstract var formatOptionLabel: (data: Option, formatOptionLabelMeta: FormatOptionLabelMeta<Option>) -> ReactNode?

Formats option labels in the menu and control as React components

Link copied to clipboard

Returns the data for the new option when it is created. Used to display the value, and is passed to onChange.

Link copied to clipboard

Resolves option data to a String to be displayed as the label by components

Link copied to clipboard

Resolves option data to a String to compare options and specify value attributes

Link copied to clipboard

Hide the selected option from the menu

Link copied to clipboard
abstract var id: String?

The id to set on the SelectContainer component.

Link copied to clipboard
abstract var inputId: String?

The id of the search input

Link copied to clipboard
abstract var inputValue: String?

The value of the search input

Link copied to clipboard
abstract var instanceId: Key?

Define an id prefix for the select components e.g. {your-id}-value

Link copied to clipboard
abstract var isClearable: Boolean?

Is the select value clearable

Link copied to clipboard
abstract var isDisabled: Boolean?

Is the select disabled

Link copied to clipboard
abstract var isLoading: Boolean?

Is the select in a state of loading (async)

Link copied to clipboard
abstract var isMulti: Boolean?

Support multiple selected options

Link copied to clipboard
abstract var isOptionDisabled: (option: Option, Options<Option>) -> Boolean?

Override the built-in logic to detect whether an option is disabled

Link copied to clipboard
abstract var isOptionSelected: (option: Option, Options<Option>) -> Boolean?

Override the built-in logic to detect whether an option is selected

Link copied to clipboard
abstract var isRtl: Boolean?

Is the select direction right-to-left

Link copied to clipboard
abstract var isSearchable: Boolean?

Whether to enable search functionality

Link copied to clipboard
abstract var isValidNewOption: (inputValue: String, Options<Option>, options: OptionsOrGroups<Option, Group>, accessors: Accessors<Option>) -> Boolean?

Determines whether the "create new ..." option should be displayed based on the current input value, select value and options array.

Link copied to clipboard
abstract var key: Key?
Link copied to clipboard

Async: Text to display when loading options

Link copied to clipboard
abstract var maxMenuHeight: Length?

Maximum height of the menu before scrolling

Link copied to clipboard
abstract var menuIsOpen: Boolean?

Whether the menu is open

Link copied to clipboard

Default placement of the menu in relation to the control. 'auto' will flip when there isn't enough space below the control.

Link copied to clipboard

Whether the menu should use a portal, and where it should attach

Link copied to clipboard
abstract var menuPosition: MenuPosition?

The CSS position value of the menu, when "fixed" extra layout management is required

Link copied to clipboard

Whether to block scroll events when the menu is open

Link copied to clipboard

Whether the menu should be scrolled into view when it opens

Link copied to clipboard
abstract var minMenuHeight: Length?

Minimum height of the menu before flipping

Link copied to clipboard
abstract var name: String?

Name of the HTML Input (optional - without this, no input will be rendered)

Link copied to clipboard

Text to display when there are no options

Link copied to clipboard

Handle blur events on the control

Link copied to clipboard
abstract var onChange: ChangeHandler<Option>?

Handle change events on the select

Link copied to clipboard

If provided, this will be called with the input value when a new option is created, and onChange will not be called. Use this when you need more control over what happens when new options are created.

Link copied to clipboard

Handle focus events on the control

Link copied to clipboard

Handle change events on the input

Link copied to clipboard

Handle key down events on the select

Link copied to clipboard
abstract var onMenuClose: () -> Unit?

Handle the menu closing

Link copied to clipboard
abstract var onMenuOpen: () -> Unit?

Handle the menu opening

Link copied to clipboard
abstract var onMenuScrollToBottom: (event: UIEvent) -> Unit?

Fired when the user scrolls to the bottom of the menu

Link copied to clipboard
abstract var onMenuScrollToTop: (event: UIEvent) -> Unit?

Fired when the user scrolls to the top of the menu

Link copied to clipboard
abstract var openMenuOnClick: Boolean?

Allows control of whether the menu is opened when the Select is clicked

Link copied to clipboard
abstract var openMenuOnFocus: Boolean?

Allows control of whether the menu is opened when the Select is focused

Link copied to clipboard

Array of options that populate the select menu

Link copied to clipboard
abstract var pageSize: Int?

Number of options to jump in menu when page{up|down} keys are used

Link copied to clipboard
abstract var placeholder: ReactNode?

Placeholder for the select value

Link copied to clipboard

Status to relay to screen readers

Link copied to clipboard
abstract var styles: StylesConfig<Option, Group>?

Style modifier methods

Link copied to clipboard
abstract var tabIndex: Int?

Sets the tabIndex attribute on the input

Link copied to clipboard
abstract var tabSelectsValue: Boolean?

Select the currently focused option when the user presses tab

Link copied to clipboard
abstract var theme: ThemeConfig?

Theme modifier method

Link copied to clipboard
abstract var value: PropsValue<Option>?

The value of the select reflected by the selected option

Functions

Link copied to clipboard
open inline operator fun Props?.unaryPlus()