chartist-svg 0.2.6 → 0.2.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,5 +1,6 @@
1
1
  Generate SVG chart using [Chartist].
2
- > You can paste the SVG code to a file directly.
2
+ > You can paste the SVG code to a file directly. \
3
+ > Use [SVGViewer](https://www.svgviewer.dev) to view the generated SVG.
3
4
 
4
5
  <br>
5
6
 
@@ -42,18 +43,24 @@ options: {
42
43
  Example:
43
44
 
44
45
  ```javascript
46
+ const Chartist = require('chartist');
47
+ const chartistSvg = require('chartist-svg');
48
+
45
49
  var data = {
46
50
  title: 'Time to play PUBG',
47
51
  subtitle: 'Player Unknown\'s Battleground',
48
52
  labels: ['P', 'U', 'B', 'G'],
49
53
  series: [
50
54
  [1, 2, 3, 4],
51
- [3, 4, 5, 6]
55
+ [3, 5, 5, 6],
52
56
  ]
53
57
  };
58
+
54
59
  var options = {
55
- css: '.ct-chart-line .ct-series .ct-point { stroke: green; }'
60
+ css: '.ct-chart-line .ct-series .ct-point { stroke: green; }',
61
+ chart: {lineSmooth: Chartist.Interpolation.step()},
56
62
  };
63
+
57
64
  chartistSvg('line', data, options).then(svg => console.log(svg));
58
65
  /* (generated svg can be used independently) */
59
66
  /* (it is not dependent upon any external css) */
package/index.js CHANGED
@@ -128,7 +128,7 @@ function defaults(o) {
128
128
  'text-anchor': 'middle',
129
129
  fill: 'indianred',
130
130
  }, o.subtitle);
131
- return Object.assign({options, resOptions, onDraw, css, title, subtitle}, o);
131
+ return Object.assign({}, o, {options, resOptions, onDraw, css, title, subtitle});
132
132
  }
133
133
 
134
134
 
@@ -142,6 +142,7 @@ function defaults(o) {
142
142
  * @param {string} type chart type (line, bar, pie)
143
143
  * @param {object} data chartist data (inc. title, subtitle)
144
144
  * @param {object} [o] options
145
+ * @param {object} [o.chart] chartist options (width, height, chartPadding, ...)
145
146
  * @param {object} [o.options] chartist options (width, height, chartPadding, ...)
146
147
  * @param {object} [o.resOptions] chartist responsive options
147
148
  * @param {object} [o.onDraw] chartist on 'draw' handler
package/index.svg ADDED
@@ -0,0 +1 @@
1
+ <svg xmlns:ct="http://gionkunz.github.com/chartist-js/ct" width="1200" height="792" style="" class="ct-chart-line"><g class="ct-grids" transform="translate(0, 72)"><line x1="60" x2="60" y1="15" y2="565" class="ct-grid ct-horizontal" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line x1="320" x2="320" y1="15" y2="565" class="ct-grid ct-horizontal" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line x1="580" x2="580" y1="15" y2="565" class="ct-grid ct-horizontal" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line x1="840" x2="840" y1="15" y2="565" class="ct-grid ct-horizontal" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="565" y2="565" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="537.5" y2="537.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="510" y2="510" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="482.5" y2="482.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="455" y2="455" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="427.5" y2="427.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="400" y2="400" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="372.5" y2="372.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="345" y2="345" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="317.5" y2="317.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="290" y2="290" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="262.5" y2="262.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="235" y2="235" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="207.5" y2="207.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="180" y2="180" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="152.5" y2="152.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="125" y2="125" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="97.5" y2="97.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="70" y2="70" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="42.5" y2="42.5" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line><line y1="15" y2="15" x1="60" x2="1100" class="ct-grid ct-vertical" style="stroke:rgba(0,0,0,.2);stroke-width:1px;stroke-dasharray:2px;stroke-dasharray:2px;stroke-width:1px;stroke:rgba(0,0,0,.2);"></line></g><g transform="translate(0, 72)"><g class="ct-series ct-series-a"><path d="M60,565L320,565L320,455L580,455L580,345L840,345L840,235" class="ct-line" style="stroke:#d70206;stroke:#d70206;fill:none;stroke-width:4px;stroke-width:4px;fill:none;"></path><line x1="60" y1="565" x2="60.01" y2="565" class="ct-point" ct:value="1" style="stroke:#d70206;stroke:#d70206;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="320" y1="565" x2="320.01" y2="565" class="ct-point" ct:value="1" style="stroke:#d70206;stroke:#d70206;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="320" y1="455" x2="320.01" y2="455" class="ct-point" ct:value="2" style="stroke:#d70206;stroke:#d70206;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="580" y1="455" x2="580.01" y2="455" class="ct-point" ct:value="2" style="stroke:#d70206;stroke:#d70206;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="580" y1="345" x2="580.01" y2="345" class="ct-point" ct:value="3" style="stroke:#d70206;stroke:#d70206;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="840" y1="345" x2="840.01" y2="345" class="ct-point" ct:value="3" style="stroke:#d70206;stroke:#d70206;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="840" y1="235" x2="840.01" y2="235" class="ct-point" ct:value="4" style="stroke:#d70206;stroke:#d70206;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line></g><g class="ct-series ct-series-b"><path d="M60,345L320,345L320,125L580,125L580,125L840,125L840,15" class="ct-line" style="stroke:#f05b4f;stroke:#f05b4f;fill:none;stroke-width:4px;stroke-width:4px;fill:none;"></path><line x1="60" y1="345" x2="60.01" y2="345" class="ct-point" ct:value="3" style="stroke:#f05b4f;stroke:#f05b4f;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="320" y1="345" x2="320.01" y2="345" class="ct-point" ct:value="3" style="stroke:#f05b4f;stroke:#f05b4f;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="320" y1="125" x2="320.01" y2="125" class="ct-point" ct:value="5" style="stroke:#f05b4f;stroke:#f05b4f;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="580" y1="125" x2="580.01" y2="125" class="ct-point" ct:value="5" style="stroke:#f05b4f;stroke:#f05b4f;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="580" y1="125" x2="580.01" y2="125" class="ct-point" ct:value="5" style="stroke:#f05b4f;stroke:#f05b4f;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="840" y1="125" x2="840.01" y2="125" class="ct-point" ct:value="5" style="stroke:#f05b4f;stroke:#f05b4f;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line><line x1="840" y1="15" x2="840.01" y2="15" class="ct-point" ct:value="6" style="stroke:#f05b4f;stroke:#f05b4f;stroke-width:10px;stroke-linecap:round;stroke-linecap:round;stroke-width:10px;stroke:green;stroke:green;"></line></g></g><g class="ct-labels" transform="translate(0, 72)"><foreignObject style="overflow: visible;" x="60" y="570" width="260" height="20"><span class="ct-label ct-horizontal ct-end" style="text-align:left;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;fill:crimson;text-anchor:start;text-anchor:start;fill:crimson;font-size:14px;font-weight:bold;font-family:Courier;width: 260px; height: 20px;" xmlns="http://www.w3.org/2000/xmlns/" transform="rotate(20, null, null) translate(-10, 0)">P</span></foreignObject><foreignObject style="overflow: visible;" x="320" y="570" width="260" height="20"><span class="ct-label ct-horizontal ct-end" style="text-align:left;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;fill:crimson;text-anchor:start;text-anchor:start;fill:crimson;font-size:14px;font-weight:bold;font-family:Courier;width: 260px; height: 20px;" xmlns="http://www.w3.org/2000/xmlns/" transform="rotate(20, null, null) translate(-10, 0)">U</span></foreignObject><foreignObject style="overflow: visible;" x="580" y="570" width="260" height="20"><span class="ct-label ct-horizontal ct-end" style="text-align:left;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;fill:crimson;text-anchor:start;text-anchor:start;fill:crimson;font-size:14px;font-weight:bold;font-family:Courier;width: 260px; height: 20px;" xmlns="http://www.w3.org/2000/xmlns/" transform="rotate(20, null, null) translate(-10, 0)">B</span></foreignObject><foreignObject style="overflow: visible;" x="840" y="570" width="260" height="20"><span class="ct-label ct-horizontal ct-end" style="text-align:left;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;fill:crimson;text-anchor:start;text-anchor:start;fill:crimson;font-size:14px;font-weight:bold;font-family:Courier;width: 260px; height: 20px;" xmlns="http://www.w3.org/2000/xmlns/" transform="rotate(20, null, null) translate(-10, 0)">G</span></foreignObject><foreignObject style="overflow: visible;" y="537.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">1</span></foreignObject><foreignObject style="overflow: visible;" y="510" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">1.25</span></foreignObject><foreignObject style="overflow: visible;" y="482.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">1.5</span></foreignObject><foreignObject style="overflow: visible;" y="455" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">1.75</span></foreignObject><foreignObject style="overflow: visible;" y="427.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">2</span></foreignObject><foreignObject style="overflow: visible;" y="400" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">2.25</span></foreignObject><foreignObject style="overflow: visible;" y="372.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">2.5</span></foreignObject><foreignObject style="overflow: visible;" y="345" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">2.75</span></foreignObject><foreignObject style="overflow: visible;" y="317.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">3</span></foreignObject><foreignObject style="overflow: visible;" y="290" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">3.25</span></foreignObject><foreignObject style="overflow: visible;" y="262.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">3.5</span></foreignObject><foreignObject style="overflow: visible;" y="235" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">3.75</span></foreignObject><foreignObject style="overflow: visible;" y="207.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">4</span></foreignObject><foreignObject style="overflow: visible;" y="180" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">4.25</span></foreignObject><foreignObject style="overflow: visible;" y="152.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">4.5</span></foreignObject><foreignObject style="overflow: visible;" y="125" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">4.75</span></foreignObject><foreignObject style="overflow: visible;" y="97.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">5</span></foreignObject><foreignObject style="overflow: visible;" y="70" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">5.25</span></foreignObject><foreignObject style="overflow: visible;" y="42.5" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">5.5</span></foreignObject><foreignObject style="overflow: visible;" y="15" x="20" height="27.5" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 28px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">5.75</span></foreignObject><foreignObject style="overflow: visible;" y="-11.19047619047619" x="20" height="26.19047619047619" width="30"><span class="ct-label ct-vertical ct-start" style="text-align:right;fill:rgba(0,0,0,.4);color:rgba(0,0,0,.4);font-size:12px;line-height:1;line-height:1;font-size:12px;color:rgba(0,0,0,.4);fill:rgba(0,0,0,.4);font-family:Courier;font-weight:bold;font-size:14px;text-anchor:end;text-anchor:end;font-size:14px;font-weight:bold;font-family:Courier;height: 26px; width: 30px;" xmlns="http://www.w3.org/2000/xmlns/">6</span></foreignObject></g><text x="600" y="28.799999999999997" height="48" font-size="18px" font-family="Verdana" font-weight="bold" text-anchor="middle" fill="crimson" role="caption">Time to play PUBG</text><text x="600" y="62.4" height="24" font-size="12px" font-family="Verdana" font-weight="bold" text-anchor="middle" fill="indianred">Player Unknown's Battleground</text></svg>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "chartist-svg",
3
- "version": "0.2.6",
3
+ "version": "0.2.8",
4
4
  "description": "Generate SVG chart using chartist on node.js.",
5
5
  "main": "index.js",
6
6
  "scripts": {