diff --git a/packages/flutter/lib/src/material/button_style.dart b/packages/flutter/lib/src/material/button_style.dart index b6c3e254902..da92a10fa1a 100644 --- a/packages/flutter/lib/src/material/button_style.dart +++ b/packages/flutter/lib/src/material/button_style.dart @@ -44,7 +44,7 @@ import 'theme_data.dart'; /// ), /// ), /// ) -///``` +/// ``` /// /// In this case the background color for all other button states would fallback /// to the ElevatedButton’s default values. To unconditionally set the button's @@ -56,7 +56,7 @@ import 'theme_data.dart'; /// backgroundColor: MaterialStateProperty.all(Colors.green), /// ), /// ) -///``` +/// ``` /// /// Configuring a ButtonStyle directly makes it possible to very /// precisely control the button’s visual attributes for all states. @@ -77,7 +77,7 @@ import 'theme_data.dart'; /// TextButton( /// style: TextButton.styleFrom(primary: Colors.green), /// ) -///``` +/// ``` /// /// To configure all of the application's text buttons in the same /// way, specify the overall theme's `textButtonTheme`: @@ -90,7 +90,7 @@ import 'theme_data.dart'; /// ), /// home: MyAppHome(), /// ) -///``` +/// ``` /// See also: /// /// * [TextButtonTheme], the theme for [TextButton]s. diff --git a/packages/flutter/lib/src/material/checkbox_list_tile.dart b/packages/flutter/lib/src/material/checkbox_list_tile.dart index 649b60e114b..c5ff79adc11 100644 --- a/packages/flutter/lib/src/material/checkbox_list_tile.dart +++ b/packages/flutter/lib/src/material/checkbox_list_tile.dart @@ -109,7 +109,7 @@ import 'theme_data.dart'; /// final String label; /// final EdgeInsets padding; /// final bool value; -/// final Function onChanged; +/// final ValueChanged onChanged; /// /// @override /// Widget build(BuildContext context) { @@ -135,7 +135,7 @@ import 'theme_data.dart'; /// Checkbox( /// value: value, /// onChanged: (bool? newValue) { -/// onChanged(newValue); +/// onChanged(newValue!); /// }, /// ), /// ], @@ -190,7 +190,7 @@ import 'theme_data.dart'; /// final String label; /// final EdgeInsets padding; /// final bool value; -/// final Function onChanged; +/// final ValueChanged onChanged; /// /// @override /// Widget build(BuildContext context) { @@ -206,7 +206,7 @@ import 'theme_data.dart'; /// Checkbox( /// value: value, /// onChanged: (bool? newValue) { -/// onChanged(newValue); +/// onChanged(newValue!); /// }, /// ), /// ], diff --git a/packages/flutter/lib/src/material/radio_list_tile.dart b/packages/flutter/lib/src/material/radio_list_tile.dart index ecf48ddadce..f8744e435f9 100644 --- a/packages/flutter/lib/src/material/radio_list_tile.dart +++ b/packages/flutter/lib/src/material/radio_list_tile.dart @@ -120,7 +120,7 @@ import 'theme_data.dart'; /// final EdgeInsets padding; /// final bool groupValue; /// final bool value; -/// final Function onChanged; +/// final ValueChanged onChanged; /// /// @override /// Widget build(BuildContext context) { @@ -132,7 +132,7 @@ import 'theme_data.dart'; /// groupValue: groupValue, /// value: value, /// onChanged: (bool? newValue) { -/// onChanged(newValue); +/// onChanged(newValue!); /// } /// ), /// RichText( @@ -221,7 +221,7 @@ import 'theme_data.dart'; /// final EdgeInsets padding; /// final bool groupValue; /// final bool value; -/// final Function onChanged; +/// final ValueChanged onChanged; /// /// @override /// Widget build(BuildContext context) { @@ -239,7 +239,7 @@ import 'theme_data.dart'; /// groupValue: groupValue, /// value: value, /// onChanged: (bool? newValue) { -/// onChanged(newValue); +/// onChanged(newValue!); /// }, /// ), /// Text(label), diff --git a/packages/flutter/lib/src/material/switch_list_tile.dart b/packages/flutter/lib/src/material/switch_list_tile.dart index 2fd85b6edfa..654b34ab9bf 100644 --- a/packages/flutter/lib/src/material/switch_list_tile.dart +++ b/packages/flutter/lib/src/material/switch_list_tile.dart @@ -112,7 +112,7 @@ enum _SwitchListTileType { material, adaptive } /// final String label; /// final EdgeInsets padding; /// final bool value; -/// final Function onChanged; +/// final ValueChanged onChanged; /// /// @override /// Widget build(BuildContext context) { @@ -193,7 +193,7 @@ enum _SwitchListTileType { material, adaptive } /// final String label; /// final EdgeInsets padding; /// final bool value; -/// final Function onChanged; +/// final ValueChanged onChanged; /// /// @override /// Widget build(BuildContext context) { diff --git a/packages/flutter/lib/src/widgets/implicit_animations.dart b/packages/flutter/lib/src/widgets/implicit_animations.dart index 704e115f9da..87cfa3dfc33 100644 --- a/packages/flutter/lib/src/widgets/implicit_animations.dart +++ b/packages/flutter/lib/src/widgets/implicit_animations.dart @@ -1139,7 +1139,7 @@ class _AnimatedAlignState extends AnimatedWidgetBaseState { /// ), /// ); /// } -///``` +/// ``` /// {@end-tool} /// /// See also: diff --git a/packages/flutter/lib/src/widgets/preferred_size.dart b/packages/flutter/lib/src/widgets/preferred_size.dart index 21b33b730c5..358171ae621 100644 --- a/packages/flutter/lib/src/widgets/preferred_size.dart +++ b/packages/flutter/lib/src/widgets/preferred_size.dart @@ -94,7 +94,7 @@ abstract class PreferredSizeWidget implements Widget { /// } /// } /// ``` -///```dart +/// ```dart /// Widget build(BuildContext context) { /// return Scaffold( /// appBar: PreferredSize( diff --git a/packages/flutter/lib/src/widgets/scroll_notification_observer.dart b/packages/flutter/lib/src/widgets/scroll_notification_observer.dart index e2dd909bffa..7742e435e26 100644 --- a/packages/flutter/lib/src/widgets/scroll_notification_observer.dart +++ b/packages/flutter/lib/src/widgets/scroll_notification_observer.dart @@ -50,7 +50,7 @@ class _ListenerEntry extends LinkedListEntry<_ListenerEntry> { /// To remove the listener from a [ScrollNotificationObserver] ancestor: /// ```dart /// ScrollNotificationObserver.of(context).removeListener(listener); -///``` +/// ``` /// /// Stateful widgets that share an ancestor [ScrollNotificationObserver] typically /// add a listener in [State.didChangeDependencies] (removing the old one diff --git a/packages/flutter_driver/lib/src/extension/extension.dart b/packages/flutter_driver/lib/src/extension/extension.dart index c9caa19281b..c5578c9cdf8 100644 --- a/packages/flutter_driver/lib/src/extension/extension.dart +++ b/packages/flutter_driver/lib/src/extension/extension.dart @@ -163,7 +163,7 @@ class _DriverBinding extends BindingBase with SchedulerBinding, ServicesBinding, /// /// final int times; /// } -///``` +/// ``` /// /// ```dart /// class SomeCommandResult extends Result { diff --git a/packages/flutter_tools/lib/src/asset.dart b/packages/flutter_tools/lib/src/asset.dart index 09717f7c1de..c03d5f44cd2 100644 --- a/packages/flutter_tools/lib/src/asset.dart +++ b/packages/flutter_tools/lib/src/asset.dart @@ -28,12 +28,12 @@ const String kFontManifestJson = 'FontManifest.json'; /// The effect of adding `uses-material-design: true` to the pubspec is to insert /// the following snippet into the asset manifest: /// -///```yaml +/// ```yaml /// material: /// - family: MaterialIcons /// fonts: /// - asset: fonts/MaterialIcons-Regular.otf -///``` +/// ``` const List> kMaterialFonts = >[ { 'family': 'MaterialIcons',