primer commit. añadido tema Velzon

This commit is contained in:
Jaime Jiménez
2025-07-19 10:57:49 +02:00
parent bb724f9f08
commit 3f151be9a7
4310 changed files with 605578 additions and 0 deletions

View File

@ -0,0 +1,48 @@
/*
Template Name: Velzon - Admin & Dashboard Template
Author: Themesbrand
Website: https://Themesbrand.com/
Contact: Themesbrand@gmail.com
File: Form input spin Js File
*/
// input spin
isData();
function isData() {
var plus = document.getElementsByClassName('plus');
var minus = document.getElementsByClassName('minus');
var product = document.getElementsByClassName("product");
if (plus) {
Array.from(plus).forEach(function (e) {
e.addEventListener('click', function (event) {
// if(event.target.previousElementSibling.value )
if (parseInt(e.previousElementSibling.value) < event.target.previousElementSibling.getAttribute('max')) {
event.target.previousElementSibling.value++;
if (product) {
Array.from(product).forEach(function (x) {
updateQuantity(event.target);
})
}
}
});
});
}
if (minus) {
Array.from(minus).forEach(function (e) {
e.addEventListener('click', function (event) {
if (parseInt(e.nextElementSibling.value) > event.target.nextElementSibling.getAttribute('min')) {
event.target.nextElementSibling.value--;
if (product) {
Array.from(product).forEach(function (x) {
updateQuantity(event.target);
})
}
}
});
});
}
}