jQuery Custom Scrollbar Plugin

Add-ons
2026-07-25 23:19 2 次浏览 • 0 次下载 25.5KB
jQuery Custom Scrollbar Plugin

Last updated: 2021-03-07 22:40:47

Usage

1. Include JS

1
2
<script type="text/javascript" src="js/jquery.nicescroll.js"></script>

2、html

1
2
3
4
5
6
7
8
9
10
11
12
<div class="content longitudinal">
<ul>
<li>jQuery is a fast and concise JavaScript framework</li>
<li>The core features of jQuery can be summarized as follows</li>
<li>It features a unique chainable syntax and a concise, clear, multifunctional interface</li>
<li>It features efficient and flexible CSS selectors</li>
<li>It also allows CSS selectors to be extended</li>
<li>It provides a convenient plugin extension mechanism and a rich collection of plugins</li>
<li>jQuery is compatible with all major browsers</li>
<li>It encapsulates commonly used JavaScript functions</li>
</ul>
</div>

3. Configure page JS

1
2
3
4
5
6
7
8
9
$('.longitudinal').niceScroll({
cursorcolor: "#ccc", //#CC0071 Cursor color
cursoropacitymax: 1, // Change the opacity when the cursor is active (scrollbar "visible" state), ranging from 1 to 0
touchbehavior: false, // Makes dragging the scrollbar feel like using a touch device on a desktop computer
cursorwidth: "5px", // Cursor width in pixels
cursorborder: "0", // Cursor border CSS definition
cursorborderradius: "5px", // Cursor border radius in pixels
autohidemode: false // Whether to hide the scrollbar
});
星河码客

发现和分享优质开源项目,传承互联网精神,为开发者服务。

关于本站

联系我们

微信/广告合作:ITcloub (备注星河码客)

免责声明:本站资源版权归原作者所有,仅供学习与交流。如有侵权,请通过「关于我们 - 侵权投诉」联系删除。

Powered by Nuxt · Deployed on Cloudflare