1/***************************************************************************/ 2/******** Scroll Top ********/ 3/***************************************************************************/ 4$(document).on('click', '#scrollTop', function () { 5 $("body:not(:animated)").animate({ scrollTop: 0 }, 500); 6 $("html").animate({ scrollTop: 0 }, 500); 7 return false; 8}); 9 10$(window).scroll(function(){ 11 if ($(this).scrollTop()>600 && true ){ 12 $("#scrollTop").css({"display":"block"}); 13 } else { 14 $("#scrollTop").css({"display":"none"}); 15 } 16}); 17 18 19jQuery(document).ready(function(){ 20 21 22}); 23 24$('.akcii_btn').on('click', function(){ 25 $('.akcii_fix').toggleClass('hide'); 26 return false; 27}); 28 29 30/***************************************************************************/ 31/******* Make catalog two columns ********/ 32/***************************************************************************/ 33 34 $('.catalog_main .catalog_sub ul').each(function(){ 35 if($(this).find('li').size()>7){ 36 $(this).find('li').css('display','inline-block'); 37 $(this).find('li').css('width','50%'); 38 // $(this).css('column-count','2'); 39 // $(this).css('-moz-column-count','2'); 40 } 41}); 42 43 $('.catalog .catalog_sub ul').each(function(){ 44 if($(this).find('li').size()>7){ 45 $(this).find('li').css('display','inline-block'); 46 $(this).find('li').css('width','50%'); 47 } 48}); 49 50 51/************************************/ 52/******** photoswipe { ********/ 53/************************************/ 54 55var pswpElement = document.querySelectorAll('.pswp')[0]; 56 57 58$(document).on('click', '.gal a', function (event) { 59 60 event.preventDefault(); 61 var elements = $(this).closest('.gal').find('a.gallery_photo'); 62 console.log(elements); 63 64 var items = []; //маÑÑив Ñлайдов 65 66 for (var i = 0; i < elements.length; i++) { 67 var size = $(elements[i]).attr('data-size').split('x'); //ÑÐ°Ð·Ð¼ÐµÑ ÑекÑÑего изобÑÐ°Ð¶ÐµÐ½Ð¸Ñ 68 items[i] = 69 { 70 src: $(elements[i]).attr('href'), // адÑÐµÑ ÐºÐ°ÑÑинки 71 w: size[0], 72 h: size[1] 73 } 74 } 75 76 var index = $(elements).index(this); 77 var options = { 78 shareEl: false, 79 index: index 80 }; 81 var gallery = new PhotoSwipe(pswpElement, PhotoSwipeUI_Default, items, options); 82 gallery.init(); 83 84 return false; 85}); 86 87 88/***************************************************************************/ 89/******* Images to backgound ********/ 90/***************************************************************************/ 91 92if($('.content_menu')){ 93 $('.content_menu .image ').each(function(){ 94 $(this).css('background-image', 'url(' + $(this).find('img').attr('src') + ')' ); 95 $(this).css('background-position', 'center center' ); 96 $(this).css('background-size', 'cover' ); 97 $(this).find('img').css('opacity', '0' ); 98 }); 99}; 100 101 102/***************************************************************************/ 103/********************* OwlCarousel Sync *************************/ 104/***************************************************************************/ 105// if( $('#sync1 .item').length > 1 ){ 106// /* Product page */ 107// var sync1 = $('#sync1'), // Main photo 108// sync2 = $('#sync2'); // Thumbs 109 110// // Sync nav 111// sync1.on('click', '.owl-next', function () { 112// sync2.trigger('next.owl.carousel') 113// }); 114// sync1.on('click', '.owl-prev', function () { 115// sync2.trigger('prev.owl.carousel') 116// }); 117 118// sync2.on('click', '.owl-next', function () { 119// sync1.trigger('next.owl.carousel') 120// }); 121// sync2.on('click', '.owl-prev', function () { 122// sync1.trigger('prev.owl.carousel') 123// }); 124 125// // Start Carousel 126// sync1.owlCarousel({ 127// center : true, 128// loop : true, 129// items : 1, 130// margin:0, 131// nav : true, 132// dot: false, 133// }); 134 135// sync2.owlCarousel({ 136 137// loop : true, 138// items : 6, 139// margin:4, 140// nav : true, 141// slideBy : 1, 142// autoWidth:true 143// }).on('click', '.owl-item', function() { 144// var i = $(this).find('.item').attr('data-sync'); 145// //- 1; 146// sync2.trigger('to.owl.carousel', [i, 500]); 147// sync1.trigger('to.owl.carousel', [i, 500]); 148// //console.log(i); 149// }); 150// } else { 151// $('#sync1.owl-carousel').show(); 152// } 153 154if( $('#sync1 .item').length > 1 ){ 155/* Product page */ 156var sync1 = $('#sync1'), // Main photo 157 sync2 = $('#sync2'); // Thumbs 158 159 // Sync nav 160 sync1.on('click', '.owl-next', function () { 161 sync2.trigger('next.owl.carousel') 162 }); 163 sync1.on('click', '.owl-prev', function () { 164 sync2.trigger('prev.owl.carousel') 165 }); 166 167 sync2.on('click', '.owl-next', function () { 168 sync1.trigger('next.owl.carousel') 169 }); 170 sync2.on('click', '.owl-prev', function () { 171 sync1.trigger('prev.owl.carousel') 172 }); 173 174 // Start Carousel
175 sync1.owlCarousel({ 176 center : true, 177 // loop : true, 178 items : 1, 179 margin:0, 180 nav : true, 181 dot: false, 182 mouseDrag:false, 183 }); 184 185 sync2.owlCarousel({ 186 center : true, 187 // loop : true, 188 items : 4, 189 margin: 10, 190 nav : true, 191 slideBy : 1, 192 mouseDrag:false, 193 }).on('click', '.owl-item', function() { 194 var i = $(this).find('.item').attr('data-sync'); 195 //- 1; 196 sync2.trigger('to.owl.carousel', [i, 400]); 197 sync1.trigger('to.owl.carousel', [i, 400]); 198 console.log(i); 199 console.log($(this)); 200 }); 201} else { 202 $('#sync1.owl-carousel').show(); 203} 204 205 206(function big_pic(){ 207 var big_pics = $('.bigpic'); 208 if(big_pics.length){ 209 big_pics.each(function(){ 210 if($(this).parent('а')){ 211 $(this).parent().attr('onclick','return hs.expand(this)'); 212 }else{ 213 $(this).wrap(a); 214 $(this).parent() 215 .attr('href',$(this).attr('src')) 216 .attr('onclick','return hs.expand(this)'); 217 } 218 }) 219 setTimeout(function(){console.log($(this).parent().attr('onclick'));},1) 220 221 } 222})($) 223 224 225var goals = (function(){ 226 var services = { 227 yaCounterID : '27355607', 228 gaUsed : true, 229 gtagUsed : true, 230 fbqUsed : false, 231 }; 232 var goalDone = function (goalName, goalParams) { 233 if(services.yaCounterID !=='' && typeof window['yaCounter' + services.yaCounterID] !== "undefined"){ 234 window['yaCounter' + services.yaCounterID].reachGoal(goalName, function () {}); 235 } 236 if(services.gaUsed && typeof ga !== "undefined"){ 237 ga('send', 'event', 'Click', goalName); 238 } 239 if(services.gtagUsed && typeof gtag !== "undefined"){ 240 gtag('event', goalName, goalParams); 241 console.log(goalName); 242 } 243 if(services.fbqUsed && typeof fbq !== "undefined"){ 244 fbq('track', goalName, { }); 245 } 246 }; 247 $('body') 248 .on('click', 'a[href^="tel:"]', function(){ 249 goalDone('Click on Phone', {'event_category': 'Clicks'}); 250 }) 251 .on('click', 'a[href^="mailto:"]', function() { 252 goalDone('Click on Email', {'event_category': 'Clicks'}); 253 }) 254 ; 255})(); 256 257jQuery(document).ready(function(){ 258 jQuery('#caruselx').tinycarousel({ axis: 'x'}); 259});
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.