Skip to content

Commit

Permalink
fix uncategorised text shown if no principal diagnosis selected
Browse files Browse the repository at this point in the history
  • Loading branch information
rithviknishad committed Jun 7, 2024
1 parent 1945a27 commit 1a0d1fb
Showing 1 changed file with 12 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,17 +48,18 @@ const PrincipalDiagnosisSelect = <T extends Option>(props: Props<T>) => {
}}
errorClassName="hidden"
/>
{diagnosis?.chapter ? (
<span className="mt-3 flex w-full flex-wrap justify-center gap-x-1 px-2 text-center text-gray-900">
<p>This encounter will be categorised under:</p>
<p className="font-bold">{diagnosis.chapter}</p>
</span>
) : (
<span className="mt-3 flex w-full flex-wrap justify-center gap-x-1 px-2 text-center italic text-gray-700">
This encounter will not be categorised under any chapter as the
diagnosis does not fall under a chapter.
</span>
)}
{diagnosis &&
(diagnosis?.chapter ? (
<span className="mt-3 flex w-full flex-wrap justify-center gap-x-1 px-2 text-center text-gray-900">
<p>This encounter will be categorised under:</p>
<p className="font-bold">{diagnosis.chapter}</p>
</span>
) : (
<span className="mt-3 flex w-full flex-wrap justify-center gap-x-1 px-2 text-center italic text-gray-700">
This encounter will not be categorised under any chapter as the
diagnosis does not fall under a chapter.
</span>
))}
</div>
</div>
);
Expand Down

0 comments on commit 1a0d1fb

Please sign in to comment.