PageSourceSearch

https://kalibr.tech/themes/kalibr/js/kalibr-2x1-carousel.js?tmf5z3

js kalibr.tech collected 2026-10-06 16:24:17 UTC 1,316 bytes, 53 lines download raw bytes

1/**
2 * @file
3 * Kalibr behaviors.
4 */
5
6(function (Drupal) {
7
8  'use strict';
9
10  /**
11   * Run carousel.
12   */
13  Drupal.behaviors.kalibr2x1Carousel = {
14    attach: function (context, settings) {
15
16      let initSlider = function (container) {
17
18        let slider = container.querySelector('[data-kalibr-2x1-carousel-slider]')
19        if (slider.dataset.tns) {
20          return;
21        }
22        slider.dataset.tns = true;
23        let instance = tns({
24          container: slider,
25          items: 1,
26          autoplay: true,
27          speed: 500,
28          mouseDrag: true,
29          responsive: {
30            850: {
31              items: 2
32            }
33          },
34          autoplayButtonOutput: false,
35          controlsContainer: container.querySelector('[data-kalibr-2x1-carousel-controls]'),
36          prevButton: container.querySelector('[data-kalibr-2x1-carousel-prev-button]'),
37          nextButton: container.querySelector('[data-kalibr-2x1-carousel-next-button]'),
38          nav: false,
39        });
40        window.sliders = window.sliders || [];
41        window.sliders.push(instance)
42
43      }
44
45      let containers = document.querySelectorAll('[data-kalibr-2x1-carousel-container]');
46      for (let i = 0; i < containers.length; ++i) {
47        initSlider(containers[i]);
48      }
49
50    }
51  };
52
53} (Drupal));

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.