fix: 120 type errors
All checks were successful
Deploy to GitHub Pages / build_site (push) Successful in 2m47s
All checks were successful
Deploy to GitHub Pages / build_site (push) Successful in 2m47s
This commit is contained in:
@@ -27,10 +27,12 @@
|
||||
function constructPath() {
|
||||
max = max !== undefined ? max : Math.max(...points);
|
||||
min = min !== undefined ? min : Math.min(...points);
|
||||
const mi = min as number;
|
||||
const ma = max as number;
|
||||
return points
|
||||
.map((point, i) => {
|
||||
const x = (i / (points.length - 1)) * 100;
|
||||
const y = 100 - ((point - min) / (max - min)) * 100;
|
||||
const y = 100 - ((point - mi) / (ma - mi)) * 100;
|
||||
return `${x},${y}`;
|
||||
})
|
||||
.join(" ");
|
||||
|
||||
Reference in New Issue
Block a user