@bahmni/registration-app 0.0.1-dev.133 → 0.0.1-dev.135

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,5 +1,5 @@
1
1
  import { jsx as t, jsxs as p, Fragment as J } from "react/jsx-runtime";
2
- import { u as W, C as Q, J as Y, I as Z, $ as ee, S as re, R as ae, c as oe, F as te, q as x, D as ne, a as se, b as me, d as de, v as G, h as ie, W as y } from "./index-Gpe9rJ-z.js";
2
+ import { u as W, C as Q, J as Y, I as Z, $ as ee, S as re, R as ae, c as oe, F as te, q as x, D as ne, a as se, b as me, d as de, v as G, h as ie, W as y } from "./index-C2Cjutln.js";
3
3
  import { useQuery as h } from "@tanstack/react-query";
4
4
  import { useState as U, useMemo as $, useCallback as v } from "react";
5
5
  const le = "_formsTableBody_1pd36_1", ce = "_customAccordianItem_1pd36_6", ue = "_formContent_1pd36_18", pe = "_formDetailsContainer_1pd36_25", be = "_observation_1pd36_30", _e = "_groupContainer_1pd36_39", fe = "_rowContainer_1pd36_43", $e = "_groupLabel_1pd36_48", Ne = "_rowLabel_1pd36_58", ge = "_rowValue_1pd36_67", he = "_groupMembers_1pd36_75", ve = "_memberRow_1pd36_81", ye = "_memberLabel_1pd36_86", Ae = "_memberValue_1pd36_94", Me = "_abnormalValue_1pd36_102", Te = "_commentSection_1pd36_110", Re = "_commentText_1pd36_116", Ce = "_nestedGroup_1pd36_125", De = "_nestedGroupLabel_1pd36_132", Le = "_nestedGroupMembers_1pd36_141", o = {
@@ -1,5 +1,5 @@
1
- import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-B2zZigpQ.js";
2
- import { k as d, l as f, m as e } from "./index-Gpe9rJ-z.js";
1
+ import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-3c5FwiSl.js";
2
+ import { k as d, l as f, m as e } from "./index-C2Cjutln.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-B2zZigpQ.js";
2
- import { k as v, l as C, m as e } from "./index-Gpe9rJ-z.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-3c5FwiSl.js";
2
+ import { k as v, l as C, m as e } from "./index-C2Cjutln.js";
3
3
  var h = (t) => {
4
4
  const [r, o] = s({
5
5
  prefix: "TanstackQueryDevtools"
@@ -1,5 +1,5 @@
1
1
  import { jsxs as _, jsx as b } from "react/jsx-runtime";
2
- import { C as F, T as U, u as I, L as X, e as k, o as x, q as K, f as Q, g as D, O as j, j as G, p as H, i as P } from "./index-Gpe9rJ-z.js";
2
+ import { C as F, T as U, u as I, L as X, e as k, o as x, q as K, f as Q, g as D, O as j, j as G, p as H, i as P } from "./index-C2Cjutln.js";
3
3
  import { useQueries as Y, useQuery as Z } from "@tanstack/react-query";
4
4
  import { useRef as z, useEffect as T, useMemo as h } from "react";
5
5
  const J = "normal", W = "http://terminology.hl7.org/CodeSystem/referencerange-meaning", ee = "A", te = "http://terminology.hl7.org/CodeSystem/v3-ObservationInterpretation", ne = (e, n) => e?.date ? Q(e.date, n).formattedResult : n("DATE_ERROR_PARSE"), re = (e) => {
@@ -1,4 +1,4 @@
1
- import { n as we, r as z, s as xt, t as B, l as q, m as y, P as Ro, w as ye, x as R, y as _, z as k, A as N, B as A, E as bs, G as ir, H as $e, K as U, M as Hn, N as Vn, Q as dt, U as D, V as xs, X as cn, Y as Be, Z as ws, _ as qt, a0 as zt, a1 as $s, a2 as Cs, a3 as $n, a4 as Ss, a5 as Nr, a6 as Bt, a7 as zo, a8 as ks, a9 as Es, aa as j, ab as Ur, ac as Ms, ad as Ds, ae as sr, af as As, ag as Ts, ah as zn, ai as Fs, aj as Is, ak as Z, al as Ps, am as Ls } from "./index-Gpe9rJ-z.js";
1
+ import { n as we, r as z, s as xt, t as B, l as q, m as y, P as Ro, w as ye, x as R, y as _, z as k, A as N, B as A, E as bs, G as ir, H as $e, K as U, M as Hn, N as Vn, Q as dt, U as D, V as xs, X as cn, Y as Be, Z as ws, _ as qt, a0 as zt, a1 as $s, a2 as Cs, a3 as $n, a4 as Ss, a5 as Nr, a6 as Bt, a7 as zo, a8 as ks, a9 as Es, aa as j, ab as Ur, ac as Ms, ad as Ds, ae as sr, af as As, ag as Ts, ah as zn, ai as Fs, aj as Is, ak as Z, al as Ps, am as Ls } from "./index-C2Cjutln.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":"useAddressFields.d.ts","sourceRoot":"","sources":["../../src/hooks/useAddressFields.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,YAAY;IAC3B,YAAY,EAAE,MAAM,CAAC;IACrB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,OAAO,CAAC;IAClB,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,MAAM,WAAW,WAAW;IAC1B,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;CAC9B;AAED,MAAM,WAAW,sBAAsB;IACrC,wBAAwB,EAAE,OAAO,CAAC;IAClC,2BAA2B,CAAC,EAAE,MAAM,CAAC;CACtC;AAED,MAAM,WAAW,uBAAuB;IACtC,CAAC,SAAS,EAAE,MAAM,GAAG;QACnB,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,eAAe,CAAC,EAAE,MAAM,CAAC;QACzB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;KACtB,CAAC;CACH;AAED,MAAM,WAAW,oBAAoB;IACnC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,MAAM,CAAC,EAAE,oBAAoB,GAAG,SAAS,CAAC;CAC3C;AAED,wBAAgB,gBAAg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;sBAjCd,MAAM;cACd,MAAM;kBACF,OAAO;;6BAiHP,YAAY,KAAG,OAAO;mCAkElB,MAAM,gBAAgB,oBAAoB;mCA+CN,MAAM,SAAS,MAAM;+BAUzD,MAAM,KAAG,MAAM,GAAG,SAAS;kCA5F3B,MAAM;;iCA2G4B,WAAW;EAoB5D"}
@@ -65807,8 +65807,26 @@ const BC2 = () => {
65807
65807
  }, mp = ({
65808
65808
  testId: t,
65809
65809
  "data-testid": e,
65810
- ...r
65811
- }) => /* @__PURE__ */ le(iw, { ...r, "data-testid": t ?? e }), nr = ({
65810
+ selectedItem: r,
65811
+ clearSelectedOnChange: n = !1,
65812
+ ...a
65813
+ }) => {
65814
+ const [c, i] = fe(
65815
+ r || null
65816
+ );
65817
+ return ue(() => {
65818
+ i(r || null), n && r && queueMicrotask(() => {
65819
+ i(null);
65820
+ });
65821
+ }, [r, n]), /* @__PURE__ */ le(
65822
+ iw,
65823
+ {
65824
+ ...a,
65825
+ selectedItem: c,
65826
+ "data-testid": t ?? e
65827
+ }
65828
+ );
65829
+ }, nr = ({
65812
65830
  testId: t,
65813
65831
  "data-testid": e,
65814
65832
  ...r
@@ -153158,7 +153176,7 @@ const cC1 = (t, e) => ["programs", t, e], LM0 = async (t, e) => {
153158
153176
  };
153159
153177
  sC1.displayName = "UserPrivilegeProvider";
153160
153178
  W2(void 0);
153161
- ur(() => Promise.resolve().then(() => yv0)), ur(() => Promise.resolve().then(() => Jv0)), ur(() => Promise.resolve().then(() => oE0)), ur(() => Promise.resolve().then(() => pM0)), ur(() => import("./FormsTable-CJbdqo4y-DahRHHcM.js")), ur(() => Promise.resolve().then(() => Zy0)), ur(() => import("./Observations-DhWTpv8S-z_x8_Ces.js")), ur(
153179
+ ur(() => Promise.resolve().then(() => yv0)), ur(() => Promise.resolve().then(() => Jv0)), ur(() => Promise.resolve().then(() => oE0)), ur(() => Promise.resolve().then(() => pM0)), ur(() => import("./FormsTable-CJbdqo4y-Bd13-5qt.js")), ur(() => Promise.resolve().then(() => Zy0)), ur(() => import("./Observations-DhWTpv8S-Bb2XuJG2.js")), ur(
153162
153180
  () => Promise.resolve().then(() => zM0)
153163
153181
  ), ur(
153164
153182
  () => Promise.resolve().then(() => cy0)
@@ -154997,7 +155015,7 @@ var hT0 = (t, e = !1) => {
154997
155015
  const e = xC1(() => {
154998
155016
  const r = this, [n] = this.#n, [a] = this.#o, [c] = this.#a, [i] = this.#c, [l] = this.#p, [s] = this.#t;
154999
155017
  let d;
155000
- return this.#i ? d = this.#i : (d = HC1(() => import("./LNWAZHJI-Bhd6tcV_.js")), this.#i = d), qC1(this.#h, this.#r), zC1(d, VC1({
155018
+ return this.#i ? d = this.#i : (d = HC1(() => import("./LNWAZHJI-DvdDpKu_.js")), this.#i = d), qC1(this.#h, this.#r), zC1(d, VC1({
155001
155019
  get queryFlavor() {
155002
155020
  return r.#d;
155003
155021
  },
@@ -155095,7 +155113,7 @@ var hT0 = (t, e = !1) => {
155095
155113
  const e = xC1(() => {
155096
155114
  const r = this, [n] = this.#n, [a] = this.#o, [c] = this.#a, [i] = this.#c, [l] = this.#p, [s] = this.#t, [d] = this.#i;
155097
155115
  let u;
155098
- return this.#l ? u = this.#l : (u = HC1(() => import("./MWZ6AO7Z-B2N1ocE9.js")), this.#l = u), qC1(this.#h, this.#r), zC1(u, VC1({
155116
+ return this.#l ? u = this.#l : (u = HC1(() => import("./MWZ6AO7Z-BXnnaaKn.js")), this.#l = u), qC1(this.#h, this.#r), zC1(u, VC1({
155099
155117
  get queryFlavor() {
155100
155118
  return r.#d;
155101
155119
  },
@@ -155741,24 +155759,26 @@ function NV0(t, e, r) {
155741
155759
  [s]
155742
155760
  ), v = ze(
155743
155761
  (g) => {
155744
- const x = w(g);
155745
- a((V) => {
155746
- const L = { ...V };
155747
- return x.forEach((T) => {
155748
- L[T] = null;
155749
- }), L;
155750
- }), i((V) => {
155751
- const L = { ...V };
155752
- return x.forEach((T) => {
155753
- L[T] = {
155762
+ const V = w(g).filter((L) => s.find(
155763
+ ($) => $.addressField === L
155764
+ )?.isStrictEntry === !0);
155765
+ a((L) => {
155766
+ const T = { ...L };
155767
+ return V.forEach(($) => {
155768
+ T[$] = null;
155769
+ }), T;
155770
+ }), i((L) => {
155771
+ const T = { ...L };
155772
+ return V.forEach(($) => {
155773
+ T[$] = {
155754
155774
  uuid: void 0,
155755
155775
  userGeneratedId: void 0,
155756
155776
  value: null
155757
155777
  };
155758
- }), L;
155778
+ }), T;
155759
155779
  });
155760
155780
  },
155761
- [w]
155781
+ [w, s]
155762
155782
  ), y = ze(
155763
155783
  (g, x) => {
155764
155784
  const V = x.userGeneratedId ?? x.name;
@@ -155791,15 +155811,12 @@ function NV0(t, e, r) {
155791
155811
  }
155792
155812
  },
155793
155813
  [s]
155794
- ), m = ze(
155795
- (g, x) => {
155796
- a((V) => ({ ...V, [g]: x })), v(g), i((V) => ({
155797
- ...V,
155798
- [g]: { ...V[g], value: null }
155799
- }));
155800
- },
155801
- [v]
155802
- ), f = ze(
155814
+ ), m = ze((g, x) => {
155815
+ a((V) => ({ ...V, [g]: x })), i((V) => ({
155816
+ ...V,
155817
+ [g]: { ...V[g], value: null }
155818
+ }));
155819
+ }, []), f = ze(
155803
155820
  (g) => {
155804
155821
  if (!e.showAddressFieldsTopDown)
155805
155822
  return;
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { ap as s, an as p, ao as E } from "./index-Gpe9rJ-z.js";
1
+ import { ap as s, an as p, ao as E } from "./index-C2Cjutln.js";
2
2
  export {
3
3
  s as IDENTIFIER_TYPES_QUERY_KEY,
4
4
  p as RegistrationApp,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bahmni/registration-app",
3
- "version": "0.0.1-dev.133",
3
+ "version": "0.0.1-dev.135",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",