[Legend] improve handling for legend rendered value #2044
Labels
:all
Applies to all chart types
bug
Something isn't working
enhancement
New feature or request
kibana cross issue
Has a Kibana issue counterpart
:legend
Legend related issue
Is your feature request related to a problem? Please describe.
Currently, our legend can be configured to show a value. We internally call it
extra
and a hardcoded logic picks that value from the dataset only if that value coincides with the domain max.This logic works well if the X domain is computed automatically from the dataset itself, but instead, if the domain is passed through the
xDomain
property of theSettings
and the max doesn't correspond to the last value in your dataset then this value is not represented in the legend.This is particularly evident in Kibana, where the time window is configured by the user in Lens and, due to the way time-picker works there are cases where the domain max will not coincide with the latest datapoint (see elastic/kibana#153079
There are a few problems here:
Describe the solution you'd like
Describe alternatives you've considered
Kibana Cross Issues
elastic/kibana#153079
The text was updated successfully, but these errors were encountered: