@pushwoosh/kit-charts 0.0.20 → 0.0.22

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pushwoosh/kit-charts",
3
- "version": "0.0.20",
3
+ "version": "0.0.22",
4
4
  "description": "Small React chart library on SVG, with a Highcharts-shaped configuration model",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -89,15 +89,15 @@ export const column = {
89
89
  stroke: borderWidth && !capped ? ctx.series.borderColor : undefined,
90
90
  strokeWidth: borderWidth && !capped ? borderWidth : undefined
91
91
  }, `c-${bar.point.index}`)), capped ? bars.map(bar => {
92
- // The rule sits on the value edge, so a bar counting down wears it below.
92
+ // The rule sits on the value edge, so a bar counting down wears it below. It is a rect
93
+ // rather than a line: only `x`/`y`/`width`/`height` are CSS properties an SVG can tween.
93
94
  const edge = bar.py <= bar.baseY ? bar.y : bar.y + bar.height;
94
- return _jsx("line", {
95
- x1: bar.x,
96
- x2: bar.x + bar.width,
97
- y1: edge,
98
- y2: edge,
99
- stroke: ctx.series.borderColor ?? ctx.color,
100
- strokeWidth: borderWidth
95
+ return _jsx("rect", {
96
+ x: bar.x,
97
+ y: edge - borderWidth / 2,
98
+ width: bar.width,
99
+ height: borderWidth,
100
+ fill: ctx.series.borderColor ?? ctx.color
101
101
  }, `cap-${bar.point.index}`);
102
102
  }) : null, _jsx(DataLabels, {
103
103
  ctx: ctx,