From 58bc5d7a5864a0c52917837104201ef2a2883eab Mon Sep 17 00:00:00 2001 From: Brett Morgan Date: Fri, 13 May 2022 12:31:56 -0700 Subject: [PATCH] Deps update, utilize `super.key` (#1265) * Deps update, utilize `super.key` * `flutter format` --- .../flutter_module_using_plugin/pubspec.lock | 29 +++++++---------- .../flutter_module_using_plugin/pubspec.yaml | 2 +- animations/lib/main.dart | 6 ++-- .../lib/src/basics/01_animated_container.dart | 2 +- .../lib/src/basics/02_page_route_builder.dart | 2 +- .../src/basics/03_animation_controller.dart | 2 +- animations/lib/src/basics/04_tweens.dart | 2 +- .../lib/src/basics/05_animated_builder.dart | 2 +- .../lib/src/basics/06_custom_tween.dart | 2 +- .../lib/src/basics/07_tween_sequence.dart | 2 +- .../lib/src/basics/08_fade_transition.dart | 2 +- animations/lib/src/misc/animated_list.dart | 2 +- .../lib/src/misc/animated_positioned.dart | 2 +- .../lib/src/misc/animated_switcher.dart | 2 +- animations/lib/src/misc/card_swipe.dart | 7 ++--- animations/lib/src/misc/carousel.dart | 4 +-- animations/lib/src/misc/curved_animation.dart | 2 +- animations/lib/src/misc/expand_card.dart | 4 +-- animations/lib/src/misc/focus_image.dart | 6 ++-- animations/lib/src/misc/hero_animation.dart | 4 +-- .../lib/src/misc/physics_card_drag.dart | 4 +-- .../lib/src/misc/repeating_animation.dart | 2 +- desktop_photo_search/fluent_ui/lib/main.dart | 4 +-- .../lib/src/widgets/photo_details.dart | 4 +-- .../lib/src/widgets/photo_search_dialog.dart | 2 +- .../lib/src/widgets/policy_dialog.dart | 2 +- .../fluent_ui/lib/src/widgets/split.dart | 5 ++- .../lib/src/widgets/unsplash_notice.dart | 4 +-- .../src/widgets/unsplash_search_content.dart | 2 +- .../fluent_ui/test/widget_test.dart | 3 +- desktop_photo_search/material/lib/main.dart | 4 +-- .../lib/src/widgets/photo_details.dart | 4 +-- .../lib/src/widgets/photo_search_dialog.dart | 2 +- .../lib/src/widgets/policy_dialog.dart | 2 +- .../material/lib/src/widgets/split.dart | 5 ++- .../lib/src/widgets/unsplash_notice.dart | 4 +-- .../src/widgets/unsplash_search_content.dart | 2 +- .../material/test/widget_test.dart | 3 +- .../federated_plugin/example/lib/main.dart | 2 +- .../federated_plugin/example/pubspec.lock | 6 ++-- .../federated_plugin/example/pubspec.yaml | 2 +- experimental/web_dashboard/pubspec.lock | 16 +++++----- flutter_maps_firestore/lib/main.dart | 20 ++++++------ form_app/lib/main.dart | 6 ++-- form_app/lib/src/autofill.dart | 2 +- form_app/lib/src/form_widgets.dart | 2 +- form_app/lib/src/sign_in_http.dart | 4 +-- form_app/lib/src/validation.dart | 2 +- game_template/lib/main.dart | 4 +-- .../lib/src/ads/banner_ad_widget.dart | 2 +- .../lib/src/app_lifecycle/app_lifecycle.dart | 2 +- .../level_selection_screen.dart | 2 +- .../lib/src/main_menu/main_menu_screen.dart | 2 +- .../src/play_session/play_session_screen.dart | 2 +- .../lib/src/settings/custom_name_dialog.dart | 2 +- .../lib/src/settings/settings_screen.dart | 7 ++--- game_template/lib/src/style/confetti.dart | 4 +-- .../lib/src/style/my_transition.dart | 3 +- .../lib/src/style/responsive_screen.dart | 4 +-- .../lib/src/win_game/win_game_screen.dart | 4 +-- game_template/pubspec.yaml | 2 +- infinite_list/lib/main.dart | 4 +-- infinite_list/lib/src/item_tile.dart | 4 +-- ios_app_clip/lib/main.dart | 2 +- isolate_example/lib/data_transfer_page.dart | 6 ++-- .../lib/infinite_process_page.dart | 6 ++-- isolate_example/lib/main.dart | 2 +- isolate_example/lib/performance_page.dart | 4 +-- jsonexample/lib/main.dart | 4 +-- jsonexample/lib/tab_pages.dart | 20 ++++++------ jsonexample/lib/widgets.dart | 12 +++---- .../lib/color_palettes_screen.dart | 11 +++---- material_3_demo/lib/component_screen.dart | 24 ++++++-------- material_3_demo/lib/elevation_screen.dart | 8 ++--- material_3_demo/lib/main.dart | 2 +- material_3_demo/lib/typography_screen.dart | 6 ++-- navigation_and_routing/lib/src/app.dart | 2 +- navigation_and_routing/lib/src/auth.dart | 8 ++--- .../lib/src/routing/route_state.dart | 8 ++--- .../lib/src/screens/author_details.dart | 4 +-- .../lib/src/screens/authors.dart | 2 +- .../lib/src/screens/book_details.dart | 4 +-- .../lib/src/screens/books.dart | 4 +-- .../lib/src/screens/navigator.dart | 4 +-- .../lib/src/screens/scaffold.dart | 4 +-- .../lib/src/screens/scaffold_body.dart | 4 +-- .../lib/src/screens/settings.dart | 6 ++-- .../lib/src/screens/sign_in.dart | 4 +-- .../lib/src/widgets/author_list.dart | 4 +-- .../lib/src/widgets/book_list.dart | 4 +-- navigation_and_routing/pubspec.lock | 31 +++++++------------ null_safety/null_safe_app/lib/badapp.dart | 2 +- null_safety/null_safe_app/lib/goodapp.dart | 2 +- place_tracker/lib/place_details.dart | 21 +++++-------- place_tracker/lib/place_list.dart | 11 +++---- place_tracker/lib/place_map.dart | 13 +++----- place_tracker/lib/place_tracker_app.dart | 4 +-- place_tracker/pubspec.lock | 16 +++++----- platform_channels/lib/main.dart | 6 ++-- .../lib/src/add_pet_details.dart | 2 +- .../lib/src/event_channel_demo.dart | 2 +- .../lib/src/method_channel_demo.dart | 2 +- .../lib/src/pet_list_screen.dart | 4 +-- .../lib/src/platform_image_demo.dart | 2 +- platform_design/lib/main.dart | 4 +-- platform_design/lib/news_tab.dart | 2 +- platform_design/lib/profile_tab.dart | 8 ++--- platform_design/lib/settings_tab.dart | 2 +- platform_design/lib/song_detail_tab.dart | 4 +-- platform_design/lib/songs_tab.dart | 2 +- platform_design/lib/widgets.dart | 14 ++++----- platform_view_swift/lib/main.dart | 4 +-- provider_counter/lib/main.dart | 4 +-- provider_shopper/lib/main.dart | 2 +- provider_shopper/lib/screens/cart.dart | 2 +- provider_shopper/lib/screens/catalog.dart | 6 ++-- provider_shopper/lib/screens/login.dart | 2 +- simplistic_calculator/lib/main.dart | 6 ++-- simplistic_calculator/pubspec.lock | 6 ++-- simplistic_calculator/pubspec.yaml | 4 +-- simplistic_calculator/typer/main_01.dart | 2 +- simplistic_calculator/typer/main_02.dart | 2 +- simplistic_calculator/typer/main_03.dart | 2 +- simplistic_calculator/typer/main_04.dart | 2 +- simplistic_calculator/typer/main_05.dart | 2 +- simplistic_calculator/typer/main_06.dart | 2 +- simplistic_calculator/typer/main_07.dart | 2 +- simplistic_calculator/typer/main_08.dart | 2 +- simplistic_calculator/typer/main_09.dart | 2 +- simplistic_calculator/typer/main_10.dart | 2 +- simplistic_calculator/typer/main_11.dart | 2 +- simplistic_calculator/typer/main_12.dart | 2 +- simplistic_calculator/typer/main_13.dart | 2 +- simplistic_calculator/typer/main_14.dart | 2 +- simplistic_calculator/typer/main_15.dart | 2 +- simplistic_calculator/typer/main_16.dart | 2 +- simplistic_calculator/typer/main_17.dart | 2 +- simplistic_calculator/typer/main_18.dart | 2 +- simplistic_calculator/typer/main_19.dart | 2 +- simplistic_calculator/typer/main_20.dart | 2 +- simplistic_calculator/typer/main_21.dart | 2 +- simplistic_calculator/typer/main_22.dart | 2 +- simplistic_calculator/typer/main_23.dart | 2 +- simplistic_calculator/typer/main_24.dart | 2 +- simplistic_calculator/typer/main_25.dart | 2 +- simplistic_calculator/typer/main_26.dart | 2 +- simplistic_calculator/typer/main_27.dart | 2 +- simplistic_calculator/typer/main_28.dart | 2 +- simplistic_calculator/typer/main_29.dart | 2 +- simplistic_calculator/typer/main_30.dart | 2 +- simplistic_calculator/typer/main_31.dart | 2 +- simplistic_calculator/typer/main_32.dart | 2 +- simplistic_calculator/typer/main_33.dart | 2 +- simplistic_calculator/typer/main_34.dart | 2 +- simplistic_calculator/typer/main_35.dart | 2 +- simplistic_calculator/typer/main_36.dart | 2 +- simplistic_calculator/typer/main_37.dart | 2 +- simplistic_calculator/typer/main_38.dart | 2 +- simplistic_calculator/typer/main_39.dart | 2 +- simplistic_calculator/typer/main_40.dart | 2 +- simplistic_calculator/typer/main_41.dart | 2 +- simplistic_calculator/typer/main_42.dart | 2 +- simplistic_calculator/typer/main_43.dart | 2 +- simplistic_calculator/typer/main_44.dart | 2 +- simplistic_calculator/typer/main_45.dart | 2 +- simplistic_calculator/typer/main_46.dart | 2 +- simplistic_calculator/typer/main_47.dart | 2 +- simplistic_calculator/typer/main_48.dart | 2 +- simplistic_calculator/typer/main_49.dart | 2 +- simplistic_calculator/typer/main_50.dart | 2 +- simplistic_calculator/typer/main_51.dart | 2 +- simplistic_calculator/typer/main_52.dart | 2 +- simplistic_calculator/typer/main_53.dart | 2 +- simplistic_calculator/typer/main_54.dart | 2 +- simplistic_calculator/typer/main_55.dart | 2 +- simplistic_calculator/typer/main_56.dart | 2 +- simplistic_calculator/typer/main_57.dart | 2 +- simplistic_calculator/typer/main_58.dart | 2 +- simplistic_calculator/typer/main_59.dart | 2 +- simplistic_calculator/typer/main_60.dart | 2 +- simplistic_calculator/typer/main_61.dart | 2 +- simplistic_calculator/typer/main_62.dart | 2 +- simplistic_calculator/typer/main_63.dart | 2 +- simplistic_calculator/typer/main_64.dart | 2 +- simplistic_calculator/typer/main_65.dart | 2 +- simplistic_calculator/typer/main_66.dart | 2 +- simplistic_calculator/typer/main_67.dart | 2 +- simplistic_calculator/typer/main_68.dart | 2 +- simplistic_calculator/typer/main_69.dart | 2 +- simplistic_calculator/typer/main_70.dart | 2 +- simplistic_calculator/typer/main_71.dart | 2 +- simplistic_calculator/typer/main_72.dart | 2 +- simplistic_calculator/typer/main_73.dart | 2 +- simplistic_calculator/typer/main_74.dart | 2 +- simplistic_calculator/typer/main_75.dart | 2 +- simplistic_calculator/typer/main_76.dart | 2 +- simplistic_calculator/typer/main_77.dart | 2 +- simplistic_calculator/typer/main_78.dart | 2 +- simplistic_calculator/typer/main_79.dart | 2 +- simplistic_calculator/typer/main_80.dart | 2 +- simplistic_calculator/typer/main_81.dart | 2 +- simplistic_calculator/typer/main_82.dart | 2 +- simplistic_calculator/typer/main_83.dart | 2 +- simplistic_calculator/typer/main_84.dart | 2 +- simplistic_calculator/typer/main_85.dart | 2 +- simplistic_calculator/typer/main_86.dart | 2 +- simplistic_calculator/typer/main_87.dart | 2 +- simplistic_calculator/typer/main_88.dart | 2 +- simplistic_calculator/typer/main_89.dart | 2 +- simplistic_calculator/typer/main_90.dart | 2 +- simplistic_calculator/typer/main_91.dart | 2 +- simplistic_calculator/typer/main_92.dart | 2 +- simplistic_calculator/typer/main_93.dart | 2 +- simplistic_calculator/typer/main_94.dart | 4 +-- simplistic_editor/lib/basic_text_field.dart | 4 +-- .../lib/basic_text_input_client.dart | 8 ++--- simplistic_editor/lib/main.dart | 8 ++--- .../text_editing_delta_history_manager.dart | 7 ++--- .../lib/toggle_button_state_manager.dart | 7 ++--- simplistic_editor/pubspec.lock | 6 ++-- testing_app/lib/main.dart | 2 +- testing_app/lib/screens/favorites.dart | 4 +-- testing_app/lib/screens/home.dart | 4 +-- veggieseasons/lib/main.dart | 2 +- veggieseasons/lib/screens/details.dart | 7 ++--- veggieseasons/lib/screens/favorites.dart | 2 +- veggieseasons/lib/screens/home.dart | 2 +- veggieseasons/lib/screens/list.dart | 2 +- veggieseasons/lib/screens/search.dart | 2 +- veggieseasons/lib/screens/settings.dart | 7 ++--- veggieseasons/lib/widgets/close_button.dart | 12 +++---- veggieseasons/lib/widgets/settings_group.dart | 9 +++--- veggieseasons/lib/widgets/settings_item.dart | 10 +++--- veggieseasons/lib/widgets/trivia.dart | 2 +- veggieseasons/lib/widgets/veggie_card.dart | 11 +++---- .../lib/widgets/veggie_headline.dart | 6 ++-- web/_tool/common.dart | 2 +- web/_tool/pubspec.lock | 4 +-- web/_tool/pubspec.yaml | 2 +- web/samples_index/lib/src/data.dart | 4 +-- web/samples_index/lib/src/search.dart | 4 +-- web/samples_index/lib/src/util.dart | 2 +- web/samples_index/pubspec.yaml | 2 +- web/samples_index/tool/grind.dart | 2 +- 244 files changed, 449 insertions(+), 500 deletions(-) diff --git a/add_to_app/android_view/flutter_module_using_plugin/pubspec.lock b/add_to_app/android_view/flutter_module_using_plugin/pubspec.lock index a4b2afce4..bfd33437e 100644 --- a/add_to_app/android_view/flutter_module_using_plugin/pubspec.lock +++ b/add_to_app/android_view/flutter_module_using_plugin/pubspec.lock @@ -42,14 +42,14 @@ packages: name: collection url: "https://pub.dartlang.org" source: hosted - version: "1.15.0" + version: "1.16.0" fake_async: dependency: transitive description: name: fake_async url: "https://pub.dartlang.org" source: hosted - version: "1.2.0" + version: "1.3.0" flutter: dependency: "direct main" description: flutter @@ -61,7 +61,7 @@ packages: name: flutter_lints url: "https://pub.dartlang.org" source: hosted - version: "1.0.4" + version: "2.0.1" flutter_test: dependency: "direct dev" description: flutter @@ -78,14 +78,14 @@ packages: name: js url: "https://pub.dartlang.org" source: hosted - version: "0.6.3" + version: "0.6.4" lints: dependency: transitive description: name: lints url: "https://pub.dartlang.org" source: hosted - version: "1.0.1" + version: "2.0.0" matcher: dependency: transitive description: @@ -99,7 +99,7 @@ packages: name: material_color_utilities url: "https://pub.dartlang.org" source: hosted - version: "0.1.3" + version: "0.1.4" meta: dependency: transitive description: @@ -120,7 +120,7 @@ packages: name: path url: "https://pub.dartlang.org" source: hosted - version: "1.8.0" + version: "1.8.1" plugin_platform_interface: dependency: transitive description: @@ -153,7 +153,7 @@ packages: name: source_span url: "https://pub.dartlang.org" source: hosted - version: "1.8.1" + version: "1.8.2" stack_trace: dependency: transitive description: @@ -188,14 +188,7 @@ packages: name: test_api url: "https://pub.dartlang.org" source: hosted - version: "0.4.8" - typed_data: - dependency: transitive - description: - name: typed_data - url: "https://pub.dartlang.org" - source: hosted - version: "1.3.0" + version: "0.4.9" url_launcher: dependency: "direct main" description: @@ -258,7 +251,7 @@ packages: name: vector_math url: "https://pub.dartlang.org" source: hosted - version: "2.1.1" + version: "2.1.2" sdks: - dart: ">=2.14.0 <3.0.0" + dart: ">=2.17.0-206.0.dev <3.0.0" flutter: ">=2.10.0" diff --git a/add_to_app/android_view/flutter_module_using_plugin/pubspec.yaml b/add_to_app/android_view/flutter_module_using_plugin/pubspec.yaml index 5972c4e73..050e54c8b 100644 --- a/add_to_app/android_view/flutter_module_using_plugin/pubspec.yaml +++ b/add_to_app/android_view/flutter_module_using_plugin/pubspec.yaml @@ -16,7 +16,7 @@ dependencies: dev_dependencies: flutter_test: sdk: flutter - flutter_lints: ^1.0.3 + flutter_lints: ^2.0.1 flutter: uses-material-design: true diff --git a/animations/lib/main.dart b/animations/lib/main.dart index 659d3fa4f..4240ff09f 100644 --- a/animations/lib/main.dart +++ b/animations/lib/main.dart @@ -159,7 +159,7 @@ final allRoutes = { }; class AnimationSamples extends StatelessWidget { - const AnimationSamples({Key? key}) : super(key: key); + const AnimationSamples({super.key}); @override Widget build(BuildContext context) { @@ -175,7 +175,7 @@ class AnimationSamples extends StatelessWidget { } class HomePage extends StatelessWidget { - const HomePage({Key? key}) : super(key: key); + const HomePage({super.key}); @override Widget build(BuildContext context) { @@ -199,7 +199,7 @@ class HomePage extends StatelessWidget { class DemoTile extends StatelessWidget { final Demo demo; - const DemoTile({required this.demo, Key? key}) : super(key: key); + const DemoTile({required this.demo, super.key}); @override Widget build(BuildContext context) { diff --git a/animations/lib/src/basics/01_animated_container.dart b/animations/lib/src/basics/01_animated_container.dart index dd499abd5..f521de7c6 100644 --- a/animations/lib/src/basics/01_animated_container.dart +++ b/animations/lib/src/basics/01_animated_container.dart @@ -11,7 +11,7 @@ double generateMargin() => Random().nextDouble() * 64; Color generateColor() => Color(0xFFFFFFFF & Random().nextInt(0xFFFFFFFF)); class AnimatedContainerDemo extends StatefulWidget { - const AnimatedContainerDemo({Key? key}) : super(key: key); + const AnimatedContainerDemo({super.key}); static String routeName = '/basics/01_animated_container'; @override diff --git a/animations/lib/src/basics/02_page_route_builder.dart b/animations/lib/src/basics/02_page_route_builder.dart index b44171405..4675e4620 100644 --- a/animations/lib/src/basics/02_page_route_builder.dart +++ b/animations/lib/src/basics/02_page_route_builder.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class PageRouteBuilderDemo extends StatelessWidget { - const PageRouteBuilderDemo({Key? key}) : super(key: key); + const PageRouteBuilderDemo({super.key}); static const String routeName = '/basics/page_route_builder'; @override diff --git a/animations/lib/src/basics/03_animation_controller.dart b/animations/lib/src/basics/03_animation_controller.dart index 2cde3f785..c87d35256 100644 --- a/animations/lib/src/basics/03_animation_controller.dart +++ b/animations/lib/src/basics/03_animation_controller.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class AnimationControllerDemo extends StatefulWidget { - const AnimationControllerDemo({Key? key}) : super(key: key); + const AnimationControllerDemo({super.key}); static const String routeName = '/basics/animation_controller'; @override diff --git a/animations/lib/src/basics/04_tweens.dart b/animations/lib/src/basics/04_tweens.dart index 4806c6c1d..455fcb517 100644 --- a/animations/lib/src/basics/04_tweens.dart +++ b/animations/lib/src/basics/04_tweens.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class TweenDemo extends StatefulWidget { - const TweenDemo({Key? key}) : super(key: key); + const TweenDemo({super.key}); static const String routeName = '/basics/tweens'; @override diff --git a/animations/lib/src/basics/05_animated_builder.dart b/animations/lib/src/basics/05_animated_builder.dart index 9387f887c..9164098b0 100644 --- a/animations/lib/src/basics/05_animated_builder.dart +++ b/animations/lib/src/basics/05_animated_builder.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class AnimatedBuilderDemo extends StatefulWidget { - const AnimatedBuilderDemo({Key? key}) : super(key: key); + const AnimatedBuilderDemo({super.key}); static const String routeName = '/basics/animated_builder'; @override diff --git a/animations/lib/src/basics/06_custom_tween.dart b/animations/lib/src/basics/06_custom_tween.dart index d9c005a20..406a670e2 100644 --- a/animations/lib/src/basics/06_custom_tween.dart +++ b/animations/lib/src/basics/06_custom_tween.dart @@ -16,7 +16,7 @@ class TypewriterTween extends Tween { } class CustomTweenDemo extends StatefulWidget { - const CustomTweenDemo({Key? key}) : super(key: key); + const CustomTweenDemo({super.key}); static const String routeName = '/basics/custom_tweens'; @override diff --git a/animations/lib/src/basics/07_tween_sequence.dart b/animations/lib/src/basics/07_tween_sequence.dart index 0c59c1e26..de50fd3f8 100644 --- a/animations/lib/src/basics/07_tween_sequence.dart +++ b/animations/lib/src/basics/07_tween_sequence.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class TweenSequenceDemo extends StatefulWidget { - const TweenSequenceDemo({Key? key}) : super(key: key); + const TweenSequenceDemo({super.key}); static const String routeName = '/basics/chaining_tweens'; @override diff --git a/animations/lib/src/basics/08_fade_transition.dart b/animations/lib/src/basics/08_fade_transition.dart index 87a66c47f..d95dfad3e 100644 --- a/animations/lib/src/basics/08_fade_transition.dart +++ b/animations/lib/src/basics/08_fade_transition.dart @@ -7,7 +7,7 @@ import 'package:flutter/material.dart'; // Refer to the AnimatedWidget docs here - https://api.flutter.dev/flutter/widgets/AnimatedWidget-class.html // for examples of other common animated widgets. class FadeTransitionDemo extends StatefulWidget { - const FadeTransitionDemo({Key? key}) : super(key: key); + const FadeTransitionDemo({super.key}); static const String routeName = '/basics/fade_transition'; @override diff --git a/animations/lib/src/misc/animated_list.dart b/animations/lib/src/misc/animated_list.dart index bf9d1056a..4a233ca91 100644 --- a/animations/lib/src/misc/animated_list.dart +++ b/animations/lib/src/misc/animated_list.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class AnimatedListDemo extends StatefulWidget { - const AnimatedListDemo({Key? key}) : super(key: key); + const AnimatedListDemo({super.key}); static String routeName = '/misc/animated_list'; @override diff --git a/animations/lib/src/misc/animated_positioned.dart b/animations/lib/src/misc/animated_positioned.dart index 1e6455cda..4f307c579 100644 --- a/animations/lib/src/misc/animated_positioned.dart +++ b/animations/lib/src/misc/animated_positioned.dart @@ -7,7 +7,7 @@ import 'dart:math'; import 'package:flutter/material.dart'; class AnimatedPositionedDemo extends StatefulWidget { - const AnimatedPositionedDemo({Key? key}) : super(key: key); + const AnimatedPositionedDemo({super.key}); static String routeName = '/basics/09_animated_positioned'; @override diff --git a/animations/lib/src/misc/animated_switcher.dart b/animations/lib/src/misc/animated_switcher.dart index be391c39e..5dc1cafb2 100644 --- a/animations/lib/src/misc/animated_switcher.dart +++ b/animations/lib/src/misc/animated_switcher.dart @@ -23,7 +23,7 @@ Widget generateContainer(int keyCount) => Container( ); class AnimatedSwitcherDemo extends StatefulWidget { - const AnimatedSwitcherDemo({Key? key}) : super(key: key); + const AnimatedSwitcherDemo({super.key}); static String routeName = '/basics/10_animated_switcher'; @override diff --git a/animations/lib/src/misc/card_swipe.dart b/animations/lib/src/misc/card_swipe.dart index c358b4e66..2bd38d433 100644 --- a/animations/lib/src/misc/card_swipe.dart +++ b/animations/lib/src/misc/card_swipe.dart @@ -6,7 +6,7 @@ import 'package:flutter/material.dart'; import 'package:flutter/physics.dart'; class CardSwipeDemo extends StatefulWidget { - const CardSwipeDemo({Key? key}) : super(key: key); + const CardSwipeDemo({super.key}); static String routeName = '/misc/card_swipe'; @override @@ -77,7 +77,7 @@ class _CardSwipeDemoState extends State { class Card extends StatelessWidget { final String imageAssetName; - const Card({required this.imageAssetName, Key? key}) : super(key: key); + const Card({required this.imageAssetName, super.key}); @override Widget build(BuildContext context) { @@ -101,8 +101,7 @@ class SwipeableCard extends StatefulWidget { final VoidCallback onSwiped; const SwipeableCard( - {required this.onSwiped, required this.imageAssetName, Key? key}) - : super(key: key); + {required this.onSwiped, required this.imageAssetName, super.key}); @override State createState() => _SwipeableCardState(); diff --git a/animations/lib/src/misc/carousel.dart b/animations/lib/src/misc/carousel.dart index 41d500f5f..6817d21b1 100644 --- a/animations/lib/src/misc/carousel.dart +++ b/animations/lib/src/misc/carousel.dart @@ -6,7 +6,7 @@ import 'dart:ui'; import 'package:flutter/material.dart'; class CarouselDemo extends StatelessWidget { - CarouselDemo({Key? key}) : super(key: key); + CarouselDemo({super.key}); static String routeName = '/misc/carousel'; static const List fileNames = [ @@ -46,7 +46,7 @@ typedef OnCurrentItemChangedCallback = void Function(int currentItem); class Carousel extends StatefulWidget { final IndexedWidgetBuilder itemBuilder; - const Carousel({Key? key, required this.itemBuilder}) : super(key: key); + const Carousel({super.key, required this.itemBuilder}); @override State createState() => _CarouselState(); diff --git a/animations/lib/src/misc/curved_animation.dart b/animations/lib/src/misc/curved_animation.dart index fcf469f2f..12f1b46a3 100644 --- a/animations/lib/src/misc/curved_animation.dart +++ b/animations/lib/src/misc/curved_animation.dart @@ -6,7 +6,7 @@ import 'dart:math' as math; import 'package:flutter/material.dart'; class CurvedAnimationDemo extends StatefulWidget { - const CurvedAnimationDemo({Key? key}) : super(key: key); + const CurvedAnimationDemo({super.key}); static const String routeName = '/misc/curved_animation'; @override diff --git a/animations/lib/src/misc/expand_card.dart b/animations/lib/src/misc/expand_card.dart index 8cbd014da..5e6ca099b 100644 --- a/animations/lib/src/misc/expand_card.dart +++ b/animations/lib/src/misc/expand_card.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class ExpandCardDemo extends StatelessWidget { - const ExpandCardDemo({Key? key}) : super(key: key); + const ExpandCardDemo({super.key}); static const String routeName = '/misc/expand_card'; @override @@ -22,7 +22,7 @@ class ExpandCardDemo extends StatelessWidget { } class ExpandCard extends StatefulWidget { - const ExpandCard({Key? key}) : super(key: key); + const ExpandCard({super.key}); @override State createState() => _ExpandCardState(); } diff --git a/animations/lib/src/misc/focus_image.dart b/animations/lib/src/misc/focus_image.dart index f89d12c65..01e12fc10 100644 --- a/animations/lib/src/misc/focus_image.dart +++ b/animations/lib/src/misc/focus_image.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class FocusImageDemo extends StatelessWidget { - const FocusImageDemo({Key? key}) : super(key: key); + const FocusImageDemo({super.key}); static String routeName = '/misc/focus_image'; @override @@ -18,7 +18,7 @@ class FocusImageDemo extends StatelessWidget { } class Grid extends StatelessWidget { - const Grid({Key? key}) : super(key: key); + const Grid({super.key}); @override Widget build(BuildContext context) { return Scaffold( @@ -72,7 +72,7 @@ Tween _createTween(BuildContext context) { } class SmallCard extends StatelessWidget { - const SmallCard({required this.imageAssetName, Key? key}) : super(key: key); + const SmallCard({required this.imageAssetName, super.key}); final String imageAssetName; @override diff --git a/animations/lib/src/misc/hero_animation.dart b/animations/lib/src/misc/hero_animation.dart index 0544385ca..965f7cd31 100644 --- a/animations/lib/src/misc/hero_animation.dart +++ b/animations/lib/src/misc/hero_animation.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class HeroAnimationDemo extends StatelessWidget { - const HeroAnimationDemo({Key? key}) : super(key: key); + const HeroAnimationDemo({super.key}); static const String routeName = '/misc/hero_animation'; @override @@ -30,7 +30,7 @@ class HeroAnimationDemo extends StatelessWidget { } class HeroPage extends StatelessWidget { - const HeroPage({Key? key}) : super(key: key); + const HeroPage({super.key}); @override Widget build(BuildContext context) { diff --git a/animations/lib/src/misc/physics_card_drag.dart b/animations/lib/src/misc/physics_card_drag.dart index 90e3763c4..538376ac3 100644 --- a/animations/lib/src/misc/physics_card_drag.dart +++ b/animations/lib/src/misc/physics_card_drag.dart @@ -6,7 +6,7 @@ import 'package:flutter/material.dart'; import 'package:flutter/physics.dart'; class PhysicsCardDragDemo extends StatelessWidget { - const PhysicsCardDragDemo({Key? key}) : super(key: key); + const PhysicsCardDragDemo({super.key}); static const String routeName = '/misc/physics_card'; @override @@ -27,7 +27,7 @@ class PhysicsCardDragDemo extends StatelessWidget { /// A draggable card that moves back to [Alignment.center] when it's /// released. class DraggableCard extends StatefulWidget { - const DraggableCard({required this.child, Key? key}) : super(key: key); + const DraggableCard({required this.child, super.key}); final Widget child; @override diff --git a/animations/lib/src/misc/repeating_animation.dart b/animations/lib/src/misc/repeating_animation.dart index 500328399..a9abcb2a9 100644 --- a/animations/lib/src/misc/repeating_animation.dart +++ b/animations/lib/src/misc/repeating_animation.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class RepeatingAnimationDemo extends StatefulWidget { - const RepeatingAnimationDemo({Key? key}) : super(key: key); + const RepeatingAnimationDemo({super.key}); static String routeName = '/misc/repeating_animation'; @override diff --git a/desktop_photo_search/fluent_ui/lib/main.dart b/desktop_photo_search/fluent_ui/lib/main.dart index 024c874ae..e897b851f 100644 --- a/desktop_photo_search/fluent_ui/lib/main.dart +++ b/desktop_photo_search/fluent_ui/lib/main.dart @@ -56,7 +56,7 @@ void setupWindow() { } class UnsplashSearchApp extends StatelessWidget { - const UnsplashSearchApp({Key? key}) : super(key: key); + const UnsplashSearchApp({super.key}); @override Widget build(BuildContext context) { @@ -68,7 +68,7 @@ class UnsplashSearchApp extends StatelessWidget { } class UnsplashHomePage extends StatelessWidget { - const UnsplashHomePage({required this.title, Key? key}) : super(key: key); + const UnsplashHomePage({required this.title, super.key}); final String title; @override diff --git a/desktop_photo_search/fluent_ui/lib/src/widgets/photo_details.dart b/desktop_photo_search/fluent_ui/lib/src/widgets/photo_details.dart index 37862907f..42aec68b4 100644 --- a/desktop_photo_search/fluent_ui/lib/src/widgets/photo_details.dart +++ b/desktop_photo_search/fluent_ui/lib/src/widgets/photo_details.dart @@ -20,8 +20,8 @@ class PhotoDetails extends StatefulWidget { const PhotoDetails({ required this.photo, required this.onPhotoSave, - Key? key, - }) : super(key: key); + super.key, + }); final Photo photo; final PhotoDetailsPhotoSaveCallback onPhotoSave; diff --git a/desktop_photo_search/fluent_ui/lib/src/widgets/photo_search_dialog.dart b/desktop_photo_search/fluent_ui/lib/src/widgets/photo_search_dialog.dart index 6c900324f..1ef925827 100644 --- a/desktop_photo_search/fluent_ui/lib/src/widgets/photo_search_dialog.dart +++ b/desktop_photo_search/fluent_ui/lib/src/widgets/photo_search_dialog.dart @@ -7,7 +7,7 @@ import 'package:fluent_ui/fluent_ui.dart'; typedef PhotoSearchDialogCallback = void Function(String searchQuery); class PhotoSearchDialog extends StatefulWidget { - const PhotoSearchDialog({required this.callback, Key? key}) : super(key: key); + const PhotoSearchDialog({required this.callback, super.key}); final PhotoSearchDialogCallback callback; @override State createState() => _PhotoSearchDialogState(); diff --git a/desktop_photo_search/fluent_ui/lib/src/widgets/policy_dialog.dart b/desktop_photo_search/fluent_ui/lib/src/widgets/policy_dialog.dart index 253903b8b..8ef8e937f 100644 --- a/desktop_photo_search/fluent_ui/lib/src/widgets/policy_dialog.dart +++ b/desktop_photo_search/fluent_ui/lib/src/widgets/policy_dialog.dart @@ -7,7 +7,7 @@ import 'package:flutter/gestures.dart'; import 'package:url_launcher/url_launcher.dart' as url_launcher; class PolicyDialog extends StatelessWidget { - const PolicyDialog({Key? key}) : super(key: key); + const PolicyDialog({super.key}); @override Widget build(BuildContext context) { diff --git a/desktop_photo_search/fluent_ui/lib/src/widgets/split.dart b/desktop_photo_search/fluent_ui/lib/src/widgets/split.dart index 95a2e30d1..7d71cb320 100644 --- a/desktop_photo_search/fluent_ui/lib/src/widgets/split.dart +++ b/desktop_photo_search/fluent_ui/lib/src/widgets/split.dart @@ -24,13 +24,12 @@ import 'package:flutter/material.dart'; class Split extends StatefulWidget { /// Builds a split oriented along [axis]. const Split({ - Key? key, + super.key, required this.axis, required this.firstChild, required this.secondChild, double? initialFirstFraction, - }) : initialFirstFraction = initialFirstFraction ?? 0.5, - super(key: key); + }) : initialFirstFraction = initialFirstFraction ?? 0.5; /// The main axis the children will lay out on. /// diff --git a/desktop_photo_search/fluent_ui/lib/src/widgets/unsplash_notice.dart b/desktop_photo_search/fluent_ui/lib/src/widgets/unsplash_notice.dart index d98b68e3a..67bb7e641 100644 --- a/desktop_photo_search/fluent_ui/lib/src/widgets/unsplash_notice.dart +++ b/desktop_photo_search/fluent_ui/lib/src/widgets/unsplash_notice.dart @@ -14,7 +14,7 @@ final _unsplashPrivacyPolicy = Uri.parse( 'https://unsplash.com/privacy?utm_source=${Uri.encodeFull(unsplashAppName)}&utm_medium=referral'); class UnsplashNotice extends StatefulWidget { - const UnsplashNotice({Key? key, required this.child}) : super(key: key); + const UnsplashNotice({super.key, required this.child}); final Widget child; @override @@ -47,7 +47,7 @@ class _UnsplashNoticeState extends State { } class _UnsplashDialog extends StatelessWidget { - const _UnsplashDialog({Key? key, required this.accepted}) : super(key: key); + const _UnsplashDialog({required this.accepted}); final Function accepted; @override diff --git a/desktop_photo_search/fluent_ui/lib/src/widgets/unsplash_search_content.dart b/desktop_photo_search/fluent_ui/lib/src/widgets/unsplash_search_content.dart index f4ba5aac4..e5ddb7386 100644 --- a/desktop_photo_search/fluent_ui/lib/src/widgets/unsplash_search_content.dart +++ b/desktop_photo_search/fluent_ui/lib/src/widgets/unsplash_search_content.dart @@ -12,7 +12,7 @@ import '../widgets/photo_details.dart'; import '../widgets/split.dart'; class UnsplashSearchContent extends StatefulWidget { - const UnsplashSearchContent({Key? key}) : super(key: key); + const UnsplashSearchContent({super.key}); @override State createState() => _UnsplashSearchContentState(); diff --git a/desktop_photo_search/fluent_ui/test/widget_test.dart b/desktop_photo_search/fluent_ui/test/widget_test.dart index b549af430..2d8864ca7 100644 --- a/desktop_photo_search/fluent_ui/test/widget_test.dart +++ b/desktop_photo_search/fluent_ui/test/widget_test.dart @@ -85,8 +85,7 @@ class FakeUnsplash implements Unsplash { const fabKey = Key('fab'); class PhotoSearchModelTester extends StatelessWidget { - const PhotoSearchModelTester({required this.query, Key? key}) - : super(key: key); + const PhotoSearchModelTester({required this.query, super.key}); final String query; @override Widget build(BuildContext context) { diff --git a/desktop_photo_search/material/lib/main.dart b/desktop_photo_search/material/lib/main.dart index 87b4c71d7..89e00b5aa 100644 --- a/desktop_photo_search/material/lib/main.dart +++ b/desktop_photo_search/material/lib/main.dart @@ -56,7 +56,7 @@ void setupWindow() { } class UnsplashSearchApp extends StatelessWidget { - const UnsplashSearchApp({Key? key}) : super(key: key); + const UnsplashSearchApp({super.key}); @override Widget build(BuildContext context) { @@ -71,7 +71,7 @@ class UnsplashSearchApp extends StatelessWidget { } class UnsplashHomePage extends StatelessWidget { - const UnsplashHomePage({required this.title, Key? key}) : super(key: key); + const UnsplashHomePage({required this.title, super.key}); final String title; @override diff --git a/desktop_photo_search/material/lib/src/widgets/photo_details.dart b/desktop_photo_search/material/lib/src/widgets/photo_details.dart index 79867fc0d..ac39e1adf 100644 --- a/desktop_photo_search/material/lib/src/widgets/photo_details.dart +++ b/desktop_photo_search/material/lib/src/widgets/photo_details.dart @@ -18,8 +18,8 @@ class PhotoDetails extends StatefulWidget { const PhotoDetails({ required this.photo, required this.onPhotoSave, - Key? key, - }) : super(key: key); + super.key, + }); final Photo photo; final PhotoDetailsPhotoSaveCallback onPhotoSave; diff --git a/desktop_photo_search/material/lib/src/widgets/photo_search_dialog.dart b/desktop_photo_search/material/lib/src/widgets/photo_search_dialog.dart index 827bdc1d9..db820fee5 100644 --- a/desktop_photo_search/material/lib/src/widgets/photo_search_dialog.dart +++ b/desktop_photo_search/material/lib/src/widgets/photo_search_dialog.dart @@ -7,7 +7,7 @@ import 'package:flutter/material.dart'; typedef PhotoSearchDialogCallback = void Function(String searchQuery); class PhotoSearchDialog extends StatefulWidget { - const PhotoSearchDialog({required this.callback, Key? key}) : super(key: key); + const PhotoSearchDialog({required this.callback, super.key}); final PhotoSearchDialogCallback callback; @override State createState() => _PhotoSearchDialogState(); diff --git a/desktop_photo_search/material/lib/src/widgets/policy_dialog.dart b/desktop_photo_search/material/lib/src/widgets/policy_dialog.dart index d6dd6f8e9..73ebd464b 100644 --- a/desktop_photo_search/material/lib/src/widgets/policy_dialog.dart +++ b/desktop_photo_search/material/lib/src/widgets/policy_dialog.dart @@ -7,7 +7,7 @@ import 'package:flutter/material.dart'; import 'package:url_launcher/url_launcher.dart' as url_launcher; class PolicyDialog extends StatelessWidget { - const PolicyDialog({Key? key}) : super(key: key); + const PolicyDialog({super.key}); @override Widget build(BuildContext context) { diff --git a/desktop_photo_search/material/lib/src/widgets/split.dart b/desktop_photo_search/material/lib/src/widgets/split.dart index 95a2e30d1..7d71cb320 100644 --- a/desktop_photo_search/material/lib/src/widgets/split.dart +++ b/desktop_photo_search/material/lib/src/widgets/split.dart @@ -24,13 +24,12 @@ import 'package:flutter/material.dart'; class Split extends StatefulWidget { /// Builds a split oriented along [axis]. const Split({ - Key? key, + super.key, required this.axis, required this.firstChild, required this.secondChild, double? initialFirstFraction, - }) : initialFirstFraction = initialFirstFraction ?? 0.5, - super(key: key); + }) : initialFirstFraction = initialFirstFraction ?? 0.5; /// The main axis the children will lay out on. /// diff --git a/desktop_photo_search/material/lib/src/widgets/unsplash_notice.dart b/desktop_photo_search/material/lib/src/widgets/unsplash_notice.dart index cb68770f6..9dda49289 100644 --- a/desktop_photo_search/material/lib/src/widgets/unsplash_notice.dart +++ b/desktop_photo_search/material/lib/src/widgets/unsplash_notice.dart @@ -14,7 +14,7 @@ final _unsplashPrivacyPolicy = Uri.parse( 'https://unsplash.com/privacy?utm_source=${Uri.encodeFull(unsplashAppName)}&utm_medium=referral'); class UnsplashNotice extends StatefulWidget { - const UnsplashNotice({Key? key, required this.child}) : super(key: key); + const UnsplashNotice({super.key, required this.child}); final Widget child; @override @@ -48,7 +48,7 @@ class _UnsplashNoticeState extends State { } class _UnsplashDialog extends StatelessWidget { - const _UnsplashDialog({Key? key, required this.accepted}) : super(key: key); + const _UnsplashDialog({required this.accepted}); final Function accepted; @override diff --git a/desktop_photo_search/material/lib/src/widgets/unsplash_search_content.dart b/desktop_photo_search/material/lib/src/widgets/unsplash_search_content.dart index 30e59946d..7d244b876 100644 --- a/desktop_photo_search/material/lib/src/widgets/unsplash_search_content.dart +++ b/desktop_photo_search/material/lib/src/widgets/unsplash_search_content.dart @@ -13,7 +13,7 @@ import '../widgets/photo_details.dart'; import '../widgets/split.dart'; class UnsplashSearchContent extends StatefulWidget { - const UnsplashSearchContent({Key? key}) : super(key: key); + const UnsplashSearchContent({super.key}); @override State createState() => _UnsplashSearchContentState(); diff --git a/desktop_photo_search/material/test/widget_test.dart b/desktop_photo_search/material/test/widget_test.dart index b549af430..2d8864ca7 100644 --- a/desktop_photo_search/material/test/widget_test.dart +++ b/desktop_photo_search/material/test/widget_test.dart @@ -85,8 +85,7 @@ class FakeUnsplash implements Unsplash { const fabKey = Key('fab'); class PhotoSearchModelTester extends StatelessWidget { - const PhotoSearchModelTester({required this.query, Key? key}) - : super(key: key); + const PhotoSearchModelTester({required this.query, super.key}); final String query; @override Widget build(BuildContext context) { diff --git a/experimental/federated_plugin/federated_plugin/example/lib/main.dart b/experimental/federated_plugin/federated_plugin/example/lib/main.dart index cbf41b3d0..3aef6dc78 100644 --- a/experimental/federated_plugin/federated_plugin/example/lib/main.dart +++ b/experimental/federated_plugin/federated_plugin/example/lib/main.dart @@ -26,7 +26,7 @@ class HomePage extends StatefulWidget { const HomePage({Key? key}) : super(key: key); @override - _HomePageState createState() => _HomePageState(); + State createState() => _HomePageState(); } class _HomePageState extends State { diff --git a/experimental/federated_plugin/federated_plugin/example/pubspec.lock b/experimental/federated_plugin/federated_plugin/example/pubspec.lock index de82b29dd..c262574c5 100644 --- a/experimental/federated_plugin/federated_plugin/example/pubspec.lock +++ b/experimental/federated_plugin/federated_plugin/example/pubspec.lock @@ -103,7 +103,7 @@ packages: name: flutter_lints url: "https://pub.dartlang.org" source: hosted - version: "1.0.4" + version: "2.0.1" flutter_test: dependency: "direct dev" description: flutter @@ -127,7 +127,7 @@ packages: name: lints url: "https://pub.dartlang.org" source: hosted - version: "1.0.1" + version: "2.0.0" matcher: dependency: transitive description: @@ -218,4 +218,4 @@ packages: source: hosted version: "2.1.2" sdks: - dart: ">=2.17.0-0 <3.0.0" + dart: ">=2.17.0-206.0.dev <3.0.0" diff --git a/experimental/federated_plugin/federated_plugin/example/pubspec.yaml b/experimental/federated_plugin/federated_plugin/example/pubspec.yaml index 44f7caeab..a639143ce 100644 --- a/experimental/federated_plugin/federated_plugin/example/pubspec.yaml +++ b/experimental/federated_plugin/federated_plugin/example/pubspec.yaml @@ -17,7 +17,7 @@ dependencies: dev_dependencies: flutter_test: sdk: flutter - flutter_lints: ^1.0.0 + flutter_lints: ^2.0.1 flutter: uses-material-design: true diff --git a/experimental/web_dashboard/pubspec.lock b/experimental/web_dashboard/pubspec.lock index 6df59c9d4..3f81ce117 100644 --- a/experimental/web_dashboard/pubspec.lock +++ b/experimental/web_dashboard/pubspec.lock @@ -175,7 +175,7 @@ packages: name: collection url: "https://pub.dartlang.org" source: hosted - version: "1.15.0" + version: "1.16.0" convert: dependency: transitive description: @@ -210,7 +210,7 @@ packages: name: fake_async url: "https://pub.dartlang.org" source: hosted - version: "1.2.0" + version: "1.3.0" file: dependency: transitive description: @@ -386,7 +386,7 @@ packages: name: js url: "https://pub.dartlang.org" source: hosted - version: "0.6.3" + version: "0.6.4" json_annotation: dependency: "direct main" description: @@ -428,7 +428,7 @@ packages: name: material_color_utilities url: "https://pub.dartlang.org" source: hosted - version: "0.1.3" + version: "0.1.4" meta: dependency: transitive description: @@ -463,7 +463,7 @@ packages: name: path url: "https://pub.dartlang.org" source: hosted - version: "1.8.0" + version: "1.8.1" plugin_platform_interface: dependency: transitive description: @@ -545,7 +545,7 @@ packages: name: source_span url: "https://pub.dartlang.org" source: hosted - version: "1.8.1" + version: "1.8.2" stack_trace: dependency: transitive description: @@ -587,7 +587,7 @@ packages: name: test_api url: "https://pub.dartlang.org" source: hosted - version: "0.4.8" + version: "0.4.9" timing: dependency: transitive description: @@ -615,7 +615,7 @@ packages: name: vector_math url: "https://pub.dartlang.org" source: hosted - version: "2.1.1" + version: "2.1.2" watcher: dependency: transitive description: diff --git a/flutter_maps_firestore/lib/main.dart b/flutter_maps_firestore/lib/main.dart index 7fd24f807..821c4d2f0 100644 --- a/flutter_maps_firestore/lib/main.dart +++ b/flutter_maps_firestore/lib/main.dart @@ -26,7 +26,7 @@ Future main() async { } class App extends StatelessWidget { - const App({Key? key}) : super(key: key); + const App({super.key}); @override Widget build(BuildContext context) { @@ -42,7 +42,7 @@ class App extends StatelessWidget { } class HomePage extends StatefulWidget { - const HomePage({required this.title, Key? key}) : super(key: key); + const HomePage({required this.title, super.key}); final String title; @override @@ -101,10 +101,10 @@ class _HomePageState extends State { class StoreCarousel extends StatelessWidget { const StoreCarousel({ - Key? key, + super.key, required this.documents, required this.mapController, - }) : super(key: key); + }); final List documents; final Completer mapController; @@ -129,10 +129,10 @@ class StoreCarousel extends StatelessWidget { class StoreCarouselList extends StatelessWidget { const StoreCarouselList({ - Key? key, + super.key, required this.documents, required this.mapController, - }) : super(key: key); + }); final List documents; final Completer mapController; @@ -164,10 +164,10 @@ class StoreCarouselList extends StatelessWidget { class StoreListTile extends StatefulWidget { const StoreListTile({ - Key? key, + super.key, required this.document, required this.mapController, - }) : super(key: key); + }); final DocumentSnapshot document; final Completer mapController; @@ -242,11 +242,11 @@ class _StoreListTileState extends State { class StoreMap extends StatelessWidget { const StoreMap({ - Key? key, + super.key, required this.documents, required this.initialPosition, required this.mapController, - }) : super(key: key); + }); final List documents; final LatLng initialPosition; diff --git a/form_app/lib/main.dart b/form_app/lib/main.dart index a0ebda026..f2b5f3bcf 100644 --- a/form_app/lib/main.dart +++ b/form_app/lib/main.dart @@ -65,7 +65,7 @@ final demos = [ ]; class FormApp extends StatelessWidget { - const FormApp({Key? key}) : super(key: key); + const FormApp({super.key}); @override Widget build(BuildContext context) { @@ -79,7 +79,7 @@ class FormApp extends StatelessWidget { } class HomePage extends StatelessWidget { - const HomePage({Key? key}) : super(key: key); + const HomePage({super.key}); @override Widget build(BuildContext context) { return Scaffold( @@ -96,7 +96,7 @@ class HomePage extends StatelessWidget { class DemoTile extends StatelessWidget { final Demo? demo; - const DemoTile({this.demo, Key? key}) : super(key: key); + const DemoTile({this.demo, super.key}); @override Widget build(BuildContext context) { diff --git a/form_app/lib/src/autofill.dart b/form_app/lib/src/autofill.dart index 49a54b45a..aaa7a5907 100644 --- a/form_app/lib/src/autofill.dart +++ b/form_app/lib/src/autofill.dart @@ -7,7 +7,7 @@ import 'package:flutter/material.dart'; // Demonstrates how to use autofill hints. The full list of hints is here: // https://github.com/flutter/engine/blob/master/lib/web_ui/lib/src/engine/text_editing/autofill_hint.dart class AutofillDemo extends StatefulWidget { - const AutofillDemo({Key? key}) : super(key: key); + const AutofillDemo({super.key}); @override State createState() => _AutofillDemoState(); diff --git a/form_app/lib/src/form_widgets.dart b/form_app/lib/src/form_widgets.dart index 9750953be..0f69426e3 100644 --- a/form_app/lib/src/form_widgets.dart +++ b/form_app/lib/src/form_widgets.dart @@ -6,7 +6,7 @@ import 'package:flutter/material.dart'; import 'package:intl/intl.dart' as intl; class FormWidgetsDemo extends StatefulWidget { - const FormWidgetsDemo({Key? key}) : super(key: key); + const FormWidgetsDemo({super.key}); @override State createState() => _FormWidgetsDemoState(); diff --git a/form_app/lib/src/sign_in_http.dart b/form_app/lib/src/sign_in_http.dart index ecef24e3c..4566e7978 100644 --- a/form_app/lib/src/sign_in_http.dart +++ b/form_app/lib/src/sign_in_http.dart @@ -31,8 +31,8 @@ class SignInHttpDemo extends StatefulWidget { const SignInHttpDemo({ this.httpClient, - Key? key, - }) : super(key: key); + super.key, + }); @override State createState() => _SignInHttpDemoState(); diff --git a/form_app/lib/src/validation.dart b/form_app/lib/src/validation.dart index 55af58ddd..8e6e7f3fe 100644 --- a/form_app/lib/src/validation.dart +++ b/form_app/lib/src/validation.dart @@ -6,7 +6,7 @@ import 'package:english_words/english_words.dart' as english_words; import 'package:flutter/material.dart'; class FormValidationDemo extends StatefulWidget { - const FormValidationDemo({Key? key}) : super(key: key); + const FormValidationDemo({super.key}); @override State createState() => _FormValidationDemoState(); diff --git a/game_template/lib/main.dart b/game_template/lib/main.dart index a442385bb..4305a4861 100644 --- a/game_template/lib/main.dart +++ b/game_template/lib/main.dart @@ -189,8 +189,8 @@ class MyApp extends StatelessWidget { required this.inAppPurchaseController, required this.adsController, required this.gamesServicesController, - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/game_template/lib/src/ads/banner_ad_widget.dart b/game_template/lib/src/ads/banner_ad_widget.dart index 3d4ea90c6..432fc751e 100644 --- a/game_template/lib/src/ads/banner_ad_widget.dart +++ b/game_template/lib/src/ads/banner_ad_widget.dart @@ -31,7 +31,7 @@ import 'preloaded_banner_ad.dart'; /// namely the `anchored_adaptive_example.dart` file: /// https://github.com/googleads/googleads-mobile-flutter/blob/main/packages/google_mobile_ads/example/lib/anchored_adaptive_example.dart class BannerAdWidget extends StatefulWidget { - const BannerAdWidget({Key? key}) : super(key: key); + const BannerAdWidget({super.key}); @override State createState() => _BannerAdWidgetState(); diff --git a/game_template/lib/src/app_lifecycle/app_lifecycle.dart b/game_template/lib/src/app_lifecycle/app_lifecycle.dart index 52dd1f30a..559bf7906 100644 --- a/game_template/lib/src/app_lifecycle/app_lifecycle.dart +++ b/game_template/lib/src/app_lifecycle/app_lifecycle.dart @@ -9,7 +9,7 @@ import 'package:provider/provider.dart'; class AppLifecycleObserver extends StatefulWidget { final Widget child; - const AppLifecycleObserver({required this.child, Key? key}) : super(key: key); + const AppLifecycleObserver({required this.child, super.key}); @override State createState() => _AppLifecycleObserverState(); diff --git a/game_template/lib/src/level_selection/level_selection_screen.dart b/game_template/lib/src/level_selection/level_selection_screen.dart index 2cec06020..1a9a7076e 100644 --- a/game_template/lib/src/level_selection/level_selection_screen.dart +++ b/game_template/lib/src/level_selection/level_selection_screen.dart @@ -14,7 +14,7 @@ import '../style/responsive_screen.dart'; import 'levels.dart'; class LevelSelectionScreen extends StatelessWidget { - const LevelSelectionScreen({Key? key}) : super(key: key); + const LevelSelectionScreen({super.key}); @override Widget build(BuildContext context) { diff --git a/game_template/lib/src/main_menu/main_menu_screen.dart b/game_template/lib/src/main_menu/main_menu_screen.dart index 00459eadd..a8ab0edaf 100644 --- a/game_template/lib/src/main_menu/main_menu_screen.dart +++ b/game_template/lib/src/main_menu/main_menu_screen.dart @@ -14,7 +14,7 @@ import '../style/palette.dart'; import '../style/responsive_screen.dart'; class MainMenuScreen extends StatelessWidget { - const MainMenuScreen({Key? key}) : super(key: key); + const MainMenuScreen({super.key}); @override Widget build(BuildContext context) { diff --git a/game_template/lib/src/play_session/play_session_screen.dart b/game_template/lib/src/play_session/play_session_screen.dart index 66bbd9396..f38163976 100644 --- a/game_template/lib/src/play_session/play_session_screen.dart +++ b/game_template/lib/src/play_session/play_session_screen.dart @@ -24,7 +24,7 @@ import '../style/palette.dart'; class PlaySessionScreen extends StatefulWidget { final GameLevel level; - const PlaySessionScreen(this.level, {Key? key}) : super(key: key); + const PlaySessionScreen(this.level, {super.key}); @override State createState() => _PlaySessionScreenState(); diff --git a/game_template/lib/src/settings/custom_name_dialog.dart b/game_template/lib/src/settings/custom_name_dialog.dart index 405f6f66e..d41b04db6 100644 --- a/game_template/lib/src/settings/custom_name_dialog.dart +++ b/game_template/lib/src/settings/custom_name_dialog.dart @@ -17,7 +17,7 @@ void showCustomNameDialog(BuildContext context) { class CustomNameDialog extends StatefulWidget { final Animation animation; - const CustomNameDialog({required this.animation, Key? key}) : super(key: key); + const CustomNameDialog({required this.animation, super.key}); @override State createState() => _CustomNameDialogState(); diff --git a/game_template/lib/src/settings/settings_screen.dart b/game_template/lib/src/settings/settings_screen.dart index 722e74f5c..3ef3e0489 100644 --- a/game_template/lib/src/settings/settings_screen.dart +++ b/game_template/lib/src/settings/settings_screen.dart @@ -14,7 +14,7 @@ import 'custom_name_dialog.dart'; import 'settings.dart'; class SettingsScreen extends StatelessWidget { - const SettingsScreen({Key? key}) : super(key: key); + const SettingsScreen({super.key}); static const _gap = SizedBox(height: 60); @@ -115,7 +115,7 @@ class SettingsScreen extends StatelessWidget { class _NameChangeLine extends StatelessWidget { final String title; - const _NameChangeLine(this.title, {Key? key}) : super(key: key); + const _NameChangeLine(this.title); @override Widget build(BuildContext context) { @@ -159,8 +159,7 @@ class _SettingsLine extends StatelessWidget { final VoidCallback? onSelected; - const _SettingsLine(this.title, this.icon, {this.onSelected, Key? key}) - : super(key: key); + const _SettingsLine(this.title, this.icon, {this.onSelected}); @override Widget build(BuildContext context) { diff --git a/game_template/lib/src/style/confetti.dart b/game_template/lib/src/style/confetti.dart index ea80387ca..b83522461 100644 --- a/game_template/lib/src/style/confetti.dart +++ b/game_template/lib/src/style/confetti.dart @@ -32,8 +32,8 @@ class Confetti extends StatefulWidget { const Confetti({ this.colors = _defaultColors, this.isStopped = false, - Key? key, - }) : super(key: key); + super.key, + }); @override State createState() => _ConfettiState(); diff --git a/game_template/lib/src/style/my_transition.dart b/game_template/lib/src/style/my_transition.dart index 7d9050199..af452ebc5 100644 --- a/game_template/lib/src/style/my_transition.dart +++ b/game_template/lib/src/style/my_transition.dart @@ -42,8 +42,7 @@ class _MyReveal extends StatefulWidget { required this.child, required this.animation, required this.color, - Key? key, - }) : super(key: key); + }); @override State<_MyReveal> createState() => _MyRevealState(); diff --git a/game_template/lib/src/style/responsive_screen.dart b/game_template/lib/src/style/responsive_screen.dart index cd33c7583..b98c7a479 100644 --- a/game_template/lib/src/style/responsive_screen.dart +++ b/game_template/lib/src/style/responsive_screen.dart @@ -28,8 +28,8 @@ class ResponsiveScreen extends StatelessWidget { required this.rectangularMenuArea, this.topMessageArea = const SizedBox.shrink(), this.mainAreaProminence = 0.8, - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/game_template/lib/src/win_game/win_game_screen.dart b/game_template/lib/src/win_game/win_game_screen.dart index 4c8be0866..88a5ca2b8 100644 --- a/game_template/lib/src/win_game/win_game_screen.dart +++ b/game_template/lib/src/win_game/win_game_screen.dart @@ -17,9 +17,9 @@ class WinGameScreen extends StatelessWidget { final Score score; const WinGameScreen({ - Key? key, + super.key, required this.score, - }) : super(key: key); + }); @override Widget build(BuildContext context) { diff --git a/game_template/pubspec.yaml b/game_template/pubspec.yaml index d5ebd7a9b..d7e32a4e9 100644 --- a/game_template/pubspec.yaml +++ b/game_template/pubspec.yaml @@ -7,7 +7,7 @@ publish_to: 'none' version: 0.0.1+1 environment: - sdk: ">=2.16.0 <3.0.0" + sdk: ">=2.17.0-0 <3.0.0" dependencies: flutter: diff --git a/infinite_list/lib/main.dart b/infinite_list/lib/main.dart index 957765d97..57fe74226 100644 --- a/infinite_list/lib/main.dart +++ b/infinite_list/lib/main.dart @@ -37,7 +37,7 @@ void setupWindow() { } class MyApp extends StatelessWidget { - const MyApp({Key? key}) : super(key: key); + const MyApp({super.key}); @override Widget build(BuildContext context) { @@ -52,7 +52,7 @@ class MyApp extends StatelessWidget { } class MyHomePage extends StatelessWidget { - const MyHomePage({Key? key}) : super(key: key); + const MyHomePage({super.key}); @override Widget build(BuildContext context) { diff --git a/infinite_list/lib/src/item_tile.dart b/infinite_list/lib/src/item_tile.dart index adcbae8a5..11f98def2 100644 --- a/infinite_list/lib/src/item_tile.dart +++ b/infinite_list/lib/src/item_tile.dart @@ -11,7 +11,7 @@ import 'api/item.dart'; class ItemTile extends StatelessWidget { final Item item; - const ItemTile({required this.item, Key? key}) : super(key: key); + const ItemTile({required this.item, super.key}); @override Widget build(BuildContext context) { @@ -34,7 +34,7 @@ class ItemTile extends StatelessWidget { /// This is the widget responsible for building the "still loading" item /// in the list (represented with "..." and a crossed square). class LoadingItemTile extends StatelessWidget { - const LoadingItemTile({Key? key}) : super(key: key); + const LoadingItemTile({super.key}); @override Widget build(BuildContext context) { diff --git a/ios_app_clip/lib/main.dart b/ios_app_clip/lib/main.dart index fb2a4b158..07c3a2831 100644 --- a/ios_app_clip/lib/main.dart +++ b/ios_app_clip/lib/main.dart @@ -13,7 +13,7 @@ void main() { // The same content is shown for both the main app target and in the App // Clip. class Demo extends StatefulWidget { - const Demo({Key? key}) : super(key: key); + const Demo({super.key}); @override State createState() => _DemoState(); diff --git a/isolate_example/lib/data_transfer_page.dart b/isolate_example/lib/data_transfer_page.dart index a6fbfb59d..c764a7b54 100644 --- a/isolate_example/lib/data_transfer_page.dart +++ b/isolate_example/lib/data_transfer_page.dart @@ -20,7 +20,7 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; class DataTransferPageStarter extends StatelessWidget { - const DataTransferPageStarter({Key? key}) : super(key: key); + const DataTransferPageStarter({super.key}); @override Widget build(BuildContext context) { @@ -32,7 +32,7 @@ class DataTransferPageStarter extends StatelessWidget { } class DataTransferPage extends StatelessWidget { - const DataTransferPage({Key? key}) : super(key: key); + const DataTransferPage({super.key}); @override Widget build(context) { @@ -197,7 +197,7 @@ class DataTransferIsolateController extends ChangeNotifier { } class RunningList extends StatelessWidget { - const RunningList({Key? key}) : super(key: key); + const RunningList({super.key}); @override Widget build(BuildContext context) { diff --git a/isolate_example/lib/infinite_process_page.dart b/isolate_example/lib/infinite_process_page.dart index e31ee97ca..89426e53b 100644 --- a/isolate_example/lib/infinite_process_page.dart +++ b/isolate_example/lib/infinite_process_page.dart @@ -19,7 +19,7 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; class InfiniteProcessPageStarter extends StatelessWidget { - const InfiniteProcessPageStarter({Key? key}) : super(key: key); + const InfiniteProcessPageStarter({super.key}); @override Widget build(context) { @@ -31,7 +31,7 @@ class InfiniteProcessPageStarter extends StatelessWidget { } class InfiniteProcessPage extends StatelessWidget { - const InfiniteProcessPage({Key? key}) : super(key: key); + const InfiniteProcessPage({super.key}); @override Widget build(context) { @@ -187,7 +187,7 @@ class InfiniteProcessIsolateController extends ChangeNotifier { } class RunningList extends StatelessWidget { - const RunningList({Key? key}) : super(key: key); + const RunningList({super.key}); @override Widget build(context) { diff --git a/isolate_example/lib/main.dart b/isolate_example/lib/main.dart index ea8c155eb..d158d9c6a 100644 --- a/isolate_example/lib/main.dart +++ b/isolate_example/lib/main.dart @@ -43,7 +43,7 @@ void setupWindow() { } class HomePage extends StatelessWidget { - const HomePage({Key? key}) : super(key: key); + const HomePage({super.key}); @override Widget build(BuildContext context) { diff --git a/isolate_example/lib/performance_page.dart b/isolate_example/lib/performance_page.dart index c520573fd..8a210e452 100644 --- a/isolate_example/lib/performance_page.dart +++ b/isolate_example/lib/performance_page.dart @@ -30,7 +30,7 @@ int fib(int n) { } class PerformancePage extends StatefulWidget { - const PerformancePage({Key? key}) : super(key: key); + const PerformancePage({super.key}); @override State createState() => _PerformancePageState(); @@ -127,7 +127,7 @@ class _PerformancePageState extends State { } class SmoothAnimationWidget extends StatefulWidget { - const SmoothAnimationWidget({Key? key}) : super(key: key); + const SmoothAnimationWidget({super.key}); @override State createState() => _SmoothAnimationWidgetState(); diff --git a/jsonexample/lib/main.dart b/jsonexample/lib/main.dart index 325b01507..1022b193e 100644 --- a/jsonexample/lib/main.dart +++ b/jsonexample/lib/main.dart @@ -26,7 +26,7 @@ void setupWindow() { } class MyApp extends StatelessWidget { - const MyApp({Key? key}) : super(key: key); + const MyApp({super.key}); @override Widget build(BuildContext context) { @@ -41,7 +41,7 @@ class MyApp extends StatelessWidget { } class MyHomePage extends StatelessWidget { - const MyHomePage({Key? key}) : super(key: key); + const MyHomePage({super.key}); @override Widget build(BuildContext context) { diff --git a/jsonexample/lib/tab_pages.dart b/jsonexample/lib/tab_pages.dart index 86c261682..379957930 100644 --- a/jsonexample/lib/tab_pages.dart +++ b/jsonexample/lib/tab_pages.dart @@ -17,7 +17,7 @@ import 'package:jsonexample/utils.dart'; import 'package:jsonexample/widgets.dart'; class BasicsPage extends StatelessWidget { - const BasicsPage({Key? key}) : super(key: key); + const BasicsPage({super.key}); List createMapRows( Map values, TextStyle normalStyle, TextStyle boldStyle) { @@ -147,7 +147,7 @@ class BasicsPage extends StatelessWidget { } class ConvertedSimplePage extends StatelessWidget { - const ConvertedSimplePage({Key? key}) : super(key: key); + const ConvertedSimplePage({super.key}); @override Widget build(BuildContext context) { @@ -170,7 +170,7 @@ class ConvertedSimplePage extends StatelessWidget { } class ConvertedComplexPage extends StatelessWidget { - const ConvertedComplexPage({Key? key}) : super(key: key); + const ConvertedComplexPage({super.key}); @override Widget build(BuildContext context) { @@ -193,7 +193,7 @@ class ConvertedComplexPage extends StatelessWidget { } class ConvertedListPage extends StatelessWidget { - const ConvertedListPage({Key? key}) : super(key: key); + const ConvertedListPage({super.key}); @override Widget build(BuildContext context) { @@ -216,7 +216,7 @@ class ConvertedListPage extends StatelessWidget { } class SerializableSimplePage extends StatelessWidget { - const SerializableSimplePage({Key? key}) : super(key: key); + const SerializableSimplePage({super.key}); @override Widget build(BuildContext context) { @@ -239,7 +239,7 @@ class SerializableSimplePage extends StatelessWidget { } class SerializableComplexPage extends StatelessWidget { - const SerializableComplexPage({Key? key}) : super(key: key); + const SerializableComplexPage({super.key}); @override Widget build(BuildContext context) { @@ -262,7 +262,7 @@ class SerializableComplexPage extends StatelessWidget { } class SerializableListPage extends StatelessWidget { - const SerializableListPage({Key? key}) : super(key: key); + const SerializableListPage({super.key}); @override Widget build(BuildContext context) { @@ -285,7 +285,7 @@ class SerializableListPage extends StatelessWidget { } class BuiltSimplePage extends StatelessWidget { - const BuiltSimplePage({Key? key}) : super(key: key); + const BuiltSimplePage({super.key}); @override Widget build(BuildContext context) { @@ -309,7 +309,7 @@ class BuiltSimplePage extends StatelessWidget { } class BuiltComplexPage extends StatelessWidget { - const BuiltComplexPage({Key? key}) : super(key: key); + const BuiltComplexPage({super.key}); @override Widget build(BuildContext context) { @@ -333,7 +333,7 @@ class BuiltComplexPage extends StatelessWidget { } class BuiltListPage extends StatelessWidget { - const BuiltListPage({Key? key}) : super(key: key); + const BuiltListPage({super.key}); @override Widget build(BuildContext context) { diff --git a/jsonexample/lib/widgets.dart b/jsonexample/lib/widgets.dart index a8b4ffd3f..a534cbad5 100644 --- a/jsonexample/lib/widgets.dart +++ b/jsonexample/lib/widgets.dart @@ -6,8 +6,7 @@ import 'package:flutter/material.dart'; import 'package:jsonexample/utils.dart'; class SimpleObjectView extends StatelessWidget { - const SimpleObjectView({required this.simpleObject, Key? key}) - : super(key: key); + const SimpleObjectView({required this.simpleObject, super.key}); final dynamic simpleObject; @@ -94,8 +93,7 @@ class SimpleObjectView extends StatelessWidget { } class SimpleObjectViewList extends StatelessWidget { - const SimpleObjectViewList({required this.simpleObjects, Key? key}) - : super(key: key); + const SimpleObjectViewList({required this.simpleObjects, super.key}); final List simpleObjects; @@ -127,8 +125,7 @@ class SimpleObjectViewList extends StatelessWidget { class ComplexObjectView extends StatelessWidget { final dynamic complexObject; - const ComplexObjectView({required this.complexObject, Key? key}) - : super(key: key); + const ComplexObjectView({required this.complexObject, super.key}); List _generateSimpleObjectWidgets(Iterable? simpleObjects) { if (simpleObjects == null) { @@ -270,8 +267,7 @@ class ComplexObjectView extends StatelessWidget { } class ComplexObjectViewList extends StatelessWidget { - const ComplexObjectViewList({required this.complexObjects, Key? key}) - : super(key: key); + const ComplexObjectViewList({required this.complexObjects, super.key}); final List complexObjects; diff --git a/material_3_demo/lib/color_palettes_screen.dart b/material_3_demo/lib/color_palettes_screen.dart index ed09096dc..e8edb5bce 100644 --- a/material_3_demo/lib/color_palettes_screen.dart +++ b/material_3_demo/lib/color_palettes_screen.dart @@ -8,7 +8,7 @@ const Widget divider = SizedBox(height: 10); const double narrowScreenWidthThreshold = 400; class ColorPalettesScreen extends StatelessWidget { - const ColorPalettesScreen({Key? key}) : super(key: key); + const ColorPalettesScreen({super.key}); @override Widget build(BuildContext context) { @@ -86,8 +86,7 @@ class ColorPalettesScreen extends StatelessWidget { } class ColorSchemeView extends StatelessWidget { - const ColorSchemeView({Key? key, required this.colorScheme}) - : super(key: key); + const ColorSchemeView({super.key, required this.colorScheme}); final ColorScheme colorScheme; @@ -239,7 +238,7 @@ class ColorSchemeView extends StatelessWidget { } class ColorGroup extends StatelessWidget { - const ColorGroup({Key? key, required this.children}) : super(key: key); + const ColorGroup({super.key, required this.children}); final List children; @@ -256,11 +255,11 @@ class ColorGroup extends StatelessWidget { class ColorChip extends StatelessWidget { const ColorChip({ - Key? key, + super.key, required this.color, required this.label, this.onColor, - }) : super(key: key); + }); final Color color; final Color? onColor; diff --git a/material_3_demo/lib/component_screen.dart b/material_3_demo/lib/component_screen.dart index 0423b0b77..f11237742 100644 --- a/material_3_demo/lib/component_screen.dart +++ b/material_3_demo/lib/component_screen.dart @@ -1,8 +1,7 @@ import 'package:flutter/material.dart'; class ComponentScreen extends StatelessWidget { - const ComponentScreen({Key? key, required this.showNavBottomBar}) - : super(key: key); + const ComponentScreen({super.key, required this.showNavBottomBar}); final bool showNavBottomBar; @@ -70,7 +69,7 @@ void Function()? handlePressed( } class Buttons extends StatefulWidget { - const Buttons({Key? key}) : super(key: key); + const Buttons({super.key}); @override State createState() => _ButtonsState(); @@ -95,8 +94,7 @@ class _ButtonsState extends State { class ButtonsWithoutIcon extends StatelessWidget { final bool isDisabled; - const ButtonsWithoutIcon({Key? key, required this.isDisabled}) - : super(key: key); + const ButtonsWithoutIcon({super.key, required this.isDisabled}); @override Widget build(BuildContext context) { @@ -146,7 +144,7 @@ class ButtonsWithoutIcon extends StatelessWidget { } class ButtonsWithIcon extends StatelessWidget { - const ButtonsWithIcon({Key? key}) : super(key: key); + const ButtonsWithIcon({super.key}); @override Widget build(BuildContext context) { @@ -205,7 +203,7 @@ class ButtonsWithIcon extends StatelessWidget { } class FloatingActionButtons extends StatelessWidget { - const FloatingActionButtons({Key? key}) : super(key: key); + const FloatingActionButtons({super.key}); @override Widget build(BuildContext context) { @@ -242,7 +240,7 @@ class FloatingActionButtons extends StatelessWidget { } class Cards extends StatelessWidget { - const Cards({Key? key}) : super(key: key); + const Cards({super.key}); @override Widget build(BuildContext context) { @@ -330,7 +328,7 @@ class Cards extends StatelessWidget { } class Dialogs extends StatefulWidget { - const Dialogs({Key? key}) : super(key: key); + const Dialogs({super.key}); @override State createState() => _DialogsState(); @@ -443,11 +441,10 @@ class NavigationBars extends StatefulWidget { final bool isExampleBar; const NavigationBars( - {Key? key, + {super.key, this.onSelectItem, required this.selectedIndex, - required this.isExampleBar}) - : super(key: key); + required this.isExampleBar}); @override State createState() => _NavigationBarsState(); @@ -483,8 +480,7 @@ class NavigationRailSection extends StatefulWidget { final int selectedIndex; const NavigationRailSection( - {Key? key, required this.onSelectItem, required this.selectedIndex}) - : super(key: key); + {super.key, required this.onSelectItem, required this.selectedIndex}); @override State createState() => _NavigationRailSectionState(); diff --git a/material_3_demo/lib/elevation_screen.dart b/material_3_demo/lib/elevation_screen.dart index fa5c559b7..bd2a0409d 100644 --- a/material_3_demo/lib/elevation_screen.dart +++ b/material_3_demo/lib/elevation_screen.dart @@ -1,7 +1,7 @@ import 'package:flutter/material.dart'; class ElevationScreen extends StatelessWidget { - const ElevationScreen({Key? key}) : super(key: key); + const ElevationScreen({super.key}); @override Widget build(BuildContext context) { @@ -48,8 +48,7 @@ class ElevationScreen extends StatelessWidget { const double narrowScreenWidthThreshold = 450; class ElevationGrid extends StatelessWidget { - const ElevationGrid({Key? key, this.shadowColor, this.surfaceTintColor}) - : super(key: key); + const ElevationGrid({super.key, this.shadowColor, this.surfaceTintColor}); final Color? shadowColor; final Color? surfaceTintColor; @@ -92,8 +91,7 @@ class ElevationGrid extends StatelessWidget { class ElevationCard extends StatefulWidget { const ElevationCard( - {Key? key, required this.info, this.shadowColor, this.surfaceTint}) - : super(key: key); + {super.key, required this.info, this.shadowColor, this.surfaceTint}); final ElevationInfo info; final Color? shadowColor; diff --git a/material_3_demo/lib/main.dart b/material_3_demo/lib/main.dart index 00e377d3a..10dfae1f1 100644 --- a/material_3_demo/lib/main.dart +++ b/material_3_demo/lib/main.dart @@ -10,7 +10,7 @@ void main() { } class Material3Demo extends StatefulWidget { - const Material3Demo({Key? key}) : super(key: key); + const Material3Demo({super.key}); @override State createState() => _Material3DemoState(); diff --git a/material_3_demo/lib/typography_screen.dart b/material_3_demo/lib/typography_screen.dart index 6f70e73c4..0f7cec64f 100644 --- a/material_3_demo/lib/typography_screen.dart +++ b/material_3_demo/lib/typography_screen.dart @@ -1,7 +1,7 @@ import 'package:flutter/material.dart'; class TypographyScreen extends StatelessWidget { - const TypographyScreen({Key? key}) : super(key: key); + const TypographyScreen({super.key}); @override Widget build(BuildContext context) { @@ -41,10 +41,10 @@ class TypographyScreen extends StatelessWidget { class TextStyleExample extends StatelessWidget { const TextStyleExample({ - Key? key, + super.key, required this.name, required this.style, - }) : super(key: key); + }); final String name; final TextStyle style; diff --git a/navigation_and_routing/lib/src/app.dart b/navigation_and_routing/lib/src/app.dart index e897400d9..04ec76454 100644 --- a/navigation_and_routing/lib/src/app.dart +++ b/navigation_and_routing/lib/src/app.dart @@ -9,7 +9,7 @@ import 'routing.dart'; import 'screens/navigator.dart'; class Bookstore extends StatefulWidget { - const Bookstore({Key? key}) : super(key: key); + const Bookstore({super.key}); @override State createState() => _BookstoreState(); diff --git a/navigation_and_routing/lib/src/auth.dart b/navigation_and_routing/lib/src/auth.dart index 9f8d33971..e037369de 100644 --- a/navigation_and_routing/lib/src/auth.dart +++ b/navigation_and_routing/lib/src/auth.dart @@ -36,10 +36,10 @@ class BookstoreAuth extends ChangeNotifier { class BookstoreAuthScope extends InheritedNotifier { const BookstoreAuthScope({ - required BookstoreAuth notifier, - required Widget child, - Key? key, - }) : super(key: key, notifier: notifier, child: child); + required super.notifier, + required super.child, + super.key, + }); static BookstoreAuth of(BuildContext context) => context .dependOnInheritedWidgetOfExactType()! diff --git a/navigation_and_routing/lib/src/routing/route_state.dart b/navigation_and_routing/lib/src/routing/route_state.dart index 38fb8f076..56a10d091 100644 --- a/navigation_and_routing/lib/src/routing/route_state.dart +++ b/navigation_and_routing/lib/src/routing/route_state.dart @@ -38,10 +38,10 @@ class RouteState extends ChangeNotifier { /// Provides the current [RouteState] to descendant widgets in the tree. class RouteStateScope extends InheritedNotifier { const RouteStateScope({ - required RouteState notifier, - required Widget child, - Key? key, - }) : super(key: key, notifier: notifier, child: child); + required super.notifier, + required super.child, + super.key, + }); static RouteState of(BuildContext context) => context.dependOnInheritedWidgetOfExactType()!.notifier!; diff --git a/navigation_and_routing/lib/src/screens/author_details.dart b/navigation_and_routing/lib/src/screens/author_details.dart index 3de7a4968..d45f861b5 100644 --- a/navigation_and_routing/lib/src/screens/author_details.dart +++ b/navigation_and_routing/lib/src/screens/author_details.dart @@ -12,9 +12,9 @@ class AuthorDetailsScreen extends StatelessWidget { final Author author; const AuthorDetailsScreen({ - Key? key, + super.key, required this.author, - }) : super(key: key); + }); @override Widget build(BuildContext context) => Scaffold( diff --git a/navigation_and_routing/lib/src/screens/authors.dart b/navigation_and_routing/lib/src/screens/authors.dart index f2a046e52..8965f91d9 100644 --- a/navigation_and_routing/lib/src/screens/authors.dart +++ b/navigation_and_routing/lib/src/screens/authors.dart @@ -11,7 +11,7 @@ import '../widgets/author_list.dart'; class AuthorsScreen extends StatelessWidget { final String title = 'Authors'; - const AuthorsScreen({Key? key}) : super(key: key); + const AuthorsScreen({super.key}); @override Widget build(BuildContext context) => Scaffold( diff --git a/navigation_and_routing/lib/src/screens/book_details.dart b/navigation_and_routing/lib/src/screens/book_details.dart index 961edf8f7..ed368a0ea 100644 --- a/navigation_and_routing/lib/src/screens/book_details.dart +++ b/navigation_and_routing/lib/src/screens/book_details.dart @@ -12,9 +12,9 @@ class BookDetailsScreen extends StatelessWidget { final Book? book; const BookDetailsScreen({ - Key? key, + super.key, this.book, - }) : super(key: key); + }); @override Widget build(BuildContext context) { diff --git a/navigation_and_routing/lib/src/screens/books.dart b/navigation_and_routing/lib/src/screens/books.dart index 1be63dbd8..4fc6509f0 100644 --- a/navigation_and_routing/lib/src/screens/books.dart +++ b/navigation_and_routing/lib/src/screens/books.dart @@ -10,8 +10,8 @@ import '../widgets/book_list.dart'; class BooksScreen extends StatefulWidget { const BooksScreen({ - Key? key, - }) : super(key: key); + super.key, + }); @override State createState() => _BooksScreenState(); diff --git a/navigation_and_routing/lib/src/screens/navigator.dart b/navigation_and_routing/lib/src/screens/navigator.dart index 2d0b1fe3e..0f62f503e 100644 --- a/navigation_and_routing/lib/src/screens/navigator.dart +++ b/navigation_and_routing/lib/src/screens/navigator.dart @@ -21,8 +21,8 @@ class BookstoreNavigator extends StatefulWidget { const BookstoreNavigator({ required this.navigatorKey, - Key? key, - }) : super(key: key); + super.key, + }); @override State createState() => _BookstoreNavigatorState(); diff --git a/navigation_and_routing/lib/src/screens/scaffold.dart b/navigation_and_routing/lib/src/screens/scaffold.dart index f13734375..494919192 100644 --- a/navigation_and_routing/lib/src/screens/scaffold.dart +++ b/navigation_and_routing/lib/src/screens/scaffold.dart @@ -10,8 +10,8 @@ import 'scaffold_body.dart'; class BookstoreScaffold extends StatelessWidget { const BookstoreScaffold({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/navigation_and_routing/lib/src/screens/scaffold_body.dart b/navigation_and_routing/lib/src/screens/scaffold_body.dart index 6b784ec0e..868e32ef7 100644 --- a/navigation_and_routing/lib/src/screens/scaffold_body.dart +++ b/navigation_and_routing/lib/src/screens/scaffold_body.dart @@ -16,8 +16,8 @@ class BookstoreScaffoldBody extends StatelessWidget { static GlobalKey navigatorKey = GlobalKey(); const BookstoreScaffoldBody({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/navigation_and_routing/lib/src/screens/settings.dart b/navigation_and_routing/lib/src/screens/settings.dart index e003da272..ff0d41a97 100644 --- a/navigation_and_routing/lib/src/screens/settings.dart +++ b/navigation_and_routing/lib/src/screens/settings.dart @@ -9,7 +9,7 @@ import '../auth.dart'; import '../routing.dart'; class SettingsScreen extends StatefulWidget { - const SettingsScreen({Key? key}) : super(key: key); + const SettingsScreen({super.key}); @override State createState() => _SettingsScreenState(); @@ -39,8 +39,8 @@ class _SettingsScreenState extends State { class SettingsContent extends StatelessWidget { const SettingsContent({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) => Column( diff --git a/navigation_and_routing/lib/src/screens/sign_in.dart b/navigation_and_routing/lib/src/screens/sign_in.dart index 4ca735379..7131cdf3c 100644 --- a/navigation_and_routing/lib/src/screens/sign_in.dart +++ b/navigation_and_routing/lib/src/screens/sign_in.dart @@ -16,8 +16,8 @@ class SignInScreen extends StatefulWidget { const SignInScreen({ required this.onSignIn, - Key? key, - }) : super(key: key); + super.key, + }); @override State createState() => _SignInScreenState(); diff --git a/navigation_and_routing/lib/src/widgets/author_list.dart b/navigation_and_routing/lib/src/widgets/author_list.dart index 82d4c7cc9..88906962a 100644 --- a/navigation_and_routing/lib/src/widgets/author_list.dart +++ b/navigation_and_routing/lib/src/widgets/author_list.dart @@ -13,8 +13,8 @@ class AuthorList extends StatelessWidget { const AuthorList({ required this.authors, this.onTap, - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) => ListView.builder( diff --git a/navigation_and_routing/lib/src/widgets/book_list.dart b/navigation_and_routing/lib/src/widgets/book_list.dart index a267a14de..b3c637098 100644 --- a/navigation_and_routing/lib/src/widgets/book_list.dart +++ b/navigation_and_routing/lib/src/widgets/book_list.dart @@ -13,8 +13,8 @@ class BookList extends StatelessWidget { const BookList({ required this.books, this.onTap, - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) => ListView.builder( diff --git a/navigation_and_routing/pubspec.lock b/navigation_and_routing/pubspec.lock index fb44b79b4..470c1a0e1 100644 --- a/navigation_and_routing/pubspec.lock +++ b/navigation_and_routing/pubspec.lock @@ -7,7 +7,7 @@ packages: name: _fe_analyzer_shared url: "https://pub.dartlang.org" source: hosted - version: "31.0.0" + version: "39.0.0" adaptive_breakpoints: dependency: transitive description: @@ -28,7 +28,7 @@ packages: name: analyzer url: "https://pub.dartlang.org" source: hosted - version: "2.8.0" + version: "4.0.0" args: dependency: transitive description: @@ -64,13 +64,6 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.3.1" - cli_util: - dependency: transitive - description: - name: cli_util - url: "https://pub.dartlang.org" - source: hosted - version: "0.3.5" clock: dependency: transitive description: @@ -84,7 +77,7 @@ packages: name: collection url: "https://pub.dartlang.org" source: hosted - version: "1.15.0" + version: "1.16.0" convert: dependency: transitive description: @@ -119,7 +112,7 @@ packages: name: fake_async url: "https://pub.dartlang.org" source: hosted - version: "1.2.0" + version: "1.3.0" file: dependency: transitive description: @@ -190,7 +183,7 @@ packages: name: js url: "https://pub.dartlang.org" source: hosted - version: "0.6.3" + version: "0.6.4" lints: dependency: transitive description: @@ -218,7 +211,7 @@ packages: name: material_color_utilities url: "https://pub.dartlang.org" source: hosted - version: "0.1.3" + version: "0.1.4" meta: dependency: transitive description: @@ -253,7 +246,7 @@ packages: name: path url: "https://pub.dartlang.org" source: hosted - version: "1.8.0" + version: "1.8.1" path_to_regexp: dependency: "direct main" description: @@ -342,7 +335,7 @@ packages: name: source_span url: "https://pub.dartlang.org" source: hosted - version: "1.8.1" + version: "1.8.2" stack_trace: dependency: transitive description: @@ -377,21 +370,21 @@ packages: name: test url: "https://pub.dartlang.org" source: hosted - version: "1.19.5" + version: "1.21.1" test_api: dependency: transitive description: name: test_api url: "https://pub.dartlang.org" source: hosted - version: "0.4.8" + version: "0.4.9" test_core: dependency: transitive description: name: test_core url: "https://pub.dartlang.org" source: hosted - version: "0.4.9" + version: "0.4.13" typed_data: dependency: transitive description: @@ -468,7 +461,7 @@ packages: name: vector_math url: "https://pub.dartlang.org" source: hosted - version: "2.1.1" + version: "2.1.2" vm_service: dependency: transitive description: diff --git a/null_safety/null_safe_app/lib/badapp.dart b/null_safety/null_safe_app/lib/badapp.dart index 74b74033e..01490c768 100644 --- a/null_safety/null_safe_app/lib/badapp.dart +++ b/null_safety/null_safe_app/lib/badapp.dart @@ -12,7 +12,7 @@ import 'services.dart'; // uncomment the for-loop and appBar lines below, and note how the new null // safety static analysis immediately flags those lines as errors. class BadMyApp extends StatelessWidget { - const BadMyApp({Key? key}) : super(key: key); + const BadMyApp({super.key}); @override Widget build(BuildContext context) { diff --git a/null_safety/null_safe_app/lib/goodapp.dart b/null_safety/null_safe_app/lib/goodapp.dart index 95bf43b4f..27bc5f979 100644 --- a/null_safety/null_safe_app/lib/goodapp.dart +++ b/null_safety/null_safe_app/lib/goodapp.dart @@ -7,7 +7,7 @@ import 'package:flutter/material.dart'; import 'services.dart'; class GoodMyApp extends StatelessWidget { - const GoodMyApp({Key? key}) : super(key: key); + const GoodMyApp({super.key}); @override Widget build(BuildContext context) { diff --git a/place_tracker/lib/place_details.dart b/place_tracker/lib/place_details.dart index 71e718c0c..fa9e677f9 100644 --- a/place_tracker/lib/place_details.dart +++ b/place_tracker/lib/place_details.dart @@ -15,8 +15,8 @@ class PlaceDetails extends StatefulWidget { const PlaceDetails({ required this.place, required this.onChanged, - Key? key, - }) : super(key: key); + super.key, + }); @override State createState() => _PlaceDetailsState(); @@ -122,8 +122,7 @@ class _DescriptionTextField extends StatelessWidget { const _DescriptionTextField({ required this.controller, required this.onChanged, - Key? key, - }) : super(key: key); + }); @override Widget build(BuildContext context) { @@ -157,8 +156,7 @@ class _Map extends StatelessWidget { required this.mapController, required this.onMapCreated, required this.markers, - Key? key, - }) : super(key: key); + }); @override Widget build(BuildContext context) { @@ -192,8 +190,7 @@ class _NameTextField extends StatelessWidget { const _NameTextField({ required this.controller, required this.onChanged, - Key? key, - }) : super(key: key); + }); @override Widget build(BuildContext context) { @@ -216,9 +213,7 @@ class _NameTextField extends StatelessWidget { } class _Reviews extends StatelessWidget { - const _Reviews({ - Key? key, - }) : super(key: key); + const _Reviews(); @override Widget build(BuildContext context) { @@ -312,9 +307,7 @@ class _StarBar extends StatelessWidget { const _StarBar({ required this.rating, required this.onChanged, - Key? key, - }) : assert(rating >= 0 && rating <= maxStars), - super(key: key); + }) : assert(rating >= 0 && rating <= maxStars); @override Widget build(BuildContext context) { diff --git a/place_tracker/lib/place_list.dart b/place_tracker/lib/place_list.dart index f041ff053..77df98010 100644 --- a/place_tracker/lib/place_list.dart +++ b/place_tracker/lib/place_list.dart @@ -10,7 +10,7 @@ import 'place_details.dart'; import 'place_tracker_app.dart'; class PlaceList extends StatefulWidget { - const PlaceList({Key? key}) : super(key: key); + const PlaceList({super.key}); @override State createState() => _PlaceListState(); @@ -69,11 +69,10 @@ class _CategoryButton extends StatelessWidget { final bool selected; final ValueChanged onCategoryChanged; const _CategoryButton({ - Key? key, required this.category, required this.selected, required this.onCategoryChanged, - }) : super(key: key); + }); @override Widget build(BuildContext context) { @@ -120,10 +119,9 @@ class _ListCategoryButtonBar extends StatelessWidget { final ValueChanged onCategoryChanged; const _ListCategoryButtonBar({ - Key? key, required this.selectedCategory, required this.onCategoryChanged, - }) : super(key: key); + }); @override Widget build(BuildContext context) { @@ -155,10 +153,9 @@ class _PlaceListTile extends StatelessWidget { final ValueChanged onPlaceChanged; const _PlaceListTile({ - Key? key, required this.place, required this.onPlaceChanged, - }) : super(key: key); + }); @override Widget build(BuildContext context) { diff --git a/place_tracker/lib/place_map.dart b/place_tracker/lib/place_map.dart index 92a36081f..bbf8b5c55 100644 --- a/place_tracker/lib/place_map.dart +++ b/place_tracker/lib/place_map.dart @@ -54,9 +54,9 @@ class PlaceMap extends StatefulWidget { final LatLng? center; const PlaceMap({ - Key? key, + super.key, this.center, - }) : super(key: key); + }); @override State createState() => _PlaceMapState(); @@ -453,11 +453,10 @@ class _AddPlaceButtonBar extends StatelessWidget { final VoidCallback onCancelPressed; const _AddPlaceButtonBar({ - Key? key, required this.visible, required this.onSavePressed, required this.onCancelPressed, - }) : super(key: key); + }); @override Widget build(BuildContext context) { @@ -498,11 +497,10 @@ class _CategoryButtonBar extends StatelessWidget { final ValueChanged onChanged; const _CategoryButtonBar({ - Key? key, required this.selectedPlaceCategory, required this.visible, required this.onChanged, - }) : super(key: key); + }); @override Widget build(BuildContext context) { @@ -560,11 +558,10 @@ class _MapFabs extends StatelessWidget { final VoidCallback onToggleMapTypePressed; const _MapFabs({ - Key? key, required this.visible, required this.onAddPlacePressed, required this.onToggleMapTypePressed, - }) : super(key: key); + }); @override Widget build(BuildContext context) { diff --git a/place_tracker/lib/place_tracker_app.dart b/place_tracker/lib/place_tracker_app.dart index 56ac95c83..1a9a41dea 100644 --- a/place_tracker/lib/place_tracker_app.dart +++ b/place_tracker/lib/place_tracker_app.dart @@ -17,7 +17,7 @@ enum PlaceTrackerViewType { } class PlaceTrackerApp extends StatelessWidget { - const PlaceTrackerApp({Key? key}) : super(key: key); + const PlaceTrackerApp({super.key}); @override Widget build(BuildContext context) { @@ -28,7 +28,7 @@ class PlaceTrackerApp extends StatelessWidget { } class _PlaceTrackerHomePage extends StatelessWidget { - const _PlaceTrackerHomePage({Key? key}) : super(key: key); + const _PlaceTrackerHomePage(); @override Widget build(BuildContext context) { diff --git a/place_tracker/pubspec.lock b/place_tracker/pubspec.lock index 1bab659b7..434b3cfaa 100644 --- a/place_tracker/pubspec.lock +++ b/place_tracker/pubspec.lock @@ -42,7 +42,7 @@ packages: name: collection url: "https://pub.dartlang.org" source: hosted - version: "1.15.0" + version: "1.16.0" crypto: dependency: transitive description: @@ -70,7 +70,7 @@ packages: name: fake_async url: "https://pub.dartlang.org" source: hosted - version: "1.2.0" + version: "1.3.0" flutter: dependency: "direct main" description: flutter @@ -141,7 +141,7 @@ packages: name: js url: "https://pub.dartlang.org" source: hosted - version: "0.6.3" + version: "0.6.4" js_wrapping: dependency: transitive description: @@ -169,7 +169,7 @@ packages: name: material_color_utilities url: "https://pub.dartlang.org" source: hosted - version: "0.1.3" + version: "0.1.4" meta: dependency: transitive description: @@ -190,7 +190,7 @@ packages: name: path url: "https://pub.dartlang.org" source: hosted - version: "1.8.0" + version: "1.8.1" pedantic: dependency: transitive description: @@ -230,7 +230,7 @@ packages: name: source_span url: "https://pub.dartlang.org" source: hosted - version: "1.8.1" + version: "1.8.2" stack_trace: dependency: transitive description: @@ -272,7 +272,7 @@ packages: name: test_api url: "https://pub.dartlang.org" source: hosted - version: "0.4.8" + version: "0.4.9" typed_data: dependency: transitive description: @@ -293,7 +293,7 @@ packages: name: vector_math url: "https://pub.dartlang.org" source: hosted - version: "2.1.1" + version: "2.1.2" sdks: dart: ">=2.17.0-206.0.dev <3.0.0" flutter: ">=2.5.0" diff --git a/platform_channels/lib/main.dart b/platform_channels/lib/main.dart index c45a3b10f..d12250f4e 100644 --- a/platform_channels/lib/main.dart +++ b/platform_channels/lib/main.dart @@ -14,7 +14,7 @@ void main() { } class PlatformChannelSample extends StatelessWidget { - const PlatformChannelSample({Key? key}) : super(key: key); + const PlatformChannelSample({super.key}); @override Widget build(BuildContext context) { @@ -64,7 +64,7 @@ List demoList = [ ]; class HomePage extends StatelessWidget { - const HomePage({Key? key}) : super(key: key); + const HomePage({super.key}); @override Widget build(BuildContext context) { @@ -83,7 +83,7 @@ class HomePage extends StatelessWidget { class DemoTile extends StatelessWidget { final DemoInfo demoInfo; - const DemoTile(this.demoInfo, {Key? key}) : super(key: key); + const DemoTile(this.demoInfo, {super.key}); @override Widget build(BuildContext context) { diff --git a/platform_channels/lib/src/add_pet_details.dart b/platform_channels/lib/src/add_pet_details.dart index dc49a33f0..96151b370 100644 --- a/platform_channels/lib/src/add_pet_details.dart +++ b/platform_channels/lib/src/add_pet_details.dart @@ -10,7 +10,7 @@ import 'package:platform_channels/src/pet_list_message_channel.dart'; /// The widget uses [TextField] and [RadioListTile] to take the [PetDetails.breed] and /// [PetDetails.petType] from the user respectively. class AddPetDetails extends StatefulWidget { - const AddPetDetails({Key? key}) : super(key: key); + const AddPetDetails({super.key}); @override State createState() => _AddPetDetailsState(); diff --git a/platform_channels/lib/src/event_channel_demo.dart b/platform_channels/lib/src/event_channel_demo.dart index ba013aa8e..6164f87c0 100644 --- a/platform_channels/lib/src/event_channel_demo.dart +++ b/platform_channels/lib/src/event_channel_demo.dart @@ -14,7 +14,7 @@ import 'package:platform_channels/src/accelerometer_event_channel.dart'; /// [Text] widgets to display the value of [AccelerometerReadings.x], /// [AccelerometerReadings.y], and [AccelerometerReadings.z] respectively. class EventChannelDemo extends StatelessWidget { - const EventChannelDemo({Key? key}) : super(key: key); + const EventChannelDemo({super.key}); @override Widget build(BuildContext context) { diff --git a/platform_channels/lib/src/method_channel_demo.dart b/platform_channels/lib/src/method_channel_demo.dart index 2db100b38..871d87abe 100644 --- a/platform_channels/lib/src/method_channel_demo.dart +++ b/platform_channels/lib/src/method_channel_demo.dart @@ -10,7 +10,7 @@ import 'package:platform_channels/src/counter_method_channel.dart'; /// It has two [ElevatedButton]s to increment and decrement the value of /// [count], and a [Text] widget to display its value. class MethodChannelDemo extends StatefulWidget { - const MethodChannelDemo({Key? key}) : super(key: key); + const MethodChannelDemo({super.key}); @override State createState() => _MethodChannelDemoState(); diff --git a/platform_channels/lib/src/pet_list_screen.dart b/platform_channels/lib/src/pet_list_screen.dart index e24956639..c3b7b0056 100644 --- a/platform_channels/lib/src/pet_list_screen.dart +++ b/platform_channels/lib/src/pet_list_screen.dart @@ -9,7 +9,7 @@ import 'package:platform_channels/src/pet_list_message_channel.dart'; /// Demonstrates how to use [BasicMessageChannel] to send & receive the platform /// Message. class PetListScreen extends StatefulWidget { - const PetListScreen({Key? key}) : super(key: key); + const PetListScreen({super.key}); @override State createState() => _PetListScreenState(); @@ -66,7 +66,7 @@ class _PetListScreenState extends State { class BuildPetList extends StatelessWidget { final List petList; - const BuildPetList(this.petList, {Key? key}) : super(key: key); + const BuildPetList(this.petList, {super.key}); @override Widget build(BuildContext context) { diff --git a/platform_channels/lib/src/platform_image_demo.dart b/platform_channels/lib/src/platform_image_demo.dart index b29b73e3e..25eb4d66f 100644 --- a/platform_channels/lib/src/platform_image_demo.dart +++ b/platform_channels/lib/src/platform_image_demo.dart @@ -13,7 +13,7 @@ import 'package:platform_channels/src/image_basic_message_channel.dart'; /// The widget uses [Image.memory] to display the image obtained from the /// platform. class PlatformImageDemo extends StatefulWidget { - const PlatformImageDemo({Key? key}) : super(key: key); + const PlatformImageDemo({super.key}); @override State createState() => _PlatformImageDemoState(); diff --git a/platform_design/lib/main.dart b/platform_design/lib/main.dart index 66c65d1c6..1151bf8c1 100644 --- a/platform_design/lib/main.dart +++ b/platform_design/lib/main.dart @@ -14,7 +14,7 @@ import 'widgets.dart'; void main() => runApp(const MyAdaptingApp()); class MyAdaptingApp extends StatelessWidget { - const MyAdaptingApp({Key? key}) : super(key: key); + const MyAdaptingApp({super.key}); @override Widget build(context) { @@ -49,7 +49,7 @@ class MyAdaptingApp extends StatelessWidget { // These differences are also subjective and have more than one 'right' answer // depending on the app and content. class PlatformAdaptingHomePage extends StatefulWidget { - const PlatformAdaptingHomePage({Key? key}) : super(key: key); + const PlatformAdaptingHomePage({super.key}); @override State createState() => diff --git a/platform_design/lib/news_tab.dart b/platform_design/lib/news_tab.dart index 87896a1a1..d3e8246a7 100644 --- a/platform_design/lib/news_tab.dart +++ b/platform_design/lib/news_tab.dart @@ -15,7 +15,7 @@ class NewsTab extends StatefulWidget { static const androidIcon = Icon(Icons.library_books); static const iosIcon = Icon(CupertinoIcons.news); - const NewsTab({Key? key}) : super(key: key); + const NewsTab({super.key}); @override State createState() => _NewsTabState(); diff --git a/platform_design/lib/profile_tab.dart b/platform_design/lib/profile_tab.dart index e203ac494..42d166991 100644 --- a/platform_design/lib/profile_tab.dart +++ b/platform_design/lib/profile_tab.dart @@ -13,7 +13,7 @@ class ProfileTab extends StatelessWidget { static const androidIcon = Icon(Icons.person); static const iosIcon = Icon(CupertinoIcons.profile_circled); - const ProfileTab({Key? key}) : super(key: key); + const ProfileTab({super.key}); Widget _buildBody(BuildContext context) { return SafeArea( @@ -115,8 +115,8 @@ class PreferenceCard extends StatelessWidget { required this.header, required this.content, required this.preferenceChoices, - Key? key, - }) : super(key: key); + super.key, + }); final String header; final String content; @@ -174,7 +174,7 @@ class LogOutButton extends StatelessWidget { static const _logoutMessage = Text( "You can't actually log out! This is just a demo of how alerts work."); - const LogOutButton({Key? key}) : super(key: key); + const LogOutButton({super.key}); // =========================================================================== // Non-shared code below because this tab shows different interfaces. On diff --git a/platform_design/lib/settings_tab.dart b/platform_design/lib/settings_tab.dart index c39cfd13f..9eb7d36be 100644 --- a/platform_design/lib/settings_tab.dart +++ b/platform_design/lib/settings_tab.dart @@ -12,7 +12,7 @@ class SettingsTab extends StatefulWidget { static const androidIcon = Icon(Icons.settings); static const iosIcon = Icon(CupertinoIcons.gear); - const SettingsTab({Key? key}) : super(key: key); + const SettingsTab({super.key}); @override State createState() => _SettingsTabState(); diff --git a/platform_design/lib/song_detail_tab.dart b/platform_design/lib/song_detail_tab.dart index e4eb0162f..fe43c5a7c 100644 --- a/platform_design/lib/song_detail_tab.dart +++ b/platform_design/lib/song_detail_tab.dart @@ -16,8 +16,8 @@ class SongDetailTab extends StatelessWidget { required this.id, required this.song, required this.color, - Key? key, - }) : super(key: key); + super.key, + }); final int id; final String song; diff --git a/platform_design/lib/songs_tab.dart b/platform_design/lib/songs_tab.dart index 71f8e1e26..45951bba8 100644 --- a/platform_design/lib/songs_tab.dart +++ b/platform_design/lib/songs_tab.dart @@ -15,7 +15,7 @@ class SongsTab extends StatefulWidget { static const androidIcon = Icon(Icons.music_note); static const iosIcon = Icon(CupertinoIcons.music_note); - const SongsTab({Key? key, this.androidDrawer}) : super(key: key); + const SongsTab({super.key, this.androidDrawer}); final Widget? androidDrawer; diff --git a/platform_design/lib/widgets.dart b/platform_design/lib/widgets.dart index a26ed9dbd..6c593259e 100644 --- a/platform_design/lib/widgets.dart +++ b/platform_design/lib/widgets.dart @@ -9,10 +9,10 @@ import 'package:flutter/material.dart'; /// A simple widget that builds different things on different platforms. class PlatformWidget extends StatelessWidget { const PlatformWidget({ - Key? key, + super.key, required this.androidBuilder, required this.iosBuilder, - }) : super(key: key); + }); final WidgetBuilder androidBuilder; final WidgetBuilder iosBuilder; @@ -41,8 +41,8 @@ class PressableCard extends StatefulWidget { required this.color, required this.flattenAnimation, this.child, - Key? key, - }) : super(key: key); + super.key, + }); final VoidCallback? onPressed; final Color color; @@ -141,8 +141,8 @@ class HeroAnimatingSongCard extends StatelessWidget { required this.color, required this.heroAnimation, this.onPressed, - Key? key, - }) : super(key: key); + super.key, + }); final String song; final Color color; @@ -220,7 +220,7 @@ class HeroAnimatingSongCard extends StatelessWidget { /// This is an example of a custom widget that an app developer might create for /// use on both iOS and Android as part of their brand's unique design. class SongPlaceholderTile extends StatelessWidget { - const SongPlaceholderTile({Key? key}) : super(key: key); + const SongPlaceholderTile({super.key}); @override Widget build(BuildContext context) { diff --git a/platform_view_swift/lib/main.dart b/platform_view_swift/lib/main.dart index ffe19916b..add62b313 100644 --- a/platform_view_swift/lib/main.dart +++ b/platform_view_swift/lib/main.dart @@ -12,7 +12,7 @@ void main() { } class PlatformView extends StatelessWidget { - const PlatformView({Key? key}) : super(key: key); + const PlatformView({super.key}); @override Widget build(BuildContext context) { @@ -27,7 +27,7 @@ class PlatformView extends StatelessWidget { } class HomePage extends StatefulWidget { - const HomePage({Key? key}) : super(key: key); + const HomePage({super.key}); @override State createState() => _HomePageState(); diff --git a/provider_counter/lib/main.dart b/provider_counter/lib/main.dart index 1f5cd96a8..d02d4e37f 100644 --- a/provider_counter/lib/main.dart +++ b/provider_counter/lib/main.dart @@ -61,7 +61,7 @@ class Counter with ChangeNotifier { } class MyApp extends StatelessWidget { - const MyApp({Key? key}) : super(key: key); + const MyApp({super.key}); @override Widget build(BuildContext context) { @@ -76,7 +76,7 @@ class MyApp extends StatelessWidget { } class MyHomePage extends StatelessWidget { - const MyHomePage({Key? key}) : super(key: key); + const MyHomePage({super.key}); @override Widget build(BuildContext context) { diff --git a/provider_shopper/lib/main.dart b/provider_shopper/lib/main.dart index e7c97447c..2a3e4fa6b 100644 --- a/provider_shopper/lib/main.dart +++ b/provider_shopper/lib/main.dart @@ -40,7 +40,7 @@ void setupWindow() { } class MyApp extends StatelessWidget { - const MyApp({Key? key}) : super(key: key); + const MyApp({super.key}); @override Widget build(BuildContext context) { diff --git a/provider_shopper/lib/screens/cart.dart b/provider_shopper/lib/screens/cart.dart index 53bbd02a5..eea8f990d 100644 --- a/provider_shopper/lib/screens/cart.dart +++ b/provider_shopper/lib/screens/cart.dart @@ -7,7 +7,7 @@ import 'package:provider/provider.dart'; import 'package:provider_shopper/models/cart.dart'; class MyCart extends StatelessWidget { - const MyCart({Key? key}) : super(key: key); + const MyCart({super.key}); @override Widget build(BuildContext context) { diff --git a/provider_shopper/lib/screens/catalog.dart b/provider_shopper/lib/screens/catalog.dart index 3580469b8..74cd7e848 100644 --- a/provider_shopper/lib/screens/catalog.dart +++ b/provider_shopper/lib/screens/catalog.dart @@ -8,7 +8,7 @@ import 'package:provider_shopper/models/cart.dart'; import 'package:provider_shopper/models/catalog.dart'; class MyCatalog extends StatelessWidget { - const MyCatalog({Key? key}) : super(key: key); + const MyCatalog({super.key}); @override Widget build(BuildContext context) { @@ -30,7 +30,7 @@ class MyCatalog extends StatelessWidget { class _AddButton extends StatelessWidget { final Item item; - const _AddButton({required this.item, Key? key}) : super(key: key); + const _AddButton({required this.item}); @override Widget build(BuildContext context) { @@ -90,7 +90,7 @@ class _MyAppBar extends StatelessWidget { class _MyListItem extends StatelessWidget { final int index; - const _MyListItem(this.index, {Key? key}) : super(key: key); + const _MyListItem(this.index); @override Widget build(BuildContext context) { diff --git a/provider_shopper/lib/screens/login.dart b/provider_shopper/lib/screens/login.dart index f461fdd2e..4c6e529e2 100644 --- a/provider_shopper/lib/screens/login.dart +++ b/provider_shopper/lib/screens/login.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class MyLogin extends StatelessWidget { - const MyLogin({Key? key}) : super(key: key); + const MyLogin({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/lib/main.dart b/simplistic_calculator/lib/main.dart index 4d2e07b36..13a18ae89 100644 --- a/simplistic_calculator/lib/main.dart +++ b/simplistic_calculator/lib/main.dart @@ -338,7 +338,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { @@ -453,11 +453,11 @@ enum CalcButtonType { outlined, elevated } class CalcButton extends ConsumerWidget { const CalcButton({ - Key? key, + super.key, required this.op, required this.label, required this.type, - }) : super(key: key); + }); final CalculatorEngineCallback op; final String label; diff --git a/simplistic_calculator/pubspec.lock b/simplistic_calculator/pubspec.lock index 1a75b26c3..de0017dc1 100644 --- a/simplistic_calculator/pubspec.lock +++ b/simplistic_calculator/pubspec.lock @@ -96,7 +96,7 @@ packages: name: flutter_lints url: "https://pub.dartlang.org" source: hosted - version: "1.0.4" + version: "2.0.1" flutter_localizations: dependency: transitive description: flutter @@ -127,7 +127,7 @@ packages: name: lints url: "https://pub.dartlang.org" source: hosted - version: "1.0.1" + version: "2.0.0" matcher: dependency: transitive description: @@ -262,5 +262,5 @@ packages: source: git version: "0.1.0" sdks: - dart: ">=2.17.0-0 <3.0.0" + dart: ">=2.17.0-206.0.dev <3.0.0" flutter: ">=2.8.0" diff --git a/simplistic_calculator/pubspec.yaml b/simplistic_calculator/pubspec.yaml index db284a359..8d4963f8b 100644 --- a/simplistic_calculator/pubspec.yaml +++ b/simplistic_calculator/pubspec.yaml @@ -4,7 +4,7 @@ publish_to: 'none' version: 1.0.0+1 environment: - sdk: ">=2.16.1 <3.0.0" + sdk: ">=2.17.0-0 <3.0.0" dependencies: auto_size_text: ^3.0.0 @@ -22,7 +22,7 @@ dependencies: path: plugins/window_size dev_dependencies: - flutter_lints: ^1.0.0 + flutter_lints: ^2.0.1 flutter_test: sdk: flutter diff --git a/simplistic_calculator/typer/main_01.dart b/simplistic_calculator/typer/main_01.dart index 26a960c70..fff109107 100644 --- a/simplistic_calculator/typer/main_01.dart +++ b/simplistic_calculator/typer/main_01.dart @@ -11,7 +11,7 @@ void main() { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_02.dart b/simplistic_calculator/typer/main_02.dart index 964d428df..fde62b05b 100644 --- a/simplistic_calculator/typer/main_02.dart +++ b/simplistic_calculator/typer/main_02.dart @@ -15,7 +15,7 @@ void main() { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_03.dart b/simplistic_calculator/typer/main_03.dart index ff71e4445..baec2b123 100644 --- a/simplistic_calculator/typer/main_03.dart +++ b/simplistic_calculator/typer/main_03.dart @@ -20,7 +20,7 @@ void main() { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_04.dart b/simplistic_calculator/typer/main_04.dart index 3c87f4ad4..22169ea79 100644 --- a/simplistic_calculator/typer/main_04.dart +++ b/simplistic_calculator/typer/main_04.dart @@ -21,7 +21,7 @@ void main() { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_05.dart b/simplistic_calculator/typer/main_05.dart index 513aaf6ac..3b51f76dc 100644 --- a/simplistic_calculator/typer/main_05.dart +++ b/simplistic_calculator/typer/main_05.dart @@ -23,7 +23,7 @@ void main() { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_06.dart b/simplistic_calculator/typer/main_06.dart index 5250d2c55..bab6c706c 100644 --- a/simplistic_calculator/typer/main_06.dart +++ b/simplistic_calculator/typer/main_06.dart @@ -26,7 +26,7 @@ void main() { class CalculatorState {} class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_07.dart b/simplistic_calculator/typer/main_07.dart index b3b4f03d1..8dd5e2739 100644 --- a/simplistic_calculator/typer/main_07.dart +++ b/simplistic_calculator/typer/main_07.dart @@ -28,7 +28,7 @@ class CalculatorState { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_08.dart b/simplistic_calculator/typer/main_08.dart index 0a8abcc41..b093a70eb 100644 --- a/simplistic_calculator/typer/main_08.dart +++ b/simplistic_calculator/typer/main_08.dart @@ -29,7 +29,7 @@ class CalculatorState { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_09.dart b/simplistic_calculator/typer/main_09.dart index 1d00c22a2..2eed048b7 100644 --- a/simplistic_calculator/typer/main_09.dart +++ b/simplistic_calculator/typer/main_09.dart @@ -34,7 +34,7 @@ class CalculatorState { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_10.dart b/simplistic_calculator/typer/main_10.dart index 480f920e8..a4d19e396 100644 --- a/simplistic_calculator/typer/main_10.dart +++ b/simplistic_calculator/typer/main_10.dart @@ -34,7 +34,7 @@ class CalculatorState { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_11.dart b/simplistic_calculator/typer/main_11.dart index dadf5482e..051d1ab5f 100644 --- a/simplistic_calculator/typer/main_11.dart +++ b/simplistic_calculator/typer/main_11.dart @@ -43,7 +43,7 @@ class CalculatorState { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_12.dart b/simplistic_calculator/typer/main_12.dart index 61e220aad..22ee384fc 100644 --- a/simplistic_calculator/typer/main_12.dart +++ b/simplistic_calculator/typer/main_12.dart @@ -45,7 +45,7 @@ class CalculatorState { class CalculatorEngine extends StateNotifier {} class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_13.dart b/simplistic_calculator/typer/main_13.dart index 22fbb6ffe..99eef9eb3 100644 --- a/simplistic_calculator/typer/main_13.dart +++ b/simplistic_calculator/typer/main_13.dart @@ -47,7 +47,7 @@ class CalculatorEngine extends StateNotifier { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_14.dart b/simplistic_calculator/typer/main_14.dart index 4d9480f0b..436d11b1e 100644 --- a/simplistic_calculator/typer/main_14.dart +++ b/simplistic_calculator/typer/main_14.dart @@ -53,7 +53,7 @@ class CalculatorEngine extends StateNotifier { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_15.dart b/simplistic_calculator/typer/main_15.dart index ede116f18..fe1304381 100644 --- a/simplistic_calculator/typer/main_15.dart +++ b/simplistic_calculator/typer/main_15.dart @@ -55,7 +55,7 @@ class CalculatorEngine extends StateNotifier { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_16.dart b/simplistic_calculator/typer/main_16.dart index b66dcc28d..29a1b8b03 100644 --- a/simplistic_calculator/typer/main_16.dart +++ b/simplistic_calculator/typer/main_16.dart @@ -60,7 +60,7 @@ class CalculatorEngine extends StateNotifier { } class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_17.dart b/simplistic_calculator/typer/main_17.dart index 5fa18b9db..20fda7036 100644 --- a/simplistic_calculator/typer/main_17.dart +++ b/simplistic_calculator/typer/main_17.dart @@ -64,7 +64,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends StatelessWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_18.dart b/simplistic_calculator/typer/main_18.dart index 699bd45fb..d4a93f7ba 100644 --- a/simplistic_calculator/typer/main_18.dart +++ b/simplistic_calculator/typer/main_18.dart @@ -64,7 +64,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context) { diff --git a/simplistic_calculator/typer/main_19.dart b/simplistic_calculator/typer/main_19.dart index 3be4e49d8..543a11054 100644 --- a/simplistic_calculator/typer/main_19.dart +++ b/simplistic_calculator/typer/main_19.dart @@ -64,7 +64,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_20.dart b/simplistic_calculator/typer/main_20.dart index 8a9110a99..02340e6a5 100644 --- a/simplistic_calculator/typer/main_20.dart +++ b/simplistic_calculator/typer/main_20.dart @@ -64,7 +64,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_21.dart b/simplistic_calculator/typer/main_21.dart index ce0844fed..bfaa5502a 100644 --- a/simplistic_calculator/typer/main_21.dart +++ b/simplistic_calculator/typer/main_21.dart @@ -64,7 +64,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_22.dart b/simplistic_calculator/typer/main_22.dart index 4dd84e39d..bcd11f443 100644 --- a/simplistic_calculator/typer/main_22.dart +++ b/simplistic_calculator/typer/main_22.dart @@ -64,7 +64,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_23.dart b/simplistic_calculator/typer/main_23.dart index 8d0f28b34..f16360538 100644 --- a/simplistic_calculator/typer/main_23.dart +++ b/simplistic_calculator/typer/main_23.dart @@ -64,7 +64,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_24.dart b/simplistic_calculator/typer/main_24.dart index f81b97686..fa539f1af 100644 --- a/simplistic_calculator/typer/main_24.dart +++ b/simplistic_calculator/typer/main_24.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_25.dart b/simplistic_calculator/typer/main_25.dart index 4e29eabe3..86c77c3f1 100644 --- a/simplistic_calculator/typer/main_25.dart +++ b/simplistic_calculator/typer/main_25.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_26.dart b/simplistic_calculator/typer/main_26.dart index 55f93d89b..6eb6fe206 100644 --- a/simplistic_calculator/typer/main_26.dart +++ b/simplistic_calculator/typer/main_26.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_27.dart b/simplistic_calculator/typer/main_27.dart index 8b7f654a4..8cef3a277 100644 --- a/simplistic_calculator/typer/main_27.dart +++ b/simplistic_calculator/typer/main_27.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_28.dart b/simplistic_calculator/typer/main_28.dart index a3319a592..184dab6ea 100644 --- a/simplistic_calculator/typer/main_28.dart +++ b/simplistic_calculator/typer/main_28.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_29.dart b/simplistic_calculator/typer/main_29.dart index 5d413fd92..f6cd577f7 100644 --- a/simplistic_calculator/typer/main_29.dart +++ b/simplistic_calculator/typer/main_29.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_30.dart b/simplistic_calculator/typer/main_30.dart index bbad58ca4..c13a0007f 100644 --- a/simplistic_calculator/typer/main_30.dart +++ b/simplistic_calculator/typer/main_30.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_31.dart b/simplistic_calculator/typer/main_31.dart index 01e11e03b..6d2facae1 100644 --- a/simplistic_calculator/typer/main_31.dart +++ b/simplistic_calculator/typer/main_31.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_32.dart b/simplistic_calculator/typer/main_32.dart index 98e69c1eb..07400f74d 100644 --- a/simplistic_calculator/typer/main_32.dart +++ b/simplistic_calculator/typer/main_32.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_33.dart b/simplistic_calculator/typer/main_33.dart index aa3d631ac..0a76af2ce 100644 --- a/simplistic_calculator/typer/main_33.dart +++ b/simplistic_calculator/typer/main_33.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_34.dart b/simplistic_calculator/typer/main_34.dart index 429ac7021..1a4a59e3d 100644 --- a/simplistic_calculator/typer/main_34.dart +++ b/simplistic_calculator/typer/main_34.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_35.dart b/simplistic_calculator/typer/main_35.dart index 5995b1ff4..8691ffc00 100644 --- a/simplistic_calculator/typer/main_35.dart +++ b/simplistic_calculator/typer/main_35.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_36.dart b/simplistic_calculator/typer/main_36.dart index 8048558b1..4d25b1a13 100644 --- a/simplistic_calculator/typer/main_36.dart +++ b/simplistic_calculator/typer/main_36.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_37.dart b/simplistic_calculator/typer/main_37.dart index e6932e21d..cb8a5d60c 100644 --- a/simplistic_calculator/typer/main_37.dart +++ b/simplistic_calculator/typer/main_37.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_38.dart b/simplistic_calculator/typer/main_38.dart index b1c3a7e3e..be7a56bcb 100644 --- a/simplistic_calculator/typer/main_38.dart +++ b/simplistic_calculator/typer/main_38.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_39.dart b/simplistic_calculator/typer/main_39.dart index e94ee5b55..6781ecb95 100644 --- a/simplistic_calculator/typer/main_39.dart +++ b/simplistic_calculator/typer/main_39.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_40.dart b/simplistic_calculator/typer/main_40.dart index 0605e2973..81481339c 100644 --- a/simplistic_calculator/typer/main_40.dart +++ b/simplistic_calculator/typer/main_40.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_41.dart b/simplistic_calculator/typer/main_41.dart index 201666c75..99d26bfa5 100644 --- a/simplistic_calculator/typer/main_41.dart +++ b/simplistic_calculator/typer/main_41.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_42.dart b/simplistic_calculator/typer/main_42.dart index 7b6459d5e..25345c8e6 100644 --- a/simplistic_calculator/typer/main_42.dart +++ b/simplistic_calculator/typer/main_42.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_43.dart b/simplistic_calculator/typer/main_43.dart index 181afd466..9657008ad 100644 --- a/simplistic_calculator/typer/main_43.dart +++ b/simplistic_calculator/typer/main_43.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_44.dart b/simplistic_calculator/typer/main_44.dart index 35aa7d219..cb3864359 100644 --- a/simplistic_calculator/typer/main_44.dart +++ b/simplistic_calculator/typer/main_44.dart @@ -65,7 +65,7 @@ final calculatorStateProvider = (_) => CalculatorEngine()); class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_45.dart b/simplistic_calculator/typer/main_45.dart index e1f36eb91..2ba090a28 100644 --- a/simplistic_calculator/typer/main_45.dart +++ b/simplistic_calculator/typer/main_45.dart @@ -67,7 +67,7 @@ final calculatorStateProvider = class ButtonDefinition {} class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_46.dart b/simplistic_calculator/typer/main_46.dart index 8353ab131..738e694a2 100644 --- a/simplistic_calculator/typer/main_46.dart +++ b/simplistic_calculator/typer/main_46.dart @@ -71,7 +71,7 @@ class ButtonDefinition { } class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_47.dart b/simplistic_calculator/typer/main_47.dart index 6fea23d39..48c063782 100644 --- a/simplistic_calculator/typer/main_47.dart +++ b/simplistic_calculator/typer/main_47.dart @@ -77,7 +77,7 @@ class ButtonDefinition { } class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_48.dart b/simplistic_calculator/typer/main_48.dart index 4ace6b4b3..7a81ccd09 100644 --- a/simplistic_calculator/typer/main_48.dart +++ b/simplistic_calculator/typer/main_48.dart @@ -79,7 +79,7 @@ class ButtonDefinition { final buttonDefinitions = []; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_49.dart b/simplistic_calculator/typer/main_49.dart index 1e8466cf2..057e2efc8 100644 --- a/simplistic_calculator/typer/main_49.dart +++ b/simplistic_calculator/typer/main_49.dart @@ -85,7 +85,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_50.dart b/simplistic_calculator/typer/main_50.dart index fc9da9ebf..17a6d072e 100644 --- a/simplistic_calculator/typer/main_50.dart +++ b/simplistic_calculator/typer/main_50.dart @@ -90,7 +90,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_51.dart b/simplistic_calculator/typer/main_51.dart index 90e29b2a4..73ba9625d 100644 --- a/simplistic_calculator/typer/main_51.dart +++ b/simplistic_calculator/typer/main_51.dart @@ -95,7 +95,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_52.dart b/simplistic_calculator/typer/main_52.dart index 17c5da937..03b3b6bc0 100644 --- a/simplistic_calculator/typer/main_52.dart +++ b/simplistic_calculator/typer/main_52.dart @@ -100,7 +100,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_53.dart b/simplistic_calculator/typer/main_53.dart index 688e8dfba..a7e89aef2 100644 --- a/simplistic_calculator/typer/main_53.dart +++ b/simplistic_calculator/typer/main_53.dart @@ -105,7 +105,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_54.dart b/simplistic_calculator/typer/main_54.dart index be3659bf9..19986ba8a 100644 --- a/simplistic_calculator/typer/main_54.dart +++ b/simplistic_calculator/typer/main_54.dart @@ -110,7 +110,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_55.dart b/simplistic_calculator/typer/main_55.dart index 5998fe4c7..71615663a 100644 --- a/simplistic_calculator/typer/main_55.dart +++ b/simplistic_calculator/typer/main_55.dart @@ -115,7 +115,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_56.dart b/simplistic_calculator/typer/main_56.dart index 67eda0ce6..b53af6855 100644 --- a/simplistic_calculator/typer/main_56.dart +++ b/simplistic_calculator/typer/main_56.dart @@ -120,7 +120,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_57.dart b/simplistic_calculator/typer/main_57.dart index b2d163292..d8cf69196 100644 --- a/simplistic_calculator/typer/main_57.dart +++ b/simplistic_calculator/typer/main_57.dart @@ -125,7 +125,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_58.dart b/simplistic_calculator/typer/main_58.dart index 103a1507b..e9292f58d 100644 --- a/simplistic_calculator/typer/main_58.dart +++ b/simplistic_calculator/typer/main_58.dart @@ -130,7 +130,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_59.dart b/simplistic_calculator/typer/main_59.dart index 71fb2adcd..560936de4 100644 --- a/simplistic_calculator/typer/main_59.dart +++ b/simplistic_calculator/typer/main_59.dart @@ -135,7 +135,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_60.dart b/simplistic_calculator/typer/main_60.dart index 2627ca56e..b78278083 100644 --- a/simplistic_calculator/typer/main_60.dart +++ b/simplistic_calculator/typer/main_60.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_61.dart b/simplistic_calculator/typer/main_61.dart index 8cde348bf..8faa17d78 100644 --- a/simplistic_calculator/typer/main_61.dart +++ b/simplistic_calculator/typer/main_61.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_62.dart b/simplistic_calculator/typer/main_62.dart index 7114ef727..0331cec5b 100644 --- a/simplistic_calculator/typer/main_62.dart +++ b/simplistic_calculator/typer/main_62.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_63.dart b/simplistic_calculator/typer/main_63.dart index 05e4c32e2..b2329800f 100644 --- a/simplistic_calculator/typer/main_63.dart +++ b/simplistic_calculator/typer/main_63.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_64.dart b/simplistic_calculator/typer/main_64.dart index 0692d63fa..e7ac179b8 100644 --- a/simplistic_calculator/typer/main_64.dart +++ b/simplistic_calculator/typer/main_64.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_65.dart b/simplistic_calculator/typer/main_65.dart index 7489a966f..c016cfb6e 100644 --- a/simplistic_calculator/typer/main_65.dart +++ b/simplistic_calculator/typer/main_65.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_66.dart b/simplistic_calculator/typer/main_66.dart index d02f9d12e..7d5a850af 100644 --- a/simplistic_calculator/typer/main_66.dart +++ b/simplistic_calculator/typer/main_66.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_67.dart b/simplistic_calculator/typer/main_67.dart index 875b330cf..51816ea8a 100644 --- a/simplistic_calculator/typer/main_67.dart +++ b/simplistic_calculator/typer/main_67.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_68.dart b/simplistic_calculator/typer/main_68.dart index 0be4dc474..32081d148 100644 --- a/simplistic_calculator/typer/main_68.dart +++ b/simplistic_calculator/typer/main_68.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_69.dart b/simplistic_calculator/typer/main_69.dart index e6e66c850..a544355d0 100644 --- a/simplistic_calculator/typer/main_69.dart +++ b/simplistic_calculator/typer/main_69.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_70.dart b/simplistic_calculator/typer/main_70.dart index a350ac6aa..56417fe3a 100644 --- a/simplistic_calculator/typer/main_70.dart +++ b/simplistic_calculator/typer/main_70.dart @@ -140,7 +140,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_71.dart b/simplistic_calculator/typer/main_71.dart index 756b91ee8..82ee08275 100644 --- a/simplistic_calculator/typer/main_71.dart +++ b/simplistic_calculator/typer/main_71.dart @@ -141,7 +141,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_72.dart b/simplistic_calculator/typer/main_72.dart index df509b09d..efbefcd6a 100644 --- a/simplistic_calculator/typer/main_72.dart +++ b/simplistic_calculator/typer/main_72.dart @@ -142,7 +142,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_73.dart b/simplistic_calculator/typer/main_73.dart index 1dfa75e4f..6b4ff5218 100644 --- a/simplistic_calculator/typer/main_73.dart +++ b/simplistic_calculator/typer/main_73.dart @@ -143,7 +143,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_74.dart b/simplistic_calculator/typer/main_74.dart index a1f5a11d4..60ef01f00 100644 --- a/simplistic_calculator/typer/main_74.dart +++ b/simplistic_calculator/typer/main_74.dart @@ -143,7 +143,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_75.dart b/simplistic_calculator/typer/main_75.dart index 6ca647e76..24a8e744e 100644 --- a/simplistic_calculator/typer/main_75.dart +++ b/simplistic_calculator/typer/main_75.dart @@ -145,7 +145,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_76.dart b/simplistic_calculator/typer/main_76.dart index fe4e28092..c54c641cd 100644 --- a/simplistic_calculator/typer/main_76.dart +++ b/simplistic_calculator/typer/main_76.dart @@ -146,7 +146,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_77.dart b/simplistic_calculator/typer/main_77.dart index 3e39adb65..7fe7bcf43 100644 --- a/simplistic_calculator/typer/main_77.dart +++ b/simplistic_calculator/typer/main_77.dart @@ -147,7 +147,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_78.dart b/simplistic_calculator/typer/main_78.dart index e32d11334..12282200d 100644 --- a/simplistic_calculator/typer/main_78.dart +++ b/simplistic_calculator/typer/main_78.dart @@ -148,7 +148,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_79.dart b/simplistic_calculator/typer/main_79.dart index bcd5cb073..9c4c7a64f 100644 --- a/simplistic_calculator/typer/main_79.dart +++ b/simplistic_calculator/typer/main_79.dart @@ -149,7 +149,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_80.dart b/simplistic_calculator/typer/main_80.dart index f33be9ae2..2b8524e24 100644 --- a/simplistic_calculator/typer/main_80.dart +++ b/simplistic_calculator/typer/main_80.dart @@ -150,7 +150,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_81.dart b/simplistic_calculator/typer/main_81.dart index 890cb4389..d9f5ac0d3 100644 --- a/simplistic_calculator/typer/main_81.dart +++ b/simplistic_calculator/typer/main_81.dart @@ -158,7 +158,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_82.dart b/simplistic_calculator/typer/main_82.dart index 930d90c9b..b6bb21537 100644 --- a/simplistic_calculator/typer/main_82.dart +++ b/simplistic_calculator/typer/main_82.dart @@ -158,7 +158,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_83.dart b/simplistic_calculator/typer/main_83.dart index a30a6c6a9..8f16d34a7 100644 --- a/simplistic_calculator/typer/main_83.dart +++ b/simplistic_calculator/typer/main_83.dart @@ -163,7 +163,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_84.dart b/simplistic_calculator/typer/main_84.dart index 542d66d61..860489dbd 100644 --- a/simplistic_calculator/typer/main_84.dart +++ b/simplistic_calculator/typer/main_84.dart @@ -168,7 +168,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_85.dart b/simplistic_calculator/typer/main_85.dart index a31e411ae..16fa9bb1e 100644 --- a/simplistic_calculator/typer/main_85.dart +++ b/simplistic_calculator/typer/main_85.dart @@ -173,7 +173,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_86.dart b/simplistic_calculator/typer/main_86.dart index 344cd1550..c6ea1f4b1 100644 --- a/simplistic_calculator/typer/main_86.dart +++ b/simplistic_calculator/typer/main_86.dart @@ -178,7 +178,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_87.dart b/simplistic_calculator/typer/main_87.dart index 630f73986..ab7e9a08b 100644 --- a/simplistic_calculator/typer/main_87.dart +++ b/simplistic_calculator/typer/main_87.dart @@ -179,7 +179,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_88.dart b/simplistic_calculator/typer/main_88.dart index 13926876f..49828dfe2 100644 --- a/simplistic_calculator/typer/main_88.dart +++ b/simplistic_calculator/typer/main_88.dart @@ -181,7 +181,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_89.dart b/simplistic_calculator/typer/main_89.dart index c95dc5fa2..9beed7e72 100644 --- a/simplistic_calculator/typer/main_89.dart +++ b/simplistic_calculator/typer/main_89.dart @@ -189,7 +189,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_90.dart b/simplistic_calculator/typer/main_90.dart index c7d78be96..6863c6ce1 100644 --- a/simplistic_calculator/typer/main_90.dart +++ b/simplistic_calculator/typer/main_90.dart @@ -194,7 +194,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_91.dart b/simplistic_calculator/typer/main_91.dart index eec03ca8b..27e6e2a31 100644 --- a/simplistic_calculator/typer/main_91.dart +++ b/simplistic_calculator/typer/main_91.dart @@ -207,7 +207,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_92.dart b/simplistic_calculator/typer/main_92.dart index 5ee2af4a6..dbd6e6f49 100644 --- a/simplistic_calculator/typer/main_92.dart +++ b/simplistic_calculator/typer/main_92.dart @@ -216,7 +216,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_93.dart b/simplistic_calculator/typer/main_93.dart index d01107c0a..4790a7dbe 100644 --- a/simplistic_calculator/typer/main_93.dart +++ b/simplistic_calculator/typer/main_93.dart @@ -216,7 +216,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/simplistic_calculator/typer/main_94.dart b/simplistic_calculator/typer/main_94.dart index e6a173bdf..37998b854 100644 --- a/simplistic_calculator/typer/main_94.dart +++ b/simplistic_calculator/typer/main_94.dart @@ -216,7 +216,7 @@ final buttonDefinitions = [ ]; class CalculatorApp extends ConsumerWidget { - const CalculatorApp({Key? key}) : super(key: key); + const CalculatorApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { @@ -288,7 +288,7 @@ enum CalcButtonType { outlined, elevated } class CalcButton extends ConsumerWidget { const CalcButton({ - Key? key, + super.key, required this.op, required this.label, required this.type, diff --git a/simplistic_editor/lib/basic_text_field.dart b/simplistic_editor/lib/basic_text_field.dart index 1261d963e..12b32666e 100644 --- a/simplistic_editor/lib/basic_text_field.dart +++ b/simplistic_editor/lib/basic_text_field.dart @@ -7,11 +7,11 @@ import 'basic_text_input_client.dart'; /// A basic text field. Defines the appearance of a basic text input client. class BasicTextField extends StatefulWidget { const BasicTextField({ - Key? key, + super.key, required this.controller, required this.style, required this.focusNode, - }) : super(key: key); + }); final TextEditingController controller; final TextStyle style; diff --git a/simplistic_editor/lib/basic_text_input_client.dart b/simplistic_editor/lib/basic_text_input_client.dart index 7be351a9f..e22bb1f2c 100644 --- a/simplistic_editor/lib/basic_text_input_client.dart +++ b/simplistic_editor/lib/basic_text_input_client.dart @@ -19,14 +19,14 @@ typedef SelectionChangedCallback = void Function( /// and vice-versa. class BasicTextInputClient extends StatefulWidget { const BasicTextInputClient({ - Key? key, + super.key, required this.controller, required this.style, required this.focusNode, this.selectionControls, required this.onSelectionChanged, required this.showSelectionHandles, - }) : super(key: key); + }); final TextEditingController controller; final TextStyle style; @@ -779,7 +779,7 @@ class BasicTextInputClientState extends State class _Editable extends MultiChildRenderObjectWidget { _Editable({ - Key? key, + super.key, required this.inlineSpan, required this.value, required this.startHandleLayerLink, @@ -817,7 +817,7 @@ class _Editable extends MultiChildRenderObjectWidget { this.promptRectRange, this.promptRectColor, required this.clipBehavior, - }) : super(key: key, children: _extractChildren(inlineSpan)); + }) : super(children: _extractChildren(inlineSpan)); // Traverses the InlineSpan tree and depth-first collects the list of // child widgets that are created in WidgetSpans. diff --git a/simplistic_editor/lib/main.dart b/simplistic_editor/lib/main.dart index ad7dc5bcd..0d8756e75 100644 --- a/simplistic_editor/lib/main.dart +++ b/simplistic_editor/lib/main.dart @@ -11,7 +11,7 @@ void main() { } class MyApp extends StatelessWidget { - const MyApp({Key? key}) : super(key: key); + const MyApp({super.key}); @override Widget build(BuildContext context) { @@ -28,7 +28,7 @@ class MyApp extends StatelessWidget { } class MyHomePage extends StatefulWidget { - const MyHomePage({Key? key, required this.title}) : super(key: key); + const MyHomePage({super.key, required this.title}); final String title; @@ -385,13 +385,13 @@ class _MyHomePageState extends State { class TextEditingDeltaView extends StatelessWidget { const TextEditingDeltaView({ - Key? key, + super.key, required this.deltaType, required this.deltaText, required this.deltaRange, required this.newSelection, required this.newComposing, - }) : super(key: key); + }); final String deltaType; final String deltaText; diff --git a/simplistic_editor/lib/text_editing_delta_history_manager.dart b/simplistic_editor/lib/text_editing_delta_history_manager.dart index 4f2a1d5d1..24740ac57 100644 --- a/simplistic_editor/lib/text_editing_delta_history_manager.dart +++ b/simplistic_editor/lib/text_editing_delta_history_manager.dart @@ -8,13 +8,12 @@ typedef TextEditingDeltaHistoryUpdateCallback = void Function( class TextEditingDeltaHistoryManager extends InheritedWidget { const TextEditingDeltaHistoryManager({ - Key? key, - required Widget child, + super.key, + required super.child, required List history, required TextEditingDeltaHistoryUpdateCallback updateHistoryOnInput, }) : _textEditingDeltaHistory = history, - _updateTextEditingDeltaHistoryOnInput = updateHistoryOnInput, - super(key: key, child: child); + _updateTextEditingDeltaHistoryOnInput = updateHistoryOnInput; static TextEditingDeltaHistoryManager of(BuildContext context) { final TextEditingDeltaHistoryManager? result = context diff --git a/simplistic_editor/lib/toggle_button_state_manager.dart b/simplistic_editor/lib/toggle_button_state_manager.dart index a45273154..3e176bc05 100644 --- a/simplistic_editor/lib/toggle_button_state_manager.dart +++ b/simplistic_editor/lib/toggle_button_state_manager.dart @@ -12,8 +12,8 @@ typedef UpdateToggleButtonsStateOnButtonPressedCallback = void Function( class ToggleButtonsStateManager extends InheritedWidget { const ToggleButtonsStateManager({ - Key? key, - required Widget child, + super.key, + required super.child, required List isToggleButtonsSelected, required UpdateToggleButtonsStateOnButtonPressedCallback updateToggleButtonsStateOnButtonPressed, @@ -23,8 +23,7 @@ class ToggleButtonsStateManager extends InheritedWidget { _updateToggleButtonsStateOnButtonPressed = updateToggleButtonsStateOnButtonPressed, _updateToggleButtonStateOnSelectionChanged = - updateToggleButtonStateOnSelectionChanged, - super(key: key, child: child); + updateToggleButtonStateOnSelectionChanged; static ToggleButtonsStateManager of(BuildContext context) { final ToggleButtonsStateManager? result = diff --git a/simplistic_editor/pubspec.lock b/simplistic_editor/pubspec.lock index 3005e69e5..9eb292a5b 100644 --- a/simplistic_editor/pubspec.lock +++ b/simplistic_editor/pubspec.lock @@ -7,7 +7,7 @@ packages: name: async url: "https://pub.dartlang.org" source: hosted - version: "2.9.0" + version: "2.8.2" boolean_selector: dependency: transitive description: @@ -21,7 +21,7 @@ packages: name: characters url: "https://pub.dartlang.org" source: hosted - version: "1.2.1" + version: "1.2.0" charcode: dependency: transitive description: @@ -120,7 +120,7 @@ packages: name: source_span url: "https://pub.dartlang.org" source: hosted - version: "1.9.0" + version: "1.8.2" stack_trace: dependency: transitive description: diff --git a/testing_app/lib/main.dart b/testing_app/lib/main.dart index 904b24e0d..c00cef8f8 100644 --- a/testing_app/lib/main.dart +++ b/testing_app/lib/main.dart @@ -13,7 +13,7 @@ void main() { } class TestingApp extends StatelessWidget { - const TestingApp({Key? key}) : super(key: key); + const TestingApp({super.key}); @override Widget build(BuildContext context) { diff --git a/testing_app/lib/screens/favorites.dart b/testing_app/lib/screens/favorites.dart index 03d6716e0..a245a4b38 100644 --- a/testing_app/lib/screens/favorites.dart +++ b/testing_app/lib/screens/favorites.dart @@ -9,7 +9,7 @@ import 'package:testing_app/models/favorites.dart'; class FavoritesPage extends StatelessWidget { static const routeName = '/favorites_page'; - const FavoritesPage({Key? key}) : super(key: key); + const FavoritesPage({super.key}); @override Widget build(BuildContext context) { @@ -36,7 +36,7 @@ class FavoritesPage extends StatelessWidget { class FavoriteItemTile extends StatelessWidget { final int itemNo; - const FavoriteItemTile(this.itemNo, {Key? key}) : super(key: key); + const FavoriteItemTile(this.itemNo, {super.key}); @override Widget build(BuildContext context) { diff --git a/testing_app/lib/screens/home.dart b/testing_app/lib/screens/home.dart index 53c217a25..5ba14eed5 100644 --- a/testing_app/lib/screens/home.dart +++ b/testing_app/lib/screens/home.dart @@ -10,7 +10,7 @@ import 'package:testing_app/screens/favorites.dart'; class HomePage extends StatelessWidget { static const routeName = '/'; - const HomePage({Key? key}) : super(key: key); + const HomePage({super.key}); @override Widget build(BuildContext context) { @@ -42,7 +42,7 @@ class HomePage extends StatelessWidget { class ItemTile extends StatelessWidget { final int itemNo; - const ItemTile(this.itemNo, {Key? key}) : super(key: key); + const ItemTile(this.itemNo, {super.key}); @override Widget build(BuildContext context) { diff --git a/veggieseasons/lib/main.dart b/veggieseasons/lib/main.dart index 9c251a0d1..a54f282d5 100644 --- a/veggieseasons/lib/main.dart +++ b/veggieseasons/lib/main.dart @@ -49,7 +49,7 @@ void setupWindow() { } class VeggieApp extends StatefulWidget { - const VeggieApp({Key? key}) : super(key: key); + const VeggieApp({super.key}); @override State createState() => _VeggieAppState(); diff --git a/veggieseasons/lib/screens/details.dart b/veggieseasons/lib/screens/details.dart index 9dc372da4..8cc96f497 100644 --- a/veggieseasons/lib/screens/details.dart +++ b/veggieseasons/lib/screens/details.dart @@ -12,7 +12,7 @@ import 'package:veggieseasons/widgets/close_button.dart'; import 'package:veggieseasons/widgets/trivia.dart'; class ServingInfoChart extends StatelessWidget { - const ServingInfoChart(this.veggie, this.prefs, {Key? key}) : super(key: key); + const ServingInfoChart(this.veggie, this.prefs, {super.key}); final Veggie veggie; @@ -157,7 +157,7 @@ class ServingInfoChart extends StatelessWidget { class InfoView extends StatelessWidget { final int? id; - const InfoView(this.id, {Key? key}) : super(key: key); + const InfoView(this.id, {super.key}); @override Widget build(BuildContext context) { @@ -238,8 +238,7 @@ class DetailsScreen extends StatefulWidget { final int? id; final String? restorationId; - const DetailsScreen({this.id, this.restorationId, Key? key}) - : super(key: key); + const DetailsScreen({this.id, this.restorationId, super.key}); static String show(NavigatorState navigator, int veggieId) { return navigator.restorablePush(_routeBuilder, arguments: veggieId); diff --git a/veggieseasons/lib/screens/favorites.dart b/veggieseasons/lib/screens/favorites.dart index 0e6c03122..e84502f9e 100644 --- a/veggieseasons/lib/screens/favorites.dart +++ b/veggieseasons/lib/screens/favorites.dart @@ -9,7 +9,7 @@ import 'package:veggieseasons/data/veggie.dart'; import 'package:veggieseasons/widgets/veggie_headline.dart'; class FavoritesScreen extends StatelessWidget { - const FavoritesScreen({this.restorationId, Key? key}) : super(key: key); + const FavoritesScreen({this.restorationId, super.key}); final String? restorationId; diff --git a/veggieseasons/lib/screens/home.dart b/veggieseasons/lib/screens/home.dart index dacd49b4e..fd6a89f5b 100644 --- a/veggieseasons/lib/screens/home.dart +++ b/veggieseasons/lib/screens/home.dart @@ -9,7 +9,7 @@ import 'package:veggieseasons/screens/search.dart'; import 'package:veggieseasons/screens/settings.dart'; class HomeScreen extends StatelessWidget { - const HomeScreen({Key? key, this.restorationId}) : super(key: key); + const HomeScreen({super.key, this.restorationId}); final String? restorationId; diff --git a/veggieseasons/lib/screens/list.dart b/veggieseasons/lib/screens/list.dart index c89395299..6cb6da270 100644 --- a/veggieseasons/lib/screens/list.dart +++ b/veggieseasons/lib/screens/list.dart @@ -13,7 +13,7 @@ import 'package:veggieseasons/styles.dart'; import 'package:veggieseasons/widgets/veggie_card.dart'; class ListScreen extends StatelessWidget { - const ListScreen({this.restorationId, Key? key}) : super(key: key); + const ListScreen({this.restorationId, super.key}); final String? restorationId; diff --git a/veggieseasons/lib/screens/search.dart b/veggieseasons/lib/screens/search.dart index 79713e0ce..0caa8186f 100644 --- a/veggieseasons/lib/screens/search.dart +++ b/veggieseasons/lib/screens/search.dart @@ -10,7 +10,7 @@ import 'package:veggieseasons/data/veggie.dart'; import 'package:veggieseasons/widgets/veggie_headline.dart'; class SearchScreen extends StatefulWidget { - const SearchScreen({this.restorationId, Key? key}) : super(key: key); + const SearchScreen({this.restorationId, super.key}); final String? restorationId; diff --git a/veggieseasons/lib/screens/settings.dart b/veggieseasons/lib/screens/settings.dart index ce491efca..53d3ccb38 100644 --- a/veggieseasons/lib/screens/settings.dart +++ b/veggieseasons/lib/screens/settings.dart @@ -11,8 +11,7 @@ import 'package:veggieseasons/widgets/settings_group.dart'; import 'package:veggieseasons/widgets/settings_item.dart'; class VeggieCategorySettingsScreen extends StatelessWidget { - const VeggieCategorySettingsScreen({Key? key, this.restorationId}) - : super(key: key); + const VeggieCategorySettingsScreen({super.key, this.restorationId}); final String? restorationId; @@ -92,7 +91,7 @@ class VeggieCategorySettingsScreen extends StatelessWidget { } class CalorieSettingsScreen extends StatelessWidget { - const CalorieSettingsScreen({Key? key, this.restorationId}) : super(key: key); + const CalorieSettingsScreen({super.key, this.restorationId}); final String? restorationId; @@ -167,7 +166,7 @@ class CalorieSettingsScreen extends StatelessWidget { } class SettingsScreen extends StatefulWidget { - const SettingsScreen({this.restorationId, Key? key}) : super(key: key); + const SettingsScreen({this.restorationId, super.key}); final String? restorationId; diff --git a/veggieseasons/lib/widgets/close_button.dart b/veggieseasons/lib/widgets/close_button.dart index 4ef6e6646..e1370f8e5 100644 --- a/veggieseasons/lib/widgets/close_button.dart +++ b/veggieseasons/lib/widgets/close_button.dart @@ -11,8 +11,8 @@ import 'package:veggieseasons/styles.dart'; class FrostedBox extends StatelessWidget { const FrostedBox({ this.child, - Key? key, - }) : super(key: key); + super.key, + }); final Widget? child; @@ -36,9 +36,9 @@ class ColorChangingIcon extends ImplicitlyAnimatedWidget { this.icon, { this.color = CupertinoColors.black, this.size, - required Duration duration, - Key? key, - }) : super(key: key, duration: duration); + required super.duration, + super.key, + }); final Color color; @@ -77,7 +77,7 @@ class _ColorChangingIconState /// A simple "close this modal" button that invokes a callback when pressed. class CloseButton extends StatefulWidget { - const CloseButton(this.onPressed, {Key? key}) : super(key: key); + const CloseButton(this.onPressed, {super.key}); final VoidCallback onPressed; diff --git a/veggieseasons/lib/widgets/settings_group.dart b/veggieseasons/lib/widgets/settings_group.dart index 191f3135b..da5cd95a0 100644 --- a/veggieseasons/lib/widgets/settings_group.dart +++ b/veggieseasons/lib/widgets/settings_group.dart @@ -14,7 +14,7 @@ import 'settings_item.dart'; // See https://github.com/flutter/flutter/projects/29 for more info. class SettingsGroupHeader extends StatelessWidget { - const SettingsGroupHeader(this.title, {Key? key}) : super(key: key); + const SettingsGroupHeader(this.title, {super.key}); final String title; @@ -35,7 +35,7 @@ class SettingsGroupHeader extends StatelessWidget { } class SettingsGroupFooter extends StatelessWidget { - const SettingsGroupFooter(this.title, {Key? key}) : super(key: key); + const SettingsGroupFooter(this.title, {super.key}); final String title; @@ -58,9 +58,8 @@ class SettingsGroup extends StatelessWidget { required this.items, this.header, this.footer, - Key? key, - }) : assert(items.isNotEmpty), - super(key: key); + super.key, + }) : assert(items.isNotEmpty); final List items; final Widget? header; diff --git a/veggieseasons/lib/widgets/settings_item.dart b/veggieseasons/lib/widgets/settings_item.dart index 8c08a701c..b503e0dee 100644 --- a/veggieseasons/lib/widgets/settings_item.dart +++ b/veggieseasons/lib/widgets/settings_item.dart @@ -16,7 +16,7 @@ import 'package:veggieseasons/styles.dart'; typedef SettingsItemCallback = FutureOr Function(); class SettingsNavigationIndicator extends StatelessWidget { - const SettingsNavigationIndicator({Key? key}) : super(key: key); + const SettingsNavigationIndicator({super.key}); @override Widget build(BuildContext context) { @@ -33,8 +33,8 @@ class SettingsIcon extends StatelessWidget { required this.icon, this.foregroundColor = CupertinoColors.white, this.backgroundColor = CupertinoColors.black, - Key? key, - }) : super(key: key); + super.key, + }); final Color backgroundColor; final Color foregroundColor; @@ -65,8 +65,8 @@ class SettingsItem extends StatefulWidget { this.content, this.subtitle, this.onPress, - Key? key, - }) : super(key: key); + super.key, + }); final String label; final Widget? icon; diff --git a/veggieseasons/lib/widgets/trivia.dart b/veggieseasons/lib/widgets/trivia.dart index 1873de90a..74583c310 100644 --- a/veggieseasons/lib/widgets/trivia.dart +++ b/veggieseasons/lib/widgets/trivia.dart @@ -10,7 +10,7 @@ class TriviaView extends StatefulWidget { final int? id; final String? restorationId; - const TriviaView({this.id, this.restorationId, Key? key}) : super(key: key); + const TriviaView({this.id, this.restorationId, super.key}); @override State createState() => _TriviaViewState(); diff --git a/veggieseasons/lib/widgets/veggie_card.dart b/veggieseasons/lib/widgets/veggie_card.dart index 73cb451f7..f7b2eb952 100644 --- a/veggieseasons/lib/widgets/veggie_card.dart +++ b/veggieseasons/lib/widgets/veggie_card.dart @@ -14,8 +14,8 @@ class FrostyBackground extends StatelessWidget { this.color, this.intensity = 25, this.child, - Key? key, - }) : super(key: key); + super.key, + }); final Color? color; final double intensity; @@ -48,8 +48,8 @@ class PressableCard extends StatefulWidget { this.shadowColor = CupertinoColors.black, this.duration = const Duration(milliseconds: 100), this.onPressed, - Key? key, - }) : super(key: key); + super.key, + }); final VoidCallback? onPressed; @@ -101,8 +101,7 @@ class _PressableCardState extends State { class VeggieCard extends StatelessWidget { const VeggieCard(this.veggie, this.isInSeason, this.isPreferredCategory, - {Key? key}) - : super(key: key); + {super.key}); /// Veggie to be displayed by the card. final Veggie veggie; diff --git a/veggieseasons/lib/widgets/veggie_headline.dart b/veggieseasons/lib/widgets/veggie_headline.dart index 0ff7a909a..d9e05ec50 100644 --- a/veggieseasons/lib/widgets/veggie_headline.dart +++ b/veggieseasons/lib/widgets/veggie_headline.dart @@ -13,8 +13,8 @@ class ZoomClipAssetImage extends StatelessWidget { this.height, this.width, required this.imageAsset, - Key? key, - }) : super(key: key); + super.key, + }); final double zoom; final double? height; @@ -45,7 +45,7 @@ class ZoomClipAssetImage extends StatelessWidget { class VeggieHeadline extends StatelessWidget { final Veggie veggie; - const VeggieHeadline(this.veggie, {Key? key}) : super(key: key); + const VeggieHeadline(this.veggie, {super.key}); List _buildSeasonDots(List seasons) { var widgets = []; diff --git a/web/_tool/common.dart b/web/_tool/common.dart index 3065a221a..90b3fa430 100644 --- a/web/_tool/common.dart +++ b/web/_tool/common.dart @@ -17,7 +17,7 @@ Future run( var proc = await Process.start( commandName, args, - workingDirectory: Directory.current.path + '/' + workingDir, + workingDirectory: '${Directory.current.path}/$workingDir', mode: ProcessStartMode.inheritStdio, ); diff --git a/web/_tool/pubspec.lock b/web/_tool/pubspec.lock index 9e7861fef..19f15062b 100644 --- a/web/_tool/pubspec.lock +++ b/web/_tool/pubspec.lock @@ -21,7 +21,7 @@ packages: name: lints url: "https://pub.dartlang.org" source: hosted - version: "1.0.1" + version: "2.0.0" markdown: dependency: "direct main" description: @@ -44,4 +44,4 @@ packages: source: hosted version: "1.8.1" sdks: - dart: ">=2.12.0 <3.0.0" + dart: ">=2.17.0-206.0.dev <3.0.0" diff --git a/web/_tool/pubspec.yaml b/web/_tool/pubspec.yaml index c41a8d8a6..4e96e0a88 100644 --- a/web/_tool/pubspec.yaml +++ b/web/_tool/pubspec.yaml @@ -9,4 +9,4 @@ dependencies: path: ^1.8.0 dev_dependencies: - lints: ^1.0.0 + lints: ^2.0.0 diff --git a/web/samples_index/lib/src/data.dart b/web/samples_index/lib/src/data.dart index 4deb247fc..3332b5e05 100644 --- a/web/samples_index/lib/src/data.dart +++ b/web/samples_index/lib/src/data.dart @@ -108,7 +108,7 @@ class Sample { var screenshotUrl = screenshots.first.url; var prefix = path.dirname(screenshotUrl); var filename = path.basenameWithoutExtension(screenshotUrl); - return path.join(prefix, filename + '_thumb.png'); + return path.join(prefix, '${filename}_thumb.png'); } String get searchAttributes { @@ -155,7 +155,7 @@ class Sample { if (description.length < 64) { return description; } - return description.substring(0, 64) + '...'; + return '${description.substring(0, 64)}...'; } } diff --git a/web/samples_index/lib/src/search.dart b/web/samples_index/lib/src/search.dart index 24ebb55ac..eb9b06c55 100644 --- a/web/samples_index/lib/src/search.dart +++ b/web/samples_index/lib/src/search.dart @@ -69,12 +69,12 @@ String searchQueryFromParams(Map params) { if (params.containsKey('type')) { if (buf.isNotEmpty) buf.write(' '); var value = params['type']; - if (value != null) buf.write('type:' + value); + if (value != null) buf.write('type:$value'); } if (params.containsKey('platform')) { if (buf.isNotEmpty) buf.write(' '); var value = params['platform']; - if (value != null) buf.write('platform:' + value); + if (value != null) buf.write('platform:$value'); } return buf.toString(); diff --git a/web/samples_index/lib/src/util.dart b/web/samples_index/lib/src/util.dart index aaf0bfc20..9a9c5e5ee 100644 --- a/web/samples_index/lib/src/util.dart +++ b/web/samples_index/lib/src/util.dart @@ -5,7 +5,7 @@ import 'dart:convert'; String indent(String content, int spaces) => - LineSplitter.split(content).join('\n' + ' ' * spaces); + LineSplitter.split(content).join('\n${' ' * spaces}'); String kebabCase(String input) => _fixCase(input, '-'); diff --git a/web/samples_index/pubspec.yaml b/web/samples_index/pubspec.yaml index 5ce93c658..5cc7c3bc2 100644 --- a/web/samples_index/pubspec.yaml +++ b/web/samples_index/pubspec.yaml @@ -15,7 +15,7 @@ dependencies: html: ^0.15.0 dev_dependencies: grinder: ^0.9.0 - flutter_lints: ^1.0.0 + flutter_lints: ^2.0.1 test: ^1.17.10 json_serializable: ^6.1.5 build: ^2.0.3 diff --git a/web/samples_index/tool/grind.dart b/web/samples_index/tool/grind.dart index 9a65cef08..96b8f7992 100644 --- a/web/samples_index/tool/grind.dart +++ b/web/samples_index/tool/grind.dart @@ -105,7 +105,7 @@ Future _createThumbnails(Directory directory) async { } var pathPrefix = path.dirname(entity.path); - var thumbnailFile = File(path.join(pathPrefix, filename + '_thumb.png')); + var thumbnailFile = File(path.join(pathPrefix, '${filename}_thumb.png')); var img = image.decodeImage(await entity.readAsBytes()); var resized = image.copyResize(img!, width: 640);