@bahmni/clinical-app 0.0.1-dev.214 → 0.0.1-dev.215
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-E_qtt95j-DXwqWn7F.js → DocumentsTable-fzVaPEDf-fFFKu-FF.js} +41 -41
- package/dist/{FormsTable-BrfHufyk-ab4GOwxj.js → FormsTable-jpNE9pzC-BVjYSRui.js} +52 -52
- package/dist/{LNWAZHJI-DAiuGM1x.js → LNWAZHJI-i5jW2Uy3.js} +2 -2
- package/dist/{MWZ6AO7Z-C-VYO4Eu.js → MWZ6AO7Z-DKF7Y_I8.js} +2 -2
- package/dist/{Observations-MHo-cJ_h-C9z0eafD.js → Observations-CVJq7iSk-DAaeRcP9.js} +52 -52
- package/dist/{YPM2AS64-VWiA6anQ.js → YPM2AS64-CR0jV7JS.js} +1 -1
- package/dist/{index-7NvNeTHS.js → index-Bg9sK_PO.js} +31261 -31057
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsxs as S, jsx as u } from "react/jsx-runtime";
|
|
2
|
-
import { c as
|
|
3
|
-
import { useRef as se, useEffect as $, useMemo as
|
|
4
|
-
const A = (a,
|
|
5
|
-
const t = Z(a,
|
|
6
|
-
let
|
|
7
|
-
i === "Image" && (
|
|
2
|
+
import { c as V, e as w, u as N, o as x, q as K, a as M, w as P, l as Q, r as z, E as G, y as H, x as j, t as Y, v as q, z as Z, f as J, A as W, k as X, P as ee, B as ae, C as te } from "./index-Bg9sK_PO.js";
|
|
3
|
+
import { useRef as se, useEffect as $, useMemo as R } from "react";
|
|
4
|
+
const A = (a, o, d, l, b, r) => {
|
|
5
|
+
const t = Z(a, o, b), s = t.value, i = J(s);
|
|
6
|
+
let n = s;
|
|
7
|
+
i === "Image" && (n = /* @__PURE__ */ u(
|
|
8
8
|
X,
|
|
9
9
|
{
|
|
10
10
|
imageSrc: s,
|
|
@@ -12,22 +12,22 @@ const A = (a, n, d, l, b, r) => {
|
|
|
12
12
|
id: `${s}-img`,
|
|
13
13
|
hideThumbnail: r
|
|
14
14
|
}
|
|
15
|
-
)), i === "Video" && (
|
|
15
|
+
)), i === "Video" && (n = /* @__PURE__ */ u(
|
|
16
16
|
ee,
|
|
17
17
|
{
|
|
18
18
|
id: `${s}-video`,
|
|
19
19
|
videoSrc: s,
|
|
20
20
|
hideThumbnail: r
|
|
21
21
|
}
|
|
22
|
-
)), i === "PDF" && (
|
|
22
|
+
)), i === "PDF" && (n = /* @__PURE__ */ u(ae, { id: `${s}-pdf`, src: s }));
|
|
23
23
|
const p = b("OBSERVATIONS_RECORDED_BY", {
|
|
24
24
|
provider: t.provider
|
|
25
|
-
}), m = a.display, v = a.observationValue?.isAbnormal ? "abnormal-obs" : "obs", c = l ? `${l}-${v}-${m}-${d}-${
|
|
25
|
+
}), m = a.display, v = a.observationValue?.isAbnormal ? "abnormal-obs" : "obs", c = l ? `${l}-${v}-${m}-${d}-${o}` : `${v}-${m}-${d}-${o}`;
|
|
26
26
|
return /* @__PURE__ */ u(
|
|
27
27
|
W,
|
|
28
28
|
{
|
|
29
29
|
header: t.header,
|
|
30
|
-
value:
|
|
30
|
+
value: n,
|
|
31
31
|
info: p,
|
|
32
32
|
id: c,
|
|
33
33
|
testId: c,
|
|
@@ -35,8 +35,8 @@ const A = (a, n, d, l, b, r) => {
|
|
|
35
35
|
},
|
|
36
36
|
`obs-${a.id}`
|
|
37
37
|
);
|
|
38
|
-
}, re = (a,
|
|
39
|
-
|
|
38
|
+
}, re = (a, o, d, l, b, r, t) => /* @__PURE__ */ u(
|
|
39
|
+
q,
|
|
40
40
|
{
|
|
41
41
|
title: a.display,
|
|
42
42
|
id: `grouped-obs-${a.display}-${l}`,
|
|
@@ -47,7 +47,7 @@ const A = (a, n, d, l, b, r) => {
|
|
|
47
47
|
i,
|
|
48
48
|
b,
|
|
49
49
|
r,
|
|
50
|
-
|
|
50
|
+
o,
|
|
51
51
|
t
|
|
52
52
|
)
|
|
53
53
|
)
|
|
@@ -55,36 +55,36 @@ const A = (a, n, d, l, b, r) => {
|
|
|
55
55
|
`grouped-obs-${a.id}`
|
|
56
56
|
), ie = ({
|
|
57
57
|
groupedData: a,
|
|
58
|
-
title:
|
|
58
|
+
title: o = "",
|
|
59
59
|
hideThumbnail: d
|
|
60
60
|
}) => {
|
|
61
61
|
const { t: l } = N(), b = (r, t, s) => {
|
|
62
62
|
const i = Y(r.encounterDetails, l);
|
|
63
63
|
return /* @__PURE__ */ S(
|
|
64
|
-
|
|
64
|
+
q,
|
|
65
65
|
{
|
|
66
66
|
title: i,
|
|
67
67
|
id: `encounter-${r.encounterId}`,
|
|
68
68
|
open: t,
|
|
69
69
|
children: [
|
|
70
70
|
r.observations.map(
|
|
71
|
-
(
|
|
72
|
-
|
|
71
|
+
(n, p) => A(
|
|
72
|
+
n,
|
|
73
73
|
p,
|
|
74
74
|
s,
|
|
75
|
-
|
|
75
|
+
o,
|
|
76
76
|
l,
|
|
77
77
|
d
|
|
78
78
|
)
|
|
79
79
|
),
|
|
80
80
|
r.groupedObservations.map(
|
|
81
|
-
(
|
|
82
|
-
|
|
81
|
+
(n, p) => re(
|
|
82
|
+
n,
|
|
83
83
|
l,
|
|
84
84
|
t,
|
|
85
85
|
p,
|
|
86
86
|
s,
|
|
87
|
-
|
|
87
|
+
o,
|
|
88
88
|
d
|
|
89
89
|
)
|
|
90
90
|
)
|
|
@@ -104,15 +104,15 @@ const A = (a, n, d, l, b, r) => {
|
|
|
104
104
|
)
|
|
105
105
|
}
|
|
106
106
|
);
|
|
107
|
-
},
|
|
108
|
-
observations:
|
|
109
|
-
title:
|
|
110
|
-
}, de = (a) => ["conceptUuid", a], le = (a,
|
|
111
|
-
const
|
|
107
|
+
}, ne = "_observations_kfbhq_1", oe = "_title_kfbhq_12", I = {
|
|
108
|
+
observations: ne,
|
|
109
|
+
title: oe
|
|
110
|
+
}, de = (a) => ["conceptUuid", a], le = (a, o) => ["observations", a, ...o], pe = ({ config: a }) => {
|
|
111
|
+
const o = a, {
|
|
112
112
|
conceptNames: d = [],
|
|
113
113
|
conceptUuid: l = [],
|
|
114
114
|
hideThumbnail: b = !1
|
|
115
|
-
} =
|
|
115
|
+
} = o, r = se(/* @__PURE__ */ new Set()), t = V(), { addNotification: s } = w(), { t: i } = N(), n = x({
|
|
116
116
|
queries: d.map((e) => ({
|
|
117
117
|
queryKey: de(e),
|
|
118
118
|
queryFn: () => K(e),
|
|
@@ -120,50 +120,50 @@ const A = (a, n, d, l, b, r) => {
|
|
|
120
120
|
}))
|
|
121
121
|
});
|
|
122
122
|
$(() => {
|
|
123
|
-
|
|
123
|
+
n.forEach((e, h) => {
|
|
124
124
|
if (e.isError && !r.current.has(h)) {
|
|
125
|
-
const
|
|
125
|
+
const U = d[h];
|
|
126
126
|
s({
|
|
127
127
|
title: i("ERROR_DEFAULT_TITLE"),
|
|
128
|
-
message: i("ERROR_FETCHING_CONCEPT", { conceptName:
|
|
128
|
+
message: i("ERROR_FETCHING_CONCEPT", { conceptName: U }),
|
|
129
129
|
type: "error"
|
|
130
130
|
}), r.current.add(h);
|
|
131
131
|
} else e.isError || r.current.delete(h);
|
|
132
132
|
});
|
|
133
|
-
}, [
|
|
134
|
-
const p =
|
|
133
|
+
}, [n, d]);
|
|
134
|
+
const p = R(() => n.map((e) => e.data?.uuid).filter((e) => !!e), [n]), m = R(() => [.../* @__PURE__ */ new Set([...p, ...l])], [p, l]), v = R(() => d.length === 0 ? !0 : n.every((e) => !e.isLoading), [n, d.length]), {
|
|
135
135
|
data: c,
|
|
136
136
|
isLoading: D,
|
|
137
|
-
isError:
|
|
138
|
-
refetch:
|
|
139
|
-
} =
|
|
137
|
+
isError: T,
|
|
138
|
+
refetch: f
|
|
139
|
+
} = M({
|
|
140
140
|
queryKey: le(t, m),
|
|
141
141
|
queryFn: () => te(t, m),
|
|
142
142
|
enabled: !!t && m.length > 0 && v
|
|
143
143
|
});
|
|
144
|
-
|
|
144
|
+
P(
|
|
145
145
|
(e) => {
|
|
146
146
|
e.patientUUID === t && e.updatedConcepts.size > 0 && [...e.updatedConcepts.keys()].some(
|
|
147
147
|
(h) => m.includes(h)
|
|
148
|
-
) &&
|
|
148
|
+
) && f();
|
|
149
149
|
},
|
|
150
|
-
[t,
|
|
150
|
+
[t, f]
|
|
151
151
|
), $(() => {
|
|
152
|
-
|
|
152
|
+
T && s({
|
|
153
153
|
title: i("ERROR_DEFAULT_TITLE"),
|
|
154
154
|
message: i("ERROR_FETCHING_OBSERVATIONS"),
|
|
155
155
|
type: "error"
|
|
156
156
|
});
|
|
157
|
-
}, [
|
|
158
|
-
const
|
|
157
|
+
}, [T]);
|
|
158
|
+
const g = R(() => {
|
|
159
159
|
if (!c) return [];
|
|
160
|
-
const e =
|
|
161
|
-
return
|
|
162
|
-
}, [c]),
|
|
160
|
+
const e = Q(c), h = z(e);
|
|
161
|
+
return G(h);
|
|
162
|
+
}, [c]), F = [
|
|
163
163
|
{ key: "name", header: "name" },
|
|
164
164
|
{ key: "value", header: "value" },
|
|
165
165
|
{ key: "form", header: "form" }
|
|
166
|
-
], O = D || !v, _ =
|
|
166
|
+
], O = D || !v, _ = T && v, B = (!c || c.entry?.length === 0 || m.length === 0) && v, C = _ ? i("ERROR_FETCHING_OBSERVATIONS") : null, L = B ? i("NO_OBSERVATIONS_FOUND") : void 0, k = g.length > 0 && !O && !_, E = o.titleTranslationKey, y = E ? i(E) : "";
|
|
167
167
|
return /* @__PURE__ */ S(
|
|
168
168
|
"div",
|
|
169
169
|
{
|
|
@@ -173,7 +173,7 @@ const A = (a, n, d, l, b, r) => {
|
|
|
173
173
|
className: I.observations,
|
|
174
174
|
children: [
|
|
175
175
|
/* @__PURE__ */ u(
|
|
176
|
-
|
|
176
|
+
H,
|
|
177
177
|
{
|
|
178
178
|
id: "observations-title",
|
|
179
179
|
testId: E ? `observations-title-${y}` : "observations-title",
|
|
@@ -182,22 +182,22 @@ const A = (a, n, d, l, b, r) => {
|
|
|
182
182
|
children: /* @__PURE__ */ u("p", { children: y })
|
|
183
183
|
}
|
|
184
184
|
),
|
|
185
|
-
|
|
185
|
+
k ? /* @__PURE__ */ u(
|
|
186
186
|
ie,
|
|
187
187
|
{
|
|
188
|
-
groupedData:
|
|
188
|
+
groupedData: g,
|
|
189
189
|
title: y,
|
|
190
190
|
hideThumbnail: b
|
|
191
191
|
}
|
|
192
192
|
) : /* @__PURE__ */ u(
|
|
193
|
-
|
|
193
|
+
j,
|
|
194
194
|
{
|
|
195
|
-
headers:
|
|
195
|
+
headers: F,
|
|
196
196
|
rows: [],
|
|
197
197
|
ariaLabel: i("OBSERVATIONS"),
|
|
198
198
|
loading: O,
|
|
199
|
-
errorStateMessage:
|
|
200
|
-
emptyStateMessage:
|
|
199
|
+
errorStateMessage: C,
|
|
200
|
+
emptyStateMessage: L,
|
|
201
201
|
dataTestId: "observations-table"
|
|
202
202
|
}
|
|
203
203
|
)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { L as we, M as z, N as xt, O as B, J as q, K as y, Q as Ro, S as ye, U as R, V as _, W as k, X as N, Y as A, _ as bs, $ as ir, a0 as $e, a1 as U, a2 as Hn, a3 as Vn, a4 as dt, a5 as D, a6 as xs, a7 as cn, a8 as Be, a9 as ws, aa as qt, ab as zt, ac as $s, ad as Cs, ae as $n, af as Ss, ag as Nr, ah as Bt, ai as zo, aj as ks, ak as Es, al as j, am as Ur, an as Ms, ao as Ds, ap as sr, aq as As, ar as Ts, as as zn, at as Fs, au as Is, av as Z, aw as Ps, ax as Ls } from "./index-Bg9sK_PO.js";
|
|
2
2
|
var Os = (e) => e != null, qs = (e) => e.filter(Os);
|
|
3
3
|
function _s(e) {
|
|
4
4
|
return (...t) => {
|