diff --git a/lib/pages/chat_search/chat_search_style.dart b/lib/pages/chat_search/chat_search_style.dart index 01e48718b6..2faacfcfc5 100644 --- a/lib/pages/chat_search/chat_search_style.dart +++ b/lib/pages/chat_search/chat_search_style.dart @@ -5,9 +5,6 @@ import 'package:flutter/material.dart'; class ChatSearchStyle { static ResponsiveUtils responsive = getIt.get(); - static double toolbarHeight(BuildContext context) => - responsive.isMobile(context) ? 64 : 72; - static const EdgeInsetsGeometry inputPadding = EdgeInsetsDirectional.only(start: 8, top: 16, bottom: 16, end: 16); @@ -20,12 +17,6 @@ class ChatSearchStyle { static const EdgeInsetsGeometry avatarPadding = EdgeInsetsDirectional.symmetric(horizontal: 8, vertical: 16); - static EdgeInsetsGeometry searchAppBarPadding(BuildContext context) => - EdgeInsetsDirectional.only( - top: responsive.isMobile(context) ? 0 : 16.0, - start: 8, - ); - static const EdgeInsetsGeometry emptyPadding = EdgeInsetsDirectional.all(16); static const double emptyGap = 128.0; diff --git a/lib/pages/chat_search/chat_search_view.dart b/lib/pages/chat_search/chat_search_view.dart index c3f66e688e..b8b05ae1cf 100644 --- a/lib/pages/chat_search/chat_search_view.dart +++ b/lib/pages/chat_search/chat_search_view.dart @@ -1,5 +1,6 @@ import 'package:collection/collection.dart'; import 'package:fluffychat/app_state/success.dart'; +import 'package:fluffychat/config/app_config.dart'; import 'package:fluffychat/domain/app_state/room/timeline_search_event_state.dart'; import 'package:fluffychat/pages/chat/chat_view_style.dart'; import 'package:fluffychat/pages/chat/events/message_download_content.dart'; @@ -42,13 +43,10 @@ class ChatSearchView extends StatelessWidget { return Scaffold( backgroundColor: LinagoraSysColors.material().onPrimary, appBar: AppBar( - toolbarHeight: ChatSearchStyle.toolbarHeight(context), + toolbarHeight: AppConfig.toolbarHeight(context), backgroundColor: LinagoraSysColors.material().onPrimary, automaticallyImplyLeading: false, - title: Padding( - padding: ChatSearchStyle.searchAppBarPadding(context), - child: _ChatSearchAppBar(controller), - ), + title: _ChatSearchAppBar(controller), ), body: controller.sameTypeEventsBuilderController != null ? _TimelineSearchView(