Skip to content

Commit

Permalink
Add missing mouse events to CoreChartOptions.events type (#10124)
Browse files Browse the repository at this point in the history
* add missing mouse events to CoreChartOptions.events type

* allow all html event names in CoreChartOptions.events
  • Loading branch information
jmorel committed Feb 9, 2022
1 parent 7d3a1b8 commit b1876a4
Showing 1 changed file with 1 addition and 14 deletions.
15 changes: 1 addition & 14 deletions types/index.esm.d.ts
Expand Up @@ -1493,20 +1493,7 @@ export interface CoreChartOptions<TType extends ChartType> extends ParsingOption
* The events option defines the browser events that the chart should listen to for tooltips and hovering.
* @default ['mousemove', 'mouseout', 'click', 'touchstart', 'touchmove']
*/
events: (
'mousemove' |
'mouseout' |
'click' |
'touchstart' |
'touchmove' |
'touchend' |
'pointerenter' |
'pointerdown' |
'pointermove' |
'pointerup' |
'pointerleave' |
'pointerout'
)[];
events: (keyof HTMLElementEventMap)[]

/**
* Called when any of the events fire. Passed the event, an array of active elements (bars, points, etc), and the chart.
Expand Down

0 comments on commit b1876a4

Please sign in to comment.