From 72f9bdde7ca3b44f79ca40519ade573e5cf3b841 Mon Sep 17 00:00:00 2001 From: Gokulram A Date: Thu, 30 Nov 2023 21:16:26 +0530 Subject: [PATCH] Remove dosage from TimelineNode component --- src/CAREUI/display/Timeline.tsx | 18 ------------------ .../Medicine/PrescrpitionTimeline.tsx | 6 +++--- 2 files changed, 3 insertions(+), 21 deletions(-) diff --git a/src/CAREUI/display/Timeline.tsx b/src/CAREUI/display/Timeline.tsx index 671f7e82cae..7549fbfd69f 100644 --- a/src/CAREUI/display/Timeline.tsx +++ b/src/CAREUI/display/Timeline.tsx @@ -10,7 +10,6 @@ export interface TimelineEvent { by: PerformedByModel | undefined; icon: IconName; notes?: string; - dosage?: string; cancelled?: boolean; } @@ -100,7 +99,6 @@ export const TimelineNode = (props: TimelineNodeProps) => {
- {props.event.dosage} {props.event.notes} {props.children}
@@ -158,19 +156,3 @@ export const TimelineNodeNotes = ({ ); }; - -export const TimelineNodeDosage = ({ - children, - icon = "l-capsule", -}: TimelineNodeNotesProps) => { - if (!children) { - return; - } - - return ( -
- -
{children}
-
- ); -}; diff --git a/src/Components/Medicine/PrescrpitionTimeline.tsx b/src/Components/Medicine/PrescrpitionTimeline.tsx index e2f1c7dcb87..27f997e2429 100644 --- a/src/Components/Medicine/PrescrpitionTimeline.tsx +++ b/src/Components/Medicine/PrescrpitionTimeline.tsx @@ -119,8 +119,9 @@ const MedicineAdministeredNode = ({ name="medicine" event={event} className={classNames(event.cancelled && "opacity-70")} - // TODO: to add administered dosage when Titrated Prescriptions are implemented - titleSuffix={`administered the medicine at ${formatTime( + titleSuffix={`administered ${ + event.administration.dosage + } dose of the medicine at ${formatTime( event.administration.administered_date )}.`} actions={ @@ -211,7 +212,6 @@ const compileEvents = ( by: administration.administered_by, cancelled: !!administration.archived_on, administration, - dosage: administration.dosage, notes: administration.notes, }); });