MCPcopy
hub / github.com/apache/echarts / init

Method init

src/coord/geo/GeoModel.ts:247–260  ·  view source on GitHub ↗
(option: GeoOption, parentModel: Model, ecModel: GlobalModel)

Source from the content-addressed store, hash-verified

245 };
246
247 init(option: GeoOption, parentModel: Model, ecModel: GlobalModel): void {
248 this.mergeDefaultAndTheme(option, ecModel);
249
250 const source = geoSourceManager.getGeoResource(option.map);
251 if (source && source.type === 'geoJSON') {
252 const itemStyle = option.itemStyle = option.itemStyle || {};
253 if (!('color' in itemStyle)) {
254 itemStyle.color = option.defaultItemStyleColor || tokens.color.backgroundTint;
255 }
256 }
257
258 // Default label emphasis `show`
259 modelUtil.defaultEmphasis(option, 'label', ['show']);
260 }
261
262 optionUpdated(): void {
263 const option = this.option;

Callers 4

constructorMethod · 0.45
setOptionMethod · 0.45
getConnectedDataURLMethod · 0.45
doPrepareMethod · 0.45

Calls 1

mergeDefaultAndThemeMethod · 0.45

Tested by

no test coverage detected