MCPcopy Create free account
hub / github.com/chartjs/Chart.js / getLineWidthForValue

Method getLineWidthForValue

src/core/core.scale.js:1456–1468  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

1454 }
1455
1456 getLineWidthForValue(value) {
1457 const grid = this.options.grid;
1458 if (!this._isVisible() || !grid.display) {
1459 return 0;
1460 }
1461 const ticks = this.ticks;
1462 const index = ticks.findIndex(t => t.value === value);
1463 if (index >= 0) {
1464 const opts = grid.setContext(this.getContext(index));
1465 return opts.lineWidth;
1466 }
1467 return 0;
1468 }
1469
1470 /**
1471 * @protected

Callers

nothing calls this directly

Calls 3

_isVisibleMethod · 0.95
getContextMethod · 0.95
setContextMethod · 0.80

Tested by

no test coverage detected