首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往
您找到你想要的搜索结果了吗?
是的
没有找到

控制页面的滚动:自定义下拉到刷新和溢出效果

(左边之前:页面内容在叠加层下滚动,右边之后:页面内容不会在叠加层下滚动) 禁用拉到刷新 关闭pull-to-refresh操作是一行CSS。只要阻止整个视口定义元素的滚动链接。...在大多数情况下,这是 body { /* 禁用“拉到刷新”功能,但允许发生滚动发光效果 Disables pull-to-refresh but allows overscroll glow effects...inbox.addEventListener('touchmove', e => { const y = e.touches[0].pageY; // 在容器顶部时激活自定义的拉到刷新效果 Activate custom pull-to-refresh...仍然保持滑动导航Disables pull-to-refresh and overscroll glow effect....inbox.addEventListener('touchmove', e => { const y = e.touches[0].pageY; // Activate custom pull-to-refresh

3.2K20

扫码

添加站长 进交流群

领取专属 10元无门槛券

手把手带您无忧上云

扫码加入开发者社群

热门标签

活动推荐

    运营活动

    活动名称
    广告关闭
    领券