style: format the new FHIR coding modules

This commit is contained in:
Marc-André Bombeck committed 2026-06-20 10:19:44 +02:00
1 parent 3dd5b3dd5b
commit a2de09daf3
2 files changed
+8 -3

No files matched your search

+3 -2
View File
@@ -252,7 +252,7 @@ const UNIT_NORMALISATION: Record<string, string> = {
"µiu/ml": "m[IU]/L",
"uiu/ml": "m[IU]/L",
// eGFR rate
"mlmin173m2": "mL/min/{1.73_m2}",
mlmin173m2: "mL/min/{1.73_m2}",
"ml/min/1.73m2": "mL/min/{1.73_m2}",
"ml/min/1.73sqm": "mL/min/{1.73_m2}",
};
@@ -297,7 +297,8 @@ export function resolveLabCoding(
unit: string,
canonicalName?: string | null,
): ResolvedLabCoding | null {
const source = canonicalName && canonicalName.length > 0 ? canonicalName : analyte;
const source =
canonicalName && canonicalName.length > 0 ? canonicalName : analyte;
const key = normaliseLabKey(source);
const resolvedKey = LAB_LOINC_BY_KEY[key] ? key : LAB_ALIASES[key];
if (!resolvedKey) return null;
+5 -1
View File
@@ -666,7 +666,11 @@ export function observationsFromReportData(
code: coding
? {
coding: [
{ system: LOINC_SYSTEM, code: coding.loinc, display: coding.display },
{
system: LOINC_SYSTEM,
code: coding.loinc,
display: coding.display,
},
],
text,
}