在两个元素之间画一条连接线 [英] Draw a connecting line between two elements
问题描述
如何在两个或多个元素之间画一条线以连接它们? HTML/CSS/JavaScript/SVG/Canvas的任何组合都可以.
How can I draw a line between two or more elements to connect them? Any combination of HTML/CSS/JavaScript/SVG/Canvas is fine.
如果您的答案支持以下任何一项,请务必提及:
If your answer supports any of these, then do mention it:
- 可拖动元素
- 可拖动/可编辑的连接
- 避免元素重叠
此问题已更新为合并该问题的众多变化.
推荐答案
jsPlumb 是支持拖放的可用选项,如其众多演示所示,包括
jsPlumb is an option available that supports drag and drop, as seen by its numerous demos, including the Flowchart demo.
它有免费的社区版和付费的工具包版.
It is available in a free Community edition, and a paid Toolkit edition.
该工具包版将社区版包装了一个全面的数据绑定层,以及用于构建应用程序和流行库集成的多个UI小部件,并已获得商业许可.
The Toolkit edition wraps the Community edition with a comprehensive data binding layer, as well as several UI widgets for building applications and integrations for popular libraries, and is commercially licensed.
这篇关于在两个元素之间画一条连接线的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!