1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-08-16 18:44:01 +02:00

Add v5.2.0-beta1 docs (#36338)

This commit is contained in:
XhmikosR
2022-05-13 20:19:48 +03:00
committed by GitHub
parent 0d0ca30f5d
commit cdce51caab
344 changed files with 174861 additions and 587 deletions

6
docs/5.2/assets/js/docs.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,19 @@
// Example starter JavaScript for disabling form submissions if there are invalid fields
(() => {
'use strict'
// Fetch all the forms we want to apply custom Bootstrap validation styles to
const forms = document.querySelectorAll('.needs-validation')
// Loop over them and prevent submission
Array.from(forms).forEach(form => {
form.addEventListener('submit', event => {
if (!form.checkValidity()) {
event.preventDefault()
event.stopPropagation()
}
form.classList.add('was-validated')
}, false)
})
})()