Skip to content

Commit

Permalink
add key to div
Browse files Browse the repository at this point in the history
  • Loading branch information
AshrafMd-1 authored Dec 26, 2023
1 parent de3c1bd commit 1149987
Showing 1 changed file with 11 additions and 13 deletions.
24 changes: 11 additions & 13 deletions src/Components/Patient/PatientHome.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -311,20 +311,18 @@ export const PatientHome = (props: any) => {
patientData.medical_history.length
) {
const medHis = patientData.medical_history;
patientMedHis = medHis.map((item: any, idx: number) => (
<>
{item?.disease !== "NO" && (
<div className="sm:col-span-1" key={`med_his_${idx}`}>
<div className="break-words text-sm font-semibold leading-5 text-zinc-400">
{item.disease}
</div>
<div className="mt-1 whitespace-normal break-words text-sm font-medium leading-5">
{item.details}
</div>
patientMedHis = medHis
.filter((item) => item.disease !== "NO")
.map((item, idx) => (
<div className="sm:col-span-1" key={`med_his_${idx}`}>
<div className="break-words text-sm font-semibold leading-5 text-zinc-400">
{item.disease}
</div>
)}
</>
));
<div className="mt-1 whitespace-normal break-words text-sm font-medium leading-5">
{item.details}
</div>
</div>
));
}

let consultationList, sampleList;
Expand Down

0 comments on commit 1149987

Please sign in to comment.