Set more than one containment in jQuery Draggable(在 jQuery Draggable 中设置多个容器)
问题描述
我正在创建一个页面上有一些元素的管理应用程序.这些元素可以拖动.但在页面中,您有 2 个可以拖动的单独位置.
I'm creating a management application with some element on the page. Those element can be dragged around. but in the page you have 2 seperate places where it could be dragged.
那么有没有一种方法可以在 jQuery draggeble 的包含选项中设置多个类?
So is there a way you can set more then one class in the containment option of the jQuery draggeble?
谢谢
推荐答案
设置 ui 包含选项如下:
set the ui containment options like following:
containment:'selector_1, selector_2,...'
这篇关于在 jQuery Draggable 中设置多个容器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:在 jQuery Draggable 中设置多个容器


基础教程推荐
- 在 JS 中获取客户端时区(不是 GMT 偏移量) 2022-01-01
- 悬停时滑动输入并停留几秒钟 2022-01-01
- 角度Apollo设置WatchQuery结果为可用变量 2022-01-01
- 动态更新多个选择框 2022-01-01
- Karma-Jasmine:如何正确监视 Modal? 2022-01-01
- 在for循环中使用setTimeout 2022-01-01
- 有没有办法使用OpenLayers更改OpenStreetMap中某些要素 2022-09-06
- 我什么时候应该在导入时使用方括号 2022-01-01
- 当用户滚动离开时如何暂停 youtube 嵌入 2022-01-01
- 响应更改 div 大小保持纵横比 2022-01-01