From 566bbb487329f5b3374f9b0ebf971b791c7526c2 Mon Sep 17 00:00:00 2001 From: tanjinzhou <415800467@qq.com> Date: Fri, 17 Jul 2020 17:36:58 +0800 Subject: [PATCH] refactor: autoFocus to autofocus --- antdv-demo | 2 +- components/auto-complete/index.jsx | 2 +- components/cascader/index.jsx | 4 ++-- components/checkbox/Checkbox.jsx | 2 +- components/date-picker/interface.js | 2 +- components/date-picker/wrapPicker.js | 4 ++-- components/input-number/index.jsx | 2 +- components/input/Input.jsx | 4 ++-- components/input/ResizableTextArea.jsx | 4 ++-- components/input/inputProps.js | 2 +- components/mentions/index.jsx | 2 +- components/modal/ActionButton.jsx | 4 ++-- components/modal/ConfirmDialog.jsx | 4 ++-- components/radio/Radio.jsx | 2 +- components/rate/index.jsx | 2 +- components/select/index.jsx | 2 +- components/switch/index.jsx | 2 +- components/time-picker/index.jsx | 2 +- components/tree-select/interface.jsx | 2 +- components/vc-checkbox/src/Checkbox.jsx | 8 ++++---- components/vc-input-number/src/index.js | 10 +++++----- components/vc-mentions/src/Mentions.jsx | 2 +- components/vc-mentions/src/mentionsProps.js | 2 +- components/vc-rate/src/Rate.jsx | 4 ++-- components/vc-select/PropTypes.js | 2 +- components/vc-select/Select.jsx | 2 +- components/vc-slider/src/Range.jsx | 2 +- components/vc-slider/src/Slider.jsx | 2 +- components/vc-slider/src/common/createSlider.jsx | 6 +++--- components/vc-switch/PropTypes.js | 2 +- components/vc-switch/Switch.jsx | 6 +++--- components/vc-time-picker/TimePicker.jsx | 8 ++++---- components/vc-tree-select/src/Select.jsx | 6 +++--- tests/shared/focusTest.js | 4 ++-- types/auto-complete.d.ts | 2 +- types/cascader.d.ts | 2 +- types/checkbox/checkbox.d.ts | 2 +- types/date-picker/common.d.ts | 2 +- types/input-number.d.ts | 2 +- types/mentions/mentions.d.ts | 2 +- types/radio/radio.d.ts | 2 +- types/rate.d.ts | 2 +- types/select/select.d.ts | 2 +- types/slider.d.ts | 2 +- types/switch.d.ts | 2 +- types/time-picker.d.ts | 2 +- 46 files changed, 70 insertions(+), 70 deletions(-) diff --git a/antdv-demo b/antdv-demo index fe4a4e29a..43f89955b 160000 --- a/antdv-demo +++ b/antdv-demo @@ -1 +1 @@ -Subproject commit fe4a4e29aebe7cc1a5bbacf43c2b34671b00c880 +Subproject commit 43f89955b59abfd51bdfd4d9dcbc3b4fc4c481b0 diff --git a/components/auto-complete/index.jsx b/components/auto-complete/index.jsx index 36306f91a..131ea470d 100644 --- a/components/auto-complete/index.jsx +++ b/components/auto-complete/index.jsx @@ -45,7 +45,7 @@ const AutoComplete = { showSearch: PropTypes.bool.def(false), transitionName: PropTypes.string.def('slide-up'), choiceTransitionName: PropTypes.string.def('zoom'), - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, backfill: PropTypes.bool, optionLabelProp: PropTypes.string.def('children'), filterOption: PropTypes.oneOfType([PropTypes.bool, PropTypes.func]).def(false), diff --git a/components/cascader/index.jsx b/components/cascader/index.jsx index 242b82aab..f948406a4 100644 --- a/components/cascader/index.jsx +++ b/components/cascader/index.jsx @@ -90,7 +90,7 @@ const CascaderProps = { getPopupContainer: PropTypes.func, popupVisible: PropTypes.bool, fieldNames: FieldNamesType, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, suffixIcon: PropTypes.any, }; @@ -167,7 +167,7 @@ const Cascader = { }, // mounted() { // this.$nextTick(() => { - // if (this.autoFocus && !this.showSearch && !this.disabled) { + // if (this.autofocus && !this.showSearch && !this.disabled) { // this.$refs.picker.focus(); // } // }); diff --git a/components/checkbox/Checkbox.jsx b/components/checkbox/Checkbox.jsx index 80403e2de..309bd9fff 100644 --- a/components/checkbox/Checkbox.jsx +++ b/components/checkbox/Checkbox.jsx @@ -22,7 +22,7 @@ export default { id: PropTypes.string, indeterminate: PropTypes.bool, type: PropTypes.string.def('checkbox'), - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, }, setup() { diff --git a/components/date-picker/interface.js b/components/date-picker/interface.js index 5f37fc592..03ba64c35 100644 --- a/components/date-picker/interface.js +++ b/components/date-picker/interface.js @@ -25,7 +25,7 @@ export const PickerProps = () => ({ pickerClass: PropTypes.string, pickerInputClass: PropTypes.string, timePicker: PropTypes.any, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, tagPrefixCls: PropTypes.string, tabindex: PropTypes.oneOfType([PropTypes.string, PropTypes.number]), align: PropTypes.object.def(() => ({})), diff --git a/components/date-picker/wrapPicker.js b/components/date-picker/wrapPicker.js index fad4e4fe5..784cd5938 100644 --- a/components/date-picker/wrapPicker.js +++ b/components/date-picker/wrapPicker.js @@ -59,10 +59,10 @@ export default function wrapPicker(Picker, props, pickerType) { }; }, mounted() { - const { autoFocus, disabled, value, defaultValue, valueFormat } = this; + const { autofocus, disabled, value, defaultValue, valueFormat } = this; checkValidate('DatePicker', defaultValue, 'defaultValue', valueFormat); checkValidate('DatePicker', value, 'value', valueFormat); - if (autoFocus && !disabled) { + if (autofocus && !disabled) { this.$nextTick(() => { this.focus(); }); diff --git a/components/input-number/index.jsx b/components/input-number/index.jsx index 69d838859..d463576c9 100644 --- a/components/input-number/index.jsx +++ b/components/input-number/index.jsx @@ -24,7 +24,7 @@ export const InputNumberProps = { name: PropTypes.string, id: PropTypes.string, precision: PropTypes.number, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, }; const InputNumber = { diff --git a/components/input/Input.jsx b/components/input/Input.jsx index abe2e0256..f7e393225 100644 --- a/components/input/Input.jsx +++ b/components/input/Input.jsx @@ -157,8 +157,8 @@ export default { onInput: handleChange, onChange: noop, }; - if (!inputProps.autoFocus) { - delete inputProps.autoFocus; + if (!inputProps.autofocus) { + delete inputProps.autofocus; } return ; }, diff --git a/components/input/ResizableTextArea.jsx b/components/input/ResizableTextArea.jsx index a1634a1eb..ee945ad9c 100644 --- a/components/input/ResizableTextArea.jsx +++ b/components/input/ResizableTextArea.jsx @@ -142,8 +142,8 @@ const ResizableTextArea = { // }, // ], }; - if (!textareaProps.autoFocus) { - delete textareaProps.autoFocus; + if (!textareaProps.autofocus) { + delete textareaProps.autofocus; } return ( diff --git a/components/input/inputProps.js b/components/input/inputProps.js index ceed5ed3d..15d20142c 100644 --- a/components/input/inputProps.js +++ b/components/input/inputProps.js @@ -24,7 +24,7 @@ export default { prefix: PropTypes.any, suffix: PropTypes.any, // spellCheck: Boolean, - autoFocus: Boolean, + autofocus: Boolean, allowClear: Boolean, lazy: { default: true, diff --git a/components/mentions/index.jsx b/components/mentions/index.jsx index bfc4828e9..add84f572 100644 --- a/components/mentions/index.jsx +++ b/components/mentions/index.jsx @@ -66,7 +66,7 @@ const Mentions = { }, mounted() { this.$nextTick(() => { - if (this.autoFocus) { + if (this.autofocus) { this.focus(); } }); diff --git a/components/modal/ActionButton.jsx b/components/modal/ActionButton.jsx index 5af45f703..1df53a27b 100644 --- a/components/modal/ActionButton.jsx +++ b/components/modal/ActionButton.jsx @@ -8,7 +8,7 @@ const ActionButtonProps = { type: ButtonType, actionFn: PropTypes.func, closeModal: PropTypes.func, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, buttonProps: PropTypes.object, }; @@ -21,7 +21,7 @@ export default { }; }, mounted() { - if (this.autoFocus) { + if (this.autofocus) { this.timeoutId = setTimeout(() => this.$el.focus()); } }, diff --git a/components/modal/ConfirmDialog.jsx b/components/modal/ConfirmDialog.jsx index 38007f544..29d3f73af 100644 --- a/components/modal/ConfirmDialog.jsx +++ b/components/modal/ConfirmDialog.jsx @@ -48,7 +48,7 @@ const ConfirmDialog = (_, { attrs }) => { {cancelText} @@ -94,7 +94,7 @@ const ConfirmDialog = (_, { attrs }) => { type={okType} actionFn={onOk} closeModal={close} - autoFocus={autoFocusButton === 'ok'} + autofocus={autoFocusButton === 'ok'} buttonProps={okButtonProps} > {okText} diff --git a/components/radio/Radio.jsx b/components/radio/Radio.jsx index 72d408bb3..844c5a314 100644 --- a/components/radio/Radio.jsx +++ b/components/radio/Radio.jsx @@ -19,7 +19,7 @@ export default { value: PropTypes.any, name: String, id: String, - autoFocus: Boolean, + autofocus: Boolean, type: PropTypes.string.def('radio'), onChange: PropTypes.func, }, diff --git a/components/rate/index.jsx b/components/rate/index.jsx index c10fc3e42..75a2a8409 100644 --- a/components/rate/index.jsx +++ b/components/rate/index.jsx @@ -17,7 +17,7 @@ export const RateProps = { tooltips: PropTypes.arrayOf(PropTypes.string), disabled: PropTypes.bool, character: PropTypes.any, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, }; const Rate = { diff --git a/components/select/index.jsx b/components/select/index.jsx index 33c0c4955..42448f2b6 100644 --- a/components/select/index.jsx +++ b/components/select/index.jsx @@ -37,7 +37,7 @@ const AbstractSelectProps = () => ({ dropdownMatchSelectWidth: PropTypes.bool, // onSearch: (value: string) => any, filterOption: PropTypes.oneOfType([PropTypes.bool, PropTypes.func]), - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, backfill: PropTypes.bool, showArrow: PropTypes.bool, getPopupContainer: PropTypes.func, diff --git a/components/switch/index.jsx b/components/switch/index.jsx index 19d093477..d69917bbd 100644 --- a/components/switch/index.jsx +++ b/components/switch/index.jsx @@ -21,7 +21,7 @@ const Switch = { tabindex: PropTypes.oneOfType([PropTypes.string, PropTypes.number]), checked: PropTypes.bool, defaultChecked: PropTypes.bool, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, loading: PropTypes.bool, }, setup() { diff --git a/components/time-picker/index.jsx b/components/time-picker/index.jsx index 0c3436fc9..2248cd344 100644 --- a/components/time-picker/index.jsx +++ b/components/time-picker/index.jsx @@ -64,7 +64,7 @@ export const TimePickerProps = () => ({ align: PropTypes.object, placement: PropTypes.any, transitionName: PropTypes.string, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, addon: PropTypes.any, clearIcon: PropTypes.any, locale: PropTypes.object, diff --git a/components/tree-select/interface.jsx b/components/tree-select/interface.jsx index f506a721d..29c314a87 100644 --- a/components/tree-select/interface.jsx +++ b/components/tree-select/interface.jsx @@ -11,7 +11,7 @@ export const TreeData = PropTypes.shape({ export const TreeSelectProps = () => ({ ...AbstractSelectProps(), - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, dropdownStyle: PropTypes.object, filterTreeNode: PropTypes.oneOfType([Function, Boolean]), getPopupContainer: PropTypes.func, diff --git a/components/vc-checkbox/src/Checkbox.jsx b/components/vc-checkbox/src/Checkbox.jsx index 11e82c4dd..e18173710 100644 --- a/components/vc-checkbox/src/Checkbox.jsx +++ b/components/vc-checkbox/src/Checkbox.jsx @@ -23,7 +23,7 @@ export default { // onClick: PropTypes.func, tabindex: PropTypes.oneOfType([PropTypes.string, PropTypes.number]), readonly: PropTypes.bool, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, value: PropTypes.any, }, { @@ -45,7 +45,7 @@ export default { }, mounted() { nextTick(() => { - if (this.autoFocus) { + if (this.autofocus) { this.$refs.input && this.$refs.input.focus(); } }); @@ -102,7 +102,7 @@ export default { disabled, readonly, tabindex, - autoFocus, + autofocus, onFocus, onBlur, value, @@ -130,7 +130,7 @@ export default { tabindex, class: `${prefixCls}-input`, checked: !!sChecked, - autoFocus, + autofocus, value, ...globalProps, onChange: this.handleChange, diff --git a/components/vc-input-number/src/index.js b/components/vc-input-number/src/index.js index bca0c4bd0..1313e9680 100755 --- a/components/vc-input-number/src/index.js +++ b/components/vc-input-number/src/index.js @@ -45,7 +45,7 @@ const inputNumberProps = { value: PropTypes.oneOfType([PropTypes.number, PropTypes.string]), defaultValue: PropTypes.oneOfType([PropTypes.number, PropTypes.string]), focusOnUpDown: PropTypes.bool, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, // onChange: PropTypes.func, // onKeyDown: PropTypes.func, // onKeyUp: PropTypes.func, @@ -110,12 +110,12 @@ export default { return { inputValue: this.toPrecisionAsStep(validValue), sValue: validValue, - focused: this.autoFocus, + focused: this.autofocus, }; }, mounted() { this.$nextTick(() => { - if (this.autoFocus && !this.disabled) { + if (this.autofocus && !this.disabled) { this.focus(); } this.updatedFunc(); @@ -540,8 +540,8 @@ export default { ); }, toNumber(num) { - const { precision, autoFocus } = this.$props; - const { focused = autoFocus } = this; + const { precision, autofocus } = this.$props; + const { focused = autofocus } = this; // num.length > 16 => This is to prevent input of large numbers const numberIsTooLarge = num && num.length > 16 && focused; if (this.isNotCompleteNumber(num) || numberIsTooLarge) { diff --git a/components/vc-mentions/src/Mentions.jsx b/components/vc-mentions/src/Mentions.jsx index 494bee270..296de7e5a 100644 --- a/components/vc-mentions/src/Mentions.jsx +++ b/components/vc-mentions/src/Mentions.jsx @@ -249,7 +249,7 @@ const Mentions = { prefixCls, placement, transitionName, - autoFocus, + autofocus, notFoundContent, getPopupContainer, ...restProps diff --git a/components/vc-mentions/src/mentionsProps.js b/components/vc-mentions/src/mentionsProps.js index 2e917d8c1..3d40339c9 100644 --- a/components/vc-mentions/src/mentionsProps.js +++ b/components/vc-mentions/src/mentionsProps.js @@ -7,7 +7,7 @@ import { import { PlaceMent } from './placement'; export const mentionsProps = { - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, prefix: PropTypes.oneOfType([PropTypes.string, PropTypes.array]), prefixCls: PropTypes.string, value: PropTypes.string, diff --git a/components/vc-rate/src/Rate.jsx b/components/vc-rate/src/Rate.jsx index 2844da4e5..bfbd95ded 100644 --- a/components/vc-rate/src/Rate.jsx +++ b/components/vc-rate/src/Rate.jsx @@ -17,7 +17,7 @@ const rateProps = { character: PropTypes.any, characterRender: PropTypes.func, tabindex: PropTypes.number, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, }; function noop() {} @@ -56,7 +56,7 @@ export default { }, mounted() { this.$nextTick(() => { - if (this.autoFocus && !this.disabled) { + if (this.autofocus && !this.disabled) { this.focus(); } }); diff --git a/components/vc-select/PropTypes.js b/components/vc-select/PropTypes.js index 4b9604325..271c9355e 100644 --- a/components/vc-select/PropTypes.js +++ b/components/vc-select/PropTypes.js @@ -42,7 +42,7 @@ export const SelectPropTypes = { tokenSeparators: PropTypes.arrayOf(PropTypes.string), getInputElement: PropTypes.func, showAction: PropTypes.arrayOf(PropTypes.string), - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, getPopupContainer: PropTypes.func, clearIcon: PropTypes.any, inputIcon: PropTypes.any, diff --git a/components/vc-select/Select.jsx b/components/vc-select/Select.jsx index f72f1517d..bb91e3bdd 100644 --- a/components/vc-select/Select.jsx +++ b/components/vc-select/Select.jsx @@ -158,7 +158,7 @@ const Select = { this.$nextTick(() => { // when defaultOpen is true, we should auto focus search input // https://github.com/ant-design/ant-design/issues/14254 - if (this.autoFocus || this._open) { + if (this.autofocus || this._open) { this.focus(); } // this.setState({ diff --git a/components/vc-slider/src/Range.jsx b/components/vc-slider/src/Range.jsx index 2e8d09564..0c3bfc636 100644 --- a/components/vc-slider/src/Range.jsx +++ b/components/vc-slider/src/Range.jsx @@ -34,7 +34,7 @@ const rangeProps = { prefixCls: PropTypes.string, min: PropTypes.number, max: PropTypes.number, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, }; const Range = { name: 'Range', diff --git a/components/vc-slider/src/Slider.jsx b/components/vc-slider/src/Slider.jsx index cc5a32f5e..81129caa7 100644 --- a/components/vc-slider/src/Slider.jsx +++ b/components/vc-slider/src/Slider.jsx @@ -13,7 +13,7 @@ const Slider = { defaultValue: PropTypes.number, value: PropTypes.number, disabled: PropTypes.bool, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, tabindex: PropTypes.number, reverse: PropTypes.bool, min: PropTypes.number, diff --git a/components/vc-slider/src/common/createSlider.jsx b/components/vc-slider/src/common/createSlider.jsx index 07a22cb6f..0f49383ae 100644 --- a/components/vc-slider/src/common/createSlider.jsx +++ b/components/vc-slider/src/common/createSlider.jsx @@ -31,7 +31,7 @@ export default function createSlider(Component) { railStyle: PropTypes.object, dotStyle: PropTypes.object, activeDotStyle: PropTypes.object, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, }; return { name: 'createSlider', @@ -75,8 +75,8 @@ export default function createSlider(Component) { // Snapshot testing cannot handle refs, so be sure to null-check this. this.document = this.$refs.sliderRef && this.$refs.sliderRef.ownerDocument; // this.setHandleRefs() - const { autoFocus, disabled } = this; - if (autoFocus && !disabled) { + const { autofocus, disabled } = this; + if (autofocus && !disabled) { this.focus(); } }); diff --git a/components/vc-switch/PropTypes.js b/components/vc-switch/PropTypes.js index a770c8e3b..0ce63feb1 100644 --- a/components/vc-switch/PropTypes.js +++ b/components/vc-switch/PropTypes.js @@ -11,6 +11,6 @@ export const switchPropTypes = { tabindex: PropTypes.oneOfType([PropTypes.string, PropTypes.number]), checked: PropTypes.bool, defaultChecked: PropTypes.bool.def(false), - autoFocus: PropTypes.bool.def(false), + autofocus: PropTypes.bool.def(false), loadingIcon: PropTypes.any, }; diff --git a/components/vc-switch/Switch.jsx b/components/vc-switch/Switch.jsx index 0a39900f2..1ec4112f2 100644 --- a/components/vc-switch/Switch.jsx +++ b/components/vc-switch/Switch.jsx @@ -32,8 +32,8 @@ export default { }, mounted() { this.$nextTick(() => { - const { autoFocus, disabled } = this; - if (autoFocus && !disabled) { + const { autofocus, disabled } = this; + if (autofocus && !disabled) { this.focus(); } }); @@ -84,7 +84,7 @@ export default { disabled, loadingIcon, defaultChecked, - autoFocus, + autofocus, ...restProps } = getOptionProps(this); const checked = this.stateChecked; diff --git a/components/vc-time-picker/TimePicker.jsx b/components/vc-time-picker/TimePicker.jsx index b8ceef059..e19f200c4 100644 --- a/components/vc-time-picker/TimePicker.jsx +++ b/components/vc-time-picker/TimePicker.jsx @@ -65,7 +65,7 @@ export default { secondStep: PropTypes.number, focusOnOpen: PropTypes.bool, // onKeyDown: PropTypes.func, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, id: PropTypes.string, inputIcon: PropTypes.any, clearIcon: PropTypes.any, @@ -116,7 +116,7 @@ export default { }, mounted() { this.$nextTick(() => { - if (this.autoFocus) { + if (this.autofocus) { this.focus(); } }); @@ -335,7 +335,7 @@ export default { getPopupContainer, name, autocomplete, - autoFocus, + autofocus, inputReadOnly, sOpen, sValue, @@ -374,7 +374,7 @@ export default { autocomplete={autocomplete} onFocus={onFocus} onBlur={onBlur} - autoFocus={autoFocus} + autofocus={autofocus} readonly={!!inputReadOnly} id={id} /> diff --git a/components/vc-tree-select/src/Select.jsx b/components/vc-tree-select/src/Select.jsx index 3c084985f..d715fd177 100644 --- a/components/vc-tree-select/src/Select.jsx +++ b/components/vc-tree-select/src/Select.jsx @@ -81,7 +81,7 @@ const Select = { open: PropTypes.bool, value: PropTypes.any, - autoFocus: PropTypes.bool, + autofocus: PropTypes.bool, defaultOpen: PropTypes.bool, defaultValue: PropTypes.any, @@ -258,8 +258,8 @@ const Select = { }, mounted() { this.$nextTick(() => { - const { autoFocus, disabled } = this.$props; - if (autoFocus && !disabled) { + const { autofocus, disabled } = this.$props; + if (autofocus && !disabled) { this.focus(); } }); diff --git a/tests/shared/focusTest.js b/tests/shared/focusTest.js index 45ccc73e4..375a79b70 100644 --- a/tests/shared/focusTest.js +++ b/tests/shared/focusTest.js @@ -44,13 +44,13 @@ export default function focusTest(Component) { }); }); - it('autoFocus', done => { + it('autofocus', done => { jest.useRealTimers(); const handleFocus = jest.fn(); mount( { render(h) { - return ; + return ; }, }, { attachToDocument: true, sync: false }, diff --git a/types/auto-complete.d.ts b/types/auto-complete.d.ts index f5ef1551b..59a8594f4 100644 --- a/types/auto-complete.d.ts +++ b/types/auto-complete.d.ts @@ -22,7 +22,7 @@ export declare class AutoComplete extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * backfill selected item the input when using keyboard diff --git a/types/cascader.d.ts b/types/cascader.d.ts index 6e9b548b3..25ebd77aa 100644 --- a/types/cascader.d.ts +++ b/types/cascader.d.ts @@ -59,7 +59,7 @@ export declare class Cascader extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * change value on each selection if set to true. diff --git a/types/checkbox/checkbox.d.ts b/types/checkbox/checkbox.d.ts index 7d72c1e1a..b0a56c153 100644 --- a/types/checkbox/checkbox.d.ts +++ b/types/checkbox/checkbox.d.ts @@ -13,7 +13,7 @@ export declare class Checkbox extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * Specifies whether the checkbox is selected. diff --git a/types/date-picker/common.d.ts b/types/date-picker/common.d.ts index 0bbe61fd5..3617d520c 100644 --- a/types/date-picker/common.d.ts +++ b/types/date-picker/common.d.ts @@ -18,7 +18,7 @@ export declare class DatepickerCommon extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * custom rendering function for date cells by setting a scoped slot diff --git a/types/input-number.d.ts b/types/input-number.d.ts index 1ed7fd586..d103c55ed 100644 --- a/types/input-number.d.ts +++ b/types/input-number.d.ts @@ -10,7 +10,7 @@ export declare class InputNumber extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * initial value diff --git a/types/mentions/mentions.d.ts b/types/mentions/mentions.d.ts index 3331544f6..b267b244b 100644 --- a/types/mentions/mentions.d.ts +++ b/types/mentions/mentions.d.ts @@ -11,7 +11,7 @@ export declare class Mentions extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * Default value diff --git a/types/radio/radio.d.ts b/types/radio/radio.d.ts index 30cbd36a8..24f921a6c 100644 --- a/types/radio/radio.d.ts +++ b/types/radio/radio.d.ts @@ -15,7 +15,7 @@ export declare class Radio extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * Specifies whether the radio is selected. diff --git a/types/rate.d.ts b/types/rate.d.ts index d2d100508..85d6b95fc 100644 --- a/types/rate.d.ts +++ b/types/rate.d.ts @@ -24,7 +24,7 @@ export declare class Rate extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * custom character of rate diff --git a/types/select/select.d.ts b/types/select/select.d.ts index a5f2bff38..cbec40840 100644 --- a/types/select/select.d.ts +++ b/types/select/select.d.ts @@ -30,7 +30,7 @@ export declare class Select extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * Whether active first option by default diff --git a/types/slider.d.ts b/types/slider.d.ts index 14c84bc89..251594aad 100644 --- a/types/slider.d.ts +++ b/types/slider.d.ts @@ -11,7 +11,7 @@ export declare class Slider extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * The default value of slider. When range is false, use number, otherwise, use [number, number] diff --git a/types/switch.d.ts b/types/switch.d.ts index 4b2e527ed..c91817fca 100644 --- a/types/switch.d.ts +++ b/types/switch.d.ts @@ -10,7 +10,7 @@ export declare class Switch extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * determine whether the Switch is checked diff --git a/types/time-picker.d.ts b/types/time-picker.d.ts index c5cde3428..813d2490f 100644 --- a/types/time-picker.d.ts +++ b/types/time-picker.d.ts @@ -24,7 +24,7 @@ export declare class TimePicker extends AntdComponent { * @default false * @type boolean */ - autoFocus: boolean; + autofocus: boolean; /** * clear tooltip of icon