@bahmni/clinical-app 0.0.1-dev.369 → 0.0.1-dev.370
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ConsultationPage-CsvlKxDv.js → ConsultationPage-BV3BXEMh.js} +15 -17
- package/dist/{DocumentsTable-B-G7w_Ik-wcv6CsoB.js → DocumentsTable-C1vD9Kw9-ftdIXmkR.js} +13 -13
- package/dist/{FormsTable-C8tKxM7t-1CbhozQB.js → FormsTable-BhI227Fr-BCbOzFC4.js} +23 -23
- package/dist/{LNWAZHJI-C15yUhzq.js → LNWAZHJI-lRV9jkB1.js} +2 -2
- package/dist/{MWZ6AO7Z-BvWshUwD.js → MWZ6AO7Z-DEiFf-Mc.js} +2 -2
- package/dist/{Observations-BZqdA0Xj-BRzAgAHR.js → Observations-D3RSu-vt-g7jomFIO.js} +48 -48
- package/dist/{YPM2AS64-jSyFdy12.js → YPM2AS64-CQhU5EiF.js} +1 -1
- package/dist/components/patientHeader/ConsultationActionButton.d.ts.map +1 -1
- package/dist/{hook-DcJywswg.js → hook-BWfIb4f3.js} +1 -1
- package/dist/{index-N1oQjWLz.js → index-1Ys3OxQI.js} +3 -3
- package/dist/{index-Ctx7k5_5.js → index-BhY34I_M.js} +8745 -8746
- package/dist/{index-DEgE4jS-.js → index-z3UC96oc.js} +1 -1
- package/dist/index.css +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsxs, jsx, Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { B,
|
|
2
|
+
import { B, q as ENCOUNTER_CONCEPTS_URL, t as Yr, x as Di, A as BAHMNI_USER_LOCATION_COOKIE_NAME, u as useTranslation, F as Dm, I as fSe, g as gr, J as kH2, K as IH2, M as TH2, P as gM2, R as rc1, U as AH2, Z as TE, _ as Ii, a0 as Id, a1 as cE, a2 as Nd, a3 as Es, a4 as dist, a5 as yt, a6 as ye, a7 as ns, a8 as Db, a9 as Hb, aa as Bb, ab as BH2, ac as KH2, ad as oV2, G as G1, V as V3, ae as zb, af as sH2, ag as VH2, ah as pC2, ai as XH2, aj as JH2, k as kYt, ak as E_, al as RH2, am as F_, an as Os, ao as v_, ap as iv, aq as jb, ar as HH2, as as Qb, at as e_, au as CLINICAL_V2_CONFIG_BASE_URL, av as o_, aw as $E, ax as Qr, ay as r_, az as Lb, aA as cv, aB as Og2, aC as T_, aD as s_, aE as a_, aF as dv, aG as DH2, aH as Sv, aI as Ib, aJ as i_, aK as Kt, aL as jr, aM as yv, aN as vv, X as Xn, aO as B_, aP as R_, aQ as P_, N as NYt, aR as iC2, aS as sC2, aT as G_, aU as Y_, aV as STOP_REASON_VALUESET_URL, aW as STOP_REASON_VALUESET_EXPAND_URL, aX as STOP_MEDICATION_URL, aY as CH2, aZ as mf, a_ as Zn, a$ as oC2, b0 as z_, b1 as K_, b2 as VE, b3 as $b, b4 as jE, b5 as J_, b6 as an, b7 as N4, b8 as c3, b9 as rC2, ba as Q_, bb as X_, bc as Pi, bd as rs, be as L_, bf as Kb, bg as Tv, bh as uv, bi as lv, bj as av, bk as CDSS_SERVER_CONFIG_URL, bl as FYt, bm as UH2, bn as Jy, bo as x_, bp as k_, bq as $H2, br as ml1, bs as q_, bt as U_, bu as M_, bv as _Yt, bw as MYt, bx as BE, by as j_, bz as GH2, bA as nE, bB as BAHMNI_CLINICAL_PATH, bC as _E, bD as tw, bE as qH2, bF as WH2, bG as QE2, bH as SGt, bI as bE, bJ as SYt } from "./index-BhY34I_M.js";
|
|
3
3
|
import * as React from "react";
|
|
4
4
|
import React__default, { createContext, useContext, useState, useCallback, useEffect, useMemo, Children, useRef, useLayoutEffect, forwardRef, isValidElement, cloneElement, useReducer, Component, useImperativeHandle, PureComponent, createRef, useSyncExternalStore, Suspense } from "react";
|
|
5
5
|
import { useQuery, useQueries, useQueryClient } from "@tanstack/react-query";
|
|
6
6
|
import { useNavigate, useSearchParams } from "react-router-dom";
|
|
7
|
-
import { u as useClinicalConfig } from "./hook-
|
|
7
|
+
import { u as useClinicalConfig } from "./hook-BWfIb4f3.js";
|
|
8
8
|
import * as ReactDOM from "react-dom";
|
|
9
9
|
import ReactDOM__default, { createPortal } from "react-dom";
|
|
10
10
|
var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
@@ -139626,9 +139626,9 @@ const allergiesFormTile = "AllergiesForm-module_allergiesFormTile__1UsbU", aller
|
|
|
139626
139626
|
duplicateNotification: duplicateNotification$2
|
|
139627
139627
|
}, allergiesQueryKeys = (p) => ["allergies", p], AllergiesForm = React__default.memo(({ encounterSessionStartContext: p }) => {
|
|
139628
139628
|
const c = !!p?.preloadedAllergies, { t: a } = useTranslation(), s = gr(), { addNotification: f } = G1(), d = V3(
|
|
139629
|
-
|
|
139629
|
+
kYt.ALLERGIES
|
|
139630
139630
|
), h = V3(
|
|
139631
|
-
|
|
139631
|
+
kYt.EDIT_ALLERGIES
|
|
139632
139632
|
), [E, C] = useState(""), [R, T] = useState(null), [H, M] = useState(!1), [$, k] = useState(
|
|
139633
139633
|
null
|
|
139634
139634
|
), {
|
|
@@ -139951,7 +139951,7 @@ const investigationsFormTile = "InvestigationsForm-module_investigationsFormTile
|
|
|
139951
139951
|
duplicateNotification: duplicateNotification$1
|
|
139952
139952
|
}, InvestigationsForm = React__default.memo(() => {
|
|
139953
139953
|
const { t: p } = useTranslation(), c = gr(), { addNotification: a } = G1(), s = V3(
|
|
139954
|
-
|
|
139954
|
+
kYt.INVESTIGATIONS
|
|
139955
139955
|
), [f, d] = useState(""), [h, E] = useState(null), [C, R] = useState(!1), { activeEncounter: T, matchReasons: H } = F_(), $ = H.includes("MATCHED") ? T?.id : void 0, {
|
|
139956
139956
|
data: k,
|
|
139957
139957
|
refetch: I,
|
|
@@ -140364,7 +140364,7 @@ const conditionsAndDiagnosesTile = "ConditionsAndDiagnoses-module_conditionsAndD
|
|
|
140364
140364
|
duplicateNotification
|
|
140365
140365
|
}, ConditionsAndDiagnoses = React__default.memo(() => {
|
|
140366
140366
|
const { t: p } = useTranslation(), c = gr(), { addNotification: a } = G1(), s = V3(
|
|
140367
|
-
|
|
140367
|
+
kYt.CONDITIONS_AND_DIAGNOSES
|
|
140368
140368
|
), [f, d] = useState(""), [h, E] = useState(null), [C, R] = useState(!1), {
|
|
140369
140369
|
selectedDiagnoses: T,
|
|
140370
140370
|
selectedConditions: H,
|
|
@@ -143319,7 +143319,7 @@ function useSubmittedEncounterForms(p) {
|
|
|
143319
143319
|
), useMemo(() => {
|
|
143320
143320
|
const C = d?.entry?.map((T) => T.resource).filter((T) => T?.resourceType === "Observation") ?? [], R = /* @__PURE__ */ new Set();
|
|
143321
143321
|
for (const T of C) {
|
|
143322
|
-
const H =
|
|
143322
|
+
const H = NYt(T);
|
|
143323
143323
|
if (!H) continue;
|
|
143324
143324
|
const M = p.find(($) => $.name === H);
|
|
143325
143325
|
M && R.add(M.uuid);
|
|
@@ -143344,7 +143344,7 @@ const observationFormsTile = "ObservationForms-module_observationFormsTile__AZ0b
|
|
|
143344
143344
|
submittedFormUuids: R = EMPTY_SET
|
|
143345
143345
|
}) => {
|
|
143346
143346
|
const { t: T } = useTranslation(), H = V3(
|
|
143347
|
-
|
|
143347
|
+
kYt.OBSERVATIONS
|
|
143348
143348
|
), [M, $] = useState(""), [k, I] = useState(null), { getFormData: S } = useObservationFormsStore(), z = useMemo(() => {
|
|
143349
143349
|
if (!M.trim()) return h;
|
|
143350
143350
|
const ee = M.toLowerCase().trim().split(/\s+/);
|
|
@@ -144921,7 +144921,7 @@ const ConsultationPad = ({
|
|
|
144921
144921
|
visitUuids: f
|
|
144922
144922
|
}) => {
|
|
144923
144923
|
const { t: d } = useTranslation(), { matchReasons: h, canEditOrCreate: E, activeEncounter: C } = F_(), R = h.includes("NO_ACTIVE_VISIT"), T = h.includes("MATCHED"), M = h.includes("MATCHED") ? C?.id ?? null : null, $ = (I, S, z) => {
|
|
144924
|
-
const O =
|
|
144924
|
+
const O = FYt(I.type);
|
|
144925
144925
|
if (!O)
|
|
144926
144926
|
return /* @__PURE__ */ jsx("div", { className: styles$4.widgetError, children: /* @__PURE__ */ jsx("p", { children: d("CONTROL_NOT_FOUND", { type: I.type }) }) }, `${I.type}-${S}`);
|
|
144927
144927
|
const Z = S < z - 1;
|
|
@@ -145103,10 +145103,9 @@ const CONSULTATION_START_EVENT = "startConsultation", dispatchConsultationStart
|
|
|
145103
145103
|
const c = (a) => p(a.detail);
|
|
145104
145104
|
return globalThis.addEventListener(CONSULTATION_START_EVENT, c), () => globalThis.removeEventListener(CONSULTATION_START_EVENT, c);
|
|
145105
145105
|
}, [p]);
|
|
145106
|
-
}, header = "PatientHeader-module_header__xXn7c", actionButtons = "PatientHeader-module_actionButtons__iEQ7a",
|
|
145106
|
+
}, header = "PatientHeader-module_header__xXn7c", actionButtons = "PatientHeader-module_actionButtons__iEQ7a", newConsultationButtonSkeleton = "PatientHeader-module_newConsultationButtonSkeleton__HFZlG", styles$2 = {
|
|
145107
145107
|
header,
|
|
145108
145108
|
actionButtons,
|
|
145109
|
-
newConsultationButton,
|
|
145110
145109
|
newConsultationButtonSkeleton
|
|
145111
145110
|
}, ConsultationActionButton = ({
|
|
145112
145111
|
isActionAreaVisible: p,
|
|
@@ -145115,7 +145114,7 @@ const CONSULTATION_START_EVENT = "startConsultation", dispatchConsultationStart
|
|
|
145115
145114
|
}) => {
|
|
145116
145115
|
const { t: s } = useTranslation();
|
|
145117
145116
|
return V3(
|
|
145118
|
-
|
|
145117
|
+
kYt.ENCOUNTER
|
|
145119
145118
|
) ? a ? /* @__PURE__ */ jsx(
|
|
145120
145119
|
$H2,
|
|
145121
145120
|
{
|
|
@@ -145125,7 +145124,6 @@ const CONSULTATION_START_EVENT = "startConsultation", dispatchConsultationStart
|
|
|
145125
145124
|
) : /* @__PURE__ */ jsx(
|
|
145126
145125
|
ml1,
|
|
145127
145126
|
{
|
|
145128
|
-
className: styles$2.newConsultationButton,
|
|
145129
145127
|
size: "md",
|
|
145130
145128
|
disabled: p,
|
|
145131
145129
|
onClick: () => dispatchConsultationStart(
|
|
@@ -145194,7 +145192,7 @@ const CONSULTATION_START_EVENT = "startConsultation", dispatchConsultationStart
|
|
|
145194
145192
|
"data-active-encounter-uuid": T && H?.id ? H.id : void 0,
|
|
145195
145193
|
"data-active-practitioner-uuid": s?.uuid ?? void 0,
|
|
145196
145194
|
children: [
|
|
145197
|
-
/* @__PURE__ */ jsx(
|
|
145195
|
+
/* @__PURE__ */ jsx(_Yt, {}),
|
|
145198
145196
|
/* @__PURE__ */ jsxs("div", { className: styles$2.actionButtons, children: [
|
|
145199
145197
|
/* @__PURE__ */ jsx(
|
|
145200
145198
|
ConsultationActionButton,
|
|
@@ -145205,7 +145203,7 @@ const CONSULTATION_START_EVENT = "startConsultation", dispatchConsultationStart
|
|
|
145205
145203
|
}
|
|
145206
145204
|
),
|
|
145207
145205
|
/* @__PURE__ */ jsx(
|
|
145208
|
-
|
|
145206
|
+
MYt,
|
|
145209
145207
|
{
|
|
145210
145208
|
printOptions: c,
|
|
145211
145209
|
renderContext: Z,
|
|
@@ -145549,7 +145547,7 @@ const DASHBOARD_CONFIG_URL = (p) => `${CLINICAL_V2_CONFIG_BASE_URL}/dashboards/$
|
|
|
145549
145547
|
const re = () => {
|
|
145550
145548
|
const ae = H.get(PROGRAM_UUID_SEARCH_PARAMS_KEY);
|
|
145551
145549
|
return ae && c.contextInformation?.program ? /* @__PURE__ */ jsx(
|
|
145552
|
-
|
|
145550
|
+
SYt,
|
|
145553
145551
|
{
|
|
145554
145552
|
programUUID: ae,
|
|
145555
145553
|
config: {
|
|
@@ -145568,7 +145566,7 @@ const DASHBOARD_CONFIG_URL = (p) => `${CLINICAL_V2_CONFIG_BASE_URL}/dashboards/$
|
|
|
145568
145566
|
{
|
|
145569
145567
|
breadcrumbItems: O,
|
|
145570
145568
|
globalActions: k,
|
|
145571
|
-
userMenu: /* @__PURE__ */ jsx(
|
|
145569
|
+
userMenu: /* @__PURE__ */ jsx(SGt, {}),
|
|
145572
145570
|
sideNavItems: te,
|
|
145573
145571
|
activeSideNavItemId: ee,
|
|
145574
145572
|
onSideNavItemClick: le,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as r, jsxs as p, Fragment as Q } from "react/jsx-runtime";
|
|
2
|
-
import { g as W, u as x, G as Y,
|
|
2
|
+
import { g as W, u as x, G as Y, H as J, w as X, a as Z, W as ee, p as te } from "./index-BhY34I_M.js";
|
|
3
3
|
import { useQuery as ae } from "@tanstack/react-query";
|
|
4
4
|
import { useState as l, useCallback as h, useEffect as D, useMemo as _ } from "react";
|
|
5
5
|
const ne = "DocumentsTable-module_documentsTableBody__6iR3w", oe = "DocumentsTable-module_viewAttachmentsLink__aQ1on", re = "DocumentsTable-module_documentViewerContainer__F5m8D", de = "DocumentsTable-module_attachmentItem__17KA7", se = "DocumentsTable-module_attachmentCounter__WFiI3", me = "DocumentsTable-module_attachmentError__RI4U2", ce = "DocumentsTable-module_documentIframe__ptq5I", le = "DocumentsTable-module_documentImage__KQVgS", d = {
|
|
@@ -34,14 +34,14 @@ const Te = [
|
|
|
34
34
|
"uploadedOn",
|
|
35
35
|
"uploadedBy"
|
|
36
36
|
], pe = /\.(jpg|jpeg|png|gif|webp|bmp|svg)$/i, B = (a) => a.attachments.length > 0 ? a.attachments : a.documentUrl ? [{ url: a.documentUrl, contentType: a.contentType }] : [], Ie = ({ config: a, encounterUuids: g }) => {
|
|
37
|
-
const [s, w] = l(!1), [o,
|
|
37
|
+
const [s, w] = l(!1), [o, U] = l(
|
|
38
38
|
null
|
|
39
39
|
), [$, O] = l(
|
|
40
40
|
/* @__PURE__ */ new Set()
|
|
41
|
-
), E = W(), { t: n } = x(), { addNotification:
|
|
42
|
-
|
|
43
|
-
}, []),
|
|
44
|
-
w(!1),
|
|
41
|
+
), E = W(), { t: n } = x(), { addNotification: L } = Y(), k = Number(a?.pageSize) || 5, [f, C] = l(1), [u, H] = l(k), [V, A] = l(void 0), M = h((e) => {
|
|
42
|
+
U(e), w(!0);
|
|
43
|
+
}, []), F = h(() => {
|
|
44
|
+
w(!1), U(null), O(/* @__PURE__ */ new Set());
|
|
45
45
|
}, []), v = h((e) => {
|
|
46
46
|
O((t) => new Set(t).add(e));
|
|
47
47
|
}, []), { data: i, isLoading: q, isError: b, error: y } = ae({
|
|
@@ -65,12 +65,12 @@ const Te = [
|
|
|
65
65
|
}, [i]), D(() => {
|
|
66
66
|
C(1), A(void 0);
|
|
67
67
|
}, [E]), D(() => {
|
|
68
|
-
b &&
|
|
68
|
+
b && L({
|
|
69
69
|
title: n("ERROR_DEFAULT_TITLE"),
|
|
70
70
|
message: y?.message ?? "",
|
|
71
71
|
type: "error"
|
|
72
72
|
});
|
|
73
|
-
}, [b, y,
|
|
73
|
+
}, [b, y, L, n]), D(() => {
|
|
74
74
|
const e = new AbortController();
|
|
75
75
|
return (async () => {
|
|
76
76
|
if (!s || !o) return;
|
|
@@ -91,7 +91,7 @@ const Te = [
|
|
|
91
91
|
}, [s, o]);
|
|
92
92
|
const j = h(
|
|
93
93
|
(e, t) => {
|
|
94
|
-
t !== u ? (
|
|
94
|
+
t !== u ? (H(t), C(1), A(void 0)) : C(e);
|
|
95
95
|
},
|
|
96
96
|
[u]
|
|
97
97
|
), I = _(
|
|
@@ -125,7 +125,7 @@ const Te = [
|
|
|
125
125
|
return e.attachments.length > 0 || e.documentUrl ? /* @__PURE__ */ r(
|
|
126
126
|
X,
|
|
127
127
|
{
|
|
128
|
-
onClick: () =>
|
|
128
|
+
onClick: () => M(e),
|
|
129
129
|
className: d.viewAttachmentsLink,
|
|
130
130
|
"data-testid": `view-attachments-${e.id}`,
|
|
131
131
|
children: n("DOCUMENTS_VIEW_ATTACHMENTS")
|
|
@@ -135,7 +135,7 @@ const Te = [
|
|
|
135
135
|
return null;
|
|
136
136
|
}
|
|
137
137
|
},
|
|
138
|
-
[
|
|
138
|
+
[M, n]
|
|
139
139
|
);
|
|
140
140
|
return /* @__PURE__ */ p(Q, { children: [
|
|
141
141
|
/* @__PURE__ */ r("div", { "data-testid": "documents-table", children: /* @__PURE__ */ r(
|
|
@@ -152,7 +152,7 @@ const Te = [
|
|
|
152
152
|
className: d.documentsTableBody,
|
|
153
153
|
dataTestId: "documents-table",
|
|
154
154
|
pageSize: u,
|
|
155
|
-
totalItems:
|
|
155
|
+
totalItems: V,
|
|
156
156
|
page: f,
|
|
157
157
|
onPageChange: j
|
|
158
158
|
}
|
|
@@ -163,7 +163,7 @@ const Te = [
|
|
|
163
163
|
id: "modalIdForActionAreaLayout",
|
|
164
164
|
portalId: "main-display-area",
|
|
165
165
|
open: s,
|
|
166
|
-
onRequestClose:
|
|
166
|
+
onRequestClose: F,
|
|
167
167
|
modalHeading: o.documentIdentifier,
|
|
168
168
|
passiveModal: !0,
|
|
169
169
|
size: "lg",
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import { jsx as i, jsxs as z, Fragment as
|
|
2
|
-
import { u as ge, g as pe, V as be, X as Ne, b as Oe,
|
|
1
|
+
import { jsx as i, jsxs as z, Fragment as he } from "react/jsx-runtime";
|
|
2
|
+
import { u as ge, g as pe, V as be, X as Ne, b as Oe, c as Te, h as Ie, y as Ee, e as Ae, f as _e, D as ve, N as Se, s as K, a as Fe, d as x, r as P, w as Ce, W as G, S as Re, $ as Be, p as De, Y as Le, k as Ue } from "./index-BhY34I_M.js";
|
|
3
3
|
import { useQueryClient as Me, useQuery as O } from "@tanstack/react-query";
|
|
4
4
|
import { useState as Q, useMemo as d, useCallback as l } from "react";
|
|
5
5
|
const ke = "FormsTable-module_formsTableBody__SvGha", we = "FormsTable-module_modalHeading__wnTmA", qe = "FormsTable-module_customAccordianItem__isszs", T = {
|
|
6
6
|
formsTableBody: ke,
|
|
7
7
|
modalHeading: we,
|
|
8
8
|
customAccordianItem: qe
|
|
9
|
-
},
|
|
9
|
+
}, Ve = "startConsultation", ze = ({
|
|
10
10
|
episodeOfCareUuids: C,
|
|
11
11
|
encounterUuids: u,
|
|
12
12
|
config: X,
|
|
13
|
-
disableActions:
|
|
14
|
-
activeEncounterUuid:
|
|
13
|
+
disableActions: W = !1,
|
|
14
|
+
activeEncounterUuid: h = null
|
|
15
15
|
}) => {
|
|
16
16
|
const { t: n } = ge(), c = pe(), [g, R] = Q(!1), [s, B] = Q(null), {
|
|
17
|
-
numberOfVisits:
|
|
17
|
+
numberOfVisits: Z,
|
|
18
18
|
hideThumbnail: J = !1,
|
|
19
19
|
forms: p
|
|
20
20
|
} = X ?? {}, ee = be(
|
|
21
21
|
Ue.EDIT_OBSERVATIONS
|
|
22
|
-
), { userPrivileges: b } = Ne(), I = ee && !
|
|
22
|
+
), { userPrivileges: b } = Ne(), I = ee && !W && !!h, D = Oe(
|
|
23
23
|
C,
|
|
24
24
|
u
|
|
25
25
|
), re = Me(), {
|
|
@@ -30,7 +30,7 @@ const ke = "FormsTable-module_formsTableBody__SvGha", we = "FormsTable-module_mo
|
|
|
30
30
|
refetch: ae
|
|
31
31
|
} = O({
|
|
32
32
|
queryKey: ["forms", c, C],
|
|
33
|
-
queryFn: () => Te(c, void 0,
|
|
33
|
+
queryFn: () => Te(c, void 0, Z),
|
|
34
34
|
enabled: !!c && !D
|
|
35
35
|
}), k = d(() => {
|
|
36
36
|
let e = L;
|
|
@@ -54,8 +54,8 @@ const ke = "FormsTable-module_formsTableBody__SvGha", we = "FormsTable-module_mo
|
|
|
54
54
|
},
|
|
55
55
|
[N, b]
|
|
56
56
|
), f = l(
|
|
57
|
-
(e) => !
|
|
58
|
-
[
|
|
57
|
+
(e) => !h || e.encounterUuid !== h ? !1 : w(e.formName),
|
|
58
|
+
[h, w]
|
|
59
59
|
), q = l(
|
|
60
60
|
(e) => N.find((r) => r.name === e)?.uuid,
|
|
61
61
|
[N]
|
|
@@ -117,25 +117,25 @@ const ke = "FormsTable-module_formsTableBody__SvGha", we = "FormsTable-module_mo
|
|
|
117
117
|
return K(A).message;
|
|
118
118
|
if (v)
|
|
119
119
|
return K(v).message;
|
|
120
|
-
}, [A, v]),
|
|
120
|
+
}, [A, v]), y = d(
|
|
121
121
|
() => [
|
|
122
122
|
{ key: "recordedOn", header: n("RECORDED_ON") },
|
|
123
123
|
{ key: "recordedBy", header: n("RECORDED_BY") }
|
|
124
124
|
],
|
|
125
125
|
[n]
|
|
126
|
-
),
|
|
127
|
-
() => [...
|
|
128
|
-
[
|
|
126
|
+
), V = d(
|
|
127
|
+
() => [...y, { key: "actions", header: n("ACTIONS") }],
|
|
128
|
+
[y, n]
|
|
129
129
|
), ce = l(
|
|
130
|
-
(e) => I && e.some((r) => f(r)) ?
|
|
131
|
-
[I, f,
|
|
132
|
-
), fe =
|
|
130
|
+
(e) => I && e.some((r) => f(r)) ? V : y,
|
|
131
|
+
[I, f, V, y]
|
|
132
|
+
), fe = y, ye = d(
|
|
133
133
|
() => [
|
|
134
134
|
{ key: "recordedOn", sortable: !0 },
|
|
135
135
|
{ key: "recordedBy", sortable: !0 }
|
|
136
136
|
],
|
|
137
137
|
[]
|
|
138
|
-
),
|
|
138
|
+
), H = d(() => {
|
|
139
139
|
const e = k.reduce(
|
|
140
140
|
(r, o) => {
|
|
141
141
|
const a = o.formName;
|
|
@@ -166,7 +166,7 @@ const ke = "FormsTable-module_formsTableBody__SvGha", we = "FormsTable-module_mo
|
|
|
166
166
|
R(!1), B(null);
|
|
167
167
|
}, []), S = l((e) => {
|
|
168
168
|
globalThis.dispatchEvent(
|
|
169
|
-
new CustomEvent(
|
|
169
|
+
new CustomEvent(Ve, {
|
|
170
170
|
detail: {
|
|
171
171
|
editOnly: "observationForms",
|
|
172
172
|
editTitle: "EDIT_OBSERVATION_FORM_TITLE",
|
|
@@ -201,8 +201,8 @@ const ke = "FormsTable-module_formsTableBody__SvGha", we = "FormsTable-module_mo
|
|
|
201
201
|
},
|
|
202
202
|
[$, S, f, n]
|
|
203
203
|
);
|
|
204
|
-
return /* @__PURE__ */ z(
|
|
205
|
-
/* @__PURE__ */ i("div", { id: "forms-table", "data-testid": "forms-table", children: U || M ||
|
|
204
|
+
return /* @__PURE__ */ z(he, { children: [
|
|
205
|
+
/* @__PURE__ */ i("div", { id: "forms-table", "data-testid": "forms-table", children: U || M || H.length === 0 || D ? /* @__PURE__ */ i(
|
|
206
206
|
G,
|
|
207
207
|
{
|
|
208
208
|
headers: fe,
|
|
@@ -215,7 +215,7 @@ const ke = "FormsTable-module_formsTableBody__SvGha", we = "FormsTable-module_mo
|
|
|
215
215
|
className: T.formsTableBody,
|
|
216
216
|
dataTestId: "forms-table"
|
|
217
217
|
}
|
|
218
|
-
) : /* @__PURE__ */ i(Re, { align: "start", children:
|
|
218
|
+
) : /* @__PURE__ */ i(Re, { align: "start", children: H.map((e, r) => {
|
|
219
219
|
const { formName: o, records: a } = e, t = ce(a);
|
|
220
220
|
return /* @__PURE__ */ i(
|
|
221
221
|
Be,
|
|
@@ -232,7 +232,7 @@ const ke = "FormsTable-module_formsTableBody__SvGha", we = "FormsTable-module_mo
|
|
|
232
232
|
rows: a,
|
|
233
233
|
loading: !1,
|
|
234
234
|
errorStateMessage: "",
|
|
235
|
-
sortable:
|
|
235
|
+
sortable: ye,
|
|
236
236
|
emptyStateMessage: n("FORMS_UNAVAILABLE"),
|
|
237
237
|
renderCell: j,
|
|
238
238
|
className: T.formsTableBody,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-
|
|
2
|
-
import { bP as d, bQ as f, bR as e } from "./index-
|
|
1
|
+
import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-CQhU5EiF.js";
|
|
2
|
+
import { bP as d, bQ as f, bR as e } from "./index-BhY34I_M.js";
|
|
3
3
|
var p = (a) => {
|
|
4
4
|
const [r, t] = c({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./YPM2AS64-
|
|
2
|
-
import { bP as v, bQ as C, bR as e } from "./index-
|
|
1
|
+
import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./YPM2AS64-CQhU5EiF.js";
|
|
2
|
+
import { bP as v, bQ as C, bR as e } from "./index-BhY34I_M.js";
|
|
3
3
|
var h = (t) => {
|
|
4
4
|
const [r, o] = s({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsxs as S, jsx as u } from "react/jsx-runtime";
|
|
2
|
-
import { g as
|
|
2
|
+
import { g as V, G, u as N, v as K, E as k, f as q, T as z, O as M, L as j, i as w, W as x, C as H, Q as L, z as P, j as W, l as J, m as X, n as Z, o as ee } from "./index-BhY34I_M.js";
|
|
3
3
|
import { useQueries as ae, useQuery as te } from "@tanstack/react-query";
|
|
4
|
-
import { useRef as se, useEffect as $, useMemo as
|
|
5
|
-
const
|
|
6
|
-
const t = P(a, n, b), s = t.value,
|
|
7
|
-
let
|
|
8
|
-
|
|
4
|
+
import { useRef as se, useEffect as $, useMemo as R } from "react";
|
|
5
|
+
const C = (a, n, d, l, b, r) => {
|
|
6
|
+
const t = P(a, n, b), s = t.value, o = W(s);
|
|
7
|
+
let i = s;
|
|
8
|
+
o === "Image" && (i = /* @__PURE__ */ u(
|
|
9
9
|
X,
|
|
10
10
|
{
|
|
11
11
|
imageSrc: s,
|
|
@@ -13,22 +13,22 @@ const D = (a, n, d, l, b, r) => {
|
|
|
13
13
|
id: `${s}-img`,
|
|
14
14
|
hideThumbnail: r
|
|
15
15
|
}
|
|
16
|
-
)),
|
|
16
|
+
)), o === "Video" && (i = /* @__PURE__ */ u(
|
|
17
17
|
Z,
|
|
18
18
|
{
|
|
19
19
|
id: `${s}-video`,
|
|
20
20
|
videoSrc: s,
|
|
21
21
|
hideThumbnail: r
|
|
22
22
|
}
|
|
23
|
-
)),
|
|
23
|
+
)), o === "PDF" && (i = /* @__PURE__ */ u(ee, { id: `${s}-pdf`, src: s }));
|
|
24
24
|
const m = b("OBSERVATIONS_RECORDED_BY", {
|
|
25
25
|
provider: t.provider
|
|
26
|
-
}), p = a.display,
|
|
26
|
+
}), p = a.display, v = a.observationValue?.isAbnormal ? "abnormal-obs" : "obs", c = l ? `${l}-${v}-${p}-${d}-${n}` : `${v}-${p}-${d}-${n}`;
|
|
27
27
|
return /* @__PURE__ */ u(
|
|
28
28
|
J,
|
|
29
29
|
{
|
|
30
30
|
header: t.header,
|
|
31
|
-
value:
|
|
31
|
+
value: i,
|
|
32
32
|
info: m,
|
|
33
33
|
id: c,
|
|
34
34
|
testId: c,
|
|
@@ -43,9 +43,9 @@ const D = (a, n, d, l, b, r) => {
|
|
|
43
43
|
id: `grouped-obs-${a.display}-${l}`,
|
|
44
44
|
open: d,
|
|
45
45
|
children: a.members?.map(
|
|
46
|
-
(s,
|
|
46
|
+
(s, o) => C(
|
|
47
47
|
s,
|
|
48
|
-
|
|
48
|
+
o,
|
|
49
49
|
b,
|
|
50
50
|
r,
|
|
51
51
|
n,
|
|
@@ -54,23 +54,23 @@ const D = (a, n, d, l, b, r) => {
|
|
|
54
54
|
)
|
|
55
55
|
},
|
|
56
56
|
`grouped-obs-${a.id}`
|
|
57
|
-
),
|
|
57
|
+
), oe = ({
|
|
58
58
|
groupedData: a,
|
|
59
59
|
title: n = "",
|
|
60
60
|
hideThumbnail: d
|
|
61
61
|
}) => {
|
|
62
62
|
const { t: l } = N(), b = (r, t, s) => {
|
|
63
|
-
const
|
|
63
|
+
const o = H(r.encounterDetails, l);
|
|
64
64
|
return /* @__PURE__ */ S(
|
|
65
65
|
L,
|
|
66
66
|
{
|
|
67
|
-
title:
|
|
67
|
+
title: o,
|
|
68
68
|
id: `encounter-${r.encounterId}`,
|
|
69
69
|
open: t,
|
|
70
70
|
children: [
|
|
71
71
|
r.observations.map(
|
|
72
|
-
(
|
|
73
|
-
|
|
72
|
+
(i, m) => C(
|
|
73
|
+
i,
|
|
74
74
|
m,
|
|
75
75
|
s,
|
|
76
76
|
n,
|
|
@@ -79,8 +79,8 @@ const D = (a, n, d, l, b, r) => {
|
|
|
79
79
|
)
|
|
80
80
|
),
|
|
81
81
|
r.groupedObservations.map(
|
|
82
|
-
(
|
|
83
|
-
|
|
82
|
+
(i, m) => re(
|
|
83
|
+
i,
|
|
84
84
|
l,
|
|
85
85
|
t,
|
|
86
86
|
m,
|
|
@@ -105,44 +105,44 @@ const D = (a, n, d, l, b, r) => {
|
|
|
105
105
|
)
|
|
106
106
|
}
|
|
107
107
|
);
|
|
108
|
-
},
|
|
109
|
-
observations:
|
|
108
|
+
}, ie = "Observations-module_observations__RKSyo", ne = "Observations-module_title__TJL3z", I = {
|
|
109
|
+
observations: ie,
|
|
110
110
|
title: ne
|
|
111
111
|
}, de = (a) => ["conceptUuid", a], le = (a, n) => ["observations", a, ...n], pe = ({ config: a }) => {
|
|
112
112
|
const n = a, {
|
|
113
113
|
conceptNames: d = [],
|
|
114
114
|
conceptUuid: l = [],
|
|
115
115
|
hideThumbnail: b = !1
|
|
116
|
-
} = n, r = se(/* @__PURE__ */ new Set()), t =
|
|
116
|
+
} = n, r = se(/* @__PURE__ */ new Set()), t = V(), { addNotification: s } = G(), { t: o } = N(), i = ae({
|
|
117
117
|
queries: d.map((e) => ({
|
|
118
118
|
queryKey: de(e),
|
|
119
|
-
queryFn: () =>
|
|
119
|
+
queryFn: () => K(e),
|
|
120
120
|
enabled: !!e
|
|
121
121
|
}))
|
|
122
122
|
});
|
|
123
123
|
$(() => {
|
|
124
|
-
|
|
124
|
+
i.forEach((e, h) => {
|
|
125
125
|
if (e.isError && !r.current.has(h)) {
|
|
126
|
-
const
|
|
126
|
+
const Q = d[h];
|
|
127
127
|
s({
|
|
128
|
-
title:
|
|
129
|
-
message:
|
|
128
|
+
title: o("ERROR_DEFAULT_TITLE"),
|
|
129
|
+
message: o("ERROR_FETCHING_CONCEPT", { conceptName: Q }),
|
|
130
130
|
type: "error"
|
|
131
131
|
}), r.current.add(h);
|
|
132
132
|
} else e.isError || r.current.delete(h);
|
|
133
133
|
});
|
|
134
|
-
}, [
|
|
135
|
-
const m =
|
|
134
|
+
}, [i, d]);
|
|
135
|
+
const m = R(() => i.map((e) => e.data?.uuid).filter((e) => !!e), [i]), p = R(() => [.../* @__PURE__ */ new Set([...m, ...l])], [m, l]), v = R(() => d.length === 0 ? !0 : i.every((e) => !e.isLoading), [i, d.length]), {
|
|
136
136
|
data: c,
|
|
137
|
-
isLoading:
|
|
137
|
+
isLoading: D,
|
|
138
138
|
isError: T,
|
|
139
139
|
refetch: O
|
|
140
140
|
} = te({
|
|
141
141
|
queryKey: le(t, p),
|
|
142
|
-
queryFn: () =>
|
|
143
|
-
enabled: !!t && p.length > 0 &&
|
|
142
|
+
queryFn: () => k(t, p),
|
|
143
|
+
enabled: !!t && p.length > 0 && v
|
|
144
144
|
});
|
|
145
|
-
|
|
145
|
+
q(
|
|
146
146
|
(e) => {
|
|
147
147
|
e.patientUUID === t && e.updatedConcepts.size > 0 && [...e.updatedConcepts.keys()].some(
|
|
148
148
|
(h) => p.includes(h)
|
|
@@ -151,25 +151,25 @@ const D = (a, n, d, l, b, r) => {
|
|
|
151
151
|
[t, O]
|
|
152
152
|
), $(() => {
|
|
153
153
|
T && s({
|
|
154
|
-
title:
|
|
155
|
-
message:
|
|
154
|
+
title: o("ERROR_DEFAULT_TITLE"),
|
|
155
|
+
message: o("ERROR_FETCHING_OBSERVATIONS"),
|
|
156
156
|
type: "error"
|
|
157
157
|
});
|
|
158
158
|
}, [T]);
|
|
159
|
-
const g =
|
|
159
|
+
const g = R(() => {
|
|
160
160
|
if (!c) return [];
|
|
161
161
|
const e = z(c), h = M(e);
|
|
162
162
|
return j(h);
|
|
163
|
-
}, [c]),
|
|
163
|
+
}, [c]), F = [
|
|
164
164
|
{ key: "name", header: "name" },
|
|
165
165
|
{ key: "value", header: "value" },
|
|
166
166
|
{ key: "form", header: "form" }
|
|
167
|
-
], f =
|
|
167
|
+
], f = D || !v, _ = T && v, A = (!c || c.entry?.length === 0 || p.length === 0) && v, U = _ ? o("ERROR_FETCHING_OBSERVATIONS") : null, Y = A ? o("NO_OBSERVATIONS_FOUND") : void 0, B = g.length > 0 && !f && !_, E = n.titleTranslationKey, y = E ? o(E) : "";
|
|
168
168
|
return /* @__PURE__ */ S(
|
|
169
169
|
"div",
|
|
170
170
|
{
|
|
171
171
|
id: "observations",
|
|
172
|
-
"data-testid":
|
|
172
|
+
"data-testid": E ? `observations-${y}` : "observations",
|
|
173
173
|
"aria-label": "observations-aria-label",
|
|
174
174
|
className: I.observations,
|
|
175
175
|
children: [
|
|
@@ -177,28 +177,28 @@ const D = (a, n, d, l, b, r) => {
|
|
|
177
177
|
w,
|
|
178
178
|
{
|
|
179
179
|
id: "observations-title",
|
|
180
|
-
testId:
|
|
181
|
-
title:
|
|
180
|
+
testId: E ? `observations-title-${y}` : "observations-title",
|
|
181
|
+
title: y,
|
|
182
182
|
className: I.title,
|
|
183
|
-
children: /* @__PURE__ */ u("p", { children:
|
|
183
|
+
children: /* @__PURE__ */ u("p", { children: y })
|
|
184
184
|
}
|
|
185
185
|
),
|
|
186
186
|
B ? /* @__PURE__ */ u(
|
|
187
|
-
|
|
187
|
+
oe,
|
|
188
188
|
{
|
|
189
189
|
groupedData: g,
|
|
190
|
-
title:
|
|
190
|
+
title: y,
|
|
191
191
|
hideThumbnail: b
|
|
192
192
|
}
|
|
193
193
|
) : /* @__PURE__ */ u(
|
|
194
194
|
x,
|
|
195
195
|
{
|
|
196
|
-
headers:
|
|
196
|
+
headers: F,
|
|
197
197
|
rows: [],
|
|
198
|
-
ariaLabel:
|
|
198
|
+
ariaLabel: o("OBSERVATIONS"),
|
|
199
199
|
loading: f,
|
|
200
|
-
errorStateMessage:
|
|
201
|
-
emptyStateMessage:
|
|
200
|
+
errorStateMessage: U,
|
|
201
|
+
emptyStateMessage: Y,
|
|
202
202
|
dataTestId: "observations-table"
|
|
203
203
|
}
|
|
204
204
|
)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { bS as we, bT as z, bU as xt, bV as B, bQ as q, bR as y, bW as Ro, bX as ye, bY as R, bZ as _, b_ as k, b$ as N, c0 as A, c1 as bs, c2 as ir, c3 as $e, c4 as U, c5 as Hn, c6 as Vn, c7 as dt, c8 as D, c9 as xs, ca as cn, cb as Be, cc as ws, cd as qt, ce as zt, cf as $s, cg as Cs, ch as $n, ci as Ss, cj as Nr, ck as Bt, cl as zo, cm as ks, cn as Es, co as j, cp as Ur, cq as Ms, cr as Ds, cs as sr, ct as As, cu as Ts, cv as zn, cw as Fs, cx as Is, cy as Z, cz as Ps, cA as Ls } from "./index-
|
|
1
|
+
import { bS as we, bT as z, bU as xt, bV as B, bQ as q, bR as y, bW as Ro, bX as ye, bY as R, bZ as _, b_ as k, b$ as N, c0 as A, c1 as bs, c2 as ir, c3 as $e, c4 as U, c5 as Hn, c6 as Vn, c7 as dt, c8 as D, c9 as xs, ca as cn, cb as Be, cc as ws, cd as qt, ce as zt, cf as $s, cg as Cs, ch as $n, ci as Ss, cj as Nr, ck as Bt, cl as zo, cm as ks, cn as Es, co as j, cp as Ur, cq as Ms, cr as Ds, cs as sr, ct as As, cu as Ts, cv as zn, cw as Fs, cx as Is, cy as Z, cz as Ps, cA as Ls } from "./index-BhY34I_M.js";
|
|
2
2
|
var Os = (e) => e != null, qs = (e) => e.filter(Os);
|
|
3
3
|
function _s(e) {
|
|
4
4
|
return (...t) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConsultationActionButton.d.ts","sourceRoot":"","sources":["../../../src/components/patientHeader/ConsultationActionButton.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,UAAU,6BAA6B;IACrC,mBAAmB,EAAE,OAAO,CAAC;IAC7B,mBAAmB,EAAE,OAAO,CAAC;IAC7B,SAAS,EAAE,OAAO,CAAC;CACpB;AAED,QAAA,MAAM,wBAAwB,EAAE,KAAK,CAAC,EAAE,CAAC,6BAA6B,
|
|
1
|
+
{"version":3,"file":"ConsultationActionButton.d.ts","sourceRoot":"","sources":["../../../src/components/patientHeader/ConsultationActionButton.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,UAAU,6BAA6B;IACrC,mBAAmB,EAAE,OAAO,CAAC;IAC7B,mBAAmB,EAAE,OAAO,CAAC;IAC7B,SAAS,EAAE,OAAO,CAAC;CACpB;AAED,QAAA,MAAM,wBAAwB,EAAE,KAAK,CAAC,EAAE,CAAC,6BAA6B,CA2CrE,CAAC;AAEF,eAAe,wBAAwB,CAAC"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import { u as g, X as u, bA as b, bK as f, bL as p, bM as _, aG as x, bG as N } from "./index-
|
|
2
|
+
import { u as g, X as u, bA as b, bK as f, bL as p, bM as _, aG as x, bG as N } from "./index-BhY34I_M.js";
|
|
3
3
|
import { lazy as h, useMemo as n, Suspense as E } from "react";
|
|
4
4
|
import "@tanstack/react-query";
|
|
5
|
-
import { u as L } from "./hook-
|
|
5
|
+
import { u as L } from "./hook-BWfIb4f3.js";
|
|
6
6
|
const C = {
|
|
7
7
|
"org.bahmni.clinical.v2.search": h(
|
|
8
|
-
() => import("./index-
|
|
8
|
+
() => import("./index-z3UC96oc.js")
|
|
9
9
|
)
|
|
10
10
|
}, v = "index-module_page__16xxw", A = "index-module_loading__wNI-4", H = "index-module_message__Ib5Iw", t = {
|
|
11
11
|
page: v,
|