[BUG] labelColor when rendering an array of labels is not working
See original GitHub issueExpected Behavior
When returning an array of objects from labelColor
on tooltips.callbacks
, the squares should get the colour returned from the function.
Current Behavior
When returning an array from labelColor
on tooltips callbacks, all squares appear black.
Possible Solution
N/A
Steps to Reproduce (for bugs)
http://jsbin.com/xuqalax/edit?html,js,output
Context
I was trying to add thousand separators, and for that I needed to edit the label
callback on tooltips. I then realized I would also need to override labelColor
in order to get the previous behaviour, but it didn’t work as expected.
Environment
- Chart.js version: 2.5.0
- Browser name and version: Google Chrome Version 56.0.2924.87 (64-bit)
Issue Analytics
- State:
- Created 7 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
ChartJs error in displaying my array data - Stack Overflow
I have an error when I display my array with chartjs. its does not display my values in the graph but its does...
Read more >Using the labels layer - Napari
The labels layer allows you to take an array of integers and display each integer as a different random color, with the background...
Read more >(To be removed) Display labeled volume - MATLAB - MathWorks
A labelvolshow object displays labeled volumetric data and enables you to modify the appearance of the display.
Read more >Customising Doughnut Charts - AG Grid
Customising Doughnut Charts. This sections details how to customise doughnut charts in your applications. Doughnut Chart Option Interfaces.
Read more >GetMetricWidgetImage: Metric Widget Structure and Syntax
One metrics array can include 1–100 metrics and expressions. ... If this is not specified, the metric is given an auto-generated label that...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I’m also experiencing this same issue, all label colours are the same even though I am specifying an array of different colours.
This is still an issue, I believe. If you return an array in the
label
callback, it makes multiple labels, but there is no way to define multiple colors. They all have to be the same color.