forked from firka/flutter
[NNBD] Migrate sample code (#72938)
This commit is contained in:
@@ -3014,7 +3014,7 @@ class InputDecoration {
|
||||
/// If null, a [BoxConstraints] with a minimum width and height of 48px is
|
||||
/// used.
|
||||
///
|
||||
/// {@tool dartpad --template=stateless_widget_scaffold_no_null_safety}
|
||||
/// {@tool dartpad --template=stateless_widget_scaffold}
|
||||
/// This example shows the differences between two `TextField` widgets when
|
||||
/// [suffixIconConstraints] is set to the default value and when one is not.
|
||||
///
|
||||
|
||||
@@ -58,7 +58,7 @@ typedef NestedScrollViewHeaderSliversBuilder = List<Widget> Function(BuildContex
|
||||
/// (those inside the [TabBarView], hooking them together so that they appear,
|
||||
/// to the user, as one coherent scroll view.
|
||||
///
|
||||
/// {@tool sample --template=stateless_widget_material_no_null_safety}
|
||||
/// {@tool sample --template=stateless_widget_material}
|
||||
///
|
||||
/// This example shows a [NestedScrollView] whose header is the combination of a
|
||||
/// [TabBar] in a [SliverAppBar] and whose body is a [TabBarView]. It uses a
|
||||
@@ -220,7 +220,7 @@ typedef NestedScrollViewHeaderSliversBuilder = List<Widget> Function(BuildContex
|
||||
/// configuration, the flexible space of the app bar will open and collapse,
|
||||
/// while the primary portion of the app bar remains pinned.
|
||||
///
|
||||
/// {@tool sample --template=stateless_widget_material_no_null_safety}
|
||||
/// {@tool sample --template=stateless_widget_material}
|
||||
///
|
||||
/// This simple example shows a [NestedScrollView] whose header contains a
|
||||
/// floating [SliverAppBar]. By using the [floatHeaderSlivers] property, the
|
||||
@@ -281,7 +281,7 @@ typedef NestedScrollViewHeaderSliversBuilder = List<Widget> Function(BuildContex
|
||||
/// for the nested "inner" scroll view below to end up under the [SliverAppBar]
|
||||
/// even when the inner scroll view thinks it has not been scrolled.
|
||||
///
|
||||
/// {@tool sample --template=stateless_widget_material_no_null_safety}
|
||||
/// {@tool sample --template=stateless_widget_material}
|
||||
///
|
||||
/// This simple example shows a [NestedScrollView] whose header contains a
|
||||
/// snapping, floating [SliverAppBar]. _Without_ setting any additional flags,
|
||||
@@ -500,7 +500,7 @@ class NestedScrollView extends StatefulWidget {
|
||||
/// [NestedScrollView], you can get its [NestedScrollViewState] by supplying a
|
||||
/// `GlobalKey<NestedScrollViewState>` to the [NestedScrollView.key] parameter).
|
||||
///
|
||||
/// {@tool dartpad --template=stateless_widget_material_no_null_safety}
|
||||
/// {@tool dartpad --template=stateless_widget_material}
|
||||
/// [NestedScrollViewState] can be obtained using a [GlobalKey].
|
||||
/// Using the following setup, you can access the inner scroll controller
|
||||
/// using `globalKey.currentState.innerController`.
|
||||
@@ -527,7 +527,7 @@ class NestedScrollView extends StatefulWidget {
|
||||
/// }
|
||||
///
|
||||
/// ScrollController get innerController {
|
||||
/// return globalKey.currentState.innerController;
|
||||
/// return globalKey.currentState!.innerController;
|
||||
/// }
|
||||
/// ```
|
||||
/// {@end-tool}
|
||||
|
||||
Reference in New Issue
Block a user