TF-3766 Change context menu style for mailbox on mobile
Signed-off-by: dab246 <tdvu@linagora.com>
This commit is contained in:
@@ -91,7 +91,6 @@ export 'presentation/views/popup_menu/popup_menu_item_widget.dart';
|
||||
export 'presentation/views/quick_search/quick_search_input_form.dart';
|
||||
export 'presentation/views/toast/toast_position.dart';
|
||||
export 'presentation/views/toast/tmail_toast.dart';
|
||||
export 'presentation/views/bottom_popup/full_screen_action_sheet_builder.dart';
|
||||
export 'presentation/views/checkbox/labeled_checkbox.dart';
|
||||
export 'presentation/views/checkbox/default_labeled_checkbox.dart';
|
||||
export 'presentation/views/checkbox/custom_icon_labeled_checkbox.dart';
|
||||
|
||||
@@ -243,6 +243,15 @@ class ThemeUtils {
|
||||
color: Colors.black,
|
||||
);
|
||||
|
||||
static final TextStyle textStyleInter400 = TextStyle(
|
||||
fontFamily: ConstantsUI.fontApp,
|
||||
fontWeight: FontWeight.w400,
|
||||
letterSpacing: -0.15,
|
||||
fontSize: 16,
|
||||
height: 21.01 / 16,
|
||||
color: AppColor.gray424244.withOpacity(0.9),
|
||||
);
|
||||
|
||||
static TextStyle textStyleM3LabelLarge({Color? color}) => TextStyle(
|
||||
fontFamily: ConstantsUI.fontApp,
|
||||
fontWeight: FontWeight.w500,
|
||||
|
||||
@@ -1,74 +0,0 @@
|
||||
import 'package:core/core.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:pointer_interceptor/pointer_interceptor.dart';
|
||||
|
||||
typedef OnCloseActionClick = Function();
|
||||
|
||||
class FullScreenActionSheetBuilder {
|
||||
final BuildContext context;
|
||||
final Widget child;
|
||||
|
||||
final Widget? titleWidget;
|
||||
final Widget? cancelWidget;
|
||||
OnCloseActionClick? onCloseActionClick;
|
||||
late double _statusBarHeight;
|
||||
|
||||
FullScreenActionSheetBuilder({
|
||||
required this.context,
|
||||
required this.child,
|
||||
this.titleWidget,
|
||||
this.cancelWidget,
|
||||
this.onCloseActionClick,
|
||||
}) {
|
||||
_statusBarHeight = MediaQuery.of(context).padding.top;
|
||||
}
|
||||
|
||||
Future show() {
|
||||
return showModalBottomSheet(
|
||||
context: context,
|
||||
isScrollControlled: true,
|
||||
barrierColor: AppColor.colorDefaultCupertinoActionSheet,
|
||||
backgroundColor: Colors.transparent,
|
||||
enableDrag: false,
|
||||
builder: (context) => PointerInterceptor(child: _buildBody(context)),
|
||||
);
|
||||
}
|
||||
|
||||
Widget _buildBody(BuildContext context) {
|
||||
return SafeArea(
|
||||
top: true,
|
||||
bottom: false,
|
||||
left: false,
|
||||
right: false,
|
||||
child: GestureDetector(
|
||||
onTap: () => FocusManager.instance.primaryFocus?.unfocus(),
|
||||
child: Padding(
|
||||
padding: EdgeInsets.only(top: _statusBarHeight),
|
||||
child: ClipRRect(
|
||||
borderRadius: const BorderRadius.only(
|
||||
topRight: Radius.circular(14),
|
||||
topLeft: Radius.circular(14),
|
||||
),
|
||||
child: Scaffold(
|
||||
appBar: AppBar(
|
||||
leading: const SizedBox.shrink(),
|
||||
title: titleWidget,
|
||||
centerTitle: true,
|
||||
actions: [
|
||||
GestureDetector(
|
||||
child: cancelWidget,
|
||||
onTapDown: (_) {
|
||||
onCloseActionClick?.call();
|
||||
Get.back();
|
||||
},
|
||||
)
|
||||
],
|
||||
),
|
||||
body: child,
|
||||
),
|
||||
)),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user