Open jadvillafania opened 4 years ago
Since your Form value is entered and determined, the value of the Form still exists when the dialog element is destroyed, and will be re-assigned when you reopen it
Is there a way to solve this now?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
use v-if to solve?
v-if can solve the problem
Since your Form value is entered and determined, the value of the Form still exists when the dialog element is destroyed, and will be re-assigned when you reopen it
This is not due to the form data, when setting destory-on-close=true
, element in the modal/drawer should be removed from dom, but now it exists, and modal style is display: none
v-if will destroy the animation effect when it is closed
v-if will destroy the animation effect when it is closed
会破坏的,直接就没有动画效果啦
Element UI version
2.13.0
OS/Browsers version
Chrome Version 79.0.3945.79
Vue version
2.6.11
Reproduction Link
https://codepen.io/hollowcast/pen/MWYbQBw
Steps to reproduce
Create a dialog with option :destroy-on-close="true"
What is Expected?
Contents of the dialog should be destroyed after it closes. (Similar to the behavior of drawer destroy on close)
What is actually happening?
Contents are not destroyed.