@openmrs/esm-patient-tests-app 11.3.1-pre.9365 → 11.3.1-pre.9369

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- var _openmrs_esm_patient_tests_app;(()=>{"use strict";var e,r,t,n,o,a,i,s,l,u,p,f,c,d,h,m,v,g,b,y,w,_={38584:(e,r,t)=>{var n={"./start":()=>Promise.all([t.e(8307),t.e(1778),t.e(1343),t.e(5434),t.e(3205),t.e(6231)]).then((()=>()=>t(26231)))},o=(e,r)=>(t.R=r,r=t.o(n,e)?n[e]():Promise.resolve().then((()=>{throw new Error('Module "'+e+'" does not exist in container.')})),t.R=void 0,r),a=(e,r)=>{if(t.S){var n="default",o=t.S[n];if(o&&o!==e)throw new Error("Container initialization failed as it has already been initialized with a different share scope");return t.S[n]=e,t.I(n,r)}};t.d(r,{get:()=>o,init:()=>a})}},P={};function S(e){var r=P[e];if(void 0!==r)return r.exports;var t=P[e]={id:e,exports:{}};return _[e].call(t.exports,t,t.exports,S),t.exports}S.m=_,S.c=P,S.n=e=>{var r=e&&e.__esModule?()=>e.default:()=>e;return S.d(r,{a:r}),r},r=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,S.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);S.r(o);var a={};e=e||[null,r({}),r([]),r(r)];for(var i=2&n&&t;"object"==typeof i&&!~e.indexOf(i);i=r(i))Object.getOwnPropertyNames(i).forEach((e=>a[e]=()=>t[e]));return a.default=()=>t,S.d(o,a),o},S.d=(e,r)=>{for(var t in r)S.o(r,t)&&!S.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:r[t]})},S.f={},S.e=e=>Promise.all(Object.keys(S.f).reduce(((r,t)=>(S.f[t](e,r),r)),[])),S.u=e=>e+".js",S.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),S.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r),t={},n="@openmrs/esm-patient-tests-app:",S.l=(e,r,o,a)=>{if(t[e])t[e].push(r);else{var i,s;if(void 0!==o)for(var l=document.getElementsByTagName("script"),u=0;u<l.length;u++){var p=l[u];if(p.getAttribute("src")==e||p.getAttribute("data-webpack")==n+o){i=p;break}}i||(s=!0,(i=document.createElement("script")).charset="utf-8",i.timeout=120,S.nc&&i.setAttribute("nonce",S.nc),i.setAttribute("data-webpack",n+o),i.src=e),t[e]=[r];var f=(r,n)=>{i.onerror=i.onload=null,clearTimeout(c);var o=t[e];if(delete t[e],i.parentNode&&i.parentNode.removeChild(i),o&&o.forEach((e=>e(n))),r)return r(n)},c=setTimeout(f.bind(null,void 0,{type:"timeout",target:i}),12e4);i.onerror=f.bind(null,i.onerror),i.onload=f.bind(null,i.onload),s&&document.head.appendChild(i)}},S.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{S.S={};var e={},r={};S.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];S.o(S.S,t)||(S.S[t]={});var a=S.S[t],i="@openmrs/esm-patient-tests-app",s=(e,r,t,n)=>{var o=a[e]=a[e]||{},s=o[r];(!s||!s.loaded&&(!n!=!s.eager?n:i>s.from))&&(o[r]={get:t,from:i,eager:!!n})},l=[];return"default"===t&&(s("@openmrs/esm-framework","8.0.1-pre.3485",(()=>Promise.all([S.e(9540),S.e(8307),S.e(5670),S.e(1343),S.e(8010),S.e(5434),S.e(4818),S.e(3205)]).then((()=>()=>S(55670))))),s("@openmrs/esm-patient-common-lib","11.3.1-pre.9365",(()=>Promise.all([S.e(9540),S.e(8307),S.e(1343),S.e(8010),S.e(5434),S.e(4818),S.e(3205),S.e(34),S.e(7473)]).then((()=>()=>S(60034))))),s("react-i18next","16.0.0",(()=>Promise.all([S.e(6336),S.e(1343)]).then((()=>()=>S(16336))))),s("react-router-dom","6.16.0",(()=>Promise.all([S.e(2913),S.e(1343)]).then((()=>()=>S(52913))))),s("react","18.3.1",(()=>S.e(4041).then((()=>()=>S(14041))))),s("rxjs","6.6.7",(()=>S.e(2457).then((()=>()=>S(82457))))),s("swr/_internal","2.2.5",(()=>Promise.all([S.e(2372),S.e(1343)]).then((()=>()=>S(42372))))),s("swr/immutable","2.2.5",(()=>Promise.all([S.e(1343),S.e(5434),S.e(7495)]).then((()=>()=>S(29876))))),s("swr/infinite","2.2.5",(()=>Promise.all([S.e(1343),S.e(5434),S.e(89)]).then((()=>()=>S(52470)))))),e[t]=l.length?Promise.all(l).then((()=>e[t]=1)):1}}})(),(()=>{var e;S.g.importScripts&&(e=S.g.location+"");var r=S.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(/\/[^\/]+$/,"/"),S.p=e})(),o=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},a=(e,r)=>{e=o(e),r=o(r);for(var t=0;;){if(t>=e.length)return t<r.length&&"u"!=(typeof r[t])[0];var n=e[t],a=(typeof n)[0];if(t>=r.length)return"u"==a;var i=r[t],s=(typeof i)[0];if(a!=s)return"o"==a&&"n"==s||"s"==s||"u"==a;if("o"!=a&&"u"!=a&&n!=i)return n<i;t++}},i=e=>{var r=e[0],t="";if(1===e.length)return"*";if(r+.5){t+=0==r?">=":-1==r?"<":1==r?"^":2==r?"~":r>0?"=":"!=";for(var n=1,o=1;o<e.length;o++)n--,t+="u"==(typeof(s=e[o]))[0]?"-":(n>0?".":"")+(n=2,s);return t}var a=[];for(o=1;o<e.length;o++){var s=e[o];a.push(0===s?"not("+l()+")":1===s?"("+l()+" || "+l()+")":2===s?a.pop()+" "+a.pop():i(s))}return l();function l(){return a.pop().replace(/^\((.+)\)$/,"$1")}},s=(e,r)=>{if(0 in e){r=o(r);var t=e[0],n=t<0;n&&(t=-t-1);for(var a=0,i=1,l=!0;;i++,a++){var u,p,f=i<e.length?(typeof e[i])[0]:"";if(a>=r.length||"o"==(p=(typeof(u=r[a]))[0]))return!l||("u"==f?i>t&&!n:""==f!=n);if("u"==p){if(!l||"u"!=f)return!1}else if(l)if(f==p)if(i<=t){if(u!=e[i])return!1}else{if(n?u>e[i]:u<e[i])return!1;u!=e[i]&&(l=!1)}else if("s"!=f&&"n"!=f){if(n||i<=t)return!1;l=!1,i--}else{if(i<=t||p<f!=n)return!1;l=!1}else"s"!=f&&"n"!=f&&(l=!1,i--)}}var c=[],d=c.pop.bind(c);for(a=1;a<e.length;a++){var h=e[a];c.push(1==h?d()|d():2==h?d()&d():h?s(h,r):!d())}return!!d()},l=(e,r)=>e&&S.o(e,r),u=e=>(e.loaded=1,e.get()),p=e=>Object.keys(e).reduce(((r,t)=>(e[t].eager&&(r[t]=e[t]),r)),{}),f=(e,r,t)=>{var n=t?p(e[r]):e[r];return Object.keys(n).reduce(((e,r)=>!e||!n[e].loaded&&a(e,r)?r:e),0)},c=(e,r,t,n)=>"Unsatisfied version "+t+" from "+(t&&e[r][t].from)+" of shared singleton module "+r+" (required "+i(n)+")",d=e=>{throw new Error(e)},h=e=>{"undefined"!=typeof console&&console.warn&&console.warn(e)},m=(e,r,t)=>t?t():((e,r)=>d("Shared module "+r+" doesn't exist in shared scope "+e))(e,r),v=(e=>function(r,t,n,o,a){var i=S.I(r);return i&&i.then&&!n?i.then(e.bind(e,r,S.S[r],t,!1,o,a)):e(r,S.S[r],t,n,o,a)})(((e,r,t,n,o,a)=>{if(!l(r,t))return m(e,t,a);var i=f(r,t,n);return s(o,i)||h(c(r,t,i,o)),u(r[t][i])})),g={},b={1343:()=>v("default","react",!1,[1,18],(()=>S.e(4041).then((()=>()=>S(14041))))),88010:()=>v("default","swr/immutable",!1,[1,2],(()=>S.e(9876).then((()=>()=>S(29876))))),55434:()=>v("default","swr/_internal",!1,[1,2],(()=>S.e(2372).then((()=>()=>S(42372))))),24818:()=>v("default","rxjs",!1,[1,6],(()=>S.e(2457).then((()=>()=>S(82457))))),8877:()=>v("default","react-router-dom",!1,[1,6],(()=>S.e(2913).then((()=>()=>S(52913))))),54440:()=>v("default","@openmrs/esm-framework",!1,[1,8],(()=>Promise.all([S.e(9540),S.e(5670),S.e(8010),S.e(4818)]).then((()=>()=>S(55670))))),72339:()=>v("default","react-i18next",!1,[1,16],(()=>S.e(6336).then((()=>()=>S(16336))))),98394:()=>v("default","swr/infinite",!1,[1,2],(()=>S.e(2470).then((()=>()=>S(52470))))),36274:()=>v("default","@openmrs/esm-patient-common-lib",!1,[1,11],(()=>Promise.all([S.e(9540),S.e(8010),S.e(4818),S.e(34)]).then((()=>()=>S(60034)))))},y={1343:[1343],3205:[8877,54440,72339,98394],4818:[24818],5434:[55434],6231:[36274],8010:[88010]},w={},S.f.consumes=(e,r)=>{S.o(y,e)&&y[e].forEach((e=>{if(S.o(g,e))return r.push(g[e]);if(!w[e]){var t=r=>{g[e]=0,S.m[e]=t=>{delete S.c[e],t.exports=r()}};w[e]=!0;var n=r=>{delete g[e],S.m[e]=t=>{throw delete S.c[e],r}};try{var o=b[e]();o.then?r.push(g[e]=o.then(t).catch(n)):t(o)}catch(e){n(e)}}}))},(()=>{var e={7773:0};S.f.j=(r,t)=>{var n=S.o(e,r)?e[r]:void 0;if(0!==n)if(n)t.push(n[2]);else if(/^(1343|3205|4818|5434|8010)$/.test(r))e[r]=0;else{var o=new Promise(((t,o)=>n=e[r]=[t,o]));t.push(n[2]=o);var a=S.p+S.u(r),i=new Error;S.l(a,(t=>{if(S.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;i.message="Loading chunk "+r+" failed.\n("+o+": "+a+")",i.name="ChunkLoadError",i.type=o,i.request=a,n[1](i)}}),"chunk-"+r,r)}};var r=(r,t)=>{var n,o,[a,i,s]=t,l=0;if(a.some((r=>0!==e[r]))){for(n in i)S.o(i,n)&&(S.m[n]=i[n]);s&&s(S)}for(r&&r(t);l<a.length;l++)o=a[l],S.o(e,o)&&e[o]&&e[o][0](),e[o]=0},t=globalThis.webpackChunk_openmrs_esm_patient_tests_app=globalThis.webpackChunk_openmrs_esm_patient_tests_app||[];t.forEach(r.bind(null,0)),t.push=r.bind(null,t.push.bind(t))})(),S.nc=void 0;var j=S(38584);_openmrs_esm_patient_tests_app=j})();
1
+ var _openmrs_esm_patient_tests_app;(()=>{"use strict";var e,r,t,n,o,a,i,s,l,u,p,f,c,d,h,m,v,g,b,y,w,_={38584:(e,r,t)=>{var n={"./start":()=>Promise.all([t.e(8307),t.e(1778),t.e(1343),t.e(5434),t.e(3205),t.e(6231)]).then((()=>()=>t(26231)))},o=(e,r)=>(t.R=r,r=t.o(n,e)?n[e]():Promise.resolve().then((()=>{throw new Error('Module "'+e+'" does not exist in container.')})),t.R=void 0,r),a=(e,r)=>{if(t.S){var n="default",o=t.S[n];if(o&&o!==e)throw new Error("Container initialization failed as it has already been initialized with a different share scope");return t.S[n]=e,t.I(n,r)}};t.d(r,{get:()=>o,init:()=>a})}},P={};function S(e){var r=P[e];if(void 0!==r)return r.exports;var t=P[e]={id:e,exports:{}};return _[e].call(t.exports,t,t.exports,S),t.exports}S.m=_,S.c=P,S.n=e=>{var r=e&&e.__esModule?()=>e.default:()=>e;return S.d(r,{a:r}),r},r=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,S.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);S.r(o);var a={};e=e||[null,r({}),r([]),r(r)];for(var i=2&n&&t;"object"==typeof i&&!~e.indexOf(i);i=r(i))Object.getOwnPropertyNames(i).forEach((e=>a[e]=()=>t[e]));return a.default=()=>t,S.d(o,a),o},S.d=(e,r)=>{for(var t in r)S.o(r,t)&&!S.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:r[t]})},S.f={},S.e=e=>Promise.all(Object.keys(S.f).reduce(((r,t)=>(S.f[t](e,r),r)),[])),S.u=e=>e+".js",S.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),S.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r),t={},n="@openmrs/esm-patient-tests-app:",S.l=(e,r,o,a)=>{if(t[e])t[e].push(r);else{var i,s;if(void 0!==o)for(var l=document.getElementsByTagName("script"),u=0;u<l.length;u++){var p=l[u];if(p.getAttribute("src")==e||p.getAttribute("data-webpack")==n+o){i=p;break}}i||(s=!0,(i=document.createElement("script")).charset="utf-8",i.timeout=120,S.nc&&i.setAttribute("nonce",S.nc),i.setAttribute("data-webpack",n+o),i.src=e),t[e]=[r];var f=(r,n)=>{i.onerror=i.onload=null,clearTimeout(c);var o=t[e];if(delete t[e],i.parentNode&&i.parentNode.removeChild(i),o&&o.forEach((e=>e(n))),r)return r(n)},c=setTimeout(f.bind(null,void 0,{type:"timeout",target:i}),12e4);i.onerror=f.bind(null,i.onerror),i.onload=f.bind(null,i.onload),s&&document.head.appendChild(i)}},S.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{S.S={};var e={},r={};S.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];S.o(S.S,t)||(S.S[t]={});var a=S.S[t],i="@openmrs/esm-patient-tests-app",s=(e,r,t,n)=>{var o=a[e]=a[e]||{},s=o[r];(!s||!s.loaded&&(!n!=!s.eager?n:i>s.from))&&(o[r]={get:t,from:i,eager:!!n})},l=[];return"default"===t&&(s("@openmrs/esm-framework","8.0.1-pre.3498",(()=>Promise.all([S.e(9540),S.e(8307),S.e(5670),S.e(1343),S.e(8010),S.e(5434),S.e(4818),S.e(3205)]).then((()=>()=>S(55670))))),s("@openmrs/esm-patient-common-lib","11.3.1-pre.9369",(()=>Promise.all([S.e(9540),S.e(8307),S.e(1343),S.e(8010),S.e(5434),S.e(4818),S.e(3205),S.e(34),S.e(7473)]).then((()=>()=>S(60034))))),s("react-i18next","16.0.0",(()=>Promise.all([S.e(6336),S.e(1343)]).then((()=>()=>S(16336))))),s("react-router-dom","6.16.0",(()=>Promise.all([S.e(2913),S.e(1343)]).then((()=>()=>S(52913))))),s("react","18.3.1",(()=>S.e(4041).then((()=>()=>S(14041))))),s("rxjs","6.6.7",(()=>S.e(2457).then((()=>()=>S(82457))))),s("swr/_internal","2.2.5",(()=>Promise.all([S.e(2372),S.e(1343)]).then((()=>()=>S(42372))))),s("swr/immutable","2.2.5",(()=>Promise.all([S.e(1343),S.e(5434),S.e(7495)]).then((()=>()=>S(29876))))),s("swr/infinite","2.2.5",(()=>Promise.all([S.e(1343),S.e(5434),S.e(89)]).then((()=>()=>S(52470)))))),e[t]=l.length?Promise.all(l).then((()=>e[t]=1)):1}}})(),(()=>{var e;S.g.importScripts&&(e=S.g.location+"");var r=S.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(/\/[^\/]+$/,"/"),S.p=e})(),o=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},a=(e,r)=>{e=o(e),r=o(r);for(var t=0;;){if(t>=e.length)return t<r.length&&"u"!=(typeof r[t])[0];var n=e[t],a=(typeof n)[0];if(t>=r.length)return"u"==a;var i=r[t],s=(typeof i)[0];if(a!=s)return"o"==a&&"n"==s||"s"==s||"u"==a;if("o"!=a&&"u"!=a&&n!=i)return n<i;t++}},i=e=>{var r=e[0],t="";if(1===e.length)return"*";if(r+.5){t+=0==r?">=":-1==r?"<":1==r?"^":2==r?"~":r>0?"=":"!=";for(var n=1,o=1;o<e.length;o++)n--,t+="u"==(typeof(s=e[o]))[0]?"-":(n>0?".":"")+(n=2,s);return t}var a=[];for(o=1;o<e.length;o++){var s=e[o];a.push(0===s?"not("+l()+")":1===s?"("+l()+" || "+l()+")":2===s?a.pop()+" "+a.pop():i(s))}return l();function l(){return a.pop().replace(/^\((.+)\)$/,"$1")}},s=(e,r)=>{if(0 in e){r=o(r);var t=e[0],n=t<0;n&&(t=-t-1);for(var a=0,i=1,l=!0;;i++,a++){var u,p,f=i<e.length?(typeof e[i])[0]:"";if(a>=r.length||"o"==(p=(typeof(u=r[a]))[0]))return!l||("u"==f?i>t&&!n:""==f!=n);if("u"==p){if(!l||"u"!=f)return!1}else if(l)if(f==p)if(i<=t){if(u!=e[i])return!1}else{if(n?u>e[i]:u<e[i])return!1;u!=e[i]&&(l=!1)}else if("s"!=f&&"n"!=f){if(n||i<=t)return!1;l=!1,i--}else{if(i<=t||p<f!=n)return!1;l=!1}else"s"!=f&&"n"!=f&&(l=!1,i--)}}var c=[],d=c.pop.bind(c);for(a=1;a<e.length;a++){var h=e[a];c.push(1==h?d()|d():2==h?d()&d():h?s(h,r):!d())}return!!d()},l=(e,r)=>e&&S.o(e,r),u=e=>(e.loaded=1,e.get()),p=e=>Object.keys(e).reduce(((r,t)=>(e[t].eager&&(r[t]=e[t]),r)),{}),f=(e,r,t)=>{var n=t?p(e[r]):e[r];return Object.keys(n).reduce(((e,r)=>!e||!n[e].loaded&&a(e,r)?r:e),0)},c=(e,r,t,n)=>"Unsatisfied version "+t+" from "+(t&&e[r][t].from)+" of shared singleton module "+r+" (required "+i(n)+")",d=e=>{throw new Error(e)},h=e=>{"undefined"!=typeof console&&console.warn&&console.warn(e)},m=(e,r,t)=>t?t():((e,r)=>d("Shared module "+r+" doesn't exist in shared scope "+e))(e,r),v=(e=>function(r,t,n,o,a){var i=S.I(r);return i&&i.then&&!n?i.then(e.bind(e,r,S.S[r],t,!1,o,a)):e(r,S.S[r],t,n,o,a)})(((e,r,t,n,o,a)=>{if(!l(r,t))return m(e,t,a);var i=f(r,t,n);return s(o,i)||h(c(r,t,i,o)),u(r[t][i])})),g={},b={1343:()=>v("default","react",!1,[1,18],(()=>S.e(4041).then((()=>()=>S(14041))))),88010:()=>v("default","swr/immutable",!1,[1,2],(()=>S.e(9876).then((()=>()=>S(29876))))),55434:()=>v("default","swr/_internal",!1,[1,2],(()=>S.e(2372).then((()=>()=>S(42372))))),24818:()=>v("default","rxjs",!1,[1,6],(()=>S.e(2457).then((()=>()=>S(82457))))),8877:()=>v("default","react-router-dom",!1,[1,6],(()=>S.e(2913).then((()=>()=>S(52913))))),54440:()=>v("default","@openmrs/esm-framework",!1,[1,8],(()=>Promise.all([S.e(9540),S.e(5670),S.e(8010),S.e(4818)]).then((()=>()=>S(55670))))),72339:()=>v("default","react-i18next",!1,[1,16],(()=>S.e(6336).then((()=>()=>S(16336))))),98394:()=>v("default","swr/infinite",!1,[1,2],(()=>S.e(2470).then((()=>()=>S(52470))))),36274:()=>v("default","@openmrs/esm-patient-common-lib",!1,[1,11],(()=>Promise.all([S.e(9540),S.e(8010),S.e(4818),S.e(34)]).then((()=>()=>S(60034)))))},y={1343:[1343],3205:[8877,54440,72339,98394],4818:[24818],5434:[55434],6231:[36274],8010:[88010]},w={},S.f.consumes=(e,r)=>{S.o(y,e)&&y[e].forEach((e=>{if(S.o(g,e))return r.push(g[e]);if(!w[e]){var t=r=>{g[e]=0,S.m[e]=t=>{delete S.c[e],t.exports=r()}};w[e]=!0;var n=r=>{delete g[e],S.m[e]=t=>{throw delete S.c[e],r}};try{var o=b[e]();o.then?r.push(g[e]=o.then(t).catch(n)):t(o)}catch(e){n(e)}}}))},(()=>{var e={7773:0};S.f.j=(r,t)=>{var n=S.o(e,r)?e[r]:void 0;if(0!==n)if(n)t.push(n[2]);else if(/^(1343|3205|4818|5434|8010)$/.test(r))e[r]=0;else{var o=new Promise(((t,o)=>n=e[r]=[t,o]));t.push(n[2]=o);var a=S.p+S.u(r),i=new Error;S.l(a,(t=>{if(S.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;i.message="Loading chunk "+r+" failed.\n("+o+": "+a+")",i.name="ChunkLoadError",i.type=o,i.request=a,n[1](i)}}),"chunk-"+r,r)}};var r=(r,t)=>{var n,o,[a,i,s]=t,l=0;if(a.some((r=>0!==e[r]))){for(n in i)S.o(i,n)&&(S.m[n]=i[n]);s&&s(S)}for(r&&r(t);l<a.length;l++)o=a[l],S.o(e,o)&&e[o]&&e[o][0](),e[o]=0},t=globalThis.webpackChunk_openmrs_esm_patient_tests_app=globalThis.webpackChunk_openmrs_esm_patient_tests_app||[];t.forEach(r.bind(null,0)),t.push=r.bind(null,t.push.bind(t))})(),S.nc=void 0;var j=S(38584);_openmrs_esm_patient_tests_app=j})();
@@ -976,9 +976,9 @@
976
976
  "initial": false,
