MCustomScrollbar does not provide scroll functions to the top of the page. However, it does support scrolling to a specific element in HTML.
For example, if I have an element with the identifier "logout" that is at the top of the page, and I need to scroll up, then write
$("#mcs_container").mCustomScrollbar("scrollTo", "#logout");
I hope you find this helpful.
Hooray!
source
share