PageSourceSearch

https://www.hollingstedt.de/_assets/af8568f739844fb45493fcc92d98942c/JavaScript/General/filter.js?1707909638

js hollingstedt.de collected 2026-10-02 23:05:22 UTC 2,073 bytes, 71 lines download raw bytes

1var dkFilter = function() {
2  var that = this;
3  this.filterShow = document.getElementById("filters_show");
4  this.filterContent = document.getElementById("filters_content");
5  this.filterForm = document.getElementById("filter_form");
6  this.filterLists = document.getElementsByClassName("filter_list");
7  this.filterTitles = document.getElementsByClassName("filter_title");
8  this.filterItems = document.getElementsByClassName("filter_radio");
9
10  this.filterChange = function() {
11    that.filterForm.submit();
12  }
13  this.filterTitleClick = function() {
14    this.parentNode.classList.toggle('open');
15    dkSlideToggle(this.nextElementSibling);
16  }
17  this.initFilterShow = function() {
18    if (that.filterShow) {
19      that.filterShow.addEventListener('click', function() {
20        dkSlideToggle(that.filterContent);
21      })
22    }
23  }
24  this.initFilterList = function() {
25    for (let i = 0; i < that.filterLists.length; i++) {
26      if (that.filterLists[i]) {
27        if (i > 0) {
28          that.filterLists[i].style.display = 'none';
29        }
30      }
31    }
32  }
33  this.initFilterTitle = function() {
34    for (let i = 0; i < that.filterTitles.length; i++) {
35      if (that.filterTitles[i]) {
36        that.filterTitles[i].addEventListener('click', that.filterTitleClick, false);
37        if (i === 0) {
38          that.filterTitles[i].parentNode.classList.add('open');
39        }
40      }
41    }
42  }
43  this.initFilterItems = function() {
44    for (let i = 0; i < that.filterItems.length; i++) {
45      if (that.filterItems[i]) {
46        that.filterItems[i].addEventListener('change', that.filterChange, false);
47      }
48    }
49  }
50  this.initFilters = function() {
51    if (window.innerWidth < 1280) {
52      if (that.filterContent) {
53        that.filterContent.style.display = 'none';
54      }
55    }
56  }
57
58  this.init = function() {
59    that.initFilterShow();
60    that.initFilterList();
61    that.initFilterTitle();
62    that.initFilterItems();
63    that.initFilters();
64  }
65  this.init();
66}
67
68
69document.addEventListener('DOMContentLoaded', function() {
70  var filters = new dkFilter();
71});

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.