当前位置:网站首页>Method of hiding scroll bar in wechat applet
Method of hiding scroll bar in wechat applet
2022-07-28 07:33:00 【No Bug】
When the content displayed on the applet page exceeds the screen height or width , We want to see everything , At this time, you must use page scrolling . But , We found that the scroll bar of the scrolling page is particularly abrupt and ugly , And refer to most small programs that remove the scroll bar . that , How do we get rid of the scroll bar ?
When the display content exceeds the page height , Will trigger page Default scroll bar . as follows :
scroll-view, The method of hiding the scroll bar is also very simple .
We can do it in app.wxss( overall situation ) Or the current page .wxss Add the following code :
::-webkit-scrollbar {
display: none;
width: 0;
height: 0;
color: transparent;
}
Be careful :
scroll-view Do not set the height to relative height , Such as 100%. otherwise ,page The scroll bar of the page will appear again !!!
You can do this :
<scroll-view scroll-y style="width: 100%; height: 100vh;"> </scroll-view>
If it still doesn't work , Reduce height Value , For example, set to height:99vh.scroll-view The height is greater than page Scroll bars will still appear at the height .
Parent element such as page Remember to set up :
overflow: hidden;
边栏推荐
- 5G 商用第三年:无人驾驶的“上山”与“下海”
- 细说共模干扰和差模干扰
- ASP.NET Core 技术内幕与项目实战读后感
- 面试中必不可少的性能优化专题~
- 指针进阶练习
- EMC rectification method set
- 两个星期学会软件测试?我震惊了!
- 教程篇(7.0) 06. 零信任网络访问ZTNA * FortiClient EMS * Fortinet 网络安全专家 NSE 5
- Deeply analyze the implementation of singleton mode
- Log in to heroku and the solution of IP address mismatch appears
猜你喜欢
随机推荐
(daily question) - the longest substring without repeated characters
DNA脱氧核糖核酸修饰金属铂纳米颗粒PtNPS-DNA|科研试剂
On deep paging
Introduction to magnetic ring selection and EMC rectification skills
DNA修饰贵金属纳米颗粒|DNA修饰纳米铜颗粒CuNPS-DNA|研究要点
Which of class A and class B is more stringent in EMC?
链表中倒数第k个节点——双指
合并两个排序的链表——每日两题
The net loss of users occurred again, and China Mobile, which lost face, launched ultra-low price packages to win users
Retryer of guava
EMC整改方法集合
常用电子产品行业标准及认证
MHA high availability configuration and failover
flow_ x+flow_ y---RGB
Tutorial (7.0) 06. Zero trust network access ztna * forticlient EMS * Fortinet network security expert NSE 5
JS secondary linkage Department
4.1.4 why set the member variable to private
Cdn.jsdelivr.net is not available, what should I do
build_ opencv.sh
【着色器实现Negative反色效果_Shader效果第十一篇】








