apache / echarts

Apache ECharts is a powerful, interactive charting and data visualization library for browser
https://echarts.apache.org
Apache License 2.0
60.77k stars 19.62k forks source link

[Bug] #17289

Closed shareeftabakhi closed 2 years ago

shareeftabakhi commented 2 years ago

Version

5.3.2

Link to Minimal Reproduction

No response

Steps to Reproduce

  1. use that geo chart component 2.register the map 3.view the result

Current Behavior

Recently when I load the map I get a console error that says Cannot read properties of undefined (reading 'regions') at GeoCreator.getFilledRegions (geoCreator.js:252:16) note that it was working fine and suddenly it stopped

ChartOptions: any = { // backgroundColor: '#000', title: { text: '', left: 'center', textStyle: { color: '#2a333d' } }, geo: { map: 'world', roam: true, label: { emphasis: { show: false, } }, silent: true, itemStyle: { normal: { borderColor: '#111' }, emphasis: { areaColor: '#2a333d' }, }, }, series: [ { type: 'scatter', progressive: 1e6, coordinateSystem: 'geo', symbolSize: '15', zoomScale: 0.222, blendMode: 'source-over', large: true, postEffect: { enable: true }, dimensions: ['lng', 'lat'], silent: true, data: [] } ], };

this.client.get("/assets/worldmap.json").subscribe((data: any) => {
  var worldMap = echarts.getMap('world');
  if (worldMap == null) {
    echarts.registerMap('world', data);
  }
  this.LoadData();
});

// in load data
    this.ChartOptions.series[0].data.push(item);

<div echarts [options]="ChartOptions" [theme]="Theme" class="chart" *ngIf="ChartOptions" style="height:100%; width:100%" (chartInit)="OnChartInit($event)"></div>

Expected Behavior

Map Works Fine as before

Environment

- OS: Windows
- Browser: Chrome
- Framework:Angular

Any additional comments?

No response

echarts-bot[bot] commented 2 years ago

I'm sorry to close this issue for it lacks the necessary title. Please provide a descriptive and as concise as possible title to describe your problems or requests and then the maintainers or I will reopen this issue.

Every good bug report or feature request starts with a title. Your issue title is a critical element as it's the first thing maintainers see.

A good issue title makes it easier for maintainers to understand what the issue is, easily locate it, and know what steps they'll need to take to fix it.

Moreover, it's better to include keywords, as this makes it easier to find the issue self and similar issues in searches.