MCPcopy
hub / github.com/tinyplex/tinybase / getTimeAxisLabels

Function getTimeAxisLabels

test/unit/core/ui-react/ui-react-dom-charts.test.tsx:58–76  ·  view source on GitHub ↗
(
  min: string,
  max: string,
  tickCount: number,
)

Source from the content-addressed store, hash-verified

56 );
57
58const getTimeAxisLabels = (
59 min: string,
60 max: string,
61 tickCount: number,
62): string[] => {
63 const store = createStore().setTable('t1', {
64 r1: {x: min, y: 3},
65 r2: {x: max, y: 5},
66 });
67 const {container, unmount} = render(
68 <LineChart store={store} tableId="t1" xCellId="x" yCellId="y">
69 <XAxis scale="time" tickCount={tickCount} />
70 </LineChart>,
71 );
72 const labels = getXAxisTickLabels(container) as string[];
73
74 unmount();
75 return labels;
76};
77
78describe.each(CHARTS)('%s', (_chartName, Chart) => {
79 describe('Table', () => {

Callers 1

Calls 4

createStoreFunction · 0.90
getXAxisTickLabelsFunction · 0.85
setTableMethod · 0.65
renderFunction · 0.50

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…