diff options
Diffstat (limited to 'vendor/twbs/bootstrap/site/docs/4.5/examples/checkout/form-validation.js')
-rw-r--r-- | vendor/twbs/bootstrap/site/docs/4.5/examples/checkout/form-validation.js | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/vendor/twbs/bootstrap/site/docs/4.5/examples/checkout/form-validation.js b/vendor/twbs/bootstrap/site/docs/4.5/examples/checkout/form-validation.js deleted file mode 100644 index 59291c8b3..000000000 --- a/vendor/twbs/bootstrap/site/docs/4.5/examples/checkout/form-validation.js +++ /dev/null @@ -1,21 +0,0 @@ -// Example starter JavaScript for disabling form submissions if there are invalid fields -(function () { - 'use strict' - - window.addEventListener('load', function () { - // Fetch all the forms we want to apply custom Bootstrap validation styles to - var forms = document.getElementsByClassName('needs-validation') - - // Loop over them and prevent submission - Array.prototype.filter.call(forms, function (form) { - form.addEventListener('submit', function (event) { - if (form.checkValidity() === false) { - event.preventDefault() - event.stopPropagation() - } - - form.classList.add('was-validated') - }, false) - }) - }, false) -})() |