@bahmni/home-app 0.0.1-dev.273 → 0.0.1-dev.278

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.
@@ -1,7 +1,7 @@
1
- import { jsx as r, jsxs as p, Fragment as x } from "react/jsx-runtime";
2
- import { u as G, a as W, h as Y, t as J, b as X, m as Z, c as ee, n as te } from "./index-Dv1mIf-k.js";
1
+ import { jsx as r, jsxs as T, Fragment as x } from "react/jsx-runtime";
2
+ import { u as G, a as W, h as Y, p as J, b as X, m as Z, c as ee, n as te } from "./index-D3sfUX20.js";
3
3
  import { useQuery as ae } from "@tanstack/react-query";
4
- import { useState as l, useCallback as h, useEffect as O, useMemo as _ } from "react";
4
+ import { useState as l, useCallback as _, useEffect as O, useMemo as h } 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", ce = "DocumentsTable-module_attachmentError__RI4U2", me = "DocumentsTable-module_documentIframe__ptq5I", le = "DocumentsTable-module_documentImage__KQVgS", d = {
6
6
  documentsTableBody: ne,
7
7
  viewAttachmentsLink: oe,
@@ -21,41 +21,41 @@ const ne = "DocumentsTable-module_documentsTableBody__6iR3w", oe = "DocumentsTab
21
21
  function R(a) {
22
22
  return !a || a.includes(":") ? "#" : `/openmrs/auth?requested_document=/document_images/${a}`;
23
23
  }
