css - 有什么方法可以禁用 CSS 滚动捕捉点?

标签 css twitter-bootstrap mobile smooth-scrolling scroll-snap-points

我有一个单页移动 Bootstrap 站点,滚动时,固定导航栏会在点击导航菜单中的链接时覆盖部分标题。我发现这是由 CSS 滚动捕捉点引起的。我尝试为所有部分的 .section 类设置 scroll-snap-type: none; 但它仍然会产生错误。如何正确禁用整个页面的 CSS 滚动捕捉点?

最佳答案

也许它会有所帮助。试试下面

 * Keyword values */
scroll-snap-type: none;
scroll-snap-type: mandatory;
scroll-snap-type: proximity;

/* Global values */
scroll-snap-type: inherit;
scroll-snap-type: initial;
scroll-snap-type: unset;

同Y跟随。(scroll-snap-type-y)

   /* Keyword values */
scroll-snap-type-x: none;
scroll-snap-type-x: mandatory;
scroll-snap-type-x: proximity;

/* Global values */
scroll-snap-type-x: inherit;
scroll-snap-type-x: initial;
scroll-snap-type-x: unset;

关于css - 有什么方法可以禁用 CSS 滚动捕捉点?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48072179/

相关文章:

css - Rails 3.1 Assets 管道指纹识别

javascript - Bootstrap : How to show modal without animation just for first time?

javascript - Angular 从日期时间选择器获取日期

html - 网站的 Apple Touch 图标

ios - 如何在 iOS 中存储应用程序设置,如 INI/CONF?

java - 如何在方法中使用 Intent 的结果

css - 如何删除网页底部的大空白区域?

html - 在 col-xs-12 中查看时在两个 Bootstrap 列之间添加空间

css - 如何使用 animate.css 减少动画延迟时间?

jquery - Bootstrap 中的等高问题