elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
19.59k stars 8.1k forks source link

[Lens] Colormapping isn't working for custom ranges and multi-top values #187519

Open bhavyarm opened 1 month ago

bhavyarm commented 1 month ago

Kibana version: main

Browser version: chrome latest

Original install method (e.g. download page, yum, from source, etc.): from snapshots

Describe the bug: If you add custom ranges for lens bar charts, color mapping feature doesn't work. You have to turn it off to see the colors.

Steps to reproduce: (Followed this tutorial - https://www.elastic.co/guide/en/kibana/current/create-a-dashboard-of-panels-with-web-server-data.html#custom-ranges. The bug happens before the conversion to donut chart)

  1. Go to dashboard ->create viz-> lens -> select kibana sample data logs
  2. Drag bytes into vertical axis - change it into sum
  3. Drag bytes into breakdown field
  4. Click on bytes in breakdown and add custom ranges
  5. The chart is all grey
  6. Turn off the color mapping
  7. Chart is colorful again
Screenshot 2024-07-03 at 4 17 23 PM

https://github.com/elastic/kibana/assets/7074629/dea0329b-be2f-498a-a48f-51458454f546

elasticmachine commented 1 month ago

Pinging @elastic/kibana-visualizations (Team:Visualizations)

nickofthyme commented 1 month ago

Thanks @bhavyarm I can confirm the issue. Two additional observations:

image

I think this would be good to look at when we work on #179322

mbondyra commented 1 month ago

It also doesn't work for multitop values, here's the dashboard screenshot with all the cases I checked: image

In total, all the cases that don't work are:

  1. Unassigned multi top values for xy chart
  2. Unassigned multi top values for partition chart
  3. 'Other' for partition chart
  4. custom ranges - both unassigned and assigned, both xy and partition