svelte-modals
svelte-modals copied to clipboard
When stacking modals, the previous ones get re-created, and lose their states.
Describe the bug A clear and concise description of what the bug is.
When opening a modal over another modal, the previous modal gets recreated even though the only change is isOpen prop. This causes it to lose it's state and reset back to default, which is not optimal when doing something like 'Settings page -> Prompt' because the settings page will reset it's state.
Reproduction Provide a reproduction URL or steps to reproduce. If a report is vague and no reproduction is provided within a reasonable time-frame, the issue will be closed.
Create a modal w/ a prop, change the prop at runtime, open a modal over the previous one, then close the new modal, the prop will reset to default value.
Additional context Add any other context about the problem here.