977
977
  "entry": false,
978
978
  "recorded": false,
979
- "size": 749464,
979
+ "size": 750995,
980
980
  "sizes": {
981
- "javascript": 749422,
981
+ "javascript": 750953,
982
982
  "consume-shared": 42
983
983
  },
984
984
  "names": [],
@@ -992,7 +992,7 @@
992
992
  "auxiliaryFiles": [
993
993
  "6231.js.map"
994
994
  ],
995
- "hash": "e67fda053b106c4f",
995
+ "hash": "0139f1cdae44e71d",
996
996
  "childrenByOrder": {}
997
997
  },
998
998
  {
@@ -1016,7 +1016,7 @@
1016
1016
  "auxiliaryFiles": [
1017
1017
  "6301.js.map"
1018
1018
  ],
1019
- "hash": "16bb533ce67c7a5b",
1019
+ "hash": "1d86341610b3d59b",
1020
1020
  "childrenByOrder": {}
1021
1021
  },
1022
1022
  {
@@ -1321,7 +1321,7 @@
1321
1321
  "auxiliaryFiles": [
1322
1322
  "openmrs-esm-patient-tests-app.js.map"
1323
1323
  ],
1324
- "hash": "adb77de7cc1c1c18",
1324
+ "hash": "4b5fc59913a61186",
1325
1325
  "childrenByOrder": {}
1326
1326
  },
