FullPage.js使其在桌面 /移动水平上可拖动

发布于 2025-02-07 19:18:15 字数 493 浏览 1 评论 0原文

我正在使用 fullpage.js 在移动设备上,一切都可以拖动,我只是正常工作,我只是正常工作,我只是正常工作还需要桌面(我创建的一个容器)也可以拖动 - 现在只能滚动。我需要这个,因为在移动水平视图上,无法拖动/移动容器。

我想知道正在使用在移动设备上启用拖动的“事物”是什么,以便我可以复制CSS或其他任何内容。

我知道那里有很多可拖动的图书馆,但我真的很想以传统的方式这样做,而没有任何额外的图书馆。

我在移动设备上启用了此ScrollOverFlow选项。我也尝试在桌面上启用它,但没有区别。

const options = {
    scrollOverflow: deviceType == 'mobile' ? true : false
}

I am using fullpage.js and on mobile, everything is draggable and works fine, I just need the desktop (a container that I created) to be draggable as well - it is only scrollable now. I need this because on mobile horizontal view, the container cannot be dragged/moved around.

I would like to know what is the "thing" that is being used that enabled draggable on mobile so that I can copy the css or whatever over.

I know that there are plenty of draggable libraries out there but I really wanna do this the conventional way, without any extra libraries.

I have this scrollOverflow option enabled on mobile. I tried enabling it on desktop as well but it didn't make a difference.

const options = {
    scrollOverflow: deviceType == 'mobile' ? true : false
}

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

辞取 2025-02-14 19:18:15

哦,我想我找到了解决方案。

我使用normalalsCrollelements选项,并定位我创建的容器。现在正常工作。 :)

Oh I think I found the solution.

I use the normalScrollElements option and target the container that I created. And it is working fine now. :)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文