Description of feature
Users expect to use dashboards to compare their data interactively, such as by hovering over one chart and seeing the related charts update. This type of synchronized cursor has been supported by many parts of Kibana, but Lens has not supported this yet. It's currently supported in TSVB, Stack Monitoring,
One example is in the Stack Monitoring application, where each of these charts has the same X axis. In this chart, there are no tooltips, and the legend is used to show the value at the current time:

Elastic-Charts has a storybook example which uses tooltips instead of updating the legend, which might work better for Lens:

How would this get exposed in Lens?
My preference is to make this behavior automatic for as many Lens charts as possible, so that users get this behavior by default. I would imagine that we can synchronize not just time series data, but any data on the X-axis. For example, if the user has built a dashboard for ecommerce data, we could synchronize all the product categories on the X axis. The default behavior would be to show the tooltips, not to update the values in the legend.
If we do want to allow some user choices, I imagine that there are the following choices users could make:
- Show the currently hovered value in the legend (off by default)
- Disable synchronized tooltips (on by default)
Implementation options
TSVB's implementation of synchronized cursors uses a mutable object called eventBus. Lens could use the same approach, which would create a separate cursor state for Lens and TSVB visualizations.
Alternatively, Lens could implement a set of UI actions that are triggered on hover, and these actions could be responded to by other Lens visualizations.
Finally, if we use the system of UI actions, we could potentially synchronize both Lens and TSVB visualizations.
Description of feature
Users expect to use dashboards to compare their data interactively, such as by hovering over one chart and seeing the related charts update. This type of synchronized cursor has been supported by many parts of Kibana, but Lens has not supported this yet. It's currently supported in TSVB, Stack Monitoring,
One example is in the Stack Monitoring application, where each of these charts has the same X axis. In this chart, there are no tooltips, and the legend is used to show the value at the current time:
Elastic-Charts has a storybook example which uses tooltips instead of updating the legend, which might work better for Lens:
How would this get exposed in Lens?
My preference is to make this behavior automatic for as many Lens charts as possible, so that users get this behavior by default. I would imagine that we can synchronize not just time series data, but any data on the X-axis. For example, if the user has built a dashboard for ecommerce data, we could synchronize all the product categories on the X axis. The default behavior would be to show the tooltips, not to update the values in the legend.
If we do want to allow some user choices, I imagine that there are the following choices users could make:
Implementation options
TSVB's implementation of synchronized cursors uses a mutable object called
eventBus. Lens could use the same approach, which would create a separate cursor state for Lens and TSVB visualizations.Alternatively, Lens could implement a set of UI actions that are triggered on hover, and these actions could be responded to by other Lens visualizations.
Finally, if we use the system of UI actions, we could potentially synchronize both Lens and TSVB visualizations.