1(function ($) { 2 // lazy load 3 document.addEventListener("DOMContentLoaded", function () { 4 const observer = new IntersectionObserver( 5 function (entries) { 6 entries.forEach(function (entry) { 7 if (!entry.isIntersecting) { 8 return; 9 } 10 11 const element = entry.target; 12 13 // background-image 14 if (element.classList.contains("lazy-bg")) { 15 element.style.backgroundImage = `url('${element.dataset.bg}')`; 16 } 17 18 // img 19 if (element.classList.contains("lazy-img")) { 20 element.src = element.dataset.src; 21 22 // ÑкÑо викоÑиÑÑовÑÑÑ srcset 23 if (element.dataset.srcset) { 24 element.srcset = element.dataset.srcset; 25 } 26 } 27 28 observer.unobserve(element); 29 }); 30 }, 31 { 32 rootMargin: "200px", 33 }, 34 ); 35 36 document.querySelectorAll(".lazy-bg, .lazy-img").forEach(function (element) { 37 observer.observe(element); 38 }); 39 }); 40 // lazy load end 41 42 $(document).ready(function () { 43 $("body").css("opacity", "1"); 44 45 $(".for-agents-button").on("click", function () { 46 fbq("track", "Lead"); 47 }); 48 49 // feedback popup 50 $(".aside-book-feedback-btn").click(function (e) { 51 e.preventDefault(); 52 $(".feedback-popup-wrapp-consultation").addClass("active"); 53 $(".feedback-popup-consultation").addClass("active"); 54 $(".popup-fill2").fadeIn(300); 55 $("html,body").addClass("disable-scroll"); 56 }); 57 $(document).mouseup(function (e) { 58 var block = $(".feedback-popup-consultation"); 59 if (!block.is(e.target) && block.has(e.target).length === 0) { 60 $(".feedback-popup-consultation").removeClass("active"); 61 $(".feedback-popup-wrapp-consultation").removeClass("active"); 62 $(".popup-fill2").fadeOut(300); 63 $("html,body").removeClass("disable-scroll"); 64 } 65 }); 66 $(".close-popup").click(function () { 67 $(".feedback-popup-consultation").removeClass("active"); 68 $(".feedback-popup-wrapp-consultation").removeClass("active"); 69 $(".popup-fill2").fadeOut(300); 70 $("html,body").removeClass("disable-scroll"); 71 }); 72 // feedback popup end 73 74 $(".wpcf7-form-control-wrap").each(function () { 75 $(this).addClass($(this).attr("data-name")); 76 }); 77 78 setInterval(() => { 79 $(".wpcf7 .wpcf7-form-control-wrap.page-title input").each(function () { 80 $(this).val($("h1").text()); 81 }); 82 $(".wpcf7 .wpcf7-form-control-wrap.page-url input").each(function () { 83 if ($(this).val() == "") { 84 $(this).val(location.href); 85 } 86 }); 87 88 $(".wpcf7 .wpcf7-spinner").each(function () { 89 if ($(this).find(".wpcf7-spinner-icon").length == 0) { 90 $(this).append('<div class="wpcf7-spinner-icon"><div></div><div></div></div>'); 91 } 92 }); 93 }, 1000); 94 95 // form phone 96 $(".wpcf7-form-control-wrap.your-phone input").intlTelInput({ 97 defaultCountry: "ua", 98 preferredCountries: ["ua"], 99 useFullscreenPopup: false, 100 }); 101 102 setTimeout(() => { 103 $(".wpcf7-form-control-wrap.your-phone input").each(function () { 104 if ($(this).val() == "") { 105 if ($(".wpcf7 .intl-tel-input .country-list .country.active .dial-code").length != 0) { 106 $(this).val($(".intl-tel-input .country-list .country.active .dial-code").eq(0).text()); 107 } 108 if ($(".iti-mobile-select").length != 0) { 109 $(this).val($(".iti-mobile-select option:selected").attr("data-dial-code")); 110 } 111 } 112 }); 113 }, 300); 114 115 setTimeout(() => { 116 $(".wpcf7 .intl-tel-input input").each(function () { 117 if ($(this).val() == "") { 118 $(this).val(""); 119 if ($(".wpcf7 .intl-tel-input .country-list .country.active .dial-code").length != 0) { 120 $(this).val($(".wpcf7 .intl-tel-input .country-list .country.active .dial-code").eq(0).text()); 121 } 122 if ($(".iti-mobile-select").length != 0) { 123 $(this).val($(".iti-mobile-select option:selected").attr("data-dial-code")); 124 } 125 } 126 $(".wpcf7 .intl-tel-input input").mask("000 00 000 00000000000"); 127 }); 128 }, 300); 129 $(".wpcf7 .intl-tel-input .country-list .country").click(function () { 130 $(".wpcf7 .intl-tel-input input").unmask(); 131 $(this).parent().parent().parent().parent().find($("input[name=your-phone]")).val(""); 132 if ($(".wpcf7 .intl-tel-input .country-list .country.active .dial-code").length != 0) { 133 $(this).parent().parent().parent().parent().find($("input[name=your-phone]")).val($(this).find(".dial-code").text()); 134 } 135 if ($(".iti-mobile-select").length != 0) { 136 $(this).parent().parent().parent().parent().find($("input[name=your-phone]")).val($(".iti-mobile-select option:selected").attr("data-dial-code")); 137 } 138 $(this) 139 .parent() 140 .parent() 141 .parent() 142 .parent() 143 .find($("input[name=your-phone]")) 144 .mask($(this).find(".dial-code").text() + " 000 000 000 00000000000"); 145 }); 146 147 $(".wpcf7-form input[name='your-phone']").keydown(function (event) { 148 if (event.keyCode == 46 || event.keyCode == 8 || event.keyCode == 9 || event.keyCode == 27 || (event.keyCode == 65 && event.ctrlKey === !0) || (event.keyCode >= 35 && event.keyCode <= 39) || event.keyCode == 32) { 149 return; 150 } else { 151 if ((event.keyCode < 48 || event.keyCode > 57) && (event.keyCode < 96 || event.keyCode > 105)) { 152 event.preventDefault(); 153 } 154 } 155 }); 156 // form phone end 157 158 document.addEventListener( 159 "wpcf7mailsent", 160 function (event) { 161 if (event.detail.contactFormId == 154133) { 162 location.href = $(".feedback-popup-wrapp.feedback-popup-wrapp-consultation").attr("data-link"); 163 } 164 }, 165 false, 166 ); 167 }); 168 $(window).on("load", function () { 169 // language popup 170 $(".language-switcher-popup a").attr("href", $(".main_header__nav .main_header__langs .list li").eq(1).attr("data-value")); 171 setTimeout(() => { 172 $(".language-switcher-popup").fadeIn(300); 173 }, 1500); 174 $(".language-switcher-popup .language-switcher-popup-buttons .language-switcher-popup-close").click(function () { 175 $(".language-switcher-popup").fadeOut(300); 176 }); 177 // language popup end 178 179 $(".main_header__currency").append($(".main_footer .samo_container").clone()); 180 181 if ($(window).width() > 992) { 182 $(".main_header__top .top-bar-contact-wrapp").css("right", $(".main_header__top .socials-col .main_header__socials").outerWidth() + 34); 183 } 184 185 $(window).scroll(function () { 186 if ($(window).scrollTop() > 0) { 187 $(".main_header__top").addClass("fixed"); 188 } else { 189 $(".main_header__top").removeClass("fixed"); 190 } 191 }); 192 193 $(".top-bar-contact-item .mob-show-other-phones").click(function () { 194 $(".top-bar-contact-item a").each(function () { 195 if ($(this).index() != 1) { 196 // $(this).fadeToggle(300); 197 $(this).toggleClass("active"); 198 // setTimeout(function() { 199 $(this).toggleClass("active-item"); 200 // }, 10); 201 } 202 }); 203 $(this).toggleClass("active"); 204 }); 205 206 if ($(window).width() > 992) {
207 $(".main_header__langs .nice-select").mouseover(function () { 208 $(this).addClass("open"); 209 }); 210 211 $(".main_header__langs").mouseleave(function () { 212 $(".main_header__langs .nice-select").trigger("click"); 213 }); 214 } 215 216 // var max_col_height1 = 0; 217 // $('.main_slider .owl-item .slide_title').each(function() { 218 // if ($(this).height() > max_col_height1) { 219 // max_col_height1 = $(this).height(); 220 // } 221 // }); 222 // var max_col_height2 = 0; 223 // $('.main_slider .owl-item .slide_slogan.text-uppercase').each(function() { 224 // if ($(this).height() > max_col_height2) { 225 // max_col_height2 = $(this).height(); 226 // } 227 // }); 228 229 // setTimeout(function() { 230 // if ($(window).width() > 992) { 231 // $(".main_slider__slide .main_slider__slide-text-fill").each(function() { 232 // $(this).height(max_col_height1 + max_col_height2 + 100); 233 // $(this).css("marginTop", ((max_col_height1 + max_col_height2 + 100) / -2) - 24); 234 // }); 235 // } else { 236 // $(".main_slider__slide .main_slider__slide-text-fill").each(function() { 237 // $(this).height(max_col_height1 + max_col_height2 + 150); 238 // $(this).css("marginTop", ((max_col_height1 + max_col_height2 + 150) / -2) - 30); 239 // }); 240 // } 241 // }, 1000); 242 243 // setTimeout(function() { 244 // var max_col_height1 = 0; 245 // $('.main_slider__slide .slide-content-inner').each(function() { 246 // if ($(this).outerHeight() > max_col_height1) { 247 // max_col_height1 = $(this).outerHeight(); 248 // } 249 // }); 250 // $('.main_slider__slide .slide-content-inner').height(max_col_height1); 251 // }, 1000); 252 253 // $(".home-popular-countries-item .home-popular-countries-item-title-after").each(function() { 254 // $(this).outerWidth($(this).parent().outerWidth() - $(this).parent().find("span").outerWidth() - 12); 255 // }); 256 257 $(".offer-countries-list1 li").each(function () { 258 $(".day_offer_on_main_sliders1").append('<div class="slider-wrapp-item owl-carousel owl-theme slider-wrapp-item-index' + $(this).index() + " " + $(this).attr("data-country-slug") + '" data-slider-slug="' + $(this).attr("data-country-slug") + '" data-slider-index="' + $(this).index() + '"></div>'); 259 }); 260 261 setTimeout(function () { 262 var slider_item_slug; 263 $(".day_offer_on_main_sliders1 .slider-wrapp-item").each(function () { 264 slider_item = $(this); 265 slider_item_slug = $(this).attr("data-slider-slug"); 266 $(".day_offer_on_main1 .day-offer-item").each(function () { 267 if ($(this).attr("data-item-country-slug") == slider_item_slug) { 268 $(this).appendTo(slider_item); 269 } 270 }); 271 }); 272 273 $(".day_offer_on_main1 .day-offer-item .day-offer-item-content-thumb img").each(function () { 274 $(this).attr("src", $(this).attr("data-original")); 275 }); 276 277 // wrapp item in block for grid in slide item 278 var counter_offer_item; 279 if ($(window).width() > 1200) { 280 $(".day_offer_on_main_sliders1>div").each(function () { 281 counter_offer_item = 0; 282 $(this) 283 .find(".day-offer-item") 284 .each(function () { 285 $(this).attr("data-index", counter_offer_item); 286 if (counter_offer_item == 0 || counter_offer_item % 6 == 0) { 287 $('<div class="day-offer-item-wrapp"></div>').insertBefore($(this)); 288 } 289 counter_offer_item++; 290 }); 291 }); 292 293 $(".day_offer_on_main_sliders1 .day-offer-item-wrapp").each(function () { 294 if ($(this).next().hasClass("day-offer-item")) { 295 $(this).next().appendTo($(this)); 296 } 297 if ($(this).next().hasClass("day-offer-item")) { 298 $(this).next().appendTo($(this)); 299 } 300 if ($(this).next().hasClass("day-offer-item")) { 301 $(this).next().appendTo($(this)); 302 } 303 if ($(this).next().hasClass("day-offer-item")) { 304 $(this).next().appendTo($(this)); 305 } 306 if ($(this).next().hasClass("day-offer-item")) { 307 $(this).next().appendTo($(this)); 308 } 309 if ($(this).next().hasClass("day-offer-item")) { 310 $(this).next().appendTo($(this)); 311 } 312 }); 313 } else if ($(window).width() > 768) { 314 $(".day_offer_on_main_sliders1>div").each(function () { 315 counter_offer_item = 0; 316 $(this) 317 .find(".day-offer-item") 318 .each(function () { 319 $(this).attr("data-index", counter_offer_item); 320 if (counter_offer_item == 0 || counter_offer_item % 4 == 0) { 321 $('<div class="day-offer-item-wrapp"></div>').insertBefore($(this)); 322 } 323 counter_offer_item++; 324 }); 325 }); 326 327 $(".day_offer_on_main_sliders1 .day-offer-item-wrapp").each(function () { 328 if ($(this).next().hasClass("day-offer-item")) { 329 $(this).next().appendTo($(this)); 330 } 331 if ($(this).next().hasClass("day-offer-item")) { 332 $(this).next().appendTo($(this)); 333 } 334 if ($(this).next().hasClass("day-offer-item")) { 335 $(this).next().appendTo($(this)); 336 } 337 if ($(this).next().hasClass("day-offer-item")) { 338 $(this).next().appendTo($(this)); 339 } 340 }); 341 } else if ($(window).width() < 768) { 342 $(".day_offer_on_main_sliders1>div").each(function () { 343 counter_offer_item = 0; 344 $(this) 345 .find(".day-offer-item") 346 .each(function () { 347 $(this).attr("data-index", counter_offer_item); 348 if (counter_offer_item == 0 || counter_offer_item % 2 == 0) { 349 $('<div class="day-offer-item-wrapp"></div>').insertBefore($(this)); 350 } 351 counter_offer_item++; 352 }); 353 }); 354 355 $(".day_offer_on_main_sliders1 .day-offer-item-wrapp").each(function () { 356 if ($(this).next().hasClass("day-offer-item")) { 357 $(this).next().appendTo($(this)); 358 } 359 if ($(this).next().hasClass("day-offer-item")) { 360 $(this).next().appendTo($(this)); 361 } 362 }); 363 } 364 // wrapp item in block for grid in slide item end 365 366 $(".day_offer_on_main_sliders1>div").owlCarousel({ 367 items: 1, 368 dots: 0, 369 nav: 1, 370 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/day-offer-arrow-left.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/day-offer-arrow-right.svg" alt="">'], 371 loop: 1, 372 margin: 0, 373 stagePadding: 0, 374 autoplay: 0, 375 smartSpeed: 1000, 376 }); 377 378 // set height offer item 379 for (let index = 0; index < $(".day_offer_on_main1 .slider-wrapp-item").length; index++) { 380 // setTimeout(() => { 381 // max_col_height = 0; 382 // $('.day_offer_on_main1 .slider-wrapp-item-index' + index + ' .day-offer-item').each(function() { 383 // if ($(this).outerHeight() > max_col_height) { 384 // max_col_height = $(this).outerHeight(); 385 // } 386 // }); 387 // $('.day_offer_on_main1 .slider-wrapp-item-index' + index + ' .day-offer-item').outerHeight(max_col_height); 388 // }, 300); 389 } 390 391 // set height offer item img 392 // setTimeout(() => { 393 // $('.day_offer_on_main .slider-wrapp-item .day-offer-item .day-offer-item-content-thumb').each(function() { 394 // $(this).outerHeight($(this).parent().outerHeight()); 395 // }); 396 397 // $('.day_offer_on_main .slider-wrapp-item .day-offer-item .day-offer-content-block').each(function() { 398 // $(this).outerHeight($(this).parent().outerHeight()); 399 // }); 400 // }, 400); 401 402 $(".day_offer_on_main1 .slider-wrapp-item").eq(0).addClass("active"); 403 404 $(".day_offer_on_main1 .slider-wrapp-item .owl-nav button img").each(function () { 405 var $img = $(this); 406 var imgID = $img.attr("id"); 407 var imgClass = $img.attr("class"); 408 var imgURL = $img.attr("src"); 409 410 jQuery.get( 411 imgURL, 412 function (data) { 413 var $svg = $(data).find("svg"); 414 if (typeof imgID !== "undefined") { 415 $svg = $svg.attr("id", imgID); 416 } 417 if (typeof imgClass !== "undefined") { 418 $svg = $svg.attr("class", imgClass + " replaced-svg"); 419 } 420 $svg = $svg.removeAttr("xmlns:a"); 421 $img.replaceWith($svg); 422 }, 423 "xml", 424 ); 425 }); 426 427 // $('.news_slider .owl-nav button img').each(function() { 428 // var $img = $(this); 429 // var imgID = $img.attr('id'); 430 // var imgClass = $img.attr('class'); 431 // var imgURL = $img.attr('src'); 432 433 // jQuery.get(imgURL, function(data) { 434 // var $svg = $(data).find('svg'); 435 // if (typeof imgID !== 'undefined') { 436 // $svg = $svg.attr('id', imgID); 437 // } 438 // if (typeof imgClass !== 'undefined') { 439 // $svg = $svg.attr('class', imgClass + ' replaced-svg'); 440 // } 441 // $svg = $svg.removeAttr('xmlns:a'); 442 // $img.replaceWith($svg); 443 444 // }, 'xml'); 445 // }); 446 }, 1000); 447 448 // home excursions tours rebuild 449 $(".offer-countries-list2 li").each(function () { 450 $(".day_offer_on_main_sliders2").append('<div class="slider-wrapp-item owl-carousel owl-theme slider-wrapp-item-index' + $(this).index() + " " + $(this).attr("data-country-slug") + '" data-sli
450der-slug="' + $(this).attr("data-country-slug") + '" data-slider-index="' + $(this).index() + '"></div>'); 451 }); 452 453 setTimeout(function () { 454 var slider_item_slug; 455 $(".day_offer_on_main_sliders2 .slider-wrapp-item").each(function () { 456 slider_item = $(this); 457 slider_item_slug = $(this).attr("data-slider-slug"); 458 $(".day_offer_on_main2 .day-offer-item").each(function () { 459 if ($(this).attr("data-item-country-slug") == slider_item_slug) { 460 // $(this).clone().appendTo(slider_item); 461 $(this).appendTo(slider_item); 462 } 463 }); 464 }); 465 466 $(".day_offer_on_main2 .day-offer-item .day-offer-item-content-thumb img").each(function () { 467 $(this).attr("src", $(this).attr("data-original")); 468 }); 469 470 if ($(window).width() < 788) { 471 $(".day_offer_on_main_sliders2>div").owlCarousel({ 472 items: 1, 473 dots: 0, 474 nav: 1, 475 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 476 loop: 0, 477 margin: 30, 478 stagePadding: 30, 479 autoplay: 0, 480 smartSpeed: 1000, 481 }); 482 } else { 483 $(".day_offer_on_main_sliders2>div").owlCarousel({ 484 items: 1, 485 dots: 0, 486 nav: 1, 487 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 488 loop: 0, 489 margin: 30, 490 stagePadding: 10, 491 autoplay: 0, 492 smartSpeed: 1000, 493 responsive: { 494 100: { 495 items: 1, 496 stagePadding: 25, 497 }, 498 480: { 499 items: 1, 500 stagePadding: 25, 501 }, 502 768: { 503 items: 2, 504 stagePadding: 25, 505 }, 506 992: { 507 items: 4, 508 }, 509 }, 510 }); 511 } 512 513 for (let index = 0; index < $(".day_offer_on_main2 .slider-wrapp-item").length; index++) { 514 var max_col_height = 0; 515 $(".day_offer_on_main2 .slider-wrapp-item-index" + index + " .home_excursions_tour-item .excursion-tour-content-block h3").each(function () { 516 $(this).css("height", "auto"); 517 if ($(this).height() > max_col_height) { 518 max_col_height = $(this).height(); 519 } 520 }); 521 $(".day_offer_on_main2 .slider-wrapp-item-index" + index + " .home_excursions_tour-item .excursion-tour-content-block h3").height(max_col_height + 10); 522 523 max_col_height = 0; 524 $(".day_offer_on_main2 .slider-wrapp-item-index" + index + " .best-price-path").each(function () { 525 if ($(this).outerHeight() > max_col_height) { 526 max_col_height = $(this).outerHeight(); 527 } 528 }); 529 $(".day_offer_on_main2 .slider-wrapp-item-index" + index + " .best-price-path").outerHeight(max_col_height); 530 } 531 532 $(".day_offer_on_main2 .slider-wrapp-item").eq(0).addClass("active"); 533 534 $(".day_offer_on_main2 .slider-wrapp-item .owl-nav button img").each(function () { 535 var $img = $(this); 536 var imgID = $img.attr("id"); 537 var imgClass = $img.attr("class"); 538 var imgURL = $img.attr("src"); 539 540 jQuery.get( 541 imgURL, 542 function (data) { 543 var $svg = $(data).find("svg"); 544 if (typeof imgID !== "undefined") { 545 $svg = $svg.attr("id", imgID); 546 } 547 if (typeof imgClass !== "undefined") { 548 $svg = $svg.attr("class", imgClass + " replaced-svg"); 549 } 550 $svg = $svg.removeAttr("xmlns:a"); 551 $img.replaceWith($svg); 552 }, 553 "xml", 554 ); 555 }); 556 557 // setTimeout(function() { 558 // console.log("1111"); 559 // $('.day_offer_on_main.day_offer_on_main2 .slider-wrapp-item .owl-nav button.owl-next.disabled').click(function() { 560 // console.log("2222"); 561 // $(".offer-countries-list.offer-countries-list2 li a.active").parent().next().trigger("click"); 562 // }); 563 // }, 1000); 564 565 // setInterval(() => { 566 // if ($(".day_offer_on_main.day_offer_on_main2 .slider-wrapp-item.active .owl-nav button.owl-next.disabled").length != 0) { 567 // // console.log("1111"); 568 // setTimeout(() => { 569 // $(".offer-countries-list.offer-countries-list2 li a.active").parent().next().find("a").trigger("click"); 570 // }, 300); 571 // } 572 // }, 10); 573 574 // $('.news_slider .owl-nav button img').each(function() { 575 // var $img = $(this); 576 // var imgID = $img.attr('id'); 577 // var imgClass = $img.attr('class'); 578 // var imgURL = $img.attr('src'); 579 580 // jQuery.get(imgURL, function(data) { 581 // var $svg = $(data).find('svg'); 582 // if (typeof imgID !== 'undefined') { 583 // $svg = $svg.attr('id', imgID); 584 // } 585 // if (typeof imgClass !== 'undefined') { 586 // $svg = $svg.attr('class', imgClass + ' replaced-svg'); 587 // } 588 // $svg = $svg.removeAttr('xmlns:a'); 589 // $img.replaceWith($svg); 590 591 // }, 'xml'); 592 // }); 593 594 // $(".offer-countries-list li").each(function() { 595 // var max_col_height = 0;
596 // $('.slider-wrapp-item[data-slider-index="1"] .day-offer-content-block h3').each(function() { 597 // $(this).css("height", "auto"); 598 // if ($(this).height() > max_col_height) { 599 // max_col_heigh = $(this).height(); 600 // } 601 // }); 602 // $('.slider-wrapp-item[data-slider-index="1"] .day-offer-content-block h3').height(max_col_height); 603 // }); 604 }, 1000); 605 606 // home excursions tours old version 607 if ($(".day_offer_on_main2").length == 0) { 608 $(".excursion-tours-contries-list li").each(function () { 609 $(".excursions_tour_on_main_sliders").append('<div class="slider-wrapp-item owl-carousel owl-theme slider-wrapp-item-index' + $(this).index() + " " + $(this).attr("data-country-slug") + '" data-slider-slug="' + $(this).attr("data-country-slug") + '" data-slider-index="' + $(this).index() + '"></div>'); 610 }); 611 setTimeout(function () { 612 var excursion_tours_slider_item_slug, excursion_tours_slider_item; 613 $(".excursions_tour_on_main_sliders .slider-wrapp-item").each(function () { 614 excursion_tours_slider_item = $(this); 615 excursion_tours_slider_item_slug = $(this).attr("data-slider-slug"); 616 $(".excursions-tour-slider-wrapp .home_excursions_tour-item").each(function () { 617 if ($(this).attr("data-item-country-slug") == excursion_tours_slider_item_slug) { 618 // $(this).clone().appendTo(excursion_tours_slider_item); 619 $(this).appendTo(excursion_tours_slider_item); 620 } 621 }); 622 }); 623 624 // $(".day_offer_on_main .day-offer-item .day-offer-item-content-thumb img").each(function() { 625 // $(this).attr("src", $(this).attr("data-original")); 626 // }); 627 628 var loop_set; 629 if ($(".excursions-tour-slider-wrapp .home_excursions_tour-item").length > 3) { 630 loop_set = 1; 631 } else { 632 loop_set = 0; 633 } 634 if ($(window).width() < 788) { 635 $(".excursions_tour_on_main_sliders>div").owlCarousel({ 636 items: 1, 637 dots: 0, 638 nav: 1, 639 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 640 loop: 0, 641 margin: 30, 642 stagePadding: 30, 643 autoplay: 0, 644 smartSpeed: 1000, 645 }); 646 } else { 647 $(".excursions_tour_on_main_sliders>div").owlCarousel({ 648 items: 1, 649 dots: 0, 650 nav: 1, 651 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 652 loop: 0, 653 margin: 30, 654 stagePadding: 10, 655 autoplay: 0, 656 smartSpeed: 1000, 657 responsive: { 658 100: { 659 items: 1, 660 stagePadding: 25, 661 }, 662 480: { 663 items: 1, 664 stagePadding: 25, 665 }, 666 768: { 667 items: 2, 668 stagePadding: 25, 669 }, 670 992: { 671 items: 4, 672 }, 673 }, 674 }); 675 } 676 677 for (let index = 0; index < $(".excursions_tour_on_main_sliders .slider-wrapp-item").length; index++) { 678 var max_col_height = 0; 679 $(".excursions_tour_on_main_sliders .slider-wrapp-item-index" + index + " .excursion-tour-content-block h3").each(function () { 680 $(this).css("height", "auto"); 681 if ($(this).height() > max_col_height) { 682 max_col_height = $(this).height(); 683 } 684 }); 685 $(".excursions_tour_on_main_sliders .slider-wrapp-item-index" + index + " .excursion-tour-content-block h3").height(max_col_height + 10); 686 687 // max_col_height = 0; 688 // $('.excursions_tour_on_main_sliders .slider-wrapp-item-index' + index + ' .excursion-tour-content-block span.best-price-path').each(function() { 689 // if ($(this).outerHeight() > max_col_height) { 690 // max_col_height = $(this).outerHeight(); 691 // } 692 // }); 693 // $('.excursions_tour_on_main_sliders .slider-wrapp-item-index' + index + ' .excursion-tour-content-block span.best-price-path').outerHeight(max_col_height); 694 } 695 696 $(".excursions_tour_on_main_sliders .slider-wrapp-item").eq(0).addClass("active"); 697 698 $(".excursions_tour_on_main_sliders .slider-wrapp-item .owl-nav button img").each(function () { 699 var $img = $(this); 700 var imgID = $img.attr("id"); 701 var imgClass = $img.attr("class"); 702 var imgURL = $img.attr("src"); 703 704 jQuery.get( 705 imgURL, 706 function (data) { 707 var $svg = $(data).find("svg"); 708 if (typeof imgID !== "undefined") { 709 $svg = $svg.attr("id", imgID); 710 } 711 if (typeof imgClass !== "undefined") { 712 $svg = $svg.attr("class", imgClass + " replaced-svg"); 713 } 714 $svg = $svg.removeAttr("xmlns:a"); 715 $img.replaceWith($svg); 716 }, 717 "xml", 718 ); 719 }); 720 }, 500); 721 // home excursions tours end 722 723 setTimeout(function () { 724 var loop_set; 725 if ($(".excursions-tour-slider-wrapp .home_excursions_tour-item").length > 3) { 726 loop_set = 1; 727 } else { 728 loop_set = 0; 729 } 730 731 if ($(window).width() < 788) { 732 $(".excursions-tour-slider-wrapp").owlCarousel({ 733 items: 1, 734 dots: 0, 735 nav: 1, 736 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 737 loop: loop_set, 738 margin: 30, 739 stagePadding: 30, 740 autoplay: 0, 741 smartSpeed: 1000, 742 }); 743 } else { 744 $(".excursions-tour-slider-wrapp").owlCarousel({ 745 items: 4, 746 dots: 0, 747 nav: 1, 748 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 749 loop: loop_set, 750 margin: 30, 751 stagePadding: 10, 752 autoplay: 0, 753 smartSpeed: 1000, 754 responsive: { 755 100: { 756 items: 1, 757 stagePadding: 25, 758 }, 759 480: { 760 items: 1, 761 stagePadding: 25, 762 }, 763 768: { 764 items: 2, 765 stagePadding: 25, 766 }, 767 992: { 768 items: 4, 769 }, 770 }, 771 }); 772 } 773 774 var max_col_height = 0; 775 $(".excursion-tour-content-block h3").each(function () { 776 $(this).css("height", "auto"); 777 if ($(this).height() > max_col_height) { 778 max_col_height = $(this).height(); 779 } 780 }); 781 $(".excursion-tour-content-block h3").height(max_col_height); 782 783 // max_col_height = 0; 784 // $('.excursion-tour-content-block .best-price-path').each(function() { 785 // $(this).css("height", "auto"); 786 // if ($(this).height() > max_col_height) { 787 // max_col_height = $(this).height(); 788 // } 789 // }); 790 // $('.excursion-tour-content-block .best-price-path').height(max_col_height); 791 792 max_col_height = 0; 793 $(".recommended_on_main .excursion-tour-coutry-title").each(function () { 794 $(this).css("height", "auto"); 795 if ($(this).height() > max_col_height) { 796 max_col_height = $(this).height(); 797 } 798 }); 799 $(".recommended_on_main .excursion-tour-coutry-title").height(max_col_height); 800 801 $(".excursions-tour-slider-wrapp .owl-nav button img").each(function () { 802 var $img = $(this); 803 var imgID = $img.attr("id"); 804 var imgClass = $img.attr("class"); 805 var imgURL = $img.attr("src"); 806 807 jQuery.get( 808 imgURL, 809 function (data) { 810 var $svg = $(data).find("svg"); 811 if (typeof imgID !== "undefined") { 812 $svg = $svg.attr("id", imgID); 813 } 814 if (typeof imgClass !== "undefined") { 815 $svg = $svg.attr("class", imgClass + " replaced-svg"); 816 } 817 $svg = $svg.removeAttr("xmlns:a"); 818 $img.replaceWith($svg); 819 }, 820 "xml", 821 ); 822 }); 823 }, 1000); 824 } 825 // home excursions tours old version end 826 827 $(".offer-countries-list1 li").click(function () { 828 // $(".day_offer_on_main1 .slider-wrapp-item").removeClass("active"); 829 // $(".day_offer_on_main1 .slider-wrapp-item").eq($(this).index()).addClass("active"); 830 $(".day_offer_on_main1 .slider-wrapp-item").fadeOut(0); 831 $(".day_offer_on_main1 .slider-wrapp-item").eq($(this).index()).fadeIn(500); 832 }); 833 834 $(".offer-countries-list1 li").eq(0).trigger("click"); 835 836 $("section.day_offer_on_main.hots_on_main .day_offer_on_main_sliders1").on("mouseenter", function () { 837 $(this).addClass("stop-change-tours"); 838 }); 839 840 $("section.day_offer_on_main.hots_on_main .day_offer_on_main_sliders1").on("mouseleave", function () { 841 $(this).removeClass("stop-change-tours"); 842 }); 843 844 if ($(window).width() > 992) { 845 setInterval(() => { 846 if ($("section.day_offer_on_main.hots_on_main .day_offer_on_main_sliders1.stop-change-tours").length == 0) { 847 if ($(".offer-countries-list1 li>a.active").parent().index() == $(".offer-countries-list1 li").length - 1) { 848 $(".offer-countries-list1 li").eq(0).find("a").trigger("click"); 849 } else { 850 $(".offer-countries-list1 li>a.active").parent().next().find("a").trigger("click"); 851 } 852 } 853 }, 5000); 854 855 var max_col_height = 0; 856 setTimeout(() => { 857 $(".day_offer_on_main .slider-wrapp-item").each(function () { 858 if ($(this).outerHeight() > max_col_height) { 859 max_col_height = $(this).outerHeight(); 860 } 861 }); 862 $(".day_offer_on_main .slider-wrapp-item").outerHeight(max_col_height); 863 }, 1000); 864 865 setTimeout(() => { 866 $(".day_offer_on_main.day_offer_on_main1").css({ 867 maxHeight: $(".day_offer_on_main.day_offer_on_main1").outerHeight(), 868 overflow: "hidden", 869 }); 870 }, 1100); 871 } 872 873 $(".offer-countries-list2 li").click(function () { 874 // $(".day_offer_on_main2 .slider-wrapp-item").removeClass("active"); 875 // $(".day_offer_on_main2 .slider-wrapp-item").eq($(this).index()).addClass("active"); 876 $(".day_offer_on_main2 .slider-wrapp-item").fadeOut(500); 877 $(".day_offer_on_main2 .slider-wrapp-item").eq($(this).index()).fadeIn(500); 878 }); 879 $(".offer-countries-list2 li").eq(0).find("a").addClass("active"); 880 881 var max_col_height = 0; 882 $(".news_on_main .post_item__title").each(function () { 883 $(this).css("height", "auto"); 884 if ($(this).height() > max_col_height) { 885 max_col_height = $(this).height(); 886 } 887 }); 888 $(".news_on_main .post_item__title").height(max_col_height); 889 890 max_col_height = 0; 891 $(".news_on_main .post_item__title>span").each(function () { 892 $(this).css("height", "auto"); 893 if ($(this).outerHeight() > max_col_height) { 894 max_col_height = $(this).outerHeight(); 895 } 896 }); 897 $(".news_on_main .post_item__title>span").outerHeight(max_col_height); 898 899 max_col_height = 0; 900 $(".news_on_main .post_item__title>span>span").each(function () { 901 $(this).css("height", "auto"); 902 if ($(this).outerHeight() > max_col_height) { 903 max_col_height = $(this).outerHeight(); 904 } 905 }); 906 $(".news_on_main .post_item__title>span>span").outerHeight(max_col_height); 907 908 if ($(window).width() < 992) { 909 setTimeout(function () { 910 $(".main_header__nav .main_header__langs .nice-select .list li").appendTo($(".main_header__nav ul")); 911 }, 1000); 912 913 setTimeout(function () { 914 $(".main_header__nav ul li.option").each(function () { 915 $(this).html('<a href="' + $(this).attr("data-value") + '">' + $(this).text() + "</a>"); 916 }); 917 }, 1000); 918 919 $(".main_header__nav ul li.option").click(function () { 920 $(".main_header__nav ul li.option").removeClass("selected"); 921 $(this).addClass("selected"); 922 // location.href = $(this).attr("data-value"); 923 }); 924 } 925 926 var MyIntervalID = setInterval(function () { 927 $(".all-hotels-restyle.all-hotels .aditional-hotel-info ul").each(function () { 928 if ($(this).find("li").length == 0) { 929 $(this).parent().fadeOut(0); 930 } 931 }); 932 }, 300); 933 934 var max_col_height = 0; 935 $(".hotel-benefits ul li").each(function () { 936 if ($(this).outerHeight() > max_col_height) { 937 max_col_height = $(this).outerHeight(); 938 } 939 }); 940 $(".hotel-benefits ul li").outerHeight(max_col_height); 941 942 setTimeout(function () { 943 $(".comments-wrapp h3"
943).html('<i class="far fa-comment"></i>' + $(".comments-wrapp h3").text() + ""); 944 }, 1000); 945 946 $(".comments-wrapp .comments-list").insertAfter($(".comments-wrapp .comment-respond")); 947 948 setTimeout(function () { 949 $(".nice-select > span").each(function () { 950 if ($(this).text() == "ru") { 951 $('<div class="comments-list-title">ÐÑе комменÑаÑии</div>').insertBefore($(".comments-wrapp .comments-list")); 952 } else if ($(this).text() == "ua") { 953 $('<div class="comments-list-title">ÐÑÑ ÐºÐ¾Ð¼ÐµÐ½ÑаÑÑ</div>').insertBefore($(".comments-wrapp .comments-list")); 954 } else if ($(this).text() == "en") { 955 $('<div class="comments-list-title">All comments</div>').insertBefore($(".comments-wrapp .comments-list")); 956 } 957 }); 958 }, 100); 959 960 // country excisions list p tpl section 961 962 setTimeout(function () { 963 $(".country-excisions-list-p-tpl-section .col-md-9 .single-excursion-item .single-excursion-item-image").each(function () { 964 if ($(window).width() > 768) { 965 $(this).outerHeight($(this).next().outerHeight()); 966 } 967 }); 968 }, 500); 969 970 // all news page 971 max_col_height = 0; 972 $(".all-news-page .news-item-content>h3").each(function () { 973 if ($(this).outerHeight() > max_col_height) { 974 max_col_height = $(this).outerHeight(); 975 } 976 }); 977 $(".all-news-page .news-item-content>h3").outerHeight(max_col_height); 978 979 // single escursion tour slider 980 $(".single-excursion-tour-p-tpl-section .col-md-9 .single-excursion-tour-page-content .lSSlideOuter .lSPager.lSGallery li").outerWidth($(".single-excursion-tour-p-tpl-section .col-md-9 .single-excursion-tour-page-content .lSSlideWrapper>.lightSlider .slider-item img").outerWidth() / 4 - 35); 981 982 // country news 983 setTimeout(function () { 984 $(".news-wrapp .news-item-thumb").each(function () { 985 if ($(window).width() > 768) { 986 $(this).outerHeight($(this).next().outerHeight()); 987 } 988 }); 989 }, 500); 990 991 $(".main_header__top").outerWidth($(window).width()); 992 $(window).resize(function () { 993 $(".main_header__top").outerWidth($(window).width()); 994 }); 995 996 $(".other-p-tamplate .accordion-restyle>.card>.card-header").click(function () { 997 $(this).toggleClass("active"); 998 $(this).next().slideToggle(300); 999 }); 1000 $(".other-p-tamplate .accordion-restyle>.card>.card-header").eq(0).trigger("click"); 1001 1002 $(".single-location-location-slider-inner").owlCarousel({ 1003 items: 1, 1004 dots: 0, 1005 nav: 1, 1006 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 1007 loop: 1, 1008 autoplay: 0, 1009 smartSpeed: 1000, 1010 }); 1011 1012 setTimeout(function () { 1013 $(".single-location-location-slider-inner .owl-nav button img").each(function () { 1014 var $img = $(this); 1015 var imgID = $img.attr("id"); 1016 var imgClass = $img.attr("class"); 1017 var imgURL = $img.attr("src"); 1018 1019 jQuery.get( 1020 imgURL, 1021 function (data) { 1022 var $svg = $(data).find("svg"); 1023 if (typeof imgID !== "undefined") { 1024 $svg = $svg.attr("id", imgID); 1025 } 1026 if (typeof imgClass !== "undefined") { 1027 $svg = $svg.attr("class", imgClass + " replaced-svg"); 1028 } 1029 $svg = $svg.removeAttr("xmlns:a"); 1030 $img.replaceWith($svg); 1031 }, 1032 "xml", 1033 ); 1034 }); 1035 }, 1000); 1036 1037 setTimeout(function () { 1038 $(".nice-select > span").each(function () { 1039 if ($(this).text() == "ru") { 1040 } else if ($(this).text() == "ua") { 1041 $(".country-filters .single-country-aside-menu-item a").each(function () { 1042 $(this).attr("href", $(this).attr("href").replace("lyubosvit.com.ua/", "lyubosvit.com.ua/ua/")); 1043 }); 1044 } else if ($(this).text() == "en") { 1045 $(".country-filters .single-country-aside-menu-item a").each(function () { 1046 $(this).attr("href", $(this).attr("href").replace("lyubosvit.com.ua/", "lyubosvit.com.ua/en/")); 1047 }); 1048 } 1049 }); 1050 }, 100); 1051 1052 $(".country-filters .single-country-aside-menu-item.single-country-aside-menu-item-has-sub .sub-menu
1052-title").click(function () { 1053 $(this).parent().toggleClass("active"); 1054 $(this).parent().find(".single-country-aside-sub-menu").slideToggle(300); 1055 $(this).parent().next(".single-country-aside-menu-item-divider").slideToggle(0); 1056 }); 1057 1058 setTimeout(function () { 1059 $(".country-filters .single-country-aside-menu-item a").each(function () { 1060 if ($(this).attr("href") == location.href) { 1061 $(this).addClass("current-menu-item"); 1062 } 1063 if ($(this).hasClass("current-menu-item") && $(this).parent().parent().hasClass("single-country-aside-sub-menu")) { 1064 $(this).parent().parent().parent().find(".sub-menu-title").trigger("click"); 1065 } 1066 }); 1067 }, 1000); 1068 1069 setTimeout(function () { 1070 $(".all-locations .location-item .location-item-img").each(function () { 1071 $(this).outerHeight($(this).next().outerHeight()); 1072 }); 1073 }, 500); 1074 1075 // $(".all-regions-slider-wrapp .region-list li").click(function() { 1076 // location.href = $(this).find("a").attr("href"); 1077 // }); 1078 1079 $(".all-regions-slider-wrapp .region-list li").click(function (e) { 1080 e.preventDefault(); 1081 var cur_loc_tab_link = $(this).find("a").attr("href"); 1082 $(".all-locations .location-item a").each(function () { 1083 if ($(this).attr("href") == cur_loc_tab_link) { 1084 $("html, body").animate( 1085 { 1086 scrollTop: $(this).parent().offset().top - 50, 1087 }, 1088 500, 1089 ); 1090 } 1091 }); 1092 // location.href = $(this).find("a").attr("href"); 1093 }); 1094 1095 setTimeout(function () { 1096 $(".country-single-location-page-content .single-location-location-slider-inner .single-location-location-slider-item .single-location-location-slider-item-img").each(function () { 1097 $(this).outerHeight($(this).next().outerHeight()); 1098 }); 1099 }, 500); 1100 1101 setTimeout(function () { 1102 var max_col_height1 = 0; 1103 $(".single-location-hotels-section .single-location-hotels-grid-item").each(function () { 1104 if ($(this).outerHeight() > max_col_height1) { 1105 max_col_height1 = $(this).outerHeight(); 1106 } 1107 }); 1108 $(".single-location-hotels-section .single-location-hotels-grid-item").outerHeight(max_col_height1); 1109 1110 max_col_height1 = 0; 1111 $(".single-location-hotels-section .single-location-hotels-grid-item .single-location-hotels-grid-item-desc .single-location-hotels-grid-item-desc-title").each(function () { 1112 if ($(this).outerHeight() > max_col_height1) { 1113 max_col_height1 = $(this).outerHeight(); 1114 } 1115 }); 1116 $(".single-location-hotels-section .single-location-hotels-grid-item .single-location-hotels-grid-item-desc .single-location-hotels-grid-item-desc-title").outerHeight(max_col_height1); 1117 1118 max_col_height1 = 0; 1119 $(".single-location-hotels-section .single-location-hotels-grid-item .single-location-hotels-grid-item-desc .single-location-hotels-grid-item-desc-text").each(function () { 1120 if ($(this).outerHeight() > max_col_height1) { 1121 max_col_height1 = $(this).outerHeight(); 1122 } 1123 }); 1124 $(".single-location-hotels-section .single-location-hotels-grid-item .single-location-hotels-grid-item-desc .single-location-hotels-grid-item-desc-text").outerHeight(max_col_height1); 1125 1126 $(".single-location-hotels-section .single-location-hotels-grid-item .single-location-hotels-grid-item-img").each(function () { 1127 $(this).outerHeight($(this).next().outerHeight()); 1128 }); 1129 }, 1000); 1130 1131 $(".single-country-locations-by-resttype-section-slider-inner").owlCarousel({ 1132 items: 1, 1133 dots: 1, 1134 nav: 1, 1135 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 1136 loop: 1, 1137 autoplay: 0, 1138 smartSpeed: 1000, 1139 }); 1140 1141 setTimeout(function () { 1142 $(".single-country-locations-by-resttype-section-sli
1142der-inner .owl-nav button img").each(function () { 1143 var $img = $(this); 1144 var imgID = $img.attr("id"); 1145 var imgClass = $img.attr("class"); 1146 var imgURL = $img.attr("src"); 1147 1148 jQuery.get( 1149 imgURL, 1150 function (data) { 1151 var $svg = $(data).find("svg"); 1152 if (typeof imgID !== "undefined") { 1153 $svg = $svg.attr("id", imgID); 1154 } 1155 if (typeof imgClass !== "undefined") { 1156 $svg = $svg.attr("class", imgClass + " replaced-svg"); 1157 } 1158 $svg = $svg.removeAttr("xmlns:a"); 1159 $img.replaceWith($svg); 1160 }, 1161 "xml", 1162 ); 1163 }); 1164 }, 1000); 1165 1166 setTimeout(function () { 1167 $(".single-country-locations-by-resttype-section-slider-inner .single-country-locations-by-resttype-section-slide-item-img").each(function () { 1168 $(this).outerHeight($(this).next().outerHeight()); 1169 }); 1170 }, 500); 1171 1172 $(".single-country-locations-by-resttype-section-slider-inner .owl-dot").each(function () { 1173 console.log($(this).index()); 1174 }); 1175 1176 // $('.single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button').click(function() { 1177 // $(this).parent().find(".single-country-locations-by-resttype-section-button").removeClass("active"); 1178 // $(this).addClass("active"); 1179 // $(this).parent().parent().parent().find($(".single-country-locations-by-resttype-section-slider-inner .owl-dot").eq($(this).attr("data-item-order"))).trigger("click"); 1180 // }); 1181 1182 if ($(".single-location-cities-section").length == 0 && $(".single-location-hotels-section").length == 0) { 1183 $(".country-single-location-page-content .back-to-all-locations").addClass("single-region-empty-page"); 1184 } 1185 1186 if ($(".single-location-hotels-section").length == 0) { 1187 $(".single-location-cities-section").addClass("single-region-last-block"); 1188 } 1189 1190 $("#regions .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").eq(0).addClass("active"); 1191 1192 // $('#regions .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button').click(function() { 1193 // $(this).parent().find(".single-country-locations-by-resttype-section-button").removeClass("active"); 1194 // $(this).addClass("active"); 1195 // $("#regions .single-country-locations-by-resttype-section-slider-inner .owl-dot").eq($(this).attr("data-item-order")).trigger("click"); 1196 // }); 1197 1198 $("#regions .single-country-locations-by-resttype-section-slider-inner .owl-nav button").click(function () { 1199 $("#regions .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").removeClass("active"); 1200 $("#regions .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").eq($("#regions .owl-dots .owl-dot.active").index()).addClass("active"); 1201 }); 1202 1203 $("#resorts .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").eq(0).addClass("active"); 1204 1205 // $('#resorts .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button').click(function() { 1206 // $(this).parent().find(".single-country-locations-by-resttype-section-button").removeClass("active"); 1207 // $(this).addClass("active"); 1208 // $("#resorts .single-country-locations-by-resttype-section-slider-inner .owl-dot").eq($(this).attr("data-item-order")).trigger("click"); 1209 // }); 1210 1211 $("#resorts .single-country-locations-by-resttype-section-slider-inner .owl-nav button").click(function () { 1212 $("#regions .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").removeClass("active"); 1213 $("#resorts .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").eq($("#resorts .owl-dots .owl-dot.active").index()).addClass("active"); 1214 }); 1215 1216 $("#cities .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").eq(0).addClass("active"); 1217 1218 // $('#cities .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button').click(function() { 1219 // $(this).parent().find(".single-country-locations-by-resttype-section-button").removeClass("active"); 1220 // $(this).addClass("active"); 1221 // $("#cities .single-country-locations-by-resttype-section-sli
1221der-inner .owl-dot").eq($(this).attr("data-item-order")).trigger("click"); 1222 // }); 1223 1224 $("#cities .single-country-locations-by-resttype-section-slider-inner .owl-nav button").click(function () { 1225 $("#cities .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").removeClass("active"); 1226 $("#cities .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").eq($("#cities .owl-dots .owl-dot.active").index()).addClass("active"); 1227 }); 1228 1229 $("#hotels .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").eq(0).addClass("active"); 1230 1231 // $('#hotels .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button').click(function() { 1232 // $(this).parent().find(".single-country-locations-by-resttype-section-button").removeClass("active"); 1233 // $(this).addClass("active"); 1234 // $("#hotels .single-country-locations-by-resttype-section-slider-inner .owl-dot").eq($(this).attr("data-item-order")).trigger("click"); 1235 // }); 1236 1237 $("#hotels .single-country-locations-by-resttype-section-slider-inner .owl-nav button").click(function () { 1238 $("#hotels .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").removeClass("active"); 1239 $("#hotels .single-country-locations-by-resttype-section-buttons .single-country-locations-by-resttype-section-button").eq($("#hotels .owl-dots .owl-dot.active").index()).addClass("active"); 1240 }); 1241 1242 // if ($(".single-location-hotels-section .single-location-hotels-grid-item").length < 4) { 1243 // $(".single-location-hotels-section .single-location-more-hotels-btn").addClass("disable-btn"); 1244 // } 1245 1246 for (var i = 0; i < 4; i++) { 1247 $(".single-location-hotels-section .single-location-hotels-grid-item").eq(i).addClass("active"); 1248 } 1249 1250 // var count_of_active_hotels, count_of_default_hotels; 1251 // count_of_default_hotels = $(".single-location-hotels-section .single-location-hotels-grid-item").length; 1252 // $(".single-location-hotels-section .single-location-more-hotels-btn").click(function(e) { 1253 // e.preventDefault(); 1254 // console.log($(".single-location-hotels-section .single-location-hotels-grid-item.active").length) 1255 // count_of_active_hotels = $(".single-location-hotels-section .single-location-hotels-grid-item.active").length 1256 // for (var i = 0; i < count_of_active_hotels + 4; i++) { 1257 // $(".single-location-hotels-section .single-location-hotels-grid-item").eq(i).addClass("active"); 1258 1259 // $(".single-location-hotels-section .single-location-hotels-grid-item .single-location-hotels-grid-item-img").each(function() { 1260 // $(this).outerHeight($(this).next().outerHeight()); 1261 // }); 1262 // setTimeout(function() { 1263 // if ($(".single-location-hotels-section .single-location-hotels-grid-item.active").length == count_of_default_hotels) { 1264 // $(".single-location-hotels-section .single-location-more-hotels-btn").addClass("disable-btn"); 1265 // $(".single-location-hotels-section").css("paddingBottom", "60px"); 1266 // } 1267 // }); 1268 // } 1269 // }); 1270 1271 $(".contacts-map .contacts-map-added-img img").each(function () { 1272 $(this).outerHeight(($(this).outerWidth() / 4) * 3); 1273 }); 1274 1275 // footer form 1276 $("body").on("focusin", ".sp-form-outer .sp-form.sp-form-regular.sp-form-embed form.sp-element-container div input", function () { 1277 $(this).parent().find("strong").fadeOut(300); 1278 }); 1279 1280 $("body").on("focusout", ".sp-form-outer .sp-form.sp-form-regular.sp-form-embed form.sp-element-container div input", function () { 1281 if ($(this).val() == "") { 1282 $(this).parent().find("strong").fadeIn(300); 1283 } 1284 }); 1285 1286 // education page 1287 if ($(window).width() > 768) { 1288 setTimeout(function () { 1289 $(".education-targets-wrapp .education-tab-target-block .education-tab-target-block-inner-img").each(function () { 1290 $(this).outerHeight($(this).next().outerHeight()); 1291 }); 1292 }, 500); 1293 } 1294 1295 $(".education-tabs .education-tab-item").click(function () { 1296 $(".education-tabs .education-tab-item").removeClass("active"); 1297 $(this).addClass("active"); 1298 $(".education-targets-wrapp .education-tab-target-block").removeClass("active"); 1299 $(".education-targets-wrapp .education-tab-target-block").eq($(this).index()).addClass("active"); 1300 1301 if ($(window).width() > 768) { 1302 setTimeout(function () { 1303 $(".education-targets-wrapp .education-tab-target-block .education-tab-target-block-inner-img").each(function () { 1304 $(this).outerHeight($(this).next().outerHeight()); 1305 }); 1306 }, 500); 1307 } 1308 }); 1309 1310 $(".education-vebinar-popup1").css("marginTop", $(".education-vebinar-popup1").outerHeight() / -2); 1311 1312 $(".call-education-vebinar-popup1").click(function (e) { 1313 e.preventDefault(); 1314 $(".education-vebinar-popup1").addClass("active"); 1315 $(".popup-fill").fadeIn(300); 1316 $("html").addClass("disable-scroll"); 1317 1318 $(".education-vebinar-popup1 .wpcf7-form-control-wrap.your-vebinar input").val($(this).parent().find(".education-tab-target-block-inner-title").text()); 1319 }); 1320 1321 $(".popup-fill, .close-popup").click(function () { 1322 $(".education-vebinar-popup1").removeClass("active"); 1323 $(".popup-fill").fadeOut(300); 1324 $("html").removeClass("disable-scroll"); 1325 }); 1326 1327 // phone mask 1328 var options = { 1329 preferredCountries: ["UA", "RU", "GB"], 1330 }; 1331 1332 $(".education-vebinar-popup .wpcf7-form-control-wrap.your-phone input").intlTelInput(options); 1333 1334 $(".iti--allow-dropdown .iti__country.iti__active").each(function () { 1335 $(this) 1336 .parent() 1337 .parent() 1338 .parent() 1339 .find("input") 1340 .val("+" + $(this).attr("data-dial-code")); 1341 }); 1342 1343 $(".iti--allow-dropdown .iti__country").click(function () { 1344 $(this) 1345 .parent() 1346 .parent() 1347 .parent() 1348 .find("input") 1349 .val("+" + $(this).attr("data-dial-code")); 1350 }); 1351 1352 $(".education-vebinar-popup .wpcf7-form-control-wrap.your-phone input").keydown(function (event) { 1353 // РазÑеÑаем: backspace, delete, tab и escape 1354 if ( 1355 event.keyCode == 46 || 1356 event.keyCode == 8 || 1357 event.keyCode == 9 || 1358 event.keyCode == 27 || 1359 // РазÑеÑаем: Ctrl+A 1360 (event.keyCode == 65 && event.ctrlKey === true) || 1361 // РазÑеÑаем: home, end, влево, впÑаво 1362 (event.keyCode >= 35 && event.keyCode <= 39) 1363 ) { 1364 // ÐиÑего не делаем 1365 return; 1366 } else { 1367 // ÐапÑеÑаем вÑе, кÑоме ÑиÑÑ Ð½Ð° оÑновной клавиаÑÑÑе, а Ñак же Num-клавиаÑÑÑе 1368 if ((event.keyCode < 48 || event.keyCode > 57) && (event.keyCode < 96 || event.keyCode > 105)) { 1369 event.preventDefault(); 1370 } 1371 } 1372 }); 1373 1374 $(".education-vebinar-popup2").css("marginTop", $(".education-vebinar-popup2").outerHeight() / -2); 1375 1376 $(".call-education-vebinar-popup2").click(function (e) { 1377 e.preventDefault(); 1378 $(".education-vebinar-popup2").addClass("active"); 1379 $(".popup-fill").fadeIn(300); 1380 $("html").addClass("disable-scroll"); 1381 1382 $(".education-vebinar-popup2 .wpcf7-form-control-wrap.your-seminar input").val($(this).parent().find(".education-tab-target-block-inner-title").text()); 1383 }); 1384 1385 $(".popup-fill, .close-popup").click(function () { 1386 $(".education-vebinar-popup2").removeClass("active"); 1387 $(".popup-fill").fadeOut(300); 1388 $("html").removeClass("disable-scroll"); 1389 }); 1390 1391 setTimeout(function () { 1392 $(".ajax-loader").each(function () { 1393 $(this).outerHeight($(this).prev().outerHeight()); 1394 $(this).outerWidth($(this).prev().outerWidth()); 1395 $(this).append('<i class="fas fa-spinner fa-spin"></i>'); 1396 $(this).css("marginTop", $(this).prev().outerHeight() * -1); 1397 }); 1398 }, 100); 1399 1400 // bonus plus 1401 if ($(window).width() > 768) { 1402 setTimeout(function () { 1403 $(".bonus-plus-p-container .bonus-plus-block-item .bonus-plus-block-item-img").each(function () { 1404 $(this).outerHeight($(this).next().outerHeight()); 1405 }); 1406 }, 500); 1407 } 1408 1409 // country excursion tours 1410 if ($(window).width() > 768) { 1411 setTimeout(function () { 1412 $(".excursions-courses-conteiner .excursions-courses-item .excursions-courses-item-thumb").each(function () { 1413 $(this).outerHeight($(this).next().outerHeight()); 1414 }); 1415 }, 500); 1416 } 1417 1418 // incoming menu 1419 $(".incoming-aside-menu .incoming-aside-menu-item .incoming-aside-menu-item-open-sub").each(function () { 1420 $(this).css("left", $(this).prev().outerWidth() - 25); 1421 }); 1422 1423 $(".incoming-aside-menu .incoming-aside-menu-item .incoming-aside-menu-item-open-sub").click(function () { 1424 $(this).parent().toggleClass("active"); 1425 $(this).next().slideToggle(300); 1426 }); 1427 1428 setTimeout(function () { 1429 $(".nice-select > span").each(function () { 1430 if ($(this).text() == "ru") { 1431 } else if ($(this).text() == "ua") { 1432 $(".incoming-aside-menu .incoming-aside-menu-item a").each(function () { 1433 $(this).attr("href", $(this).attr("href").replace("lyubosvit.com.ua/", "lyubosvit.com.ua/ua/")); 1434 }); 1435 } else if ($(this).text() == "en") { 1436 $(".incoming-aside-menu .incoming-aside-menu-item a").each(function () { 1437 $(this).attr("href", $(this).attr("href").replace("lyubosvit.com.ua/", "lyubosvit.com.ua/en/")); 1438 }); 1439 } 1440 }); 1441 1442 $(".incoming-aside-menu .incoming-aside-menu-item a").each(function () { 1443 if ($(this).attr("href") == location.href) { 1444 $(this).addClass("current-menu-item"); 1445 } 1446 if ($(this).hasClass("current-menu-item") && $(this).parent().find(".incoming-aside-menu-item-sub-menu").length != 0) { 1447 $(this).parent().find(".incoming-aside-menu-item-open-sub").trigger("click"); 1448 } 1449 if ($(this).hasClass("current-menu-item") && $(this).parent().hasClass("incoming-aside-menu-item-sub-menu")) { 1450 $(this).parent().parent().find(".incoming-aside-menu-item-open-sub").trigger("click"); 1451 } 1452 }); 1453 }, 1000); 1454 1455 // Incoming - Main travel destinations 1456 $(".main-travel-destinations-p-item-slider").lightSlider({ 1457 gallery: true, 1458 item: 1, 1459 loop: true, 1460 slideMargin: 0, 1461 thumbItem: 7, 1462 thumbMargin: 15, 1463 controls: true, 1464 prevHtml: '<i class="fas fa-chevron-left"></i>', 1465 nextHtml: '<i class="fas fa-chevron-right"></i>', 1466 }); 1467 1468 $(".incoming-main-travel-destinations .incoming-main-travel-destinations-tabs .incoming-main-travel-destinations-tab-item").click(function () { 1469 $(".incoming-main-travel-destinations .incoming-main-travel-destinations-tabs .incoming-main-travel-destinations-tab-item").removeClass("active"); 1470 $(this).addClass("active"); 1471 1472 $(".incoming-main-travel-destinations .incoming-main-travel-destinations-content-tabs .incoming-main-travel-destinations-content-tab-item").removeClass("active"); 1473 $(".incoming-main-travel-destinations .incoming-main-travel-destinations-content-tabs .incoming-main-travel-destinations-content-tab-item").eq($(this).index()).addClass("active"); 1474 }); 1475 1476 $(".incoming-main-travel-destinations .incoming-main-travel-destinations-tabs .incoming-main-travel-destinations-tab-item").eq(0).trigger("click"); 1477 1478 // Incoming - ÑкÑкÑÑÑии 1479 setTimeout(function () { 1480 $(".incoming-excursions .single-excursion-item .single-excursion-item-image").each(function () { 1481 if ($(window).width() > 768) { 1482 $(this).outerHeight($(this).next().outerHeight()); 1483 } 1484 }); 1485 }, 500); 1486 1487 // Child camp 1488 if ($(".child-camp-filter-block").length != 0) { 1489 function singleCountryDublValues(el) { 1490 $(el).each(function () { 1491 $(el + ':contains("' + $(this).text() + '"):gt(0)').addClass("dubl"); 1492 }); 1493 } 1494 singleCountryDublValues(".single-country-regions-filter li"); 1495 singleCountryDublValues(".single-country-spec-filter li"); 1496 singleCountryDublValues(".single-country-age-filter li"); 1497 } 1498 1499 // child camp filter 1500 1501 $(".accordion-child-camp .card .card-header").eq(0).trigger("click"); 1502 1503 var max_col_height = 0; 1504 $(".child-camp-filter-block .child-camp-filter-block-title").each(function () { 1505 $(this).css("height", "auto"); 1506 if ($(this).height() > max_col_height) { 1507 max_col_height = $(this).height(); 1508 } 1509 }); 1510 $(".child-camp-filter-block .child-camp-filter-block-title").height(max_col_height); 1511 1512 max_col_height = 0; 1513 $(".hotels_page .hotels-select-title").each(function () { 1514 $(this).css("height", "auto"); 1515 if ($(this).height() > max_col_height) { 1516 max_col_height = $(this).height(); 1517 } 1518 }); 1519 $(".hotels_page .hotels-select-title").height(max_col_height); 1520 1521 $(".child-camp-filter-block .single-country-spec-filter-current").click(function () { 1522 $(this).toggleClass("open"); 1523 $(this).parent().toggleClass("open"); 1524 }); 1525 1526 $(".single-country-spec-filter li").click(function () { 1527 $(".single-country-spec-filter-current").text($(this).text()); 1528 $(".child-camp-filter-block .single-country-spec-filter-current").trigger("click"); 1529 }); 1530 1531 $(".child-camp-filter-block .single-country-age-filter-current").click(function () { 1532 $(this).toggleClass("open"); 1533 $(this).parent().toggleClass("open"); 1534 }); 1535 1536 $(".single-country-age-filter li").click(function () { 1537 $(".single-country-age-filter-current").text($(this).text()); 1538 $(".child-camp-filter-block .single-country-age-filter-current").trigger("click"); 1539 }); 1540 1541 var cur_camp_reg, active_spec, active_age; 1542 $(".single-country-regions-filter li").click(function () { 1543 if ($(this).index() != 0) { 1544 cur_camp_reg = $(this).text(); 1545 $(".child-camp-items-block .child-camp-item .hotel-region-name").each(function () { 1546 if ($(this).text() == cur_camp_reg) { 1547 $(this).parent().parent().addClass("child-camp-item-match-region"); 1548 } else { 1549 $(this).parent().parent().removeClass("child-camp-item-match-region"); 1550 } 1551 }); 1552 1553 // check active spec 1554 // $('.child-camp-items-block .child-camp-item.child-cam
1554p-item-match-region .hotel-spec-value').each(function() { 1555 // active_spec = $(this).text(); 1556 // $('.single-country-spec-filter li').each(function() { 1557 // if ($(this).index() != 0) { 1558 // if ($(this).text() == active_spec) { 1559 // $(this).addClass("active"); 1560 // } else { 1561 // $(this).addClass("not-active"); 1562 // } 1563 // } 1564 // }); 1565 // }); 1566 1567 // $('.child-camp-items-block .child-camp-item.child-camp-item-match-region .hotel-age-value').each(function() { 1568 // active_age = $(this).text(); 1569 1570 // }); 1571 } else { 1572 $(".child-camp-items-block .child-camp-item").addClass("child-camp-item-match-region"); 1573 // $('.single-country-spec-filter li').removeClass("active not-active"); 1574 } 1575 }); 1576 1577 $(".single-country-spec-filter li").click(function () { 1578 if ($(this).index() != 0) { 1579 cur_camp_reg = $(this).text(); 1580 $(".child-camp-items-block .child-camp-item .hotel-spec-value").removeClass("child-camp-item-match-spec child-camp-item-dismatch-spec"); 1581 $(".child-camp-items-block .child-camp-item .hotel-spec-value").each(function () { 1582 if ($(this).text() == cur_camp_reg) { 1583 $(this).parent().parent().parent().addClass("child-camp-item-match-spec"); 1584 } else { 1585 $(this).parent().parent().parent().addClass("child-camp-item-dismatch-spec"); 1586 } 1587 }); 1588 } else { 1589 $(".child-camp-items-block .child-camp-item .hotel-spec-value").removeClass("child-camp-item-match-spec child-camp-item-dismatch-spec"); 1590 } 1591 }); 1592 1593 $(".single-country-age-filter li").click(function () { 1594 if ($(this).index() != 0) { 1595 cur_camp_reg = $(this).text(); 1596 $(".child-camp-items-block .child-camp-item .hotel-age-value").removeClass("child-camp-item-match-age child-camp-item-dismatch-age"); 1597 $(".child-camp-items-block .child-camp-item .hotel-age-value").each(function () { 1598 if ($(this).text() == cur_camp_reg) { 1599 $(this).parent().parent().parent().addClass("child-camp-item-match-age"); 1600 } else { 1601 $(this).parent().parent().parent().addClass("child-camp-item-dismatch-age"); 1602 } 1603 }); 1604 } else { 1605 $(".child-camp-items-block .child-camp-item .hotel-age-value").removeClass("child-camp-item-match-age child-camp-item-dismatch-age"); 1606 } 1607 }); 1608 1609 var hotel_name_to_target; 1610 var hotel_name_to_search; 1611 var pos = 0; 1612 $("#hotel_title").keyup(function () { 1613 $(".child-camp-items-block .child-camp-item").removeClass("match-text dismatch-text"); 1614 hotel_name_to_target = $(this).val(); 1615 hotel_name_to_target = hotel_name_to_target.toLowerCase(); 1616 $(".child-camp-items-block .child-camp-item .country_title>span").each(function () { 1617 hotel_name_to_search = $(this).text(); 1618 if (hotel_name_to_search.indexOf(hotel_name_to_target) != -1) { 1619 $(this).parent().parent().parent().parent().addClass("match-text").removeClass("dismatch-text"); 1620 } else { 1621 $(this).parent().parent().parent().parent().removeClass("match-text").addClass("dismatch-text"); 1622 } 1623 }); 1624 }); 1625 1626 setTimeout(function () { 1627 $(".child-camp-items-block .child-camp-item .hotel-thubnail-wrapp .hotel-thubnail").each(function () { 1628 $(this).height($(this).parent().parent().height()); 1629 }); 1630 }, 1000); 1631 1632 $(".child-camp-items-block .child-camp-item .country_title span.hidden-lower-title").each(function () { 1633 var str = $(this).text(); 1634 var res = str.toLowerCase(); 1635 $(this).text(res); 1636 }); 1637 1638 // single country main page tours 1639 1640 setTimeout(function () { 1641 $(".single_country__info-content-wrapp>.single_country__info").attr("origin-height", $(".single_country__info-content-wrapp>.single_country__info").outerHeight() + 11); 1642 $(".single_country__info-content-wrapp>.single_country__info").outerHeight($(".single_country__info-content-wrapp").prev().outerHeight()); 1643 }, 1000); 1644 1645 $(".single_country__info-content-more-btn").click(function () { 1646 if (!$(".single_country__info-content-wrapp>.single_country__info").hasClass("open")) { 1647 $(".single_country__info-content-wrapp>.single_country__info").animate( 1648 { 1649 height: $(".single_country__info-content-wrapp>.single_country__info").attr("origin-height"), 1650 }, 1651 300, 1652 ); 1653 } else { 1654 $(".single_country__info-content-wrapp>.single_country__info").animate( 1655 { 1656 height: $(".single_country__info-content-wrapp").prev().outerHeight(), 1657 }, 1658 300, 1659 ); 1660 } 1661 $(".single_country__info-content-wrapp>.single_country__info").toggleClass("open"); 1662 }); 1663 1664 if ($(".single-country-choosen-excursion-tours").length != 0) { 1665 setTimeout(function () { 1666 var max_col_height = 0; 1667 $(".single-country-choosen-excursion-tours .excursion-tour-content-block h3").each(function () { 1668 $(this).css("height", "auto"); 1669 if ($(this).height() > max_col_height) { 1670 max_col_height = $(this).height(); 1671 } 1672 }); 1673 $(".single-country-choosen-excursion-tours .excursion-tour-content-block h3").height(max_col_height); 1674 1675 max_col_height = 0; 1676 $(".single-country-choosen-excursion-tours .excursion-tour-content-block .best-price-path").each(function () { 1677 $(this).css("height", "auto"); 1678 if ($(this).height() > max_col_height) { 1679 max_col_height = $(this).height(); 1680 } 1681 }); 1682 $(".single-country-choosen-excursion-tours .excursion-tour-content-block .best-price-path").height(max_col_height - 20); 1683 1684 max_col_height = 0; 1685 $(".single-country-choosen-excursion-tours .recommended_on_main .excursion-tour-coutry-title").each(function () { 1686 $(this).css("height", "auto"); 1687 if ($(this).height() > max_col_height) { 1688 max_col_height = $(this).height(); 1689 } 1690 }); 1691 $(".single-country-choosen-excursion-tours .recommended_on_main .excursion-tour-coutry-title").height(max_col_height); 1692 1693 max_col_height = 0; 1694 $(".single-country-choosen-excursion-tours .day-offer-item .day-offer-content-block>.best-price-path").each(function () { 1695 if ($(this).outerHeight() > max_col_height) { 1696 max_col_height = $(this).outerHeight(); 1697 } 1698 }); 1699 $(".single-country-choosen-excursion-tours .day-offer-item .day-offer-content-block>.best-price-path").outerHeight(max_col_height); 1700 }, 1100); 1701 } 1702 1703 setTimeout(function () { 1704 var loop_set; 1705 if ($(".single-country-choosen-excursion-tours .home_excursions_tour-item").length > 3) { 1706 loop_set = 1; 1707 } else { 1708 loop_set = 0; 1709 } 1710 1711 if ($(window).width() < 788) { 1712 $(".single-country-choosen-excursion-tours").owlCarousel({ 1713 items: 1, 1714 dots: 0, 1715 nav: 1, 1716 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 1717 loop: loop_set, 1718 margin: 10, 1719 stagePadding: 5, 1720 autoplay: 0, 1721 smartSpeed: 1000, 1722 }); 1723 } else { 1724 $(".single-country-choosen-excursion-tours").owlCarousel({ 1725 items: 4, 1726 dots: 0, 1727 nav: 1, 1728 navText: ['<img class="" src="/wp-content/themes/lubosvit/assets/img/left-arrow.svg" alt="">', '<img class="" src="/wp-content/themes/lubosvit/assets/img/right-arrow.svg" alt="">'], 1729 loop: loop_set, 1730 margin: 30, 1731 stagePadding: 10, 1732 autoplay: 0, 1733 smartSpeed: 1000, 1734 responsive: { 1735 100: { 1736 items: 1, 1737 stagePadding: 25, 1738 }, 1739 480: { 1740 items: 1, 1741 stagePadding: 25, 1742 }, 1743 768: { 1744 items: 2, 1745 stagePadding: 25, 1746 }, 1747 992: { 1748 items: 2, 1749 }, 1750 1200: { 1751 items: 4, 1752 }, 1753 }, 1754 }); 1755 } 1756 1757 setTimeout(function () { 1758 $(".single-country-choosen-excursion-tours .owl-nav button img").each(function () { 1759 var $img = $(this); 1760 var imgID = $img.attr("id"); 1761 var imgClass = $img.attr("class"); 1762 var imgURL = $img.attr("src"); 1763 1764 jQuery.get( 1765 imgURL, 1766 function (data) { 1767 var $svg = $(data).find("svg"); 1768 if (typeof imgID !== "undefined") { 1769 $svg = $svg.attr("id", imgID); 1770 } 1771 if (typeof imgClass !== "undefined") { 1772 $svg = $svg.attr("class", imgClass + " replaced-svg"); 1773 } 1774 $svg = $svg.removeAttr("xmlns:a"); 1775 $img.replaceWith($svg); 1776 }, 1777 "xml", 1778 ); 1779 }); 1780 }, 1000); 1781 }, 1000); 1782 1783 // set single hotel video size 1784 if ($(window).width() > 767) { 1785 setInterval(() => { 1786 $(".single-hotel-content-container video, .single-hotel-content-container .mejs-video").each(function () { 1787 $(this).outerHeight(($(this).outerWidth() / 16) * 9); 1788 }); 1789 }, 1); 1790 } 1791 1792 // single hotel descr tabs main image 1793 $(".single_hotel__tab_content .tab-pane").each(function () { 1794 if ($(this).find(".number_type_img_wrapp").length == 0) { 1795 if ($(this).find(".number_type_descr_wrapp img").length != 0) { 1796 $('<img src="' + $(this).find(".number_type_descr_wrapp img").eq(0).attr("src") + '" alt="" class="number_type_img_wrapp">').insertBefore($(this).find(".number_type_descr_wrapp")); 1797 } 1798 } 1799 }); 1800 1801 // set photogallery 1802 setTimeout(() => { 1803 // single hotel 1804 $(".photogallery-gallery-hidden1").lightGallery({ 1805 thumbnail: true, 1806 animateThumb: true, 1807 showThumbByDefault: true, 1808 download: false, 1809 }); 1810 1811 var current_img; 1812 $(".single-hotel-slider-container .lSSlideWrapper img").click(function () { 1813 current_img = $(this).attr("src"); 1814 $(".photogallery-gallery-hidden1 a").each(function () { 1815 if ($(this).attr("href") == current_img) { 1816 $(this).trigger("click"); 1817 } 1818 }); 1819 }); 1820 1821 // single hotel numbers types 1822 $(".photogallery-gallery-hidden1_1").lightGallery({ 1823 thumbnail: true, 1824 animateThumb: true, 1825 showThumbByDefault: true, 1826 download: false, 1827 }); 1828 1829 $(".number_type_img_wrapp.single-hotel-numbers-type-slider img").click(function () { 1830 current_img = $(this).attr("original-src"); 1831 console.log(current_img); 1832 $(".photogallery-gallery-hidden1_1 a").each(function () { 1833 if ($(this).attr("href") == current_img) { 1834 $(this).trigger("click"); 1835 } 1836 }); 1837 }); 1838 1839 // single country, incoming 1840 $(".photogallery-gallery-hidden2").lightGallery({ 1841 thumbnail: true, 1842 animateThumb: true, 1843 showThumbByDefault: true, 1844 download: false, 1845 }); 1846 1847 $(".single-country-galery.lightSlider img").click(function () { 1848 current_img = $(this).attr("original-src"); 1849 console.log(current_img); 1850 $(".photogallery-gallery-hidden2 a").each(function () { 1851 if ($(this).attr("href") == current_img) { 1852 $(this).trigger("click"); 1853 } 1854 }); 1855 }); 1856 1857 // single incoming travel destinations 1858 $(".photogallery-gallery-hidden3").lightGallery({ 1859 thumbnail: true, 1860 animateThumb: true, 1861 showThumbByDefault: true, 1862 download: false, 1863 }); 1864 1865 $(".main-travel-destinations-p-item-slider.lightSlider img").click(function () { 1866 current_img = $(this).attr("original-src"); 1867 console.log(current_img); 1868 $(".photogallery-gallery-hidden3 a").each(function () { 1869 if ($(this).attr("href") == current_img) { 1870 $(this).trigger("click"); 1871 } 1872 }); 1873 }); 1874 1875 // single excursion 1876 $(".photogallery-gallery-hidden4").lightGallery({ 1877 thumbnail: true, 1878 animateThumb: true, 1879 showThumbByDefault: true, 1880 download: false, 1881 }); 1882 1883 $(".excorsion-tour-slider.lightSlider img").click(function () { 1884 current_img = $(this).attr("original-src"); 1885 console.log(current_img); 1886 $(".photogallery-gallery-hidden4 a").each(function () { 1887 if ($(this).attr("href") == current_img) { 1888 $(this).trigger("click"); 1889 } 1890 }); 1891 }); 1892 }, 400); 1893 1894 // check 404 page 1895 // if ($(".error-page").length != 0) { 1896 // $(".location-page-header").css("background-image", "url(/wp-content/uploads/2018/06/d
1896af063bbb8e989734d5925256d83a589.jpg)"); 1897 // $(".location-page-header .page_title").text("СÑÑаниÑа не найдена"); 1898 // } 1899 }); 1900})(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.