@bahmni/home-app 0.0.1-dev.286 → 0.0.1-dev.289
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/{DocumentsTable-CTZvYQiU-dQz7AAJn.js → DocumentsTable-DXWkjdux-RKYyqPN1.js} +9 -9
- package/dist/{FormsTable-TGKGC2Zf-CTqSE0_z.js → FormsTable-DLJpQ6yJ-DD3aiVoh.js} +34 -34
- package/dist/{LNWAZHJI-Bx-LcIHq.js → LNWAZHJI-BIFXNcCx.js} +2 -2
- package/dist/{MWZ6AO7Z-BNiBaB3J.js → MWZ6AO7Z-CoKwDpSj.js} +2 -2
- package/dist/{Observations-DI0NQ7gj-C2cXb_cK.js → Observations-Dk1JBpvB-uRbMnmE_.js} +26 -26
- package/dist/{YPM2AS64-D2bkCIX_.js → YPM2AS64-C8712irf.js} +1 -1
- package/dist/{index-sPqBbGqo.js → index-B7zEVNJ0.js} +1 -1
- package/dist/{index-DdcPODBK.js → index-DcQlEVCH.js} +55 -55
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as r, jsxs as h, Fragment as x } from "react/jsx-runtime";
|
|
2
|
-
import { u as G, a as W, h as Y,
|
|
2
|
+
import { u as G, a as W, h as Y, k as J, w as X, m as Z, c as ee, n as te } from "./index-DcQlEVCH.js";
|
|
3
3
|
import { useQuery as ae } from "@tanstack/react-query";
|
|
4
4
|
import { useState as l, useCallback as _, useEffect as N, useMemo as p } 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 = {
|
|
@@ -18,7 +18,7 @@ const ne = "DocumentsTable-module_documentsTableBody__6iR3w", oe = "DocumentsTab
|
|
|
18
18
|
uploadedBy: "DOCUMENTS_UPLOADED_BY",
|
|
19
19
|
attachments: "DOCUMENTS_ATTACHMENTS"
|
|
20
20
|
};
|
|
21
|
-
function
|
|
21
|
+
function R(a) {
|
|
22
22
|
return !a || a.includes(":") ? "#" : `/openmrs/auth?requested_document=/document_images/${a}`;
|
|
23
23
|
}
|
|
24
24
|
function ie(a, g) {
|
|
@@ -33,12 +33,12 @@ const Te = [
|
|
|
33
33
|
"attachments",
|
|
34
34
|
"uploadedOn",
|
|
35
35
|
"uploadedBy"
|
|
36
|
-
], he = /\.(jpg|jpeg|png|gif|webp|bmp|svg)$/i,
|
|
36
|
+
], he = /\.(jpg|jpeg|png|gif|webp|bmp|svg)$/i, B = (a) => a.attachments.length > 0 ? a.attachments : a.documentUrl ? [{ url: a.documentUrl, contentType: a.contentType }] : [], fe = ({ config: a, encounterUuids: g }) => {
|
|
37
37
|
const [s, w] = l(!1), [o, U] = l(
|
|
38
38
|
null
|
|
39
|
-
), [
|
|
39
|
+
), [k, D] = l(
|
|
40
40
|
/* @__PURE__ */ new Set()
|
|
41
|
-
), E = G(), { t: n } = W(), { addNotification: L } = Y(),
|
|
41
|
+
), E = G(), { t: n } = W(), { addNotification: L } = Y(), $ = Number(a?.pageSize) || 5, [O, C] = l(1), [u, V] = l($), [F, A] = l(void 0), M = _((e) => {
|
|
42
42
|
U(e), w(!0);
|
|
43
43
|
}, []), H = _(() => {
|
|
44
44
|
w(!1), U(null), D(/* @__PURE__ */ new Set());
|
|
@@ -74,9 +74,9 @@ const Te = [
|
|
|
74
74
|
const e = new AbortController();
|
|
75
75
|
return (async () => {
|
|
76
76
|
if (!s || !o) return;
|
|
77
|
-
const t = /* @__PURE__ */ new Set(), m =
|
|
77
|
+
const t = /* @__PURE__ */ new Set(), m = B(o);
|
|
78
78
|
for (let c = 0; c < m.length; c++) {
|
|
79
|
-
const S =
|
|
79
|
+
const S = R(m[c].url);
|
|
80
80
|
try {
|
|
81
81
|
(await fetch(S, {
|
|
82
82
|
method: "HEAD",
|
|
@@ -104,7 +104,7 @@ const Te = [
|
|
|
104
104
|
})),
|
|
105
105
|
[f]
|
|
106
106
|
), T = p(
|
|
107
|
-
() => o ?
|
|
107
|
+
() => o ? B(o) : [],
|
|
108
108
|
[o]
|
|
109
109
|
), Q = _(
|
|
110
110
|
(e, t) => {
|
|
@@ -169,7 +169,7 @@ const Te = [
|
|
|
169
169
|
size: "lg",
|
|
170
170
|
testId: "document-view-modal",
|
|
171
171
|
children: /* @__PURE__ */ r("div", { className: d.documentViewerContainer, children: T.map((e, t) => {
|
|
172
|
-
const m =
|
|
172
|
+
const m = R(e.url), c = e.contentType?.toLowerCase().includes("pdf"), S = (e.contentType?.toLowerCase().includes("image") ?? !1) || he.test(e.url ?? ""), I = k.has(t);
|
|
173
173
|
return m === "#" || I ? /* @__PURE__ */ h(
|
|
174
174
|
"div",
|
|
175
175
|
{
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { jsx as s, jsxs as
|
|
2
|
-
import { a as ee, u as re, v as ae,
|
|
1
|
+
import { jsx as s, jsxs as W, Fragment as X } from "react/jsx-runtime";
|
|
2
|
+
import { a as ee, u as re, v as ae, Z as oe, S as te, I as se, $ as ne, e as de, _ as R, m as ie, w as me, c as q, O as ue, L as le, n as ce, q as fe, D as ye } from "./index-DcQlEVCH.js";
|
|
3
3
|
import { useQueryClient as be, useQuery as f } from "@tanstack/react-query";
|
|
4
4
|
import { useState as U, useMemo as d, useCallback as y } from "react";
|
|
5
5
|
const pe = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_customAccordianItem__isszs", A = {
|
|
@@ -13,21 +13,21 @@ const pe = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
|
|
|
13
13
|
config: H
|
|
14
14
|
}) => {
|
|
15
15
|
const { t } = ee(), u = re(), [l, O] = U(!1), [o, I] = U(null), {
|
|
16
|
-
numberOfVisits:
|
|
17
|
-
hideThumbnail:
|
|
16
|
+
numberOfVisits: w,
|
|
17
|
+
hideThumbnail: $ = !1,
|
|
18
18
|
forms: c
|
|
19
19
|
} = H ?? {}, L = ae(
|
|
20
20
|
m,
|
|
21
21
|
n
|
|
22
|
-
),
|
|
22
|
+
), k = be(), {
|
|
23
23
|
data: T = [],
|
|
24
24
|
isLoading: F,
|
|
25
25
|
isError: _,
|
|
26
|
-
error:
|
|
27
|
-
refetch:
|
|
26
|
+
error: K,
|
|
27
|
+
refetch: j
|
|
28
28
|
} = f({
|
|
29
29
|
queryKey: ["forms", u, m],
|
|
30
|
-
queryFn: () => oe(u, void 0,
|
|
30
|
+
queryFn: () => oe(u, void 0, w),
|
|
31
31
|
enabled: !!u && !L
|
|
32
32
|
}), v = d(() => {
|
|
33
33
|
let e = T;
|
|
@@ -39,15 +39,15 @@ const pe = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
|
|
|
39
39
|
}, [T, n, c]), { data: B = [] } = f({
|
|
40
40
|
queryKey: ["observationForms"],
|
|
41
41
|
queryFn: () => te()
|
|
42
|
-
}),
|
|
42
|
+
}), D = y(
|
|
43
43
|
(e) => B.find((r) => r.name === e)?.uuid,
|
|
44
44
|
[B]
|
|
45
45
|
), b = d(() => {
|
|
46
46
|
if (o)
|
|
47
|
-
return
|
|
48
|
-
}, [o,
|
|
49
|
-
isLoading:
|
|
50
|
-
isError:
|
|
47
|
+
return D(o.formName);
|
|
48
|
+
}, [o, D]), {
|
|
49
|
+
isLoading: x,
|
|
50
|
+
isError: V,
|
|
51
51
|
error: p
|
|
52
52
|
} = f({
|
|
53
53
|
queryKey: ["formMetadata", b],
|
|
@@ -65,36 +65,36 @@ const pe = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
|
|
|
65
65
|
});
|
|
66
66
|
de(
|
|
67
67
|
(e) => {
|
|
68
|
-
e.patientUUID === u && e.updatedConcepts.size > 0 && (
|
|
68
|
+
e.patientUUID === u && e.updatedConcepts.size > 0 && (j(), k.invalidateQueries({ queryKey: ["formsEncounterFHIR"] }));
|
|
69
69
|
},
|
|
70
70
|
[u]
|
|
71
71
|
);
|
|
72
72
|
const Q = d(() => !g?.entry || !o?.formName ? [] : g.entry.filter((e) => e.resource?.resourceType === "Observation").map((e) => e.resource).filter((e) => {
|
|
73
73
|
const r = Ne(e);
|
|
74
74
|
return !r || r.includes(o.formName);
|
|
75
|
-
}), [g, o?.formName]),
|
|
75
|
+
}), [g, o?.formName]), P = d(() => {
|
|
76
76
|
if (p)
|
|
77
|
-
return
|
|
77
|
+
return R(p).message;
|
|
78
78
|
if (N)
|
|
79
|
-
return
|
|
80
|
-
}, [p, N]),
|
|
79
|
+
return R(N).message;
|
|
80
|
+
}, [p, N]), E = d(
|
|
81
81
|
() => [
|
|
82
82
|
{ key: "recordedOn", header: t("RECORDED_ON") },
|
|
83
83
|
{ key: "recordedBy", header: t("RECORDED_BY") }
|
|
84
84
|
],
|
|
85
85
|
[t]
|
|
86
|
-
),
|
|
86
|
+
), Y = d(
|
|
87
87
|
() => [
|
|
88
88
|
{ key: "recordedOn", sortable: !0 },
|
|
89
89
|
{ key: "recordedBy", sortable: !0 }
|
|
90
90
|
],
|
|
91
91
|
[]
|
|
92
|
-
),
|
|
92
|
+
), M = d(() => {
|
|
93
93
|
const e = v.reduce(
|
|
94
94
|
(r, a) => {
|
|
95
95
|
const i = a.formName;
|
|
96
96
|
r[i] ??= [];
|
|
97
|
-
const h = a.providers.map((
|
|
97
|
+
const h = a.providers.map((J) => J.providerName).filter(Boolean).join(", ");
|
|
98
98
|
return r[i].push({
|
|
99
99
|
id: a.encounterUuid,
|
|
100
100
|
formName: a.formName,
|
|
@@ -116,7 +116,7 @@ const pe = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
|
|
|
116
116
|
).sort((r, a) => r.formName.localeCompare(a.formName));
|
|
117
117
|
}, [v, t]), S = y((e) => {
|
|
118
118
|
I(e), O(!0);
|
|
119
|
-
}, []),
|
|
119
|
+
}, []), Z = y(() => {
|
|
120
120
|
O(!1), I(null);
|
|
121
121
|
}, []), C = y(
|
|
122
122
|
(e, r) => {
|
|
@@ -131,21 +131,21 @@ const pe = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
|
|
|
131
131
|
},
|
|
132
132
|
[S]
|
|
133
133
|
);
|
|
134
|
-
return /* @__PURE__ */
|
|
135
|
-
/* @__PURE__ */ s("div", { id: "forms-table", "data-testid": "forms-table", children: F || _ ||
|
|
134
|
+
return /* @__PURE__ */ W(X, { children: [
|
|
135
|
+
/* @__PURE__ */ s("div", { id: "forms-table", "data-testid": "forms-table", children: F || _ || M.length === 0 || L ? /* @__PURE__ */ s(
|
|
136
136
|
q,
|
|
137
137
|
{
|
|
138
|
-
headers:
|
|
138
|
+
headers: E,
|
|
139
139
|
ariaLabel: t("FORMS_HEADING"),
|
|
140
140
|
rows: [],
|
|
141
141
|
loading: F,
|
|
142
|
-
errorStateMessage: _ ?
|
|
142
|
+
errorStateMessage: _ ? K?.message : void 0,
|
|
143
143
|
emptyStateMessage: t("FORMS_UNAVAILABLE"),
|
|
144
144
|
renderCell: C,
|
|
145
145
|
className: A.formsTableBody,
|
|
146
146
|
dataTestId: "forms-table"
|
|
147
147
|
}
|
|
148
|
-
) : /* @__PURE__ */ s(ue, { align: "start", children:
|
|
148
|
+
) : /* @__PURE__ */ s(ue, { align: "start", children: M.map((e, r) => {
|
|
149
149
|
const { formName: a, records: i } = e;
|
|
150
150
|
return /* @__PURE__ */ s(
|
|
151
151
|
le,
|
|
@@ -157,12 +157,12 @@ const pe = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
|
|
|
157
157
|
children: /* @__PURE__ */ s(
|
|
158
158
|
q,
|
|
159
159
|
{
|
|
160
|
-
headers:
|
|
160
|
+
headers: E,
|
|
161
161
|
ariaLabel: t("FORMS_HEADING"),
|
|
162
162
|
rows: i,
|
|
163
163
|
loading: !1,
|
|
164
164
|
errorStateMessage: "",
|
|
165
|
-
sortable:
|
|
165
|
+
sortable: Y,
|
|
166
166
|
emptyStateMessage: t("FORMS_UNAVAILABLE"),
|
|
167
167
|
renderCell: C,
|
|
168
168
|
className: A.formsTableBody,
|
|
@@ -179,7 +179,7 @@ const pe = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
|
|
|
179
179
|
id: "modalIdForActionAreaLayout",
|
|
180
180
|
portalId: "main-display-area",
|
|
181
181
|
open: l,
|
|
182
|
-
onRequestClose:
|
|
182
|
+
onRequestClose: Z,
|
|
183
183
|
modalHeading: o.formName,
|
|
184
184
|
modalLabel: `${o.recordedOn} | ${o.recordedBy}`,
|
|
185
185
|
passiveModal: !0,
|
|
@@ -189,12 +189,12 @@ const pe = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
|
|
|
189
189
|
fe,
|
|
190
190
|
{
|
|
191
191
|
observations: Q,
|
|
192
|
-
isLoading:
|
|
193
|
-
isError:
|
|
194
|
-
errorMessage:
|
|
192
|
+
isLoading: x || z,
|
|
193
|
+
isError: V || G,
|
|
194
|
+
errorMessage: P,
|
|
195
195
|
emptyStateMessage: t("NO_FORM_DATA_AVAILABLE"),
|
|
196
196
|
testIdPrefix: o.formName,
|
|
197
|
-
hideThumbnail:
|
|
197
|
+
hideThumbnail: $
|
|
198
198
|
}
|
|
199
199
|
)
|
|
200
200
|
}
|
|
@@ -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 {
|
|
1
|
+
import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-C8712irf.js";
|
|
2
|
+
import { P as d, Q as f, T as e } from "./index-DcQlEVCH.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 {
|
|
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-C8712irf.js";
|
|
2
|
+
import { P as v, Q as C, T as e } from "./index-DcQlEVCH.js";
|
|
3
3
|
var h = (t) => {
|
|
4
4
|
const [r, o] = s({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as I, jsx as u } from "react/jsx-runtime";
|
|
2
|
-
import { u as B, h as V, a as S,
|
|
2
|
+
import { u as B, h as V, a as S, b as w, R as j, e as k, W as z, d as Q, K as x, z as G, c as M, j as P, f as H, U as W, g as J, i as Y, H as X, l as Z, N as ee } from "./index-DcQlEVCH.js";
|
|
3
3
|
import { useQueries as ae, useQuery as te } from "@tanstack/react-query";
|
|
4
|
-
import { useRef as se, useEffect as
|
|
5
|
-
const
|
|
4
|
+
import { useRef as se, useEffect as $, useMemo as E } from "react";
|
|
5
|
+
const D = (a, n, d, l, b, r) => {
|
|
6
6
|
const t = W(a, n, b), s = t.value, o = J(s);
|
|
7
7
|
let i = s;
|
|
8
8
|
o === "Image" && (i = /* @__PURE__ */ u(
|
|
@@ -23,7 +23,7 @@ const H = (a, n, d, l, b, r) => {
|
|
|
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, y = a.observationValue?.isAbnormal ? "abnormal-obs" : "obs", c = l ? `${l}-${y}-${p}-${d}-${n}` : `${y}-${p}-${d}-${n}`;
|
|
27
27
|
return /* @__PURE__ */ u(
|
|
28
28
|
Y,
|
|
29
29
|
{
|
|
@@ -37,13 +37,13 @@ const H = (a, n, d, l, b, r) => {
|
|
|
37
37
|
`obs-${a.id}`
|
|
38
38
|
);
|
|
39
39
|
}, re = (a, n, d, l, b, r, t) => /* @__PURE__ */ u(
|
|
40
|
-
|
|
40
|
+
H,
|
|
41
41
|
{
|
|
42
42
|
title: a.display,
|
|
43
43
|
id: `grouped-obs-${a.display}-${l}`,
|
|
44
44
|
open: d,
|
|
45
45
|
children: a.members?.map(
|
|
46
|
-
(s, o) =>
|
|
46
|
+
(s, o) => D(
|
|
47
47
|
s,
|
|
48
48
|
o,
|
|
49
49
|
b,
|
|
@@ -62,14 +62,14 @@ const H = (a, n, d, l, b, r) => {
|
|
|
62
62
|
const { t: l } = S(), b = (r, t, s) => {
|
|
63
63
|
const o = P(r.encounterDetails, l);
|
|
64
64
|
return /* @__PURE__ */ I(
|
|
65
|
-
|
|
65
|
+
H,
|
|
66
66
|
{
|
|
67
67
|
title: o,
|
|
68
68
|
id: `encounter-${r.encounterId}`,
|
|
69
69
|
open: t,
|
|
70
70
|
children: [
|
|
71
71
|
r.observations.map(
|
|
72
|
-
(i, m) =>
|
|
72
|
+
(i, m) => D(
|
|
73
73
|
i,
|
|
74
74
|
m,
|
|
75
75
|
s,
|
|
@@ -120,7 +120,7 @@ const H = (a, n, d, l, b, r) => {
|
|
|
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
126
|
const q = d[h];
|
|
@@ -132,15 +132,15 @@ const H = (a, n, d, l, b, r) => {
|
|
|
132
132
|
} else e.isError || r.current.delete(h);
|
|
133
133
|
});
|
|
134
134
|
}, [i, d]);
|
|
135
|
-
const m =
|
|
135
|
+
const m = E(() => i.map((e) => e.data?.uuid).filter((e) => !!e), [i]), p = E(() => [.../* @__PURE__ */ new Set([...m, ...l])], [m, l]), y = E(() => d.length === 0 ? !0 : i.every((e) => !e.isLoading), [i, d.length]), {
|
|
136
136
|
data: c,
|
|
137
|
-
isLoading:
|
|
137
|
+
isLoading: L,
|
|
138
138
|
isError: T,
|
|
139
139
|
refetch: g
|
|
140
140
|
} = te({
|
|
141
141
|
queryKey: le(t, p),
|
|
142
|
-
queryFn: () =>
|
|
143
|
-
enabled: !!t && p.length > 0 &&
|
|
142
|
+
queryFn: () => j(t, p),
|
|
143
|
+
enabled: !!t && p.length > 0 && y
|
|
144
144
|
});
|
|
145
145
|
k(
|
|
146
146
|
(e) => {
|
|
@@ -149,54 +149,54 @@ const H = (a, n, d, l, b, r) => {
|
|
|
149
149
|
) && g();
|
|
150
150
|
},
|
|
151
151
|
[t, g]
|
|
152
|
-
),
|
|
152
|
+
), $(() => {
|
|
153
153
|
T && s({
|
|
154
154
|
title: o("ERROR_DEFAULT_TITLE"),
|
|
155
155
|
message: o("ERROR_FETCHING_OBSERVATIONS"),
|
|
156
156
|
type: "error"
|
|
157
157
|
});
|
|
158
158
|
}, [T]);
|
|
159
|
-
const O =
|
|
159
|
+
const O = E(() => {
|
|
160
160
|
if (!c) return [];
|
|
161
161
|
const e = z(c), h = Q(e);
|
|
162
162
|
return x(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
|
-
],
|
|
167
|
+
], f = L || !y, _ = T && y, U = (!c || c.entry?.length === 0 || p.length === 0) && y, A = _ ? o("ERROR_FETCHING_OBSERVATIONS") : null, K = U ? o("NO_OBSERVATIONS_FOUND") : void 0, C = O.length > 0 && !f && !_, R = n.titleTranslationKey, v = R ? o(R) : "";
|
|
168
168
|
return /* @__PURE__ */ I(
|
|
169
169
|
"div",
|
|
170
170
|
{
|
|
171
171
|
id: "observations",
|
|
172
|
-
"data-testid":
|
|
172
|
+
"data-testid": R ? `observations-${v}` : "observations",
|
|
173
173
|
"aria-label": "observations-aria-label",
|
|
174
174
|
className: N.observations,
|
|
175
175
|
children: [
|
|
176
176
|
/* @__PURE__ */ u(
|
|
177
|
-
|
|
177
|
+
G,
|
|
178
178
|
{
|
|
179
179
|
id: "observations-title",
|
|
180
|
-
testId:
|
|
181
|
-
title:
|
|
180
|
+
testId: R ? `observations-title-${v}` : "observations-title",
|
|
181
|
+
title: v,
|
|
182
182
|
className: N.title,
|
|
183
|
-
children: /* @__PURE__ */ u("p", { children:
|
|
183
|
+
children: /* @__PURE__ */ u("p", { children: v })
|
|
184
184
|
}
|
|
185
185
|
),
|
|
186
186
|
C ? /* @__PURE__ */ u(
|
|
187
187
|
oe,
|
|
188
188
|
{
|
|
189
189
|
groupedData: O,
|
|
190
|
-
title:
|
|
190
|
+
title: v,
|
|
191
191
|
hideThumbnail: b
|
|
192
192
|
}
|
|
193
193
|
) : /* @__PURE__ */ u(
|
|
194
|
-
|
|
194
|
+
M,
|
|
195
195
|
{
|
|
196
|
-
headers:
|
|
196
|
+
headers: F,
|
|
197
197
|
rows: [],
|
|
198
198
|
ariaLabel: o("OBSERVATIONS"),
|
|
199
|
-
loading:
|
|
199
|
+
loading: f,
|
|
200
200
|
errorStateMessage: A,
|
|
201
201
|
emptyStateMessage: K,
|
|
202
202
|
dataTestId: "observations-table"
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { V as we, Y as z, a0 as xt, a1 as B, Q as q, T as y, a2 as Ro, a3 as ye, a4 as R, a5 as _, a6 as k, a7 as N, a8 as A, a9 as bs, aa as ir, ab as $e, ac as G, ad as Hn, ae as Vn, af as dt, ag as D, ah as xs, ai as cn, aj as Be, ak as ws, al as qt, am as zt, an as $s, ao as Cs, ap as $n, aq as Ss, ar as Nr, as as Bt, at as zo, au as ks, av as Es, aw as j, ax as Gr, ay as Ms, az as Ds, aA as sr, aB as As, aC as Ts, aD as zn, aE as Fs, aF as Is, aG as Z, aH as Ps, aI as Ls } from "./index-DcQlEVCH.js";
|
|
2
2
|
var Os = (e) => e != null, qs = (e) => e.filter(Os);
|
|
3
3
|
function _s(e) {
|
|
4
4
|
return (...t) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs as Ne, jsx as ne, Fragment as Xi } from "react/jsx-runtime";
|
|
2
|
-
import { a as ot, C as Qi,
|
|
2
|
+
import { a as ot, C as Qi, o as Ji, r as ec, p as tc, s as rc, t as nc, x as oc, y as hi, A as ac, X as lc, h as ic, B as cc, E as sc, F as fc, M as pc, G as hc, J as uc } from "./index-DcQlEVCH.js";
|
|
3
3
|
import * as X from "react";
|
|
4
4
|
import r, { createContext as at, useContext as $e, Children as q1, useState as pe, useLayoutEffect as V1, useEffect as ie, useMemo as lt, useCallback as Me, useRef as oe, forwardRef as y1, useReducer as dc, cloneElement as G1, isValidElement as wc } from "react";
|
|
5
5
|
import { useQuery as mc } from "@tanstack/react-query";
|
|
@@ -163576,8 +163576,18 @@ hM.propTypes = dM.propTypes;
|
|
|
163576
163576
|
const Jt = () => {
|
|
163577
163577
|
const t = fqe();
|
|
163578
163578
|
return !t.patientUuid || t.patientUuid === "" ? null : t.patientUuid;
|
|
163579
|
-
}, Wje = R2(void 0),
|
|
163579
|
+
}, Wje = R2(void 0), uM = () => {
|
|
163580
163580
|
const t = se(Wje);
|
|
163581
|
+
if (!t)
|
|
163582
|
+
throw new Error(
|
|
163583
|
+
"useUserPrivilege must be used within a UserPrivilegeProvider"
|
|
163584
|
+
);
|
|
163585
|
+
return t;
|
|
163586
|
+
}, pM = (t) => {
|
|
163587
|
+
const { userPrivileges: e } = uM();
|
|
163588
|
+
return KE(e, t);
|
|
163589
|
+
}, Kje = R2(void 0), Yr = () => {
|
|
163590
|
+
const t = se(Kje);
|
|
163581
163591
|
if (!t)
|
|
163582
163592
|
throw new Error(
|
|
163583
163593
|
"useNotification must be used within a NotificationProvider"
|
|
@@ -163590,7 +163600,7 @@ const Jt = () => {
|
|
|
163590
163600
|
t(e);
|
|
163591
163601
|
});
|
|
163592
163602
|
}, [t]), null;
|
|
163593
|
-
},
|
|
163603
|
+
}, Gje = n.memo(({ children: t }) => {
|
|
163594
163604
|
const [e, r] = v1([]), o = G1(() => /* @__PURE__ */ new Map(), []), a = _1(
|
|
163595
163605
|
(i) => {
|
|
163596
163606
|
const s = gL0();
|
|
@@ -163620,7 +163630,7 @@ const Jt = () => {
|
|
|
163620
163630
|
}), () => {
|
|
163621
163631
|
o.forEach((i) => clearTimeout(i)), o.clear();
|
|
163622
163632
|
}), [e, c, o]), /* @__PURE__ */ ce(
|
|
163623
|
-
|
|
163633
|
+
Kje.Provider,
|
|
163624
163634
|
{
|
|
163625
163635
|
value: {
|
|
163626
163636
|
notifications: e,
|
|
@@ -163641,18 +163651,8 @@ const Jt = () => {
|
|
|
163641
163651
|
}
|
|
163642
163652
|
);
|
|
163643
163653
|
});
|
|
163644
|
-
|
|
163645
|
-
const
|
|
163646
|
-
const t = se(Gje);
|
|
163647
|
-
if (!t)
|
|
163648
|
-
throw new Error(
|
|
163649
|
-
"useUserPrivilege must be used within a UserPrivilegeProvider"
|
|
163650
|
-
);
|
|
163651
|
-
return t;
|
|
163652
|
-
}, pM = (t) => {
|
|
163653
|
-
const { userPrivileges: e } = uM();
|
|
163654
|
-
return KE(e, t);
|
|
163655
|
-
}, JP0 = "AllergiesTable-module_mildSeverity__NCNu-", QP0 = "AllergiesTable-module_moderateSeverity__lsUlB", XP0 = "AllergiesTable-module_severeSeverity__amsyH", ej0 = "AllergiesTable-module_allergyName__eTq4L", tj0 = "AllergiesTable-module_allergyCategory__8KWd5", rj0 = "AllergiesTable-module_activeStatus__Lvg78", nj0 = "AllergiesTable-module_inactiveStatus__7iadA", oj0 = "AllergiesTable-module_allergiesTableBody__Fqg2Z", aj0 = "AllergiesTable-module_allergiesTableWrapper__Jxpwd", sn = {
|
|
163654
|
+
Gje.displayName = "NotificationProvider";
|
|
163655
|
+
const JP0 = "AllergiesTable-module_mildSeverity__NCNu-", QP0 = "AllergiesTable-module_moderateSeverity__lsUlB", XP0 = "AllergiesTable-module_severeSeverity__amsyH", ej0 = "AllergiesTable-module_allergyName__eTq4L", tj0 = "AllergiesTable-module_allergyCategory__8KWd5", rj0 = "AllergiesTable-module_activeStatus__Lvg78", nj0 = "AllergiesTable-module_inactiveStatus__7iadA", oj0 = "AllergiesTable-module_allergiesTableBody__Fqg2Z", aj0 = "AllergiesTable-module_allergiesTableWrapper__Jxpwd", sn = {
|
|
163656
163656
|
mildSeverity: JP0,
|
|
163657
163657
|
moderateSeverity: QP0,
|
|
163658
163658
|
severeSeverity: XP0,
|
|
@@ -169322,7 +169322,7 @@ const XW0 = async (t) => (await hje(t, "completed")).map(JW0), exe = ({
|
|
|
169322
169322
|
}),
|
|
169323
169323
|
[e, o, c]
|
|
169324
169324
|
);
|
|
169325
|
-
return /* @__PURE__ */ d1(
|
|
169325
|
+
return /* @__PURE__ */ d1(Wje.Provider, { value: i, children: t });
|
|
169326
169326
|
};
|
|
169327
169327
|
HFe.displayName = "UserPrivilegeProvider";
|
|
169328
169328
|
const xFe = R2(void 0), bFe = ({ children: t }) => {
|
|
@@ -169374,7 +169374,7 @@ const iJ0 = () => {
|
|
|
169374
169374
|
);
|
|
169375
169375
|
return t;
|
|
169376
169376
|
};
|
|
169377
|
-
B0(() => Promise.resolve().then(() => fj0)), B0(() => Promise.resolve().then(() => Ij0)), B0(() => Promise.resolve().then(() => gF0)), B0(() => Promise.resolve().then(() => xF0)), B0(() => import("./DocumentsTable-
|
|
169377
|
+
B0(() => Promise.resolve().then(() => fj0)), B0(() => Promise.resolve().then(() => Ij0)), B0(() => Promise.resolve().then(() => gF0)), B0(() => Promise.resolve().then(() => xF0)), B0(() => import("./DocumentsTable-DXWkjdux-RKYyqPN1.js")), B0(() => Promise.resolve().then(() => MW0)), B0(() => import("./FormsTable-DLJpQ6yJ-DD3aiVoh.js")), B0(() => Promise.resolve().then(() => tW0)), B0(() => import("./Observations-Dk1JBpvB-uRbMnmE_.js")), B0(
|
|
169378
169378
|
() => Promise.resolve().then(() => AW0)
|
|
169379
169379
|
), B0(
|
|
169380
169380
|
() => Promise.resolve().then(() => zU0)
|
|
@@ -171310,7 +171310,7 @@ var TJ0 = (t, e = !1) => {
|
|
|
171310
171310
|
const e = FFe(() => {
|
|
171311
171311
|
const r = this, [o] = this.#n, [a] = this.#o, [c] = this.#a, [l] = this.#c, [i] = this.#p, [s] = this.#t;
|
|
171312
171312
|
let d;
|
|
171313
|
-
return this.#l ? d = this.#l : (d = PFe(() => import("./LNWAZHJI-
|
|
171313
|
+
return this.#l ? d = this.#l : (d = PFe(() => import("./LNWAZHJI-BIFXNcCx.js")), this.#l = d), sqe(this.#u, this.#r), BFe(d, IFe({
|
|
171314
171314
|
get queryFlavor() {
|
|
171315
171315
|
return r.#d;
|
|
171316
171316
|
},
|
|
@@ -171408,7 +171408,7 @@ var TJ0 = (t, e = !1) => {
|
|
|
171408
171408
|
const e = FFe(() => {
|
|
171409
171409
|
const r = this, [o] = this.#n, [a] = this.#o, [c] = this.#a, [l] = this.#c, [i] = this.#p, [s] = this.#t, [d] = this.#l;
|
|
171410
171410
|
let h;
|
|
171411
|
-
return this.#i ? h = this.#i : (h = PFe(() => import("./MWZ6AO7Z-
|
|
171411
|
+
return this.#i ? h = this.#i : (h = PFe(() => import("./MWZ6AO7Z-CoKwDpSj.js")), this.#i = h), sqe(this.#u, this.#r), BFe(h, IFe({
|
|
171412
171412
|
get queryFlavor() {
|
|
171413
171413
|
return r.#d;
|
|
171414
171414
|
},
|
|
@@ -171538,7 +171538,7 @@ const SG0 = {
|
|
|
171538
171538
|
}
|
|
171539
171539
|
}
|
|
171540
171540
|
}, ZG0 = "home", ZJ0 = "/bahmni/home/index.html#/login", kJ0 = "/bahmni/home/index.html#/changePassword", BJ0 = 6, kG0 = B0(
|
|
171541
|
-
() => import("./index-
|
|
171541
|
+
() => import("./index-B7zEVNJ0.js").then((t) => ({
|
|
171542
171542
|
default: t.HomePage
|
|
171543
171543
|
}))
|
|
171544
171544
|
), BG0 = [
|
|
@@ -171561,40 +171561,40 @@ function IJ0() {
|
|
|
171561
171561
|
console.error("Failed to initialize app:", o), e(!0);
|
|
171562
171562
|
}
|
|
171563
171563
|
})();
|
|
171564
|
-
}, []), t ? /* @__PURE__ */ d1(pqe, { client: PG0, children: /* @__PURE__ */ d1(bFe, { children: /* @__PURE__ */ d1(HFe, { children: /* @__PURE__ */ d1(
|
|
171564
|
+
}, []), t ? /* @__PURE__ */ d1(pqe, { client: PG0, children: /* @__PURE__ */ d1(bFe, { children: /* @__PURE__ */ d1(HFe, { children: /* @__PURE__ */ d1(Gje, { children: /* @__PURE__ */ ce(aK0, { children: [
|
|
171565
171565
|
/* @__PURE__ */ d1(YP0, {}),
|
|
171566
171566
|
/* @__PURE__ */ d1(dqe, { fallback: /* @__PURE__ */ d1(Ep1, {}), children: /* @__PURE__ */ d1(wqe, { children: IG0(BG0) }) }),
|
|
171567
171567
|
/* @__PURE__ */ d1(RG0, { initialIsOpen: !1 })
|
|
171568
171568
|
] }) }) }) }) }) : /* @__PURE__ */ d1(Ep1, {});
|
|
171569
171569
|
}
|
|
171570
171570
|
export {
|
|
171571
|
-
|
|
171572
|
-
|
|
171573
|
-
|
|
171571
|
+
QY0 as $,
|
|
171572
|
+
eY0 as A,
|
|
171573
|
+
kJ0 as B,
|
|
171574
171574
|
QG0 as C,
|
|
171575
|
-
|
|
171576
|
-
|
|
171577
|
-
|
|
171578
|
-
|
|
171575
|
+
YY0 as D,
|
|
171576
|
+
LY0 as E,
|
|
171577
|
+
ZJ0 as F,
|
|
171578
|
+
UU2 as G,
|
|
171579
171579
|
Lx0 as H,
|
|
171580
|
-
|
|
171581
|
-
|
|
171582
|
-
|
|
171580
|
+
eJ0 as I,
|
|
171581
|
+
sJ0 as J,
|
|
171582
|
+
lJ0 as K,
|
|
171583
171583
|
Nl as L,
|
|
171584
171584
|
Xu as M,
|
|
171585
171585
|
$x0 as N,
|
|
171586
171586
|
bl as O,
|
|
171587
|
-
|
|
171588
|
-
|
|
171589
|
-
|
|
171590
|
-
|
|
171591
|
-
|
|
171592
|
-
|
|
171593
|
-
|
|
171594
|
-
|
|
171595
|
-
|
|
171587
|
+
SJ0 as P,
|
|
171588
|
+
h0 as Q,
|
|
171589
|
+
JY0 as R,
|
|
171590
|
+
XY0 as S,
|
|
171591
|
+
BFe as T,
|
|
171592
|
+
oJ0 as U,
|
|
171593
|
+
fJ0 as V,
|
|
171594
|
+
aJ0 as W,
|
|
171595
|
+
iJ0 as X,
|
|
171596
171596
|
W2 as Y,
|
|
171597
|
-
|
|
171597
|
+
tJ0 as Z,
|
|
171598
171598
|
K0 as _,
|
|
171599
171599
|
J2 as a,
|
|
171600
171600
|
mK0 as a0,
|
|
@@ -171643,29 +171643,29 @@ export {
|
|
|
171643
171643
|
Z3 as ax,
|
|
171644
171644
|
LG0 as ay,
|
|
171645
171645
|
gJ0 as az,
|
|
171646
|
-
|
|
171646
|
+
GY0 as b,
|
|
171647
171647
|
p0 as c,
|
|
171648
|
-
|
|
171648
|
+
cJ0 as d,
|
|
171649
171649
|
Kr as e,
|
|
171650
|
-
|
|
171651
|
-
|
|
171650
|
+
_Y0 as f,
|
|
171651
|
+
ML0 as g,
|
|
171652
171652
|
Yr as h,
|
|
171653
|
-
|
|
171654
|
-
|
|
171655
|
-
|
|
171656
|
-
|
|
171653
|
+
QH0 as i,
|
|
171654
|
+
nJ0 as j,
|
|
171655
|
+
rJ0 as k,
|
|
171656
|
+
Bx0 as l,
|
|
171657
171657
|
z2 as m,
|
|
171658
171658
|
Ht as n,
|
|
171659
|
-
|
|
171660
|
-
|
|
171659
|
+
nE2 as o,
|
|
171660
|
+
GG0 as p,
|
|
171661
171661
|
uFe as q,
|
|
171662
171662
|
yw as r,
|
|
171663
|
-
|
|
171664
|
-
|
|
171663
|
+
uM as s,
|
|
171664
|
+
CY0 as t,
|
|
171665
171665
|
Jt as u,
|
|
171666
171666
|
s7 as v,
|
|
171667
171667
|
gs as w,
|
|
171668
|
-
|
|
171669
|
-
|
|
171668
|
+
BJ0 as x,
|
|
171669
|
+
XG0 as y,
|
|
171670
171670
|
q9 as z
|
|
171671
171671
|
};
|
package/dist/index.js
CHANGED