MCPcopy
hub / github.com/chartjs/Chart.js / x

Function x

src/core/core.interaction.js:368–371  ·  view source on GitHub ↗

* x mode returns the elements that hit-test at the current x coordinate * @function Chart.Interaction.modes.x * @param {Chart} chart - the chart we are returning items from * @param {Event} e - the event we are find things at * @param {InteractionOptions} options - options to use * @p

(chart, e, options, useFinalPosition)

Source from the content-addressed store, hash-verified

366 * @return {InteractionItem[]} - items that are found
367 */
368 x(chart, e, options, useFinalPosition) {
369 const position = getRelativePosition(e, chart);
370 return getAxisItems(chart, position, 'x', options.intersect, useFinalPosition);
371 },
372
373 /**
374 * y mode returns the elements that hit-test at the current y coordinate

Callers

nothing calls this directly

Calls 2

getRelativePositionFunction · 0.85
getAxisItemsFunction · 0.85

Tested by

no test coverage detected