mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
fix(Toast): failed to sync clear toast
This commit is contained in:
parent
9f1c1a8d81
commit
a48caa7c98
@ -16,10 +16,13 @@ export function usePopupState() {
|
|||||||
|
|
||||||
const open = (props: Record<string, any>) => {
|
const open = (props: Record<string, any>) => {
|
||||||
extend(state, props);
|
extend(state, props);
|
||||||
|
// for transition
|
||||||
nextTick(() => toggle(true));
|
nextTick(() => toggle(true));
|
||||||
};
|
};
|
||||||
|
|
||||||
const close = () => toggle(false);
|
const close = () => {
|
||||||
|
nextTick(() => toggle(false));
|
||||||
|
};
|
||||||
|
|
||||||
useExpose({ open, close, toggle });
|
useExpose({ open, close, toggle });
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user