refactor: Use AnimatedSize for FAB

This commit is contained in:
Krille 2023-06-03 17:49:13 +02:00
parent 299aac134d
commit 5039f1ba3b
No known key found for this signature in database
1 changed files with 2 additions and 6 deletions

View File

@ -63,14 +63,10 @@ class StartChatFloatingActionButton extends StatelessWidget {
Widget build(BuildContext context) {
return ValueListenableBuilder<bool>(
valueListenable: scrolledToTop,
builder: (context, scrolledToTop, _) => AnimatedContainer(
builder: (context, scrolledToTop, _) => AnimatedSize(
duration: FluffyThemes.animationDuration,
curve: FluffyThemes.animationCurve,
width: roomsIsEmpty
? null
: scrolledToTop
? 144
: 56,
clipBehavior: Clip.none,
child: scrolledToTop
? FloatingActionButton.extended(
onPressed: () => _onPressed(context),