N
N
Neyury2016-08-13 22:23:53
JavaScript
Neyury, 2016-08-13 22:23:53

How to implement similar arrows in the web?

How can you implement similar arrows between blocks on a web page? Arrows can be dragged to another block. they follow the floating block, and so on.
1-png.86632
From the possible options, I imagine (vaguely) svg or canvas (did not really work with both things), located behind the container with blocks. And control with the help of js, which stores the coordinates of blocks, arrows, and what is connected with what. When you click on a document, it checks if there is an arrow on the coordinates, if there is, it starts moving behind the cursor, if the next click on the block, the arrow is assigned to the block.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
X
xmoonlight, 2016-08-13
@xmoonlight

Raphael.js (SVG) - there is such functionality.

M
Mikhail Beloshitsky, 2016-08-14
@mbeloshitsky

jointjs
It's true that developers are promoting their new framework, rappid, but for diagrams with arrows, free jointjs will suffice.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question