When using 'data-width="100%" ' , the canvas width gets calculated, to px's.
When my bootstrap Menu opens, the parent of the canvas width will be reduced.
When the parent will get smaller and the canvas size remains, the canvas will get outside his parent.
This makes you able to scroll unwanted from left to right.
When using 'data-width="100%" ' , the canvas width gets calculated, to px's. When my bootstrap Menu opens, the parent of the canvas width will be reduced. When the parent will get smaller and the canvas size remains, the canvas will get outside his parent.
This makes you able to scroll unwanted from left to right.
use 'this.width' instead of 'width' which will get 100% style width of the element https://github.com/gwatts/jquery.sparkline/blob/657f42892ee384691e2540fae1f04058da4145d5/src/vcanvas-canvas.js#L18
When using 'this.width' the element will resize due to the percentage width