From 2c240ca4ea0f37e6397365396d6a2753ce59ccf3 Mon Sep 17 00:00:00 2001 From: tamara-slosarek Date: Fri, 21 Feb 2025 10:48:03 +0100 Subject: [PATCH] feat(app): improve styling of missing / none guidelines --- .../drug/widgets/annotation_cards/guideline.dart | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/app/lib/drug/widgets/annotation_cards/guideline.dart b/app/lib/drug/widgets/annotation_cards/guideline.dart index 6e974576..14736ac0 100644 --- a/app/lib/drug/widgets/annotation_cards/guideline.dart +++ b/app/lib/drug/widgets/annotation_cards/guideline.dart @@ -84,16 +84,18 @@ class GuidelineAnnotationCard extends StatelessWidget { if ( implicationText != null && drug.warningLevel != WarningLevel.none - ) TextSpan( - text: context.l10n.drugs_page_implication_description, - style: descriptionStyle, - ), - TextSpan(text: ':\n', style: descriptionStyle), + ) ...[ + TextSpan( + text: context.l10n.drugs_page_implication_description, + style: descriptionStyle, + ), + TextSpan(text: ':\n', style: descriptionStyle), + ], WidgetSpan(child: SizedBox(height: PharMeTheme.mediumSpace * 1.3)), TextSpan( text: implicationText ?? context.l10n.drugs_page_no_guidelines_text, - style: implicationText != null + style: drug.warningLevel != WarningLevel.none ? TextStyle(fontWeight: FontWeight.bold) : TextStyle(fontStyle: FontStyle.italic) ),