1327
1327
  {
@@ -1465,10 +1465,10 @@
1465
1465
  "initial": true,
1466
1466
  "entry": true,
1467
1467
  "recorded": false,
1468
- "size": 3746787,
1468
+ "size": 3748318,
1469
1469
  "sizes": {
1470
1470
  "consume-shared": 294,
1471
- "javascript": 3723575,
1471
+ "javascript": 3725106,
1472
1472
  "share-init": 378,
1473
1473
  "runtime": 22540
1474
1474
  },
@@ -1485,7 +1485,7 @@
1485
1485
  "auxiliaryFiles": [
1486
1486
  "main.js.map"
1487
1487
  ],
1488
- "hash": "dd79658ff5eaa67b",
1488
+ "hash": "5623a8059c2b4f28",
1489
1489
  "childrenByOrder": {}
1490
1490
  },
1491
1491
  {
@@ -1538,9 +1538,9 @@
1538
1538
  "entry": false,
1539
1539
  "recorded": false,
1540
1540
  "reason": "split chunk (cache group: defaultVendors)",
1541
- "size": 4299554,
1541
+ "size": 4300961,
1542
1542
  "sizes": {
1543
- "javascript": 4299554
1543
+ "javascript": 4300961
1544
1544
  },
1545
1545
  "names": [],
1546
1546
  "idHints": [
@@ -1556,7 +1556,7 @@
1556
1556
  "auxiliaryFiles": [
1557
1557
  "9540.js.map"
1558
1558
  ],
1559
- "hash": "b69d5e0b08dd8876",
1559
+ "hash": "ba8d2a5737ecd71f",
1560
1560
  "childrenByOrder": {}
1561
1561
  },
1562
1562
  {
package/dist/routes.json CHANGED
@@ -1 +1 @@
1
- {"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{"fhir2":">=1.2","webservices.rest":">=2.2.0"},"extensions":[{"name":"test-results-summary-dashboard","component":"testResultsDashboardLink","slot":"patient-chart-dashboard-slot","meta":{"slot":"patient-chart-test-results-dashboard-slot","path":"Results","hideDashboardTitle":true,"layoutMode":"anchored"},"order":4},{"name":"test-results-filtered-overview","slot":"test-results-filtered-overview-slot","component":"externalOverview"},{"name":"results-viewer","slots":["patient-chart-results-viewer-slot","patient-chart-test-results-dashboard-slot"],"component":"resultsViewer"},{"name":"lab-order-panel","component":"labOrderPanel","slot":"order-basket-slot","order":2}],"modals":[{"name":"timeline-results-modal","component":"timelineResultsModal"},{"name":"print-modal","component":"printModal"},{"name":"edit-lab-results-modal","component":"editLabResultsModal"}],"workspaces":[{"name":"add-lab-order","type":"order","component":"addLabOrderWorkspace","title":"addLabOrderWorkspaceTitle"}],"version":"11.3.1-pre.9365"}
1
+ {"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{"fhir2":">=1.2","webservices.rest":">=2.2.0"},"extensions":[{"name":"test-results-summary-dashboard","component":"testResultsDashboardLink","slot":"patient-chart-dashboard-slot","meta":{"slot":"patient-chart-test-results-dashboard-slot","path":"Results","hideDashboardTitle":true,"layoutMode":"anchored"},"order":4},{"name":"test-results-filtered-overview","slot":"test-results-filtered-overview-slot","component":"externalOverview"},{"name":"results-viewer","slots":["patient-chart-results-viewer-slot","patient-chart-test-results-dashboard-slot"],"component":"resultsViewer"},{"name":"lab-order-panel","component":"labOrderPanel","slot":"order-basket-slot","order":2}],"modals":[{"name":"timeline-results-modal","component":"timelineResultsModal"},{"name":"print-modal","component":"printModal"},{"name":"edit-lab-results-modal","component":"editLabResultsModal"}],"workspaces":[{"name":"add-lab-order","type":"order","component":"addLabOrderWorkspace","title":"addLabOrderWorkspaceTitle"}],"version":"11.3.1-pre.9369"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openmrs/esm-patient-tests-app",
3
- "version": "11.3.1-pre.9365",
3
+ "version": "11.3.1-pre.9369",
4
4
  "license": "MPL-2.0",
5
5
  "description": "Patient test order and results microfrontend for the OpenMRS SPA",
6
6
  "browser": "dist/openmrs-esm-patient-tests-app.js",
@@ -53,7 +53,7 @@
53
53
  "swr": "2.x"
54
54
  },
55
55
  "devDependencies": {
56
- "@openmrs/esm-patient-common-lib": "11.3.1-pre.9365",
56
+ "@openmrs/esm-patient-common-lib": "11.3.1-pre.9369",
57
57
  "webpack": "^5.99.9"
58
58
  },
59
59
  "stableVersion": "11.3.0"
@@ -62,7 +62,8 @@ describe('GroupedTimeline', () => {
62
62
  expect(screen.getByText('Nov 9')).toBeInTheDocument();
63
63
  expect(screen.getByText('01:39 AM')).toBeInTheDocument();
64
64
  expect(screen.getByText('Total bilirubin')).toBeInTheDocument();
65
- expect(screen.getByText('umol/L')).toBeInTheDocument();
65
+ // Units are now combined with range, so if there's no range, units won't be displayed separately
66
+ // Total bilirubin doesn't have a range in timelineData, so units are not displayed
66
67
  expect(screen.getByText('261.9')).toBeInTheDocument();
67
68
  expect(screen.getByText('21.5')).toBeInTheDocument();
68
69
  expect(screen.getByText('Serum glutamic-pyruvic transaminase')).toBeInTheDocument();
@@ -1,8 +1,9 @@
1
1
  import {
2
- selectReferenceRange,
2
+ formatRangeWithUnits,
3
3
  formatReferenceRange,
4
4
  getMostRecentObservationWithRange,
5
5
  rangeAlreadyHasUnits,
6
+ selectReferenceRange,
6
7
  type ReferenceRanges,
7
8
  } from './reference-range-helpers';
8
9
 
@@ -269,4 +270,39 @@ describe('Reference Range Helpers', () => {
269
270
  expect(rangeAlreadyHasUnits('0 – 50', '')).toBe(false);
270
271
  });
271
272
  });
273
+
274
+ describe('formatRangeWithUnits', () => {
275
+ it('returns "--" when range is undefined', () => {
276
+ expect(formatRangeWithUnits(undefined, 'U/L')).toBe('--');
277
+ });
278
+
279
+ it('returns "--" when range is empty string', () => {
280
+ expect(formatRangeWithUnits('', 'U/L')).toBe('--');
281
+ });
282
+
283
+ it('returns range as-is when range already includes units', () => {
284
+ expect(formatRangeWithUnits('0 – 50 U/L', 'U/L')).toBe('0 – 50 U/L');
285
+ });
286
+
287
+ it('appends units when range does not include units', () => {
288
+ expect(formatRangeWithUnits('0 – 50', 'U/L')).toBe('0 – 50 U/L');
289
+ });
290
+
291
+ it('returns range without units when units is undefined', () => {
292
+ expect(formatRangeWithUnits('0 – 50', undefined)).toBe('0 – 50');
293
+ });
294
+
295
+ it('returns range without units when units is empty', () => {
296
+ expect(formatRangeWithUnits('0 – 50', '')).toBe('0 – 50');
297
+ });
298
+
299
+ it('handles trimmed strings correctly', () => {
300
+ expect(formatRangeWithUnits(' 0 – 50 ', ' U/L ')).toBe('0 – 50 U/L');
301
+ });
302
+
303
+ it('handles range with units and different units parameter', () => {
304
+ // If range already has units, don't append different units
305
+ expect(formatRangeWithUnits('0 – 50 mg/dL', 'U/L')).toBe('0 – 50 mg/dL');
306
+ });
307
+ });
272
308
  });
@@ -1,5 +1,4 @@
1
1
  import { exist } from '../loadPatientTestData/helpers';
2
- import type { OBSERVATION_INTERPRETATION } from '@openmrs/esm-patient-common-lib';
3
2
 
4
3
  export interface ReferenceRanges {
5
4
  hiAbsolute?: number;
@@ -82,6 +81,56 @@ export function rangeAlreadyHasUnits(range: string | undefined, units: string |
82
81
  return trimmedRange.endsWith(trimmedUnits) || trimmedRange.endsWith(` ${trimmedUnits}`);
83
82
  }
84
83
 
84
+ /**
85
+ * Checks if a range string already contains any units (common unit patterns).
86
+ * This helps detect if a range already has units even if they differ from the parameter.
87
+ * @param range The formatted range string (e.g., "0 – 50 mg/dL")
88
+ * @returns true if the range appears to already contain units, false otherwise
89
+ */
90
+ function rangeHasAnyUnits(range: string): boolean {
91
+ if (!range) {
92
+ return false;
93
+ }
94
+
95
+ const trimmedRange = range.trim();
96
+ // Common unit patterns: ends with common unit abbreviations or contains unit-like patterns
97
+ // This is a heuristic to detect if units are already present
98
+ const unitPattern = /\s+[a-zA-Z\/%°]+$/;
99
+ return unitPattern.test(trimmedRange);
100
+ }
101
+
102
+ /**
103
+ * Formats a reference range with units for display, avoiding duplicate units.
104
+ * @param range The formatted range string (may or may not include units)
105
+ * @param units The units string to append if not already present
106
+ * @returns Formatted string with range and units (e.g., "0 – 50 U/L")
107
+ */
108
+ export function formatRangeWithUnits(range: string | undefined, units: string | undefined): string {
109
+ const trimmedRange = range?.trim() || '';
110
+ const trimmedUnits = units?.trim() || '';
111
+
112
+ // If range is empty, return '--' (even if units exist, we need a range to display)
113
+ if (!trimmedRange) {
114
+ return '--';
115
+ }
116
+
117
+ // Check if range already includes the specific units parameter
118
+ const hasSpecificUnits = rangeAlreadyHasUnits(trimmedRange, trimmedUnits);
119
+ if (hasSpecificUnits) {
120
+ return trimmedRange;
121
+ }
122
+
123
+ // Check if range already has any units (even if different from parameter)
124
+ // This prevents appending units when range already has different units (e.g., "0 – 50 mg/dL" with "U/L" parameter)
125
+ const hasAnyUnits = rangeHasAnyUnits(trimmedRange);
126
+ if (hasAnyUnits) {
127
+ return trimmedRange;
128
+ }
129
+
130
+ // Append units if not already present
131
+ return trimmedUnits ? `${trimmedRange} ${trimmedUnits}` : trimmedRange;
132
+ }
133
+
85
134
  /**
86
135
  * Finds the most recent observation that has reference range data.
87
136
  */
@@ -9,8 +9,8 @@ import type {
9
9
  NewRowStartCellProps,
10
10
  TimelineDataGroupProps,
11
11
  } from './grouped-timeline-types';
12
+ import { getMostRecentObservationWithRange, formatRangeWithUnits } from './reference-range-helpers';
12
13
  import FilterContext from '../filter/filter-context';
13
- import { getMostRecentObservationWithRange } from './reference-range-helpers';
14
14
  import styles from './grouped-timeline.scss';
15
15
 
16
16
  export const ShadowBox: React.FC = () => <div className={styles['shadow-box']} />;
@@ -131,6 +131,8 @@ const NewRowStartCell: React.FC<NewRowStartCellProps> = ({
131
131
  });
132
132
  }, [patientUuid, conceptUuid, title]);
