Skip to content

Commit

Permalink
feat(app): remove PageDescriptionText
Browse files Browse the repository at this point in the history
  • Loading branch information
tamslo committed Mar 1, 2024
1 parent 7fadc06 commit 48d116a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 15 deletions.
15 changes: 1 addition & 14 deletions app/lib/common/widgets/page_description.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class PageDescription extends StatelessWidget {
const PageDescription(this.widget);

factory PageDescription.fromText(String text) =>
PageDescription(PageDescriptionText(text));
PageDescription(Text(text));

final Widget widget;

Expand All @@ -19,16 +19,3 @@ class PageDescription extends StatelessWidget {
);
}
}

final pageDescriptionTextStyle = PharMeTheme.textTheme.bodyMedium;

class PageDescriptionText extends StatelessWidget {
const PageDescriptionText(this.text);

final String text;

@override
Widget build(BuildContext context) {
return Text(text, style: pageDescriptionTextStyle);
}
}
2 changes: 1 addition & 1 deletion app/lib/report/pages/report.dart
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class ReportPage extends StatelessWidget {
PageDescription(
Column(
children: [
PageDescriptionText(context.l10n.report_legend_text),
Text(context.l10n.report_legend_text),
SizedBox(height: PharMeTheme.smallSpace * 0.5),
_buildWarningLevelIndicators(
getText: (warningLevel) =>
Expand Down

0 comments on commit 48d116a

Please sign in to comment.