Слияние кода завершено, страница обновится автоматически
category | type | title |
---|---|---|
Components |
Data Entry |
Select |
Select component to select value from options.
<select>
element.<Select>
<Option value="lucy">lucy</Option>
</Select>
Property | Description | Type | Default |
---|---|---|---|
allowClear | Show clear button. | boolean | false |
autoFocus | Get focus by default | boolean | false |
defaultActiveFirstOption | Whether active first option by default | boolean | true |
defaultValue | Initial selected option. | string|number|string[]|number[] | - |
disabled | Whether disabled select | boolean | false |
dropdownClassName | className of dropdown menu | string | - |
dropdownMatchSelectWidth | Whether dropdown's with is same with select. | boolean | true |
dropdownStyle | style of dropdown menu | object | - |
filterOption | If true, filter options by input, if function, filter options against it. The function will receive two arguments, inputValue and option , if the function returns true , the option will be included in the filtered set; Otherwise, it will be excluded. |
boolean or function(inputValue, option) | true |
firstActiveValue | Value of action option by default | string|string[] | - |
getPopupContainer | Parent Node which the selector should be rendered to. Default to body . When position issues happen, try to modify it into scrollable content and position it relative. Example
|
function(triggerNode) | () => document.body |
labelInValue | whether to embed label in value, turn the format of value from string to {key: string, label: ReactNode}
|
boolean | false |
maxTagCount | Max tag count to show | number | - |
maxTagPlaceholder | Placeholder for not showing tags | ReactNode/function(omittedValues) | - |
mode | Set mode of Select (Support after 2.9) | 'default' | 'multiple' | 'tags' | 'combobox' | 'default' |
notFoundContent | Specify content to show when no result matches.. | string | 'Not Found' |
optionFilterProp | Which prop value of option will be used for filter if filterOption is true | string | value |
optionLabelProp | Which prop value of option will render as content of select. | string |
value for combobox , children for other modes |
placeholder | Placeholder of select | string|ReactNode | - |
showArrow | Whether to show the drop-down arrow | boolean | true |
size | Size of Select input. default large small
|
string | default |
tokenSeparators | Separator used to tokenize on tag/multiple mode | string[] | |
value | Current selected option. | string|number|string[]|number[] | - |
onBlur | Called when blur | function | - |
onChange | Called when select an option or input value change, or value of input is changed in combobox mode | function(value, option:Option/Array<Option>) | - |
onDeselect | Called when a option is deselected, the params are option's value (or key) . only called for multiple or tags, effective in multiple or tags mode only. | function(value, option:Option) | - |
onFocus | Called when focus | function | - |
onInputKeyDown | Called when key pressed | function | - |
onMouseEnter | Called when mouse enter | function | - |
onMouseLeave | Called when mouse leave | function | - |
onPopupScroll | Called when dropdown scrolls | function | - |
onPopupFocus | Called when dropdown focus | function | - |
onSearch | Callback function that is fired when input changed. | function(value: string) | |
onSelect | Called when a option is selected, the params are option's value (or key) and option instance. | function(value, option:Option) | - |
showCheckAll | Whether to show the check-all button of drop-down menu | boolean | true |
footer | drop-down menu footer content | string| ReactNode | - |
choiceRender | Only used tags , function returned value is Select show Content |
function(liDom, value) | - |
filter |
Select query input |
boolean | false |
filterValue |
Select query input value |
string | - |
onFilterChange |
Select query input change |
function(value) | - |
loading | data's loading | boolean|object ([More] | |
choiceRemove | Only used tags and multiple ,Quicky remove value |
boolean | function(value) | true | (value) => true |
onChoiceRemove | Only used tags and multiple ,Quicky remove value callback |
function(value) | - |
Name | Description |
---|---|
blur() | Remove focus |
focus() | Get focus |
Property | Description | Type | Default |
---|---|---|---|
disabled | Disable this option | boolean | false |
key | Same usage as value . If React request you to set this property, you can set it to value of option, and then omit value property. |
string | |
title |
title of Select after select this Option |
string | - |
value | default to filter with this property | string|number | - |
Property | Description | Type | Default |
---|---|---|---|
key | string | - | |
label | Group label | string|React.Element | - |
Вы можете оставить комментарий после Вход в систему
Неприемлемый контент может быть отображен здесь и не будет показан на странице. Вы можете проверить и изменить его с помощью соответствующей функции редактирования.
Если вы подтверждаете, что содержание не содержит непристойной лексики/перенаправления на рекламу/насилия/вульгарной порнографии/нарушений/пиратства/ложного/незначительного или незаконного контента, связанного с национальными законами и предписаниями, вы можете нажать «Отправить» для подачи апелляции, и мы обработаем ее как можно скорее.
Опубликовать ( 0 )