import {IBaseForm} from '../baseForm' import {paramsInterfaceValidKey} from '../../../script/index' export interface CascaderInterface extends IBaseForm { options: Function popperClass?: string showAllLevels?: boolean clearable?: boolean collapseTags?: boolean optionsValue?: string optionsLabel?: string emitPath?: boolean checkStrictly?: boolean lazy?: boolean lazyLoad?: Function multiple?: boolean visibleChanges?: Function filters?: Function | boolean filterOptions?: Function | boolean filterMethod?: Function filterInput?: Function | boolean teleported?: boolean leaf?: string keyUp?: number | Function } export interface OptionsConfigInterface { value: string label: string emitPath?: boolean checkStrictly?: boolean lazy?: boolean lazyLoad?: Function multiple?: boolean } export class CascaderConfig implements CascaderInterface { type = 'infoCascader' model = '' label = '' optionsValue = 'id' optionsLabel = 'name' size = '' showAllLevels = false clearable = true emitPath = false checkStrictly = false lazy = false multiple = false constructor (params: CascaderInterface) { paramsInterfaceValidKey(this, params) } options = () => [] visibleChanges = (): void => { } lazyLoad = (): void => { } disabled = () => false placeholder = (): string => 'pleaseSelect' methods = (): void => { } }