chore: Improve FABs

This commit is contained in:
Krille Fear 2021-12-31 09:12:47 +01:00
commit 6751c65f1f
4 changed files with 15 additions and 19 deletions

View file

@ -206,18 +206,13 @@ class ChatListView extends StatelessWidget {
Expanded(child: _ChatListViewBody(controller)),
]),
floatingActionButton: selectMode == SelectMode.normal
? controller.scrolledToTop
? FloatingActionButton.extended(
onPressed: () =>
VRouter.of(context).to('/newprivatechat'),
icon: const Icon(CupertinoIcons.chat_bubble),
label: Text(L10n.of(context).newChat),
)
: FloatingActionButton(
onPressed: () =>
VRouter.of(context).to('/newprivatechat'),
child: const Icon(CupertinoIcons.chat_bubble),
)
? FloatingActionButton.extended(
isExtended: controller.scrolledToTop,
onPressed: () =>
VRouter.of(context).to('/newprivatechat'),
icon: const Icon(CupertinoIcons.chat_bubble),
label: Text(L10n.of(context).newChat),
)
: null,
bottomNavigationBar: Column(
mainAxisSize: MainAxisSize.min,