diff --git a/dist/Js/navbar.js b/dist/Js/navbar.js index 7c01bf6..134476d 100644 --- a/dist/Js/navbar.js +++ b/dist/Js/navbar.js @@ -1,40 +1,357 @@ $(document).ready(function() { let navbarHtml = `
- -
`; + +`; $("#navbar-head").html(navbarHtml); + $(".navbar-toggler").click(function(){ + $("#navbar-head").toggleClass("bg-white"); + }) + $('.pricing').find('.biz-nav-wrapper .navbar').addClass('bg-white'); // active-menu @@ -56,10 +373,15 @@ $(document).ready(function() { if (width <= 991.98) { $(".dropdown .nav-link").attr("data-toggle", "dropdown"); + $('.navbar-collapse.mega-nav ul').addClass('d-none') + $('.navbar-collapse.mobile-menu ul').removeClass('d-none') + } else { $(".dropdown .nav-link").attr("data-toggle", ""); + $('.navbar-collapse.mega-nav ul').removeClass('d-none') + $('.navbar-collapse.mobile-menu ul').addClass('d-none') + $('.navbar-expand-lg .navbar-collapse.mobile-menu').remove() } - // Toggle Icon Change $(".biz-nav-wrapper .navbar-toggler").click(function() { $(this).find(".navbar-toggler-icon,.navbar-close-icon").toggle("slow"); @@ -88,7 +410,25 @@ $(document).ready(function() { // c = currentScrollTop; // }); - + $(".nav-item.dropdown.has-mega-menu").off().hover( + function(e){ $("#navbar-head").find(".navbar").css("background-color", "#fff");}, // over + function(e){$("#navbar-head").find(".navbar").css("background-color", ""); } // out + ); + $(document).scroll(function() { + if($(window).scrollTop() === 0) { + $(".nav-item.dropdown.has-mega-menu").off().hover( + function(e){ $("#navbar-head").find(".navbar").css("background-color", "#fff");}, // over + function(e){$("#navbar-head").find(".navbar").css("background-color", ""); } // out + ); + } + else{ + $(".nav-item.dropdown.has-mega-menu").off().hover( + function(e){ $("#navbar-head").find(".navbar").css("background-color", "#fff");}, // over + function(e){$("#navbar-head").find(".navbar").css("background-color", "#fff"); } // out + ); + } + }); + var scroll_start = 0; var startchange = $(".main-body"); var offset = startchange.offset(); @@ -105,6 +445,10 @@ $(document).ready(function() { .find(".navbar") .css("background-color", "transparent") .css("box-shadow", "none"); + $(".nav-item.dropdown.has-mega-menu").hover( + function(e){ $("#navbar-head").find(".navbar").css("background-color", "#fff");}, // over + function(e){$("#navbar-head").find(".navbar").css("background-color", ""); } // out + ); } }); } else { @@ -113,4 +457,51 @@ $(document).ready(function() { .css("background-color", "#fff") .css("box-shadow", "0px 12px 20px -25px"); } +$('.owl-carousel.server-img-sec').owlCarousel({ + // loop: true, + margin: 10, + rtl: false, + nav: false, + autoHeight:true, + responsive: { + 0: { + items: 1 + }, + 600: { + items: 3 + }, + 1000: { + items: 4 + } + } +}); +$('.owl-carousel.accessories-img-sec').owlCarousel({ + // loop: true, + margin: 10, + rtl: false, + nav: false, + autoHeight:true, + responsive: { + 0: { + items: 1 + }, + 600: { + items: 3 + }, + 1000: { + items: 4 + } + } +}); + +$('.navbar-nav').mouseover(function (e) { + $('.mbil-name').addClass('padding_bottom_ONE_FIVE'); + $('.navbar-brand img').addClass('padding_bottom_ONE_FIVE'); +}); + +$('.navbar-nav').mouseout(function (e) { + $('.mbil-name').removeClass('padding_bottom_ONE_FIVE'); + $('.navbar-brand img').removeClass('padding_bottom_ONE_FIVE'); +}); + }); \ No newline at end of file diff --git a/index.html b/index.html index f4567c9..e880df4 100644 --- a/index.html +++ b/index.html @@ -21,17 +21,14 @@
- - -
-
+
shopping-cart-item-img
diff --git a/styles/style.scss b/styles/style.scss index b340196..0f564d1 100644 --- a/styles/style.scss +++ b/styles/style.scss @@ -201,7 +201,7 @@ $background-color_2: #fff; .dropdown-menu { width: 100%; left: 0; - margin-top: 1.5rem; + // margin-top: 1.5rem; } .dropdown { &:hover { @@ -376,4 +376,9 @@ $background-color_2: #fff; to { transform: rotate(360deg); } - } \ No newline at end of file + } + +.mbil-name, .navbar-brand img{ + transition: all .2s ease; +} +