PageSourceSearch

https://bioetlocal.org/wp-content/themes/bioetlocal/assets/js/home-actus.js?ver=1788184787

js bioetlocal.org collected 2026-10-07 21:07:07 UTC 1,942 bytes, 57 lines download raw bytes

1/* ── Carousel Actus (Slick Slider) ────────────────────────── */
2jQuery(function ($) {
3    $('.js-actus-slider').each(function () {
4        var $slider  = $(this);
5        var uid      = $slider.data('uid');
6        var $section = $('#' + uid);
7        var $arrows  = $section.find('.home-actus-prev, .home-actus-next');
8
9        function updateArrows() {
10            var s = $slider.slick('getSlick');
11            $arrows.toggle(s.slideCount > s.options.slidesToShow);
12        }
13
14        $slider.on('breakpoint', updateArrows);
15
16        $slider.slick({
17            slidesToShow  : 3,
18            slidesToScroll: 1,
19            arrows        : false,
20            infinite      : false,
21            responsive: [
22                { breakpoint: 992,  settings: { slidesToShow: 2 } },
23                { breakpoint: 480,  settings: { slidesToShow: 1 } },
24            ],
25        });
26
27        updateArrows();
28
29        $section.find('.home-actus-prev').on('click', function () {
30            $slider.slick('slickPrev');
31        });
32
33        $section.find('.home-actus-next').on('click', function () {
34            $slider.slick('slickNext');
35        });
36
37        $section.find('.home-actus-filter').on('click', function () {
38            var $btn     = $(this);
39            var isActive = $btn.hasClass('is-active');
40
41            $section.find('.home-actus-filter').removeClass('is-active');
42            $slider.slick('slickUnfilter');
43
44            if (!isActive) {
45                $btn.addClass('is-active');
46                var cat = $btn.data('filter');
47                $slider.slick('slickFilter', function (idx, el) {
48                    var slugs = ($(el).data('cat-slugs') || '').trim().split(/\s+/);
49                    return slugs.indexOf(cat) !== -1;
50                });
51                $slider.slick('slickGoTo', 0);
52            }
53
54            updateArrows();
55        });
56    });
57});

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.