-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
使用antd弹窗ez-modal-react打开一个弹窗,接着使用非 ez-modal-react 方式再打开一个弹窗,接着关闭这2个弹窗再次打开。
重复2次以上这个步骤。
这时ez-modal-react打开的弹窗,会被第二个弹窗的遮罩挡住。
原因在于非ez-modal-react 打开的弹窗没有在关闭后销毁,他的dom占位还在html中,因为antd是根据弹窗占位的元素创建的先后顺序来安排z-index的。
需要配合非ez-modal-react 管理的弹窗一起使用时,解决办法如下。
- 给这个弹窗设置
destroyOnClose={true}
即关闭后注销(由Antd内部控制的行为) - 都用ez-modal-react来管理弹窗
Metadata
Metadata
Assignees
Labels
No labels