HERE IS WHERE YOU CAN VIEW MY JSFIDDLE
On my website, I have a main home page with a smooth scroll wheel script implemented. Additionally, I have a 'about' div that becomes visible when a button is clicked. The issue I am facing is that I want the smooth scroll functionality to also work on the 'about' div, but it is not functioning as desired. The div does not scroll as intended. Furthermore, when the 'about' div is open, I want the 'home' div to remain static without scrolling.
$('button').click(function() {
if ($(this).hasClass("clicked")) {
$("#about").css({"visibility": "hidden"});
$("body").css({"overflow": "auto"});
$(this).removeClass("clicked");
} else {
$("#about").css({"visibility": "visible"});
$("body").css({"overflow": "hidden"});
$(this).addClass("clicked");
}
});
$("body").smoothWheel();