@ampath/esm-dha-workflow-app 4.0.0-next.37 → 4.0.0-next.39

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.
@@ -129,7 +129,7 @@
129
129
  "auxiliaryFiles": [
130
130
  "91.js.map"
131
131
  ],
132
- "hash": "4d2e8a5a058ae30c",
132
+ "hash": "6c1681e222757b13",
133
133
  "childrenByOrder": {}
134
134
  },
135
135
  {
@@ -253,6 +253,31 @@
253
253
  "hash": "00b99bce4e0cdd42",
254
254
  "childrenByOrder": {}
255
255
  },
256
+ {
257
+ "rendered": true,
258
+ "initial": false,
259
+ "entry": false,
260
+ "recorded": false,
261
+ "reason": "split chunk (cache group: default)",
262
+ "size": 175375,
263
+ "sizes": {
264
+ "javascript": 175375
265
+ },
266
+ "names": [],
267
+ "idHints": [],
268
+ "runtime": [
269
+ "@ampath/esm-dha-workflow-app",
270
+ "main"
271
+ ],
272
+ "files": [
273
+ "194.js"
274
+ ],
275
+ "auxiliaryFiles": [
276
+ "194.js.map"
277
+ ],
278
+ "hash": "a03eeab4f1dc489a",
279
+ "childrenByOrder": {}
280
+ },
256
281
  {
257
282
  "rendered": true,
258
283
  "initial": false,
@@ -539,6 +564,30 @@
539
564
  "hash": "1cf020a5c10527cf",
540
565
  "childrenByOrder": {}
541
566
  },
567
+ {
568
+ "rendered": true,
569
+ "initial": false,
570
+ "entry": false,
571
+ "recorded": false,
572
+ "size": 234864,
573
+ "sizes": {
574
+ "javascript": 234864
575
+ },
576
+ "names": [],
577
+ "idHints": [],
578
+ "runtime": [
579
+ "@ampath/esm-dha-workflow-app",
580
+ "main"
581
+ ],
582
+ "files": [
583
+ "701.js"
584
+ ],
585
+ "auxiliaryFiles": [
586
+ "701.js.map"
587
+ ],
588
+ "hash": "ba6debf4d03f3c9a",
589
+ "childrenByOrder": {}
590
+ },
542
591
  {
543
592
  "rendered": true,
544
593
  "initial": false,
@@ -620,9 +669,9 @@
620
669
  "entry": false,
621
670
  "recorded": false,
622
671
  "reason": "split chunk (cache group: default)",
623
- "size": 72252,
672
+ "size": 72545,
624
673
  "sizes": {
625
- "javascript": 72252
674
+ "javascript": 72545
626
675
  },
627
676
  "names": [],
628
677
  "idHints": [],
@@ -636,7 +685,7 @@
636
685
  "auxiliaryFiles": [
637
686
  "752.js.map"
638
687
  ],
639
- "hash": "3678dcc01b4f9a5a",
688
+ "hash": "d10a02876f1d734d",
640
689
  "childrenByOrder": {}
641
690
  },
642
691
  {
@@ -664,7 +713,7 @@
664
713
  "auxiliaryFiles": [
665
714
  "main.js.map"
666
715
  ],
667
- "hash": "575bc9166394b298",
716
+ "hash": "08a3baaae6614ff4",
668
717
  "childrenByOrder": {}
669
718
  },
670
719
  {
@@ -691,31 +740,6 @@
691
740
  "hash": "1bbec8794c0e9005",
692
741
  "childrenByOrder": {}
693
742
  },
694
- {
695
- "rendered": true,
696
- "initial": false,
697
- "entry": false,
698
- "recorded": false,
699
- "reason": "split chunk (cache group: default)",
700
- "size": 165062,
701
- "sizes": {
702
- "javascript": 165062
703
- },
704
- "names": [],
705
- "idHints": [],
706
- "runtime": [
707
- "@ampath/esm-dha-workflow-app",
708
- "main"
709
- ],
710
- "files": [
711
- "849.js"
712
- ],
713
- "auxiliaryFiles": [
714
- "849.js.map"
715
- ],
716
- "hash": "7134baaded99cb1d",
717
- "childrenByOrder": {}
718
- },
719
743
  {
720
744
  "rendered": true,
721
745
  "initial": true,
@@ -743,30 +767,6 @@
743
767
  "hash": "6e062cdfe933c84f",
744
768
  "childrenByOrder": {}
745
769
  },
