MCPcopy Create free account
hub / github.com/ChartGPU/ChartGPU / getPointSizeCssPx

Function getPointSizeCssPx

src/renderers/createScatterRenderer.ts:57–64  ·  view source on GitHub ↗
(point: DataPoint)

Source from the content-addressed store, hash-verified

55};
56
57const getPointSizeCssPx = (point: DataPoint): number | null => {
58 if (isTupleDataPoint(point)) {
59 const s = point[2];
60 return typeof s === 'number' && Number.isFinite(s) ? s : null;
61 }
62 const s = point.size;
63 return typeof s === 'number' && Number.isFinite(s) ? s : null;
64};
65
66const toScatterTuple = (point: DataPoint): ScatterPointTuple => {
67 if (isTupleDataPoint(point)) return point;

Callers 1

prepareFunction · 0.70

Calls 1

isTupleDataPointFunction · 0.70

Tested by

no test coverage detected