Use fontFamily for all style in Text widget
Signed-off-by: dab246 <tdvu@linagora.com>
This commit is contained in:
+3
-2
@@ -1,4 +1,5 @@
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class AttachmentHeaderComposerWidgetStyle {
|
||||
@@ -13,12 +14,12 @@ class AttachmentHeaderComposerWidgetStyle {
|
||||
static const EdgeInsetsGeometry sizeLabelPadding = EdgeInsetsDirectional.symmetric(horizontal: 5, vertical: 2);
|
||||
static const EdgeInsetsGeometry padding = EdgeInsetsDirectional.all(8);
|
||||
|
||||
static const TextStyle labelTextSize = TextStyle(
|
||||
static TextStyle labelTextSize = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 13,
|
||||
color: AppColor.colorLabelComposer,
|
||||
fontWeight: FontWeight.w500
|
||||
);
|
||||
static const TextStyle sizeLabelTextSize = TextStyle(
|
||||
static TextStyle sizeLabelTextSize = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 12,
|
||||
color: Colors.white,
|
||||
fontWeight: FontWeight.w500
|
||||
|
||||
+10
-6
@@ -1,4 +1,5 @@
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class AttachmentItemComposerWidgetStyle {
|
||||
@@ -17,19 +18,22 @@ class AttachmentItemComposerWidgetStyle {
|
||||
static const EdgeInsetsGeometry deleteIconPadding = EdgeInsetsDirectional.all(3);
|
||||
static const EdgeInsetsGeometry progressLoadingPadding = EdgeInsetsDirectional.only(top: 8);
|
||||
|
||||
static const TextStyle labelTextStyle = TextStyle(
|
||||
static TextStyle labelTextStyle =
|
||||
ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 14,
|
||||
color: Colors.black,
|
||||
fontWeight: FontWeight.w500
|
||||
fontWeight: FontWeight.w500,
|
||||
);
|
||||
static const TextStyle dotsLabelTextStyle = TextStyle(
|
||||
static TextStyle dotsLabelTextStyle =
|
||||
ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 12,
|
||||
color: Colors.black,
|
||||
fontWeight: FontWeight.w500
|
||||
fontWeight: FontWeight.w500,
|
||||
);
|
||||
static const TextStyle sizeLabelTextStyle = TextStyle(
|
||||
static TextStyle sizeLabelTextStyle =
|
||||
ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 11,
|
||||
color: AppColor.colorLabelComposer,
|
||||
fontWeight: FontWeight.w500
|
||||
fontWeight: FontWeight.w500,
|
||||
);
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/responsive_utils.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:core/utils/platform_info.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
@@ -42,7 +43,7 @@ class ComposerStyle {
|
||||
static const EdgeInsetsGeometry popupItemPadding = EdgeInsetsDirectional.symmetric(horizontal: 12);
|
||||
static const EdgeInsetsGeometry insertImageLoadingBarMargin = EdgeInsetsDirectional.only(top: 12);
|
||||
|
||||
static const TextStyle popupItemTextStyle = TextStyle(
|
||||
static TextStyle popupItemTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: Colors.black,
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class DraggableRecipientTagWidgetStyle {
|
||||
@@ -13,7 +14,7 @@ class DraggableRecipientTagWidgetStyle {
|
||||
static const EdgeInsetsGeometry padding = EdgeInsets.symmetric(horizontal: 6, vertical: 3);
|
||||
static const EdgeInsetsGeometry labelPadding = EdgeInsets.symmetric(horizontal: 8);
|
||||
|
||||
static const TextStyle labelTextStyle = TextStyle(
|
||||
static TextStyle labelTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: Colors.white,
|
||||
fontSize: 17,
|
||||
fontWeight: FontWeight.normal
|
||||
|
||||
+6
-5
@@ -1,4 +1,5 @@
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class FromComposerBottomSheetStyle {
|
||||
@@ -29,27 +30,27 @@ class FromComposerBottomSheetStyle {
|
||||
color: AppColor.colorBgSearchBar
|
||||
);
|
||||
|
||||
static const TextStyle appBarTitleTextStyle = TextStyle(
|
||||
static TextStyle appBarTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: Colors.black,
|
||||
fontWeight: FontWeight.w700,
|
||||
fontSize: 20.0,
|
||||
);
|
||||
static const TextStyle searchBarTextStyle = TextStyle(
|
||||
static TextStyle searchBarTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: Colors.black,
|
||||
fontSize: 16.0,
|
||||
fontWeight: FontWeight.w600,
|
||||
);
|
||||
static const TextStyle searchHintTextStyle = TextStyle(
|
||||
static TextStyle searchHintTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: AppColor.loginTextFieldHintColor,
|
||||
fontSize: 16.0,
|
||||
fontWeight: FontWeight.w400,
|
||||
);
|
||||
static const TextStyle identityItemTitleTextStyle = TextStyle(
|
||||
static TextStyle identityItemTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: Colors.black,
|
||||
fontSize: 16.0,
|
||||
fontWeight: FontWeight.w500,
|
||||
);
|
||||
static const TextStyle identityItemSubTitleTextStyle = TextStyle(
|
||||
static TextStyle identityItemSubTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 13,
|
||||
fontWeight: FontWeight.w400,
|
||||
color: AppColor.colorLabelQuotas
|
||||
|
||||
+4
-3
@@ -1,4 +1,5 @@
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class FromComposerMobileWidgetStyle {
|
||||
@@ -24,18 +25,18 @@ class FromComposerMobileWidgetStyle {
|
||||
)
|
||||
);
|
||||
|
||||
static const TextStyle prefixTextStyle = TextStyle(
|
||||
static TextStyle prefixTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.w400,
|
||||
color: AppColor.colorLabelComposer
|
||||
);
|
||||
static const TextStyle buttonTitleTextStyle = TextStyle(
|
||||
static TextStyle buttonTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColor.colorCalendarEventUnread,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
);
|
||||
static const TextStyle buttonSubTitleTextStyle = TextStyle(
|
||||
static TextStyle buttonSubTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColor.colorLabelComposer,
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class TabletBottomBarComposerWidgetStyle {
|
||||
@@ -18,7 +19,7 @@ class TabletBottomBarComposerWidgetStyle {
|
||||
static const EdgeInsetsGeometry padding = EdgeInsetsDirectional.symmetric(horizontal: 32, vertical: 12);
|
||||
static const EdgeInsetsGeometry iconPadding = EdgeInsetsDirectional.all(5);
|
||||
static const EdgeInsetsGeometry sendButtonPadding = EdgeInsetsDirectional.symmetric(vertical: 8, horizontal: 24);
|
||||
static const TextStyle sendButtonTextStyle = TextStyle(
|
||||
static TextStyle sendButtonTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontWeight: FontWeight.w500,
|
||||
fontSize: 15,
|
||||
color: Colors.white,
|
||||
|
||||
@@ -31,7 +31,7 @@ class RecipientComposerWidgetStyle {
|
||||
static const EdgeInsetsGeometry recipientMargin = EdgeInsetsDirectional.only(top: 12);
|
||||
static const EdgeInsetsGeometry enableRecipientButtonMargin = EdgeInsetsDirectional.only(top: 10);
|
||||
|
||||
static const TextStyle prefixButtonTextStyle = TextStyle(
|
||||
static TextStyle prefixButtonTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontFamily: ConstantsUI.fontApp,
|
||||
fontSize: 15,
|
||||
fontWeight: FontWeight.w400,
|
||||
|
||||
+3
-2
@@ -1,4 +1,5 @@
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class RecipientSuggestionItemWidgetStyle {
|
||||
@@ -8,12 +9,12 @@ class RecipientSuggestionItemWidgetStyle {
|
||||
static const EdgeInsetsGeometry suggestionDuplicatedMargin = EdgeInsets.all(8.0);
|
||||
static const EdgeInsetsGeometry labelPadding = EdgeInsets.symmetric(horizontal: 16.0);
|
||||
|
||||
static const TextStyle labelTextStyle = TextStyle(
|
||||
static TextStyle labelTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: AppColor.colorHintSearchBar,
|
||||
fontSize: 13,
|
||||
fontWeight: FontWeight.normal
|
||||
);
|
||||
static const TextStyle labelHighlightTextStyle = TextStyle(
|
||||
static TextStyle labelHighlightTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: Colors.black,
|
||||
fontSize: 13,
|
||||
fontWeight: FontWeight.bold
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class RecipientTagItemWidgetStyle {
|
||||
@@ -12,7 +13,7 @@ class RecipientTagItemWidgetStyle {
|
||||
static const EdgeInsetsGeometry webMobileCounterMargin = EdgeInsetsDirectional.only(start: 8);
|
||||
static const EdgeInsetsGeometry webCounterMargin = EdgeInsetsDirectional.only(top: 8, start: 8);
|
||||
|
||||
static const TextStyle labelTextStyle = TextStyle(
|
||||
static TextStyle labelTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: Colors.black,
|
||||
fontSize: 17,
|
||||
fontWeight: FontWeight.w400
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
import 'package:core/presentation/constants/constants_ui.dart';
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -26,11 +25,7 @@ class BottomBarComposerWidgetStyle {
|
||||
static const EdgeInsetsGeometry richTextIconPadding = EdgeInsetsDirectional.all(2);
|
||||
static const EdgeInsetsGeometry popupItemPadding = EdgeInsetsDirectional.symmetric(horizontal: 12);
|
||||
|
||||
static const TextStyle sendButtonTextStyle = TextStyle(
|
||||
fontFamily: ConstantsUI.fontApp,
|
||||
fontWeight: FontWeight.w500,
|
||||
fontSize: 17,
|
||||
height: 22 / 17,
|
||||
static TextStyle sendButtonTextStyle = ThemeUtils.textStyleHeadingHeadingSmall().copyWith(
|
||||
color: Colors.white,
|
||||
letterSpacing: -0.41,
|
||||
);
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:tmail_ui_user/features/composer/presentation/styles/web/bottom_bar_composer_widget_style.dart';
|
||||
|
||||
@@ -20,7 +21,7 @@ class DropZoneWidgetStyle {
|
||||
top: 8
|
||||
);
|
||||
|
||||
static const TextStyle labelTextStyle = TextStyle(
|
||||
static TextStyle labelTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
color: Colors.black,
|
||||
fontSize: 22,
|
||||
fontWeight: FontWeight.w600
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class DropdownButtonFontSizeWidgetStyle {
|
||||
@@ -14,7 +15,7 @@ class DropdownButtonFontSizeWidgetStyle {
|
||||
static const EdgeInsetsGeometry padding = EdgeInsets.all(4);
|
||||
static const EdgeInsetsGeometry labelPadding = EdgeInsets.symmetric(horizontal: 16);
|
||||
|
||||
static const TextStyle labelTextStyle = TextStyle(
|
||||
static TextStyle labelTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColor.colorLabelRichText
|
||||
|
||||
+6
-6
@@ -63,32 +63,32 @@ class FromComposerDropDownWidgetStyle {
|
||||
height: 72,
|
||||
overlayColor: WidgetStateProperty.resolveWith<Color>((Set<WidgetState> states) => Colors.white)
|
||||
);
|
||||
static const TextStyle avatarTextStyle = TextStyle(
|
||||
static TextStyle avatarTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: Colors.black,
|
||||
);
|
||||
static const TextStyle dropdownItemTitleTextStyle = TextStyle(
|
||||
static TextStyle dropdownItemTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColor.colorDropDownItemTitleComposer,
|
||||
);
|
||||
static const TextStyle dropdownItemSubTitleTextStyle = TextStyle(
|
||||
static TextStyle dropdownItemSubTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 13,
|
||||
fontWeight: FontWeight.w400,
|
||||
color: AppColor.colorLabelQuotas
|
||||
);
|
||||
static const TextStyle dropdownTitleTextStyle = TextStyle(
|
||||
static TextStyle dropdownTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColor.colorDropDownTitleComposer,
|
||||
);
|
||||
static const TextStyle dropdownButtonTitleTextStyle = TextStyle(
|
||||
static TextStyle dropdownButtonTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColor.colorCalendarEventUnread
|
||||
);
|
||||
static const TextStyle dropdownButtonSubTitleTextStyle = TextStyle(
|
||||
static TextStyle dropdownButtonSubTitleTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColor.colorLabelComposer
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class ItemMenuFontSizeWidgetStyle {
|
||||
static const TextStyle labelTextStyle = TextStyle(
|
||||
static TextStyle labelTextStyle = ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: Colors.black,
|
||||
|
||||
@@ -75,7 +75,7 @@ class AttachmentItemComposerWidget extends StatelessWidget with AppLoaderMixin {
|
||||
? ExtendedText(
|
||||
fileName,
|
||||
maxLines: 1,
|
||||
overflowWidget: const TextOverflowWidget(
|
||||
overflowWidget: TextOverflowWidget(
|
||||
position: TextOverflowPosition.middle,
|
||||
clearType: TextOverflowClearType.clipRect,
|
||||
child: Text(
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
|
||||
import 'package:core/presentation/extensions/color_extension.dart';
|
||||
import 'package:core/presentation/utils/style_utils.dart';
|
||||
import 'package:core/presentation/utils/theme_utils.dart';
|
||||
import 'package:dropdown_button2/dropdown_button2.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:pointer_interceptor/pointer_interceptor.dart';
|
||||
@@ -106,10 +107,11 @@ class DropDownMenuHeaderStyleWidget extends StatelessWidget {
|
||||
|
||||
Widget _buildHeaderStyle(String name, double size, FontWeight fontWeight) {
|
||||
return Text(name,
|
||||
style: TextStyle(
|
||||
fontSize: size,
|
||||
fontWeight: fontWeight,
|
||||
color: Colors.black),
|
||||
style: ThemeUtils.defaultTextStyleInterFont.copyWith(
|
||||
fontSize: size,
|
||||
fontWeight: fontWeight,
|
||||
color: Colors.black,
|
||||
),
|
||||
maxLines: 1,
|
||||
softWrap: CommonTextStyle.defaultSoftWrap,
|
||||
overflow: CommonTextStyle.defaultTextOverFlow);
|
||||
|
||||
Reference in New Issue
Block a user