PageSourceSearch

https://novabydova.com.ua/js/scripts.js?v=1745958774

js novabydova.com.ua collected 2026-10-06 21:54:08 UTC 19,693 bytes, 740 lines download raw bytes

1//  different select
2function createByJson() {
3    var jsonData = [];
4    $("#byjson").msDropDown({byJson:{data:jsonData, name:'payments2'}}).data("dd");
5}
6$(document).ready(function(e) {
7    //no use
8    try {
9        var pages = $("#pages").msDropdown({on:{change:function(data, ui) {
10                    var val = data.value;
11                    if(val!="")
12                        window.location = val;
13                }}}).data("dd");
14
15        var pagename = document.location.pathname.toString();
16        pagename = pagename.split("/");
17        pages.setIndexByValue(pagename[pagename.length-1]);
18        $("#ver").html(msBeautify.version.msDropdown);
19    } catch(e) {
20        //console.log(e);
21    }
22
23    $("#ver").html(msBeautify.version.msDropdown);
24
25    //convert
26    $(".select-language select").msDropdown({roundedBorder:false});
27    createByJson();
28    $("#tech").data("dd");
29});
30function showValue(h) {
31    console.log(h.name, h.value);
32}
33$("#tech").change(function() {
34    console.log("by jquery: ", this.value);
35});
36// end different select
37
38//stylish select
39jQuery(function($){
40    // $('.select-language select').sSelect({ddMaxHeight: '150px'});
41    $('.select-language select').change(function(){  	window.location.href = $('.select-language select').getSetSSValue();  });
42});
43jQuery(function($){
44    $('.white-select select, .small-select select').niceSelect();
45});
46//end stylish select
47
48// checkbox  and radio
49jQuery(function($){
50    $('input[type=radio], input[type=checkbox]').iCheck();
51});
52// end checkbox and radio
53
54// carousel
55jQuery(function($){
56
57    $('.carousel').owlCarousel({
58        autoplay: true,
59        loop:true,
60        margin:10,
61        nav: true,
62        autoplayHoverPause: true,
63        smartSpeed: 1500,
64        autoplaySpeed : 1500,
65        animateOut: 'fadeOut',
66        animateIn: 'flipIn',
67        responsive:{
68            0:{
69                items:1
70            },
71            600:{
72                items:1
73            },
74            1000:{
75                items:1
76            }
77        }
78    });
79
80    $('.carousel-2').owlCarousel({
81        smartSpeed: 2000,
82        loop:true,
83        margin:0,
84        nav: true,
85        responsive:{
86            0:{
87                items:1
88            },
89            767:{
90                items:2
91            },
92            959:{
93                items:2
94            },
95            1023:{
96                items:2
97            }
98        }
99    });
100
101    $('.carousel-20').owlCarousel({
102        smartSpeed: 2000,
103        loop:true,
104        margin:10,
105        nav: true,
106        animateOut: 'fadeOut',
107        animateIn: 'flipIn',
108        responsive:{
109            0:{
110                items:1
111            },
112            767:{
113                items:2
114            },
115            959:{
116                items:2
117            },
118            1023:{
119                items:2
120            }
121        }
122    });
123    if (window.screen.width <= 768) {
124        $('.carousel-3').owlCarousel({
125            loop: true,
126            margin: 10,
127            nav: false,
128            autoplay: true,
129            autoplayHoverPause: true,
130            autoplayTimeout: 10000,
131            autoplaySpeed: 10000,
132            autoplayDelay: false,
133            autoplayHoverPause: false,
134            animateOut: 'fadeOut',
135            animateIn: 'flipIn',
136            slideTransition: 'linear',
137            responsive: {
138                0: {
139                    items: 1,
140                },
141            }
142        });
143        $('.carousel-4, .carousel-5').owlCarousel({
144            loop:true,
145            margin:10,
146            nav: false,
147            autoplay: true,
148            autoplayHoverPause: true,
149            autoplayTimeout : 10000,
150            autoplaySpeed : 10000,
151            autoplayDelay: false,
152            autoplayHoverPause:false,
153            animateOut: 'fadeOut',
154            animateIn: 'flipIn',
155            slideTransition: 'linear',
156            responsive:{
157                0:{
158                    items:1,
159                },
160            }
161        });
162    }else{
163        $('.carousel-3').owlCarousel({
164            loop:true,
165            margin:10,
166            nav: false,
167            autoplay: true,
168            autoplayHoverPause: true,
169            autoplayTimeout : 10000,
170            autoplaySpeed : 10000,
171            autoplayDelay: false,
172            autoplayHoverPause:false,
173            animateOut: 'fadeOut',
174            animateIn: 'flipIn',
175            slideTransition: 'linear',
176            responsive:{
177                0:{
178                    items:1,
179                },
180                768:{
181                    items:2
182                },
183                959:{
184                    items:2
185                },
186                1023:{
187                    items:2
188                }
189            }
190        });
191        $('.carousel-4, .carousel-5').owlCarousel({
192            loop:true,
193            margin:10,
194            nav: false,
195            autoplay: true,
196            autoplayHoverPause: true,
197            autoplayTimeout : 10000,
198            autoplaySpeed : 10000,
199            autoplayDelay: false,
200            autoplayHoverPause:false,
201            animateOut: 'fadeOut',
202            animateIn: 'flipIn',
203            slideTransition: 'linear',
204            responsive:{
205                0:{
206                    items:1,
207                },
208                768:{
209                    items:2
210                },
211                959:{
212                    items:2
213                },
214                1023:{
215                    items:2
216                }
217            }
218        });
219    }
220
221    $('.carousel-advantages').owlCarousel({
222        loop:true,
223        margin:10,
224        nav: false,
225        autoplay: true,
226        autoplayHoverPause: true,
227        autoplayTimeout : 10000,
228        autoplaySpeed : 10000,
229        autoplayDelay: false,
230        autoplayHoverPause:false,
231        animateOut: 'fadeOut',
232        animateIn: 'flipIn',
233        slideTransition: 'linear',
234        responsive:{
235            0:{
236                items:1
237            },
238        }
239    });
240    $('.carousel-6').owlCarousel({
241        autoplay: false,
242        autoplayHoverPause: true,
243        loop:true,
244        margin:10,
245        nav: true,
246        smartSpeed: 2000,
247        animateOut: 'fadeOut',
248        animateIn: 'flipIn',
249        responsive:{
250            0:{
251                items:1
252            },
253            600:{
254                items:1
255            },
256            1000:{
257                items:1
258            }
259        }
260    });
261
262    $('.carousel-video').owlCarousel({
263        items: 1,
264        autoPlay: false,
265        stopOnHover: true,
266        center: true,
267        navigation: true,
268        pagination: false,
269        autoHeight: true,
270        goToFirstSpeed: 1300,
271        singleItem: true,
272        responsive: true,
273        responsiveRefreshRate: 200,
274        responsiveBaseWidth: window,
275        videoWidth: false, // Default false; Type: Boolean/Number
276        videoHeight: false, // Default false; Type: Boolean/Number
277        video: true,
278        animateOut: 'fadeOut',
279        animateIn: 'flipIn',
280        onTranslate: function() {
281            $('.owl-item').find('video').each(function() {
282                this.pause();
283            });
284        }
285    });
286    $('.carousel-7').owlCarousel({
287        loop:true,
288        margin: 0,
289        nav: true,
290        responsive:{
291            0:{
292                items:1
293            },
294            768:{
295                items:2
296            },
297            1000:{
298                items:3
299            }
300        }
301    });
302
303    $('.carousel-8').owlCarousel({
304        loop:false,
305        margin: 25,
306        nav: true,
307        responsive:{
308            0:{
309                items:1
310            },
311            768:{
312                items:2
313            },
314            1000:{
315                items:2
316            }
317        }
318    });
319
320});
321
322// end carousel
323
324//placeholder ie
325$(document).ready(function() {
326    /* Placeholder for IE */
327    if($.browser.msie) { // Условие для вызова только в IE
328        $("form").find("input[type='text']").each(function() {
329            var tp = $(this).attr("placeholder");
330            $(this).attr('value',tp).css('color','#A9A9A9');
331        }).focusin(function() {
332            var val = $(this).attr('placeholder');
333            if($(this).val() == val) {
334                $(this).attr('value','').css('color','#747b80');
335            }
336        }).focusout(function() {
337            var val = $(this).attr('placeholder');
338            if($(this).val() == "") {
339                $(this).attr('value', val).css('color','#A9A9A9');
340            }
341        });
342        /* Protected send form */
343        $("form").submit(function() {
344            $(this).find("input[type='text']").each(function() {
345                var val = $(this).attr('placeholder');
346                if($(this).val() == val) {
347                    $(this).attr('value','');
348                }
349            })
350        });
351    }
352});
353//end placeholder ie
354
355//main menu
356$(function() {
357    menuOpened = false;
358    var userWidth = window.innerWidth;
359    var body = document.body;
360    let button = document.getElementById("mainMenuBtn");
361    let sideMenu = document.getElementById("sideMenu");
362    let hiddenMenu = document.getElementById("hiddenMenu");
363
364    let closeMenu = function () {
365        button.classList.remove("menu-btn--active");
366        hiddenMenu.classList.remove("nav--active");
367        if (userWidth < 768) {
368            body.style.overflow = "auto";
369        }
370        menuOpened = false;
371    };
372    let openMenu = function () {
373        button.classList.add("menu-btn--active");
374        hiddenMenu.classList.add("nav--active");
375        if (userWidth < 768) {
376            setTimeout(function () {
377                body.style.overflow = "hidden";
378            }, 200);
379        }
380        menuOpened = true
381    };
382    if (userWidth > 768) {
383        button.addEventListener("mouseover", function () {
384            if (!menuOpened) {
385                openMenu();
386            } else {
387                closeMenu();
388            }
389        });
390    }
391    button.addEventListener("click", function () {
392        if (!menuOpened) {
393            openMenu();
394        } else {
395            closeMenu();
396        }
397    });
398    window.addEventListener("mouseover", function (ev) {
399        let targetEl = ev.target.closest("#hiddenMenu") || ev.target.closest("#mainMenuBtn");
400        if (targetEl == null && menuOpened) {
401            closeMenu();
402        }
403    });
404    sideMenu.addEventListener("mouseover", function () {
405        if (!menuOpened) {
406            button.classList.add("menu-btn--active");
407            hiddenMenu.classList.add("nav--active");
408            menuOpened = true;
409        } else {
410            return
411        }
412    });
413    hiddenMenu.addEventListener("mouseout",function (ev) {
414        if(ev.clientX > 315){
415            closeMenu();
416        }
417    })
418
419});
420//end main menu
421
422// main menu 2
423jQuery(function($){
424    $(window).scroll(function() {
425        var scroll = $(window).scrollTop();
426        if (scroll >= 70) {
427            $(".page").addClass("active");
428        }
429        if (scroll <= 70) {
430            $(".page").removeClass("active");
431        }
432    });
433});
434// end main menu 2
435
436// project action hover
437jQuery(function($){
438    $('a.action').hover(function() {
439        $(this).closest('.project-box').addClass('action-on');
440    }, function() {
441        $(this).closest('.project-box').removeClass('action-on');
442    });
443});
444// end project action hover
445
446// tabs
447$(document).ready(function(){
448
449    $('.tab-link').click(function(){
450        var tab_id = $(this).attr('data-tab');
451
452        $('.tab-link').removeClass('current');
453        $('.inner-tab').removeClass('current');
454
455        $(this).addClass('current');
456        $("#"+tab_id).addClass('current');
457    })
458
459    $('.tab-link-2').click(function(){
460        var tab_id = $(this).attr('data-tab');
461
462        $('.tab-link-2').removeClass('current');
463        $('.inner-tab-2').removeClass('current');
464
465        $(this).addClass('current');
466        $("#"+tab_id).addClass('current');
467    })
468
469    $('.tab-link-3').click(function(){
470        var tab_id = $(this).attr('data-tab');
471
472        $('.tab-link-3').removeClass('current');
473        $('.inner-tab-3').removeClass('current');
474
475        $(this).addClass('current');
476        $("#"+tab_id).addClass('current');
477        sliceMapArea();
478    })
479
480    $('.tab-link-4').click(function(){
481        var tab_id = $(this).attr('data-tab');
482
483        $('.tab-link-4').removeClass('current');
484        $('.inner-tab-4').removeClass('current');
485
486        $(this).addClass('current');
487        $("#"+tab_id).addClass('current');
488    })
489
490    $('.tab-link-5').click(function(){
491        var tab_id = $(this).attr('data-tab');
492
493        $('.tab-link-5').removeClass('current');
494        $('.inner-tab-5').removeClass('current');
495
496        $(this).addClass('current');
497        $("#"+tab_id).addClass('current');
498    })
499    $('.tab-cont #tab-1').click();
500});
501// end tabs
502
503//footer menu
504jQuery(function($){
505    $('.footer-box .title a').click(function(){
506        // $('.footer-box').removeClass('active');
507        // $('.footer-box .title a').removeClass('active');
508        $(this).toggleClass("active");
509        $(this).closest('.footer-box').toggleClass('active');
510    });
511});
512//end footer menu
513
514//parallax
515jQuery(function($){
516window.addEventListener('scroll', movement, false);
517let a=0;
518let w = pageYOffset;
519let arr = [w, 0];
520
521function movement(){
522    arr[1] = pageYOffset;
523    if(arr[0]<arr[1]){
524        if(a>-20){
525            a = a-1;
526        }
527        arr[0] = arr[1];
528    }
529
530    else if(arr[0]>=arr[1]){
531        if(a<20){
532            a = a+1;
533        }
534        arr[0] = arr[1];
535    }
536
537    let contents = document.getElementsByClassName('photo-title');
538    for(let i=0; i<contents.length; i++){
539        contents[i].previousElementSibling.style.transform = 'translateY(' + a/2 + 'px)';
540    }
541
542}
543});
544// end parallax
545
546// animate
547jQuery(function($){
548    jQuery('.general-plan-section .info article').addClass("hidden").viewportChecker({
549        classToAdd: 'visible animated fadeInLeft',
550        offset: 200
551    });
552    jQuery('.technologies-section article').addClass("hidden").viewportChecker({
553        classToAdd: 'visible animated fadeInRight',
554        offset: 200
555    });
556});
557// end animate
558
559// scroll section
560(function($){
561    $(window).on("load",function(){
562
563        $.mCustomScrollbar.defaults.theme="light-2"; //set "light-2" as the default theme
564
565        $(".scroll").mCustomScrollbar({
566            axis:"x",
567            advanced:{autoExpandHorizontalScroll:true},
568            mouseWheel:{enable:true, deltaFactor: 150, normalizeDelta: true, preventDefault:false},
569            scrollInertia:300
570
571        });
572
573        $(".scrollTo a").click(function(e){
574            e.preventDefault();
575            var $this=$(this),
576                rel=$this.attr("rel"),
577                el=rel==="content-y" ? ".demo-y" : rel==="content-x" ? ".demo-x" : ".demo-yx",
578                data=$this.data("scroll-to"),
579                href=$this.attr("href").split(/#(.+)/)[1],
580                to=data ? $(el).find(".mCSB_container").find(data) : el===".demo-yx" ? eval("("+href+")") : href,
581                output=$("#info > p code"),
582                outputTXTdata=el===".demo-yx" ? data : "'"+data+"'",
583                outputTXThref=el===".demo-yx" ? href : "'"+href+"'",
584                outputTXT=data ? "$('"+el+"').find('.mCSB_container').find("+outputTXTdata+")" : outputTXThref;
585            $(el).mCustomScrollbar("scrollTo",to);
586            output.text("$('"+el+"').mCustomScrollbar('scrollTo',"+outputTXT+");");
587        });
588
589    });
590})(jQuery);
591// end scroll section
592
593// room number
594jQuery(function($){
595    $('.room-number').click(function() {
596        $('.room-number').removeClass('active');
597        $(this).addClass('active');
598        var val = $(this).data('value');
599        $('.room-number-value').val(val);
600        filter();
601    });
602});
603// end room number
604
605// range slider
606jQuery(function($){
607    $(".slider-range").ionRangeSlider({
608        skin: "big",
609        type: "double",
610        min: 0,
611        max: 100,
612        from: 24,
613        to: 56,
614        step: 1,
615        grid: false,             // show/hide grid
616        force_edges: false,     // force UI in the box
617        hide_min_max: false,    // show/hide MIN and MAX labels
618        hide_from_to: false,    // show/hide FROM and TO labels
619        block: false            // block instance from changing
620    });
621});
622// end range slider
623
624// magnific popup
625jQuery(function($){
626    $('.open-popup-link').magnificPopup({
627        type:'inline',
628        midClick: true,
629        showCloseBtn:false,
630        closeOnBgClick: true,
631        fixedContentPos: false,
632        removalDelay: 300,
633        mainClass: 'mfp-move-horizontal',
634        callbacks: {
635            open: function() {
636                jQuery('body').addClass('noscroll');
637            },
638            close: function() {
639                jQuery('body').removeClass('noscroll');
640            }
641        }
642    });
643    return false
644});
645// end magnific popup
646
647// open general plan
648jQuery(function($){
649    $('.open-general-plan-link').click(function() {
650        $('.general-plan-section.hide').removeClass('hide');
651        $(this).hide('fast');
652        genPlanMapArea();
653    });
654    $('.close-general-plan-link').click(function() {
655        $('.general-plan-section').addClass('hide');
656        $('.open-general-plan-link').show('fast');
657    });
658});
659// end open general plan
660
661function sliceMapArea(){
662    $('#slice-image').on('body',function(){
663        $(this).imageMap();
664    });
665    // MapHilight Status Image Bg
666    var statusBuilding = $('.slice-block'),
667        statusBuildingImg = $('#slice-image');
668
669    if (statusBuilding.length) {
670        statusBuildingImg.maphilight({
671            fill: true,
672            stroke: false,
673            //strokeColor: '#D2D2D2'
674            fillColor: '951542',
675            fillOpacity: 0.55
676        });
677
678    }
679
680    var popup = {
681        el:  $('.floor-section-popup')
682    };
683
684    popup.countText = popup.el.find('.countText');
685    popup.areaText = popup.el.find('.areaText');
686
687    var setPopupCoords = function ($el, e) {
688        var posX = e.pageX;
689        var posY = e.pageY - $(window).scrollTop();
690
691        var popupH = popup.el.innerHeight();
692        var popupW = popup.el.innerWidth();
693
694        popup.el.css({
695            'top': (posY - popupH) + 'px',
696            'left': (posX + 10) + 'px'
697        });
698    };
699
700    statusBuilding.on('mousemove', function (e) {
701        setPopupCoords($(this), e);
702        var targetItem = e.target.closest('area'), position = $(targetItem).offset();
703        if (targetItem) {
704            var count = targetItem.dataset.countRoom;
705            var type = targetItem.dataset.type;
706            var area = targetItem.dataset.area;
707                if(count>0 && (type==0 || type==4)) {
708                    $('.floor-section-popup .part-count span').show();
709                }else{
710                    $('.floor-section-popup .part-count span').hide();
711                }
712                    popup.countText.html(count);
713                    popup.areaText.html(area);
714                    popup.el.addClass('-show');
715
716        }
717        if(!targetItem) {
718            popup.el.removeClass('-show');
719        }
720    }).on('mouseout', function () {
721        popup.el.removeClass('-show');
722    });
723
724}
725
726// open menu complex
727jQuery(function($){
728    const $menu = $('.page .top-menu li');
729    $(document).mouseup(e => {
730        if (!$menu.is(e.target)
731            && $menu.has(e.target).length === 0)
732        {
733            $menu.removeClass('open');
734        }
735    });
736    $($menu).click(function() {
737        $(this).toggleClass('open');
738    });
739});
740// end open menu complex

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.