From 994b4aa2a3818acbdc583996e850ca6c16b2a823 Mon Sep 17 00:00:00 2001 From: 07akioni <07akioni2@gmail.com> Date: Tue, 8 Dec 2020 13:47:01 +0800 Subject: [PATCH] feat(auto-complete): disabled --- .../components/auto-complete/enUS/index.demo-entry.md | 1 + .../components/auto-complete/zhCN/index.demo-entry.md | 1 + src/auto-complete/src/AutoComplete.vue | 5 +++++ 3 files changed, 7 insertions(+) diff --git a/demo/documentation/components/auto-complete/enUS/index.demo-entry.md b/demo/documentation/components/auto-complete/enUS/index.demo-entry.md index 9ca81c669..284271b4a 100644 --- a/demo/documentation/components/auto-complete/enUS/index.demo-entry.md +++ b/demo/documentation/components/auto-complete/enUS/index.demo-entry.md @@ -14,6 +14,7 @@ after-select |-|-|-|-| |blur-after-select|`boolean`|`false`|| |clear-after-select|`boolean`|`false`|| +|disabled|`boolean`|`false`|| |options|`Array`|`[]`|| |placeholder|`string`|`'Please Input'`|| |size|`'small' \| 'medium' \| 'large'`|`'medium'`|| diff --git a/demo/documentation/components/auto-complete/zhCN/index.demo-entry.md b/demo/documentation/components/auto-complete/zhCN/index.demo-entry.md index 299facf6a..358c7dc23 100644 --- a/demo/documentation/components/auto-complete/zhCN/index.demo-entry.md +++ b/demo/documentation/components/auto-complete/zhCN/index.demo-entry.md @@ -14,6 +14,7 @@ after-select |-|-|-|-| |blur-after-select|`boolean`|`false`|| |clear-after-select|`boolean`|`false`|| +|disabled|`boolean`|`false`|| |options|`Array`|`[]`|| |placeholder|`string`|`'请输入'`|| |size|`'small' \| 'medium' \| 'large'`|`'medium'`|| diff --git a/src/auto-complete/src/AutoComplete.vue b/src/auto-complete/src/AutoComplete.vue index 964965ccb..8f5343dc0 100644 --- a/src/auto-complete/src/AutoComplete.vue +++ b/src/auto-complete/src/AutoComplete.vue @@ -23,6 +23,7 @@ :value="value" :placeholder="placeholder" :size="mergedSize" + :disabled="disabled" @focus="canBeActivated = true" @input="handleInput" @blur="handleBlur" @@ -110,6 +111,10 @@ export default { type: Boolean, default: undefined }, + disabled: { + type: Boolean, + default: false + }, placeholder: { type: String, default: undefined