PageSourceSearch

https://www.tanea.gr/wp-content/themes/whsk_taneagr/common/js/main.js?ver=1.4.2

js tanea.gr collected 2026-10-02 02:53:45 UTC 5,473 bytes, 191 lines download raw bytes

1$(document).ready(function() {
2  if( /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) ) {
3    $('body').addClass('is-mobile');
4  } else {
5    $('body').addClass('is-desktop');
6  }
7});
8
9// $(document).ready(function() {
10//   ways1();
11// });
12
13
14// document.querySelector('.footer-newsletter .checkterms').addEventListener('change', function(e){
15//   if(e.target.checked){
16//   document.querySelector('.footer-newsletter #mc-embedded-subscribe').disabled = false;
17//   } else {
18//   document.querySelector('.footer-newsletter #mc-embedded-subscribe').disabled = true;
19//   }
20// });
21
22$("#seach-button").click(function() {
23  $(this).toggleClass("active-item");
24  $("body").toggleClass("activeSearch");
25});  
26
27$("#burger-area").click(function() {
28  $(this).toggleClass("active-item");
29  $("body").toggleClass("activeBurger");
30});
31
32$("#Now").click(function() {
33  $(this).toggleClass("active-item");
34  $("body").toggleClass("activeNow");
35});  
36
37 $("#burger-area-desktop").click(function() {
38 $(this).toggleClass("active-item");
39 $("body").toggleClass("activeBurger");
40 });
41 
42 $("#burger-area-sticky").click(function() {
43 $(this).toggleClass("active-item");
44 $("body").toggleClass("activeBurger");
45 });
46 
47 $("#burger-area-mobile").click(function() {
48 $(this).toggleClass("active-item");
49 $("body").toggleClass("activeBurger");
50 });  
51
52$("#closeBurger").click(function() {
53  $("body").removeClass("activeBurger");
54});
55$("#closeFocus").click(function() {
56  $("body").removeClass("activeNow");
57});
58
59
60var dropbtn = document.querySelectorAll('.smb');
61for (var i = 0; i < dropbtn.length; i++) {
62dropbtn[i].addEventListener("click", function(){ this.parentElement.parentElement.classList.toggle('active'); });
63}
64  
65
66if(document.querySelector('body').classList.contains('page-login')) {
67document.addEventListener("DOMContentLoaded", function() {
68  var fixedElement = document.getElementById("fixedElement");
69  var closeButton = document.getElementById("closeButton");
70
71  closeButton.addEventListener("click", function() {
72    fixedElement.classList.toggle("show");
73    document.getElementById('statuslog').innerHTML = '';    
74  });
75  
76});
77}
78
79
80// window.addEventListener('scroll', function() {
81//  if (window.innerWidth <= 667) {  
82//   var header = document.querySelector('.article-header');
83//   var rect = header.getBoundingClientRect();
84//   var scrollTop = window.pageYOffset || document.documentElement.scrollTop;
85  
86//   if (rect.top <= 0 && !header.classList.contains('fixed-header')) {
87//     header.classList.add('fixed-header');
88//   } else if (scrollTop === 0) {
89//     header.classList.remove('fixed-header');
90//   }
91//  }
92// });
93
94  document.addEventListener('DOMContentLoaded', function() {
95    const politicsButtons = document.querySelectorAll('.pixel-button');
96
97    politicsButtons.forEach(function(button) {
98      button.addEventListener('click', function() {
99
100        // gtag('event', 'conversion', {
101        //   'send_to': 'AW-17031169797/TNpTCJD3xL0aEIWOjLk_'
102        // });
103
104         const eventName = button.getAttribute('data-name'); // Get custom event name
105         gtag('event', eventName); // send to GA4
106
107         fbq('trackCustom', eventName);
108         
109         console.log(`Custom event sent: ${eventName}`);
110      });
111    });
112  });
113
114
115
116function openTab(evt, TabName) {
117  // Declare all variables
118  var i, tabcontent, tablinks;
119
120  // Get all elements with class="tabcontent" and hide them
121  tabcontent = document.getElementsByClassName("tabcontent");
122  for (i = 0; i < tabcontent.length; i++) {
123    tabcontent[i].style.display = "none";
124  }
125
126  // Get all elements with class="tablinks" and remove the class "active"
127  tablinks = document.getElementsByClassName("tablinks");
128  for (i = 0; i < tablinks.length; i++) {
129    tablinks[i].className = tablinks[i].className.replace(" active", "");
130  }
131
132  // Show the current tab, and add an "active" class to the button that opened the tab
133  document.getElementById(TabName).style.display = "block";
134  evt.currentTarget.className += " active";
135}
136
137document.getElementById("defaultOpen").click();
138
139
140  // if (window.innerWidth < 1023) {
141  //   document.getElementById("Focustabs_inner").appendChild(document.getElementById("AsideFocus"));    
142  // }
143
144
145
146// if ($(window).width() < 767) {
147//    $('#DailyPaper').appendTo('#AppendDaily');
148//    $('#mikrooikonomikos').appendTo('#appendMikrooikonomikos');  
149// }
150
151// if (window.innerWidth > 1200) {
152//   $('#weatherrow').appendTo('#HomeWeather');
153// }
154
155// window.addEventListener('DOMContentLoaded', () => {
156//   setInterval(() => {
157//     const elemTxt = document.querySelector(".qc-cmp2-footer-links button[mode=link]:last-child");
158//     if(elemTxt) {
159//         elemTxt.innerHTML = 'ΕΝΝΟΜΟ ΣΥΜΦΕΡΟΝ';
160//     }
161//   }, 200)
162// });
163
164/*
165$(document).ready(function () {
166  var $dasBillboard = $(".das-billboard--in");
167  var $window = $(window);
168
169  function checkAdFixed() {
170    if ($dasBillboard.hasClass("adActive")) {
171      var billboardHeight = $dasBillboard.outerHeight();
172      var scrollDistance = 30;
173      var scrollTop = $window.scrollTop();
174
175      if (scrollTop >= scrollDistance) {
176        $dasBillboard.addClass("adFixed");
177      } else {
178        $dasBillboard.removeClass("adFixed");
179      }
180    } else {
181      $dasBillboard.removeClass("adFixed");
182    }
183  }
184
185  // Initial check
186  checkAdFixed();
187
188  // Attach a scroll event listener to check if the user scrolls
189  $window.on("scroll", checkAdFixed);
190});
191*/ 

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.