mirror of
https://github.com/flutter/samples.git
synced 2025-11-08 22:09:06 +00:00
web/charts: Migrate to null safety (#921)
This commit is contained in:
@@ -22,10 +22,10 @@ import 'package:charts_flutter/flutter.dart' as charts;
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class ScatterPlotAnimationZoomChart extends StatelessWidget {
|
||||
final List<charts.Series> seriesList;
|
||||
final bool animate;
|
||||
final List<charts.Series<dynamic, num>> seriesList;
|
||||
final bool? animate;
|
||||
|
||||
const ScatterPlotAnimationZoomChart(this.seriesList, {this.animate, Key key})
|
||||
const ScatterPlotAnimationZoomChart(this.seriesList, {this.animate, Key? key})
|
||||
: super(key: key);
|
||||
|
||||
/// Creates a [ScatterPlotChart] with sample data and no transition.
|
||||
|
||||
@@ -26,10 +26,10 @@ import 'package:charts_flutter/flutter.dart' as charts;
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class BucketingAxisScatterPlotChart extends StatelessWidget {
|
||||
final List<charts.Series> seriesList;
|
||||
final bool animate;
|
||||
final List<charts.Series<dynamic, num>> seriesList;
|
||||
final bool? animate;
|
||||
|
||||
const BucketingAxisScatterPlotChart(this.seriesList, {this.animate, Key key})
|
||||
const BucketingAxisScatterPlotChart(this.seriesList, {this.animate, Key? key})
|
||||
: super(key: key);
|
||||
|
||||
/// Creates a [ScatterPlotChart] with sample data and no transition.
|
||||
|
||||
@@ -21,11 +21,11 @@ import 'package:charts_flutter/flutter.dart' as charts;
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class ComparisonPointsScatterPlotChart extends StatelessWidget {
|
||||
final List<charts.Series> seriesList;
|
||||
final bool animate;
|
||||
final List<charts.Series<dynamic, num>> seriesList;
|
||||
final bool? animate;
|
||||
|
||||
const ComparisonPointsScatterPlotChart(this.seriesList,
|
||||
{this.animate, Key key})
|
||||
{this.animate, Key? key})
|
||||
: super(key: key);
|
||||
|
||||
/// Creates a [ScatterPlotChart] with sample data and no transition.
|
||||
|
||||
@@ -32,10 +32,10 @@ import 'package:charts_flutter/flutter.dart' as charts;
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class ShapesScatterPlotChart extends StatelessWidget {
|
||||
final List<charts.Series> seriesList;
|
||||
final bool animate;
|
||||
final List<charts.Series<dynamic, num>> seriesList;
|
||||
final bool? animate;
|
||||
|
||||
const ShapesScatterPlotChart(this.seriesList, {this.animate, Key key})
|
||||
const ShapesScatterPlotChart(this.seriesList, {this.animate, Key? key})
|
||||
: super(key: key);
|
||||
|
||||
/// Creates a [ScatterPlotChart] with sample data and no transition.
|
||||
@@ -196,9 +196,9 @@ class LinearSales {
|
||||
final int year;
|
||||
final int sales;
|
||||
final double radius;
|
||||
final String shape;
|
||||
final charts.Color fillColor;
|
||||
final double strokeWidth;
|
||||
final String? shape;
|
||||
final charts.Color? fillColor;
|
||||
final double? strokeWidth;
|
||||
|
||||
LinearSales(this.year, this.sales, this.radius, this.shape, this.fillColor,
|
||||
this.strokeWidth);
|
||||
|
||||
@@ -21,10 +21,10 @@ import 'package:charts_flutter/flutter.dart' as charts;
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class SimpleScatterPlotChart extends StatelessWidget {
|
||||
final List<charts.Series> seriesList;
|
||||
final bool animate;
|
||||
final List<charts.Series<dynamic, num>> seriesList;
|
||||
final bool? animate;
|
||||
|
||||
const SimpleScatterPlotChart(this.seriesList, {this.animate, Key key})
|
||||
const SimpleScatterPlotChart(this.seriesList, {this.animate, Key? key})
|
||||
: super(key: key);
|
||||
|
||||
/// Creates a [ScatterPlotChart] with sample data and no transition.
|
||||
|
||||
Reference in New Issue
Block a user