Skip to content

Commit

Permalink
upgraded deps, fixed linter issues, added repaint boundaries to all c…
Browse files Browse the repository at this point in the history
…harts
  • Loading branch information
OlehMarch committed Nov 9, 2023
1 parent 92394f2 commit 99c92db
Show file tree
Hide file tree
Showing 18 changed files with 150 additions and 155 deletions.
11 changes: 3 additions & 8 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ void main() {
}

class App extends StatelessWidget {
const App({Key? key}) : super(key: key);
const App({super.key});

@override
Widget build(BuildContext context) {
Expand All @@ -29,14 +29,9 @@ class App extends StatelessWidget {
}
}

class HomePage extends StatefulWidget {
const HomePage({Key? key}) : super(key: key);
class HomePage extends StatelessWidget {
const HomePage({super.key});

@override
_HomePageState createState() => _HomePageState();
}

class _HomePageState extends State<HomePage> {
@override
Widget build(BuildContext context) {
return const ExampleScaffold(
Expand Down
24 changes: 12 additions & 12 deletions example/lib/src/bar_chart.dart
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ final _data = BehaviorSubject<BarChartData>.seeded(BarChartData(
));

class BarChartExample extends StatelessWidget {
const BarChartExample({Key? key}) : super(key: key);
const BarChartExample({super.key});

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -68,7 +68,7 @@ class BarChartExample extends StatelessWidget {
}

class _Chart extends StatelessWidget {
const _Chart({Key? key}) : super(key: key);
const _Chart();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -99,7 +99,7 @@ class _Chart extends StatelessWidget {
}

class _GeneralDataSetupGroup extends StatelessWidget {
const _GeneralDataSetupGroup({Key? key}) : super(key: key);
const _GeneralDataSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -255,7 +255,7 @@ class _GeneralDataSetupGroup extends StatelessWidget {
}

class _GeneralSettingsSetupGroup extends StatelessWidget {
const _GeneralSettingsSetupGroup({Key? key}) : super(key: key);
const _GeneralSettingsSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -341,7 +341,7 @@ class _GeneralSettingsSetupGroup extends StatelessWidget {
}

class _BarAlignmentSetupGroup extends StatelessWidget {
const _BarAlignmentSetupGroup({Key? key}) : super(key: key);
const _BarAlignmentSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -371,7 +371,7 @@ class _BarAlignmentSetupGroup extends StatelessWidget {
}

class _BarFitSetupGroup extends StatelessWidget {
const _BarFitSetupGroup({Key? key}) : super(key: key);
const _BarFitSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -400,7 +400,7 @@ class _BarFitSetupGroup extends StatelessWidget {
}

class _YAxisLayoutSetupGroup extends StatelessWidget {
const _YAxisLayoutSetupGroup({Key? key}) : super(key: key);
const _YAxisLayoutSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -430,7 +430,7 @@ class _YAxisLayoutSetupGroup extends StatelessWidget {
}

class _AxisDivisionsEdgesSetupGroup extends StatelessWidget {
const _AxisDivisionsEdgesSetupGroup({Key? key}) : super(key: key);
const _AxisDivisionsEdgesSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -460,7 +460,7 @@ class _AxisDivisionsEdgesSetupGroup extends StatelessWidget {
}

class _GridStyleSetupGroup extends StatelessWidget {
const _GridStyleSetupGroup({Key? key}) : super(key: key);
const _GridStyleSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -507,7 +507,7 @@ class _GridStyleSetupGroup extends StatelessWidget {
}

class _AxisStyleSetupGroup extends StatelessWidget {
const _AxisStyleSetupGroup({Key? key}) : super(key: key);
const _AxisStyleSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -596,7 +596,7 @@ class _AxisStyleSetupGroup extends StatelessWidget {
}

class _BarStyleSetupGroup extends StatelessWidget {
const _BarStyleSetupGroup({Key? key}) : super(key: key);
const _BarStyleSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -811,7 +811,7 @@ class _BarStyleSetupGroup extends StatelessWidget {
}

class _BardBorderSetupGroup extends StatelessWidget {
const _BardBorderSetupGroup({Key? key}) : super(key: key);
const _BardBorderSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down
14 changes: 7 additions & 7 deletions example/lib/src/gauge_chart.dart
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ final _data = BehaviorSubject<GaugeChartData>.seeded(
);

class GaugeChartExample extends StatelessWidget {
const GaugeChartExample({Key? key}) : super(key: key);
const GaugeChartExample({super.key});

@override
Widget build(BuildContext context) {
Expand All @@ -51,7 +51,7 @@ class GaugeChartExample extends StatelessWidget {
}

class _Chart extends StatelessWidget {
const _Chart({Key? key}) : super(key: key);
const _Chart();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -90,7 +90,7 @@ class _Chart extends StatelessWidget {
}

class _GeneralDataSetupGroup extends StatelessWidget {
const _GeneralDataSetupGroup({Key? key}) : super(key: key);
const _GeneralDataSetupGroup();

List<double> getRandomizedData({required bool fixedQty}) {
if (fixedQty) {
Expand Down Expand Up @@ -141,7 +141,7 @@ class _GeneralDataSetupGroup extends StatelessWidget {
}

class _GeneralSettingsSetupGroup extends StatelessWidget {
const _GeneralSettingsSetupGroup({Key? key}) : super(key: key);
const _GeneralSettingsSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -213,7 +213,7 @@ class _GeneralSettingsSetupGroup extends StatelessWidget {
}

class _BackgroundStyleSetupGroup extends StatelessWidget {
const _BackgroundStyleSetupGroup({Key? key}) : super(key: key);
const _BackgroundStyleSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -271,7 +271,7 @@ class _BackgroundStyleSetupGroup extends StatelessWidget {
}

class _BackgroundBorderStyleSetupGroup extends StatelessWidget {
const _BackgroundBorderStyleSetupGroup({Key? key}) : super(key: key);
const _BackgroundBorderStyleSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -392,7 +392,7 @@ class _BackgroundBorderStyleSetupGroup extends StatelessWidget {
}

class _SectionStyleSetupGroup extends StatelessWidget {
const _SectionStyleSetupGroup({Key? key}) : super(key: key);
const _SectionStyleSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down
16 changes: 8 additions & 8 deletions example/lib/src/line_chart.dart
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ final _data = BehaviorSubject<LineChartData>.seeded(LineChartData(
));

class LineChartExample extends StatelessWidget {
const LineChartExample({Key? key}) : super(key: key);
const LineChartExample({super.key});

@override
Widget build(BuildContext context) {
Expand All @@ -78,7 +78,7 @@ class LineChartExample extends StatelessWidget {
}

class _Chart extends StatelessWidget {
const _Chart({Key? key}) : super(key: key);
const _Chart();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -109,7 +109,7 @@ class _Chart extends StatelessWidget {
}

class _GeneralDataSetupGroup extends StatelessWidget {
const _GeneralDataSetupGroup({Key? key}) : super(key: key);
const _GeneralDataSetupGroup();

Map<DateTime, double> getRandomizedData({required bool positive}) {
final year = DateTime.now().year;
Expand Down Expand Up @@ -241,7 +241,7 @@ class _GeneralDataSetupGroup extends StatelessWidget {
}

class _GridTypeSetupGroup extends StatelessWidget {
const _GridTypeSetupGroup({Key? key}) : super(key: key);
const _GridTypeSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -269,7 +269,7 @@ class _GridTypeSetupGroup extends StatelessWidget {
}

class _DataTypeSetupGroup extends StatelessWidget {
const _DataTypeSetupGroup({Key? key}) : super(key: key);
const _DataTypeSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -297,7 +297,7 @@ class _DataTypeSetupGroup extends StatelessWidget {
}

class _GeneralSettingsSetupGroup extends StatelessWidget {
const _GeneralSettingsSetupGroup({Key? key}) : super(key: key);
const _GeneralSettingsSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -388,7 +388,7 @@ class _GeneralSettingsSetupGroup extends StatelessWidget {
}

class _AxisDivisionsEdgesSetupGroup extends StatelessWidget {
const _AxisDivisionsEdgesSetupGroup({Key? key}) : super(key: key);
const _AxisDivisionsEdgesSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down Expand Up @@ -418,7 +418,7 @@ class _AxisDivisionsEdgesSetupGroup extends StatelessWidget {
}

class _LimitLabelSnapPositionSetupGroup extends StatelessWidget {
const _LimitLabelSnapPositionSetupGroup({Key? key}) : super(key: key);
const _LimitLabelSnapPositionSetupGroup();

@override
Widget build(BuildContext context) {
Expand Down
7 changes: 3 additions & 4 deletions example/lib/src/scaffolds/example_scaffold.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ final _selected = BehaviorSubject<int>.seeded(0);

class ExampleScaffold extends StatelessWidget {
const ExampleScaffold({
Key? key,
super.key,
required this.tabs,
}) : super(key: key);
});

final Map<String, Widget> tabs;

Expand Down Expand Up @@ -45,9 +45,8 @@ class ExampleScaffold extends StatelessWidget {

class _AppMenu extends StatelessWidget implements PreferredSizeWidget {
const _AppMenu({
Key? key,
required this.tabs,
}) : super(key: key);
});

final List<String> tabs;

Expand Down
13 changes: 6 additions & 7 deletions example/lib/src/scaffolds/setup_scaffold.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ const setupWidth = 315.0;

class SetupScaffold extends StatefulWidget {
const SetupScaffold({
Key? key,
super.key,
required this.setupChildren,
required this.body,
}) : super(key: key);
});

final List<Widget> setupChildren;
final Widget body;
Expand Down Expand Up @@ -121,10 +121,9 @@ class _SetupScaffoldState extends State<SetupScaffold>

class _Setup extends StatelessWidget {
const _Setup({
Key? key,
required this.controller,
required this.children,
}) : super(key: key);
});

final ScrollController controller;
final List<Widget> children;
Expand Down Expand Up @@ -157,7 +156,7 @@ class _Setup extends StatelessWidget {
}

class SetupDivider extends StatelessWidget {
const SetupDivider({Key? key}) : super(key: key);
const SetupDivider({super.key});

@override
Widget build(BuildContext context) {
Expand All @@ -171,10 +170,10 @@ class SetupDivider extends StatelessWidget {

class SetupGroup extends StatelessWidget {
const SetupGroup({
Key? key,
super.key,
required this.title,
required this.children,
}) : super(key: key);
});

final String title;
final List<Widget> children;
Expand Down
4 changes: 2 additions & 2 deletions example/lib/src/widgets/button.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ import 'package:flutter/material.dart';

class Button extends StatelessWidget {
const Button({
Key? key,
super.key,
required this.title,
required this.onPressed,
}) : super(key: key);
});

final Widget title;
final VoidCallback onPressed;
Expand Down
7 changes: 3 additions & 4 deletions example/lib/src/widgets/color_list_tile.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ import 'package:flutter_colorpicker/flutter_colorpicker.dart';

class ColorListTile extends StatelessWidget {
const ColorListTile({
Key? key,
super.key,
this.title,
required this.value,
required this.onChanged,
}) : super(key: key);
});

final Widget? title;
final Color value;
Expand Down Expand Up @@ -43,10 +43,9 @@ class ColorListTile extends StatelessWidget {

class _Dialog extends StatefulWidget {
const _Dialog({
Key? key,
required this.title,
required this.value,
}) : super(key: key);
});

final Widget? title;
final Color value;
Expand Down
Loading

0 comments on commit 99c92db

Please sign in to comment.