fix: font issue on linux.
This commit is contained in:
@@ -18,11 +18,11 @@ var darkTheme = _darkTheme.copyWith(
|
|||||||
textTheme: _darkTheme.textTheme.copyWith(
|
textTheme: _darkTheme.textTheme.copyWith(
|
||||||
headline1: TextStyle(
|
headline1: TextStyle(
|
||||||
color: Color(0xffc0c6d4),
|
color: Color(0xffc0c6d4),
|
||||||
fontFamilyFallback: kIsWeb ? null : [defaultFontFamily],
|
fontFamily: kIsWeb ? null : defaultFontFamily,
|
||||||
),
|
),
|
||||||
bodyText2: TextStyle(
|
bodyText2: TextStyle(
|
||||||
color: Color(0xffc0c6d4),
|
color: Color(0xffc0c6d4),
|
||||||
fontFamilyFallback: kIsWeb ? null : [defaultFontFamily],
|
fontFamily: kIsWeb ? null : defaultFontFamily,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
popupMenuTheme: _darkTheme.popupMenuTheme.copyWith(
|
popupMenuTheme: _darkTheme.popupMenuTheme.copyWith(
|
||||||
@@ -34,6 +34,7 @@ var darkTheme = _darkTheme.copyWith(
|
|||||||
tooltipTheme: _darkTheme.tooltipTheme.copyWith(
|
tooltipTheme: _darkTheme.tooltipTheme.copyWith(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
color: Colors.grey,
|
color: Colors.grey,
|
||||||
|
fontFamily: kIsWeb ? null : defaultFontFamily,
|
||||||
),
|
),
|
||||||
padding: EdgeInsets.symmetric(horizontal: 3, vertical: 2),
|
padding: EdgeInsets.symmetric(horizontal: 3, vertical: 2),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
|
|||||||
@@ -18,11 +18,11 @@ var lightTheme = _lightTheme.copyWith(
|
|||||||
textTheme: _lightTheme.textTheme.copyWith(
|
textTheme: _lightTheme.textTheme.copyWith(
|
||||||
headline1: TextStyle(
|
headline1: TextStyle(
|
||||||
color: Color(0xff414d68),
|
color: Color(0xff414d68),
|
||||||
fontFamilyFallback: kIsWeb ? null : [defaultFontFamily],
|
fontFamily: kIsWeb ? null : defaultFontFamily,
|
||||||
),
|
),
|
||||||
bodyText2: TextStyle(
|
bodyText2: TextStyle(
|
||||||
color: Color(0xff414d68),
|
color: Color(0xff414d68),
|
||||||
fontFamilyFallback: kIsWeb ? null : [defaultFontFamily],
|
fontFamily: kIsWeb ? null : defaultFontFamily,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
popupMenuTheme: _lightTheme.popupMenuTheme.copyWith(
|
popupMenuTheme: _lightTheme.popupMenuTheme.copyWith(
|
||||||
@@ -34,6 +34,7 @@ var lightTheme = _lightTheme.copyWith(
|
|||||||
tooltipTheme: _lightTheme.tooltipTheme.copyWith(
|
tooltipTheme: _lightTheme.tooltipTheme.copyWith(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
color: Colors.grey.shade600,
|
color: Colors.grey.shade600,
|
||||||
|
fontFamily: kIsWeb ? null : defaultFontFamily,
|
||||||
),
|
),
|
||||||
padding: EdgeInsets.symmetric(horizontal: 3, vertical: 2),
|
padding: EdgeInsets.symmetric(horizontal: 3, vertical: 2),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
|
|||||||
@@ -60,8 +60,6 @@ class _DMarkdownFieldState extends State<DMarkdownField> {
|
|||||||
? context.watch<SettingsProvider>().activeColor ?? Color(0xff565656)
|
? context.watch<SettingsProvider>().activeColor ?? Color(0xff565656)
|
||||||
: Color(0xff565656)),
|
: Color(0xff565656)),
|
||||||
),
|
),
|
||||||
child: DefaultTextStyle(
|
|
||||||
style: context.t.textTheme.bodyText2!,
|
|
||||||
child: isPreview
|
child: isPreview
|
||||||
? GestureDetector(
|
? GestureDetector(
|
||||||
onTap: widget.readOnly
|
onTap: widget.readOnly
|
||||||
@@ -77,6 +75,7 @@ class _DMarkdownFieldState extends State<DMarkdownField> {
|
|||||||
text: _previewText ?? '',
|
text: _previewText ?? '',
|
||||||
padding: EdgeInsets.only(left: 15),
|
padding: EdgeInsets.only(left: 15),
|
||||||
onTapLink: H.launchURL,
|
onTapLink: H.launchURL,
|
||||||
|
textStyle: context.t.textTheme.bodyText2,
|
||||||
onCodeCopied: () {
|
onCodeCopied: () {
|
||||||
Notificator.success(
|
Notificator.success(
|
||||||
context,
|
context,
|
||||||
@@ -127,7 +126,6 @@ class _DMarkdownFieldState extends State<DMarkdownField> {
|
|||||||
ActionType.h5: LocaleKeys.md_editor_h5.tr(),
|
ActionType.h5: LocaleKeys.md_editor_h5.tr(),
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
),
|
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -237,8 +237,6 @@ class _MarketWidgetState extends State<MarketWidget> {
|
|||||||
),
|
),
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: const EdgeInsets.only(left: 8),
|
padding: const EdgeInsets.only(left: 8),
|
||||||
child: DefaultTextStyle(
|
|
||||||
style: context.t.textTheme.bodyText2!,
|
|
||||||
child: MdPreview(
|
child: MdPreview(
|
||||||
text: _schemes.firstWhereOrNull((e) => e.uuid == _selected)?.description ?? '',
|
text: _schemes.firstWhereOrNull((e) => e.uuid == _selected)?.description ?? '',
|
||||||
widgetImage: (imageUrl) => CachedNetworkImage(
|
widgetImage: (imageUrl) => CachedNetworkImage(
|
||||||
@@ -251,12 +249,12 @@ class _MarketWidgetState extends State<MarketWidget> {
|
|||||||
errorWidget: (context, url, error) => const Icon(Icons.error),
|
errorWidget: (context, url, error) => const Icon(Icons.error),
|
||||||
),
|
),
|
||||||
onTapLink: H.launchURL,
|
onTapLink: H.launchURL,
|
||||||
|
textStyle: context.t.textTheme.bodyText2,
|
||||||
onCodeCopied: () {},
|
onCodeCopied: () {},
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -242,11 +242,10 @@ class _MeWidgetState extends State<MeWidget> {
|
|||||||
),
|
),
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: const EdgeInsets.only(left: 8),
|
padding: const EdgeInsets.only(left: 8),
|
||||||
child: DefaultTextStyle(
|
|
||||||
style: context.t.textTheme.bodyText2!,
|
|
||||||
child: MdPreview(
|
child: MdPreview(
|
||||||
text: _schemes.firstWhereOrNull((e) => e.uuid == _selected)?.description ?? '',
|
text: _schemes.firstWhereOrNull((e) => e.uuid == _selected)?.description ?? '',
|
||||||
onTapLink: H.launchURL,
|
onTapLink: H.launchURL,
|
||||||
|
textStyle: context.t.textTheme.bodyText2,
|
||||||
widgetImage: (imageUrl) => CachedNetworkImage(
|
widgetImage: (imageUrl) => CachedNetworkImage(
|
||||||
imageUrl: imageUrl,
|
imageUrl: imageUrl,
|
||||||
placeholder: (context, url) => const SizedBox(
|
placeholder: (context, url) => const SizedBox(
|
||||||
@@ -260,7 +259,6 @@ class _MeWidgetState extends State<MeWidget> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in New Issue
Block a user