Server IP : 80.87.202.40 / Your IP : 216.73.216.169 Web Server : Apache System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64 User : bitrix ( 600) PHP Version : 8.2.27 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/bitrix/ext_www/rospirotorg.ru/bitrix/templates/landing24/assets/js/helpers/faq/ |
Upload File : |
;(function() { "use strict"; if (document.querySelector('.landing-edit-mode') === null) { BX.addCustomEvent("BX.Landing.Block:init", function(event) { if (event.block.querySelector("[class^='landing-block-faq-']") !== null) { initCard(event.block); } }); } function initCard(block) { const cards = block.querySelectorAll('.landing-block-card'); cards.forEach(function(card) { if (BX.Dom.hasClass(card, 'active')) { BX.Dom.removeClass(card, 'active'); } if (card.querySelector('.landing-block-faq-visible')) { card.querySelector('.landing-block-faq-visible').onclick = function() { if (!BX.Dom.hasClass(card, 'active')) { if (BX.Dom.hasClass(card, 'faq-single-mode')) { cards.forEach(function(card) { BX.Dom.removeClass(card, 'active'); }) } BX.Dom.addClass(card, 'active'); } else { BX.Dom.removeClass(card, 'active'); } }; } }) } })();