diff --git a/packages/two_dimensional_scrollables/lib/src/tree_view/tree.dart b/packages/two_dimensional_scrollables/lib/src/tree_view/tree.dart index f9fc6c82e7e..4f7dd216d27 100644 --- a/packages/two_dimensional_scrollables/lib/src/tree_view/tree.dart +++ b/packages/two_dimensional_scrollables/lib/src/tree_view/tree.dart @@ -496,6 +496,7 @@ class TreeView extends StatefulWidget { /// The default [AnimationStyle] used for node expand and collapse animations, /// when one has not been provided in [toggleAnimationStyle]. + // ignore: prefer_const_constructors static AnimationStyle defaultToggleAnimationStyle = AnimationStyle( curve: defaultAnimationCurve, duration: defaultAnimationDuration, diff --git a/packages/two_dimensional_scrollables/test/tree_view/render_tree_test.dart b/packages/two_dimensional_scrollables/test/tree_view/render_tree_test.dart index 3b239380d53..5ffd419bf7f 100644 --- a/packages/two_dimensional_scrollables/test/tree_view/render_tree_test.dart +++ b/packages/two_dimensional_scrollables/test/tree_view/render_tree_test.dart @@ -505,6 +505,7 @@ void main() { // Customize the animation treeView = TreeView( tree: treeNodes, + // ignore: prefer_const_constructors toggleAnimationStyle: AnimationStyle( duration: const Duration(milliseconds: 500), curve: Curves.bounceIn, diff --git a/packages/two_dimensional_scrollables/test/tree_view/tree_test.dart b/packages/two_dimensional_scrollables/test/tree_view/tree_test.dart index 5e536402b85..5db48784272 100644 --- a/packages/two_dimensional_scrollables/test/tree_view/tree_test.dart +++ b/packages/two_dimensional_scrollables/test/tree_view/tree_test.dart @@ -546,6 +546,7 @@ void main() { // Default expect( style, + // ignore: prefer_const_constructors AnimationStyle( duration: TreeView.defaultAnimationDuration, curve: TreeView.defaultAnimationCurve, @@ -574,6 +575,7 @@ void main() { await tester.pumpWidget(MaterialApp( home: TreeView( tree: simpleNodeSet, + // ignore: prefer_const_constructors toggleAnimationStyle: AnimationStyle( curve: Curves.easeIn, duration: const Duration(milliseconds: 200), @@ -757,6 +759,7 @@ void main() { home: TreeView( tree: tree, controller: controller, + // ignore: prefer_const_constructors toggleAnimationStyle: AnimationStyle( curve: Curves.easeInOut, duration: Duration.zero, @@ -843,6 +846,7 @@ void main() { home: TreeView( tree: tree, controller: controller, + // ignore: prefer_const_constructors toggleAnimationStyle: AnimationStyle( curve: Curves.easeInOut, duration: const Duration(milliseconds: 200),