You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've managed to narrow down the issue quite a bit, which makes this completely obsolete and confusing. I'm closing this in favour of #777.
See old issue details:
Describe the bug and the expected behavior
When a form that's been wired up with @conform-to/react is placed inside a Dialog component (tested with Radix UI and Headless UI), the form unexpectedly resets to its initial value upon the first validation failure. This only occurs the first time validation fails; subsequent validation failures don't cause the form to reset.
Expected behaviour: The form should maintain its current state and display validation errors without resetting to the initial value.
I've managed to narrow down the issue quite a bit, which makes this completely obsolete and confusing. I'm closing this in favour of #777.
See old issue details:
Describe the bug and the expected behavior
When a form that's been wired up with @conform-to/react is placed inside a Dialog component (tested with Radix UI and Headless UI), the form unexpectedly resets to its initial value upon the first validation failure. This only occurs the first time validation fails; subsequent validation failures don't cause the form to reset.
Expected behaviour: The form should maintain its current state and display validation errors without resetting to the initial value.
Conform version
v1.2.1
Steps to Reproduce the Bug or Issue
To try the same without a dialog, find this line inside
App.tsx
and setplaceInsideDialog
to false:What browsers are you seeing the problem on?
Chrome, Firefox, Safari
Screenshots or Videos
Form inside a dialog:
CleanShot.2024-09-18.at.22.57.21.mp4
Exact same form outside the dialog:
CleanShot.2024-09-18.at.22.55.39.mp4
The text was updated successfully, but these errors were encountered: