PageSourceSearch

https://lucemyra.com/wp-content/themes/healthandnutrition/assets/js/custom.js?ver=1.0

js lucemyra.com collected 2026-10-08 18:20:57 UTC 8,658 bytes, 309 lines download raw bytes

1jQuery(document).ready(function($) {
2    $('.dropdown').prepend('<i class="fa fa-angle-down sub-active"></i>');
3
4    if ($(".menu-toggle").length > 0) {
5      $(document)
6        .off("click", ".menu-toggle")
7        .on("click", ".menu-toggle", function (e) {
8          e.stopPropagation();
9          $("body").toggleClass("mb-hidden");
10          $(".nav-grp").toggleClass("active");
11        });
12      $(document).click(function (e) {
13        if (!$(e.target).is(".menu-toggle,.nav-grp, .nav-grp * ")) {
14          if ($(".nav-grp").is(":visible")) {
15            $('body').removeClass('mb-hidden');
16            $('.nav-grp').removeClass('active');
17            $('.sub-active').removeClass('active');
18            $('.dropdown').removeClass('active');
19          }
20        }
21      });
22    }
23
24    $(window).scroll(function () {
25      if ($(window).scrollTop() > 200) {
26          $('header').addClass('fixed');
27      }
28      if ($(window).scrollTop() < 200) {
29        $('header').removeClass('fixed');
30      }
31    });
32
33    $('.sub-active').click(function() {
34      $(this).parent().toggleClass('active');
35      $('.subment').animate({
36        height: 'toggle'
37      });
38    });
39    $('#close-toggle').click(function() {
40        $('body').removeClass('mb-hidden');
41        $('.nav-grp').removeClass('active');
42        $('.sub-active').removeClass('active');
43        $('.dropdown').removeClass('active');
44    });
45
46    $('.nav-search-btn').click(function() {
47      $('body').addClass('mb-hidden');
48      $('.search-modal').addClass('show');
49    });
50
51    $('.search-close').click(function() {
52      $('body').removeClass('mb-hidden');
53      $('.search-modal').removeClass('show');
54    });
55    $('.menu-toggle').click(function() {
56      $(this).addClass('active');
57    });
58
59 
60      /* Meet Team Slider Start */
61      $('.meet-slider').slick({
62        autoplay: true,
63        arrows: true,
64        slidesToShow: 3,
65        slidesToScroll: 1,
66        infinite: true,
67        responsive: [
68          {
69            breakpoint: 1080,
70            settings: {
71              slidesToShow: 2,
72              slidesToScroll: 1,
73            }
74          },
75          {
76            breakpoint: 480,
77            settings: {
78              slidesToShow: 1,
79              slidesToScroll: 1,
80            }
81          },
82        ]
83      });
84      /* Meet Team Slider End */
85
86      /* Product Slider Start */
87      $('.trending-prot').slick({
88        autoplay: true,
89        arrows: true,
90        slidesToShow: 4,
91        slidesToScroll: 1,
92        infinite: true,
93        responsive: [
94          {
95            breakpoint: 1080,
96            settings: {
97              slidesToShow: 3,
98              slidesToScroll: 1,
99            }
100          },
101          {
102            breakpoint: 768,
103            settings: {
104              slidesToShow: 2,
105              slidesToScroll: 1,
106            }
107          },
108          {
109            breakpoint: 480,
110            settings: {
111              slidesToShow: 1,
112              slidesToScroll: 1,
113            }
114          },
115        ]
116      });
117      /* ProductSlider End */
118
119      /* Testimonials Slider Start */
120      $('.testi-slider').slick({
121        autoplay: true,
122        arrows: false,
123        slidesToShow: 1,
124        slidesToScroll: 1,
125        dots: true,
126      });
127      /* Testimonials Slider End */
128
129      //video start
130     /* $(document).ready(function() {
131        $('.vid-play-btn').magnificPopup({
132            disableOn: 700,
133            type: 'iframe',
134            mainClass: 'mfp-fade',
135            removalDelay: 160,
136            preloader: false,
137            fixedContentPos: false,
138            callbacks: {
139              markupParse: function(template, values, item) {
140                  template.find('iframe').addClass('video-iframe');
141              }
142          }
143        });
144      });*/
145      //Video End
146      //home slick slider 
147      $(document).ready(function () {
148        $('.banner-slider').slick({
149          dots: true,
150          infinite: false,
151          speed: 500,
152          arrows: true,
153          slidesToShow: 1,
154          slidesToScroll: 1
155        }); 
156      });
157      
158      
159      //menu-icon click
160      $(document).ready(function(){
161       
162        $(".menu-icon").on("click", function(){
163            $(".mobile-menu").toggleClass("open");
164        });
165
166    $(".mobile-menu .close").on("click", function(){
167            $(".mobile-menu.open").removeClass("open");
168        });
169    });
170
171              $(".srch").on("click", function(){
172            $(".form_head_search").toggleClass("srh-op");
173        });
174
175    $(".form_head_search .cls").on("click", function(){
176            $(this).parent(".form_head_search.srh-op").removeClass("srh-op");
177        });
178
179$(function () {
180  $('.accordian .title').click(function (e) {
181    e.preventDefault(); // Corrected from j.preventDefault();
182
183    var $this = $(this);
184    var $accordion = $this.closest('.accordian');
185    var $content = $this.next('.content');
186
187    // If this accordion is already active, remove active and slide up
188    if ($accordion.hasClass('active')) {
189      $accordion.removeClass('active');
190      $content.stop(true, true).slideUp();
191    } else {
192      // Close others
193      $('.accordian').removeClass('active').find('.content').slideUp();
194
195      // Open the clicked one
196      $accordion.addClass('active');
197      $content.stop(true, true).slideDown();
198    }
199  });
200});
201    
202$('.back-to-top').on('click', function(e) {
203      e.preventDefault();
204      $('html,body').animate({scrollTop: 0}, 600);
205  });
206$(window).scroll(function () {
207        if ($(window).scrollTop() >500) {
208          $('.back-to-top').css("display", "flex");
209        }
210        if ($(window).scrollTop() <530) {
211          $('.back-to-top').hide();
212        }
213     });
214    
215    
216    // Open/Collapse footer
217    $('.abt-lcm-title').on('click', function(e) {
218        $(this).parent().toggleClass('open');
219        var abtLcmContainer = $('.fot-abt-lcm-wrap');
220        var abtLcmContent = $('.fot-abt-lcm-content');
221        
222        if($(abtLcmContainer).hasClass('open')){
223            $(abtLcmContent).slideDown(400);
224            $('.show-abt-lcm').html("Collapse");
225        }else{
226            $(abtLcmContent).slideUp(400);
227            $('.show-abt-lcm').html("Expand");
228        }
229    });
230    
231
232});      
233
234/**** scroll to section ****/
235$(document).ready(function () {
236
237  // Handle SAME PAGE clicks
238  $('a[href^="#"]:not([href="#"])').on('click', function (e) {
239    const target = $(this.getAttribute('href'));
240    if (target.length) {
241      e.preventDefault();
242
243      setTimeout(function () {
244        $('html, body').stop().animate({
245          scrollTop: target.offset().top - 60
246        }, 600);
247      }, 10); // small delay ensures DOM is ready
248    }
249  });
250
251  // Handle CROSS PAGE (after page load)
252  if (window.location.hash) {
253    const target = $(window.location.hash);
254
255    if (target.length) {
256      setTimeout(function () {
257        $('html, body').stop().animate({
258          scrollTop: target.offset().top - 60
259        }, 600);
260      }, 10); // small delay ensures DOM is ready
261    }
262  }
263});
264
265$(document).ready(function(){
266
267    /*******/
268    jQuery(".ai-btn-open").on("click", function(){
269        jQuery('body').addClass('open-ai');
270    });
271    jQuery(".close-ai-pop, .ai-pop-overlay").on("click", function(){
272        jQuery('body').removeClass('open-ai');
273    });
274
275// AI Search Function
276
277jQuery('section#h-ai-sec a.iffel-button').on('click', function (e) {
278    e.preventDefault();
279        jQuery('.popupaisearch-container').addClass('active');
280    });
281jQuery('.popupaisearch-close-icon').on('click', function (e) {
282    e.preventDefault();
283        jQuery('.popupaisearch-container').removeClass('active');
284    });
285// Tab function
286jQuery('.popAi-tab-head li').on('click', function(e){
287    jQuery('.popAi-tab-head li').removeClass('active');
288    jQuery(this).addClass('active');
289    
290    var tabId = jQuery(this).data('tab');
291    jQuery('.popAi-tab-content').removeClass('active');
292    jQuery('#' +tabId).addClass('active');
293    e.preventDefault();
294});
295
296$('.mobile-menu li.menu-item-has-children').append('<i class="fa fa-angle-right"></i>') ;
297
298
299$('li.menu-item-has-children .fa-angle-right').on('click', function(){
300$(this).parent('li.menu-item-has-children').toggleClass('down');
301
302})
303
304//accordian first open class
305         $( ".accordian" ).first().addClass('active');
306//end
307
308
309  });

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.