Skip to content

Commit

Permalink
feat(AutoComplete): AutoComplete增加deletable属性
Browse files Browse the repository at this point in the history
  • Loading branch information
btboys committed Oct 24, 2022
1 parent 4582c2e commit 163bce2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/components/auto-complete/autocomplete.vue
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
@keypress.enter="onEnter"
/>
<i v-if="loading" class="h-icon-loading"></i>
<i v-else-if="tempValue && !disabled" class="h-icon-close text-hover" @mousedown="clear"></i>
<i v-else-if="tempValue && (!disabled || deletable)" class="h-icon-close text-hover" @mousedown="clear"></i>
</template>
</div>
<div :class="groupCls">
Expand Down Expand Up @@ -124,6 +124,10 @@ export default {
showDropdownWhenNoResult: {
type: Boolean,
default: true
},
deletable: {
type: Boolean,
default: true
}
},
data() {
Expand Down

0 comments on commit 163bce2

Please sign in to comment.