@bahmni/clinical-app 0.0.1-dev.107 → 0.0.1-dev.109

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.
Files changed (34) hide show
  1. package/dist/FormsTable-BanYzo5c-KsdVVSMe.js +318 -0
  2. package/dist/{LNWAZHJI-DKhyLV_Q.js → LNWAZHJI-De-LKNGb.js} +7 -7
  3. package/dist/{MWZ6AO7Z-CwM39bNX.js → MWZ6AO7Z-DYIVGZga.js} +9 -9
  4. package/dist/{YPM2AS64-DRx2fnqw.js → YPM2AS64-CIVqaRmV.js} +1 -1
  5. package/dist/components/consultationPad/ConsultationPad.d.ts.map +1 -1
  6. package/dist/components/forms/medications/MedicationsForm.d.ts.map +1 -1
  7. package/dist/components/forms/medications/SelectedMedicationItem.d.ts +1 -0
  8. package/dist/components/forms/medications/SelectedMedicationItem.d.ts.map +1 -1
  9. package/dist/components/forms/vaccinations/SelectedVaccinationItem.d.ts +23 -0
  10. package/dist/components/forms/vaccinations/SelectedVaccinationItem.d.ts.map +1 -0
  11. package/dist/components/forms/vaccinations/VaccinationForm.d.ts +10 -0
  12. package/dist/components/forms/vaccinations/VaccinationForm.d.ts.map +1 -0
  13. package/dist/constants/app.d.ts +0 -2
  14. package/dist/constants/app.d.ts.map +1 -1
  15. package/dist/hooks/useMedicationConfig.d.ts.map +1 -1
  16. package/dist/hooks/useMedicationSearch.d.ts.map +1 -1
  17. package/dist/{index-DQ_AJQ-E.js → index-BK9tPWzE.js} +19456 -18652
  18. package/dist/index.css +1 -1
  19. package/dist/index.js +2 -2
  20. package/dist/locales/locale_en.json +14 -1
  21. package/dist/locales/locale_es.json +14 -1
  22. package/dist/models/medication.d.ts +1 -0
  23. package/dist/models/medication.d.ts.map +1 -1
  24. package/dist/models/medicationConfig.d.ts +1 -29
  25. package/dist/models/medicationConfig.d.ts.map +1 -1
  26. package/dist/services/medicationService.d.ts +1 -3
  27. package/dist/services/medicationService.d.ts.map +1 -1
  28. package/dist/stores/medicationsStore.d.ts +1 -0
  29. package/dist/stores/medicationsStore.d.ts.map +1 -1
  30. package/dist/stores/vaccinationsStore.d.ts +28 -0
  31. package/dist/stores/vaccinationsStore.d.ts.map +1 -0
  32. package/dist/utils/fhir/medicationRequestResourceCreator.d.ts.map +1 -1
  33. package/package.json +1 -1
  34. package/dist/FormsTable-COjqJWg6-DL1-WqVh.js +0 -259
