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

Function getPointSizeCssPx

src/interaction/findNearestPoint.ts:64–71  ·  view source on GitHub ↗
(p: DataPoint)

Source from the content-addressed store, hash-verified

62};
63
64const getPointSizeCssPx = (p: DataPoint): number | null => {
65 if (isTupleDataPoint(p)) {
66 const s = p[2];
67 return typeof s === 'number' && Number.isFinite(s) ? s : null;
68 }
69 const s = p.size;
70 return typeof s === 'number' && Number.isFinite(s) ? s : null;
71};
72
73const toScatterTuple = (p: DataPoint): ScatterPointTuple => {
74 if (isTupleDataPoint(p)) return p;

Callers 2

getScatterRadiusCssPxFunction · 0.70
getMaxScatterRadiusCssPxFunction · 0.70

Calls 1

isTupleDataPointFunction · 0.70

Tested by

no test coverage detected