Skip to content

Commit

Permalink
content: Use weightVariableTextStyle in ContentTheme.textStyleError
Browse files Browse the repository at this point in the history
This converts the last remaining place where we were using
TextStyle.fontWeight directly, when we should have been using
weightVariableTextStyle.

(In a future with
  flutter/flutter#148026
, though, all uses of weightVariableTextStyle should be changed back
to plain TextStyle.fontWeight.)
  • Loading branch information
chrisbobbe committed Jun 7, 2024
1 parent 8801eea commit fe76fae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/widgets/content.dart
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ class ContentTheme extends ThemeExtension<ContentTheme> {
)
.merge(weightVariableTextStyle(context))
.copyWith(debugLabel: 'ContentTheme.textStylePlainParagraph'),
textStyleError = const TextStyle(
fontSize: kBaseFontSize, fontWeight: FontWeight.bold, color: Colors.red);
textStyleError = const TextStyle(fontSize: kBaseFontSize, color: Colors.red)
.merge(weightVariableTextStyle(context, wght: 700));

ContentTheme._({
required this.textStylePlainParagraph,
Expand Down

0 comments on commit fe76fae

Please sign in to comment.