BubbleChartConfig.fromJson constructor
BubbleChartConfig.fromJson(
- Map<String, dynamic> json
)
Implementation
factory BubbleChartConfig.fromJson(Map<String, dynamic> json) {
final series = _parseBubbleSeries(json);
return BubbleChartConfig(
bubbleSeries: series,
minBubbleRadius: JsonValue.doubleOrNull(json['minBubbleRadius']) ?? 4,
maxBubbleRadius: JsonValue.doubleOrNull(json['maxBubbleRadius']) ?? 40,
showLabels: JsonValue.boolOrNull(json['showLabels']) ?? false,
title: json['title'] != null ? TitlesData.fromJson(json['title']) : null,
tooltip: json['tooltip'] != null
? ChartTooltip.fromJson(json['tooltip'])
: null,
legend: json['legend'] != null
? ChartLegend.fromJson(json['legend'])
: null,
toolbox: json['toolbox'] != null
? ChartToolbox.fromJson(json['toolbox'])
: null,
grid: json['grid'] != null ? GridData.fromJson(json['grid']) : null,
);
}