Skip to content

Commit

Permalink
Reset form on dialog show
Browse files Browse the repository at this point in the history
  • Loading branch information
niemyjski committed Dec 10, 2024
1 parent 6787390 commit 98e6028
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
const { enhance, form: formData } = form;
</script>

<Dialog.Root bind:open>
<Dialog.Root bind:open onOpenChange={() => form.reset()}>
<Dialog.Content class="sm:max-w-[425px]">
<form method="POST" use:enhance>
<Dialog.Header>
Expand Down

0 comments on commit 98e6028

Please sign in to comment.