@bahmni/clinical-app 0.0.1-dev.106 → 0.0.1-dev.108

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.
@@ -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, _ as W, a as f, b as Z, V as ee, Q as $, A as re, c as ae, l as oe, E as ne, t as I, G as te, N, e as se, X as de, d as ie, J as me } from "./index-jQa2f6J7.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", Ae = "_memberRow_1pd36_81", Me = "_memberLabel_1pd36_86", Ce = "_memberValue_1pd36_94", Le = "_abnormalValue_1pd36_102", Oe = "_commentSection_1pd36_110", Re = "_commentText_1pd36_116", Te = "_nestedGroup_1pd36_125", De = "_nestedGroupLabel_1pd36_132", Fe = "_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: Ae,
18
+ memberLabel: Me,
19
+ memberValue: Ce,
20
+ abnormalValue: Le,
21
+ commentSection: Oe,
22
+ commentText: Re,
23
+ nestedGroup: Te,
24
+ nestedGroupLabel: De,
25
+ nestedGroupMembers: Fe
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
+ }, Ge = ({
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, M] = 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: T = [] } = f({
168
+ queryKey: ["observationForms"],
169
+ queryFn: de
170
+ }), D = g(
171
+ (n) => T.find((s) => s.name === n)?.uuid,
172
+ [T]
173
+ ), y = b(() => {
174
+ if (t)
175
+ return D(t.formName);
176
+ }, [t, D]), {
177
+ data: we,
178
+ isLoading: j,
179
+ error: F
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
+ }), G = 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]), w = 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
+ ), B = b(() => {
207
+ const n = R.reduce(
208
+ (s, d) => {
209
+ const _ = d.formName;
210
+ s[_] ??= [];
211
+ const A = 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: A ?? "--",
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
+ (_, A) => A.encounterDateTime - _.encounterDateTime
228
+ )
229
+ })
230
+ ).sort((s, d) => s.formName.localeCompare(d.formName));
231
+ }, [R, a]), V = g((n) => {
232
+ M(n), u(!0);
233
+ }, []), Q = g(() => {
234
+ u(!1), M(null);
235
+ }, []), S = g(
236
+ (n, s) => {
237
+ switch (s) {
238
+ case "recordedOn":
239
+ return /* @__PURE__ */ o(ee, { onClick: () => V(n), children: n.recordedOn });
240
+ case "recordedBy":
241
+ return n.recordedBy;
242
+ default:
243
+ return null;
244
+ }
245
+ },
246
+ [V]
247
+ );
248
+ return /* @__PURE__ */ p(z, { children: [
249
+ /* @__PURE__ */ o("div", { "data-testid": "forms-table", children: L || O || B.length === 0 || C ? /* @__PURE__ */ o(
250
+ $,
251
+ {
252
+ headers: w,
253
+ ariaLabel: a("FORMS_HEADING"),
254
+ rows: [],
255
+ loading: L,
256
+ errorStateMessage: O ? H?.message : void 0,
257
+ emptyStateMessage: a("FORMS_UNAVAILABLE"),
258
+ renderCell: S,
259
+ className: r.formsTableBody,
260
+ "data-testid": "sortable-data-table"
261
+ }
262
+ ) : /* @__PURE__ */ o(re, { align: "start", children: B.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
+ $,
273
+ {
274
+ headers: w,
275
+ ariaLabel: a("FORMS_HEADING"),
276
+ rows: _,
277
+ loading: !1,
278
+ errorStateMessage: "",
279
+ sortable: P,
280
+ emptyStateMessage: a("FORMS_UNAVAILABLE"),
281
+ renderCell: S,
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 }) : F ? /* @__PURE__ */ o("div", { children: I(F).message ?? a("ERROR_FETCHING_FORM_METADATA") }) : E ? /* @__PURE__ */ o("div", { children: I(E).message ?? a("ERROR_FETCHING_FORM_DATA") }) : G.length > 0 ? /* @__PURE__ */ o("div", { className: r.formDetailsContainer, children: G.map((n, s) => /* @__PURE__ */ o(
303
+ Ge,
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,9 +1,9 @@
1
- import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-lJoMtftK.js";
2
- import { g as d, d as f, f as e } from "./index-C_onZcPP.js";
3
- var p = (a) => {
1
+ import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64--kUlzXUl.js";
2
+ import { g as f, f as d, h as e } from "./index-jQa2f6J7.js";
3
+ var h = (a) => {
4
4
  const [r, t] = c({
5
5
  prefix: "TanstackQueryDevtools"
6
- }), n = d(), s = f(() => {
6
+ }), n = f(), s = d(() => {
7
7
  const o = r.theme_preference || l;
8
8
  return o !== "system" ? o : n();
9
9
  });
@@ -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,13 +1,13 @@
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-lJoMtftK.js";
2
- import { g as v, d as C, f as e } from "./index-C_onZcPP.js";
3
- var f = (t) => {
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--kUlzXUl.js";
2
+ import { g as h, f as v, h as e } from "./index-jQa2f6J7.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
13
  return e(u, {
@@ -20,7 +20,7 @@ var f = (t) => {
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-C_onZcPP.js";
1
+ import { i as we, j as z, o as xt, k as B, f as q, h as y, P as Ro, m as ye, S as R, n as _, p as k, q as N, r as A, s as bs, v as ir, w as $e, x as U, y as Hn, z as Vn, B as dt, D, F as xs, H as cn, I 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-jQa2f6J7.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;AAkCzC,UAAU,oBAAoB;IAC5B,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CAsWnD,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;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 +1 @@
1
- {"version":3,"file":"ObservationForms.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/observations/ObservationForms.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,KAAyC,MAAM,OAAO,CAAC;AAM9D,UAAU,qBAAqB;IAC7B,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,eAAe,KAAK,IAAI,CAAC;IAC/C,aAAa,CAAC,EAAE,eAAe,EAAE,CAAC;IAClC,YAAY,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAE1C,WAAW,EAAE,eAAe,EAAE,CAAC;IAC/B,iBAAiB,EAAE,CAAC,cAAc,EAAE,eAAe,EAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACxE,oBAAoB,EAAE,OAAO,CAAC;CAC/B;AAED;;;;;;;;;;;;;GAaG;AACH,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,qBAAqB,CAqPrD,CAAC;AAIF,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"ObservationForms.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/observations/ObservationForms.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,KAAyC,MAAM,OAAO,CAAC;AAY9D,UAAU,qBAAqB;IAC7B,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,eAAe,KAAK,IAAI,CAAC;IAC/C,aAAa,CAAC,EAAE,eAAe,EAAE,CAAC;IAClC,YAAY,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAE1C,WAAW,EAAE,eAAe,EAAE,CAAC;IAC/B,iBAAiB,EAAE,CAAC,cAAc,EAAE,eAAe,EAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACxE,oBAAoB,EAAE,OAAO,CAAC;CAC/B;AAED;;;;;;;;;;;;;GAaG;AACH,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,qBAAqB,CAuQrD,CAAC;AAIF,eAAe,gBAAgB,CAAC"}
@@ -1,12 +1,13 @@
1
1
  import { ObservationForm, Form2Observation } from '@bahmni/services';
2
2
  import { default as React } from 'react';
3
+ import { VALIDATION_STATE_EMPTY, VALIDATION_STATE_MANDATORY, VALIDATION_STATE_INVALID } from '../../../constants/forms';
3
4
  interface ObservationFormsContainerProps {
4
5
  onViewingFormChange: (viewingForm: ObservationForm | null) => void;
5
6
  viewingForm?: ObservationForm | null;
6
7
  onRemoveForm?: (formUuid: string) => void;
7
8
  pinnedForms: ObservationForm[];
8
9
  updatePinnedForms: (newPinnedForms: ObservationForm[]) => Promise<void>;
9
- onFormObservationsChange?: (formUuid: string, observations: Form2Observation[]) => void;
10
+ onFormObservationsChange?: (formUuid: string, observations: Form2Observation[], validationState?: null | typeof VALIDATION_STATE_EMPTY | typeof VALIDATION_STATE_MANDATORY | typeof VALIDATION_STATE_INVALID) => void;
10
11
  existingObservations?: Form2Observation[];
11
12
  }
12
13
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"ObservationFormsContainer.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/observations/ObservationFormsContainer.tsx"],"names":[],"mappings":"AAWA,OAAO,wCAAwC,CAAC;AAChD,OAAO,oCAAoC,CAAC;AAC5C,OAAO,EACL,eAAe,EACf,gBAAgB,EAGjB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,KAA2B,MAAM,OAAO,CAAC;AAMhD,UAAU,8BAA8B;IAEtC,mBAAmB,EAAE,CAAC,WAAW,EAAE,eAAe,GAAG,IAAI,KAAK,IAAI,CAAC;IAEnE,WAAW,CAAC,EAAE,eAAe,GAAG,IAAI,CAAC;IAErC,YAAY,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAE1C,WAAW,EAAE,eAAe,EAAE,CAAC;IAC/B,iBAAiB,EAAE,CAAC,cAAc,EAAE,eAAe,EAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAExE,wBAAwB,CAAC,EAAE,CACzB,QAAQ,EAAE,MAAM,EAChB,YAAY,EAAE,gBAAgB,EAAE,KAC7B,IAAI,CAAC;IAEV,oBAAoB,CAAC,EAAE,gBAAgB,EAAE,CAAC;CAC3C;AAED;;;;;;;;;GASG;AACH,QAAA,MAAM,yBAAyB,EAAE,KAAK,CAAC,EAAE,CAAC,8BAA8B,CAmLvE,CAAC;AAEF,eAAe,yBAAyB,CAAC"}
1
+ {"version":3,"file":"ObservationFormsContainer.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/observations/ObservationFormsContainer.tsx"],"names":[],"mappings":"AAWA,OAAO,wCAAwC,CAAC;AAChD,OAAO,oCAAoC,CAAC;AAC5C,OAAO,EACL,eAAe,EACf,gBAAgB,EAGjB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,KAA2B,MAAM,OAAO,CAAC;AAEhD,OAAO,EAEL,sBAAsB,EACtB,0BAA0B,EAC1B,wBAAwB,EACzB,MAAM,0BAA0B,CAAC;AAIlC,UAAU,8BAA8B;IAEtC,mBAAmB,EAAE,CAAC,WAAW,EAAE,eAAe,GAAG,IAAI,KAAK,IAAI,CAAC;IAEnE,WAAW,CAAC,EAAE,eAAe,GAAG,IAAI,CAAC;IAErC,YAAY,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAE1C,WAAW,EAAE,eAAe,EAAE,CAAC;IAC/B,iBAAiB,EAAE,CAAC,cAAc,EAAE,eAAe,EAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAExE,wBAAwB,CAAC,EAAE,CACzB,QAAQ,EAAE,MAAM,EAChB,YAAY,EAAE,gBAAgB,EAAE,EAChC,eAAe,CAAC,EACZ,IAAI,GACJ,OAAO,sBAAsB,GAC7B,OAAO,0BAA0B,GACjC,OAAO,wBAAwB,KAChC,IAAI,CAAC;IAEV,oBAAoB,CAAC,EAAE,gBAAgB,EAAE,CAAC;CAC3C;AAED;;;;;;;;;GASG;AACH,QAAA,MAAM,yBAAyB,EAAE,KAAK,CAAC,EAAE,CAAC,8BAA8B,CAgQvE,CAAC;AAEF,eAAe,yBAAyB,CAAC"}
@@ -4,4 +4,11 @@ export declare const PINNED_FORMS_DELIMITER = "###";
4
4
  export declare const FORM_CONTROL_TYPE_OBS_GROUP = "obsGroupControl";
5
5
  export declare const FORM_CONTROL_TYPE_OBS = "obsControl";
6
6
  export declare const FORM_CONTROL_TYPE_MULTISELECT = "multiselect";
7
+ /**
8
+ * Validation states for observation forms.
9
+ * These values are also used to match error messages from form2-controls library.
10
+ */
11
+ export declare const VALIDATION_STATE_EMPTY = "empty";
12
+ export declare const VALIDATION_STATE_MANDATORY = "mandatory";
13
+ export declare const VALIDATION_STATE_INVALID = "invalid";
7
14
  //# sourceMappingURL=forms.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"forms.d.ts","sourceRoot":"","sources":["../../src/constants/forms.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,6BAA6B,UAGzC,CAAC;AAEF,eAAO,MAAM,sBAAsB,UAAwC,CAAC;AAE5E,eAAO,MAAM,sBAAsB,QAAQ,CAAC;AAE5C,eAAO,MAAM,2BAA2B,oBAAoB,CAAC;AAC7D,eAAO,MAAM,qBAAqB,eAAe,CAAC;AAClD,eAAO,MAAM,6BAA6B,gBAAgB,CAAC"}
1
+ {"version":3,"file":"forms.d.ts","sourceRoot":"","sources":["../../src/constants/forms.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,6BAA6B,UAGzC,CAAC;AAEF,eAAO,MAAM,sBAAsB,UAAwC,CAAC;AAE5E,eAAO,MAAM,sBAAsB,QAAQ,CAAC;AAE5C,eAAO,MAAM,2BAA2B,oBAAoB,CAAC;AAC7D,eAAO,MAAM,qBAAqB,eAAe,CAAC;AAClD,eAAO,MAAM,6BAA6B,gBAAgB,CAAC;AAE3D;;;GAGG;AACH,eAAO,MAAM,sBAAsB,UAAU,CAAC;AAC9C,eAAO,MAAM,0BAA0B,cAAc,CAAC;AACtD,eAAO,MAAM,wBAAwB,YAAY,CAAC"}