1;( function( $ ) { 2 'use strict'; 3 4 $( document ).ready( function() { 5 6 var doctorFilter = { 7 init: function() { 8 this.setFirstCat(); 9 $( document ).on( 'click', '[data-doctor-cat-filter]', this.filterDoctorList ); 10 }, 11 12 setFirstCat: function() { 13 var $firstCat = $('[data-doctor-cat-filter]').first(); 14 15 $firstCat.closest('li').addClass('active-filter'); 16 17 $('.doc-list li[data-doctor-cat*="' + $firstCat.attr('data-doctor-cat-filter') + '"]').show(); 18 19 doctorFilter.hideLoader(); 20 }, 21 22 filterDoctorList: function( e ) { 23 e.preventDefault(); 24 25 doctorFilter.showLoader(); 26 27 var $this = $( this ), 28 cat = $this.attr( 'data-doctor-cat-filter' ); 29 30 if ( cat ) { 31 $( '.filter-lst ul li' ).removeClass( 'active-filter' ); 32 $( this ).closest( 'li' ).addClass( 'active-filter' ); 33 $( '.doc-list li[data-doctor-cat]' ).hide(); 34 35 setTimeout( function() { 36 $( 'li[data-doctor-cat]' ).each( function( i, li ) { 37 if ( $( li ).attr( 'data-doctor-cat' ).includes( cat ) ) { 38 $( li ).show(); 39 } 40 } ); 41 42 doctorFilter.hideLoader(); 43 }, 1000 ); 44 } 45 }, 46 47 showLoader: function() { 48 $( '.doc-list .doc-loader' ).show(); 49 }, 50 hideLoader: function() { 51 $( '.doc-list .doc-loader' ).hide(); 52 } 53 } 54 55 doctorFilter.init(); 56 57 58 var acc = document.getElementsByClassName("accordion"); 59 var i; 60 61 for (i = 0; i < acc.length; i++) { 62 acc[i].addEventListener("click", function() { 63 this.classList.toggle("active"); 64 var panel = this.nextElementSibling; 65 if (panel.style.maxHeight) { 66 panel.style.maxHeight = null; 67 } else { 68 panel.style.maxHeight = panel.scrollHeight + "px"; 69 } 70 }); 71 } 72 73 // Sticky mobile buttons. 74 $(document).ready(function(){ 75 var bodyheight = $('body').innerHeight(); 76 var completehgt = bodyheight - 600 77 $(window).scroll(function(){ 78 if ($(window).scrollTop() < completehgt) { 79 $('.ftr-action-btn-m').addClass('fixedfooter'); 80 } 81 if ($(window).scrollTop() > completehgt) { 82 $('.ftr-action-btn-m').removeClass('fixedfooter'); 83 } 84 }); 85 }); 86 87 88 // Book online popup. 89 $( document ).on( 'click', '.js-book-online-toggle', function( e ) { 90 e.preventDefault(); 91 92 if ( $( '.forhealth-book-popup' ).hasClass( 'active' ) ) { 93 $( '.forhealth-book-popup-overlay, .forhealth-book-popup' ).removeClass( 'active' ); 94 } else { 95 $( '.forhealth-book-popup-overlay, .forhealth-book-popup' ).addClass( 'active' ); 96 } 97 } ); 98 99 $( document ).on( 'click', '[data-hotdoc-widget]', function( e ) { 100 e.preventDefault(); 101 102 $( '.forhealth-book-popup-overlay, .forhealth-book-popup' ).removeClass( 'active' ); 103 } ); 104 105 // Slick slider. 106 $( '.slidergp-main' ).slick( { 107 dots: false, 108 infinite: false, 109 slidesToShow: 3, 110 slidesToScroll: 1, 111 autoplay: true, 112 autoplaySpeed: 2000, 113 centerPadding: '60px', 114 responsive: [ 115 { 116 breakpoint: 1024, 117 settings: { 118 slidesToShow: 3, 119 slidesToScroll: 3, 120 infinite: true, 121 dots: true 122 } 123 }, 124 { 125 breakpoint: 600, 126 settings: { 127 slidesToShow: 2, 128 slidesToScroll: 2 129 } 130 }, 131 { 132 breakpoint: 480, 133 settings: { 134 slidesToShow: 1, 135 slidesToScroll: 1 136 } 137 } 138 ] 139 } ); 140 141 } ); // Doc.ready end. 142} )( jQuery ); 143 144 145;( function( $ ) { 146 'use strict'; 147 148 var forhealth_popup = { 149 init: function() { 150 $( document ).on( 'click', '[target="_popup"]', this.show_popup ); 151 $( document ).on( 'click', '.js-fh-popup-close', this.close_popup ); 152 }, 153 show_popup: function( e ) { 154 e.preventDefault(); 155 156 var $this = $( this ); 157 var link = $this.attr( 'href' ); 158 159 forhealth_popup.close_popup(); 160 161 $( document.body ).trigger( 'forhealth_popup_open' ); 162 163 $( 'html, body' ).addClass( 'fh-html-no-scroll' ); 164 165 $( 'body' ).append( ` 166 <div class="fh-popup-overlay js-fh-popup-close"></div> 167 <div class="fh-popup"> 168 <div class="js-fh-popup-close fh-popup__close">X</div> 169 <iframe src="${link}" frameborder="0" scrolling="yes"></iframe> 170 </div> 171 ` ); 172 }, 173 close_popup: function() { 174 $( 'html, body' ).removeClass( 'fh-html-no-scroll' ); 175 $( '.fh-popup-overlay, .fh-popup' ).remove(); 176 } 177 }; 178 179 forhealth_popup.init(); 180 181 $( document ).ready( function() { 182 183 $( document.body ).on( 'forhealth_popup_open', function() { 184 $( '.forhealth-book-popup-overlay, .forhealth-book-popup' ).removeClass( 'active' ); 185 } ); 186 187 } ); // Doc.ready end. 188 189} )( jQuery );
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.