Fixes #5768: When setting `data-confirm` attribute to a submit button, clicking on the button would not trigger form submission