Show measurement in tooltip on hover
This commit is contained in:
parent
0a6bbc9980
commit
de27115917
@ -221,7 +221,7 @@
|
||||
}
|
||||
},
|
||||
interaction: {
|
||||
mode: 'index',
|
||||
mode: 'x',
|
||||
intersect: false
|
||||
},
|
||||
plugins: {
|
||||
@ -229,7 +229,8 @@
|
||||
callbacks: {
|
||||
title: (context) => prettyPrintDays(context[0].parsed.x),
|
||||
label: (context) => context.dataset.label + ': ' + Math.round(context.parsed.y)
|
||||
}
|
||||
},
|
||||
filter: (context, idx, items) => Math.abs(context.parsed.x - items[0].parsed.x) < 0.5/24
|
||||
}
|
||||
},
|
||||
maintainAspectRatio: false
|
||||
|
Loading…
Reference in New Issue
Block a user