mirror of
https://github.com/grafana/grafana.git
synced 2024-11-28 03:34:15 -06:00
cc3fc18076
* added packages reference menu item. * removed the draft flag. * Updated docs by running script.
3.6 KiB
3.6 KiB
+++
-----------------------------------------------------------------------
Do not edit this file. It is automatically generated by API Documenter.
-----------------------------------------------------------------------
title = "Cascader" keywords = ["grafana","documentation","sdk","@grafana/ui"] type = "docs" +++
Cascader class
Signature
export declare class Cascader extends React.PureComponent<CascaderProps, CascaderState>
Import
import { Cascader } from '@grafana/ui';
Constructors
Constructor | Modifiers | Description |
---|---|---|
constructor(props) | Constructs a new instance of the Cascader class |
Properties
Property | Modifiers | Type | Description |
---|---|---|---|
flattenOptions | (options: CascaderOption[], optionPath?: CascaderOption[]) => SelectableValue<string[]>[] |
||
onBlur | () => void |
||
onBlurCascade | () => void |
||
onChange | (value: string[], selectedOptions: CascaderOption[]) => void |
||
onCreateOption | (value: string) => void |
||
onInputKeyDown | (e: React.KeyboardEvent<HTMLInputElement>) => void |
||
onSelect | (obj: SelectableValue<string[]>) => void |
Methods
Method | Modifiers | Description |
---|---|---|
render() | ||
setInitialValue(searchableOptions, initValue) |
constructor(props)
Constructs a new instance of the Cascader
class
Signature
constructor(props: CascaderProps);
Parameters
Parameter | Type | Description |
---|---|---|
props | CascaderProps |
flattenOptions property
Signature
flattenOptions: (options: CascaderOption[], optionPath?: CascaderOption[]) => SelectableValue<string[]>[];
onBlur property
Signature
onBlur: () => void;
onBlurCascade property
Signature
onBlurCascade: () => void;
onChange property
Signature
onChange: (value: string[], selectedOptions: CascaderOption[]) => void;
onCreateOption property
Signature
onCreateOption: (value: string) => void;
onInputKeyDown property
Signature
onInputKeyDown: (e: React.KeyboardEvent<HTMLInputElement>) => void;
onSelect property
Signature
onSelect: (obj: SelectableValue<string[]>) => void;
render method
Signature
render(): JSX.Element;
Returns:
JSX.Element
setInitialValue method
Signature
setInitialValue(searchableOptions: Array<SelectableValue<string[]>>, initValue?: string): {
rcValue: string[];
activeLabel: any;
};
Parameters
Parameter | Type | Description |
---|---|---|
searchableOptions | Array<SelectableValue<string[]>> |
|
initValue | string |
Returns:
{ rcValue: string[]; activeLabel: any; }