PageSourceSearch

https://www.vic-sur-seille.fr/wp-content/themes/theme_client/js/functions.js?ver=7.0.6

js vic-sur-seille.fr collected 2026-10-02 22:20:59 UTC 4,725 bytes, 167 lines download raw bytes

1jQuery(document).ready(function () {
2    var $ = jQuery;
3
4    resizeActu();
5
6    var scrollTop = jQuery(document).scrollTop();
7    if ( scrollTop > 100 ) {
8        jQuery('#site-header').addClass('sticky');
9    } else {
10        jQuery('#site-header').removeClass('sticky');
11    }
12
13
14    jQuery(document).on('scroll', function() {
15        var scrollTop = jQuery(document).scrollTop();
16        if ( scrollTop > 100 ) {
17            jQuery('#site-header').addClass('sticky');
18        } else {
19            jQuery('#site-header').removeClass('sticky');
20        }
21
22    });
23
24    jQuery('.section-acces-rapide .titre-alaune').on('click', function() {
25        jQuery(this).parent().toggleClass('active');
26    })
27
28    $('.navbar-nav .nav-link').on('click', function() {
29        if ($(window).width() < 992) {
30            $('#mainNav').collapse('hide');
31        }
32    });
33
34    jQuery(document).on('click', '.pojo-a11y-btn-resize-font', function(){
35        resizeActu();
36    });
37
38    if (jQuery(window).width() < 1300 ) jQuery('.section-acces-rapide').removeClass('active');
39
40
41    var lastScrollTop = 0;
42    $(window).scroll(function(event){
43        var st = $(this).scrollTop();
44        if (st > lastScrollTop){
45            jQuery('.section-acces-rapide').removeClass('active');
46        } /*else {
47            // upscroll code
48            jQuery('.section-acces-rapide').addClass('active');
49        }*/
50        lastScrollTop = st;
51    });
52
53    if ( jQuery(window).width() > 991 ) {
54        jQuery('.section-acces-rapide').addClass('active');
55    }
56
57
58    jQuery(window).resize(function() {
59        if ( jQuery(window).width() > 991 ) {
60            jQuery('.section-acces-rapide').addClass('active');
61        }
62    });
63
64    jQuery('a[href$=".jpg"]').colorbox({scalePhotos:true, 'maxHeight': '80%', 'maxWidth' : '80%'});
65
66
67});
68
69function resizeActu() {
70    //jQuery('.actualites-liste .row').find('article').css('height', '')
71    /*if ( jQuery('.actualites-liste').length > 0 ||  jQuery('.actualites-liste-accueil').length > 0 ) {
72        if ( jQuery(window).width() > 991) {
73            jQuery('.actualites-liste .row:not(.row-first),.actualites-liste-accueil .row:not(.row-first)').find('article').css('height', jQuery('.actualites-liste,.actualites-liste-accueil').find('article').parent().height()+'px')
74        } else {
75            jQuery('.actualites-liste .row:not(.row-first),.actualites-liste-accueil .row:not(.row-first)').find('article').css('height', '')
76        }
77    }*/
78    if ( jQuery('.agenda-liste').length > 0  ) {
79        if ( jQuery(window).width() > 991) {
80            jQuery('.agenda-liste .row:not(.row-first)').find('article').css('height', jQuery('.agenda-liste').find('article').parent().height()+'px')
81        } else {
82            jQuery('.agenda-liste .row:not(.row-first)').find('article').css('height', '')
83        }
84    }
85
86}
87
88jQuery(window).load(function(){
89    // SLIDER A LA UNE
90
91
92    var slick_slider_a_la_une = new Swiper(".sliderUne", {
93        slidesPerView: 1,
94        grabCursor: true,
95        loop: false,
96        autoplay: {
97            delay: 4000,
98            disableOnInteraction: true,
99        },
100    });
101
102    // actualites
103    var swiper = new Swiper(".mySwiper", {
104        slidesPerView: 1,
105        grabCursor: true,
106        loop: true,
107        autoplay: {
108            delay: 5000,
109            disableOnInteraction: true,
110        },
111        breakpoints: {
112            600: {
113                slidesPerView: 2,
114            },
115            750: {
116                slidesPerView: 3,
117            },
118        }
119    });
120
121
122    var slider_agenda = new Swiper(".slick_slider_agenda", {
123        slidesPerView: 1,
124        grabCursor: true,
125        loop: true,
126        autoplay: {
127            delay: 5000,
128            disableOnInteraction: true,
129        },
130        breakpoints: {
131            575: {
132                slidesPerView: 2,
133            },
134            768: {
135                slidesPerView: 3,
136            },
137        }
138    });
139
140    var slider_labels = new Swiper(".sliderLabels", {
141        slidesPerView: 1,
142        grabCursor: true,
143        loop: false,
144        autoplay: {
145            delay: 5000,
146            disableOnInteraction: true,
147        },
148        breakpoints: {
149            575: {
150                slidesPerView: 2,
151            },
152            768: {
153                slidesPerView: 3,
154            },
155            950: {
156                slidesPerView: 4,
157            },
158            1250: {
159                slidesPerView: 4,
160            },
161            1500: {
162                slidesPerView: 5,
163            }
164        }
165    });
166
167});

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.