MCPcopy Index your code
hub / github.com/apache/echarts / coordDataToAllCellLevelLayout

Function coordDataToAllCellLevelLayout

src/coord/matrix/matrixCoordHelper.ts:66–78  ·  view source on GitHub ↗
(
    coordValue: MatrixCoordValueOption,
    dims: MatrixDimPair,
    thisDimIdx: number // 0 | 1
)

Source from the content-addressed store, hash-verified

64 * For the y direction, it's the opposite.
65 */
66export function coordDataToAllCellLevelLayout(
67 coordValue: MatrixCoordValueOption,
68 dims: MatrixDimPair,
69 thisDimIdx: number // 0 | 1
70): MatrixCellLayoutInfo | NullUndefined {
71 // Find in body.
72 let result: MatrixCellLayoutInfo | NullUndefined = dims[XY[thisDimIdx]].getCell(coordValue);
73 // Find in corner or dimension area.
74 if (!result && isNumber(coordValue) && coordValue < 0) {
75 result = dims[XY[1 - thisDimIdx]].getUnitLayoutInfo(thisDimIdx, Math.round(coordValue));
76 }
77 return result;
78}
79
80export function resetXYLocatorRange(out: unknown[] | NullUndefined): MatrixXYLocatorRange {
81 const rg = (out || []) as MatrixXYLocatorRange;

Calls 3

isNumberFunction · 0.85
getUnitLayoutInfoMethod · 0.80
getCellMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…