chore: formate auto-complete code
parent
16224a1d47
commit
2b6ef8e10f
|
@ -26,7 +26,7 @@ describe('AutoComplete with Custom Input Element Render', () => {
|
||||||
input.element.value = '123';
|
input.element.value = '123';
|
||||||
input.trigger('input');
|
input.trigger('input');
|
||||||
Vue.nextTick(() => {
|
Vue.nextTick(() => {
|
||||||
expect($$('.ant-select-dropdown-menu-item').length).toBe(3);
|
expect($$('.ant-select-item-option').length).toBe(3);
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -20,8 +20,6 @@ const AutoCompleteProps = {
|
||||||
dropdownMenuStyle: PropTypes.style,
|
dropdownMenuStyle: PropTypes.style,
|
||||||
optionLabelProp: PropTypes.string,
|
optionLabelProp: PropTypes.string,
|
||||||
dropdownMatchSelectWidth: PropTypes.looseBool,
|
dropdownMatchSelectWidth: PropTypes.looseBool,
|
||||||
// onChange?: (value: SelectValue) => void;
|
|
||||||
// onSelect?: (value: SelectValue, option: Object) => any;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const AutoComplete = defineComponent({
|
const AutoComplete = defineComponent({
|
||||||
|
@ -86,7 +84,7 @@ const AutoComplete = defineComponent({
|
||||||
render() {
|
render() {
|
||||||
const { size, prefixCls: customizePrefixCls, dataSource } = this;
|
const { size, prefixCls: customizePrefixCls, dataSource } = this;
|
||||||
let optionChildren: any;
|
let optionChildren: any;
|
||||||
const getPrefixCls = this.configProvider.getPrefixCls;
|
const { getPrefixCls } = this.configProvider;
|
||||||
const prefixCls = getPrefixCls('select', customizePrefixCls);
|
const prefixCls = getPrefixCls('select', customizePrefixCls);
|
||||||
const { class: className } = this.$attrs as any;
|
const { class: className } = this.$attrs as any;
|
||||||
const cls = {
|
const cls = {
|
||||||
|
|
Loading…
Reference in New Issue