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 2019/10/18 08:40:58 UTC

[GitHub] [incubator-echarts] bcpelletier commented on issue #11420: Programmatically selecting countries with geo and map series

bcpelletier commented on issue #11420: Programmatically selecting countries with geo and map series
URL: https://github.com/apache/incubator-echarts/issues/11420#issuecomment-543603477
 
 
   I will try to explain.
   
   The functionality would be to allow to select and deselect countries modifying the underlaying data.
   
   In the case you have a "normal" map series e.g
   
   Series: [ {
   name: 'UD',
   type: 'map',
   map: 'world',
   data: [ { name : 'Spain', selected : true}] 
   }]
   
   The map would load with a country selected, in this case, Spain.
   
   But, if we have a series that references a geoIndex, echarts does not use the selected parameters and does not "pre-select" Spain
   
     geo: {
     map: 'world',
     roam: true,
   ...},
   Series: [ 
   {
   geoIndex: 0,
   data: [ { name : 'Spain', selected : true}] 
   }
   
   Btw if geoIndex is used there isn't any way of selecting a country programmatically, "mapSelect" action doesn't work and "highlight" action works but "deselects" once resize() is called (kind of useless imo)
   
   So at least this would allow to re-merge the data with selected so the map can be controlled apart from the end user "clicking" on the map.
   
   Hope that I have explained myself.
   
   Thank you.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

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