- If you want just drag and drop use jQuery UI.
- If you want to connect divs use jsPlumb.
- If you want flowcharts use jsPlumb + jQuery UI. jQuery to drag elements on to the diagram div and jsPlumb to connect them.
You can achieve almost every thing what ever is being done here. I have used it personally to create something very similar. jsPlumb is MIT License, so you don't have worry about any thing.