You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2021/10/22 10:46:43 UTC

[GitHub] [echarts] KrzysztofMadejski opened a new issue #15926: VisualMap: compute colors depending on values

KrzysztofMadejski opened a new issue #15926:
URL: https://github.com/apache/echarts/issues/15926


   ### What problem does this feature solve?
   Sometimes I do not know all the values that will come from the backend. Still, I'd like specific values/categories to have stable colors no matter how many or in which order will be retrieved. 
   
   Currently I do have defined colors for a few values and for the rest I'm hashing the values and generating unique color codes, but I have to do it by generating `chart/series.color` property based on the data. I'd prefer to have a native way of doing it in ECharts.
   
   ### What does the proposed API look like?
   Introduce third way of mapping next to  'Linear Mapping' and 'Table Mapping'. It could be called 'Functional Mapping'.
   
   Each of the visual channels (color, symbol, etc.) could take a function apart from an array or a map. Implementation would be very similar to Table Mapping, but instead of:
   ```javascript
   channel[value]
   ```
   would do
   ```javascript
   channel(value)
   ```
   
   Seems like a relatively easy change.
   <!-- This issue is generated by echarts-issue-helper. DO NOT REMOVE -->
   <!-- This issue is in English. DO NOT REMOVE -->


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [echarts] pissang commented on issue #15926: VisualMap: compute colors depending on values

Posted by GitBox <gi...@apache.org>.
pissang commented on issue #15926:
URL: https://github.com/apache/echarts/issues/15926#issuecomment-951503781


   It's a useful proposal that we have been considering for a while. Currently `itemStyle.color` can be a callback function to have similar effect.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [echarts] echarts-bot[bot] commented on issue #15926: VisualMap: compute colors depending on values

Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] commented on issue #15926:
URL: https://github.com/apache/echarts/issues/15926#issuecomment-949507657


   Hi! We've received your issue and please be patient to get responded. 🎉
   The average response time is expected to be within one day for weekdays.
   
   In the meanwhile, please make sure that it contains **a minimum reproducible demo** and necessary **images** to illustrate. Otherwise, our committers will ask you to do so.
   
   *A minimum reproducible demo* should contain as little data and components as possible but can still illustrate your problem. This is the best way for us to reproduce it and solve the problem faster.
   
   You may also check out the [API](http://echarts.apache.org/api.html) and [chart option](http://echarts.apache.org/option.html) to get the answer.
   
   If you don't get helped for a long time (over a week) or have an urgent question to ask, you may also send an email to dev@echarts.apache.org. Please attach the issue link if it's a technical question.
   
   If you are interested in the project, you may also subscribe to our [mailing list](https://echarts.apache.org/en/maillist.html).
   
   Have a nice day! 🍵


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org