mirror of
https://git.imnavajas.es/jjimenez/safekat.git
synced 2025-07-25 22:52:08 +00:00
terminando servicios manipulados y preimpresion
This commit is contained in:
@ -1,39 +0,0 @@
|
||||
/**
|
||||
* Pricing
|
||||
*/
|
||||
|
||||
'use strict';
|
||||
|
||||
document.addEventListener('DOMContentLoaded', function (event) {
|
||||
(function () {
|
||||
const priceDurationToggler = document.querySelector('.price-duration-toggler'),
|
||||
priceMonthlyList = [].slice.call(document.querySelectorAll('.price-monthly')),
|
||||
priceYearlyList = [].slice.call(document.querySelectorAll('.price-yearly'));
|
||||
|
||||
function togglePrice() {
|
||||
if (priceDurationToggler.checked) {
|
||||
// If checked
|
||||
priceYearlyList.map(function (yearEl) {
|
||||
yearEl.classList.remove('d-none');
|
||||
});
|
||||
priceMonthlyList.map(function (monthEl) {
|
||||
monthEl.classList.add('d-none');
|
||||
});
|
||||
} else {
|
||||
// If not checked
|
||||
priceYearlyList.map(function (yearEl) {
|
||||
yearEl.classList.add('d-none');
|
||||
});
|
||||
priceMonthlyList.map(function (monthEl) {
|
||||
monthEl.classList.remove('d-none');
|
||||
});
|
||||
}
|
||||
}
|
||||
// togglePrice Event Listener
|
||||
togglePrice();
|
||||
|
||||
priceDurationToggler.onchange = function () {
|
||||
togglePrice();
|
||||
};
|
||||
})();
|
||||
});
|
||||
Reference in New Issue
Block a user