@bahmni/appointments-app 0.0.1-dev.238 → 0.0.1-dev.239
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-1XgzVmNY-m8gJhwm3.js → DocumentsTable-CD-yiYOH-CaZC2lNo.js} +8 -8
- package/dist/{FormsTable-B0J51cB5-Dmmq1xJr.js → FormsTable-DJ3FB7TZ-B2icb6hy.js} +23 -23
- package/dist/{LNWAZHJI-COLIfjgg.js → LNWAZHJI-BAiuHiUo.js} +2 -2
- package/dist/{MWZ6AO7Z-h5adSN6d.js → MWZ6AO7Z-jgVZJkt6.js} +2 -2
- package/dist/{Observations-Cqov9775-N4ieiWsF.js → Observations-DG-3eskL-XQsSDppm.js} +27 -27
- package/dist/{YPM2AS64-B2URhxvI.js → YPM2AS64-cFpTk2Qz.js} +1 -1
- package/dist/{index-BXQ5u6yw.js → index-CiSdLjcg.js} +373 -372
- package/dist/{index-BoEx0_Jv.js → index-Kv6M5X-7.js} +17 -17
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as r, jsxs as p, Fragment as Y } from "react/jsx-runtime";
|
|
2
|
-
import { t as K, u as Q, r as W, a as J, N as X, d as Z, o as ee, l as te,
|
|
2
|
+
import { t as K, u as Q, r as W, a as J, N as X, d as Z, o as ee, l as te, H as ae } from "./index-CiSdLjcg.js";
|
|
3
3
|
import { useState as l, useCallback as h, useEffect as f, useMemo as T } from "react";
|
|
4
4
|
const ne = "_documentsTableBody_1voj8_1", oe = "_viewAttachmentsLink_1voj8_11", re = "_documentViewerContainer_1voj8_15", de = "_attachmentItem_1voj8_23", se = "_attachmentCounter_1voj8_27", ce = "_attachmentError_1voj8_36", ie = "_documentIframe_1voj8_44", le = "_documentImage_1voj8_50", d = {
|
|
5
5
|
documentsTableBody: ne,
|
|
@@ -37,13 +37,13 @@ const _e = [
|
|
|
37
37
|
null
|
|
38
38
|
), [R, I] = l(
|
|
39
39
|
/* @__PURE__ */ new Set()
|
|
40
|
-
), E = K(), { t: n } = Q(), { addNotification: U } = W(), $ = Number(a?.pageSize) || 5, [C, A] = l(1), [m,
|
|
40
|
+
), E = K(), { t: n } = Q(), { addNotification: U } = W(), $ = Number(a?.pageSize) || 5, [C, A] = l(1), [m, k] = l($), [H, y] = l(void 0), M = h((e) => {
|
|
41
41
|
L(e), w(!0);
|
|
42
|
-
}, []),
|
|
42
|
+
}, []), V = h(() => {
|
|
43
43
|
w(!1), L(null), I(/* @__PURE__ */ new Set());
|
|
44
44
|
}, []), b = h((e) => {
|
|
45
45
|
I((t) => new Set(t).add(e));
|
|
46
|
-
}, []), { data: u, isLoading:
|
|
46
|
+
}, []), { data: u, isLoading: F, isError: D, error: v } = J({
|
|
47
47
|
queryKey: [
|
|
48
48
|
"documents",
|
|
49
49
|
E,
|
|
@@ -90,7 +90,7 @@ const _e = [
|
|
|
90
90
|
}, [s, o]);
|
|
91
91
|
const q = h(
|
|
92
92
|
(e, t) => {
|
|
93
|
-
t !== m ? (
|
|
93
|
+
t !== m ? (k(t), A(1), y(void 0)) : A(e);
|
|
94
94
|
},
|
|
95
95
|
[m]
|
|
96
96
|
), N = T(
|
|
@@ -143,7 +143,7 @@ const _e = [
|
|
|
143
143
|
headers: z,
|
|
144
144
|
ariaLabel: n("DOCUMENTS_TABLE_HEADING"),
|
|
145
145
|
rows: P,
|
|
146
|
-
loading:
|
|
146
|
+
loading: F,
|
|
147
147
|
errorStateMessage: D ? v?.message : null,
|
|
148
148
|
sortable: x,
|
|
149
149
|
emptyStateMessage: n("DOCUMENTS_NO_RECORDS"),
|
|
@@ -151,7 +151,7 @@ const _e = [
|
|
|
151
151
|
className: d.documentsTableBody,
|
|
152
152
|
dataTestId: "documents-table",
|
|
153
153
|
pageSize: m,
|
|
154
|
-
totalItems:
|
|
154
|
+
totalItems: H,
|
|
155
155
|
page: C,
|
|
156
156
|
onPageChange: q
|
|
157
157
|
}
|
|
@@ -162,7 +162,7 @@ const _e = [
|
|
|
162
162
|
id: "modalIdForActionAreaLayout",
|
|
163
163
|
portalId: "main-display-area",
|
|
164
164
|
open: s,
|
|
165
|
-
onRequestClose:
|
|
165
|
+
onRequestClose: V,
|
|
166
166
|
modalHeading: o.documentIdentifier,
|
|
167
167
|
passiveModal: !0,
|
|
168
168
|
size: "lg",
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
import { jsx as s, jsxs as J, Fragment as W } from "react/jsx-runtime";
|
|
2
|
-
import { u as Z, t as ee, g as re, b as ae, a as c, B as te,
|
|
2
|
+
import { u as Z, t as ee, g as re, b as ae, a as c, B as te, V as U, d as oe, N as se, o as S, Q as ne, X as de, l as ie, c as ue, w as me, e as le, E as ce, y as fe, v as ye } from "./index-CiSdLjcg.js";
|
|
3
3
|
import { useState as q, useMemo as d, useCallback as f } from "react";
|
|
4
4
|
const be = "_formsTableBody_81hra_1", ge = "_customAccordianItem_81hra_6", I = {
|
|
5
5
|
formsTableBody: be,
|
|
6
6
|
customAccordianItem: ge
|
|
7
|
-
}, Ne = (
|
|
8
|
-
(n) => n.url ===
|
|
7
|
+
}, Ne = (u) => u ? u.extension?.find(
|
|
8
|
+
(n) => n.url === me
|
|
9
9
|
)?.valueString : void 0, Oe = ({
|
|
10
|
-
episodeOfCareUuids:
|
|
10
|
+
episodeOfCareUuids: u,
|
|
11
11
|
encounterUuids: n,
|
|
12
12
|
config: C
|
|
13
13
|
}) => {
|
|
14
|
-
const { t: o } = Z(),
|
|
15
|
-
|
|
14
|
+
const { t: o } = Z(), m = ee(), [l, O] = q(!1), [t, A] = q(null), { numberOfVisits: V, hideThumbnail: k = !1 } = C ?? {}, B = re(
|
|
15
|
+
u,
|
|
16
16
|
n
|
|
17
|
-
),
|
|
17
|
+
), w = ae(), {
|
|
18
18
|
data: y = [],
|
|
19
19
|
isLoading: E,
|
|
20
20
|
isError: T,
|
|
21
|
-
error:
|
|
22
|
-
refetch:
|
|
21
|
+
error: H,
|
|
22
|
+
refetch: K
|
|
23
23
|
} = c({
|
|
24
|
-
queryKey: ["forms",
|
|
25
|
-
queryFn: () => le(
|
|
26
|
-
enabled: !!
|
|
24
|
+
queryKey: ["forms", m, u],
|
|
25
|
+
queryFn: () => le(m, void 0, V),
|
|
26
|
+
enabled: !!m && !B
|
|
27
27
|
}), F = d(() => !n || n.length === 0 ? y : y.filter(
|
|
28
28
|
(e) => n.includes(e.encounterUuid)
|
|
29
29
|
), [y, n]), { data: _ = [] } = c({
|
|
@@ -36,8 +36,8 @@ const be = "_formsTableBody_81hra_1", ge = "_customAccordianItem_81hra_6", I = {
|
|
|
36
36
|
if (t)
|
|
37
37
|
return v(t.formName);
|
|
38
38
|
}, [t, v]), {
|
|
39
|
-
isLoading:
|
|
40
|
-
isError:
|
|
39
|
+
isLoading: Q,
|
|
40
|
+
isError: j,
|
|
41
41
|
error: g
|
|
42
42
|
} = c({
|
|
43
43
|
queryKey: ["formMetadata", b],
|
|
@@ -45,8 +45,8 @@ const be = "_formsTableBody_81hra_1", ge = "_customAccordianItem_81hra_6", I = {
|
|
|
45
45
|
enabled: !!b && l
|
|
46
46
|
}), {
|
|
47
47
|
data: N,
|
|
48
|
-
isLoading:
|
|
49
|
-
isError:
|
|
48
|
+
isLoading: x,
|
|
49
|
+
isError: $,
|
|
50
50
|
error: p
|
|
51
51
|
} = c({
|
|
52
52
|
queryKey: ["formsEncounterFHIR", t?.encounterUuid],
|
|
@@ -55,9 +55,9 @@ const be = "_formsTableBody_81hra_1", ge = "_customAccordianItem_81hra_6", I = {
|
|
|
55
55
|
});
|
|
56
56
|
te(
|
|
57
57
|
(e) => {
|
|
58
|
-
e.patientUUID ===
|
|
58
|
+
e.patientUUID === m && e.updatedConcepts.size > 0 && (K(), w.invalidateQueries({ queryKey: ["formsEncounterFHIR"] }));
|
|
59
59
|
},
|
|
60
|
-
[
|
|
60
|
+
[m]
|
|
61
61
|
);
|
|
62
62
|
const z = d(() => !N?.entry || !t?.formName ? [] : N.entry.filter((e) => e.resource?.resourceType === "Observation").map((e) => e.resource).filter((e) => {
|
|
63
63
|
const r = Ne(e);
|
|
@@ -129,7 +129,7 @@ const be = "_formsTableBody_81hra_1", ge = "_customAccordianItem_81hra_6", I = {
|
|
|
129
129
|
ariaLabel: o("FORMS_HEADING"),
|
|
130
130
|
rows: [],
|
|
131
131
|
loading: E,
|
|
132
|
-
errorStateMessage: T ?
|
|
132
|
+
errorStateMessage: T ? H?.message : void 0,
|
|
133
133
|
emptyStateMessage: o("FORMS_UNAVAILABLE"),
|
|
134
134
|
renderCell: R,
|
|
135
135
|
className: I.formsTableBody,
|
|
@@ -176,15 +176,15 @@ const be = "_formsTableBody_81hra_1", ge = "_customAccordianItem_81hra_6", I = {
|
|
|
176
176
|
size: "md",
|
|
177
177
|
testId: "form-details-modal",
|
|
178
178
|
children: /* @__PURE__ */ s(
|
|
179
|
-
|
|
179
|
+
ue,
|
|
180
180
|
{
|
|
181
181
|
observations: z,
|
|
182
|
-
isLoading:
|
|
183
|
-
isError:
|
|
182
|
+
isLoading: Q || x,
|
|
183
|
+
isError: j || $,
|
|
184
184
|
errorMessage: G,
|
|
185
185
|
emptyStateMessage: o("NO_FORM_DATA_AVAILABLE"),
|
|
186
186
|
testIdPrefix: t.formName,
|
|
187
|
-
hideThumbnail:
|
|
187
|
+
hideThumbnail: k
|
|
188
188
|
}
|
|
189
189
|
)
|
|
190
190
|
}
|
|
@@ -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-cFpTk2Qz.js";
|
|
2
|
+
import { S as d, W as f, Z as e } from "./index-CiSdLjcg.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-cFpTk2Qz.js";
|
|
2
|
+
import { S as v, W as C, Z as e } from "./index-CiSdLjcg.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 N, jsx as u } from "react/jsx-runtime";
|
|
2
|
-
import { t as V, r as
|
|
2
|
+
import { t as V, r as x, u as S, f as K, m as Q, a as Y, B as j, z as w, A as z, _ as G, Y as H, o as M, x as J, J as F, h as P, i as W, F as X, j as Z, T as ee, k as ae, n as te } from "./index-CiSdLjcg.js";
|
|
3
3
|
import { useRef as se, useEffect as $, useMemo as T } from "react";
|
|
4
4
|
const A = (a, n, d, l, b, r) => {
|
|
5
|
-
const t =
|
|
5
|
+
const t = P(a, n, b), s = t.value, i = W(s);
|
|
6
6
|
let o = s;
|
|
7
7
|
i === "Image" && (o = /* @__PURE__ */ u(
|
|
8
8
|
Z,
|
|
@@ -20,15 +20,15 @@ const A = (a, n, d, l, b, r) => {
|
|
|
20
20
|
hideThumbnail: r
|
|
21
21
|
}
|
|
22
22
|
)), i === "PDF" && (o = /* @__PURE__ */ u(ae, { id: `${s}-pdf`, src: s }));
|
|
23
|
-
const
|
|
23
|
+
const m = b("OBSERVATIONS_RECORDED_BY", {
|
|
24
24
|
provider: t.provider
|
|
25
|
-
}),
|
|
25
|
+
}), p = a.display, y = a.observationValue?.isAbnormal ? "abnormal-obs" : "obs", c = l ? `${l}-${y}-${p}-${d}-${n}` : `${y}-${p}-${d}-${n}`;
|
|
26
26
|
return /* @__PURE__ */ u(
|
|
27
27
|
X,
|
|
28
28
|
{
|
|
29
29
|
header: t.header,
|
|
30
30
|
value: o,
|
|
31
|
-
info:
|
|
31
|
+
info: m,
|
|
32
32
|
id: c,
|
|
33
33
|
testId: c,
|
|
34
34
|
ariaLabel: c
|
|
@@ -59,7 +59,7 @@ const A = (a, n, d, l, b, r) => {
|
|
|
59
59
|
hideThumbnail: d
|
|
60
60
|
}) => {
|
|
61
61
|
const { t: l } = S(), b = (r, t, s) => {
|
|
62
|
-
const i =
|
|
62
|
+
const i = J(r.encounterDetails, l);
|
|
63
63
|
return /* @__PURE__ */ N(
|
|
64
64
|
F,
|
|
65
65
|
{
|
|
@@ -68,9 +68,9 @@ const A = (a, n, d, l, b, r) => {
|
|
|
68
68
|
open: t,
|
|
69
69
|
children: [
|
|
70
70
|
r.observations.map(
|
|
71
|
-
(o,
|
|
71
|
+
(o, m) => A(
|
|
72
72
|
o,
|
|
73
|
-
|
|
73
|
+
m,
|
|
74
74
|
s,
|
|
75
75
|
n,
|
|
76
76
|
l,
|
|
@@ -78,11 +78,11 @@ const A = (a, n, d, l, b, r) => {
|
|
|
78
78
|
)
|
|
79
79
|
),
|
|
80
80
|
r.groupedObservations.map(
|
|
81
|
-
(o,
|
|
81
|
+
(o, m) => re(
|
|
82
82
|
o,
|
|
83
83
|
l,
|
|
84
84
|
t,
|
|
85
|
-
|
|
85
|
+
m,
|
|
86
86
|
s,
|
|
87
87
|
n,
|
|
88
88
|
d
|
|
@@ -107,15 +107,15 @@ const A = (a, n, d, l, b, r) => {
|
|
|
107
107
|
}, oe = "_observations_kfbhq_1", ne = "_title_kfbhq_12", I = {
|
|
108
108
|
observations: oe,
|
|
109
109
|
title: ne
|
|
110
|
-
}, de = (a) => ["conceptUuid", a], le = (a, n) => ["observations", a, ...n],
|
|
110
|
+
}, de = (a) => ["conceptUuid", a], le = (a, n) => ["observations", a, ...n], me = ({ config: a }) => {
|
|
111
111
|
const n = a, {
|
|
112
112
|
conceptNames: d = [],
|
|
113
113
|
conceptUuid: l = [],
|
|
114
114
|
hideThumbnail: b = !1
|
|
115
|
-
} = n, r = se(/* @__PURE__ */ new Set()), t = V(), { addNotification: s } =
|
|
115
|
+
} = n, r = se(/* @__PURE__ */ new Set()), t = V(), { addNotification: s } = x(), { t: i } = S(), o = K({
|
|
116
116
|
queries: d.map((e) => ({
|
|
117
117
|
queryKey: de(e),
|
|
118
|
-
queryFn: () =>
|
|
118
|
+
queryFn: () => Q(e),
|
|
119
119
|
enabled: !!e
|
|
120
120
|
}))
|
|
121
121
|
});
|
|
@@ -131,20 +131,20 @@ const A = (a, n, d, l, b, r) => {
|
|
|
131
131
|
} else e.isError || r.current.delete(h);
|
|
132
132
|
});
|
|
133
133
|
}, [o, d]);
|
|
134
|
-
const
|
|
134
|
+
const m = T(() => o.map((e) => e.data?.uuid).filter((e) => !!e), [o]), p = T(() => [.../* @__PURE__ */ new Set([...m, ...l])], [m, l]), y = T(() => d.length === 0 ? !0 : o.every((e) => !e.isLoading), [o, d.length]), {
|
|
135
135
|
data: c,
|
|
136
136
|
isLoading: U,
|
|
137
137
|
isError: R,
|
|
138
138
|
refetch: f
|
|
139
|
-
} =
|
|
140
|
-
queryKey: le(t,
|
|
141
|
-
queryFn: () => te(t,
|
|
142
|
-
enabled: !!t &&
|
|
139
|
+
} = Y({
|
|
140
|
+
queryKey: le(t, p),
|
|
141
|
+
queryFn: () => te(t, p),
|
|
142
|
+
enabled: !!t && p.length > 0 && y
|
|
143
143
|
});
|
|
144
|
-
|
|
144
|
+
j(
|
|
145
145
|
(e) => {
|
|
146
146
|
e.patientUUID === t && e.updatedConcepts.size > 0 && [...e.updatedConcepts.keys()].some(
|
|
147
|
-
(h) =>
|
|
147
|
+
(h) => p.includes(h)
|
|
148
148
|
) && f();
|
|
149
149
|
},
|
|
150
150
|
[t, f]
|
|
@@ -157,13 +157,13 @@ const A = (a, n, d, l, b, r) => {
|
|
|
157
157
|
}, [R]);
|
|
158
158
|
const g = T(() => {
|
|
159
159
|
if (!c) return [];
|
|
160
|
-
const e =
|
|
161
|
-
return
|
|
160
|
+
const e = w(c), h = z(e);
|
|
161
|
+
return G(h);
|
|
162
162
|
}, [c]), D = [
|
|
163
163
|
{ key: "name", header: "name" },
|
|
164
164
|
{ key: "value", header: "value" },
|
|
165
165
|
{ key: "form", header: "form" }
|
|
166
|
-
],
|
|
166
|
+
], _ = U || !y, O = R && y, B = (!c || c.entry?.length === 0 || p.length === 0) && y, L = O ? i("ERROR_FETCHING_OBSERVATIONS") : null, k = B ? i("NO_OBSERVATIONS_FOUND") : void 0, q = g.length > 0 && !_ && !O, E = n.titleTranslationKey, v = E ? i(E) : "";
|
|
167
167
|
return /* @__PURE__ */ N(
|
|
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-${v}` : "observations-title",
|
|
@@ -190,12 +190,12 @@ const A = (a, n, d, l, b, r) => {
|
|
|
190
190
|
hideThumbnail: b
|
|
191
191
|
}
|
|
192
192
|
) : /* @__PURE__ */ u(
|
|
193
|
-
|
|
193
|
+
M,
|
|
194
194
|
{
|
|
195
195
|
headers: D,
|
|
196
196
|
rows: [],
|
|
197
197
|
ariaLabel: i("OBSERVATIONS"),
|
|
198
|
-
loading:
|
|
198
|
+
loading: _,
|
|
199
199
|
errorStateMessage: L,
|
|
200
200
|
emptyStateMessage: k,
|
|
201
201
|
dataTestId: "observations-table"
|
|
@@ -207,6 +207,6 @@ const A = (a, n, d, l, b, r) => {
|
|
|
207
207
|
};
|
|
208
208
|
export {
|
|
209
209
|
de as conceptUuidQueryKeys,
|
|
210
|
-
|
|
210
|
+
me as default,
|
|
211
211
|
le as observationsQueryKeys
|
|
212
212
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as we, a0 as z, a1 as xt, a2 as B,
|
|
1
|
+
import { $ as we, a0 as z, a1 as xt, a2 as B, W as q, Z as y, a3 as Ro, a4 as ye, a5 as R, a6 as _, a7 as k, a8 as N, a9 as A, aa as bs, ab as ir, ac as $e, ad as G, ae as Hn, af as Vn, ag as dt, ah as D, ai as xs, aj as cn, ak as Be, al as ws, am as qt, an as zt, ao as $s, ap as Cs, aq as $n, ar as Ss, as as Nr, at as Bt, au as zo, av as ks, aw as Es, ax as j, ay as Gr, az as Ms, aA as Ds, aB as sr, aC as As, aD as Ts, aE as zn, aF as Fs, aG as Is, aH as Z, aI as Ps, aJ as Ls } from "./index-CiSdLjcg.js";
|
|
2
2
|
var Os = (e) => e != null, qs = (e) => e.filter(Os);
|
|
3
3
|
function _s(e) {
|
|
4
4
|
return (...t) => {
|