jquery.chain
Follow for dots use a lines.
Initilization:
var chain = line : color: '#b59371' // color of line width: 1 // width of line dots : size : 2 2 // size rect, first arg. like radius for round color: '#b59371' // color rect or round el : '.Chain' // selector or node follow: '.Chain-dot' // items by block, selector or array nodes add : 'round' // enable round, rect or false canvas: appendTo: false // insert canvas to node, false = el: '.Chain' css : position : 'absolute' width : '100%' height : '100%' pointerEvents: 'none' left : 0 top : 0 ; chain;
Methods
chain // stop followchainstartchainclearfn // clear canvas, if set function then clear cache too, after run callbackchain // set new position (if use: follow: [ [x, y], [x, y], [x, y] ]) "block" is optionally, default first element
To use the offset
// data attributes for offset
Install
npm install jquery.chain
bower install jquery.chain