fuxiao82 commented on issue #3966:
URL: https://github.com/apache/echarts/issues/3966#issuecomment-962977271
const regisOption: RegisOption = {
type: 'FeatureCollection',
crs,
features: world.map((item) => {
if (item.properties.name !== '俄罗斯') {
return item
}
item.geometry.coordinates.forEach((detail) => {
detail[0].forEach((itemDetail) => {
//地图坐标需要转换,经过分析,经度小于-20度的加上360就可以了!
if (itemDetail[0] < -20) {
itemDetail[0] += 360
}
})
})
return item
})
}
world like:
[{
"geometry": {
"type": "Polygon",
"coordinates":[...]
},
"properties": {
"name": "俄罗斯",
"childNum": 1
}
},{},{},...]
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]