chore: bump Vue 3.2 and remove event shim (#9218)

This commit is contained in:
neverland
2021-08-10 10:04:55 +08:00
committed by GitHub
parent ac2940a365
commit 9025d3b4e3
7 changed files with 59 additions and 86 deletions
+1 -1
View File
@@ -372,7 +372,7 @@ export default defineComponent({
onBlur={onDetailBlur}
onFocus={() => onFocus('addressDetail')}
onInput={onChangeDetail}
onSelectSearch={(event: Event) => emit('select-search', event)}
onSelect-search={(event: Event) => emit('select-search', event)}
/>
{props.showPostal && (
<Field
+1 -1
View File
@@ -293,7 +293,7 @@ export default defineComponent({
emit('confirm', parseValues(values), index);
};
const onCancel = () => emit('cancel');
const onCancel = (...args: unknown[]) => emit('cancel', ...args);
onMounted(setValues);
+1 -1
View File
@@ -281,7 +281,7 @@ export default defineComponent({
color={props.activeColor}
swipeThreshold={0}
swipeable={props.swipeable}
onClickTab={onClickTab}
onClick-tab={onClickTab}
>
{state.tabs.map(renderTab)}
</Tabs>
+1 -1
View File
@@ -23,7 +23,7 @@ test('should emit click-step event when step is clicked', () => {
const wrapper = mount({
setup() {
return () => (
<Steps active={1} onClickStep={onClickStep}>
<Steps active={1} onClick-step={onClickStep}>
<Step>A</Step>
<Step>B</Step>
<Step>C</Step>
-27
View File
@@ -6,37 +6,10 @@ declare module 'vue' {
interface ComponentCustomProps {
role?: string;
tabindex?: number;
// should be removed after Vue supported component events typing
// see: https://github.com/vuejs/vue-next/issues/1553
// https://github.com/vuejs/vue-next/issues/3029
onBlur?: EventHandler;
onOpen?: EventHandler;
onEdit?: EventHandler;
onLoad?: EventHandler;
onClose?: EventHandler;
onFocus?: EventHandler;
onInput?: EventHandler;
onClick?: EventHandler;
onPress?: EventHandler;
onScale?: EventHandler;
onCancel?: EventHandler;
onClosed?: EventHandler;
onChange?: EventHandler;
onDelete?: EventHandler;
onOpened?: EventHandler;
onScroll?: EventHandler;
onSubmit?: EventHandler;
onSelect?: EventHandler;
onToggle?: EventHandler;
onConfirm?: EventHandler;
onPreview?: EventHandler;
onKeypress?: EventHandler;
onTouchend?: EventHandler;
onClickTab?: EventHandler;
onClickStep?: EventHandler;
onTouchmove?: EventHandler;
onTouchstart?: EventHandler;
onTouchcancel?: EventHandler;
onSelectSearch?: EventHandler;
}
}