From aeaad3918237bf8e180419cc7823837a76137e10 Mon Sep 17 00:00:00 2001 From: julian Date: Tue, 11 Apr 2023 08:28:05 -0600 Subject: [PATCH] style fix --- lib/widgets/custom_tab_view.dart | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/lib/widgets/custom_tab_view.dart b/lib/widgets/custom_tab_view.dart index 49fd81d18..6d89499a3 100644 --- a/lib/widgets/custom_tab_view.dart +++ b/lib/widgets/custom_tab_view.dart @@ -22,7 +22,6 @@ class CustomTabView extends StatefulWidget { } class _CustomTabViewState extends State { - final _key = GlobalKey(); late int _selectedIndex; static const duration = Duration(milliseconds: 250); @@ -80,6 +79,9 @@ class _CustomTabViewState extends State { : CrossFadeState.showSecond, duration: const Duration(milliseconds: 250), ), + const SizedBox( + height: 19, + ), ], ), ), @@ -88,9 +90,6 @@ class _CustomTabViewState extends State { ), ], ), - const SizedBox( - height: 19, - ), Stack( children: [ Container( @@ -117,7 +116,6 @@ class _CustomTabViewState extends State { ], ), AnimatedSwitcher( - key: _key, duration: duration, transitionBuilder: (child, animation) { return FadeTransition( @@ -135,7 +133,7 @@ class _CustomTabViewState extends State { ); }, child: AnimatedAlign( - key: Key(widget.titles[_selectedIndex]), + key: Key("${widget.titles[_selectedIndex]}_customTabKey"), alignment: Alignment.topCenter, duration: duration, child: Padding(