133
133
 
134
+ const rangeUnitsDisplay = formatRangeWithUnits(range, units);
135
+
134
136
  return (
135
137
  <div
136
138
  className={styles.rowStartCell}
@@ -147,9 +149,7 @@ const NewRowStartCell: React.FC<NewRowStartCellProps> = ({
147
149
  <span className={styles.trendlineLink}>{title}</span>
148
150
  )}
149
151
  </span>
150
- <span className={styles.rangeUnits}>
151
- {range} {units}
152
- </span>
152
+ <span className={styles.rangeUnits}>{rangeUnitsDisplay}</span>
153
153
  </div>
154
154
  );
155
155
  };
@@ -1,7 +1,7 @@
1
1
  import React, { useCallback, useMemo } from 'react';
2
2
  import classNames from 'classnames';
3
3
  import { useTranslation } from 'react-i18next';
4
- import { rangeAlreadyHasUnits } from '../grouped-timeline/reference-range-helpers';
4
+ import { formatRangeWithUnits } from '../grouped-timeline/reference-range-helpers';
5
5
  import {
6
6
  DataTable,
7
7
  DataTableSkeleton,
@@ -98,12 +98,7 @@ const IndividualResultsTable: React.FC<IndividualResultsTableProps> = ({
98
98
  const displayUnits = row.units ?? '';
99
99
  const isString = isNaN(parseFloat(row.value));
100
100
 
101
- // Check if range already includes units to avoid duplication
102
- // formatReferenceRange includes units, so if range has units, don't append again
103
- const hasUnits = rangeAlreadyHasUnits(displayRange, displayUnits);
104
- const referenceRangeDisplay = hasUnits
105
- ? displayRange
106
- : `${displayRange || '--'} ${displayUnits || ''}`.trim() || '--';
101
+ const referenceRangeDisplay = formatRangeWithUnits(displayRange, displayUnits);
107
102
 
108
103
  return {
109
104
  ...row,
@@ -1,7 +1,7 @@
1
1
  import React, { useMemo } from 'react';
2
2
  import classNames from 'classnames';
3
3
  import { useTranslation } from 'react-i18next';
4
- import { rangeAlreadyHasUnits } from '../grouped-timeline/reference-range-helpers';
4
+ import { formatRangeWithUnits } from '../grouped-timeline/reference-range-helpers';
5
5
  import {
6
6
  DataTable,
7
7
  TableContainer,
@@ -71,10 +71,7 @@ const LabSetPanel: React.FC<LabSetPanelProps> = ({ panel, activePanel, setActive
71
71
  hasRange
72
72
  ? panel.entries.map((test) => {
73
73
  const units = test.units ?? '';
74
- // Check if range already includes units to avoid duplication
75
- // formatReferenceRange includes units, so if range has units, don't append again
76
- const hasUnits = rangeAlreadyHasUnits(test.range, units);
77
- const range = hasUnits ? test.range : test.range ? `${test.range} ${units}` : '--';
74
+ const range = formatRangeWithUnits(test.range, units);
78
75
  return {
79
76
  id: test.conceptUuid,
80
77
  testName: test.display,