Final chapter: migrate api doc samples to super-parameters (#104007)
This commit is contained in:
parent
7fdf747723
commit
2cbad4b3ae
@ -6,7 +6,3 @@ linter:
|
||||
rules:
|
||||
# Samples want to print things pretty often.
|
||||
avoid_print: false
|
||||
# TODO(goderbauer): enable when super params are more established and
|
||||
# seeing them in the API samples is no longer surprising,
|
||||
# https://github.com/flutter/flutter/issues/101068
|
||||
use_super_parameters: false
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -43,12 +43,12 @@ final CatmullRomSpline path = CatmullRomSpline(
|
||||
|
||||
class FollowCurve2D extends StatefulWidget {
|
||||
const FollowCurve2D({
|
||||
Key? key,
|
||||
super.key,
|
||||
required this.path,
|
||||
this.curve = Curves.easeInOut,
|
||||
required this.child,
|
||||
this.duration = const Duration(seconds: 1),
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final Curve2D path;
|
||||
final Curve curve;
|
||||
@ -97,7 +97,7 @@ class _FollowCurve2DState extends State<FollowCurve2D>
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const CupertinoIndicatorApp());
|
||||
|
||||
class CupertinoIndicatorApp extends StatelessWidget {
|
||||
const CupertinoIndicatorApp({Key? key}) : super(key: key);
|
||||
const CupertinoIndicatorApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class CupertinoIndicatorApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class CupertinoIndicatorExample extends StatelessWidget {
|
||||
const CupertinoIndicatorExample({Key? key}) : super(key: key);
|
||||
const CupertinoIndicatorExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const CupertinoTabBarApp());
|
||||
|
||||
class CupertinoTabBarApp extends StatelessWidget {
|
||||
const CupertinoTabBarApp({Key? key}) : super(key: key);
|
||||
const CupertinoTabBarApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class CupertinoTabBarApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class CupertinoTabBarExample extends StatelessWidget {
|
||||
const CupertinoTabBarExample({Key? key}) : super(key: key);
|
||||
const CupertinoTabBarExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const CupertinoButtonApp());
|
||||
|
||||
class CupertinoButtonApp extends StatelessWidget {
|
||||
const CupertinoButtonApp({Key? key}) : super(key: key);
|
||||
const CupertinoButtonApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class CupertinoButtonApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class CupertinoButtonExample extends StatelessWidget {
|
||||
const CupertinoButtonExample({Key? key}) : super(key: key);
|
||||
const CupertinoButtonExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -10,7 +10,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const ContextMenuApp());
|
||||
|
||||
class ContextMenuApp extends StatelessWidget {
|
||||
const ContextMenuApp({Key? key}) : super(key: key);
|
||||
const ContextMenuApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -22,7 +22,7 @@ class ContextMenuApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class ContextMenuExample extends StatelessWidget {
|
||||
const ContextMenuExample({Key? key}) : super(key: key);
|
||||
const ContextMenuExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const DatePickerApp());
|
||||
|
||||
class DatePickerApp extends StatelessWidget {
|
||||
const DatePickerApp({Key? key}) : super(key: key);
|
||||
const DatePickerApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class DatePickerApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class DatePickerExample extends StatefulWidget {
|
||||
const DatePickerExample({Key? key}) : super(key: key);
|
||||
const DatePickerExample({super.key});
|
||||
|
||||
@override
|
||||
State<DatePickerExample> createState() => _DatePickerExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const TimerPickerApp());
|
||||
|
||||
class TimerPickerApp extends StatelessWidget {
|
||||
const TimerPickerApp({Key? key}) : super(key: key);
|
||||
const TimerPickerApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class TimerPickerApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class TimerPickerExample extends StatefulWidget {
|
||||
const TimerPickerExample({Key? key}) : super(key: key);
|
||||
const TimerPickerExample({super.key});
|
||||
|
||||
@override
|
||||
State<TimerPickerExample> createState() => _TimerPickerExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const ActionSheetApp());
|
||||
|
||||
class ActionSheetApp extends StatelessWidget {
|
||||
const ActionSheetApp({Key? key}) : super(key: key);
|
||||
const ActionSheetApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class ActionSheetApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class ActionSheetExample extends StatelessWidget {
|
||||
const ActionSheetExample({Key? key}) : super(key: key);
|
||||
const ActionSheetExample({super.key});
|
||||
|
||||
// This shows a CupertinoModalPopup which hosts a CupertinoActionSheet.
|
||||
void _showActionSheet(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const AlertDialogApp());
|
||||
|
||||
class AlertDialogApp extends StatelessWidget {
|
||||
const AlertDialogApp({Key? key}) : super(key: key);
|
||||
const AlertDialogApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class AlertDialogApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class AlertDialogExample extends StatelessWidget {
|
||||
const AlertDialogExample({Key? key}) : super(key: key);
|
||||
const AlertDialogExample({super.key});
|
||||
|
||||
// This shows a CupertinoModalPopup which hosts a CupertinoAlertDialog.
|
||||
void _showAlertDialog(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const CupertinoFormRowApp());
|
||||
|
||||
class CupertinoFormRowApp extends StatelessWidget {
|
||||
const CupertinoFormRowApp({Key? key}) : super(key: key);
|
||||
const CupertinoFormRowApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class CupertinoFormRowApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class CupertinoFormRowExample extends StatefulWidget {
|
||||
const CupertinoFormRowExample({Key? key}) : super(key: key);
|
||||
const CupertinoFormRowExample({super.key});
|
||||
|
||||
@override
|
||||
State<CupertinoFormRowExample> createState() => _CupertinoFormRowExampleState();
|
||||
@ -114,11 +114,11 @@ class _CupertinoFormRowExampleState extends State<CupertinoFormRowExample> {
|
||||
|
||||
class PrefixWidget extends StatelessWidget {
|
||||
const PrefixWidget({
|
||||
Key? key,
|
||||
super.key,
|
||||
required this.icon,
|
||||
required this.title,
|
||||
required this.color,
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final IconData icon;
|
||||
final String title;
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const NavBarApp());
|
||||
|
||||
class NavBarApp extends StatelessWidget {
|
||||
const NavBarApp({Key? key}) : super(key: key);
|
||||
const NavBarApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class NavBarApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class NavBarExample extends StatefulWidget {
|
||||
const NavBarExample({Key? key}) : super(key: key);
|
||||
const NavBarExample({super.key});
|
||||
|
||||
@override
|
||||
State<NavBarExample> createState() => _NavBarExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const SliverNavBarApp());
|
||||
|
||||
class SliverNavBarApp extends StatelessWidget {
|
||||
const SliverNavBarApp({Key? key}) : super(key: key);
|
||||
const SliverNavBarApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class SliverNavBarApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class SliverNavBarExample extends StatelessWidget {
|
||||
const SliverNavBarExample({Key? key}) : super(key: key);
|
||||
const SliverNavBarExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -63,7 +63,7 @@ class SliverNavBarExample extends StatelessWidget {
|
||||
}
|
||||
|
||||
class NextPage extends StatelessWidget {
|
||||
const NextPage({ Key? key }) : super(key: key);
|
||||
const NextPage({ super.key });
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const PageScaffoldApp());
|
||||
|
||||
class PageScaffoldApp extends StatelessWidget {
|
||||
const PageScaffoldApp({Key? key}) : super(key: key);
|
||||
const PageScaffoldApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class PageScaffoldApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class PageScaffoldExample extends StatefulWidget {
|
||||
const PageScaffoldExample({Key? key}) : super(key: key);
|
||||
const PageScaffoldExample({super.key});
|
||||
|
||||
@override
|
||||
State<PageScaffoldExample> createState() => _PageScaffoldExampleState();
|
||||
|
@ -19,7 +19,7 @@ const List<String> _fruitNames = <String>[
|
||||
void main() => runApp(const CupertinoPickerApp());
|
||||
|
||||
class CupertinoPickerApp extends StatelessWidget {
|
||||
const CupertinoPickerApp({Key? key}) : super(key: key);
|
||||
const CupertinoPickerApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -30,7 +30,7 @@ class CupertinoPickerApp extends StatelessWidget {
|
||||
}
|
||||
}
|
||||
class CupertinoPickerExample extends StatefulWidget {
|
||||
const CupertinoPickerExample({Key? key}) : super(key: key);
|
||||
const CupertinoPickerExample({super.key});
|
||||
|
||||
@override
|
||||
State<CupertinoPickerExample> createState() => _CupertinoPickerExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const RefreshControlApp());
|
||||
|
||||
class RefreshControlApp extends StatelessWidget {
|
||||
const RefreshControlApp({Key? key}) : super(key: key);
|
||||
const RefreshControlApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class RefreshControlApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class RefreshControlExample extends StatefulWidget {
|
||||
const RefreshControlExample({Key? key}) : super(key: key);
|
||||
const RefreshControlExample({super.key});
|
||||
|
||||
@override
|
||||
State<RefreshControlExample> createState() => _RefreshControlExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const CupertinoDialogApp());
|
||||
|
||||
class CupertinoDialogApp extends StatelessWidget {
|
||||
const CupertinoDialogApp({Key? key}) : super(key: key);
|
||||
const CupertinoDialogApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -22,7 +22,7 @@ class CupertinoDialogApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class CupertinoDialogExample extends StatelessWidget {
|
||||
const CupertinoDialogExample({Key? key}) : super(key: key);
|
||||
const CupertinoDialogExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const ModalPopupApp());
|
||||
|
||||
class ModalPopupApp extends StatelessWidget {
|
||||
const ModalPopupApp({Key? key}) : super(key: key);
|
||||
const ModalPopupApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -22,7 +22,7 @@ class ModalPopupApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class ModalPopupExample extends StatelessWidget {
|
||||
const ModalPopupExample({Key? key}) : super(key: key);
|
||||
const ModalPopupExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const ScrollbarApp());
|
||||
|
||||
class ScrollbarApp extends StatelessWidget {
|
||||
const ScrollbarApp({Key? key}) : super(key: key);
|
||||
const ScrollbarApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class ScrollbarApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class ScrollbarExample extends StatelessWidget {
|
||||
const ScrollbarExample({Key? key}) : super(key: key);
|
||||
const ScrollbarExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const ScrollbarApp());
|
||||
|
||||
class ScrollbarApp extends StatelessWidget {
|
||||
const ScrollbarApp({Key? key}) : super(key: key);
|
||||
const ScrollbarApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class ScrollbarApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class ScrollbarExample extends StatefulWidget {
|
||||
const ScrollbarExample({Key? key}) : super(key: key);
|
||||
const ScrollbarExample({super.key});
|
||||
|
||||
@override
|
||||
State<ScrollbarExample> createState() => _ScrollbarExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const SearchTextFieldApp());
|
||||
|
||||
class SearchTextFieldApp extends StatelessWidget {
|
||||
const SearchTextFieldApp({Key? key}) : super(key: key);
|
||||
const SearchTextFieldApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class SearchTextFieldApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class SearchTextFieldExample extends StatefulWidget {
|
||||
const SearchTextFieldExample({Key? key}) : super(key: key);
|
||||
const SearchTextFieldExample({super.key});
|
||||
|
||||
@override
|
||||
State<SearchTextFieldExample> createState() => _SearchTextFieldExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const SearchTextFieldApp());
|
||||
|
||||
class SearchTextFieldApp extends StatelessWidget {
|
||||
const SearchTextFieldApp({Key? key}) : super(key: key);
|
||||
const SearchTextFieldApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class SearchTextFieldApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class SearchTextFieldExample extends StatefulWidget {
|
||||
const SearchTextFieldExample({Key? key}) : super(key: key);
|
||||
const SearchTextFieldExample({super.key});
|
||||
|
||||
@override
|
||||
State<SearchTextFieldExample> createState() => _SearchTextFieldExampleState();
|
||||
@ -60,9 +60,9 @@ class _SearchTextFieldExampleState extends State<SearchTextFieldExample> {
|
||||
|
||||
class SearchTextField extends StatelessWidget {
|
||||
const SearchTextField({
|
||||
Key? key,
|
||||
super.key,
|
||||
required this.fieldValue,
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final ValueChanged<String> fieldValue;
|
||||
|
||||
|
@ -17,7 +17,7 @@ Map<Sky, Color> skyColors = <Sky, Color> {
|
||||
void main() => runApp(const SegmentedControlApp());
|
||||
|
||||
class SegmentedControlApp extends StatelessWidget {
|
||||
const SegmentedControlApp({Key? key}) : super(key: key);
|
||||
const SegmentedControlApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -29,7 +29,7 @@ class SegmentedControlApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class SegmentedControlExample extends StatefulWidget {
|
||||
const SegmentedControlExample({Key? key}) : super(key: key);
|
||||
const SegmentedControlExample({super.key});
|
||||
|
||||
@override
|
||||
State<SegmentedControlExample> createState() => _SegmentedControlExampleState();
|
||||
|
@ -17,7 +17,7 @@ Map<Sky, Color> skyColors = <Sky, Color> {
|
||||
void main() => runApp(const SegmentedControlApp());
|
||||
|
||||
class SegmentedControlApp extends StatelessWidget {
|
||||
const SegmentedControlApp({Key? key}) : super(key: key);
|
||||
const SegmentedControlApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -29,7 +29,7 @@ class SegmentedControlApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class SegmentedControlExample extends StatefulWidget {
|
||||
const SegmentedControlExample({Key? key}) : super(key: key);
|
||||
const SegmentedControlExample({super.key});
|
||||
|
||||
@override
|
||||
State<SegmentedControlExample> createState() => _SegmentedControlExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const CupertinoSliderApp());
|
||||
|
||||
class CupertinoSliderApp extends StatelessWidget {
|
||||
const CupertinoSliderApp({Key? key}) : super(key: key);
|
||||
const CupertinoSliderApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class CupertinoSliderApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class CupertinoSliderExample extends StatefulWidget {
|
||||
const CupertinoSliderExample({Key? key}) : super(key: key);
|
||||
const CupertinoSliderExample({super.key});
|
||||
|
||||
@override
|
||||
State<CupertinoSliderExample> createState() => _CupertinoSliderExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const CupertinoSwitchApp());
|
||||
|
||||
class CupertinoSwitchApp extends StatelessWidget {
|
||||
const CupertinoSwitchApp({Key? key}) : super(key: key);
|
||||
const CupertinoSwitchApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class CupertinoSwitchApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class CupertinoSwitchExample extends StatefulWidget {
|
||||
const CupertinoSwitchExample({Key? key}) : super(key: key);
|
||||
const CupertinoSwitchExample({super.key});
|
||||
|
||||
@override
|
||||
State<CupertinoSwitchExample> createState() => _CupertinoSwitchExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const TabControllerApp());
|
||||
|
||||
class TabControllerApp extends StatelessWidget {
|
||||
const TabControllerApp({Key? key}) : super(key: key);
|
||||
const TabControllerApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class TabControllerApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class TabControllerExample extends StatefulWidget {
|
||||
const TabControllerExample({Key? key}) : super(key: key);
|
||||
const TabControllerExample({super.key});
|
||||
|
||||
@override
|
||||
State<TabControllerExample> createState() => _TabControllerExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const TabScaffoldApp());
|
||||
|
||||
class TabScaffoldApp extends StatelessWidget {
|
||||
const TabScaffoldApp({Key? key}) : super(key: key);
|
||||
const TabScaffoldApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class TabScaffoldApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class TabScaffoldExample extends StatefulWidget {
|
||||
const TabScaffoldExample({Key? key}) : super(key: key);
|
||||
const TabScaffoldExample({super.key});
|
||||
|
||||
@override
|
||||
State<TabScaffoldExample> createState() => _TabScaffoldExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const CupertinoTextFieldApp());
|
||||
|
||||
class CupertinoTextFieldApp extends StatelessWidget {
|
||||
const CupertinoTextFieldApp({Key? key}) : super(key: key);
|
||||
const CupertinoTextFieldApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class CupertinoTextFieldApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class CupertinoTextFieldExample extends StatefulWidget {
|
||||
const CupertinoTextFieldExample({Key? key}) : super(key: key);
|
||||
const CupertinoTextFieldExample({super.key});
|
||||
|
||||
@override
|
||||
State<CupertinoTextFieldExample> createState() => _CupertinoTextFieldExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/cupertino.dart';
|
||||
void main() => runApp(const FormSectionApp());
|
||||
|
||||
class FormSectionApp extends StatelessWidget {
|
||||
const FormSectionApp({Key? key}) : super(key: key);
|
||||
const FormSectionApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class FormSectionApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class FromSectionExample extends StatelessWidget {
|
||||
const FromSectionExample({Key? key}) : super(key: key);
|
||||
const FromSectionExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -7,7 +7,7 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class CounterBody extends StatelessWidget {
|
||||
const CounterBody({Key? key, required this.counterValueNotifier}) : super(key: key);
|
||||
const CounterBody({super.key, required this.counterValueNotifier});
|
||||
|
||||
final ValueNotifier<int> counterValueNotifier;
|
||||
|
||||
@ -36,7 +36,7 @@ class CounterBody extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyApp extends StatefulWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
State<MyApp> createState() => _MyAppState();
|
||||
|
@ -11,7 +11,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,11 +26,11 @@ class MyApp extends StatelessWidget {
|
||||
|
||||
class ColorChanger extends StatefulWidget {
|
||||
const ColorChanger({
|
||||
Key? key,
|
||||
super.key,
|
||||
required this.initialColor,
|
||||
required this.useResolver,
|
||||
this.child,
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final HSVColor initialColor;
|
||||
final bool useResolver;
|
||||
@ -86,7 +86,7 @@ class _ColorChangerState extends State<ColorChanger> {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -23,7 +23,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -23,7 +23,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -23,7 +23,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -23,7 +23,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const AutocompleteExampleApp());
|
||||
|
||||
class AutocompleteExampleApp extends StatelessWidget {
|
||||
const AutocompleteExampleApp({Key? key}) : super(key: key);
|
||||
const AutocompleteExampleApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -27,7 +27,7 @@ class AutocompleteExampleApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class AutocompleteBasicExample extends StatelessWidget {
|
||||
const AutocompleteBasicExample({Key? key}) : super(key: key);
|
||||
const AutocompleteBasicExample({super.key});
|
||||
|
||||
static const List<String> _kOptions = <String>[
|
||||
'aardvark',
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const AutocompleteExampleApp());
|
||||
|
||||
class AutocompleteExampleApp extends StatelessWidget {
|
||||
const AutocompleteExampleApp({Key? key}) : super(key: key);
|
||||
const AutocompleteExampleApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -54,7 +54,7 @@ class User {
|
||||
}
|
||||
|
||||
class AutocompleteBasicUserExample extends StatelessWidget {
|
||||
const AutocompleteBasicUserExample({Key? key}) : super(key: key);
|
||||
const AutocompleteBasicUserExample({super.key});
|
||||
|
||||
static const List<User> _userOptions = <User>[
|
||||
User(name: 'Alice', email: 'alice@example.com'),
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -23,7 +23,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -23,7 +23,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -11,7 +11,7 @@ void main() {
|
||||
}
|
||||
|
||||
class BottomAppBarDemo extends StatefulWidget {
|
||||
const BottomAppBarDemo({Key? key}) : super(key: key);
|
||||
const BottomAppBarDemo({super.key});
|
||||
|
||||
@override
|
||||
State createState() => _BottomAppBarDemoState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -23,7 +23,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -23,7 +23,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -11,7 +11,7 @@ void main() {
|
||||
}
|
||||
|
||||
class ButtonApp extends StatelessWidget {
|
||||
const ButtonApp({Key? key}) : super(key: key);
|
||||
const ButtonApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -26,7 +26,7 @@ class ButtonApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class ButtonTypesExample extends StatelessWidget {
|
||||
const ButtonTypesExample({Key? key}) : super(key: key);
|
||||
const ButtonTypesExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -45,7 +45,7 @@ class ButtonTypesExample extends StatelessWidget {
|
||||
}
|
||||
|
||||
class ButtonTypesGroup extends StatelessWidget {
|
||||
const ButtonTypesGroup({ Key? key, required this.enabled }) : super(key: key);
|
||||
const ButtonTypesGroup({ super.key, required this.enabled });
|
||||
|
||||
final bool enabled;
|
||||
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() { runApp(const CardExamplesApp()); }
|
||||
|
||||
class CardExamplesApp extends StatelessWidget {
|
||||
const CardExamplesApp({Key? key}) : super(key: key);
|
||||
const CardExamplesApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -38,7 +38,7 @@ class CardExamplesApp extends StatelessWidget {
|
||||
///
|
||||
/// https://m3.material.io/components/cards/specs#a012d40d-7a5c-4b07-8740-491dec79d58b
|
||||
class ElevatedCardExample extends StatelessWidget {
|
||||
const ElevatedCardExample({ Key? key }) : super(key: key);
|
||||
const ElevatedCardExample({ super.key });
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -61,7 +61,7 @@ class ElevatedCardExample extends StatelessWidget {
|
||||
///
|
||||
/// https://m3.material.io/components/cards/specs#0f55bf62-edf2-4619-b00d-b9ed462f2c5a
|
||||
class FilledCardExample extends StatelessWidget {
|
||||
const FilledCardExample({ Key? key }) : super(key: key);
|
||||
const FilledCardExample({ super.key });
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -86,7 +86,7 @@ class FilledCardExample extends StatelessWidget {
|
||||
///
|
||||
/// https://m3.material.io/components/cards/specs#0f55bf62-edf2-4619-b00d-b9ed462f2c5a
|
||||
class OutlinedCardExample extends StatelessWidget {
|
||||
const OutlinedCardExample({ Key? key }) : super(key: key);
|
||||
const OutlinedCardExample({ super.key });
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -28,7 +28,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -10,7 +10,7 @@ import 'package:flutter/scheduler.dart' show timeDilation;
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -29,7 +29,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -11,7 +11,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -31,12 +31,12 @@ class MyApp extends StatelessWidget {
|
||||
|
||||
class LinkedLabelCheckbox extends StatelessWidget {
|
||||
const LinkedLabelCheckbox({
|
||||
Key? key,
|
||||
super.key,
|
||||
required this.label,
|
||||
required this.padding,
|
||||
required this.value,
|
||||
required this.onChanged,
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final String label;
|
||||
final EdgeInsets padding;
|
||||
@ -77,7 +77,7 @@ class LinkedLabelCheckbox extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -29,12 +29,12 @@ class MyApp extends StatelessWidget {
|
||||
|
||||
class LabeledCheckbox extends StatelessWidget {
|
||||
const LabeledCheckbox({
|
||||
Key? key,
|
||||
super.key,
|
||||
required this.label,
|
||||
required this.padding,
|
||||
required this.value,
|
||||
required this.onChanged,
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final String label;
|
||||
final EdgeInsets padding;
|
||||
@ -66,7 +66,7 @@ class LabeledCheckbox extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -34,7 +34,7 @@ class Actor {
|
||||
}
|
||||
|
||||
class CastList extends StatefulWidget {
|
||||
const CastList({Key? key}) : super(key: key);
|
||||
const CastList({super.key});
|
||||
|
||||
@override
|
||||
State createState() => CastListState();
|
||||
@ -76,7 +76,7 @@ class CastListState extends State<CastList> {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -24,7 +24,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key, this.restorationId}) : super(key: key);
|
||||
const MyStatefulWidget({super.key, this.restorationId});
|
||||
|
||||
final String? restorationId;
|
||||
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -24,7 +24,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key, this.restorationId}) : super(key: key);
|
||||
const MyStatefulWidget({super.key, this.restorationId});
|
||||
|
||||
final String? restorationId;
|
||||
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -25,7 +25,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class DialogExample extends StatelessWidget {
|
||||
const DialogExample({Key? key}) : super(key: key);
|
||||
const DialogExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class DialogExample extends StatelessWidget {
|
||||
const DialogExample({Key? key}) : super(key: key);
|
||||
const DialogExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -20,7 +20,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class DialogExample extends StatelessWidget {
|
||||
const DialogExample({Key? key}) : super(key: key);
|
||||
const DialogExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class DialogExample extends StatelessWidget {
|
||||
const DialogExample({Key? key}) : super(key: key);
|
||||
const DialogExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class DialogExample extends StatelessWidget {
|
||||
const DialogExample({Key? key}) : super(key: key);
|
||||
const DialogExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -11,7 +11,7 @@ const List<String> list = <String>['One', 'Two', 'Three', 'Four'];
|
||||
void main() => runApp(const DropdownButtonApp());
|
||||
|
||||
class DropdownButtonApp extends StatelessWidget {
|
||||
const DropdownButtonApp({Key? key}) : super(key: key);
|
||||
const DropdownButtonApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -27,7 +27,7 @@ class DropdownButtonApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class DropdownButtonExample extends StatefulWidget {
|
||||
const DropdownButtonExample({Key? key}) : super(key: key);
|
||||
const DropdownButtonExample({super.key});
|
||||
|
||||
@override
|
||||
State<DropdownButtonExample> createState() => _DropdownButtonExampleState();
|
||||
|
@ -17,7 +17,7 @@ Map<String, String> cities = <String, String>{
|
||||
void main() => runApp(const DropdownButtonApp());
|
||||
|
||||
class DropdownButtonApp extends StatelessWidget {
|
||||
const DropdownButtonApp({Key? key}) : super(key: key);
|
||||
const DropdownButtonApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -31,7 +31,7 @@ class DropdownButtonApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class DropdownButtonExample extends StatefulWidget {
|
||||
const DropdownButtonExample({Key? key}) : super(key: key);
|
||||
const DropdownButtonExample({super.key});
|
||||
|
||||
@override
|
||||
State<DropdownButtonExample> createState() => _DropdownButtonExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const DropdownButtonApp());
|
||||
|
||||
class DropdownButtonApp extends StatelessWidget {
|
||||
const DropdownButtonApp({Key? key}) : super(key: key);
|
||||
const DropdownButtonApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -23,7 +23,7 @@ class DropdownButtonApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class DropdownButtonExample extends StatefulWidget {
|
||||
const DropdownButtonExample({Key? key}) : super(key: key);
|
||||
const DropdownButtonExample({super.key});
|
||||
|
||||
@override
|
||||
State<DropdownButtonExample> createState() => _DropdownButtonExampleState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -48,7 +48,7 @@ List<Item> generateItems(int numberOfItems) {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -49,7 +49,7 @@ List<Item> generateItems(int numberOfItems) {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MaterialApp(home: MyApp()));
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -20,7 +20,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class FabExample extends StatelessWidget {
|
||||
const FabExample({Key? key}) : super(key: key);
|
||||
const FabExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -20,7 +20,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class FabExample extends StatelessWidget {
|
||||
const FabExample({Key? key}) : super(key: key);
|
||||
const FabExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class FabExample extends StatelessWidget {
|
||||
const FabExample({Key? key}) : super(key: key);
|
||||
const FabExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class FabExample extends StatelessWidget {
|
||||
const FabExample({Key? key}) : super(key: key);
|
||||
const FabExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -35,7 +35,7 @@ class AlmostEndFloatFabLocation extends StandardFabLocation
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -30,7 +30,7 @@ class MyApp extends StatelessWidget {
|
||||
double _volume = 0.0;
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
@override
|
||||
|
@ -21,7 +21,7 @@ void main() {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key, required this.image}) : super(key: key);
|
||||
const MyStatelessWidget({super.key, required this.image});
|
||||
|
||||
final ImageProvider image;
|
||||
|
||||
|
@ -21,7 +21,7 @@ void main() {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key, required this.image}) : super(key: key);
|
||||
const MyStatelessWidget({super.key, required this.image});
|
||||
|
||||
final ImageProvider image;
|
||||
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -28,7 +28,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -28,7 +28,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class InputDecoratorExample extends StatelessWidget {
|
||||
const InputDecoratorExample({Key? key}) : super(key: key);
|
||||
const InputDecoratorExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -28,7 +28,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class InputDecoratorExample extends StatelessWidget {
|
||||
const InputDecoratorExample({Key? key}) : super(key: key);
|
||||
const InputDecoratorExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class InputDecoratorExample extends StatelessWidget {
|
||||
const InputDecoratorExample({Key? key}) : super(key: key);
|
||||
const InputDecoratorExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@ -21,7 +21,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class InputDecoratorExample extends StatelessWidget {
|
||||
const InputDecoratorExample({Key? key}) : super(key: key);
|
||||
const InputDecoratorExample({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -27,12 +27,12 @@ class MyApp extends StatelessWidget {
|
||||
|
||||
class CustomListItem extends StatelessWidget {
|
||||
const CustomListItem({
|
||||
Key? key,
|
||||
super.key,
|
||||
required this.thumbnail,
|
||||
required this.title,
|
||||
required this.user,
|
||||
required this.viewCount,
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final Widget thumbnail;
|
||||
final String title;
|
||||
@ -70,11 +70,10 @@ class CustomListItem extends StatelessWidget {
|
||||
|
||||
class _VideoDescription extends StatelessWidget {
|
||||
const _VideoDescription({
|
||||
Key? key,
|
||||
required this.title,
|
||||
required this.user,
|
||||
required this.viewCount,
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final String title;
|
||||
final String user;
|
||||
@ -111,7 +110,7 @@ class _VideoDescription extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -27,13 +27,12 @@ class MyApp extends StatelessWidget {
|
||||
|
||||
class _ArticleDescription extends StatelessWidget {
|
||||
const _ArticleDescription({
|
||||
Key? key,
|
||||
required this.title,
|
||||
required this.subtitle,
|
||||
required this.author,
|
||||
required this.publishDate,
|
||||
required this.readDuration,
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final String title;
|
||||
final String subtitle;
|
||||
@ -100,14 +99,14 @@ class _ArticleDescription extends StatelessWidget {
|
||||
|
||||
class CustomListItemTwo extends StatelessWidget {
|
||||
const CustomListItemTwo({
|
||||
Key? key,
|
||||
super.key,
|
||||
required this.thumbnail,
|
||||
required this.title,
|
||||
required this.subtitle,
|
||||
required this.author,
|
||||
required this.publishDate,
|
||||
required this.readDuration,
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
final Widget thumbnail;
|
||||
final String title;
|
||||
@ -149,7 +148,7 @@ class CustomListItemTwo extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -26,7 +26,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -28,7 +28,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyStatefulWidget extends StatefulWidget {
|
||||
const MyStatefulWidget({Key? key}) : super(key: key);
|
||||
const MyStatefulWidget({super.key});
|
||||
|
||||
@override
|
||||
State<MyStatefulWidget> createState() => _MyStatefulWidgetState();
|
||||
|
@ -9,7 +9,7 @@ import 'package:flutter/material.dart';
|
||||
void main() => runApp(const MyApp());
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
static const String _title = 'Flutter Code Sample';
|
||||
|
||||
@ -41,7 +41,7 @@ class ListTileCursor extends MaterialStateMouseCursor {
|
||||
}
|
||||
|
||||
class MyStatelessWidget extends StatelessWidget {
|
||||
const MyStatelessWidget({Key? key}) : super(key: key);
|
||||
const MyStatelessWidget({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user