fix(transition): transition should accept multiple handlers on same event
fix #1746
This commit is contained in:
parent
791eff3dfb
commit
48576e582c
@ -105,6 +105,8 @@ export function useTransitionState(): TransitionState {
|
||||
return state
|
||||
}
|
||||
|
||||
const TransitionHookValidator = [Function, Array]
|
||||
|
||||
const BaseTransitionImpl = {
|
||||
name: `BaseTransition`,
|
||||
|
||||
@ -113,20 +115,20 @@ const BaseTransitionImpl = {
|
||||
appear: Boolean,
|
||||
persisted: Boolean,
|
||||
// enter
|
||||
onBeforeEnter: Function,
|
||||
onEnter: Function,
|
||||
onAfterEnter: Function,
|
||||
onEnterCancelled: Function,
|
||||
onBeforeEnter: TransitionHookValidator,
|
||||
onEnter: TransitionHookValidator,
|
||||
onAfterEnter: TransitionHookValidator,
|
||||
onEnterCancelled: TransitionHookValidator,
|
||||
// leave
|
||||
onBeforeLeave: Function,
|
||||
onLeave: Function,
|
||||
onAfterLeave: Function,
|
||||
onLeaveCancelled: Function,
|
||||
onBeforeLeave: TransitionHookValidator,
|
||||
onLeave: TransitionHookValidator,
|
||||
onAfterLeave: TransitionHookValidator,
|
||||
onLeaveCancelled: TransitionHookValidator,
|
||||
// appear
|
||||
onBeforeAppear: Function,
|
||||
onAppear: Function,
|
||||
onAfterAppear: Function,
|
||||
onAppearCancelled: Function
|
||||
onBeforeAppear: TransitionHookValidator,
|
||||
onAppear: TransitionHookValidator,
|
||||
onAfterAppear: TransitionHookValidator,
|
||||
onAppearCancelled: TransitionHookValidator
|
||||
},
|
||||
|
||||
setup(props: BaseTransitionProps, { slots }: SetupContext) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user