django-bootstrap-modal-forms icon indicating copy to clipboard operation
django-bootstrap-modal-forms copied to clipboard

btnSubmit fails detection after html minification

Open markmono opened this issue 2 years ago • 0 comments
trafficstars

After playing around with minifying my html, I came across an issue where the submit button detection no longer works due to type="submit" being removed from buttons.

My approach was changing the selector being used to detect the submit button

let btnSubmit = form.querySelector('button:not([type="button"]:not([type="reset"]');

This will still allow any other buttons which appear on the modal to perform as expected.

markmono avatar Jul 06 '23 04:07 markmono