24
- function ie(a, g) {
24
+ function ie(a, E) {
25
25
  return a.map((s) => ({
26
26
  key: s,
27
- header: g(ue[s])
27
+ header: E(ue[s])
28
28
  }));
29
29
  }
30
- const Te = [
30
+ const pe = [
31
31
  "documentIdentifier",
32
32
  "documentType",
33
33
  "uploadedOn",
34
34
  "uploadedBy",
35
35
  "action"
36
- ], pe = /\.(jpg|jpeg|png|gif|webp|bmp|svg)$/i, B = (a) => a.attachments.length > 0 ? a.attachments : a.documentUrl ? [{ url: a.documentUrl, contentType: a.contentType }] : [], Ie = ({ config: a, encounterUuids: g }) => {
36
+ ], Te = /\.(jpg|jpeg|png|gif|webp|bmp|svg)$/i, B = (a) => a.attachments.length > 0 ? a.attachments : a.documentUrl ? [{ url: a.documentUrl, contentType: a.contentType }] : [], Ie = ({ config: a, encounterUuids: E }) => {
37
37
  const [s, w] = l(!1), [o, U] = l(
38
38
  null
39
39
  ), [$, D] = l(
40
40
  /* @__PURE__ */ new Set()
41
- ), E = G(), { t: n } = W(), { addNotification: L } = Y(), k = Number(a?.pageSize) || 5, [f, C] = l(1), [u, V] = l(k), [F, A] = l(void 0), M = h((e) => {
41
+ ), g = G(), { t: n } = W(), { addNotification: L } = Y(), k = Number(a?.pageSize) || 5, [f, C] = l(1), [u, V] = l(k), [F, A] = l(void 0), M = _((e) => {
42
42
  U(e), w(!0);
43
- }, []), q = h(() => {
43
+ }, []), q = _(() => {
44
44
  w(!1), U(null), D(/* @__PURE__ */ new Set());
45
- }, []), v = h((e) => {
45
+ }, []), v = _((e) => {
46
46
  D((t) => new Set(t).add(e));
47
47
  }, []), { data: i, isLoading: H, isError: b, error: y } = ae({
48
48
  queryKey: [
49
49
  "documents",
50
- E,
51
50
  g,
51
+ E,
52
52
  f,
53
53
  u
54
54
  ],
55
- enabled: !!E,
55
+ enabled: !!g,
56
56
  queryFn: () => J(
57
- E,
58
57
  g,
58
+ E,
59
59
  u,
60
60
  f
61
61
  )
@@ -64,7 +64,7 @@ const Te = [
64
64
  i && A(i.total);
65
65
  }, [i]), O(() => {
66
66
  C(1), A(void 0);
67
- }, [E]), O(() => {
67
+ }, [g]), O(() => {
68
68
  b && L({
69
69
  title: n("ERROR_DEFAULT_TITLE"),
70
70
  message: y?.message ?? "",
@@ -89,24 +89,24 @@ const Te = [
89
89
  e.signal.aborted || D(t);
90
90
  })(), () => e.abort();
91
91
  }, [s, o]);
92
- const j = h(
92
+ const j = _(
93
93
  (e, t) => {
94
94
  t !== u ? (V(t), C(1), A(void 0)) : C(e);
95
95
  },
96
96
  [u]
97
- ), I = _(
98
- () => a?.fields ?? Te,
97
+ ), I = h(
98
+ () => a?.fields ?? pe,
99
99
  [a?.fields]
100
- ), P = _(() => [...i?.documents ?? []].sort((e, t) => !e.uploadedOn && !t.uploadedOn ? 0 : e.uploadedOn ? t.uploadedOn ? new Date(t.uploadedOn).getTime() - new Date(e.uploadedOn).getTime() : -1 : 1), [i]), z = _(() => ie(I, n), [I, n]), K = _(
100
+ ), P = h(() => [...i?.documents ?? []].sort((e, t) => !e.uploadedOn && !t.uploadedOn ? 0 : e.uploadedOn ? t.uploadedOn ? new Date(t.uploadedOn).getTime() - new Date(e.uploadedOn).getTime() : -1 : 1), [i]), z = h(() => ie(I, n), [I, n]), K = h(
101
101
  () => I.map((e) => ({
102
102
  key: e,
103
103
  sortable: e !== "action"
104
104
  })),
105
105
  [I]
106
- ), T = _(
106
+ ), p = h(
107
107
  () => o ? B(o) : [],
108
108
  [o]
109
- ), Q = h(
109
+ ), Q = _(
110
110
  (e, t) => {
111
111
  switch (t) {
112
112
  case "documentIdentifier":
@@ -137,7 +137,7 @@ const Te = [
137
137
  },
138
138
  [M, n]
139
139
  );
140
- return /* @__PURE__ */ p(x, { children: [
140
+ return /* @__PURE__ */ T(x, { children: [
141
141
  /* @__PURE__ */ r("div", { "data-testid": "documents-table", children: /* @__PURE__ */ r(
142
142
  ee,
143
143
  {
@@ -168,33 +168,33 @@ const Te = [
168
168
  passiveModal: !0,
169
169
  size: "lg",
170
170
  testId: "document-view-modal",
171
- children: /* @__PURE__ */ r("div", { className: d.documentViewerContainer, children: T.map((e, t) => {
172
- const c = R(e.url), m = e.contentType?.toLowerCase().includes("pdf"), S = (e.contentType?.toLowerCase().includes("image") ?? !1) || pe.test(e.url ?? ""), N = $.has(t);
173
- return c === "#" || N ? /* @__PURE__ */ p(
171
+ children: /* @__PURE__ */ r("div", { className: d.documentViewerContainer, children: p.map((e, t) => {
172
+ const c = R(e.url), m = e.contentType?.toLowerCase().includes("pdf"), S = (e.contentType?.toLowerCase().includes("image") ?? !1) || Te.test(e.url ?? ""), N = $.has(t);
173
+ return c === "#" || N ? /* @__PURE__ */ T(
174
174
  "div",
175
175
  {
176
176
  className: d.attachmentError,
177
177
  "data-testid": `attachment-error-${t}`,
178
178
  children: [
179
- T.length > 1 && /* @__PURE__ */ p("p", { className: d.attachmentCounter, children: [
179
+ p.length > 1 && /* @__PURE__ */ T("p", { className: d.attachmentCounter, children: [
180
180
  t + 1,
181
181
  "/",
182
- T.length
182
+ p.length
183
183
  ] }),
184
184
  /* @__PURE__ */ r("p", { children: n("DOCUMENTS_ERROR_LOADING_ATTACHMENT") })
185
185
  ]
186
186
  },
187
187
  `${o.id}-${e.url}`
188
- ) : /* @__PURE__ */ p(
188
+ ) : /* @__PURE__ */ T(
189
189
  "div",
190
190
  {
191
191
  className: d.attachmentItem,
192
192
  "data-testid": `attachment-item-${t}`,
193
193
  children: [
194
- T.length > 1 && /* @__PURE__ */ p("p", { className: d.attachmentCounter, children: [
194
+ p.length > 1 && /* @__PURE__ */ T("p", { className: d.attachmentCounter, children: [
195
195
  t + 1,
196
196
  "/",
197
- T.length
197
+ p.length
198
198
  ] }),
199
199
  S ? /* @__PURE__ */ r(
200
200
  "img",
@@ -1,30 +1,30 @@
1
1
  import { jsx as s, jsxs as W, Fragment as Z } from "react/jsx-runtime";
2
- import { a as ee, u as re, w as ae, e as oe, Q as te, X as se, J as ne, d as de, R as S, m as ie, b as me, c as U, T as ue, C as le, n as ce, f as fe, Y as ye } from "./index-Dv1mIf-k.js";
3
- import { useQueryClient as pe, useQuery as f } from "@tanstack/react-query";
2
+ import { a as ee, u as re, g as ae, d as oe, e as te, f as se, i as ne, j as de, R as S, m as ie, b as me, c as U, C as ue, T as le, n as ce, t as fe, s as ye } from "./index-D3sfUX20.js";
3
+ import { useQueryClient as be, useQuery as f } from "@tanstack/react-query";
4
4
  import { useState as q, useMemo as d, useCallback as y } from "react";
5
- const be = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_customAccordianItem__isszs", A = {
6
- formsTableBody: be,
7
- customAccordianItem: ge
8
- }, Ne = (m) => m ? m.extension?.find(
5
+ const ge = "FormsTable-module_formsTableBody__SvGha", pe = "FormsTable-module_customAccordianItem__isszs", A = {
6
+ formsTableBody: ge,
7
+ customAccordianItem: pe
8
+ }, he = (m) => m ? m.extension?.find(
9
9
  (n) => n.url === ye
10
10
  )?.valueString : void 0, Ie = ({
11
11
  episodeOfCareUuids: m,
12
12
  encounterUuids: n,
13
- config: w
13
+ config: j
14
14
  }) => {
15
15
  const { t } = ee(), u = re(), [l, T] = q(!1), [o, O] = q(null), {
16
16
  numberOfVisits: k,
17
- hideThumbnail: H = !1,
17
+ hideThumbnail: w = !1,
18
18
  forms: c
19
- } = w ?? {}, I = ae(
19
+ } = j ?? {}, I = ae(
20
20
  m,
21
21
  n
22
- ), K = pe(), {
22
+ ), H = be(), {
23
23
  data: F = [],
24
24
  isLoading: L,
25
25
  isError: B,
26
- error: Q,
27
- refetch: j
26
+ error: K,
27
+ refetch: x
28
28
  } = f({
29
29
  queryKey: ["forms", u, m],
30
30
  queryFn: () => oe(u, void 0, k),
@@ -42,22 +42,22 @@ const be = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
42
42
  }), M = y(
43
43
  (e) => E.find((r) => r.name === e)?.uuid,
44
44
  [E]
45
- ), p = d(() => {
45
+ ), b = d(() => {
46
46
  if (o)
47
47
  return M(o.formName);
48
48
  }, [o, M]), {
49
- isLoading: x,
50
- isError: V,
51
- error: b
49
+ isLoading: V,
50
+ isError: $,
51
+ error: g
52
52
  } = f({
53
- queryKey: ["formMetadata", p],
54
- queryFn: () => se(p),
55
- enabled: !!p && l
53
+ queryKey: ["formMetadata", b],
54
+ queryFn: () => se(b),
55
+ enabled: !!b && l
56
56
  }), {
57
- data: g,
58
- isLoading: $,
59
- isError: z,
60
- error: N
57
+ data: p,
58
+ isLoading: z,
59
+ isError: G,
60
+ error: h
61
61
  } = f({
62
62
  queryKey: ["formsEncounterFHIR", o?.encounterUuid],
63
63
  queryFn: () => ne(o.encounterUuid),
@@ -65,19 +65,19 @@ const be = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
65
65
  });
66
66
  de(
67
67
  (e) => {
68
- e.patientUUID === u && e.updatedConcepts.size > 0 && (j(), K.invalidateQueries({ queryKey: ["formsEncounterFHIR"] }));
68
+ e.patientUUID === u && e.updatedConcepts.size > 0 && (x(), H.invalidateQueries({ queryKey: ["formsEncounterFHIR"] }));
69
69
  },
70
70
  [u]
71
71
  );
72
- const G = d(() => !g?.entry || !o?.formName ? [] : g.entry.filter((e) => e.resource?.resourceType === "Observation").map((e) => e.resource).filter((e) => {
73
- const r = Ne(e);
72
+ const Q = d(() => !p?.entry || !o?.formName ? [] : p.entry.filter((e) => e.resource?.resourceType === "Observation").map((e) => e.resource).filter((e) => {
73
+ const r = he(e);
74
74
  return !r || r.includes(o.formName);
75
- }), [g, o?.formName]), J = d(() => {
76
- if (b)
77
- return S(b).message;
78
- if (N)
79
- return S(N).message;
80
- }, [b, N]), R = d(
75
+ }), [p, o?.formName]), P = d(() => {
76
+ if (g)
77
+ return S(g).message;
78
+ if (h)
79
+ return S(h).message;
80
+ }, [g, h]), R = d(
81
81
  () => [
82
82
  { key: "recordedOn", header: t("RECORDED_ON") },
83
83
  { key: "recordedBy", header: t("RECORDED_BY") }
@@ -94,12 +94,12 @@ const be = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
94
94
  (r, a) => {
95
95
  const i = a.formName;
96
96
  r[i] ??= [];
97
- const h = a.providers.map((P) => P.providerName).filter(Boolean).join(", ");
97
+ const N = a.providers.map((X) => X.providerName).filter(Boolean).join(", ");
98
98
  return r[i].push({
99
99
  id: a.encounterUuid,
100
100
  formName: a.formName,
101
101
  recordedOn: ie(a.encounterDateTime, t, !0).formattedResult,
102
- recordedBy: h ?? "--",
102
+ recordedBy: N ?? "--",
103
103
  encounterDateTime: a.encounterDateTime,
104
104
  encounterUuid: a.encounterUuid
105
105
  }), r;
@@ -110,13 +110,13 @@ const be = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
110
110
  ([r, a]) => ({
111
111
  formName: r,
112
112
  records: a.sort(
113
- (i, h) => h.encounterDateTime - i.encounterDateTime
113
+ (i, N) => N.encounterDateTime - i.encounterDateTime
114
114
  )
115
115
  })
116
116
  ).sort((r, a) => r.formName.localeCompare(a.formName));
117
117
  }, [C, t]), v = y((e) => {
118
118
  O(e), T(!0);
119
- }, []), X = y(() => {
119
+ }, []), J = y(() => {
120
120
  T(!1), O(null);
121
121
  }, []), D = y(
122
122
  (e, r) => {
@@ -139,7 +139,7 @@ const be = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
139
139
  ariaLabel: t("FORMS_HEADING"),
140
140
  rows: [],
141
141
  loading: L,
142
- errorStateMessage: B ? Q?.message : void 0,
142
+ errorStateMessage: B ? K?.message : void 0,
143
143
  emptyStateMessage: t("FORMS_UNAVAILABLE"),
144
144
  renderCell: D,
145
145
  className: A.formsTableBody,
@@ -179,7 +179,7 @@ const be = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
179
179
  id: "modalIdForActionAreaLayout",
180
180
  portalId: "main-display-area",
181
181
  open: l,
182
- onRequestClose: X,
182
+ onRequestClose: J,
183
183
  modalHeading: o.formName,
184
184
  modalLabel: `${o.recordedOn} | ${o.recordedBy}`,
185
185
  passiveModal: !0,
@@ -188,13 +188,13 @@ const be = "FormsTable-module_formsTableBody__SvGha", ge = "FormsTable-module_cu
188
188
  children: /* @__PURE__ */ s(
189
189
  fe,
190
190
  {
191
- observations: G,
192
- isLoading: x || $,
193
- isError: V || z,
194
- errorMessage: J,
191
+ observations: Q,
192
+ isLoading: V || z,
193
+ isError: $ || G,
194
+ errorMessage: P,
195
195
  emptyStateMessage: t("NO_FORM_DATA_AVAILABLE"),
196
196
  testIdPrefix: o.formName,
197
- hideThumbnail: H
197
+ hideThumbnail: w
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-n7d56V9h.js";
2
- import { U as d, V as f, W as e } from "./index-Dv1mIf-k.js";
1
+ import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-BKXHiH2D.js";
2
+ import { W as d, X as f, Y as e } from "./index-D3sfUX20.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-n7d56V9h.js";
2
- import { U as v, V as C, W as e } from "./index-Dv1mIf-k.js";
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-BKXHiH2D.js";
2
+ import { W as v, X as C, Y as e } from "./index-D3sfUX20.js";
3
3
  var h = (t) => {
4
4
  const [r, o] = s({
5
5
  prefix: "TanstackQueryDevtools"
@@ -1,12 +1,12 @@
1
- import { jsxs as I, jsx as u } from "react/jsx-runtime";
2
- import { u as M, h as k, a as N, K as q, G, d as Q, i as z, s as X, l as j, z as w, c as x, o as H, g as A, j as P, y as Y, k as J, M as W, S as Z, A as ee } from "./index-Dv1mIf-k.js";
1
+ import { jsxs as N, jsx as u } from "react/jsx-runtime";
2
+ import { u as q, h as w, a as S, k as K, l as k, j as x, v as z, E as M, y as P, z as j, c as G, w as H, P as L, o as J, x as Y, q as W, _ as X, B as Z, L as ee } from "./index-D3sfUX20.js";
3
3
  import { useQueries as ae, useQuery as te } from "@tanstack/react-query";
4
- import { useRef as se, useEffect as $, useMemo as T } from "react";
4
+ import { useRef as se, useEffect as $, useMemo as R } from "react";
5
5
  const D = (a, n, d, l, b, r) => {
6
- const t = P(a, n, b), s = t.value, o = Y(s);
6
+ const t = J(a, n, b), s = t.value, o = Y(s);
7
7
  let i = s;
8
8
  o === "Image" && (i = /* @__PURE__ */ u(
9
- W,
9
+ X,
10
10
  {
11
11
  imageSrc: s,
12
12
  alt: s,
@@ -25,7 +25,7 @@ const D = (a, n, d, l, b, r) => {
25
25
  provider: t.provider
26
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
- J,
28
+ W,
29
29
  {
30
30
  header: t.header,
31
31
  value: i,
@@ -37,7 +37,7 @@ const D = (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
- A,
40
+ L,
41
41
  {
42
42
  title: a.display,
43
43
  id: `grouped-obs-${a.display}-${l}`,
@@ -59,10 +59,10 @@ const D = (a, n, d, l, b, r) => {
59
59
  title: n = "",
60
60
  hideThumbnail: d
61
61
  }) => {
62
- const { t: l } = N(), b = (r, t, s) => {
62
+ const { t: l } = S(), b = (r, t, s) => {
63
63
  const o = H(r.encounterDetails, l);
64
- return /* @__PURE__ */ I(
65
- A,
64
+ return /* @__PURE__ */ N(
65
+ L,
66
66
  {
67
67
  title: o,
68
68
  id: `encounter-${r.encounterId}`,
@@ -105,7 +105,7 @@ const D = (a, n, d, l, b, r) => {
105
105
  )
106
106
  }
107
107
  );
108
- }, ie = "Observations-module_observations__RKSyo", ne = "Observations-module_title__TJL3z", S = {
108
+ }, ie = "Observations-module_observations__RKSyo", ne = "Observations-module_title__TJL3z", I = {
109
109
  observations: ie,
110
110
  title: ne
111
111
  }, de = (a) => ["conceptUuid", a], le = (a, n) => ["observations", a, ...n], pe = ({ config: a }) => {
@@ -113,10 +113,10 @@ const D = (a, n, d, l, b, r) => {
113
113
  conceptNames: d = [],
114
114
  conceptUuid: l = [],
115
115
  hideThumbnail: b = !1
116
- } = n, r = se(/* @__PURE__ */ new Set()), t = M(), { addNotification: s } = k(), { t: o } = N(), i = ae({
116
+ } = n, r = se(/* @__PURE__ */ new Set()), t = q(), { addNotification: s } = w(), { t: o } = S(), i = ae({
117
117
  queries: d.map((e) => ({
118
118
  queryKey: de(e),
119
- queryFn: () => q(e),
119
+ queryFn: () => K(e),
120
120
  enabled: !!e
121
121
  }))
122
122
  });
@@ -132,17 +132,17 @@ const D = (a, n, d, l, b, r) => {
132
132
  } else e.isError || r.current.delete(h);
133
133
  });
134
134
  }, [i, d]);
135
- const m = T(() => i.map((e) => e.data?.uuid).filter((e) => !!e), [i]), p = T(() => [.../* @__PURE__ */ new Set([...m, ...l])], [m, l]), y = T(() => d.length === 0 ? !0 : i.every((e) => !e.isLoading), [i, d.length]), {
135
+ const m = R(() => i.map((e) => e.data?.uuid).filter((e) => !!e), [i]), p = R(() => [.../* @__PURE__ */ new Set([...m, ...l])], [m, l]), y = R(() => d.length === 0 ? !0 : i.every((e) => !e.isLoading), [i, d.length]), {
136
136
  data: c,
137
137
  isLoading: F,
138
- isError: R,
138
+ isError: T,
139
139
  refetch: g
140
140
  } = te({
141
141
  queryKey: le(t, p),
142
- queryFn: () => G(t, p),
142
+ queryFn: () => k(t, p),
143
143
  enabled: !!t && p.length > 0 && y
144
144
  });
145
- Q(
145
+ x(
146
146
  (e) => {
147
147
  e.patientUUID === t && e.updatedConcepts.size > 0 && [...e.updatedConcepts.keys()].some(
148
148
  (h) => p.includes(h)
@@ -150,40 +150,40 @@ const D = (a, n, d, l, b, r) => {
150
150
  },
151
151
  [t, g]
152
152
  ), $(() => {
153
- R && s({
153
+ T && s({
154
154
  title: o("ERROR_DEFAULT_TITLE"),
155
155
  message: o("ERROR_FETCHING_OBSERVATIONS"),
156
156
  type: "error"
157
157
  });
158
- }, [R]);
159
- const O = T(() => {
158
+ }, [T]);
159
+ const O = R(() => {
160
160
  if (!c) return [];
161
- const e = z(c), h = X(e);
162
- return j(h);
163
- }, [c]), L = [
161
+ const e = z(c), h = M(e);
162
+ return P(h);
163
+ }, [c]), A = [
164
164
  { key: "name", header: "name" },
165
165
  { key: "value", header: "value" },
166
166
  { key: "form", header: "form" }
167
- ], f = F || !y, _ = R && y, K = (!c || c.entry?.length === 0 || p.length === 0) && y, C = _ ? o("ERROR_FETCHING_OBSERVATIONS") : null, U = K ? o("NO_OBSERVATIONS_FOUND") : void 0, B = O.length > 0 && !f && !_, E = n.titleTranslationKey, v = E ? o(E) : "";
168
- return /* @__PURE__ */ I(
167
+ ], _ = F || !y, f = T && y, B = (!c || c.entry?.length === 0 || p.length === 0) && y, C = f ? o("ERROR_FETCHING_OBSERVATIONS") : null, Q = B ? o("NO_OBSERVATIONS_FOUND") : void 0, U = O.length > 0 && !_ && !f, E = n.titleTranslationKey, v = E ? o(E) : "";
168
+ return /* @__PURE__ */ N(
169
169
  "div",
170
170
  {
171
171
  id: "observations",
172
172
  "data-testid": E ? `observations-${v}` : "observations",
173
173
  "aria-label": "observations-aria-label",
174
- className: S.observations,
174
+ className: I.observations,
175
175
  children: [
176
176
  /* @__PURE__ */ u(
177
- w,
177
+ j,
178
178
  {
179
179
  id: "observations-title",
180
180
  testId: E ? `observations-title-${v}` : "observations-title",
181
181
  title: v,
182
- className: S.title,
182
+ className: I.title,
183
183
  children: /* @__PURE__ */ u("p", { children: v })
184
184
  }
185
185
  ),
186
- B ? /* @__PURE__ */ u(
186
+ U ? /* @__PURE__ */ u(
187
187
  oe,
188
188
  {
189
189
  groupedData: O,
@@ -191,14 +191,14 @@ const D = (a, n, d, l, b, r) => {
191
191
  hideThumbnail: b
192
192
  }
193
193
  ) : /* @__PURE__ */ u(
194
- x,
194
+ G,
195
195
  {
196
- headers: L,
196
+ headers: A,
197
197
  rows: [],
198
198
  ariaLabel: o("OBSERVATIONS"),
199
- loading: f,
199
+ loading: _,
200
200
  errorStateMessage: C,
201
- emptyStateMessage: U,
201
+ emptyStateMessage: Q,
202
202
  dataTestId: "observations-table"
203
203
  }
204
204
  )
@@ -1,4 +1,4 @@
1
- import { Z as we, $ as z, a0 as xt, a1 as B, V as q, W 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-Dv1mIf-k.js";
1
+ import { Z as we, $ as z, a0 as xt, a1 as B, X as q, Y 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-D3sfUX20.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, D as Qi, p as Ji, q as ec, _ as tc, r as rc, E as nc, H as oc, v as hi, O as ac, x as lc, h as ic, B as cc, I as sc, L as fc, F as pc, N as hc, P as uc } from "./index-Dv1mIf-k.js";
2
+ import { a as ot, r as Qi, A as Ji, D as ec, F as tc, G as rc, H as nc, I as oc, J as hi, V as ac, K as lc, h as ic, M as cc, N as sc, O as fc, Q as pc, S as hc, U as uc } from "./index-D3sfUX20.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";