From bb00482276691842a570e81496cbb108d928b637 Mon Sep 17 00:00:00 2001 From: rithviknishad Date: Fri, 17 May 2024 19:57:23 +0530 Subject: [PATCH 1/2] Improve events UI --- .../ConsultationDetails/Events/GenericEvent.tsx | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/Components/Facility/ConsultationDetails/Events/GenericEvent.tsx b/src/Components/Facility/ConsultationDetails/Events/GenericEvent.tsx index 3176e18f2f3..dae260576a1 100644 --- a/src/Components/Facility/ConsultationDetails/Events/GenericEvent.tsx +++ b/src/Components/Facility/ConsultationDetails/Events/GenericEvent.tsx @@ -43,7 +43,13 @@ const formatValue = (value: unknown, key?: string): ReactNode => { return `No ${key?.replaceAll(/_/g, " ")}`; } - return value.map((v) => formatValue(v, key)); + return ( + + ); } if (value instanceof Date) { @@ -77,7 +83,7 @@ export default function GenericEvent(props: IProps) { return (
{Object.entries(props.values).map(([key, value]) => ( -
+
{key.replaceAll(/_/g, " ")} From 93dc136c4fdede22b4ed420e690faf9b44699b62 Mon Sep 17 00:00:00 2001 From: rithviknishad Date: Fri, 17 May 2024 19:59:15 +0530 Subject: [PATCH 2/2] remove unnecessry spaces --- .../Facility/ConsultationDetails/Events/GenericEvent.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Components/Facility/ConsultationDetails/Events/GenericEvent.tsx b/src/Components/Facility/ConsultationDetails/Events/GenericEvent.tsx index dae260576a1..543336987b2 100644 --- a/src/Components/Facility/ConsultationDetails/Events/GenericEvent.tsx +++ b/src/Components/Facility/ConsultationDetails/Events/GenericEvent.tsx @@ -83,7 +83,7 @@ export default function GenericEvent(props: IProps) { return (
{Object.entries(props.values).map(([key, value]) => ( -
+
{key.replaceAll(/_/g, " ")}