Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EuiComboBox prop docs added #3007

Merged
merged 17 commits into from
Mar 12, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions src/components/combo_box/combo_box.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,24 +54,57 @@ interface _EuiComboBoxProps<T>
Omit<HTMLAttributes<HTMLDivElement>, 'onChange'>,
DrillProps<T> {
'data-test-subj'?: string;
/**
* Defines wether manner of search is asynchronous or not
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
async: boolean;
className?: string;
/**
* when true creates a shorter height box
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
compressed: boolean;
/**
* when true occupies the entire width available
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
fullWidth: boolean;
id?: string;
inputRef?: RefCallback<HTMLInputElement>;
/**
* Shows a button that quickly clears any input
*/
isClearable: boolean;
/**
* Disables the combo box
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
isDisabled?: boolean;
isInvalid?: boolean;
/**
* Adds/swaps for loading spinner & disables
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
isLoading?: boolean;
/**
* hides the suggestions list
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
noSuggestions?: boolean;
onBlur?: FocusEventHandler<HTMLDivElement>;
/**
* Called every time the query in the combo box is parsed.
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
onChange?: (options: Array<EuiComboBoxOptionOption<T>>) => void;
onFocus?: FocusEventHandler<HTMLDivElement>;
onKeyDown?: KeyboardEventHandler<HTMLDivElement>;
/**
* Called every time the text query in the search box is parsed.
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
onSearchChange?: (searchValue: string, hasMatchingOptions?: boolean) => void;
/**
* Sets the placeholder of the combo box
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
placeholder?: string;
rowHeight?: number;
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
/**
* when true allows the user to select a single option
anishagg17 marked this conversation as resolved.
Show resolved Hide resolved
*/
singleSelection: boolean | EuiComboBoxSingleSelectionShape;
}

Expand Down