If you can provide a snippet of code along with the issue you're facing, it would greatly assist in finding a solution. However, here is an example showcasing how to change the color of a navbar upon scrolling:
$(document).ready(function(){
$(window).scroll(function(){
var scroll = $(window).scrollTop();
if (scroll > 300) {
$(".black").css("background" , "blue");
}
else{
$(".black").css("background" , "#333");
}
})
})
body{
margin:0;
padding:0;
height:1000px;
}
.black{
position:fixed;
top:0;
background:#333;
width:100%;
height:50px;
}
.black ul{
list-style-type:none;
padding:0;
}
.black ul li{
display:inline-block;
width:100px;
color:red;
}
.blue{
position:fixed;
top:0;
background:blue;
width:100%;
height:50px;
}
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<div class="black">
<ul>
<li>link</li>
<li>link</li>
<li>link</li>
<li>link</li>
</ul>
</div>