@@ -0,0 +1,318 @@
1
+ import { jsx as o, jsxs as p, Fragment as z } from "react/jsx-runtime";
2
+ import { u as X, C as Y, F as W, a as f, b as Z, V as ee, Q as G, _ as re, c as ae, d as oe, E as ne, t as I, X as te, N, r as se, e as de, f as ie, g as me } from "./index-BK9tPWzE.js";
3
+ import { useState as U, useMemo as b, useCallback as g } from "react";
4
+ import { createPortal as le } from "react-dom";
5
+ const ce = "_formsTableBody_1pd36_1", ue = "_customAccordianItem_1pd36_6", pe = "_formContent_1pd36_18", _e = "_formDetailsContainer_1pd36_25", be = "_observation_1pd36_30", fe = "_groupContainer_1pd36_39", ge = "_rowContainer_1pd36_43", Ne = "_groupLabel_1pd36_48", he = "_rowLabel_1pd36_58", ye = "_rowValue_1pd36_67", ve = "_groupMembers_1pd36_75", Me = "_memberRow_1pd36_81", Ae = "_memberLabel_1pd36_86", Ce = "_memberValue_1pd36_94", Le = "_abnormalValue_1pd36_102", Oe = "_commentSection_1pd36_110", Re = "_commentText_1pd36_116", Fe = "_nestedGroup_1pd36_125", Te = "_nestedGroupLabel_1pd36_132", De = "_nestedGroupMembers_1pd36_141", r = {
6
+ formsTableBody: ce,
7
+ customAccordianItem: ue,
8
+ formContent: pe,
9
+ formDetailsContainer: _e,
10
+ observation: be,
11
+ groupContainer: fe,
12
+ rowContainer: ge,
13
+ groupLabel: Ne,
14
+ rowLabel: he,
15
+ rowValue: ye,
16
+ groupMembers: ve,
17
+ memberRow: Me,
18
+ memberLabel: Ae,
19
+ memberValue: Ce,
20
+ abnormalValue: Le,
21
+ commentSection: Oe,
22
+ commentText: Re,
23
+ nestedGroup: Fe,
24
+ nestedGroupLabel: Te,
25
+ nestedGroupMembers: De
26
+ }, Ee = "ABNORMAL", q = (e) => {
27
+ const i = e.concept?.units, m = e.concept?.lowNormal, a = e.concept?.hiNormal, l = m != null, c = a != null, u = l && c ? ` (${m} - ${a})` : l ? ` (>${m})` : c ? ` (<${a})` : "", t = e.interpretation && e.interpretation.toUpperCase() === Ee;
28
+ return { units: i, rangeString: u, isAbnormal: t };
29
+ }, x = ({
30
+ member: e,
31
+ depth: i = 0
32
+ }) => {
33
+ const m = e.groupMembers && e.groupMembers.length > 0, a = e.conceptNameToDisplay ?? e.concept?.shortName ?? e.concept?.name;
34
+ if (m)
35
+ return /* @__PURE__ */ p("div", { className: r.nestedGroup, children: [
36
+ /* @__PURE__ */ o(
37
+ "div",
38
+ {
39
+ className: r.nestedGroupLabel,
40
+ style: { paddingLeft: `${i * 16}px` },
41
+ children: a
42
+ }
43
+ ),
44
+ /* @__PURE__ */ o("div", { className: r.nestedGroupMembers, children: e.groupMembers?.map((t) => /* @__PURE__ */ o(
45
+ x,
46
+ {
47
+ member: t,
48
+ depth: i + 1
49
+ },
50
+ `${t.concept.uuid}`
51
+ )) })
52
+ ] });
53
+ const { units: l, rangeString: c, isAbnormal: u } = q(e);
54
+ return /* @__PURE__ */ p(
55
+ "div",
56
+ {
57
+ className: r.memberRow,
58
+ style: { paddingLeft: `${i * 16}px` },
59
+ children: [
60
+ /* @__PURE__ */ p(
61
+ "p",
62
+ {
63
+ className: N(
64
+ r.memberLabel,
65
+ u ? r.abnormalValue : ""
66
+ ),
67
+ children: [
68
+ a,
69
+ c
70
+ ]
71
+ }
72
+ ),
73
+ /* @__PURE__ */ p(
74
+ "p",
75
+ {
76
+ className: N(
77
+ r.memberValue,
78
+ u ? r.abnormalValue : ""
79
+ ),
80
+ children: [
81
+ e.valueAsString,
82
+ l && ` ${l}`
83
+ ]
84
+ }
85
+ )
86
+ ]
87
+ }
88
+ );
89
+ }, we = ({
90
+ observation: e,
91
+ index: i
92
+ }) => {
93
+ const m = e.groupMembers && e.groupMembers.length > 0, { units: a, rangeString: l, isAbnormal: c } = q(e);
94
+ return /* @__PURE__ */ p(
95
+ "div",
96
+ {
97
+ className: r.observation,
98
+ children: [
99
+ /* @__PURE__ */ p(
100
+ "div",
101
+ {
102
+ className: m ? r.groupContainer : r.rowContainer,
103
+ children: [
104
+ /* @__PURE__ */ p(
105
+ "p",
106
+ {
107
+ className: N(
108
+ m ? r.groupLabel : r.rowLabel,
109
+ !m && c ? r.abnormalValue : ""
110
+ ),
111
+ children: [
112
+ e.conceptNameToDisplay,
113
+ !m && l && /* @__PURE__ */ o("span", { className: r.rangeInfo, children: l })
114
+ ]
115
+ }
116
+ ),
117
+ m ? /* @__PURE__ */ o("div", { className: r.groupMembers, children: e.groupMembers?.map((u) => /* @__PURE__ */ o(
118
+ x,
119
+ {
120
+ member: u,
121
+ depth: 0
122
+ },
123
+ `${u.concept.uuid}`
124
+ )) }) : /* @__PURE__ */ p(
125
+ "p",
126
+ {
127
+ className: N(
128
+ r.rowValue,
129
+ c ? r.abnormalValue : ""
130
+ ),
131
+ children: [
132
+ e.valueAsString,
133
+ a && ` ${a}`
134
+ ]
135
+ }
136
+ )
137
+ ]
138
+ }
139
+ ),
140
+ e.comment && /* @__PURE__ */ o("div", { className: r.commentSection, children: /* @__PURE__ */ p("span", { className: r.commentText, children: [
141
+ e.comment,
142
+ e.providers?.[0]?.name && ` - by ${e.providers[0].name}`
143
+ ] }) })
144
+ ]
145
+ },
146
+ `${e.concept.uuid}-${i}`
147
+ );
148
+ }, Ie = ({
149
+ episodeOfCareUuids: e,
150
+ encounterUuids: i,
151
+ config: m
152
+ }) => {
153
+ const { t: a } = X(), l = Y(), [c, u] = U(!1), [t, A] = U(null), k = m?.numberOfVisits, C = W(
154
+ e,
155
+ i
156
+ ), {
157
+ data: h = [],
158
+ isLoading: L,
159
+ isError: O,
160
+ error: H
161
+ } = f({
162
+ queryKey: ["forms", l, e],
163
+ queryFn: () => se(l, void 0, k),
164
+ enabled: !!l && !C
165
+ }), R = b(() => !i || i.length === 0 ? h : h.filter(
166
+ (n) => i.includes(n.encounterUuid)
167
+ ), [h, i]), { data: F = [] } = f({
168
+ queryKey: ["observationForms"],
169
+ queryFn: de
170
+ }), T = g(
171
+ (n) => F.find((s) => s.name === n)?.uuid,
172
+ [F]
173
+ ), y = b(() => {
174
+ if (t)
175
+ return T(t.formName);
176
+ }, [t, T]), {
177
+ data: Be,
178
+ isLoading: j,
179
+ error: D
180
+ } = f({
181
+ queryKey: ["formMetadata", y],
182
+ queryFn: () => ie(y),
183
+ enabled: !!y && c
184
+ }), {
185
+ data: v,
186
+ isLoading: K,
187
+ error: E
188
+ } = f({
189
+ queryKey: ["formsEncounter", t?.encounterUuid],
190
+ queryFn: () => me(t.encounterUuid, !0),
191
+ enabled: !!t?.encounterUuid && c
192
+ }), w = b(() => !v?.observations || !t?.formName ? [] : v.observations.filter(
193
+ (n) => "formFieldPath" in n && typeof n.formFieldPath == "string" && n.formFieldPath.includes(t.formName)
194
+ ), [v?.observations, t?.formName]), B = b(
195
+ () => [
196
+ { key: "recordedOn", header: a("FORM_RECORDED_ON") },
197
+ { key: "recordedBy", header: a("FORM_RECORDED_BY") }
198
+ ],
199
+ [a]
200
+ ), P = b(
201
+ () => [
202
+ { key: "recordedOn", sortable: !0 },
203
+ { key: "recordedBy", sortable: !0 }
204
+ ],
205
+ []
206
+ ), V = b(() => {
207
+ const n = R.reduce(
208
+ (s, d) => {
209
+ const _ = d.formName;
210
+ s[_] ??= [];
211
+ const M = d.providers.map((J) => J.providerName).filter(Boolean).join(", ");
212
+ return s[_].push({
213
+ id: d.encounterUuid,
214
+ formName: d.formName,
215
+ recordedOn: Z(d.encounterDateTime, a, te).formattedResult,
216
+ recordedBy: M ?? "--",
217
+ encounterDateTime: d.encounterDateTime,
218
+ encounterUuid: d.encounterUuid
219
+ }), s;
220
+ },
221
+ {}
222
+ );
223
+ return Object.entries(n).map(
224
+ ([s, d]) => ({
225
+ formName: s,
226
+ records: d.sort(
227
+ (_, M) => M.encounterDateTime - _.encounterDateTime
228
+ )
229
+ })
230
+ ).sort((s, d) => s.formName.localeCompare(d.formName));
231
+ }, [R, a]), S = g((n) => {
232
+ A(n), u(!0);
233
+ }, []), Q = g(() => {
234
+ u(!1), A(null);
235
+ }, []), $ = g(
236
+ (n, s) => {
237
+ switch (s) {
238
+ case "recordedOn":
239
+ return /* @__PURE__ */ o(ee, { onClick: () => S(n), children: n.recordedOn });
240
+ case "recordedBy":
241
+ return n.recordedBy;
242
+ default:
243
+ return null;
244
+ }
245
+ },
246
+ [S]
247
+ );
248
+ return /* @__PURE__ */ p(z, { children: [
249
+ /* @__PURE__ */ o("div", { "data-testid": "forms-table", children: L || O || V.length === 0 || C ? /* @__PURE__ */ o(
250
+ G,
251
+ {
252
+ headers: B,
253
+ ariaLabel: a("FORMS_HEADING"),
254
+ rows: [],
255
+ loading: L,
256
+ errorStateMessage: O ? H?.message : void 0,
257
+ emptyStateMessage: a("FORMS_UNAVAILABLE"),
258
+ renderCell: $,
259
+ className: r.formsTableBody,
260
+ "data-testid": "sortable-data-table"
261
+ }
262
+ ) : /* @__PURE__ */ o(re, { align: "start", children: V.map((n, s) => {
263
+ const { formName: d, records: _ } = n;
264
+ return /* @__PURE__ */ o(
265
+ ae,
266
+ {
267
+ title: d,
268
+ className: r.customAccordianItem,
269
+ testId: `accordian-title-${d}`,
270
+ open: s === 0,
271
+ children: /* @__PURE__ */ o(
272
+ G,
273
+ {
274
+ headers: B,
275
+ ariaLabel: a("FORMS_HEADING"),
276
+ rows: _,
277
+ loading: !1,
278
+ errorStateMessage: "",
279
+ sortable: P,
280
+ emptyStateMessage: a("FORMS_UNAVAILABLE"),
281
+ renderCell: $,
282
+ className: r.formsTableBody,
283
+ "data-testid": "forms-data-table"
284
+ }
285
+ )
286
+ },
287
+ d
288
+ );
289
+ }) }) }),
290
+ c && t && le(
291
+ /* @__PURE__ */ o(
292
+ oe,
293
+ {
294
+ id: "formDetailsModal",
295
+ open: c,
296
+ onRequestClose: Q,
297
+ modalHeading: t.formName,
298
+ modalLabel: `${t.recordedOn} | ${t.recordedBy}`,
299
+ passiveModal: !0,
300
+ size: "md",
301
+ testId: "form-details-modal",
302
+ children: /* @__PURE__ */ o("div", { className: r.formContent, children: j || K ? /* @__PURE__ */ o(ne, { width: "100%", lineCount: 3 }) : D ? /* @__PURE__ */ o("div", { children: I(D).message ?? a("ERROR_FETCHING_FORM_METADATA") }) : E ? /* @__PURE__ */ o("div", { children: I(E).message ?? a("ERROR_FETCHING_FORM_DATA") }) : w.length > 0 ? /* @__PURE__ */ o("div", { className: r.formDetailsContainer, children: w.map((n, s) => /* @__PURE__ */ o(
303
+ we,
304
+ {
305
+ observation: n,
306
+ index: s
307
+ },
308
+ `${n.concept.uuid}`
309
+ )) }) : /* @__PURE__ */ o("div", { children: a("NO_FORM_DATA_AVAILABLE") }) })
310
+ }
311
+ ),
312
+ document.getElementById("actionAreaLayout") ?? document.body
313
+ )
314
+ ] });
315
+ };
316
+ export {
317
+ Ie as default
318
+ };
@@ -1,23 +1,23 @@
1
- import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-DRx2fnqw.js";
2
- import { g as d, d as f, f as e } from "./index-DQ_AJQ-E.js";
3
- var p = (a) => {
1
+ import { c, T as l, P as m, a as i, D as u, Q as v } from "./YPM2AS64-CIVqaRmV.js";
2
+ import { h as d, i as f, j as e } from "./index-BK9tPWzE.js";
3
+ var h = (a) => {
4
4
  const [r, t] = c({
5
5
  prefix: "TanstackQueryDevtools"
6
6
  }), n = d(), s = f(() => {
7
7
  const o = r.theme_preference || l;
8
8
  return o !== "system" ? o : n();
9
9
  });
10
- return e(i.Provider, {
10
+ return e(v.Provider, {
11
11
  value: a,
12
12
  get children() {
13
13
  return e(m, {
14
14
  localStore: r,
15
15
  setLocalStore: t,
16
16
  get children() {
17
- return e(u.Provider, {
17
+ return e(i.Provider, {
18
18
  value: s,
19
19
  get children() {
20
- return e(v, {
20
+ return e(u, {
21
21
  localStore: r,
22
22
  setLocalStore: t
23
23
  });
@@ -27,7 +27,7 @@ var p = (a) => {
27
27
  });
28
28
  }
29
29
  });
30
- }, C = p;
30
+ }, C = h;
31
31
  export {
32
32
  C as default
33
33
  };
@@ -1,26 +1,26 @@
1
- import { c as s, T as c, P as u, a as i, b as m, C as d, Q as P } from "./YPM2AS64-DRx2fnqw.js";
2
- import { g as v, d as C, f as e } from "./index-DQ_AJQ-E.js";
3
- var f = (t) => {
1
+ import { c as s, T as c, P as i, a as u, b as m, C as P, Q as d } from "./YPM2AS64-CIVqaRmV.js";
2
+ import { h, i as v, j as e } from "./index-BK9tPWzE.js";
3
+ var C = (t) => {
4
4
  const [r, o] = s({
5
5
  prefix: "TanstackQueryDevtools"
6
- }), a = v(), l = C(() => {
6
+ }), a = h(), l = v(() => {
7
7
  const n = r.theme_preference || c;
8
8
  return n !== "system" ? n : a();
9
9
  });
10
- return e(P.Provider, {
10
+ return e(d.Provider, {
11
11
  value: t,
12
12
  get children() {
13
- return e(u, {
13
+ return e(i, {
14
14
  disabled: !0,
15
15
  localStore: r,
16
16
  setLocalStore: o,
17
17
  get children() {
18
- return e(i.Provider, {
18
+ return e(u.Provider, {
19
19
  value: l,
20
20
  get children() {
21
21
  return e(m, {
22
22
  get children() {
23
- return e(d, {
23
+ return e(P, {
24
24
  localStore: r,
25
25
  setLocalStore: o,
26
26
  get onClose() {
@@ -36,7 +36,7 @@ var f = (t) => {
36
36
  });
37
37
  }
38
38
  });
39
- }, p = f;
39
+ }, p = C;
40
40
  export {
41
41
  p as default
42
42
  };
@@ -1,4 +1,4 @@
1
- import { h as we, i as z, o as xt, j as B, d as q, f as y, P as Ro, m as ye, S as R, k as _, n as k, p as N, q as A, r as bs, s as ir, v as $e, w as U, x as Hn, y as Vn, z as dt, B as D, D as xs, F as cn, H as Be, I as ws, K as qt, L as zt, M as $s, N as Cs, O as $n, R as Ss, T as Nr, U as Bt, $ as zo, W as ks, Y as Es, Z as j, a0 as Ur, a1 as Ms, a2 as Ds, a3 as sr, a4 as As, a5 as Ts, a6 as zn, a7 as Fs, a8 as Is, a9 as Z, aa as Ps, ab as Ls } from "./index-DQ_AJQ-E.js";
1
+ import { k as we, l as z, o as xt, m as B, i as q, j as y, P as Ro, n as ye, S as R, p as _, q as k, s as N, v as A, w as bs, x as ir, y as $e, z as U, A as Hn, B as Vn, D as dt, G as D, H as xs, I as cn, J as Be, K as ws, L as qt, M as zt, O as $s, R as Cs, T as $n, U as Ss, W as Nr, Y as Bt, $ as zo, Z as ks, a0 as Es, a1 as j, a2 as Ur, a3 as Ms, a4 as Ds, a5 as sr, a6 as As, a7 as Ts, a8 as zn, a9 as Fs, aa as Is, ab as Z, ac as Ps, ad as Ls } from "./index-BK9tPWzE.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":"ConsultationPad.d.ts","sourceRoot":"","sources":["../../../src/components/consultationPad/ConsultationPad.tsx"],"names":[],"mappings":"AAgBA,OAAO,KAAoB,MAAM,OAAO,CAAC;AAuCzC,UAAU,oBAAoB;IAC5B,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CA2XnD,CAAC;AAEF,eAAe,eAAe,CAAC"}
1
+ {"version":3,"file":"ConsultationPad.d.ts","sourceRoot":"","sources":["../../../src/components/consultationPad/ConsultationPad.tsx"],"names":[],"mappings":"AAgBA,OAAO,KAAoB,MAAM,OAAO,CAAC;AAyCzC,UAAU,oBAAoB;IAC5B,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CAiZnD,CAAC;AAEF,eAAe,eAAe,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"MedicationsForm.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/medications/MedicationsForm.tsx"],"names":[],"mappings":"AAQA,OAAO,KAAoC,MAAM,OAAO,CAAC;AASzD;;;;;GAKG;AACH,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAsK3B,CAAC;AAIH,eAAe,eAAe,CAAC"}
1
+ {"version":3,"file":"MedicationsForm.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/medications/MedicationsForm.tsx"],"names":[],"mappings":"AAQA,OAAO,KAAoC,MAAM,OAAO,CAAC;AASzD;;;;;GAKG;AACH,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAwK3B,CAAC;AAIH,eAAe,eAAe,CAAC"}
@@ -17,6 +17,7 @@ export interface SelectedMedicationItemProps {
17
17
  updateStartDate: (medicationId: string, date: Date) => void;
18
18
  updateDispenseQuantity: (medicationId: string, quantity: number) => void;
19
19
  updateDispenseUnit: (medicationId: string, unit: Concept) => void;
20
+ updateNote: (medicationId: string, note: string) => void;
20
21
  }
21
22
  declare const SelectedMedicationItem: React.FC<SelectedMedicationItemProps>;
22
23
  export default SelectedMedicationItem;
@@ -1 +1 @@
1
- {"version":3,"file":"SelectedMedicationItem.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/medications/SelectedMedicationItem.tsx"],"names":[],"mappings":"AAcA,OAAO,KAAiC,MAAM,OAAO,CAAC;AAEtD,OAAO,EAAE,OAAO,EAAE,MAAM,mCAAmC,CAAC;AAC5D,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACrB,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AAS/E,MAAM,WAAW,2BAA2B;IAC1C,oBAAoB,EAAE,oBAAoB,CAAC;IAC3C,gBAAgB,EAAE,gBAAgB,CAAC;IACnC,YAAY,EAAE,CAAC,YAAY,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAC7D,gBAA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I,CAAC;IACzE,kBAAkB,EAAE,CAAC,YAAY,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,KAAK,IAAI,CAAC;IAClE,UAAU,EAAE,CAAC,YAAY,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CAC1D;AAED,QAAA,MAAM,sBAAsB,EAAE,KAAK,CAAC,EAAE,CAAC,2BAA2B,CAka/D,CAAC;AAIJ,eAAe,sBAAsB,CAAC"}
@@ -0,0 +1,23 @@
1
+ import { default as React } from 'react';
2
+ import { Concept } from '../../../models/encounterConcepts';
3
+ import { DurationUnitOption, MedicationInputEntry } from '../../../models/medication';
4
+ import { Frequency, MedicationConfig } from '../../../models/medicationConfig';
5
+ export interface SelectedVaccinationItemProps {
6
+ vaccinationInputEntry: MedicationInputEntry;
7
+ medicationConfig: MedicationConfig;
8
+ updateDosage: (vaccinationId: string, dosage: number) => void;
9
+ updateDosageUnit: (vaccinationId: string, unit: Concept) => void;
10
+ updateFrequency: (vaccinationId: string, frequency: Frequency | null) => void;
11
+ updateRoute: (vaccinationId: string, route: Concept) => void;
12
+ updateDuration: (vaccinationId: string, duration: number) => void;
13
+ updateDurationUnit: (vaccinationId: string, unit: DurationUnitOption | null) => void;
14
+ updateInstruction: (vaccinationId: string, instruction: Concept) => void;
15
+ updateisSTAT: (vaccinationId: string, isSTAT: boolean) => void;
16
+ updateStartDate: (vaccinationId: string, date: Date) => void;
17
+ updateDispenseQuantity: (vaccinationId: string, quantity: number) => void;
18
+ updateDispenseUnit: (vaccinationId: string, unit: Concept) => void;
19
+ updateNote: (vaccinationId: string, note: string) => void;
20
+ }
21
+ declare const SelectedVaccinationItem: React.FC<SelectedVaccinationItemProps>;
22
+ export default SelectedVaccinationItem;
23
+ //# sourceMappingURL=SelectedVaccinationItem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SelectedVaccinationItem.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/vaccinations/SelectedVaccinationItem.ts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,kBAAkB,EAAE,CAAC,aAAa,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,KAAK,IAAI,CAAC;IACnE,UAAU,EAAE,CAAC,aAAa,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CAC3D;AAED,QAAA,MAAM,uBAAuB,EAAE,KAAK,CAAC,EAAE,CAAC,4BAA4B,CAiZjE,CAAC;AAIJ,eAAe,uBAAuB,CAAC"}
@@ -0,0 +1,10 @@
1
+ import { default as React } from 'react';
2
+ /**
3
+ * VaccinationForm component
4
+ *
5
+ * A component that displays a search interface for vaccinations and a list of selected vaccinations.
6
+ * It allows users to search for vaccinations, select them, and specify dosage, frequency, route, timing, and duration.
7
+ */
8
+ declare const VaccinationForm: React.FC;
9
+ export default VaccinationForm;
10
+ //# sourceMappingURL=VaccinationForm.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VaccinationForm.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/vaccinations/VaccinationForm.tsx"],"names":[],"mappings":"AASA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAYzD;;;;;GAKG;AACH,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EA8L3B,CAAC;AAIH,eAAe,eAAe,CAAC"}
@@ -3,8 +3,6 @@ export declare const ENCOUNTER_CONCEPTS_URL: string;
3
3
  export declare const BAHMNI_USER_LOCATION_COOKIE_NAME = "bahmni.user.location";
4
4
  export declare const PROVIDER_RESOURCE_URL: (userUUID: string) => string;
5
5
  export declare const USER_RESOURCE_URL: (username: string) => string;
6
- export declare const MEDICATION_ORDERS_METADATA_URL: string;
7
- export declare const MEDICATIONS_SEARCH_URL: (searchTerm: string, count: number) => string;
8
6
  export declare const CONSULTATION_BUNDLE_URL: string;
9
7
  export declare const ENCOUNTER_SEARCH_URL: string;
10
8
  export declare const OBSERVATION_FORMS_URL: string;
@@ -1 +1 @@
1
- {"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../src/constants/app.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,oBAAoB,gCAAgC,CAAC;AAClE,eAAO,MAAM,sBAAsB,QAEuC,CAAC;AAE3E,eAAO,MAAM,gCAAgC,yBAAyB,CAAC;AAEvE,eAAO,MAAM,qBAAqB,GAAI,UAAU,MAAM,WACyB,CAAC;AAEhF,eAAO,MAAM,iBAAiB,GAAI,UAAU,MAAM,WACuB,CAAC;AAE1E,eAAO,MAAM,8BAA8B,QACQ,CAAC;AAEpD,eAAO,MAAM,sBAAsB,GAAI,YAAY,MAAM,EAAE,OAAO,MAAM,WAEF,CAAC;AAEvE,eAAO,MAAM,uBAAuB,QAA0C,CAAC;AAC/E,eAAO,MAAM,oBAAoB,QAAiC,CAAC;AACnE,eAAO,MAAM,qBAAqB,QACuB,CAAC;AAC1D,eAAO,MAAM,kBAAkB,aAAa,CAAC"}
1
+ {"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../src/constants/app.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,oBAAoB,gCAAgC,CAAC;AAClE,eAAO,MAAM,sBAAsB,QAEuC,CAAC;AAE3E,eAAO,MAAM,gCAAgC,yBAAyB,CAAC;AAEvE,eAAO,MAAM,qBAAqB,GAAI,UAAU,MAAM,WACyB,CAAC;AAEhF,eAAO,MAAM,iBAAiB,GAAI,UAAU,MAAM,WACuB,CAAC;AAE1E,eAAO,MAAM,uBAAuB,QAA0C,CAAC;AAC/E,eAAO,MAAM,oBAAoB,QAAiC,CAAC;AACnE,eAAO,MAAM,qBAAqB,QACuB,CAAC;AAC1D,eAAO,MAAM,kBAAkB,aAAa,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"useMedicationConfig.d.ts","sourceRoot":"","sources":["../../src/hooks/useMedicationConfig.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AAG9D,UAAU,yBAAyB;IACjC,gBAAgB,EAAE,gBAAgB,GAAG,IAAI,CAAC;IAC1C,OAAO,EAAE,OAAO,CAAC;IACjB,KAAK,EAAE,KAAK,GAAG,IAAI,CAAC;CACrB;AAED,eAAO,MAAM,mBAAmB,QAAO,yBAmCtC,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
1
+ {"version":3,"file":"useMedicationConfig.d.ts","sourceRoot":"","sources":["../../src/hooks/useMedicationConfig.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AAE9D,UAAU,yBAAyB;IACjC,gBAAgB,EAAE,gBAAgB,GAAG,IAAI,CAAC;IAC1C,OAAO,EAAE,OAAO,CAAC;IACjB,KAAK,EAAE,KAAK,GAAG,IAAI,CAAC;CACrB;AAID,eAAO,MAAM,mBAAmB,QAAO,yBAmCtC,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"useMedicationSearch.d.ts","sourceRoot":"","sources":["../../src/hooks/useMedicationSearch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,UAAU,EAAE,MAAM,SAAS,CAAC;AAK7C,UAAU,sBAAsB;IAC9B,aAAa,EAAE,UAAU,EAAE,CAAC;IAC5B,OAAO,EAAE,OAAO,CAAC;IACjB,KAAK,EAAE,KAAK,GAAG,IAAI,CAAC;CACrB;AAED,eAAO,MAAM,mBAAmB,GAC9B,YAAY,MAAM,EAClB,cAAU,EACV,sBAAmB,KAClB,sBA+CF,CAAC"}
1
+ {"version":3,"file":"useMedicationSearch.d.ts","sourceRoot":"","sources":["../../src/hooks/useMedicationSearch.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAMrC,UAAU,sBAAsB;IAC9B,aAAa,EAAE,UAAU,EAAE,CAAC;IAC5B,OAAO,EAAE,OAAO,CAAC;IACjB,KAAK,EAAE,KAAK,GAAG,IAAI,CAAC;CACrB;AAID,eAAO,MAAM,mBAAmB,GAC9B,YAAY,MAAM,EAClB,cAAU,EACV,sBAAmB,KAClB,sBAmCF,CAAC"}