Make <dialog> usable without JS (for form confirmation) #10851
Labels
addition/proposal
New features or enhancements
needs implementer interest
Moving the issue forward requires implementers to express interest
What problem are you trying to solve?
I'd like to have the possibility for a confirmation before a form submit.
What solutions exist today?
Using javascript to intersept the submission, call
dialow.showModal()
, check the result and continue submitting or not.How would you solve it?
Given this is quite a common use case, I would suggest the following:
Hitting the submit button should open the dialog. Then, hitting cancel should close the dialog, and prevent the original submission. Hitting confirm should close the dialog, and allow the original form submission to go through.
Anything else?
It is quite possible that I don't fully understand how this all evolves, but it feels a bit strange to me that there are things added like dialog that only / partially work without javascript.
The text was updated successfully, but these errors were encountered: