1var windowWidth = 0, windowHeight = 0, headerHeight = 0, footerHeight = 0, footerTop = 0; 2 3makansutra = { 4 init: function() { 5 makansutra.resize(); 6 makansutra.scroll(); 7 8 // detect if mobile or touch device 9 if (Modernizr.touch) { 10 $('html').addClass('bp-touch'); 11 } 12 13 $(".backToTop").click(function(event) { 14 event.preventDefault(); 15 $("html, body").animate({scrollTop : 0 }, 600, 'easeInOutCirc' ); 16 return false; 17 }); 18 }, 19 getBiggest: function(elements) { 20 var biggest_height = 0; 21 for ( var i = 0; i < elements.length ; i++ ){ 22 var element_height = $(elements[i]).outerHeight(); 23 //compare the height, if bigger, assign to variable 24 if(element_height > biggest_height ) biggest_height = element_height; 25 } 26 return biggest_height; 27 }, 28 resize: function() { 29 windowWidth = $(window).width(); 30 windowHeight = $(window).height(); 31 32 // STICKY FOOTER 33 headerHeight = $('header').outerHeight(); 34 footerHeight = $('footer').outerHeight(); 35 footerTop = (footerHeight) * -1 36 $('footer').css({marginTop: footerTop}); 37 $('#main-wrapper').css({paddingBottom: footerHeight}); 38 39 // for equalizer 40 $('.classname').css({minHeight: 0}); 41 var ClassName = makansutra.getBiggest($('.classname')); 42 $('.classname').css({minHeight: ClassName}); 43 }, 44 scroll: function() { 45 var height = $(window).scrollTop(); 46 if (height > 100) { 47 $('.backToTop').fadeIn(); 48 } else { 49 $('.backToTop').fadeOut(); 50 } 51 }, 52 animation: function() { 53 if (Modernizr.touch) { 54 //$('.animate').removeClass('animate').removeAttr('anim-control').removeAttr('anim-delay').removeAttr('anim-name'); 55 } 56 57 $('.animate').each(function() { 58 var thisAnim = $(this), // this content 59 animControl = $(this).attr('anim-control'), // for single or parent container 60 animName = $(this).attr('anim-name'), // customize animation 61 animDelay = parseFloat($(this).attr('anim-delay')), // delay value 62 delayIncrease = 0.2; 63 // if the container is parent 64 if(animControl == 'parent') { 65 // add delay to each child element 66 $(this).children().each(function(index) { 67 var element = $(this); 68 if(isNaN(animDelay)) { 69 animDelay = 0.5; 70 } 71 if(animDelay == 0) { 72 delayIncrease = 0; 73 } 74 var delayNum = animDelay + (delayIncrease * index) + 's'; 75 setTimeout(function() { 76 $(element).css('-webkit-animation-delay', delayNum) 77 .css('-moz-animation-delay', delayNum) 78 .css('-ms-animation-delay', delayNum) 79 .css('-o-animation-delay', delayNum) 80 }, 100); 81 }); 82 $(this).css({opacity: 1}); 83 84 if(animName == null) { 85 // if no customize animation then use default animation 86 $(this).children().each(function(index) { 87 $(this).addClass('anim-content'); 88 }); 89 } else { 90 // if have customize animation 91 $(this).children().each(function(index) { 92 $(this).addClass('animated'); 93 $(this).on('inview',function(event,visible){ 94 if (visible == true) { 95 $(this).addClass(animName); 96 } 97 }); 98 }); 99 } 100 101 // if the container is not parent 102 } else { 103 if(animName == null) { 104 // if no customize animation then use default animation 105 $(this).addClass('anim-content'); 106 } else { 107 // if have customize animation 108 $(this).addClass('animated'); 109 $(this).on('inview',function(event,visible){ 110 if (visible == true) { 111 $(this).addClass(animName); 112 } 113 }); 114 } 115 // if have customize animation-delay 116 if(animDelay != null) { 117 if(isNaN(animDelay)) { 118 animDelay = 0.5; 119 } 120 var delayNum = animDelay + 's'; 121 $(this).css('-webkit-animation-delay', delayNum) 122 .css('-moz-animation-delay', delayNum) 123 .css('-ms-animation-delay', delayNum) 124 .css('-o-animation-delay', delayNum); 125 } 126 } 127 }); 128 129 $.each($('.anim-content, .animated, .inview, .tween'),function(){ 130 $(this).on('inview',function(event,visible){ 131 if (visible == true) { 132 if(!$(this).hasClass('done')) { 133 $(this).addClass('visible done'); 134 if($(this).hasClass('count-up')) { 135 bpCount(); 136 } 137 } 138 } 139 }); 140 }); 141 } 142} 143 144makansutra.init(); 145 146$(window).scroll(function(event){ 147 makansutra.scroll(); 148}); 149 150$(window).resize(function() { 151 makansutra.resize(); 152}); 153 154function stopVideosOnModal(){ 155 $(".modalvideo iframe").each(function(){ 156 $(this).attr('src',$(this).attr('src')); 157 }); 158} 159 160function openModal(title,video){ 161 stopVideosOnModal(); 162 $(".modalvideo").hide(); 163 164 $('#'+video).show(); 165 $("#modalTitle").html(title); 166 //$("#modalVideo").html(''); 167 //console.log('<iframe id="vid" class="embed-responsive-item vid" src="https://www.youtube.com/embed/'+video+'" frameborder="0" gesture="media" allow="encrypted-media" allowfullscreen></iframe>'); 168} 169 170$(window).load(function() { 171 $('#instafeed img').each(function() {
172 if (!this.complete || typeof this.naturalWidth == "undefined" || this.naturalWidth == 0) { 173 // image was broken, replace with your new image 174 this.src = theme_base_url+'/assets/images/vidthumb.png'; 175 } 176 }); 177}); 178 179$(document).ready(function() { 180 $('.date_field input').each(function(){ 181 $(this).attr('autocomplete',"off"); 182 }); 183 if (Modernizr.touch) { 184 $('html').addClass('bp-touch'); 185 } 186 187 $('.banner-slider').slick({ 188 slidesToShow: 1, 189 slidesToScroll: 1, 190 arrows: true, 191 fade: true, 192 prevArrow:"<a class='prev arrows shadow'><i class='fa fa-angle-left' aria-hidden='true'></i></a", 193 nextArrow:"<a class='next arrows shadow'><i class='fa fa-angle-right' aria-hidden='true'></i></a>", 194 asNavFor: '.thumb-slider' 195 }); 196 197 $('.thumb-slider').slick({ 198 slidesToShow: 7, 199 slidesToScroll: 1, 200 asNavFor: '.banner-slider', 201 dots: false, 202 focusOnSelect: true, 203 slidesToScroll: 1, 204 arrows: false, 205 swipe: true, 206 responsive: [ 207 208 { 209 breakpoint: 991, 210 settings: { 211 slidesToShow: 5 212 } 213 }, 214 { 215 breakpoint: 768, 216 settings: { 217 slidesToShow: 4 218 } 219 }, 220 { 221 breakpoint: 640, 222 settings: { 223 slidesToShow: 3 224 } 225 } 226 ] 227 }); 228 229 $('.sliding-item').slick({ 230 dots: false, 231 swipe: true, 232 slidesToShow: 1, 233 slidesToScroll: 1, 234 autoplay: true, 235 autoplaySpeed: 5000, 236 prevArrow: '<div class="item-nav prev"><i class="fa fa-angle-left" aria-hidden="true"></i></div>', 237 nextArrow: '<div class="item-nav next"><i class="fa fa-angle-right" aria-hidden="true"></i></div>' 238 }); 239 240 $('li.dropdown').hover(function() { 241 $(this).find('.dropdown-menu').stop(true, true).delay(200).fadeIn(500); 242 }, function() { 243 $(this).find('.dropdown-menu').stop(true, true).delay(200).fadeOut(500); 244 }); 245 246 $('.featvid').slick({ 247 slidesToShow: 1, 248 slidesToScroll: 1, 249 arrows: false, 250 fade: true, 251 asNavFor: '.Vidthumb-slider' 252 }); 253 254 $('.Vidthumb-slider').slick({ 255 prevArrow:"<a class='prev arrows'><i class='fa fa-angle-left' aria-hidden='true'></i></a", 256 nextArrow:"<a class='next arrows'><i class='fa fa-angle-right' aria-hidden='true'></i></a>", 257 slidesToShow: 4, 258 slidesToScroll: 1, 259 asNavFor: '.featvid', 260 dots: false, 261 focusOnSelect: true, 262 slidesToScroll: 1, 263 arrows: true, 264 swipe: true, 265 }); 266 267 $('.ins-sl').slick({ 268 slidesToShow: 6, 269 slidesToScroll: 1, 270 focusOnSelect: true, 271 arrows: false, 272 responsive: [ 273 274 { 275 breakpoint: 991, 276 settings: { 277 slidesToShow: 4 278 } 279 }, 280 { 281 breakpoint: 768, 282 settings: { 283 slidesToShow: 4 284 } 285 }, 286 { 287 breakpoint: 640, 288 settings: { 289 slidesToShow: 3 290 } 291 } 292 ] 293 }); 294 295 $('.abt-slider').slick({ 296 prevArrow:"<a class='prev arrows shadow'><i class='fa fa-angle-left' aria-hidden='true'></i></a", 297 nextArrow:"<a class='next arrows shadow'><i class='fa fa-angle-right' aria-hidden='true'></i></a>", 298 slidesToShow: 3, 299 slidesToScroll: 1, 300 dots: true, 301 focusOnSelect: true, 302 slidesToScroll: 1, 303 arrows: true, 304 swipe: true, 305 infinite: true 306 }); 307 308 $('.banquet-slider').slick({ 309 slidesToShow: 1, 310 slidesToScroll: 1, 311 arrows: true, 312 dots: true, 313 autoplay: true, 314 fade: true, 315 prevArrow:"<a class='prev arrows shadow'><i class='fa fa-angle-left' aria-hidden='true'></i></a", 316 nextArrow:"<a class='next arrows shadow'><i class='fa fa-angle-right' aria-hidden='true'></i></a>", 317 }); 318 319 $('.editorial-slider').slick({ 320 slidesToShow: 1, 321 slidesToScroll: 1, 322 arrows: true, 323 fade: true, 324 dots: true, 325 prevArrow:"<a class='prev arrows shadow'><i class='fa fa-angle-left' aria-hidden='true'></i></a", 326 nextArrow:"<a class='next arrows shadow'><i class='fa fa-angle-right' aria-hidden='true'></i></a>" 327 }); 328 329 330 $('.mobile-btn').click(function(event){ 331 $('.menu').animate({ 332 'right': '0' 333 }); 334 $('#main-container').css({opacity : 0.5}, 600, 'easeInExpo') 335 }); 336 337 $('.closeBtn').click(function(event){ 338 $('.menu').animate({ 339 'right': '-100%' 340 }, 300, 'easeInExpo'); 341 $('#main-container').css({opacity : 1}, 600, 'easeInExpo') 342 }); 343 344 /* 345 var videoSrc = $("#modal1 iframe").attr("src"); 346 347 $('#modal1').on('show.bs.modal', function () { // on opening the modal 348 // set the video to autostart 349 $("#modal1 iframe").attr("src", videoSrc+"?autoplay=1"); 350 }); 351 352 $("#modal1").on('hidden.bs.modal', function (e) { // on closing the modal 353 // stop the video 354 $("#modal1 iframe").attr("src", null); 355 }); 356 */ 357 $("#modal1").on('hidden.bs.modal', function (e) { // on closing the modal 358 stopVideosOnModal(); 359 }); 360 361 makansutra.resize(); 362}); 363 364 365 366$(window).load(function() { 367 makansutra.resize(); 368 $('#sbi_images').slick({ 369 slidesToShow: 6, 370 slidesToScroll: 6, 371 dots: true,
372 arrows: false, 373 autoplay: true, 374 prevArrow:"<a class='prev arrows shadow'><i class='fa fa-angle-left' aria-hidden='true'></i></a", 375 nextArrow:"<a class='next arrows shadow'><i class='fa fa-angle-right' aria-hidden='true'></i></a>", 376 responsive: [{ 377 breakpoint: 480, 378 settings: { 379 slidesToShow: 1, 380 slidesToScroll: 1, 381 dots: false 382 } 383 }] 384 }); 385}); 386 387 388// preloader once done 389Pace.on('done', function() { 390 // totally hide the preloader especially for IE 391 setTimeout(function() { 392 $('.pace-inactive').hide(); 393 }, 500); 394 395 $('.loader').fadeOut('slow'); 396 397 makansutra.animation(); 398 makansutra.resize(); 399}); 400 401function changeActiveTo(divname){ 402 //alert(divname); 403 $('.eat-nav').removeClass('active'); 404 $('.eat-nav.'+divname).addClass('active'); 405 $('.eat-containers').hide(); 406 $('#'+divname+'-eat-container').show(); 407}
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.