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

Function afterDraw

src/plugins/plugin.tooltip.js:1247–1263  ·  view source on GitHub ↗
(chart)

Source from the content-addressed store, hash-verified

1245 },
1246
1247 afterDraw(chart) {
1248 const tooltip = chart.tooltip;
1249
1250 if (tooltip && tooltip._willRender()) {
1251 const args = {
1252 tooltip
1253 };
1254
1255 if (chart.notifyPlugins('beforeTooltipDraw', {...args, cancelable: true}) === false) {
1256 return;
1257 }
1258
1259 tooltip.draw(chart.ctx);
1260
1261 chart.notifyPlugins('afterTooltipDraw', args);
1262 }
1263 },
1264
1265 afterEvent(chart, args) {
1266 if (chart.tooltip) {

Callers

nothing calls this directly

Calls 3

_willRenderMethod · 0.80
notifyPluginsMethod · 0.80
drawMethod · 0.65

Tested by

no test coverage detected