相关疑难解决方法(0)

如何更改网页的默认scrollspeed,scrollamount,scrollinertia

我想改变网页的默认滚动速度,数量和惯性.我谷歌很多,但是徒劳无功

幸运的是,今天晚些时候,我发现了一个插件,它允许我们仅在特定div标签内而不是在整个网页中更改卷轴速度,数量,惯性.

这是一个基本代码

    $(".I-WILL-APPLY-ONLY HERE").mCustomScrollbar({
 set_width:false, 
set_height:false, 
 horizontalScroll:false, 
scrollInertia:550, 
 SCROLLINERTIA:"easeOutCirc", 
 mouseWheel:"auto", 
  autoDraggerLength:true, 
    scrollButtons:{ 
enable:false, 
       scrollType:"continuous", 
     SCROLLSPEED:20, 
      SCROLLAMOUNT:40 
     },
    advanced:{
updateOnBrowserResize:true, 
   updateOnContentResize:false, 
      autoExpandHorizontalScroll:false, 
    autoScrollOnFocus:true 
   },
           callbacks:{
     onScrollStart:function(){}, 
    onScroll:function(){}, 
onTotalScroll:function(){}, 
    onTotalScrollBack:function(){}, 
   onTotalScrollOffset:0, 
whileScrolling:false, 
       whileScrollingInterval:30 
 }
   });



<div id="I-WILL-APPLY-ONLY HERE" class="I-WILL-APPLY-ONLY HERE">
A basic height in pixels would be defined for this element and any content appearing here will have a different scrollspeed,inertia.Mentioning heignt of this div element is compulsary,else i wont show the output    </div>
Run Code Online (Sandbox Code Playgroud)

问题是我想要整个页面,而不仅仅是有一个特定的div元素.任何帮助将不胜感激.请帮助我

提前致谢

html jquery jquery-ui jquery-plugins

11
推荐指数
2
解决办法
2万
查看次数

标签 统计

html ×1

jquery ×1

jquery-plugins ×1

jquery-ui ×1