746
- {
747
- "rendered": true,
748
- "initial": false,
749
- "entry": false,
750
- "recorded": false,
751
- "size": 233317,
752
- "sizes": {
753
- "javascript": 233317
754
- },
755
- "names": [],
756
- "idHints": [],
757
- "runtime": [
758
- "@ampath/esm-dha-workflow-app",
759
- "main"
760
- ],
761
- "files": [
762
- "943.js"
763
- ],
764
- "auxiliaryFiles": [
765
- "943.js.map"
766
- ],
767
- "hash": "245e4b3234073083",
768
- "childrenByOrder": {}
769
- },
770
770
  {
771
771
  "rendered": true,
772
772
  "initial": false,
package/dist/main.js CHANGED
@@ -1 +1 @@
1
- (()=>{var e,r,t,n,o={38091:(e,r,t)=>{"use strict";t.d(r,{moduleName:()=>o});var n=t(25987),o=(n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.Array,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.String,n.Type.String,n.Type.String,"@ampath/esm-dha-workflow-app"),a={featureName:"Consulation Workflow",moduleName:o};t(84767),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(72),t.e(93)]).then(t.bind(t,69093))}),{featureName:"side-nav-workflow-link",moduleName:o}),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(114),t.e(849),t.e(943)]).then(t.bind(t,76943))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(72),t.e(114),t.e(849),t.e(709)]).then(t.bind(t,50849))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(752),t.e(15)]).then(t.bind(t,45015))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(752),t.e(339)]).then(t.bind(t,88339))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(752),t.e(833)]).then(t.bind(t,41833))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(752),t.e(729)]).then(t.bind(t,71729))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(72),t.e(76),t.e(420)]).then(t.bind(t,27420))}),{featureName:"workflow-registry-link",moduleName:o})},84767:(e,r,t)=>{var n={"./am.json":[81197,197],"./en.json":[34300,300],"./es.json":[93099,99],"./fr.json":[94055,55],"./he.json":[84652,652],"./km.json":[54335,335]};function o(e){if(!t.o(n,e))return Promise.resolve().then((()=>{var r=new Error("Cannot find module '"+e+"'");throw r.code="MODULE_NOT_FOUND",r}));var r=n[e],o=r[0];return t.e(r[1]).then((()=>t(o)))}o.keys=()=>Object.keys(n),o.id=84767,e.exports=o}},a={};function i(e){var r=a[e];if(void 0!==r)return r.exports;var t=a[e]={id:e,exports:{}};return o[e].call(t.exports,t,t.exports,i),t.exports}i.m=o,i.c=a,i.n=e=>{var r=e&&e.__esModule?()=>e.default:()=>e;return i.d(r,{a:r}),r},r=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,i.t=function(t,n){if(1&n&&(t=this(t)),8&n)return t;if("object"==typeof t&&t){if(4&n&&t.__esModule)return t;if(16&n&&"function"==typeof t.then)return t}var o=Object.create(null);i.r(o);var a={};e=e||[null,r({}),r([]),r(r)];for(var u=2&n&&t;"object"==typeof u&&!~e.indexOf(u);u=r(u))Object.getOwnPropertyNames(u).forEach((e=>a[e]=()=>t[e]));return a.default=()=>t,i.d(o,a),o},i.d=(e,r)=>{for(var t in r)i.o(r,t)&&!i.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:r[t]})},i.f={},i.e=e=>Promise.all(Object.keys(i.f).reduce(((r,t)=>(i.f[t](e,r),r)),[])),i.u=e=>e+".js",i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),i.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r),t={},n="@ampath/esm-dha-workflow-app:",i.l=(e,r,o,a)=>{if(t[e])t[e].push(r);else{var u,l;if(void 0!==o)for(var c=document.getElementsByTagName("script"),p=0;p<c.length;p++){var s=c[p];if(s.getAttribute("src")==e||s.getAttribute("data-webpack")==n+o){u=s;break}}u||(l=!0,(u=document.createElement("script")).charset="utf-8",u.timeout=120,i.nc&&u.setAttribute("nonce",i.nc),u.setAttribute("data-webpack",n+o),u.src=e),t[e]=[r];var f=(r,n)=>{u.onerror=u.onload=null,clearTimeout(d);var o=t[e];if(delete t[e],u.parentNode&&u.parentNode.removeChild(u),o&&o.forEach((e=>e(n))),r)return r(n)},d=setTimeout(f.bind(null,void 0,{type:"timeout",target:u}),12e4);u.onerror=f.bind(null,u.onerror),u.onload=f.bind(null,u.onload),l&&document.head.appendChild(u)}},i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{i.S={};var e={},r={};i.I=(t,n)=>{n||(n=[]);var o=r[t];if(o||(o=r[t]={}),!(n.indexOf(o)>=0)){if(n.push(o),e[t])return e[t];i.o(i.S,t)||(i.S[t]={});var a=i.S[t],u="@ampath/esm-dha-workflow-app",l=(e,r,t,n)=>{var o=a[e]=a[e]||{},i=o[r];(!i||!i.loaded&&(!n!=!i.eager?n:u>i.from))&&(o[r]={get:t,from:u,eager:!!n})},c=[];return"default"===t&&(l("@openmrs/esm-framework","8.0.1-pre.3529",(()=>Promise.all([i.e(961),i.e(246),i.e(104),i.e(710),i.e(72),i.e(76),i.e(231),i.e(114),i.e(83),i.e(987)]).then((()=>()=>i(48710))))),l("dayjs","1.11.13",(()=>i.e(353).then((()=>()=>i(74353))))),l("react-i18next","16.0.0",(()=>Promise.all([i.e(255),i.e(72)]).then((()=>()=>i(77255))))),l("react-router-dom","6.30.1",(()=>Promise.all([i.e(961),i.e(282),i.e(72)]).then((()=>()=>i(20282))))),l("react","18.3.1",(()=>i.e(540).then((()=>()=>i(96540))))),l("rxjs","6.6.7",(()=>i.e(184).then((()=>()=>i(63184)))))),e[t]=c.length?Promise.all(c).then((()=>e[t]=1)):1}}})(),(()=>{var e;i.g.importScripts&&(e=i.g.location+"");var r=i.g.document;if(!e&&r&&(r.currentScript&&"SCRIPT"===r.currentScript.tagName.toUpperCase()&&(e=r.currentScript.src),!e)){var t=r.getElementsByTagName("script");if(t.length)for(var n=t.length-1;n>-1&&(!e||!/^http(s?):/.test(e));)e=t[n--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),i.p=e})(),(()=>{var e=e=>{var r=e=>e.split(".").map((e=>+e==e?+e:e)),t=/^([^-+]+)?(?:-([^+]+))?(?:\+(.+))?$/.exec(e),n=t[1]?r(t[1]):[];return t[2]&&(n.length++,n.push.apply(n,r(t[2]))),t[3]&&(n.push([]),n.push.apply(n,r(t[3]))),n},r=e=>{var t=e[0],n="";if(1===e.length)return"*";if(t+.5){n+=0==t?">=":-1==t?"<":1==t?"^":2==t?"~":t>0?"=":"!=";for(var o=1,a=1;a<e.length;a++)o--,n+="u"==(typeof(u=e[a]))[0]?"-":(o>0?".":"")+(o=2,u);return n}var i=[];for(a=1;a<e.length;a++){var u=e[a];i.push(0===u?"not("+l()+")":1===u?"("+l()+" || "+l()+")":2===u?i.pop()+" "+i.pop():r(u))}return l();function l(){return i.pop().replace(/^\((.+)\)$/,"$1")}},t=(r,n)=>{if(0 in r){n=e(n);var o=r[0],a=o<0;a&&(o=-o-1);for(var i=0,u=1,l=!0;;u++,i++){var c,p,s=u<r.length?(typeof r[u])[0]:"";if(i>=n.length||"o"==(p=(typeof(c=n[i]))[0]))return!l||("u"==s?u>o&&!a:""==s!=a);if("u"==p){if(!l||"u"!=s)return!1}else if(l)if(s==p)if(u<=o){if(c!=r[u])return!1}else{if(a?c>r[u]:c<r[u])return!1;c!=r[u]&&(l=!1)}else if("s"!=s&&"n"!=s){if(a||u<=o)return!1;l=!1,u--}else{if(u<=o||p<s!=a)return!1;l=!1}else"s"!=s&&"n"!=s&&(l=!1,u--)}}var f=[],d=f.pop.bind(f);for(i=1;i<r.length;i++){var h=r[i];f.push(1==h?d()|d():2==h?d()&d():h?t(h,n):!d())}return!!d()},n=(r,t,n)=>{var o=n?(e=>Object.keys(e).reduce(((r,t)=>(e[t].eager&&(r[t]=e[t]),r)),{}))(r[t]):r[t];return Object.keys(o).reduce(((r,t)=>!r||!o[r].loaded&&((r,t)=>{r=e(r),t=e(t);for(var n=0;;){if(n>=r.length)return n<t.length&&"u"!=(typeof t[n])[0];var o=r[n],a=(typeof o)[0];if(n>=t.length)return"u"==a;var i=t[n],u=(typeof i)[0];if(a!=u)return"o"==a&&"n"==u||"s"==u||"u"==a;if("o"!=a&&"u"!=a&&o!=i)return o<i;n++}})(r,t)?t:r),0)},o=(e,r,t)=>t?t():((e,r)=>(e=>{throw new Error(e)})("Shared module "+r+" doesn't exist in shared scope "+e))(e,r),a=(e=>function(r,t,n,o,a){var u=i.I(r);return u&&u.then&&!n?u.then(e.bind(e,r,i.S[r],t,!1,o,a)):e(r,i.S[r],t,n,o,a)})(((e,a,u,l,c,p)=>{if(!((e,r)=>e&&i.o(e,r))(a,u))return o(e,u,p);var s,f,d=n(a,u,l);return t(c,d)||(f=((e,t,n,o)=>"Unsatisfied version "+n+" from "+(n&&e[t][n].from)+" of shared singleton module "+t+" (required "+r(o)+")")(a,u,d,c),"undefined"!=typeof console&&console.warn&&console.warn(f)),(s=a[u][d]).loaded=1,s.get()})),u={},l={25987:()=>a("default","@openmrs/esm-framework",!1,[0],(()=>Promise.all([i.e(961),i.e(246),i.e(104),i.e(710),i.e(72),i.e(76),i.e(231),i.e(114),i.e(83)]).then((()=>()=>i(48710))))),16072:()=>a("default","react",!1,[1,18],(()=>i.e(540).then((()=>()=>i(96540))))),2076:()=>a("default","react-i18next",!1,[1,16],(()=>i.e(255).then((()=>()=>i(77255))))),70231:()=>a("default","dayjs",!1,[1,1],(()=>i.e(353).then((()=>()=>i(74353))))),27114:()=>a("default","react-router-dom",!1,[1,6],(()=>i.e(282).then((()=>()=>i(20282))))),53083:()=>a("default","rxjs",!1,[1,6],(()=>i.e(184).then((()=>()=>i(63184)))))};[25987].forEach((e=>{i.m[e]=r=>{u[e]=0,delete i.c[e];var t=l[e]();if("function"!=typeof t)throw new Error("Shared module is not available for eager consumption: "+e);r.exports=t()}}));var c={72:[16072],76:[2076],83:[53083],114:[27114],231:[70231],792:[25987],987:[25987]},p={};i.f.consumes=(e,r)=>{i.o(c,e)&&c[e].forEach((e=>{if(i.o(u,e))return r.push(u[e]);if(!p[e]){var t=r=>{u[e]=0,i.m[e]=t=>{delete i.c[e],t.exports=r()}};p[e]=!0;var n=r=>{delete u[e],i.m[e]=t=>{throw delete i.c[e],r}};try{var o=l[e]();o.then?r.push(u[e]=o.then(t).catch(n)):t(o)}catch(e){n(e)}}}))}})(),(()=>{var e={91:0,792:0,987:0};i.f.j=(r,t)=>{var n=i.o(e,r)?e[r]:void 0;if(0!==n)if(n)t.push(n[2]);else if(/^(114|231|72|76|83|987)$/.test(r))e[r]=0;else{var o=new Promise(((t,o)=>n=e[r]=[t,o]));t.push(n[2]=o);var a=i.p+i.u(r),u=new Error;i.l(a,(t=>{if(i.o(e,r)&&(0!==(n=e[r])&&(e[r]=void 0),n)){var o=t&&("load"===t.type?"missing":t.type),a=t&&t.target&&t.target.src;u.message="Loading chunk "+r+" failed.\n("+o+": "+a+")",u.name="ChunkLoadError",u.type=o,u.request=a,n[1](u)}}),"chunk-"+r,r)}};var r=(r,t)=>{var n,o,[a,u,l]=t,c=0;if(a.some((r=>0!==e[r]))){for(n in u)i.o(u,n)&&(i.m[n]=u[n]);l&&l(i)}for(r&&r(t);c<a.length;c++)o=a[c],i.o(e,o)&&e[o]&&e[o][0](),e[o]=0},t=globalThis.webpackChunk_ampath_esm_dha_workflow_app=globalThis.webpackChunk_ampath_esm_dha_workflow_app||[];t.forEach(r.bind(null,0)),t.push=r.bind(null,t.push.bind(t))})(),i.nc=void 0,i(38091)})();
1
+ (()=>{var e,r,t,n,o={38091:(e,r,t)=>{"use strict";t.d(r,{moduleName:()=>o});var n=t(25987),o=(n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.Array,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.ConceptUuid,n.Type.String,n.Type.String,n.Type.String,"@ampath/esm-dha-workflow-app"),a={featureName:"Consulation Workflow",moduleName:o};t(84767),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(72),t.e(93)]).then(t.bind(t,69093))}),{featureName:"side-nav-workflow-link",moduleName:o}),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(114),t.e(194),t.e(701)]).then(t.bind(t,75701))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(72),t.e(114),t.e(194),t.e(709)]).then(t.bind(t,36194))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(752),t.e(15)]).then(t.bind(t,45015))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(752),t.e(339)]).then(t.bind(t,88339))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(752),t.e(833)]).then(t.bind(t,41833))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(961),t.e(246),t.e(104),t.e(72),t.e(76),t.e(231),t.e(752),t.e(729)]).then(t.bind(t,71729))}),a),(0,n.getAsyncLifecycle)((function(){return Promise.all([t.e(72),t.e(76),t.e(420)]).then(t.bind(t,27420))}),{featureName:"workflow-registry-link",moduleName:o})},84767:(e,r,t)=>{var n={"./am.json":[81197,197],"./en.json":[34300,300],"./es.json":[93099,99],"./fr.json":[94055,55],"./he.json":[84652,652],"./km.json":[54335,335]};function o(e){if(!t.o(n,e))return Promise.resolve().then((()=>{var r=new Error("Cannot find module '"+e+"'");throw r.code="MODULE_NOT_FOUND",r}));var r=n[e],o=r[0];return t.e(r[1]).then((()=>t(o)))}o.keys=()=>Object.keys(n),o.id=84767,e.exports=o}},a={};function i(e){var r=a[e];if(void 0!==r)return r.exports;var t=a[e]={id:e,exports:{}};return o[e].call(t.exports,t,t.exports,i),t.exports}i.m=o,i.c=a,i.n=e=>{var r=e&&e.__esModule?()=>e.default:()=>e;return i.d(r,{a:r}),r},r=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,i.t=function(t,n){if(1&n&&(t=this(t)),8&n)return t;if("object"==typeof t&&t){if(4&n&&t.__esModule)return t;if(16&n&&"function"==typeof t.then)return t}var o=Object.create(null);i.r(o);var a={};e=e||[null,r({}),r([]),r(r)];for(var u=2&n&&t;"object"==typeof u&&!~e.indexOf(u);u=r(u))Object.getOwnPropertyNames(u).forEach((e=>a[e]=()=>t[e]));return a.default=()=>t,i.d(o,a),o},i.d=(e,r)=>{for(var t in r)i.o(r,t)&&!i.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:r[t]})},i.f={},i.e=e=>Promise.all(Object.keys(i.f).reduce(((r,t)=>(i.f[t](e,r),r)),[])),i.u=e=>e+".js",i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),i.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r),t={},n="@ampath/esm-dha-workflow-app:",i.l=(e,r,o,a)=>{if(t[e])t[e].push(r);else{var u,l;if(void 0!==o)for(var c=document.getElementsByTagName("script"),p=0;p<c.length;p++){var s=c[p];if(s.getAttribute("src")==e||s.getAttribute("data-webpack")==n+o){u=s;break}}u||(l=!0,(u=document.createElement("script")).charset="utf-8",u.timeout=120,i.nc&&u.setAttribute("nonce",i.nc),u.setAttribute("data-webpack",n+o),u.src=e),t[e]=[r];var f=(r,n)=>{u.onerror=u.onload=null,clearTimeout(d);var o=t[e];if(delete t[e],u.parentNode&&u.parentNode.removeChild(u),o&&o.forEach((e=>e(n))),r)return r(n)},d=setTimeout(f.bind(null,void 0,{type:"timeout",target:u}),12e4);u.onerror=f.bind(null,u.onerror),u.onload=f.bind(null,u.onload),l&&document.head.appendChild(u)}},i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{i.S={};var e={},r={};i.I=(t,n)=>{n||(n=[]);var o=r[t];if(o||(o=r[t]={}),!(n.indexOf(o)>=0)){if(n.push(o),e[t])return e[t];i.o(i.S,t)||(i.S[t]={});var a=i.S[t],u="@ampath/esm-dha-workflow-app",l=(e,r,t,n)=>{var o=a[e]=a[e]||{},i=o[r];(!i||!i.loaded&&(!n!=!i.eager?n:u>i.from))&&(o[r]={get:t,from:u,eager:!!n})},c=[];return"default"===t&&(l("@openmrs/esm-framework","8.0.1-pre.3529",(()=>Promise.all([i.e(961),i.e(246),i.e(104),i.e(710),i.e(72),i.e(76),i.e(231),i.e(114),i.e(83),i.e(987)]).then((()=>()=>i(48710))))),l("dayjs","1.11.13",(()=>i.e(353).then((()=>()=>i(74353))))),l("react-i18next","16.0.0",(()=>Promise.all([i.e(255),i.e(72)]).then((()=>()=>i(77255))))),l("react-router-dom","6.30.1",(()=>Promise.all([i.e(961),i.e(282),i.e(72)]).then((()=>()=>i(20282))))),l("react","18.3.1",(()=>i.e(540).then((()=>()=>i(96540))))),l("rxjs","6.6.7",(()=>i.e(184).then((()=>()=>i(63184)))))),e[t]=c.length?Promise.all(c).then((()=>e[t]=1)):1}}})(),(()=>{var e;i.g.importScripts&&(e=i.g.location+"");var r=i.g.document;if(!e&&r&&(r.currentScript&&"SCRIPT"===r.currentScript.tagName.toUpperCase()&&(e=r.currentScript.src),!e)){var t=r.getElementsByTagName("script");if(t.length)for(var n=t.length-1;n>-1&&(!e||!/^http(s?):/.test(e));)e=t[n--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),i.p=e})(),(()=>{var e=e=>{var r=e=>e.split(".").map((e=>+e==e?+e:e)),t=/^([^-+]+)?(?:-([^+]+))?(?:\+(.+))?$/.exec(e),n=t[1]?r(t[1]):[];return t[2]&&(n.length++,n.push.apply(n,r(t[2]))),t[3]&&(n.push([]),n.push.apply(n,r(t[3]))),n},r=e=>{var t=e[0],n="";if(1===e.length)return"*";if(t+.5){n+=0==t?">=":-1==t?"<":1==t?"^":2==t?"~":t>0?"=":"!=";for(var o=1,a=1;a<e.length;a++)o--,n+="u"==(typeof(u=e[a]))[0]?"-":(o>0?".":"")+(o=2,u);return n}var i=[];for(a=1;a<e.length;a++){var u=e[a];i.push(0===u?"not("+l()+")":1===u?"("+l()+" || "+l()+")":2===u?i.pop()+" "+i.pop():r(u))}return l();function l(){return i.pop().replace(/^\((.+)\)$/,"$1")}},t=(r,n)=>{if(0 in r){n=e(n);var o=r[0],a=o<0;a&&(o=-o-1);for(var i=0,u=1,l=!0;;u++,i++){var c,p,s=u<r.length?(typeof r[u])[0]:"";if(i>=n.length||"o"==(p=(typeof(c=n[i]))[0]))return!l||("u"==s?u>o&&!a:""==s!=a);if("u"==p){if(!l||"u"!=s)return!1}else if(l)if(s==p)if(u<=o){if(c!=r[u])return!1}else{if(a?c>r[u]:c<r[u])return!1;c!=r[u]&&(l=!1)}else if("s"!=s&&"n"!=s){if(a||u<=o)return!1;l=!1,u--}else{if(u<=o||p<s!=a)return!1;l=!1}else"s"!=s&&"n"!=s&&(l=!1,u--)}}var f=[],d=f.pop.bind(f);for(i=1;i<r.length;i++){var h=r[i];f.push(1==h?d()|d():2==h?d()&d():h?t(h,n):!d())}return!!d()},n=(r,t,n)=>{var o=n?(e=>Object.keys(e).reduce(((r,t)=>(e[t].eager&&(r[t]=e[t]),r)),{}))(r[t]):r[t];return Object.keys(o).reduce(((r,t)=>!r||!o[r].loaded&&((r,t)=>{r=e(r),t=e(t);for(var n=0;;){if(n>=r.length)return n<t.length&&"u"!=(typeof t[n])[0];var o=r[n],a=(typeof o)[0];if(n>=t.length)return"u"==a;var i=t[n],u=(typeof i)[0];if(a!=u)return"o"==a&&"n"==u||"s"==u||"u"==a;if("o"!=a&&"u"!=a&&o!=i)return o<i;n++}})(r,t)?t:r),0)},o=(e,r,t)=>t?t():((e,r)=>(e=>{throw new Error(e)})("Shared module "+r+" doesn't exist in shared scope "+e))(e,r),a=(e=>function(r,t,n,o,a){var u=i.I(r);return u&&u.then&&!n?u.then(e.bind(e,r,i.S[r],t,!1,o,a)):e(r,i.S[r],t,n,o,a)})(((e,a,u,l,c,p)=>{if(!((e,r)=>e&&i.o(e,r))(a,u))return o(e,u,p);var s,f,d=n(a,u,l);return t(c,d)||(f=((e,t,n,o)=>"Unsatisfied version "+n+" from "+(n&&e[t][n].from)+" of shared singleton module "+t+" (required "+r(o)+")")(a,u,d,c),"undefined"!=typeof console&&console.warn&&console.warn(f)),(s=a[u][d]).loaded=1,s.get()})),u={},l={25987:()=>a("default","@openmrs/esm-framework",!1,[0],(()=>Promise.all([i.e(961),i.e(246),i.e(104),i.e(710),i.e(72),i.e(76),i.e(231),i.e(114),i.e(83)]).then((()=>()=>i(48710))))),16072:()=>a("default","react",!1,[1,18],(()=>i.e(540).then((()=>()=>i(96540))))),2076:()=>a("default","react-i18next",!1,[1,16],(()=>i.e(255).then((()=>()=>i(77255))))),70231:()=>a("default","dayjs",!1,[1,1],(()=>i.e(353).then((()=>()=>i(74353))))),27114:()=>a("default","react-router-dom",!1,[1,6],(()=>i.e(282).then((()=>()=>i(20282))))),53083:()=>a("default","rxjs",!1,[1,6],(()=>i.e(184).then((()=>()=>i(63184)))))};[25987].forEach((e=>{i.m[e]=r=>{u[e]=0,delete i.c[e];var t=l[e]();if("function"!=typeof t)throw new Error("Shared module is not available for eager consumption: "+e);r.exports=t()}}));var c={72:[16072],76:[2076],83:[53083],114:[27114],231:[70231],792:[25987],987:[25987]},p={};i.f.consumes=(e,r)=>{i.o(c,e)&&c[e].forEach((e=>{if(i.o(u,e))return r.push(u[e]);if(!p[e]){var t=r=>{u[e]=0,i.m[e]=t=>{delete i.c[e],t.exports=r()}};p[e]=!0;var n=r=>{delete u[e],i.m[e]=t=>{throw delete i.c[e],r}};try{var o=l[e]();o.then?r.push(u[e]=o.then(t).catch(n)):t(o)}catch(e){n(e)}}}))}})(),(()=>{var e={91:0,792:0,987:0};i.f.j=(r,t)=>{var n=i.o(e,r)?e[r]:void 0;if(0!==n)if(n)t.push(n[2]);else if(/^(114|231|72|76|83|987)$/.test(r))e[r]=0;else{var o=new Promise(((t,o)=>n=e[r]=[t,o]));t.push(n[2]=o);var a=i.p+i.u(r),u=new Error;i.l(a,(t=>{if(i.o(e,r)&&(0!==(n=e[r])&&(e[r]=void 0),n)){var o=t&&("load"===t.type?"missing":t.type),a=t&&t.target&&t.target.src;u.message="Loading chunk "+r+" failed.\n("+o+": "+a+")",u.name="ChunkLoadError",u.type=o,u.request=a,n[1](u)}}),"chunk-"+r,r)}};var r=(r,t)=>{var n,o,[a,u,l]=t,c=0;if(a.some((r=>0!==e[r]))){for(n in u)i.o(u,n)&&(i.m[n]=u[n]);l&&l(i)}for(r&&r(t);c<a.length;c++)o=a[c],i.o(e,o)&&e[o]&&e[o][0](),e[o]=0},t=globalThis.webpackChunk_ampath_esm_dha_workflow_app=globalThis.webpackChunk_ampath_esm_dha_workflow_app||[];t.forEach(r.bind(null,0)),t.push=r.bind(null,t.push.bind(t))})(),i.nc=void 0,i(38091)})();
package/dist/routes.json CHANGED
@@ -1 +1 @@
1
- {"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{},"pages":[{"component":"root","route":"home","online":true,"offline":true}],"extensions":[{"component":"workflowRegistryLink","name":"workflow-registry-link","slot":"app-menu-slot","online":true,"offline":true},{"component":"navLinks","name":"side-nav-workflow-links","slot":"dha-workflow-slot","online":true,"offline":true},{"name":"metrics-card-patients-in-waiting","component":"waitingPatientsExtension","slot":"clinic-metrics-slot","order":1},{"name":"metrics-card-patients-attended-to","component":"attendedToPatientsExtension","slot":"clinic-metrics-slot","order":2},{"name":"metrics-card-patients-in-waiting","component":"triageWaitingPatientsExtension","slot":"triage-metrics-slot","order":1},{"name":"metrics-card-patients-attended-to","component":"triageAttendedToPatientsExtension","slot":"triage-metrics-slot","order":2}],"modals":[{"name":"sign-off-queue-entry-modal","component":"signOffModal"}],"version":"4.0.0-next.37"}
1
+ {"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{},"pages":[{"component":"root","route":"home","online":true,"offline":true}],"extensions":[{"component":"workflowRegistryLink","name":"workflow-registry-link","slot":"app-menu-slot","online":true,"offline":true},{"component":"navLinks","name":"side-nav-workflow-links","slot":"dha-workflow-slot","online":true,"offline":true},{"name":"metrics-card-patients-in-waiting","component":"waitingPatientsExtension","slot":"clinic-metrics-slot","order":1},{"name":"metrics-card-patients-attended-to","component":"attendedToPatientsExtension","slot":"clinic-metrics-slot","order":2},{"name":"metrics-card-patients-in-waiting","component":"triageWaitingPatientsExtension","slot":"triage-metrics-slot","order":1},{"name":"metrics-card-patients-attended-to","component":"triageAttendedToPatientsExtension","slot":"triage-metrics-slot","order":2}],"modals":[{"name":"sign-off-queue-entry-modal","component":"signOffModal"}],"version":"4.0.0-next.39"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ampath/esm-dha-workflow-app",
3
- "version": "4.0.0-next.37",
3
+ "version": "4.0.0-next.39",
4
4
  "license": "MPL-2.0",
5
5
  "description": "An OpenMRS seed application for building microfrontends",
6
6
  "browser": "dist/esm-dha-workflow-app.js",
@@ -0,0 +1,18 @@
1
+ import React from 'react';
2
+ import ServiceQueueComponent from '../../../service-queues/service-queue/service-queue.component';
3
+ import { QUEUE_SERVICE_UUIDS } from '../../../shared/constants/concepts';
4
+
5
+ interface MchConsultationProps {}
6
+ const MchConsultation: React.FC<MchConsultationProps> = () => {
7
+ return (
8
+ <>
9
+ <div>
10
+ <ServiceQueueComponent
11
+ serviceTypeUuid={QUEUE_SERVICE_UUIDS.MCH_CLINICAL_CONSULTATION_SERVICE_UUID}
12
+ title="MCH Consultation"
13
+ />
14
+ </div>
15
+ </>
16
+ );
17
+ };
18
+ export default MchConsultation;
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ import ServiceQueueComponent from '../../../service-queues/service-queue/service-queue.component';
3
+ import { QUEUE_SERVICE_UUIDS } from '../../../shared/constants/concepts';
4
+
5
+ interface TriageProps {}
6
+ const MchTriage: React.FC<TriageProps> = () => {
7
+ return (
8
+ <>
9
+ <div>
10
+ <ServiceQueueComponent serviceTypeUuid={QUEUE_SERVICE_UUIDS.MCH_TRIAGE_SERVICE_UUID} title="MCH Triage" />
11
+ </div>
12
+ </>
13
+ );
14
+ };
15
+ export default MchTriage;
@@ -18,7 +18,7 @@ import {
18
18
  import styles from './send-to-triage.modal.scss';
19
19
  import { type Patient, useVisitTypes, useSession, showSnackbar, type VisitType } from '@openmrs/esm-framework';
20
20
  import { type HieClient, type CreateVisitDto, type QueueEntryDto, type ServiceQueue } from '../../types';
21
- import { createQueueEntry, fetchServiceQueuesByLocationUuid } from '../../../resources/queue.resource';
21
+ import { createQueueEntry, getFacilityServiceQueues } from '../../../resources/queue.resource';
22
22
  import { QUEUE_PRIORITIES_UUIDS, QUEUE_STATUS_UUIDS } from '../../../shared/constants/concepts';
23
23
  import { createVisit } from '../../../resources/visit.resource';
24
24
 
@@ -88,7 +88,7 @@ const SendToTriageModal: React.FC<SendToTriageModalProps> = ({
88
88
  uuid: QUEUE_STATUS_UUIDS.WAITING_UUID,
89
89
  },
90
90
  priority: {
91
- uuid: selectedPriority,
91
+ uuid: selectedPriority ?? QUEUE_PRIORITIES_UUIDS.NORMAL_PRIORITY_UUID,
92
92
  },
93
93
  queue: {
94
94
  uuid: selectedServiceQueue,
@@ -105,12 +105,6 @@ const SendToTriageModal: React.FC<SendToTriageModalProps> = ({
105
105
  const onPatientSelect = (patient: Patient) => {
106
106
  setSelectedPatient(patient);
107
107
  };
108
- const getServiceQueues = async () => {
109
- const resp = await fetchServiceQueuesByLocationUuid(locationUuid);
110
- if (resp && resp.results) {
111
- setServiceQueues(resp.results);
112
- }
113
- };
114
108
  const visitTypeChangeHandler = (selectedVisitType: { selectedItem: { id: string; text: string } }) => {
115
109
  const vt = selectedVisitType.selectedItem.id;
116
110
  setSelectedVisitType(vt);
@@ -178,6 +172,20 @@ const SendToTriageModal: React.FC<SendToTriageModalProps> = ({
178
172
  };
179
173
  });
180
174
  }
175
+ async function getServiceQueues() {
176
+ try {
177
+ const sqs = await getFacilityServiceQueues(locationUuid);
178
+ if (sqs.length > 0) {
179
+ setServiceQueues(sqs);
180
+ }
181
+ } catch (e) {
182
+ showSnackbar({
183
+ kind: 'error',
184
+ title: 'An error occurred while fetching service queues',
185
+ subtitle: e.message ?? 'An error occurred while fetching service queues, please try agin',
186
+ });
187
+ }
188
+ }
181
189
 
182
190
  return (
183
191
  <>
@@ -237,7 +245,7 @@ const SendToTriageModal: React.FC<SendToTriageModalProps> = ({
237
245
  <SelectItem value="" text="Select" />;
238
246
  {serviceQueues &&
239
247
  serviceQueues.map((sq) => {
240
- return <SelectItem value={sq.uuid} text={sq.display} />;
248
+ return <SelectItem value={sq.uuid} text={`${sq.display} (${sq.location.display ?? ''})`} />;
241
249
  })}
242
250
  </Select>
243
251
  </div>
@@ -1,5 +1,6 @@
1
1
  import { openmrsFetch, restBaseUrl } from '@openmrs/esm-framework';
2
2
  import { type QueueEntryDto, type ServiceQueueApiResponse } from '../registry/types';
3
+ import { getLocationByUuid } from '../shared/services/location.resource';
3
4
 
4
5
  export async function fetchServiceQueuesByLocationUuid<T>(locationUuid: string): Promise<ServiceQueueApiResponse> {
5
6
  const url = `${restBaseUrl}/queue`;
@@ -35,3 +36,25 @@ export async function createQueueEntry(createQueueEntryDto: QueueEntryDto) {
35
36
 
36
37
  return response.json();
37
38
  }
39
+
40
+ export async function getFacilityServiceQueues(locationUuid: string) {
41
+ const currentLocation = await getLocationByUuid(locationUuid);
42
+ if (!currentLocation) return;
43
+ const parentLocation = currentLocation.parentLocation;
44
+ //get child locations
45
+ if (!parentLocation) return;
46
+ const parentLocationDetail = await getLocationByUuid(parentLocation.uuid);
47
+ const childLocations = parentLocationDetail.childLocations ?? [];
48
+ const childLocationUuids =
49
+ childLocations.map((c) => {
50
+ return c.uuid;
51
+ }) ?? [];
52
+ let sqs = [];
53
+ if (childLocationUuids.length > 0) {
54
+ for (let i = 0; i < childLocationUuids.length; i++) {
55
+ const s = await fetchServiceQueuesByLocationUuid(childLocationUuids[i]);
56
+ sqs = [...sqs, ...s.results];
57
+ }
58
+ }
59
+ return sqs;
60
+ }
@@ -12,6 +12,8 @@ import Consultation from './service-queues/consultation/consultation.component';
12
12
  import Dashboard from './dashboard/dashboard.component';
13
13
  import AccountingComponent from './accounting/accounting.component';
14
14
  import DailyBookings from './bookings/daily/daily-bookings.component';
15
+ import MchTriage from './mch/queues/triage/mch-triage';
16
+ import MchConsultation from './mch/queues/consultation/mch-consultation';
15
17
 
16
18
  const Root: React.FC = () => {
17
19
  const spaBasePath = window.spaBase;
@@ -34,6 +36,8 @@ const Root: React.FC = () => {
34
36
  <Route path="appointments" element={<AppointmentsComponent />} />
35
37
  <Route path="accounting" element={<AccountingComponent />} />
36
38
  <Route path="bookings/daily" element={<DailyBookings />} />
39
+ <Route path="mch/triage" element={<MchTriage />} />
40
+ <Route path="mch/consultation" element={<MchConsultation />} />
37
41
  <Route path="*" element={<RegistryComponent />} />
38
42
  </Routes>
39
43
  </main>
@@ -8,6 +8,9 @@ const COMPLETED_UUID = 'a89c1ef8-1350-11df-a1f1-0026b9348838';
8
8
  const TRIAGE_SERVICE_UUID = '2d4472e2-d7ab-4430-8e0e-a9ffcd809bf4';
9
9
  const CLINICAL_CONSULTATION_SERVICE_UUID = '7f7ec7ad-cdd7-4ed9-bc2e-5c5bd9f065b2';
10
10
 
11
+ const MCH_TRIAGE_SERVICE_UUID = '7e4452bf-f9b7-4977-a21f-1c8b94831bac';
12
+ const MCH_CLINICAL_CONSULTATION_SERVICE_UUID = '0026e273-5f8c-46b5-8bb4-0d8301d50321';
13
+
11
14
  export const QUEUE_PRIORITIES_UUIDS = {
12
15
  NORMAL_PRIORITY_UUID,
13
16
  EMERGENCY_PRIORITY_UUID,
@@ -22,4 +25,6 @@ export const QUEUE_STATUS_UUIDS = {
22
25
  export const QUEUE_SERVICE_UUIDS = {
23
26
  TRIAGE_SERVICE_UUID,
24
27
  CLINICAL_CONSULTATION_SERVICE_UUID,
28
+ MCH_TRIAGE_SERVICE_UUID,
29
+ MCH_CLINICAL_CONSULTATION_SERVICE_UUID,
25
30
  };
@@ -0,0 +1,9 @@
1
+ import { type Location, openmrsFetch, restBaseUrl } from '@openmrs/esm-framework';
2
+
3
+ export async function getLocationByUuid(locationUuid: string): Promise<Location> {
4
+ const locationBaseUrl = `${restBaseUrl}/location`;
5
+ const locationUrl = `${locationBaseUrl}/${locationUuid}`;
6
+ const resp = await openmrsFetch(locationUrl);
7
+ const data = await resp.json();
8
+ return data ?? null;
9
+ }
package/dist/849.js DELETED
@@ -1 +0,0 @@
1
- "use strict";(globalThis.webpackChunk_ampath_esm_dha_workflow_app=globalThis.webpackChunk_ampath_esm_dha_workflow_app||[]).push([[849],{3754:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(72996),a=n.n(r),o=n(70159),i=n.n(o)()(a());i.push([e.id,".-esm-dha-workflow__send-to-triage-modal__formSection___8euyX{display:flex;flex-direction:column;width:100%;row-gap:5px;margin-top:15px}.-esm-dha-workflow__send-to-triage-modal__formRow___Hf27O{display:flex;flex-direction:row;width:100%;column-gap:5px}.-esm-dha-workflow__send-to-triage-modal__formControl___Gmnpd{display:flex;flex-direction:column;width:45%;row-gap:5px}.-esm-dha-workflow__send-to-triage-modal__actionSection___Dlgbe{display:flex;flex-direction:row;column-gap:5px;margin-top:15px}.-esm-dha-workflow__send-to-triage-modal__patientAction___ECxUB{display:flex;flex-direction:row;column-gap:5px;margin-top:15px}.-esm-dha-workflow__send-to-triage-modal__greenBtn___wFmfq{background-color:#28a745}","",{version:3,sources:["webpack://./src/registry/modal/send-to-triage/send-to-triage.modal.scss"],names:[],mappings:"AAAA,8DACI,YAAA,CACA,qBAAA,CACA,UAAA,CACA,WAAA,CACA,eAAA,CAEJ,0DACG,YAAA,CACA,kBAAA,CACA,UAAA,CACA,cAAA,CAEH,8DACG,YAAA,CACA,qBAAA,CACA,SAAA,CACA,WAAA,CAEH,gEACI,YAAA,CACA,kBAAA,CACA,cAAA,CACA,eAAA,CAEJ,gEACI,YAAA,CACA,kBAAA,CACA,cAAA,CACA,eAAA,CAEJ,2DACI,wBAAA",sourcesContent:[".formSection{\n display: flex;\n flex-direction: column;\n width: 100%;\n row-gap: 5px;\n margin-top: 15px;\n}\n.formRow{\n display: flex;\n flex-direction: row;\n width: 100%;\n column-gap: 5px;\n}\n.formControl{\n display: flex;\n flex-direction: column;\n width: 45%;\n row-gap: 5px;\n}\n.actionSection{\n display: flex;\n flex-direction: row;\n column-gap: 5px;\n margin-top: 15px;\n}\n.patientAction{\n display: flex;\n flex-direction: row;\n column-gap: 5px;\n margin-top: 15px;\n}\n.greenBtn{\n background-color: #28a745;\n}"],sourceRoot:""}]),i.locals={formSection:"-esm-dha-workflow__send-to-triage-modal__formSection___8euyX",formRow:"-esm-dha-workflow__send-to-triage-modal__formRow___Hf27O",formControl:"-esm-dha-workflow__send-to-triage-modal__formControl___Gmnpd",actionSection:"-esm-dha-workflow__send-to-triage-modal__actionSection___Dlgbe",patientAction:"-esm-dha-workflow__send-to-triage-modal__patientAction___ECxUB",greenBtn:"-esm-dha-workflow__send-to-triage-modal__greenBtn___wFmfq"};const l=i},4405:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(72996),a=n.n(r),o=n(70159),i=n.n(o)()(a());i.push([e.id,".-esm-dha-workflow__otp-input-component__otpDataInput___hnFAW{width:3rem;height:3rem;text-align:center}.-esm-dha-workflow__otp-input-component__otpInputContainer___HV3nG{display:flex;flex-direction:row;column-gap:5px}.-esm-dha-workflow__otp-input-component__otpDataInputContainer___73DPe{width:4rem;height:4rem}","",{version:3,sources:["webpack://./src/shared/ui/otp-input/otp-input.component.scss"],names:[],mappings:"AAAA,8DACE,UAAA,CACA,WAAA,CACA,iBAAA,CAEF,mEACG,YAAA,CACA,kBAAA,CACA,cAAA,CAEH,uEACI,UAAA,CACA,WAAA",sourcesContent:[".otpDataInput{\n width: 3rem;\n height: 3rem;\n text-align: center;\n}\n.otpInputContainer{\n display: flex;\n flex-direction: row;\n column-gap: 5px;\n}\n.otpDataInputContainer{\n width: 4rem;\n height: 4rem;\n}"],sourceRoot:""}]),i.locals={otpDataInput:"-esm-dha-workflow__otp-input-component__otpDataInput___hnFAW",otpInputContainer:"-esm-dha-workflow__otp-input-component__otpInputContainer___HV3nG",otpDataInputContainer:"-esm-dha-workflow__otp-input-component__otpDataInputContainer___73DPe"};const l=i},6842:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(72996),a=n.n(r),o=n(70159),i=n.n(o)()(a());i.push([e.id,".-esm-dha-workflow__registry-component__registryLayout___PF4WP{display:flex;flex-direction:row;width:100%;row-gap:10px;padding:2% 2%}.-esm-dha-workflow__registry-component__mainContent___qOmrp{display:flex;flex-direction:column;width:100%}.-esm-dha-workflow__registry-component__registryHeader___YIQ62{display:flex;flex-direction:column;row-gap:10px;width:100%}.-esm-dha-workflow__registry-component__registryContent___W1b-9{display:flex;flex-direction:column;width:100%}.-esm-dha-workflow__registry-component__formRow___qlwjG{display:flex;flex-direction:row;width:100%;column-gap:5px;margin-top:10px}.-esm-dha-workflow__registry-component__formControl___R5c2A{width:30%}.-esm-dha-workflow__registry-component__hieData___jx5gt{margin-top:15px;display:flex;flex-direction:column;width:80%;row-gap:10px}.-esm-dha-workflow__registry-component__btnContainer___aXZfC{padding:5px 5px}.-esm-dha-workflow__registry-component__selectionHeader___-zRam{display:flex;flex-direction:column;width:100%;row-gap:5px}.-esm-dha-workflow__registry-component__patientSelect___wgPYw{display:flex;flex-direction:row;width:100%;column-gap:5px}.-esm-dha-workflow__registry-component__patientSelectRadio___3aGYW{width:70%}.-esm-dha-workflow__registry-component__patientConfirmSelection___Py9-y{display:flex;flex-direction:row;width:30%;column-gap:5px}.-esm-dha-workflow__registry-component__formBtn___ok0W6{display:flex;flex-direction:row;column-gap:5px}.-esm-dha-workflow__registry-component__registrySearchBtn___jHA2M{height:30px}.-esm-dha-workflow__registry-component__principalDependantSection___y\\+Uv2{display:flex;flex-direction:row;width:100%;margin-top:15px}.-esm-dha-workflow__registry-component__dependantCard___BUkYp{display:flex;flex-direction:row;width:30%}","",{version:3,sources:["webpack://./src/registry/registry.component.scss"],names:[],mappings:"AAAA,+DACI,YAAA,CACA,kBAAA,CACA,UAAA,CACA,YAAA,CACA,aAAA,CAEJ,4DACE,YAAA,CACA,qBAAA,CACA,UAAA,CAEF,+DACI,YAAA,CACA,qBAAA,CACA,YAAA,CACA,UAAA,CAEJ,gEACI,YAAA,CACA,qBAAA,CACA,UAAA,CAEJ,wDACI,YAAA,CACA,kBAAA,CACA,UAAA,CACA,cAAA,CACA,eAAA,CAEJ,4DACI,SAAA,CAEJ,wDACI,eAAA,CACA,YAAA,CACA,qBAAA,CACA,SAAA,CACA,YAAA,CAEJ,6DACI,eAAA,CAEJ,gEACI,YAAA,CACA,qBAAA,CACA,UAAA,CACA,WAAA,CAEJ,8DACI,YAAA,CACA,kBAAA,CACA,UAAA,CACA,cAAA,CAEJ,mEACI,SAAA,CAEJ,wEACI,YAAA,CACA,kBAAA,CACA,SAAA,CACA,cAAA,CAEJ,wDACI,YAAA,CACA,kBAAA,CACA,cAAA,CAEJ,kEACI,WAAA,CAEJ,2EACI,YAAA,CACA,kBAAA,CACA,UAAA,CACA,eAAA,CAEJ,8DACI,YAAA,CACA,kBAAA,CACA,SAAA",sourcesContent:[".registryLayout{\n display: flex;\n flex-direction: row;\n width: 100%;\n row-gap: 10px;\n padding: 2% 2%;\n}\n.mainContent{\n display: flex;\n flex-direction: column;\n width: 100%;\n}\n.registryHeader{\n display: flex;\n flex-direction: column;\n row-gap: 10px;\n width: 100%;\n}\n.registryContent{\n display: flex;\n flex-direction: column;\n width: 100%;\n}\n.formRow{\n display: flex;\n flex-direction: row;\n width: 100%;\n column-gap: 5px;\n margin-top: 10px;\n}\n.formControl{\n width: 30%;\n}\n.hieData{\n margin-top: 15px;\n display: flex;\n flex-direction: column;\n width: 80%;\n row-gap: 10px;\n}\n.btnContainer{\n padding: 5px 5px;\n}\n.selectionHeader{\n display: flex;\n flex-direction: column;\n width: 100%;\n row-gap: 5px;\n}\n.patientSelect{\n display: flex;\n flex-direction: row;\n width: 100%;\n column-gap: 5px;\n}\n.patientSelectRadio{\n width: 70%;\n}\n.patientConfirmSelection{\n display: flex;\n flex-direction: row;\n width: 30%;\n column-gap: 5px;\n}\n.formBtn{\n display: flex;\n flex-direction: row;\n column-gap: 5px;\n}\n.registrySearchBtn{\n height: 30px;\n}\n.principalDependantSection{\n display: flex;\n flex-direction: row;\n width: 100%;\n margin-top: 15px;\n}\n.dependantCard{\n display: flex;\n flex-direction: row;\n width: 30%;\n}"],sourceRoot:""}]),i.locals={registryLayout:"-esm-dha-workflow__registry-component__registryLayout___PF4WP",mainContent:"-esm-dha-workflow__registry-component__mainContent___qOmrp",registryHeader:"-esm-dha-workflow__registry-component__registryHeader___YIQ62",registryContent:"-esm-dha-workflow__registry-component__registryContent___W1b-9",formRow:"-esm-dha-workflow__registry-component__formRow___qlwjG",formControl:"-esm-dha-workflow__registry-component__formControl___R5c2A",hieData:"-esm-dha-workflow__registry-component__hieData___jx5gt",btnContainer:"-esm-dha-workflow__registry-component__btnContainer___aXZfC",selectionHeader:"-esm-dha-workflow__registry-component__selectionHeader___-zRam",patientSelect:"-esm-dha-workflow__registry-component__patientSelect___wgPYw",patientSelectRadio:"-esm-dha-workflow__registry-component__patientSelectRadio___3aGYW",patientConfirmSelection:"-esm-dha-workflow__registry-component__patientConfirmSelection___Py9-y",formBtn:"-esm-dha-workflow__registry-component__formBtn___ok0W6",registrySearchBtn:"-esm-dha-workflow__registry-component__registrySearchBtn___jHA2M",principalDependantSection:"-esm-dha-workflow__registry-component__principalDependantSection___y+Uv2",dependantCard:"-esm-dha-workflow__registry-component__dependantCard___BUkYp"};const l=i},25838:(e,t,n)=>{n.d(t,{_:()=>l,j:()=>c});var r=n(25987);function a(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function l(e){a(i,r,o,l,c,"next",e)}function c(e){a(i,r,o,l,c,"throw",e)}l(void 0)}))}}function i(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}function l(e){return o((function(){var t,n,a;return i(this,(function(o){switch(o.label){case 0:return t="".concat(r.restBaseUrl,"/visit"),[4,(0,r.openmrsFetch)(t,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(e)})];case 1:return(n=o.sent()).ok?[3,3]:[4,n.text()];case 2:throw a=o.sent(),new Error("Request failed with ".concat(n.status,": ").concat(a));case 3:return[2,n.json()]}}))}))()}function c(e,t){return o((function(){var n,a,o;return i(this,(function(i){switch(i.label){case 0:return n="".concat(r.restBaseUrl,"/visit/").concat(e),[4,(0,r.openmrsFetch)(n,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(t)})];case 1:return(a=i.sent()).ok?[3,3]:[4,a.text()];case 2:throw o=i.sent(),new Error("Request failed with ".concat(a.status,": ").concat(o));case 3:return[2,a.json()]}}))}))()}},50849:(e,t,n)=>{n.r(t),n.d(t,{default:()=>Ue});var r=n(39246),a=n(16072),o=n.n(a),i=n(85072),l=n.n(i),c=n(97825),u=n.n(c),s=n(77659),d=n.n(s),f=n(55056),m=n.n(f),p=n(10540),A=n.n(p),h=n(41113),_=n.n(h),y=n(6842),b={};b.styleTagTransform=_(),b.setAttributes=m(),b.insert=d().bind(null,"head"),b.domAPI=u(),b.insertStyleElement=A(),l()(y.A,b);const w=y.A&&y.A.locals?y.A.locals:void 0;var g=["National ID","Alien ID","Passport","Mandate Number","Refugee ID"],v=function(e){return e.Draft="DRAFT",e.Sent="SENT",e.Verified="VERIFIED",e}({}),C=function(e){return e.NationalID="National ID",e.SHANumber="SHA Number",e.HouseholdNumber="Household Number",e.RefugeeID="Refugee ID",e.AlienID="Alien ID",e.MandateNumber="Mandate Number",e.Cr="id",e.TemporaryDependantID="Temporary Dependant ID",e.BirthCertificate="Birth Certificate",e}({}),E=n(62801);function x(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function k(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var o=e.apply(t,n);function i(e){x(o,r,a,i,l,"next",e)}function l(e){x(o,r,a,i,l,"throw",e)}i(void 0)}))}}function S(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}function I(e,t){return k((function(){var n,r;return S(this,(function(a){switch(a.label){case 0:return[4,fetch(e,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)})];case 1:return(n=a.sent()).ok?[3,3]:[4,n.text()];case 2:throw r=a.sent(),new Error("Request failed with ".concat(n.status,": ").concat(r));case 3:return[2,n.json()]}}))}))()}function T(e){return k((function(){var t,n,r;return S(this,(function(a){switch(a.label){case 0:return[4,(0,E.bo)()];case 1:return t=a.sent(),n="".concat(t,"/client/search"),r={identificationNumber:e.identificationNumber,identificationType:e.identificationType,locationUuid:e.locationUuid},[2,I(n,r)]}}))}))()}var N=n(25987),D=n(84497),P={};P.styleTagTransform=_(),P.setAttributes=m(),P.insert=d().bind(null,"head"),P.domAPI=u(),P.insertStyleElement=A(),l()(D.A,P);const O=D.A&&D.A.locals?D.A.locals:void 0;var R=function(e){for(var t=e.split(""),n=0;n<e.length;n++)n%2==0&&(t[n]="*");return t.join("")},j=function(e){for(var t=e.split(""),n=0;n<e.length;n++)0!=n&&n!==e.length-1&&(t[n]="*");return t.join("")},B=n(4405),F={};F.styleTagTransform=_(),F.setAttributes=m(),F.insert=d().bind(null,"head"),F.domAPI=u(),F.insertStyleElement=A(),l()(B.A,F);const U=B.A&&B.A.locals?B.A.locals:void 0;function H(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Y(e){return function(e){if(Array.isArray(e))return H(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||q(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function q(e,t){if(e){if("string"==typeof e)return H(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?H(e,t):void 0}}const M=function(e){var t,n,i=e.onChange,l=e.otpLength,c=(t=(0,a.useState)(Array(l).fill("")),n=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,o=[],i=!0,l=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(o.push(r.value),!t||o.length!==t);i=!0);}catch(e){l=!0,a=e}finally{try{i||null==n.return||n.return()}finally{if(l)throw a}}return o}}(t,n)||q(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),u=c[0],s=c[1],d=(0,a.useRef)([]);if(!l)return o().createElement(o().Fragment,null,"OTP Length not defined");var f=function(e){d.current[e]&&d.current[e].focus()};return o().createElement("div",{className:U.otpInputContainer,onPaste:function(e){e.preventDefault();var t=e.clipboardData.getData("text").replace(/\D/g,"").slice(0,l);if(t){var n=Y(u);t.split("").forEach((function(e,t){n[t]=e})),s(n),null==i||i(n.join("")),f(t.length-1)}}},u.map((function(e,t){return o().createElement("div",{className:U.otpDataInputContainer},o().createElement(r.ksK,{className:U.otpDataInput,key:t,id:"otp-".concat(t),value:e,labelText:"",hideLabel:!0,maxLength:1,inputMode:"numeric",pattern:"[0-9]*",ref:function(e){return d.current[t]=e},onChange:function(e){return function(e,t){if(/^\d?$/.test(e)){var n=Y(u);n[t]=e,s(n),e&&t<l-1&&f(t+1),null==i||i(n.join(""))}}(e.target.value,t)},onKeyDown:function(e){return function(e,t){"Backspace"===e.key&&!u[t]&&t>0&&f(t-1)}(e,t)},style:{height:"4rem",width:"4rem",borderStyle:"solid grey",backgroundColor:"#e5ebf7"}}))})))};function L(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function V(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function W(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var o=e.apply(t,n);function i(e){V(o,r,a,i,l,"next",e)}function l(e){V(o,r,a,i,l,"throw",e)}i(void 0)}))}}function G(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,o=[],i=!0,l=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(o.push(r.value),!t||o.length!==t);i=!0);}catch(e){l=!0,a=e}finally{try{i||null==n.return||n.return()}finally{if(l)throw a}}return o}}(e,t)||function(e,t){if(e){if("string"==typeof e)return L(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?L(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function J(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}const $=function(e){var t=e.requestCustomOtpDto,n=e.phoneNumber,i=e.open,l=e.onModalClose,c=e.onOtpSuccessfullVerification,u=G((0,a.useState)(""),2),s=u[0],d=u[1],f=G((0,a.useState)(v.Draft),2),m=f[0],p=f[1],A=G((0,a.useState)(!1),2),h=A[0],_=A[1],y=G((0,a.useState)(""),2),b=y[0],w=y[1],g=function(e,t,n){(0,N.showSnackbar)({kind:e,title:t,subtitle:n})};return o().createElement(o().Fragment,null,o().createElement(r.aFV,{open:i,size:"md",onSecondarySubmit:l,onRequestClose:l,onRequestSubmit:function(){window.open("https://afyayangu.go.ke/","_blank")},primaryButtonText:"Register on Afya Yangu",secondaryButtonText:"Cancel"},o().createElement(r.cwr,null,o().createElement("div",{className:O.modalVerificationLayout},o().createElement("div",{className:O.sectionHeader},o().createElement("h4",{className:O.sectionTitle},"One Time Password (OTP)"),o().createElement("h6",null,"Enter one time password to proceed")),o().createElement("div",{className:O.sectionContent},o().createElement("div",{className:O.contentHeader},m===v.Draft?o().createElement(o().Fragment,null,o().createElement("h6",null,"Send Code to Phone ",R(n))):o().createElement(o().Fragment,null),m===v.Verified?o().createElement(o().Fragment,null,o().createElement("h6",null,"OTP Verification Successfull!")):o().createElement(o().Fragment,null)),o().createElement("div",{className:O.otpSection},m===v.Sent?o().createElement(o().Fragment,null,o().createElement(r.lRv,null,"Enter OTP"),o().createElement(M,{otpLength:5,onChange:function(e){return d(e)}})):o().createElement(o().Fragment,null))),o().createElement("div",{className:O.sectionAction},m===v.Draft?o().createElement(o().Fragment,null,o().createElement(r.$nd,{kind:"primary",onClick:function(){return W((function(){var e,n,r;return J(this,(function(a){switch(a.label){case 0:if(!t.identificationNumber)return g("error","Invalid Identification Value","Please enter a valid ID value"),[2];_(!0),a.label=1;case 1:return a.trys.push([1,3,4,5]),[4,(o=t,k((function(){var e,t,n;return S(this,(function(r){switch(r.label){case 0:return[4,(0,E.bo)()];case 1:return e=r.sent(),t="".concat(e,"/client/send-custom-otp"),n={identificationNumber:o.identificationNumber,identificationType:o.identificationType,locationUuid:o.locationUuid},[2,I(t,n)]}}))}))())];case 2:return e=a.sent(),w(e.sessionId),p(v.Sent),g("success","OTP sent successfully","A code was sent to ".concat(e.maskedPhone)),[3,5];case 3:return n=a.sent(),r=n.message||"Failed to send OTP",g("error","Error sending OTP",r),[3,5];case 4:return _(!1),[7];case 5:return[2]}var o}))}))()}},h?o().createElement(r.OuH,{description:"Sending OTP..."}):"Send OTP")):o().createElement(o().Fragment,null),m===v.Sent?o().createElement(o().Fragment,null,o().createElement(r.$nd,{kind:"primary",onClick:function(){return W((function(){var e,n;return J(this,(function(r){switch(r.label){case 0:if(!s.trim())return g("error","Please enter the OTP code",""),[2];_(!0),r.label=1;case 1:return r.trys.push([1,3,4,5]),[4,(a={sessionId:b,otp:s,locationUuid:t.locationUuid},k((function(){var e,t,n;return S(this,(function(r){switch(r.label){case 0:return[4,(0,E.bo)()];case 1:return e=r.sent(),t="".concat(e,"/client/validate-custom-otp"),n={sessionId:a.sessionId,otp:a.otp,locationUuid:a.locationUuid},[2,I(t,n)]}}))}))())];case 2:return r.sent(),p(v.Verified),(0,N.showSnackbar)({kind:"success",title:"OTP Verified",subtitle:"You can now fetch data from Client Registry."}),[3,5];case 3:return e=r.sent(),n=e.message||"OTP verification failed",(0,N.showSnackbar)({kind:"error",title:"OTP Verification Failed",subtitle:n}),[3,5];case 4:return _(!1),[7];case 5:return[2]}var a}))}))()}},h?o().createElement(r.OuH,{description:"Verifying OTP..."}):"Verify")):o().createElement(o().Fragment,null),m===v.Verified?o().createElement(o().Fragment,null,o().createElement(r.$nd,{kind:"primary",onClick:c},"Continue")):o().createElement(o().Fragment,null))))))};var z=n(86575),K={};K.styleTagTransform=_(),K.setAttributes=m(),K.insert=d().bind(null,"head"),K.domAPI=u(),K.insertStyleElement=A(),l()(z.A,K);const X=z.A&&z.A.locals?z.A.locals:void 0;function Q(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Z=["id","other_identifications","first_name","middle_name","last_name","gender","date_of_birth","is_alive","deceased_datetime","phone","email","civil_status","place_of_birth","citizenship","country","county","sub_county","ward","village_estate","longitude","latitude","identification_type"];const ee=function(e){var t=e.client,n=(0,a.useMemo)((function(){return e=t,n={},Object.keys(e).filter((function(e){return Z.includes(e)})).forEach((function(t){if("other_identifications"===t){var r=(o=e[t],i={},o.forEach((function(e){i[e.identification_type]=e.identification_number})),i);n=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),r.forEach((function(t){Q(e,t,n[t])}))}return e}({},n,r)}else if("identification_type"===t)n[e.identification_type]=e.identification_number;else{var a=e[t];n[t]=a}var o,i})),n;var e,n}),[t]);return t&&n?o().createElement(o().Fragment,null,o().createElement(r.XIK,null,o().createElement(r.ndF,null,o().createElement(r.Hjg,null,o().createElement(r.A0N,null,"Field"),o().createElement(r.A0N,null,"Value"))),o().createElement(r.BFY,null,Object.keys(n).map((function(e){return o().createElement(r.Hjg,null,o().createElement(r.nA6,null,e),o().createElement(r.nA6,null,n[e]))}))))):o().createElement(o().Fragment,null,o().createElement("h4",null,"No patient Data to Display"))},te=function(){return o().createElement(o().Fragment,null,o().createElement(r.zWQ,{defaultSelected:"sha",legendText:"Patient",onChange:function(e){},name:"payment-options-radio-group"},o().createElement(r.aaP,{id:"sha",labelText:"Social Health Authority",value:"sha"}),o().createElement(r.aaP,{id:"insurance",labelText:"Other Insurance",value:"other"}),o().createElement(r.aaP,{id:"cash",labelText:"Cash",value:"cash"})))},ne=function(e){var t=e.client,n=e.open,a=e.onModalClose,i=(e.onSubmit,e.onSendClientToTriage);return t?o().createElement(o().Fragment,null,o().createElement(r.aFV,{open:n,size:"md",onSecondarySubmit:a,onRequestClose:a,onRequestSubmit:function(){window.open("https://afyayangu.go.ke/","_blank")},primaryButtonText:"Register on Afya Yangu",secondaryButtonText:"Cancel"},o().createElement(r.cwr,null,o().createElement("div",{className:X.clientDetailsLayout},o().createElement("div",{className:X.sectionHeader},o().createElement("h4",{className:X.sectionTitle},"Patient/Payment Details")),o().createElement("div",{className:X.sectionContent},o().createElement(r.tUM,null,o().createElement(r.wbY,{contained:!0},o().createElement(r.ozo,null,"Patient Details"),o().createElement(r.ozo,null,"Payment Details")),o().createElement(r.T2N,null,o().createElement(r.KpK,null,o().createElement(ee,{client:t})),o().createElement(r.KpK,null,o().createElement(te,null))))),o().createElement("div",{className:X.actionSection},o().createElement("div",{className:X.btnContainer},o().createElement(r.$nd,{kind:"primary"},"Book Appointment")),o().createElement("div",{className:X.btnContainer},o().createElement(r.$nd,{kind:"secondary"},"Walk In Orders")),o().createElement("div",{className:X.btnContainer},o().createElement(r.$nd,{kind:"tertiary",onClick:function(){return i(t.id)}},"Send To Triage"))))))):o().createElement(o().Fragment,null,"No Client data")};function re(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function ae(e){return(t=function(){var t,n,r,a;return function(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}(this,(function(o){switch(o.label){case 0:return t="".concat(N.restBaseUrl,"/patient"),n=new URLSearchParams({q:e,v:"full",includeDead:"true",limit:"10",totalCount:"true"}).toString(),[4,(0,N.openmrsFetch)("".concat(t,"?").concat(n))];case 1:return(r=o.sent()).ok?[3,3]:[4,r.text()];case 2:throw a=o.sent(),new Error("Request failed with ".concat(r.status,": ").concat(a));case 3:return[2,r.json()]}}))},function(){var e=this,n=arguments;return new Promise((function(r,a){var o=t.apply(e,n);function i(e){re(o,r,a,i,l,"next",e)}function l(e){re(o,r,a,i,l,"throw",e)}i(void 0)}))})();var t}var oe=n(3754),ie={};ie.styleTagTransform=_(),ie.setAttributes=m(),ie.insert=d().bind(null,"head"),ie.domAPI=u(),ie.insertStyleElement=A(),l()(oe.A,ie);const le=oe.A&&oe.A.locals?oe.A.locals:void 0;function ce(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function ue(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var o=e.apply(t,n);function i(e){ce(o,r,a,i,l,"next",e)}function l(e){ce(o,r,a,i,l,"throw",e)}i(void 0)}))}}function se(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}function de(e){return ue((function(){var t,n,r,a;return se(this,(function(o){switch(o.label){case 0:return t="".concat(N.restBaseUrl,"/queue"),n=new URLSearchParams({v:"custom:(uuid,display,name,description,service:(uuid,display),allowedPriorities:(uuid,display),allowedStatuses:(uuid,display),location:(uuid,display))",location:e}).toString(),[4,(0,N.openmrsFetch)("".concat(t,"?").concat(n))];case 1:return(r=o.sent()).ok?[3,3]:[4,r.text()];case 2:throw a=o.sent(),new Error("Request failed with ".concat(r.status,": ").concat(a));case 3:return[2,r.json()]}}))}))()}var fe=n(75862),me=n(25838);function pe(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Ae(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function he(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var o=e.apply(t,n);function i(e){Ae(o,r,a,i,l,"next",e)}function l(e){Ae(o,r,a,i,l,"throw",e)}i(void 0)}))}}function _e(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,o=[],i=!0,l=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(o.push(r.value),!t||o.length!==t);i=!0);}catch(e){l=!0,a=e}finally{try{i||null==n.return||n.return()}finally{if(l)throw a}}return o}}(e,t)||function(e,t){if(e){if("string"==typeof e)return pe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?pe(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ye(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}const be=function(e){var t=e.patients,n=e.open,i=e.onModalClose,l=(e.onSubmit,e.client),c=e.onCreateAmrsPatient,u=e.onManualRegistration,s=_e((0,a.useState)(),2),d=s[0],f=s[1],m=_e((0,a.useState)(),2),p=m[0],A=m[1],h=_e((0,a.useState)(),2),_=h[0],y=h[1],b=_e((0,a.useState)(),2),w=b[0],g=b[1],v=_e((0,a.useState)(""),2),C=v[0],E=v[1],x=_e((0,a.useState)(!1),2),k=x[0],S=x[1],I=(0,N.useVisitTypes)(),T=(0,N.useSession)().sessionLocation.uuid,D=(0,a.useMemo)((function(){return I.map((function(e){return{id:e.uuid,text:e.display}}))}),[I]);if((0,a.useEffect)((function(){P()}),[t]),!t)return o().createElement(o().Fragment,null,"No Client data");var P=function(){return he((function(){var e;return ye(this,(function(t){switch(t.label){case 0:return[4,de(T)];case 1:return(e=t.sent())&&e.results&&y(e.results),[2]}}))}))()},O=function(e){return e.location?e.patient?!!e.visitType||(j("error","Please select a visit",""),!1):(j("error","Please select a patient",""),!1):(j("error","Missing location in create visits",""),!1)},R=function(){var e;return{visitType:p,location:T,startDatetime:null,stopDatetime:null,patient:null!==(e=null==d?void 0:d.uuid)&&void 0!==e?e:""}},j=function(e,t,n){(0,N.showSnackbar)({kind:e,title:t,subtitle:n})};return o().createElement(o().Fragment,null,o().createElement(r.aFV,{open:n,size:"md",onSecondarySubmit:function(){return i({success:!1})},onRequestClose:function(){return i({success:!1})},onRequestSubmit:function(){window.open("https://afyayangu.go.ke/","_blank")},primaryButtonText:"Register on Afya Yangu",secondaryButtonText:"Cancel"},o().createElement(r.cwr,null,o().createElement("div",{className:le.clientDetailsLayout},o().createElement("div",{className:le.sectionHeader},o().createElement("h4",{className:le.sectionTitle},"Send To Triage")),t.length>0?o().createElement("div",{className:le.sectionContent},o().createElement("div",{className:le.patientSelect},o().createElement(r.XIK,null,o().createElement(r.ndF,null,o().createElement(r.Hjg,null,o().createElement(r.A0N,null,"No"),o().createElement(r.A0N,null,"Name"),o().createElement(r.A0N,null,"Gender"),o().createElement(r.A0N,null,"Select Patient"))),o().createElement(r.BFY,null,t.map((function(e,t){return o().createElement(r.Hjg,{key:e.uuid},o().createElement(r.nA6,null,t+1),o().createElement(r.nA6,null,e.person.preferredName.display),o().createElement(r.nA6,null,e.person.gender),o().createElement(r.nA6,null,o().createElement(r.Sc0,{id:e.uuid,labelText:"",onChange:function(){f(e)}})))}))))),o().createElement("div",{className:le.formSection},o().createElement("div",{className:le.formRow},o().createElement("div",{className:le.formControl},o().createElement(r.a32,{onChange:function(e){var t=e.selectedItem.id;A(t)},id:"visit-type-combobox",items:D,itemToString:function(e){return e?e.text:""},titleText:"Select a Visit Type"})),o().createElement("div",{className:le.formControl},o().createElement(r.l6P,{id:"service",labelText:"Select a Service",onChange:function(e){var t=e.target.value;g(t)}},o().createElement(r.ebT,{value:"",text:"Select"}),";",_&&_.map((function(e){return o().createElement(r.ebT,{value:e.uuid,text:e.display})}))))),o().createElement("div",{className:le.formRow},o().createElement("div",{className:le.formControl},o().createElement(r.l6P,{id:"priority",labelText:"Select Priority",onChange:function(e){return t=e.target.value,void E(t);var t}},o().createElement(r.ebT,{value:"",text:"Select"}),";",o().createElement(r.ebT,{value:fe.i3.NORMAL_PRIORITY_UUID,text:"NORMAL"}),";",o().createElement(r.ebT,{value:fe.i3.EMERGENCY_PRIORITY_UUID,text:"EMERGENCY"}),";"))))):o().createElement(o().Fragment,null),o().createElement("div",{className:le.actionSection},t.length>0?o().createElement("div",{className:le.btnContainer},o().createElement(r.$nd,{className:le.greenBtn,onClick:function(){return he((function(){var e,t;return ye(this,(function(n){switch(n.label){case 0:S(!0),n.label=1;case 1:return n.trys.push([1,5,6,7]),[4,he((function(){var e,t;return ye(this,(function(n){switch(n.label){case 0:return e=R(),O(e)?[4,(0,me._)(e)]:[2,!1];case 1:if(t=n.sent())return j("success","Visit has been created succesfully",""),[2,t];throw j("error","Error creating patient visit",""),new Error("Error creating patient visit")}}))}))()];case 2:return(e=n.sent())?(r=e.uuid,t={visit:{uuid:r},queueEntry:{status:{uuid:fe.cn.WAITING_UUID},priority:{uuid:C},queue:{uuid:w},patient:{uuid:d.uuid},startedAt:(new Date).toISOString(),sortWeight:0}},[4,(a=t,ue((function(){var e,t,n;return se(this,(function(r){switch(r.label){case 0:return e="".concat(N.restBaseUrl,"/visit-queue-entry"),[4,(0,N.openmrsFetch)(e,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(a)})];case 1:return(t=r.sent()).ok?[3,3]:[4,t.text()];case 2:throw n=r.sent(),new Error("Request failed with ".concat(t.status,": ").concat(n));case 3:return[2,t.json()]}}))}))())]):[3,4];case 3:n.sent()&&(j("success","Patient has succesfully been moved to the Triage queue",""),i({success:!0})),n.label=4;case 4:return[3,7];case 5:return n.sent(),j("error","Error creating visit",""),[3,7];case 6:return S(!1),[7];case 7:return[2]}var r,a}))}))()}},k?o().createElement(r.OuH,{description:"Sending To Triage..."}):"Send To Triage")):o().createElement(o().Fragment,null,o().createElement("div",{className:le.patientAction},o().createElement("div",{className:le.btnContainer},o().createElement(r.$nd,{kind:"primary",onClick:function(){return c(l)}},"Automatically Register in AMRS")),o().createElement("div",{className:le.btnContainer},o().createElement(r.$nd,{kind:"secondary",onClick:u},"Manually Register")))))))))};var we=n(27114);function ge(e,t){return"".concat(e.first_name," ").concat(j(e.middle_name)," (").concat(e.gender,") (DOB: ").concat(e.date_of_birth,") (").concat(t,") (CR: ").concat(e.id,")")}function ve(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Ce(e){return function(e){if(Array.isArray(e))return ve(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return ve(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ve(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Ee=Ce([C.Cr,C.SHANumber,C.HouseholdNumber,C.RefugeeID,C.MandateNumber,C.AlienID,C.NationalID,C.TemporaryDependantID]).concat(Ce(["first_name","middle_name","last_name"]),Ce(["gender","date_of_birth","is_alive","deceased_datetime"]),Ce(["phone","email","civil_status","place_of_birth","citizenship"]),Ce(["country","county","sub_county","ward","village_estate","longitude","latitude"]));function xe(e){var t="";switch(e){case"Divorced":t="a899ad58-1350-11df-a1f1-0026b9348838";break;case"Married":t="a8aa76b0-1350-11df-a1f1-0026b9348838";break;case"Single":t="a899ac7c-1350-11df-a1f1-0026b9348838";break;default:t="a89ad3a4-1350-11df-a1f1-0026b9348838"}return t}function ke(e){var t;switch(e){case C.NationalID:t="58a47054-1359-11df-a1f1-0026b9348838";break;case C.HouseholdNumber:t="bb74b20e-dcee-4f59-bdf1-2dffc3abf106";break;case C.AlienID:t="12f5b147-3403-4a73-913d-7ded9ffec094";break;case C.SHANumber:t="cf5362b2-8049-4442-b3c6-36f870e320cb";break;case C.MandateNumber:t="aae2d097-20ba-43ca-9b71-fd8296068f39";break;case C.RefugeeID:t="465e81af-8d69-47e9-9127-53a94adc75fb";break;case C.Cr:t="e88dc246-3614-4ee3-8141-1f2a83054e72";break;case C.BirthCertificate:t="7924e13b-131a-4da8-8efa-e294184a1b0d";break;case C.TemporaryDependantID:t="a3d34214-93e8-4faf-bf4d-0272eee079eb"}return t}function Se(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function Ie(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var o=e.apply(t,n);function i(e){Se(o,r,a,i,l,"next",e)}function l(e){Se(o,r,a,i,l,"throw",e)}i(void 0)}))}}function Te(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}var Ne=function(e,t){return Ie((function(){var n,r;return Te(this,(function(a){switch(a.label){case 0:return[4,Ie((function(){var e,t,n,r;return Te(this,(function(a){switch(a.label){case 0:return[4,(0,E.E$)()];case 1:return e=a.sent(),t=new AbortController,[4,(0,N.openmrsFetch)("".concat(e,"/amrs-id-generator/generateidentifier"),{headers:{"Content-Type":"application/json"},method:"POST",body:{user:1},signal:t.signal})];case 2:return[4,a.sent().json()];case 3:return n=a.sent(),[2,null!==(r=n.identifier)&&void 0!==r?r:""]}}))}))()];case 1:return n=a.sent(),r=function(e,t){var n=[];return n.push({identifierType:ke(C.Cr),identifier:e.id,location:t}),n.push({identifierType:ke(e.identification_type),identifier:e.identification_number,location:t}),n}(t,e),r.push({identifierType:"58a4732e-1359-11df-a1f1-0026b9348838",identifier:n,location:e,preferred:!0}),[2,r]}}))}))()};function De(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function Pe(e,t){return(n=function(){var n,r;return function(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}(this,(function(a){switch(a.label){case 0:return n=function(e){var t={},n={},r={},a=[];Ee.forEach((function(o){"first_name"===o&&(n.givenName=e.first_name),"middle_name"===o&&(n.middleName=e.middle_name),"last_name"===o&&(n.familyName=e.last_name),"gender"===o&&(t.gender="Male"===e.gender?"M":"F"),"date_of_birth"===o&&(t.birthdate=e.date_of_birth,t.birthdateEstimated=!1),"is_alive"===o&&(t.dead=0===e.is_alive),"deceased_datetime"===o&&e.deceased_datetime.length>0&&(t.deathDate=e.deceased_datetime),"country"===o&&e.country.length>0&&(r.country=e.country,r.address1=e.country),"place_of_birth"===o&&e.place_of_birth.length>0&&(r.address10=e.place_of_birth),"county"===o&&e.county.length>0&&(r.countyDistrict=e.county),"sub_county"===o&&e.sub_county.length>0&&(r.address2=e.sub_county,r.stateProvince=e.sub_county),"ward"===o&&e.sub_county.length>0&&(r.address7=e.sub_county,r.address4=e.sub_county),"village_estate"===o&&e.village_estate.length>0&&(r.cityVillage=e.village_estate),"longitude"===o&&e.longitude.length>0&&(r.longitude=e.longitude),"latitude"===o&&e.latitude.length>0&&(r.latitude=e.latitude),"place_of_birth"===o&&e.place_of_birth.length>0&&a.push({value:e.place_of_birth,attributeType:"8d8718c2-c2cc-11de-8d13-0010c6dffd0f"}),"phone"===o&&e.phone.length>0&&a.push({value:e.phone,attributeType:"72a759a8-1359-11df-a1f1-0026b9348838"}),"email"===o&&e.email.length>0&&a.push({value:e.email,attributeType:"2f65dbcb-3e58-45a3-8be7-fd1dc9aa0faa"}),"civil_status"===o&&e.civil_status.length>0&&a.push({value:xe(e.civil_status),attributeType:"8d871f2a-c2cc-11de-8d13-0010c6dffd0f"}),"id"===o&&e.id&&a.push({value:e.id,attributeType:"e068e02b-faac-4baf-bd58-fe6e0c29a81f"}),"citizenship"===o&&e.citizenship&&a.push({value:e.citizenship,attributeType:"8d871afc-c2cc-11de-8d13-0010c6dffd0f"})}));var o=function(e){var t=[],n=e.find((function(e){return"Alternative Phone Number"===e.relationship})),r=e.find((function(e){return"Next Of Kin"===e.remarks}));return n&&"Phone"===n.contact_type&&t.push({value:n.contact_id,attributeType:"c725f524-c14a-4468-ac19-4a0e6661c930"}),r&&("Phone"===r.contact_type&&t.push({value:r.contact_id,attributeType:"a657a4f1-9c0f-444b-a1fd-445bb91dd12d"}),t.push({value:r.relationship,attributeType:"5730994e-c267-426b-87b6-c152b606973d"}),t.push({value:r.contact_name,attributeType:"72a75bec-1359-11df-a1f1-0026b9348838"})),t}(e.alternative_contacts);return a=Ce(a).concat(Ce(o)),Object.keys(n).length>0&&(t.names=[n]),Object.keys(r).length>0&&(t.addresses=[r]),a.length>0&&(t.attributes=a),t}(e),[4,Ne(t,e)];case 1:return r=a.sent(),[4,(o={person:n,identifiers:r},Ie((function(){return Te(this,(function(e){switch(e.label){case 0:return[4,(0,N.openmrsFetch)("".concat(N.restBaseUrl,"/patient"),{method:"POST",headers:{"Content-Type":"application/json"},body:o})];case 1:return[2,e.sent()]}}))}))())];case 2:return[4,a.sent().json()];case 3:return[2,a.sent()]}var o}))},function(){var e=this,t=arguments;return new Promise((function(r,a){var o=n.apply(e,t);function i(e){De(o,r,a,i,l,"next",e)}function l(e){De(o,r,a,i,l,"throw",e)}i(void 0)}))})();var n}function Oe(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Re(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function je(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var o=e.apply(t,n);function i(e){Re(o,r,a,i,l,"next",e)}function l(e){Re(o,r,a,i,l,"throw",e)}i(void 0)}))}}function Be(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,o=[],i=!0,l=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(o.push(r.value),!t||o.length!==t);i=!0);}catch(e){l=!0,a=e}finally{try{i||null==n.return||n.return()}finally{if(l)throw a}}return o}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Oe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Oe(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Fe(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}const Ue=function(){var e=Be((0,a.useState)("National ID"),2),t=e[0],n=e[1],i=Be((0,a.useState)(""),2),l=i[0],c=i[1],u=Be((0,a.useState)(!1),2),s=u[0],d=u[1],f=Be((0,a.useState)(),2),m=f[0],p=f[1],A=Be((0,a.useState)(),2),h=A[0],_=A[1],y=Be((0,a.useState)([]),2),b=y[0],v=y[1],C=Be((0,a.useState)("principal"),2),E=C[0],x=C[1],k=Be((0,a.useState)(!1),2),S=k[0],I=k[1],D=Be((0,a.useState)(!1),2),P=D[0],O=D[1],B=Be((0,a.useState)(!1),2),F=B[0],U=B[1],H=Be((0,a.useState)(),2),Y=H[0],q=H[1],M=(0,N.useSession)().sessionLocation.uuid,L=(0,we.useNavigate)(),V=function(e,t,n){(0,N.showSnackbar)({kind:e,title:t,subtitle:n})},W=function(){O(!1)},G=function(){window.location.href="".concat(window.spaBase,"/patient-registration")},J=function(){return"principal"===E?m:"dependants"===E?h:m},z=function(){p(null),_(null),v([]),x(null),c(""),n("National ID"),O(!1),I(!1),U(!1),x("principal")};return o().createElement(o().Fragment,null,o().createElement("div",{className:w.registryLayout},o().createElement("div",{className:w.mainContent},o().createElement("div",{className:w.registryHeader},o().createElement("h4",null,"Client Registry"),o().createElement("p",null,"Please enter identification number to begin")),o().createElement("div",{className:w.registryContent},o().createElement("div",{className:w.formRow},o().createElement("div",{className:w.formControl},o().createElement(r.msM,{id:"identifier-type-dropdown",label:"Identifier Type",titleText:"Select Identifier Type",items:g,selectedItem:t,onChange:function(e){var t=e.selectedItem;return n(t)}})),o().createElement("div",{className:w.formControl},o().createElement(r.ksK,{id:"identifier-value",labelText:"".concat(t," Value"),value:l,onChange:function(e){return c(e.target.value)},placeholder:"Enter ".concat(t.toLowerCase()," value")}))),o().createElement("div",{className:w.formRow},o().createElement("div",{className:w.formControl},o().createElement("div",{className:w.formBtn},o().createElement(r.$nd,{className:w.registrySearchBtn,kind:"primary",onClick:function(){return je((function(){var e,n,r,a,o,i;return Fe(this,(function(c){switch(c.label){case 0:d(!0),c.label=1;case 1:return c.trys.push([1,3,4,5]),function(e){return e.identificationNumber?e.identificationType?!!e.locationUuid||(V("error","No default location selected",""),!1):(V("error","Please enter a valid identification type",""),!1):(V("error","Please enter a valid identification number",""),!1)}(e={identificationNumber:l,identificationType:t,locationUuid:M})?(q(e),[4,T(e)]):[2,!1];case 2:if(n=c.sent(),0===(r=Array.isArray(n)?n:[]).length)throw z(),new Error("No matching patient found in Client Registry.");return a=r[0],p(a),V("success","Client Data Loaded","Patient fetched successfully"),[3,5];case 3:return o=c.sent(),i=o.message||"Failed to fetch client data",z(),V("error","Fetch Failed",i),[3,5];case 4:return d(!1),[7];case 5:return[2]}}))}))()},disabled:s},s?o().createElement(r.OuH,{description:"Searching..."}):"Search"),o().createElement(r.$nd,{className:w.registrySearchBtn,kind:"secondary",onClick:G},"Emergency Registration"),o().createElement(r.$nd,{className:w.registrySearchBtn,kind:"tertiary",onClick:function(){window.open("https://afyayangu.go.ke/","_blank")}},"Register on Afya Yangu")))),m?o().createElement("div",{className:w.formRow},o().createElement("div",{className:w.hieData},o().createElement("div",{className:w.selectionHeader},o().createElement("h5",null,"Please select one patient and request patient to share the OTP sent")),o().createElement("div",{className:w.patientSelect},o().createElement("div",{className:w.patientSelectRadio},o().createElement(r.zWQ,{defaultSelected:"principal",legendText:"Patient",onChange:function(e){x(e)},name:"radio-button-default-group"},o().createElement(r.aaP,{id:"principal",labelText:"Principal",value:"principal"}),o().createElement(r.aaP,{id:"dependants",labelText:"Dependants",value:"dependants"}))),o().createElement("div",{className:w.patientConfirmSelection},o().createElement("div",{className:w.btnContainer},o().createElement(r.$nd,{kind:"primary",onClick:function(){I(!0)}}," ","Confirm")),o().createElement("div",{className:w.btnContainer},o().createElement(r.$nd,{kind:"secondary",onClick:z},"Cancel")))),o().createElement("div",{className:w.principalDependantSection},"principal"===E?o().createElement(o().Fragment,null,o().createElement(r.XIK,null,o().createElement(r.ndF,null,o().createElement(r.Hjg,null,o().createElement(r.A0N,null,"Name"),o().createElement(r.A0N,null,"CR"),o().createElement(r.A0N,null,"Phone No"),o().createElement(r.A0N,null,"ID No"))),o().createElement(r.BFY,null,o().createElement(r.Hjg,null,o().createElement(r.nA6,null,m.first_name," ",j(m.middle_name)," ",j(m.last_name)),o().createElement(r.nA6,null,R(m.id)),o().createElement(r.nA6,null,R(m.phone)),o().createElement(r.nA6,null,R(m.identification_number)))))):o().createElement(o().Fragment,null),"dependants"===E?o().createElement(o().Fragment,null,o().createElement(r.zWQ,{defaultSelected:"",helperText:"",invalidText:"",legendText:"",name:"dependant-group",onChange:function(e){return function(e){var t=m.dependants;if(t.length>0){var n=t.find((function(t){return t.result[0].id===e}));n&&_(n.result[0])}}(e)}},m.dependants.map((function(e){var t=e.result[0],n=e.relationship;return o().createElement(r.aaP,{id:t.id,labelText:ge(t,n),value:t.id})})))):o().createElement(o().Fragment,null),S?o().createElement($,{requestCustomOtpDto:Y,phoneNumber:m.phone,open:S,onModalClose:function(){I(!1)},onOtpSuccessfullVerification:function(){I(!1),O(!0)}}):o().createElement(o().Fragment,null),m&&P?o().createElement(o().Fragment,null,o().createElement(ne,{client:J(),open:P,onModalClose:W,onSubmit:function(){},onSendClientToTriage:function(e){return je((function(){var t;return Fe(this,(function(n){switch(n.label){case 0:return W(),[4,ae(e)];case 1:return(t=n.sent()).totalCount>0?(V("success","".concat(t.totalCount," ").concat(t.totalCount>0?"Patients":"Patient"," found in the system with ").concat(e),""),v(t.results),U(!0)):(V("error","Patient not found in the system",""),v([]),U(!0)),[2]}}))}))()}})," "):o().createElement(o().Fragment,null),m&&F?o().createElement(o().Fragment,null,o().createElement(be,{client:J(),patients:b,open:F,onModalClose:function(e){U(!1),e&&e.success&&L("/triage")},onSubmit:function(){},onCreateAmrsPatient:function(){return je((function(){var e,t,n,r,a,o,i,l,c,u,s,d;return Fe(this,(function(f){switch(f.label){case 0:if(!(e=J()))return V("error","Principal or dependant not selected",""),[2];f.label=1;case 1:return f.trys.push([1,3,,4]),[4,Pe(e,M)];case 2:return(t=f.sent())&&(V("success","Patient created succesfully",""),v([t])),[3,4];case 3:if(n=f.sent(),a=null!==(r=n.responseBody)&&void 0!==r?r:n.message,V("error","Error Creating Patient",""),o=function(e){var t=[];if(e&&e.error)if(e.error.error){var n=e.error.error.globalErrors||null;if(n){var r=!0,a=!1,o=void 0;try{for(var i,l=n[Symbol.iterator]();!(r=(i=l.next()).done);r=!0){var c=i.value;t.push(c.message)}}catch(e){a=!0,o=e}finally{try{r||null==l.return||l.return()}finally{if(a)throw o}}}}else if(e.error)if(e.error.globalErrors){var u=e.error.globalErrors||null;if(u){var s=!0,d=!1,f=void 0;try{for(var m,p=u[Symbol.iterator]();!(s=(m=p.next()).done);s=!0){var A=m.value;t.push(A.message)}}catch(e){d=!0,f=e}finally{try{s||null==p.return||p.return()}finally{if(d)throw f}}}}else e.error.message&&t.push(e.error.message);else t.push(e.error.error.message||"An error occurred while creating the patient. Please try again or contact support");return t}(a),o&&o.length>0){i=!0,l=!1,c=void 0;try{for(u=o[Symbol.iterator]();!(i=(s=u.next()).done);i=!0)d=s.value,V("error",d,"")}catch(e){l=!0,c=e}finally{try{i||null==u.return||u.return()}finally{if(l)throw c}}}return[3,4];case 4:return[2]}}))}))()},onManualRegistration:function(){U(!1),G()}})):o().createElement(o().Fragment,null)))):o().createElement(o().Fragment,null)))))}},62801:(e,t,n)=>{n.d(t,{E$:()=>c,SW:()=>u,bo:()=>s});var r=n(25987),a=n(38091);function o(e,t,n,r,a,o,i){try{var l=e[o](i),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(r,a)}function i(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var i=e.apply(t,n);function l(e){o(i,r,a,l,c,"next",e)}function c(e){o(i,r,a,l,c,"throw",e)}l(void 0)}))}}function l(e,t){var n,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return i.next=l(0),i.throw=l(1),i.return=l(2),"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(l){return function(c){return function(l){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,l[0]&&(o=0)),o;)try{if(n=1,r&&(a=2&l[0]?r.return:l[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,l[1])).done)return a;switch(r=0,a&&(l=[2&l[0],a.value]),l[0]){case 0:case 1:a=l;break;case 4:return o.label++,{value:l[1],done:!1};case 5:o.label++,r=l[1],l=[0];continue;case 7:l=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==l[0]&&2!==l[0])){o=0;continue}if(3===l[0]&&(!a||l[1]>a[0]&&l[1]<a[3])){o.label=l[1];break}if(6===l[0]&&o.label<a[1]){o.label=a[1],a=l;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(l);break}a[2]&&o.ops.pop(),o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e],r=0}finally{n=a=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}([l,c])}}}function c(){return i((function(){var e;return l(this,(function(t){switch(t.label){case 0:return[4,(0,r.getConfig)(a.moduleName)];case 1:return[2,null!=(e=t.sent().subDomainUrl)?e:null]}}))}))()}function u(){return i((function(){var e;return l(this,(function(t){switch(t.label){case 0:return[4,(0,r.getConfig)(a.moduleName)];case 1:return[2,null!=(e=t.sent().etlBaseUrl)?e:null]}}))}))()}function s(){return i((function(){var e;return l(this,(function(t){switch(t.label){case 0:return[4,(0,r.getConfig)(a.moduleName)];case 1:return[2,null!=(e=t.sent().hieBaseUrl)?e:null]}}))}))()}},75862:(e,t,n)=>{n.d(t,{XA:()=>o,cn:()=>a,i3:()=>r});var r={NORMAL_PRIORITY_UUID:"bbd99c12-67e9-4381-8b4c-1f231e86f8e2",EMERGENCY_PRIORITY_UUID:"8e86ff12-ec83-41e8-a534-bb410739d880"},a={WAITING_UUID:"89d01aa5-0ab0-4626-934b-37766b4cd779",IN_SERVICE_UUID:"f9cf5768-508f-45de-8d40-eaf6ea3f3b02",COMPLETED_UUID:"a89c1ef8-1350-11df-a1f1-0026b9348838"},o={TRIAGE_SERVICE_UUID:"2d4472e2-d7ab-4430-8e0e-a9ffcd809bf4",CLINICAL_CONSULTATION_SERVICE_UUID:"7f7ec7ad-cdd7-4ed9-bc2e-5c5bd9f065b2"}},84497:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(72996),a=n.n(r),o=n(70159),i=n.n(o)()(a());i.push([e.id,".-esm-dha-workflow__otp-verification-modal__modalVerificationLayout___MST8n{display:flex;flex-direction:column;row-gap:10px;width:100%}.-esm-dha-workflow__otp-verification-modal__sectionHeader___g62oo{display:flex;flex-direction:column;column-gap:5px;margin-top:5px;margin-bottom:5px}.-esm-dha-workflow__otp-verification-modal__otpSection___R\\+cLH{display:flex;flex-direction:column;width:100%;row-gap:15px}","",{version:3,sources:["webpack://./src/registry/modal/otp-verification-modal/otp-verification-modal.scss"],names:[],mappings:"AAAA,4EACE,YAAA,CACA,qBAAA,CACA,YAAA,CACA,UAAA,CAEF,kEACE,YAAA,CACA,qBAAA,CACA,cAAA,CACA,cAAA,CACA,iBAAA,CAEF,gEACE,YAAA,CACA,qBAAA,CACA,UAAA,CACA,YAAA",sourcesContent:[".modalVerificationLayout {\n display: flex;\n flex-direction: column;\n row-gap: 10px;\n width: 100%;\n}\n.sectionHeader{\n display: flex;\n flex-direction: column;\n column-gap: 5px;\n margin-top: 5px;\n margin-bottom: 5px;\n}\n.otpSection{\n display: flex;\n flex-direction: column;\n width: 100%;\n row-gap: 15px;\n}"],sourceRoot:""}]),i.locals={modalVerificationLayout:"-esm-dha-workflow__otp-verification-modal__modalVerificationLayout___MST8n",sectionHeader:"-esm-dha-workflow__otp-verification-modal__sectionHeader___g62oo",otpSection:"-esm-dha-workflow__otp-verification-modal__otpSection___R+cLH"};const l=i},86575:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(72996),a=n.n(r),o=n(70159),i=n.n(o)()(a());i.push([e.id,".-esm-dha-workflow__client-details-modal__clientDetailsLayout___r5WF\\+{display:flex;flex-direction:column;width:100%;row-gap:5px}.-esm-dha-workflow__client-details-modal__sectionHeader___lH-gL{display:flex;flex-direction:column;row-gap:5px;margin-top:5px;margin-bottom:10px}.-esm-dha-workflow__client-details-modal__sectionContent___QDFT7{display:flex;flex-direction:column;row-gap:5px}.-esm-dha-workflow__client-details-modal__actionSection___okVDp{display:flex;flex-direction:row;width:100%;column-gap:5px}.-esm-dha-workflow__client-details-modal__btnContainer___ETNEk{margin-top:2px;margin-bottom:2px}","",{version:3,sources:["webpack://./src/registry/modal/client-details-modal/client-details-modal.scss"],names:[],mappings:"AAAA,uEACI,YAAA,CACA,qBAAA,CACA,UAAA,CACA,WAAA,CAEJ,gEACI,YAAA,CACA,qBAAA,CACA,WAAA,CACA,cAAA,CACA,kBAAA,CAEJ,iEACI,YAAA,CACA,qBAAA,CACA,WAAA,CAEJ,gEACI,YAAA,CACA,kBAAA,CACA,UAAA,CACA,cAAA,CAEJ,+DACI,cAAA,CACA,iBAAA",sourcesContent:[".clientDetailsLayout{\n display: flex;\n flex-direction: column;\n width: 100%;\n row-gap: 5px;\n}\n.sectionHeader{\n display: flex;\n flex-direction: column;\n row-gap: 5px;\n margin-top: 5px;\n margin-bottom: 10px;\n}\n.sectionContent{\n display: flex;\n flex-direction: column;\n row-gap: 5px;\n}\n.actionSection{\n display: flex;\n flex-direction: row;\n width: 100%;\n column-gap: 5px;\n}\n.btnContainer{\n margin-top: 2px;\n margin-bottom: 2px;\n}"],sourceRoot:""}]),i.locals={clientDetailsLayout:"-esm-dha-workflow__client-details-modal__clientDetailsLayout___r5WF+",sectionHeader:"-esm-dha-workflow__client-details-modal__sectionHeader___lH-gL",sectionContent:"-esm-dha-workflow__client-details-modal__sectionContent___QDFT7",actionSection:"-esm-dha-workflow__client-details-modal__actionSection___okVDp",btnContainer:"-esm-dha-workflow__client-details-modal__btnContainer___ETNEk"};const l=i}}]);