eo-auto-complete
<eo-auto-complete>
构件 eo-auto-complete
Examples
Basic
caption
分组
filterByCaption
disabled
events
With Form
Properties
Name | Description | Type | Default | Required |
---|---|---|---|---|
name | 字段名称 | string | ||
placeholder | 占位说明 | string | ||
label | 字段文本 | string | ||
inputStyle | 输入框样式 | React.CSSProperties | ||
disabled | 是否禁用 | boolean | ||
required | 是否必填 | boolean | ||
value | string | |||
options | 选项列表 | string[] | OptionType[] | ✅ | |
filterByCaption | 搜索时是否根据caption过滤options | boolean | ||
validator | 表单项校验方法 | ((value: any) => MessageBody) | ||
pattern | 正则校验规则 | string | ||
message | 校验文本信息 | Record<string, string> |
Events
Name | Description | Event Detail |
---|---|---|
change | 值改变事件 | string |
Type references
Option
Name | Type | Required | Description |
---|---|---|---|
label | string | ✅ | |
caption | string | ||
value | any | ✅ |
OptionGroup
Name | Type | Required | Description |
---|---|---|---|
label | string | ✅ | |
options | Option[] | ✅ |
OptionType
Option | OptionGroup