1(function($) { 2 $.fn.removeClassWild = function(mask) { 3 return this.removeClass(function(index, cls) { 4 var re = mask.replace(/\*/g, '\\S+'); 5 return (cls.match(new RegExp('\\b' + re + '', 'g')) || []).join(' '); 6 }); 7 }; 8})(jQuery); 9 10$(function(){ 11 $(document).on('click','.menu.menu--open .menu__section-toggle',function(){ 12 var section = $(this).data('section-toggle'); 13 $('div[data-barba="container"]').removeClassWild("section_*"); 14 $('div[data-barba="container"]').addClass('section_'+section); 15 }); 16 $(document).on('click','.header__bottom .header__menu .header__button',function(){ 17 var section = $('.menu__tech-list .menu__section-toggle.is-active').data('section-toggle'); 18 if($('body').hasClass('menu-is-open')){ 19 $('div[data-barba="container"]').removeClassWild("section_*"); 20 }else{ 21 $('div[data-barba="container"]').addClass('section_'+section); 22 } 23 24 // 25 }); 26 27 //VALIDATE_MASK_PHONE 28 phone_input = $(".form_time_pop input[placeholder*='ТелеÑон']").inputmask("+7 (999) 999-99-99"); 29 $(document).on('click','input[type="submit"]',function(e){ 30 input_valid = $(this).parents('form').find(phone_input); 31 if(input_valid.length > 0){ 32 if($(input_valid).inputmask("isComplete")){ 33 $(input_valid).next('.error_valid').remove(); 34 } 35 else{ 36 e.preventDefault(); 37 if($(input_valid).next('.error_valid').length == 0){ 38 $('<span class="error_valid">ÐведиÑе коÑÑекÑнÑй Ð½Ð¾Ð¼ÐµÑ ÑелеÑона</span>').insertAfter(input_valid); 39 } 40 } 41 } 42 }); 43 $(document).on('keyup',phone_input,function(){ 44 if($(this.activeElement).inputmask("isComplete")){ 45 $(this.activeElement).next('.error_valid').remove(); 46 } 47 }); 48 49 $('body').on('change', '.policy_check.checkbox_field input', function () { 50 if (!$(this).is(':checked')) { 51 $(this).parents('form').find('.button').addClass('disabled-button').attr("disabled", "disabled"); 52 } else { 53 $(this).parents('form').find('.button').removeClass('disabled-button').removeAttr("disabled"); 54 } 55 }); 56 if($('.pop_form_sales_btn').length > 0){ 57 //$('.with-aside__left.user-text .with-aside__container').append($('.pop_form_sales_btn')); 58 //console.log(312321); 59 } 60 61 $(".cards-layout__container_seo_text").each(function(){ 62 console.log($(this).text()); 63 if($.trim($(this).text()) == ""){ 64 $(this).remove(); 65 } 66 }); 67 68 $(document).on('click','.categories-list__container .categories-list__item',function(){ 69 70 $(this).toggleClass('is-active'); 71 $(this).find('.action-dropdown').toggleClass('is-active'); 72 //$('.categories-list__container .action-dropdown__content').css({'height' : '0', 'min-height':'0'}); 73 //$('.categories-list__container .categories-list__item').removeClass('is-active'); 74 //$('.categories-list__container .categories-list__item .action-dropdown').removeClass('is-active'); 75 if($(this).hasClass('is-active')){ 76 $(this).find('.action-dropdown__content').css({'height' : 'auto', 'min-height':'auto'}); 77 }else{ 78 $(this).find('.action-dropdown__content').css({'height' : '0', 'min-height':'0'}); 79 } 80 }); 81 82 ///YANDEX 83 $(document).on('click','button[type="submit"]',function(){ 84 if($(this).find('.button__text').text() == "ÐаказаÑÑ Ð·Ð²Ð¾Ð½Ð¾Ðº"){ 85 ym(44926993,'reachGoal','zakazat_zvonok'); 86 } 87 if($(this).find('.button__text').text() == "ÐолÑÑиÑÑ ÑенÑ"){ 88 ym(44926993,'reachGoal','poluchit_cenu'); 89 } 90 91 if($(this).find('.button__text').text() == "ÐапиÑаÑÑÑÑ" && $(this).parents('.request-form__info').find('.request-form__title').text() == "ÐапиÑаÑÑÑÑ Ð½Ð° демо-показ"){ 92 ym(44926993,'reachGoal','zapisatsya_demo_pokaz'); 93 } 94 if($(this).find('.button__text').text() == "ÐÑпÑавиÑÑ" && $(this).parents('.form__container').find('.form__title').text() == "ÐапиÑаÑÑ ÑообÑение"){ 95 ym(44926993,'reachGoal','napisat_soobshchenie'); 96 } 97 if($(this).find('.button__text').text() == "ÐÑпÑавиÑÑ Ð·Ð°ÑвкÑ" && $(this).parents('.request-form__info').find('.request-form__title').text() == "ÐÑÑавÑÑе заÑÐ²ÐºÑ Ð½Ð° покÑÐ¿ÐºÑ Ð¸ Ð¼Ñ ÑÑÐ°Ð·Ñ Ð¿Ð¾Ð´Ð³Ð¾Ñовим Ð´Ð»Ñ Ð²Ð°Ñ Ð¿ÐµÑÑоналÑное пÑедложение"){ 98 ym(44926993,'reachGoal','otpravit_zayavku'); 99 } 100 }); 101 102 $(document).on('click','button[type="button"]',function(){ 103 if($(this).find('.button__text').text() == "УзнаÑÑ ÑенÑ"){ 104 ym(44926993,'reachGoal','poluchit_cenu'); 105 } 106 });
107 108 $(document).on('submit','form',function(){ 109 if($(this).find('.request-form__title').text() == "ÐапиÑаÑÑÑÑ Ð½Ð° демо-показ"){ 110 ym(44926993,'reachGoal','demo_pokaz_submit'); 111 } 112 if($(this).find('.request-form__title').text() == "ÐÑÑавÑÑе заÑÐ²ÐºÑ Ð½Ð° покÑÐ¿ÐºÑ Ð¸ Ð¼Ñ ÑÑÐ°Ð·Ñ Ð¿Ð¾Ð´Ð³Ð¾Ñовим Ð´Ð»Ñ Ð²Ð°Ñ Ð¿ÐµÑÑоналÑное пÑедложение"){ 113 ym(44926993,'reachGoal','ostavte_zayavku_na_pokupku_submit'); 114 } 115 }); 116 117 $(document).on('click','.simple-popup__action a',function(e){ 118 e.preventDefault(); 119 window.open($(this).attr('href'), '_blank'); 120 }); 121 122 $(document).on('click','.simple-popup .simple-popup__close',function(){ 123 document.cookie = "simple_popup_"+$(this).parents('.simple-popup').data('id')+"="+$(this).parents('.simple-popup').data('id')+"; path=/;"; 124 //console.log(document.cookie); 125 }); 126 127 $(document).on('click','.button_sale_detail',function(e){ 128 $('.prod_form_hidden input').val($('h1:first').text()); 129 $('#pop_form_sales_detail .form_time_title').text($('h1:first').text()); 130 }); 131 $(document).on('click','.header__location .header__button',function(e){ 132 //$('.location-initial__bottom .button:last-child').trigger('click'); 133 }); 134 $(document).on('click','.product-view-options div[data-link_tabs="service"]',function(){ 135 //document.querySelector('.product-view-options div[data-link_tabs="service"]').click(); 136 137 const event = new Event('click') 138 const dropdownEl = document.querySelector('.nav-panel__items a[href="#service"]') 139 140 dropdownEl.addEventListener('click', () => console.log('Dropdown clicked!')); 141 dropdownEl.dispatchEvent(event); 142 143 }); 144 145 146}); 147 148
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.