Skip to content

Commit bd43f87

Browse files
Christofer BengtssonChristofer Bengtsson
authored andcommitted
fix(box): remove Number.isNaN
1 parent 555e5ec commit bd43f87

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/picasso.js/src/core/chart-components/box/box-shapes.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ export function buildShapes({
254254
const rendHeight = height;
255255

256256

257-
const allValidValues = [item.min, item.start, item.med, item.end, item.max].filter(v => typeof v === 'number' && !Number.isNaN(v));
257+
const allValidValues = [item.min, item.start, item.med, item.end, item.max].filter(isNumber);
258258

259259
const isLowerOutOfBounds = Math.min(...allValidValues) < 0 && Math.max(...allValidValues) < 0;
260260
const isHigherOutOfBounds = Math.min(...allValidValues) > 1 && Math.max(...allValidValues) > 1;

0 commit comments

Comments
 (0)