TF-3933 Avoid load font from google

Signed-off-by: dab246 <tdvu@linagora.com>
This commit is contained in:
dab246
2025-08-01 18:10:56 +07:00
committed by Dat H. Pham
parent 1c04825367
commit 801b08bc90
31 changed files with 352 additions and 277 deletions
@@ -1,5 +1,27 @@
import 'package:core/utils/platform_info.dart';
class ConstantsUI {
static const String fontApp = 'Inter';
static final List<String>? fontFamilyFallback = PlatformInfo.isMobile
? null
: webFontFamilyFallback;
static const List<String> webFontFamilyFallback = [
'Roboto', // Default Flutter font Latin, Cyrillic, Diacritics
'NotoSans', // Latin, Cyrillic supports European languages
'NotoSansArabic', // Arabic script
'NotoSansTamil', // Tamil script
'NotoSansThai', // Thai script
'NotoSansKR', // Korean
'NotoSansSC', // Simplified Chinese (zh_Hans)
'NotoSansMath', // Math symbols (∑, ∫, √, etc.)
'NotoSansEgyptianHieroglyphs', // Egyptian Hieroglyphs (𓀀)
'NotoEmoji', // Monochrome emoji
'NotoSansSymbols', // Miscellaneous symbols and arrows
'NotoSansSymbols2', // Extended symbol support
'sans-serif', // Generic fallback for any platform
];
static const double htmlContentMaxHeight = 22000.0;
static const double composerHtmlContentMaxHeight = 20000.0;
static const double htmlContentMinWidth = 300;