feat: add onPopupReopen (#8641)

This commit is contained in:
neverland
2021-05-01 16:40:50 +08:00
committed by GitHub
parent 161b5980eb
commit b43822562f
2 changed files with 23 additions and 0 deletions
+4
View File
@@ -1,6 +1,7 @@
import {
ref,
watch,
provide,
Teleport,
computed,
PropType,
@@ -21,6 +22,7 @@ import { useEventListener } from '@vant/use';
import { useExpose } from '../composables/use-expose';
import { useLockScroll } from '../composables/use-lock-scroll';
import { useLazyRender } from '../composables/use-lazy-render';
import { POPUP_TOGGLE_KEY } from '../composables/on-popup-reopen';
// Components
import { Icon } from '../icon';
@@ -245,6 +247,8 @@ export default defineComponent({
}
});
provide(POPUP_TOGGLE_KEY, () => props.show);
return () => {
if (props.teleport) {
return (