PageSourceSearch

https://www.prixdeslibraires.qc.ca/client_file/themes/biztrox/js/theme.js?rand=1790938517

js prixdeslibraires.qc.ca collected 2026-10-02 10:55:55 UTC 9,812 bytes, 381 lines download raw bytes

1/**
2 * WEBSITE: https://themefisher.com
3 * TWITTER: https://twitter.com/themefisher
4 * FACEBOOK: https://facebook.com/themefisher
5 * GITHUB: https://github.com/themefisher/
6 */
7
8(function ($) {
9  'use strict';
10
11  // Preloader js
12
13  $(window).on('load', function () {
14    $('.preloader').fadeOut(700);
15  });   
16
17  //  Search Form Open
18  $('#searchOpen').on('click', function () {
19    $('.search-form').addClass('open');
20  });
21  $('#searchClose').on('click', function () {
22    $('.search-form').removeClass('open');
23  });
24
25  //Hero Slider
26  $('.hero-slider').slick({
27    autoplay: true,
28    infinite: true,
29    arrows: true,
30    prevArrow: '<button type=\'button\' class=\'prevArrow\'><i class=\'ti-arrow-left\'></i></button>',
31    nextArrow: '<button type=\'button\' class=\'nextArrow\'><i class=\'ti-arrow-right\'></i></button>',
32    dots: true,
33    autoplaySpeed: 7000,
34    pauseOnFocus: false,
35    pauseOnHover: false,
36    customPaging: function (slider, i) {
37      var icon = $(slider.$slides[i]).data('icon');
38      var text = $(slider.$slides[i]).data('text');
39      return '<a><i class="' + icon + '"></i><span>' + text + '</span></a>';
40    },
41    responsive: [{
42      breakpoint: 576,
43      settings: {
44        arrows: false
45      }
46    }]
47  });
48  $('.hero-slider').slickAnimation();
49
50  // hero slider without pagination
51  $('.hero-slider-2').slick({
52    autoplay: true,
53    infinite: true,
54    arrows: false,
55    autoplaySpeed: 7000,
56    pauseOnFocus: false,
57    pauseOnHover: false,
58    dots: false
59  });
60  $('.hero-slider-2').slickAnimation();
61
62  // slick slider
63  $('.work-slider').slick({
64    dots: true,
65    infinite: true,
66    speed: 300,
67    slidesToShow: 4,
68    slidesToScroll: 4,
69    arrows: false,
70    autoplay: true,
71    responsive: [{
72        breakpoint: 1024,
73        settings: {
74          slidesToShow: 3,
75          slidesToScroll: 3,
76          infinite: true,
77          dots: true
78        }
79      },
80      {
81        breakpoint: 600,
82        settings: {
83          slidesToShow: 2,
84          slidesToScroll: 2
85        }
86      },
87      {
88        breakpoint: 401,
89        settings: {
90          slidesToShow: 1,
91          slidesToScroll: 1
92        }
93      }
94    ]
95  });
96
97  // about slider
98  $('.about-slider').slick({
99    arrows: true,
100    autoplay: true,
101    prevArrow: '<button type=\'button\' class=\'prevArrow\'><i class=\'ti-arrow-left\'></i></button>',
102    nextArrow: '<button type=\'button\' class=\'nextArrow\'><i class=\'ti-arrow-right\'></i></button>'
103  });
104  // about post slider
105  $('.post-slider').slick({
106    arrows: true,
107    autoplay: true,
108    prevArrow: '<button type=\'button\' class=\'prevArrow\'><i class=\'ti-arrow-left\'></i></button>',
109    nextArrow: '<button type=\'button\' class=\'nextArrow\'><i class=\'ti-arrow-right\'></i></button>'
110  });
111
112  // Accordions
113  $('.collapse').on('shown.bs.collapse', function () {
114    $(this).parent().find('.ti-plus').removeClass('ti-plus').addClass('ti-minus');
115  }).on('hidden.bs.collapse', function () {
116    $(this).parent().find('.ti-minus').removeClass('ti-minus').addClass('ti-plus');
117  });
118
119  // testimonial slider
120  $('.testimonial-slider').slick({
121    infinite: false,
122    dots: false,
123    arrows: true,
124    autoplay: true,
125    prevArrow: '<button type=\'button\' class=\'prevArrow\'><i class=\'ti-arrow-left\'></i></button>',
126    nextArrow: '<button type=\'button\' class=\'nextArrow\'><i class=\'ti-arrow-right\'></i></button>'
127  });
128
129  // clients logo slider
130  $('.client-logo-slider').slick({
131    infinite: true,
132    slidesToShow: 5,
133    slidesToScroll: 1,
134    autoplay: true,
135    dots: false,
136    arrows: false,
137    responsive: [{
138        breakpoint: 1024,
139        settings: {
140          slidesToShow: 3,
141          slidesToScroll: 1
142        }
143      },
144      {
145        breakpoint: 600,
146        settings: {
147          slidesToShow: 3,
148          slidesToScroll: 1
149        }
150      },
151      {
152        breakpoint: 480,
153        settings: {
154          slidesToShow: 2,
155          slidesToScroll: 1
156        }
157      },
158      {
159        breakpoint: 400,
160        settings: {
161          slidesToShow: 1,
162          slidesToScroll: 1
163        }
164      }
165    ]
166  });
167
168  //   magnific popup video
169  $('.popup-youtube, .popup-vimeo, .popup-gmaps').magnificPopup({
170    disableOn: 700,
171    type: 'iframe',
172    mainClass: 'mfp-zoom-in',
173    removalDelay: 160,
174    preloader: false,
175    fixedContentPos: true
176  });
177
178  // Magnific Popup Image
179  $('.popup-image').magnificPopup({
180    type: 'image',
181    removalDelay: 160, //delay removal by X to allow out-animation
182    callbacks: {
183      beforeOpen: function () {
184        // just a hack that adds mfp-anim class to markup
185        this.st.image.markup = this.st.image.markup.replace('mfp-figure', 'mfp-figure mfp-with-anim');
186        this.st.mainClass = this.st.el.attr('data-effect');
187      }
188    },
189    closeOnContentClick: true,
190    midClick: true,
191    fixedContentPos: true,
192    fixedBgPos: true
193  });
194
195  // filter
196  $(document).ready(function () {
197    var containerEl = document.querySelector('.filtr-container');
198    var filterizd;
199    if (containerEl) {
200      filterizd = $('.filtr-container').filterizr({});
201    }
202    //Active changer
203    $('.fltr-controls').on('click', function () {
204      $('.fltr-controls').removeClass('active');
205      $(this).addClass('active');
206    });
207
208    new WOW().init();
209  });
210
211  // animation scroll js
212  /*
213  var html_body = $('html, body');
214  $('nav a, .page-scroll').on('click', function () { //use page-scroll class in any HTML tag for scrolling
215    if (location.pathname.replace(/^\//, '') === this.pathname.replace(/^\//, '') && location.hostname === this.hostname) {
216      var target = $(this.hash);
217      target = target.length ? target : $('[name=' + this.hash.slice(1) + ']');
218      if (target.length) {
219        html_body.animate({
220          scrollTop: target.offset().top - 90
221        }, 1500, 'easeInOutExpo');
222        return false;
223      }
224    }
225  }); */
226
227  // easeInOutExpo Declaration
228  jQuery.extend(jQuery.easing, {
229    easeInOutExpo: function (x, t, b, c, d) {
230      if (t === 0) {
231        return b;
232      }
233      if (t === d) {
234        return b + c;
235      }
236      if ((t /= d / 2) < 1) {
237        return c / 2 * Math.pow(2, 10 * (t - 1)) + b;
238      }
239      return c / 2 * (-Math.pow(2, -10 * --t) + 2) + b;
240    }
241  });
242
243  // back to top button
244  $('.back-to-top').on('click', function (e) {
245    e.preventDefault();
246    $('html,body').animate({
247      scrollTop: 0
248    }, 1500, 'easeInOutExpo');
249  });
250
251  // -----------------------------
252  //  Count Up
253  // -----------------------------
254  function counter() {
255    var oTop;
256    if ($('.count').length !== 0) {
257      oTop = $('.count').offset().top - window.innerHeight;
258    }
259    if ($(window).scrollTop() > oTop) {
260      $('.count').each(function () {
261        var $this = $(this),
262          countTo = $this.attr('data-count');
263        $({
264          countNum: $this.text()
265        }).animate({
266          countNum: countTo
267        }, {
268          duration: 1000,
269          easing: 'swing',
270          step: function () {
271            $this.text(Math.floor(this.countNum));
272          },
273          complete: function () {
274            $this.text(this.countNum);
275          }
276        });
277      });
278    }
279  }
280  $(window).on('scroll', function () {
281    counter();
282  });
283
284  // syotimer
285  $('#simple-timer').syotimer({
286    year: 2019,
287    month: 1,
288    day: 31,
289    hour: 0,
290    minute: 0
291  });
292
293  // AOS
294  AOS.init();
295
296
297  // Parallax background
298  function bgParallax() {
299    if ($('.parallax').length) {
300      $('.parallax').each(function () {
301        var height = $(this).position().top;
302        var resize = height - $(window).scrollTop();
303        var doParallax = -(resize / 5);
304        var positionValue = doParallax + 'px';
305        var img = $(this).data('bg-image');
306
307        $(this).css({
308          backgroundImage: 'url(' + img + ')',
309          backgroundPosition: '50%' + positionValue,
310          backgroundSize: 'cover'
311        });
312      });
313    }
314  }
315
316  // DATA BACKGROUND IMAGE
317  var sliderBgSetting = $('.slide-bg-image');
318  sliderBgSetting.each(function (indx) {
319    if ($(this).attr('data-background')) {
320      $(this).css('background-image', 'url(' + $(this).data('background') + ')');
321    }
322  });
323
324  // SWIPER SLIDER
325  /*
326  var menu = [];
327  jQuery('.swiper-slide').each(function (index) {
328    menu.push(jQuery(this).find('.slide-inner').attr('data-text'));
329  });
330  var interleaveOffset = 0.5;
331  var swiperOptions = {
332    loop: true,
333    speed: 1000,
334    parallax: true,
335    autoplay: {
336      delay: 6500,
337      disableOnInteraction: false
338    },
339    watchSlidesProgress: true,
340    pagination: {
341      el: '.swiper-pagination',
342      clickable: true
343    },
344
345    navigation: {
346      nextEl: '.swiper-button-next',
347      prevEl: '.swiper-button-prev'
348    },
349
350    on: {
351      progress: function () {
352        var swiper = this;
353        for (var i = 0; i < swiper.slides.length; i++) {
354          var slideProgress = swiper.slides[i].progress;
355          var innerOffset = swiper.width * interleaveOffset;
356          var innerTranslate = slideProgress * innerOffset;
357          swiper.slides[i].querySelector('.slide-inner').style.transform =
358            'translate3d(' + innerTranslate + 'px, 0, 0)';
359        }
360      },
361
362       touchStart: function () {
363        var swiper = this;
364        for (var i = 0; i < swiper.slides.length; i++) {
365          swiper.slides[i].style.transition = '';
366        }
367      },
368
369      setTransition: function (speed) {
370        var swiper = this;
371        for (var i = 0; i < swiper.slides.length; i++) {
372          swiper.slides[i].style.transition = speed + 'ms';
373          swiper.slides[i].querySelector('.slide-inner').style.transition =
374            speed + 'ms';
375        }
376      }
377    }
378  };
379  var swiper = new Swiper('.swiper-container', swiperOptions);
380  */
381})(jQuery);

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.