Interactions
To start listening for interactions on any chart, provide the appropriate [SeriesType]InteractionEvents
class to the interactionEvents
parameter of any Series
.
For example, BarSeries
will accept interactionEvents
of type BarInteractionEvents
.
Look into interaction guides of individual charts to learn more about chart-specific interaction details.
Interaction Events
Every InteractionEvents
class supports these types of interaction callbacks.
Event | Description |
---|---|
| Called when the pointer that will trigger a tap gesture comes in contact with the screen. |
| Called when the pointer that will trigger a tap gesture stops making contact with the screen. |
| Call after the tap gesture is completed, i.e. right after |
| Called when a double tap gesture is detected. |
| Called when a pointer comes in contact with the screen and starts to move. |
| Called when the pointer location is updated for the pointer that started the drag gesture. |
| Called when the pointer that started the drag gesture stops moving. |
| Called for every type of interaction event. |
Enabling and Disabling interactions
Along with the interaction callbacks, every InteractionEvents
class has a isEnabled
boolean to enable and disable interactions.
Interaction Result
Each InteractionEvent
callback will receive a Series
specific interaction result as an argument.
Look into interaction guides of individual charts to learn more about chart-specific interaction details provided to in the interaction result.
Each interaction result has
Property | Description |
---|---|
| The offset of the interaction relative to the chart |
| Relevant |
TouchInteractionType
TouchInteractionType
is an enum with the following values
tap
tapUp
tapDown
doubleTap
dragStart
drag
dragEnd
Last updated