触摸导航
¥Touch Navigation
你可以在任何支持触控的设备上滑动以浏览演示文稿。水平滑动切换水平幻灯片,垂直滑动切换垂直幻灯片。
¥You can swipe to navigate through a presentation on any touch-enabled device. Horizontal swipes change between horizontal slides, vertical swipes change between vertical slides.
如果你想禁用此功能,你可以在初始化时将 touch
配置选项设置为 false。
¥If you wish to disable this you can set the touch
config option to false when initializing.
Reveal.initialize({
touch: false,
});
如果你的内容中有某些部分需要保持对触摸事件的可访问性,则需要通过向元素添加 data-prevent-swipe
属性来高亮。一个常见的例子是需要滚动的元素。
¥If there's some part of your content that needs to remain accessible to touch events you'll need to highlight this by adding a data-prevent-swipe
attribute to the element. One common example where this is useful is elements that need to be scrolled.
<section>
<p data-prevent-swipe>Can't change slides by swiping across this element.</p>
</section>