@empoweredvote/ev-ui 0.10.0 → 0.10.1
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/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -65,7 +65,7 @@ function RadarChartCore({
|
|
|
65
65
|
const max = ((_a = topic == null ? void 0 : topic.stances) == null ? void 0 : _a.length) || 10;
|
|
66
66
|
const pct = Math.min(value / max * 10, 10);
|
|
67
67
|
const angle = 2 * Math.PI * index / numSpokes;
|
|
68
|
-
const adjusted = value === 0 ? 0 : invertedSpokes[shortTitle] ?
|
|
68
|
+
const adjusted = value === 0 ? 0 : invertedSpokes[shortTitle] ? (max + 1) * 10 / max - pct : pct;
|
|
69
69
|
const r = adjusted / 10 * radius;
|
|
70
70
|
const x = centerX + r * Math.sin(angle);
|
|
71
71
|
const y = centerY - r * Math.cos(angle);
|
|
@@ -90,7 +90,7 @@ function RadarChartCore({
|
|
|
90
90
|
const max = ((_b = topic == null ? void 0 : topic.stances) == null ? void 0 : _b.length) || 10;
|
|
91
91
|
const pct = Math.min(value / max * 10, 10);
|
|
92
92
|
const angle = 2 * Math.PI * index / numSpokes;
|
|
93
|
-
const adjusted = value === 0 ? 0 : invertedSpokes[shortTitle] ?
|
|
93
|
+
const adjusted = value === 0 ? 0 : invertedSpokes[shortTitle] ? (max + 1) * 10 / max - pct : pct;
|
|
94
94
|
const r = adjusted / 10 * radius;
|
|
95
95
|
const x = centerX + r * Math.sin(angle);
|
|
96
96
|
const y = centerY - r * Math.cos(angle);
|