@openmrs/esm-app-shell 9.0.3-pre.4470 → 9.0.3-pre.4482

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1 @@
1
+ (self.webpackChunk_openmrs_esm_app_shell=self.webpackChunk_openmrs_esm_app_shell||[]).push([["4937"],{648(e,t){var r,n;r=this,n=function(){return function(e,t,r){t.prototype.isToday=function(){var e="YYYY-MM-DD",t=r();return this.format(e)===t.format(e)}}},"object"==(t&&"u">typeof Symbol&&t.constructor===Symbol?"symbol":typeof t)?e.exports=n():"function"==typeof define&&define.amd?define(n):(r="u">typeof globalThis?globalThis:r||self).dayjs_plugin_isToday=n()},6871(e,t){var r,n;function o(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}r=this,n=function(){return function(e,t,r){var n=t.prototype,i=function(e){var t=e.date,i=e.utc,a={};if(!(null===t||o(t,Date)||o(t,Array)||n.$utils().u(t)||"Object"!==t.constructor.name)){if(!Object.keys(t).length)return new Date;var u=i?r.utc():r();Object.keys(t).forEach(function(e){var r;a["date"===(r=n.$utils().p(e))?"day":r]=t[e]});var s=a.day||(a.year||a.month>=0?1:u.date()),l=a.year||u.year(),c=a.month>=0?a.month:a.year||a.day?0:u.month(),d=a.hour||0,f=a.minute||0,p=a.second||0,h=a.millisecond||0;return i?new Date(Date.UTC(l,c,s,d,f,p,h)):new Date(l,c,s,d,f,p,h)}return t},a=n.parse;n.parse=function(e){e.date=i.bind(this)(e),a.bind(this)(e)};var u=n.set,s=n.add,l=n.subtract,c=function(e,t,r,n){void 0===n&&(n=1);var o=Object.keys(t),i=this;return o.forEach(function(r){i=e.bind(i)(t[r]*n,r)}),i};n.set=function(e,t){return t=void 0===t?e:t,"Object"===e.constructor.name?c.bind(this)(function(e,t){return u.bind(this)(t,e)},t,e):u.bind(this)(e,t)},n.add=function(e,t){return"Object"===e.constructor.name?c.bind(this)(s,e,t):s.bind(this)(e,t)},n.subtract=function(e,t){return"Object"===e.constructor.name?c.bind(this)(s,e,t,-1):l.bind(this)(e,t)}}},"object"==(t&&"u">typeof Symbol&&t.constructor===Symbol?"symbol":typeof t)?e.exports=n():"function"==typeof define&&define.amd?define(n):(r="u">typeof globalThis?globalThis:r||self).dayjs_plugin_objectSupport=n()},2147(e,t){var r,n;r=this,n=function(){"use strict";var e="minute",t=/[+-]\d\d(?::?\d\d)?/g,r=/([+-]|\d\d)/g;return function(n,o,i){var a=o.prototype;i.utc=function(e){var t={date:e,utc:!0,args:arguments};return new o(t)},a.utc=function(t){var r=i(this.toDate(),{locale:this.$L,utc:!0});return t?r.add(this.utcOffset(),e):r},a.local=function(){return i(this.toDate(),{locale:this.$L,utc:!1})};var u=a.parse;a.parse=function(e){e.utc&&(this.$u=!0),this.$utils().u(e.$offset)||(this.$offset=e.$offset),u.call(this,e)};var s=a.init;a.init=function(){if(this.$u){var e=this.$d;this.$y=e.getUTCFullYear(),this.$M=e.getUTCMonth(),this.$D=e.getUTCDate(),this.$W=e.getUTCDay(),this.$H=e.getUTCHours(),this.$m=e.getUTCMinutes(),this.$s=e.getUTCSeconds(),this.$ms=e.getUTCMilliseconds()}else s.call(this)};var l=a.utcOffset;a.utcOffset=function(n,o){var i=this.$utils().u;if(i(n))return this.$u?0:i(this.$offset)?l.call(this):this.$offset;if("string"==typeof n&&null===(n=function(e){void 0===e&&(e="");var n=e.match(t);if(!n)return null;var o=(""+n[0]).match(r)||["-",0,0],i=o[0],a=60*o[1]+ +o[2];return 0===a?0:"+"===i?a:-a}(n)))return this;var a=16>=Math.abs(n)?60*n:n,u=this;if(o)return u.$offset=a,u.$u=0===n,u;if(0!==n){var s=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(u=this.local().add(a+s,e)).$offset=a,u.$x.$localOffset=s}else u=this.utc();return u};var c=a.format;a.format=function(e){var t=e||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return c.call(this,t)},a.valueOf=function(){var e=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*e},a.isUTC=function(){return!!this.$u},a.toISOString=function(){return this.toDate().toISOString()},a.toString=function(){return this.toDate().toUTCString()};var d=a.toDate;a.toDate=function(e){return"s"===e&&this.$offset?i(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():d.call(this)};var f=a.diff;a.diff=function(e,t,r){if(e&&this.$u===e.$u)return f.call(this,e,t,r);var n=this.local(),o=i(e).local();return f.call(n,o,t,r)}}},"object"==(t&&"u">typeof Symbol&&t.constructor===Symbol?"symbol":typeof t)?e.exports=n():"function"==typeof define&&define.amd?define(n):(r="u">typeof globalThis?globalThis:r||self).dayjs_plugin_utc=n()},904(e){var t=Object.prototype.hasOwnProperty,r=Object.prototype.toString;function n(e){if(!e||"[object Object]"!==r.call(e)||e.nodeType||e.setInterval)return!1;var n,o=t.call(e,"constructor"),i=t.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!o&&!i)return!1;for(n in e);return void 0===n||t.call(e,n)}e.exports=function e(){var t,r,o,i,a,u,s,l=arguments[0]||{},c=1,d=arguments.length,f=!1;for("boolean"==typeof l&&(f=l,l=arguments[1]||{},c=2),(void 0===l?"undefined":(t=l)&&"u">typeof Symbol&&t.constructor===Symbol?"symbol":typeof t)!="object"&&"function"!=typeof l&&(l={});c<d;c++)if(null!=(r=arguments[c]))for(o in r)i=l[o],l!==(a=r[o])&&(f&&a&&(n(a)||(u=Array.isArray(a)))?(u?(u=!1,s=i&&Array.isArray(i)?i:[]):s=i&&n(i)?i:{},l[o]=e(f,s,a)):void 0!==a&&(l[o]=a));return l}},6768(e,t,r){!function(t){"use strict";var n=r(9375);function o(e){return function(t,r){var n;return(void 0===t?"undefined":(n=t)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)=="object"&&(r=t,t=null),null==t&&(t=new Date().toString()),r||(r={}),e.call(this,t,r)}}var i=e.exports={generate:o(function(e,t){return new n(e,t)})};t&&(t.fn.geopattern=o(function(e,r){return this.each(function(){var n=t(this).attr("data-title-sha");n&&(r=t.extend({hash:n},r));var o=i.generate(e,r);t(this).css("background-image",o.toDataUrl())})}))}("u">typeof jQuery?jQuery:null)},8505(e){"use strict";e.exports={hex2rgb:function(e){e=e.replace(/^#?([a-f\d])([a-f\d])([a-f\d])$/i,function(e,t,r,n){return t+t+r+r+n+n});var t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?{r:parseInt(t[1],16),g:parseInt(t[2],16),b:parseInt(t[3],16)}:null},rgb2hex:function(e){return"#"+["r","g","b"].map(function(t){return("0"+e[t].toString(16)).slice(-2)}).join("")},rgb2hsl:function(e){var t,r,n=e.r,o=e.g,i=e.b,a=Math.max(n/=255,o/=255,i/=255),u=Math.min(n,o,i),s=(a+u)/2;if(a===u)t=r=0;else{var l=a-u;switch(r=s>.5?l/(2-a-u):l/(a+u),a){case n:t=(o-i)/l+6*(o<i);break;case o:t=(i-n)/l+2;break;case i:t=(n-o)/l+4}t/=6}return{h:t,s:r,l:s}},hsl2rgb:function(e){function t(e,t,r){return(r<0&&(r+=1),r>1&&(r-=1),r<1/6)?e+(t-e)*6*r:r<.5?t:r<2/3?e+(t-e)*(2/3-r)*6:e}var r,n,o,i=e.h,a=e.s,u=e.l;if(0===a)r=n=o=u;else{var s=u<.5?u*(1+a):u+a-u*a,l=2*u-s;r=t(l,s,i+1/3),n=t(l,s,i),o=t(l,s,i-1/3)}return{r:Math.round(255*r),g:Math.round(255*n),b:Math.round(255*o)}},rgb2rgbString:function(e){return"rgb("+[e.r,e.g,e.b].join(",")+")"}}},9375(e,t,r){"use strict";var n=r(904),o=r(8505),i=r(2088),a=r(959),u={baseColor:"#933c3c"},s=["octogons","overlappingCircles","plusSigns","xes","sineWaves","hexagons","overlappingRings","plaid","triangles","squares","concentricCircles","diamonds","tessellation","nestedSquares","mosaicSquares","chevrons"],l="#000";function c(e,t,r){return parseInt(e.substr(t,r||1),16)}function d(e,t,r,n,o){return(parseFloat(e)-t)*(o-n)/(r-t)+n}function f(e){return e%2==0?"#ddd":"#222"}function p(e){return d(e,0,15,.02,.15)}var h=e.exports=function(e,t){return this.opts=n({},u,t),this.hash=t.hash||i(e),this.svg=new a,this.generateBackground(),this.generatePattern(),this};function m(e){return[[e,0,e,3*e],[0,e,3*e,e]]}function y(e){return[0,0,e,e,0,e,0,0].join(",")}function b(e,t,r,n,o){var i=y(n),a=p(o[0]),u=f(o[0]),s={stroke:l,"stroke-opacity":.02,"fill-opacity":a,fill:u};e.polyline(i,s).transform({translate:[t+n,r],scale:[-1,1]}),e.polyline(i,s).transform({translate:[t+n,r+2*n],scale:[1,-1]}),s={stroke:l,"stroke-opacity":.02,"fill-opacity":a=p(o[1]),fill:u=f(o[1])},e.polyline(i,s).transform({translate:[t+n,r+2*n],scale:[-1,-1]}),e.polyline(i,s).transform({translate:[t+n,r],scale:[1,1]})}function v(e,t,r,n,o){var i=p(o),a=f(o),u=y(n),s={stroke:l,"stroke-opacity":.02,"fill-opacity":i,fill:a};e.polyline(u,s).transform({translate:[t,r+n],scale:[1,-1]}),e.polyline(u,s).transform({translate:[t+2*n,r+n],scale:[-1,-1]}),e.polyline(u,s).transform({translate:[t,r+n],scale:[1,1]}),e.polyline(u,s).transform({translate:[t+2*n,r+n],scale:[-1,1]})}h.prototype.toSvg=function(){return this.svg.toString()},h.prototype.toString=function(){return this.toSvg()},h.prototype.toBase64=function(){var e=this.toSvg();return"u">typeof window&&"function"==typeof window.btoa?window.btoa(e):new Buffer(e).toString("base64")},h.prototype.toDataUri=function(){return"data:image/svg+xml;base64,"+this.toBase64()},h.prototype.toDataUrl=function(){return'url("'+this.toDataUri()+'")'},h.prototype.generateBackground=function(){var e,t,r,n;this.opts.color?r=o.hex2rgb(this.opts.color):(t=d(c(this.hash,14,3),0,4095,0,359),n=c(this.hash,17),(e=o.rgb2hsl(o.hex2rgb(this.opts.baseColor))).h=(360*e.h-t+360)%360/360,n%2==0?e.s=Math.min(1,(100*e.s+n)/100):e.s=Math.max(0,(100*e.s-n)/100),r=o.hsl2rgb(e)),this.color=o.rgb2hex(r),this.svg.rect(0,0,"100%","100%",{fill:o.rgb2rgbString(r)})},h.prototype.generatePattern=function(){var e=this.opts.generator;if(e){if(0>s.indexOf(e))throw Error("The generator "+e+" does not exist.")}else e=s[c(this.hash,20)];return this["geo"+e.slice(0,1).toUpperCase()+e.slice(1)]()},h.prototype.geoHexagons=function(){var e,t,r,n,o,i,a,u,s,h=d(c(this.hash,0),0,15,8,60),m=h*Math.sqrt(3),y=2*h,b=(u=h/2,[0,s=Math.sin(60*Math.PI/180)*h,u,0,u+h,0,2*h,s,u+h,2*s,u,2*s,0,s].join(","));for(this.svg.setWidth(3*y+3*h),this.svg.setHeight(6*m),t=0,a=0;a<6;a++)for(i=0;i<6;i++)o=c(this.hash,t),e=i%2==0?a*m:a*m+m/2,r=p(o),n={fill:f(o),"fill-opacity":r,stroke:l,"stroke-opacity":.02},this.svg.polyline(b,n).transform({translate:[i*h*1.5-y/2,e-m/2]}),0===i&&this.svg.polyline(b,n).transform({translate:[6*h*1.5-y/2,e-m/2]}),0===a&&(e=i%2==0?6*m:6*m+m/2,this.svg.polyline(b,n).transform({translate:[i*h*1.5-y/2,e-m/2]})),0===i&&0===a&&this.svg.polyline(b,n).transform({translate:[6*h*1.5-y/2,5*m+m/2]}),t++},h.prototype.geoSineWaves=function(){var e,t,r,n,o,i,a,u=Math.floor(d(c(this.hash,0),0,15,100,400)),s=Math.floor(d(c(this.hash,1),0,15,30,100)),l=Math.floor(d(c(this.hash,2),0,15,3,30));for(this.svg.setWidth(u),this.svg.setHeight(36*l),t=0;t<36;t++)r=p(i=c(this.hash,t)),e=f(i),a=u/4*.7,o={fill:"none",stroke:e,opacity:r,"stroke-width":""+l+"px"},n="M0 "+s+" C "+a+" 0, "+(u/2-a)+" 0, "+u/2+" "+s+" S "+(u-a)+" "+2*s+", "+u+" "+s+" S "+(1.5*u-a)+" 0, "+1.5*u+", "+s,this.svg.path(n,o).transform({translate:[-u/4,l*t-1.5*s]}),this.svg.path(n,o).transform({translate:[-u/4,l*t-1.5*s+36*l]})},h.prototype.geoChevrons=function(){var e,t,r,n,o,i,a,u=d(c(this.hash,0),0,15,30,80),s=d(c(this.hash,0),0,15,30,80),h=(e=.66*s,[[0,0,u/2,s-e,u/2,s,0,e,0,0],[u/2,s-e,u,0,u,e,u/2,s,u/2,s-e]].map(function(e){return e.join(",")}));for(this.svg.setWidth(6*u),this.svg.setHeight(6*s*.66),t=0,a=0;a<6;a++)for(i=0;i<6;i++)r=p(o=c(this.hash,t)),n={stroke:l,"stroke-opacity":.02,fill:f(o),"fill-opacity":r,"stroke-width":1},this.svg.group(n).transform({translate:[i*u,a*s*.66-s/2]}).polyline(h).end(),0===a&&this.svg.group(n).transform({translate:[i*u,6*s*.66-s/2]}).polyline(h).end(),t+=1},h.prototype.geoPlusSigns=function(){var e,t,r,n,o,i,a,u,s=d(c(this.hash,0),0,15,10,25),h=3*s,y=m(s);for(this.svg.setWidth(12*s),this.svg.setHeight(12*s),r=0,u=0;u<6;u++)for(a=0;a<6;a++)n=p(i=c(this.hash,r)),t=f(i),e=+(u%2!=0),o={fill:t,stroke:l,"stroke-opacity":.02,"fill-opacity":n},this.svg.group(o).transform({translate:[a*h-a*s+e*s-s,u*h-u*s-h/2]}).rect(y).end(),0===a&&this.svg.group(o).transform({translate:[4*h-a*s+e*s-s,u*h-u*s-h/2]}).rect(y).end(),0===u&&this.svg.group(o).transform({translate:[a*h-a*s+e*s-s,4*h-u*s-h/2]}).rect(y).end(),0===a&&0===u&&this.svg.group(o).transform({translate:[4*h-a*s+e*s-s,4*h-u*s-h/2]}).rect(y).end(),r++},h.prototype.geoXes=function(){var e,t,r,n,o,i,a,u=d(c(this.hash,0),0,15,10,25),s=m(u),l=3*u*.943;for(this.svg.setWidth(3*l),this.svg.setHeight(3*l),t=0,a=0;a<6;a++)for(i=0;i<6;i++)r=p(o=c(this.hash,t)),e=i%2==0?a*l-.5*l:a*l-.5*l+l/4,n={fill:f(o),opacity:r},this.svg.group(n).transform({translate:[i*l/2-l/2,e-a*l/2],rotate:[45,l/2,l/2]}).rect(s).end(),0===i&&this.svg.group(n).transform({translate:[6*l/2-l/2,e-a*l/2],rotate:[45,l/2,l/2]}).rect(s).end(),0===a&&(e=i%2==0?6*l-l/2:6*l-l/2+l/4,this.svg.group(n).transform({translate:[i*l/2-l/2,e-6*l/2],rotate:[45,l/2,l/2]}).rect(s).end()),5===a&&this.svg.group(n).transform({translate:[i*l/2-l/2,e-11*l/2],rotate:[45,l/2,l/2]}).rect(s).end(),0===i&&0===a&&this.svg.group(n).transform({translate:[6*l/2-l/2,e-6*l/2],rotate:[45,l/2,l/2]}).rect(s).end(),t++},h.prototype.geoOverlappingCircles=function(){var e,t,r,n,o,i,a=d(c(this.hash,0),0,15,25,200)/2;for(this.svg.setWidth(6*a),this.svg.setHeight(6*a),e=0,i=0;i<6;i++)for(o=0;o<6;o++)t=p(n=c(this.hash,e)),r={fill:f(n),opacity:t},this.svg.circle(o*a,i*a,a,r),0===o&&this.svg.circle(6*a,i*a,a,r),0===i&&this.svg.circle(o*a,6*a,a,r),0===o&&0===i&&this.svg.circle(6*a,6*a,a,r),e++},h.prototype.geoOctogons=function(){var e,t,r,n,o,i,a,u=d(c(this.hash,0),0,15,10,60),s=[e=.33*u,0,u-e,0,u,e,u,u-e,u-e,u,e,u,0,u-e,0,e,e,0].join(",");for(this.svg.setWidth(6*u),this.svg.setHeight(6*u),r=0,a=0;a<6;a++)for(i=0;i<6;i++)n=p(o=c(this.hash,r)),t=f(o),this.svg.polyline(s,{fill:t,"fill-opacity":n,stroke:l,"stroke-opacity":.02}).transform({translate:[i*u,a*u]}),r+=1},h.prototype.geoSquares=function(){var e,t,r,n,o,i,a=d(c(this.hash,0),0,15,10,60);for(this.svg.setWidth(6*a),this.svg.setHeight(6*a),t=0,i=0;i<6;i++)for(o=0;o<6;o++)r=p(n=c(this.hash,t)),e=f(n),this.svg.rect(o*a,i*a,a,a,{fill:e,"fill-opacity":r,stroke:l,"stroke-opacity":.02}),t+=1},h.prototype.geoConcentricCircles=function(){var e,t,r,n,o,i,a=d(c(this.hash,0),0,15,10,60),u=a/5;for(this.svg.setWidth((a+u)*6),this.svg.setHeight((a+u)*6),t=0,i=0;i<6;i++)for(o=0;o<6;o++)r=p(n=c(this.hash,t)),e=f(n),this.svg.circle(o*a+o*u+(a+u)/2,i*a+i*u+(a+u)/2,a/2,{fill:"none",stroke:e,opacity:r,"stroke-width":u+"px"}),r=p(n=c(this.hash,39-t)),e=f(n),this.svg.circle(o*a+o*u+(a+u)/2,i*a+i*u+(a+u)/2,a/4,{fill:e,"fill-opacity":r}),t+=1},h.prototype.geoOverlappingRings=function(){var e,t,r,n,o,i,a=d(c(this.hash,0),0,15,10,60),u=a/4;for(this.svg.setWidth(6*a),this.svg.setHeight(6*a),e=0,i=0;i<6;i++)for(o=0;o<6;o++)t=p(n=c(this.hash,e)),r={fill:"none",stroke:f(n),opacity:t,"stroke-width":u+"px"},this.svg.circle(o*a,i*a,a-u/2,r),0===o&&this.svg.circle(6*a,i*a,a-u/2,r),0===i&&this.svg.circle(o*a,6*a,a-u/2,r),0===o&&0===i&&this.svg.circle(6*a,6*a,a-u/2,r),e+=1},h.prototype.geoTriangles=function(){var e,t,r,n,o,i,a,u,s=d(c(this.hash,0),0,15,15,80),h=s/2*Math.sqrt(3),m=[u=s/2,0,s,h,0,h,u,0].join(",");for(this.svg.setWidth(3*s),this.svg.setHeight(6*h),e=0,a=0;a<6;a++)for(i=0;i<6;i++)t=p(o=c(this.hash,e)),n={fill:f(o),"fill-opacity":t,stroke:l,"stroke-opacity":.02},r=a%2==0?180*(i%2==0):180*(i%2!=0),this.svg.polyline(m,n).transform({translate:[i*s*.5-s/2,h*a],rotate:[r,s/2,h/2]}),0===i&&this.svg.polyline(m,n).transform({translate:[6*s*.5-s/2,h*a],rotate:[r,s/2,h/2]}),e+=1},h.prototype.geoDiamonds=function(){var e,t,r,n,o,i,a,u=d(c(this.hash,0),0,15,10,50),s=d(c(this.hash,1),0,15,10,50),h=[u/2,0,u,s/2,u/2,s,0,s/2].join(",");for(this.svg.setWidth(6*u),this.svg.setHeight(3*s),t=0,a=0;a<6;a++)for(i=0;i<6;i++)r=p(o=c(this.hash,t)),n={fill:f(o),"fill-opacity":r,stroke:l,"stroke-opacity":.02},e=a%2==0?0:u/2,this.svg.polyline(h,n).transform({translate:[i*u-u/2+e,s/2*a-s/2]}),0===i&&this.svg.polyline(h,n).transform({translate:[6*u-u/2+e,s/2*a-s/2]}),0===a&&this.svg.polyline(h,n).transform({translate:[i*u-u/2+e,s/2*6-s/2]}),0===i&&0===a&&this.svg.polyline(h,n).transform({translate:[6*u-u/2+e,s/2*6-s/2]}),t+=1},h.prototype.geoNestedSquares=function(){var e,t,r,n,o,i,a=d(c(this.hash,0),0,15,4,12),u=7*a;for(this.svg.setWidth((u+a)*6+6*a),this.svg.setHeight((u+a)*6+6*a),e=0,i=0;i<6;i++)for(o=0;o<6;o++)t=p(n=c(this.hash,e)),r={fill:"none",stroke:f(n),opacity:t,"stroke-width":a+"px"},this.svg.rect(o*u+o*a*2+a/2,i*u+i*a*2+a/2,u,u,r),t=p(n=c(this.hash,39-e)),r={fill:"none",stroke:f(n),opacity:t,"stroke-width":a+"px"},this.svg.rect(o*u+o*a*2+a/2+2*a,i*u+i*a*2+a/2+2*a,3*a,3*a,r),e+=1},h.prototype.geoMosaicSquares=function(){var e,t,r,n=d(c(this.hash,0),0,15,15,50);for(this.svg.setWidth(8*n),this.svg.setHeight(8*n),e=0,r=0;r<4;r++)for(t=0;t<4;t++)t%2==0?r%2==0?v(this.svg,t*n*2,r*n*2,n,c(this.hash,e)):b(this.svg,t*n*2,r*n*2,n,[c(this.hash,e),c(this.hash,e+1)]):r%2==0?b(this.svg,t*n*2,r*n*2,n,[c(this.hash,e),c(this.hash,e+1)]):v(this.svg,t*n*2,r*n*2,n,c(this.hash,e)),e+=1},h.prototype.geoPlaid=function(){var e,t,r,n,o,i,a=0,u=0;for(t=0;t<36;)a+=c(this.hash,t)+5,r=p(i=c(this.hash,t+1)),e=f(i),n=i+5,this.svg.rect(0,a,"100%",n,{opacity:r,fill:e}),a+=n,t+=2;for(t=0;t<36;)u+=c(this.hash,t)+5,r=p(i=c(this.hash,t+1)),e=f(i),o=i+5,this.svg.rect(u,0,o,"100%",{opacity:r,fill:e}),u+=o,t+=2;this.svg.setWidth(u),this.svg.setHeight(a)},h.prototype.geoTessellation=function(){var e,t,r,n,o=d(c(this.hash,0),0,15,5,40),i=o*Math.sqrt(3),a=2*o,u=o/2*Math.sqrt(3),s=[0,0,u,o/2,0,o,0,0].join(","),h=3*o+2*u,m=2*i+2*o;for(this.svg.setWidth(h),this.svg.setHeight(m),e=0;e<20;e++)switch(t=p(n=c(this.hash,e)),r={stroke:l,"stroke-opacity":.02,fill:f(n),"fill-opacity":t,"stroke-width":1},e){case 0:this.svg.rect(-o/2,-o/2,o,o,r),this.svg.rect(h-o/2,-o/2,o,o,r),this.svg.rect(-o/2,m-o/2,o,o,r),this.svg.rect(h-o/2,m-o/2,o,o,r);break;case 1:this.svg.rect(a/2+u,i/2,o,o,r);break;case 2:this.svg.rect(-o/2,m/2-o/2,o,o,r),this.svg.rect(h-o/2,m/2-o/2,o,o,r);break;case 3:this.svg.rect(a/2+u,1.5*i+o,o,o,r);break;case 4:this.svg.polyline(s,r).transform({translate:[o/2,-o/2],rotate:[0,o/2,u/2]}),this.svg.polyline(s,r).transform({translate:[o/2,m- -o/2],rotate:[0,o/2,u/2],scale:[1,-1]});break;case 5:this.svg.polyline(s,r).transform({translate:[h-o/2,-o/2],rotate:[0,o/2,u/2],scale:[-1,1]}),this.svg.polyline(s,r).transform({translate:[h-o/2,m+o/2],rotate:[0,o/2,u/2],scale:[-1,-1]});break;case 6:this.svg.polyline(s,r).transform({translate:[h/2+o/2,i/2]});break;case 7:this.svg.polyline(s,r).transform({translate:[h-h/2-o/2,i/2],scale:[-1,1]});break;case 8:this.svg.polyline(s,r).transform({translate:[h/2+o/2,m-i/2],scale:[1,-1]});break;case 9:this.svg.polyline(s,r).transform({translate:[h-h/2-o/2,m-i/2],scale:[-1,-1]});break;case 10:this.svg.polyline(s,r).transform({translate:[o/2,m/2-o/2]});break;case 11:this.svg.polyline(s,r).transform({translate:[h-o/2,m/2-o/2],scale:[-1,1]});break;case 12:this.svg.rect(0,0,o,o,r).transform({translate:[o/2,o/2],rotate:[-30,0,0]});break;case 13:this.svg.rect(0,0,o,o,r).transform({scale:[-1,1],translate:[-h+o/2,o/2],rotate:[-30,0,0]});break;case 14:this.svg.rect(0,0,o,o,r).transform({translate:[o/2,m/2-o/2-o],rotate:[30,0,o]});break;case 15:this.svg.rect(0,0,o,o,r).transform({scale:[-1,1],translate:[-h+o/2,m/2-o/2-o],rotate:[30,0,o]});break;case 16:this.svg.rect(0,0,o,o,r).transform({scale:[1,-1],translate:[o/2,-m+m/2-o/2-o],rotate:[30,0,o]});break;case 17:this.svg.rect(0,0,o,o,r).transform({scale:[-1,-1],translate:[-h+o/2,-m+m/2-o/2-o],rotate:[30,0,o]});break;case 18:this.svg.rect(0,0,o,o,r).transform({scale:[1,-1],translate:[o/2,-m+o/2],rotate:[-30,0,0]});break;case 19:this.svg.rect(0,0,o,o,r).transform({scale:[-1,-1],translate:[-h+o/2,-m+o/2],rotate:[-30,0,0]})}}},2088(e){"use strict";function t(){var e=0x67452301,t=0xefcdab89,r=0x98badcfe,n=0x10325476,o=0xc3d2e1f0,i=new Uint32Array(80),a=0,u=24,s=0;function l(){for(var u,s,l=16;l<80;l++){var c=i[l-3]^i[l-8]^i[l-14]^i[l-16];i[l]=c<<1|c>>>31}var d=e,f=t,p=r,h=n,m=o;for(l=0;l<80;l++){l<20?(u=h^f&(p^h),s=0x5a827999):l<40?(u=f^p^h,s=0x6ed9eba1):l<60?(u=f&p|h&(f|p),s=0x8f1bbcdc):(u=f^p^h,s=0xca62c1d6);var y=(d<<5|d>>>27)+u+m+s+(0|i[l]);m=h,h=p,p=f<<30|f>>>2,f=d,d=y}for(l=0,e=e+d|0,t=t+f|0,r=r+p|0,n=n+h|0,o=o+m|0,a=0;l<16;l++)i[l]=0}function c(e){i[a]|=(255&e)<<u,u?u-=8:(a++,u=24),16===a&&l()}function d(e){for(var t="",r=28;r>=0;r-=4)t+=(e>>r&15).toString(16);return t}return{update:function(e){if("string"==typeof e){var t=e.length;s+=8*t;for(var r=0;r<t;r++)c(e.charCodeAt(r));return}var n=e.length;s+=8*n;for(var o=0;o<n;o++)c(e[o])},digest:function(){c(128),(a>14||14===a&&u<24)&&l(),a=14,u=24,c(0),c(0),c(s>0xffffffffff?s/0x10000000000:0),c(s>0xffffffff?s/0x100000000:0);for(var i=24;i>=0;i-=8)c(s>>i);return d(e)+d(t)+d(r)+d(n)+d(o)}}}e.exports=function(e){if(void 0===e)return t();var r=t();return r.update(e),r.digest()}},959(e,t,r){"use strict";var n=r(904),o=r(52);function i(){return this.width=100,this.height=100,this.svg=o("svg"),this.context=[],this.setAttributes(this.svg,{xmlns:"http://www.w3.org/2000/svg",width:this.width,height:this.height}),this}e.exports=i,i.prototype.currentContext=function(){return this.context[this.context.length-1]||this.svg},i.prototype.end=function(){return this.context.pop(),this},i.prototype.currentNode=function(){var e=this.currentContext();return e.lastChild||e},i.prototype.transform=function(e){return this.currentNode().setAttribute("transform",Object.keys(e).map(function(t){return t+"("+e[t].join(",")+")"}).join(" ")),this},i.prototype.setAttributes=function(e,t){Object.keys(t).forEach(function(r){e.setAttribute(r,t[r])})},i.prototype.setWidth=function(e){this.svg.setAttribute("width",Math.floor(e))},i.prototype.setHeight=function(e){this.svg.setAttribute("height",Math.floor(e))},i.prototype.toString=function(){return this.svg.toString()},i.prototype.rect=function(e,t,r,i,a){var u=this;if(Array.isArray(e))return e.forEach(function(e){u.rect.apply(u,e.concat(a))}),this;var s=o("rect");return this.currentContext().appendChild(s),this.setAttributes(s,n({x:e,y:t,width:r,height:i},a)),this},i.prototype.circle=function(e,t,r,i){var a=o("circle");return this.currentContext().appendChild(a),this.setAttributes(a,n({cx:e,cy:t,r:r},i)),this},i.prototype.path=function(e,t){var r=o("path");return this.currentContext().appendChild(r),this.setAttributes(r,n({d:e},t)),this},i.prototype.polyline=function(e,t){var r=this;if(Array.isArray(e))return e.forEach(function(e){r.polyline(e,t)}),this;var i=o("polyline");return this.currentContext().appendChild(i),this.setAttributes(i,n({points:e},t)),this},i.prototype.group=function(e){var t=o("g");return this.currentContext().appendChild(t),this.context.push(t),this.setAttributes(t,n({},e)),this}},52(e){"use strict";var t=e.exports=function(e){return(null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?t[Symbol.hasInstance](this):this instanceof t)?(this.tagName=e,this.attributes=Object.create(null),this.children=[],this.lastChild=null,this):new t(e)};t.prototype.appendChild=function(e){return this.children.push(e),this.lastChild=e,this},t.prototype.setAttribute=function(e,t){return this.attributes[e]=t,this},t.prototype.toString=function(){var e=this;return["<",e.tagName,Object.keys(e.attributes).map(function(t){return[" ",t,'="',e.attributes[t],'"'].join("")}).join(""),">",e.children.map(function(e){return e.toString()}).join(""),"</",e.tagName,">"].join("")}},2992(e,t){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function n(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}function o(e,t,r){return(o=f()?Reflect.construct:function(e,t,r){var n=[null];n.push.apply(n,t);var o=new(Function.bind.apply(e,n));return r&&u(o,r.prototype),o}).apply(null,arguments)}function i(e){return(i=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function a(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function s(e){return function(e){if(Array.isArray(e))return r(e)}(e)||a(e)||c(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function c(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return r(e,t)}}function d(e){var t="function"==typeof Map?new Map:void 0;return(d=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return o(e,arguments,i(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),u(r,e)})(e)}function f(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(f=function(){return!!e})()}function p(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}t.pathToRegexp=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.delimiter,n=void 0===r?"/":r,o=t.end,i=t.sensitive,a=t.trailing,u=[],c=[],d=!0,f=!1,E=void 0;try{for(var S,O=(function e(t,r){if(Array.isArray(t)){var n=!0,o=!1,i=void 0;try{for(var a,u=t[Symbol.iterator]();!(n=(a=u.next()).done);n=!0){var s=a.value;e(s,r)}}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}}else r.push(t);return r})(e,[])[Symbol.iterator]();!(d=(S=O.next()).done);d=!0){var A=S.value,x=(void 0===A?"undefined":l(A))==="object"?A:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.encodePath,n=void 0===r?h:r,o=s(e),i=[],a=0,u=0;function l(){var t="";if(m.test(o[a]))do t+=o[a++];while(y.test(o[a]));else if('"'===o[a]){for(var r=a;a++<o.length;){if('"'===o[a]){a++,r=0;break}"\\"===o[a]&&a++,t+=o[a]}if(r)throw new w("Unterminated quote at index ".concat(r),e)}if(!t)throw new w("Missing parameter name at index ".concat(a),e);return t}for(;a<o.length;){var c=o[a],d=b[c];d?i.push({type:d,index:a++,value:c}):"\\"===c?i.push({type:"escape",index:a++,value:o[a++]}):":"===c?i.push({type:"param",index:a++,value:l()}):"*"===c?i.push({type:"wildcard",index:a++,value:l()}):i.push({type:"char",index:a++,value:c})}return i.push({type:"end",index:a,value:""}),new g(function t(r){for(var o=[];;){var a=i[u++];if(a.type===r)break;if("char"===a.type||"escape"===a.type){for(var s=a.value,l=i[u];"char"===l.type||"escape"===l.type;)s+=l.value,l=i[++u];o.push({type:"text",value:n(s)});continue}if("param"===a.type||"wildcard"===a.type){o.push({type:a.type,name:a.value});continue}if("{"===a.type){o.push({type:"group",tokens:t("}")});continue}throw new w("Unexpected ".concat(a.type," at index ").concat(a.index,", expected ").concat(r),e)}return o}("end"),e)}(A,t),D=!0,j=!1,C=void 0;try{for(var P,k=(function e(t,r,n){var o,i,a,u,s,l,c;return function(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(d){switch(d.label){case 0:if(r!==t.length)return[3,2];return[4,n];case 1:return[2,d.sent()];case 2:if("group"!==(o=t[r]).type)return[3,11];i=!0,a=!1,u=void 0,d.label=3;case 3:d.trys.push([3,8,9,10]),s=e(o.tokens,0,n.slice())[Symbol.iterator](),d.label=4;case 4:if(i=(l=s.next()).done)return[3,7];return[5,p(e(t,r+1,l.value))];case 5:d.sent(),d.label=6;case 6:return i=!0,[3,4];case 7:return[3,10];case 8:return c=d.sent(),a=!0,u=c,[3,10];case 9:try{i||null==s.return||s.return()}finally{if(a)throw u}return[7];case 10:return[3,12];case 11:n.push(o),d.label=12;case 12:return[5,p(e(t,r+1,n))];case 13:return d.sent(),[2]}})})(x.tokens,0,[])[Symbol.iterator]();!(D=(P=k.next()).done);D=!0){var I=P.value;c.push(function(e,t,r,n){var o="",i="",a=!0,u=!0,s=!1,l=void 0;try{for(var c,d=e[Symbol.iterator]();!(u=(c=d.next()).done);u=!0){var f,p,h=c.value;if("text"===h.type){o+=v(h.value),i+=h.value,a||(a=h.value.includes(t));continue}if("param"===h.type||"wildcard"===h.type){if(!a&&!i)throw new w('Missing text before "'.concat(h.name,'" ').concat(h.type),n);"param"===h.type?o+="(".concat((f=t,(p=a?"":i).length<2?f.length<2?"[^".concat(v(f+p),"]"):"(?:(?!".concat(v(f),")[^").concat(v(p),"])"):f.length<2?"(?:(?!".concat(v(p),")[^").concat(v(f),"])"):"(?:(?!".concat(v(p),"|").concat(v(f),")[\\s\\S])")),"+)"):o+="([\\s\\S]+)",r.push(h),i="",a=!1;continue}}}catch(e){s=!0,l=e}finally{try{u||null==d.return||d.return()}finally{if(s)throw l}}return o}(I,n,u,x.originalPath))}}catch(e){j=!0,C=e}finally{try{D||null==k.return||k.return()}finally{if(j)throw C}}}}catch(e){f=!0,E=e}finally{try{d||null==O.return||O.return()}finally{if(f)throw E}}var T="^(?:".concat(c.join("|"),")");return(void 0===a||a)&&(T+="(?:".concat(v(n),"$)?")),{regexp:new RegExp(T+=void 0===o||o?"$":"(?=".concat(v(n),"|$)"),void 0!==i&&i?"":"i"),keys:u}};var h=function(e){return e},m=RegExp("^[$_\\u0041-\\u005A\\u0061-\\u007A\\u00AA\\u00B5\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376-\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0560-\\u0588\\u05D0-\\u05EA\\u05EF-\\u05F2\\u0620-\\u064A\\u066E-\\u066F\\u0671-\\u06D3\\u06D5\\u06E5-\\u06E6\\u06EE-\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4-\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u0860-\\u086A\\u0870-\\u0887\\u0889-\\u088F\\u08A0-\\u08C9\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098C\\u098F-\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC-\\u09DD\\u09DF-\\u09E1\\u09F0-\\u09F1\\u09FC\\u0A05-\\u0A0A\\u0A0F-\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32-\\u0A33\\u0A35-\\u0A36\\u0A38-\\u0A39\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8\\u0AAA-\\u0AB0\\u0AB2-\\u0AB3\\u0AB5-\\u0AB9\\u0ABD\\u0AD0\\u0AE0-\\u0AE1\\u0AF9\\u0B05-\\u0B0C\\u0B0F-\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32-\\u0B33\\u0B35-\\u0B39\\u0B3D\\u0B5C-\\u0B5D\\u0B5F-\\u0B61\\u0B71\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99-\\u0B9A\\u0B9C\\u0B9E-\\u0B9F\\u0BA3-\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BD0\\u0C05-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C39\\u0C3D\\u0C58-\\u0C5A\\u0C5C-\\u0C5D\\u0C60-\\u0C61\\u0C80\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3\\u0CB5-\\u0CB9\\u0CBD\\u0CDC-\\u0CDE\\u0CE0-\\u0CE1\\u0CF1-\\u0CF2\\u0D04-\\u0D0C\\u0D0E-\\u0D10\\u0D12-\\u0D3A\\u0D3D\\u0D4E\\u0D54-\\u0D56\\u0D5F-\\u0D61\\u0D7A-\\u0D7F\\u0D85-\\u0D96\\u0D9A-\\u0DB1\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0E01-\\u0E30\\u0E32-\\u0E33\\u0E40-\\u0E46\\u0E81-\\u0E82\\u0E84\\u0E86-\\u0E8A\\u0E8C-\\u0EA3\\u0EA5\\u0EA7-\\u0EB0\\u0EB2-\\u0EB3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6\\u0EDC-\\u0EDF\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8C\\u1000-\\u102A\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065-\\u1066\\u106E-\\u1070\\u1075-\\u1081\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F5\\u13F8-\\u13FD\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16EE-\\u16F8\\u1700-\\u1711\\u171F-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1878\\u1880-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19B0-\\u19C9\\u1A00-\\u1A16\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4C\\u1B83-\\u1BA0\\u1BAE-\\u1BAF\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1C80-\\u1C8A\\u1C90-\\u1CBA\\u1CBD-\\u1CBF\\u1CE9-\\u1CEC\\u1CEE-\\u1CF3\\u1CF5-\\u1CF6\\u1CFA\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2118-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2160-\\u2188\\u2C00-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2-\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303C\\u3041-\\u3096\\u309B-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312F\\u3131-\\u318E\\u31A0-\\u31BF\\u31F0-\\u31FF\\u3400-\\u4DBF\\u4E00-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A-\\uA62B\\uA640-\\uA66E\\uA67F-\\uA69D\\uA6A0-\\uA6EF\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA7DC\\uA7F1-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB\\uA8FD-\\uA8FE\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uA9E0-\\uA9E4\\uA9E6-\\uA9EF\\uA9FA-\\uA9FE\\uAA00-\\uAA28\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA7E-\\uAAAF\\uAAB1\\uAAB5-\\uAAB6\\uAAB9-\\uAABD\\uAAC0\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEA\\uAAF2-\\uAAF4\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E\\uAB30-\\uAB5A\\uAB5C-\\uAB69\\uAB70-\\uABE2\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36\\uFB38-\\uFB3C\\uFB3E\\uFB40-\\uFB41\\uFB43-\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC\\u{10000}-\\u{1000B}\\u{1000D}-\\u{10026}\\u{10028}-\\u{1003A}\\u{1003C}-\\u{1003D}\\u{1003F}-\\u{1004D}\\u{10050}-\\u{1005D}\\u{10080}-\\u{100FA}\\u{10140}-\\u{10174}\\u{10280}-\\u{1029C}\\u{102A0}-\\u{102D0}\\u{10300}-\\u{1031F}\\u{1032D}-\\u{1034A}\\u{10350}-\\u{10375}\\u{10380}-\\u{1039D}\\u{103A0}-\\u{103C3}\\u{103C8}-\\u{103CF}\\u{103D1}-\\u{103D5}\\u{10400}-\\u{1049D}\\u{104B0}-\\u{104D3}\\u{104D8}-\\u{104FB}\\u{10500}-\\u{10527}\\u{10530}-\\u{10563}\\u{10570}-\\u{1057A}\\u{1057C}-\\u{1058A}\\u{1058C}-\\u{10592}\\u{10594}-\\u{10595}\\u{10597}-\\u{105A1}\\u{105A3}-\\u{105B1}\\u{105B3}-\\u{105B9}\\u{105BB}-\\u{105BC}\\u{105C0}-\\u{105F3}\\u{10600}-\\u{10736}\\u{10740}-\\u{10755}\\u{10760}-\\u{10767}\\u{10780}-\\u{10785}\\u{10787}-\\u{107B0}\\u{107B2}-\\u{107BA}\\u{10800}-\\u{10805}\\u{10808}\\u{1080A}-\\u{10835}\\u{10837}-\\u{10838}\\u{1083C}\\u{1083F}-\\u{10855}\\u{10860}-\\u{10876}\\u{10880}-\\u{1089E}\\u{108E0}-\\u{108F2}\\u{108F4}-\\u{108F5}\\u{10900}-\\u{10915}\\u{10920}-\\u{10939}\\u{10940}-\\u{10959}\\u{10980}-\\u{109B7}\\u{109BE}-\\u{109BF}\\u{10A00}\\u{10A10}-\\u{10A13}\\u{10A15}-\\u{10A17}\\u{10A19}-\\u{10A35}\\u{10A60}-\\u{10A7C}\\u{10A80}-\\u{10A9C}\\u{10AC0}-\\u{10AC7}\\u{10AC9}-\\u{10AE4}\\u{10B00}-\\u{10B35}\\u{10B40}-\\u{10B55}\\u{10B60}-\\u{10B72}\\u{10B80}-\\u{10B91}\\u{10C00}-\\u{10C48}\\u{10C80}-\\u{10CB2}\\u{10CC0}-\\u{10CF2}\\u{10D00}-\\u{10D23}\\u{10D4A}-\\u{10D65}\\u{10D6F}-\\u{10D85}\\u{10E80}-\\u{10EA9}\\u{10EB0}-\\u{10EB1}\\u{10EC2}-\\u{10EC7}\\u{10F00}-\\u{10F1C}\\u{10F27}\\u{10F30}-\\u{10F45}\\u{10F70}-\\u{10F81}\\u{10FB0}-\\u{10FC4}\\u{10FE0}-\\u{10FF6}\\u{11003}-\\u{11037}\\u{11071}-\\u{11072}\\u{11075}\\u{11083}-\\u{110AF}\\u{110D0}-\\u{110E8}\\u{11103}-\\u{11126}\\u{11144}\\u{11147}\\u{11150}-\\u{11172}\\u{11176}\\u{11183}-\\u{111B2}\\u{111C1}-\\u{111C4}\\u{111DA}\\u{111DC}\\u{11200}-\\u{11211}\\u{11213}-\\u{1122B}\\u{1123F}-\\u{11240}\\u{11280}-\\u{11286}\\u{11288}\\u{1128A}-\\u{1128D}\\u{1128F}-\\u{1129D}\\u{1129F}-\\u{112A8}\\u{112B0}-\\u{112DE}\\u{11305}-\\u{1130C}\\u{1130F}-\\u{11310}\\u{11313}-\\u{11328}\\u{1132A}-\\u{11330}\\u{11332}-\\u{11333}\\u{11335}-\\u{11339}\\u{1133D}\\u{11350}\\u{1135D}-\\u{11361}\\u{11380}-\\u{11389}\\u{1138B}\\u{1138E}\\u{11390}-\\u{113B5}\\u{113B7}\\u{113D1}\\u{113D3}\\u{11400}-\\u{11434}\\u{11447}-\\u{1144A}\\u{1145F}-\\u{11461}\\u{11480}-\\u{114AF}\\u{114C4}-\\u{114C5}\\u{114C7}\\u{11580}-\\u{115AE}\\u{115D8}-\\u{115DB}\\u{11600}-\\u{1162F}\\u{11644}\\u{11680}-\\u{116AA}\\u{116B8}\\u{11700}-\\u{1171A}\\u{11740}-\\u{11746}\\u{11800}-\\u{1182B}\\u{118A0}-\\u{118DF}\\u{118FF}-\\u{11906}\\u{11909}\\u{1190C}-\\u{11913}\\u{11915}-\\u{11916}\\u{11918}-\\u{1192F}\\u{1193F}\\u{11941}\\u{119A0}-\\u{119A7}\\u{119AA}-\\u{119D0}\\u{119E1}\\u{119E3}\\u{11A00}\\u{11A0B}-\\u{11A32}\\u{11A3A}\\u{11A50}\\u{11A5C}-\\u{11A89}\\u{11A9D}\\u{11AB0}-\\u{11AF8}\\u{11BC0}-\\u{11BE0}\\u{11C00}-\\u{11C08}\\u{11C0A}-\\u{11C2E}\\u{11C40}\\u{11C72}-\\u{11C8F}\\u{11D00}-\\u{11D06}\\u{11D08}-\\u{11D09}\\u{11D0B}-\\u{11D30}\\u{11D46}\\u{11D60}-\\u{11D65}\\u{11D67}-\\u{11D68}\\u{11D6A}-\\u{11D89}\\u{11D98}\\u{11DB0}-\\u{11DDB}\\u{11EE0}-\\u{11EF2}\\u{11F02}\\u{11F04}-\\u{11F10}\\u{11F12}-\\u{11F33}\\u{11FB0}\\u{12000}-\\u{12399}\\u{12400}-\\u{1246E}\\u{12480}-\\u{12543}\\u{12F90}-\\u{12FF0}\\u{13000}-\\u{1342F}\\u{13441}-\\u{13446}\\u{13460}-\\u{143FA}\\u{14400}-\\u{14646}\\u{16100}-\\u{1611D}\\u{16800}-\\u{16A38}\\u{16A40}-\\u{16A5E}\\u{16A70}-\\u{16ABE}\\u{16AD0}-\\u{16AED}\\u{16B00}-\\u{16B2F}\\u{16B40}-\\u{16B43}\\u{16B63}-\\u{16B77}\\u{16B7D}-\\u{16B8F}\\u{16D40}-\\u{16D6C}\\u{16E40}-\\u{16E7F}\\u{16EA0}-\\u{16EB8}\\u{16EBB}-\\u{16ED3}\\u{16F00}-\\u{16F4A}\\u{16F50}\\u{16F93}-\\u{16F9F}\\u{16FE0}-\\u{16FE1}\\u{16FE3}\\u{16FF2}-\\u{16FF6}\\u{17000}-\\u{18CD5}\\u{18CFF}-\\u{18D1E}\\u{18D80}-\\u{18DF2}\\u{1AFF0}-\\u{1AFF3}\\u{1AFF5}-\\u{1AFFB}\\u{1AFFD}-\\u{1AFFE}\\u{1B000}-\\u{1B122}\\u{1B132}\\u{1B150}-\\u{1B152}\\u{1B155}\\u{1B164}-\\u{1B167}\\u{1B170}-\\u{1B2FB}\\u{1BC00}-\\u{1BC6A}\\u{1BC70}-\\u{1BC7C}\\u{1BC80}-\\u{1BC88}\\u{1BC90}-\\u{1BC99}\\u{1D400}-\\u{1D454}\\u{1D456}-\\u{1D49C}\\u{1D49E}-\\u{1D49F}\\u{1D4A2}\\u{1D4A5}-\\u{1D4A6}\\u{1D4A9}-\\u{1D4AC}\\u{1D4AE}-\\u{1D4B9}\\u{1D4BB}\\u{1D4BD}-\\u{1D4C3}\\u{1D4C5}-\\u{1D505}\\u{1D507}-\\u{1D50A}\\u{1D50D}-\\u{1D514}\\u{1D516}-\\u{1D51C}\\u{1D51E}-\\u{1D539}\\u{1D53B}-\\u{1D53E}\\u{1D540}-\\u{1D544}\\u{1D546}\\u{1D54A}-\\u{1D550}\\u{1D552}-\\u{1D6A5}\\u{1D6A8}-\\u{1D6C0}\\u{1D6C2}-\\u{1D6DA}\\u{1D6DC}-\\u{1D6FA}\\u{1D6FC}-\\u{1D714}\\u{1D716}-\\u{1D734}\\u{1D736}-\\u{1D74E}\\u{1D750}-\\u{1D76E}\\u{1D770}-\\u{1D788}\\u{1D78A}-\\u{1D7A8}\\u{1D7AA}-\\u{1D7C2}\\u{1D7C4}-\\u{1D7CB}\\u{1DF00}-\\u{1DF1E}\\u{1DF25}-\\u{1DF2A}\\u{1E030}-\\u{1E06D}\\u{1E100}-\\u{1E12C}\\u{1E137}-\\u{1E13D}\\u{1E14E}\\u{1E290}-\\u{1E2AD}\\u{1E2C0}-\\u{1E2EB}\\u{1E4D0}-\\u{1E4EB}\\u{1E5D0}-\\u{1E5ED}\\u{1E5F0}\\u{1E6C0}-\\u{1E6DE}\\u{1E6E0}-\\u{1E6E2}\\u{1E6E4}-\\u{1E6E5}\\u{1E6E7}-\\u{1E6ED}\\u{1E6F0}-\\u{1E6F4}\\u{1E6FE}-\\u{1E6FF}\\u{1E7E0}-\\u{1E7E6}\\u{1E7E8}-\\u{1E7EB}\\u{1E7ED}-\\u{1E7EE}\\u{1E7F0}-\\u{1E7FE}\\u{1E800}-\\u{1E8C4}\\u{1E900}-\\u{1E943}\\u{1E94B}\\u{1EE00}-\\u{1EE03}\\u{1EE05}-\\u{1EE1F}\\u{1EE21}-\\u{1EE22}\\u{1EE24}\\u{1EE27}\\u{1EE29}-\\u{1EE32}\\u{1EE34}-\\u{1EE37}\\u{1EE39}\\u{1EE3B}\\u{1EE42}\\u{1EE47}\\u{1EE49}\\u{1EE4B}\\u{1EE4D}-\\u{1EE4F}\\u{1EE51}-\\u{1EE52}\\u{1EE54}\\u{1EE57}\\u{1EE59}\\u{1EE5B}\\u{1EE5D}\\u{1EE5F}\\u{1EE61}-\\u{1EE62}\\u{1EE64}\\u{1EE67}-\\u{1EE6A}\\u{1EE6C}-\\u{1EE72}\\u{1EE74}-\\u{1EE77}\\u{1EE79}-\\u{1EE7C}\\u{1EE7E}\\u{1EE80}-\\u{1EE89}\\u{1EE8B}-\\u{1EE9B}\\u{1EEA1}-\\u{1EEA3}\\u{1EEA5}-\\u{1EEA9}\\u{1EEAB}-\\u{1EEBB}\\u{20000}-\\u{2A6DF}\\u{2A700}-\\u{2B81D}\\u{2B820}-\\u{2CEAD}\\u{2CEB0}-\\u{2EBE0}\\u{2EBF0}-\\u{2EE5D}\\u{2F800}-\\u{2FA1D}\\u{30000}-\\u{3134A}\\u{31350}-\\u{33479}]$","u"),y=RegExp("^[$\\u200C\\u200D\\u0030-\\u0039\\u0041-\\u005A\\u005F\\u0061-\\u007A\\u00AA\\u00B5\\u00B7\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0300-\\u0374\\u0376-\\u0377\\u037A-\\u037D\\u037F\\u0386-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u0483-\\u0487\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0560-\\u0588\\u0591-\\u05BD\\u05BF\\u05C1-\\u05C2\\u05C4-\\u05C5\\u05C7\\u05D0-\\u05EA\\u05EF-\\u05F2\\u0610-\\u061A\\u0620-\\u0669\\u066E-\\u06D3\\u06D5-\\u06DC\\u06DF-\\u06E8\\u06EA-\\u06FC\\u06FF\\u0710-\\u074A\\u074D-\\u07B1\\u07C0-\\u07F5\\u07FA\\u07FD\\u0800-\\u082D\\u0840-\\u085B\\u0860-\\u086A\\u0870-\\u0887\\u0889-\\u088F\\u0897-\\u08E1\\u08E3-\\u0963\\u0966-\\u096F\\u0971-\\u0983\\u0985-\\u098C\\u098F-\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BC-\\u09C4\\u09C7-\\u09C8\\u09CB-\\u09CE\\u09D7\\u09DC-\\u09DD\\u09DF-\\u09E3\\u09E6-\\u09F1\\u09FC\\u09FE\\u0A01-\\u0A03\\u0A05-\\u0A0A\\u0A0F-\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32-\\u0A33\\u0A35-\\u0A36\\u0A38-\\u0A39\\u0A3C\\u0A3E-\\u0A42\\u0A47-\\u0A48\\u0A4B-\\u0A4D\\u0A51\\u0A59-\\u0A5C\\u0A5E\\u0A66-\\u0A75\\u0A81-\\u0A83\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8\\u0AAA-\\u0AB0\\u0AB2-\\u0AB3\\u0AB5-\\u0AB9\\u0ABC-\\u0AC5\\u0AC7-\\u0AC9\\u0ACB-\\u0ACD\\u0AD0\\u0AE0-\\u0AE3\\u0AE6-\\u0AEF\\u0AF9-\\u0AFF\\u0B01-\\u0B03\\u0B05-\\u0B0C\\u0B0F-\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32-\\u0B33\\u0B35-\\u0B39\\u0B3C-\\u0B44\\u0B47-\\u0B48\\u0B4B-\\u0B4D\\u0B55-\\u0B57\\u0B5C-\\u0B5D\\u0B5F-\\u0B63\\u0B66-\\u0B6F\\u0B71\\u0B82-\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99-\\u0B9A\\u0B9C\\u0B9E-\\u0B9F\\u0BA3-\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BBE-\\u0BC2\\u0BC6-\\u0BC8\\u0BCA-\\u0BCD\\u0BD0\\u0BD7\\u0BE6-\\u0BEF\\u0C00-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C39\\u0C3C-\\u0C44\\u0C46-\\u0C48\\u0C4A-\\u0C4D\\u0C55-\\u0C56\\u0C58-\\u0C5A\\u0C5C-\\u0C5D\\u0C60-\\u0C63\\u0C66-\\u0C6F\\u0C80-\\u0C83\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3\\u0CB5-\\u0CB9\\u0CBC-\\u0CC4\\u0CC6-\\u0CC8\\u0CCA-\\u0CCD\\u0CD5-\\u0CD6\\u0CDC-\\u0CDE\\u0CE0-\\u0CE3\\u0CE6-\\u0CEF\\u0CF1-\\u0CF3\\u0D00-\\u0D0C\\u0D0E-\\u0D10\\u0D12-\\u0D44\\u0D46-\\u0D48\\u0D4A-\\u0D4E\\u0D54-\\u0D57\\u0D5F-\\u0D63\\u0D66-\\u0D6F\\u0D7A-\\u0D7F\\u0D81-\\u0D83\\u0D85-\\u0D96\\u0D9A-\\u0DB1\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0DCA\\u0DCF-\\u0DD4\\u0DD6\\u0DD8-\\u0DDF\\u0DE6-\\u0DEF\\u0DF2-\\u0DF3\\u0E01-\\u0E3A\\u0E40-\\u0E4E\\u0E50-\\u0E59\\u0E81-\\u0E82\\u0E84\\u0E86-\\u0E8A\\u0E8C-\\u0EA3\\u0EA5\\u0EA7-\\u0EBD\\u0EC0-\\u0EC4\\u0EC6\\u0EC8-\\u0ECE\\u0ED0-\\u0ED9\\u0EDC-\\u0EDF\\u0F00\\u0F18-\\u0F19\\u0F20-\\u0F29\\u0F35\\u0F37\\u0F39\\u0F3E-\\u0F47\\u0F49-\\u0F6C\\u0F71-\\u0F84\\u0F86-\\u0F97\\u0F99-\\u0FBC\\u0FC6\\u1000-\\u1049\\u1050-\\u109D\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u135D-\\u135F\\u1369-\\u1371\\u1380-\\u138F\\u13A0-\\u13F5\\u13F8-\\u13FD\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16EE-\\u16F8\\u1700-\\u1715\\u171F-\\u1734\\u1740-\\u1753\\u1760-\\u176C\\u176E-\\u1770\\u1772-\\u1773\\u1780-\\u17D3\\u17D7\\u17DC-\\u17DD\\u17E0-\\u17E9\\u180B-\\u180D\\u180F-\\u1819\\u1820-\\u1878\\u1880-\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1920-\\u192B\\u1930-\\u193B\\u1946-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19B0-\\u19C9\\u19D0-\\u19DA\\u1A00-\\u1A1B\\u1A20-\\u1A5E\\u1A60-\\u1A7C\\u1A7F-\\u1A89\\u1A90-\\u1A99\\u1AA7\\u1AB0-\\u1ABD\\u1ABF-\\u1ADD\\u1AE0-\\u1AEB\\u1B00-\\u1B4C\\u1B50-\\u1B59\\u1B6B-\\u1B73\\u1B80-\\u1BF3\\u1C00-\\u1C37\\u1C40-\\u1C49\\u1C4D-\\u1C7D\\u1C80-\\u1C8A\\u1C90-\\u1CBA\\u1CBD-\\u1CBF\\u1CD0-\\u1CD2\\u1CD4-\\u1CFA\\u1D00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u200C-\\u200D\\u203F-\\u2040\\u2054\\u2071\\u207F\\u2090-\\u209C\\u20D0-\\u20DC\\u20E1\\u20E5-\\u20F0\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2118-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2160-\\u2188\\u2C00-\\u2CE4\\u2CEB-\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D7F-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2DE0-\\u2DFF\\u3005-\\u3007\\u3021-\\u302F\\u3031-\\u3035\\u3038-\\u303C\\u3041-\\u3096\\u3099-\\u309F\\u30A1-\\u30FF\\u3105-\\u312F\\u3131-\\u318E\\u31A0-\\u31BF\\u31F0-\\u31FF\\u3400-\\u4DBF\\u4E00-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA62B\\uA640-\\uA66F\\uA674-\\uA67D\\uA67F-\\uA6F1\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA7DC\\uA7F1-\\uA827\\uA82C\\uA840-\\uA873\\uA880-\\uA8C5\\uA8D0-\\uA8D9\\uA8E0-\\uA8F7\\uA8FB\\uA8FD-\\uA92D\\uA930-\\uA953\\uA960-\\uA97C\\uA980-\\uA9C0\\uA9CF-\\uA9D9\\uA9E0-\\uA9FE\\uAA00-\\uAA36\\uAA40-\\uAA4D\\uAA50-\\uAA59\\uAA60-\\uAA76\\uAA7A-\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEF\\uAAF2-\\uAAF6\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E\\uAB30-\\uAB5A\\uAB5C-\\uAB69\\uAB70-\\uABEA\\uABEC-\\uABED\\uABF0-\\uABF9\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D-\\uFB28\\uFB2A-\\uFB36\\uFB38-\\uFB3C\\uFB3E\\uFB40-\\uFB41\\uFB43-\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE00-\\uFE0F\\uFE20-\\uFE2F\\uFE33-\\uFE34\\uFE4D-\\uFE4F\\uFE70-\\uFE74\\uFE76-\\uFEFC\\uFF10-\\uFF19\\uFF21-\\uFF3A\\uFF3F\\uFF41-\\uFF5A\\uFF65-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC\\u{10000}-\\u{1000B}\\u{1000D}-\\u{10026}\\u{10028}-\\u{1003A}\\u{1003C}-\\u{1003D}\\u{1003F}-\\u{1004D}\\u{10050}-\\u{1005D}\\u{10080}-\\u{100FA}\\u{10140}-\\u{10174}\\u{101FD}\\u{10280}-\\u{1029C}\\u{102A0}-\\u{102D0}\\u{102E0}\\u{10300}-\\u{1031F}\\u{1032D}-\\u{1034A}\\u{10350}-\\u{1037A}\\u{10380}-\\u{1039D}\\u{103A0}-\\u{103C3}\\u{103C8}-\\u{103CF}\\u{103D1}-\\u{103D5}\\u{10400}-\\u{1049D}\\u{104A0}-\\u{104A9}\\u{104B0}-\\u{104D3}\\u{104D8}-\\u{104FB}\\u{10500}-\\u{10527}\\u{10530}-\\u{10563}\\u{10570}-\\u{1057A}\\u{1057C}-\\u{1058A}\\u{1058C}-\\u{10592}\\u{10594}-\\u{10595}\\u{10597}-\\u{105A1}\\u{105A3}-\\u{105B1}\\u{105B3}-\\u{105B9}\\u{105BB}-\\u{105BC}\\u{105C0}-\\u{105F3}\\u{10600}-\\u{10736}\\u{10740}-\\u{10755}\\u{10760}-\\u{10767}\\u{10780}-\\u{10785}\\u{10787}-\\u{107B0}\\u{107B2}-\\u{107BA}\\u{10800}-\\u{10805}\\u{10808}\\u{1080A}-\\u{10835}\\u{10837}-\\u{10838}\\u{1083C}\\u{1083F}-\\u{10855}\\u{10860}-\\u{10876}\\u{10880}-\\u{1089E}\\u{108E0}-\\u{108F2}\\u{108F4}-\\u{108F5}\\u{10900}-\\u{10915}\\u{10920}-\\u{10939}\\u{10940}-\\u{10959}\\u{10980}-\\u{109B7}\\u{109BE}-\\u{109BF}\\u{10A00}-\\u{10A03}\\u{10A05}-\\u{10A06}\\u{10A0C}-\\u{10A13}\\u{10A15}-\\u{10A17}\\u{10A19}-\\u{10A35}\\u{10A38}-\\u{10A3A}\\u{10A3F}\\u{10A60}-\\u{10A7C}\\u{10A80}-\\u{10A9C}\\u{10AC0}-\\u{10AC7}\\u{10AC9}-\\u{10AE6}\\u{10B00}-\\u{10B35}\\u{10B40}-\\u{10B55}\\u{10B60}-\\u{10B72}\\u{10B80}-\\u{10B91}\\u{10C00}-\\u{10C48}\\u{10C80}-\\u{10CB2}\\u{10CC0}-\\u{10CF2}\\u{10D00}-\\u{10D27}\\u{10D30}-\\u{10D39}\\u{10D40}-\\u{10D65}\\u{10D69}-\\u{10D6D}\\u{10D6F}-\\u{10D85}\\u{10E80}-\\u{10EA9}\\u{10EAB}-\\u{10EAC}\\u{10EB0}-\\u{10EB1}\\u{10EC2}-\\u{10EC7}\\u{10EFA}-\\u{10F1C}\\u{10F27}\\u{10F30}-\\u{10F50}\\u{10F70}-\\u{10F85}\\u{10FB0}-\\u{10FC4}\\u{10FE0}-\\u{10FF6}\\u{11000}-\\u{11046}\\u{11066}-\\u{11075}\\u{1107F}-\\u{110BA}\\u{110C2}\\u{110D0}-\\u{110E8}\\u{110F0}-\\u{110F9}\\u{11100}-\\u{11134}\\u{11136}-\\u{1113F}\\u{11144}-\\u{11147}\\u{11150}-\\u{11173}\\u{11176}\\u{11180}-\\u{111C4}\\u{111C9}-\\u{111CC}\\u{111CE}-\\u{111DA}\\u{111DC}\\u{11200}-\\u{11211}\\u{11213}-\\u{11237}\\u{1123E}-\\u{11241}\\u{11280}-\\u{11286}\\u{11288}\\u{1128A}-\\u{1128D}\\u{1128F}-\\u{1129D}\\u{1129F}-\\u{112A8}\\u{112B0}-\\u{112EA}\\u{112F0}-\\u{112F9}\\u{11300}-\\u{11303}\\u{11305}-\\u{1130C}\\u{1130F}-\\u{11310}\\u{11313}-\\u{11328}\\u{1132A}-\\u{11330}\\u{11332}-\\u{11333}\\u{11335}-\\u{11339}\\u{1133B}-\\u{11344}\\u{11347}-\\u{11348}\\u{1134B}-\\u{1134D}\\u{11350}\\u{11357}\\u{1135D}-\\u{11363}\\u{11366}-\\u{1136C}\\u{11370}-\\u{11374}\\u{11380}-\\u{11389}\\u{1138B}\\u{1138E}\\u{11390}-\\u{113B5}\\u{113B7}-\\u{113C0}\\u{113C2}\\u{113C5}\\u{113C7}-\\u{113CA}\\u{113CC}-\\u{113D3}\\u{113E1}-\\u{113E2}\\u{11400}-\\u{1144A}\\u{11450}-\\u{11459}\\u{1145E}-\\u{11461}\\u{11480}-\\u{114C5}\\u{114C7}\\u{114D0}-\\u{114D9}\\u{11580}-\\u{115B5}\\u{115B8}-\\u{115C0}\\u{115D8}-\\u{115DD}\\u{11600}-\\u{11640}\\u{11644}\\u{11650}-\\u{11659}\\u{11680}-\\u{116B8}\\u{116C0}-\\u{116C9}\\u{116D0}-\\u{116E3}\\u{11700}-\\u{1171A}\\u{1171D}-\\u{1172B}\\u{11730}-\\u{11739}\\u{11740}-\\u{11746}\\u{11800}-\\u{1183A}\\u{118A0}-\\u{118E9}\\u{118FF}-\\u{11906}\\u{11909}\\u{1190C}-\\u{11913}\\u{11915}-\\u{11916}\\u{11918}-\\u{11935}\\u{11937}-\\u{11938}\\u{1193B}-\\u{11943}\\u{11950}-\\u{11959}\\u{119A0}-\\u{119A7}\\u{119AA}-\\u{119D7}\\u{119DA}-\\u{119E1}\\u{119E3}-\\u{119E4}\\u{11A00}-\\u{11A3E}\\u{11A47}\\u{11A50}-\\u{11A99}\\u{11A9D}\\u{11AB0}-\\u{11AF8}\\u{11B60}-\\u{11B67}\\u{11BC0}-\\u{11BE0}\\u{11BF0}-\\u{11BF9}\\u{11C00}-\\u{11C08}\\u{11C0A}-\\u{11C36}\\u{11C38}-\\u{11C40}\\u{11C50}-\\u{11C59}\\u{11C72}-\\u{11C8F}\\u{11C92}-\\u{11CA7}\\u{11CA9}-\\u{11CB6}\\u{11D00}-\\u{11D06}\\u{11D08}-\\u{11D09}\\u{11D0B}-\\u{11D36}\\u{11D3A}\\u{11D3C}-\\u{11D3D}\\u{11D3F}-\\u{11D47}\\u{11D50}-\\u{11D59}\\u{11D60}-\\u{11D65}\\u{11D67}-\\u{11D68}\\u{11D6A}-\\u{11D8E}\\u{11D90}-\\u{11D91}\\u{11D93}-\\u{11D98}\\u{11DA0}-\\u{11DA9}\\u{11DB0}-\\u{11DDB}\\u{11DE0}-\\u{11DE9}\\u{11EE0}-\\u{11EF6}\\u{11F00}-\\u{11F10}\\u{11F12}-\\u{11F3A}\\u{11F3E}-\\u{11F42}\\u{11F50}-\\u{11F5A}\\u{11FB0}\\u{12000}-\\u{12399}\\u{12400}-\\u{1246E}\\u{12480}-\\u{12543}\\u{12F90}-\\u{12FF0}\\u{13000}-\\u{1342F}\\u{13440}-\\u{13455}\\u{13460}-\\u{143FA}\\u{14400}-\\u{14646}\\u{16100}-\\u{16139}\\u{16800}-\\u{16A38}\\u{16A40}-\\u{16A5E}\\u{16A60}-\\u{16A69}\\u{16A70}-\\u{16ABE}\\u{16AC0}-\\u{16AC9}\\u{16AD0}-\\u{16AED}\\u{16AF0}-\\u{16AF4}\\u{16B00}-\\u{16B36}\\u{16B40}-\\u{16B43}\\u{16B50}-\\u{16B59}\\u{16B63}-\\u{16B77}\\u{16B7D}-\\u{16B8F}\\u{16D40}-\\u{16D6C}\\u{16D70}-\\u{16D79}\\u{16E40}-\\u{16E7F}\\u{16EA0}-\\u{16EB8}\\u{16EBB}-\\u{16ED3}\\u{16F00}-\\u{16F4A}\\u{16F4F}-\\u{16F87}\\u{16F8F}-\\u{16F9F}\\u{16FE0}-\\u{16FE1}\\u{16FE3}-\\u{16FE4}\\u{16FF0}-\\u{16FF6}\\u{17000}-\\u{18CD5}\\u{18CFF}-\\u{18D1E}\\u{18D80}-\\u{18DF2}\\u{1AFF0}-\\u{1AFF3}\\u{1AFF5}-\\u{1AFFB}\\u{1AFFD}-\\u{1AFFE}\\u{1B000}-\\u{1B122}\\u{1B132}\\u{1B150}-\\u{1B152}\\u{1B155}\\u{1B164}-\\u{1B167}\\u{1B170}-\\u{1B2FB}\\u{1BC00}-\\u{1BC6A}\\u{1BC70}-\\u{1BC7C}\\u{1BC80}-\\u{1BC88}\\u{1BC90}-\\u{1BC99}\\u{1BC9D}-\\u{1BC9E}\\u{1CCF0}-\\u{1CCF9}\\u{1CF00}-\\u{1CF2D}\\u{1CF30}-\\u{1CF46}\\u{1D165}-\\u{1D169}\\u{1D16D}-\\u{1D172}\\u{1D17B}-\\u{1D182}\\u{1D185}-\\u{1D18B}\\u{1D1AA}-\\u{1D1AD}\\u{1D242}-\\u{1D244}\\u{1D400}-\\u{1D454}\\u{1D456}-\\u{1D49C}\\u{1D49E}-\\u{1D49F}\\u{1D4A2}\\u{1D4A5}-\\u{1D4A6}\\u{1D4A9}-\\u{1D4AC}\\u{1D4AE}-\\u{1D4B9}\\u{1D4BB}\\u{1D4BD}-\\u{1D4C3}\\u{1D4C5}-\\u{1D505}\\u{1D507}-\\u{1D50A}\\u{1D50D}-\\u{1D514}\\u{1D516}-\\u{1D51C}\\u{1D51E}-\\u{1D539}\\u{1D53B}-\\u{1D53E}\\u{1D540}-\\u{1D544}\\u{1D546}\\u{1D54A}-\\u{1D550}\\u{1D552}-\\u{1D6A5}\\u{1D6A8}-\\u{1D6C0}\\u{1D6C2}-\\u{1D6DA}\\u{1D6DC}-\\u{1D6FA}\\u{1D6FC}-\\u{1D714}\\u{1D716}-\\u{1D734}\\u{1D736}-\\u{1D74E}\\u{1D750}-\\u{1D76E}\\u{1D770}-\\u{1D788}\\u{1D78A}-\\u{1D7A8}\\u{1D7AA}-\\u{1D7C2}\\u{1D7C4}-\\u{1D7CB}\\u{1D7CE}-\\u{1D7FF}\\u{1DA00}-\\u{1DA36}\\u{1DA3B}-\\u{1DA6C}\\u{1DA75}\\u{1DA84}\\u{1DA9B}-\\u{1DA9F}\\u{1DAA1}-\\u{1DAAF}\\u{1DF00}-\\u{1DF1E}\\u{1DF25}-\\u{1DF2A}\\u{1E000}-\\u{1E006}\\u{1E008}-\\u{1E018}\\u{1E01B}-\\u{1E021}\\u{1E023}-\\u{1E024}\\u{1E026}-\\u{1E02A}\\u{1E030}-\\u{1E06D}\\u{1E08F}\\u{1E100}-\\u{1E12C}\\u{1E130}-\\u{1E13D}\\u{1E140}-\\u{1E149}\\u{1E14E}\\u{1E290}-\\u{1E2AE}\\u{1E2C0}-\\u{1E2F9}\\u{1E4D0}-\\u{1E4F9}\\u{1E5D0}-\\u{1E5FA}\\u{1E6C0}-\\u{1E6DE}\\u{1E6E0}-\\u{1E6F5}\\u{1E6FE}-\\u{1E6FF}\\u{1E7E0}-\\u{1E7E6}\\u{1E7E8}-\\u{1E7EB}\\u{1E7ED}-\\u{1E7EE}\\u{1E7F0}-\\u{1E7FE}\\u{1E800}-\\u{1E8C4}\\u{1E8D0}-\\u{1E8D6}\\u{1E900}-\\u{1E94B}\\u{1E950}-\\u{1E959}\\u{1EE00}-\\u{1EE03}\\u{1EE05}-\\u{1EE1F}\\u{1EE21}-\\u{1EE22}\\u{1EE24}\\u{1EE27}\\u{1EE29}-\\u{1EE32}\\u{1EE34}-\\u{1EE37}\\u{1EE39}\\u{1EE3B}\\u{1EE42}\\u{1EE47}\\u{1EE49}\\u{1EE4B}\\u{1EE4D}-\\u{1EE4F}\\u{1EE51}-\\u{1EE52}\\u{1EE54}\\u{1EE57}\\u{1EE59}\\u{1EE5B}\\u{1EE5D}\\u{1EE5F}\\u{1EE61}-\\u{1EE62}\\u{1EE64}\\u{1EE67}-\\u{1EE6A}\\u{1EE6C}-\\u{1EE72}\\u{1EE74}-\\u{1EE77}\\u{1EE79}-\\u{1EE7C}\\u{1EE7E}\\u{1EE80}-\\u{1EE89}\\u{1EE8B}-\\u{1EE9B}\\u{1EEA1}-\\u{1EEA3}\\u{1EEA5}-\\u{1EEA9}\\u{1EEAB}-\\u{1EEBB}\\u{1FBF0}-\\u{1FBF9}\\u{20000}-\\u{2A6DF}\\u{2A700}-\\u{2B81D}\\u{2B820}-\\u{2CEAD}\\u{2CEB0}-\\u{2EBE0}\\u{2EBF0}-\\u{2EE5D}\\u{2F800}-\\u{2FA1D}\\u{30000}-\\u{3134A}\\u{31350}-\\u{33479}\\u{E0100}-\\u{E01EF}]$","u"),b={"{":"{","}":"}","(":"(",")":")","[":"[","]":"]","+":"+","?":"?","!":"!"};function v(e){return e.replace(/[.+*?^${}()[\]|/\\]/g,"\\$&")}var g=function e(t,r){n(this,e),this.tokens=t,this.originalPath=r},w=function(e){if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function t(e,r){n(this,t);var o,a,u,s=e;return r&&(s+=": ".concat(r)),s+="; visit https://git.new/pathToRegexpError for info",o=t,a=[s],o=i(o),(u=function(e,t){if(t&&("object"===l(t)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,f()?Reflect.construct(o,a||[],i(this).constructor):o.apply(this,a))).originalPath=r,u}return t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&u(t,e),t}(d(TypeError))},8279(e,t,r){"use strict";var n=r(2065);t.createRoot=n.createRoot,t.hydrateRoot=n.hydrateRoot},4131(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7127),a=r(1138);t.AsyncSubject=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.value=null,t.hasNext=!1,t.hasCompleted=!1,t}return o(t,e),t.prototype._subscribe=function(t){return this.hasError?(t.error(this.thrownError),a.Subscription.EMPTY):this.hasCompleted&&this.hasNext?(t.next(this.value),t.complete(),a.Subscription.EMPTY):e.prototype._subscribe.call(this,t)},t.prototype.next=function(e){this.hasCompleted||(this.value=e,this.hasNext=!0)},t.prototype.error=function(t){this.hasCompleted||e.prototype.error.call(this,t)},t.prototype.complete=function(){this.hasCompleted=!0,this.hasNext&&e.prototype.next.call(this,this.value),e.prototype.complete.call(this)},t}(i.Subject)},9553(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7127),a=r(1277);t.BehaviorSubject=function(e){function t(t){var r=e.call(this)||this;return r._value=t,r}return o(t,e),Object.defineProperty(t.prototype,"value",{get:function(){return this.getValue()},enumerable:!0,configurable:!0}),t.prototype._subscribe=function(t){var r=e.prototype._subscribe.call(this,t);return r&&!r.closed&&t.next(this._value),r},t.prototype.getValue=function(){if(this.hasError)throw this.thrownError;if(!this.closed)return this._value;throw new a.ObjectUnsubscribedError},t.prototype.next=function(t){e.prototype.next.call(this,this._value=t)},t}(i.Subject)},4921(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.InnerSubscriber=function(e){function t(t,r,n){var o=e.call(this)||this;return o.parent=t,o.outerValue=r,o.outerIndex=n,o.index=0,o}return o(t,e),t.prototype._next=function(e){this.parent.notifyNext(this.outerValue,e,this.outerIndex,this.index++,this)},t.prototype._error=function(e){this.parent.notifyError(e,this),this.unsubscribe()},t.prototype._complete=function(){this.parent.notifyComplete(this),this.unsubscribe()},t}(r(7097).Subscriber)},8292(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,o=r(1684),i=r(2200),a=r(9923);(n=t.NotificationKind||(t.NotificationKind={})).NEXT="N",n.ERROR="E",n.COMPLETE="C",t.Notification=function(){function e(e,t,r){this.kind=e,this.value=t,this.error=r,this.hasValue="N"===e}return e.prototype.observe=function(e){switch(this.kind){case"N":return e.next&&e.next(this.value);case"E":return e.error&&e.error(this.error);case"C":return e.complete&&e.complete()}},e.prototype.do=function(e,t,r){switch(this.kind){case"N":return e&&e(this.value);case"E":return t&&t(this.error);case"C":return r&&r()}},e.prototype.accept=function(e,t,r){return e&&"function"==typeof e.next?this.observe(e):this.do(e,t,r)},e.prototype.toObservable=function(){switch(this.kind){case"N":return i.of(this.value);case"E":return a.throwError(this.error);case"C":return o.empty()}throw Error("unexpected notification kind value")},e.createNext=function(t){return void 0!==t?new e("N",t):e.undefinedValueNotification},e.createError=function(t){return new e("E",void 0,t)},e.createComplete=function(){return e.completeNotification},e.completeNotification=new e("C"),e.undefinedValueNotification=new e("N",void 0),e}()},7154(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(6012),o=r(4665),i=r(4227),a=r(7654),u=r(3657);function s(e){if(e||(e=u.config.Promise||Promise),!e)throw Error("no Promise impl found");return e}t.Observable=function(){function e(e){this._isScalar=!1,e&&(this._subscribe=e)}return e.prototype.lift=function(t){var r=new e;return r.source=this,r.operator=t,r},e.prototype.subscribe=function(e,t,r){var n=this.operator,i=o.toSubscriber(e,t,r);if(n?i.add(n.call(i,this.source)):i.add(this.source||u.config.useDeprecatedSynchronousErrorHandling&&!i.syncErrorThrowable?this._subscribe(i):this._trySubscribe(i)),u.config.useDeprecatedSynchronousErrorHandling&&i.syncErrorThrowable&&(i.syncErrorThrowable=!1,i.syncErrorThrown))throw i.syncErrorValue;return i},e.prototype._trySubscribe=function(e){try{return this._subscribe(e)}catch(t){u.config.useDeprecatedSynchronousErrorHandling&&(e.syncErrorThrown=!0,e.syncErrorValue=t),n.canReportError(e)?e.error(t):console.warn(t)}},e.prototype.forEach=function(e,t){var r=this;return new(t=s(t))(function(t,n){var o;o=r.subscribe(function(t){try{e(t)}catch(e){n(e),o&&o.unsubscribe()}},n,t)})},e.prototype._subscribe=function(e){var t=this.source;return t&&t.subscribe(e)},e.prototype[i.observable]=function(){return this},e.prototype.pipe=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return 0===e.length?this:a.pipeFromArray(e)(this)},e.prototype.toPromise=function(e){var t=this;return new(e=s(e))(function(e,r){var n;t.subscribe(function(e){return n=e},function(e){return r(e)},function(){return e(n)})})},e.create=function(t){return new e(t)},e}()},4109(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3657),o=r(2618);t.empty={closed:!0,next:function(e){},error:function(e){if(n.config.useDeprecatedSynchronousErrorHandling)throw e;o.hostReportError(e)},complete:function(){}}},5238(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.OuterSubscriber=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.notifyNext=function(e,t,r,n,o){this.destination.next(t)},t.prototype.notifyError=function(e,t){this.destination.error(e)},t.prototype.notifyComplete=function(e){this.destination.complete()},t}(r(7097).Subscriber)},2462(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7127),a=r(3954),u=r(1138),s=r(4436),l=r(1277),c=r(2746);t.ReplaySubject=function(e){function t(t,r,n){void 0===t&&(t=1/0),void 0===r&&(r=1/0);var o=e.call(this)||this;return o.scheduler=n,o._events=[],o._infiniteTimeWindow=!1,o._bufferSize=t<1?1:t,o._windowTime=r<1?1:r,r===1/0?(o._infiniteTimeWindow=!0,o.next=o.nextInfiniteTimeWindow):o.next=o.nextTimeWindow,o}return o(t,e),t.prototype.nextInfiniteTimeWindow=function(t){if(!this.isStopped){var r=this._events;r.push(t),r.length>this._bufferSize&&r.shift()}e.prototype.next.call(this,t)},t.prototype.nextTimeWindow=function(t){this.isStopped||(this._events.push(new d(this._getNow(),t)),this._trimBufferThenGetEvents()),e.prototype.next.call(this,t)},t.prototype._subscribe=function(e){var t,r=this._infiniteTimeWindow,n=r?this._events:this._trimBufferThenGetEvents(),o=this.scheduler,i=n.length;if(this.closed)throw new l.ObjectUnsubscribedError;if(this.isStopped||this.hasError?t=u.Subscription.EMPTY:(this.observers.push(e),t=new c.SubjectSubscription(this,e)),o&&e.add(e=new s.ObserveOnSubscriber(e,o)),r)for(var a=0;a<i&&!e.closed;a++)e.next(n[a]);else for(var a=0;a<i&&!e.closed;a++)e.next(n[a].value);return this.hasError?e.error(this.thrownError):this.isStopped&&e.complete(),t},t.prototype._getNow=function(){return(this.scheduler||a.queue).now()},t.prototype._trimBufferThenGetEvents=function(){for(var e=this._getNow(),t=this._bufferSize,r=this._windowTime,n=this._events,o=n.length,i=0;i<o&&!(e-n[i].time<r);)i++;return o>t&&(i=Math.max(i,o-t)),i>0&&n.splice(0,i),n},t}(i.Subject);var d=function(e,t){this.time=e,this.value=t}},3054(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Scheduler=function(){function e(t,r){void 0===r&&(r=e.now),this.SchedulerAction=t,this.now=r}return e.prototype.schedule=function(e,t,r){return void 0===t&&(t=0),new this.SchedulerAction(this,e).schedule(r,t)},e.now=function(){return Date.now()},e}()},7127(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7154),a=r(7097),u=r(1138),s=r(1277),l=r(2746),c=r(3798),d=function(e){function t(t){var r=e.call(this,t)||this;return r.destination=t,r}return o(t,e),t}(a.Subscriber);t.SubjectSubscriber=d;var f=function(e){function t(){var t=e.call(this)||this;return t.observers=[],t.closed=!1,t.isStopped=!1,t.hasError=!1,t.thrownError=null,t}return o(t,e),t.prototype[c.rxSubscriber]=function(){return new d(this)},t.prototype.lift=function(e){var t=new p(this,this);return t.operator=e,t},t.prototype.next=function(e){if(this.closed)throw new s.ObjectUnsubscribedError;if(!this.isStopped)for(var t=this.observers,r=t.length,n=t.slice(),o=0;o<r;o++)n[o].next(e)},t.prototype.error=function(e){if(this.closed)throw new s.ObjectUnsubscribedError;this.hasError=!0,this.thrownError=e,this.isStopped=!0;for(var t=this.observers,r=t.length,n=t.slice(),o=0;o<r;o++)n[o].error(e);this.observers.length=0},t.prototype.complete=function(){if(this.closed)throw new s.ObjectUnsubscribedError;this.isStopped=!0;for(var e=this.observers,t=e.length,r=e.slice(),n=0;n<t;n++)r[n].complete();this.observers.length=0},t.prototype.unsubscribe=function(){this.isStopped=!0,this.closed=!0,this.observers=null},t.prototype._trySubscribe=function(t){if(!this.closed)return e.prototype._trySubscribe.call(this,t);throw new s.ObjectUnsubscribedError},t.prototype._subscribe=function(e){if(this.closed)throw new s.ObjectUnsubscribedError;return this.hasError?(e.error(this.thrownError),u.Subscription.EMPTY):this.isStopped?(e.complete(),u.Subscription.EMPTY):(this.observers.push(e),new l.SubjectSubscription(this,e))},t.prototype.asObservable=function(){var e=new i.Observable;return e.source=this,e},t.create=function(e,t){return new p(e,t)},t}(i.Observable);t.Subject=f;var p=function(e){function t(t,r){var n=e.call(this)||this;return n.destination=t,n.source=r,n}return o(t,e),t.prototype.next=function(e){var t=this.destination;t&&t.next&&t.next(e)},t.prototype.error=function(e){var t=this.destination;t&&t.error&&this.destination.error(e)},t.prototype.complete=function(){var e=this.destination;e&&e.complete&&this.destination.complete()},t.prototype._subscribe=function(e){return this.source?this.source.subscribe(e):u.Subscription.EMPTY},t}(f);t.AnonymousSubject=p},2746(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.SubjectSubscription=function(e){function t(t,r){var n=e.call(this)||this;return n.subject=t,n.subscriber=r,n.closed=!1,n}return o(t,e),t.prototype.unsubscribe=function(){if(!this.closed){this.closed=!0;var e=this.subject,t=e.observers;if(this.subject=null,t&&0!==t.length&&!e.isStopped&&!e.closed){var r=t.indexOf(this.subscriber);-1!==r&&t.splice(r,1)}}},t}(r(1138).Subscription)},7097(e,t,r){"use strict";function n(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}var o,i=this&&this.__extends||(o=function(e,t){return(o=Object.setPrototypeOf||n({__proto__:[]},Array)&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var a=r(7894),u=r(4109),s=r(1138),l=r(3798),c=r(3657),d=r(2618),f=function(e){function t(r,o,i){var a=e.call(this)||this;switch(a.syncErrorValue=null,a.syncErrorThrown=!1,a.syncErrorThrowable=!1,a.isStopped=!1,arguments.length){case 0:a.destination=u.empty;break;case 1:if(!r){a.destination=u.empty;break}if((void 0===r?"undefined":r&&"u">typeof Symbol&&r.constructor===Symbol?"symbol":typeof r)=="object"){n(r,t)?(a.syncErrorThrowable=r.syncErrorThrowable,a.destination=r,r.add(a)):(a.syncErrorThrowable=!0,a.destination=new p(a,r));break}default:a.syncErrorThrowable=!0,a.destination=new p(a,r,o,i)}return a}return i(t,e),t.prototype[l.rxSubscriber]=function(){return this},t.create=function(e,r,n){var o=new t(e,r,n);return o.syncErrorThrowable=!1,o},t.prototype.next=function(e){this.isStopped||this._next(e)},t.prototype.error=function(e){this.isStopped||(this.isStopped=!0,this._error(e))},t.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,e.prototype.unsubscribe.call(this))},t.prototype._next=function(e){this.destination.next(e)},t.prototype._error=function(e){this.destination.error(e),this.unsubscribe()},t.prototype._complete=function(){this.destination.complete(),this.unsubscribe()},t.prototype._unsubscribeAndRecycle=function(){var e=this._parentOrParents;return this._parentOrParents=null,this.unsubscribe(),this.closed=!1,this.isStopped=!1,this._parentOrParents=e,this},t}(s.Subscription);t.Subscriber=f;var p=function(e){function t(t,r,n,o){var i,s=e.call(this)||this;s._parentSubscriber=t;var l=s;return a.isFunction(r)?i=r:r&&(i=r.next,n=r.error,o=r.complete,r!==u.empty&&(l=Object.create(r),a.isFunction(l.unsubscribe)&&s.add(l.unsubscribe.bind(l)),l.unsubscribe=s.unsubscribe.bind(s))),s._context=l,s._next=i,s._error=n,s._complete=o,s}return i(t,e),t.prototype.next=function(e){if(!this.isStopped&&this._next){var t=this._parentSubscriber;c.config.useDeprecatedSynchronousErrorHandling&&t.syncErrorThrowable?this.__tryOrSetError(t,this._next,e)&&this.unsubscribe():this.__tryOrUnsub(this._next,e)}},t.prototype.error=function(e){if(!this.isStopped){var t=this._parentSubscriber,r=c.config.useDeprecatedSynchronousErrorHandling;if(this._error)r&&t.syncErrorThrowable?this.__tryOrSetError(t,this._error,e):this.__tryOrUnsub(this._error,e),this.unsubscribe();else if(t.syncErrorThrowable)r?(t.syncErrorValue=e,t.syncErrorThrown=!0):d.hostReportError(e),this.unsubscribe();else{if(this.unsubscribe(),r)throw e;d.hostReportError(e)}}},t.prototype.complete=function(){var e=this;if(!this.isStopped){var t=this._parentSubscriber;if(this._complete){var r=function(){return e._complete.call(e._context)};c.config.useDeprecatedSynchronousErrorHandling&&t.syncErrorThrowable?this.__tryOrSetError(t,r):this.__tryOrUnsub(r),this.unsubscribe()}else this.unsubscribe()}},t.prototype.__tryOrUnsub=function(e,t){try{e.call(this._context,t)}catch(e){if(this.unsubscribe(),c.config.useDeprecatedSynchronousErrorHandling)throw e;d.hostReportError(e)}},t.prototype.__tryOrSetError=function(e,t,r){if(!c.config.useDeprecatedSynchronousErrorHandling)throw Error("bad call");try{t.call(this._context,r)}catch(t){if(c.config.useDeprecatedSynchronousErrorHandling)return e.syncErrorValue=t,e.syncErrorThrown=!0,!0;return d.hostReportError(t),!0}return!1},t.prototype._unsubscribe=function(){var e=this._parentSubscriber;this._context=null,this._parentSubscriber=null,e.unsubscribe()},t}(f);t.SafeSubscriber=p},1138(e,t,r){"use strict";function n(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}Object.defineProperty(t,"__esModule",{value:!0});var o=r(9109),i=r(5393),a=r(7894),u=r(6384);function s(e){return e.reduce(function(e,t){return e.concat(n(t,u.UnsubscriptionError)?t.errors:t)},[])}t.Subscription=function(){var e;function t(e){this.closed=!1,this._parentOrParents=null,this._subscriptions=null,e&&(this._ctorUnsubscribe=!0,this._unsubscribe=e)}return t.prototype.unsubscribe=function(){if(!this.closed){var e,r=this._parentOrParents,l=this._ctorUnsubscribe,c=this._unsubscribe,d=this._subscriptions;if(this.closed=!0,this._parentOrParents=null,this._subscriptions=null,n(r,t))r.remove(this);else if(null!==r)for(var f=0;f<r.length;++f)r[f].remove(this);if(a.isFunction(c)){l&&(this._unsubscribe=void 0);try{c.call(this)}catch(t){e=n(t,u.UnsubscriptionError)?s(t.errors):[t]}}if(o.isArray(d))for(var f=-1,p=d.length;++f<p;){var h=d[f];if(i.isObject(h))try{h.unsubscribe()}catch(t){e=e||[],n(t,u.UnsubscriptionError)?e=e.concat(s(t.errors)):e.push(t)}}if(e)throw new u.UnsubscriptionError(e)}},t.prototype.add=function(e){var r=e;if(!e)return t.EMPTY;switch(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e){case"function":r=new t(e);case"object":if(r===this||r.closed||"function"!=typeof r.unsubscribe)return r;if(this.closed)return r.unsubscribe(),r;if(!n(r,t)){var o=r;(r=new t)._subscriptions=[o]}break;default:throw Error("unrecognized teardown "+e+" added to Subscription.")}var i=r._parentOrParents;if(null===i)r._parentOrParents=this;else if(n(i,t)){if(i===this)return r;r._parentOrParents=[i,this]}else{if(-1!==i.indexOf(this))return r;i.push(this)}var a=this._subscriptions;return null===a?this._subscriptions=[r]:a.push(r),r},t.prototype.remove=function(e){var t=this._subscriptions;if(t){var r=t.indexOf(e);-1!==r&&t.splice(r,1)}},(e=new t).closed=!0,t.EMPTY=e,t}()},3657(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=!1;t.config={Promise:void 0,set useDeprecatedSynchronousErrorHandling(value){value?console.warn("DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n"+Error().stack):r&&console.log("RxJS: Back to a better error behavior. Thank you. <3"),r=value},get useDeprecatedSynchronousErrorHandling(){return r}}},8255(e,t,r){"use strict";function n(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}var o,i=this&&this.__extends||(o=function(e,t){return(o=Object.setPrototypeOf||n({__proto__:[]},Array)&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var a=r(7097),u=r(7154),s=r(3997);t.SimpleInnerSubscriber=function(e){function t(t){var r=e.call(this)||this;return r.parent=t,r}return i(t,e),t.prototype._next=function(e){this.parent.notifyNext(e)},t.prototype._error=function(e){this.parent.notifyError(e),this.unsubscribe()},t.prototype._complete=function(){this.parent.notifyComplete(),this.unsubscribe()},t}(a.Subscriber),t.ComplexInnerSubscriber=function(e){function t(t,r,n){var o=e.call(this)||this;return o.parent=t,o.outerValue=r,o.outerIndex=n,o}return i(t,e),t.prototype._next=function(e){this.parent.notifyNext(this.outerValue,e,this.outerIndex,this)},t.prototype._error=function(e){this.parent.notifyError(e),this.unsubscribe()},t.prototype._complete=function(){this.parent.notifyComplete(this),this.unsubscribe()},t}(a.Subscriber),t.SimpleOuterSubscriber=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.notifyNext=function(e){this.destination.next(e)},t.prototype.notifyError=function(e){this.destination.error(e)},t.prototype.notifyComplete=function(){this.destination.complete()},t}(a.Subscriber),t.ComplexOuterSubscriber=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.notifyNext=function(e,t,r,n){this.destination.next(t)},t.prototype.notifyError=function(e){this.destination.error(e)},t.prototype.notifyComplete=function(e){this.destination.complete()},t}(a.Subscriber),t.innerSubscribe=function(e,t){var r;if(!t.closed){if(n(e,u.Observable))return e.subscribe(t);try{r=s.subscribeTo(e)(t)}catch(e){t.error(e)}return r}}},9226(e,t,r){"use strict";var n,o,i=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var a=r(7127),u=r(7154),s=r(7097),l=r(1138),c=r(9509),d=function(e){function t(t,r){var n=e.call(this)||this;return n.source=t,n.subjectFactory=r,n._refCount=0,n._isComplete=!1,n}return i(t,e),t.prototype._subscribe=function(e){return this.getSubject().subscribe(e)},t.prototype.getSubject=function(){var e=this._subject;return(!e||e.isStopped)&&(this._subject=this.subjectFactory()),this._subject},t.prototype.connect=function(){var e=this._connection;return!e&&(this._isComplete=!1,(e=this._connection=new l.Subscription).add(this.source.subscribe(new f(this.getSubject(),this))),e.closed&&(this._connection=null,e=l.Subscription.EMPTY)),e},t.prototype.refCount=function(){return c.refCount()(this)},t}(u.Observable);t.ConnectableObservable=d,t.connectableObservableDescriptor={operator:{value:null},_refCount:{value:0,writable:!0},_subject:{value:null,writable:!0},_connection:{value:null,writable:!0},_subscribe:{value:(o=d.prototype)._subscribe},_isComplete:{value:o._isComplete,writable:!0},getSubject:{value:o.getSubject},connect:{value:o.connect},refCount:{value:o.refCount}};var f=function(e){function t(t,r){var n=e.call(this,t)||this;return n.connectable=r,n}return i(t,e),t.prototype._error=function(t){this._unsubscribe(),e.prototype._error.call(this,t)},t.prototype._complete=function(){this.connectable._isComplete=!0,this._unsubscribe(),e.prototype._complete.call(this)},t.prototype._unsubscribe=function(){var e=this.connectable;if(e){this.connectable=null;var t=e._connection;e._refCount=0,e._subject=null,e._connection=null,t&&t.unsubscribe()}},t}(a.SubjectSubscriber);(function(e){this.connectable=e}).prototype.call=function(e,t){var r=this.connectable;r._refCount++;var n=new p(e,r),o=t.subscribe(n);return n.closed||(n.connection=r.connect()),o};var p=function(e){function t(t,r){var n=e.call(this,t)||this;return n.connectable=r,n}return i(t,e),t.prototype._unsubscribe=function(){var e=this.connectable;if(!e){this.connection=null;return}this.connectable=null;var t=e._refCount;if(t<=0||(e._refCount=t-1,t>1)){this.connection=null;return}var r=this.connection,n=e._connection;this.connection=null,n&&(!r||n===r)&&n.unsubscribe()},t}(s.Subscriber)},6213(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7154),a=r(8752),u=r(2651);t.SubscribeOnObservable=function(e){function t(t,r,n){void 0===r&&(r=0),void 0===n&&(n=a.asap);var o=e.call(this)||this;return o.source=t,o.delayTime=r,o.scheduler=n,(!u.isNumeric(r)||r<0)&&(o.delayTime=0),n&&"function"==typeof n.schedule||(o.scheduler=a.asap),o}return o(t,e),t.create=function(e,r,n){return void 0===r&&(r=0),void 0===n&&(n=a.asap),new t(e,r,n)},t.dispatch=function(e){var t=e.source,r=e.subscriber;return this.add(t.subscribe(r))},t.prototype._subscribe=function(e){var r=this.delayTime,n=this.source;return this.scheduler.schedule(t.dispatch,r,{source:n,subscriber:e})},t}(i.Observable)},2115(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(9489),a=r(9109),u=r(5238),s=r(8632),l=r(2060),c={};t.combineLatest=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=void 0,n=void 0;return i.isScheduler(e[e.length-1])&&(n=e.pop()),"function"==typeof e[e.length-1]&&(r=e.pop()),1===e.length&&a.isArray(e[0])&&(e=e[0]),l.fromArray(e,n).lift(new d(r))};var d=function(){function e(e){this.resultSelector=e}return e.prototype.call=function(e,t){return t.subscribe(new f(e,this.resultSelector))},e}();t.CombineLatestOperator=d;var f=function(e){function t(t,r){var n=e.call(this,t)||this;return n.resultSelector=r,n.active=0,n.values=[],n.observables=[],n}return o(t,e),t.prototype._next=function(e){this.values.push(c),this.observables.push(e)},t.prototype._complete=function(){var e=this.observables,t=e.length;if(0===t)this.destination.complete();else{this.active=t,this.toRespond=t;for(var r=0;r<t;r++){var n=e[r];this.add(s.subscribeToResult(this,n,void 0,r))}}},t.prototype.notifyComplete=function(e){0==(this.active-=1)&&this.destination.complete()},t.prototype.notifyNext=function(e,t,r){var n=this.values,o=n[r],i=this.toRespond?o===c?--this.toRespond:this.toRespond:0;n[r]=t,0===i&&(this.resultSelector?this._tryResultSelector(n):this.destination.next(n.slice()))},t.prototype._tryResultSelector=function(e){var t;try{t=this.resultSelector.apply(this,e)}catch(e){this.destination.error(e);return}this.destination.next(t)},t}(u.OuterSubscriber);t.CombineLatestSubscriber=f},8093(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2200),o=r(7930);t.concat=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return o.concatAll()(n.of.apply(void 0,e))}},6349(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154),o=r(9001),i=r(1684);t.defer=function(e){return new n.Observable(function(t){var r;try{r=e()}catch(e){t.error(e);return}return(r?o.from(r):i.empty()).subscribe(t)})}},1684(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154);t.EMPTY=new n.Observable(function(e){return e.complete()}),t.empty=function(e){var r;return e?(r=e,new n.Observable(function(e){return r.schedule(function(){return e.complete()})})):t.EMPTY}},9001(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154),o=r(3997),i=r(204);t.from=function(e,t){var r;return t?i.scheduled(e,t):(null!=(r=n.Observable)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](e):e instanceof r)?e:new n.Observable(o.subscribeTo(e))}},2060(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154),o=r(9128),i=r(4101);t.fromArray=function(e,t){return t?i.scheduleArray(e,t):new n.Observable(o.subscribeToArray(e))}},1861(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154),o=r(9489),i=r(8914),a=r(2060);t.merge=function(){for(var e,t,r=[],u=0;u<arguments.length;u++)r[u]=arguments[u];var s=1/0,l=null,c=r[r.length-1];return(o.isScheduler(c)?(l=r.pop(),r.length>1&&"number"==typeof r[r.length-1]&&(s=r.pop())):"number"==typeof c&&(s=r.pop()),null===l&&1===r.length&&(e=r[0],null!=(t=n.Observable)&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t))?r[0]:i.mergeAll(s)(a.fromArray(r,l))}},2200(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9489),o=r(2060),i=r(4101);t.of=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=e[e.length-1];return n.isScheduler(r)?(e.pop(),i.scheduleArray(e,r)):o.fromArray(e)}},2964(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(9109),a=r(2060),u=r(5238),s=r(8632);t.race=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(1===e.length)if(!i.isArray(e[0]))return e[0];else e=e[0];return a.fromArray(e,void 0).lift(new l)};var l=function(){function e(){}return e.prototype.call=function(e,t){return t.subscribe(new c(e))},e}();t.RaceOperator=l;var c=function(e){function t(t){var r=e.call(this,t)||this;return r.hasFirst=!1,r.observables=[],r.subscriptions=[],r}return o(t,e),t.prototype._next=function(e){this.observables.push(e)},t.prototype._complete=function(){var e=this.observables,t=e.length;if(0===t)this.destination.complete();else{for(var r=0;r<t&&!this.hasFirst;r++){var n=e[r],o=s.subscribeToResult(this,n,void 0,r);this.subscriptions&&this.subscriptions.push(o),this.add(o)}this.observables=null}},t.prototype.notifyNext=function(e,t,r){if(!this.hasFirst){this.hasFirst=!0;for(var n=0;n<this.subscriptions.length;n++)if(n!==r){var o=this.subscriptions[n];o.unsubscribe(),this.remove(o)}this.subscriptions=null}this.destination.next(t)},t}(u.OuterSubscriber);t.RaceSubscriber=c},9923(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154);function o(e){var t=e.error;e.subscriber.error(t)}t.throwError=function(e,t){return new n.Observable(t?function(r){return t.schedule(o,0,{error:e,subscriber:r})}:function(t){return t.error(e)})}},4888(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154),o=r(7661),i=r(2651),a=r(9489);function u(e){var t=e.index,r=e.period,n=e.subscriber;if(n.next(t),!n.closed){if(-1===r)return n.complete();e.index=t+1,this.schedule(e,r)}}t.timer=function(e,t,r){void 0===e&&(e=0);var s=-1;return i.isNumeric(t)?s=1>Number(t)&&1||Number(t):a.isScheduler(t)&&(r=t),a.isScheduler(r)||(r=o.async),new n.Observable(function(t){var n=i.isNumeric(e)?e:e-r.now();return r.schedule(u,n,{index:0,period:s,subscriber:t})})}},3834(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(2060),a=r(9109),u=r(7097),s=r(2648),l=r(8255);t.zip=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=e[e.length-1];return"function"==typeof r&&e.pop(),i.fromArray(e,void 0).lift(new c(r))};var c=function(){function e(e){this.resultSelector=e}return e.prototype.call=function(e,t){return t.subscribe(new d(e,this.resultSelector))},e}();t.ZipOperator=c;var d=function(e){function t(t,r,n){void 0===n&&(n=Object.create(null));var o=e.call(this,t)||this;return o.resultSelector=r,o.iterators=[],o.active=0,o.resultSelector="function"==typeof r?r:void 0,o}return o(t,e),t.prototype._next=function(e){var t=this.iterators;a.isArray(e)?t.push(new p(e)):"function"==typeof e[s.iterator]?t.push(new f(e[s.iterator]())):t.push(new h(this.destination,this,e))},t.prototype._complete=function(){var e=this.iterators,t=e.length;if(this.unsubscribe(),0===t)return void this.destination.complete();this.active=t;for(var r=0;r<t;r++){var n=e[r];n.stillUnsubscribed?this.destination.add(n.subscribe()):this.active--}},t.prototype.notifyInactive=function(){this.active--,0===this.active&&this.destination.complete()},t.prototype.checkIterators=function(){for(var e=this.iterators,t=e.length,r=this.destination,n=0;n<t;n++){var o=e[n];if("function"==typeof o.hasValue&&!o.hasValue())return}for(var i=!1,a=[],n=0;n<t;n++){var o=e[n],u=o.next();if(o.hasCompleted()&&(i=!0),u.done)return void r.complete();a.push(u.value)}this.resultSelector?this._tryresultSelector(a):r.next(a),i&&r.complete()},t.prototype._tryresultSelector=function(e){var t;try{t=this.resultSelector.apply(this,e)}catch(e){this.destination.error(e);return}this.destination.next(t)},t}(u.Subscriber);t.ZipSubscriber=d;var f=function(){function e(e){this.iterator=e,this.nextResult=e.next()}return e.prototype.hasValue=function(){return!0},e.prototype.next=function(){var e=this.nextResult;return this.nextResult=this.iterator.next(),e},e.prototype.hasCompleted=function(){var e=this.nextResult;return!!(e&&e.done)},e}(),p=function(){function e(e){this.array=e,this.index=0,this.length=0,this.length=e.length}return e.prototype[s.iterator]=function(){return this},e.prototype.next=function(e){var t=this.index++,r=this.array;return t<this.length?{value:r[t],done:!1}:{value:null,done:!0}},e.prototype.hasValue=function(){return this.array.length>this.index},e.prototype.hasCompleted=function(){return this.array.length===this.index},e}(),h=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.parent=r,o.observable=n,o.stillUnsubscribed=!0,o.buffer=[],o.isComplete=!1,o}return o(t,e),t.prototype[s.iterator]=function(){return this},t.prototype.next=function(){var e=this.buffer;return 0===e.length&&this.isComplete?{value:null,done:!0}:{value:e.shift(),done:!1}},t.prototype.hasValue=function(){return this.buffer.length>0},t.prototype.hasCompleted=function(){return 0===this.buffer.length&&this.isComplete},t.prototype.notifyComplete=function(){this.buffer.length>0?(this.isComplete=!0,this.parent.notifyInactive()):this.destination.complete()},t.prototype.notifyNext=function(e){this.buffer.push(e),this.parent.checkIterators()},t.prototype.subscribe=function(){return l.innerSubscribe(this.observable,new l.SimpleInnerSubscriber(this))},t}(l.SimpleOuterSubscriber)},6278(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.audit=function(e){return function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.durationSelector=e}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.durationSelector))},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.durationSelector=r,n.hasValue=!1,n}return o(t,e),t.prototype._next=function(e){if(this.value=e,this.hasValue=!0,!this.throttled){var t=void 0;try{t=(0,this.durationSelector)(e)}catch(e){return this.destination.error(e)}var r=i.innerSubscribe(t,new i.SimpleInnerSubscriber(this));!r||r.closed?this.clearThrottle():this.add(this.throttled=r)}},t.prototype.clearThrottle=function(){var e=this.value,t=this.hasValue,r=this.throttled;r&&(this.remove(r),this.throttled=void 0,r.unsubscribe()),t&&(this.value=void 0,this.hasValue=!1,this.destination.next(e))},t.prototype.notifyNext=function(){this.clearThrottle()},t.prototype.notifyComplete=function(){this.clearThrottle()},t}(i.SimpleOuterSubscriber)},643(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7661),o=r(6278),i=r(4888);t.auditTime=function(e,t){return void 0===t&&(t=n.async),o.audit(function(){return i.timer(e,t)})}},4987(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.buffer=function(e){return function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.closingNotifier=e}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.closingNotifier))},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.buffer=[],n.add(i.innerSubscribe(r,new i.SimpleInnerSubscriber(n))),n}return o(t,e),t.prototype._next=function(e){this.buffer.push(e)},t.prototype.notifyNext=function(){var e=this.buffer;this.buffer=[],this.destination.next(e)},t}(i.SimpleOuterSubscriber)},7288(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.bufferCount=function(e,t){return void 0===t&&(t=null),function(r){return r.lift(new a(e,t))}};var a=function(){function e(e,t){this.bufferSize=e,this.startBufferEvery=t,t&&e!==t?this.subscriberClass=s:this.subscriberClass=u}return e.prototype.call=function(e,t){return t.subscribe(new this.subscriberClass(e,this.bufferSize,this.startBufferEvery))},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.bufferSize=r,n.buffer=[],n}return o(t,e),t.prototype._next=function(e){var t=this.buffer;t.push(e),t.length==this.bufferSize&&(this.destination.next(t),this.buffer=[])},t.prototype._complete=function(){var t=this.buffer;t.length>0&&this.destination.next(t),e.prototype._complete.call(this)},t}(i.Subscriber),s=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.bufferSize=r,o.startBufferEvery=n,o.buffers=[],o.count=0,o}return o(t,e),t.prototype._next=function(e){var t=this.bufferSize,r=this.startBufferEvery,n=this.buffers,o=this.count;this.count++,o%r==0&&n.push([]);for(var i=n.length;i--;){var a=n[i];a.push(e),a.length===t&&(n.splice(i,1),this.destination.next(a))}},t.prototype._complete=function(){for(var t=this.buffers,r=this.destination;t.length>0;){var n=t.shift();n.length>0&&r.next(n)}e.prototype._complete.call(this)},t}(i.Subscriber)},9118(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7661),a=r(7097),u=r(9489);t.bufferTime=function(e){var t=arguments.length,r=i.async;u.isScheduler(arguments[arguments.length-1])&&(r=arguments[arguments.length-1],t--);var n=null;t>=2&&(n=arguments[1]);var o=1/0;return t>=3&&(o=arguments[2]),function(t){return t.lift(new s(e,n,o,r))}};var s=function(){function e(e,t,r,n){this.bufferTimeSpan=e,this.bufferCreationInterval=t,this.maxBufferSize=r,this.scheduler=n}return e.prototype.call=function(e,t){return t.subscribe(new c(e,this.bufferTimeSpan,this.bufferCreationInterval,this.maxBufferSize,this.scheduler))},e}(),l=function(){this.buffer=[]},c=function(e){function t(t,r,n,o,i){var a=e.call(this,t)||this;a.bufferTimeSpan=r,a.bufferCreationInterval=n,a.maxBufferSize=o,a.scheduler=i,a.contexts=[];var u=a.openContext();return a.timespanOnly=null==n||n<0,a.timespanOnly?a.add(u.closeAction=i.schedule(d,r,{subscriber:a,context:u,bufferTimeSpan:r})):(a.add(u.closeAction=i.schedule(p,r,{subscriber:a,context:u})),a.add(i.schedule(f,n,{bufferTimeSpan:r,bufferCreationInterval:n,subscriber:a,scheduler:i}))),a}return o(t,e),t.prototype._next=function(e){for(var t,r=this.contexts,n=r.length,o=0;o<n;o++){var i=r[o],a=i.buffer;a.push(e),a.length==this.maxBufferSize&&(t=i)}t&&this.onBufferFull(t)},t.prototype._error=function(t){this.contexts.length=0,e.prototype._error.call(this,t)},t.prototype._complete=function(){for(var t=this.contexts,r=this.destination;t.length>0;){var n=t.shift();r.next(n.buffer)}e.prototype._complete.call(this)},t.prototype._unsubscribe=function(){this.contexts=null},t.prototype.onBufferFull=function(e){this.closeContext(e);var t=e.closeAction;if(t.unsubscribe(),this.remove(t),!this.closed&&this.timespanOnly){e=this.openContext();var r=this.bufferTimeSpan,n={subscriber:this,context:e,bufferTimeSpan:r};this.add(e.closeAction=this.scheduler.schedule(d,r,n))}},t.prototype.openContext=function(){var e=new l;return this.contexts.push(e),e},t.prototype.closeContext=function(e){this.destination.next(e.buffer);var t=this.contexts;(t?t.indexOf(e):-1)>=0&&t.splice(t.indexOf(e),1)},t}(a.Subscriber);function d(e){var t=e.subscriber,r=e.context;r&&t.closeContext(r),t.closed||(e.context=t.openContext(),e.context.closeAction=this.schedule(e,e.bufferTimeSpan))}function f(e){var t=e.bufferCreationInterval,r=e.bufferTimeSpan,n=e.subscriber,o=e.scheduler,i=n.openContext();n.closed||(n.add(i.closeAction=o.schedule(p,r,{subscriber:n,context:i})),this.schedule(e,t))}function p(e){var t=e.subscriber,r=e.context;t.closeContext(r)}},4623(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(1138),a=r(8632),u=r(5238);t.bufferToggle=function(e,t){return function(r){return r.lift(new s(e,t))}};var s=function(){function e(e,t){this.openings=e,this.closingSelector=t}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.openings,this.closingSelector))},e}(),l=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.closingSelector=n,o.contexts=[],o.add(a.subscribeToResult(o,r)),o}return o(t,e),t.prototype._next=function(e){for(var t=this.contexts,r=t.length,n=0;n<r;n++)t[n].buffer.push(e)},t.prototype._error=function(t){for(var r=this.contexts;r.length>0;){var n=r.shift();n.subscription.unsubscribe(),n.buffer=null,n.subscription=null}this.contexts=null,e.prototype._error.call(this,t)},t.prototype._complete=function(){for(var t=this.contexts;t.length>0;){var r=t.shift();this.destination.next(r.buffer),r.subscription.unsubscribe(),r.buffer=null,r.subscription=null}this.contexts=null,e.prototype._complete.call(this)},t.prototype.notifyNext=function(e,t){e?this.closeBuffer(e):this.openBuffer(t)},t.prototype.notifyComplete=function(e){this.closeBuffer(e.context)},t.prototype.openBuffer=function(e){try{var t=this.closingSelector.call(this,e);t&&this.trySubscribe(t)}catch(e){this._error(e)}},t.prototype.closeBuffer=function(e){var t=this.contexts;if(t&&e){var r=e.buffer,n=e.subscription;this.destination.next(r),t.splice(t.indexOf(e),1),this.remove(n),n.unsubscribe()}},t.prototype.trySubscribe=function(e){var t=this.contexts,r=new i.Subscription,n={buffer:[],subscription:r};t.push(n);var o=a.subscribeToResult(this,e,n);!o||o.closed?this.closeBuffer(n):(o.context=n,this.add(o),r.add(o))},t}(u.OuterSubscriber)},2771(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(1138),a=r(8255);t.bufferWhen=function(e){return function(t){return t.lift(new u(e))}};var u=function(){function e(e){this.closingSelector=e}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.closingSelector))},e}(),s=function(e){function t(t,r){var n=e.call(this,t)||this;return n.closingSelector=r,n.subscribing=!1,n.openBuffer(),n}return o(t,e),t.prototype._next=function(e){this.buffer.push(e)},t.prototype._complete=function(){var t=this.buffer;t&&this.destination.next(t),e.prototype._complete.call(this)},t.prototype._unsubscribe=function(){this.buffer=void 0,this.subscribing=!1},t.prototype.notifyNext=function(){this.openBuffer()},t.prototype.notifyComplete=function(){this.subscribing?this.complete():this.openBuffer()},t.prototype.openBuffer=function(){var e,t=this.closingSubscription;t&&(this.remove(t),t.unsubscribe());var r=this.buffer;this.buffer&&this.destination.next(r),this.buffer=[];try{e=(0,this.closingSelector)()}catch(e){return this.error(e)}t=new i.Subscription,this.closingSubscription=t,this.add(t),this.subscribing=!0,t.add(a.innerSubscribe(e,new a.SimpleInnerSubscriber(this))),this.subscribing=!1},t}(a.SimpleOuterSubscriber)},7610(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.catchError=function(e){return function(t){var r=new a(e),n=t.lift(r);return r.caught=n}};var a=function(){function e(e){this.selector=e}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.selector,this.caught))},e}(),u=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.selector=r,o.caught=n,o}return o(t,e),t.prototype.error=function(t){if(!this.isStopped){var r=void 0;try{r=this.selector(t,this.caught)}catch(t){e.prototype.error.call(this,t);return}this._unsubscribeAndRecycle();var n=new i.SimpleInnerSubscriber(this);this.add(n);var o=i.innerSubscribe(r,n);o!==n&&this.add(o)}},t}(i.SimpleOuterSubscriber)},3101(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2115);t.combineAll=function(e){return function(t){return t.lift(new n.CombineLatestOperator(e))}}},6923(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9109),o=r(2115),i=r(9001);t.combineLatest=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=null;return"function"==typeof e[e.length-1]&&(r=e.pop()),1===e.length&&n.isArray(e[0])&&(e=e[0].slice()),function(t){return t.lift.call(i.from([t].concat(e)),new o.CombineLatestOperator(r))}}},325(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(8093);t.concat=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){return t.lift.call(n.concat.apply(void 0,[t].concat(e)))}}},7930(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(8914);t.concatAll=function(){return n.mergeAll(1)}},9091(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(5643);t.concatMap=function(e,t){return n.mergeMap(e,t,1)}},2710(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9091);t.concatMapTo=function(e,t){return n.concatMap(function(){return e},t)}},8786(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.count=function(e){return function(t){return t.lift(new a(e,t))}};var a=function(){function e(e,t){this.predicate=e,this.source=t}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.predicate,this.source))},e}(),u=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.predicate=r,o.source=n,o.count=0,o.index=0,o}return o(t,e),t.prototype._next=function(e){this.predicate?this._tryPredicate(e):this.count++},t.prototype._tryPredicate=function(e){var t;try{t=this.predicate(e,this.index++,this.source)}catch(e){this.destination.error(e);return}t&&this.count++},t.prototype._complete=function(){this.destination.next(this.count),this.destination.complete()},t}(i.Subscriber)},8966(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.debounce=function(e){return function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.durationSelector=e}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.durationSelector))},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.durationSelector=r,n.hasValue=!1,n}return o(t,e),t.prototype._next=function(e){try{var t=this.durationSelector.call(this,e);t&&this._tryNext(e,t)}catch(e){this.destination.error(e)}},t.prototype._complete=function(){this.emitValue(),this.destination.complete()},t.prototype._tryNext=function(e,t){var r=this.durationSubscription;this.value=e,this.hasValue=!0,r&&(r.unsubscribe(),this.remove(r)),(r=i.innerSubscribe(t,new i.SimpleInnerSubscriber(this)))&&!r.closed&&this.add(this.durationSubscription=r)},t.prototype.notifyNext=function(){this.emitValue()},t.prototype.notifyComplete=function(){this.emitValue()},t.prototype.emitValue=function(){if(this.hasValue){var t=this.value,r=this.durationSubscription;r&&(this.durationSubscription=void 0,r.unsubscribe(),this.remove(r)),this.value=void 0,this.hasValue=!1,e.prototype._next.call(this,t)}},t}(i.SimpleOuterSubscriber)},8387(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(7661);t.debounceTime=function(e,t){return void 0===t&&(t=a.async),function(r){return r.lift(new u(e,t))}};var u=function(){function e(e,t){this.dueTime=e,this.scheduler=t}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.dueTime,this.scheduler))},e}(),s=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.dueTime=r,o.scheduler=n,o.debouncedSubscription=null,o.lastValue=null,o.hasValue=!1,o}return o(t,e),t.prototype._next=function(e){this.clearDebounce(),this.lastValue=e,this.hasValue=!0,this.add(this.debouncedSubscription=this.scheduler.schedule(l,this.dueTime,this))},t.prototype._complete=function(){this.debouncedNext(),this.destination.complete()},t.prototype.debouncedNext=function(){if(this.clearDebounce(),this.hasValue){var e=this.lastValue;this.lastValue=null,this.hasValue=!1,this.destination.next(e)}},t.prototype.clearDebounce=function(){var e=this.debouncedSubscription;null!==e&&(this.remove(e),e.unsubscribe(),this.debouncedSubscription=null)},t}(i.Subscriber);function l(e){e.debouncedNext()}},1974(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.defaultIfEmpty=function(e){return void 0===e&&(e=null),function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.defaultValue=e}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.defaultValue))},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.defaultValue=r,n.isEmpty=!0,n}return o(t,e),t.prototype._next=function(e){this.isEmpty=!1,this.destination.next(e)},t.prototype._complete=function(){this.isEmpty&&this.destination.next(this.defaultValue),this.destination.complete()},t}(i.Subscriber)},926(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7661),a=r(8710),u=r(7097),s=r(8292);t.delay=function(e,t){void 0===t&&(t=i.async);var r=a.isDate(e)?e-t.now():Math.abs(e);return function(e){return e.lift(new l(r,t))}};var l=function(){function e(e,t){this.delay=e,this.scheduler=t}return e.prototype.call=function(e,t){return t.subscribe(new c(e,this.delay,this.scheduler))},e}(),c=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.delay=r,o.scheduler=n,o.queue=[],o.active=!1,o.errored=!1,o}return o(t,e),t.dispatch=function(e){for(var t=e.source,r=t.queue,n=e.scheduler,o=e.destination;r.length>0&&r[0].time-n.now()<=0;)r.shift().notification.observe(o);if(r.length>0){var i=Math.max(0,r[0].time-n.now());this.schedule(e,i)}else this.unsubscribe(),t.active=!1},t.prototype._schedule=function(e){this.active=!0,this.destination.add(e.schedule(t.dispatch,this.delay,{source:this,destination:this.destination,scheduler:e}))},t.prototype.scheduleNotification=function(e){if(!0!==this.errored){var t=this.scheduler,r=new d(t.now()+this.delay,e);this.queue.push(r),!1===this.active&&this._schedule(t)}},t.prototype._next=function(e){this.scheduleNotification(s.Notification.createNext(e))},t.prototype._error=function(e){this.errored=!0,this.queue=[],this.destination.error(e),this.unsubscribe()},t.prototype._complete=function(){this.scheduleNotification(s.Notification.createComplete()),this.unsubscribe()},t}(u.Subscriber),d=function(e,t){this.time=e,this.notification=t}},1058(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(7154),u=r(5238),s=r(8632);t.delayWhen=function(e,t){return t?function(r){return new d(r,t).lift(new l(e))}:function(t){return t.lift(new l(e))}};var l=function(){function e(e){this.delayDurationSelector=e}return e.prototype.call=function(e,t){return t.subscribe(new c(e,this.delayDurationSelector))},e}(),c=function(e){function t(t,r){var n=e.call(this,t)||this;return n.delayDurationSelector=r,n.completed=!1,n.delayNotifierSubscriptions=[],n.index=0,n}return o(t,e),t.prototype.notifyNext=function(e,t,r,n,o){this.destination.next(e),this.removeSubscription(o),this.tryComplete()},t.prototype.notifyError=function(e,t){this._error(e)},t.prototype.notifyComplete=function(e){var t=this.removeSubscription(e);t&&this.destination.next(t),this.tryComplete()},t.prototype._next=function(e){var t=this.index++;try{var r=this.delayDurationSelector(e,t);r&&this.tryDelay(r,e)}catch(e){this.destination.error(e)}},t.prototype._complete=function(){this.completed=!0,this.tryComplete(),this.unsubscribe()},t.prototype.removeSubscription=function(e){e.unsubscribe();var t=this.delayNotifierSubscriptions.indexOf(e);return -1!==t&&this.delayNotifierSubscriptions.splice(t,1),e.outerValue},t.prototype.tryDelay=function(e,t){var r=s.subscribeToResult(this,e,t);r&&!r.closed&&(this.destination.add(r),this.delayNotifierSubscriptions.push(r))},t.prototype.tryComplete=function(){this.completed&&0===this.delayNotifierSubscriptions.length&&this.destination.complete()},t}(u.OuterSubscriber),d=function(e){function t(t,r){var n=e.call(this)||this;return n.source=t,n.subscriptionDelay=r,n}return o(t,e),t.prototype._subscribe=function(e){this.subscriptionDelay.subscribe(new f(e,this.source))},t}(a.Observable),f=function(e){function t(t,r){var n=e.call(this)||this;return n.parent=t,n.source=r,n.sourceSubscribed=!1,n}return o(t,e),t.prototype._next=function(e){this.subscribeToSource()},t.prototype._error=function(e){this.unsubscribe(),this.parent.error(e)},t.prototype._complete=function(){this.unsubscribe(),this.subscribeToSource()},t.prototype.subscribeToSource=function(){this.sourceSubscribed||(this.sourceSubscribed=!0,this.unsubscribe(),this.source.subscribe(this.parent))},t}(i.Subscriber)},2045(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.dematerialize=function(){return function(e){return e.lift(new a)}};var a=function(){function e(){}return e.prototype.call=function(e,t){return t.subscribe(new u(e))},e}(),u=function(e){function t(t){return e.call(this,t)||this}return o(t,e),t.prototype._next=function(e){e.observe(this.destination)},t}(i.Subscriber)},6961(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.distinct=function(e,t){return function(r){return r.lift(new a(e,t))}};var a=function(){function e(e,t){this.keySelector=e,this.flushes=t}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.keySelector,this.flushes))},e}(),u=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.keySelector=r,o.values=new Set,n&&o.add(i.innerSubscribe(n,new i.SimpleInnerSubscriber(o))),o}return o(t,e),t.prototype.notifyNext=function(){this.values.clear()},t.prototype.notifyError=function(e){this._error(e)},t.prototype._next=function(e){this.keySelector?this._useKeySelector(e):this._finalizeNext(e,e)},t.prototype._useKeySelector=function(e){var t,r=this.destination;try{t=this.keySelector(e)}catch(e){r.error(e);return}this._finalizeNext(t,e)},t.prototype._finalizeNext=function(e,t){var r=this.values;r.has(e)||(r.add(e),this.destination.next(t))},t}(i.SimpleOuterSubscriber);t.DistinctSubscriber=u},6693(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.distinctUntilChanged=function(e,t){return function(r){return r.lift(new a(e,t))}};var a=function(){function e(e,t){this.compare=e,this.keySelector=t}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.compare,this.keySelector))},e}(),u=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.keySelector=n,o.hasKey=!1,"function"==typeof r&&(o.compare=r),o}return o(t,e),t.prototype.compare=function(e,t){return e===t},t.prototype._next=function(e){try{var t,r=this.keySelector;t=r?r(e):e}catch(e){return this.destination.error(e)}var n=!1;if(this.hasKey)try{n=(0,this.compare)(this.key,t)}catch(e){return this.destination.error(e)}else this.hasKey=!0;n||(this.key=t,this.destination.next(e))},t}(i.Subscriber)},2296(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(6693);t.distinctUntilKeyChanged=function(e,t){return n.distinctUntilChanged(function(r,n){return t?t(r[e],n[e]):r[e]===n[e]})}},8876(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2021),o=r(7851),i=r(8777),a=r(1974),u=r(5450);t.elementAt=function(e,t){if(e<0)throw new n.ArgumentOutOfRangeError;var r=arguments.length>=2;return function(s){return s.pipe(o.filter(function(t,r){return r===e}),u.take(1),r?a.defaultIfEmpty(t):i.throwIfEmpty(function(){return new n.ArgumentOutOfRangeError}))}}},1148(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(8093),o=r(2200);t.endWith=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){return n.concat(t,o.of.apply(void 0,e))}}},4434(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.every=function(e,t){return function(r){return r.lift(new a(e,t,r))}};var a=function(){function e(e,t,r){this.predicate=e,this.thisArg=t,this.source=r}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.predicate,this.thisArg,this.source))},e}(),u=function(e){function t(t,r,n,o){var i=e.call(this,t)||this;return i.predicate=r,i.thisArg=n,i.source=o,i.index=0,i.thisArg=n||i,i}return o(t,e),t.prototype.notifyComplete=function(e){this.destination.next(e),this.destination.complete()},t.prototype._next=function(e){var t=!1;try{t=this.predicate.call(this.thisArg,e,this.index++,this.source)}catch(e){this.destination.error(e);return}t||this.notifyComplete(!1)},t.prototype._complete=function(){this.notifyComplete(!0)},t}(i.Subscriber)},8811(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.exhaust=function(){return function(e){return e.lift(new a)}};var a=function(){function e(){}return e.prototype.call=function(e,t){return t.subscribe(new u(e))},e}(),u=function(e){function t(t){var r=e.call(this,t)||this;return r.hasCompleted=!1,r.hasSubscription=!1,r}return o(t,e),t.prototype._next=function(e){this.hasSubscription||(this.hasSubscription=!0,this.add(i.innerSubscribe(e,new i.SimpleInnerSubscriber(this))))},t.prototype._complete=function(){this.hasCompleted=!0,this.hasSubscription||this.destination.complete()},t.prototype.notifyComplete=function(){this.hasSubscription=!1,this.hasCompleted&&this.destination.complete()},t}(i.SimpleOuterSubscriber)},2429(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(2827),a=r(9001),u=r(8255);t.exhaustMap=function e(t,r){return r?function(n){return n.pipe(e(function(e,n){return a.from(t(e,n)).pipe(i.map(function(t,o){return r(e,t,n,o)}))}))}:function(e){return e.lift(new s(t))}};var s=function(){function e(e){this.project=e}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.project))},e}(),l=function(e){function t(t,r){var n=e.call(this,t)||this;return n.project=r,n.hasSubscription=!1,n.hasCompleted=!1,n.index=0,n}return o(t,e),t.prototype._next=function(e){this.hasSubscription||this.tryNext(e)},t.prototype.tryNext=function(e){var t,r=this.index++;try{t=this.project(e,r)}catch(e){this.destination.error(e);return}this.hasSubscription=!0,this._innerSub(t)},t.prototype._innerSub=function(e){var t=new u.SimpleInnerSubscriber(this),r=this.destination;r.add(t);var n=u.innerSubscribe(e,t);n!==t&&r.add(n)},t.prototype._complete=function(){this.hasCompleted=!0,this.hasSubscription||this.destination.complete(),this.unsubscribe()},t.prototype.notifyNext=function(e){this.destination.next(e)},t.prototype.notifyError=function(e){this.destination.error(e)},t.prototype.notifyComplete=function(){this.hasSubscription=!1,this.hasCompleted&&this.destination.complete()},t}(u.SimpleOuterSubscriber)},9790(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.expand=function(e,t,r){return void 0===t&&(t=1/0),t=1>(t||0)?1/0:t,function(n){return n.lift(new a(e,t,r))}};var a=function(){function e(e,t,r){this.project=e,this.concurrent=t,this.scheduler=r}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.project,this.concurrent,this.scheduler))},e}();t.ExpandOperator=a;var u=function(e){function t(t,r,n,o){var i=e.call(this,t)||this;return i.project=r,i.concurrent=n,i.scheduler=o,i.index=0,i.active=0,i.hasCompleted=!1,n<1/0&&(i.buffer=[]),i}return o(t,e),t.dispatch=function(e){var t=e.subscriber,r=e.result,n=e.value,o=e.index;t.subscribeToProjection(r,n,o)},t.prototype._next=function(e){var r=this.destination;if(r.closed)return void this._complete();var n=this.index++;if(this.active<this.concurrent){r.next(e);try{var o=(0,this.project)(e,n);this.scheduler?this.destination.add(this.scheduler.schedule(t.dispatch,0,{subscriber:this,result:o,value:e,index:n})):this.subscribeToProjection(o,e,n)}catch(e){r.error(e)}}else this.buffer.push(e)},t.prototype.subscribeToProjection=function(e,t,r){this.active++,this.destination.add(i.innerSubscribe(e,new i.SimpleInnerSubscriber(this)))},t.prototype._complete=function(){this.hasCompleted=!0,this.hasCompleted&&0===this.active&&this.destination.complete(),this.unsubscribe()},t.prototype.notifyNext=function(e){this._next(e)},t.prototype.notifyComplete=function(){var e=this.buffer;this.active--,e&&e.length>0&&this._next(e.shift()),this.hasCompleted&&0===this.active&&this.destination.complete()},t}(i.SimpleOuterSubscriber);t.ExpandSubscriber=u},7851(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.filter=function(e,t){return function(r){return r.lift(new a(e,t))}};var a=function(){function e(e,t){this.predicate=e,this.thisArg=t}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.predicate,this.thisArg))},e}(),u=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.predicate=r,o.thisArg=n,o.count=0,o}return o(t,e),t.prototype._next=function(e){var t;try{t=this.predicate.call(this.thisArg,e,this.count++)}catch(e){this.destination.error(e);return}t&&this.destination.next(e)},t}(i.Subscriber)},7183(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(1138);t.finalize=function(e){return function(t){return t.lift(new u(e))}};var u=function(){function e(e){this.callback=e}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.callback))},e}(),s=function(e){function t(t,r){var n=e.call(this,t)||this;return n.add(new a.Subscription(r)),n}return o(t,e),t}(i.Subscriber)},8054(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.find=function(e,t){if("function"!=typeof e)throw TypeError("predicate is not a function");return function(r){return r.lift(new a(e,r,!1,t))}};var a=function(){function e(e,t,r,n){this.predicate=e,this.source=t,this.yieldIndex=r,this.thisArg=n}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.predicate,this.source,this.yieldIndex,this.thisArg))},e}();t.FindValueOperator=a;var u=function(e){function t(t,r,n,o,i){var a=e.call(this,t)||this;return a.predicate=r,a.source=n,a.yieldIndex=o,a.thisArg=i,a.index=0,a}return o(t,e),t.prototype.notifyComplete=function(e){var t=this.destination;t.next(e),t.complete(),this.unsubscribe()},t.prototype._next=function(e){var t=this.predicate,r=this.thisArg,n=this.index++;try{t.call(r||this,e,n,this.source)&&this.notifyComplete(this.yieldIndex?n:e)}catch(e){this.destination.error(e)}},t.prototype._complete=function(){this.notifyComplete(this.yieldIndex?-1:void 0)},t}(i.Subscriber);t.FindValueSubscriber=u},384(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(8054);t.findIndex=function(e,t){return function(r){return r.lift(new n.FindValueOperator(e,r,!0,t))}}},8663(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2747),o=r(7851),i=r(5450),a=r(1974),u=r(8777),s=r(9156);t.first=function(e,t){var r=arguments.length>=2;return function(l){return l.pipe(e?o.filter(function(t,r){return e(t,r,l)}):s.identity,i.take(1),r?a.defaultIfEmpty(t):u.throwIfEmpty(function(){return new n.EmptyError}))}}},6659(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(1138),u=r(7154),s=r(7127);t.groupBy=function(e,t,r,n){return function(o){return o.lift(new l(e,t,r,n))}};var l=function(){function e(e,t,r,n){this.keySelector=e,this.elementSelector=t,this.durationSelector=r,this.subjectSelector=n}return e.prototype.call=function(e,t){return t.subscribe(new c(e,this.keySelector,this.elementSelector,this.durationSelector,this.subjectSelector))},e}(),c=function(e){function t(t,r,n,o,i){var a=e.call(this,t)||this;return a.keySelector=r,a.elementSelector=n,a.durationSelector=o,a.subjectSelector=i,a.groups=null,a.attemptedToUnsubscribe=!1,a.count=0,a}return o(t,e),t.prototype._next=function(e){var t;try{t=this.keySelector(e)}catch(e){this.error(e);return}this._group(e,t)},t.prototype._group=function(e,t){var r,n=this.groups;n||(n=this.groups=new Map);var o=n.get(t);if(this.elementSelector)try{r=this.elementSelector(e)}catch(e){this.error(e)}else r=e;if(!o){o=this.subjectSelector?this.subjectSelector():new s.Subject,n.set(t,o);var i=new f(t,o,this);if(this.destination.next(i),this.durationSelector){var a=void 0;try{a=this.durationSelector(new f(t,o))}catch(e){this.error(e);return}this.add(a.subscribe(new d(t,o,this)))}}o.closed||o.next(r)},t.prototype._error=function(e){var t=this.groups;t&&(t.forEach(function(t,r){t.error(e)}),t.clear()),this.destination.error(e)},t.prototype._complete=function(){var e=this.groups;e&&(e.forEach(function(e,t){e.complete()}),e.clear()),this.destination.complete()},t.prototype.removeGroup=function(e){this.groups.delete(e)},t.prototype.unsubscribe=function(){this.closed||(this.attemptedToUnsubscribe=!0,0===this.count&&e.prototype.unsubscribe.call(this))},t}(i.Subscriber),d=function(e){function t(t,r,n){var o=e.call(this,r)||this;return o.key=t,o.group=r,o.parent=n,o}return o(t,e),t.prototype._next=function(e){this.complete()},t.prototype._unsubscribe=function(){var e=this.parent,t=this.key;this.key=this.parent=null,e&&e.removeGroup(t)},t}(i.Subscriber),f=function(e){function t(t,r,n){var o=e.call(this)||this;return o.key=t,o.groupSubject=r,o.refCountSubscription=n,o}return o(t,e),t.prototype._subscribe=function(e){var t=new a.Subscription,r=this.refCountSubscription,n=this.groupSubject;return r&&!r.closed&&t.add(new p(r)),t.add(n.subscribe(e)),t},t}(u.Observable);t.GroupedObservable=f;var p=function(e){function t(t){var r=e.call(this)||this;return r.parent=t,t.count++,r}return o(t,e),t.prototype.unsubscribe=function(){var t=this.parent;t.closed||this.closed||(e.prototype.unsubscribe.call(this),t.count-=1,0===t.count&&t.attemptedToUnsubscribe&&t.unsubscribe())},t}(a.Subscription)},6494(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.ignoreElements=function(){return function(e){return e.lift(new a)}};var a=function(){function e(){}return e.prototype.call=function(e,t){return t.subscribe(new u(e))},e}(),u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype._next=function(e){},t}(i.Subscriber)},7240(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.isEmpty=function(){return function(e){return e.lift(new a)}};var a=function(){function e(){}return e.prototype.call=function(e,t){return t.subscribe(new u(e))},e}(),u=function(e){function t(t){return e.call(this,t)||this}return o(t,e),t.prototype.notifyComplete=function(e){var t=this.destination;t.next(e),t.complete()},t.prototype._next=function(e){this.notifyComplete(!1)},t.prototype._complete=function(){this.notifyComplete(!0)},t}(i.Subscriber)},7801(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2747),o=r(7851),i=r(950),a=r(8777),u=r(1974),s=r(9156);t.last=function(e,t){var r=arguments.length>=2;return function(l){return l.pipe(e?o.filter(function(t,r){return e(t,r,l)}):s.identity,i.takeLast(1),r?u.defaultIfEmpty(t):a.throwIfEmpty(function(){return new n.EmptyError}))}}},2827(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.map=function(e,t){return function(r){if("function"!=typeof e)throw TypeError("argument is not a function. Are you looking for `mapTo()`?");return r.lift(new a(e,t))}};var a=function(){function e(e,t){this.project=e,this.thisArg=t}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.project,this.thisArg))},e}();t.MapOperator=a;var u=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.project=r,o.count=0,o.thisArg=n||o,o}return o(t,e),t.prototype._next=function(e){var t;try{t=this.project.call(this.thisArg,e,this.count++)}catch(e){this.destination.error(e);return}this.destination.next(t)},t}(i.Subscriber)},4078(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.mapTo=function(e){return function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.value=e}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.value))},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.value=r,n}return o(t,e),t.prototype._next=function(e){this.destination.next(this.value)},t}(i.Subscriber)},5604(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(8292);t.materialize=function(){return function(e){return e.lift(new u)}};var u=function(){function e(){}return e.prototype.call=function(e,t){return t.subscribe(new s(e))},e}(),s=function(e){function t(t){return e.call(this,t)||this}return o(t,e),t.prototype._next=function(e){this.destination.next(a.Notification.createNext(e))},t.prototype._error=function(e){var t=this.destination;t.next(a.Notification.createError(e)),t.complete()},t.prototype._complete=function(){var e=this.destination;e.next(a.Notification.createComplete()),e.complete()},t}(i.Subscriber)},5699(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7103);t.max=function(e){return n.reduce("function"==typeof e?function(t,r){return e(t,r)>0?t:r}:function(e,t){return e>t?e:t})}},5709(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1861);t.merge=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){return t.lift.call(n.merge.apply(void 0,[t].concat(e)))}}},8914(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(5643),o=r(9156);t.mergeAll=function(e){return void 0===e&&(e=1/0),n.mergeMap(o.identity,e)}},5643(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(2827),a=r(9001),u=r(8255);function s(e,t,r){return(void 0===r&&(r=1/0),"function"==typeof t)?function(n){return n.pipe(s(function(r,n){return a.from(e(r,n)).pipe(i.map(function(e,o){return t(r,e,n,o)}))},r))}:("number"==typeof t&&(r=t),function(t){return t.lift(new l(e,r))})}t.mergeMap=s;var l=function(){function e(e,t){void 0===t&&(t=1/0),this.project=e,this.concurrent=t}return e.prototype.call=function(e,t){return t.subscribe(new c(e,this.project,this.concurrent))},e}();t.MergeMapOperator=l;var c=function(e){function t(t,r,n){void 0===n&&(n=1/0);var o=e.call(this,t)||this;return o.project=r,o.concurrent=n,o.hasCompleted=!1,o.buffer=[],o.active=0,o.index=0,o}return o(t,e),t.prototype._next=function(e){this.active<this.concurrent?this._tryNext(e):this.buffer.push(e)},t.prototype._tryNext=function(e){var t,r=this.index++;try{t=this.project(e,r)}catch(e){this.destination.error(e);return}this.active++,this._innerSub(t)},t.prototype._innerSub=function(e){var t=new u.SimpleInnerSubscriber(this),r=this.destination;r.add(t);var n=u.innerSubscribe(e,t);n!==t&&r.add(n)},t.prototype._complete=function(){this.hasCompleted=!0,0===this.active&&0===this.buffer.length&&this.destination.complete(),this.unsubscribe()},t.prototype.notifyNext=function(e){this.destination.next(e)},t.prototype.notifyComplete=function(){var e=this.buffer;this.active--,e.length>0?this._next(e.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()},t}(u.SimpleOuterSubscriber);t.MergeMapSubscriber=c,t.flatMap=s},5006(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(5643);t.mergeMapTo=function(e,t,r){return(void 0===r&&(r=1/0),"function"==typeof t)?n.mergeMap(function(){return e},t,r):("number"==typeof t&&(r=t),n.mergeMap(function(){return e},r))}},7924(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.mergeScan=function(e,t,r){return void 0===r&&(r=1/0),function(n){return n.lift(new a(e,t,r))}};var a=function(){function e(e,t,r){this.accumulator=e,this.seed=t,this.concurrent=r}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.accumulator,this.seed,this.concurrent))},e}();t.MergeScanOperator=a;var u=function(e){function t(t,r,n,o){var i=e.call(this,t)||this;return i.accumulator=r,i.acc=n,i.concurrent=o,i.hasValue=!1,i.hasCompleted=!1,i.buffer=[],i.active=0,i.index=0,i}return o(t,e),t.prototype._next=function(e){if(this.active<this.concurrent){var t=this.index++,r=this.destination,n=void 0;try{n=(0,this.accumulator)(this.acc,e,t)}catch(e){return r.error(e)}this.active++,this._innerSub(n)}else this.buffer.push(e)},t.prototype._innerSub=function(e){var t=new i.SimpleInnerSubscriber(this),r=this.destination;r.add(t);var n=i.innerSubscribe(e,t);n!==t&&r.add(n)},t.prototype._complete=function(){this.hasCompleted=!0,0===this.active&&0===this.buffer.length&&(!1===this.hasValue&&this.destination.next(this.acc),this.destination.complete()),this.unsubscribe()},t.prototype.notifyNext=function(e){var t=this.destination;this.acc=e,this.hasValue=!0,t.next(e)},t.prototype.notifyComplete=function(){var e=this.buffer;this.active--,e.length>0?this._next(e.shift()):0===this.active&&this.hasCompleted&&(!1===this.hasValue&&this.destination.next(this.acc),this.destination.complete())},t}(i.SimpleOuterSubscriber);t.MergeScanSubscriber=u},4049(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7103);t.min=function(e){return n.reduce("function"==typeof e?function(t,r){return 0>e(t,r)?t:r}:function(e,t){return e<t?e:t})}},6683(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9226);t.multicast=function(e,t){return function(r){if(i="function"==typeof e?e:function(){return e},"function"==typeof t)return r.lift(new o(i,t));var i,a=Object.create(r,n.connectableObservableDescriptor);return a.source=r,a.subjectFactory=i,a}};var o=function(){function e(e,t){this.subjectFactory=e,this.selector=t}return e.prototype.call=function(e,t){var r=this.selector,n=this.subjectFactory(),o=r(n).subscribe(e);return o.add(t.subscribe(n)),o},e}();t.MulticastOperator=o},4436(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(8292);t.observeOn=function(e,t){return void 0===t&&(t=0),function(r){return r.lift(new u(e,t))}};var u=function(){function e(e,t){void 0===t&&(t=0),this.scheduler=e,this.delay=t}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.scheduler,this.delay))},e}();t.ObserveOnOperator=u;var s=function(e){function t(t,r,n){void 0===n&&(n=0);var o=e.call(this,t)||this;return o.scheduler=r,o.delay=n,o}return o(t,e),t.dispatch=function(e){var t=e.notification,r=e.destination;t.observe(r),this.unsubscribe()},t.prototype.scheduleMessage=function(e){this.destination.add(this.scheduler.schedule(t.dispatch,this.delay,new l(e,this.destination)))},t.prototype._next=function(e){this.scheduleMessage(a.Notification.createNext(e))},t.prototype._error=function(e){this.scheduleMessage(a.Notification.createError(e)),this.unsubscribe()},t.prototype._complete=function(){this.scheduleMessage(a.Notification.createComplete()),this.unsubscribe()},t}(i.Subscriber);t.ObserveOnSubscriber=s;var l=function(e,t){this.notification=e,this.destination=t};t.ObserveOnMessage=l},4058(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(9001),a=r(9109),u=r(8255);t.onErrorResumeNext=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return 1===e.length&&a.isArray(e[0])&&(e=e[0]),function(t){return t.lift(new s(e))}},t.onErrorResumeNextStatic=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=void 0;return 1===e.length&&a.isArray(e[0])&&(e=e[0]),r=e.shift(),i.from(r).lift(new s(e))};var s=function(){function e(e){this.nextSources=e}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.nextSources))},e}(),l=function(e){function t(t,r){var n=e.call(this,t)||this;return n.destination=t,n.nextSources=r,n}return o(t,e),t.prototype.notifyError=function(){this.subscribeToNextSource()},t.prototype.notifyComplete=function(){this.subscribeToNextSource()},t.prototype._error=function(e){this.subscribeToNextSource(),this.unsubscribe()},t.prototype._complete=function(){this.subscribeToNextSource(),this.unsubscribe()},t.prototype.subscribeToNextSource=function(){var e=this.nextSources.shift();if(e){var t=new u.SimpleInnerSubscriber(this),r=this.destination;r.add(t);var n=u.innerSubscribe(e,t);n!==t&&r.add(n)}else this.destination.complete()},t}(u.SimpleOuterSubscriber)},4253(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.pairwise=function(){return function(e){return e.lift(new a)}};var a=function(){function e(){}return e.prototype.call=function(e,t){return t.subscribe(new u(e))},e}(),u=function(e){function t(t){var r=e.call(this,t)||this;return r.hasPrev=!1,r}return o(t,e),t.prototype._next=function(e){var t;this.hasPrev?t=[this.prev,e]:this.hasPrev=!0,this.prev=e,t&&this.destination.next(t)},t}(i.Subscriber)},4255(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1985),o=r(7851);t.partition=function(e,t){return function(r){return[o.filter(e,t)(r),o.filter(n.not(e,t))(r)]}}},8356(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2827);t.pluck=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=e.length;if(0===r)throw Error("list of properties cannot be empty.");return function(t){var o,i;return n.map((o=e,i=r,function(e){for(var t=e,r=0;r<i;r++){var n=null!=t?t[o[r]]:void 0;if(void 0===n)return;t=n}return t}))(t)}}},626(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7127),o=r(6683);t.publish=function(e){return e?o.multicast(function(){return new n.Subject},e):o.multicast(new n.Subject)}},6880(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9553),o=r(6683);t.publishBehavior=function(e){return function(t){return o.multicast(new n.BehaviorSubject(e))(t)}}},2158(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(4131),o=r(6683);t.publishLast=function(){return function(e){return o.multicast(new n.AsyncSubject)(e)}}},2337(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2462),o=r(6683);t.publishReplay=function(e,t,r,i){r&&"function"!=typeof r&&(i=r);var a="function"==typeof r?r:void 0,u=new n.ReplaySubject(e,t,i);return function(e){return o.multicast(function(){return u},a)(e)}}},1596(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9109),o=r(2964);t.race=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){return 1===e.length&&n.isArray(e[0])&&(e=e[0]),t.lift.call(o.race.apply(void 0,[t].concat(e)))}}},7103(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(740),o=r(950),i=r(1974),a=r(7654);t.reduce=function(e,t){return arguments.length>=2?function(r){return a.pipe(n.scan(e,t),o.takeLast(1),i.defaultIfEmpty(t))(r)}:function(t){return a.pipe(n.scan(function(t,r,n){return e(t,r,n+1)}),o.takeLast(1))(t)}}},9509(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.refCount=function(){return function(e){return e.lift(new a(e))}};var a=function(){function e(e){this.connectable=e}return e.prototype.call=function(e,t){var r=this.connectable;r._refCount++;var n=new u(e,r),o=t.subscribe(n);return n.closed||(n.connection=r.connect()),o},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.connectable=r,n}return o(t,e),t.prototype._unsubscribe=function(){var e=this.connectable;if(!e){this.connection=null;return}this.connectable=null;var t=e._refCount;if(t<=0||(e._refCount=t-1,t>1)){this.connection=null;return}var r=this.connection,n=e._connection;this.connection=null,n&&(!r||n===r)&&n.unsubscribe()},t}(i.Subscriber)},1198(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(1684);t.repeat=function(e){return void 0===e&&(e=-1),function(t){return 0===e?a.empty():e<0?t.lift(new u(-1,t)):t.lift(new u(e-1,t))}};var u=function(){function e(e,t){this.count=e,this.source=t}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.count,this.source))},e}(),s=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.count=r,o.source=n,o}return o(t,e),t.prototype.complete=function(){if(!this.isStopped){var t=this.source,r=this.count;if(0===r)return e.prototype.complete.call(this);r>-1&&(this.count=r-1),t.subscribe(this._unsubscribeAndRecycle())}},t}(i.Subscriber)},130(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7127),a=r(8255);t.repeatWhen=function(e){return function(t){return t.lift(new u(e))}};var u=function(){function e(e){this.notifier=e}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.notifier,t))},e}(),s=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.notifier=r,o.source=n,o.sourceIsBeingSubscribedTo=!0,o}return o(t,e),t.prototype.notifyNext=function(){this.sourceIsBeingSubscribedTo=!0,this.source.subscribe(this)},t.prototype.notifyComplete=function(){if(!1===this.sourceIsBeingSubscribedTo)return e.prototype.complete.call(this)},t.prototype.complete=function(){if(this.sourceIsBeingSubscribedTo=!1,!this.isStopped){if(this.retries||this.subscribeToRetries(),!this.retriesSubscription||this.retriesSubscription.closed)return e.prototype.complete.call(this);this._unsubscribeAndRecycle(),this.notifications.next(void 0)}},t.prototype._unsubscribe=function(){var e=this.notifications,t=this.retriesSubscription;e&&(e.unsubscribe(),this.notifications=void 0),t&&(t.unsubscribe(),this.retriesSubscription=void 0),this.retries=void 0},t.prototype._unsubscribeAndRecycle=function(){var t=this._unsubscribe;return this._unsubscribe=null,e.prototype._unsubscribeAndRecycle.call(this),this._unsubscribe=t,this},t.prototype.subscribeToRetries=function(){this.notifications=new i.Subject;try{var t;t=(0,this.notifier)(this.notifications)}catch(t){return e.prototype.complete.call(this)}this.retries=t,this.retriesSubscription=a.innerSubscribe(t,new a.SimpleInnerSubscriber(this))},t}(a.SimpleOuterSubscriber)},4607(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.retry=function(e){return void 0===e&&(e=-1),function(t){return t.lift(new a(e,t))}};var a=function(){function e(e,t){this.count=e,this.source=t}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.count,this.source))},e}(),u=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.count=r,o.source=n,o}return o(t,e),t.prototype.error=function(t){if(!this.isStopped){var r=this.source,n=this.count;if(0===n)return e.prototype.error.call(this,t);n>-1&&(this.count=n-1),r.subscribe(this._unsubscribeAndRecycle())}},t}(i.Subscriber)},6351(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7127),a=r(8255);t.retryWhen=function(e){return function(t){return t.lift(new u(e,t))}};var u=function(){function e(e,t){this.notifier=e,this.source=t}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.notifier,this.source))},e}(),s=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.notifier=r,o.source=n,o}return o(t,e),t.prototype.error=function(t){if(!this.isStopped){var r=this.errors,n=this.retries,o=this.retriesSubscription;if(n)this.errors=void 0,this.retriesSubscription=void 0;else{r=new i.Subject;try{n=(0,this.notifier)(r)}catch(t){return e.prototype.error.call(this,t)}o=a.innerSubscribe(n,new a.SimpleInnerSubscriber(this))}this._unsubscribeAndRecycle(),this.errors=r,this.retries=n,this.retriesSubscription=o,r.next(t)}},t.prototype._unsubscribe=function(){var e=this.errors,t=this.retriesSubscription;e&&(e.unsubscribe(),this.errors=void 0),t&&(t.unsubscribe(),this.retriesSubscription=void 0),this.retries=void 0},t.prototype.notifyNext=function(){var e=this._unsubscribe;this._unsubscribe=null,this._unsubscribeAndRecycle(),this._unsubscribe=e,this.source.subscribe(this)},t}(a.SimpleOuterSubscriber)},5607(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.sample=function(e){return function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.notifier=e}return e.prototype.call=function(e,t){var r=new u(e),n=t.subscribe(r);return n.add(i.innerSubscribe(this.notifier,new i.SimpleInnerSubscriber(r))),n},e}(),u=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.hasValue=!1,t}return o(t,e),t.prototype._next=function(e){this.value=e,this.hasValue=!0},t.prototype.notifyNext=function(){this.emitValue()},t.prototype.notifyComplete=function(){this.emitValue()},t.prototype.emitValue=function(){this.hasValue&&(this.hasValue=!1,this.destination.next(this.value))},t}(i.SimpleOuterSubscriber)},8226(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(7661);t.sampleTime=function(e,t){return void 0===t&&(t=a.async),function(r){return r.lift(new u(e,t))}};var u=function(){function e(e,t){this.period=e,this.scheduler=t}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.period,this.scheduler))},e}(),s=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.period=r,o.scheduler=n,o.hasValue=!1,o.add(n.schedule(l,r,{subscriber:o,period:r})),o}return o(t,e),t.prototype._next=function(e){this.lastValue=e,this.hasValue=!0},t.prototype.notifyNext=function(){this.hasValue&&(this.hasValue=!1,this.destination.next(this.lastValue))},t}(i.Subscriber);function l(e){var t=e.subscriber,r=e.period;t.notifyNext(),this.schedule(e,r)}},740(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.scan=function(e,t){var r=!1;return arguments.length>=2&&(r=!0),function(n){return n.lift(new a(e,t,r))}};var a=function(){function e(e,t,r){void 0===r&&(r=!1),this.accumulator=e,this.seed=t,this.hasSeed=r}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.accumulator,this.seed,this.hasSeed))},e}(),u=function(e){function t(t,r,n,o){var i=e.call(this,t)||this;return i.accumulator=r,i._seed=n,i.hasSeed=o,i.index=0,i}return o(t,e),Object.defineProperty(t.prototype,"seed",{get:function(){return this._seed},set:function(e){this.hasSeed=!0,this._seed=e},enumerable:!0,configurable:!0}),t.prototype._next=function(e){if(this.hasSeed)return this._tryNext(e);this.seed=e,this.destination.next(e)},t.prototype._tryNext=function(e){var t,r=this.index++;try{t=this.accumulator(this.seed,e,r)}catch(e){this.destination.error(e)}this.seed=t,this.destination.next(t)},t}(i.Subscriber)},7818(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.sequenceEqual=function(e,t){return function(r){return r.lift(new a(e,t))}};var a=function(){function e(e,t){this.compareTo=e,this.comparator=t}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.compareTo,this.comparator))},e}();t.SequenceEqualOperator=a;var u=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.compareTo=r,o.comparator=n,o._a=[],o._b=[],o._oneComplete=!1,o.destination.add(r.subscribe(new s(t,o))),o}return o(t,e),t.prototype._next=function(e){this._oneComplete&&0===this._b.length?this.emit(!1):(this._a.push(e),this.checkValues())},t.prototype._complete=function(){this._oneComplete?this.emit(0===this._a.length&&0===this._b.length):this._oneComplete=!0,this.unsubscribe()},t.prototype.checkValues=function(){for(var e=this._a,t=this._b,r=this.comparator;e.length>0&&t.length>0;){var n=e.shift(),o=t.shift(),i=!1;try{i=r?r(n,o):n===o}catch(e){this.destination.error(e)}i||this.emit(!1)}},t.prototype.emit=function(e){var t=this.destination;t.next(e),t.complete()},t.prototype.nextB=function(e){this._oneComplete&&0===this._a.length?this.emit(!1):(this._b.push(e),this.checkValues())},t.prototype.completeB=function(){this._oneComplete?this.emit(0===this._a.length&&0===this._b.length):this._oneComplete=!0},t}(i.Subscriber);t.SequenceEqualSubscriber=u;var s=function(e){function t(t,r){var n=e.call(this,t)||this;return n.parent=r,n}return o(t,e),t.prototype._next=function(e){this.parent.nextB(e)},t.prototype._error=function(e){this.parent.error(e),this.unsubscribe()},t.prototype._complete=function(){this.parent.completeB(),this.unsubscribe()},t}(i.Subscriber)},9882(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(6683),o=r(9509),i=r(7127);function a(){return new i.Subject}t.share=function(){return function(e){return o.refCount()(n.multicast(a)(e))}}},9945(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2462);t.shareReplay=function(e,t,r){var o;return o=e&&(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"?e:{bufferSize:e,windowTime:t,refCount:!1,scheduler:r},function(e){var t,r,i,a,u,s,l,c,d,f,p,h;return e.lift((u=void 0===(a=(t=o).bufferSize)?1/0:a,l=void 0===(s=t.windowTime)?1/0:s,c=t.refCount,d=t.scheduler,f=0,p=!1,h=!1,function(e){var t;f++,!r||p?(p=!1,t=(r=new n.ReplaySubject(u,l,d)).subscribe(this),i=e.subscribe({next:function(e){r.next(e)},error:function(e){p=!0,r.error(e)},complete:function(){h=!0,i=void 0,r.complete()}}),h&&(i=void 0)):t=r.subscribe(this),this.add(function(){f--,t.unsubscribe(),t=void 0,i&&!h&&c&&0===f&&(i.unsubscribe(),i=void 0,r=void 0)})}))}}},2085(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(2747);t.single=function(e){return function(t){return t.lift(new u(e,t))}};var u=function(){function e(e,t){this.predicate=e,this.source=t}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.predicate,this.source))},e}(),s=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.predicate=r,o.source=n,o.seenValue=!1,o.index=0,o}return o(t,e),t.prototype.applySingleValue=function(e){this.seenValue?this.destination.error("Sequence contains more than one element"):(this.seenValue=!0,this.singleValue=e)},t.prototype._next=function(e){var t=this.index++;this.predicate?this.tryNext(e,t):this.applySingleValue(e)},t.prototype.tryNext=function(e,t){try{this.predicate(e,t,this.source)&&this.applySingleValue(e)}catch(e){this.destination.error(e)}},t.prototype._complete=function(){var e=this.destination;this.index>0?(e.next(this.seenValue?this.singleValue:void 0),e.complete()):e.error(new a.EmptyError)},t}(i.Subscriber)},3354(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.skip=function(e){return function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.total=e}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.total))},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.total=r,n.count=0,n}return o(t,e),t.prototype._next=function(e){++this.count>this.total&&this.destination.next(e)},t}(i.Subscriber)},2022(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(2021);t.skipLast=function(e){return function(t){return t.lift(new u(e))}};var u=function(){function e(e){if(this._skipCount=e,this._skipCount<0)throw new a.ArgumentOutOfRangeError}return e.prototype.call=function(e,t){return 0===this._skipCount?t.subscribe(new i.Subscriber(e)):t.subscribe(new s(e,this._skipCount))},e}(),s=function(e){function t(t,r){var n=e.call(this,t)||this;return n._skipCount=r,n._count=0,n._ring=Array(r),n}return o(t,e),t.prototype._next=function(e){var t=this._skipCount,r=this._count++;if(r<t)this._ring[r]=e;else{var n=r%t,o=this._ring,i=o[n];o[n]=e,this.destination.next(i)}},t}(i.Subscriber)},3120(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.skipUntil=function(e){return function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.notifier=e}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.notifier))},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;n.hasValue=!1;var o=new i.SimpleInnerSubscriber(n);n.add(o),n.innerSubscription=o;var a=i.innerSubscribe(r,o);return a!==o&&(n.add(a),n.innerSubscription=a),n}return o(t,e),t.prototype._next=function(t){this.hasValue&&e.prototype._next.call(this,t)},t.prototype.notifyNext=function(){this.hasValue=!0,this.innerSubscription&&this.innerSubscription.unsubscribe()},t.prototype.notifyComplete=function(){},t}(i.SimpleOuterSubscriber)},6525(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.skipWhile=function(e){return function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.predicate=e}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.predicate))},e}(),u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.predicate=r,n.skipping=!0,n.index=0,n}return o(t,e),t.prototype._next=function(e){var t=this.destination;this.skipping&&this.tryCallPredicate(e),this.skipping||t.next(e)},t.prototype.tryCallPredicate=function(e){try{var t=this.predicate(e,this.index++);this.skipping=!!t}catch(e){this.destination.error(e)}},t}(i.Subscriber)},5921(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(8093),o=r(9489);t.startWith=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=e[e.length-1];return o.isScheduler(r)?(e.pop(),function(t){return n.concat(e,t,r)}):function(t){return n.concat(e,t)}}},7044(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(6213);t.subscribeOn=function(e,t){return void 0===t&&(t=0),function(r){return r.lift(new o(e,t))}};var o=function(){function e(e,t){this.scheduler=e,this.delay=t}return e.prototype.call=function(e,t){return new n.SubscribeOnObservable(t,this.delay,this.scheduler).subscribe(e)},e}()},5018(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(6179),o=r(9156);t.switchAll=function(){return n.switchMap(o.identity)}},6179(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(2827),a=r(9001),u=r(8255);t.switchMap=function e(t,r){return"function"==typeof r?function(n){return n.pipe(e(function(e,n){return a.from(t(e,n)).pipe(i.map(function(t,o){return r(e,t,n,o)}))}))}:function(e){return e.lift(new s(t))}};var s=function(){function e(e){this.project=e}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.project))},e}(),l=function(e){function t(t,r){var n=e.call(this,t)||this;return n.project=r,n.index=0,n}return o(t,e),t.prototype._next=function(e){var t,r=this.index++;try{t=this.project(e,r)}catch(e){this.destination.error(e);return}this._innerSub(t)},t.prototype._innerSub=function(e){var t=this.innerSubscription;t&&t.unsubscribe();var r=new u.SimpleInnerSubscriber(this),n=this.destination;n.add(r),this.innerSubscription=u.innerSubscribe(e,r),this.innerSubscription!==r&&n.add(this.innerSubscription)},t.prototype._complete=function(){var t=this.innerSubscription;(!t||t.closed)&&e.prototype._complete.call(this),this.unsubscribe()},t.prototype._unsubscribe=function(){this.innerSubscription=void 0},t.prototype.notifyComplete=function(){this.innerSubscription=void 0,this.isStopped&&e.prototype._complete.call(this)},t.prototype.notifyNext=function(e){this.destination.next(e)},t}(u.SimpleOuterSubscriber)},9462(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(6179);t.switchMapTo=function(e,t){return t?n.switchMap(function(){return e},t):n.switchMap(function(){return e})}},5450(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(2021),u=r(1684);t.take=function(e){return function(t){return 0===e?u.empty():t.lift(new s(e))}};var s=function(){function e(e){if(this.total=e,this.total<0)throw new a.ArgumentOutOfRangeError}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.total))},e}(),l=function(e){function t(t,r){var n=e.call(this,t)||this;return n.total=r,n.count=0,n}return o(t,e),t.prototype._next=function(e){var t=this.total,r=++this.count;r<=t&&(this.destination.next(e),r===t&&(this.destination.complete(),this.unsubscribe()))},t}(i.Subscriber)},950(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(2021),u=r(1684);t.takeLast=function(e){return function(t){return 0===e?u.empty():t.lift(new s(e))}};var s=function(){function e(e){if(this.total=e,this.total<0)throw new a.ArgumentOutOfRangeError}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.total))},e}(),l=function(e){function t(t,r){var n=e.call(this,t)||this;return n.total=r,n.ring=[],n.count=0,n}return o(t,e),t.prototype._next=function(e){var t=this.ring,r=this.total,n=this.count++;t.length<r?t.push(e):t[n%r]=e},t.prototype._complete=function(){var e=this.destination,t=this.count;if(t>0)for(var r=this.count>=this.total?this.total:this.count,n=this.ring,o=0;o<r;o++){var i=t++%r;e.next(n[i])}e.complete()},t}(i.Subscriber)},1824(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.takeUntil=function(e){return function(t){return t.lift(new a(e))}};var a=function(){function e(e){this.notifier=e}return e.prototype.call=function(e,t){var r=new u(e),n=i.innerSubscribe(this.notifier,new i.SimpleInnerSubscriber(r));return n&&!r.seenValue?(r.add(n),t.subscribe(r)):r},e}(),u=function(e){function t(t){var r=e.call(this,t)||this;return r.seenValue=!1,r}return o(t,e),t.prototype.notifyNext=function(){this.seenValue=!0,this.complete()},t.prototype.notifyComplete=function(){},t}(i.SimpleOuterSubscriber)},7373(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097);t.takeWhile=function(e,t){return void 0===t&&(t=!1),function(r){return r.lift(new a(e,t))}};var a=function(){function e(e,t){this.predicate=e,this.inclusive=t}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.predicate,this.inclusive))},e}(),u=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.predicate=r,o.inclusive=n,o.index=0,o}return o(t,e),t.prototype._next=function(e){var t,r=this.destination;try{t=this.predicate(e,this.index++)}catch(e){r.error(e);return}this.nextOrComplete(e,t)},t.prototype.nextOrComplete=function(e,t){var r=this.destination;t?r.next(e):(this.inclusive&&r.next(e),r.complete())},t}(i.Subscriber)},1032(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(898),u=r(7894);t.tap=function(e,t,r){return function(n){return n.lift(new s(e,t,r))}};var s=function(){function e(e,t,r){this.nextOrObserver=e,this.error=t,this.complete=r}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.nextOrObserver,this.error,this.complete))},e}(),l=function(e){function t(t,r,n,o){var i=e.call(this,t)||this;return i._tapNext=a.noop,i._tapError=a.noop,i._tapComplete=a.noop,i._tapError=n||a.noop,i._tapComplete=o||a.noop,u.isFunction(r)?(i._context=i,i._tapNext=r):r&&(i._context=r,i._tapNext=r.next||a.noop,i._tapError=r.error||a.noop,i._tapComplete=r.complete||a.noop),i}return o(t,e),t.prototype._next=function(e){try{this._tapNext.call(this._context,e)}catch(e){this.destination.error(e);return}this.destination.next(e)},t.prototype._error=function(e){try{this._tapError.call(this._context,e)}catch(e){this.destination.error(e);return}this.destination.error(e)},t.prototype._complete=function(){try{this._tapComplete.call(this._context)}catch(e){this.destination.error(e);return}return this.destination.complete()},t}(i.Subscriber)},6249(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(8255);t.defaultThrottleConfig={leading:!0,trailing:!1},t.throttle=function(e,r){return void 0===r&&(r=t.defaultThrottleConfig),function(t){return t.lift(new a(e,!!r.leading,!!r.trailing))}};var a=function(){function e(e,t,r){this.durationSelector=e,this.leading=t,this.trailing=r}return e.prototype.call=function(e,t){return t.subscribe(new u(e,this.durationSelector,this.leading,this.trailing))},e}(),u=function(e){function t(t,r,n,o){var i=e.call(this,t)||this;return i.destination=t,i.durationSelector=r,i._leading=n,i._trailing=o,i._hasValue=!1,i}return o(t,e),t.prototype._next=function(e){this._hasValue=!0,this._sendValue=e,this._throttled||(this._leading?this.send():this.throttle(e))},t.prototype.send=function(){var e=this._hasValue,t=this._sendValue;e&&(this.destination.next(t),this.throttle(t)),this._hasValue=!1,this._sendValue=void 0},t.prototype.throttle=function(e){var t=this.tryDurationSelector(e);t&&this.add(this._throttled=i.innerSubscribe(t,new i.SimpleInnerSubscriber(this)))},t.prototype.tryDurationSelector=function(e){try{return this.durationSelector(e)}catch(e){return this.destination.error(e),null}},t.prototype.throttlingDone=function(){var e=this._throttled,t=this._trailing;e&&e.unsubscribe(),this._throttled=void 0,t&&this.send()},t.prototype.notifyNext=function(){this.throttlingDone()},t.prototype.notifyComplete=function(){this.throttlingDone()},t}(i.SimpleOuterSubscriber)},5708(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(7661),u=r(6249);t.throttleTime=function(e,t,r){return void 0===t&&(t=a.async),void 0===r&&(r=u.defaultThrottleConfig),function(n){return n.lift(new s(e,t,r.leading,r.trailing))}};var s=function(){function e(e,t,r,n){this.duration=e,this.scheduler=t,this.leading=r,this.trailing=n}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.duration,this.scheduler,this.leading,this.trailing))},e}(),l=function(e){function t(t,r,n,o,i){var a=e.call(this,t)||this;return a.duration=r,a.scheduler=n,a.leading=o,a.trailing=i,a._hasTrailingValue=!1,a._trailingValue=null,a}return o(t,e),t.prototype._next=function(e){this.throttled?this.trailing&&(this._trailingValue=e,this._hasTrailingValue=!0):(this.add(this.throttled=this.scheduler.schedule(c,this.duration,{subscriber:this})),this.leading?this.destination.next(e):this.trailing&&(this._trailingValue=e,this._hasTrailingValue=!0))},t.prototype._complete=function(){this._hasTrailingValue&&this.destination.next(this._trailingValue),this.destination.complete()},t.prototype.clearThrottle=function(){var e=this.throttled;e&&(this.trailing&&this._hasTrailingValue&&(this.destination.next(this._trailingValue),this._trailingValue=null,this._hasTrailingValue=!1),e.unsubscribe(),this.remove(e),this.throttled=null)},t}(i.Subscriber);function c(e){e.subscriber.clearThrottle()}},8777(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(2747),a=r(7097);t.throwIfEmpty=function(e){return void 0===e&&(e=l),function(t){return t.lift(new u(e))}};var u=function(){function e(e){this.errorFactory=e}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.errorFactory))},e}(),s=function(e){function t(t,r){var n=e.call(this,t)||this;return n.errorFactory=r,n.hasValue=!1,n}return o(t,e),t.prototype._next=function(e){this.hasValue=!0,this.destination.next(e)},t.prototype._complete=function(){if(this.hasValue)return this.destination.complete();var e=void 0;try{e=this.errorFactory()}catch(t){e=t}this.destination.error(e)},t}(a.Subscriber);function l(){return new i.EmptyError}},7093(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7661),o=r(740),i=r(6349),a=r(2827);t.timeInterval=function(e){return void 0===e&&(e=n.async),function(t){return i.defer(function(){return t.pipe(o.scan(function(t,r){var n=t.current;return{value:r,current:e.now(),last:n}},{current:e.now(),value:void 0,last:void 0}),a.map(function(e){var t=e.current,r=e.last;return new u(e.value,t-r)}))})}};var u=function(e,t){this.value=e,this.interval=t};t.TimeInterval=u},9846(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7661),o=r(6490),i=r(2706),a=r(9923);t.timeout=function(e,t){return void 0===t&&(t=n.async),i.timeoutWith(e,a.throwError(new o.TimeoutError),t)}},2706(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7661),a=r(8710),u=r(8255);t.timeoutWith=function(e,t,r){return void 0===r&&(r=i.async),function(n){var o=a.isDate(e),i=o?e-r.now():Math.abs(e);return n.lift(new s(i,o,t,r))}};var s=function(){function e(e,t,r,n){this.waitFor=e,this.absoluteTimeout=t,this.withObservable=r,this.scheduler=n}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.absoluteTimeout,this.waitFor,this.withObservable,this.scheduler))},e}(),l=function(e){function t(t,r,n,o,i){var a=e.call(this,t)||this;return a.absoluteTimeout=r,a.waitFor=n,a.withObservable=o,a.scheduler=i,a.scheduleTimeout(),a}return o(t,e),t.dispatchTimeout=function(e){var t=e.withObservable;e._unsubscribeAndRecycle(),e.add(u.innerSubscribe(t,new u.SimpleInnerSubscriber(e)))},t.prototype.scheduleTimeout=function(){var e=this.action;e?this.action=e.schedule(this,this.waitFor):this.add(this.action=this.scheduler.schedule(t.dispatchTimeout,this.waitFor,this))},t.prototype._next=function(t){this.absoluteTimeout||this.scheduleTimeout(),e.prototype._next.call(this,t)},t.prototype._unsubscribe=function(){this.action=void 0,this.scheduler=null,this.withObservable=null},t}(u.SimpleOuterSubscriber)},8133(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7661),o=r(2827);t.timestamp=function(e){return void 0===e&&(e=n.async),o.map(function(t){return new i(t,e.now())})};var i=function(e,t){this.value=e,this.timestamp=t};t.Timestamp=i},3291(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7103);function o(e,t,r){return 0===r?[t]:(e.push(t),e)}t.toArray=function(){return n.reduce(o,[])}},8697(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7127),a=r(8255);t.window=function(e){return function(t){return t.lift(new u(e))}};var u=function(){function e(e){this.windowBoundaries=e}return e.prototype.call=function(e,t){var r=new s(e),n=t.subscribe(r);return n.closed||r.add(a.innerSubscribe(this.windowBoundaries,new a.SimpleInnerSubscriber(r))),n},e}(),s=function(e){function t(t){var r=e.call(this,t)||this;return r.window=new i.Subject,t.next(r.window),r}return o(t,e),t.prototype.notifyNext=function(){this.openWindow()},t.prototype.notifyError=function(e){this._error(e)},t.prototype.notifyComplete=function(){this._complete()},t.prototype._next=function(e){this.window.next(e)},t.prototype._error=function(e){this.window.error(e),this.destination.error(e)},t.prototype._complete=function(){this.window.complete(),this.destination.complete()},t.prototype._unsubscribe=function(){this.window=null},t.prototype.openWindow=function(){var e=this.window;e&&e.complete();var t=this.destination,r=this.window=new i.Subject;t.next(r)},t}(a.SimpleOuterSubscriber)},4870(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7097),a=r(7127);t.windowCount=function(e,t){return void 0===t&&(t=0),function(r){return r.lift(new u(e,t))}};var u=function(){function e(e,t){this.windowSize=e,this.startWindowEvery=t}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.windowSize,this.startWindowEvery))},e}(),s=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.destination=t,o.windowSize=r,o.startWindowEvery=n,o.windows=[new a.Subject],o.count=0,t.next(o.windows[0]),o}return o(t,e),t.prototype._next=function(e){for(var t=this.startWindowEvery>0?this.startWindowEvery:this.windowSize,r=this.destination,n=this.windowSize,o=this.windows,i=o.length,u=0;u<i&&!this.closed;u++)o[u].next(e);var s=this.count-n+1;if(s>=0&&s%t==0&&!this.closed&&o.shift().complete(),++this.count%t==0&&!this.closed){var l=new a.Subject;o.push(l),r.next(l)}},t.prototype._error=function(e){var t=this.windows;if(t)for(;t.length>0&&!this.closed;)t.shift().error(e);this.destination.error(e)},t.prototype._complete=function(){var e=this.windows;if(e)for(;e.length>0&&!this.closed;)e.shift().complete();this.destination.complete()},t.prototype._unsubscribe=function(){this.count=0,this.windows=null},t}(i.Subscriber)},5372(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7127),a=r(7661),u=r(7097),s=r(2651),l=r(9489);t.windowTime=function(e){var t=a.async,r=null,n=1/0;return l.isScheduler(arguments[3])&&(t=arguments[3]),l.isScheduler(arguments[2])?t=arguments[2]:s.isNumeric(arguments[2])&&(n=Number(arguments[2])),l.isScheduler(arguments[1])?t=arguments[1]:s.isNumeric(arguments[1])&&(r=Number(arguments[1])),function(o){return o.lift(new c(e,r,n,t))}};var c=function(){function e(e,t,r,n){this.windowTimeSpan=e,this.windowCreationInterval=t,this.maxWindowSize=r,this.scheduler=n}return e.prototype.call=function(e,t){return t.subscribe(new f(e,this.windowTimeSpan,this.windowCreationInterval,this.maxWindowSize,this.scheduler))},e}(),d=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._numberOfNextedValues=0,t}return o(t,e),t.prototype.next=function(t){this._numberOfNextedValues++,e.prototype.next.call(this,t)},Object.defineProperty(t.prototype,"numberOfNextedValues",{get:function(){return this._numberOfNextedValues},enumerable:!0,configurable:!0}),t}(i.Subject),f=function(e){function t(t,r,n,o,i){var a=e.call(this,t)||this;a.destination=t,a.windowTimeSpan=r,a.windowCreationInterval=n,a.maxWindowSize=o,a.scheduler=i,a.windows=[];var u=a.openWindow();return null!==n&&n>=0?(a.add(i.schedule(m,r,{subscriber:a,window:u,context:null})),a.add(i.schedule(h,n,{windowTimeSpan:r,windowCreationInterval:n,subscriber:a,scheduler:i}))):a.add(i.schedule(p,r,{subscriber:a,window:u,windowTimeSpan:r})),a}return o(t,e),t.prototype._next=function(e){for(var t=this.windows,r=t.length,n=0;n<r;n++){var o=t[n];!o.closed&&(o.next(e),o.numberOfNextedValues>=this.maxWindowSize&&this.closeWindow(o))}},t.prototype._error=function(e){for(var t=this.windows;t.length>0;)t.shift().error(e);this.destination.error(e)},t.prototype._complete=function(){for(var e=this.windows;e.length>0;){var t=e.shift();t.closed||t.complete()}this.destination.complete()},t.prototype.openWindow=function(){var e=new d;return this.windows.push(e),this.destination.next(e),e},t.prototype.closeWindow=function(e){e.complete();var t=this.windows;t.splice(t.indexOf(e),1)},t}(u.Subscriber);function p(e){var t=e.subscriber,r=e.windowTimeSpan,n=e.window;n&&t.closeWindow(n),e.window=t.openWindow(),this.schedule(e,r)}function h(e){var t=e.windowTimeSpan,r=e.subscriber,n=e.scheduler,o=e.windowCreationInterval,i=r.openWindow(),a={action:this,subscription:null};a.subscription=n.schedule(m,t,{subscriber:r,window:i,context:a}),this.add(a.subscription),this.schedule(e,o)}function m(e){var t=e.subscriber,r=e.window,n=e.context;n&&n.action&&n.subscription&&n.action.remove(n.subscription),t.closeWindow(r)}},7473(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7127),a=r(1138),u=r(5238),s=r(8632);t.windowToggle=function(e,t){return function(r){return r.lift(new l(e,t))}};var l=function(){function e(e,t){this.openings=e,this.closingSelector=t}return e.prototype.call=function(e,t){return t.subscribe(new c(e,this.openings,this.closingSelector))},e}(),c=function(e){function t(t,r,n){var o=e.call(this,t)||this;return o.openings=r,o.closingSelector=n,o.contexts=[],o.add(o.openSubscription=s.subscribeToResult(o,r,r)),o}return o(t,e),t.prototype._next=function(e){var t=this.contexts;if(t)for(var r=t.length,n=0;n<r;n++)t[n].window.next(e)},t.prototype._error=function(t){var r=this.contexts;if(this.contexts=null,r)for(var n=r.length,o=-1;++o<n;){var i=r[o];i.window.error(t),i.subscription.unsubscribe()}e.prototype._error.call(this,t)},t.prototype._complete=function(){var t=this.contexts;if(this.contexts=null,t)for(var r=t.length,n=-1;++n<r;){var o=t[n];o.window.complete(),o.subscription.unsubscribe()}e.prototype._complete.call(this)},t.prototype._unsubscribe=function(){var e=this.contexts;if(this.contexts=null,e)for(var t=e.length,r=-1;++r<t;){var n=e[r];n.window.unsubscribe(),n.subscription.unsubscribe()}},t.prototype.notifyNext=function(e,t,r,n,o){if(e===this.openings){var u=void 0;try{u=(0,this.closingSelector)(t)}catch(e){return this.error(e)}var l=new i.Subject,c=new a.Subscription,d={window:l,subscription:c};this.contexts.push(d);var f=s.subscribeToResult(this,u,d);f.closed?this.closeWindow(this.contexts.length-1):(f.context=d,c.add(f)),this.destination.next(l)}else this.closeWindow(this.contexts.indexOf(e))},t.prototype.notifyError=function(e){this.error(e)},t.prototype.notifyComplete=function(e){e!==this.openSubscription&&this.closeWindow(this.contexts.indexOf(e.context))},t.prototype.closeWindow=function(e){if(-1!==e){var t=this.contexts,r=t[e],n=r.window,o=r.subscription;t.splice(e,1),n.complete(),o.unsubscribe()}},t}(u.OuterSubscriber)},2561(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(7127),a=r(5238),u=r(8632);t.windowWhen=function(e){return function(t){return t.lift(new s(e))}};var s=function(){function e(e){this.closingSelector=e}return e.prototype.call=function(e,t){return t.subscribe(new l(e,this.closingSelector))},e}(),l=function(e){function t(t,r){var n=e.call(this,t)||this;return n.destination=t,n.closingSelector=r,n.openWindow(),n}return o(t,e),t.prototype.notifyNext=function(e,t,r,n,o){this.openWindow(o)},t.prototype.notifyError=function(e){this._error(e)},t.prototype.notifyComplete=function(e){this.openWindow(e)},t.prototype._next=function(e){this.window.next(e)},t.prototype._error=function(e){this.window.error(e),this.destination.error(e),this.unsubscribeClosingNotification()},t.prototype._complete=function(){this.window.complete(),this.destination.complete(),this.unsubscribeClosingNotification()},t.prototype.unsubscribeClosingNotification=function(){this.closingNotification&&this.closingNotification.unsubscribe()},t.prototype.openWindow=function(e){void 0===e&&(e=null),e&&(this.remove(e),e.unsubscribe());var t,r=this.window;r&&r.complete();var n=this.window=new i.Subject;this.destination.next(n);try{t=(0,this.closingSelector)()}catch(e){this.destination.error(e),this.window.error(e);return}this.add(this.closingNotification=u.subscribeToResult(this,t))},t}(a.OuterSubscriber)},329(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(5238),a=r(8632);t.withLatestFrom=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){var r;return"function"==typeof e[e.length-1]&&(r=e.pop()),t.lift(new u(e,r))}};var u=function(){function e(e,t){this.observables=e,this.project=t}return e.prototype.call=function(e,t){return t.subscribe(new s(e,this.observables,this.project))},e}(),s=function(e){function t(t,r,n){var o=e.call(this,t)||this;o.observables=r,o.project=n,o.toRespond=[];var i=r.length;o.values=Array(i);for(var u=0;u<i;u++)o.toRespond.push(u);for(var u=0;u<i;u++){var s=r[u];o.add(a.subscribeToResult(o,s,void 0,u))}return o}return o(t,e),t.prototype.notifyNext=function(e,t,r){this.values[r]=t;var n=this.toRespond;if(n.length>0){var o=n.indexOf(r);-1!==o&&n.splice(o,1)}},t.prototype.notifyComplete=function(){},t.prototype._next=function(e){if(0===this.toRespond.length){var t=[e].concat(this.values);this.project?this._tryProject(t):this.destination.next(t)}},t.prototype._tryProject=function(e){var t;try{t=this.project.apply(this,e)}catch(e){this.destination.error(e);return}this.destination.next(t)},t}(i.OuterSubscriber)},3410(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3834);t.zip=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){return t.lift.call(n.zip.apply(void 0,[t].concat(e)))}}},4327(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3834);t.zipAll=function(e){return function(t){return t.lift(new n.ZipOperator(e))}}},4101(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154),o=r(1138);t.scheduleArray=function(e,t){return new n.Observable(function(r){var n=new o.Subscription,i=0;return n.add(t.schedule(function(){i===e.length?r.complete():(r.next(e[i++]),r.closed||n.add(this.schedule()))})),n})}},8540(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154),o=r(1138),i=r(2648);t.scheduleIterable=function(e,t){if(!e)throw Error("Iterable cannot be null");return new n.Observable(function(r){var n,a=new o.Subscription;return a.add(function(){n&&"function"==typeof n.return&&n.return()}),a.add(t.schedule(function(){n=e[i.iterator](),a.add(t.schedule(function(){if(!r.closed){try{var e,t,o=n.next();e=o.value,t=o.done}catch(e){r.error(e);return}t?r.complete():(r.next(e),this.schedule())}}))})),a})}},5771(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154),o=r(1138),i=r(4227);t.scheduleObservable=function(e,t){return new n.Observable(function(r){var n=new o.Subscription;return n.add(t.schedule(function(){var o=e[i.observable]();n.add(o.subscribe({next:function(e){n.add(t.schedule(function(){return r.next(e)}))},error:function(e){n.add(t.schedule(function(){return r.error(e)}))},complete:function(){n.add(t.schedule(function(){return r.complete()}))}}))})),n})}},1481(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7154),o=r(1138);t.schedulePromise=function(e,t){return new n.Observable(function(r){var n=new o.Subscription;return n.add(t.schedule(function(){return e.then(function(e){n.add(t.schedule(function(){r.next(e),n.add(t.schedule(function(){return r.complete()}))}))},function(e){n.add(t.schedule(function(){return r.error(e)}))})})),n})}},204(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(5771),o=r(1481),i=r(4101),a=r(8540),u=r(2808),s=r(7321),l=r(4370),c=r(4892);t.scheduled=function(e,t){if(null!=e){if(u.isInteropObservable(e))return n.scheduleObservable(e,t);else if(s.isPromise(e))return o.schedulePromise(e,t);else if(l.isArrayLike(e))return i.scheduleArray(e,t);else if(c.isIterable(e)||"string"==typeof e)return a.scheduleIterable(e,t)}throw TypeError((null!==e&&(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)||e)+" is not observable")}},7035(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.Action=function(e){function t(t,r){return e.call(this)||this}return o(t,e),t.prototype.schedule=function(e,t){return void 0===t&&(t=0),this},t}(r(1138).Subscription)},2058(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(433);t.AsapAction=function(e){function t(t,r){var n=e.call(this,t,r)||this;return n.scheduler=t,n.work=r,n}return o(t,e),t.prototype.requestAsyncId=function(t,r,n){return(void 0===n&&(n=0),null!==n&&n>0)?e.prototype.requestAsyncId.call(this,t,r,n):(t.actions.push(this),t.scheduled||(t.scheduled=i.Immediate.setImmediate(t.flush.bind(t,null))))},t.prototype.recycleAsyncId=function(t,r,n){if(void 0===n&&(n=0),null!==n&&n>0||null===n&&this.delay>0)return e.prototype.recycleAsyncId.call(this,t,r,n);0===t.actions.length&&(i.Immediate.clearImmediate(r),t.scheduled=void 0)},t}(r(3247).AsyncAction)},367(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.AsapScheduler=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.flush=function(e){this.active=!0,this.scheduled=void 0;var t,r=this.actions,n=-1,o=r.length;e=e||r.shift();do if(t=e.execute(e.state,e.delay))break;while(++n<o&&(e=r.shift()));if(this.active=!1,t){for(;++n<o&&(e=r.shift());)e.unsubscribe();throw t}},t}(r(4548).AsyncScheduler)},3247(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.AsyncAction=function(e){function t(t,r){var n=e.call(this,t,r)||this;return n.scheduler=t,n.work=r,n.pending=!1,n}return o(t,e),t.prototype.schedule=function(e,t){if(void 0===t&&(t=0),this.closed)return this;this.state=e;var r=this.id,n=this.scheduler;return null!=r&&(this.id=this.recycleAsyncId(n,r,t)),this.pending=!0,this.delay=t,this.id=this.id||this.requestAsyncId(n,this.id,t),this},t.prototype.requestAsyncId=function(e,t,r){return void 0===r&&(r=0),setInterval(e.flush.bind(e,this),r)},t.prototype.recycleAsyncId=function(e,t,r){if(void 0===r&&(r=0),null!==r&&this.delay===r&&!1===this.pending)return t;clearInterval(t)},t.prototype.execute=function(e,t){if(this.closed)return Error("executing a cancelled action");this.pending=!1;var r=this._execute(e,t);if(r)return r;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},t.prototype._execute=function(e,t){var r=!1,n=void 0;try{this.work(e)}catch(e){r=!0,n=!!e&&e||Error(e)}if(r)return this.unsubscribe(),n},t.prototype._unsubscribe=function(){var e=this.id,t=this.scheduler,r=t.actions,n=r.indexOf(this);this.work=null,this.state=null,this.pending=!1,this.scheduler=null,-1!==n&&r.splice(n,1),null!=e&&(this.id=this.recycleAsyncId(t,e,null)),this.delay=null},t}(r(7035).Action)},4548(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(3054);t.AsyncScheduler=function(e){function t(r,n){void 0===n&&(n=i.Scheduler.now);var o=e.call(this,r,function(){return t.delegate&&t.delegate!==o?t.delegate.now():n()})||this;return o.actions=[],o.active=!1,o.scheduled=void 0,o}return o(t,e),t.prototype.schedule=function(r,n,o){return(void 0===n&&(n=0),t.delegate&&t.delegate!==this)?t.delegate.schedule(r,n,o):e.prototype.schedule.call(this,r,n,o)},t.prototype.flush=function(e){var t,r=this.actions;if(this.active)return void r.push(e);this.active=!0;do if(t=e.execute(e.state,e.delay))break;while(e=r.shift());if(this.active=!1,t){for(;e=r.shift();)e.unsubscribe();throw t}},t}(i.Scheduler)},5976(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.QueueAction=function(e){function t(t,r){var n=e.call(this,t,r)||this;return n.scheduler=t,n.work=r,n}return o(t,e),t.prototype.schedule=function(t,r){return(void 0===r&&(r=0),r>0)?e.prototype.schedule.call(this,t,r):(this.delay=r,this.state=t,this.scheduler.flush(this),this)},t.prototype.execute=function(t,r){return r>0||this.closed?e.prototype.execute.call(this,t,r):this._execute(t,r)},t.prototype.requestAsyncId=function(t,r,n){return(void 0===n&&(n=0),null!==n&&n>0||null===n&&this.delay>0)?e.prototype.requestAsyncId.call(this,t,r,n):t.flush(this)},t}(r(3247).AsyncAction)},9865(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){var r,o;return(n=Object.setPrototypeOf||(r={__proto__:[]},(null!=(o=Array)&&"u">typeof Symbol&&o[Symbol.hasInstance]?!!o[Symbol.hasInstance](r):r instanceof o)&&function(e,t){e.__proto__=t})||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.QueueScheduler=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t}(r(4548).AsyncScheduler)},8752(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2058);t.asapScheduler=new(r(367)).AsapScheduler(n.AsapAction),t.asap=t.asapScheduler},7661(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3247);t.asyncScheduler=new(r(4548)).AsyncScheduler(n.AsyncAction),t.async=t.asyncScheduler},3954(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(5976);t.queueScheduler=new(r(9865)).QueueScheduler(n.QueueAction),t.queue=t.queueScheduler},2648(e,t){"use strict";function r(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}Object.defineProperty(t,"__esModule",{value:!0}),t.getSymbolIterator=r,t.iterator=r(),t.$$iterator=t.iterator},4227(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.observable="function"==typeof Symbol&&Symbol.observable||"@@observable"},3798(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.rxSubscriber="function"==typeof Symbol?Symbol("rxSubscriber"):"@@rxSubscriber_"+Math.random(),t.$$rxSubscriber=t.rxSubscriber},2021(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ArgumentOutOfRangeError=function(){function e(){return Error.call(this),this.message="argument out of range",this.name="ArgumentOutOfRangeError",this}return e.prototype=Object.create(Error.prototype),e}()},2747(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EmptyError=function(){function e(){return Error.call(this),this.message="no elements in sequence",this.name="EmptyError",this}return e.prototype=Object.create(Error.prototype),e}()},433(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=1,n=Promise.resolve(),o={};function i(e){return e in o&&(delete o[e],!0)}t.Immediate={setImmediate:function(e){var t=r++;return o[t]=!0,n.then(function(){return i(t)&&e()}),t},clearImmediate:function(e){i(e)}},t.TestTools={pending:function(){return Object.keys(o).length}}},1277(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ObjectUnsubscribedError=function(){function e(){return Error.call(this),this.message="object unsubscribed",this.name="ObjectUnsubscribedError",this}return e.prototype=Object.create(Error.prototype),e}()},6490(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TimeoutError=function(){function e(){return Error.call(this),this.message="Timeout has occurred",this.name="TimeoutError",this}return e.prototype=Object.create(Error.prototype),e}()},6384(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UnsubscriptionError=function(){function e(e){return Error.call(this),this.message=e?e.length+" errors occurred during unsubscription:\n"+e.map(function(e,t){return t+1+") "+e.toString()}).join("\n "):"",this.name="UnsubscriptionError",this.errors=e,this}return e.prototype=Object.create(Error.prototype),e}()},6012(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7097);t.canReportError=function(e){for(;e;){var t,r=e,o=r.closed,i=r.destination,a=r.isStopped;if(o||a)return!1;e=i&&(null!=(t=n.Subscriber)&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](i):i instanceof t)?i:null}return!0}},2618(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hostReportError=function(e){setTimeout(function(){throw e},0)}},9156(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.identity=function(e){return e}},9109(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isArray=Array.isArray||function(e){return e&&"number"==typeof e.length}},4370(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isArrayLike=function(e){return e&&"number"==typeof e.length&&"function"!=typeof e}},8710(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isDate=function(e){var t;return(null!=(t=Date)&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t)&&!isNaN(+e)}},7894(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isFunction=function(e){return"function"==typeof e}},2808(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(4227);t.isInteropObservable=function(e){return e&&"function"==typeof e[n.observable]}},4892(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2648);t.isIterable=function(e){return e&&"function"==typeof e[n.iterator]}},2651(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9109);t.isNumeric=function(e){return!n.isArray(e)&&e-parseFloat(e)+1>=0}},5393(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isObject=function(e){return null!==e&&(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"}},7321(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isPromise=function(e){return!!e&&"function"!=typeof e.subscribe&&"function"==typeof e.then}},9489(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isScheduler=function(e){return e&&"function"==typeof e.schedule}},898(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.noop=function(){}},1985(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.not=function(e,t){function r(){return!r.pred.apply(r.thisArg,arguments)}return r.pred=e,r.thisArg=t,r}},7654(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9156);function o(e){return 0===e.length?n.identity:1===e.length?e[0]:function(t){return e.reduce(function(e,t){return t(e)},t)}}t.pipe=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return o(e)},t.pipeFromArray=o},3997(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(9128),o=r(4320),i=r(107),a=r(352),u=r(4370),s=r(7321),l=r(5393),c=r(2648),d=r(4227);t.subscribeTo=function(e){if(e&&"function"==typeof e[d.observable])return a.subscribeToObservable(e);if(u.isArrayLike(e))return n.subscribeToArray(e);if(s.isPromise(e))return o.subscribeToPromise(e);if(e&&"function"==typeof e[c.iterator])return i.subscribeToIterable(e);throw TypeError("You provided "+(l.isObject(e)?"an invalid object":"'"+e+"'")+" where a stream was expected. You can provide an Observable, Promise, Array, or Iterable.")}},9128(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.subscribeToArray=function(e){return function(t){for(var r=0,n=e.length;r<n&&!t.closed;r++)t.next(e[r]);t.complete()}}},107(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2648);t.subscribeToIterable=function(e){return function(t){for(var r=e[n.iterator]();;){var o=void 0;try{o=r.next()}catch(e){return t.error(e),t}if(o.done){t.complete();break}if(t.next(o.value),t.closed)break}return"function"==typeof r.return&&t.add(function(){r.return&&r.return()}),t}}},352(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(4227);t.subscribeToObservable=function(e){return function(t){var r=e[n.observable]();if("function"==typeof r.subscribe)return r.subscribe(t);throw TypeError("Provided object does not correctly implement Symbol.observable")}}},4320(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2618);t.subscribeToPromise=function(e){return function(t){return e.then(function(e){t.closed||(t.next(e),t.complete())},function(e){return t.error(e)}).then(null,n.hostReportError),t}}},8632(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(4921),o=r(3997),i=r(7154);t.subscribeToResult=function(e,t,r,a,u){if(void 0===u&&(u=new n.InnerSubscriber(e,r,a)),!u.closed){var s;return(null!=(s=i.Observable)&&"u">typeof Symbol&&s[Symbol.hasInstance]?!!s[Symbol.hasInstance](t):t instanceof s)?t.subscribe(u):o.subscribeTo(t)(u)}}},4665(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7097),o=r(3798),i=r(4109);t.toSubscriber=function(e,t,r){if(e){var a;if(null!=(a=n.Subscriber)&&"u">typeof Symbol&&a[Symbol.hasInstance]?!!a[Symbol.hasInstance](e):e instanceof a)return e;if(e[o.rxSubscriber])return e[o.rxSubscriber]()}return e||t||r?new n.Subscriber(e,t,r):new n.Subscriber(i.empty)}},2719(e,t,r){"use strict";r(6278).audit,r(643).auditTime,r(4987).buffer,r(7288).bufferCount,r(9118).bufferTime,r(4623).bufferToggle,r(2771).bufferWhen,r(7610).catchError,r(3101).combineAll,r(6923).combineLatest,r(325).concat,r(7930).concatAll,r(9091).concatMap,r(2710).concatMapTo,r(8786).count,r(8966).debounce,r(8387).debounceTime,r(1974).defaultIfEmpty,r(926).delay,r(1058).delayWhen,r(2045).dematerialize,r(6961).distinct,r(6693).distinctUntilChanged,r(2296).distinctUntilKeyChanged,r(8876).elementAt,r(1148).endWith,r(4434).every,r(8811).exhaust,r(2429).exhaustMap,r(9790).expand,r(7851).filter,r(7183).finalize,r(8054).find,r(384).findIndex,r(8663).first,r(6659).groupBy,r(6494).ignoreElements,r(7240).isEmpty,r(7801).last,t.map=r(2827).map,r(4078).mapTo,r(5604).materialize,r(5699).max,r(5709).merge,r(8914).mergeAll;var n=r(5643);n.mergeMap,n.flatMap,r(5006).mergeMapTo,r(7924).mergeScan,r(4049).min,r(6683).multicast,r(4436).observeOn,r(4058).onErrorResumeNext,r(4253).pairwise,r(4255).partition,r(8356).pluck,r(626).publish,r(6880).publishBehavior,r(2158).publishLast,r(2337).publishReplay,r(1596).race,r(7103).reduce,r(1198).repeat,r(130).repeatWhen,r(4607).retry,r(6351).retryWhen,r(9509).refCount,r(5607).sample,r(8226).sampleTime,r(740).scan,r(7818).sequenceEqual,r(9882).share,r(9945).shareReplay,r(2085).single,r(3354).skip,r(2022).skipLast,r(3120).skipUntil,r(6525).skipWhile,r(5921).startWith,r(7044).subscribeOn,r(5018).switchAll,r(6179).switchMap,r(9462).switchMapTo,t.take=r(5450).take,r(950).takeLast,r(1824).takeUntil,r(7373).takeWhile,r(1032).tap,r(6249).throttle,r(5708).throttleTime,r(8777).throwIfEmpty,r(7093).timeInterval,r(9846).timeout,r(2706).timeoutWith,r(8133).timestamp,r(3291).toArray,r(8697).window,r(4870).windowCount,r(5372).windowTime,r(7473).windowToggle,r(2561).windowWhen,r(329).withLatestFrom,r(3410).zip,r(4327).zipAll},6503(e,t,r){"use strict";function n(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function o(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}var i=Symbol("SemVer ANY");e.exports=function(){var e,t;function r(e,t){if(!(this instanceof r))throw TypeError("Cannot call a class as a function");if(t=a(t),o(e,r))if(!!t.loose===e.loose)return e;else e=e.value;d("comparator",e=e.trim().split(/\s+/).join(" "),t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===i?this.value="":this.value=this.operator+this.semver.version,d("comp",this)}return e=[{key:"parse",value:function(e){var t=this.options.loose?s[l.COMPARATORLOOSE]:s[l.COMPARATOR],r=e.match(t);if(!r)throw TypeError("Invalid comparator: ".concat(e));this.operator=void 0!==r[1]?r[1]:"","="===this.operator&&(this.operator=""),r[2]?this.semver=new f(r[2],this.options.loose):this.semver=i}},{key:"toString",value:function(){return this.value}},{key:"test",value:function(e){if(d("Comparator.test",e,this.options.loose),this.semver===i||e===i)return!0;if("string"==typeof e)try{e=new f(e,this.options)}catch(e){return!1}return c(e,this.operator,this.semver,this.options)}},{key:"intersects",value:function(e,t){if(!o(e,r))throw TypeError("a Comparator is required");return""===this.operator?""===this.value||new p(e.value,t).test(this.value):""===e.operator?""===e.value||new p(this.value,t).test(e.semver):!((t=a(t)).includePrerelease&&("<0.0.0-0"===this.value||"<0.0.0-0"===e.value)||!t.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0")))&&!!(this.operator.startsWith(">")&&e.operator.startsWith(">")||this.operator.startsWith("<")&&e.operator.startsWith("<")||this.semver.version===e.semver.version&&this.operator.includes("=")&&e.operator.includes("=")||c(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<")||c(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">"))}}],t=[{key:"ANY",get:function(){return i}}],e&&n(r.prototype,e),t&&n(r,t),r}();var a=r(6480),u=r(4299),s=u.safeRe,l=u.t,c=r(570),d=r(7139),f=r(7583),p=r(7490)},7490(e,t,r){"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function o(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}var i=/\s+/g;e.exports=function(){var e;function t(e,r){var n=this;if(!(this instanceof t))throw TypeError("Cannot call a class as a function");if(r=u(r),o(e,t))if(!!r.loose===e.loose&&!!r.includePrerelease===e.includePrerelease)return e;else return new t(e.raw,r);if(o(e,s))return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e.trim().replace(i," "),this.set=this.raw.split("||").map(function(e){return n.parseRange(e.trim())}).filter(function(e){return e.length}),!this.set.length)throw TypeError("Invalid SemVer Range: ".concat(this.raw));if(this.set.length>1){var a=this.set[0];if(this.set=this.set.filter(function(e){return!w(e[0])}),0===this.set.length)this.set=[a];else if(this.set.length>1){var l=!0,c=!1,d=void 0;try{for(var f,p=this.set[Symbol.iterator]();!(l=(f=p.next()).done);l=!0){var h=f.value;if(1===h.length&&E(h[0])){this.set=[h];break}}}catch(e){c=!0,d=e}finally{try{l||null==p.return||p.return()}finally{if(c)throw d}}}}this.formatted=void 0}return e=[{key:"range",get:function(){if(void 0===this.formatted){this.formatted="";for(var e=0;e<this.set.length;e++){e>0&&(this.formatted+="||");for(var t=this.set[e],r=0;r<t.length;r++)r>0&&(this.formatted+=" "),this.formatted+=t[r].toString().trim()}}return this.formatted}},{key:"format",value:function(){return this.range}},{key:"toString",value:function(){return this.range}},{key:"parseRange",value:function(e){var t,r=this,o=((this.options.includePrerelease&&v)|(this.options.loose&&g))+":"+e,i=a.get(o);if(i)return i;var u=this.options.loose,c=u?f[p.HYPHENRANGELOOSE]:f[p.HYPHENRANGE];l("hyphen replace",e=e.replace(c,R(this.options.includePrerelease))),l("comparator trim",e=e.replace(f[p.COMPARATORTRIM],h)),l("tilde trim",e=e.replace(f[p.TILDETRIM],m)),l("caret trim",e=e.replace(f[p.CARETTRIM],y));var d=e.split(" ").map(function(e){return O(e,r.options)}).join(" ").split(/\s+/).map(function(e){return T(e,r.options)});u&&(d=d.filter(function(e){return l("loose invalid filter",e,r.options),!!e.match(f[p.COMPARATORLOOSE])})),l("range list",d);var b=new Map,E=d.map(function(e){return new s(e,r.options)}),S=!0,A=!1,x=void 0;try{for(var D,j=E[Symbol.iterator]();!(S=(D=j.next()).done);S=!0){var C=D.value;if(w(C))return[C];b.set(C.value,C)}}catch(e){A=!0,x=e}finally{try{S||null==j.return||j.return()}finally{if(A)throw x}}b.size>1&&b.has("")&&b.delete("");var P=function(e){if(Array.isArray(e))return n(e)}(t=b.values())||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||function(e){if(e){if("string"==typeof e)return n(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return n(e,void 0)}}(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}();return a.set(o,P),P}},{key:"intersects",value:function(e,r){if(!o(e,t))throw TypeError("a Range is required");return this.set.some(function(t){return S(t,r)&&e.set.some(function(e){return S(e,r)&&t.every(function(t){return e.every(function(e){return t.intersects(e,r)})})})})}},{key:"test",value:function(e){if(!e)return!1;if("string"==typeof e)try{e=new c(e,this.options)}catch(e){return!1}for(var t=0;t<this.set.length;t++)if(F(this.set[t],e,this.options))return!0;return!1}}],function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,e),t}();var a=new(r(3235)),u=r(6480),s=r(6503),l=r(7139),c=r(7583),d=r(4299),f=d.safeRe,p=d.t,h=d.comparatorTrimReplace,m=d.tildeTrimReplace,y=d.caretTrimReplace,b=r(9345),v=b.FLAG_INCLUDE_PRERELEASE,g=b.FLAG_LOOSE,w=function(e){return"<0.0.0-0"===e.value},E=function(e){return""===e.value},S=function(e,t){for(var r=!0,n=e.slice(),o=n.pop();r&&n.length;)r=n.every(function(e){return o.intersects(e,t)}),o=n.pop();return r},O=function(e,t){return l("comp",e=e.replace(f[p.BUILD],""),t),l("caret",e=j(e,t)),l("tildes",e=x(e,t)),l("xrange",e=P(e,t)),l("stars",e=I(e,t)),e},A=function(e){return!e||"x"===e.toLowerCase()||"*"===e},x=function(e,t){return e.trim().split(/\s+/).map(function(e){return D(e,t)}).join(" ")},D=function(e,t){var r=t.loose?f[p.TILDELOOSE]:f[p.TILDE];return e.replace(r,function(t,r,n,o,i){var a;return l("tilde",e,t,r,n,o,i),A(r)?a="":A(n)?a=">=".concat(r,".0.0 <").concat(+r+1,".0.0-0"):A(o)?a=">=".concat(r,".").concat(n,".0 <").concat(r,".").concat(+n+1,".0-0"):i?(l("replaceTilde pr",i),a=">=".concat(r,".").concat(n,".").concat(o,"-").concat(i," <").concat(r,".").concat(+n+1,".0-0")):a=">=".concat(r,".").concat(n,".").concat(o," <").concat(r,".").concat(+n+1,".0-0"),l("tilde return",a),a})},j=function(e,t){return e.trim().split(/\s+/).map(function(e){return C(e,t)}).join(" ")},C=function(e,t){l("caret",e,t);var r=t.loose?f[p.CARETLOOSE]:f[p.CARET],n=t.includePrerelease?"-0":"";return e.replace(r,function(t,r,o,i,a){var u;return l("caret",e,t,r,o,i,a),A(r)?u="":A(o)?u=">=".concat(r,".0.0").concat(n," <").concat(+r+1,".0.0-0"):A(i)?u="0"===r?">=".concat(r,".").concat(o,".0").concat(n," <").concat(r,".").concat(+o+1,".0-0"):">=".concat(r,".").concat(o,".0").concat(n," <").concat(+r+1,".0.0-0"):a?(l("replaceCaret pr",a),u="0"===r?"0"===o?">=".concat(r,".").concat(o,".").concat(i,"-").concat(a," <").concat(r,".").concat(o,".").concat(+i+1,"-0"):">=".concat(r,".").concat(o,".").concat(i,"-").concat(a," <").concat(r,".").concat(+o+1,".0-0"):">=".concat(r,".").concat(o,".").concat(i,"-").concat(a," <").concat(+r+1,".0.0-0")):(l("no pr"),u="0"===r?"0"===o?">=".concat(r,".").concat(o,".").concat(i).concat(n," <").concat(r,".").concat(o,".").concat(+i+1,"-0"):">=".concat(r,".").concat(o,".").concat(i).concat(n," <").concat(r,".").concat(+o+1,".0-0"):">=".concat(r,".").concat(o,".").concat(i," <").concat(+r+1,".0.0-0")),l("caret return",u),u})},P=function(e,t){return l("replaceXRanges",e,t),e.split(/\s+/).map(function(e){return k(e,t)}).join(" ")},k=function(e,t){e=e.trim();var r=t.loose?f[p.XRANGELOOSE]:f[p.XRANGE];return e.replace(r,function(r,n,o,i,a,u){l("xRange",e,r,n,o,i,a,u);var s=A(o),c=s||A(i),d=c||A(a);return"="===n&&d&&(n=""),u=t.includePrerelease?"-0":"",s?r=">"===n||"<"===n?"<0.0.0-0":"*":n&&d?(c&&(i=0),a=0,">"===n?(n=">=",c?(o=+o+1,i=0):i=+i+1,a=0):"<="===n&&(n="<",c?o=+o+1:i=+i+1),"<"===n&&(u="-0"),r="".concat(n+o,".").concat(i,".").concat(a).concat(u)):c?r=">=".concat(o,".0.0").concat(u," <").concat(+o+1,".0.0-0"):d&&(r=">=".concat(o,".").concat(i,".0").concat(u," <").concat(o,".").concat(+i+1,".0-0")),l("xRange return",r),r})},I=function(e,t){return l("replaceStars",e,t),e.trim().replace(f[p.STAR],"")},T=function(e,t){return l("replaceGTE0",e,t),e.trim().replace(f[t.includePrerelease?p.GTE0PRE:p.GTE0],"")},R=function(e){return function(t,r,n,o,i,a,u,s,l,c,d,f){return r=A(n)?"":A(o)?">=".concat(n,".0.0").concat(e?"-0":""):A(i)?">=".concat(n,".").concat(o,".0").concat(e?"-0":""):a?">=".concat(r):">=".concat(r).concat(e?"-0":""),s=A(l)?"":A(c)?"<".concat(+l+1,".0.0-0"):A(d)?"<".concat(l,".").concat(+c+1,".0-0"):f?"<=".concat(l,".").concat(c,".").concat(d,"-").concat(f):e?"<".concat(l,".").concat(c,".").concat(+d+1,"-0"):"<=".concat(s),"".concat(r," ").concat(s).trim()}},F=function(e,t,r){for(var n=0;n<e.length;n++)if(!e[n].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(var o=0;o<e.length;o++)if(l(e[o].semver),e[o].semver!==s.ANY&&e[o].semver.prerelease.length>0){var i=e[o].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}return!1}return!0}},7583(e,t,r){"use strict";function n(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}var o=r(7139),i=r(9345),a=i.MAX_LENGTH,u=i.MAX_SAFE_INTEGER,s=r(4299),l=s.safeRe,c=s.t,d=r(6480),f=r(6640).compareIdentifiers;e.exports=function(){var e;function t(e,r){if(!(this instanceof t))throw TypeError("Cannot call a class as a function");if(r=d(r),n(e,t))if(!!r.loose===e.loose&&!!r.includePrerelease===e.includePrerelease)return e;else e=e.version;else if("string"!=typeof e)throw TypeError('Invalid version. Must be a string. Got type "'.concat(void 0===e?"undefined":(i=e)&&"u">typeof Symbol&&i.constructor===Symbol?"symbol":typeof i,'".'));if(e.length>a)throw TypeError("version is longer than ".concat(a," characters"));o("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;var i,s=e.trim().match(r.loose?l[c.LOOSE]:l[c.FULL]);if(!s)throw TypeError("Invalid Version: ".concat(e));if(this.raw=e,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>u||this.major<0)throw TypeError("Invalid major version");if(this.minor>u||this.minor<0)throw TypeError("Invalid minor version");if(this.patch>u||this.patch<0)throw TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map(function(e){if(/^[0-9]+$/.test(e)){var t=+e;if(t>=0&&t<u)return t}return e}):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}return e=[{key:"format",value:function(){return this.version="".concat(this.major,".").concat(this.minor,".").concat(this.patch),this.prerelease.length&&(this.version+="-".concat(this.prerelease.join("."))),this.version}},{key:"toString",value:function(){return this.version}},{key:"compare",value:function(e){if(o("SemVer.compare",this.version,this.options,e),!n(e,t)){if("string"==typeof e&&e===this.version)return 0;e=new t(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}},{key:"compareMain",value:function(e){return(n(e,t)||(e=new t(e,this.options)),this.major<e.major)?-1:this.major>e.major?1:this.minor<e.minor?-1:this.minor>e.minor?1:this.patch<e.patch?-1:+(this.patch>e.patch)}},{key:"comparePre",value:function(e){if(n(e,t)||(e=new t(e,this.options)),this.prerelease.length&&!e.prerelease.length)return -1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;var r=0;do{var i=this.prerelease[r],a=e.prerelease[r];if(o("prerelease compare",r,i,a),void 0===i&&void 0===a)return 0;if(void 0===a)return 1;if(void 0===i)return -1;else if(i===a)continue;else return f(i,a)}while(++r)}},{key:"compareBuild",value:function(e){n(e,t)||(e=new t(e,this.options));var r=0;do{var i=this.build[r],a=e.build[r];if(o("build compare",r,i,a),void 0===i&&void 0===a)return 0;if(void 0===a)return 1;if(void 0===i)return -1;else if(i===a)continue;else return f(i,a)}while(++r)}},{key:"inc",value:function(e,t,r){if(e.startsWith("pre")){if(!t&&!1===r)throw Error("invalid increment argument: identifier is empty");if(t){var n="-".concat(t).match(this.options.loose?l[c.PRERELEASELOOSE]:l[c.PRERELEASE]);if(!n||n[1]!==t)throw Error("invalid identifier: ".concat(t))}}switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t,r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t,r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t,r),this.inc("pre",t,r);break;case"prerelease":0===this.prerelease.length&&this.inc("patch",t,r),this.inc("pre",t,r);break;case"release":if(0===this.prerelease.length)throw Error("version ".concat(this.raw," is not a prerelease"));this.prerelease.length=0;break;case"major":(0!==this.minor||0!==this.patch||0===this.prerelease.length)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(0!==this.patch||0===this.prerelease.length)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":0===this.prerelease.length&&this.patch++,this.prerelease=[];break;case"pre":var o=+!!Number(r);if(0===this.prerelease.length)this.prerelease=[o];else{for(var i=this.prerelease.length;--i>=0;)"number"==typeof this.prerelease[i]&&(this.prerelease[i]++,i=-2);if(-1===i){if(t===this.prerelease.join(".")&&!1===r)throw Error("invalid increment argument: identifier already exists");this.prerelease.push(o)}}if(t){var a=[t,o];!1===r&&(a=[t]),0===f(this.prerelease[0],t)?isNaN(this.prerelease[1])&&(this.prerelease=a):this.prerelease=a}break;default:throw Error("invalid increment argument: ".concat(e))}return this.raw=this.format(),this.build.length&&(this.raw+="+".concat(this.build.join("."))),this}}],function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,e),t}()},5995(e,t,r){"use strict";var n=r(5749);e.exports=function(e,t){var r=n(e.trim().replace(/^[=v]+/,""),t);return r?r.version:null}},570(e,t,r){"use strict";function n(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}var o=r(6534),i=r(9962),a=r(4907),u=r(9928),s=r(6228),l=r(4401);e.exports=function(e,t,r,c){switch(t){case"===":return(void 0===e?"undefined":n(e))==="object"&&(e=e.version),(void 0===r?"undefined":n(r))==="object"&&(r=r.version),e===r;case"!==":return(void 0===e?"undefined":n(e))==="object"&&(e=e.version),(void 0===r?"undefined":n(r))==="object"&&(r=r.version),e!==r;case"":case"=":case"==":return o(e,r,c);case"!=":return i(e,r,c);case">":return a(e,r,c);case">=":return u(e,r,c);case"<":return s(e,r,c);case"<=":return l(e,r,c);default:throw TypeError("Invalid operator: ".concat(t))}}},5877(e,t,r){"use strict";var n=r(7583),o=r(5749),i=r(4299),a=i.safeRe,u=i.t;e.exports=function(e,t){if(i=e,null!=n&&"u">typeof Symbol&&n[Symbol.hasInstance]?!!n[Symbol.hasInstance](i):i instanceof n)return e;if("number"==typeof e&&(e=String(e)),"string"!=typeof e)return null;var r=null;if((t=t||{}).rtl){for(var i,s,l=t.includePrerelease?a[u.COERCERTLFULL]:a[u.COERCERTL];(s=l.exec(e))&&(!r||r.index+r[0].length!==e.length);)r&&s.index+s[0].length===r.index+r[0].length||(r=s),l.lastIndex=s.index+s[1].length+s[2].length;l.lastIndex=-1}else r=e.match(t.includePrerelease?a[u.COERCEFULL]:a[u.COERCE]);if(null===r)return null;var c=r[2],d=r[3]||"0",f=r[4]||"0",p=t.includePrerelease&&r[5]?"-".concat(r[5]):"",h=t.includePrerelease&&r[6]?"+".concat(r[6]):"";return o("".concat(c,".").concat(d,".").concat(f).concat(p).concat(h),t)}},2740(e,t,r){"use strict";var n=r(7583);e.exports=function(e,t,r){var o=new n(e,r),i=new n(t,r);return o.compare(i)||o.compareBuild(i)}},9478(e,t,r){"use strict";var n=r(2057);e.exports=function(e,t){return n(e,t,!0)}},2057(e,t,r){"use strict";var n=r(7583);e.exports=function(e,t,r){return new n(e,r).compare(new n(t,r))}},6003(e,t,r){"use strict";var n=r(5749);e.exports=function(e,t){var r=n(e,null,!0),o=n(t,null,!0),i=r.compare(o);if(0===i)return null;var a=i>0,u=a?r:o,s=a?o:r,l=!!u.prerelease.length;if(s.prerelease.length&&!l){if(!s.patch&&!s.minor)return"major";if(0===s.compareMain(u))return s.minor&&!s.patch?"minor":"patch"}var c=l?"pre":"";return r.major!==o.major?c+"major":r.minor!==o.minor?c+"minor":r.patch!==o.patch?c+"patch":"prerelease"}},6534(e,t,r){"use strict";var n=r(2057);e.exports=function(e,t,r){return 0===n(e,t,r)}},4907(e,t,r){"use strict";var n=r(2057);e.exports=function(e,t,r){return n(e,t,r)>0}},9928(e,t,r){"use strict";var n=r(2057);e.exports=function(e,t,r){return n(e,t,r)>=0}},4006(e,t,r){"use strict";var n=r(7583);e.exports=function(e,t,r,o,i){"string"==typeof r&&(i=o,o=r,r=void 0);try{return new n((null!=n&&"u">typeof Symbol&&n[Symbol.hasInstance]?!!n[Symbol.hasInstance](e):e instanceof n)?e.version:e,r).inc(t,o,i).version}catch(e){return null}}},6228(e,t,r){"use strict";var n=r(2057);e.exports=function(e,t,r){return 0>n(e,t,r)}},4401(e,t,r){"use strict";var n=r(2057);e.exports=function(e,t,r){return 0>=n(e,t,r)}},9211(e,t,r){"use strict";var n=r(7583);e.exports=function(e,t){return new n(e,t).major}},2895(e,t,r){"use strict";var n=r(7583);e.exports=function(e,t){return new n(e,t).minor}},9962(e,t,r){"use strict";var n=r(2057);e.exports=function(e,t,r){return 0!==n(e,t,r)}},5749(e,t,r){"use strict";var n=r(7583);e.exports=function(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(null!=n&&"u">typeof Symbol&&n[Symbol.hasInstance]?!!n[Symbol.hasInstance](e):e instanceof n)return e;try{return new n(e,t)}catch(e){if(!r)return null;throw e}}},6008(e,t,r){"use strict";var n=r(7583);e.exports=function(e,t){return new n(e,t).patch}},510(e,t,r){"use strict";var n=r(5749);e.exports=function(e,t){var r=n(e,t);return r&&r.prerelease.length?r.prerelease:null}},6153(e,t,r){"use strict";var n=r(2057);e.exports=function(e,t,r){return n(t,e,r)}},9268(e,t,r){"use strict";var n=r(2740);e.exports=function(e,t){return e.sort(function(e,r){return n(r,e,t)})}},5775(e,t,r){"use strict";var n=r(7490);e.exports=function(e,t,r){try{t=new n(t,r)}catch(e){return!1}return t.test(e)}},4372(e,t,r){"use strict";var n=r(2740);e.exports=function(e,t){return e.sort(function(e,r){return n(e,r,t)})}},3440(e,t,r){"use strict";var n=r(5749);e.exports=function(e,t){var r=n(e,t);return r?r.version:null}},8164(e,t,r){"use strict";var n=r(4299),o=r(9345),i=r(7583),a=r(6640);e.exports={parse:r(5749),valid:r(3440),clean:r(5995),inc:r(4006),diff:r(6003),major:r(9211),minor:r(2895),patch:r(6008),prerelease:r(510),compare:r(2057),rcompare:r(6153),compareLoose:r(9478),compareBuild:r(2740),sort:r(4372),rsort:r(9268),gt:r(4907),lt:r(6228),eq:r(6534),neq:r(9962),gte:r(9928),lte:r(4401),cmp:r(570),coerce:r(5877),Comparator:r(6503),Range:r(7490),satisfies:r(5775),toComparators:r(7690),maxSatisfying:r(5901),minSatisfying:r(6975),minVersion:r(8158),validRange:r(3429),outside:r(3452),gtr:r(2560),ltr:r(9801),intersects:r(453),simplifyRange:r(1784),subset:r(7885),SemVer:i,re:n.re,src:n.src,tokens:n.t,SEMVER_SPEC_VERSION:o.SEMVER_SPEC_VERSION,RELEASE_TYPES:o.RELEASE_TYPES,compareIdentifiers:a.compareIdentifiers,rcompareIdentifiers:a.rcompareIdentifiers}},9345(e){"use strict";e.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:16,MAX_SAFE_BUILD_LENGTH:250,MAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER||0x1fffffffffffff,RELEASE_TYPES:["major","premajor","minor","preminor","patch","prepatch","prerelease"],SEMVER_SPEC_VERSION:"2.0.0",FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}},7139(e){"use strict";var t,r;function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}e.exports=("u"<typeof process?"undefined":(t=process)&&"u">typeof Symbol&&t.constructor===Symbol?"symbol":typeof t)=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?function(){for(var e=arguments.length,t=Array(e),o=0;o<e;o++)t[o]=arguments[o];return(r=console).error.apply(r,["SEMVER"].concat(function(e){if(Array.isArray(e))return n(e)}(t)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||function(e){if(e){if("string"==typeof e)return n(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return n(e,void 0)}}(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()))}:function(){}},6640(e){"use strict";var t=/^[0-9]+$/,r=function(e,r){if("number"==typeof e&&"number"==typeof r)return e===r?0:e<r?-1:1;var n=t.test(e),o=t.test(r);return n&&o&&(e*=1,r*=1),e===r?0:n&&!o?-1:o&&!n?1:e<r?-1:1};e.exports={compareIdentifiers:r,rcompareIdentifiers:function(e,t){return r(t,e)}}},3235(e){"use strict";e.exports=function(){var e;function t(){if(!(this instanceof t))throw TypeError("Cannot call a class as a function");this.max=1e3,this.map=new Map}return e=[{key:"get",value:function(e){var t=this.map.get(e);if(void 0!==t)return this.map.delete(e),this.map.set(e,t),t}},{key:"delete",value:function(e){return this.map.delete(e)}},{key:"set",value:function(e,t){if(!this.delete(e)&&void 0!==t){if(this.map.size>=this.max){var r=this.map.keys().next().value;this.delete(r)}this.map.set(e,t)}return this}}],function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,e),t}()},6480(e){"use strict";var t=Object.freeze({loose:!0}),r=Object.freeze({});e.exports=function(e){return e?(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)!="object"?t:e:r}},4299(e,t,r){"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var o=r(9345),i=o.MAX_SAFE_COMPONENT_LENGTH,a=o.MAX_SAFE_BUILD_LENGTH,u=o.MAX_LENGTH,s=r(7139),l=(t=e.exports={}).re=[],c=t.safeRe=[],d=t.src=[],f=t.safeSrc=[],p=t.t={},h=0,m="[a-zA-Z0-9-]",y=[["\\s",1],["\\d",u],[m,a]],b=function(e){var t=!0,r=!1,o=void 0;try{for(var i,a=y[Symbol.iterator]();!(t=(i=a.next()).done);t=!0){var u,s=(u=i.value,function(e){if(Array.isArray(e))return e}(u)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(u)||function(e){if(e){if("string"==typeof e)return n(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return n(e,2)}}(u)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),l=s[0],c=s[1];e=e.split("".concat(l,"*")).join("".concat(l,"{0,").concat(c,"}")).split("".concat(l,"+")).join("".concat(l,"{1,").concat(c,"}"))}}catch(e){r=!0,o=e}finally{try{t||null==a.return||a.return()}finally{if(r)throw o}}return e},v=function(e,t,r){var n=b(t),o=h++;s(e,o,t),p[e]=o,d[o]=t,f[o]=n,l[o]=new RegExp(t,r?"g":void 0),c[o]=new RegExp(n,r?"g":void 0)};v("NUMERICIDENTIFIER","0|[1-9]\\d*"),v("NUMERICIDENTIFIERLOOSE","\\d+"),v("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-]".concat(m,"*")),v("MAINVERSION","(".concat(d[p.NUMERICIDENTIFIER],")\\.")+"(".concat(d[p.NUMERICIDENTIFIER],")\\.")+"(".concat(d[p.NUMERICIDENTIFIER],")")),v("MAINVERSIONLOOSE","(".concat(d[p.NUMERICIDENTIFIERLOOSE],")\\.")+"(".concat(d[p.NUMERICIDENTIFIERLOOSE],")\\.")+"(".concat(d[p.NUMERICIDENTIFIERLOOSE],")")),v("PRERELEASEIDENTIFIER","(?:".concat(d[p.NONNUMERICIDENTIFIER],"|").concat(d[p.NUMERICIDENTIFIER],")")),v("PRERELEASEIDENTIFIERLOOSE","(?:".concat(d[p.NONNUMERICIDENTIFIER],"|").concat(d[p.NUMERICIDENTIFIERLOOSE],")")),v("PRERELEASE","(?:-(".concat(d[p.PRERELEASEIDENTIFIER],"(?:\\.").concat(d[p.PRERELEASEIDENTIFIER],")*))")),v("PRERELEASELOOSE","(?:-?(".concat(d[p.PRERELEASEIDENTIFIERLOOSE],"(?:\\.").concat(d[p.PRERELEASEIDENTIFIERLOOSE],")*))")),v("BUILDIDENTIFIER","".concat(m,"+")),v("BUILD","(?:\\+(".concat(d[p.BUILDIDENTIFIER],"(?:\\.").concat(d[p.BUILDIDENTIFIER],")*))")),v("FULLPLAIN","v?".concat(d[p.MAINVERSION]).concat(d[p.PRERELEASE],"?").concat(d[p.BUILD],"?")),v("FULL","^".concat(d[p.FULLPLAIN],"$")),v("LOOSEPLAIN","[v=\\s]*".concat(d[p.MAINVERSIONLOOSE]).concat(d[p.PRERELEASELOOSE],"?").concat(d[p.BUILD],"?")),v("LOOSE","^".concat(d[p.LOOSEPLAIN],"$")),v("GTLT","((?:<|>)?=?)"),v("XRANGEIDENTIFIERLOOSE","".concat(d[p.NUMERICIDENTIFIERLOOSE],"|x|X|\\*")),v("XRANGEIDENTIFIER","".concat(d[p.NUMERICIDENTIFIER],"|x|X|\\*")),v("XRANGEPLAIN","[v=\\s]*(".concat(d[p.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(d[p.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(d[p.XRANGEIDENTIFIER],")")+"(?:".concat(d[p.PRERELEASE],")?").concat(d[p.BUILD],"?")+")?)?"),v("XRANGEPLAINLOOSE","[v=\\s]*(".concat(d[p.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(d[p.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(d[p.XRANGEIDENTIFIERLOOSE],")")+"(?:".concat(d[p.PRERELEASELOOSE],")?").concat(d[p.BUILD],"?")+")?)?"),v("XRANGE","^".concat(d[p.GTLT],"\\s*").concat(d[p.XRANGEPLAIN],"$")),v("XRANGELOOSE","^".concat(d[p.GTLT],"\\s*").concat(d[p.XRANGEPLAINLOOSE],"$")),v("COERCEPLAIN","".concat("(^|[^\\d])(\\d{1,").concat(i,"})")+"(?:\\.(\\d{1,".concat(i,"}))?")+"(?:\\.(\\d{1,".concat(i,"}))?")),v("COERCE","".concat(d[p.COERCEPLAIN],"(?:$|[^\\d])")),v("COERCEFULL",d[p.COERCEPLAIN]+"(?:".concat(d[p.PRERELEASE],")?")+"(?:".concat(d[p.BUILD],")?")+"(?:$|[^\\d])"),v("COERCERTL",d[p.COERCE],!0),v("COERCERTLFULL",d[p.COERCEFULL],!0),v("LONETILDE","(?:~>?)"),v("TILDETRIM","(\\s*)".concat(d[p.LONETILDE],"\\s+"),!0),t.tildeTrimReplace="$1~",v("TILDE","^".concat(d[p.LONETILDE]).concat(d[p.XRANGEPLAIN],"$")),v("TILDELOOSE","^".concat(d[p.LONETILDE]).concat(d[p.XRANGEPLAINLOOSE],"$")),v("LONECARET","(?:\\^)"),v("CARETTRIM","(\\s*)".concat(d[p.LONECARET],"\\s+"),!0),t.caretTrimReplace="$1^",v("CARET","^".concat(d[p.LONECARET]).concat(d[p.XRANGEPLAIN],"$")),v("CARETLOOSE","^".concat(d[p.LONECARET]).concat(d[p.XRANGEPLAINLOOSE],"$")),v("COMPARATORLOOSE","^".concat(d[p.GTLT],"\\s*(").concat(d[p.LOOSEPLAIN],")$|^$")),v("COMPARATOR","^".concat(d[p.GTLT],"\\s*(").concat(d[p.FULLPLAIN],")$|^$")),v("COMPARATORTRIM","(\\s*)".concat(d[p.GTLT],"\\s*(").concat(d[p.LOOSEPLAIN],"|").concat(d[p.XRANGEPLAIN],")"),!0),t.comparatorTrimReplace="$1$2$3",v("HYPHENRANGE","^\\s*(".concat(d[p.XRANGEPLAIN],")")+"\\s+-\\s+"+"(".concat(d[p.XRANGEPLAIN],")")+"\\s*$"),v("HYPHENRANGELOOSE","^\\s*(".concat(d[p.XRANGEPLAINLOOSE],")")+"\\s+-\\s+"+"(".concat(d[p.XRANGEPLAINLOOSE],")")+"\\s*$"),v("STAR","(<|>)?=?\\s*\\*"),v("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),v("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")},2560(e,t,r){"use strict";var n=r(3452);e.exports=function(e,t,r){return n(e,t,">",r)}},453(e,t,r){"use strict";var n=r(7490);e.exports=function(e,t,r){return e=new n(e,r),t=new n(t,r),e.intersects(t,r)}},9801(e,t,r){"use strict";var n=r(3452);e.exports=function(e,t,r){return n(e,t,"<",r)}},5901(e,t,r){"use strict";var n=r(7583),o=r(7490);e.exports=function(e,t,r){var i=null,a=null,u=null;try{u=new o(t,r)}catch(e){return null}return e.forEach(function(e){u.test(e)&&(!i||-1===a.compare(e))&&(a=new n(i=e,r))}),i}},6975(e,t,r){"use strict";var n=r(7583),o=r(7490);e.exports=function(e,t,r){var i=null,a=null,u=null;try{u=new o(t,r)}catch(e){return null}return e.forEach(function(e){u.test(e)&&(!i||1===a.compare(e))&&(a=new n(i=e,r))}),i}},8158(e,t,r){"use strict";var n=r(7583),o=r(7490),i=r(4907);e.exports=function(e,t){e=new o(e,t);var r=new n("0.0.0");if(e.test(r)||(r=new n("0.0.0-0"),e.test(r)))return r;r=null;for(var a=0;a<e.set.length;++a)!function(t){var o=e.set[t],a=null;o.forEach(function(e){var t=new n(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":(!a||i(t,a))&&(a=t);break;case"<":case"<=":break;default:throw Error("Unexpected operation: ".concat(e.operator))}}),a&&(!r||i(r,a))&&(r=a)}(a);return r&&e.test(r)?r:null}},3452(e,t,r){"use strict";var n=r(7583),o=r(6503),i=o.ANY,a=r(7490),u=r(5775),s=r(4907),l=r(6228),c=r(4401),d=r(9928);e.exports=function(e,t,r,f){var p,h,m,y,b;switch(e=new n(e,f),t=new a(t,f),r){case">":p=s,h=c,m=l,y=">",b=">=";break;case"<":p=l,h=d,m=s,y="<",b="<=";break;default:throw TypeError('Must provide a hilo val of "<" or ">"')}if(u(e,t,f))return!1;for(var v=0;v<t.set.length;++v){var g=function(r){var n=t.set[r],a=null,u=null;return(n.forEach(function(e){e.semver===i&&(e=new o(">=0.0.0")),a=a||e,u=u||e,p(e.semver,a.semver,f)?a=e:m(e.semver,u.semver,f)&&(u=e)}),a.operator===y||a.operator===b||(!u.operator||u.operator===y)&&h(e,u.semver)||u.operator===b&&m(e,u.semver))?{v:!1}:void 0}(v);if("object"==(g&&"u">typeof Symbol&&g.constructor===Symbol?"symbol":typeof g))return g.v}return!0}},1784(e,t,r){"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var o=r(5775),i=r(2057);e.exports=function(e,t,r){var a=[],u=null,s=null,l=e.sort(function(e,t){return i(e,t,r)}),c=!0,d=!1,f=void 0;try{for(var p,h=l[Symbol.iterator]();!(c=(p=h.next()).done);c=!0){var m=p.value;o(m,t,r)?(s=m,u||(u=m)):(s&&a.push([u,s]),s=null,u=null)}}catch(e){d=!0,f=e}finally{try{c||null==h.return||h.return()}finally{if(d)throw f}}u&&a.push([u,null]);var y=[],b=!0,v=!1,g=void 0;try{for(var w,E=a[Symbol.iterator]();!(b=(w=E.next()).done);b=!0){var S,O=(S=w.value,function(e){if(Array.isArray(e))return e}(S)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(S)||function(e){if(e){if("string"==typeof e)return n(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return n(e,2)}}(S)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),A=O[0],x=O[1];A===x?y.push(A):x||A!==l[0]?x?A===l[0]?y.push("<=".concat(x)):y.push("".concat(A," - ").concat(x)):y.push(">=".concat(A)):y.push("*")}}catch(e){v=!0,g=e}finally{try{b||null==E.return||E.return()}finally{if(v)throw g}}var D=y.join(" || "),j="string"==typeof t.raw?t.raw:String(t);return D.length<j.length?D:t}},7885(e,t,r){"use strict";var n=r(7490),o=r(6503),i=o.ANY,a=r(5775),u=r(2057),s=[new o(">=0.0.0-0")],l=[new o(">=0.0.0")],c=function(e,t,r){if(e===t)return!0;if(1===e.length&&e[0].semver===i)if(1===t.length&&t[0].semver===i)return!0;else e=r.includePrerelease?s:l;if(1===t.length&&t[0].semver===i)if(r.includePrerelease)return!0;else t=l;var n=new Set,o=!0,c=!1,p=void 0;try{for(var h,m,y,b=e[Symbol.iterator]();!(o=(y=b.next()).done);o=!0){var v=y.value;">"===v.operator||">="===v.operator?h=d(h,v,r):"<"===v.operator||"<="===v.operator?m=f(m,v,r):n.add(v.semver)}}catch(e){c=!0,p=e}finally{try{o||null==b.return||b.return()}finally{if(c)throw p}}if(n.size>1)return null;if(h&&m&&((S=u(h.semver,m.semver,r))>0||0===S&&(">="!==h.operator||"<="!==m.operator)))return null;var g=!0,w=!1,E=void 0;try{for(var S,O,A=n[Symbol.iterator]();!(g=(O=A.next()).done);g=!0){var x=O.value;if(h&&!a(x,String(h),r)||m&&!a(x,String(m),r))return null;var D=!0,j=!1,C=void 0;try{for(var P,k=t[Symbol.iterator]();!(D=(P=k.next()).done);D=!0){var I=P.value;if(!a(x,String(I),r))return!1}}catch(e){j=!0,C=e}finally{try{D||null==k.return||k.return()}finally{if(j)throw C}}return!0}}catch(e){w=!0,E=e}finally{try{g||null==A.return||A.return()}finally{if(w)throw E}}var T=!!m&&!r.includePrerelease&&!!m.semver.prerelease.length&&m.semver,R=!!h&&!r.includePrerelease&&!!h.semver.prerelease.length&&h.semver;T&&1===T.prerelease.length&&"<"===m.operator&&0===T.prerelease[0]&&(T=!1);var F=!0,N=!1,M=void 0;try{for(var B,L,V,U,$,W=t[Symbol.iterator]();!(F=($=W.next()).done);F=!0){var z=$.value;if(U=U||">"===z.operator||">="===z.operator,V=V||"<"===z.operator||"<="===z.operator,h){if(R&&z.semver.prerelease&&z.semver.prerelease.length&&z.semver.major===R.major&&z.semver.minor===R.minor&&z.semver.patch===R.patch&&(R=!1),">"===z.operator||">="===z.operator){if((B=d(h,z,r))===z&&B!==h)return!1}else if(">="===h.operator&&!a(h.semver,String(z),r))return!1}if(m){if(T&&z.semver.prerelease&&z.semver.prerelease.length&&z.semver.major===T.major&&z.semver.minor===T.minor&&z.semver.patch===T.patch&&(T=!1),"<"===z.operator||"<="===z.operator){if((L=f(m,z,r))===z&&L!==m)return!1}else if("<="===m.operator&&!a(m.semver,String(z),r))return!1}if(!z.operator&&(m||h)&&0!==S)return!1}}catch(e){N=!0,M=e}finally{try{F||null==W.return||W.return()}finally{if(N)throw M}}return(!h||!V||!!m||0===S)&&(!m||!U||!!h||0===S)&&!R&&!T&&!0},d=function(e,t,r){if(!e)return t;var n=u(e.semver,t.semver,r);return n>0?e:n<0||">"===t.operator&&">="===e.operator?t:e},f=function(e,t,r){if(!e)return t;var n=u(e.semver,t.semver,r);return n<0?e:n>0||"<"===t.operator&&"<="===e.operator?t:e};e.exports=function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(e===t)return!0;e=new n(e,r),t=new n(t,r);var o=!1,i=!0,a=!1,u=void 0;try{e:for(var s,l=e.set[Symbol.iterator]();!(i=(s=l.next()).done);i=!0){var d=s.value,f=!0,p=!1,h=void 0;try{for(var m,y=t.set[Symbol.iterator]();!(f=(m=y.next()).done);f=!0){var b=m.value,v=c(d,b,r);if(o=o||null!==v,v)continue e}}catch(e){p=!0,h=e}finally{try{f||null==y.return||y.return()}finally{if(p)throw h}}if(o)return!1}}catch(e){a=!0,u=e}finally{try{i||null==l.return||l.return()}finally{if(a)throw u}}return!0}},7690(e,t,r){"use strict";var n=r(7490);e.exports=function(e,t){return new n(e,t).set.map(function(e){return e.map(function(e){return e.value}).join(" ").trim().split(" ")})}},3429(e,t,r){"use strict";var n=r(7490);e.exports=function(e,t){try{return new n(e,t).range||"*"}catch(e){return null}}},3642(e,t,r){"use strict";var n=r(6925),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=n.useState,a=n.useEffect,u=n.useLayoutEffect,s=n.useDebugValue;function l(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!o(e,r)}catch(e){return!0}}var c="u"<typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var r=t(),n=i({inst:{value:r,getSnapshot:t}}),o=n[0].inst,c=n[1];return u(function(){o.value=r,o.getSnapshot=t,l(o)&&c({inst:o})},[e,r,t]),a(function(){return l(o)&&c({inst:o}),e(function(){l(o)&&c({inst:o})})},[e]),s(r),r};t.useSyncExternalStore=void 0!==n.useSyncExternalStore?n.useSyncExternalStore:c},8597(e,t,r){"use strict";e.exports=r(3642)},188(e,t,r){"use strict";r.d(t,{A:()=>s});let n="u">typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto);for(var o,i=new Uint8Array(16),a=[],u=0;u<256;++u)a.push((u+256).toString(16).slice(1));let s=function(e,t,r){if(n&&!t&&!e)return n();var u=(e=e||{}).random||(e.rng||function(){if(!o&&!(o="u">typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)))throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return o(i)})();if(u[6]=15&u[6]|64,u[8]=63&u[8]|128,t){r=r||0;for(var s=0;s<16;++s)t[r+s]=u[s];return t}return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return a[e[t+0]]+a[e[t+1]]+a[e[t+2]]+a[e[t+3]]+"-"+a[e[t+4]]+a[e[t+5]]+"-"+a[e[t+6]]+a[e[t+7]]+"-"+a[e[t+8]]+a[e[t+9]]+"-"+a[e[t+10]]+a[e[t+11]]+a[e[t+12]]+a[e[t+13]]+a[e[t+14]]+a[e[t+15]]}(u)}},5794(e,t,r){"use strict";r.d(t,{D3:()=>d,jj:()=>f,uA:()=>c,B4:()=>h,sM:()=>p,jX:()=>l});var n=r(2883);function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function a(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){i(e,t,r[t])})}return e}function u(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var s={flags:function(){var e={},t=!0,r=!1,n=void 0;try{for(var o,i=Object.keys(localStorage)[Symbol.iterator]();!(t=(o=i.next()).done);t=!0){var u=o.value;if(u.startsWith("openmrs:feature-flag:")){var s=u.replace("openmrs:feature-flag:",""),l=JSON.parse(localStorage.getItem("openmrs:feature-flag-meta:".concat(s))||"{}");e[s]=a({enabled:"true"===localStorage.getItem(u)},l)}}}catch(e){r=!0,n=e}finally{try{t||null==i.return||i.return()}finally{if(r)throw n}}return e}()},l=(0,n.jf)("feature-flags",s);function c(e,t,r){l.setState(function(n){var o,s;return{flags:u(a({},n.flags),i({},e,{enabled:null!=(o=null==(s=n.flags[e])?void 0:s.enabled)&&o,label:t,description:r}))}})}function d(){var e=l.getState().flags;Object.keys(localStorage).filter(function(e){return e.startsWith("openmrs:feature-flag:")}).forEach(function(t){var r=t.replace("openmrs:feature-flag:","");e[r]||(localStorage.removeItem(t),localStorage.removeItem("openmrs:feature-flag-meta:".concat(r)))})}function f(e){return l.getState().flags[e].enabled}function p(e,t){l.subscribe(function(r){t(r.flags[e].enabled)})}function h(e,t){l.setState(function(r){return{flags:u(a({},r.flags),i({},e,u(a({},r.flags[e]),{enabled:t})))}})}l.subscribe(function(e){var t=!0,r=!1,n=void 0;try{for(var i,a=Object.entries(e.flags)[Symbol.iterator]();!(t=(i=a.next()).done);t=!0){var u,s=(u=i.value,function(e){if(Array.isArray(e))return e}(u)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(u)||function(e){if(e){if("string"==typeof e)return o(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return o(e,2)}}(u)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),l=s[0],c=s[1];localStorage.setItem("openmrs:feature-flag:".concat(l),c.enabled.toString()),localStorage.setItem("openmrs:feature-flag-meta:".concat(l),JSON.stringify({label:c.label,description:c.description}))}}catch(e){r=!0,n=e}finally{try{t||null==a.return||a.return()}finally{if(r)throw n}}})},1017(e,t,r){"use strict";r.d(t,{u:()=>a});var n=r(7994),o=["red","magenta","purple","blue","teal","cyan","gray","green","warm-gray","cool-gray","high-contrast","outline"],i={primaryColor:{_type:n.ZU.String,_description:"The color for displaying primary diagnoses tags",_default:"red",_validators:[n.y$.oneOf(o)]},secondaryColor:{_type:n.ZU.String,_description:"The color for displaying secondary diagnoses tags",_default:"blue",_validators:[n.y$.oneOf(o)]}},a={"Brand color #1":{_default:"#005d5d",_type:n.ZU.String},"Brand color #2":{_default:"#004144",_type:n.ZU.String},"Brand color #3":{_default:"#007d79",_type:n.ZU.String},excludePatientIdentifierCodeTypes:{uuids:{_type:n.ZU.Array,_description:"List of UUIDs of patient identifier types to exclude from rendering in the patient banner",_default:[],_elements:{_type:n.ZU.UUID}}},implementationName:{_type:n.ZU.String,_description:"A name of the place (or authority) where all possible locations a user can choose are located.",_default:"Clinic"},patientPhotoConceptUuid:{_type:n.ZU.ConceptUuid,_default:"736e8771-e501-4615-bfa7-570c03f4bef5",_description:"Used to look up the patient photo, which is stored as an attachment obs. Set to `null` in order to disable the feature and use only generated avatars. To remove the avatars entirely, use extension configuration's `remove` feature."},preferredCalendar:{_type:n.ZU.Object,_description:"Keys should be locale codes, and values should be the preferred calendar for that locale. For example, {'am': 'ethiopic'}.",_default:{am:"ethiopic"},_elements:{_validators:[n.y$.oneOf(["buddhist","chinese","coptic","dangi","ethioaa","ethiopic","gregory","hebrew","indian","islamic","islamic-umalqura","islamic-tbla","islamic-civil","islamic-rgsa","iso8601","japanese","persian","roc","islamicc"])]}},preferredDateLocale:{_type:n.ZU.Object,_description:"Allows setting the locale used for date formatting for any browser locale. Does not affect time formatting. Keys should be locale codes, and values should be the preferred locale for formatting dates. For example, {'en': 'en-US', 'fr-CA': 'en-CA'}.",_default:{en:"en-GB"},_elements:{_type:n.ZU.String}},diagnosisTags:i}},7488(e,t,r){"use strict";r.d(t,{Ay:()=>c,BE:()=>l});var n=r(6925),o=r.n(n),i=r(8597),a=r(9593);let u=o().use||(e=>{if("pending"===e.status)throw e;if("fulfilled"===e.status)return e.value;if("rejected"===e.status)throw e.reason;throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}),s={dedupe:!0},l=a.OBJECT.defineProperty(a.SWRConfig,"defaultValue",{value:a.defaultConfig}),c=(0,a.withArgs)((e,t,r)=>{let{cache:o,compare:l,suspense:c,fallbackData:d,revalidateOnMount:f,revalidateIfStale:p,refreshInterval:h,refreshWhenHidden:m,refreshWhenOffline:y,keepPreviousData:b}=r,[v,g,w,E]=a.SWRGlobalState.get(o),[S,O]=(0,a.serialize)(e),A=(0,n.useRef)(!1),x=(0,n.useRef)(!1),D=(0,n.useRef)(S),j=(0,n.useRef)(t),C=(0,n.useRef)(r),P=()=>C.current.isVisible()&&C.current.isOnline(),[k,I,T,R]=(0,a.createCacheHelper)(o,S),F=(0,n.useRef)({}).current,N=(0,a.isUndefined)(d)?r.fallback[S]:d,M=(e,t)=>{for(let r in F)if("data"===r){if(!l(e[r],t[r])&&(!(0,a.isUndefined)(e[r])||!l(H,t[r])))return!1}else if(t[r]!==e[r])return!1;return!0},B=(0,n.useMemo)(()=>{let e=!!S&&!!t&&((0,a.isUndefined)(f)?!C.current.isPaused()&&!c&&(!!(0,a.isUndefined)(p)||p):f),r=t=>{let r=(0,a.mergeObjects)(t);return(delete r._k,e)?{isValidating:!0,isLoading:!0,...r}:r},n=k(),o=R(),i=r(n),u=n===o?i:r(o),s=i;return[()=>{let e=r(k());return M(e,s)?(s.data=e.data,s.isLoading=e.isLoading,s.isValidating=e.isValidating,s.error=e.error,s):(s=e,e)},()=>u]},[o,S]),L=(0,i.useSyncExternalStore)((0,n.useCallback)(e=>T(S,(t,r)=>{M(r,t)||e()}),[o,S]),B[0],B[1]),V=!A.current,U=v[S]&&v[S].length>0,$=L.data,W=(0,a.isUndefined)($)?N:$,z=L.error,K=(0,n.useRef)(W),H=b?(0,a.isUndefined)($)?K.current:$:W,G=(!U||!!(0,a.isUndefined)(z))&&(V&&!(0,a.isUndefined)(f)?f:!C.current.isPaused()&&(c?!(0,a.isUndefined)(W)&&p:(0,a.isUndefined)(W)||p)),q=!!(S&&t&&V&&G),Z=(0,a.isUndefined)(L.isValidating)?q:L.isValidating,Y=(0,a.isUndefined)(L.isLoading)?q:L.isLoading,J=(0,n.useCallback)(async e=>{let t,n,o=j.current;if(!S||!o||x.current||C.current.isPaused())return!1;let i=!0,u=e||{},s=!w[S]||!u.dedupe,c=()=>a.IS_REACT_LEGACY?!x.current&&S===D.current&&A.current:S===D.current,d={isValidating:!1,isLoading:!1},f=()=>{I(d)},p=()=>{let e=w[S];e&&e[1]===n&&delete w[S]},h={isValidating:!0};(0,a.isUndefined)(k().data)&&(h.isLoading=!0);try{if(s&&(I(h),r.loadingTimeout&&(0,a.isUndefined)(k().data)&&setTimeout(()=>{i&&c()&&C.current.onLoadingSlow(S,r)},r.loadingTimeout),w[S]=[o(O),(0,a.getTimestamp)()]),[t,n]=w[S],t=await t,s&&setTimeout(p,r.dedupingInterval),!w[S]||w[S][1]!==n)return s&&c()&&C.current.onDiscarded(S),!1;d.error=a.UNDEFINED;let e=g[S];if(!(0,a.isUndefined)(e)&&(n<=e[0]||n<=e[1]||0===e[1]))return f(),s&&c()&&C.current.onDiscarded(S),!1;let u=k().data;d.data=l(u,t)?u:t,s&&c()&&C.current.onSuccess(t,S,r)}catch(r){p();let e=C.current,{shouldRetryOnError:t}=e;!e.isPaused()&&(d.error=r,s&&c()&&(e.onError(r,S,e),(!0===t||(0,a.isFunction)(t)&&t(r))&&(!C.current.revalidateOnFocus||!C.current.revalidateOnReconnect||P())&&e.onErrorRetry(r,S,e,e=>{let t=v[S];t&&t[0]&&t[0](a.revalidateEvents.ERROR_REVALIDATE_EVENT,e)},{retryCount:(u.retryCount||0)+1,dedupe:!0})))}return i=!1,f(),!0},[S,o]),X=(0,n.useCallback)((...e)=>(0,a.internalMutate)(o,D.current,...e),[]);if((0,a.useIsomorphicLayoutEffect)(()=>{j.current=t,C.current=r,(0,a.isUndefined)($)||(K.current=$)}),(0,a.useIsomorphicLayoutEffect)(()=>{if(!S)return;let e=J.bind(a.UNDEFINED,s),t=0,r=(0,a.subscribeCallback)(S,v,(r,n={})=>{if(r==a.revalidateEvents.FOCUS_EVENT){let r=Date.now();C.current.revalidateOnFocus&&r>t&&P()&&(t=r+C.current.focusThrottleInterval,e())}else if(r==a.revalidateEvents.RECONNECT_EVENT)C.current.revalidateOnReconnect&&P()&&e();else if(r==a.revalidateEvents.MUTATE_EVENT)return J();else if(r==a.revalidateEvents.ERROR_REVALIDATE_EVENT)return J(n)});return x.current=!1,D.current=S,A.current=!0,I({_k:O}),G&&((0,a.isUndefined)(W)||a.IS_SERVER?e():(0,a.rAF)(e)),()=>{x.current=!0,r()}},[S]),(0,a.useIsomorphicLayoutEffect)(()=>{let e;function t(){let t=(0,a.isFunction)(h)?h(k().data):h;t&&-1!==e&&(e=setTimeout(r,t))}function r(){!k().error&&(m||C.current.isVisible())&&(y||C.current.isOnline())?J(s).then(t):t()}return t(),()=>{e&&(clearTimeout(e),e=-1)}},[h,m,y,S]),(0,n.useDebugValue)(H),c&&(0,a.isUndefined)(W)&&S){if(!a.IS_REACT_LEGACY&&a.IS_SERVER)throw Error("Fallback data is required when using suspense in SSR.");j.current=t,C.current=r,x.current=!1;let e=E[S];if((0,a.isUndefined)(e)||u(X(e)),(0,a.isUndefined)(z)){let e=J(s);(0,a.isUndefined)(H)||(e.status="fulfilled",e.value=!0),u(e)}else throw z}return{mutate:X,get data(){return F.data=!0,H},get error(){return F.error=!0,z},get isValidating(){return F.isValidating=!0,Z},get isLoading(){return F.isLoading=!0,Y}}})},6269(e,t,r){"use strict";r.d(t,{A:()=>c});var n=r(6925),o=r.n(n),i=r(8597),a=r(9593);let u=o().use||(e=>{if("pending"===e.status)throw e;if("fulfilled"===e.status)return e.value;if("rejected"===e.status)throw e.reason;throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}),s={dedupe:!0};a.OBJECT.defineProperty(a.SWRConfig,"defaultValue",{value:a.defaultConfig});let l=(0,a.withArgs)((e,t,r)=>{let{cache:o,compare:l,suspense:c,fallbackData:d,revalidateOnMount:f,revalidateIfStale:p,refreshInterval:h,refreshWhenHidden:m,refreshWhenOffline:y,keepPreviousData:b}=r,[v,g,w,E]=a.SWRGlobalState.get(o),[S,O]=(0,a.serialize)(e),A=(0,n.useRef)(!1),x=(0,n.useRef)(!1),D=(0,n.useRef)(S),j=(0,n.useRef)(t),C=(0,n.useRef)(r),P=()=>C.current.isVisible()&&C.current.isOnline(),[k,I,T,R]=(0,a.createCacheHelper)(o,S),F=(0,n.useRef)({}).current,N=(0,a.isUndefined)(d)?r.fallback[S]:d,M=(e,t)=>{for(let r in F)if("data"===r){if(!l(e[r],t[r])&&(!(0,a.isUndefined)(e[r])||!l(H,t[r])))return!1}else if(t[r]!==e[r])return!1;return!0},B=(0,n.useMemo)(()=>{let e=!!S&&!!t&&((0,a.isUndefined)(f)?!C.current.isPaused()&&!c&&(!!(0,a.isUndefined)(p)||p):f),r=t=>{let r=(0,a.mergeObjects)(t);return(delete r._k,e)?{isValidating:!0,isLoading:!0,...r}:r},n=k(),o=R(),i=r(n),u=n===o?i:r(o),s=i;return[()=>{let e=r(k());return M(e,s)?(s.data=e.data,s.isLoading=e.isLoading,s.isValidating=e.isValidating,s.error=e.error,s):(s=e,e)},()=>u]},[o,S]),L=(0,i.useSyncExternalStore)((0,n.useCallback)(e=>T(S,(t,r)=>{M(r,t)||e()}),[o,S]),B[0],B[1]),V=!A.current,U=v[S]&&v[S].length>0,$=L.data,W=(0,a.isUndefined)($)?N:$,z=L.error,K=(0,n.useRef)(W),H=b?(0,a.isUndefined)($)?K.current:$:W,G=(!U||!!(0,a.isUndefined)(z))&&(V&&!(0,a.isUndefined)(f)?f:!C.current.isPaused()&&(c?!(0,a.isUndefined)(W)&&p:(0,a.isUndefined)(W)||p)),q=!!(S&&t&&V&&G),Z=(0,a.isUndefined)(L.isValidating)?q:L.isValidating,Y=(0,a.isUndefined)(L.isLoading)?q:L.isLoading,J=(0,n.useCallback)(async e=>{let t,n,o=j.current;if(!S||!o||x.current||C.current.isPaused())return!1;let i=!0,u=e||{},s=!w[S]||!u.dedupe,c=()=>a.IS_REACT_LEGACY?!x.current&&S===D.current&&A.current:S===D.current,d={isValidating:!1,isLoading:!1},f=()=>{I(d)},p=()=>{let e=w[S];e&&e[1]===n&&delete w[S]},h={isValidating:!0};(0,a.isUndefined)(k().data)&&(h.isLoading=!0);try{if(s&&(I(h),r.loadingTimeout&&(0,a.isUndefined)(k().data)&&setTimeout(()=>{i&&c()&&C.current.onLoadingSlow(S,r)},r.loadingTimeout),w[S]=[o(O),(0,a.getTimestamp)()]),[t,n]=w[S],t=await t,s&&setTimeout(p,r.dedupingInterval),!w[S]||w[S][1]!==n)return s&&c()&&C.current.onDiscarded(S),!1;d.error=a.UNDEFINED;let e=g[S];if(!(0,a.isUndefined)(e)&&(n<=e[0]||n<=e[1]||0===e[1]))return f(),s&&c()&&C.current.onDiscarded(S),!1;let u=k().data;d.data=l(u,t)?u:t,s&&c()&&C.current.onSuccess(t,S,r)}catch(r){p();let e=C.current,{shouldRetryOnError:t}=e;!e.isPaused()&&(d.error=r,s&&c()&&(e.onError(r,S,e),(!0===t||(0,a.isFunction)(t)&&t(r))&&(!C.current.revalidateOnFocus||!C.current.revalidateOnReconnect||P())&&e.onErrorRetry(r,S,e,e=>{let t=v[S];t&&t[0]&&t[0](a.revalidateEvents.ERROR_REVALIDATE_EVENT,e)},{retryCount:(u.retryCount||0)+1,dedupe:!0})))}return i=!1,f(),!0},[S,o]),X=(0,n.useCallback)((...e)=>(0,a.internalMutate)(o,D.current,...e),[]);if((0,a.useIsomorphicLayoutEffect)(()=>{j.current=t,C.current=r,(0,a.isUndefined)($)||(K.current=$)}),(0,a.useIsomorphicLayoutEffect)(()=>{if(!S)return;let e=J.bind(a.UNDEFINED,s),t=0,r=(0,a.subscribeCallback)(S,v,(r,n={})=>{if(r==a.revalidateEvents.FOCUS_EVENT){let r=Date.now();C.current.revalidateOnFocus&&r>t&&P()&&(t=r+C.current.focusThrottleInterval,e())}else if(r==a.revalidateEvents.RECONNECT_EVENT)C.current.revalidateOnReconnect&&P()&&e();else if(r==a.revalidateEvents.MUTATE_EVENT)return J();else if(r==a.revalidateEvents.ERROR_REVALIDATE_EVENT)return J(n)});return x.current=!1,D.current=S,A.current=!0,I({_k:O}),G&&((0,a.isUndefined)(W)||a.IS_SERVER?e():(0,a.rAF)(e)),()=>{x.current=!0,r()}},[S]),(0,a.useIsomorphicLayoutEffect)(()=>{let e;function t(){let t=(0,a.isFunction)(h)?h(k().data):h;t&&-1!==e&&(e=setTimeout(r,t))}function r(){!k().error&&(m||C.current.isVisible())&&(y||C.current.isOnline())?J(s).then(t):t()}return t(),()=>{e&&(clearTimeout(e),e=-1)}},[h,m,y,S]),(0,n.useDebugValue)(H),c&&(0,a.isUndefined)(W)&&S){if(!a.IS_REACT_LEGACY&&a.IS_SERVER)throw Error("Fallback data is required when using suspense in SSR.");j.current=t,C.current=r,x.current=!1;let e=E[S];if((0,a.isUndefined)(e)||u(X(e)),(0,a.isUndefined)(z)){let e=J(s);(0,a.isUndefined)(H)||(e.status="fulfilled",e.value=!0),u(e)}else throw z}return{mutate:X,get data(){return F.data=!0,H},get error(){return F.error=!0,z},get isValidating(){return F.isValidating=!0,Z},get isLoading(){return F.isLoading=!0,Y}}}),c=(0,a.withMiddleware)(l,e=>(t,r,n)=>(n.revalidateOnFocus=!1,n.revalidateIfStale=!1,n.revalidateOnReconnect=!1,e(t,r,n)))},3709(e,t,r){"use strict";r.d(t,{Ay:()=>d});var n=r(6925),o=r.n(n),i=r(8597),a=r(9593);let u=o().use||(e=>{if("pending"===e.status)throw e;if("fulfilled"===e.status)return e.value;if("rejected"===e.status)throw e.reason;throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}),s={dedupe:!0};a.OBJECT.defineProperty(a.SWRConfig,"defaultValue",{value:a.defaultConfig});let l=(0,a.withArgs)((e,t,r)=>{let{cache:o,compare:l,suspense:c,fallbackData:d,revalidateOnMount:f,revalidateIfStale:p,refreshInterval:h,refreshWhenHidden:m,refreshWhenOffline:y,keepPreviousData:b}=r,[v,g,w,E]=a.SWRGlobalState.get(o),[S,O]=(0,a.serialize)(e),A=(0,n.useRef)(!1),x=(0,n.useRef)(!1),D=(0,n.useRef)(S),j=(0,n.useRef)(t),C=(0,n.useRef)(r),P=()=>C.current.isVisible()&&C.current.isOnline(),[k,I,T,R]=(0,a.createCacheHelper)(o,S),F=(0,n.useRef)({}).current,N=(0,a.isUndefined)(d)?r.fallback[S]:d,M=(e,t)=>{for(let r in F)if("data"===r){if(!l(e[r],t[r])&&(!(0,a.isUndefined)(e[r])||!l(H,t[r])))return!1}else if(t[r]!==e[r])return!1;return!0},B=(0,n.useMemo)(()=>{let e=!!S&&!!t&&((0,a.isUndefined)(f)?!C.current.isPaused()&&!c&&(!!(0,a.isUndefined)(p)||p):f),r=t=>{let r=(0,a.mergeObjects)(t);return(delete r._k,e)?{isValidating:!0,isLoading:!0,...r}:r},n=k(),o=R(),i=r(n),u=n===o?i:r(o),s=i;return[()=>{let e=r(k());return M(e,s)?(s.data=e.data,s.isLoading=e.isLoading,s.isValidating=e.isValidating,s.error=e.error,s):(s=e,e)},()=>u]},[o,S]),L=(0,i.useSyncExternalStore)((0,n.useCallback)(e=>T(S,(t,r)=>{M(r,t)||e()}),[o,S]),B[0],B[1]),V=!A.current,U=v[S]&&v[S].length>0,$=L.data,W=(0,a.isUndefined)($)?N:$,z=L.error,K=(0,n.useRef)(W),H=b?(0,a.isUndefined)($)?K.current:$:W,G=(!U||!!(0,a.isUndefined)(z))&&(V&&!(0,a.isUndefined)(f)?f:!C.current.isPaused()&&(c?!(0,a.isUndefined)(W)&&p:(0,a.isUndefined)(W)||p)),q=!!(S&&t&&V&&G),Z=(0,a.isUndefined)(L.isValidating)?q:L.isValidating,Y=(0,a.isUndefined)(L.isLoading)?q:L.isLoading,J=(0,n.useCallback)(async e=>{let t,n,o=j.current;if(!S||!o||x.current||C.current.isPaused())return!1;let i=!0,u=e||{},s=!w[S]||!u.dedupe,c=()=>a.IS_REACT_LEGACY?!x.current&&S===D.current&&A.current:S===D.current,d={isValidating:!1,isLoading:!1},f=()=>{I(d)},p=()=>{let e=w[S];e&&e[1]===n&&delete w[S]},h={isValidating:!0};(0,a.isUndefined)(k().data)&&(h.isLoading=!0);try{if(s&&(I(h),r.loadingTimeout&&(0,a.isUndefined)(k().data)&&setTimeout(()=>{i&&c()&&C.current.onLoadingSlow(S,r)},r.loadingTimeout),w[S]=[o(O),(0,a.getTimestamp)()]),[t,n]=w[S],t=await t,s&&setTimeout(p,r.dedupingInterval),!w[S]||w[S][1]!==n)return s&&c()&&C.current.onDiscarded(S),!1;d.error=a.UNDEFINED;let e=g[S];if(!(0,a.isUndefined)(e)&&(n<=e[0]||n<=e[1]||0===e[1]))return f(),s&&c()&&C.current.onDiscarded(S),!1;let u=k().data;d.data=l(u,t)?u:t,s&&c()&&C.current.onSuccess(t,S,r)}catch(r){p();let e=C.current,{shouldRetryOnError:t}=e;!e.isPaused()&&(d.error=r,s&&c()&&(e.onError(r,S,e),(!0===t||(0,a.isFunction)(t)&&t(r))&&(!C.current.revalidateOnFocus||!C.current.revalidateOnReconnect||P())&&e.onErrorRetry(r,S,e,e=>{let t=v[S];t&&t[0]&&t[0](a.revalidateEvents.ERROR_REVALIDATE_EVENT,e)},{retryCount:(u.retryCount||0)+1,dedupe:!0})))}return i=!1,f(),!0},[S,o]),X=(0,n.useCallback)((...e)=>(0,a.internalMutate)(o,D.current,...e),[]);if((0,a.useIsomorphicLayoutEffect)(()=>{j.current=t,C.current=r,(0,a.isUndefined)($)||(K.current=$)}),(0,a.useIsomorphicLayoutEffect)(()=>{if(!S)return;let e=J.bind(a.UNDEFINED,s),t=0,r=(0,a.subscribeCallback)(S,v,(r,n={})=>{if(r==a.revalidateEvents.FOCUS_EVENT){let r=Date.now();C.current.revalidateOnFocus&&r>t&&P()&&(t=r+C.current.focusThrottleInterval,e())}else if(r==a.revalidateEvents.RECONNECT_EVENT)C.current.revalidateOnReconnect&&P()&&e();else if(r==a.revalidateEvents.MUTATE_EVENT)return J();else if(r==a.revalidateEvents.ERROR_REVALIDATE_EVENT)return J(n)});return x.current=!1,D.current=S,A.current=!0,I({_k:O}),G&&((0,a.isUndefined)(W)||a.IS_SERVER?e():(0,a.rAF)(e)),()=>{x.current=!0,r()}},[S]),(0,a.useIsomorphicLayoutEffect)(()=>{let e;function t(){let t=(0,a.isFunction)(h)?h(k().data):h;t&&-1!==e&&(e=setTimeout(r,t))}function r(){!k().error&&(m||C.current.isVisible())&&(y||C.current.isOnline())?J(s).then(t):t()}return t(),()=>{e&&(clearTimeout(e),e=-1)}},[h,m,y,S]),(0,n.useDebugValue)(H),c&&(0,a.isUndefined)(W)&&S){if(!a.IS_REACT_LEGACY&&a.IS_SERVER)throw Error("Fallback data is required when using suspense in SSR.");j.current=t,C.current=r,x.current=!1;let e=E[S];if((0,a.isUndefined)(e)||u(X(e)),(0,a.isUndefined)(z)){let e=J(s);(0,a.isUndefined)(H)||(e.status="fulfilled",e.value=!0),u(e)}else throw z}return{mutate:X,get data(){return F.data=!0,H},get error(){return F.error=!0,z},get isValidating(){return F.isValidating=!0,Z},get isLoading(){return F.isLoading=!0,Y}}}),c=Promise.resolve(),d=(0,a.withMiddleware)(l,e=>(t,r,o)=>{let u,s=(0,n.useRef)(!1),{cache:l,initialSize:d=1,revalidateAll:f=!1,persistSize:p=!1,revalidateFirstPage:h=!0,revalidateOnMount:m=!1,parallel:y=!1}=o,[,,,b]=a.SWRGlobalState.get(a.cache);try{(u=(0,a.serialize)(t?t(0,null):null)[0])&&(u=a.INFINITE_PREFIX+u)}catch(e){}let[v,g,w]=(0,a.createCacheHelper)(l,u),E=(0,n.useCallback)(()=>(0,a.isUndefined)(v()._l)?d:v()._l,[l,u,d]);(0,i.useSyncExternalStore)((0,n.useCallback)(e=>u?w(u,()=>{e()}):()=>{},[l,u]),E,E);let S=(0,n.useCallback)(()=>{let e=v()._l;return(0,a.isUndefined)(e)?d:e},[u,d]),O=(0,n.useRef)(S());(0,a.useIsomorphicLayoutEffect)(()=>{if(!s.current){s.current=!0;return}u&&g({_l:p?O.current:S()})},[u,l]);let A=m&&!s.current,x=e(u,async e=>{let n=v()._i,i=v()._r;g({_r:a.UNDEFINED});let u=[],s=S(),[c]=(0,a.createCacheHelper)(l,e),d=c().data,p=[],m=null;for(let e=0;e<s;++e){let[s,c]=(0,a.serialize)(t(e,y?null:m));if(!s)break;let[v,g]=(0,a.createCacheHelper)(l,s),w=v().data,E=f||n||(0,a.isUndefined)(w)||h&&!e&&!(0,a.isUndefined)(d)||A||d&&!(0,a.isUndefined)(d[e])&&!o.compare(d[e],w);if(r&&("function"==typeof i?i(w,c):E)){let t=async()=>{if(s in b){let e=b[s];delete b[s],w=await e}else w=await r(c);g({data:w,_k:c}),u[e]=w};y?p.push(t):await t()}else u[e]=w;y||(m=w)}return y&&await Promise.all(p.map(e=>e())),g({_i:a.UNDEFINED}),u},o),D=(0,n.useCallback)(function(e,t){let r="boolean"==typeof t?{revalidate:t}:t||{},n=!1!==r.revalidate;return u?(n&&((0,a.isUndefined)(e)?g({_i:!0,_r:r.revalidate}):g({_i:!1,_r:r.revalidate})),arguments.length?x.mutate(e,{...r,revalidate:n}):x.mutate()):c},[u,l]),j=(0,n.useCallback)(e=>{let r;if(!u)return c;let[,n]=(0,a.createCacheHelper)(l,u);if((0,a.isFunction)(e)?r=e(S()):"number"==typeof e&&(r=e),"number"!=typeof r)return c;n({_l:r}),O.current=r;let o=[],[i]=(0,a.createCacheHelper)(l,u),s=null;for(let e=0;e<r;++e){let[r]=(0,a.serialize)(t(e,s)),[n]=(0,a.createCacheHelper)(l,r),u=r?n().data:a.UNDEFINED;if((0,a.isUndefined)(u))return D(i().data);o.push(u),s=u}return D(o)},[u,l,D,S]);return{size:S(),setSize:j,mutate:D,get data(){return x.data},get error(){return x.error},get isValidating(){return x.isValidating},get isLoading(){return x.isLoading}}})},9167(e,t,r){"use strict";r.d(t,{y:()=>o});let n=e=>{let t,r=new Set,n=(e,n)=>{let o="function"==typeof e?e(t):e;if(!Object.is(o,t)){let e=t;t=(null!=n?n:"object"!=typeof o||null===o)?o:Object.assign({},t,o),r.forEach(r=>r(t,e))}},o=()=>t,i={setState:n,getState:o,getInitialState:()=>a,subscribe:e=>(r.add(e),()=>r.delete(e)),destroy:()=>{console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),r.clear()}},a=t=e(n,o,i);return i},o=e=>e?n(e):n},4356(e,t,r){"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function o(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}function i(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function a(e,t,r){return t&&i(e.prototype,t),r&&i(e,r),e}r.d(t,{A:()=>c});var u=function(){function e(){o(this,e)}return a(e,[{key:"add",value:function(e,t,r){if("string"!=typeof arguments[0])for(var n in arguments[0])this.add(n,arguments[0][n],arguments[1]);else(Array.isArray(e)?e:[e]).forEach(function(e){this[e]=this[e]||[],t&&this[e][r?"unshift":"push"](t)},this)}},{key:"run",value:function(e,t){this[e]=this[e]||[],this[e].forEach(function(e){e.call(t&&t.context?t.context:t,t)})}}]),e}(),s=function(){function e(t){o(this,e),this.jsep=t,this.registered={}}return a(e,[{key:"register",value:function(){for(var e=this,t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];r.forEach(function(t){if((void 0===t?"undefined":t&&"u">typeof Symbol&&t.constructor===Symbol?"symbol":typeof t)!="object"||!t.name||!t.init)throw Error("Invalid JSEP plugin format");e.registered[t.name]||(t.init(e.jsep),e.registered[t.name]=t)})}}]),e}(),l=function(){function e(t){o(this,e),this.expr=t,this.index=0}return a(e,[{key:"char",get:function(){return this.expr.charAt(this.index)}},{key:"code",get:function(){return this.expr.charCodeAt(this.index)}},{key:"throwError",value:function(e){var t=Error(e+" at character "+this.index);throw t.index=this.index,t.description=e,t}},{key:"runHook",value:function(t,r){if(e.hooks[t]){var n={context:this,node:r};return e.hooks.run(t,n),n.node}return r}},{key:"searchHook",value:function(t){if(e.hooks[t]){var r={context:this};return e.hooks[t].find(function(e){return e.call(r.context,r),r.node}),r.node}}},{key:"gobbleSpaces",value:function(){for(var t=this.code;t===e.SPACE_CODE||t===e.TAB_CODE||t===e.LF_CODE||t===e.CR_CODE;)t=this.expr.charCodeAt(++this.index);this.runHook("gobble-spaces")}},{key:"parse",value:function(){this.runHook("before-all");var t=this.gobbleExpressions(),r=1===t.length?t[0]:{type:e.COMPOUND,body:t};return this.runHook("after-all",r)}},{key:"gobbleExpressions",value:function(t){for(var r,n,o=[];this.index<this.expr.length;)if((r=this.code)===e.SEMCOL_CODE||r===e.COMMA_CODE)this.index++;else if(n=this.gobbleExpression())o.push(n);else if(this.index<this.expr.length){if(r===t)break;this.throwError('Unexpected "'+this.char+'"')}return o}},{key:"gobbleExpression",value:function(){var e=this.searchHook("gobble-expression")||this.gobbleBinaryExpression();return this.gobbleSpaces(),this.runHook("after-expression",e)}},{key:"gobbleBinaryOp",value:function(){this.gobbleSpaces();for(var t=this.expr.substr(this.index,e.max_binop_len),r=t.length;r>0;){if(e.binary_ops.hasOwnProperty(t)&&(!e.isIdentifierStart(this.code)||this.index+t.length<this.expr.length&&!e.isIdentifierPart(this.expr.charCodeAt(this.index+t.length))))return this.index+=r,t;t=t.substr(0,--r)}return!1}},{key:"gobbleBinaryExpression",value:function(){var t,r,n,o,i,a,u,s,l,c;if(!(a=this.gobbleToken())||!(r=this.gobbleBinaryOp()))return a;for(i={value:r,prec:e.binaryPrecedence(r),right_a:e.right_associative.has(r)},(u=this.gobbleToken())||this.throwError("Expected expression after "+r),o=[a,i,u];r=this.gobbleBinaryOp();){if(0===(n=e.binaryPrecedence(r))){this.index-=r.length;break}for(i={value:r,prec:n,right_a:e.right_associative.has(r)},l=r;o.length>2&&(c=o[o.length-2],i.right_a&&c.right_a?n>c.prec:n<=c.prec);)u=o.pop(),r=o.pop().value,a=o.pop(),t={type:e.BINARY_EXP,operator:r,left:a,right:u},o.push(t);(t=this.gobbleToken())||this.throwError("Expected expression after "+l),o.push(i,t)}for(s=o.length-1,t=o[s];s>1;)t={type:e.BINARY_EXP,operator:o[s-1].value,left:o[s-2],right:t},s-=2;return t}},{key:"gobbleToken",value:function(){var t,r,n,o;if(this.gobbleSpaces(),o=this.searchHook("gobble-token"))return this.runHook("after-token",o);if(t=this.code,e.isDecimalDigit(t)||t===e.PERIOD_CODE)return this.gobbleNumericLiteral();if(t===e.SQUOTE_CODE||t===e.DQUOTE_CODE)o=this.gobbleStringLiteral();else if(t===e.OBRACK_CODE)o=this.gobbleArray();else{for(n=(r=this.expr.substr(this.index,e.max_unop_len)).length;n>0;){if(e.unary_ops.hasOwnProperty(r)&&(!e.isIdentifierStart(this.code)||this.index+r.length<this.expr.length&&!e.isIdentifierPart(this.expr.charCodeAt(this.index+r.length)))){this.index+=n;var i=this.gobbleToken();return i||this.throwError("missing unaryOp argument"),this.runHook("after-token",{type:e.UNARY_EXP,operator:r,argument:i,prefix:!0})}r=r.substr(0,--n)}e.isIdentifierStart(t)?(o=this.gobbleIdentifier(),e.literals.hasOwnProperty(o.name)?o={type:e.LITERAL,value:e.literals[o.name],raw:o.name}:o.name===e.this_str&&(o={type:e.THIS_EXP})):t===e.OPAREN_CODE&&(o=this.gobbleGroup())}return o?(o=this.gobbleTokenProperty(o),this.runHook("after-token",o)):this.runHook("after-token",!1)}},{key:"gobbleTokenProperty",value:function(t){this.gobbleSpaces();for(var r=this.code;r===e.PERIOD_CODE||r===e.OBRACK_CODE||r===e.OPAREN_CODE||r===e.QUMARK_CODE;){var n=void 0;if(r===e.QUMARK_CODE){if(this.expr.charCodeAt(this.index+1)!==e.PERIOD_CODE)break;n=!0,this.index+=2,this.gobbleSpaces(),r=this.code}this.index++,r===e.OBRACK_CODE?((t={type:e.MEMBER_EXP,computed:!0,object:t,property:this.gobbleExpression()}).property||this.throwError('Unexpected "'+this.char+'"'),this.gobbleSpaces(),(r=this.code)!==e.CBRACK_CODE&&this.throwError("Unclosed ["),this.index++):r===e.OPAREN_CODE?t={type:e.CALL_EXP,arguments:this.gobbleArguments(e.CPAREN_CODE),callee:t}:(r===e.PERIOD_CODE||n)&&(n&&this.index--,this.gobbleSpaces(),t={type:e.MEMBER_EXP,computed:!1,object:t,property:this.gobbleIdentifier()}),n&&(t.optional=!0),this.gobbleSpaces(),r=this.code}return t}},{key:"gobbleNumericLiteral",value:function(){for(var t,r,n="";e.isDecimalDigit(this.code);)n+=this.expr.charAt(this.index++);if(this.code===e.PERIOD_CODE)for(n+=this.expr.charAt(this.index++);e.isDecimalDigit(this.code);)n+=this.expr.charAt(this.index++);if("e"===(t=this.char)||"E"===t){for(n+=this.expr.charAt(this.index++),("+"===(t=this.char)||"-"===t)&&(n+=this.expr.charAt(this.index++));e.isDecimalDigit(this.code);)n+=this.expr.charAt(this.index++);e.isDecimalDigit(this.expr.charCodeAt(this.index-1))||this.throwError("Expected exponent ("+n+this.char+")")}return r=this.code,e.isIdentifierStart(r)?this.throwError("Variable names cannot start with a number ("+n+this.char+")"):(r===e.PERIOD_CODE||1===n.length&&n.charCodeAt(0)===e.PERIOD_CODE)&&this.throwError("Unexpected period"),{type:e.LITERAL,value:parseFloat(n),raw:n}}},{key:"gobbleStringLiteral",value:function(){for(var t="",r=this.index,n=this.expr.charAt(this.index++),o=!1;this.index<this.expr.length;){var i=this.expr.charAt(this.index++);if(i===n){o=!0;break}if("\\"===i)switch(i=this.expr.charAt(this.index++)){case"n":t+="\n";break;case"r":t+="\r";break;case"t":t+=" ";break;case"b":t+="\b";break;case"f":t+="\f";break;case"v":t+="\v";break;default:t+=i}else t+=i}return o||this.throwError('Unclosed quote after "'+t+'"'),{type:e.LITERAL,value:t,raw:this.expr.substring(r,this.index)}}},{key:"gobbleIdentifier",value:function(){var t=this.code,r=this.index;for(e.isIdentifierStart(t)?this.index++:this.throwError("Unexpected "+this.char);this.index<this.expr.length;)if(t=this.code,e.isIdentifierPart(t))this.index++;else break;return{type:e.IDENTIFIER,name:this.expr.slice(r,this.index)}}},{key:"gobbleArguments",value:function(t){for(var r=[],n=!1,o=0;this.index<this.expr.length;){this.gobbleSpaces();var i=this.code;if(i===t){n=!0,this.index++,t===e.CPAREN_CODE&&o&&o>=r.length&&this.throwError("Unexpected token "+String.fromCharCode(t));break}if(i===e.COMMA_CODE){if(this.index++,++o!==r.length){if(t===e.CPAREN_CODE)this.throwError("Unexpected token ,");else if(t===e.CBRACK_CODE)for(var a=r.length;a<o;a++)r.push(null)}}else if(r.length!==o&&0!==o)this.throwError("Expected comma");else{var u=this.gobbleExpression();u&&u.type!==e.COMPOUND||this.throwError("Expected comma"),r.push(u)}}return n||this.throwError("Expected "+String.fromCharCode(t)),r}},{key:"gobbleGroup",value:function(){this.index++;var t=this.gobbleExpressions(e.CPAREN_CODE);if(this.code===e.CPAREN_CODE)return(this.index++,1===t.length)?t[0]:!!t.length&&{type:e.SEQUENCE_EXP,expressions:t};this.throwError("Unclosed (")}},{key:"gobbleArray",value:function(){return this.index++,{type:e.ARRAY_EXP,elements:this.gobbleArguments(e.CBRACK_CODE)}}}],[{key:"version",get:function(){return"1.4.0"}},{key:"toString",value:function(){return"JavaScript Expression Parser (JSEP) v"+e.version}},{key:"addUnaryOp",value:function(t){return e.max_unop_len=Math.max(t.length,e.max_unop_len),e.unary_ops[t]=1,e}},{key:"addBinaryOp",value:function(t,r,n){return e.max_binop_len=Math.max(t.length,e.max_binop_len),e.binary_ops[t]=r,n?e.right_associative.add(t):e.right_associative.delete(t),e}},{key:"addIdentifierChar",value:function(t){return e.additional_identifier_chars.add(t),e}},{key:"addLiteral",value:function(t,r){return e.literals[t]=r,e}},{key:"removeUnaryOp",value:function(t){return delete e.unary_ops[t],t.length===e.max_unop_len&&(e.max_unop_len=e.getMaxKeyLen(e.unary_ops)),e}},{key:"removeAllUnaryOps",value:function(){return e.unary_ops={},e.max_unop_len=0,e}},{key:"removeIdentifierChar",value:function(t){return e.additional_identifier_chars.delete(t),e}},{key:"removeBinaryOp",value:function(t){return delete e.binary_ops[t],t.length===e.max_binop_len&&(e.max_binop_len=e.getMaxKeyLen(e.binary_ops)),e.right_associative.delete(t),e}},{key:"removeAllBinaryOps",value:function(){return e.binary_ops={},e.max_binop_len=0,e}},{key:"removeLiteral",value:function(t){return delete e.literals[t],e}},{key:"removeAllLiterals",value:function(){return e.literals={},e}},{key:"parse",value:function(t){return new e(t).parse()}},{key:"getMaxKeyLen",value:function(e){var t,r;return(t=Math).max.apply(t,[0].concat(function(e){if(Array.isArray(e))return n(e)}(r=Object.keys(e).map(function(e){return e.length}))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||function(e){if(e){if("string"==typeof e)return n(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return n(e,void 0)}}(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()))}},{key:"isDecimalDigit",value:function(e){return e>=48&&e<=57}},{key:"binaryPrecedence",value:function(t){return e.binary_ops[t]||0}},{key:"isIdentifierStart",value:function(t){return t>=65&&t<=90||t>=97&&t<=122||t>=128&&!e.binary_ops[String.fromCharCode(t)]||e.additional_identifier_chars.has(String.fromCharCode(t))}},{key:"isIdentifierPart",value:function(t){return e.isIdentifierStart(t)||e.isDecimalDigit(t)}}]),e}();Object.assign(l,{hooks:new u,plugins:new s(l),COMPOUND:"Compound",SEQUENCE_EXP:"SequenceExpression",IDENTIFIER:"Identifier",MEMBER_EXP:"MemberExpression",LITERAL:"Literal",THIS_EXP:"ThisExpression",CALL_EXP:"CallExpression",UNARY_EXP:"UnaryExpression",BINARY_EXP:"BinaryExpression",ARRAY_EXP:"ArrayExpression",TAB_CODE:9,LF_CODE:10,CR_CODE:13,SPACE_CODE:32,PERIOD_CODE:46,COMMA_CODE:44,SQUOTE_CODE:39,DQUOTE_CODE:34,OPAREN_CODE:40,CPAREN_CODE:41,OBRACK_CODE:91,CBRACK_CODE:93,QUMARK_CODE:63,SEMCOL_CODE:59,COLON_CODE:58,unary_ops:{"-":1,"!":1,"~":1,"+":1},binary_ops:{"||":1,"??":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":10,"/":10,"%":10,"**":11},right_associative:new Set(["**"]),additional_identifier_chars:new Set(["$","_"]),literals:{true:!0,false:!1,null:null},this_str:"this"}),l.max_unop_len=l.getMaxKeyLen(l.unary_ops),l.max_binop_len=l.getMaxKeyLen(l.binary_ops);var c=function(e){return new l(e).parse()},d=Object.getOwnPropertyNames(function e(){o(this,e)});Object.getOwnPropertyNames(l).filter(function(e){return!d.includes(e)&&void 0===c[e]}).forEach(function(e){c[e]=l[e]}),c.Jsep=l,c.plugins.register({name:"ternary",init:function(e){e.hooks.add("after-expression",function(t){if(t.node&&this.code===e.QUMARK_CODE){this.index++;var r=t.node,n=this.gobbleExpression();if(n||this.throwError("Expected expression"),this.gobbleSpaces(),this.code===e.COLON_CODE){this.index++;var o=this.gobbleExpression();if(o||this.throwError("Expected expression"),t.node={type:"ConditionalExpression",test:r,consequent:n,alternate:o},r.operator&&e.binary_ops[r.operator]<=.9){for(var i=r;i.right.operator&&e.binary_ops[i.right.operator]<=.9;)i=i.right;t.node.test=i.right,i.right=t.node,t.node=r}}else this.throwError("Expected :")}})}})},4748(e,t,r){"use strict";r.d(t,{A:()=>u});var n=r(6533);let o=function(e,t){for(var r=e.length;r--;)if((0,n.A)(e[r][0],t))return r;return -1};var i=Array.prototype.splice;function a(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}a.prototype.clear=function(){this.__data__=[],this.size=0},a.prototype.delete=function(e){var t=this.__data__,r=o(t,e);return!(r<0)&&(r==t.length-1?t.pop():i.call(t,r,1),--this.size,!0)},a.prototype.get=function(e){var t=this.__data__,r=o(t,e);return r<0?void 0:t[r][1]},a.prototype.has=function(e){return o(this.__data__,e)>-1},a.prototype.set=function(e,t){var r=this.__data__,n=o(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this};let u=a},2178(e,t,r){"use strict";r.d(t,{A:()=>i});var n=r(5340),o=r(1190);let i=(0,n.A)(o.A,"Map")},3750(e,t,r){"use strict";r.d(t,{A:()=>f});var n=(0,r(5340).A)(Object,"create"),o=Object.prototype.hasOwnProperty,i=Object.prototype.hasOwnProperty;function a(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}a.prototype.clear=function(){this.__data__=n?n(null):{},this.size=0},a.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=!!t,t},a.prototype.get=function(e){var t=this.__data__;if(n){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return o.call(t,e)?t[e]:void 0},a.prototype.has=function(e){var t=this.__data__;return n?void 0!==t[e]:i.call(t,e)},a.prototype.set=function(e,t){var r=this.__data__;return this.size+=+!this.has(e),r[e]=n&&void 0===t?"__lodash_hash_undefined__":t,this};var u=r(4748),s=r(2178);let l=function(e){var t=void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e},c=function(e,t){var r=e.__data__;return l(t)?r["string"==typeof t?"string":"hash"]:r.map};function d(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}d.prototype.clear=function(){this.size=0,this.__data__={hash:new a,map:new(s.A||u.A),string:new a}},d.prototype.delete=function(e){var t=c(this,e).delete(e);return this.size-=!!t,t},d.prototype.get=function(e){return c(this,e).get(e)},d.prototype.has=function(e){return c(this,e).has(e)},d.prototype.set=function(e,t){var r=c(this,e),n=r.size;return r.set(e,t),this.size+=+(r.size!=n),this};let f=d},6146(e,t,r){"use strict";r.d(t,{A:()=>u});var n=r(4748),o=r(2178),i=r(3750);function a(e){var t=this.__data__=new n.A(e);this.size=t.size}a.prototype.clear=function(){this.__data__=new n.A,this.size=0},a.prototype.delete=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r},a.prototype.get=function(e){return this.__data__.get(e)},a.prototype.has=function(e){return this.__data__.has(e)},a.prototype.set=function(e,t){var r,a,u=this.__data__;if(r=u,null!=(a=n.A)&&"u">typeof Symbol&&a[Symbol.hasInstance]?!!a[Symbol.hasInstance](r):r instanceof a){var s=u.__data__;if(!o.A||s.length<199)return s.push([e,t]),this.size=++u.size,this;u=this.__data__=new i.A(s)}return u.set(e,t),this.size=u.size,this};let u=a},3578(e,t,r){"use strict";r.d(t,{A:()=>n});let n=r(1190).A.Symbol},3807(e,t,r){"use strict";r.d(t,{A:()=>n});let n=r(1190).A.Uint8Array},4075(e,t,r){"use strict";r.d(t,{A:()=>c});let n=function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n};var o=r(2797),i=r(8206),a=r(8134),u=r(2936),s=r(7931),l=Object.prototype.hasOwnProperty;let c=function(e,t){var r=(0,i.A)(e),c=!r&&(0,o.A)(e),d=!r&&!c&&(0,a.A)(e),f=!r&&!c&&!d&&(0,s.A)(e),p=r||c||d||f,h=p?n(e.length,String):[],m=h.length;for(var y in e)(t||l.call(e,y))&&!(p&&("length"==y||d&&("offset"==y||"parent"==y)||f&&("buffer"==y||"byteLength"==y||"byteOffset"==y)||(0,u.A)(y,m)))&&h.push(y);return h}},6239(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e,t){for(var r=-1,n=null==e?0:e.length,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}},5761(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}},886(e,t,r){"use strict";r.d(t,{A:()=>a});var n=r(5033),o=r(6533),i=Object.prototype.hasOwnProperty;let a=function(e,t,r){var a=e[t];i.call(e,t)&&(0,o.A)(a,r)&&(void 0!==r||t in e)||(0,n.A)(e,t,r)}},5033(e,t,r){"use strict";r.d(t,{A:()=>o});var n=r(8396);let o=function(e,t,r){"__proto__"==t&&n.A?(0,n.A)(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}},2288(e,t,r){"use strict";r.d(t,{A:()=>W});var n=r(6146);let o=function(e,t){for(var r=-1,n=null==e?0:e.length;++r<n&&!1!==t(e[r],r,e););return e};var i=r(886),a=r(4976),u=r(1571),s=r(5527),l=r(6755),c=r(7085),d=r(5587),f=r(4416),p=r(7409),h=r(1722),m=r(72),y=Object.prototype.hasOwnProperty;let b=function(e){var t=e.length,r=new e.constructor(t);return t&&"string"==typeof e[0]&&y.call(e,"index")&&(r.index=e.index,r.input=e.input),r};var v=r(9466);let g=function(e,t){var r=t?(0,v.A)(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)};var w=/\w*$/;let E=function(e){var t=new e.constructor(e.source,w.exec(e));return t.lastIndex=e.lastIndex,t};var S=r(3578),O=S.A?S.A.prototype:void 0,A=O?O.valueOf:void 0,x=r(2160);let D=function(e,t,r){var n=e.constructor;switch(t){case"[object ArrayBuffer]":return(0,v.A)(e);case"[object Boolean]":case"[object Date]":return new n(+e);case"[object DataView]":return g(e,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return(0,x.A)(e,r);case"[object Map]":case"[object Set]":return new n;case"[object Number]":case"[object String]":return new n(e);case"[object RegExp]":return E(e);case"[object Symbol]":return A?Object(A.call(e)):{}}};var j=r(2371),C=r(8206),P=r(8134),k=r(779),I=r(6476),T=r(6026),R=T.A&&T.A.isMap,F=R?(0,I.A)(R):function(e){return(0,k.A)(e)&&"[object Map]"==(0,m.A)(e)},N=r(8836),M=T.A&&T.A.isSet,B=M?(0,I.A)(M):function(e){return(0,k.A)(e)&&"[object Set]"==(0,m.A)(e)},L="[object Arguments]",V="[object Function]",U="[object Object]",$={};$[L]=$["[object Array]"]=$["[object ArrayBuffer]"]=$["[object DataView]"]=$["[object Boolean]"]=$["[object Date]"]=$["[object Float32Array]"]=$["[object Float64Array]"]=$["[object Int8Array]"]=$["[object Int16Array]"]=$["[object Int32Array]"]=$["[object Map]"]=$["[object Number]"]=$[U]=$["[object RegExp]"]=$["[object Set]"]=$["[object String]"]=$["[object Symbol]"]=$["[object Uint8Array]"]=$["[object Uint8ClampedArray]"]=$["[object Uint16Array]"]=$["[object Uint32Array]"]=!0,$["[object Error]"]=$[V]=$["[object WeakMap]"]=!1;let W=function e(t,r,y,v,g,w){var E,S=1&r,O=2&r,A=4&r;if(y&&(E=g?y(t,v,g,w):y(t)),void 0!==E)return E;if(!(0,N.A)(t))return t;var x=(0,C.A)(t);if(x){if(E=b(t),!S)return(0,c.A)(t,E)}else{var k,I,T,R,M=(0,m.A)(t),W=M==V||"[object GeneratorFunction]"==M;if((0,P.A)(t))return(0,l.A)(t,S);if(M==U||M==L||W&&!g){if(E=O||W?{}:(0,j.A)(t),!S)return O?(I=(k=E)&&(0,a.A)(t,(0,s.A)(t),k),(0,a.A)(t,(0,f.A)(t),I)):(R=(T=E)&&(0,a.A)(t,(0,u.A)(t),T),(0,a.A)(t,(0,d.A)(t),R))}else{if(!$[M])return g?t:{};E=D(t,M,S)}}w||(w=new n.A);var z=w.get(t);if(z)return z;w.set(t,E),B(t)?t.forEach(function(n){E.add(e(n,r,y,n,t,w))}):F(t)&&t.forEach(function(n,o){E.set(o,e(n,r,y,o,t,w))});var K=A?O?h.A:p.A:O?s.A:u.A,H=x?void 0:K(t);return o(H||t,function(n,o){H&&(n=t[o=n]),(0,i.A)(E,o,e(n,r,y,o,t,w))}),E}},3292(e,t,r){"use strict";r.d(t,{A:()=>i});var n=r(5761),o=r(8206);let i=function(e,t,r){var i=t(e);return(0,o.A)(e)?i:(0,n.A)(i,r(e))}},1799(e,t,r){"use strict";r.d(t,{A:()=>d});var n=r(3578),o=Object.prototype,i=o.hasOwnProperty,a=o.toString,u=n.A?n.A.toStringTag:void 0;let s=function(e){var t=i.call(e,u),r=e[u];try{e[u]=void 0;var n=!0}catch(e){}var o=a.call(e);return n&&(t?e[u]=r:delete e[u]),o};var l=Object.prototype.toString,c=n.A?n.A.toStringTag:void 0;let d=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":c&&c in Object(e)?s(e):l.call(e)}},5217(e,t,r){"use strict";r.d(t,{A:()=>a});var n=r(4666),o=(0,r(2478).A)(Object.keys,Object),i=Object.prototype.hasOwnProperty;let a=function(e){if(!(0,n.A)(e))return o(e);var t=[];for(var r in Object(e))i.call(e,r)&&"constructor"!=r&&t.push(r);return t}},2102(e,t,r){"use strict";r.d(t,{A:()=>x});var n=r(6146),o=r(5033),i=r(6533);let a=function(e,t,r){(void 0===r||(0,i.A)(e[t],r))&&(void 0!==r||t in e)||(0,o.A)(e,t,r)},u=function(e,t,r){for(var n=-1,o=Object(e),i=r(e),a=i.length;a--;){var u=i[++n];if(!1===t(o[u],u,o))break}return e};var s=r(6755),l=r(2160),c=r(7085),d=r(2371),f=r(2797),p=r(8206),h=r(3497),m=r(779),y=r(8134),b=r(111),v=r(8836),g=r(7344),w=r(7931);let E=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]};var S=r(4976),O=r(5527);let A=function(e,t,r,n,o,i,u){var A=E(e,r),x=E(t,r),D=u.get(x);if(D)return void a(e,r,D);var j=i?i(A,x,r+"",e,t,u):void 0,C=void 0===j;if(C){var P=(0,p.A)(x),k=!P&&(0,y.A)(x),I=!P&&!k&&(0,w.A)(x);(j=x,P||k||I)?(0,p.A)(A)?j=A:(0,m.A)(A)&&(0,h.A)(A)?j=(0,c.A)(A):k?(C=!1,j=(0,s.A)(x,!0)):I?(C=!1,j=(0,l.A)(x,!0)):j=[]:(0,g.A)(x)||(0,f.A)(x)?(j=A,(0,f.A)(A))?j=(0,S.A)(A,(0,O.A)(A)):(!(0,v.A)(A)||(0,b.A)(A))&&(j=(0,d.A)(x)):C=!1}C&&(u.set(x,j),o(j,x,n,i,u),u.delete(x)),a(e,r,j)},x=function e(t,r,o,i,s){t!==r&&u(r,function(u,l){if(s||(s=new n.A),(0,v.A)(u))A(t,r,l,o,e,i,s);else{var c=i?i(E(t,l),u,l+"",t,r,s):void 0;void 0===c&&(c=u),a(t,l,c)}},O.A)}},6476(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e){return function(t){return e(t)}}},9466(e,t,r){"use strict";r.d(t,{A:()=>o});var n=r(3807);let o=function(e){var t=new e.constructor(e.byteLength);return new n.A(t).set(new n.A(e)),t}},6755(e,t,r){"use strict";r.d(t,{A:()=>l});var n=r(1190);function o(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}var i=("u"<typeof exports?"undefined":o(exports))=="object"&&exports&&!exports.nodeType&&exports,a=i&&("u"<typeof module?"undefined":o(module))=="object"&&module&&!module.nodeType&&module,u=a&&a.exports===i?n.A.Buffer:void 0,s=u?u.allocUnsafe:void 0;let l=function(e,t){if(t)return e.slice();var r=e.length,n=s?s(r):new e.constructor(r);return e.copy(n),n}},2160(e,t,r){"use strict";r.d(t,{A:()=>o});var n=r(9466);let o=function(e,t){var r=t?(0,n.A)(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}},7085(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}},4976(e,t,r){"use strict";r.d(t,{A:()=>i});var n=r(886),o=r(5033);let i=function(e,t,r,i){var a=!r;r||(r={});for(var u=-1,s=t.length;++u<s;){var l=t[u],c=i?i(r[l],e[l],l,r,e):void 0;void 0===c&&(c=e[l]),a?(0,o.A)(r,l,c):(0,n.A)(r,l,c)}return r}},6317(e,t,r){"use strict";r.d(t,{A:()=>d});var n=r(8205),o=r(1369),i=r(1136),a=r(6533),u=r(3497),s=r(2936),l=r(8836);let c=function(e,t,r){if(!(0,l.A)(r))return!1;var n=void 0===t?"undefined":t&&"u">typeof Symbol&&t.constructor===Symbol?"symbol":typeof t;return("number"==n?!!((0,u.A)(r)&&(0,s.A)(t,r.length)):"string"==n&&t in r)&&(0,a.A)(r[t],e)},d=function(e){var t;return t=function(t,r){var n=-1,o=r.length,i=o>1?r[o-1]:void 0,a=o>2?r[2]:void 0;for(i=e.length>3&&"function"==typeof i?(o--,i):void 0,a&&c(r[0],r[1],a)&&(i=o<3?void 0:i,o=1),t=Object(t);++n<o;){var u=r[n];u&&e(t,u,n,i)}return t},(0,i.A)((0,o.A)(t,void 0,n.A),t+"")}},8396(e,t,r){"use strict";r.d(t,{A:()=>o});var n=r(5340);let o=function(){try{var e=(0,n.A)(Object,"defineProperty");return e({},"",{}),e}catch(e){}}()},4991(e,t,r){"use strict";var n;r.d(t,{A:()=>o});let o=("u"<typeof global?"undefined":(n=global)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)=="object"&&global&&global.Object===Object&&global},7409(e,t,r){"use strict";r.d(t,{A:()=>a});var n=r(3292),o=r(5587),i=r(1571);let a=function(e){return(0,n.A)(e,i.A,o.A)}},1722(e,t,r){"use strict";r.d(t,{A:()=>a});var n=r(3292),o=r(4416),i=r(5527);let a=function(e){return(0,n.A)(e,i.A,o.A)}},5340(e,t,r){"use strict";r.d(t,{A:()=>m});var n,o=r(111),i=r(1190).A["__core-js_shared__"],a=(n=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",u=r(8836),s=r(7530),l=/^\[object .+?Constructor\]$/,c=Object.prototype,d=Function.prototype.toString,f=c.hasOwnProperty,p=RegExp("^"+d.call(f).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");let h=function(e){return!!(0,u.A)(e)&&(!a||!(a in e))&&((0,o.A)(e)?p:l).test((0,s.A)(e))},m=function(e,t){var r=null==e?void 0:e[t];return h(r)?r:void 0}},9640(e,t,r){"use strict";r.d(t,{A:()=>n});let n=(0,r(2478).A)(Object.getPrototypeOf,Object)},5587(e,t,r){"use strict";r.d(t,{A:()=>u});let n=function(e,t){for(var r=-1,n=null==e?0:e.length,o=0,i=[];++r<n;){var a=e[r];t(a,r,e)&&(i[o++]=a)}return i};var o=r(1026),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols;let u=a?function(e){return null==e?[]:n(a(e=Object(e)),function(t){return i.call(e,t)})}:o.A},4416(e,t,r){"use strict";r.d(t,{A:()=>u});var n=r(5761),o=r(9640),i=r(5587),a=r(1026);let u=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)(0,n.A)(t,(0,i.A)(e)),e=(0,o.A)(e);return t}:a.A},72(e,t,r){"use strict";r.d(t,{A:()=>O});var n=r(5340),o=r(1190),i=(0,n.A)(o.A,"DataView"),a=r(2178),u=(0,n.A)(o.A,"Promise"),s=(0,n.A)(o.A,"Set"),l=(0,n.A)(o.A,"WeakMap"),c=r(1799),d=r(7530),f="[object Map]",p="[object Promise]",h="[object Set]",m="[object WeakMap]",y="[object DataView]",b=(0,d.A)(i),v=(0,d.A)(a.A),g=(0,d.A)(u),w=(0,d.A)(s),E=(0,d.A)(l),S=c.A;(i&&S(new i(new ArrayBuffer(1)))!=y||a.A&&S(new a.A)!=f||u&&S(u.resolve())!=p||s&&S(new s)!=h||l&&S(new l)!=m)&&(S=function(e){var t=(0,c.A)(e),r="[object Object]"==t?e.constructor:void 0,n=r?(0,d.A)(r):"";if(n)switch(n){case b:return y;case v:return f;case g:return p;case w:return h;case E:return m}return t});let O=S},2371(e,t,r){"use strict";r.d(t,{A:()=>s});var n=r(8836),o=Object.create,i=function(){function e(){}return function(t){if(!(0,n.A)(t))return{};if(o)return o(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}(),a=r(9640),u=r(4666);let s=function(e){return"function"!=typeof e.constructor||(0,u.A)(e)?{}:i((0,a.A)(e))}},2936(e,t,r){"use strict";r.d(t,{A:()=>o});var n=/^(?:0|[1-9]\d*)$/;let o=function(e,t){var r=void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e;return!!(t=null==t?0x1fffffffffffff:t)&&("number"==r||"symbol"!=r&&n.test(e))&&e>-1&&e%1==0&&e<t}},4666(e,t,r){"use strict";r.d(t,{A:()=>o});var n=Object.prototype;let o=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||n)}},6026(e,t,r){"use strict";r.d(t,{A:()=>s});var n=r(4991);function o(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}var i=("u"<typeof exports?"undefined":o(exports))=="object"&&exports&&!exports.nodeType&&exports,a=i&&("u"<typeof module?"undefined":o(module))=="object"&&module&&!module.nodeType&&module,u=a&&a.exports===i&&n.A.process;let s=function(){try{var e=a&&a.require&&a.require("util").types;if(e)return e;return u&&u.binding&&u.binding("util")}catch(e){}}()},2478(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e,t){return function(r){return e(t(r))}}},1369(e,t,r){"use strict";r.d(t,{A:()=>i});let n=function(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)};var o=Math.max;let i=function(e,t,r){return t=o(void 0===t?e.length-1:t,0),function(){for(var i=arguments,a=-1,u=o(i.length-t,0),s=Array(u);++a<u;)s[a]=i[t+a];a=-1;for(var l=Array(t+1);++a<t;)l[a]=i[a];return l[t]=r(s),n(e,this,l)}}},1190(e,t,r){"use strict";r.d(t,{A:()=>a});var n,o=r(4991),i=("u"<typeof self?"undefined":(n=self)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)=="object"&&self&&self.Object===Object&&self;let a=o.A||i||Function("return this")()},1136(e,t,r){"use strict";r.d(t,{A:()=>l});var n,o,i=r(8396),a=r(8205),u=i.A?function(e,t){return(0,i.A)(e,"toString",{configurable:!0,enumerable:!1,value:function(){return t},writable:!0})}:a.A,s=Date.now;let l=(n=0,o=0,function(){var e=s(),t=16-(e-o);if(o=e,t>0){if(++n>=800)return arguments[0]}else n=0;return u.apply(void 0,arguments)})},7530(e,t,r){"use strict";r.d(t,{A:()=>o});var n=Function.prototype.toString;let o=function(e){if(null!=e){try{return n.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},6533(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e,t){return e===t||e!=e&&t!=t}},8205(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e){return e}},2797(e,t,r){"use strict";r.d(t,{A:()=>l});var n=r(1799),o=r(779);let i=function(e){return(0,o.A)(e)&&"[object Arguments]"==(0,n.A)(e)};var a=Object.prototype,u=a.hasOwnProperty,s=a.propertyIsEnumerable;let l=i(function(){return arguments}())?i:function(e){return(0,o.A)(e)&&u.call(e,"callee")&&!s.call(e,"callee")}},8206(e,t,r){"use strict";r.d(t,{A:()=>n});let n=Array.isArray},3497(e,t,r){"use strict";r.d(t,{A:()=>i});var n=r(111),o=r(5283);let i=function(e){return null!=e&&(0,o.A)(e.length)&&!(0,n.A)(e)}},8134(e,t,r){"use strict";r.d(t,{A:()=>s});var n=r(1190);function o(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}var i=("u"<typeof exports?"undefined":o(exports))=="object"&&exports&&!exports.nodeType&&exports,a=i&&("u"<typeof module?"undefined":o(module))=="object"&&module&&!module.nodeType&&module,u=a&&a.exports===i?n.A.Buffer:void 0;let s=(u?u.isBuffer:void 0)||function(){return!1}},4809(e,t,r){"use strict";r.d(t,{A:()=>k});var n=r(6146),o=r(3750);function i(e){var t=-1,r=null==e?0:e.length;for(this.__data__=new o.A;++t<r;)this.add(e[t])}i.prototype.add=i.prototype.push=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},i.prototype.has=function(e){return this.__data__.has(e)};let a=function(e,t){for(var r=-1,n=null==e?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1},u=function(e,t,r,n,o,u){var s=1&r,l=e.length,c=t.length;if(l!=c&&!(s&&c>l))return!1;var d=u.get(e),f=u.get(t);if(d&&f)return d==t&&f==e;var p=-1,h=!0,m=2&r?new i:void 0;for(u.set(e,t),u.set(t,e);++p<l;){var y=e[p],b=t[p];if(n)var v=s?n(b,y,p,t,e,u):n(y,b,p,e,t,u);if(void 0!==v){if(v)continue;h=!1;break}if(m){if(!a(t,function(e,t){if(!m.has(t)&&(y===e||o(y,e,r,n,u)))return m.push(t)})){h=!1;break}}else if(!(y===b||o(y,b,r,n,u))){h=!1;break}}return u.delete(e),u.delete(t),h};var s=r(3578),l=r(3807),c=r(6533);let d=function(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r},f=function(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r};var p=s.A?s.A.prototype:void 0,h=p?p.valueOf:void 0;let m=function(e,t,r,n,o,i,a){switch(r){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)break;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":if(e.byteLength!=t.byteLength||!i(new l.A(e),new l.A(t)))break;return!0;case"[object Boolean]":case"[object Date]":case"[object Number]":return(0,c.A)(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var s=d;case"[object Set]":var p=1&n;if(s||(s=f),e.size!=t.size&&!p)break;var m=a.get(e);if(m)return m==t;n|=2,a.set(e,t);var y=u(s(e),s(t),n,o,i,a);return a.delete(e),y;case"[object Symbol]":if(h)return h.call(e)==h.call(t)}return!1};var y=r(7409);function b(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}var v=Object.prototype.hasOwnProperty;let g=function(e,t,r,n,o,i){var a=1&r,u=(0,y.A)(e),s=u.length;if(s!=(0,y.A)(t).length&&!a)return!1;for(var l=s;l--;){var c=u[l];if(!(a?c in t:v.call(t,c)))return!1}var d=i.get(e),f=i.get(t);if(d&&f)return d==t&&f==e;var p=!0;i.set(e,t),i.set(t,e);for(var h=a;++l<s;){var m=e[c=u[l]],g=t[c];if(n)var w=a?n(g,m,c,t,e,i):n(m,g,c,e,t,i);if(!(void 0===w?m===g||o(m,g,r,n,i):w)){p=!1;break}h||(h="constructor"==c)}if(p&&!h){var E=e.constructor,S=t.constructor;E!=S&&"constructor"in e&&"constructor"in t&&!("function"==typeof E&&b(E,E)&&"function"==typeof S&&b(S,S))&&(p=!1)}return i.delete(e),i.delete(t),p};var w=r(72),E=r(8206),S=r(8134),O=r(7931),A="[object Arguments]",x="[object Array]",D="[object Object]",j=Object.prototype.hasOwnProperty;let C=function(e,t,r,o,i,a){var s=(0,E.A)(e),l=(0,E.A)(t),c=s?x:(0,w.A)(e),d=l?x:(0,w.A)(t);c=c==A?D:c,d=d==A?D:d;var f=c==D,p=d==D,h=c==d;if(h&&(0,S.A)(e)){if(!(0,S.A)(t))return!1;s=!0,f=!1}if(h&&!f)return a||(a=new n.A),s||(0,O.A)(e)?u(e,t,r,o,i,a):m(e,t,c,r,o,i,a);if(!(1&r)){var y=f&&j.call(e,"__wrapped__"),b=p&&j.call(t,"__wrapped__");if(y||b){var v=y?e.value():e,C=b?t.value():t;return a||(a=new n.A),i(v,C,r,o,a)}}return!!h&&(a||(a=new n.A),g(e,t,r,o,i,a))};var P=r(779);let k=function(e,t){return function e(t,r,n,o,i){return t===r||(null!=t&&null!=r&&((0,P.A)(t)||(0,P.A)(r))?C(t,r,n,o,e,i):t!=t&&r!=r)}(e,t)}},111(e,t,r){"use strict";r.d(t,{A:()=>i});var n=r(1799),o=r(8836);let i=function(e){if(!(0,o.A)(e))return!1;var t=(0,n.A)(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},5283(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=0x1fffffffffffff}},8836(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e){var t=void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e;return null!=e&&("object"==t||"function"==t)}},779(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(e){return null!=e&&(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"}},7344(e,t,r){"use strict";r.d(t,{A:()=>c});var n=r(1799),o=r(9640),i=r(779),a=Object.prototype,u=Function.prototype.toString,s=a.hasOwnProperty,l=u.call(Object);let c=function(e){if(!(0,i.A)(e)||"[object Object]"!=(0,n.A)(e))return!1;var t=(0,o.A)(e);if(null===t)return!0;var r=s.call(t,"constructor")&&t.constructor;return"function"==typeof r&&(null!=r&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](r):r instanceof r)&&u.call(r)==l}},1787(e,t,r){"use strict";r.d(t,{A:()=>i});var n=r(1799),o=r(779);let i=function(e){return(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="symbol"||(0,o.A)(e)&&"[object Symbol]"==(0,n.A)(e)}},7931(e,t,r){"use strict";r.d(t,{A:()=>c});var n=r(1799),o=r(5283),i=r(779),a={};a["[object Float32Array]"]=a["[object Float64Array]"]=a["[object Int8Array]"]=a["[object Int16Array]"]=a["[object Int32Array]"]=a["[object Uint8Array]"]=a["[object Uint8ClampedArray]"]=a["[object Uint16Array]"]=a["[object Uint32Array]"]=!0,a["[object Arguments]"]=a["[object Array]"]=a["[object ArrayBuffer]"]=a["[object Boolean]"]=a["[object DataView]"]=a["[object Date]"]=a["[object Error]"]=a["[object Function]"]=a["[object Map]"]=a["[object Number]"]=a["[object Object]"]=a["[object RegExp]"]=a["[object Set]"]=a["[object String]"]=a["[object WeakMap]"]=!1;var u=r(6476),s=r(6026),l=s.A&&s.A.isTypedArray;let c=l?(0,u.A)(l):function(e){return(0,i.A)(e)&&(0,o.A)(e.length)&&!!a[(0,n.A)(e)]}},1571(e,t,r){"use strict";r.d(t,{A:()=>a});var n=r(4075),o=r(5217),i=r(3497);let a=function(e){return(0,i.A)(e)?(0,n.A)(e):(0,o.A)(e)}},5527(e,t,r){"use strict";r.d(t,{A:()=>c});var n=r(4075),o=r(8836),i=r(4666);let a=function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t};var u=Object.prototype.hasOwnProperty;let s=function(e){if(!(0,o.A)(e))return a(e);var t=(0,i.A)(e),r=[];for(var n in e)"constructor"==n&&(t||!u.call(e,n))||r.push(n);return r};var l=r(3497);let c=function(e){return(0,l.A)(e)?(0,n.A)(e,!0):s(e)}},7403(e,t,r){"use strict";r.d(t,{A:()=>o});var n=r(2102);let o=(0,r(6317).A)(function(e,t,r){(0,n.A)(e,t,r)})},313(e,t,r){"use strict";r.d(t,{A:()=>V});var n,o,i,a=r(6239),u=r(2288),s=r(8206),l=r(1787),c=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,d=/^\w*$/;let f=function(e,t){if((0,s.A)(e))return!1;var r=void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e;return!!("number"==r||"symbol"==r||"boolean"==r||null==e||(0,l.A)(e))||d.test(e)||!c.test(e)||null!=t&&e in Object(t)};var p=r(3750);function h(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw TypeError("Expected a function");var r=function(){var n=arguments,o=t?t.apply(this,n):n[0],i=r.cache;if(i.has(o))return i.get(o);var a=e.apply(this,n);return r.cache=i.set(o,a)||i,a};return r.cache=new(h.Cache||p.A),r}h.Cache=p.A;var m=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,y=/\\(\\)?/g,b=(o=(n=h(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(m,function(e,r,n,o){t.push(n?o.replace(y,"$1"):r||e)}),t},function(e){return 500===o.size&&o.clear(),e})).cache,n),v=r(2768);let g=function(e,t){return(0,s.A)(e)?e:f(e,t)?[e]:b((0,v.A)(e))},w=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0};var E=1/0;let S=function(e){if("string"==typeof e||(0,l.A)(e))return e;var t=e+"";return"0"==t&&1/e==-E?"-0":t},O=function(e,t){t=g(t,e);for(var r=0,n=t.length;null!=e&&r<n;)e=e[S(t[r++])];return r&&r==n?e:void 0},A=function(e,t,r){var n=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(r=r>o?o:r)<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;for(var i=Array(o);++n<o;)i[n]=e[n+t];return i};var x=Object.prototype.hasOwnProperty;let D=function(e,t){t=g(t,e);var r,n=-1,o=t.length;if(!o)return!0;for(var i=null==e||(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)!="object"&&"function"!=typeof e;++n<o;){var a=t[n];if("string"==typeof a){if("__proto__"===a&&!x.call(e,"__proto__"))return!1;if("constructor"===a&&n+1<o&&"string"==typeof t[n+1]&&"prototype"===t[n+1]){if(i&&0===n)continue;return!1}}}var u=(r=t).length<2?e:O(e,A(r,0,-1));return null==u||delete u[S(w(t))]};var j=r(4976),C=r(7344);let P=function(e){return(0,C.A)(e)?void 0:e};var k=r(5761),I=r(3578),T=r(2797),R=I.A?I.A.isConcatSpreadable:void 0;let F=function(e){return(0,s.A)(e)||(0,T.A)(e)||!!(R&&e&&e[R])},N=function e(t,r,n,o,i){var a=-1,u=t.length;for(n||(n=F),i||(i=[]);++a<u;){var s=t[a];r>0&&n(s)?r>1?e(s,r-1,n,o,i):(0,k.A)(i,s):o||(i[i.length]=s)}return i};var M=r(1369),B=r(1136),L=r(1722);let V=(i=function(e,t){var r={};if(null==e)return r;var n=!1;t=(0,a.A)(t,function(t){return t=g(t,e),n||(n=t.length>1),t}),(0,j.A)(e,(0,L.A)(e),r),n&&(r=(0,u.A)(r,7,P));for(var o=t.length;o--;)D(r,t[o]);return r},(0,B.A)((0,M.A)(i,void 0,function(e){return(null==e?0:e.length)?N(e,1):[]}),i+""))},1026(e,t,r){"use strict";r.d(t,{A:()=>n});let n=function(){return[]}},2768(e,t,r){"use strict";r.d(t,{A:()=>d});var n=r(3578),o=r(6239),i=r(8206),a=r(1787),u=1/0,s=n.A?n.A.prototype:void 0,l=s?s.toString:void 0;let c=function e(t){if("string"==typeof t)return t;if((0,i.A)(t))return(0,o.A)(t,e)+"";if((0,a.A)(t))return l?l.call(t):"";var r=t+"";return"0"==r&&1/t==-u?"-0":r},d=function(e){return null==e?"":c(e)}},2879(e,t,r){"use strict";function n(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function o(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function i(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?o(Object(r),!0).forEach(function(t){var n,o,i;n=e,o=t,i=r[t],o in n?Object.defineProperty(n,o,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[o]=i}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):o(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function a(e){return(a="function"==typeof Symbol&&"symbol"==n(Symbol.iterator)?function(e){return void 0===e?"undefined":n(e)}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":void 0===e?"undefined":n(e)})(e)}function u(e){return(u="function"==typeof Symbol&&"symbol"==n(Symbol.iterator)?function(e){return void 0===e?"undefined":n(e)}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":void 0===e?"undefined":n(e)})(e)}function s(e,t){var r;if("function"!=typeof(r=t.domElement?function(){return t.domElement}:t.domElementGetter?t.domElementGetter:e.domElementGetter?e.domElementGetter:function(e){var t=e.appName||e.name;if(!t)throw Error("single-spa's dom-element-getter-helpers was not given an application name as a prop, so it can't make a unique dom element container for the react application");var r="single-spa-application:".concat(t);return function(){var e=document.getElementById(r);return e||((e=document.createElement("div")).id=r,document.body.appendChild(e)),e}}(t)))throw Error("single-spa's dom-element-getter-helpers was given an invalid domElementGetter for application or parcel '".concat(t.name,"'. Expected a function, received ").concat(u(r)));return function(){var e,n=r(t);if(null!=(e=HTMLElement)&&"u">typeof Symbol&&e[Symbol.hasInstance]?!e[Symbol.hasInstance](n):!(n instanceof e))throw Error("single-spa's dom-element-getter-helpers: domElementGetter returned an invalid dom element for application or parcel '".concat(t.name,"'. Expected HTMLElement, received ").concat(u(n)));return n}}r.d(t,{A:()=>d,i:()=>l});var l=null;try{l=require("react").createContext()}catch(e){}var c={React:null,ReactDOM:null,ReactDOMClient:null,rootComponent:null,loadRootComponent:null,errorBoundary:null,errorBoundaryClass:null,domElementGetter:null,parcelCanUpdate:!0,suppressComponentDidCatchWarning:!1,domElements:{},renderResults:{},updateResolves:{},unmountResolves:{}};function d(e){if("object"!==a(e))throw Error("single-spa-react requires a configuration object");var t,r=i(i({},c),e);if(!r.React)throw Error("single-spa-react must be passed opts.React");if(!r.ReactDOM&&!r.ReactDOMClient)throw Error("single-spa-react must be passed opts.ReactDOM or opts.ReactDOMClient");if(r.renderType||(null!=(t=r.ReactDOMClient)&&t.createRoot?r.renderType="createRoot":r.renderType="render"),!r.rootComponent&&!r.loadRootComponent)throw Error("single-spa-react must be passed opts.rootComponent or opts.loadRootComponent");if(r.errorBoundary&&"function"!=typeof r.errorBoundary)throw Error("The errorBoundary opt for single-spa-react must either be omitted or be a function that returns React elements");!l&&r.React.createContext&&(l=r.React.createContext()),r.SingleSpaRoot=function(e){function t(e){t.displayName="SingleSpaRoot(".concat(e.name,")")}return t.prototype=Object.create(e.React.Component.prototype),t.prototype.componentDidMount=function(){setTimeout(this.props.mountFinished)},t.prototype.componentWillUnmount=function(){setTimeout(this.props.unmountFinished)},t.prototype.render=function(){return setTimeout(this.props.updateFinished),this.props.children},t}(r);var n={bootstrap:f.bind(null,r),mount:p.bind(null,r),unmount:h.bind(null,r)};return r.parcelCanUpdate&&(n.update=m.bind(null,r)),n}function f(e,t){return e.rootComponent?Promise.resolve():e.loadRootComponent(t).then(function(t){e.rootComponent=t})}function p(e,t){return new Promise(function(r,n){e.suppressComponentDidCatchWarning||!function(e){if(!(e&&"string"==typeof e.version&&e.version.indexOf(".")>=0))return!1;var t=e.version.slice(0,e.version.indexOf("."));try{return Number(t)>=16}catch(e){return!1}}(e.React)||e.errorBoundary||e.errorBoundaryClass||(e.rootComponent.prototype?e.rootComponent.prototype.componentDidCatch||console.warn("single-spa-react: ".concat(t.name||t.appName||t.childAppName,"'s rootComponent should implement componentDidCatch to avoid accidentally unmounting the entire single-spa application.")):console.warn("single-spa-react: ".concat(t.name||t.appName||t.childAppName,"'s rootComponent does not implement an error boundary. If using a functional component, consider providing an opts.errorBoundary to singleSpaReact(opts).")));var o,i=b(e,t,function(){r(this)}),a=s(e,t)(),u=function(e){var t=e.reactDom,r=e.renderType,n=e.elementToRender,o=e.domElement,i=t[r];if("function"!=typeof i)throw Error('renderType "'.concat(r,'" did not return a function.'));switch(r){case"createRoot":case"unstable_createRoot":case"createBlockingRoot":case"unstable_createBlockingRoot":var a=i(o);return a.render(n),a;case"hydrateRoot":return i(o,n);default:return i(n,o),null}}({elementToRender:i,domElement:a,reactDom:y(e),renderType:"function"==typeof(o=e).renderType?o.renderType():o.renderType});e.domElements[t.name]=a,e.renderResults[t.name]=u})}function h(e,t){return new Promise(function(r){e.unmountResolves[t.name]=r;var n=e.renderResults[t.name];n&&n.unmount?n.unmount():y(e).unmountComponentAtNode(e.domElements[t.name]),delete e.domElements[t.name],delete e.renderResults[t.name]})}function m(e,t){return new Promise(function(r){e.updateResolves[t.name]||(e.updateResolves[t.name]=[]),e.updateResolves[t.name].push(r);var n=b(e,t,null),o=e.renderResults[t.name];if(o&&o.render)o.render(n);else{var i=s(e,t)();y(e).render(n,i)}})}function y(e){return e.ReactDOMClient||e.ReactDOM}function b(e,t,r){var n=e.React.createElement(e.rootComponent,t),o=l?e.React.createElement(l.Provider,{value:t},n):n;return(e.errorBoundary||t.errorBoundary||e.errorBoundaryClass||t.errorBoundaryClass)&&(e.errorBoundaryClass=e.errorBoundaryClass||t.errorBoundaryClass||function(e,t){function r(t){e.React.Component.apply(this,arguments),this.state={caughtError:null,caughtErrorInfo:null},r.displayName="SingleSpaReactErrorBoundary(".concat(t.name,")")}return r.prototype=Object.create(e.React.Component.prototype),r.prototype.render=function(){return this.state.caughtError?(e.errorBoundary||t.errorBoundary)(this.state.caughtError,this.state.caughtErrorInfo,this.props):this.props.children},r.prototype.componentDidCatch=function(e,t){this.setState({caughtError:e,caughtErrorInfo:t})},r}(e,t),o=e.React.createElement(e.errorBoundaryClass,t,o)),o=e.React.createElement(e.SingleSpaRoot,i(i({},t),{},{mountFinished:r,updateFinished:function(){e.updateResolves[t.name]&&(e.updateResolves[t.name].forEach(function(e){return e()}),delete e.updateResolves[t.name])},unmountFinished:function(){e.unmountResolves[t.name]&&(e.unmountResolves[t.name](),delete e.unmountResolves[t.name])}}),o)}},3058(e,t,r){"use strict";r.d(t,{lo:()=>A,HW:()=>T,QE:()=>K,xC:()=>L,$f:()=>D,Kx:()=>V,EW:()=>R,E4:()=>F,Gm:()=>O,eA:()=>k,yH:()=>N,ut:()=>x,Y0:()=>H,L7:()=>z,IU:()=>E,Jj:()=>w,g$:()=>M,Gp:()=>U,Ct:()=>S,Fi:()=>$,st:()=>B});var n=r(8507),o=r(2883);let i=function(e){return void 0===e};var a=r(7436),u=r(7344),s=r(7994),l=r(7774),c="${openmrsSpaBase}/login",d={redirectAuthFailure:{enabled:{_type:s.ZU.Boolean,_default:!0,_description:"Whether to redirect logged-out users to `redirectAuthFailure.url`"},url:{_type:s.ZU.String,_default:c,_validators:[s.y$.isUrl],_description:"The url to which users will be redirected when they are logged out. If set to blank, the `location` header from the response will be used."},errors:{_type:s.ZU.Array,_default:[401],_elements:{_type:s.ZU.Number,_validators:[s.y$.inRange(100,600)]},_description:"The HTTP error codes for which users will be redirected"},resolvePromise:{_type:s.ZU.Boolean,_default:!1,_description:"Changes how requests that fail authentication are handled. Try messing with this if redirects to the login page aren't working correctly."}},followRedirects:{_type:s.ZU.Boolean,_default:!0,_description:"Whether openmrsFetch should support redirects returned from the backend"}};function f(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function p(e,t,r){return(p=v()?Reflect.construct:function(e,t,r){var n=[null];n.push.apply(n,t);var o=new(Function.bind.apply(e,n));return r&&m(o,r.prototype),o}).apply(null,arguments)}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function m(e,t){return(m=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function y(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function b(e){var t="function"==typeof Map?new Map:void 0;return(b=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return p(e,arguments,h(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),m(r,e)})(e)}function v(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(v=function(){return!!e})()}function g(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var w="/ws/rest/v1",E="/ws/fhir2/R4",S="".concat(w,"/session");function O(e){return e&&e.startsWith("http")?e:("/"!==e[0]&&(e="/"+e),window.openmrsBase+e)}function A(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if("string"!=typeof e)throw Error("The first argument to @openmrs/api's openmrsFetch function must be a url string");if((void 0===t?"undefined":y(t))!=="object")throw Error("The second argument to @openmrs/api's openmrsFetch function must be a plain object.");if(!window.openmrsBase)throw Error("@openmrs/api is running in a browser that doesn't have window.openmrsBase, which is provided by openmrs-module-spa's HTML file.");var r=O(e);if(t.headers||(t.headers={}),(0,u.A)(t.body)&&(t.body=JSON.stringify(t.body)),void 0===t.headers.Accept&&(t.headers.Accept="application/json"),null===t.headers.Accept&&delete t.headers.Accept,e.startsWith(w)&&void 0===t.headers["Disable-WWW-Authenticate"]&&(t.headers["Disable-WWW-Authenticate"]="true"),e.startsWith(E)){var n=new URL(r,window.location.toString());n.searchParams.has("_summary")||(n.searchParams.set("_summary","data"),r=n.toString())}var o=Error();return window.fetch(r,t).then(function(e){var t;return(t=function(){var t,n,i,a,u,d;return function(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(f){switch(f.label){case 0:return t=e,[4,(0,s.zj)("@openmrs/esm-api")];case 1:if(i=(n=f.sent()).redirectAuthFailure,a=n.followRedirects,t.ok)if(204===t.status)return a&&t.headers.has("location")&&(u=t.headers.get("location"))&&(0,l.oo)({to:u}),t.data=null,[2,t];else return[2,t.clone().text().then(function(e){try{e&&(t.data=JSON.parse(e))}catch(e){}return t})];if(r===O(S)&&403===t.status||i.enabled&&i.errors.includes(t.status))return(0,l.g4)(),d=i.url||t.headers.get("location")||c,(0,l.oo)({to:d}),[2,i.resolvePromise?Promise.resolve():new Promise(function(){})];return[2,t.clone().text().then(function(e){var n=e;try{n=JSON.parse(e)}catch(e){}throw new D(r,t,n,o)},function(e){throw new D(r,t,null,o)})]}})},function(){var e=this,r=arguments;return new Promise(function(n,o){var i=t.apply(e,r);function a(e){f(i,n,o,a,u,"next",e)}function u(e){f(i,n,o,a,u,"throw",e)}a(void 0)})})()})}function x(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if((void 0===t?"undefined":y(t))!=="object")throw Error("The second argument to openmrsObservableFetch must be either omitted or an object");var r=new AbortController;return t.signal=r.signal,new a.Observable(function(n){var o=!1;return A(e,t).then(function(e){o=!0,n.next(e),n.complete()},function(e){o=!0,n.error(e)}),function(){o||r.abort()}})}var D=function(e){if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function t(e,r,n,o){var i,a;if(!(this instanceof t))throw TypeError("Cannot call a class as a function");return a=h(a=t),g(i=function(e,t){if(t&&("object"===y(t)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,v()?Reflect.construct(a,[],h(this).constructor):a.apply(this,void 0)),"response",void 0),g(i,"responseBody",void 0),i.message="Server responded with ".concat(r.status," (").concat(r.statusText,") for url ").concat(e,". Check err.responseBody or network tab in dev tools for more info"),o.message=i.message,i.responseBody=n,i.response=r,i.stack="Stacktrace for outgoing request:\n".concat(o.stack,"\nStacktrace for incoming response:\n").concat(i.stack),i}return t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&m(t,e),t}(b(Error));function j(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function C(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){j(i,n,o,a,u,"next",e)}function u(e){j(i,n,o,a,u,"throw",e)}a(void 0)})}}function P(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}var k=(0,o.Zd)("session",{loaded:!1,session:null}),I=0;function T(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{includeAuthStatus:!0};return(I<Date.now()-6e4||!k.getState().loaded)&&N(),new a.Observable(function(t){var r=function(r){if(r.loaded)if(e.includeAuthStatus)t.next(r.session);else{var n;t.next(null==(n=r.session)?void 0:n.user)}};return r(k.getState()),k.subscribe(r)})}function R(){return(I<Date.now()-6e4||!k.getState().loaded)&&N(),k}function F(e){var t,r,n,o=null!=(t=e.locale)?t:null==(n=e.user)||null==(r=n.userProperties)?void 0:r.defaultLocale;o&&o.includes("_")&&(o=o.replaceAll("_","-")),function(e){if(void 0===e||"string"!=typeof e)return!1;try{new Intl.Locale(e)}catch(e){return!1}return!0}(o)&&o!==document.documentElement.getAttribute("lang")&&document.documentElement.setAttribute("lang",o)}function N(e,t){I=Date.now();var r={};return e&&t&&(r.Authorization="Basic ".concat(window.btoa("".concat(e,":").concat(t)))),W(A(S,{headers:r}))}function M(){k.setState({loaded:!0,session:{authenticated:!1,sessionId:""}})}function B(e,t){var r,n;if(void 0===t)return!e;if(!e)return!0;return r=e,n=t,("string"==typeof r?!i(n.privileges.find(function(e){return r===e.display})):Array.isArray(r)?r.every(function(e){return!i(n.privileges.find(function(t){return e===t.display}))}):(i(r)||console.error('Could not understand privileges "'.concat(r,'"')),!0))||!i(t.roles.find(function(e){return"System Developer"===e.display}))}function L(){var e,t;return new Promise(function(r){var n=function(n){n.loaded&&n.session.user&&(e=n.session.user,r(n.session.user),t&&t())};n(k.getState()),e||(t=k.subscribe(n))})}function V(){return new Promise(function(e,t){T().subscribe(function(t){e(t.sessionLocation)},t).unsubscribe()})}function U(e,t){return C(function(){return P(this,function(r){return[2,W(A(S,{method:"POST",body:{sessionLocation:e},headers:{"Content-Type":"application/json"},signal:t.signal}))]})})()}function $(e,t,r){return C(function(){return P(this,function(n){switch(n.label){case 0:return r||(r=new AbortController),[4,A("".concat(w,"/user/").concat(e),{method:"POST",body:{userProperties:t},headers:{"Content-Type":"application/json"},signal:r.signal})];case 1:return n.sent(),[2,N()]}})})()}function W(e){return new Promise(function(t,r){e.then(function(e){var n,o;"object"==((o=null==e?void 0:e.data)&&"u">typeof Symbol&&o.constructor===Symbol?"symbol":typeof o)?(n={loaded:!0,session:e.data},k.setState(n),t(n)):(n={loaded:!1,session:null},k.setState(n),r(n))}).catch(function(e){(0,n.N)("Failed to fetch new session information: ".concat(e));var t={loaded:!1,session:null};k.setState(t),r(t)})})}function z(){return"development"===window.spaEnv||"true"===localStorage.getItem("openmrs:devtools")}k.subscribe(function(e){e.loaded&&e.session&&F(e.session)});var K={"webservices.rest":"2.24.0",fhir2:"1.0.0-SNAPSHOT"};function H(){(0,s.T0)("@openmrs/esm-api",d),N()}},7994(e,t,r){"use strict";r.d(t,{Gt:()=>Z,GV:()=>G,Rt:()=>g,YP:()=>O,hs:()=>E,T0:()=>z,Nc:()=>c,ZU:()=>l,td:()=>J,qG:()=>eb,GI:()=>D,FL:()=>K,g$:()=>P,H:()=>w,zj:()=>Y,mq:()=>X,gU:()=>ev,tN:()=>k,P0:()=>C,IS:()=>S,UY:()=>j,Nh:()=>ef,kl:()=>H,vu:()=>x,r4:()=>ey,yL:()=>eg,Nz:()=>ep,y$:()=>ew,G9:()=>A,ks:()=>q});var n,o=r(2102),i=(0,r(6317).A)(function(e,t,r,n){(0,o.A)(e,t,r,n)}),a=r(4809),u=r(313),s=r(2288),l=((n={}).Array="Array",n.Boolean="Boolean",n.ConceptUuid="ConceptUuid",n.Number="Number",n.Object="Object",n.String="String",n.UUID="UUID",n.PersonAttributeTypeUuid="PersonAttributeTypeUuid",n.PatientIdentifierTypeUuid="PatientIdentifierTypeUuid",n);function c(e,t){return function(r){if(!e(r))if("function"==typeof t)return t(r);else return t}}var d=c(function(e){return Array.isArray(e)},"must be an array"),f=c(function(e){return"boolean"==typeof e},"must be a boolean"),p=c(function(e){return"number"==typeof e},"must be a number"),h=c(function(e){return"string"==typeof e},"must be a string"),m=c(function(e){return(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"&&!Array.isArray(e)&&null!==e},"must be an object (not an array or null)"),y=c(function(e){return/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(e)||/^[0-9a-f]{36}$/i.test(e)},"must be a valid UUID or a 36-character hexadecimal string"),b=r(2883),v=r(8254),g=(0,b.Zd)("config-internal",{providedConfigs:[],schemas:{},moduleLoaded:{}}),w=(0,b.Zd)("temporary-config",{config:function(){try{return JSON.parse(localStorage.getItem("openmrs:temporaryConfig")||"{}")}catch(e){return{}}}()});w.subscribe(function(e){var t=e.config;try{localStorage.setItem("openmrs:temporaryConfig",JSON.stringify(t))}catch(e){}});var E=(0,b.Zd)("config-store-of-extension-state",{mountedExtensions:[]});function S(e){return(0,b.jf)("config-module-".concat(e),{config:null,loaded:!1,translationOverridesLoaded:!1})}function O(){return(0,b.jf)("config-extension-slots",{slots:{}})}function A(e){return x(O().getState(),e)}function x(e,t){var r=e.slots[t];return null!=r?r:{loaded:!1,config:{}}}function D(){return(0,b.jf)("config-extensions",{configs:{}})}function j(e,t){if("string"!=typeof e||"string"!=typeof t||"__proto__"===e||"__proto__"===t||"constructor"===e||"constructor"===t||"prototype"===e||"prototype"===t)throw Error("Attempted to call `getExtensionConfig()` with invalid argument");var r=D(),n=function(r){var n;return null==(n=r.configs[e])?void 0:n[t]};return{getInitialState:function(){return n(r.getInitialState())},getState:function(){var e;return null!=(e=n(r.getState()))?e:{loaded:!1,config:null}},setState:function(n){var o=arguments.length>1&&void 0!==arguments[1]&&arguments[1];r.setState(function(r){r.configs[e]||(r.configs[e]={});var i="function"==typeof n?n(r.configs.slotName[t]):n;return o?r.configs[e][t]=Object.assign({},i):r.configs[e][t]=Object.assign({},r.configs[e][t],i),r})},subscribe:function(e){return r.subscribe(function(t,r){var o=n(t),i=n(r);(0,v.b)(o,i)||e(o,i)})},destroy:function(){}}}function C(e,t,r){var n,o=null==(n=e.configs[t])?void 0:n[r];return null!=o?o:{loaded:!1,config:null}}function P(e,t,r){var n,o=null==(n=e.configure)?void 0:n[r];return null!=o?o:null}var k=(0,b.Zd)("config-implementer-tools",{config:{}});function I(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function T(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function R(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){T(e,t,r[t])})}return e}function F(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function N(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],a=!0,u=!1;try{for(o=o.call(e);!(a=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){u=!0,n=e}finally{try{a||null==o.return||o.return()}finally{if(u)throw n}}return i}}(e,t)||L(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function M(e){return function(e){if(Array.isArray(e))return I(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||L(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function B(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function L(e,t){if(e){if("string"==typeof e)return I(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return I(e,t)}}function V(e,t){return i({},e,t,function(e,t){if(Array.isArray(t))return t})}var U=[];function $(){var e,t,r,n,o,i,u,l,c,d,f=g.getState(),p=w.getState(),h=E.getState();(function(e,t){var r=!0,n=!1,o=void 0;try{for(var i,a=Object.keys(e.schemas)[Symbol.iterator]();!(r=(i=a.next()).done);r=!0){var u=i.value,s=S(u),l=void 0;if(e.moduleLoaded[u]){var c=function(e,t,r){var n=t.schemas[e],o=et(e,Q(t,r));en(n,o,e);var i=eu(n,o);return eo(n,i,e),delete i.extensionSlots,i}(u,e,t);l={translationOverridesLoaded:!0,loaded:!0,config:c}}else{var d=function(e,t,r){var n=eu(em,et(e,Q(t,r)));return eo(em,n,e),delete n.extensionSlots,n}(u,e,t);l={translationOverridesLoaded:!0,loaded:!1,config:d}}s.setState(l)}}catch(e){n=!0,o=e}finally{try{r||null==a.return||a.return()}finally{if(n)throw o}}})(f,p),e=f,t=p,r=k.getState(),n={config:function(e,t){var r=function e(t){return t.hasOwnProperty("_default")?F(R({},t),{_value:t._default,_source:"default"}):el(t)?Object.keys(t).reduce(function(r,n){return r[n]=e(t[n]),r},{}):{}}((u=e.schemas,(0,s.A)(u,5))),n=M(e.providedConfigs.map(function(e){return[e.config,e.source]})).concat([[t.config,"temporary config"]]),o=!0,i=!1,a=void 0;try{for(var u,l,c=n[Symbol.iterator]();!(o=(l=c.next()).done);o=!0){var d=N(l.value,2),f=d[0],p=d[1];r=er([r,function e(t,r){return el(t)?Object.keys(t).reduce(function(n,o){return n[o]=e(t[o],r),n},{}):{_value:t,_source:r}}(f,p)])}}catch(e){i=!0,a=e}finally{try{o||null==c.return||c.return()}finally{if(i)throw a}}return r}(e,t)},(0,a.A)(r.config,n.config)||k.setState(n),u=Object.fromEntries(Object.entries((function(e){var t=!0,r=!1,n=void 0;try{for(var o,i=Object.entries(e)[Symbol.iterator]();!(t=(o=i.next()).done);t=!0){var a=N(o.value,2),u=a[0],s=a[1],l=!0,c=!1,d=void 0;try{for(var f,p=Object.entries(s)[Symbol.iterator]();!(l=(f=p.next()).done);l=!0){var h=N(f.value,2),m=h[0],y=h[1];!function(e,t,r){var n="".concat(t,".extensionSlots.").concat(r),o="Extension slot config '".concat(n,"'"),i=Object.keys(e).filter(function(e){return!["add","remove","order","configure"].includes(e)});i.length&&ed(n,o+"' contains invalid keys '".concat(i.join("', '"),"'")),!e.add||Array.isArray(e.add)&&e.add.every(function(e){return"string"==typeof e})||ed(n,o+".add' is invalid. Must be an array of strings (extension IDs)"),!e.remove||Array.isArray(e.remove)&&e.remove.every(function(e){return"string"==typeof e})||ed(n,o+".remove' is invalid. Must be an array of strings (extension IDs)"),!e.order||Array.isArray(e.order)&&e.order.every(function(e){return"string"==typeof e})||ed(n,o+".order' is invalid. Must be an array of strings (extension IDs)"),e.configure&&!el(e.configure)&&ed(n,o+".configure' is invalid. Must be an object with extension IDs for keys")}(y,u,m)}}catch(e){c=!0,d=e}finally{try{l||null==p.return||p.return()}finally{if(c)throw d}}}}catch(e){r=!0,n=e}finally{try{t||null==i.return||i.return()}finally{if(r)throw n}}}(i=Object.keys(o=er(Q(f,p))).reduce(function(e,t){var r,n;return(null==(r=o[t])?void 0:r.extensionSlots)&&(e[t]=null==(n=o[t])?void 0:n.extensionSlots),e},{})),Object.keys(i).reduce(function(e,t){return R({},e,i[t])},{}))).map(function(e){var t=N(e,2);return[t[0],{loaded:!0,config:t[1]}]})),d={slots:R({},(c=(l=O()).getState()).slots,u)},(0,a.A)(c.slots,d.slots)||l.setState(d),function(e,t,r){var n={},o=!0,i=!1,u=void 0;try{for(var s,l=t.mountedExtensions[Symbol.iterator]();!(o=(s=l.next()).done);o=!0){var c=s.value,d=function(e,t,r,n,o,i){var a,u,s,l,c,d=(a=n,N(a.split("#"),1)[0]),f=o.schemas[d],p=f?d:t,h=Q(o,i),m=et(e,h),y=null!=(u=null==m||null==(c=m.extensionSlots)||null==(l=c[r])||null==(s=l.configure)?void 0:s[n])?u:{},b=er([et(p,h),y]),v=null!=f?f:o.schemas[t];en(v,b,p);var g=eu(v,b);return eo(v,g,p),delete g.extensionSlots,g}(c.slotModuleName,c.extensionModuleName,c.slotName,c.extensionId,e,r);n[c.slotName]||(n[c.slotName]={}),n[c.slotName][c.extensionId]={config:d,loaded:!0}}}catch(e){i=!0,u=e}finally{try{o||null==l.return||l.return()}finally{if(i)throw u}}var f=D(),p=f.getState(),h={configs:n};(0,a.A)(p.configs,h.configs)||f.setState(h)}(f,h,p)}function W(){$(),U.push(g.subscribe($)),U.push(w.subscribe($)),U.push(E.subscribe($))}function z(e,t){ee(e,t);var r=V(t,em);g.setState(function(t){return F(R({},t),{schemas:F(R({},t.schemas),T({},e,r)),moduleLoaded:F(R({},t.moduleLoaded),T({},e,!0))})})}function K(e){g.setState(function(t){return F(R({},t),{schemas:F(R({},t.schemas),T({},e,em))})})}function H(e){g.setState(function(t){return F(R({},t),{moduleLoaded:F(R({},t.moduleLoaded),T({},e,!0))})})}function G(e){g.setState(function(t){return F(R({},t),{schemas:F(R({},t.schemas),T({},e,eh))})})}function q(e,t){ee(e,t);var r=V(t,em);g.getState().schemas[e]&&console.error("Config schema for extension ".concat(e," already exists. If there are multiple extensions with this same name, one will probably crash.")),g.setState(function(t){return F(R({},t),{schemas:F(R({},t.schemas),T({},e,r))})})}function Z(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"provided";g.setState(function(r){return F(R({},r),{providedConfigs:M(r.providedConfigs).concat([{source:t,config:e}])})})}function Y(e){return new Promise(function(t){var r=function(e){e.loaded&&e.config&&(t((0,u.A)(e.config,["Display conditions","Translation overrides"])),o&&o())},n=S(e);r(n.getState());var o=n.subscribe(r)})}function J(e,t,r){var n=[new Promise(function(t){var r=function(e){if(e.translationOverridesLoaded&&e.config){var r;t(null!=(r=e.config["Translation overrides"])?r:{}),o&&o()}},n=S(e);r(n.getState());var o=n.subscribe(r)})];return t&&r&&n.push(new Promise(function(e){var n=function(t){if(t.loaded&&t.config){var r;e(null!=(r=t.config["Translation overrides"])?r:{}),i&&i()}},o=j(t,r);n(o.getState());var i=o.subscribe(n)})),Promise.all(n)}function X(e,t,r){en(e,t,r);var n=eu(e,t);return eo(e,n,r),n}function Q(e,t){return M(e.providedConfigs.map(function(e){return e.config})).concat([t.config])}function ee(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n="Please verify that you are running the latest version and, if so, alert the maintainer.",o=!0,i=!1,a=void 0;try{for(var u,s=Object.keys(t).filter(function(e){return!e.startsWith("_")})[Symbol.iterator]();!(o=(u=s.next()).done);o=!0){var c=u.value,d=r+(r&&".")+c,f=t[c];if("Display conditions"===d&&console.error("".concat(e,' declares a configuration option called "Display conditions"; the "Display conditions" option is a reserved name. ').concat(n)),"Translation overrides"===d&&console.error("".concat(e,' declares a configuration option called "Translation overrides"; the "Translation overrides" option is a reserved name. ').concat(n)),!el(f)){console.error("".concat(e," has bad config schema definition for key '").concat(d,"'. ").concat(n));continue}f.hasOwnProperty("_default")||ee(e,f,d);var p=f._elements;if(es(p)&&ee(e,p,d+"._elements"),f._validators){var h=!0,m=!1,y=void 0;try{for(var b,v=f._validators[Symbol.iterator]();!(h=(b=v.next()).done);h=!0){var g=b.value;"function"!=typeof g&&console.error("".concat(e," has invalid validator for key '").concat(d,"' ").concat(n,".")+"\n\nIf you're the maintainer: validators must be functions that return either "+"undefined or an error string. Received ".concat(g,"."))}}catch(e){m=!0,y=e}finally{try{h||null==v.return||v.return()}finally{if(m)throw y}}}var w=f._type;w&&!Object.values(l).includes(w)&&console.error("".concat(e," has invalid type for key '").concat(d,"' ").concat(n,".")+"\n\nIf you're the maintainer: the allowed types are ".concat(Object.values(l).join(", "),". ")+"Received '".concat(w,"'")),Object.keys(f).every(function(e){return["_description","_validators","_elements","_type"].includes(e)})&&!r.includes("._elements")&&console.error("".concat(e," has bad config schema definition for key '").concat(d,"'. ").concat(n,".")+"\n\nIf you're the maintainer: all config elements must have a default. "+"Received ".concat(JSON.stringify(f))),p&&w&&![l.Array,l.Object].includes(w)&&console.error("".concat(e," has bad config schema definition for key '").concat(d,"'. ").concat(n,".")+"\n\nIf you're the maintainer: the 'elements' key only works with '_type' equal to 'Array' or 'Object'. "+"Received ".concat(JSON.stringify(w)))}}catch(e){i=!0,a=e}finally{try{o||null==s.return||s.return()}finally{if(i)throw a}}}function et(e,t){return er(t.map(function(t){return t[e]}).filter(function(e){return!!e}))}function er(e){return e.reduce(function(e,t){return V(e,t)},{})}function en(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=!0,o=!1,i=void 0;try{for(var a,u=Object.keys(t)[Symbol.iterator]();!(n=(a=u.next()).done);n=!0){var s=a.value,c=t[s],d=r+"."+s,f=e[s];if(!e.hasOwnProperty(s)){("extensionSlots"!==s||""===r)&&ed(d,"Unknown config key '".concat(d,"' provided. Ignoring."));continue}(function e(t,r,n){ei(n,t._type,r),el(r)?t._type===l.Object?function(t,r,n){if(t._elements){var o=!0,i=!1,a=void 0;try{for(var u,s=Object.keys(r)[Symbol.iterator]();!(o=(u=s.next()).done);o=!0){var l=u.value,c=r[l];e(t._elements,c,"".concat(n,".").concat(l))}}catch(e){i=!0,a=e}finally{try{o||null==s.return||s.return()}finally{if(i)throw a}}}}(t,r,n):t.hasOwnProperty("_default")||t.hasOwnProperty("_type")||en(t,r,n):t._type===l.Array&&function(t,r,n){var o;if(ei(n,l.Array,r)){if(es(t._elements))for(var i=0;i<r.length;i++)e(t._elements,r[i],"".concat(n,"[").concat(i,"]"));for(var a=0;a<r.length;a++)ei("".concat(n,"[").concat(a,"]"),null==(o=t._elements)?void 0:o._type,r[a])}}(t,r,n)})(f,c,d)}}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}}W();function eo(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";if(e){if(t!==e._default&&ea(r,e._validators,t),el(t)){var n=!0,o=!1,i=void 0;try{for(var a,u=Object.keys(t)[Symbol.iterator]();!(n=(a=u.next()).done);n=!0){var s=a.value,c=t[s],d=r+"."+s,f=e[s];e._type===l.Object&&e._elements?eo(e._elements,c,d):eo(f,c,d)}}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}}else if(Array.isArray(t)&&e._elements)for(var p=0;p<t.length;p++)eo(e._elements,t[p],"".concat(r,"[").concat(p,"]"))}}function ei(e,t,r){return!t||ea(e,[{Array:d,Boolean:f,ConceptUuid:y,Number:p,Object:m,String:h,UUID:y,PersonAttributeTypeUuid:y,PatientIdentifierTypeUuid:y}[t]],r)}function ea(e,t,r){var n=!0;if(t)try{var o=!0,i=!1,a=void 0;try{for(var u,s=t[Symbol.iterator]();!(o=(u=s.next()).done);o=!0){var l=(0,u.value)(r);if("string"==typeof l){var c=(void 0===r?"undefined":B(r))==="object"?"Invalid configuration for ".concat(e,": ").concat(l):"Invalid configuration value ".concat(r," for ").concat(e,": ").concat(l);ed(e,c),n=!1}}}catch(e){i=!0,a=e}finally{try{o||null==s.return||s.return()}finally{if(i)throw a}}}catch(t){console.error('Skipping invalid validator at "'.concat(e,'". Encountered error\n ').concat(t))}return n}var eu=function(e,t){var r=structuredClone(t);if(!e)return r;var n=!0,o=!1,i=void 0;try{for(var a,u=Object.keys(e)[Symbol.iterator]();!(n=(a=u.next()).done);n=!0)!function(){var t=a.value,n=r[t],o=e[t];if(o&&(o.hasOwnProperty("_type")||o.hasOwnProperty("_default"))){r.hasOwnProperty(t)||(r[t]=o._default);var i=o._elements;if(n&&es(i)){if(o._type===l.Array&&Array.isArray(n)){var u=n.map(function(e){return eu(i,e)});r[t]=u}else if(o._type===l.Object){var s=!0,c=!1,d=void 0;try{for(var f,p=Object.keys(n)[Symbol.iterator]();!(s=(f=p.next()).done);s=!0){var h=f.value;n[h]=eu(i,n[h])}}catch(e){c=!0,d=e}finally{try{s||null==p.return||p.return()}finally{if(c)throw d}}}}}else if(el(o)){var m=null!=n?n:{};el(m)&&(r[t]=eu(o,m))}}()}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}return r};function es(e){return!!e&&Object.keys(e).filter(function(e){return!["_default","_validators"].includes(e)}).length>0}function el(e){return(void 0===e?"undefined":B(e))==="object"&&!Array.isArray(e)&&null!==e}var ec=new Set;function ed(e,t){var r="".concat(e,":::").concat(t);ec||(ec=new Set),ec.has(r)||(console.error(t),ec.add(r))}function ef(e){e?ec.forEach(function(t){t.startsWith(e)&&ec.delete(t)}):ec.clear()}function ep(){U.forEach(function(e){return e()}),U.length=0,W()}var eh={"Translation overrides":{_description:"Per-language overrides for frontend translations should be keyed by language code and each language dictionary contains the translation key and the display value",_type:l.Object,_default:{},_validators:[c(function(e){return Object.keys(e).every(function(e){return/^[a-z]{2,3}(-[A-Z]{2,3})?$/.test(e)})},function(e){var t=Object.keys(e).filter(function(e){return!/^[a-z]{2,3}(-[A-Z]{2,3})?$/.test(e)});return"The 'Translation overrides' object should have language codes for keys. Language codes must be in the form of a two-to-three letter language code optionally followed by a hyphen and a two-to-three letter country code. The following keys do not conform: ".concat(t.join(", "),".")})]}},em=R({"Display conditions":{privileges:{_description:"The privilege(s) the user must have to use this extension",_type:l.Array,_default:[]},expression:{_description:"The expression that determines whether the extension is displayed",_type:l.String,_default:void 0}}},eh),ey=function(e,t){return c(function(r){return e<=r&&r<=t},"must be between ".concat(e," and ").concat(t))},eb=function(e){var t=e.concat(["openmrsBase","openmrsSpaBase"]);return c(function(e){if(!e||"string"!=typeof e)return!1;for(var r=/\${(.*?)}/g,n=r.exec(e);n;){if(!t.includes(n[1]))return!1;n=r.exec(e)}return!0},"Should be a URL or path. The allowed template parameters are "+t.map(function(e){return"${"+e+"}"}).join(", "))},ev=eb([]),eg=function(e){return c(function(t){return e.includes(t)},"Must be one of the following: '".concat(e.join("', '"),"'."))},ew={inRange:ey,isUrl:ev,isUrlWithTemplateParameters:eb,oneOf:eg}},1265(e,t,r){"use strict";r.d(t,{hG:()=>v,dx:()=>C,X1:()=>g,Bv:()=>l,Pu:()=>x,Vs:()=>O,cD:()=>c,KU:()=>s,BX:()=>T,Ds:()=>F,DK:()=>B,BR:()=>M,$y:()=>w,xL:()=>N,E$:()=>S,Rb:()=>k,SY:()=>d,NH:()=>R,Cj:()=>P,Qx:()=>A,Zu:()=>u});var n,o,i=r(3058);function a(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}var u="".concat(i.Jj,"/attachment");function s(e,t){return(0,i.lo)("".concat(u,"/").concat(e),{signal:t.signal})}function l(e,t,r){return(0,i.lo)("".concat(u,"?patient=").concat(e,"&includeEncounterless=").concat(t),{signal:r.signal})}function c(e,t){var r;return(r=function(){var r;return function(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(n){return(r=new FormData).append("fileCaption",t.fileDescription),r.append("patient",e),t.file?r.append("file",t.file,t.fileName):(r.append("file",new File([""],t.fileName),t.fileName),r.append("base64Content",t.base64Content)),[2,(0,i.lo)("".concat(u),{method:"POST",body:r})]})},function(){var e=this,t=arguments;return new Promise(function(n,o){var i=r.apply(e,t);function u(e){a(i,n,o,u,s,"next",e)}function s(e){a(i,n,o,u,s,"throw",e)}u(void 0)})})()}function d(e,t){return(0,i.lo)("".concat(u,"/").concat(e),{method:"DELETE",signal:t.signal})}var f=r(7426);function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function h(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function m(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){h(i,n,o,a,u,"next",e)}function u(e){h(i,n,o,a,u,"throw",e)}a(void 0)})}}function y(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],a=!0,u=!1;try{for(o=o.call(e);!(a=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){u=!0,n=e}finally{try{a||null==o.return||o.return()}finally{if(u)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return p(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return p(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function b(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}function v(e,t){var r=!(arguments.length>2)||void 0===arguments[2]||arguments[2];return m(function(){var n,o,a,u;return b(this,function(s){switch(s.label){case 0:var l;if(!e)return[3,2];return n=null,[4,Promise.all([(0,i.lo)("".concat(i.IU,"/Patient/").concat(e),t).catch(function(e){return n=e}),r?(l=e,m(function(){var e,t;return b(this,function(r){switch(r.label){case 0:return[4,(0,f.pb)("patient-registration")];case 1:return[2,null!=(e=null==(t=r.sent().find(function(e){return e.fhirPatient.id===l}))?void 0:t.fhirPatient)?e:null]}})})()):Promise.resolve(null)])];case 1:if(a=(o=y.apply(void 0,[s.sent(),2]))[0],u=o[1],a.ok)return[2,a.data];if(u)return[2,u];if(n)throw n;s.label=2;case 2:return[2,null]}})})()}function g(e,t){var r=new CustomEvent("openmrs:".concat(e),{detail:null!=t?t:void 0,cancelable:!0,bubbles:!0});return window.dispatchEvent(r)}function w(e,t){var r=function(e){t("detail"in e&&null!==e.detail?e.detail:void 0)};return window.addEventListener("openmrs:".concat(e),r),function(){window.removeEventListener("openmrs:".concat(e),r)}}var E=r(2719);function S(e){return{uuid:e.uuid,display:e.display}}function O(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,r=new URLSearchParams;e&&r.set("tag",e),t&&r.set("q",t);var n=r.toString(),o="".concat(i.Jj,"/location").concat(n?"?"+n:"");return(0,i.ut)(o).pipe((0,E.map)(function(e){return e.data.results.map(S)})).pipe((0,E.take)(1))}function A(e){return{uuid:e.uuid,display:e.display,name:e.name}}function x(){return(0,i.ut)("".concat(i.Jj,"/visittype")).pipe((0,E.map)(function(e){return e.data.results.map(A)})).pipe((0,E.take)(1))}var D=r(2883),j=r(7436),C=((n={}).NEWVISIT="startVisit",n.EDITVISIT="editVisit",n.LOADING="loadingVisit",n),P=((o={}).NOTSTARTED="notStarted",o.ONGOING="ongoing",o),k="custom:(uuid,display,voided,indication,startDatetime,stopDatetime,encounters:(uuid,display,encounterDatetime,form:(uuid,name),location:ref,encounterType:ref,encounterProviders:(uuid,display,provider:(uuid,display))),patient:(uuid,display),visitType:(uuid,name,display),attributes:(uuid,display,attributeType:(name,datatypeClassname,uuid),value),location:(uuid,name,display))",I=function(){try{return JSON.parse(sessionStorage.getItem("openmrs:visitStoreState")||"null")}catch(e){return null}}()||{patientUuid:null,manuallySetVisitUuid:null,mutateVisitCallbacks:{}};function T(){return(0,D.jf)("visit",I)}function R(e,t){T().setState({patientUuid:e,manuallySetVisitUuid:t})}function F(e,t){return(0,i.lo)("".concat(i.Jj,"/visit"),{signal:t.signal,method:"POST",headers:{"Content-type":"application/json"},body:e})}function N(e,t,r){return(0,i.lo)("".concat(i.Jj,"/visit/").concat(e),{signal:r.signal,method:"POST",headers:{"Content-type":"application/json"},body:t})}function M(e,t,r){return(0,i.lo)("".concat(i.Jj,"/visit?patient=").concat(e,"&v=").concat(null!=r?r:k),{signal:t.signal,method:"GET",headers:{"Content-type":"application/json"}})}T().subscribe(function(e){var t;t=e,sessionStorage.setItem("openmrs:visitStoreState",JSON.stringify(t))});var B=new j.BehaviorSubject(null)},8507(e,t,r){"use strict";r.d(t,{J:()=>i,N:()=>o});var n=r(9726);function o(e){var t=a(e);setTimeout(function(){throw t})}function i(){var e=Error();return function(t){var r=a(t);r.stack+="\nAsync stacktrace:\n".concat(e.stack),o(t)}}function a(e){var t,r;if(null!=(r=Error)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](e):e instanceof r)return e;if(null===e)return Error("'null' was thrown as an error");if((void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"){try{t="Object thrown as error: ".concat(JSON.stringify(e))}catch(r){t="Object thrown as error with the following properties: ".concat(Object.keys(e))}return Error(t)}if(void 0===e)return Error("'undefined' was thrown as an error");return Error(e.toString())}window.onerror=function(e){return console.error("Unexpected error: ",e),(0,n.Vt)({description:null!=e?e:"Oops! An unexpected error occurred.",kind:"error",title:"Error"}),!1},window.onunhandledrejection=function(e){var t;console.error("Unhandled rejection: ",e.reason),(0,n.Vt)({description:null!=(t=e.reason)?t:"Oops! An unhandled promise rejection occurred.",kind:"error",title:"Error"})}},6014(e,t,r){"use strict";r.d(t,{dX:()=>O,wE:()=>j,_3:()=>g,uN:()=>D,$F:()=>A,Gz:()=>S,eb:()=>E,Sj:()=>x,mv:()=>w,PQ:()=>n.A});var n=r(4356),o="ArrowFunctionExpression";function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var u=r(4693);function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function l(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function c(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){l(i,n,o,a,u,"next",e)}function u(e){l(i,n,o,a,u,"throw",e)}a(void 0)})}}function d(e,t,r){return(d=b()?Reflect.construct:function(e,t,r){var n=[null];n.push.apply(n,t);var o=new(Function.bind.apply(e,n));return r&&h(o,r.prototype),o}).apply(null,arguments)}function f(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}function p(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function h(e,t){return(h=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function m(e){return function(e){if(Array.isArray(e))return s(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e){if(e){if("string"==typeof e)return s(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return s(e,void 0)}}(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function y(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function b(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(b=function(){return!!e})()}function v(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}function g(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x(e,t,C)}function w(e){return c(function(e){var t=arguments;return v(this,function(r){return[2,D(e,t.length>1&&void 0!==t[1]?t[1]:{},C)]})}).apply(this,arguments)}function E(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x(e,t,P)}function S(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return D(e,t,P)}function O(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x(e,t,k)}function A(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return D(e,t,k)}function x(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0;if("string"!=typeof e&&((void 0===e?"undefined":y(e))!=="object"||!e||!("type"in e)))throw"Unknown expression type ".concat(e,". Expressions must either be a string or pre-compiled string.");if("string"==typeof e&&0===e.trim().length)throw{type:"Empty expression",message:"Expression cannot be an empty string"};null==t&&(t={});var o=R(t,u.z),i=I("string"==typeof e?(0,n.A)(e):e,o);if(r(i))return i;throw{type:"Invalid result",message:"string"==typeof e?"The expression ".concat(e," did not produce a valid result"):"The expression did not produce a valid result"}}function D(e,t){return c(function(e){var t,r,o,i=arguments;return v(this,function(a){if(t=i.length>1&&void 0!==i[1]?i[1]:{},r=i.length>2?i[2]:void 0,"string"!=typeof e&&((void 0===e?"undefined":y(e))!=="object"||!e||!("type"in e)))return[2,Promise.reject("Unknown expression type ".concat(e,". Expressions must either be a string or pre-compiled string."))];if("string"==typeof e&&0===e.trim().length)throw{type:"Empty expression",message:"Expression cannot be an empty string"};return null==t&&(t={}),o=R(t,u.f),[2,Promise.resolve(I("string"==typeof e?(0,n.A)(e):e,o)).then(function(t){if(r(t))return t;throw{type:"Invalid result",message:"string"==typeof e?"The expression ".concat(e," did not produce a valid result"):"The expression did not produce a valid result"}})]})}).apply(this,arguments)}function j(e){return(0,n.A)(e)}function C(e){return"string"==typeof e||"number"==typeof e||"boolean"==typeof e||null==e||f(e,Date)}function P(e){return"boolean"==typeof e}function k(e){return"number"==typeof e}function I(e,t){switch(e.type){case"UnaryExpression":var r,n,o,i,a,u,s,l,c,p,h=e,b=t,v=I(h.argument,b);switch(h.operator){case"+":return+v;case"-":return-v;case"~":return~v;case"!":return!v;default:throw"Expression evaluator does not support operator '".concat(h.operator,"''")}case"BinaryExpression":var g=e,w=t,E=I(g.left,w),S=I(g.right,w);switch(g.operator){case"+":return E+S;case"-":return E-S;case"*":return E*S;case"/":return E/S;case"%":return E%S;case"**":return Math.pow(E,S);case"==":return E==S;case"===":return E===S;case"!=":return E!=S;case"!==":return E!==S;case">":return E>S;case">=":return E>=S;case"<":return E<S;case"<=":return E<=S;case"in":return E in S;case"&&":return E&&S;case"||":return E||S;case"??":return null!=E?E:S;default:throw"Expression evaluator does not support operator '".concat(g.operator,"' operator")}case"ConditionalExpression":return O=e,A=t,I(O.test,A)?I(O.consequent,A):I(O.alternate,A);case"CallExpression":var O,A,x,D=e,j=t,C=null==(x=D.arguments)?void 0:x.map(F(j)),P=I(D.callee,j);if(P){if("function"!=typeof P)throw"".concat(M(D.callee)," is not a function")}else throw"No function named ".concat(M(D.callee)," is defined in this context");return P.apply(void 0,m(C));case"ArrowFunctionExpression":return B=e,L=t,W=null!=(V=null==($=B.params)?void 0:$.map(function(e){if("Identifier"===e.type)return e.name;throw"Cannot handle parameter of type ".concat(e.type)}))?V:[],(function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];if(t.length<W.length)throw"Required argument(s) ".concat(W.slice(t.length,-1).join(", ")," were not provided");var n=Object.fromEntries(W.reduce(function(e,r,n){var o=t[n];return function e(t){if("string"==typeof t||"number"==typeof t||"boolean"==typeof t||"function"==typeof t||null===t||f(t,RegExp))return!0;if((void 0===t?"undefined":y(t))==="object"){var r=!0,n=!1,o=void 0;try{for(var i,a=Object.keys(t)[Symbol.iterator]();!(r=(i=a.next()).done);r=!0){var u=i.value;if(!e(t[u]))return!1}}catch(e){n=!0,o=e}finally{try{r||null==a.return||a.return()}finally{if(n)throw o}}return!0}if(Array.isArray(t)){var s=!0,l=!1,c=void 0;try{for(var d,p=t[Symbol.iterator]();!(s=(d=p.next()).done);s=!0){var h=d.value;if(!e(h))return!1}}catch(e){l=!0,c=e}finally{try{s||null==p.return||p.return()}finally{if(l)throw c}}}return!1}(o)&&e.push([r,o]),e},[]));return I(B.body,L.addVariables(n))}).bind(null!=(U=L.thisObj)?U:null);case"MemberExpression":return function(e,t){var r,n=I(e.object,t);if(void 0===n)switch(e.object.type){case"Identifier":var o=T(e.object,t);throw ReferenceError("ReferenceError: ".concat(o," is not defined"));case"MemberExpression":var i=T(e.property,t);throw TypeError("TypeError: cannot read properties of undefined (reading '".concat(i,"')"));default:throw"VisitMemberExpression does not support operator '".concat(e.object.type,"' type")}var a=n;if("string"==typeof n)a=String.prototype;else if("number"==typeof n)a=Number.prototype;else if("function"==typeof n);else if((void 0===n?"undefined":y(n))!=="object")throw"VisitMemberExpression does not support member access on type ".concat(void 0===n?"undefined":y(n));switch(t.thisObj=a,e.property.type){case"Identifier":case"MemberExpression":r=I(e.property,t);break;default:var u=I(e.property,t);if(void 0===u)throw{type:"Illegal property access",message:"No property was supplied to the property access"};N(u),r=n[u]}return"function"==typeof r?r.bind(n):r}(e,t);case"ArrayExpression":return z=e,K=t,null==(H=z.elements)?void 0:H.map(F(K));case"SequenceExpression":return G=e,q=t,(Z=G.expressions.map(F(q)))[Z.length-1];case"NewExpression":var k=e,R=t;if(k.callee&&"Identifier"===k.callee.type){var B,L,V,U,$,W,z,K,H,G,q,Z,Y,J=null==(Y=k.arguments)?void 0:Y.map(F(R));switch(k.callee.name){case"Date":return d(Date,m(J));case"RegExp":return d(RegExp,m(J));default:throw"Cannot instantiate object of type ".concat(k.callee.name)}}if(k.callee)throw"new must be called with either Date or RegExp";throw'Could not handle "new" without a specified class';case"Literal":return N((r=e).value),r.value;case"Identifier":var X=e,Q=t;N(X.name);var ee=Q.thisObj;if(ee&&((void 0===ee?"undefined":y(ee))==="object"||"function"==typeof ee)&&X.name in ee){var et=ee[X.name];return N(et),et}if(Q.variables&&X.name in Q.variables){var er=Q.variables[X.name];return N(er),er}return X.name in Q.globals?Q.globals[X.name]:void 0;case"TemplateLiteral":return n=e,o=t,l=null!=(i=null==(u=n.expressions)?void 0:u.map(F(o)))?i:[],(c=null!=(a=null==(s=n.quasis)?void 0:s.map(F(o)))?a:[]).filter(function(e){return!e.tail}).map(function(e){return e.value}).join("")+l.join("")+c.filter(function(e){return e.tail}).map(function(e){return e.value}).join("");case"TemplateElement":return{value:(p=e).cooked,tail:p.tail};default:throw"Expression evaluator does not support expression of type '".concat(e.type,"'")}}function T(e,t){switch(e.type){case"Literal":return e.value;case"Identifier":return e.name;case"MemberExpression":return T(e.property,t);default:throw"VisitExpressionName does not support expression of type '".concat(e.type,"'")}}function R(e,t){var r={thisObj:void 0,variables:p({},e),globals:p({},t),addVariables:function(e){return this.variables=p({},this.variables,e),this}};return r.addVariables.bind(r),r}function F(e){return function(t){return null===t?null:I(t,e)}}function N(e){if("__proto__"===e||"prototype"===e||"constructor"===e)throw{type:"Illegal property access",message:"Cannot access the ".concat(e," property of objects")}}function M(e){if(!e)return null;if("MemberExpression"===e.type){var t;return null==(t=e.property)?void 0:t.name}return e.name}n.A.plugins.register({name:"arrow",init:function(e){e.addBinaryOp("=>",.1,!0),e.hooks.add("gobble-expression",function(t){if(this.gobbleSpaces(),this.code===e.OPAREN_CODE){var r=this.index;if(this.index++,this.gobbleSpaces(),this.code===e.CPAREN_CODE){this.index++;var n=this.gobbleBinaryOp();if("=>"===n){var i=this.gobbleBinaryExpression();i||this.throwError("Expected expression after "+n),t.node={type:o,params:null,body:i};return}}this.index=r}}),e.hooks.add("after-expression",function(t){!function t(r){r&&(Object.values(r).forEach(function(e){e&&(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"&&t(e)}),"=>"===r.operator&&(r.type=o,r.params=r.left?[r.left]:null,r.body=r.right,r.params&&r.params[0].type===e.SEQUENCE_EXP&&(r.params=r.params[0].expressions),delete r.left,delete r.right,delete r.operator))}(t.node)})}}),n.A.plugins.register({name:"new",init:function(e){e.addUnaryOp("new"),e.hooks.add("after-token",function(t){var r=t.node;if(r&&"new"===r.operator){r.argument&&[e.CALL_EXP,e.MEMBER_EXP].includes(r.argument.type)||this.throwError("Expected new function()"),t.node=r.argument;for(var n=t.node;n.type===e.MEMBER_EXP||n.type===e.CALL_EXP&&n.callee.type===e.MEMBER_EXP;)n=n.type===e.MEMBER_EXP?n.object:n.callee.object;n.type="NewExpression"}})}}),n.A.plugins.register({name:"numbers",init:function(e){function t(e){return"x"===e||"X"===e?(this.index+=2,[[48,57],[65,70],[97,102]]):"b"===e||"B"===e?(this.index+=2,[[48,49]]):"o"===e||"O"===e||e>="0"&&e<="7"?(this.index+=e<="7"?1:2,[[48,55]]):null}function r(t){var r=this,n=this.index,o="",i=function(){for(;e.isDecimalDigit(r.code)||95===r.code;)95===r.code?r.index++:o+=r.expr.charAt(r.index++)};i(),this.code===e.PERIOD_CODE&&(o+=this.expr.charAt(this.index++),i());var a=this.char;("e"===a||"E"===a)&&(o+=this.expr.charAt(this.index++),("+"===(a=this.char)||"-"===a)&&(o+=this.expr.charAt(this.index++)),i(),e.isDecimalDigit(this.expr.charCodeAt(this.index-1))||this.throwError("Expected exponent ("+o+this.char+")"));var u=this.code;if(e.isIdentifierStart(u))this.throwError("Variable names cannot start with a number ("+o+this.char+")");else if(u===e.PERIOD_CODE){o.length>1&&this.throwError("Unexpected period ".concat(JSON.stringify({chCode:u,number:o},null,2))),this.index=n;return}t.node={type:e.LITERAL,value:parseFloat(o),raw:this.expr.substring(n,this.index)}}e.hooks.add("gobble-token",function(n){if(48===this.code){var o=this.index,a=this.expr.charAt(this.index+1),u=t.call(this,a);if(u){for(var s,l,c,d="";s=this.code,l=u,95===s||l.some(function(e){var t=function(e){if(Array.isArray(e))return e}(e)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return i(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return i(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],n=t[1];return s>=r&&s<=n});)95===this.code?this.index++:d+=this.expr.charAt(this.index++);if(e.isIdentifierPart(this.code)){if(e.isDecimalDigit(this.code)&&e.isDecimalDigit(a.charCodeAt(0))){this.index=o+1,r.call(this,n);return}this.throwError("unexpected char within number")}n.node={type:e.LITERAL,value:parseInt(d,"x"===(c=a)||"X"===c?16:"b"===c||"B"===c?2:8),raw:this.expr.substring(o,this.index)}}}else(e.isDecimalDigit(this.code)||this.code===e.PERIOD_CODE)&&r.call(this,n)})}}),n.A.plugins.register({name:"regex",init:function(e){e.hooks.add("gobble-token",function(t){if(47===this.code){for(var r=++this.index,n=!1;this.index<this.expr.length;){if(47===this.code&&!n){for(var o=this.expr.slice(r,this.index),i="";++this.index<this.expr.length;){var a=this.code;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)i+=this.char;else break}var u=void 0;try{u=new RegExp(o,i)}catch(e){this.throwError(e.message)}return t.node={type:e.LITERAL,value:u,raw:this.expr.slice(r-1,this.index)},t.node=this.gobbleTokenProperty(t.node),t.node}this.code===e.OBRACK_CODE?n=!0:n&&this.code===e.CBRACK_CODE&&(n=!1),this.index+=92===this.code?2:1}this.throwError("Unclosed Regex")}})}}),n.A.plugins.register({name:"ternary",init:function(e){e.hooks.add("after-expression",function(t){if(t.node&&this.code===e.QUMARK_CODE){this.index++;var r=t.node,n=this.gobbleExpression();if(n||this.throwError("Expected expression"),this.gobbleSpaces(),this.code===e.COLON_CODE){this.index++;var o=this.gobbleExpression();if(o||this.throwError("Expected expression"),t.node={type:"ConditionalExpression",test:r,consequent:n,alternate:o},r.operator&&e.binary_ops[r.operator]<=.9){for(var i=r;i.right.operator&&e.binary_ops[i.right.operator]<=.9;)i=i.right;t.node.test=i.right,i.right=t.node,t.node=r}}else this.throwError("Expected :")}})}}),n.A.plugins.register({name:"jsepTemplateLiteral",init:function(e){function t(e){var t=!(arguments.length>1)||void 0===arguments[1]||arguments[1];if(96===this.code){for(var r={type:"TemplateLiteral",quasis:[],expressions:[]},n="",o="",i=!1,u=this.expr.length,s=function(){return r.quasis.push({type:"TemplateElement",value:{raw:o,cooked:n},tail:i})};this.index<u;){var l,c,d=this.expr.charAt(++this.index);if("`"===d)return this.index+=1,i=!0,s(),e.node=r,t&&(e.node=this.gobbleTokenProperty(e.node)),e.node;if("$"===d&&"{"===this.expr.charAt(this.index+1))this.index+=2,s(),o="",n="",(c=r.expressions).push.apply(c,function(e){if(Array.isArray(e))return a(e)}(l=this.gobbleExpressions(125))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(l)||function(e){if(e){if("string"==typeof e)return a(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return a(e,void 0)}}(l)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),125!==this.code&&this.throwError("unclosed ${");else if("\\"===d)switch(o+=d,d=this.expr.charAt(++this.index),o+=d,d){case"n":n+="\n";break;case"r":n+="\r";break;case"t":n+=" ";break;case"b":n+="\b";break;case"f":n+="\f";break;case"v":n+="\v";break;default:n+=d}else n+=d,o+=d}this.throwError("Unclosed `")}}e.hooks.add("gobble-token",t),e.hooks.add("after-token",function(r){if((r.node.type===e.IDENTIFIER||r.node.type===e.MEMBER_EXP)&&96===this.code)return r.node={type:"TaggedTemplateExpression",tag:r.node,quasi:t.bind(this)(r,!1)},r.node=this.gobbleTokenProperty(r.node),r.node})}}),n.A.addBinaryOp("in",7),n.A.addBinaryOp("??",1)},4693(e,t,r){"use strict";r.d(t,{f:()=>a,z:()=>i});var n,o,i={Array:Array,Boolean:Boolean,Symbol:Symbol,Infinity:1/0,NaN:NaN,Math:Math,Number:Number,BigInt:BigInt,String:String,RegExp:RegExp,JSON:JSON,isFinite:isFinite,isNaN:isNaN,parseFloat:parseFloat,parseInt:parseInt,decodeURI:decodeURI,encodeURI:encodeURI,encodeURIComponent:encodeURIComponent,Object:{__proto__:void 0,assign:Object.assign.bind(null),fromEntries:Object.fromEntries.bind(null),hasOwn:Object.hasOwn.bind(null),keys:Object.keys.bind(null),is:Object.is.bind(null),values:Object.values.bind(null)}},a=(n=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},i),o=o={Promise:Promise},Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(o)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(o)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(o,e))}),n)},7477(e,t,r){"use strict";r.d(t,{J_:()=>eh,zx:()=>W,ES:()=>R,FY:()=>z,zF:()=>b,Uh:()=>ew,io:()=>es,Ef:()=>f,wG:()=>ej,Qb:()=>eg,dO:()=>d,o1:()=>ey,rD:()=>ev,Vx:()=>q,sr:()=>Z,YX:()=>eb,Tj:()=>N,Gp:()=>G,K0:()=>B,Q_:()=>ed,a9:()=>m,xg:()=>F,DQ:()=>y,Ml:()=>em,Xb:()=>ec,Fg:()=>X,VK:()=>M,pm:()=>eu,Ju:()=>J,cL:()=>H,ap:()=>K,Yo:()=>L,No:()=>V});var n=r(3058),o=r(7994),i=r(6014),a=r(5794),u=r(9726),s=r(2316),l=r(4809),c=r(7403);function d(){var e=!(arguments.length>0)||void 0===arguments[0]||arguments[0],t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return f((0,s.s)(),e,t)}function f(e){var t=!(arguments.length>1)||void 0===arguments[1]||arguments[1],r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return!!(e?t:r)}var p=r(2883),h=(0,p.Zd)("extensionsInternal",{slots:{},extensions:{}}),m=function(){return(0,p.jf)("extensionsInternal",{slots:{},extensions:{}})};function y(e){var t=h.getState(),r=e(t);r!==t&&h.setState(r)}var b=function(){return(0,p.jf)("extensions",{slots:{}})};function v(e){var t=[],r=!0,n=!1,i=void 0;try{for(var a,u=Object.values(e.extensions)[Symbol.iterator]();!(r=(a=u.next()).done);r=!0){var s=a.value,c=!0,d=!1,f=void 0;try{for(var p,h=s.instances[Symbol.iterator]();!(c=(p=h.next()).done);c=!0){var m=p.value;t.push({slotModuleName:m.slotModuleName,extensionModuleName:s.moduleName,slotName:m.slotName,extensionId:m.id})}}catch(e){d=!0,f=e}finally{try{c||null==h.return||h.return()}finally{if(d)throw f}}}}catch(e){n=!0,i=e}finally{try{r||null==u.return||u.return()}finally{if(n)throw i}}(0,l.A)(o.hs.getState().mountedExtensions,t)||o.hs.setState({mountedExtensions:t})}function g(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function w(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function E(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){w(e,t,r[t])})}return e}function S(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function O(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],a=!0,u=!1;try{for(o=o.call(e);!(a=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){u=!0,n=e}finally{try{a||null==o.return||o.return()}finally{if(u)throw n}}return i}}(e,t)||x(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function A(e){return function(e){if(Array.isArray(e))return g(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||x(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function x(e,t){if(e){if("string"==typeof e)return g(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return g(e,t)}}v(h.getState()),h.subscribe(v);var D=m(),j=b(),C=(0,o.YP)(),P=(0,o.GI)();function k(e,t,r,n,i){var a={},u=(0,s.s)(),c=Object.entries(n.flags).filter(function(e){return O(e,2)[1].enabled}).map(function(e){return O(e,1)[0]}),d=!0,f=!1,p=void 0;try{for(var h,m=Object.entries(e.slots)[Symbol.iterator]();!(d=(h=m.next()).done);d=!0){var y=O(h.value,2),b=y[0],v=y[1],g=(0,o.vu)(t,v.name).config,w=$(b,e,g,r,c,u,i.session);a[b]={moduleName:v.moduleName,assignedExtensions:w}}}catch(e){f=!0,p=e}finally{try{d||null==m.return||m.return()}finally{if(f)throw p}}(0,l.A)(j.getState().slots,a)||j.setState({slots:a})}function I(){k(D.getState(),C.getState(),P.getState(),a.jX.getState(),n.eA.getState())}function T(e,t,r){return{moduleName:t,name:e,attachedIds:[],config:null,state:r}}function R(e){return O(e.split("#"),1)[0]}function F(e,t){var r=R(t);return e.extensions[r]}function N(e){return F(D.getState(),e)}D.subscribe(function(e){k(e,C.getState(),P.getState(),a.jX.getState(),n.eA.getState())}),C.subscribe(function(e){k(D.getState(),e,P.getState(),a.jX.getState(),n.eA.getState())}),P.subscribe(function(e){k(D.getState(),C.getState(),e,a.jX.getState(),n.eA.getState())}),a.jX.subscribe(function(e){k(D.getState(),C.getState(),P.getState(),e,n.eA.getState())}),n.eA.subscribe(function(e){k(D.getState(),C.getState(),P.getState(),a.jX.getState(),e)}),I(),(0,u.gj)(I);var M=function(e){return D.setState(function(t){return t.extensions[e.name]=S(E({},e),{instances:[]}),t})};function B(e,t){y(function(r){var n=r.slots[e];return n?S(E({},r),{slots:S(E({},r.slots),w({},e,S(E({},n),{attachedIds:A(n.attachedIds).concat([t])})))}):S(E({},r),{slots:S(E({},r.slots),w({},e,S(E({},T(e)),{attachedIds:[t]})))})})}function L(e,t){y(function(r){var n=r.slots[e];return n&&n.attachedIds.includes(t)?S(E({},r),{slots:S(E({},r.slots),w({},e,S(E({},n),{attachedIds:n.attachedIds.filter(function(e){return e!==t})})))}):r})}function V(e){y(function(t){var r=t.slots[e];return r?S(E({},t),{slots:S(E({},t.slots),w({},e,S(E({},r),{attachedIds:[]})))}):t})}function U(e,t,r,n){var o=t.indexOf(e);if(-1!==o)return o;if(void 0!==r)return 1e3+r;var i=n.indexOf(e);return -1!==i?2e3+i:-1}function $(e,t,r,a,u,s,l){var d=(g=r,w=t.slots[e].attachedIds,S=g.add||[],O=g.remove||[],x=g.order||[],j=D.getState().extensions,A(w).concat(A(S)).filter(function(e){return!O.includes(e)}).sort(function(e,t){var r,n,o=U(e,x,null==(r=j[R(e)])?void 0:r.order,w),i=U(t,x,null==(n=j[R(t)])?void 0:n.order,w);return -1===i?-1:-1===o?1:o-i})),p=[],h=null==(C=t.slots[e])?void 0:C.state,m=h&&(void 0===h?"undefined":h&&"u">typeof Symbol&&h.constructor===Symbol?"symbol":typeof h)=="object"?E({session:l},h):{session:l},y=!0,b=!1,v=void 0;try{for(var g,w,S,O,x,j,C,P,k=d[Symbol.iterator]();!(y=(P=k.next()).done);y=!0){var I=P.value,T=(0,o.P0)(a,e,I).config,F=(0,o.g$)(r,e,I),N=(0,c.A)(T,F),M=R(I),B=t.extensions[M];if(B){var L,V,$,W,z,K,H,G,q,Z,Y=null!=(L=null!=(V=null==N||null==(H=N["Display conditions"])?void 0:H.privileges)?V:B.privileges)?L:[];if(Y&&("string"==typeof Y||Array.isArray(Y)&&Y.length>0)&&(!(null==l?void 0:l.user)||!(0,n.st)(Y,l.user)))continue;var J=(null==N||null==(G=N["Display conditions"])?void 0:G.expression)||B.displayExpression;if(void 0!==J&&"string"==typeof J&&J.trim().length>0)try{if(!(0,i.eb)(J,m))continue}catch(t){console.error("Error while evaluating expression '".concat(J,"' for extension ").concat(M," in slot ").concat(e),t);continue}if(B.featureFlag&&!u.includes(B.featureFlag)||window.offlineEnabled&&!f(s,B.online,B.offline))continue;p.push({id:I,name:M,moduleName:B.moduleName,config:N,featureFlag:B.featureFlag,meta:B.meta,online:null==($=null!=(W=null==N||null==(q=N["Display conditions"])?void 0:q.online)?W:B.online)||$,offline:null!=(z=null!=(K=null==N||null==(Z=N["Display conditions"])?void 0:Z.offline)?K:B.offline)&&z})}}}catch(e){b=!0,v=e}finally{try{y||null==k.return||k.return()}finally{if(b)throw v}}return p}function W(e){var t=D.getState(),r=(0,o.G9)(e).config,i=P.getState(),u=a.jX.getState(),l=n.eA.getState(),c=(0,s.s)();return $(e,t,r,i,Object.entries(u.flags).filter(function(e){return O(e,2)[1].enabled}).map(function(e){return O(e,1)[0]}),c,l.session)}var z=function(e,t,r){return D.setState(function(n){var o,i=null==(o=n.slots[t])?void 0:o.moduleName;if(i&&i!=e)return console.warn("An extension slot with the name '".concat(t,'\' already exists. Refusing to register the same slot name twice (in "registerExtensionSlot"). The existing one is from module ').concat(i,".")),n;if(i&&i==e)return n;if(n.slots[t])return S(E({},n),{slots:S(E({},n.slots),w({},t,S(E({},n.slots[t]),{moduleName:e,state:r})))});var a=T(t,e,r);return S(E({},n),{slots:S(E({},n.slots),w({},t,E({},a)))})})};function K(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];D.setState(function(n){var o=r?(0,c.A)(n.slots[e].state,t):t;return S(E({},n),{slots:S(E({},n.slots),w({},e,S(E({},n.slots[e]),{state:o})))})})}var H=function(){return j.setState(function(){return{slots:{},extensions:{}}})},G=(0,p.Zd)("left-nav",{slotName:null,basePath:window.spaBase,mode:"normal"});function q(e){var t=e.name,r=e.basePath,n=e.mode,o=e.componentContext,i=e.state;G.setState({slotName:t,basePath:r,mode:null!=n?n:"normal",componentContext:o,state:i})}function Z(e){G.getState().slotName===e&&G.setState(G.getInitialState(),!0)}var Y=(0,p.Zd)("modalRegistry",{modals:{}});function J(e){Y.setState(function(t){return t.modals[e.name]=e,t})}function X(e){var t=Y.getState().modals[e];if(!t){var r=N(e);r&&(t={name:e,load:r.load,moduleName:r.moduleName},console.warn("Modal ".concat(e,' was registered as an extension. This is deprecated and will be removed in the future. Please register it in the "modals" section of routes.json instead of the "extensions" section.')),J(t))}return t}var Q=r(5565);function ee(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function et(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function er(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){et(e,t,r[t])})}return e}function en(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function eo(e){return function(e){if(Array.isArray(e))return ee(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e){if(e){if("string"==typeof e)return ee(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return ee(e,void 0)}}(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var ei=(0,p.Zd)("workspaceRegistrations",{workspaces:{}}),ea=(0,p.Zd)("workspaceGroups",{workspaceGroups:{}});function eu(e){ei.setState(function(t){var r,n,o,i,a,u;return{workspaces:en(er({},t.workspaces),et({},e.name,en(er({},e),{load:e.load,preferredWindowSize:null!=(r=e.preferredWindowSize)?r:"normal",type:null!=(n=e.type)?n:"form",canHide:null!=(o=e.canHide)&&o,canMaximize:null!=(i=e.canMaximize)&&i,width:null!=(a=e.width)?a:"narrow",groups:null!=(u=e.groups)?u:[]})))}})}function es(e){ea.setState(function(t){var r=t.workspaceGroups[e.name];return r?{workspaceGroups:en(er({},t.workspaceGroups),et({},e.name,en(er({},r),{members:Array.from(new Set(eo(r.members).concat(eo(e.members))))})))}:{workspaceGroups:en(er({},t.workspaceGroups),et({},e.name,{name:e.name,members:e.members}))}})}var el=new Set;function ec(e){var t=ei.getState().workspaces;if(t[e])return t[e];var r,n,o,i,a,u,s,l,c,d,f,p,h=N(e);if(h)return el.has(e)||(console.warn("The workspace '".concat(e,'\' is registered as an extension. This is deprecated. Please register it in the "workspaces" section of the routes.json file.')),el.add(e)),{name:h.name,title:function(e){var t,r=null==e||null==(t=e.meta)?void 0:t.title;return"string"==typeof r?r:r&&(void 0===r?"undefined":r&&"u">typeof Symbol&&r.constructor===Symbol?"symbol":typeof r)=="object"?(0,Q.t)(e.moduleName,r.key,r.default):e.name}(h),moduleName:h.moduleName,preferredWindowSize:null!=(r=null==(s=h.meta)?void 0:s.screenSize)?r:"normal",load:h.load,type:null!=(n=null==(l=h.meta)?void 0:l.type)?n:"form",canHide:null!=(o=null==(c=h.meta)?void 0:c.canHide)&&o,canMaximize:null!=(i=null==(d=h.meta)?void 0:d.canMaximize)&&i,width:null!=(a=null==(f=h.meta)?void 0:f.width)?a:"narrow",groups:null!=(u=null==(p=h.meta)?void 0:p.groups)?u:[]};throw Error("No workspace named '".concat(e,"' has been registered."))}function ed(e){var t=ea.getState().workspaceGroups;if(t[e])return t[e];throw Error("No workspace group named '".concat(e,"' has been registered."))}function ef(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function ep(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var eh=(0,p.Zd)("workspace2",{registeredGroupsByName:{},registeredWindowsByName:{},registeredWorkspacesByName:{},openedGroup:null,openedWindows:[],workspaceTitleByWorkspaceName:{},isMostRecentlyOpenedWindowHidden:!1});function em(e){var t=eh.getState(),r=t.registeredWorkspacesByName,n=t.registeredWindowsByName,o=r[e];if(o){var i=n[o.window];if(i)return i;throw Error("No workspace window found with name: ".concat(o.window," for workspace: ").concat(e))}throw Error("No workspace found with name: ".concat(e))}function ey(e){var t=eh.getState(),r=t.registeredGroupsByName,n=t.registeredWindowsByName[e];if(n){var o=r[n.group];if(o)return o;throw Error("No workspace group found with name: ".concat(n.group," for window: ").concat(e))}throw Error("No workspace window found with name: ".concat(e))}function eb(e){return eh.getState().openedWindows.findIndex(function(t){return t.openedWorkspaces.find(function(t){return t.workspaceName===e})})}function ev(e,t){if(0!=t.length){var r=ef({},eh.getState().registeredGroupsByName),n=!0,o=!1,i=void 0;try{for(var a,u=t[Symbol.iterator]();!(n=(a=u.next()).done);n=!0){var s=a.value;if(r[s.name])throw Error("Cannot register workspace group ".concat(s.name," more than once"));r[s.name]=ep(ef({},s),{moduleName:e})}}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}eh.setState({registeredGroupsByName:r})}}function eg(e,t){if(0!=t.length){var r=ef({},eh.getState().registeredWindowsByName),n=!0,o=!1,i=void 0;try{for(var a,u=t[Symbol.iterator]();!(n=(a=u.next()).done);n=!0){var s=a.value;if(r[s.name])throw Error("Cannot register workspace window ".concat(s.name," more than once"));var l=ep(ef({},s),{moduleName:e});r[s.name]=l}}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}eh.setState({registeredWindowsByName:r})}}function ew(e,t){if(0!=t.length){var r=ef({},eh.getState().registeredWorkspacesByName),n=!0,o=!1,i=void 0;try{for(var a,u=t[Symbol.iterator]();!(n=(a=u.next()).done);n=!0){var s=a.value;if(r[s.name])throw Error("Cannot register workspace ".concat(s.name," more than once"));var l=ep(ef({},s),{moduleName:e});r[s.name]=l}}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}eh.setState({registeredWorkspacesByName:r})}}var eE=r(480);function eS(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function eO(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function eA(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ex(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){eA(e,t,r[t])})}return e}function eD(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var e_=0;function ej(e,t,r,n){var o;return(o=function(e,t,r,n){var o,i,a,u,s,l,c,f,p,h,m,b,v=arguments;return function(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(g){switch(g.label){case 0:if(o=v.length>4&&void 0!==v[4]?v[4]:function(e){return e},i=v.length>5&&void 0!==v[5]?v[5]:{},a=R(n),u=N(n),s=null,!e)return[3,3];if(!u)throw Error("Couldn't find extension '".concat(a,"' to attach to '").concat(t,"'"));if(l=u.meta,c=u.moduleName,f=u.online,p=u.offline,h=u.load,!d(f,p))return[3,2];return y(function(o){var i;return eD(ex({},o),{extensions:eD(ex({},o.extensions),eA({},a,eD(ex({},o.extensions[a]),{instances:((function(e){if(Array.isArray(e))return eS(e)})(i=o.extensions[a].instances)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(i)||function(e){if(e){if("string"==typeof e)return eS(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return eS(e,void 0)}}(i)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([{domElement:e,id:n,slotName:t,slotModuleName:r}])})))})}),[4,h()];case 1:m=g.sent(),b=e_++,s=(0,eE.mountRootParcel)(o(eD(ex({},m),{name:"".concat(t,"/").concat(a,"-").concat(b)})),eD(ex({},i),{_meta:l,_extensionContext:{extensionId:n,extensionSlotName:t,extensionSlotModuleName:r,extensionModuleName:c},domElement:e})),g.label=2;case 2:return[3,4];case 3:console.warn("Tried to render ".concat(n," into ").concat(t," but no DOM element was available.")),g.label=4;case 4:return[2,s]}})},function(){var e=this,t=arguments;return new Promise(function(r,n){var i=o.apply(e,t);function a(e){eO(i,r,n,a,u,"next",e)}function u(e){eO(i,r,n,a,u,"throw",e)}a(void 0)})}).apply(this,arguments)}},4099(e,t,r){"use strict";let n,o,i,a,u,s;r.r(t),r.d(t,{GenderUnknownIcon:()=>tp,evaluateAsNumber:()=>D.dX,StockManagementPictogram:()=>f4,ChemistryIcon:()=>e6,BabyIcon:()=>eq,DashboardExtension:()=>rd,openmrsComponentDecorator:()=>L.F7,tryRegisterExtension:()=>q,pictogramIds:()=>fR,ActivityIcon:()=>e$,compile:()=>D.wE,checkStatus:()=>F.dO,TableBatchActions:()=>eA,getAsyncLifecycle:()=>L.ns,subscribeOpenmrsEvent:()=>A.$y,dispatchConnectivityChanged:()=>p.Yt,PasswordIcon:()=>tN,Assessment2Pictogram:()=>fB,CloseIcon:()=>te,getWorkspaceGroupRegistration:()=>F.Q_,registerWorkspace:()=>F.pm,useFeatureFlag:()=>L.u,reset:()=>F.cL,LabOrderIcon:()=>tO,VisitMode:()=>A.dx,offlineUuidPrefix:()=>B.jU,useLocations:()=>L.kH,getLifecycle:()=>L.JK,formatDatetime:()=>l3,getVisitsForPatient:()=>A.BR,subscribeConnectivity:()=>p.sT,formatPartialDate:()=>lQ,CustomOverflowMenu:()=>eT,LocationIcon:()=>tx,GroupIcon:()=>tm,canBeginEditSynchronizationItemsOfType:()=>B.xN,VisitStatus:()=>A.Cj,createUseStore:()=>L.rr,getCurrentImportMap:()=>S,getSessionLocation:()=>d.Kx,usePatient:()=>L.tQ,useRenderableExtensions:()=>L.oU,getOpenedWindowIndexByWorkspace:()=>F.YX,checkStatusFor:()=>F.Ef,clearHistory:()=>M.g4,clearConfigErrors:()=>f.Nh,formatTime:()=>l2,isDevEnabled:()=>d.L7,setLeftNav:()=>F.Vx,syncOfflinePatientData:()=>B.sK,closeWorkspaceGroup2:()=>h_,ConfigurableLink:()=>L.i_,sessionStore:()=>d.eA,subscribeSnackbarShown:()=>p.ls,getDynamicOfflineDataEntriesFor:()=>B.WA,getLoggedInUser:()=>d.xC,GenderMaleIcon:()=>td,getExtensionSlotConfigFromStore:()=>f.vu,evaluateAsNumberAsync:()=>D.$F,putDynamicOfflineDataFor:()=>B.ff,implementerToolsConfigStore:()=>f.tN,Type:()=>f.ZU,InPatientPictogram:()=>fG,cleanupObsoleteFeatureFlags:()=>N.D3,showSnackbar:()=>pp,PatientBannerActionsMenu:()=>fw,PatientSearchPictogram:()=>fJ,DocumentAttachmentIcon:()=>to,Snackbar:()=>pa,CardiologyPictogram:()=>fV,ImageMedicalIcon:()=>tv,ActionableNotificationComponent:()=>dA,DiagnosisTags:()=>c1,iconIds:()=>eU,PatientsPictogram:()=>fX,interpolateUrl:()=>M.JG,setupHistory:()=>M.Wh,subscribeToastShown:()=>p.dX,detachAll:()=>F.No,convertToLocaleCalendar:()=>l4,DocumentIcon:()=>tn,configInternalStore:()=>f.Rt,ActionMenuButton2:()=>hH,setupDynamicOfflineDataHandler:()=>B.iD,makeUrl:()=>d.Gm,oneOf:()=>f.yL,selectPreferredName:()=>fi,launchWorkspaceGroup:()=>function e(t,r){var n,o=(0,F.Q_)(t),i=r.state,a=r.onWorkspaceGroupLaunch,u=r.workspaceGroupCleanup,s=r.workspaceToLaunch,l=function(){return pB}();if(l.getState().openWorkspaces.length){var c=l.getState().workspaceGroup;c?pD(null==c?void 0:c.name,function(){e(t,r)}):p$(function(){e(t,r)})}else l.setState(function(e){return pA(pO({},e),{workspaceGroup:{name:t,members:o.members,cleanup:u}})}),pG(t,i),null==a||a(),s&&pj(s.name,null!=(n=s.additionalProps)?n:{})},syncDynamicOfflineData:()=>B.u1,createErrorHandler:()=>x.J,openmrsObservableFetch:()=>d.ut,parseDate:()=>lG,getAttachmentByUuid:()=>A.KU,LeftNavMenu:()=>c7,getExtensionRegistration:()=>F.Tj,ShoppingCartAddItemIcon:()=>rs,ReferralOrderIcon:()=>t$,ReportIcon:()=>tz,dispatchToastShown:()=>p.Vt,registerExtension:()=>F.VK,setupOfflineSync:()=>B.cy,useConnectivity:()=>L.Fx,DownloadIcon:()=>ti,provide:()=>f.Gt,getSynchronizationItemsFor:()=>B.Io,ShoppingCartArrowDownIcon:()=>tJ,featureFlagsStore:()=>N.jX,promptBeforeClosing:()=>pk,removeDynamicOfflineDataFor:()=>B.wn,jsep:()=>D.PQ,GeriatricsPictogram:()=>fK,SearchIcon:()=>tG,reportError:()=>x.N,slugify:()=>g,resetAllRoutesOverrides:()=>ei,isOmrsDateToday:()=>lz,getExtensionStore:()=>F.zF,BloodBankPictogram:()=>fL,TriagePictogram:()=>f5,Workspace2:()=>hB,refetchCurrentUser:()=>d.yH,CheckmarkOutlineIcon:()=>e4,registerExtensionSlot:()=>F.FY,AllergiesIcon:()=>ro,ArrowDownIcon:()=>ez,useOpenmrsInfinite:()=>L.iy,getExtensionConfigFromExtensionSlotStore:()=>f.g$,OpenmrsDatePicker:()=>cZ,getExtensionConfigFromStore:()=>f.P0,getDynamicOfflineDataEntries:()=>B.FE,messageOmrsServiceWorker:()=>B.ms,navigate:()=>M.oo,launchWorkspace2:()=>hj,getGroupByWindowName:()=>F.o1,CustomOverflowMenuItem:()=>eR,isUrl:()=>f.gU,CaretDownIcon:()=>eJ,ArrowLeftIcon:()=>eK,FacilityPictogram:()=>fz,ViewOffIcon:()=>rt,setCurrentOfflineMode:()=>B.Og,updateInternalExtensionStore:()=>F.DQ,dispatchActionableNotificationShown:()=>p.LQ,formatDurationBetween:()=>cn,defaultVisitCustomRepresentation:()=>A.Rb,getBreadcrumbsFor:()=>M.qh,useOpenmrsPagination:()=>L.Ed,Pagination:()=>fe,CheckmarkFilledIcon:()=>e3,clearCurrentUser:()=>d.g$,showModal:()=>db,ChevronUpIcon:()=>e9,saveVisit:()=>A.Ds,useAttachments:()=>L._9,Pictogram:()=>pt,useExtensionSlot:()=>L.br,ChevronDownIcon:()=>e5,OpenmrsDateRangePicker:()=>c0,deleteAttachmentPermanently:()=>A.SY,getVisitTypes:()=>A.Pu,OverflowMenuHorizontalIcon:()=>tR,EventScheduleIcon:()=>ts,getSessionStore:()=>d.EW,ActionMenu:()=>hp,ProcedureOrderIcon:()=>tV,preloadImport:()=>E,registerWorkspaceWindows2:()=>F.Qb,useOnVisible:()=>L.Jm,setSessionLocation:()=>d.Gp,userHasAccess:()=>d.st,ChartAverageIcon:()=>e1,getFeatureFlag:()=>N.jj,UserAvatarIcon:()=>t8,renderExtension:()=>F.wG,useFhirInfinite:()=>L.vL,toVisitTypeObject:()=>A.Qx,useSession:()=>L.wV,EmergencyDepartmentPictogram:()=>fW,Notification:()=>dg,dispatchSnackbarShown:()=>p.$3,getSynchronizationItem:()=>B.Gp,navigateAndLaunchWorkspace:()=>pC,omrsOfflineCachingStrategyHttpHeaderName:()=>B.JC,formatDate:()=>l0,workspace2StoreActions:()=>hk,SwitcherIcon:()=>tZ,esmStyleGuideSchema:()=>eE.u,useAssignedExtensionIds:()=>L.Tt,CaretRightIcon:()=>eQ,evaluateAsType:()=>D.Sj,PageHeader:()=>d8,TranslateIcon:()=>t4,setUserProperties:()=>d.Fi,MovementIcon:()=>tT,localStorageRoutesPrefix:()=>V,renderInlineNotifications:()=>dG,subscribePrecacheStaticDependencies:()=>p.ff,PaymentsDeskPictogram:()=>fQ,usePrimaryIdentifierCode:()=>L.wJ,dispatchPrecacheStaticDependencies:()=>p.pc,getCurrentUser:()=>d.HW,useLayoutType:()=>L.qv,XrayPictogram:()=>f8,CaretUpIcon:()=>e0,renderActionableNotifications:()=>dZ,OpenmrsAppContext:()=>L.p6,setupModals:()=>dy,omrsOfflineResponseBodyHttpHeaderName:()=>B.UH,getDefaultsFromConfigSchema:()=>function e(t){var r={},n=!0,o=!1,i=void 0;try{for(var a,u=Object.keys(t)[Symbol.iterator]();!(n=(a=u.next()).done);n=!0){var s=a.value;if(ml(t[s])&&t[s].hasOwnProperty("_default"))r[s]=t[s]._default;else{if(s.startsWith("_"))continue;ml(t[s])?r[s]=e(t[s]):r[s]=t[s]}}}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}return r},subscribeTo:()=>el.i7,useAbortController:()=>L.Ie,Extension:()=>L.YY,getFhirServerPaginationHandlers:()=>L.mw,useConnectedExtensions:()=>L.zD,registerApp:()=>J,queueSynchronizationItemFor:()=>B.Iq,HospitalBedIcon:()=>tb,useExtensionInternalStore:()=>L.$B,configExtensionStore:()=>f.hs,getSynchronizationItems:()=>B.pb,getExtensionSlotsConfigStore:()=>f.YP,RenderIfValueIsTruthy:()=>L.fS,registerFeatureFlag:()=>N.uA,useFhirFetchAll:()=>L.oq,restBaseUrl:()=>d.Jj,CalendarHeatMapIcon:()=>eZ,getWorkspaceRegistration:()=>F.Xb,resetConfigSystem:()=>f.Nz,getFullSynchronizationItems:()=>B.C$,getExtensionInternalStore:()=>F.a9,registerGlobalStore:()=>el.CE,runSynchronization:()=>B.AO,evaluateAsBoolean:()=>D.eb,PatientBannerPatientInfo:()=>fy,getDefaultCalendar:()=>lJ,SettingsIcon:()=>tq,DrugOrderIcon:()=>ta,isOnline:()=>ms.s,ProgramsIcon:()=>tU,useAssignedExtensions:()=>L.CX,CloseFilledIcon:()=>tt,canAccessStorage:()=>Q,registerDefaultCalendar:()=>lY,TreeViewAltIcon:()=>t5,OverflowMenuVerticalIcon:()=>tF,getConfigStore:()=>f.IS,registerWorkspaceGroup:()=>F.io,InformationSquareIcon:()=>tE,EmptyCard:()=>c4,ChevronLeftIcon:()=>e8,RadiologyIcon:()=>ru,renderToasts:()=>pw,isDesktop:()=>L.xl,integrateBreakpoints:()=>ep,RegistrationPictogram:()=>f2,CardHeader:()=>ew,getExtensionRegistrationFrom:()=>F.xg,InformationIcon:()=>tg,TrashCanIcon:()=>t6,useOpenmrsSWR:()=>L.M3,Assessment1Pictogram:()=>fM,finishRegisteringAllApps:()=>X,importDynamic:()=>w,useFhirPagination:()=>L.to,useVisitContextStore:()=>L.xH,ArrowUpIcon:()=>eG,showActionableNotification:()=>dY,getDynamicOfflineDataHandlers:()=>B.qb,useForceUpdate:()=>L.CH,updateWorkspaceWindowState:()=>pV,useVisit:()=>L.fq,PatientBannerPatientIdentifiers:()=>fd,WorkspaceNotification:()=>p5,TransferPictogram:()=>f6,usePagination:()=>L.WQ,Breakpoint:()=>ec,PatientBannerToggleContactDetailsButton:()=>hG,CloseOutlineIcon:()=>tr,addRoutesOverride:()=>en,ObstetricsPictogram:()=>fY,parseDateInput:()=>l5,getConfig:()=>f.zj,attach:()=>F.K0,getLocale:()=>li,ActionMenuButton:()=>pQ,isUrlWithTemplateParameters:()=>f.qG,useEmrConfiguration:()=>L.E4,useLeftNav:()=>L.if,ToolsIcon:()=>t3,ErrorState:()=>c6,detach:()=>F.Yo,setCurrentVisit:()=>A.NH,registerOmrsServiceWorker:()=>B.sZ,ConditionsIcon:()=>ra,SaveIcon:()=>tH,activateOfflineCapability:()=>B.nr,useWorkspaces:()=>pW,resetWorkspaceStore:()=>pH,useConfig:()=>L.UK,validator:()=>f.Nc,CalendarIcon:()=>eY,getHistory:()=>M.JK,StickyNoteAddIcon:()=>tX,useWorkspace2Store:()=>hI,getPatientName:()=>ft,getVisitStore:()=>A.BX,getCoreTranslation:()=>h.V,registerModuleWithConfigSystem:()=>f.FL,isOfflineUuid:()=>B.bO,registerModuleLoad:()=>f.kl,getBreadcrumbs:()=>M.lz,extractVariableNames:()=>I,getOfflineSynchronizationStore:()=>B.LM,translateFrom:()=>h.t,EditIcon:()=>tu,useStoreWithActions:()=>L.mQ,putDynamicOfflineData:()=>B.yD,shallowEqual:()=>hv.b,subscribeNotificationShown:()=>p.bJ,MaximizeIcon:()=>t_,promptForClosingWorkspaces:()=>hP,WarningIcon:()=>rn,closeAllWorkspaces:()=>p$,fhirBaseUrl:()=>d.IU,usePatientPhoto:()=>fA,registerBreadcrumb:()=>M.vf,EventsIcon:()=>tl,createGlobalStore:()=>el.Zd,workspaceStore:()=>pB,getCurrentOfflineMode:()=>B.wJ,subscribeToFeatureFlag:()=>N.sM,useExtensionStore:()=>L.Gz,closeWorkspace:()=>pF,createAttachment:()=>A.cD,useLeftNavStore:()=>L.TA,TableIcon:()=>t1,Icon:()=>rc,InformationFilledIcon:()=>tw,LaboratoryPictogram:()=>fq,temporaryConfigStore:()=>f.H,getPromptBeforeClosingFcn:()=>pI,toDateObjectStrict:()=>lK,defineConfigSchema:()=>f.T0,filterBreadcrumbs:()=>M.D_,PatientBannerContactDetails:()=>h4,getAssignedExtensions:()=>F.zx,PatientPhoto:()=>fC,MaterialOrderIcon:()=>tD,MicroscopeIcon:()=>tP,PharmacyPictogram:()=>f0,AttachmentIcon:()=>ri,MoneyIcon:()=>tk,getAttachments:()=>A.Bv,getFullSynchronizationItemsFor:()=>B.xc,PageHeaderContent:()=>d7,MedicationIcon:()=>tj,PrinterIcon:()=>tL,getWorkspaceGroupStore:()=>pG,PatientListsPictogram:()=>f9,useAppContext:()=>L.Us,isOpenmrsRoutes:()=>es,AppointmentsAltPictogram:()=>fN,GenericOrderTypeIcon:()=>th,useExtensionSlotStore:()=>L.uL,ViewIcon:()=>rr,formattedName:()=>fo,sessionEndpoint:()=>d.Ct,duration:()=>ct,TableOfContentsIcon:()=>t0,CaretLeftIcon:()=>eX,getTranslationOverrides:()=>f.td,isVersionSatisfied:()=>mp,EmptyCardIllustration:()=>c3,PenIcon:()=>tB,getWorkspaceStore:()=>pL,registerOfflinePatientHandler:()=>B.KG,useDefineAppContext:()=>L.jn,showToast:()=>pE,validators:()=>f.y$,getGlobalStore:()=>el.jf,useOnClickOutside:()=>L.Wr,getWindowByWorkspaceName:()=>F.Ml,ArrowRightIcon:()=>eH,loadLifeCycles:()=>H,registerBreadcrumbs:()=>M.MY,MotherIcon:()=>tI,fetchCurrentPatient:()=>A.hG,Toast:()=>ph,MessageQueueIcon:()=>tC,goBackInHistory:()=>M.tA,Pharmacy2Pictogram:()=>f1,GroupAccessIcon:()=>ty,setupApiModule:()=>d.Y0,getAsyncExtensionLifecycle:()=>L.sc,showNotification:()=>dq,renderLoadingSpinner:()=>h6,WorkspaceContainer:()=>hm,queueSynchronizationItem:()=>B.Zr,getModalRegistration:()=>F.Fg,ListCheckedIcon:()=>tA,ResponsiveWrapper:()=>pr,GynaecologyPictogram:()=>fH,ShoppingCartIcon:()=>tY,removeRoutesOverride:()=>eo,updateVisit:()=>A.xL,backendDependencies:()=>d.QE,MaybePictogram:()=>pe,beginEditSynchronizationItem:()=>B.FO,omrsOfflineResponseStatusHttpHeaderName:()=>B.Gj,getStartedVisit:()=>A.DK,openmrsFetch:()=>d.lo,isOpenmrsAppRoutes:()=>eu,useStore:()=>L.Pj,HomePictogram:()=>f7,DentistryPictogram:()=>f$,ServiceQueuesPictogram:()=>f3,launchWorkspace:()=>pj,setFeatureFlag:()=>N.B4,NumericObservation:()=>d1,attachmentUrl:()=>A.Zu,interpolateString:()=>M.zl,inRange:()=>f.r4,useExtensionSlotMeta:()=>L.Wq,AppointmentsPictogram:()=>fF,renderSnackbars:()=>pf,getRegisteredWorkspace2Names:()=>hR,toLocationObject:()=>A.E$,ChartLineIcon:()=>e2,UserHasAccess:()=>L.qw,evaluateAsBooleanAsync:()=>D.Gz,changeWorkspaceContext:()=>pN,createDashboard:()=>rf,getLocations:()=>A.Vs,updateExtensionSlotState:()=>F.ap,getOfflineDb:()=>B.e,canCloseWorkspaceWithoutPrompting:()=>px,getExtensionsConfigStore:()=>f.GI,age:()=>fu,syncAllDynamicOfflineData:()=>B.Td,isOmrsDateStrict:()=>lW,registerWorkspaceGroups2:()=>F.rD,usePaginationInfo:()=>L.WK,evaluateAsync:()=>D.mv,useOpenmrsFetchAll:()=>L.Bf,showWorkspacePrompts:()=>pz,useVisitTypes:()=>L.wr,ageAsDuration:()=>fa,removeDynamicOfflineData:()=>B.NU,getExtensionNameFromId:()=>F.ES,deleteSynchronizationItem:()=>B.lY,useWorkspace2Context:()=>hT,ResetIcon:()=>tK,RenewIcon:()=>tW,subscribeActionableNotificationShown:()=>p.bK,ErrorCard:()=>c5,GenderFemaleIcon:()=>tc,getOfflinePatientDataStore:()=>B.WK,retry:()=>mb,ComponentContext:()=>L.zq,ExtensionSlot:()=>L.W3,getOmrsServiceWorker:()=>B.Rs,subscribeConnectivityChanged:()=>p.gj,unsetLeftNav:()=>F.sr,MaybeIcon:()=>rl,useCustomOverflowMenu:()=>eI,PedestrianFamilyIcon:()=>tM,generateOfflineUuid:()=>B.sA,cancelPrompt:()=>pT,CtScanPictogram:()=>fU,dispatchNotificationShown:()=>p.FI,leftNavStore:()=>F.Gp,OpenmrsFetchError:()=>d.$f,UserFollowIcon:()=>t7,launchWorkspaceGroup2:()=>hD,ChevronRightIcon:()=>e7,UserXrayIcon:()=>t9,GenderOtherIcon:()=>tf,formatDuration:()=>l6,toOmrsIsoString:()=>lH,Labs2Pictogram:()=>fZ,workspace2Store:()=>F.J_,setUserLanguage:()=>d.E4,useBodyScrollLock:()=>L.yJ,getExtensionConfig:()=>f.UY,SyringeIcon:()=>tQ,LocationPicker:()=>dn,useDebounce:()=>L.d7,TimeIcon:()=>t2,getExtensionSlotConfig:()=>f.G9,AddIcon:()=>eW,processConfig:()=>f.mq,InventoryManagementIcon:()=>tS,registerWorkspaces2:()=>F.Uh,UserIcon:()=>re,formatPatientName:()=>fn,fireOpenmrsEvent:()=>A.X1,registerModal:()=>F.Ju,registerTranslationNamespace:()=>f.GV,displayName:()=>fr,evaluate:()=>D._3,defineExtensionConfigSchema:()=>f.ks,renderWorkspaceWindowsAndMenu:()=>ma,getSyncLifecycle:()=>L.g9,evaluateAsTypeAsync:()=>D.uN});var l,c,d=r(3058),f=r(7994),p=r(9726),h=r(5565);function m(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function y(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){m(i,n,o,a,u,"next",e)}function u(e){m(i,n,o,a,u,"throw",e)}a(void 0)})}}function b(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function v(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}function g(e){return e.replace(/[\/\-@]/g,"_")}function w(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"./start",n=arguments.length>2?arguments[2]:void 0;return y(function(){var o,i,a,u,s,l,c;return v(this,function(d){switch(d.label){case 0:return o=(null==n?void 0:n.maxLoadingTime)&&!(n.maxLoadingTime<=0)?n.maxLoadingTime:6e5,i=void 0,[4,Promise.race([E(e,null==n?void 0:n.importMap),new Promise(function(t,r){i=setTimeout(function(){var t;r(Error("Could not resolve requested script, ".concat(e,", within ").concat((t=o)<1e3?"".concat(t," milliseconds"):t<6e4?"".concat(Math.floor(t/1e3)," seconds"):t<36e5?"".concat(Math.floor(t/6e4)," minutes"):t<864e5?"".concat(Math.floor(t/36e5)," hours"):"".concat(Math.floor(t/864e5)," days"),".")))},o)})])];case 1:var f;if(d.sent(),i&&clearTimeout(i),a=g(e),!((void 0===(f=u=window[a])?"undefined":b(f))==="object"&&null!==f&&"init"in f&&"function"==typeof f.init&&"get"in f&&"function"==typeof f.get))throw console.error(s="The global variable ".concat(a," does not refer to a federated module")),Error(s);return u.init(r.S.default),[4,u.get(t)];case 2:if((void 0===(l=d.sent()())?"undefined":b(l))!=="object"||null===l)throw console.error(c="Container for ".concat(e," did not return an ESM module as expected")),Error(c);return[2,l]}})})()}function E(e,t){return y(function(){var r,n,o,i,a,u,s;return v(this,function(l){switch(l.label){case 0:if("string"!=typeof e||0===e.trim().length)throw console.error("Attempted to call importDynamic() without supplying a package to load"),Error("Attempted to call importDynamic() without supplying a package to load");if(r=g(e),window[r])return[3,7];if(null==t)return[3,1];return o=t,[3,3];case 1:return[4,S()];case 2:o=l.sent(),l.label=3;case 3:if(!(n=o).imports.hasOwnProperty(e))throw console.error(i="Could not find the package ".concat(e," defined in the current importmap")),Error(i);(a=n.imports[e]).startsWith("./")&&(a=window.spaBase+a.substring(1)),u=!!window.localStorage.getItem("import-map-override:".concat(e)),l.label=4;case 4:return l.trys.push([4,6,,7]),[4,new Promise(function(e,t){!function(e,t,r){var n,o,i,a=document.head.querySelector('script[src="'.concat(e,'"]')),u=window[O];if(u||(u=window[O]=new Set([])),a)u.has(e)?(i=function(){n&&a.removeEventListener("load",n),o&&a.removeEventListener("error",o)},n=function(){i(),t(null)},o=function(e){i(),r(e.message)},a.addEventListener("load",n),a.addEventListener("error",o)):(console.warn("Script at ".concat(e," already loaded. Not loading it again.")),t(null));else{u.add(e);var s,l,c,d=document.createElement("script");d.src=e,d.type="text/javascript",d.async=!0;var f=setTimeout(function(){console.error("The script at ".concat(e," did not load within 5 seconds. This may indicate an issue with the imports in the script's entry-point file or with the script's bundler configuration."))},5e3);c=function(){clearTimeout(f),u.delete(e),s&&d.removeEventListener("load",s),l&&d.removeEventListener("error",l)},s=function(){c(),t(null)},l=function(t){c();var n,o="Failed to load script from ".concat(e);console.error(o,t),r(null!=(n=t.message)?n:o)},d.addEventListener("load",s),d.addEventListener("error",l),document.head.appendChild(d)}}(a,e,t)})];case 5:return[2,l.sent()];case 6:return s=l.sent(),u&&(0,p.Vt)({kind:"error",title:(0,h.V)("scriptLoadingFailed","Error: Script failed to load"),description:(0,h.V)("scriptLoadingError","Failed to load overridden script from {{- url}}. Please check that the bundled script is available at the expected URL. Click the button below to reset all import map overrides.",{url:a}),actionButtonLabel:(0,h.V)("resetOverrides","Reset overrides"),onActionButtonClick:function(){window.importMapOverrides.resetOverrides(),window.location.reload()}}),[2,Promise.reject(s)];case 7:return[2,Promise.resolve()]}})})()}function S(){return y(function(){return v(this,function(e){return[2,window.importMapOverrides.getCurrentPageMap()]})})()}var O=Symbol("__openmrs_script_loading"),A=r(1265),x=r(8507),D=r(6014),j=r(4356),C=r(4693);function P(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function k(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function I(e){if("string"!=typeof e&&((void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)!="object"||!e||!("type"in e)))throw"Unknown expression type ".concat(e,". Expressions must either be a string or pre-compiled string.");var t,r={globals:k({},C.f),isLocalExpression:!1,variables:new Set};return T("string"==typeof e?(0,j.A)(e):e,r),function(e){if(Array.isArray(e))return P(e)}(t=r.variables)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||function(e){if(e){if("string"==typeof e)return P(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return P(e,void 0)}}(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function T(e,t){switch(e.type){case"UnaryExpression":return r=e,n=t,T(r.argument,n);case"BinaryExpression":return o=e,i=t,[T(o.left,i),T(o.right,i)].filter(Boolean);case"ConditionalExpression":return a=e,u=t,[T(a.consequent,u),T(a.test,u),T(a.alternate,u)].filter(Boolean);case"CallExpression":return s=e,l=t,d=T(s.callee,l),null==(c=s.arguments)||c.map(R(l)),d;case"ArrowFunctionExpression":return function(e,t){var r=k({},t);r.isLocalExpression=!0;var n=null!=(s=null==(c=e.params)?void 0:c.map(R(r)))?s:[],o=null!=(l=T(e.body,r))?l:[];if(o&&Array.isArray(o)){var i=!0,a=!1,u=void 0;try{for(var s,l,c,d,f=o[Symbol.iterator]();!(i=(d=f.next()).done);i=!0){var p=d.value;n.includes(p)||t.variables.add(p)}}catch(e){a=!0,u=e}finally{try{i||null==f.return||f.return()}finally{if(a)throw u}}}}(e,t);case"MemberExpression":return f=e,p=t,T(f.object,p),void((h=k({},p)).isLocalExpression=!0,T(f.property,h));case"ArrayExpression":return m=e,y=t,void(null==(b=m.elements)||b.map(R(y)));case"SequenceExpression":return v=e,g=t,void(null==(w=v.expressions)||w.map(R(g)));case"NewExpression":return E=e,S=t,void(null==(O=E.arguments)||O.map(R(S)));case"Literal":case"TemplateElement":return;case"Identifier":var r,n,o,i,a,u,s,l,c,d,f,p,h,m,y,b,v,g,w,E,S,O,A,x,D,j,C=e,P=t;if(!(C.name in P.globals))if(P.isLocalExpression)return C.name;else P.variables.add(C.name);return;case"TemplateLiteral":return A=e,x=t,void(null==(D=A.expressions)||D.map(R(x)),null==(j=A.quasis)||j.map(R(x)));default:throw"Expression evaluator does not support expression of type '".concat(e.type,"'")}}function R(e){return function(t){return null===t?null:T(t,e)}}var F=r(7477),N=r(5794),M=r(7774),B=r(7426),L=r(6258),V="openmrs-routes:",U=r(480);function $(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function W(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){$(i,n,o,a,u,"next",e)}function u(e){$(i,n,o,a,u,"throw",e)}a(void 0)})}}function z(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}var K=new Map;function H(e,t){return W(function(){var r,n,o,i,a;return z(this,function(u){switch(u.label){case 0:return o=(n=(r=t.indexOf("#"))>=0)?t.substring(0,r):e,i=n?t.substring(r+1):t,[4,w(o)];case 1:if((a=u.sent())&&Object.hasOwn(a,i)&&"function"==typeof a[i]){var s,l;return[2,(s=o,l=a,W(function(){var e,t;return z(this,function(r){switch(r.label){case 0:if(s in K)return[3,5];if(null==l)return[3,1];return t=l,[3,3];case 1:return[4,w(s)];case 2:t=r.sent(),r.label=3;case 3:return e=t,[4,K[s]=new Promise(function(t,r){if(Object.hasOwn(e,"startupApp")){var n=e.startupApp;if("function"==typeof n)return Promise.resolve(n()).then(function(){(0,f.kl)(s),t(null)}).catch(r)}(0,f.kl)(s),t(null)})];case 4:return r.sent(),[3,7];case 5:return[4,K[s]];case 6:r.sent(),r.label=7;case 7:return[2]}})})()).then(function(){return a[i]()})]}return a?a&&Object.hasOwn(a,i)?console.warn("The export ".concat(t,", defined in ").concat(e,"'s routes.json, is not a function")):console.warn("".concat(o,' does not define a component called "').concat(i,'", referenced in ').concat(e,"'s routes.json. This cannot be loaded.")):console.warn("Unknown app ".concat(o," for ").concat(t," defined in ").concat(e,"'s routes.json")),[2,G]}})})()}var G={bootstrap:function(){return Promise.resolve()},mount:function(){return Promise.resolve()},unmount:function(){return Promise.resolve()}};function q(e,t){var r=t.name;if(!r)return void console.error("An extension definition in ".concat(e,' is missing an name and thus cannot be\nregistered. To fix this, ensure that you define the "name" field inside the\nextension definition.'),t);t.slots&&t.slot&&console.warn("The extension ".concat(r," from ").concat(e," declares both a 'slots' property and\na 'slot' property. Only the 'slots' property will be honored."));var n=t.slots?t.slots:t.slot?[t.slot]:[];if(!t.component)return void console.error("The extension ".concat(r," from ").concat(e," is missing a 'component' entry and thus cannot be registered.\nTo fix this, ensure that you define a 'component' field inside the extension definition."),t);(0,F.VK)({name:r,load:function(){return H(e,t.component)},meta:t.meta||{},order:t.order,moduleName:e,privileges:t.privileges,online:null==(u=t.online)||u,offline:null!=(s=t.offline)&&s,featureFlag:t.featureFlag,displayExpression:t.displayExpression});var o=!0,i=!1,a=void 0;try{for(var u,s,l,c=n[Symbol.iterator]();!(o=(l=c.next()).done);o=!0){var d=l.value;(0,F.K0)(d,r)}}catch(e){i=!0,a=e}finally{try{o||null==c.return||c.return()}finally{if(i)throw a}}}function Z(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}var Y=[];function J(e,t){if(e&&t&&(void 0===t?"undefined":Z(t))==="object"){(0,f.FL)(e);var r,n,o,i,a,u,s,l,c,d=null!=(r=t.extensions)?r:[],p=null!=(n=t.modals)?n:[],h=null!=(o=t.workspaces)?o:[],m=null!=(i=t.workspaceGroups)?i:[],y=null!=(a=t.featureFlags)?a:[],b=null!=(u=t.workspaceGroups2)?u:[],v=null!=(s=t.workspaceWindows2)?s:[],g=null!=(l=t.workspaces2)?l:[];null==(c=t.pages)||c.forEach(function(t){if(t&&(void 0===t?"undefined":Z(t))==="object"&&Object.hasOwn(t,"component")&&(Object.hasOwn(t,"route")||Object.hasOwn(t,"routeRegex")||Object.hasOwn(t,"routes"))){var r,n;Y.push((r=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},t),n=n={appName:e},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))}else console.warn("A page for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),d.forEach(function(t){t&&(void 0===t?"undefined":Z(t))==="object"&&Object.hasOwn(t,"name")&&Object.hasOwn(t,"component")?q(e,t):console.warn("An extension for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),p.forEach(function(t){if(t&&(void 0===t?"undefined":Z(t))==="object"&&Object.hasOwn(t,"name")&&Object.hasOwn(t,"component")){var r;(r=t.name)?t.component?(0,F.Ju)({name:r,moduleName:e,load:function(){return H(e,t.component)}}):console.error("The modal ".concat(r," from ").concat(e," is missing a 'component' entry and thus cannot be registered.\nTo fix this, ensure that you define a 'component' field inside the modal definition."),t):console.error("A modal definition in ".concat(e,' is missing an name and thus cannot be\nregistered. To fix this, ensure that you define the "name" field inside the\nmodal definition.'),t)}else console.warn("A modal for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),h.forEach(function(t){t&&(void 0===t?"undefined":Z(t))==="object"&&Object.hasOwn(t,"name")&&Object.hasOwn(t,"component")?function(e,t){var r=t.name;if(!r)return console.error("A workspace definition in ".concat(e,' is missing a name and thus cannot be registered.\nTo fix this, ensure that you define the "name" field inside the workspace definition.'),t);var n=t.title;if(!n)return console.error("A workspace definition in ".concat(e,' is missing a title and thus cannot be registered.\nTo fix this, ensure that you define the "title" field inside the workspace definition.'),t);if(!t.component)return console.error("The workspace ".concat(r," from ").concat(e," is missing a 'component' entry and thus cannot be registered.\nTo fix this, ensure that you define a 'component' field inside the workspace definition."),t);(0,F.pm)({name:r,title:n,component:t.component,moduleName:e,type:t.type,canHide:t.canHide,canMaximize:t.canMaximize,width:t.width,preferredWindowSize:t.preferredWindowSize,groups:t.groups,load:function(){return H(e,t.component)}});var o=!0,i=!1,a=void 0;try{for(var u,s=(t.groups||[])[Symbol.iterator]();!(o=(u=s.next()).done);o=!0){var l=u.value;(0,F.io)({name:l,members:[r]})}}catch(e){i=!0,a=e}finally{try{o||null==s.return||s.return()}finally{if(i)throw a}}}(e,t):console.warn("A workspace for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),m.forEach(function(t){if(t&&(void 0===t?"undefined":Z(t))==="object"&&Object.hasOwn(t,"name")){var r,n;(n=t.name)?(0,F.io)({name:n,members:null!=(r=t.members)?r:[]}):console.error("A workspace group definition in ".concat(e,' is missing a name and thus cannot be registered.\nTo fix this, ensure that you define the "name" field inside the workspace definition.'),t)}else console.warn("A workspace group for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),(0,F.rD)(e,b),function(e,t){(0,F.Qb)(e,t);var r=!0,n=!1,o=void 0;try{for(var i,a=t[Symbol.iterator]();!(r=(i=a.next()).done);r=!0){var u=i.value;if(u.icon){var s={name:u.name,component:u.icon,slot:u.group,order:u.order};q(e,s)}}}catch(e){n=!0,o=e}finally{try{r||null==a.return||a.return()}finally{if(n)throw o}}}(e,v),(0,F.Uh)(e,g),y.forEach(function(t){if(t&&(void 0===t?"undefined":Z(t))==="object"&&Object.hasOwn(t,"flagName"))t.flagName?t.label?t.description?(0,N.uA)(t.flagName,t.label,t.description):console.error("A feature flag definition in ".concat(e,' is missing a description and thus cannot be registered.\nTo fix this, ensure that you define the "description" field inside the feature flag definition.'),t):console.error("A feature flag definition in ".concat(e,' is missing a description and thus cannot be registered.\nTo fix this, ensure that you define the "label" field inside the feature flag definition.'),t):console.error("A feature flag definition in ".concat(e,' is missing a name and thus cannot be registered.\nTo fix this, ensure that you define the "name" field inside the feature flag definition.'),t);else console.warn("A feature flag for ".concat(e," could not be registered as it does not appear to have the required properties"),t)})}}function X(){Y.sort(function(e,t){return e.appName.localeCompare(t.appName,"en")});var e=new Map,t=!0,r=!1,n=void 0;try{for(var o,i=Y[Symbol.iterator]();!(t=(o=i.next()).done);t=!0){var a,u=o.value;e.has(u.appName)?e.set(u.appName,e.get(u.appName)+1):e.set(u.appName,0);var s=e.get(u.appName),l="".concat(u.appName,"-page-").concat(s),c=null!=(a=u.containerDomId)?a:"omrs-apps-container",d=document.getElementById(c),f="single-spa-application:".concat(l);if(d){var p=document.createElement("div");p.id=f,null==d||d.appendChild(p)}else throw Error("".concat(u.appName," ").concat(u.component,' cannot be mounted to "').concat(c,'"; DOM element does not exist.'));!function(e,t){var r,n,o,i,a=void 0!==t.route?t.route:void 0!==t.routeRegex&&new RegExp(t.routeRegex);if(!1===a)return console.warn('A registered page definition is missing a route and thus cannot be registered.\nTo fix this, ensure that you define the "route" (or alternatively the "routeRegex") field inside the extension definition.',e);if(!t.component)return console.warn('A registered page definition is missing a component and thus cannot be registered.\nTo fix this, ensure that you define the "component" field inside the page definition.',e);var u=(r=function e(t){if(Array.isArray(t)){var r,n=t.map(e);return function(e){return n.some(function(t){return t(e)})}}return"string"==typeof t?(0,U.pathToActiveWhen)(window.getOpenmrsSpaBase()+t):(null!=(r=RegExp)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](t):t instanceof r)?function(e){return t.test(e.pathname.replace(window.getOpenmrsSpaBase(),""))}:function(){return t}}(a),n=t.online,o=t.offline,i=t.featureFlag,window.offlineEnabled?function(e){return!!(navigator.onLine&&(null==n||n)||!navigator.onLine&&null!=o&&o)&&(!i||!!(0,N.jj)(i))&&r(e)}:r);(0,U.registerApplication)(e,function(){return H(t.appName,t.component)},u)}(l,u)}}catch(e){r=!0,n=e}finally{try{t||null==i.return||i.return()}finally{if(r)throw n}}}function Q(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.localStorage;try{return e.getItem("test"),!0}catch(e){return!1}}function ee(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function et(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}var er=Q();function en(e,t){if(er){if("string"==typeof t)if(t.startsWith("http"))return ea(e,t);else try{var r,n=JSON.parse(t);if(eu(n))return ea(e,n);console.error("The supplied routes for ".concat(e," is not a valid OpenmrsAppRoutes object"),t)}catch(t){console.error("Could not add routes override for ".concat(e,": "),t)}else{if(null!=(r=URL)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](t):t instanceof r)return ea(e,t.toString());if(eu(t))return ea(e,t)}console.error("Override for ".concat(e," is not in a valid format. Expected either a Javascript Object, a JSON string of a Javascript object, or a URL"),t)}}function eo(e){er&&localStorage.removeItem(V+e)}function ei(){if(er){var e=!0,t=!1,r=void 0;try{for(var n,o=Object.keys(localStorage)[Symbol.iterator]();!(e=(n=o.next()).done);e=!0){var i=n.value;i.startsWith(V)&&localStorage.removeItem(i)}}catch(e){t=!0,r=e}finally{try{e||null==o.return||o.return()}finally{if(t)throw r}}}}function ea(e,t){localStorage.setItem(V+e,JSON.stringify(t))}function eu(e){if(e&&(void 0===e?"undefined":et(e))==="object"){var t=Object.prototype.hasOwnProperty;return!(t.call(e,"pages")&&(!e.pages||!Array.isArray(e.pages))||t.call(e,"extensions")&&(!e.extensions||!Array.isArray(e.extensions))||t.call(e,"workspaces")&&(!e.workspaces||!Array.isArray(e.workspaces))||t.call(e,"modals")&&(!e.modals||!Array.isArray(e.modals)))}return!1}function es(e){return!!e&&(void 0===e?"undefined":et(e))==="object"&&Object.entries(e).every(function(e){var t=function(e){if(Array.isArray(e))return e}(e)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return ee(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return ee(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],n=t[1];return"string"==typeof r&&eu(n)})}var el=r(2883),ec={PHONE_MIN:0,PHONE_MAX:600,TABLET_MIN:601,TABLET_MAX:1023,SMALL_DESKTOP_MIN:1024,SMALL_DESKTOP_MAX:1439,LARGE_DESKTOP_MIN:1440,LARGE_DESKTOP_MAX:Number.MAX_SAFE_INTEGER};function ed(){document.body.classList.toggle("omrs-breakpoint-lt-tablet",window.innerWidth<ec.TABLET_MIN),document.body.classList.toggle("omrs-breakpoint-gt-phone",window.innerWidth>ec.PHONE_MAX),document.body.classList.toggle("omrs-breakpoint-gt-tablet",window.innerWidth>ec.TABLET_MAX),document.body.classList.toggle("omrs-breakpoint-lt-desktop",window.innerWidth<ec.SMALL_DESKTOP_MIN),document.body.classList.toggle("omrs-breakpoint-lt-small-desktop",window.innerWidth<ec.SMALL_DESKTOP_MIN),document.body.classList.toggle("omrs-breakpoint-lt-large-desktop",window.innerWidth<ec.LARGE_DESKTOP_MIN),document.body.classList.toggle("omrs-breakpoint-gt-small-desktop",window.innerWidth>ec.SMALL_DESKTOP_MAX)}var ef=!1;function ep(){ef||(window.addEventListener("resize",ed),ed(),ef=!0)}var eh=r(5264),em=r(6925),ey=r.n(em),eb=r(9663),ev=r.n(eb);function eg(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ew(e){var t,r=e.title,n=e.children,o="tablet"===(0,L.qv)();return(0,eh.jsxs)("div",{className:ev()((eg(t={},"Vkmd-M3ZdPZe+c6OloVbnw==",o),eg(t,"ocWGqN+S6wY3-wV0QG3pOw==",!o),t)),children:[(0,eh.jsx)("h4",{children:r}),n]})}var eE=r(1017),eS=r(8326),eO={"carbon.table.batch.cancel":"cancel","carbon.table.batch.items.selected":"batchActionsItemsSelected","carbon.table.batch.item.selected":"batchActionItemSelected","carbon.table.batch.selectAll":"selectAll"},eA=function(e){return(0,eh.jsx)(eS.TableBatchActions,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({translateWithId:function(e,t){var r=eO[e];return r?(0,h.V)(r,e,t):e}},e))};let ex="_8PykSzSXNNdifN25ybqq3w==",eD="qsOLntRcFqCu-mnZH0czJA==",e_="BserJewmzluWUcq5q8a0yw==",ej="n86GzT7Rs8Kf8e25ihYZPg==";function eC(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function eP(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var ek=(0,em.createContext)(null);function eI(){var e=(0,em.useContext)(ek);if(!e)throw Error("useCustomOverflowMenu must be used within a CustomOverflowMenu");return e}function eT(e){var t,r=e.menuTitle,n=e.children,o=function(e){if(Array.isArray(e))return e}(t=ey().useState(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return eC(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return eC(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=o[0],a=o[1],u=(0,L.Wr)(function(){return a(!1)},i),s="tablet"===(0,L.qv)(),l=(0,em.useCallback)(function(){return a(function(e){return!e})},[]),c=(0,em.useRef)(null),d=(0,em.useRef)(null),f=(0,em.useId)(),p="custom-overflow-menu-trigger-".concat(f),h="custom-overflow-menu-".concat(f),m=(0,em.useCallback)(function(){var e;a(!1),null==(e=c.current)||e.focus()},[]),y=(0,em.useMemo)(function(){return{closeMenu:m}},[m]),b=(0,em.useCallback)(function(e){"Escape"===e.key&&i&&(e.stopPropagation(),m())},[m,i]),v=em.Children.toArray(n);(0,em.useEffect)(function(){if(i&&d.current){var e=d.current.querySelector('[role="menuitem"]:not([disabled])');null==e||e.focus()}},[i]);var g=(0,em.useCallback)(function(e){e.currentIndex;var t,r,n,o,i,a,u=e.direction,s=null==(r=d.current)?void 0:r.querySelectorAll('[role="menuitem"]:not([disabled])');if(null==s?void 0:s.length){var l=null!=(t=null==(o=document.activeElement)||null==(n=o.closest)?void 0:n.call(o,'[role="menuitem"]'))?t:document.activeElement,c=Array.from(s).indexOf(l);if(-1===c){null==(a=s[u>0?0:s.length-1])||a.focus();return}var f=c+u,p=f<0?s.length-1:f>=s.length?0:f;null==(i=s[p])||i.focus()}},[]),w=v.map(function(e,t){return(0,em.isValidElement)(e)?(0,em.cloneElement)(e,{closeMenu:m,handleOverflowMenuItemFocus:g,index:t}):e});return(0,eh.jsxs)("div",{"data-overflow-menu":!0,className:ev()("cds--overflow-menu",ex),ref:u,children:[(0,eh.jsx)("button",{className:ev()("cds--btn","cds--btn--ghost","cds--overflow-menu__trigger",{"cds--overflow-menu--open":i},ej),"aria-controls":h,"aria-expanded":i,"aria-haspopup":"true",id:p,onClick:l,onKeyDown:b,ref:c,children:r}),(0,eh.jsxs)("div",{className:ev()("cds--overflow-menu-options","cds--overflow-menu--flip",eD,eP({},e_,i)),"aria-labelledby":p,"data-floating-menu-direction":"bottom",id:h,onKeyDown:b,ref:d,role:"menu",tabIndex:-1,children:[(0,eh.jsx)("ul",{className:ev()("cds--overflow-menu-options__content",{"cds--overflow-menu-options--lg":s}),children:(0,eh.jsx)(ek.Provider,{value:y,children:w})}),(0,eh.jsx)("span",{})]})]})}function eR(e){var t,r,n=(0,em.useContext)(ek);return(0,eh.jsx)(eS.OverflowMenuItem,(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){eP(e,t,r[t])})}return e}({},e),r=r={closeMenu:null==n?void 0:n.closeMenu},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))}var eF=r(9737),eN=r(7665);function eM(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function eB(e){if(Array.isArray(e))return e}function eL(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function eV(e,t){if(e){if("string"==typeof e)return eM(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return eM(e,t)}}var eU=["omrs-icon-activity","omrs-icon-add","omrs-icon-arrow-down","omrs-icon-arrow-left","omrs-icon-arrow-right","omrs-icon-arrow-up","omrs-icon-baby","omrs-icon-calendar-heat-map","omrs-icon-calendar","omrs-icon-caret-down","omrs-icon-caret-left","omrs-icon-caret-right","omrs-icon-caret-up","omrs-icon-chart-average","omrs-icon-chart-line","omrs-icon-checkmark-filled","omrs-icon-checkmark-outline","omrs-icon-chemistry","omrs-icon-chevron-down","omrs-icon-chevron-left","omrs-icon-chevron-right","omrs-icon-chevron-up","omrs-icon-close","omrs-icon-close-filled","omrs-icon-close-outline","omrs-icon-document","omrs-icon-document-attachment","omrs-icon-download","omrs-icon-drug-order","omrs-icon-edit","omrs-icon-event-schedule","omrs-icon-events","omrs-icon-gender-female","omrs-icon-gender-male","omrs-icon-gender-other","omrs-icon-gender-unknown","omrs-icon-generic-order-type","omrs-icon-group","omrs-icon-group-access","omrs-icon-hospital-bed","omrs-icon-image-medical","omrs-icon-information","omrs-icon-information-filled","omrs-icon-information-square","omrs-icon-inventory-management","omrs-icon-lab-order","omrs-icon-list-checked","omrs-icon-location","omrs-icon-material-order","omrs-icon-maximize","omrs-icon-medication","omrs-icon-message-queue","omrs-icon-microscope","omrs-icon-money","omrs-icon-mother","omrs-icon-movement","omrs-icon-overflow-menu--horizontal","omrs-icon-overflow-menu--vertical","omrs-icon-password","omrs-icon-pedestrian-family","omrs-icon-pen","omrs-icon-printer","omrs-icon-procedure-order","omrs-icon-programs","omrs-icon-renew","omrs-icon-referral-order","omrs-icon-report","omrs-icon-reset","omrs-icon-save","omrs-icon-search","omrs-icon-settings","omrs-icon-shopping-cart","omrs-icon-shopping-cart--arrow-down","omrs-icon-sticky-note-add","omrs-icon-switcher","omrs-icon-syringe","omrs-icon-table-of-contents","omrs-icon-table","omrs-icon-time","omrs-icon-tools","omrs-icon-translate","omrs-icon-trash-can","omrs-icon-tree-view--alt","omrs-icon-user-avatar","omrs-icon-user-follow","omrs-icon-user-xray","omrs-icon-user","omrs-icon-view-off","omrs-icon-view","omrs-icon-warning"],e$=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-activity",iconProps:e})})),eW=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-add",iconProps:e})})),ez=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-arrow-down",iconProps:e})})),eK=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-arrow-left",iconProps:e})})),eH=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-arrow-right",iconProps:e})})),eG=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-arrow-up",iconProps:e})})),eq=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-baby",iconProps:e})})),eZ=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-calendar-heat-map",iconProps:e})})),eY=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-calendar",iconProps:e})})),eJ=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-caret-down",iconProps:e})})),eX=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-caret-left",iconProps:e})})),eQ=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-caret-right",iconProps:e})})),e0=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-caret-up",iconProps:e})})),e1=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-chart-average",iconProps:e})})),e2=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-chart-line",iconProps:e})})),e3=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-checkmark-filled",iconProps:e})})),e4=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-checkmark-outline",iconProps:e})})),e6=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-chemistry",iconProps:e})})),e5=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-chevron-down",iconProps:e})})),e8=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-chevron-left",iconProps:e})})),e7=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-chevron-right",iconProps:e})})),e9=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-chevron-up",iconProps:e})})),te=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-close",iconProps:e})})),tt=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-close-filled",iconProps:e})})),tr=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-close-outline",iconProps:e})})),tn=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-document",iconProps:e})})),to=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-document-attachment",iconProps:e})})),ti=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-download",iconProps:e})})),ta=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-drug-order",iconProps:e})})),tu=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-edit",iconProps:e})})),ts=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-event-schedule",iconProps:e})})),tl=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-events",iconProps:e})})),tc=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-gender-female",iconProps:e})})),td=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-gender-male",iconProps:e})})),tf=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-gender-other",iconProps:e})})),tp=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-gender-unknown",iconProps:e})})),th=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-generic-order-type",iconProps:e})})),tm=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-group",iconProps:e})})),ty=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-group-access",iconProps:e})})),tb=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-hospital-bed",iconProps:e})})),tv=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-image-medical",iconProps:e})})),tg=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-information",iconProps:e})})),tw=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-information-filled",iconProps:e})})),tE=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-information-square",iconProps:e})})),tS=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-inventory-management",iconProps:e})})),tO=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-lab-order",iconProps:e})})),tA=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-list-checked",iconProps:e})})),tx=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-location",iconProps:e})})),tD=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-material-order",iconProps:e})})),t_=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-maximize",iconProps:e})})),tj=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-medication",iconProps:e})})),tC=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-message-queue",iconProps:e})})),tP=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-microscope",iconProps:e})})),tk=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-money",iconProps:e})})),tI=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-mother",iconProps:e})})),tT=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-movement",iconProps:e})})),tR=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-overflow-menu--horizontal",iconProps:e})})),tF=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-overflow-menu--horizontal",iconProps:e})})),tN=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-password",iconProps:e})})),tM=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-pedestrian-family",iconProps:e})})),tB=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-pen",iconProps:e})})),tL=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-printer",iconProps:e})})),tV=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-procedure-order",iconProps:e})})),tU=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-programs",iconProps:e})})),t$=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-referral-order",iconProps:e})})),tW=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-renew",iconProps:e})})),tz=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-report",iconProps:e})})),tK=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-reset",iconProps:e})})),tH=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-save",iconProps:e})})),tG=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-search",iconProps:e})})),tq=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-settings",iconProps:e})})),tZ=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-switcher",iconProps:e})})),tY=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-shopping-cart",iconProps:e})})),tJ=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-shopping-cart--arrow-down",iconProps:e})})),tX=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-sticky-note-add",iconProps:e})})),tQ=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-syringe",iconProps:e})})),t0=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-table-of-contents",iconProps:e})})),t1=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-table",iconProps:e})})),t2=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-time",iconProps:e})})),t3=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-tools",iconProps:e})})),t4=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-translate",iconProps:e})})),t6=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-trash-can",iconProps:e})})),t5=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-tree-view--alt",iconProps:e})})),t8=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-user-avatar",iconProps:e})})),t7=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-user-follow",iconProps:e})})),t9=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-user-xray",iconProps:e})})),re=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-user",iconProps:e})})),rt=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-view-off",iconProps:e})})),rr=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-view",iconProps:e})})),rn=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(rc,{ref:t,icon:"omrs-icon-warning",iconProps:e})})),ro=rn,ri=to,ra=tA,ru=tv,rs=tJ,rl=(0,em.memo)((0,em.forwardRef)(function(e,t){var r,n=eB(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||eV(r)||eL(),o=n[0],i=n.slice(1),a=o.icon,u=o.fallback,s=function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(o,["icon","fallback"]),l=(eB(i)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),1!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(i)||eV(i,1)||eL())[0],c=(0,em.useRef)(a?document.getElementById(a):void 0);return(0,em.useEffect)(function(){var e=document.getElementById("omrs-svgs-container"),t=new MutationObserver(function(e){var t=!0,r=!1,n=void 0;try{for(var o,i=e[Symbol.iterator]();!(t=(o=i.next()).done);t=!0){var u=o.value;"childList"===u.type&&(c.current=a?document.getElementById(a):void 0)}}catch(e){r=!0,n=e}finally{try{t||null==i.return||i.return()}finally{if(r)throw n}}});return e&&t.observe(e,{childList:!0}),function(){return t.disconnect()}},[a]),(0,eh.jsx)(L.fS,{value:c.current,fallback:u,children:(0,eh.jsx)(rc,{ref:l,icon:a,iconProps:s})})})),rc=(0,em.memo)((0,em.forwardRef)(function(e,t){var r=e.icon,n=Object.assign({},{fill:"currentColor",size:20},e.iconProps),o=n.className,i=n.fill,a=n.size;(a<=0||a>72)&&(console.error("Invalid size '".concat(a,"' specified for ").concat(r,". Defaulting to 20.")),a=20);var u=(0,em.useRef)(null);return(0,em.useImperativeHandle)(t,function(){return u.current}),(0,em.useEffect)(function(){u.current&&"currentColor"!==i&&u.current.style.setProperty("--omrs-icon-fill",i)},[]),(0,eh.jsx)("svg",{ref:u,className:ev()("omrs-icon","BfFhdfwf1e98NnHqJTMOmw==",o),height:a,width:a,viewBox:"0 0 16 16",children:(0,eh.jsx)("use",{href:"#".concat(r)})})})),rd=function(e){var t=e.path,r=e.title,n=e.basePath,o=e.icon,i=(0,eF.useTranslation)().t,a=(0,eN.useLocation)(),u=(0,em.useMemo)(function(){if(!t)return!1;var e,r=t.startsWith("/")?t.slice(1):t;if(r.startsWith("http"))return r===window.location.href;var n=r.split("/").map(function(e){return decodeURIComponent(e)}),o=(null!=(e=a.pathname)?e:"").split("/").slice(1).map(function(e){return decodeURIComponent(e)});return o.some(function(e,t){return n.every(function(e,r){return o[t+r]===e})})},[a.pathname,t]);return(0,eh.jsx)("div",{children:(0,eh.jsx)(L.i_,{className:ev()("cds--side-nav__link",{"active-left-nav-link":u}),to:"".concat(n,"/").concat(encodeURIComponent(t)),children:(0,eh.jsxs)("span",{className:"ds1tfuMnfJ+PmahVRNLpnQ==",children:[(0,eh.jsx)(rl,{icon:o,className:"_4ZrrhAdbDQb3EuiAijKGFw==",size:16}),(0,eh.jsx)("span",{children:i(r)})]})})},t)};function rf(e){return function(t){var r=t.basePath;return(0,eh.jsx)(eN.BrowserRouter,{children:(0,eh.jsx)(rd,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({basePath:r},e))})}}function rp(e){let t=(0,em.useRef)(null);return(0,em.useMemo)(()=>({get current(){return t.current},set current(value){t.current=value,"function"==typeof e?e(value):e&&(e.current=value)}}),[e])}function rh(...e){return(...t)=>{for(let r of e)"function"==typeof r&&r(...t)}}let rm="u">typeof document?ey().useLayoutEffect:()=>{};function ry(e){let t=(0,em.useRef)(null);return rm(()=>{t.current=e},[e]),(0,em.useCallback)((...e)=>{let r=t.current;return null==r?void 0:r(...e)},[])}let rb={prefix:String(Math.round(1e10*Math.random())),current:0},rv=ey().createContext(rb),rg=ey().createContext(!1),rw=("u">typeof window&&window.document&&window.document.createElement,new WeakMap),rE="function"==typeof ey().useId?function(e){let t=ey().useId(),[r]=(0,em.useState)(rx()),n=r?"react-aria":`react-aria${rb.prefix}`;return e||`${n}-${t}`}:function(e){let t=(0,em.useContext)(rv),r=function(e=!1){let t=(0,em.useContext)(rv),r=(0,em.useRef)(null);if(null===r.current&&!e){var n,o;let e=null==(o=ey().__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED)||null==(n=o.ReactCurrentOwner)?void 0:n.current;if(e){let r=rw.get(e);null==r?rw.set(e,{id:t.current,state:e.memoizedState}):e.memoizedState!==r.state&&(t.current=r.id,rw.delete(e))}r.current=++t.current}return r.current}(!!e),n=`react-aria${t.prefix}`;return e||`${n}-${r}`};function rS(){return!1}function rO(){return!0}function rA(e){return()=>{}}function rx(){return"function"==typeof ey().useSyncExternalStore?ey().useSyncExternalStore(rA,rS,rO):(0,em.useContext)(rg)}let rD=!!("u">typeof window&&window.document&&window.document.createElement),r_=new Map;function rj(e){let[t,r]=(0,em.useState)(e),o=(0,em.useRef)(null),i=rE(t),a=(0,em.useRef)(null);if(n&&n.register(a,i),rD){let e=r_.get(i);e&&!e.includes(o)?e.push(o):r_.set(i,[o])}return rm(()=>()=>{n&&n.unregister(a),r_.delete(i)},[i]),(0,em.useEffect)(()=>{let e=o.current;return e&&r(e),()=>{e&&(o.current=null)}}),i}function rC(e=[]){let t=rj(),[r,n]=function(e){let[t,r]=(0,em.useState)(e),n=(0,em.useRef)(null),o=ry(()=>{if(!n.current)return;let e=n.current.next();if(e.done){n.current=null;return}t===e.value?o():r(e.value)});rm(()=>{n.current&&o()});let i=ry(e=>{n.current=e(t),o()});return[t,i]}(t),o=(0,em.useCallback)(()=>{n(function*(){yield t,yield document.getElementById(t)?t:void 0})},[t,n]);return rm(o,[t,o,...e]),r}"u">typeof FinalizationRegistry&&(n=new FinalizationRegistry(e=>{r_.delete(e)}));let rP=function(){for(var e,t,r=0,n="",o=arguments.length;r<o;r++)(e=arguments[r])&&(t=function e(t){var r,n,o="";if("string"==typeof t||"number"==typeof t)o+=t;else if("object"==typeof t)if(Array.isArray(t)){var i=t.length;for(r=0;r<i;r++)t[r]&&(n=e(t[r]))&&(o&&(o+=" "),o+=n)}else for(n in t)t[n]&&(o&&(o+=" "),o+=n);return o}(e))&&(n&&(n+=" "),n+=t);return n};function rk(...e){let t={...e[0]};for(let r=1;r<e.length;r++){let n=e[r];for(let e in n){let r=t[e],o=n[e];"function"==typeof r&&"function"==typeof o&&"o"===e[0]&&"n"===e[1]&&e.charCodeAt(2)>=65&&90>=e.charCodeAt(2)?t[e]=rh(r,o):("className"===e||"UNSAFE_className"===e)&&"string"==typeof r&&"string"==typeof o?t[e]=rP(r,o):"id"===e&&r&&o?t.id=function(e,t){if(e===t)return e;let r=r_.get(e);if(r)return r.forEach(e=>e.current=t),t;let n=r_.get(t);return n?(n.forEach(t=>t.current=e),e):t}(r,o):t[e]=void 0!==o?o:r}}return t}let rI=Symbol("default");function rT({values:e,children:t}){for(let[r,n]of e)t=ey().createElement(r.Provider,{value:n},t);return t}function rR(e){let{className:t,style:r,children:n,defaultClassName:o,defaultChildren:i,defaultStyle:a,values:u}=e;return(0,em.useMemo)(()=>{let e,s,l;return e="function"==typeof t?t({...u,defaultClassName:o}):t,s="function"==typeof r?r({...u,defaultStyle:a||{}}):r,l="function"==typeof n?n({...u,defaultChildren:i}):null==n?i:n,{className:null!=e?e:o,style:s||a?{...a,...s}:void 0,children:null!=l?l:i,"data-rac":""}},[t,r,n,o,i,a,u])}function rF(e,t){let r=(0,em.useContext)(e);if(null===t)return null;if(r&&"object"==typeof r&&"slots"in r&&r.slots){let e=t||rI;if(!r.slots[e]){let e=new Intl.ListFormat().format(Object.keys(r.slots).map(e=>`"${e}"`)),n=t?`Invalid slot "${t}".`:"A slot prop is required.";throw Error(`${n} Valid slot names are ${e}.`)}return r.slots[e]}return r}function rN(e,t,r){let{ref:n,...o}=rF(r,e.slot)||{},i=rp((0,em.useMemo)(()=>(function(...e){return 1===e.length&&e[0]?e[0]:t=>{for(let r of e)"function"==typeof r?r(t):null!=r&&(r.current=t)}})(t,n),[t,n])),a=rk(o,e);return"style"in o&&o.style&&"style"in e&&e.style&&("function"==typeof o.style||"function"==typeof e.style?a.style=t=>{let r="function"==typeof o.style?o.style(t):o.style,n={...t.defaultStyle,...r},i="function"==typeof e.style?e.style({...t,defaultStyle:n}):e.style;return{...n,...i}}:a.style={...o.style,...e.style}),[a,i]}function rM(e=!0){let[t,r]=(0,em.useState)(e),n=(0,em.useRef)(!1),o=(0,em.useCallback)(e=>{n.current=!0,r(!!e)},[]);return rm(()=>{n.current||r(!1)},[]),[o,t]}function rB(e){let t=/^(data-.*)$/,r={};for(let n in e)t.test(n)||(r[n]=e[n]);return r}let rL=(0,em.createContext)(null),rV=null;function rU(e,t="assertive",r=7e3){rV?rV.announce(e,t,r):(rV=new r$,("boolean"==typeof IS_REACT_ACT_ENVIRONMENT?IS_REACT_ACT_ENVIRONMENT:"u">typeof jest)?rV.announce(e,t,r):setTimeout(()=>{(null==rV?void 0:rV.isAttached())&&(null==rV||rV.announce(e,t,r))},100))}class r${isAttached(){var e;return null==(e=this.node)?void 0:e.isConnected}createLog(e){let t=document.createElement("div");return t.setAttribute("role","log"),t.setAttribute("aria-live",e),t.setAttribute("aria-relevant","additions"),t}destroy(){this.node&&(document.body.removeChild(this.node),this.node=null)}announce(e,t="assertive",r=7e3){var n,o;if(!this.node)return;let i=document.createElement("div");"object"==typeof e?(i.setAttribute("role","img"),i.setAttribute("aria-labelledby",e["aria-labelledby"])):i.textContent=e,"assertive"===t?null==(n=this.assertiveLog)||n.appendChild(i):null==(o=this.politeLog)||o.appendChild(i),""!==e&&setTimeout(()=>{i.remove()},r)}clear(e){this.node&&((!e||"assertive"===e)&&this.assertiveLog&&(this.assertiveLog.innerHTML=""),(!e||"polite"===e)&&this.politeLog&&(this.politeLog.innerHTML=""))}constructor(){this.node=null,this.assertiveLog=null,this.politeLog=null,"u">typeof document&&(this.node=document.createElement("div"),this.node.dataset.liveAnnouncer="true",Object.assign(this.node.style,{border:0,clip:"rect(0 0 0 0)",clipPath:"inset(50%)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"}),this.assertiveLog=this.createLog("assertive"),this.node.appendChild(this.assertiveLog),this.politeLog=this.createLog("polite"),this.node.appendChild(this.politeLog),document.body.prepend(this.node))}}let rW=new Set(["id"]),rz=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),rK=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),rH=/^(data-.*)$/;function rG(e,t={}){let{labelable:r,isLink:n,propNames:o}=t,i={};for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(rW.has(t)||r&&rz.has(t)||n&&rK.has(t)||(null==o?void 0:o.has(t))||rH.test(t))&&(i[t]=e[t]);return i}let rq=["input:not([disabled]):not([type=hidden])","select:not([disabled])","textarea:not([disabled])","button:not([disabled])","a[href]","area[href]","summary","iframe","object","embed","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable^="false"])'],rZ=rq.join(":not([hidden]),")+",[tabindex]:not([disabled]):not([hidden])";rq.push('[tabindex]:not([tabindex="-1"]):not([disabled])');let rY=rq.join(':not([hidden]):not([tabindex="-1"]),');function rJ(e){return e.matches(rZ)}function rX(e){return e.matches(rY)}let rQ=e=>{var t;return null!=(t=null==e?void 0:e.ownerDocument)?t:document},r0=e=>e&&"window"in e&&e.window===e?e:rQ(e).defaultView||window;function r1(e){if(function(){if(null==r2){r2=!1;try{document.createElement("div").focus({get preventScroll(){return r2=!0,!0}})}catch{}}return r2}())e.focus({preventScroll:!0});else{let t=function(e){let t=e.parentNode,r=[],n=document.scrollingElement||document.documentElement;for(;t instanceof HTMLElement&&t!==n;)(t.offsetHeight<t.scrollHeight||t.offsetWidth<t.scrollWidth)&&r.push({element:t,scrollTop:t.scrollTop,scrollLeft:t.scrollLeft}),t=t.parentNode;return n instanceof HTMLElement&&r.push({element:n,scrollTop:n.scrollTop,scrollLeft:n.scrollLeft}),r}(e);e.focus(),function(e){for(let{element:t,scrollTop:r,scrollLeft:n}of e)t.scrollTop=r,t.scrollLeft=n}(t)}}let r2=null;function r3(e){return e.nativeEvent=e,e.isDefaultPrevented=()=>e.defaultPrevented,e.isPropagationStopped=()=>e.cancelBubble,e.persist=()=>{},e}function r4(e,t){Object.defineProperty(e,"target",{value:t}),Object.defineProperty(e,"currentTarget",{value:t})}function r6(e){let t=(0,em.useRef)({isFocused:!1,observer:null});rm(()=>{let e=t.current;return()=>{e.observer&&(e.observer.disconnect(),e.observer=null)}},[]);let r=ry(t=>{null==e||e(t)});return(0,em.useCallback)(e=>{if(e.target instanceof HTMLButtonElement||e.target instanceof HTMLInputElement||e.target instanceof HTMLTextAreaElement||e.target instanceof HTMLSelectElement){t.current.isFocused=!0;let n=e.target;n.addEventListener("focusout",e=>{t.current.isFocused=!1,n.disabled&&r(r3(e)),t.current.observer&&(t.current.observer.disconnect(),t.current.observer=null)},{once:!0}),t.current.observer=new MutationObserver(()=>{if(t.current.isFocused&&n.disabled){var e;null==(e=t.current.observer)||e.disconnect();let r=n===document.activeElement?null:document.activeElement;n.dispatchEvent(new FocusEvent("blur",{relatedTarget:r})),n.dispatchEvent(new FocusEvent("focusout",{bubbles:!0,relatedTarget:r}))}}),t.current.observer.observe(n,{attributes:!0,attributeFilter:["disabled"]})}},[r])}let r5=!1;function r8(e){var t;return!("u"<typeof window)&&null!=window.navigator&&((null==(t=window.navigator.userAgentData)?void 0:t.brands.some(t=>e.test(t.brand)))||e.test(window.navigator.userAgent))}function r7(e){var t;return"u">typeof window&&null!=window.navigator&&e.test((null==(t=window.navigator.userAgentData)?void 0:t.platform)||window.navigator.platform)}function r9(e){let t=null;return()=>(null==t&&(t=e()),t)}let ne=r9(function(){return r7(/^Mac/i)}),nt=r9(function(){return r7(/^iPhone/i)}),nr=r9(function(){return r7(/^iPad/i)||ne()&&navigator.maxTouchPoints>1}),nn=r9(function(){return nt()||nr()});r9(function(){return ne()||nn()});let no=r9(function(){return r8(/AppleWebKit/i)&&!ni()}),ni=r9(function(){return r8(/Chrome/i)}),na=r9(function(){return r8(/Android/i)}),nu=r9(function(){return r8(/Firefox/i)}),ns=new Map,nl=new Set;function nc(){if("u"<typeof window)return;function e(e){return"propertyName"in e}let t=r=>{if(!e(r)||!r.target)return;let n=ns.get(r.target);if(n&&(n.delete(r.propertyName),0===n.size&&(r.target.removeEventListener("transitioncancel",t),ns.delete(r.target)),0===ns.size)){for(let e of nl)e();nl.clear()}};document.body.addEventListener("transitionrun",r=>{if(!e(r)||!r.target)return;let n=ns.get(r.target);n||(n=new Set,ns.set(r.target,n),r.target.addEventListener("transitioncancel",t,{once:!0})),n.add(r.propertyName)}),document.body.addEventListener("transitionend",t)}function nd(e){requestAnimationFrame(()=>{0===ns.size?e():nl.add(e)})}"u">typeof document&&("loading"!==document.readyState?nc():document.addEventListener("DOMContentLoaded",nc));let nf="default",np="",nh=new WeakMap;function nm(e){if(nn())"disabled"===nf&&(nf="restoring",setTimeout(()=>{nd(()=>{if("restoring"===nf){let t=rQ(e);"none"===t.documentElement.style.webkitUserSelect&&(t.documentElement.style.webkitUserSelect=np||""),np="",nf="default"}})},300));else if((e instanceof HTMLElement||e instanceof SVGElement)&&e&&nh.has(e)){let t=nh.get(e),r="userSelect"in e.style?"userSelect":"webkitUserSelect";"none"===e.style[r]&&(e.style[r]=t),""===e.getAttribute("style")&&e.removeAttribute("style"),nh.delete(e)}}let ny=ey().createContext({register:()=>{}});function nb(e,t,r){if(!t.has(e))throw TypeError("attempted to "+r+" private field on non-instance");return t.get(e)}function nv(e,t,r){if(t.has(e))throw TypeError("Cannot initialize the same private elements twice on an object");t.set(e,r)}function ng(e,t,r){var n=nb(e,t,"set");if(n.set)n.set.call(e,r);else{if(!n.writable)throw TypeError("attempted to set read only private field");n.value=r}return r}function nw(e,t){rm(()=>{if(e&&e.ref&&t)return e.ref.current=t.current,()=>{e.ref&&(e.ref.current=null)}})}function nE(){let e=(0,em.useRef)(new Map),t=(0,em.useCallback)((t,r,n,o)=>{let i=(null==o?void 0:o.once)?(...t)=>{e.current.delete(n),n(...t)}:n;e.current.set(n,{type:r,eventTarget:t,fn:i,options:o}),t.addEventListener(r,i,o)},[]),r=(0,em.useCallback)((t,r,n,o)=>{var i;let a=(null==(i=e.current.get(n))?void 0:i.fn)||n;t.removeEventListener(r,a,o),e.current.delete(n)},[]),n=(0,em.useCallback)(()=>{e.current.forEach((e,t)=>{r(e.eventTarget,e.type,t,e.options)})},[r]);return(0,em.useEffect)(()=>n,[n]),{addGlobalListener:t,removeGlobalListener:r,removeAllGlobalListeners:n}}ny.displayName="PressResponderContext";function nS(e,t){return!!t&&!!e&&e.contains(t)}function nO(e){return e.target}function nA(e,t,r=!0){var n,o;let{metaKey:i,ctrlKey:a,altKey:u,shiftKey:s}=t;nu()&&(null==(o=window.event)||null==(n=o.type)?void 0:n.startsWith("key"))&&"_blank"===e.target&&(ne()?i=!0:a=!0);let l=no()&&ne()&&!nr()&&1?new KeyboardEvent("keydown",{keyIdentifier:"Enter",metaKey:i,ctrlKey:a,altKey:u,shiftKey:s}):new MouseEvent("click",{metaKey:i,ctrlKey:a,altKey:u,shiftKey:s,bubbles:!0,cancelable:!0});nA.isOpening=r,r1(e),e.dispatchEvent(l),nA.isOpening=!1}function nx(e){return 0===e.mozInputSource&&!!e.isTrusted||(na()&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType)}nA.isOpening=!1;var nD=r(2065),n_=r.n(nD),nj=new WeakMap;class nC{continuePropagation(){ng(this,nj,!1)}get shouldStopPropagation(){var e;return e=nb(this,nj,"get"),e.get?e.get.call(this):e.value}constructor(e,t,r,n){var o;nv(this,nj,{writable:!0,value:void 0}),ng(this,nj,!0);let i=null!=(o=null==n?void 0:n.target)?o:r.currentTarget;const a=null==i?void 0:i.getBoundingClientRect();let u,s=0,l,c=null;null!=r.clientX&&null!=r.clientY&&(l=r.clientX,c=r.clientY),a&&(null!=l&&null!=c?(u=l-a.left,s=c-a.top):(u=a.width/2,s=a.height/2)),this.type=e,this.pointerType=t,this.target=r.currentTarget,this.shiftKey=r.shiftKey,this.metaKey=r.metaKey,this.ctrlKey=r.ctrlKey,this.altKey=r.altKey,this.x=u,this.y=s}}let nP=Symbol("linkClicked");function nk(e){let{onPress:t,onPressChange:r,onPressStart:n,onPressEnd:o,onPressUp:i,onClick:a,isDisabled:u,isPressed:s,preventFocusOnPress:l,shouldCancelOnPointerExit:c,allowTextSelectionOnPress:d,ref:f,...p}=function(e){let t=(0,em.useContext)(ny);if(t){let{register:r,...n}=t;e=rk(n,e),r()}return nw(t,e.ref),e}(e),[h,m]=(0,em.useState)(!1),y=(0,em.useRef)({isPressed:!1,ignoreEmulatedMouseEvents:!1,didFirePressStart:!1,isTriggeringEvent:!1,activePointerId:null,target:null,isOverTarget:!1,pointerType:null,disposables:[]}),{addGlobalListener:b,removeAllGlobalListeners:v}=nE(),g=ry((e,t)=>{let o=y.current;if(u||o.didFirePressStart)return!1;let i=!0;if(o.isTriggeringEvent=!0,n){let r=new nC("pressstart",t,e);n(r),i=r.shouldStopPropagation}return r&&r(!0),o.isTriggeringEvent=!1,o.didFirePressStart=!0,m(!0),i}),w=ry((e,n,i=!0)=>{let a=y.current;if(!a.didFirePressStart)return!1;a.didFirePressStart=!1,a.isTriggeringEvent=!0;let s=!0;if(o){let t=new nC("pressend",n,e);o(t),s=t.shouldStopPropagation}if(r&&r(!1),m(!1),t&&i&&!u){let r=new nC("press",n,e);t(r),s&&(s=r.shouldStopPropagation)}return a.isTriggeringEvent=!1,s}),E=ry((e,t)=>{let r=y.current;if(u)return!1;if(i){r.isTriggeringEvent=!0;let n=new nC("pressup",t,e);return i(n),r.isTriggeringEvent=!1,n.shouldStopPropagation}return!0}),S=ry(e=>{let t=y.current;if(t.isPressed&&t.target){for(let r of(t.didFirePressStart&&null!=t.pointerType&&w(nR(t.target,e),t.pointerType,!1),t.isPressed=!1,t.isOverTarget=!1,t.activePointerId=null,t.pointerType=null,v(),d||nm(t.target),t.disposables))r();t.disposables=[]}}),O=ry(e=>{c&&S(e)}),A=ry(e=>{null==a||a(e)}),x=ry((e,t)=>{if(a){let r=new MouseEvent("click",e);r4(r,t),a(r3(r))}}),D=(0,em.useMemo)(()=>{let e=y.current,t={onKeyDown(t){if(nT(t.nativeEvent,t.currentTarget)&&nS(t.currentTarget,nO(t.nativeEvent))){var n;nF(nO(t.nativeEvent),t.key)&&t.preventDefault();let o=!0;if(!e.isPressed&&!t.repeat){e.target=t.currentTarget,e.isPressed=!0,e.pointerType="keyboard",o=g(t,"keyboard");let n=t.currentTarget;b(rQ(t.currentTarget),"keyup",rh(t=>{nT(t,n)&&!t.repeat&&nS(n,nO(t))&&e.target&&E(nR(e.target,t),"keyboard")},r),!0)}o&&t.stopPropagation(),t.metaKey&&ne()&&(null==(n=e.metaKeyEvents)||n.set(t.key,t.nativeEvent))}else"Meta"===t.key&&(e.metaKeyEvents=new Map)},onClick(t){if((!t||nS(t.currentTarget,nO(t.nativeEvent)))&&t&&0===t.button&&!e.isTriggeringEvent&&!nA.isOpening){let r=!0;if(u&&t.preventDefault(),!e.ignoreEmulatedMouseEvents&&!e.isPressed&&("virtual"===e.pointerType||nx(t.nativeEvent))){let e=g(t,"virtual"),n=E(t,"virtual"),o=w(t,"virtual");A(t),r=e&&n&&o}else if(e.isPressed&&"keyboard"!==e.pointerType){let n=e.pointerType||t.nativeEvent.pointerType||"virtual";r=w(nR(t.currentTarget,t),n,!0),e.isOverTarget=!1,A(t),S(t)}e.ignoreEmulatedMouseEvents=!1,r&&t.stopPropagation()}}},r=t=>{var r,n,o;if(e.isPressed&&e.target&&nT(t,e.target)){nF(nO(t),t.key)&&t.preventDefault();let r=nO(t),o=nS(e.target,nO(t));w(nR(e.target,t),"keyboard",o),o&&x(t,e.target),v(),"Enter"!==t.key&&nI(e.target)&&nS(e.target,r)&&!t[nP]&&(t[nP]=!0,nA(e.target,t,!1)),e.isPressed=!1,null==(n=e.metaKeyEvents)||n.delete(t.key)}else if("Meta"===t.key&&(null==(r=e.metaKeyEvents)?void 0:r.size)){let t=e.metaKeyEvents;for(let r of(e.metaKeyEvents=void 0,t.values()))null==(o=e.target)||o.dispatchEvent(new KeyboardEvent("keyup",r))}};if("u">typeof PointerEvent){t.onPointerDown=t=>{var o;if(0!==t.button||!nS(t.currentTarget,nO(t.nativeEvent)))return;if(o=t.nativeEvent,!na()&&0===o.width&&0===o.height||1===o.width&&1===o.height&&0===o.pressure&&0===o.detail&&"mouse"===o.pointerType){e.pointerType="virtual";return}e.pointerType=t.pointerType;let i=!0;if(!e.isPressed){e.isPressed=!0,e.isOverTarget=!0,e.activePointerId=t.pointerId,e.target=t.currentTarget,d||function(e){if(nn()){if("default"===nf){let t=rQ(e);np=t.documentElement.style.webkitUserSelect,t.documentElement.style.webkitUserSelect="none"}nf="disabled"}else if(e instanceof HTMLElement||e instanceof SVGElement){let t="userSelect"in e.style?"userSelect":"webkitUserSelect";nh.set(e,e.style[t]),e.style[t]="none"}}(e.target),i=g(t,e.pointerType);let o=nO(t.nativeEvent);"releasePointerCapture"in o&&o.releasePointerCapture(t.pointerId),b(rQ(t.currentTarget),"pointerup",r,!1),b(rQ(t.currentTarget),"pointercancel",n,!1)}i&&t.stopPropagation()},t.onMouseDown=t=>{if(nS(t.currentTarget,nO(t.nativeEvent))&&0===t.button){if(l){let r=function(e){for(;e&&!rJ(e);)e=e.parentElement;let t=r0(e),r=t.document.activeElement;if(!r||r===e)return;r5=!0;let n=!1,o=e=>{(e.target===r||n)&&e.stopImmediatePropagation()},i=t=>{(t.target===r||n)&&(t.stopImmediatePropagation(),e||n||(n=!0,r1(r),s()))},a=t=>{(t.target===e||n)&&t.stopImmediatePropagation()},u=t=>{(t.target===e||n)&&(t.stopImmediatePropagation(),n||(n=!0,r1(r),s()))};t.addEventListener("blur",o,!0),t.addEventListener("focusout",i,!0),t.addEventListener("focusin",u,!0),t.addEventListener("focus",a,!0);let s=()=>{cancelAnimationFrame(l),t.removeEventListener("blur",o,!0),t.removeEventListener("focusout",i,!0),t.removeEventListener("focusin",u,!0),t.removeEventListener("focus",a,!0),r5=!1,n=!1},l=requestAnimationFrame(s);return s}(t.target);r&&e.disposables.push(r)}t.stopPropagation()}},t.onPointerUp=t=>{nS(t.currentTarget,nO(t.nativeEvent))&&"virtual"!==e.pointerType&&0===t.button&&E(t,e.pointerType||t.pointerType)},t.onPointerEnter=t=>{t.pointerId===e.activePointerId&&e.target&&!e.isOverTarget&&null!=e.pointerType&&(e.isOverTarget=!0,g(nR(e.target,t),e.pointerType))},t.onPointerLeave=t=>{t.pointerId===e.activePointerId&&e.target&&e.isOverTarget&&null!=e.pointerType&&(e.isOverTarget=!1,w(nR(e.target,t),e.pointerType,!1),O(t))};let r=t=>{if(t.pointerId===e.activePointerId&&e.isPressed&&0===t.button&&e.target){if(nS(e.target,nO(t))&&null!=e.pointerType){let r=!1,n=setTimeout(()=>{e.isPressed&&e.target instanceof HTMLElement&&(r?S(t):(r1(e.target),e.target.click()))},80);b(t.currentTarget,"click",()=>r=!0,!0),e.disposables.push(()=>clearTimeout(n))}else S(t);e.isOverTarget=!1}},n=e=>{S(e)};t.onDragStart=e=>{nS(e.currentTarget,nO(e.nativeEvent))&&S(e)}}return t},[b,u,l,v,d,S,O,w,g,E,A,x]);return(0,em.useEffect)(()=>{let e=null==f?void 0:f.current;e&&e instanceof r0(e).Element&&"auto"===r0(e).getComputedStyle(e).touchAction&&(e.style.touchAction="pan-x pan-y pinch-zoom")},[f]),(0,em.useEffect)(()=>{let e=y.current;return()=>{var t;for(let r of(d||nm(null!=(t=e.target)?t:void 0),e.disposables))r();e.disposables=[]}},[d]),{isPressed:s||h,pressProps:rk(p,D)}}function nI(e){return"A"===e.tagName&&e.hasAttribute("href")}function nT(e,t){let{key:r,code:n}=e,o=t.getAttribute("role");return("Enter"===r||" "===r||"Spacebar"===r||"Space"===n)&&!(t instanceof r0(t).HTMLInputElement&&!nM(t,r)||t instanceof r0(t).HTMLTextAreaElement||t.isContentEditable)&&!(("link"===o||!o&&nI(t))&&"Enter"!==r)}function nR(e,t){let r=t.clientX,n=t.clientY;return{currentTarget:e,shiftKey:t.shiftKey,ctrlKey:t.ctrlKey,metaKey:t.metaKey,altKey:t.altKey,clientX:r,clientY:n}}function nF(e,t){return e instanceof HTMLInputElement?!nM(e,t):!(e instanceof HTMLInputElement)&&(e instanceof HTMLButtonElement?"submit"!==e.type&&"reset"!==e.type:!nI(e))}let nN=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function nM(e,t){return"checkbox"===e.type||"radio"===e.type?" "===t:nN.has(e.type)}let nB=null,nL=new Set,nV=new Map,nU=!1,n$=!1,nW={Tab:!0,Escape:!0};function nz(e,t){for(let r of nL)r(e,t)}function nK(e){nU=!0,e.metaKey||!ne()&&e.altKey||e.ctrlKey||"Control"===e.key||"Shift"===e.key||"Meta"===e.key||(nB="keyboard",nz("keyboard",e))}function nH(e){nB="pointer",("mousedown"===e.type||"pointerdown"===e.type)&&(nU=!0,nz("pointer",e))}function nG(e){nx(e)&&(nU=!0,nB="virtual")}function nq(e){e.target!==window&&e.target!==document&&!r5&&e.isTrusted&&(nU||n$||(nB="virtual",nz("virtual",e)),nU=!1,n$=!1)}function nZ(){r5||(nU=!1,n$=!0)}function nY(e){if("u"<typeof window||nV.get(r0(e)))return;let t=r0(e),r=rQ(e),n=t.HTMLElement.prototype.focus;t.HTMLElement.prototype.focus=function(){nU=!0,n.apply(this,arguments)},r.addEventListener("keydown",nK,!0),r.addEventListener("keyup",nK,!0),r.addEventListener("click",nG,!0),t.addEventListener("focus",nq,!0),t.addEventListener("blur",nZ,!1),"u">typeof PointerEvent&&(r.addEventListener("pointerdown",nH,!0),r.addEventListener("pointermove",nH,!0),r.addEventListener("pointerup",nH,!0)),t.addEventListener("beforeunload",()=>{nJ(e)},{once:!0}),nV.set(t,{focus:n})}let nJ=(e,t)=>{let r=r0(e),n=rQ(e);t&&n.removeEventListener("DOMContentLoaded",t),nV.has(r)&&(r.HTMLElement.prototype.focus=nV.get(r).focus,n.removeEventListener("keydown",nK,!0),n.removeEventListener("keyup",nK,!0),n.removeEventListener("click",nG,!0),r.removeEventListener("focus",nq,!0),r.removeEventListener("blur",nZ,!1),"u">typeof PointerEvent&&(n.removeEventListener("pointerdown",nH,!0),n.removeEventListener("pointermove",nH,!0),n.removeEventListener("pointerup",nH,!0)),nV.delete(r))};function nX(){return"pointer"!==nB}"u">typeof document&&("loading"!==(u=rQ(void 0)).readyState?nY(void 0):u.addEventListener("DOMContentLoaded",()=>{nY(void 0)}));let nQ=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function n0(e){let t=rQ(e),r=((e=document)=>e.activeElement)(t);"virtual"===nB?nd(()=>{((e=document)=>e.activeElement)(t)===r&&e.isConnected&&r1(e)}):r1(e)}function n1(e){let{isDisabled:t,onFocus:r,onBlur:n,onFocusChange:o}=e,i=(0,em.useCallback)(e=>{if(e.target===e.currentTarget)return n&&n(e),o&&o(!1),!0},[n,o]),a=r6(i),u=(0,em.useCallback)(e=>{let t=rQ(e.target),n=t?((e=document)=>e.activeElement)(t):((e=document)=>e.activeElement)();e.target===e.currentTarget&&n===nO(e.nativeEvent)&&(r&&r(e),o&&o(!0),a(e))},[o,r,a]);return{focusProps:{onFocus:!t&&(r||o||n)?u:void 0,onBlur:!t&&(n||o)?i:void 0}}}function n2(e){if(!e)return;let t=!0;return r=>{e({...r,preventDefault(){r.preventDefault()},isDefaultPrevented:()=>r.isDefaultPrevented(),stopPropagation(){t=!0},continuePropagation(){t=!1},isPropagationStopped:()=>t}),t&&r.stopPropagation()}}let n3=ey().createContext(null);function n4(e,t){let{focusProps:r}=n1(e),{keyboardProps:n}={keyboardProps:e.isDisabled?{}:{onKeyDown:n2(e.onKeyDown),onKeyUp:n2(e.onKeyUp)}},o=rk(r,n),i=function(e){let t=(0,em.useContext)(n3)||{};nw(t,e);let{ref:r,...n}=t;return n}(t),a=e.isDisabled?{}:i,u=(0,em.useRef)(e.autoFocus);(0,em.useEffect)(()=>{u.current&&t.current&&n0(t.current),u.current=!1},[t]);let s=e.excludeFromTabOrder?-1:0;return e.isDisabled&&(s=void 0),{focusableProps:rk({...o,tabIndex:s},a)}}function n6(e){let{isDisabled:t,onBlurWithin:r,onFocusWithin:n,onFocusWithinChange:o}=e,i=(0,em.useRef)({isFocusWithin:!1}),{addGlobalListener:a,removeAllGlobalListeners:u}=nE(),s=(0,em.useCallback)(e=>{e.currentTarget.contains(e.target)&&i.current.isFocusWithin&&!e.currentTarget.contains(e.relatedTarget)&&(i.current.isFocusWithin=!1,u(),r&&r(e),o&&o(!1))},[r,o,i,u]),l=r6(s),c=(0,em.useCallback)(e=>{if(!e.currentTarget.contains(e.target))return;let t=rQ(e.target),r=((e=document)=>e.activeElement)(t);if(!i.current.isFocusWithin&&r===nO(e.nativeEvent)){n&&n(e),o&&o(!0),i.current.isFocusWithin=!0,l(e);let r=e.currentTarget;a(t,"focus",e=>{if(i.current.isFocusWithin&&!nS(r,e.target)){let n=new t.defaultView.FocusEvent("blur",{relatedTarget:e.target});r4(n,r),s(r3(n))}},{capture:!0})}},[n,o,l,a,s]);return t?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:c,onBlur:s}}}function n5(e={}){var t;let{autoFocus:r=!1,isTextInput:n,within:o}=e,i=(0,em.useRef)({isFocused:!1,isFocusVisible:r||nX()}),[a,u]=(0,em.useState)(!1),[s,l]=(0,em.useState)(()=>i.current.isFocused&&i.current.isFocusVisible),c=(0,em.useCallback)(()=>l(i.current.isFocused&&i.current.isFocusVisible),[]),d=(0,em.useCallback)(e=>{i.current.isFocused=e,u(e),c()},[c]);t={isTextInput:n},nY(),(0,em.useEffect)(()=>{let e=(e,r)=>{var n;let o,a,u,s,l;n=!!(null==t?void 0:t.isTextInput),o=rQ(null==r?void 0:r.target),a="u">typeof window?r0(null==r?void 0:r.target).HTMLInputElement:HTMLInputElement,u="u">typeof window?r0(null==r?void 0:r.target).HTMLTextAreaElement:HTMLTextAreaElement,s="u">typeof window?r0(null==r?void 0:r.target).HTMLElement:HTMLElement,l="u">typeof window?r0(null==r?void 0:r.target).KeyboardEvent:KeyboardEvent,(n=n||o.activeElement instanceof a&&!nQ.has(o.activeElement.type)||o.activeElement instanceof u||o.activeElement instanceof s&&o.activeElement.isContentEditable)&&"keyboard"===e&&r instanceof l&&!nW[r.key]||(e=>{i.current.isFocusVisible=e,c()})(nX())};return nL.add(e),()=>{nL.delete(e)}},[]);let{focusProps:f}=n1({isDisabled:o,onFocusChange:d}),{focusWithinProps:p}=n6({isDisabled:!o,onFocusWithinChange:d});return{isFocused:a,isFocusVisible:s,focusProps:o?p:f}}ey().forwardRef(function(e,t){let{children:r,...n}=e,o=rp(t),i={...n,ref:o};return ey().createElement(n3.Provider,{value:i},r)});let n8=!1,n7=0;function n9(e){"touch"===e.pointerType&&(n8=!0,setTimeout(()=>{n8=!1},50))}function oe(){if("u">typeof document)return"u">typeof PointerEvent&&document.addEventListener("pointerup",n9),n7++,()=>{!(--n7>0)&&"u">typeof PointerEvent&&document.removeEventListener("pointerup",n9)}}function ot(e){let{onHoverStart:t,onHoverChange:r,onHoverEnd:n,isDisabled:o}=e,[i,a]=(0,em.useState)(!1),u=(0,em.useRef)({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;(0,em.useEffect)(oe,[]);let{addGlobalListener:s,removeAllGlobalListeners:l}=nE(),{hoverProps:c,triggerHoverEnd:d}=(0,em.useMemo)(()=>{let e=(e,t)=>{let o=u.target;u.pointerType="",u.target=null,"touch"!==t&&u.isHovered&&o&&(u.isHovered=!1,l(),n&&n({type:"hoverend",target:o,pointerType:t}),r&&r(!1),a(!1))},i={};return"u">typeof PointerEvent&&(i.onPointerEnter=n=>{n8&&"mouse"===n.pointerType||((n,i)=>{if(u.pointerType=i,o||"touch"===i||u.isHovered||!n.currentTarget.contains(n.target))return;u.isHovered=!0;let l=n.currentTarget;u.target=l,s(rQ(n.target),"pointerover",t=>{u.isHovered&&u.target&&!nS(u.target,t.target)&&e(t,t.pointerType)},{capture:!0}),t&&t({type:"hoverstart",target:l,pointerType:i}),r&&r(!0),a(!0)})(n,n.pointerType)},i.onPointerLeave=t=>{!o&&t.currentTarget.contains(t.target)&&e(t,t.pointerType)}),{hoverProps:i,triggerHoverEnd:e}},[t,r,n,o,u,s,l]);return(0,em.useEffect)(()=>{o&&d({currentTarget:u.target},u.pointerType)},[o]),{hoverProps:c,isHovered:i}}if("u">typeof HTMLTemplateElement){let e=Object.getOwnPropertyDescriptor(Node.prototype,"firstChild").get;Object.defineProperty(HTMLTemplateElement.prototype,"firstChild",{configurable:!0,enumerable:!0,get:function(){return this.dataset.reactAriaHidden?this.content.firstChild:e.call(this)}})}let or=(0,em.createContext)(!1);function on(e){let t=(t,r)=>(0,em.useContext)(or)?null:e(t,r);return t.displayName=e.displayName||e.name,(0,em.forwardRef)(t)}let oo=new Set(["form","formAction","formEncType","formMethod","formNoValidate","formTarget","name","value"]),oi=(0,em.createContext)({}),oa=on(function(e,t){var r;[e,t]=rN(e,t,oi);let n=((r=e).isPending&&(r.onPress=void 0,r.onPressStart=void 0,r.onPressEnd=void 0,r.onPressChange=void 0,r.onPressUp=void 0,r.onKeyDown=void 0,r.onKeyUp=void 0,r.onClick=void 0,r.href=void 0),e=r),{isPending:o}=n,{buttonProps:i,isPressed:a}=function(e,t){let r,{elementType:n="button",isDisabled:o,onPress:i,onPressStart:a,onPressEnd:u,onPressUp:s,onPressChange:l,preventFocusOnPress:c,allowFocusWhenDisabled:d,onClick:f,href:p,target:h,rel:m,type:y="button"}=e;r="button"===n?{type:y,disabled:o}:{role:"button",href:"a"!==n||o?void 0:p,target:"a"===n?h:void 0,type:"input"===n?y:void 0,disabled:"input"===n?o:void 0,"aria-disabled":o&&"input"!==n?o:void 0,rel:"a"===n?m:void 0};let{pressProps:b,isPressed:v}=nk({onPressStart:a,onPressEnd:u,onPressChange:l,onPress:i,onPressUp:s,onClick:f,isDisabled:o,preventFocusOnPress:c,ref:t}),{focusableProps:g}=n4(e,t);d&&(g.tabIndex=o?-1:g.tabIndex);let w=rk(g,b,rG(e,{labelable:!0}));return{isPressed:v,buttonProps:rk(r,w,{"aria-haspopup":e["aria-haspopup"],"aria-expanded":e["aria-expanded"],"aria-controls":e["aria-controls"],"aria-pressed":e["aria-pressed"],"aria-current":e["aria-current"]})}}(e,t),{focusProps:u,isFocused:s,isFocusVisible:l}=n5(e),{hoverProps:c,isHovered:d}=ot({...e,isDisabled:e.isDisabled||o}),f={isHovered:d,isPressed:(n.isPressed||a)&&!o,isFocused:s,isFocusVisible:l,isDisabled:e.isDisabled||!1,isPending:null!=o&&o},p=rR({...e,values:f,defaultClassName:"react-aria-Button"}),h=rj(i.id),m=rj(),y=i["aria-labelledby"];o&&(y?y=`${y} ${m}`:i["aria-label"]&&(y=`${h} ${m}`));let b=(0,em.useRef)(o);return(0,em.useEffect)(()=>{let e={"aria-labelledby":y||h};!b.current&&s&&o?rU(e,"assertive"):b.current&&s&&!o&&rU(e,"assertive"),b.current=o},[o,s,y,h]),ey().createElement("button",{...rG(e,{propNames:oo}),...rk(i,u,c),...p,type:"submit"===i.type&&o?"button":i.type,id:h,ref:t,"aria-labelledby":y,slot:e.slot||void 0,"aria-disabled":o?"true":i["aria-disabled"],"data-disabled":e.isDisabled||void 0,"data-pressed":f.isPressed||void 0,"data-hovered":d||void 0,"data-focused":s||void 0,"data-pending":o||void 0,"data-focus-visible":l||void 0},ey().createElement(rL.Provider,{value:{id:m}},p.children))});(0,em.createContext)(null),(0,em.createContext)(null),(0,em.createContext)(null),(0,em.createContext)(null),(0,em.createContext)(null);let ou=(0,em.createContext)({}),os=(0,em.createContext)({}),ol=(0,em.forwardRef)(function(e,t){[e,t]=rN(e,t,os);let{elementType:r="span",...n}=e;return ey().createElement(r,{className:"react-aria-Text",...n,ref:t})}),oc=new Set(["Arab","Syrc","Samr","Mand","Thaa","Mend","Nkoo","Adlm","Rohg","Hebr"]),od=new Set(["ae","ar","arc","bcc","bqi","ckb","dv","fa","glk","he","ku","mzn","nqo","pnb","ps","sd","ug","ur","yi"]);function of(e){if(Intl.Locale){let t=new Intl.Locale(e).maximize(),r="function"==typeof t.getTextInfo?t.getTextInfo():t.textInfo;if(r)return"rtl"===r.direction;if(t.script)return oc.has(t.script)}let t=e.split("-")[0];return od.has(t)}let op=Symbol.for("react-aria.i18n.locale");function oh(){let e="u">typeof window&&window[op]||"u">typeof navigator&&(navigator.language||navigator.userLanguage)||"en-US";try{Intl.DateTimeFormat.supportedLocalesOf([e])}catch{e="en-US"}return{locale:e,direction:of(e)?"rtl":"ltr"}}let om=oh(),oy=new Set;function ob(){for(let e of(om=oh(),oy))e(om)}function ov(){let e=rx(),[t,r]=(0,em.useState)(om);return((0,em.useEffect)(()=>(0===oy.size&&window.addEventListener("languagechange",ob),oy.add(r),()=>{oy.delete(r),0===oy.size&&window.removeEventListener("languagechange",ob)}),[]),e)?{locale:"en-US",direction:"ltr"}:t}let og=ey().createContext(null);function ow(e){let{locale:t,children:r}=e,n=ov(),o=ey().useMemo(()=>t?{locale:t,direction:of(t)?"rtl":"ltr"}:n,[n,t]);return ey().createElement(og.Provider,{value:o},r)}function oE(){let e=ov();return(0,em.useContext)(og)||e}var oS={};function oO(e,t){return e-t*Math.floor(e/t)}function oA(e,t,r,n){let o=(t=oD(e,t))-1,i=-2;return r<=2?i=0:ox(t)&&(i=-1),1721425+365*o+Math.floor(o/4)-Math.floor(o/100)+Math.floor(o/400)+Math.floor((367*r-362)/12+i+n)}function ox(e){return e%4==0&&(e%100!=0||e%400==0)}function oD(e,t){return"BC"===e?1-t:t}function o_(e){let t="AD";return e<=0&&(t="BC",e=1-e),[t,e]}oS={"ar-AE":{dateRange:e=>`${e.startDate} \u{625}\u{644}\u{649} ${e.endDate}`,dateSelected:e=>`${e.date} \u{627}\u{644}\u{645}\u{62D}\u{62F}\u{62F}`,finishRangeSelectionPrompt:"انقر لإنهاء عملية تحديد نطاق التاريخ",maximumDate:"آخر تاريخ متاح",minimumDate:"أول تاريخ متاح",next:"التالي",previous:"السابق",selectedDateDescription:e=>`\u{62A}\u{627}\u{631}\u{64A}\u{62E} \u{645}\u{62D}\u{62F}\u{62F}: ${e.date}`,selectedRangeDescription:e=>`\u{627}\u{644}\u{645}\u{62F}\u{649} \u{627}\u{644}\u{632}\u{645}\u{646}\u{64A} \u{627}\u{644}\u{645}\u{62D}\u{62F}\u{62F}: ${e.dateRange}`,startRangeSelectionPrompt:"انقر لبدء عملية تحديد نطاق التاريخ",todayDate:e=>`\u{627}\u{644}\u{64A}\u{648}\u{645}\u{60C} ${e.date}`,todayDateSelected:e=>`\u{627}\u{644}\u{64A}\u{648}\u{645}\u{60C} ${e.date} \u{645}\u{62D}\u{62F}\u{62F}`},"bg-BG":{dateRange:e=>`${e.startDate} \u{434}\u{43E} ${e.endDate}`,dateSelected:e=>`\u{418}\u{437}\u{431}\u{440}\u{430}\u{43D}\u{43E} \u{435} ${e.date}`,finishRangeSelectionPrompt:"Натиснете, за да довършите избора на времеви интервал",maximumDate:"Последна налична дата",minimumDate:"Първа налична дата",next:"Напред",previous:"Назад",selectedDateDescription:e=>`\u{418}\u{437}\u{431}\u{440}\u{430}\u{43D}\u{430} \u{434}\u{430}\u{442}\u{430}: ${e.date}`,selectedRangeDescription:e=>`\u{418}\u{437}\u{431}\u{440}\u{430}\u{43D} \u{434}\u{438}\u{430}\u{43F}\u{430}\u{437}\u{43E}\u{43D}: ${e.dateRange}`,startRangeSelectionPrompt:"Натиснете, за да пристъпите към избора на времеви интервал",todayDate:e=>`\u{414}\u{43D}\u{435}\u{441}, ${e.date}`,todayDateSelected:e=>`\u{414}\u{43D}\u{435}\u{441}, ${e.date} \u{441}\u{430} \u{438}\u{437}\u{431}\u{440}\u{430}\u{43D}\u{438}`},"cs-CZ":{dateRange:e=>`${e.startDate} a\u{17E} ${e.endDate}`,dateSelected:e=>`Vybr\xe1no ${e.date}`,finishRangeSelectionPrompt:"Kliknut\xedm dokonč\xedte v\xfdběr rozsahu dat",maximumDate:"Posledn\xed dostupn\xe9 datum",minimumDate:"Prvn\xed dostupn\xe9 datum",next:"Dalš\xed",previous:"Předchoz\xed",selectedDateDescription:e=>`Vybran\xe9 datum: ${e.date}`,selectedRangeDescription:e=>`Vybran\xe9 obdob\xed: ${e.dateRange}`,startRangeSelectionPrompt:"Kliknut\xedm zah\xe1j\xedte v\xfdběr rozsahu dat",todayDate:e=>`Dnes, ${e.date}`,todayDateSelected:e=>`Dnes, vybr\xe1no ${e.date}`},"da-DK":{dateRange:e=>`${e.startDate} til ${e.endDate}`,dateSelected:e=>`${e.date} valgt`,finishRangeSelectionPrompt:"Klik for at fuldf\xf8re valg af datoomr\xe5de",maximumDate:"Sidste ledige dato",minimumDate:"F\xf8rste ledige dato",next:"N\xe6ste",previous:"Forrige",selectedDateDescription:e=>`Valgt dato: ${e.date}`,selectedRangeDescription:e=>`Valgt interval: ${e.dateRange}`,startRangeSelectionPrompt:"Klik for at starte valg af datoomr\xe5de",todayDate:e=>`I dag, ${e.date}`,todayDateSelected:e=>`I dag, ${e.date} valgt`},"de-DE":{dateRange:e=>`${e.startDate} bis ${e.endDate}`,dateSelected:e=>`${e.date} ausgew\xe4hlt`,finishRangeSelectionPrompt:"Klicken, um die Auswahl des Datumsbereichs zu beenden",maximumDate:"Letztes verf\xfcgbares Datum",minimumDate:"Erstes verf\xfcgbares Datum",next:"Weiter",previous:"Zur\xfcck",selectedDateDescription:e=>`Ausgew\xe4hltes Datum: ${e.date}`,selectedRangeDescription:e=>`Ausgew\xe4hlter Bereich: ${e.dateRange}`,startRangeSelectionPrompt:"Klicken, um die Auswahl des Datumsbereichs zu beginnen",todayDate:e=>`Heute, ${e.date}`,todayDateSelected:e=>`Heute, ${e.date} ausgew\xe4hlt`},"el-GR":{dateRange:e=>`${e.startDate} \u{3AD}\u{3C9}\u{3C2} ${e.endDate}`,dateSelected:e=>`\u{395}\u{3C0}\u{3B9}\u{3BB}\u{3AD}\u{3C7}\u{3B8}\u{3B7}\u{3BA}\u{3B5} ${e.date}`,finishRangeSelectionPrompt:"Κάντε κλικ για να ολοκληρώσετε την επιλογή εύρους ημερομηνιών",maximumDate:"Τελευταία διαθέσιμη ημερομηνία",minimumDate:"Πρώτη διαθέσιμη ημερομηνία",next:"Επόμενο",previous:"Προηγούμενο",selectedDateDescription:e=>`\u{395}\u{3C0}\u{3B9}\u{3BB}\u{3B5}\u{3B3}\u{3BC}\u{3AD}\u{3BD}\u{3B7} \u{3B7}\u{3BC}\u{3B5}\u{3C1}\u{3BF}\u{3BC}\u{3B7}\u{3BD}\u{3AF}\u{3B1}: ${e.date}`,selectedRangeDescription:e=>`\u{395}\u{3C0}\u{3B9}\u{3BB}\u{3B5}\u{3B3}\u{3BC}\u{3AD}\u{3BD}\u{3BF} \u{3B5}\u{3CD}\u{3C1}\u{3BF}\u{3C2}: ${e.dateRange}`,startRangeSelectionPrompt:"Κάντε κλικ για να ξεκινήσετε την επιλογή εύρους ημερομηνιών",todayDate:e=>`\u{3A3}\u{3AE}\u{3BC}\u{3B5}\u{3C1}\u{3B1}, ${e.date}`,todayDateSelected:e=>`\u{3A3}\u{3AE}\u{3BC}\u{3B5}\u{3C1}\u{3B1}, \u{3B5}\u{3C0}\u{3B9}\u{3BB}\u{3AD}\u{3C7}\u{3C4}\u{3B7}\u{3BA}\u{3B5} ${e.date}`},"en-US":{previous:"Previous",next:"Next",selectedDateDescription:e=>`Selected Date: ${e.date}`,selectedRangeDescription:e=>`Selected Range: ${e.dateRange}`,todayDate:e=>`Today, ${e.date}`,todayDateSelected:e=>`Today, ${e.date} selected`,dateSelected:e=>`${e.date} selected`,startRangeSelectionPrompt:"Click to start selecting date range",finishRangeSelectionPrompt:"Click to finish selecting date range",minimumDate:"First available date",maximumDate:"Last available date",dateRange:e=>`${e.startDate} to ${e.endDate}`},"es-ES":{dateRange:e=>`${e.startDate} a ${e.endDate}`,dateSelected:e=>`${e.date} seleccionado`,finishRangeSelectionPrompt:"Haga clic para terminar de seleccionar rango de fechas",maximumDate:"\xdaltima fecha disponible",minimumDate:"Primera fecha disponible",next:"Siguiente",previous:"Anterior",selectedDateDescription:e=>`Fecha seleccionada: ${e.date}`,selectedRangeDescription:e=>`Intervalo seleccionado: ${e.dateRange}`,startRangeSelectionPrompt:"Haga clic para comenzar a seleccionar un rango de fechas",todayDate:e=>`Hoy, ${e.date}`,todayDateSelected:e=>`Hoy, ${e.date} seleccionado`},"et-EE":{dateRange:e=>`${e.startDate} kuni ${e.endDate}`,dateSelected:e=>`${e.date} valitud`,finishRangeSelectionPrompt:"Kl\xf5psake kuup\xe4evavahemiku valimise l\xf5petamiseks",maximumDate:"Viimane saadaolev kuup\xe4ev",minimumDate:"Esimene saadaolev kuup\xe4ev",next:"J\xe4rgmine",previous:"Eelmine",selectedDateDescription:e=>`Valitud kuup\xe4ev: ${e.date}`,selectedRangeDescription:e=>`Valitud vahemik: ${e.dateRange}`,startRangeSelectionPrompt:"Kl\xf5psake kuup\xe4evavahemiku valimiseks",todayDate:e=>`T\xe4na, ${e.date}`,todayDateSelected:e=>`T\xe4na, ${e.date} valitud`},"fi-FI":{dateRange:e=>`${e.startDate} \u{2013} ${e.endDate}`,dateSelected:e=>`${e.date} valittu`,finishRangeSelectionPrompt:"Lopeta p\xe4iv\xe4m\xe4\xe4r\xe4alueen valinta napsauttamalla t\xe4t\xe4.",maximumDate:"Viimeinen varattavissa oleva p\xe4iv\xe4m\xe4\xe4r\xe4",minimumDate:"Ensimm\xe4inen varattavissa oleva p\xe4iv\xe4m\xe4\xe4r\xe4",next:"Seuraava",previous:"Edellinen",selectedDateDescription:e=>`Valittu p\xe4iv\xe4m\xe4\xe4r\xe4: ${e.date}`,selectedRangeDescription:e=>`Valittu aikav\xe4li: ${e.dateRange}`,startRangeSelectionPrompt:"Aloita p\xe4iv\xe4m\xe4\xe4r\xe4alueen valinta napsauttamalla t\xe4t\xe4.",todayDate:e=>`T\xe4n\xe4\xe4n, ${e.date}`,todayDateSelected:e=>`T\xe4n\xe4\xe4n, ${e.date} valittu`},"fr-FR":{dateRange:e=>`${e.startDate} \xe0 ${e.endDate}`,dateSelected:e=>`${e.date} s\xe9lectionn\xe9`,finishRangeSelectionPrompt:"Cliquer pour finir de s\xe9lectionner la plage de dates",maximumDate:"Derni\xe8re date disponible",minimumDate:"Premi\xe8re date disponible",next:"Suivant",previous:"Pr\xe9c\xe9dent",selectedDateDescription:e=>`Date s\xe9lectionn\xe9e\xa0: ${e.date}`,selectedRangeDescription:e=>`Plage s\xe9lectionn\xe9e\xa0: ${e.dateRange}`,startRangeSelectionPrompt:"Cliquer pour commencer \xe0 s\xe9lectionner la plage de dates",todayDate:e=>`Aujourd'hui, ${e.date}`,todayDateSelected:e=>`Aujourd\u{2019}hui, ${e.date} s\xe9lectionn\xe9`},"he-IL":{dateRange:e=>`${e.startDate} \u{5E2}\u{5D3} ${e.endDate}`,dateSelected:e=>`${e.date} \u{5E0}\u{5D1}\u{5D7}\u{5E8}`,finishRangeSelectionPrompt:"חץ כדי לסיים את בחירת טווח התאריכים",maximumDate:"תאריך פנוי אחרון",minimumDate:"תאריך פנוי ראשון",next:"הבא",previous:"הקודם",selectedDateDescription:e=>`\u{5EA}\u{5D0}\u{5E8}\u{5D9}\u{5DA} \u{5E0}\u{5D1}\u{5D7}\u{5E8}: ${e.date}`,selectedRangeDescription:e=>`\u{5D8}\u{5D5}\u{5D5}\u{5D7} \u{5E0}\u{5D1}\u{5D7}\u{5E8}: ${e.dateRange}`,startRangeSelectionPrompt:"לחץ כדי להתחיל בבחירת טווח התאריכים",todayDate:e=>`\u{5D4}\u{5D9}\u{5D5}\u{5DD}, ${e.date}`,todayDateSelected:e=>`\u{5D4}\u{5D9}\u{5D5}\u{5DD}, ${e.date} \u{5E0}\u{5D1}\u{5D7}\u{5E8}`},"hr-HR":{dateRange:e=>`${e.startDate} do ${e.endDate}`,dateSelected:e=>`${e.date} odabran`,finishRangeSelectionPrompt:"Kliknite da dovršite raspon odabranih datuma",maximumDate:"Posljednji raspoloživi datum",minimumDate:"Prvi raspoloživi datum",next:"Sljedeći",previous:"Prethodni",selectedDateDescription:e=>`Odabrani datum: ${e.date}`,selectedRangeDescription:e=>`Odabrani raspon: ${e.dateRange}`,startRangeSelectionPrompt:"Kliknite da započnete raspon odabranih datuma",todayDate:e=>`Danas, ${e.date}`,todayDateSelected:e=>`Danas, odabran ${e.date}`},"hu-HU":{dateRange:e=>`${e.startDate}\u{2013}${e.endDate}`,dateSelected:e=>`${e.date} kiv\xe1lasztva`,finishRangeSelectionPrompt:"Kattintson a d\xe1tumtartom\xe1ny kijel\xf6l\xe9s\xe9nek befejez\xe9s\xe9hez",maximumDate:"Utols\xf3 el\xe9rhető d\xe1tum",minimumDate:"Az első el\xe9rhető d\xe1tum",next:"K\xf6vetkező",previous:"Előző",selectedDateDescription:e=>`Kijel\xf6lt d\xe1tum: ${e.date}`,selectedRangeDescription:e=>`Kijel\xf6lt tartom\xe1ny: ${e.dateRange}`,startRangeSelectionPrompt:"Kattintson a d\xe1tumtartom\xe1ny kijel\xf6l\xe9s\xe9nek ind\xedt\xe1s\xe1hoz",todayDate:e=>`Ma, ${e.date}`,todayDateSelected:e=>`Ma, ${e.date} kijel\xf6lve`},"it-IT":{dateRange:e=>`Da ${e.startDate} a ${e.endDate}`,dateSelected:e=>`${e.date} selezionata`,finishRangeSelectionPrompt:"Fai clic per completare la selezione dell’intervallo di date",maximumDate:"Ultima data disponibile",minimumDate:"Prima data disponibile",next:"Successivo",previous:"Precedente",selectedDateDescription:e=>`Data selezionata: ${e.date}`,selectedRangeDescription:e=>`Intervallo selezionato: ${e.dateRange}`,startRangeSelectionPrompt:"Fai clic per selezionare l’intervallo di date",todayDate:e=>`Oggi, ${e.date}`,todayDateSelected:e=>`Oggi, ${e.date} selezionata`},"ja-JP":{dateRange:e=>`${e.startDate} \u{304B}\u{3089} ${e.endDate}`,dateSelected:e=>`${e.date} \u{3092}\u{9078}\u{629E}`,finishRangeSelectionPrompt:"クリックして日付範囲の選択を終了",maximumDate:"最終利用可能日",minimumDate:"最初の利用可能日",next:"次へ",previous:"前へ",selectedDateDescription:e=>`\u{9078}\u{629E}\u{3057}\u{305F}\u{65E5}\u{4ED8} : ${e.date}`,selectedRangeDescription:e=>`\u{9078}\u{629E}\u{7BC4}\u{56F2} : ${e.dateRange}`,startRangeSelectionPrompt:"クリックして日付範囲の選択を開始",todayDate:e=>`\u{672C}\u{65E5}\u{3001}${e.date}`,todayDateSelected:e=>`\u{672C}\u{65E5}\u{3001}${e.date} \u{3092}\u{9078}\u{629E}`},"ko-KR":{dateRange:e=>`${e.startDate} ~ ${e.endDate}`,dateSelected:e=>`${e.date} \u{C120}\u{D0DD}\u{B428}`,finishRangeSelectionPrompt:"날짜 범위 선택을 완료하려면 클릭하십시오.",maximumDate:"마지막으로 사용 가능한 일자",minimumDate:"처음으로 사용 가능한 일자",next:"다음",previous:"이전",selectedDateDescription:e=>`\u{C120}\u{D0DD} \u{C77C}\u{C790}: ${e.date}`,selectedRangeDescription:e=>`\u{C120}\u{D0DD} \u{BC94}\u{C704}: ${e.dateRange}`,startRangeSelectionPrompt:"날짜 범위 선택을 시작하려면 클릭하십시오.",todayDate:e=>`\u{C624}\u{B298}, ${e.date}`,todayDateSelected:e=>`\u{C624}\u{B298}, ${e.date} \u{C120}\u{D0DD}\u{B428}`},"lt-LT":{dateRange:e=>`Nuo ${e.startDate} iki ${e.endDate}`,dateSelected:e=>`Pasirinkta ${e.date}`,finishRangeSelectionPrompt:"Spustelėkite, kad baigtumėte pasirinkti datų intervalą",maximumDate:"Paskutinė galima data",minimumDate:"Pirmoji galima data",next:"Paskesnis",previous:"Ankstesnis",selectedDateDescription:e=>`Pasirinkta data: ${e.date}`,selectedRangeDescription:e=>`Pasirinktas intervalas: ${e.dateRange}`,startRangeSelectionPrompt:"Spustelėkite, kad pradėtumėte pasirinkti datų intervalą",todayDate:e=>`\u{160}iandien, ${e.date}`,todayDateSelected:e=>`\u{160}iandien, pasirinkta ${e.date}`},"lv-LV":{dateRange:e=>`No ${e.startDate} l\u{12B}dz ${e.endDate}`,dateSelected:e=>`Atlas\u{12B}ts: ${e.date}`,finishRangeSelectionPrompt:"Noklikšķiniet, lai pabeigtu datumu diapazona atlasi",maximumDate:"Pēdējais pieejamais datums",minimumDate:"Pirmais pieejamais datums",next:"Tālāk",previous:"Atpakaļ",selectedDateDescription:e=>`Atlas\u{12B}tais datums: ${e.date}`,selectedRangeDescription:e=>`Atlas\u{12B}tais diapazons: ${e.dateRange}`,startRangeSelectionPrompt:"Noklikšķiniet, lai sāktu datumu diapazona atlasi",todayDate:e=>`\u{160}odien, ${e.date}`,todayDateSelected:e=>`Atlas\u{12B}ta \u{161}odiena, ${e.date}`},"nb-NO":{dateRange:e=>`${e.startDate} til ${e.endDate}`,dateSelected:e=>`${e.date} valgt`,finishRangeSelectionPrompt:"Klikk for \xe5 fullf\xf8re valg av datoomr\xe5de",maximumDate:"Siste tilgjengelige dato",minimumDate:"F\xf8rste tilgjengelige dato",next:"Neste",previous:"Forrige",selectedDateDescription:e=>`Valgt dato: ${e.date}`,selectedRangeDescription:e=>`Valgt omr\xe5de: ${e.dateRange}`,startRangeSelectionPrompt:"Klikk for \xe5 starte valg av datoomr\xe5de",todayDate:e=>`I dag, ${e.date}`,todayDateSelected:e=>`I dag, ${e.date} valgt`},"nl-NL":{dateRange:e=>`${e.startDate} tot ${e.endDate}`,dateSelected:e=>`${e.date} geselecteerd`,finishRangeSelectionPrompt:"Klik om de selectie van het datumbereik te voltooien",maximumDate:"Laatste beschikbare datum",minimumDate:"Eerste beschikbare datum",next:"Volgende",previous:"Vorige",selectedDateDescription:e=>`Geselecteerde datum: ${e.date}`,selectedRangeDescription:e=>`Geselecteerd bereik: ${e.dateRange}`,startRangeSelectionPrompt:"Klik om het datumbereik te selecteren",todayDate:e=>`Vandaag, ${e.date}`,todayDateSelected:e=>`Vandaag, ${e.date} geselecteerd`},"pl-PL":{dateRange:e=>`${e.startDate} do ${e.endDate}`,dateSelected:e=>`Wybrano ${e.date}`,finishRangeSelectionPrompt:"Kliknij, aby zakończyć wyb\xf3r zakresu dat",maximumDate:"Ostatnia dostępna data",minimumDate:"Pierwsza dostępna data",next:"Dalej",previous:"Wstecz",selectedDateDescription:e=>`Wybrana data: ${e.date}`,selectedRangeDescription:e=>`Wybrany zakres: ${e.dateRange}`,startRangeSelectionPrompt:"Kliknij, aby rozpocząć wyb\xf3r zakresu dat",todayDate:e=>`Dzisiaj, ${e.date}`,todayDateSelected:e=>`Dzisiaj wybrano ${e.date}`},"pt-BR":{dateRange:e=>`${e.startDate} a ${e.endDate}`,dateSelected:e=>`${e.date} selecionado`,finishRangeSelectionPrompt:"Clique para concluir a sele\xe7\xe3o do intervalo de datas",maximumDate:"\xdaltima data dispon\xedvel",minimumDate:"Primeira data dispon\xedvel",next:"Pr\xf3ximo",previous:"Anterior",selectedDateDescription:e=>`Data selecionada: ${e.date}`,selectedRangeDescription:e=>`Intervalo selecionado: ${e.dateRange}`,startRangeSelectionPrompt:"Clique para iniciar a sele\xe7\xe3o do intervalo de datas",todayDate:e=>`Hoje, ${e.date}`,todayDateSelected:e=>`Hoje, ${e.date} selecionado`},"pt-PT":{dateRange:e=>`${e.startDate} a ${e.endDate}`,dateSelected:e=>`${e.date} selecionado`,finishRangeSelectionPrompt:"Clique para terminar de selecionar o intervalo de datas",maximumDate:"\xdaltima data dispon\xedvel",minimumDate:"Primeira data dispon\xedvel",next:"Pr\xf3ximo",previous:"Anterior",selectedDateDescription:e=>`Data selecionada: ${e.date}`,selectedRangeDescription:e=>`Intervalo selecionado: ${e.dateRange}`,startRangeSelectionPrompt:"Clique para come\xe7ar a selecionar o intervalo de datas",todayDate:e=>`Hoje, ${e.date}`,todayDateSelected:e=>`Hoje, ${e.date} selecionado`},"ro-RO":{dateRange:e=>`De la ${e.startDate} p\xe2n\u{103} la ${e.endDate}`,dateSelected:e=>`${e.date} selectat\u{103}`,finishRangeSelectionPrompt:"Apăsaţi pentru a finaliza selecţia razei pentru dată",maximumDate:"Ultima dată disponibilă",minimumDate:"Prima dată disponibilă",next:"Următorul",previous:"\xcenainte",selectedDateDescription:e=>`Dat\u{103} selectat\u{103}: ${e.date}`,selectedRangeDescription:e=>`Interval selectat: ${e.dateRange}`,startRangeSelectionPrompt:"Apăsaţi pentru a \xeencepe selecţia razei pentru dată",todayDate:e=>`Ast\u{103}zi, ${e.date}`,todayDateSelected:e=>`Azi, ${e.date} selectat\u{103}`},"ru-RU":{dateRange:e=>`\u{421} ${e.startDate} \u{43F}\u{43E} ${e.endDate}`,dateSelected:e=>`\u{412}\u{44B}\u{431}\u{440}\u{430}\u{43D}\u{43E} ${e.date}`,finishRangeSelectionPrompt:"Щелкните, чтобы завершить выбор диапазона дат",maximumDate:"Последняя доступная дата",minimumDate:"Первая доступная дата",next:"Далее",previous:"Назад",selectedDateDescription:e=>`\u{412}\u{44B}\u{431}\u{440}\u{430}\u{43D}\u{43D}\u{430}\u{44F} \u{434}\u{430}\u{442}\u{430}: ${e.date}`,selectedRangeDescription:e=>`\u{412}\u{44B}\u{431}\u{440}\u{430}\u{43D}\u{43D}\u{44B}\u{439} \u{434}\u{438}\u{430}\u{43F}\u{430}\u{437}\u{43E}\u{43D}: ${e.dateRange}`,startRangeSelectionPrompt:"Щелкните, чтобы начать выбор диапазона дат",todayDate:e=>`\u{421}\u{435}\u{433}\u{43E}\u{434}\u{43D}\u{44F}, ${e.date}`,todayDateSelected:e=>`\u{421}\u{435}\u{433}\u{43E}\u{434}\u{43D}\u{44F}, \u{432}\u{44B}\u{431}\u{440}\u{430}\u{43D}\u{43E} ${e.date}`},"sk-SK":{dateRange:e=>`Od ${e.startDate} do ${e.endDate}`,dateSelected:e=>`Vybrat\xfd d\xe1tum ${e.date}`,finishRangeSelectionPrompt:"Kliknut\xedm dokonč\xedte v\xfdber rozsahu d\xe1tumov",maximumDate:"Posledn\xfd dostupn\xfd d\xe1tum",minimumDate:"Prv\xfd dostupn\xfd d\xe1tum",next:"Nasleduj\xface",previous:"Predch\xe1dzaj\xface",selectedDateDescription:e=>`Vybrat\xfd d\xe1tum: ${e.date}`,selectedRangeDescription:e=>`Vybrat\xfd rozsah: ${e.dateRange}`,startRangeSelectionPrompt:"Kliknut\xedm spust\xedte v\xfdber rozsahu d\xe1tumov",todayDate:e=>`Dnes ${e.date}`,todayDateSelected:e=>`Vybrat\xfd dne\u{161}n\xfd d\xe1tum ${e.date}`},"sl-SI":{dateRange:e=>`${e.startDate} do ${e.endDate}`,dateSelected:e=>`${e.date} izbrano`,finishRangeSelectionPrompt:"Kliknite za dokončanje izbire datumskega obsega",maximumDate:"Zadnji razpoložljivi datum",minimumDate:"Prvi razpoložljivi datum",next:"Naprej",previous:"Nazaj",selectedDateDescription:e=>`Izbrani datum: ${e.date}`,selectedRangeDescription:e=>`Izbrano obmo\u{10D}je: ${e.dateRange}`,startRangeSelectionPrompt:"Kliknite za začetek izbire datumskega obsega",todayDate:e=>`Danes, ${e.date}`,todayDateSelected:e=>`Danes, ${e.date} izbrano`},"sr-SP":{dateRange:e=>`${e.startDate} do ${e.endDate}`,dateSelected:e=>`${e.date} izabran`,finishRangeSelectionPrompt:"Kliknite da dovršite opseg izabranih datuma",maximumDate:"Zadnji raspoloživi datum",minimumDate:"Prvi raspoloživi datum",next:"Sledeći",previous:"Prethodni",selectedDateDescription:e=>`Izabrani datum: ${e.date}`,selectedRangeDescription:e=>`Izabrani period: ${e.dateRange}`,startRangeSelectionPrompt:"Kliknite da započnete opseg izabranih datuma",todayDate:e=>`Danas, ${e.date}`,todayDateSelected:e=>`Danas, izabran ${e.date}`},"sv-SE":{dateRange:e=>`${e.startDate} till ${e.endDate}`,dateSelected:e=>`${e.date} har valts`,finishRangeSelectionPrompt:"Klicka f\xf6r att avsluta val av datumintervall",maximumDate:"Sista tillg\xe4ngliga datum",minimumDate:"F\xf6rsta tillg\xe4ngliga datum",next:"N\xe4sta",previous:"F\xf6reg\xe5ende",selectedDateDescription:e=>`Valt datum: ${e.date}`,selectedRangeDescription:e=>`Valt intervall: ${e.dateRange}`,startRangeSelectionPrompt:"Klicka f\xf6r att v\xe4lja datumintervall",todayDate:e=>`Idag, ${e.date}`,todayDateSelected:e=>`Idag, ${e.date} har valts`},"tr-TR":{dateRange:e=>`${e.startDate} - ${e.endDate}`,dateSelected:e=>`${e.date} se\xe7ildi`,finishRangeSelectionPrompt:"Tarih aralığı se\xe7imini tamamlamak i\xe7in tıklayın",maximumDate:"Son m\xfcsait tarih",minimumDate:"İlk m\xfcsait tarih",next:"Sonraki",previous:"\xd6nceki",selectedDateDescription:e=>`Se\xe7ilen Tarih: ${e.date}`,selectedRangeDescription:e=>`Se\xe7ilen Aral\u{131}k: ${e.dateRange}`,startRangeSelectionPrompt:"Tarih aralığı se\xe7imini başlatmak i\xe7in tıklayın",todayDate:e=>`Bug\xfcn, ${e.date}`,todayDateSelected:e=>`Bug\xfcn, ${e.date} se\xe7ildi`},"uk-UA":{dateRange:e=>`${e.startDate} \u{2014} ${e.endDate}`,dateSelected:e=>`\u{412}\u{438}\u{431}\u{440}\u{430}\u{43D}\u{43E} ${e.date}`,finishRangeSelectionPrompt:"Натисніть, щоб завершити вибір діапазону дат",maximumDate:"Остання доступна дата",minimumDate:"Перша доступна дата",next:"Наступний",previous:"Попередній",selectedDateDescription:e=>`\u{412}\u{438}\u{431}\u{440}\u{430}\u{43D}\u{430} \u{434}\u{430}\u{442}\u{430}: ${e.date}`,selectedRangeDescription:e=>`\u{412}\u{438}\u{431}\u{440}\u{430}\u{43D}\u{438}\u{439} \u{434}\u{456}\u{430}\u{43F}\u{430}\u{437}\u{43E}\u{43D}: ${e.dateRange}`,startRangeSelectionPrompt:"Натисніть, щоб почати вибір діапазону дат",todayDate:e=>`\u{421}\u{44C}\u{43E}\u{433}\u{43E}\u{434}\u{43D}\u{456}, ${e.date}`,todayDateSelected:e=>`\u{421}\u{44C}\u{43E}\u{433}\u{43E}\u{434}\u{43D}\u{456}, \u{432}\u{438}\u{431}\u{440}\u{430}\u{43D}\u{43E} ${e.date}`},"zh-CN":{dateRange:e=>`${e.startDate} \u{81F3} ${e.endDate}`,dateSelected:e=>`\u{5DF2}\u{9009}\u{62E9} ${e.date}`,finishRangeSelectionPrompt:"单击以完成选择日期范围",maximumDate:"最后一个可用日期",minimumDate:"第一个可用日期",next:"下一页",previous:"上一页",selectedDateDescription:e=>`\u{9009}\u{5B9A}\u{7684}\u{65E5}\u{671F}\u{FF1A}${e.date}`,selectedRangeDescription:e=>`\u{9009}\u{5B9A}\u{7684}\u{8303}\u{56F4}\u{FF1A}${e.dateRange}`,startRangeSelectionPrompt:"单击以开始选择日期范围",todayDate:e=>`\u{4ECA}\u{5929}\u{FF0C}\u{5373} ${e.date}`,todayDateSelected:e=>`\u{5DF2}\u{9009}\u{62E9}\u{4ECA}\u{5929}\u{FF0C}\u{5373} ${e.date}`},"zh-TW":{dateRange:e=>`${e.startDate} \u{81F3} ${e.endDate}`,dateSelected:e=>`\u{5DF2}\u{9078}\u{53D6} ${e.date}`,finishRangeSelectionPrompt:"按一下以完成選取日期範圍",maximumDate:"最後一個可用日期",minimumDate:"第一個可用日期",next:"下一頁",previous:"上一頁",selectedDateDescription:e=>`\u{9078}\u{5B9A}\u{7684}\u{65E5}\u{671F}\u{FF1A}${e.date}`,selectedRangeDescription:e=>`\u{9078}\u{5B9A}\u{7684}\u{7BC4}\u{570D}\u{FF1A}${e.dateRange}`,startRangeSelectionPrompt:"按一下以開始選取日期範圍",todayDate:e=>`\u{4ECA}\u{5929}\u{FF0C}${e.date}`,todayDateSelected:e=>`\u{5DF2}\u{9078}\u{53D6}\u{4ECA}\u{5929}\u{FF0C}${e.date}`}};let oj={standard:[31,28,31,30,31,30,31,31,30,31,30,31],leapyear:[31,29,31,30,31,30,31,31,30,31,30,31]};class oC{fromJulianDay(e){let t=e-1721426,r=Math.floor(t/146097),n=oO(t,146097),o=Math.floor(n/36524),i=oO(n,36524),a=Math.floor(i/1461),u=Math.floor(oO(i,1461)/365),[s,l]=o_(400*r+100*o+4*a+u+ +(4!==o&&4!==u)),c=e-oA(s,l,1,1),d=2;e<oA(s,l,3,1)?d=0:ox(l)&&(d=1);let f=Math.floor(((c+d)*12+373)/367),p=e-oA(s,l,f,1)+1;return new oJ(s,l,f,p)}toJulianDay(e){return oA(e.era,e.year,e.month,e.day)}getDaysInMonth(e){return oj[ox(e.year)?"leapyear":"standard"][e.month-1]}getMonthsInYear(e){return 12}getDaysInYear(e){return ox(e.year)?366:365}getYearsInEra(e){return 9999}getEras(){return["BC","AD"]}isInverseEra(e){return"BC"===e.era}balanceDate(e){e.year<=0&&(e.era="BC"===e.era?"AD":"BC",e.year=1-e.year)}constructor(){this.identifier="gregory"}}function oP(e,t){let r=e.copy(),n="hour"in r?oV(r,t):0;ok(r,t.years||0),r.calendar.balanceYearMonth&&r.calendar.balanceYearMonth(r,e),r.month+=t.months||0,oI(r),oT(r),r.day+=7*(t.weeks||0),r.day+=t.days||0,r.day+=n,function(e){for(;e.day<1;)e.month--,oI(e),e.day+=e.calendar.getDaysInMonth(e);for(;e.day>e.calendar.getDaysInMonth(e);)e.day-=e.calendar.getDaysInMonth(e),e.month++,oI(e)}(r),r.calendar.balanceDate&&r.calendar.balanceDate(r),r.year<1&&(r.year=1,r.month=1,r.day=1);let o=r.calendar.getYearsInEra(r);if(r.year>o){var i,a;let e=null==(i=(a=r.calendar).isInverseEra)?void 0:i.call(a,r);r.year=o,r.month=e?1:r.calendar.getMonthsInYear(r),r.day=e?1:r.calendar.getDaysInMonth(r)}r.month<1&&(r.month=1,r.day=1);let u=r.calendar.getMonthsInYear(r);return r.month>u&&(r.month=u,r.day=r.calendar.getDaysInMonth(r)),r.day=Math.max(1,Math.min(r.calendar.getDaysInMonth(r),r.day)),r}function ok(e,t){var r,n;(null==(r=(n=e.calendar).isInverseEra)?void 0:r.call(n,e))&&(t=-t),e.year+=t}function oI(e){for(;e.month<1;)ok(e,-1),e.month+=e.calendar.getMonthsInYear(e);let t=0;for(;e.month>(t=e.calendar.getMonthsInYear(e));)e.month-=t,ok(e,1)}function oT(e){e.month=Math.max(1,Math.min(e.calendar.getMonthsInYear(e),e.month)),e.day=Math.max(1,Math.min(e.calendar.getDaysInMonth(e),e.day))}function oR(e){e.calendar.constrainDate&&e.calendar.constrainDate(e),e.year=Math.max(1,Math.min(e.calendar.getYearsInEra(e),e.year)),oT(e)}function oF(e){let t={};for(let r in e)"number"==typeof e[r]&&(t[r]=-e[r]);return t}function oN(e,t){let r=e.copy();return null!=t.era&&(r.era=t.era),null!=t.year&&(r.year=t.year),null!=t.month&&(r.month=t.month),null!=t.day&&(r.day=t.day),oR(r),r}function oM(e,t){let r=e.copy();return null!=t.hour&&(r.hour=t.hour),null!=t.minute&&(r.minute=t.minute),null!=t.second&&(r.second=t.second),null!=t.millisecond&&(r.millisecond=t.millisecond),oB(r),r}function oB(e){e.millisecond=Math.max(0,Math.min(e.millisecond,1e3)),e.second=Math.max(0,Math.min(e.second,59)),e.minute=Math.max(0,Math.min(e.minute,59)),e.hour=Math.max(0,Math.min(e.hour,23))}function oL(e,t){let r=e%t;return r<0&&(r+=t),r}function oV(e,t){let r;return e.hour+=t.hours||0,e.minute+=t.minutes||0,e.second+=t.seconds||0,e.millisecond+=t.milliseconds||0,e.second+=Math.floor(e.millisecond/1e3),e.millisecond=oL(e.millisecond,1e3),e.minute+=Math.floor(e.second/60),e.second=oL(e.second,60),e.hour+=Math.floor(e.minute/60),e.minute=oL(e.minute,60),r=Math.floor(e.hour/24),e.hour=oL(e.hour,24),r}function oU(e,t){let r=e.copy();return oV(r,t),r}function o$(e,t,r,n){let o=e.copy();switch(t){case"era":{let t=e.calendar.getEras(),i=t.indexOf(e.era);if(i<0)throw Error("Invalid era: "+e.era);i=oz(i,r,0,t.length-1,null==n?void 0:n.round),o.era=t[i],oR(o);break}case"year":var i,a;(null==(i=(a=o.calendar).isInverseEra)?void 0:i.call(a,o))&&(r=-r),o.year=oz(e.year,r,-1/0,9999,null==n?void 0:n.round),o.year===-1/0&&(o.year=1),o.calendar.balanceYearMonth&&o.calendar.balanceYearMonth(o,e);break;case"month":o.month=oz(e.month,r,1,e.calendar.getMonthsInYear(e),null==n?void 0:n.round);break;case"day":o.day=oz(e.day,r,1,e.calendar.getDaysInMonth(e),null==n?void 0:n.round);break;default:throw Error("Unsupported field "+t)}return e.calendar.balanceDate&&e.calendar.balanceDate(o),oR(o),o}function oW(e,t,r,n){let o=e.copy();switch(t){case"hour":{let t=e.hour,i=0,a=23;if((null==n?void 0:n.hourCycle)===12){let e=t>=12;i=12*!!e,a=e?23:11}o.hour=oz(t,r,i,a,null==n?void 0:n.round);break}case"minute":o.minute=oz(e.minute,r,0,59,null==n?void 0:n.round);break;case"second":o.second=oz(e.second,r,0,59,null==n?void 0:n.round);break;case"millisecond":o.millisecond=oz(e.millisecond,r,0,999,null==n?void 0:n.round);break;default:throw Error("Unsupported field "+t)}return o}function oz(e,t,r,n,o=!1){if(o){(e+=Math.sign(t))<r&&(e=n);let o=Math.abs(t);(e=t>0?Math.ceil(e/o)*o:Math.floor(e/o)*o)>n&&(e=r)}else(e+=t)<r?e=n-(r-e-1):e>n&&(e=r+(e-n-1));return e}function oK(e,t){let r;return r=(null!=t.years&&0!==t.years||null!=t.months&&0!==t.months||null!=t.weeks&&0!==t.weeks||null!=t.days&&0!==t.days?o9(oP(io(e),{years:t.years,months:t.months,weeks:t.weeks,days:t.days}),e.timeZone):o4(e)-e.offset)+(t.milliseconds||0),r+=1e3*(t.seconds||0),r+=6e4*(t.minutes||0),ii(it(r+=36e5*(t.hours||0),e.timeZone),e.calendar)}function oH(e){return`${String(e.hour).padStart(2,"0")}:${String(e.minute).padStart(2,"0")}:${String(e.second).padStart(2,"0")}${e.millisecond?String(e.millisecond/1e3).slice(1):""}`}function oG(e){let t,r=ii(e,new oC);return t="BC"===r.era?1===r.year?"0000":"-"+String(Math.abs(1-r.year)).padStart(6,"00"):String(r.year).padStart(4,"0"),`${t}-${String(r.month).padStart(2,"0")}-${String(r.day).padStart(2,"0")}`}function oq(e){return`${oG(e)}T${oH(e)}`}function oZ(e){let t,r="object"==typeof e[0]?e.shift():new oC;if("string"==typeof e[0])t=e.shift();else{let e=r.getEras();t=e[e.length-1]}return[r,t,e.shift(),e.shift(),e.shift()]}var oY=new WeakMap;class oJ{copy(){return this.era?new oJ(this.calendar,this.era,this.year,this.month,this.day):new oJ(this.calendar,this.year,this.month,this.day)}add(e){return oP(this,e)}subtract(e){return oP(this,oF(e))}set(e){return oN(this,e)}cycle(e,t,r){return o$(this,e,t,r)}toDate(e){return ie(this,e)}toString(){return oG(this)}compare(e){return im(this,e)}constructor(...e){nv(this,oY,{writable:!0,value:void 0});let[t,r,n,o,i]=oZ(e);this.calendar=t,this.era=r,this.year=n,this.month=o,this.day=i,oR(this)}}var oX=new WeakMap;class oQ{copy(){return new oQ(this.hour,this.minute,this.second,this.millisecond)}add(e){return oU(this,e)}subtract(e){return oU(this,oF(e))}set(e){return oM(this,e)}cycle(e,t,r){return oW(this,e,t,r)}toString(){return oH(this)}compare(e){var t,r;return t=this,r=e,iy(t)-iy(r)}constructor(e=0,t=0,r=0,n=0){nv(this,oX,{writable:!0,value:void 0}),this.hour=e,this.minute=t,this.second=r,this.millisecond=n,oB(this)}}var o0=new WeakMap;class o1{copy(){return this.era?new o1(this.calendar,this.era,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond):new o1(this.calendar,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond)}add(e){return oP(this,e)}subtract(e){return oP(this,oF(e))}set(e){return oN(oM(this,e),e)}cycle(e,t,r){switch(e){case"era":case"year":case"month":case"day":return o$(this,e,t,r);default:return oW(this,e,t,r)}}toDate(e,t){return ie(this,e,t)}toString(){return oq(this)}compare(e){var t,r;let n=im(this,e);return 0===n?(t=this,r=io(e),iy(t)-iy(r)):n}constructor(...e){nv(this,o0,{writable:!0,value:void 0});let[t,r,n,o,i]=oZ(e);this.calendar=t,this.era=r,this.year=n,this.month=o,this.day=i,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,oR(this)}}var o2=new WeakMap;class o3{copy(){return this.era?new o3(this.calendar,this.era,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond):new o3(this.calendar,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond)}add(e){return oK(this,e)}subtract(e){return oK(this,oF(e))}set(e,t){let r,n;return 0===(n=oM(oN(r=io(this),e),e)).compare(r)?this:ii(it(o9(n,this.timeZone,t),this.timeZone),this.calendar)}cycle(e,t,r){return function(e,t,r,n){switch(t){case"hour":{let t=0,o=23;if((null==n?void 0:n.hourCycle)===12){let r=e.hour>=12;t=12*!!r,o=r?23:11}let i=io(e),a=ii(oM(i,{hour:t}),new oC),u=[o9(a,e.timeZone,"earlier"),o9(a,e.timeZone,"later")].filter(t=>it(t,e.timeZone).day===a.day)[0],s=ii(oM(i,{hour:o}),new oC),l=[o9(s,e.timeZone,"earlier"),o9(s,e.timeZone,"later")].filter(t=>it(t,e.timeZone).day===s.day).pop(),c=o4(e)-e.offset,d=Math.floor(c/36e5),f=c%36e5;return ii(it(c=36e5*oz(d,r,Math.floor(u/36e5),Math.floor(l/36e5),null==n?void 0:n.round)+f,e.timeZone),e.calendar)}case"minute":case"second":case"millisecond":return oW(e,t,r,n);case"era":case"year":case"month":case"day":return ii(it(o9(o$(io(e),t,r,n),e.timeZone),e.timeZone),e.calendar);default:throw Error("Unsupported field "+t)}}(this,e,t,r)}toDate(){var e;return e=this,new Date(o4(e)-e.offset)}toString(){var e;let t,r,n;return`${oq(this)}${t=0>Math.sign(e=this.offset)?"-":"+",r=Math.floor((e=Math.abs(e))/36e5),n=e%36e5/6e4,`${t}${String(r).padStart(2,"0")}:${String(n).padStart(2,"0")}`}[${this.timeZone}]`}toAbsoluteString(){return this.toDate().toISOString()}compare(e){return this.toDate().getTime()-(function(e,t){if(e instanceof o3){var r,n;return e.timeZone===t?e:(r=e,n=t,ii(it(o4(r)-r.offset,n),r.calendar))}return it(o9(e,t,void 0),t)})(e,this.timeZone).toDate().getTime()}constructor(...e){nv(this,o2,{writable:!0,value:void 0});let[t,r,n,o,i]=oZ(e),a=e.shift(),u=e.shift();this.calendar=t,this.era=r,this.year=n,this.month=o,this.day=i,this.timeZone=a,this.offset=u,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,oR(this)}}function o4(e){return o6(oD((e=ii(e,new oC)).era,e.year),e.month,e.day,e.hour,e.minute,e.second,e.millisecond)}function o6(e,t,r,n,o,i,a){let u=new Date;return u.setUTCHours(n,o,i,a),u.setUTCFullYear(e,t-1,r),u.getTime()}function o5(e,t){if("UTC"===t)return 0;if(e>0&&t===iv())return -6e4*new Date(e).getTimezoneOffset();let{year:r,month:n,day:o,hour:i,minute:a,second:u}=o7(e,t);return o6(r,n,o,i,a,u,0)-1e3*Math.floor(e/1e3)}let o8=new Map;function o7(e,t){let r=o8.get(t);r||(r=new Intl.DateTimeFormat("en-US",{timeZone:t,hour12:!1,era:"short",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),o8.set(t,r));let n=r.formatToParts(new Date(e)),o={};for(let e of n)"literal"!==e.type&&(o[e.type]=e.value);return{year:"BC"===o.era||"B"===o.era?-o.year+1:+o.year,month:+o.month,day:+o.day,hour:"24"===o.hour?0:+o.hour,minute:+o.minute,second:+o.second}}function o9(e,t,r="compatible"){var n,o,i;let a=io(e);if("UTC"===t)return o4(a);if(t===iv()&&"compatible"===r){a=ii(a,new oC);let e=new Date,t=oD(a.era,a.year);return e.setFullYear(t,a.month-1,a.day),e.setHours(a.hour,a.minute,a.second,a.millisecond),e.getTime()}let u=o4(a),s=o5(u-864e5,t),l=o5(u+864e5,t),c=(n=a,((o=u-s)==(i=u-l)?[o]:[o,i]).filter(e=>{var r;let o;return r=n,o=o7(e,t),r.year===o.year&&r.month===o.month&&r.day===o.day&&r.hour===o.hour&&r.minute===o.minute&&r.second===o.second}));if(1===c.length)return c[0];if(c.length>1)switch(r){case"compatible":case"earlier":return c[0];case"later":return c[c.length-1];case"reject":throw RangeError("Multiple possible absolute times found")}switch(r){case"earlier":return Math.min(u-s,u-l);case"compatible":case"later":return Math.max(u-s,u-l);case"reject":throw RangeError("No such absolute time found")}}function ie(e,t,r="compatible"){return new Date(o9(e,t,r))}function it(e,t){let r=o5(e,t),n=new Date(e+r),o=n.getUTCFullYear();return new o3(o<1?"BC":"AD",o<1?-o+1:o,n.getUTCMonth()+1,n.getUTCDate(),t,r,n.getUTCHours(),n.getUTCMinutes(),n.getUTCSeconds(),n.getUTCMilliseconds())}function ir(e){return new oJ(e.calendar,e.era,e.year,e.month,e.day)}function io(e,t){let r=0,n=0,o=0,i=0;if("timeZone"in e)({hour:r,minute:n,second:o,millisecond:i}=e);else if("hour"in e&&!t)return e;return t&&({hour:r,minute:n,second:o,millisecond:i}=t),new o1(e.calendar,e.era,e.year,e.month,e.day,r,n,o,i)}function ii(e,t){if(il(e.calendar,t))return e;let r=t.fromJulianDay(e.calendar.toJulianDay(e)),n=e.copy();return n.calendar=t,n.era=r.era,n.year=r.year,n.month=r.month,n.day=r.day,oR(n),n}let ia={"001":1,AD:1,AE:6,AF:6,AI:1,AL:1,AM:1,AN:1,AR:1,AT:1,AU:1,AX:1,AZ:1,BA:1,BE:1,BG:1,BH:6,BM:1,BN:1,BY:1,CH:1,CL:1,CM:1,CN:1,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DZ:6,EC:1,EE:1,EG:6,ES:1,FI:1,FJ:1,FO:1,FR:1,GB:1,GE:1,GF:1,GP:1,GR:1,HR:1,HU:1,IE:1,IQ:6,IR:6,IS:1,IT:1,JO:6,KG:1,KW:6,KZ:1,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MK:1,MN:1,MQ:1,MV:5,MY:1,NL:1,NO:1,NZ:1,OM:6,PL:1,QA:6,RE:1,RO:1,RS:1,RU:1,SD:6,SE:1,SI:1,SK:1,SM:1,SY:6,TJ:1,TM:1,TR:1,UA:1,UY:1,UZ:1,VA:1,VN:1,XK:1};function iu(e,t){return t=ii(t,e.calendar),e.era===t.era&&e.year===t.year&&e.month===t.month&&e.day===t.day}function is(e,t){return il(e.calendar,t.calendar)&&iu(e,t)}function il(e,t){var r,n,o,i;return null!=(i=null!=(o=null==(r=e.isEqual)?void 0:r.call(e,t))?o:null==(n=t.isEqual)?void 0:n.call(t,e))?i:e.identifier===t.identifier}let ic={sun:0,mon:1,tue:2,wed:3,thu:4,fri:5,sat:6};function id(e,t,r){let n,o=Math.ceil(e.calendar.toJulianDay(e)+1-(r?ic[r]:(n=function(e){if(Intl.Locale){let t=iS.get(e);return!t&&(t=new Intl.Locale(e).maximize().region)&&iS.set(e,t),t}let t=e.split("-")[1];return"u"===t?void 0:t}(t))&&ia[n]||0))%7;return o<0&&(o+=7),o}function ip(e){return it(Date.now(),e)}function ih(e){return ir(ip(e))}function im(e,t){return e.calendar.toJulianDay(e)-t.calendar.toJulianDay(t)}function iy(e){return 36e5*e.hour+6e4*e.minute+1e3*e.second+e.millisecond}let ib=null;function iv(){return null==ib&&(ib=new Intl.DateTimeFormat().resolvedOptions().timeZone),ib}function ig(e){return e.subtract({days:e.day-1})}function iw(e){return e.add({days:e.calendar.getDaysInMonth(e)-e.day})}function iE(e,t,r){let n=id(e,t,r);return e.subtract({days:n})}let iS=new Map;function iO(e,t){return e&&t?0>=e.compare(t)?e:t:e||t}function iA(e,t){return e&&t?e.compare(t)>=0?e:t:e||t}let ix=Symbol.for("react-aria.i18n.locale"),iD=Symbol.for("react-aria.i18n.strings");class i_{getStringForLocale(e,t){let r=this.getStringsForLocale(t)[e];if(!r)throw Error(`Could not find intl message ${e} in ${t} locale`);return r}getStringsForLocale(e){let t=this.strings[e];return t||(t=function(e,t,r="en-US"){var n;if(t[e])return t[e];let o=(n=e,Intl.Locale?new Intl.Locale(n).language:n.split("-")[0]);if(t[o])return t[o];for(let e in t)if(e.startsWith(o+"-"))return t[e];return t[r]}(e,this.strings,this.defaultLocale),this.strings[e]=t),t}static getGlobalDictionaryForPackage(e){if("u"<typeof window)return null;let t=window[ix];if(void 0===s){let e=window[iD];if(!e)return null;for(let r in s={},e)s[r]=new i_({[t]:e[r]},t)}let r=null==s?void 0:s[e];if(!r)throw Error(`Strings for package "${e}" were not included by LocalizedStringProvider. Please add it to the list passed to createLocalizedStringDictionary.`);return r}constructor(e,t="en-US"){this.strings=Object.fromEntries(Object.entries(e).filter(([,e])=>e)),this.defaultLocale=t}}let ij=new Map,iC=new Map;class iP{format(e,t){let r=this.strings.getStringForLocale(e,this.locale);return"function"==typeof r?r(t,this):r}plural(e,t,r="cardinal"){let n=t["="+e];if(n)return"function"==typeof n?n():n;let o=this.locale+":"+r,i=ij.get(o);return i||(i=new Intl.PluralRules(this.locale,{type:r}),ij.set(o,i)),"function"==typeof(n=t[i.select(e)]||t.other)?n():n}number(e){let t=iC.get(this.locale);return t||(t=new Intl.NumberFormat(this.locale),iC.set(this.locale,t)),t.format(e)}select(e,t){let r=e[t]||e.other;return"function"==typeof r?r():r}constructor(e,t){this.locale=e,this.strings=t}}let ik=new WeakMap;function iI(e,t){let r;return t&&i_.getGlobalDictionaryForPackage(t)||((r=ik.get(e))||(r=new i_(e),ik.set(e,r)),r)}function iT(e,t){let{locale:r}=oE(),n=iI(e,t);return(0,em.useMemo)(()=>new iP(r,n),[r,n])}let iR=new Map;class iF{format(e){return this.formatter.format(e)}formatToParts(e){return this.formatter.formatToParts(e)}formatRange(e,t){if("function"==typeof this.formatter.formatRange)return this.formatter.formatRange(e,t);if(t<e)throw RangeError("End date must be >= start date");return`${this.formatter.format(e)} \u{2013} ${this.formatter.format(t)}`}formatRangeToParts(e,t){if("function"==typeof this.formatter.formatRangeToParts)return this.formatter.formatRangeToParts(e,t);if(t<e)throw RangeError("End date must be >= start date");let r=this.formatter.formatToParts(e),n=this.formatter.formatToParts(t);return[...r.map(e=>({...e,source:"startRange"})),{type:"literal",value:" – ",source:"shared"},...n.map(e=>({...e,source:"endRange"}))]}resolvedOptions(){let e=this.formatter.resolvedOptions();return null==iL&&(iL="h12"===new Intl.DateTimeFormat("fr",{hour:"numeric",hour12:!1}).resolvedOptions().hourCycle),iL&&(this.resolvedHourCycle||(this.resolvedHourCycle=function(e,t){if(!t.timeStyle&&!t.hour)return;e=e.replace(/(-u-)?-nu-[a-zA-Z0-9]+/,"");let r=iM(e+=(e.includes("-u-")?"":"-u")+"-nu-latn",{...t,timeZone:void 0}),n=parseInt(r.formatToParts(new Date(2020,2,3,0)).find(e=>"hour"===e.type).value,10),o=parseInt(r.formatToParts(new Date(2020,2,3,23)).find(e=>"hour"===e.type).value,10);if(0===n&&23===o)return"h23";if(24===n&&23===o)return"h24";if(0===n&&11===o)return"h11";if(12===n&&11===o)return"h12";throw Error("Unexpected hour cycle result")}(e.locale,this.options)),e.hourCycle=this.resolvedHourCycle,e.hour12="h11"===this.resolvedHourCycle||"h12"===this.resolvedHourCycle),"ethiopic-amete-alem"===e.calendar&&(e.calendar="ethioaa"),e}constructor(e,t={}){this.formatter=iM(e,t),this.options=t}}let iN={true:{ja:"h11"},false:{}};function iM(e,t={}){if("boolean"==typeof t.hour12&&(null==iB&&(iB="24"===new Intl.DateTimeFormat("en-US",{hour:"numeric",hour12:!1}).format(new Date(2020,2,3,0))),iB)){let r=iN[String((t={...t}).hour12)][e.split("-")[0]],n=t.hour12?"h12":"h23";t.hourCycle=null!=r?r:n,delete t.hour12}let r=e+(t?Object.entries(t).sort((e,t)=>e[0]<t[0]?-1:1).join():"");if(iR.has(r))return iR.get(r);let n=new Intl.DateTimeFormat(e,t);return iR.set(r,n),n}let iB=null,iL=null;function iV(e,t){let r=(0,em.useRef)(null);return e&&r.current&&t(e,r.current)&&(e=r.current),r.current=e,e}function iU(e){e=iV(null!=e?e:{},i$);let{locale:t}=oE();return(0,em.useMemo)(()=>new iF(t,e),[t,e])}function i$(e,t){if(e===t)return!0;let r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(let n of r)if(t[n]!==e[n])return!1;return!0}function iW(e){return e&&e.__esModule?e.default:e}let iz=new WeakMap;function iK(e){return(null==e?void 0:e.calendar.identifier)==="gregory"&&"BC"===e.era?"short":void 0}function iH(e,t,r,n){let o=iT(iW(oS),"@react-aria/calendar"),i=iK(e)||iK(t),a=iU({month:"long",year:"numeric",era:i,calendar:e.calendar.identifier,timeZone:r}),u=iU({month:"long",year:"numeric",day:"numeric",era:i,calendar:e.calendar.identifier,timeZone:r});return(0,em.useMemo)(()=>{if(iu(e,ig(e))){let i=e,u=t;if(e.calendar.getFormattableMonth&&(i=e.calendar.getFormattableMonth(e)),t.calendar.getFormattableMonth&&(u=t.calendar.getFormattableMonth(t)),iu(t,iw(e)))return a.format(i.toDate(r));if(iu(t,iw(t)))return n?iG(a,o,i,u,r):a.formatRange(i.toDate(r),u.toDate(r))}return n?iG(u,o,e,t,r):u.formatRange(e.toDate(r),t.toDate(r))},[e,t,a,u,o,r,n])}function iG(e,t,r,n,o){let i=e.formatRangeToParts(r.toDate(o),n.toDate(o)),a=-1;for(let e=0;e<i.length;e++){let t=i[e];if("shared"===t.source&&"literal"===t.type)a=e;else if("endRange"===t.source)break}let u="",s="";for(let e=0;e<i.length;e++)e<a?u+=i[e].value:e>a&&(s+=i[e].value);return t.format("dateRange",{startDate:u,endDate:s})}function iq(e,t){let r=(0,em.useRef)(!0),n=(0,em.useRef)(null);(0,em.useEffect)(()=>(r.current=!0,()=>{r.current=!1}),[]),(0,em.useEffect)(()=>{let o=n.current;r.current?r.current=!1:(!o||t.some((e,t)=>!Object.is(e,o[t])))&&e(),n.current=t},t)}function iZ(e,t){let{id:r,"aria-label":n,"aria-labelledby":o}=e;return r=rj(r),o&&n?o=[...new Set([r,...o.trim().split(/\s+/)])].join(" "):o&&(o=o.trim().split(/\s+/).join(" ")),n||o||!t||(n=t),{id:r,"aria-label":n,"aria-labelledby":o}}function iY(e,t){var r,n;let o,i,a,u,s,l=iT((r=oS)&&r.__esModule?r.default:r,"@react-aria/calendar"),c=rG(e),d=iH(t.visibleRange.start,t.visibleRange.end,t.timeZone,!1),f=iH(t.visibleRange.start,t.visibleRange.end,t.timeZone,!0);iq(()=>{t.isFocused||rU(f)},[f]);let p=(a=iT(iW(oS),"@react-aria/calendar"),"highlightedRange"in t?{start:o,end:i}=t.highlightedRange||{}:o=i=null!=(n=t.value)?n:void 0,u=iU({weekday:"long",month:"long",year:"numeric",day:"numeric",era:iK(o)||iK(i),timeZone:t.timeZone}),s="anchorDate"in t?t.anchorDate:null,(0,em.useMemo)(()=>{if(!s&&o&&i)if(iu(o,i)){let e=u.format(o.toDate(t.timeZone));return a.format("selectedDateDescription",{date:e})}else{let e=iG(u,a,o,i,t.timeZone);return a.format("selectedRangeDescription",{dateRange:e})}return""},[o,i,s,t.timeZone,a,u]));iq(()=>{p&&rU(p,"polite",4e3)},[p]);let h=rC([!!e.errorMessage,e.isInvalid,e.validationState]);iz.set(t,{ariaLabel:e["aria-label"],ariaLabelledBy:e["aria-labelledby"],errorMessageId:h,selectedDateDescription:p});let[m,y]=(0,em.useState)(!1),b=e.isDisabled||t.isNextVisibleRangeInvalid();b&&m&&(y(!1),t.setFocused(!0));let[v,g]=(0,em.useState)(!1),w=e.isDisabled||t.isPreviousVisibleRangeInvalid();return w&&v&&(g(!1),t.setFocused(!0)),{calendarProps:rk(c,iZ({id:e.id,"aria-label":[e["aria-label"],f].filter(Boolean).join(", "),"aria-labelledby":e["aria-labelledby"]}),{role:"application","aria-describedby":e["aria-describedby"]||void 0}),nextButtonProps:{onPress:()=>t.focusNextPage(),"aria-label":l.format("next"),isDisabled:b,onFocusChange:y},prevButtonProps:{onPress:()=>t.focusPreviousPage(),"aria-label":l.format("previous"),isDisabled:w,onFocusChange:g},errorMessageProps:{id:h},title:d}}let iJ={border:0,clip:"rect(0 0 0 0)",clipPath:"inset(50%)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap"};function iX(e){let{children:t,elementType:r="div",isFocusable:n,style:o,...i}=e,{visuallyHiddenProps:a}=function(e={}){let{style:t,isFocusable:r}=e,[n,o]=(0,em.useState)(!1),{focusWithinProps:i}=n6({isDisabled:!r,onFocusWithinChange:e=>o(e)}),a=(0,em.useMemo)(()=>n?t:t?{...iJ,...t}:iJ,[n]);return{visuallyHiddenProps:{...i,style:a}}}(e);return ey().createElement(r,rk(i,a),t)}function iQ(e,t,r,n){let o=ry(r),i=null==r;(0,em.useEffect)(()=>{if(i||!e.current)return;let r=e.current;return r.addEventListener(t,o,n),()=>{r.removeEventListener(t,o,n)}},[e,t,n,i,o])}let i0=0,i1=new Map;function i2(e){let[t,r]=(0,em.useState)();return rm(()=>{if(!e)return;let t=i1.get(e);if(t)r(t.element.id);else{let n=`react-aria-description-${i0++}`;r(n);let o=document.createElement("div");o.id=n,o.style.display="none",o.textContent=e,document.body.appendChild(o),t={refCount:0,element:o},i1.set(e,t)}return t.refCount++,()=>{t&&0==--t.refCount&&(t.element.remove(),i1.delete(e))}},[e]),{"aria-describedby":e?t:void 0}}function i3(e,t){if(!e)return!1;let r=window.getComputedStyle(e),n=/(auto|scroll)/.test(r.overflow+r.overflowX+r.overflowY);return n&&t&&(n=e.scrollHeight!==e.clientHeight||e.scrollWidth!==e.clientWidth),n}function i4(e,t,r){let n="left"===r?"offsetLeft":"offsetTop",o=0;for(;t.offsetParent&&(o+=t[n],t.offsetParent!==e);){if(t.offsetParent.contains(e)){o-=e[n];break}t=t.offsetParent}return o}function i6(e,t){if(e&&document.contains(e)){let a=document.scrollingElement||document.documentElement;if("hidden"===window.getComputedStyle(a).overflow)for(let t of function(e){let t=[];for(;e&&e!==document.documentElement;)i3(e,void 0)&&t.push(e),e=e.parentElement;return t}(e))!function(e,t){let r=i4(e,t,"left"),n=i4(e,t,"top"),o=t.offsetWidth,i=t.offsetHeight,a=e.scrollLeft,u=e.scrollTop,{borderTopWidth:s,borderLeftWidth:l,scrollPaddingTop:c,scrollPaddingRight:d,scrollPaddingBottom:f,scrollPaddingLeft:p}=getComputedStyle(e),h=a+parseInt(l,10),m=u+parseInt(s,10),y=h+e.clientWidth,b=m+e.clientHeight,v=parseInt(c,10)||0,g=parseInt(f,10)||0,w=parseInt(d,10)||0,E=parseInt(p,10)||0;r<=a+E?a=r-parseInt(l,10)-E:r+o>y-w&&(a+=r+o-y+w),n<=m+v?u=n-parseInt(s,10)-v:n+i>b-g&&(u+=n+i-b+g),e.scrollLeft=a,e.scrollTop=u}(t,e);else{var r,n,o,i;let{left:a,top:u}=e.getBoundingClientRect();null==e||null==(r=e.scrollIntoView)||r.call(e,{block:"nearest"});let{left:s,top:l}=e.getBoundingClientRect();(Math.abs(a-s)>1||Math.abs(u-l)>1)&&(null==t||null==(o=t.containingElement)||null==(n=o.scrollIntoView)||n.call(o,{block:"center",inline:"center"}),null==(i=e.scrollIntoView)||i.call(e,{block:"nearest"}))}}}function i5(e,t){let r=e;for(i3(r,t)&&(r=r.parentElement);r&&!i3(r,t);)r=r.parentElement;return r||document.scrollingElement||document.documentElement}class i8 extends oC{fromJulianDay(e){let t=super.fromJulianDay(e);return new oJ(this,oD(t.era,t.year)- -543,t.month,t.day)}toJulianDay(e){return super.toJulianDay(i7(e))}getEras(){return["BE"]}getDaysInMonth(e){return super.getDaysInMonth(i7(e))}balanceDate(){}constructor(...e){super(...e),this.identifier="buddhist"}}function i7(e){let[t,r]=o_(e.year+-543);return new oJ(t,r,e.month,e.day)}function i9(e,t,r,n){return e+365*t+Math.floor(t/4)+30*(r-1)+n-1}function ae(e,t){let r=Math.floor(4*(t-e)/1461),n=1+Math.floor((t-i9(e,r,1,1))/30),o=t+1-i9(e,r,n,1);return[r,n,o]}function at(e){return Math.floor(e%4/3)}function ar(e,t){return t%13!=0?30:at(e)+5}class an{fromJulianDay(e){let[t,r,n]=ae(1723856,e),o="AM";return t<=0&&(o="AA",t+=5500),new oJ(this,o,t,r,n)}toJulianDay(e){let t=e.year;return"AA"===e.era&&(t-=5500),i9(1723856,t,e.month,e.day)}getDaysInMonth(e){return ar(e.year,e.month)}getMonthsInYear(){return 13}getDaysInYear(e){return 365+at(e.year)}getYearsInEra(e){return"AA"===e.era?9999:9991}getEras(){return["AA","AM"]}constructor(){this.identifier="ethiopic"}}class ao extends an{fromJulianDay(e){let[t,r,n]=ae(1723856,e);return new oJ(this,"AA",t+=5500,r,n)}getEras(){return["AA"]}getYearsInEra(){return 9999}constructor(...e){super(...e),this.identifier="ethioaa"}}class ai extends an{fromJulianDay(e){let[t,r,n]=ae(1824665,e),o="CE";return t<=0&&(o="BCE",t=1-t),new oJ(this,o,t,r,n)}toJulianDay(e){let t=e.year;return"BCE"===e.era&&(t=1-t),i9(1824665,t,e.month,e.day)}getDaysInMonth(e){let t=e.year;return"BCE"===e.era&&(t=1-t),ar(t,e.month)}isInverseEra(e){return"BCE"===e.era}balanceDate(e){e.year<=0&&(e.era="BCE"===e.era?"CE":"BCE",e.year=1-e.year)}getEras(){return["BCE","CE"]}getYearsInEra(e){return"BCE"===e.era?9999:9715}constructor(...e){super(...e),this.identifier="coptic"}}let aa=765433;function au(e){return 7>oO(7*e+1,19)}function as(e){let t=Math.floor((235*e-234)/19),r=29*t+Math.floor((12084+13753*t)/25920);return 3>oO(3*(r+1),7)&&(r+=1),r}function al(e){let t,r;return as(e)+(t=as(e-1),r=as(e),as(e+1)-r==356?2:+(r-t==382))}function ac(e){return al(e+1)-al(e)}function ad(e,t){if(t>=6&&!au(e)&&t++,4===t||7===t||9===t||11===t||13===t)return 29;let r=function(e){let t=ac(e);switch(t>380&&(t-=30),t){case 353:return 0;case 354:return 1;case 355:return 2}}(e);return 2===t?2===r?30:29:3===t?0===r?29:30:6===t?30*!!au(e):30}class af{fromJulianDay(e){let t=e-347997,r=Math.floor((25920*t/aa*19+234)/235)+1,n=al(r),o=Math.floor(t-n);for(;o<1;)o=Math.floor(t-(n=al(--r)));let i=1,a=0;for(;a<o;)a+=ad(r,i),i++;let u=o-(a-=ad(r,--i));return new oJ(this,r,i,u)}toJulianDay(e){let t=al(e.year);for(let r=1;r<e.month;r++)t+=ad(e.year,r);return t+e.day+347997}getDaysInMonth(e){return ad(e.year,e.month)}getMonthsInYear(e){return au(e.year)?13:12}getDaysInYear(e){return ac(e.year)}getYearsInEra(){return 9999}getEras(){return["AM"]}balanceYearMonth(e,t){t.year!==e.year&&(au(t.year)&&!au(e.year)&&t.month>6?e.month--:!au(t.year)&&au(e.year)&&t.month>6&&e.month++)}constructor(){this.identifier="hebrew"}}class ap extends oC{fromJulianDay(e){let t,r,n,o=super.fromJulianDay(e),i=o.year-78,a=e-oA(o.era,o.year,1,1);if(a<80?(i--,a+=(t=ox(o.year-1)?31:30)+155+90+10):(t=ox(o.year)?31:30,a-=80),a<t)r=1,n=a+1;else{let e=a-t;e<155?(r=Math.floor(e/31)+2,n=e%31+1):(e-=155,r=Math.floor(e/30)+7,n=e%30+1)}return new oJ(this,i,r,n)}toJulianDay(e){let t,r,[n,o]=o_(e.year+78);return(ox(o)?(t=31,r=oA(n,o,3,21)):(t=30,r=oA(n,o,3,22)),1===e.month)?r+e.day-1:(r+=t+31*Math.min(e.month-2,5),e.month>=8&&(r+=(e.month-7)*30),r+=e.day-1)}getDaysInMonth(e){return 1===e.month&&ox(e.year+78)||e.month>=2&&e.month<=6?31:30}getYearsInEra(){return 9919}getEras(){return["saka"]}balanceDate(){}constructor(...e){super(...e),this.identifier="indian"}}function ah(e,t,r,n){return n+Math.ceil(29.5*(r-1))+(t-1)*354+Math.floor((3+11*t)/30)+e-1}function am(e,t,r){let n=Math.floor((30*(r-t)+10646)/10631),o=Math.min(12,Math.ceil((r-(29+ah(t,n,1,1)))/29.5)+1),i=r-ah(t,n,o,1)+1;return new oJ(e,n,o,i)}function ay(e){return(14+11*e)%30<11}class ab{fromJulianDay(e){return am(this,1948440,e)}toJulianDay(e){return ah(1948440,e.year,e.month,e.day)}getDaysInMonth(e){let t=29+e.month%2;return 12===e.month&&ay(e.year)&&t++,t}getMonthsInYear(){return 12}getDaysInYear(e){return ay(e.year)?355:354}getYearsInEra(){return 9665}getEras(){return["AH"]}constructor(){this.identifier="islamic-civil"}}class av extends ab{fromJulianDay(e){return am(this,1948439,e)}toJulianDay(e){return ah(1948439,e.year,e.month,e.day)}constructor(...e){super(...e),this.identifier="islamic-tbla"}}function ag(e){return 460322+i[e-1300]}function aw(e,t){return(o[e-1300]&1<<11-(t-1))==0?29:30}function aE(e,t){let r=ag(e);for(let n=1;n<t;n++)r+=aw(e,n);return r}function aS(e){return i[e+1-1300]-i[e-1300]}class aO extends ab{fromJulianDay(e){let t=e-1948440,r=ag(1300),n=ag(1600);if(t<r||t>n)return super.fromJulianDay(e);{let e=1299,r=1,n=1;for(;n>0;){n=t-ag(++e)+1;let o=aS(e);if(n===o){r=12;break}if(n<o){let t=aw(e,r);for(r=1;n>t;)n-=t,t=aw(e,++r);break}}return new oJ(this,e,r,t-aE(e,r)+1)}}toJulianDay(e){return e.year<1300||e.year>1600?super.toJulianDay(e):1948440+aE(e.year,e.month)+(e.day-1)}getDaysInMonth(e){return e.year<1300||e.year>1600?super.getDaysInMonth(e):aw(e.year,e.month)}getDaysInYear(e){return e.year<1300||e.year>1600?super.getDaysInYear(e):aS(e.year)}constructor(){if(super(),this.identifier="islamic-umalqura",o||(o=new Uint16Array(Uint8Array.from(atob("qgpUDckO1AbqBmwDrQpVBakGkgepC9QF2gpcBS0NlQZKB1QLagutBa4ETwoXBYsGpQbVCtYCWwmdBE0KJg2VDawFtgm6AlsKKwWVCsoG6Qr0AnYJtgJWCcoKpAvSC9kF3AJtCU0FpQpSC6ULtAW2CVcFlwJLBaMGUgdlC2oFqworBZUMSg2lDcoF1gpXCasESwmlClILagt1BXYCtwhbBFUFqQW0BdoJ3QRuAjYJqgpUDbIN1QXaAlsJqwRVCkkLZAtxC7QFtQpVCiUNkg7JDtQG6QprCasEkwpJDaQNsg25CroEWworBZUKKgtVC1wFvQQ9Ah0JlQpKC1oLbQW2AjsJmwRVBqkGVAdqC2wFrQpVBSkLkgupC9QF2gpaBasKlQVJB2QHqgu1BbYCVgpNDiULUgtqC60FrgIvCZcESwalBqwG1gpdBZ0ETQoWDZUNqgW1BdoCWwmtBJUFygbkBuoK9QS2AlYJqgpUC9IL2QXqAm0JrQSVCkoLpQuyBbUJ1gSXCkcFkwZJB1ULagVrCisFiwpGDaMNygXWCtsEawJLCaUKUgtpC3UFdgG3CFsCKwVlBbQF2gntBG0BtgimClINqQ3UBdoKWwmrBFMGKQdiB6kLsgW1ClUFJQuSDckO0gbpCmsFqwRVCikNVA2qDbUJugQ7CpsETQqqCtUK2gJdCV4ELgqaDFUNsga5BroEXQotBZUKUguoC7QLuQXaAloJSgukDdEO6AZqC20FNQWVBkoNqA3UDdoGWwWdAisGFQtKC5ULqgWuCi4JjwwnBZUGqgbWCl0FnQI="),e=>e.charCodeAt(0)).buffer)),!i){i=new Uint32Array(301);let e=0;for(let t=1300;t<=1600;t++){i[t-1300]=e;for(let r=1;r<=12;r++)e+=aw(t,r)}}}}let aA=[[1868,9,8],[1912,7,30],[1926,12,25],[1989,1,8],[2019,5,1]],ax=[[1912,7,29],[1926,12,24],[1989,1,7],[2019,4,30]],aD=[1867,1911,1925,1988,2018],a_=["meiji","taisho","showa","heisei","reiwa"];function aj(e){let t=aA.findIndex(([t,r,n])=>!!(e.year<t)||e.year===t&&!!(e.month<r)||e.year===t&&e.month===r&&!!(e.day<n));return -1===t?aA.length-1:0===t?0:t-1}function aC(e){let t=aD[a_.indexOf(e.era)];if(!t)throw Error("Unknown era: "+e.era);return new oJ(e.year+t,e.month,e.day)}class aP extends oC{fromJulianDay(e){let t=super.fromJulianDay(e),r=aj(t);return new oJ(this,a_[r],t.year-aD[r],t.month,t.day)}toJulianDay(e){return super.toJulianDay(aC(e))}balanceDate(e){let t=aC(e),r=aj(t);a_[r]!==e.era&&(e.era=a_[r],e.year=t.year-aD[r]),this.constrainDate(e)}constrainDate(e){let t=a_.indexOf(e.era),r=ax[t];if(null!=r){let[n,o,i]=r,a=n-aD[t];e.year=Math.max(1,Math.min(a,e.year)),e.year===a&&(e.month=Math.min(o,e.month),e.month===o&&(e.day=Math.min(i,e.day)))}if(1===e.year&&t>=0){let[,r,n]=aA[t];e.month=Math.max(r,e.month),e.month===r&&(e.day=Math.max(n,e.day))}}getEras(){return a_}getYearsInEra(e){let t=a_.indexOf(e.era),r=aA[t],n=aA[t+1];if(null==n)return 9999-r[0]+1;let o=n[0]-r[0];return(e.month<n[1]||e.month===n[1]&&e.day<n[2])&&o++,o}getDaysInMonth(e){return super.getDaysInMonth(aC(e))}getMinimumMonthInYear(e){let t=ak(e);return t?t[1]:1}getMinimumDayInMonth(e){let t=ak(e);return t&&e.month===t[1]?t[2]:1}constructor(...e){super(...e),this.identifier="japanese"}}function ak(e){if(1===e.year)return aA[a_.indexOf(e.era)]}let aI=[0,31,62,93,124,155,186,216,246,276,306,336];class aT{fromJulianDay(e){let t=e-1948320,r=1+Math.floor((33*t+3)/12053),n=t-(365*(r-1)+Math.floor((8*r+21)/33)),o=n<216?Math.floor(n/31):Math.floor((n-6)/30),i=n-aI[o]+1;return new oJ(this,r,o+1,i)}toJulianDay(e){let t=1948319+365*(e.year-1)+Math.floor((8*e.year+21)/33);return t+=aI[e.month-1],t+=e.day}getMonthsInYear(){return 12}getDaysInMonth(e){return e.month<=6?31:e.month<=11||8>oO(25*e.year+11,33)?30:29}getEras(){return["AP"]}getYearsInEra(){return 9377}constructor(){this.identifier="persian"}}function aR(e){return"minguo"===e.era?e.year+1911:1-e.year+1911}function aF(e){let t=e-1911;return t>0?["minguo",t]:["before_minguo",1-t]}class aN extends oC{fromJulianDay(e){let t=super.fromJulianDay(e),[r,n]=aF(oD(t.era,t.year));return new oJ(this,r,n,t.month,t.day)}toJulianDay(e){return super.toJulianDay(aM(e))}getEras(){return["before_minguo","minguo"]}balanceDate(e){let[t,r]=aF(aR(e));e.era=t,e.year=r}isInverseEra(e){return"before_minguo"===e.era}getDaysInMonth(e){return super.getDaysInMonth(aM(e))}getYearsInEra(e){return"before_minguo"===e.era?9999:8088}constructor(...e){super(...e),this.identifier="roc"}}function aM(e){let[t,r]=o_(aR(e));return new oJ(t,r,e.month,e.day)}function aB(e){switch(e){case"buddhist":return new i8;case"ethiopic":return new an;case"ethioaa":return new ao;case"coptic":return new ai;case"hebrew":return new af;case"indian":return new ap;case"islamic-civil":return new ab;case"islamic-tbla":return new av;case"islamic-umalqura":return new aO;case"japanese":return new aP;case"persian":return new aT;case"roc":return new aN;default:return new oC}}function aL(e,t,r){return null!=t&&0>e.compare(t)||null!=r&&e.compare(r)>0}function aV(e,t,r,n,o){let i={};for(let e in t)i[e]=Math.floor(t[e]/2),i[e]>0&&t[e]%2==0&&i[e]--;let a=aU(e,t,r).subtract(i);return aW(e,a,t,r,n,o)}function aU(e,t,r,n,o){let i=e;if(t.years)i=ig(e.subtract({months:e.month-1}));else t.months?i=ig(e):t.weeks&&(i=iE(e,r));return aW(e,i,t,r,n,o)}function a$(e,t,r,n,o){let i={...t};i.days?i.days--:i.weeks?i.weeks--:i.months?i.months--:i.years&&i.years--;let a=aU(e,t,r).subtract(i);return aW(e,a,t,r,n,o)}function aW(e,t,r,n,o,i){if(o&&e.compare(o)>=0){let e=iA(t,aU(ir(o),r,n));e&&(t=e)}if(i&&0>=e.compare(i)){let e=iO(t,a$(ir(i),r,n));e&&(t=e)}return t}function az(e,t,r){if(t){let r=iA(e,ir(t));r&&(e=r)}if(r){let t=iO(e,ir(r));t&&(e=t)}return e}function aK(e,t,r){if(!r)return e;for(;e.compare(t)>=0&&r(e);)e=e.subtract({days:1});return e.compare(t)>=0?e:null}function aH(e,t,r){let[n,o]=(0,em.useState)(e||t),i=(0,em.useRef)(void 0!==e),a=void 0!==e;(0,em.useEffect)(()=>{i.current,i.current=a},[a]);let u=a?e:n,s=(0,em.useCallback)((e,...t)=>{let n=(e,...t)=>{r&&!Object.is(u,e)&&r(e,...t),a||(u=e)};"function"==typeof e?o((r,...o)=>{let i=e(a?u:r,...o);return(n(i,...t),a)?r:i}):(a||o(e),n(e,...t))},[a,u,r]);return[u,s]}function aG(e){var t,r,n;let o=(0,em.useMemo)(()=>new iF(e.locale),[e.locale]),i=(0,em.useMemo)(()=>o.resolvedOptions(),[o]),{locale:a,createCalendar:u,visibleDuration:s={months:1},minValue:l,maxValue:c,selectionAlignment:d,isDateUnavailable:f,pageBehavior:p="visible",firstDayOfWeek:h}=e,m=(0,em.useMemo)(()=>u(i.calendar),[u,i.calendar]),[y,b]=aH(e.value,null!=(t=e.defaultValue)?t:null,e.onChange),v=(0,em.useMemo)(()=>y?ii(ir(y),m):null,[y,m]),g=(0,em.useMemo)(()=>y&&"timeZone"in y?y.timeZone:i.timeZone,[y,i.timeZone]),[w,E]=aH((0,em.useMemo)(()=>e.focusedValue?az(ii(ir(e.focusedValue),m),l,c):void 0,[e.focusedValue,m,l,c]),(0,em.useMemo)(()=>az(e.defaultFocusedValue?ii(ir(e.defaultFocusedValue),m):v||ii(ih(g),m),l,c),[e.defaultFocusedValue,v,g,m,l,c]),e.onFocusChange),[S,O]=(0,em.useState)(()=>{switch(d){case"start":return aU(w,s,a,l,c);case"end":return a$(w,s,a,l,c);default:return aV(w,s,a,l,c)}}),[A,x]=(0,em.useState)(e.autoFocus||!1),D=(0,em.useMemo)(()=>{let e={...s};return e.days?e.days--:e.days=-1,S.add(e)},[S,s]),[j,C]=(0,em.useState)(m);if(!il(m,j)){let e=ii(w,m);O(aV(e,s,a,l,c)),E(e),C(m)}function P(e){E(e=az(e,l,c))}function k(t){if(!e.isDisabled&&!e.isReadOnly){let e=t;if(null===e)return void b(null);(e=aK(e=az(e,l,c),S,f))&&(e=ii(e,(null==y?void 0:y.calendar)||new oC),y&&"hour"in y?b(y.set(e)):b(e))}}aL(w,l,c)?E(az(w,l,c)):0>w.compare(S)?O(a$(w,s,a,l,c)):w.compare(D)>0&&O(aU(w,s,a,l,c));let I=(0,em.useMemo)(()=>!!v&&(!!(f&&f(v))||aL(v,l,c)),[v,f,l,c]),T=e.isInvalid||"invalid"===e.validationState||I,R=(0,em.useMemo)(()=>"visible"===p?s:aq(s),[p,s]);return{isDisabled:null!=(r=e.isDisabled)&&r,isReadOnly:null!=(n=e.isReadOnly)&&n,value:v,setValue:k,visibleRange:{start:S,end:D},minValue:l,maxValue:c,focusedDate:w,timeZone:g,validationState:T?"invalid":null,isValueInvalid:T,setFocusedDate(e){P(e),x(!0)},focusNextDay(){P(w.add({days:1}))},focusPreviousDay(){P(w.subtract({days:1}))},focusNextRow(){s.days?this.focusNextPage():(s.weeks||s.months||s.years)&&P(w.add({weeks:1}))},focusPreviousRow(){s.days?this.focusPreviousPage():(s.weeks||s.months||s.years)&&P(w.subtract({weeks:1}))},focusNextPage(){let e=S.add(R);E(az(w.add(R),l,c)),O(aU(aW(w,e,R,a,l,c),R,a))},focusPreviousPage(){let e=S.subtract(R);E(az(w.subtract(R),l,c)),O(aU(aW(w,e,R,a,l,c),R,a))},focusSectionStart(){s.days?P(S):s.weeks?P(iE(w,a)):(s.months||s.years)&&P(ig(w))},focusSectionEnd(){s.days?P(D):s.weeks?P(iE(w,a,void 0).add({days:6})):(s.months||s.years)&&P(iw(w))},focusNextSection(e){e||s.days?s.days?this.focusNextPage():s.weeks?P(w.add({months:1})):(s.months||s.years)&&P(w.add({years:1})):P(w.add(aq(s)))},focusPreviousSection(e){e||s.days?s.days?this.focusPreviousPage():s.weeks?P(w.subtract({months:1})):(s.months||s.years)&&P(w.subtract({years:1})):P(w.subtract(aq(s)))},selectFocusedDate(){f&&f(w)||k(w)},selectDate(e){k(e)},isFocused:A,setFocused:x,isInvalid:e=>aL(e,l,c),isSelected(e){return null!=v&&iu(e,v)&&!this.isCellDisabled(e)&&!this.isCellUnavailable(e)},isCellFocused:e=>A&&w&&iu(e,w),isCellDisabled(t){return e.isDisabled||0>t.compare(S)||t.compare(D)>0||this.isInvalid(t)},isCellUnavailable:t=>!!e.isDateUnavailable&&e.isDateUnavailable(t),isPreviousVisibleRangeInvalid(){let e=S.subtract({days:1});return iu(e,S)||this.isInvalid(e)},isNextVisibleRangeInvalid(){let e=D.add({days:1});return iu(e,D)||this.isInvalid(e)},getDatesInWeek(e,t=S){let r=t.add({weeks:e}),n=[],o=id(r=iE(r,a,h),a,h);for(let e=0;e<o;e++)n.push(null);for(;n.length<7;){n.push(r);let e=r.add({days:1});if(iu(r,e))break;r=e}for(;n.length<7;)n.push(null);return n}}}function aq(e){let t={...e};for(let r in e)t[r]=1;return t}function aZ(e,t){return e&&t?(0>t.compare(e)&&([e,t]=[t,e]),{start:ir(e),end:ir(t)}):null}function aY(e,t){return(e=ii(e,(null==t?void 0:t.calendar)||new oC),t&&"hour"in t)?t.set(e):e}function aJ(e,t,r){let n=e.add({days:r});for(;(r<0?n.compare(t.visibleRange.start)>=0:0>=n.compare(t.visibleRange.end))&&!t.isCellUnavailable(n);)n=n.add({days:r});if(t.isCellUnavailable(n))return n.add({days:-r})}let aX=(0,em.createContext)(null),aQ=(0,em.createContext)(null),a0=(0,em.createContext)(null),a1=(0,em.createContext)(null),a2=(0,em.forwardRef)(function(e,t){[e,t]=rN(e,t,aX);let{locale:r}=oE(),n=aG({...e,locale:r,createCalendar:e.createCalendar||aB}),{calendarProps:o,prevButtonProps:i,nextButtonProps:a,errorMessageProps:u,title:s}=iY(e,n),l=rR({...e,values:{state:n,isDisabled:e.isDisabled||!1,isInvalid:n.isValueInvalid},defaultClassName:"react-aria-Calendar"});return ey().createElement("div",{...l,...o,ref:t,slot:e.slot||void 0,"data-disabled":e.isDisabled||void 0,"data-invalid":n.isValueInvalid||void 0},ey().createElement(rT,{values:[[oi,{slots:{previous:i,next:a}}],[ou,{"aria-hidden":!0,level:2,children:s}],[a0,n],[aX,e],[os,{slots:{errorMessage:u}}]]},ey().createElement(iX,null,ey().createElement("h2",null,o["aria-label"])),l.children,ey().createElement(iX,null,ey().createElement("button",{"aria-label":a["aria-label"],disabled:a.isDisabled,onClick:()=>n.focusNextPage(),tabIndex:-1}))))}),a3=(0,em.forwardRef)(function(e,t){var r,n;let o,i,a;[e,t]=rN(e,t,aQ);let{locale:u}=oE(),s=function(e){let{value:t,defaultValue:r,onChange:n,createCalendar:o,locale:i,visibleDuration:a={months:1},minValue:u,maxValue:s,...l}=e,[c,d]=aH(t,r||null,n),[f,p]=(0,em.useState)(null),h="center";if(c&&c.start&&c.end){let e=aV(ir(c.start),a,i,u,s).add(a).subtract({days:1});c.end.compare(e)>0&&(h="start")}let m=(0,em.useRef)(null),[y,b]=(0,em.useState)(null),v=(0,em.useMemo)(()=>iA(u,null==y?void 0:y.start),[u,y]),g=(0,em.useMemo)(()=>iO(s,null==y?void 0:y.end),[s,y]),w=aG({...l,value:c&&c.start,createCalendar:o,locale:i,visibleDuration:a,minValue:v,maxValue:g,selectionAlignment:h}),E=t=>{t&&e.isDateUnavailable&&!e.allowsNonContiguousRanges?(m.current={start:aJ(t,w,-1),end:aJ(t,w,1)},b(m.current)):(m.current=null,b(null))},[S,O]=(0,em.useState)(w.visibleRange);is(w.visibleRange.start,S.start)&&is(w.visibleRange.end,S.end)||(E(f),O(w.visibleRange));let A=e=>{e?(p(e),E(e)):(p(null),E(null))},x=f?aZ(f,w.focusedDate):c&&aZ(c.start,c.end),D=t=>{if(e.isReadOnly)return;let r=aK(az(t,v,g),w.visibleRange.start,e.isDateUnavailable);if(r)if(f){let e=aZ(f,r);e&&d({start:aY(e.start,null==c?void 0:c.start),end:aY(e.end,null==c?void 0:c.end)}),A(null)}else A(r)},[j,C]=(0,em.useState)(!1),{isDateUnavailable:P}=e,k=(0,em.useMemo)(()=>!!c&&!f&&(!!(P&&(P(c.start)||P(c.end)))||aL(c.start,u,s)||aL(c.end,u,s)),[P,c,f,u,s]),I=e.isInvalid||"invalid"===e.validationState||k;return{...w,value:c,setValue:d,anchorDate:f,setAnchorDate:A,highlightedRange:x,validationState:I?"invalid":null,isValueInvalid:I,selectFocusedDate(){D(w.focusedDate)},selectDate:D,highlightDate(e){f&&w.setFocusedDate(e)},isSelected:e=>!!(x&&e.compare(x.start)>=0&&0>=e.compare(x.end)&&!w.isCellDisabled(e)&&!w.isCellUnavailable(e)),isInvalid(e){var t,r;return w.isInvalid(e)||aL(e,null==(t=m.current)?void 0:t.start,null==(r=m.current)?void 0:r.end)},isDragging:j,setDragging:C}}({...e,locale:u,createCalendar:e.createCalendar||aB}),{calendarProps:l,prevButtonProps:c,nextButtonProps:d,errorMessageProps:f,title:p}=(r=e,n=t,o=iY(r,s),i=(0,em.useRef)(!1),iQ(a=(0,em.useRef)("u">typeof window?window:null),"pointerdown",e=>{i.current=0===e.width&&0===e.height}),iQ(a,"pointerup",e=>{if(i.current){i.current=!1;return}if(s.setDragging(!1),!s.anchorDate)return;let t=e.target;n.current&&n.current.contains(document.activeElement)&&(!n.current.contains(t)||!t.closest('button, [role="button"]'))&&s.selectFocusedDate()}),o.calendarProps.onBlur=e=>{n.current&&(e.relatedTarget&&n.current.contains(e.relatedTarget)||!s.anchorDate||s.selectFocusedDate())},iQ(n,"touchmove",e=>{s.isDragging&&e.preventDefault()},{passive:!1,capture:!0}),o),h=rR({...e,values:{state:s,isDisabled:e.isDisabled||!1,isInvalid:s.isValueInvalid},defaultClassName:"react-aria-RangeCalendar"});return ey().createElement("div",{...h,...l,ref:t,slot:e.slot||void 0,"data-disabled":e.isDisabled||void 0,"data-invalid":s.isValueInvalid||void 0},ey().createElement(rT,{values:[[oi,{slots:{previous:c,next:d}}],[ou,{"aria-hidden":!0,level:2,children:p}],[a1,s],[aQ,e],[os,{slots:{errorMessage:f}}]]},ey().createElement(iX,null,ey().createElement("h2",null,l["aria-label"])),h.children,ey().createElement(iX,null,ey().createElement("button",{"aria-label":d["aria-label"],disabled:d.isDisabled,onClick:()=>s.focusNextPage(),tabIndex:-1}))))}),a4=(0,em.createContext)(null),a6=(0,em.forwardRef)(function(e,t){var r,n;let o=(0,em.useContext)(a0),i=(0,em.useContext)(a1),a=rF(aX),u=rF(aQ),s=null!=o?o:i,l=s.visibleRange.start;e.offset&&(l=l.add(e.offset));let c=null!=(r=null==a?void 0:a.firstDayOfWeek)?r:null==u?void 0:u.firstDayOfWeek,{gridProps:d,headerProps:f,weekDays:p,weeksInMonth:h}=function(e,t){let r,{startDate:n=t.visibleRange.start,endDate:o=t.visibleRange.end,firstDayOfWeek:i}=e,{direction:a}=oE(),u=iH(n,o,t.timeZone,!0),{ariaLabel:s,ariaLabelledBy:l}=iz.get(t),c=iZ({"aria-label":[s,u].filter(Boolean).join(", "),"aria-labelledby":l}),d=iU({weekday:e.weekdayStyle||"narrow",timeZone:t.timeZone}),{locale:f}=oE(),p=(0,em.useMemo)(()=>{let e=iE(ih(t.timeZone),f,i);return[...Array(7).keys()].map(r=>{let n=e.add({days:r}).toDate(t.timeZone);return d.format(n)})},[f,t.timeZone,d,i]),h=(r=n.calendar.getDaysInMonth(n),Math.ceil((id(ig(n),f,i)+r)/7));return{gridProps:rk(c,{role:"grid","aria-readonly":t.isReadOnly||void 0,"aria-disabled":t.isDisabled||void 0,"aria-multiselectable":"highlightedRange"in t||void 0,onKeyDown:e=>{switch(e.key){case"Enter":case" ":e.preventDefault(),t.selectFocusedDate();break;case"PageUp":e.preventDefault(),e.stopPropagation(),t.focusPreviousSection(e.shiftKey);break;case"PageDown":e.preventDefault(),e.stopPropagation(),t.focusNextSection(e.shiftKey);break;case"End":e.preventDefault(),e.stopPropagation(),t.focusSectionEnd();break;case"Home":e.preventDefault(),e.stopPropagation(),t.focusSectionStart();break;case"ArrowLeft":e.preventDefault(),e.stopPropagation(),"rtl"===a?t.focusNextDay():t.focusPreviousDay();break;case"ArrowUp":e.preventDefault(),e.stopPropagation(),t.focusPreviousRow();break;case"ArrowRight":e.preventDefault(),e.stopPropagation(),"rtl"===a?t.focusPreviousDay():t.focusNextDay();break;case"ArrowDown":e.preventDefault(),e.stopPropagation(),t.focusNextRow();break;case"Escape":"setAnchorDate"in t&&(e.preventDefault(),t.setAnchorDate(null))}},onFocus:()=>t.setFocused(!0),onBlur:()=>t.setFocused(!1)}),headerProps:{"aria-hidden":!0},weekDays:p,weeksInMonth:h}}({startDate:l,endDate:iw(l),weekdayStyle:e.weekdayStyle,firstDayOfWeek:c},s);return ey().createElement(a4.Provider,{value:{headerProps:f,weekDays:p,startDate:l,weeksInMonth:h}},ey().createElement("table",{...rG(e),...d,ref:t,style:e.style,className:null!=(n=e.className)?n:"react-aria-CalendarGrid"},"function"!=typeof e.children?e.children:ey().createElement(ey().Fragment,null,ey().createElement(a5,null,e=>ey().createElement(a8,null,e)),ey().createElement(a7,null,e.children))))}),a5=(0,em.forwardRef)(function(e,t){let{children:r,style:n,className:o}=e,{headerProps:i,weekDays:a}=(0,em.useContext)(a4);return ey().createElement("thead",{...rG(e),...i,ref:t,style:n,className:o||"react-aria-CalendarGridHeader"},ey().createElement("tr",null,a.map((e,t)=>ey().cloneElement(r(e),{key:t}))))}),a8=(0,em.forwardRef)(function(e,t){let{children:r,style:n,className:o}=e;return ey().createElement("th",{...rG(e),ref:t,style:n,className:o||"react-aria-CalendarHeaderCell"},r)}),a7=(0,em.forwardRef)(function(e,t){let{children:r,style:n,className:o}=e,i=(0,em.useContext)(a0),a=(0,em.useContext)(a1),u=null!=i?i:a,{startDate:s,weeksInMonth:l}=(0,em.useContext)(a4);return ey().createElement("tbody",{...rG(e),ref:t,style:n,className:o||"react-aria-CalendarGridBody"},[...Array(l).keys()].map(e=>ey().createElement("tr",{key:e},u.getDatesInWeek(e,s).map((e,t)=>e?ey().cloneElement(r(e),{key:t}):ey().createElement("td",{key:t})))))}),a9=(0,em.forwardRef)(function({date:e,...t},r){var n,o,i;let a=(0,em.useContext)(a0),u=(0,em.useContext)(a1),s=null!=a?a:u,{startDate:l}=null!=(n=(0,em.useContext)(a4))?n:{startDate:s.visibleRange.start},c=(0,em.useRef)(null),{cellProps:d,buttonProps:f,...p}=function(e,t,r){var n;let o,{date:i,isDisabled:a}=e,{errorMessageId:u,selectedDateDescription:s}=iz.get(t),l=iT((n=oS)&&n.__esModule?n.default:n,"@react-aria/calendar"),c=iU({weekday:"long",day:"numeric",month:"long",year:"numeric",era:iK(i),timeZone:t.timeZone}),d=t.isSelected(i),f=t.isCellFocused(i);a=a||t.isCellDisabled(i);let p=t.isCellUnavailable(i),h=!a&&!p,m=t.isValueInvalid&&!!("highlightedRange"in t?!t.anchorDate&&t.highlightedRange&&i.compare(t.highlightedRange.start)>=0&&0>=i.compare(t.highlightedRange.end):t.value&&iu(t.value,i));m&&(d=!0),i=iV(i,is);let y=(0,em.useMemo)(()=>i.toDate(t.timeZone),[i,t.timeZone]),b=iu(i,ih(t.timeZone)),v=(0,em.useMemo)(()=>{let e="";return"highlightedRange"in t&&t.value&&!t.anchorDate&&(iu(i,t.value.start)||iu(i,t.value.end))&&(e=s+", "),e+=c.format(y),b?e=l.format(d?"todayDateSelected":"todayDate",{date:e}):d&&(e=l.format("dateSelected",{date:e})),t.minValue&&iu(i,t.minValue)?e+=", "+l.format("minimumDate"):t.maxValue&&iu(i,t.maxValue)&&(e+=", "+l.format("maximumDate")),e},[c,y,l,d,b,i,t,s]),g="";"anchorDate"in t&&f&&!t.isReadOnly&&h&&(g=t.anchorDate?l.format("finishRangeSelectionPrompt"):l.format("startRangeSelectionPrompt"));let w=i2(g),E=(0,em.useRef)(!1),S=(0,em.useRef)(!1),O=(0,em.useRef)(void 0),{pressProps:A,isPressed:x}=nk({shouldCancelOnPointerExit:"anchorDate"in t&&!!t.anchorDate,preventFocusOnPress:!0,isDisabled:!h||t.isReadOnly,onPressStart(e){if(t.isReadOnly)return void t.setFocusedDate(i);if("highlightedRange"in t&&!t.anchorDate&&("mouse"===e.pointerType||"touch"===e.pointerType)){if(t.highlightedRange&&!m){if(iu(i,t.highlightedRange.start)){t.setAnchorDate(t.highlightedRange.end),t.setFocusedDate(i),t.setDragging(!0),S.current=!0;return}else if(iu(i,t.highlightedRange.end)){t.setAnchorDate(t.highlightedRange.start),t.setFocusedDate(i),t.setDragging(!0),S.current=!0;return}}let r=()=>{t.setDragging(!0),O.current=void 0,t.selectDate(i),t.setFocusedDate(i),E.current=!0};"touch"===e.pointerType?O.current=setTimeout(r,200):r()}},onPressEnd(){S.current=!1,E.current=!1,clearTimeout(O.current),O.current=void 0},onPress(){"anchorDate"in t||t.isReadOnly||(t.selectDate(i),t.setFocusedDate(i))},onPressUp(e){if(!t.isReadOnly&&("anchorDate"in t&&O.current&&(t.selectDate(i),t.setFocusedDate(i)),"anchorDate"in t))if(S.current)t.setAnchorDate(i);else if(t.anchorDate&&!E.current)t.selectDate(i),t.setFocusedDate(i);else if("keyboard"!==e.pointerType||t.anchorDate)"virtual"===e.pointerType&&(t.selectDate(i),t.setFocusedDate(i));else{t.selectDate(i);let e=i.add({days:1});t.isInvalid(e)&&(e=i.subtract({days:1})),t.isInvalid(e)||t.setFocusedDate(e)}}});a||(o=iu(i,t.focusedDate)?0:-1),(0,em.useEffect)(()=>{f&&r.current&&(r1(r.current),"pointer"!==nB&&document.activeElement===r.current&&i6(r.current,{containingElement:i5(r.current)}))},[f,r]);let D=iU({day:"numeric",timeZone:t.timeZone,calendar:i.calendar.identifier}),j=(0,em.useMemo)(()=>D.formatToParts(y).find(e=>"day"===e.type).value,[D,y]);return{cellProps:{role:"gridcell","aria-disabled":!h||void 0,"aria-selected":d||void 0,"aria-invalid":m||void 0},buttonProps:rk(A,{onFocus(){a||t.setFocusedDate(i)},tabIndex:o,role:"button","aria-disabled":!h||void 0,"aria-label":v,"aria-invalid":m||void 0,"aria-describedby":[m?u:void 0,w["aria-describedby"]].filter(Boolean).join(" ")||void 0,onPointerEnter(e){"highlightDate"in t&&("touch"!==e.pointerType||t.isDragging)&&h&&t.highlightDate(i)},onPointerDown(e){"releasePointerCapture"in e.target&&e.target.releasePointerCapture(e.pointerId)},onContextMenu(e){e.preventDefault()}}),isPressed:x,isFocused:f,isSelected:d,isDisabled:a,isUnavailable:p,isOutsideVisibleRange:0>i.compare(t.visibleRange.start)||i.compare(t.visibleRange.end)>0,isInvalid:m,formattedDate:j}}({date:e},s,c),{hoverProps:h,isHovered:m}=ot({...t,isDisabled:p.isDisabled}),{focusProps:y,isFocusVisible:b}=n5();b&&(b=p.isFocused);let v=(o=l,i=ii(i=e,o.calendar),o=ig(o),i=ig(i),o.era!==i.era||o.year!==i.year||o.month!==i.month),g=!1,w=!1;"highlightedRange"in s&&s.highlightedRange&&(g=iu(e,s.highlightedRange.start),w=iu(e,s.highlightedRange.end));let E=rR({...t,defaultChildren:p.formattedDate,defaultClassName:"react-aria-CalendarCell",values:{date:e,isHovered:m,isOutsideMonth:v,isFocusVisible:b,isSelectionStart:g,isSelectionEnd:w,...p}}),S={"data-focused":p.isFocused||void 0,"data-hovered":m||void 0,"data-pressed":p.isPressed||void 0,"data-unavailable":p.isUnavailable||void 0,"data-disabled":p.isDisabled||void 0,"data-focus-visible":b||void 0,"data-outside-visible-range":p.isOutsideVisibleRange||void 0,"data-outside-month":v||void 0,"data-selected":p.isSelected||void 0,"data-selection-start":g||void 0,"data-selection-end":w||void 0,"data-invalid":p.isInvalid||void 0};return ey().createElement("td",{...d,ref:r},ey().createElement("div",{...rk(rG(t),f,y,h,S,E),ref:c}))}),ue=(0,em.createContext)({}),ut=(0,em.forwardRef)(function(e,t){var r,n;[e,t]=rN(e,t,ue);let{isDisabled:o,isInvalid:i,onHoverStart:a,onHoverChange:u,onHoverEnd:s,...l}=e,{hoverProps:c,isHovered:d}=ot({onHoverStart:a,onHoverChange:u,onHoverEnd:s,isDisabled:o}),{isFocused:f,isFocusVisible:p,focusProps:h}=n5({within:!0});null!=o||(o=!!e["aria-disabled"]&&"false"!==e["aria-disabled"]),null!=i||(i=!!e["aria-invalid"]&&"false"!==e["aria-invalid"]);let m=rR({...e,values:{isHovered:d,isFocusWithin:f,isFocusVisible:p,isDisabled:o,isInvalid:i},defaultClassName:"react-aria-Group"});return ey().createElement("div",{...rk(l,h,c),...m,ref:t,role:null!=(r=e.role)?r:"group",slot:null!=(n=e.slot)?n:void 0,"data-focus-within":f||void 0,"data-hovered":d||void 0,"data-focus-visible":p||void 0,"data-disabled":o||void 0,"data-invalid":i||void 0},m.children)}),ur=(0,em.createContext)({}),un=on(function(e,t){[e,t]=rN(e,t,ur);let{hoverProps:r,isHovered:n}=ot(e),{isFocused:o,isFocusVisible:i,focusProps:a}=n5({isTextInput:!0,autoFocus:e.autoFocus}),u=!!e["aria-invalid"]&&"false"!==e["aria-invalid"],s=rR({...e,values:{isHovered:n,isFocused:o,isFocusVisible:i,isDisabled:e.disabled||!1,isInvalid:u},defaultClassName:"react-aria-Input"});return ey().createElement("input",{...rk((e=>{let{onHoverStart:t,onHoverChange:r,onHoverEnd:n,...o}=e;return o})(e),a,r),...s,ref:t,"data-focused":o||void 0,"data-disabled":e.disabled||void 0,"data-hovered":n||void 0,"data-focus-visible":i||void 0,"data-invalid":u||void 0})});var uo={};uo={"ar-AE":{calendar:"التقويم",day:"يوم",dayPeriod:"ص/م",endDate:"تاريخ الانتهاء",era:"العصر",hour:"الساعات",minute:"الدقائق",month:"الشهر",second:"الثواني",selectedDateDescription:e=>`\u{62A}\u{627}\u{631}\u{64A}\u{62E} \u{645}\u{62D}\u{62F}\u{62F}: ${e.date}`,selectedRangeDescription:e=>`\u{627}\u{644}\u{645}\u{62F}\u{649} \u{627}\u{644}\u{632}\u{645}\u{646}\u{64A} \u{627}\u{644}\u{645}\u{62D}\u{62F}\u{62F}: ${e.startDate} \u{625}\u{644}\u{649} ${e.endDate}`,selectedTimeDescription:e=>`\u{627}\u{644}\u{648}\u{642}\u{62A} \u{627}\u{644}\u{645}\u{62D}\u{62F}\u{62F}: ${e.time}`,startDate:"تاريخ البدء",timeZoneName:"التوقيت",weekday:"اليوم",year:"السنة"},"bg-BG":{calendar:"Календар",day:"ден",dayPeriod:"пр.об./сл.об.",endDate:"Крайна дата",era:"ера",hour:"час",minute:"минута",month:"месец",second:"секунда",selectedDateDescription:e=>`\u{418}\u{437}\u{431}\u{440}\u{430}\u{43D}\u{430} \u{434}\u{430}\u{442}\u{430}: ${e.date}`,selectedRangeDescription:e=>`\u{418}\u{437}\u{431}\u{440}\u{430}\u{43D} \u{434}\u{438}\u{430}\u{43F}\u{430}\u{437}\u{43E}\u{43D}: ${e.startDate} \u{434}\u{43E} ${e.endDate}`,selectedTimeDescription:e=>`\u{418}\u{437}\u{431}\u{440}\u{430}\u{43D}\u{43E} \u{432}\u{440}\u{435}\u{43C}\u{435}: ${e.time}`,startDate:"Начална дата",timeZoneName:"часова зона",weekday:"ден от седмицата",year:"година"},"cs-CZ":{calendar:"Kalend\xe1ř",day:"den",dayPeriod:"č\xe1st dne",endDate:"Konečn\xe9 datum",era:"letopočet",hour:"hodina",minute:"minuta",month:"měs\xedc",second:"sekunda",selectedDateDescription:e=>`Vybran\xe9 datum: ${e.date}`,selectedRangeDescription:e=>`Vybran\xe9 obdob\xed: ${e.startDate} a\u{17E} ${e.endDate}`,selectedTimeDescription:e=>`Vybran\xfd \u{10D}as: ${e.time}`,startDate:"Poč\xe1tečn\xed datum",timeZoneName:"časov\xe9 p\xe1smo",weekday:"den v t\xfddnu",year:"rok"},"da-DK":{calendar:"Kalender",day:"dag",dayPeriod:"AM/PM",endDate:"Slutdato",era:"\xe6ra",hour:"time",minute:"minut",month:"m\xe5ned",second:"sekund",selectedDateDescription:e=>`Valgt dato: ${e.date}`,selectedRangeDescription:e=>`Valgt interval: ${e.startDate} til ${e.endDate}`,selectedTimeDescription:e=>`Valgt tidspunkt: ${e.time}`,startDate:"Startdato",timeZoneName:"tidszone",weekday:"ugedag",year:"\xe5r"},"de-DE":{calendar:"Kalender",day:"Tag",dayPeriod:"Tagesh\xe4lfte",endDate:"Enddatum",era:"Epoche",hour:"Stunde",minute:"Minute",month:"Monat",second:"Sekunde",selectedDateDescription:e=>`Ausgew\xe4hltes Datum: ${e.date}`,selectedRangeDescription:e=>`Ausgew\xe4hlter Bereich: ${e.startDate} bis ${e.endDate}`,selectedTimeDescription:e=>`Ausgew\xe4hlte Zeit: ${e.time}`,startDate:"Anfangsdatum",timeZoneName:"Zeitzone",weekday:"Wochentag",year:"Jahr"},"el-GR":{calendar:"Ημερολόγιο",day:"ημέρα",dayPeriod:"π.μ./μ.μ.",endDate:"Ημερομηνία λήξης",era:"περίοδος",hour:"ώρα",minute:"λεπτό",month:"μήνας",second:"δευτερόλεπτο",selectedDateDescription:e=>`\u{395}\u{3C0}\u{3B9}\u{3BB}\u{3B5}\u{3B3}\u{3BC}\u{3AD}\u{3BD}\u{3B7} \u{3B7}\u{3BC}\u{3B5}\u{3C1}\u{3BF}\u{3BC}\u{3B7}\u{3BD}\u{3AF}\u{3B1}: ${e.date}`,selectedRangeDescription:e=>`\u{395}\u{3C0}\u{3B9}\u{3BB}\u{3B5}\u{3B3}\u{3BC}\u{3AD}\u{3BD}\u{3BF} \u{3B5}\u{3CD}\u{3C1}\u{3BF}\u{3C2}: ${e.startDate} \u{3AD}\u{3C9}\u{3C2} ${e.endDate}`,selectedTimeDescription:e=>`\u{395}\u{3C0}\u{3B9}\u{3BB}\u{3B5}\u{3B3}\u{3BC}\u{3AD}\u{3BD}\u{3B7} \u{3CE}\u{3C1}\u{3B1}: ${e.time}`,startDate:"Ημερομηνία έναρξης",timeZoneName:"ζώνη ώρας",weekday:"καθημερινή",year:"έτος"},"en-US":{era:"era",year:"year",month:"month",day:"day",hour:"hour",minute:"minute",second:"second",dayPeriod:"AM/PM",calendar:"Calendar",startDate:"Start Date",endDate:"End Date",weekday:"day of the week",timeZoneName:"time zone",selectedDateDescription:e=>`Selected Date: ${e.date}`,selectedRangeDescription:e=>`Selected Range: ${e.startDate} to ${e.endDate}`,selectedTimeDescription:e=>`Selected Time: ${e.time}`},"es-ES":{calendar:"Calendario",day:"d\xeda",dayPeriod:"a.\xa0m./p.\xa0m.",endDate:"Fecha final",era:"era",hour:"hora",minute:"minuto",month:"mes",second:"segundo",selectedDateDescription:e=>`Fecha seleccionada: ${e.date}`,selectedRangeDescription:e=>`Rango seleccionado: ${e.startDate} a ${e.endDate}`,selectedTimeDescription:e=>`Hora seleccionada: ${e.time}`,startDate:"Fecha de inicio",timeZoneName:"zona horaria",weekday:"d\xeda de la semana",year:"a\xf1o"},"et-EE":{calendar:"Kalender",day:"p\xe4ev",dayPeriod:"enne/p\xe4rast l\xf5unat",endDate:"L\xf5ppkuup\xe4ev",era:"ajastu",hour:"tund",minute:"minut",month:"kuu",second:"sekund",selectedDateDescription:e=>`Valitud kuup\xe4ev: ${e.date}`,selectedRangeDescription:e=>`Valitud vahemik: ${e.startDate} kuni ${e.endDate}`,selectedTimeDescription:e=>`Valitud aeg: ${e.time}`,startDate:"Alguskuup\xe4ev",timeZoneName:"ajav\xf6\xf6nd",weekday:"n\xe4dalap\xe4ev",year:"aasta"},"fi-FI":{calendar:"Kalenteri",day:"p\xe4iv\xe4",dayPeriod:"vuorokaudenaika",endDate:"P\xe4\xe4ttymisp\xe4iv\xe4",era:"aikakausi",hour:"tunti",minute:"minuutti",month:"kuukausi",second:"sekunti",selectedDateDescription:e=>`Valittu p\xe4iv\xe4m\xe4\xe4r\xe4: ${e.date}`,selectedRangeDescription:e=>`Valittu aikav\xe4li: ${e.startDate} \u{2013} ${e.endDate}`,selectedTimeDescription:e=>`Valittu aika: ${e.time}`,startDate:"Alkamisp\xe4iv\xe4",timeZoneName:"aikavy\xf6hyke",weekday:"viikonp\xe4iv\xe4",year:"vuosi"},"fr-FR":{calendar:"Calendrier",day:"jour",dayPeriod:"cadran",endDate:"Date de fin",era:"\xe8re",hour:"heure",minute:"minute",month:"mois",second:"seconde",selectedDateDescription:e=>`Date s\xe9lectionn\xe9e\xa0: ${e.date}`,selectedRangeDescription:e=>`Plage s\xe9lectionn\xe9e\xa0: ${e.startDate} au ${e.endDate}`,selectedTimeDescription:e=>`Heure choisie\xa0: ${e.time}`,startDate:"Date de d\xe9but",timeZoneName:"fuseau horaire",weekday:"jour de la semaine",year:"ann\xe9e"},"he-IL":{calendar:"לוח שנה",day:"יום",dayPeriod:"לפנה״צ/אחה״צ",endDate:"תאריך סיום",era:"תקופה",hour:"שעה",minute:"דקה",month:"חודש",second:"שנייה",selectedDateDescription:e=>`\u{5EA}\u{5D0}\u{5E8}\u{5D9}\u{5DA} \u{5E0}\u{5D1}\u{5D7}\u{5E8}: ${e.date}`,selectedRangeDescription:e=>`\u{5D8}\u{5D5}\u{5D5}\u{5D7} \u{5E0}\u{5D1}\u{5D7}\u{5E8}: ${e.startDate} \u{5E2}\u{5D3} ${e.endDate}`,selectedTimeDescription:e=>`\u{5D6}\u{5DE}\u{5DF} \u{5E0}\u{5D1}\u{5D7}\u{5E8}: ${e.time}`,startDate:"תאריך התחלה",timeZoneName:"אזור זמן",weekday:"יום בשבוע",year:"שנה"},"hr-HR":{calendar:"Kalendar",day:"dan",dayPeriod:"AM/PM",endDate:"Datum završetka",era:"era",hour:"sat",minute:"minuta",month:"mjesec",second:"sekunda",selectedDateDescription:e=>`Odabrani datum: ${e.date}`,selectedRangeDescription:e=>`Odabrani raspon: ${e.startDate} do ${e.endDate}`,selectedTimeDescription:e=>`Odabrano vrijeme: ${e.time}`,startDate:"Datum početka",timeZoneName:"vremenska zona",weekday:"dan u tjednu",year:"godina"},"hu-HU":{calendar:"Napt\xe1r",day:"nap",dayPeriod:"napszak",endDate:"Befejező d\xe1tum",era:"\xe9ra",hour:"\xf3ra",minute:"perc",month:"h\xf3nap",second:"m\xe1sodperc",selectedDateDescription:e=>`Kijel\xf6lt d\xe1tum: ${e.date}`,selectedRangeDescription:e=>`Kijel\xf6lt tartom\xe1ny: ${e.startDate}\u{2013}${e.endDate}`,selectedTimeDescription:e=>`Kijel\xf6lt id\u{151}: ${e.time}`,startDate:"Kezdő d\xe1tum",timeZoneName:"időz\xf3na",weekday:"h\xe9t napja",year:"\xe9v"},"it-IT":{calendar:"Calendario",day:"giorno",dayPeriod:"AM/PM",endDate:"Data finale",era:"era",hour:"ora",minute:"minuto",month:"mese",second:"secondo",selectedDateDescription:e=>`Data selezionata: ${e.date}`,selectedRangeDescription:e=>`Intervallo selezionato: da ${e.startDate} a ${e.endDate}`,selectedTimeDescription:e=>`Ora selezionata: ${e.time}`,startDate:"Data iniziale",timeZoneName:"fuso orario",weekday:"giorno della settimana",year:"anno"},"ja-JP":{calendar:"カレンダー",day:"日",dayPeriod:"午前/午後",endDate:"終了日",era:"時代",hour:"時",minute:"分",month:"月",second:"秒",selectedDateDescription:e=>`\u{9078}\u{629E}\u{3057}\u{305F}\u{65E5}\u{4ED8} : ${e.date}`,selectedRangeDescription:e=>`\u{9078}\u{629E}\u{7BC4}\u{56F2} : ${e.startDate} \u{304B}\u{3089} ${e.endDate}`,selectedTimeDescription:e=>`\u{9078}\u{629E}\u{3057}\u{305F}\u{6642}\u{9593} : ${e.time}`,startDate:"開始日",timeZoneName:"タイムゾーン",weekday:"曜日",year:"年"},"ko-KR":{calendar:"달력",day:"일",dayPeriod:"오전/오후",endDate:"종료일",era:"연호",hour:"시",minute:"분",month:"월",second:"초",selectedDateDescription:e=>`\u{C120}\u{D0DD} \u{C77C}\u{C790}: ${e.date}`,selectedRangeDescription:e=>`\u{C120}\u{D0DD} \u{BC94}\u{C704}: ${e.startDate} ~ ${e.endDate}`,selectedTimeDescription:e=>`\u{C120}\u{D0DD} \u{C2DC}\u{AC04}: ${e.time}`,startDate:"시작일",timeZoneName:"시간대",weekday:"요일",year:"년"},"lt-LT":{calendar:"Kalendorius",day:"diena",dayPeriod:"iki pietų / po pietų",endDate:"Pabaigos data",era:"era",hour:"valanda",minute:"minutė",month:"mėnuo",second:"sekundė",selectedDateDescription:e=>`Pasirinkta data: ${e.date}`,selectedRangeDescription:e=>`Pasirinktas intervalas: nuo ${e.startDate} iki ${e.endDate}`,selectedTimeDescription:e=>`Pasirinktas laikas: ${e.time}`,startDate:"Pradžios data",timeZoneName:"laiko juosta",weekday:"savaitės diena",year:"metai"},"lv-LV":{calendar:"Kalendārs",day:"diena",dayPeriod:"priekšpusdienā/pēcpusdienā",endDate:"Beigu datums",era:"ēra",hour:"stundas",minute:"minūtes",month:"mēnesis",second:"sekundes",selectedDateDescription:e=>`Atlas\u{12B}tais datums: ${e.date}`,selectedRangeDescription:e=>`Atlas\u{12B}tais diapazons: no ${e.startDate} l\u{12B}dz ${e.endDate}`,selectedTimeDescription:e=>`Atlas\u{12B}tais laiks: ${e.time}`,startDate:"Sākuma datums",timeZoneName:"laika josla",weekday:"nedēļas diena",year:"gads"},"nb-NO":{calendar:"Kalender",day:"dag",dayPeriod:"a.m./p.m.",endDate:"Sluttdato",era:"tidsalder",hour:"time",minute:"minutt",month:"m\xe5ned",second:"sekund",selectedDateDescription:e=>`Valgt dato: ${e.date}`,selectedRangeDescription:e=>`Valgt omr\xe5de: ${e.startDate} til ${e.endDate}`,selectedTimeDescription:e=>`Valgt tid: ${e.time}`,startDate:"Startdato",timeZoneName:"tidssone",weekday:"ukedag",year:"\xe5r"},"nl-NL":{calendar:"Kalender",day:"dag",dayPeriod:"a.m./p.m.",endDate:"Einddatum",era:"tijdperk",hour:"uur",minute:"minuut",month:"maand",second:"seconde",selectedDateDescription:e=>`Geselecteerde datum: ${e.date}`,selectedRangeDescription:e=>`Geselecteerd bereik: ${e.startDate} tot ${e.endDate}`,selectedTimeDescription:e=>`Geselecteerde tijd: ${e.time}`,startDate:"Startdatum",timeZoneName:"tijdzone",weekday:"dag van de week",year:"jaar"},"pl-PL":{calendar:"Kalendarz",day:"dzień",dayPeriod:"rano / po południu / wieczorem",endDate:"Data końcowa",era:"era",hour:"godzina",minute:"minuta",month:"miesiąc",second:"sekunda",selectedDateDescription:e=>`Wybrana data: ${e.date}`,selectedRangeDescription:e=>`Wybrany zakres: ${e.startDate} do ${e.endDate}`,selectedTimeDescription:e=>`Wybrany czas: ${e.time}`,startDate:"Data początkowa",timeZoneName:"strefa czasowa",weekday:"dzień tygodnia",year:"rok"},"pt-BR":{calendar:"Calend\xe1rio",day:"dia",dayPeriod:"AM/PM",endDate:"Data final",era:"era",hour:"hora",minute:"minuto",month:"m\xeas",second:"segundo",selectedDateDescription:e=>`Data selecionada: ${e.date}`,selectedRangeDescription:e=>`Intervalo selecionado: ${e.startDate} a ${e.endDate}`,selectedTimeDescription:e=>`Hora selecionada: ${e.time}`,startDate:"Data inicial",timeZoneName:"fuso hor\xe1rio",weekday:"dia da semana",year:"ano"},"pt-PT":{calendar:"Calend\xe1rio",day:"dia",dayPeriod:"am/pm",endDate:"Data de T\xe9rmino",era:"era",hour:"hora",minute:"minuto",month:"m\xeas",second:"segundo",selectedDateDescription:e=>`Data selecionada: ${e.date}`,selectedRangeDescription:e=>`Intervalo selecionado: ${e.startDate} a ${e.endDate}`,selectedTimeDescription:e=>`Hora selecionada: ${e.time}`,startDate:"Data de In\xedcio",timeZoneName:"fuso hor\xe1rio",weekday:"dia da semana",year:"ano"},"ro-RO":{calendar:"Calendar",day:"zi",dayPeriod:"a.m/p.m.",endDate:"Dată final",era:"eră",hour:"oră",minute:"minut",month:"lună",second:"secundă",selectedDateDescription:e=>`Dat\u{103} selectat\u{103}: ${e.date}`,selectedRangeDescription:e=>`Interval selectat: de la ${e.startDate} p\xe2n\u{103} la ${e.endDate}`,selectedTimeDescription:e=>`Ora selectat\u{103}: ${e.time}`,startDate:"Dată \xeenceput",timeZoneName:"fus orar",weekday:"ziua din săptăm\xe2nă",year:"an"},"ru-RU":{calendar:"Календарь",day:"день",dayPeriod:"AM/PM",endDate:"Дата окончания",era:"эра",hour:"час",minute:"минута",month:"месяц",second:"секунда",selectedDateDescription:e=>`\u{412}\u{44B}\u{431}\u{440}\u{430}\u{43D}\u{43D}\u{430}\u{44F} \u{434}\u{430}\u{442}\u{430}: ${e.date}`,selectedRangeDescription:e=>`\u{412}\u{44B}\u{431}\u{440}\u{430}\u{43D}\u{43D}\u{44B}\u{439} \u{434}\u{438}\u{430}\u{43F}\u{430}\u{437}\u{43E}\u{43D}: \u{441} ${e.startDate} \u{43F}\u{43E} ${e.endDate}`,selectedTimeDescription:e=>`\u{412}\u{44B}\u{431}\u{440}\u{430}\u{43D}\u{43D}\u{43E}\u{435} \u{432}\u{440}\u{435}\u{43C}\u{44F}: ${e.time}`,startDate:"Дата начала",timeZoneName:"часовой пояс",weekday:"день недели",year:"год"},"sk-SK":{calendar:"Kalend\xe1r",day:"deň",dayPeriod:"AM/PM",endDate:"D\xe1tum ukončenia",era:"letopočet",hour:"hodina",minute:"min\xfata",month:"mesiac",second:"sekunda",selectedDateDescription:e=>`Vybrat\xfd d\xe1tum: ${e.date}`,selectedRangeDescription:e=>`Vybrat\xfd rozsah: od ${e.startDate} do ${e.endDate}`,selectedTimeDescription:e=>`Vybrat\xfd \u{10D}as: ${e.time}`,startDate:"D\xe1tum začatia",timeZoneName:"časov\xe9 p\xe1smo",weekday:"deň t\xfdždňa",year:"rok"},"sl-SI":{calendar:"Koledar",day:"dan",dayPeriod:"dop/pop",endDate:"Datum konca",era:"doba",hour:"ura",minute:"minuta",month:"mesec",second:"sekunda",selectedDateDescription:e=>`Izbrani datum: ${e.date}`,selectedRangeDescription:e=>`Izbrano obmo\u{10D}je: ${e.startDate} do ${e.endDate}`,selectedTimeDescription:e=>`Izbrani \u{10D}as: ${e.time}`,startDate:"Datum začetka",timeZoneName:"časovni pas",weekday:"dan v tednu",year:"leto"},"sr-SP":{calendar:"Kalendar",day:"дан",dayPeriod:"пре подне/по подне",endDate:"Datum završetka",era:"ера",hour:"сат",minute:"минут",month:"месец",second:"секунд",selectedDateDescription:e=>`Izabrani datum: ${e.date}`,selectedRangeDescription:e=>`Izabrani opseg: od ${e.startDate} do ${e.endDate}`,selectedTimeDescription:e=>`Izabrano vreme: ${e.time}`,startDate:"Datum početka",timeZoneName:"временска зона",weekday:"дан у недељи",year:"година"},"sv-SE":{calendar:"Kalender",day:"dag",dayPeriod:"fm/em",endDate:"Slutdatum",era:"era",hour:"timme",minute:"minut",month:"m\xe5nad",second:"sekund",selectedDateDescription:e=>`Valt datum: ${e.date}`,selectedRangeDescription:e=>`Valt intervall: ${e.startDate} till ${e.endDate}`,selectedTimeDescription:e=>`Vald tid: ${e.time}`,startDate:"Startdatum",timeZoneName:"tidszon",weekday:"veckodag",year:"\xe5r"},"tr-TR":{calendar:"Takvim",day:"g\xfcn",dayPeriod:"\xd6\xd6/\xd6S",endDate:"Bitiş Tarihi",era:"\xe7ağ",hour:"saat",minute:"dakika",month:"ay",second:"saniye",selectedDateDescription:e=>`Se\xe7ilen Tarih: ${e.date}`,selectedRangeDescription:e=>`Se\xe7ilen Aral\u{131}k: ${e.startDate} - ${e.endDate}`,selectedTimeDescription:e=>`Se\xe7ilen Zaman: ${e.time}`,startDate:"Başlangı\xe7 Tarihi",timeZoneName:"saat dilimi",weekday:"haftanın g\xfcn\xfc",year:"yıl"},"uk-UA":{calendar:"Календар",day:"день",dayPeriod:"дп/пп",endDate:"Дата завершення",era:"ера",hour:"година",minute:"хвилина",month:"місяць",second:"секунда",selectedDateDescription:e=>`\u{412}\u{438}\u{431}\u{440}\u{430}\u{43D}\u{430} \u{434}\u{430}\u{442}\u{430}: ${e.date}`,selectedRangeDescription:e=>`\u{412}\u{438}\u{431}\u{440}\u{430}\u{43D}\u{438}\u{439} \u{434}\u{456}\u{430}\u{43F}\u{430}\u{437}\u{43E}\u{43D}: ${e.startDate} \u{2014} ${e.endDate}`,selectedTimeDescription:e=>`\u{412}\u{438}\u{431}\u{440}\u{430}\u{43D}\u{438}\u{439} \u{447}\u{430}\u{441}: ${e.time}`,startDate:"Дата початку",timeZoneName:"часовий пояс",weekday:"день тижня",year:"рік"},"zh-CN":{calendar:"日历",day:"日",dayPeriod:"上午/下午",endDate:"结束日期",era:"纪元",hour:"小时",minute:"分钟",month:"月",second:"秒",selectedDateDescription:e=>`\u{9009}\u{5B9A}\u{7684}\u{65E5}\u{671F}\u{FF1A}${e.date}`,selectedRangeDescription:e=>`\u{9009}\u{5B9A}\u{7684}\u{8303}\u{56F4}\u{FF1A}${e.startDate} \u{81F3} ${e.endDate}`,selectedTimeDescription:e=>`\u{9009}\u{5B9A}\u{7684}\u{65F6}\u{95F4}\u{FF1A}${e.time}`,startDate:"开始日期",timeZoneName:"时区",weekday:"工作日",year:"年"},"zh-TW":{calendar:"日曆",day:"日",dayPeriod:"上午/下午",endDate:"結束日期",era:"纪元",hour:"小时",minute:"分钟",month:"月",second:"秒",selectedDateDescription:e=>`\u{9078}\u{5B9A}\u{7684}\u{65E5}\u{671F}\u{FF1A}${e.date}`,selectedRangeDescription:e=>`\u{9078}\u{5B9A}\u{7684}\u{7BC4}\u{570D}\u{FF1A}${e.startDate} \u{81F3} ${e.endDate}`,selectedTimeDescription:e=>`\u{9078}\u{5B9A}\u{7684}\u{6642}\u{9593}\u{FF1A}${e.time}`,startDate:"開始日期",timeZoneName:"时区",weekday:"工作日",year:"年"}};let ui=ey().createContext(null),ua="react-aria-focus-scope-restore",uu=null;function us(e){var t,r,n,o,i,a,u,s,l,c;let d,f,p,h,{children:m,contain:y,restoreFocus:b,autoFocus:v}=e,g=(0,em.useRef)(null),w=(0,em.useRef)(null),E=(0,em.useRef)([]),{parentNode:S}=(0,em.useContext)(ui)||{},O=(0,em.useMemo)(()=>new uO({scopeRef:E}),[E]);rm(()=>{let e=S||uA.root;if(uA.getTreeNode(e.scopeRef)&&uu&&!up(uu,e.scopeRef)){let t=uA.getTreeNode(uu);t&&(e=t)}e.addChild(O),uA.addNode(O)},[O,S]),rm(()=>{let e=uA.getTreeNode(E);e&&(e.contain=!!y)},[y]),rm(()=>{var e;let t=null==(e=g.current)?void 0:e.nextSibling,r=[],n=e=>e.stopPropagation();for(;t&&t!==w.current;)r.push(t),t.addEventListener(ua,n),t=t.nextSibling;return E.current=r,()=>{for(let e of r)e.removeEventListener(ua,n)}},[m]),rm(()=>{if(r||n)return;let e=t.current,o=rQ(e?e[0]:void 0),i=e=>{let r=nO(e);ud(r,t.current)?uu=t:uf(r)||(uu=null)};return o.addEventListener("focusin",i,!1),null==e||e.forEach(e=>e.addEventListener("focusin",i,!1)),()=>{o.removeEventListener("focusin",i,!1),null==e||e.forEach(e=>e.removeEventListener("focusin",i,!1))}},[t=E,r=b,n=y]),o=E,i=y,d=(0,em.useRef)(void 0),f=(0,em.useRef)(void 0),rm(()=>{let e=o.current;if(!i){f.current&&(cancelAnimationFrame(f.current),f.current=void 0);return}let t=rQ(e?e[0]:void 0),r=e=>{if("Tab"!==e.key||e.altKey||e.ctrlKey||e.metaKey||!uc(o)||e.isComposing)return;let r=((e=document)=>e.activeElement)(t),n=o.current;if(!n||!ud(r,n))return;let i=ug(ul(n),{tabbable:!0},n);if(!r)return;i.currentNode=r;let a=e.shiftKey?i.previousNode():i.nextNode();a||(i.currentNode=e.shiftKey?n[n.length-1].nextElementSibling:n[0].previousElementSibling,a=e.shiftKey?i.previousNode():i.nextNode()),e.preventDefault(),a&&uh(a,!0)},n=e=>{(!uu||up(uu,o))&&ud(nO(e),o.current)?(uu=o,d.current=nO(e)):uc(o)&&!uf(nO(e),o)?d.current?d.current.focus():uu&&uu.current&&uy(uu.current):uc(o)&&(d.current=nO(e))},a=e=>{f.current&&cancelAnimationFrame(f.current),f.current=requestAnimationFrame(()=>{let r=nB,n=("virtual"===r||null===r)&&na()&&ni(),i=((e=document)=>e.activeElement)(t);if(!n&&i&&uc(o)&&!uf(i,o)){uu=o;let t=nO(e);if(t&&t.isConnected){var a;d.current=t,null==(a=d.current)||a.focus()}else uu.current&&uy(uu.current)}})};return t.addEventListener("keydown",r,!1),t.addEventListener("focusin",n,!1),null==e||e.forEach(e=>e.addEventListener("focusin",n,!1)),null==e||e.forEach(e=>e.addEventListener("focusout",a,!1)),()=>{t.removeEventListener("keydown",r,!1),t.removeEventListener("focusin",n,!1),null==e||e.forEach(e=>e.removeEventListener("focusin",n,!1)),null==e||e.forEach(e=>e.removeEventListener("focusout",a,!1))}},[o,i]),rm(()=>()=>{f.current&&cancelAnimationFrame(f.current)},[f]),a=E,u=b,s=y,p=(0,em.useRef)("u">typeof document?((e=document)=>e.activeElement)(rQ(a.current?a.current[0]:void 0)):null),rm(()=>{let e=a.current,t=rQ(e?e[0]:void 0);if(!u||s)return;let r=()=>{(!uu||up(uu,a))&&ud(((e=document)=>e.activeElement)(t),a.current)&&(uu=a)};return t.addEventListener("focusin",r,!1),null==e||e.forEach(e=>e.addEventListener("focusin",r,!1)),()=>{t.removeEventListener("focusin",r,!1),null==e||e.forEach(e=>e.removeEventListener("focusin",r,!1))}},[a,s]),rm(()=>{let e=rQ(a.current?a.current[0]:void 0);if(!u)return;let t=t=>{if("Tab"!==t.key||t.altKey||t.ctrlKey||t.metaKey||!uc(a)||t.isComposing)return;let r=e.activeElement;if(!uf(r,a)||!ub(a))return;let n=uA.getTreeNode(a);if(!n)return;let o=n.nodeToRestore,i=ug(e.body,{tabbable:!0});i.currentNode=r;let u=t.shiftKey?i.previousNode():i.nextNode();if(o&&o.isConnected&&o!==e.body||(o=void 0,n.nodeToRestore=void 0),(!u||!uf(u,a))&&o){i.currentNode=o;do u=t.shiftKey?i.previousNode():i.nextNode();while(uf(u,a));(t.preventDefault(),t.stopPropagation(),u)?uh(u,!0):uf(o)?uh(o,!0):r.blur()}};return s||e.addEventListener("keydown",t,!0),()=>{s||e.removeEventListener("keydown",t,!0)}},[a,u,s]),rm(()=>{var e;let t=rQ(a.current?a.current[0]:void 0);if(!u)return;let r=uA.getTreeNode(a);if(r)return r.nodeToRestore=null!=(e=p.current)?e:void 0,()=>{let e=uA.getTreeNode(a);if(!e)return;let r=e.nodeToRestore,n=((e=document)=>e.activeElement)(t);if(u&&r&&(n&&uf(n,a)||n===t.body&&ub(a))){let e=uA.clone();requestAnimationFrame(()=>{if(t.activeElement===t.body){let t=e.getTreeNode(a);for(;t;){if(t.nodeToRestore&&t.nodeToRestore.isConnected)return void uv(t.nodeToRestore);t=t.parent}for(t=e.getTreeNode(a);t;){if(t.scopeRef&&t.scopeRef.current&&uA.getTreeNode(t.scopeRef))return void uv(um(t.scopeRef.current,!0));t=t.parent}}})}}},[a,u]),l=E,c=v,h=ey().useRef(c),(0,em.useEffect)(()=>{h.current&&(uu=l,!ud(((e=document)=>e.activeElement)(rQ(l.current?l.current[0]:void 0)),uu.current)&&l.current&&uy(l.current)),h.current=!1},[l]),(0,em.useEffect)(()=>{let e=((e=document)=>e.activeElement)(rQ(E.current?E.current[0]:void 0)),t=null;if(ud(e,E.current)){for(let r of uA.traverse())r.scopeRef&&ud(e,r.scopeRef.current)&&(t=r);t===uA.getTreeNode(E)&&(uu=t.scopeRef)}},[E]),rm(()=>()=>{var e,t,r;let n=null!=(r=null==(t=uA.getTreeNode(E))||null==(e=t.parent)?void 0:e.scopeRef)?r:null;(E===uu||up(E,uu))&&(!n||uA.getTreeNode(n))&&(uu=n),uA.removeTreeNode(E)},[E]);let A=(0,em.useMemo)(()=>{var e;return e=E,{focusNext(t={}){var r;let n=e.current,{from:o,tabbable:i,wrap:a,accept:u}=t,s=o||((e=document)=>e.activeElement)(rQ(null!=(r=n[0])?r:void 0)),l=n[0].previousElementSibling,c=ug(ul(n),{tabbable:i,accept:u},n);c.currentNode=ud(s,n)?s:l;let d=c.nextNode();return!d&&a&&(c.currentNode=l,d=c.nextNode()),d&&uh(d,!0),d},focusPrevious(t={}){var r;let n=e.current,{from:o,tabbable:i,wrap:a,accept:u}=t,s=o||((e=document)=>e.activeElement)(rQ(null!=(r=n[0])?r:void 0)),l=n[n.length-1].nextElementSibling,c=ug(ul(n),{tabbable:i,accept:u},n);c.currentNode=ud(s,n)?s:l;let d=c.previousNode();return!d&&a&&(c.currentNode=l,d=c.previousNode()),d&&uh(d,!0),d},focusFirst(t={}){let r=e.current,{tabbable:n,accept:o}=t,i=ug(ul(r),{tabbable:n,accept:o},r);i.currentNode=r[0].previousElementSibling;let a=i.nextNode();return a&&uh(a,!0),a},focusLast(t={}){let r=e.current,{tabbable:n,accept:o}=t,i=ug(ul(r),{tabbable:n,accept:o},r);i.currentNode=r[r.length-1].nextElementSibling;let a=i.previousNode();return a&&uh(a,!0),a}}},[]),x=(0,em.useMemo)(()=>({focusManager:A,parentNode:O}),[O,A]);return ey().createElement(ui.Provider,{value:x},ey().createElement("span",{"data-focus-scope-start":!0,hidden:!0,ref:g}),m,ey().createElement("span",{"data-focus-scope-end":!0,hidden:!0,ref:w}))}function ul(e){return e[0].parentElement}function uc(e){let t=uA.getTreeNode(uu);for(;t&&t.scopeRef!==e;){if(t.contain)return!1;t=t.parent}return!0}function ud(e,t){return!!e&&!!t&&t.some(t=>t.contains(e))}function uf(e,t=null){if(e instanceof Element&&e.closest("[data-react-aria-top-layer]"))return!0;for(let{scopeRef:r}of uA.traverse(uA.getTreeNode(t)))if(r&&ud(e,r.current))return!0;return!1}function up(e,t){var r;let n=null==(r=uA.getTreeNode(t))?void 0:r.parent;for(;n;){if(n.scopeRef===e)return!0;n=n.parent}return!1}function uh(e,t=!1){if(null==e||t){if(null!=e)try{e.focus()}catch{}}else try{n0(e)}catch{}}function um(e,t=!0){let r=e[0].previousElementSibling,n=ul(e),o=ug(n,{tabbable:t},e);o.currentNode=r;let i=o.nextNode();return t&&!i&&((o=ug(n=ul(e),{tabbable:!1},e)).currentNode=r,i=o.nextNode()),i}function uy(e,t=!0){uh(um(e,t))}function ub(e){let t=uA.getTreeNode(uu);for(;t&&t.scopeRef!==e;){if(t.nodeToRestore)return!1;t=t.parent}return(null==t?void 0:t.scopeRef)===e}function uv(e){e.dispatchEvent(new CustomEvent(ua,{bubbles:!0,cancelable:!0}))&&uh(e)}function ug(e,t,r){var n,o,i;let a=(null==t?void 0:t.tabbable)?rX:rJ,u=rQ((null==e?void 0:e.nodeType)===Node.ELEMENT_NODE?e:null),s=(n=e||u,o=NodeFilter.SHOW_ELEMENT,i={acceptNode(e){var n;return(null==t||null==(n=t.from)?void 0:n.contains(e))?NodeFilter.FILTER_REJECT:a(e)&&function e(t,r){return"#comment"!==t.nodeName&&function(e){let t=r0(e);if(!(e instanceof t.HTMLElement)&&!(e instanceof t.SVGElement))return!1;let{display:r,visibility:n}=e.style,o="none"!==r&&"hidden"!==n&&"collapse"!==n;if(o){let{getComputedStyle:t}=e.ownerDocument.defaultView,{display:r,visibility:n}=t(e);o="none"!==r&&"hidden"!==n&&"collapse"!==n}return o}(t)&&!t.hasAttribute("hidden")&&!t.hasAttribute("data-react-aria-prevent-focus")&&("DETAILS"!==t.nodeName||!r||"SUMMARY"===r.nodeName||t.hasAttribute("open"))&&(!t.parentElement||e(t.parentElement,t))}(e)&&(!r||ud(e,r))&&(!(null==t?void 0:t.accept)||t.accept(e))?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}},u.createTreeWalker(n,o,i));return(null==t?void 0:t.from)&&(s.currentNode=t.from),s}function uw(e,t={}){return{focusNext(r={}){let n=e.current;if(!n)return null;let{from:o,tabbable:i=t.tabbable,wrap:a=t.wrap,accept:u=t.accept}=r,s=o||((e=document)=>e.activeElement)(rQ(n)),l=ug(n,{tabbable:i,accept:u});n.contains(s)&&(l.currentNode=s);let c=l.nextNode();return!c&&a&&(l.currentNode=n,c=l.nextNode()),c&&uh(c,!0),c},focusPrevious(r=t){let n=e.current;if(!n)return null;let{from:o,tabbable:i=t.tabbable,wrap:a=t.wrap,accept:u=t.accept}=r,s=o||((e=document)=>e.activeElement)(rQ(n)),l=ug(n,{tabbable:i,accept:u});if(n.contains(s))l.currentNode=s;else{let e=uE(l);return e&&uh(e,!0),null!=e?e:null}let c=l.previousNode();if(!c&&a){l.currentNode=n;let e=uE(l);if(!e)return null;c=e}return c&&uh(c,!0),null!=c?c:null},focusFirst(r=t){let n=e.current;if(!n)return null;let{tabbable:o=t.tabbable,accept:i=t.accept}=r,a=ug(n,{tabbable:o,accept:i}).nextNode();return a&&uh(a,!0),a},focusLast(r=t){let n=e.current;if(!n)return null;let{tabbable:o=t.tabbable,accept:i=t.accept}=r,a=uE(ug(n,{tabbable:o,accept:i}));return a&&uh(a,!0),null!=a?a:null}}}function uE(e){let t,r;do(t=e.lastChild())&&(r=t);while(t);return r}class uS{get size(){return this.fastMap.size}getTreeNode(e){return this.fastMap.get(e)}addTreeNode(e,t,r){let n=this.fastMap.get(null!=t?t:null);if(!n)return;let o=new uO({scopeRef:e});n.addChild(o),o.parent=n,this.fastMap.set(e,o),r&&(o.nodeToRestore=r)}addNode(e){this.fastMap.set(e.scopeRef,e)}removeTreeNode(e){if(null===e)return;let t=this.fastMap.get(e);if(!t)return;let r=t.parent;for(let e of this.traverse())e!==t&&t.nodeToRestore&&e.nodeToRestore&&t.scopeRef&&t.scopeRef.current&&ud(e.nodeToRestore,t.scopeRef.current)&&(e.nodeToRestore=t.nodeToRestore);let n=t.children;r&&(r.removeChild(t),n.size>0&&n.forEach(e=>r&&r.addChild(e))),this.fastMap.delete(t.scopeRef)}*traverse(e=this.root){if(null!=e.scopeRef&&(yield e),e.children.size>0)for(let t of e.children)yield*this.traverse(t)}clone(){var e,t;let r=new uS;for(let n of this.traverse())r.addTreeNode(n.scopeRef,null!=(t=null==(e=n.parent)?void 0:e.scopeRef)?t:null,n.nodeToRestore);return r}constructor(){this.fastMap=new Map,this.root=new uO({scopeRef:null}),this.fastMap.set(null,this.root)}}class uO{addChild(e){this.children.add(e),e.parent=this}removeChild(e){this.children.delete(e),e.parent=void 0}constructor(e){this.children=new Set,this.contain=!1,this.scopeRef=e.scopeRef}}let uA=new uS;function ux(e,t,r){let{direction:n}=oE(),o=(0,em.useMemo)(()=>uw(t),[t]),i=()=>{var e;if(!t.current)return;let r=null==(e=window.event)?void 0:e.target,n=ug(t.current,{tabbable:!0});if(r&&(n.currentNode=r,r=n.previousNode()),!r){let e;do(e=n.lastChild())&&(r=e);while(e)}for(;null==r?void 0:r.hasAttribute("data-placeholder");){let e=n.previousNode();if(e&&e.hasAttribute("data-placeholder"))r=e;else break}r&&r.focus()},{pressProps:a}=nk({preventFocusOnPress:!0,allowTextSelectionOnPress:!0,onPressStart(e){"mouse"===e.pointerType&&i()},onPress(e){"mouse"!==e.pointerType&&i()}});return rk(a,{onKeyDown:i=>{if(i.currentTarget.contains(i.target)&&(i.altKey&&("ArrowDown"===i.key||"ArrowUp"===i.key)&&"setOpen"in e&&(i.preventDefault(),i.stopPropagation(),e.setOpen(!0)),!r))switch(i.key){case"ArrowLeft":if(i.preventDefault(),i.stopPropagation(),"rtl"===n){if(t.current){let e=i.target,r=uD(t.current,e.getBoundingClientRect().left,-1);r&&r.focus()}}else o.focusPrevious();break;case"ArrowRight":if(i.preventDefault(),i.stopPropagation(),"rtl"===n){if(t.current){let e=i.target,r=uD(t.current,e.getBoundingClientRect().left,1);r&&r.focus()}}else o.focusNext()}}})}function uD(e,t,r){let n=ug(e,{tabbable:!0}),o=n.nextNode(),i=null,a=1/0;for(;o;){let e=o.getBoundingClientRect().left-t,u=Math.abs(e);Math.sign(e)===r&&u<a&&(i=o,a=u),o=n.nextNode()}return i}function u_(e,t,r){let n=(0,em.useRef)(t),o=ry(()=>{r&&r(n.current)});(0,em.useEffect)(()=>{var t;let r=null==e||null==(t=e.current)?void 0:t.form;return null==r||r.addEventListener("reset",o),()=>{null==r||r.removeEventListener("reset",o)}},[e,o])}function uj(e){let{description:t,errorMessage:r,isInvalid:n,validationState:o}=e,{labelProps:i,fieldProps:a}=function(e){let{id:t,label:r,"aria-labelledby":n,"aria-label":o,labelElementType:i="label"}=e;t=rj(t);let a=rj(),u={};return r&&(n=n?`${a} ${n}`:a,u={id:a,htmlFor:"label"===i?t:void 0}),{labelProps:u,fieldProps:iZ({id:t,"aria-label":o,"aria-labelledby":n})}}(e),u=rC([!!t,!!r,n,o]),s=rC([!!t,!!r,n,o]);return{labelProps:i,fieldProps:a=rk(a,{"aria-describedby":[u,s,e["aria-describedby"]].filter(Boolean).join(" ")||void 0}),descriptionProps:{id:u},errorMessageProps:{id:s}}}function uC(e,t,r){let{validationBehavior:n,focus:o}=e;rm(()=>{if("native"===n&&(null==r?void 0:r.current)&&!r.current.disabled){var e;let n,o=t.realtimeValidation.isInvalid?t.realtimeValidation.validationErrors.join(" ")||"Invalid value.":"";r.current.setCustomValidity(o),r.current.hasAttribute("title")||(r.current.title=""),t.realtimeValidation.isInvalid||t.updateValidation({isInvalid:!(e=r.current).validity.valid,validationDetails:{badInput:(n=e.validity).badInput,customError:n.customError,patternMismatch:n.patternMismatch,rangeOverflow:n.rangeOverflow,rangeUnderflow:n.rangeUnderflow,stepMismatch:n.stepMismatch,tooLong:n.tooLong,tooShort:n.tooShort,typeMismatch:n.typeMismatch,valueMissing:n.valueMissing,valid:n.valid},validationErrors:e.validationMessage?[e.validationMessage]:[]})}});let i=ry(()=>{t.resetValidation()}),a=ry(e=>{var n,i;t.displayValidation.isInvalid||t.commitValidation();let a=null==r||null==(n=r.current)?void 0:n.form;!e.defaultPrevented&&r&&a&&function(e){for(let t=0;t<e.elements.length;t++){let r=e.elements[t];if(!r.validity.valid)return r}return null}(a)===r.current&&(o?o():null==(i=r.current)||i.focus(),nB="keyboard",nz("keyboard",null)),e.preventDefault()}),u=ry(()=>{t.commitValidation()});(0,em.useEffect)(()=>{let e=null==r?void 0:r.current;if(!e)return;let t=e.form;return e.addEventListener("invalid",a),e.addEventListener("change",u),null==t||t.addEventListener("reset",i),()=>{e.removeEventListener("invalid",a),e.removeEventListener("change",u),null==t||t.removeEventListener("reset",i)}},[r,a,u,i,n])}let uP=new WeakMap,uk="__role_"+Date.now(),uI="__focusManager_"+Date.now();function uT(e,t,r){var n,o;let i,{isInvalid:a,validationErrors:u,validationDetails:s}=t.displayValidation,{labelProps:l,fieldProps:c,descriptionProps:d,errorMessageProps:f}=uj({...e,labelElementType:"span",isInvalid:a,errorMessage:e.errorMessage||u}),p=(0,em.useRef)(null),{focusWithinProps:h}=n6({...e,onFocusWithin(r){var n;p.current=t.value,null==(n=e.onFocus)||n.call(e,r)},onBlurWithin:r=>{var n;t.confirmPlaceholder(),t.value!==p.current&&t.commitValidation(),null==(n=e.onBlur)||n.call(e,r)},onFocusWithinChange:e.onFocusChange}),m=iT((o=uo)&&o.__esModule?o.default:o,"@react-aria/datepicker"),y="hour"===t.maxGranularity?"selectedTimeDescription":"selectedDateDescription",b="hour"===t.maxGranularity?"time":"date",v=i2(t.value?m.format(y,{[b]:t.formatValue({month:"long"})}):""),g="presentation"===e[uk]?c["aria-describedby"]:[v["aria-describedby"],c["aria-describedby"]].filter(Boolean).join(" ")||void 0,w=e[uI],E=(0,em.useMemo)(()=>w||uw(r),[w,r]),S=ux(t,r,"presentation"===e[uk]);uP.set(t,{ariaLabel:e["aria-label"],ariaLabelledBy:[l.id,e["aria-labelledby"]].filter(Boolean).join(" ")||void 0,ariaDescribedBy:g,focusManager:E});let O=(0,em.useRef)(e.autoFocus);i="presentation"===e[uk]?{role:"presentation"}:rk(c,{role:"group","aria-disabled":e.isDisabled||void 0,"aria-describedby":g}),(0,em.useEffect)(()=>{O.current&&E.focusFirst(),O.current=!1},[E]),u_(e.inputRef,t.value,t.setValue),uC({...e,focus(){E.focusFirst()}},t,e.inputRef);let A={type:"hidden",name:e.name,value:(null==(n=t.value)?void 0:n.toString())||"",disabled:e.isDisabled};"native"===e.validationBehavior&&(A.type="text",A.hidden=!0,A.required=e.isRequired,A.onChange=()=>{});let x=rG(e);return{labelProps:{...l,onClick:()=>{E.focusFirst()}},fieldProps:rk(x,i,S,h,{onKeyDown(t){e.onKeyDown&&e.onKeyDown(t)},onKeyUp(t){e.onKeyUp&&e.onKeyUp(t)},style:{unicodeBidi:"isolate"}}),inputProps:A,descriptionProps:d,errorMessageProps:f,isInvalid:a,validationErrors:u,validationDetails:s}}var uR={};uR={"ar-AE":{rangeOverflow:e=>`\u{64A}\u{62C}\u{628} \u{623}\u{646} \u{62A}\u{643}\u{648}\u{646} \u{627}\u{644}\u{642}\u{64A}\u{645}\u{629} ${e.maxValue} \u{623}\u{648} \u{642}\u{628}\u{644} \u{630}\u{644}\u{643}.`,rangeReversed:"تاريخ البدء يجب أن يكون قبل تاريخ الانتهاء.",rangeUnderflow:e=>`\u{64A}\u{62C}\u{628} \u{623}\u{646} \u{62A}\u{643}\u{648}\u{646} \u{627}\u{644}\u{642}\u{64A}\u{645}\u{629} ${e.minValue} \u{623}\u{648} \u{628}\u{639}\u{62F} \u{630}\u{644}\u{643}.`,unavailableDate:"البيانات المحددة غير متاحة."},"bg-BG":{rangeOverflow:e=>`\u{421}\u{442}\u{43E}\u{439}\u{43D}\u{43E}\u{441}\u{442}\u{442}\u{430} \u{442}\u{440}\u{44F}\u{431}\u{432}\u{430} \u{434}\u{430} \u{435} ${e.maxValue} \u{438}\u{43B}\u{438} \u{43F}\u{43E}-\u{440}\u{430}\u{43D}\u{43D}\u{430}.`,rangeReversed:"Началната дата трябва да е преди крайната.",rangeUnderflow:e=>`\u{421}\u{442}\u{43E}\u{439}\u{43D}\u{43E}\u{441}\u{442}\u{442}\u{430} \u{442}\u{440}\u{44F}\u{431}\u{432}\u{430} \u{434}\u{430} \u{435} ${e.minValue} \u{438}\u{43B}\u{438} \u{43F}\u{43E}-\u{43A}\u{44A}\u{441}\u{43D}\u{43E}.`,unavailableDate:"Избраната дата не е налична."},"cs-CZ":{rangeOverflow:e=>`Hodnota mus\xed b\xfdt ${e.maxValue} nebo d\u{159}\xedv\u{11B}j\u{161}\xed.`,rangeReversed:"Datum zah\xe1jen\xed mus\xed předch\xe1zet datu ukončen\xed.",rangeUnderflow:e=>`Hodnota mus\xed b\xfdt ${e.minValue} nebo pozd\u{11B}j\u{161}\xed.`,unavailableDate:"Vybran\xe9 datum nen\xed k dispozici."},"da-DK":{rangeOverflow:e=>`V\xe6rdien skal v\xe6re ${e.maxValue} eller tidligere.`,rangeReversed:"Startdatoen skal v\xe6re f\xf8r slutdatoen.",rangeUnderflow:e=>`V\xe6rdien skal v\xe6re ${e.minValue} eller nyere.`,unavailableDate:"Den valgte dato er ikke tilg\xe6ngelig."},"de-DE":{rangeOverflow:e=>`Der Wert muss ${e.maxValue} oder fr\xfcher sein.`,rangeReversed:"Das Anfangsdatum muss vor dem Enddatum liegen.",rangeUnderflow:e=>`Der Wert muss ${e.minValue} oder sp\xe4ter sein.`,unavailableDate:"Das ausgew\xe4hlte Datum ist nicht verf\xfcgbar."},"el-GR":{rangeOverflow:e=>`\u{397} \u{3C4}\u{3B9}\u{3BC}\u{3AE} \u{3C0}\u{3C1}\u{3AD}\u{3C0}\u{3B5}\u{3B9} \u{3BD}\u{3B1} \u{3B5}\u{3AF}\u{3BD}\u{3B1}\u{3B9} ${e.maxValue} \u{3AE} \u{3C0}\u{3B1}\u{3BB}\u{3B1}\u{3B9}\u{3CC}\u{3C4}\u{3B5}\u{3C1}\u{3B7}.`,rangeReversed:"Η ημερομηνία έναρξης πρέπει να είναι πριν από την ημερομηνία λήξης.",rangeUnderflow:e=>`\u{397} \u{3C4}\u{3B9}\u{3BC}\u{3AE} \u{3C0}\u{3C1}\u{3AD}\u{3C0}\u{3B5}\u{3B9} \u{3BD}\u{3B1} \u{3B5}\u{3AF}\u{3BD}\u{3B1}\u{3B9} ${e.minValue} \u{3AE} \u{3BC}\u{3B5}\u{3C4}\u{3B1}\u{3B3}\u{3B5}\u{3BD}\u{3AD}\u{3C3}\u{3C4}\u{3B5}\u{3C1}\u{3B7}.`,unavailableDate:"Η επιλεγμένη ημερομηνία δεν είναι διαθέσιμη."},"en-US":{rangeUnderflow:e=>`Value must be ${e.minValue} or later.`,rangeOverflow:e=>`Value must be ${e.maxValue} or earlier.`,rangeReversed:"Start date must be before end date.",unavailableDate:"Selected date unavailable."},"es-ES":{rangeOverflow:e=>`El valor debe ser ${e.maxValue} o anterior.`,rangeReversed:"La fecha de inicio debe ser anterior a la fecha de finalizaci\xf3n.",rangeUnderflow:e=>`El valor debe ser ${e.minValue} o posterior.`,unavailableDate:"Fecha seleccionada no disponible."},"et-EE":{rangeOverflow:e=>`V\xe4\xe4rtus peab olema ${e.maxValue} v\xf5i varasem.`,rangeReversed:"Alguskuup\xe4ev peab olema enne l\xf5ppkuup\xe4eva.",rangeUnderflow:e=>`V\xe4\xe4rtus peab olema ${e.minValue} v\xf5i hilisem.`,unavailableDate:"Valitud kuup\xe4ev pole saadaval."},"fi-FI":{rangeOverflow:e=>`Arvon on oltava ${e.maxValue} tai sit\xe4 aikaisempi.`,rangeReversed:"Aloitusp\xe4iv\xe4n on oltava ennen lopetusp\xe4iv\xe4\xe4.",rangeUnderflow:e=>`Arvon on oltava ${e.minValue} tai sit\xe4 my\xf6h\xe4isempi.`,unavailableDate:"Valittu p\xe4iv\xe4m\xe4\xe4r\xe4 ei ole k\xe4ytett\xe4viss\xe4."},"fr-FR":{rangeOverflow:e=>`La valeur doit \xeatre ${e.maxValue} ou ant\xe9rieure.`,rangeReversed:"La date de d\xe9but doit \xeatre ant\xe9rieure \xe0 la date de fin.",rangeUnderflow:e=>`La valeur doit \xeatre ${e.minValue} ou ult\xe9rieure.`,unavailableDate:"La date s\xe9lectionn\xe9e n’est pas disponible."},"he-IL":{rangeOverflow:e=>`\u{5D4}\u{5E2}\u{5E8}\u{5DA} \u{5D7}\u{5D9}\u{5D9}\u{5D1} \u{5DC}\u{5D4}\u{5D9}\u{5D5}\u{5EA} ${e.maxValue} \u{5D0}\u{5D5} \u{5DE}\u{5D5}\u{5E7}\u{5D3}\u{5DD} \u{5D9}\u{5D5}\u{5EA}\u{5E8}.`,rangeReversed:"תאריך ההתחלה חייב להיות לפני תאריך הסיום.",rangeUnderflow:e=>`\u{5D4}\u{5E2}\u{5E8}\u{5DA} \u{5D7}\u{5D9}\u{5D9}\u{5D1} \u{5DC}\u{5D4}\u{5D9}\u{5D5}\u{5EA} ${e.minValue} \u{5D0}\u{5D5} \u{5DE}\u{5D0}\u{5D5}\u{5D7}\u{5E8} \u{5D9}\u{5D5}\u{5EA}\u{5E8}.`,unavailableDate:"התאריך הנבחר אינו זמין."},"hr-HR":{rangeOverflow:e=>`Vrijednost mora biti ${e.maxValue} ili ranije.`,rangeReversed:"Datum početka mora biti prije datuma završetka.",rangeUnderflow:e=>`Vrijednost mora biti ${e.minValue} ili kasnije.`,unavailableDate:"Odabrani datum nije dostupan."},"hu-HU":{rangeOverflow:e=>`Az \xe9rt\xe9knek ${e.maxValue} vagy kor\xe1bbinak kell lennie.`,rangeReversed:"A kezdő d\xe1tumnak a befejező d\xe1tumn\xe1l kor\xe1bbinak kell lennie.",rangeUnderflow:e=>`Az \xe9rt\xe9knek ${e.minValue} vagy k\xe9s\u{151}bbinek kell lennie.`,unavailableDate:"A kiv\xe1lasztott d\xe1tum nem \xe9rhető el."},"it-IT":{rangeOverflow:e=>`Il valore deve essere ${e.maxValue} o precedente.`,rangeReversed:"La data di inizio deve essere antecedente alla data di fine.",rangeUnderflow:e=>`Il valore deve essere ${e.minValue} o successivo.`,unavailableDate:"Data selezionata non disponibile."},"ja-JP":{rangeOverflow:e=>`\u{5024}\u{306F} ${e.maxValue} \u{4EE5}\u{4E0B}\u{306B}\u{3059}\u{308B}\u{5FC5}\u{8981}\u{304C}\u{3042}\u{308A}\u{307E}\u{3059}\u{3002}`,rangeReversed:"開始日は終了日より前にする必要があります。",rangeUnderflow:e=>`\u{5024}\u{306F} ${e.minValue} \u{4EE5}\u{4E0A}\u{306B}\u{3059}\u{308B}\u{5FC5}\u{8981}\u{304C}\u{3042}\u{308A}\u{307E}\u{3059}\u{3002}`,unavailableDate:"選択した日付は使用できません。"},"ko-KR":{rangeOverflow:e=>`\u{AC12}\u{C740} ${e.maxValue} \u{C774}\u{C804}\u{C774}\u{C5B4}\u{C57C} \u{D569}\u{B2C8}\u{B2E4}.`,rangeReversed:"시작일은 종료일 이전이어야 합니다.",rangeUnderflow:e=>`\u{AC12}\u{C740} ${e.minValue} \u{C774}\u{C0C1}\u{C774}\u{C5B4}\u{C57C} \u{D569}\u{B2C8}\u{B2E4}.`,unavailableDate:"선택한 날짜를 사용할 수 없습니다."},"lt-LT":{rangeOverflow:e=>`Reik\u{161}m\u{117} turi b\u{16B}ti ${e.maxValue} arba ankstesn\u{117}.`,rangeReversed:"Pradžios data turi būti ankstesnė nei pabaigos data.",rangeUnderflow:e=>`Reik\u{161}m\u{117} turi b\u{16B}ti ${e.minValue} arba naujesn\u{117}.`,unavailableDate:"Pasirinkta data nepasiekiama."},"lv-LV":{rangeOverflow:e=>`V\u{113}rt\u{12B}bai ir j\u{101}b\u{16B}t ${e.maxValue} vai agr\u{101}kai.`,rangeReversed:"Sākuma datumam ir jābūt pirms beigu datuma.",rangeUnderflow:e=>`V\u{113}rt\u{12B}bai ir j\u{101}b\u{16B}t ${e.minValue} vai v\u{113}l\u{101}kai.`,unavailableDate:"Atlasītais datums nav pieejams."},"nb-NO":{rangeOverflow:e=>`Verdien m\xe5 v\xe6re ${e.maxValue} eller tidligere.`,rangeReversed:"Startdatoen m\xe5 v\xe6re f\xf8r sluttdatoen.",rangeUnderflow:e=>`Verdien m\xe5 v\xe6re ${e.minValue} eller senere.`,unavailableDate:"Valgt dato utilgjengelig."},"nl-NL":{rangeOverflow:e=>`Waarde moet ${e.maxValue} of eerder zijn.`,rangeReversed:"De startdatum moet voor de einddatum liggen.",rangeUnderflow:e=>`Waarde moet ${e.minValue} of later zijn.`,unavailableDate:"Geselecteerde datum niet beschikbaar."},"pl-PL":{rangeOverflow:e=>`Warto\u{15B}\u{107} musi mie\u{107} warto\u{15B}\u{107} ${e.maxValue} lub wcze\u{15B}niejsz\u{105}.`,rangeReversed:"Data rozpoczęcia musi być wcześniejsza niż data zakończenia.",rangeUnderflow:e=>`Warto\u{15B}\u{107} musi mie\u{107} warto\u{15B}\u{107} ${e.minValue} lub p\xf3\u{17A}niejsz\u{105}.`,unavailableDate:"Wybrana data jest niedostępna."},"pt-BR":{rangeOverflow:e=>`O valor deve ser ${e.maxValue} ou anterior.`,rangeReversed:"A data inicial deve ser anterior \xe0 data final.",rangeUnderflow:e=>`O valor deve ser ${e.minValue} ou posterior.`,unavailableDate:"Data selecionada indispon\xedvel."},"pt-PT":{rangeOverflow:e=>`O valor tem de ser ${e.maxValue} ou anterior.`,rangeReversed:"A data de in\xedcio deve ser anterior \xe0 data de fim.",rangeUnderflow:e=>`O valor tem de ser ${e.minValue} ou posterior.`,unavailableDate:"Data selecionada indispon\xedvel."},"ro-RO":{rangeOverflow:e=>`Valoarea trebuie s\u{103} fie ${e.maxValue} sau anterioar\u{103}.`,rangeReversed:"Data de \xeenceput trebuie să fie anterioară datei de sf\xe2rșit.",rangeUnderflow:e=>`Valoarea trebuie s\u{103} fie ${e.minValue} sau ulterioar\u{103}.`,unavailableDate:"Data selectată nu este disponibilă."},"ru-RU":{rangeOverflow:e=>`\u{417}\u{43D}\u{430}\u{447}\u{435}\u{43D}\u{438}\u{435} \u{434}\u{43E}\u{43B}\u{436}\u{43D}\u{43E} \u{431}\u{44B}\u{442}\u{44C} \u{43D}\u{435} \u{43F}\u{43E}\u{437}\u{436}\u{435} ${e.maxValue}.`,rangeReversed:"Дата начала должна предшествовать дате окончания.",rangeUnderflow:e=>`\u{417}\u{43D}\u{430}\u{447}\u{435}\u{43D}\u{438}\u{435} \u{434}\u{43E}\u{43B}\u{436}\u{43D}\u{43E} \u{431}\u{44B}\u{442}\u{44C} \u{43D}\u{435} \u{440}\u{430}\u{43D}\u{44C}\u{448}\u{435} ${e.minValue}.`,unavailableDate:"Выбранная дата недоступна."},"sk-SK":{rangeOverflow:e=>`Hodnota mus\xed by\u{165} ${e.maxValue} alebo skor\u{161}ia.`,rangeReversed:"D\xe1tum začiatku mus\xed byť skorš\xed ako d\xe1tum konca.",rangeUnderflow:e=>`Hodnota mus\xed by\u{165} ${e.minValue} alebo neskor\u{161}ia.`,unavailableDate:"Vybrat\xfd d\xe1tum je nedostupn\xfd."},"sl-SI":{rangeOverflow:e=>`Vrednost mora biti ${e.maxValue} ali starej\u{161}a.`,rangeReversed:"Začetni datum mora biti pred končnim datumom.",rangeUnderflow:e=>`Vrednost mora biti ${e.minValue} ali novej\u{161}a.`,unavailableDate:"Izbrani datum ni na voljo."},"sr-SP":{rangeOverflow:e=>`Vrednost mora da bude ${e.maxValue} ili starija.`,rangeReversed:"Datum početka mora biti pre datuma završetka.",rangeUnderflow:e=>`Vrednost mora da bude ${e.minValue} ili novija.`,unavailableDate:"Izabrani datum nije dostupan."},"sv-SE":{rangeOverflow:e=>`V\xe4rdet m\xe5ste vara ${e.maxValue} eller tidigare.`,rangeReversed:"Startdatumet m\xe5ste vara f\xf6re slutdatumet.",rangeUnderflow:e=>`V\xe4rdet m\xe5ste vara ${e.minValue} eller senare.`,unavailableDate:"Det valda datumet \xe4r inte tillg\xe4ngligt."},"tr-TR":{rangeOverflow:e=>`De\u{11F}er, ${e.maxValue} veya \xf6ncesi olmal\u{131}d\u{131}r.`,rangeReversed:"Başlangı\xe7 tarihi bitiş tarihinden \xf6nce olmalıdır.",rangeUnderflow:e=>`De\u{11F}er, ${e.minValue} veya sonras\u{131} olmal\u{131}d\u{131}r.`,unavailableDate:"Se\xe7ilen tarih kullanılamıyor."},"uk-UA":{rangeOverflow:e=>`\u{417}\u{43D}\u{430}\u{447}\u{435}\u{43D}\u{43D}\u{44F} \u{43C}\u{430}\u{454} \u{431}\u{443}\u{442}\u{438} \u{43D}\u{435} \u{43F}\u{456}\u{437}\u{43D}\u{456}\u{448}\u{435} ${e.maxValue}.`,rangeReversed:"Дата початку має передувати даті завершення.",rangeUnderflow:e=>`\u{417}\u{43D}\u{430}\u{447}\u{435}\u{43D}\u{43D}\u{44F} \u{43C}\u{430}\u{454} \u{431}\u{443}\u{442}\u{438} \u{43D}\u{435} \u{440}\u{430}\u{43D}\u{456}\u{448}\u{435} ${e.minValue}.`,unavailableDate:"Вибрана дата недоступна."},"zh-CN":{rangeOverflow:e=>`\u{503C}\u{5FC5}\u{987B}\u{662F} ${e.maxValue} \u{6216}\u{66F4}\u{65E9}\u{65E5}\u{671F}\u{3002}`,rangeReversed:"开始日期必须早于结束日期。",rangeUnderflow:e=>`\u{503C}\u{5FC5}\u{987B}\u{662F} ${e.minValue} \u{6216}\u{66F4}\u{665A}\u{65E5}\u{671F}\u{3002}`,unavailableDate:"所选日期不可用。"},"zh-TW":{rangeOverflow:e=>`\u{503C}\u{5FC5}\u{9808}\u{662F} ${e.maxValue} \u{6216}\u{66F4}\u{65E9}\u{3002}`,rangeReversed:"開始日期必須在結束日期之前。",rangeUnderflow:e=>`\u{503C}\u{5FC5}\u{9808}\u{662F} ${e.minValue} \u{6216}\u{66F4}\u{665A}\u{3002}`,unavailableDate:"所選日期無法使用。"}};let uF={badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valueMissing:!1,valid:!0},uN={...uF,customError:!0,valid:!1},uM={isInvalid:!1,validationDetails:uF,validationErrors:[]},uB=(0,em.createContext)({}),uL="__formValidationState"+Date.now();function uV(e){if(e[uL]){let{realtimeValidation:t,displayValidation:r,updateValidation:n,resetValidation:o,commitValidation:i}=e[uL];return{realtimeValidation:t,displayValidation:r,updateValidation:n,resetValidation:o,commitValidation:i}}return function(e){let{isInvalid:t,validationState:r,name:n,value:o,builtinValidation:i,validate:a,validationBehavior:u="aria"}=e;r&&(t||(t="invalid"===r));let s=void 0!==t?{isInvalid:t,validationErrors:[],validationDetails:uN}:null,l=(0,em.useMemo)(()=>a&&null!=o?u$(function(e,t){if("function"==typeof e){let r=e(t);if(r&&"boolean"!=typeof r)return uU(r)}return[]}(a,o)):null,[a,o]);(null==i?void 0:i.validationDetails.valid)&&(i=void 0);let c=(0,em.useContext)(uB),d=(0,em.useMemo)(()=>n?Array.isArray(n)?n.flatMap(e=>uU(c[e])):uU(c[n]):[],[c,n]),[f,p]=(0,em.useState)(c),[h,m]=(0,em.useState)(!1);c!==f&&(p(c),m(!1));let y=(0,em.useMemo)(()=>u$(h?[]:d),[h,d]),b=(0,em.useRef)(uM),[v,g]=(0,em.useState)(uM),w=(0,em.useRef)(uM),[E,S]=(0,em.useState)(!1);return(0,em.useEffect)(()=>{if(!E)return;S(!1);let e=l||i||b.current;uW(e,w.current)||(w.current=e,g(e))}),{realtimeValidation:s||y||l||i||uM,displayValidation:"native"===u?s||y||v:s||y||l||i||v,updateValidation(e){"aria"!==u||uW(v,e)?b.current=e:g(e)},resetValidation(){uW(uM,w.current)||(w.current=uM,g(uM)),"native"===u&&S(!1),m(!0)},commitValidation(){"native"===u&&S(!0),m(!0)}}}(e)}function uU(e){return e?Array.isArray(e)?e:[e]:[]}function u$(e){return e.length?{isInvalid:!0,validationErrors:e,validationDetails:uN}:null}function uW(e,t){return e===t||!!e&&!!t&&e.isInvalid===t.isInvalid&&e.validationErrors.length===t.validationErrors.length&&e.validationErrors.every((e,r)=>e===t.validationErrors[r])&&Object.entries(e.validationDetails).every(([e,r])=>t.validationDetails[e]===r)}function uz(...e){let t=new Set,r=!1,n={...uF};for(let o of e){for(let e of o.validationErrors)t.add(e);for(let e in r||(r=o.isInvalid),n)n[e]||(n[e]=o.validationDetails[e])}return n.valid=!r,{isInvalid:r,validationErrors:[...t],validationDetails:n}}let uK=new i_((l=uR)&&l.__esModule?l.default:l);function uH(){return"u">typeof navigator&&(navigator.language||navigator.userLanguage)||"en-US"}function uG(e,t,r,n,o){let i=null!=e&&null!=r&&e.compare(r)>0,a=null!=e&&null!=t&&0>e.compare(t),u=null!=e&&(null==n?void 0:n(e))||!1,s=i||a||u,l=[];if(s){let e=uH(),n=new iP(e,i_.getGlobalDictionaryForPackage("@react-stately/datepicker")||uK),s=new iF(e,uY({},o)),c=s.resolvedOptions().timeZone;a&&null!=t&&l.push(n.format("rangeUnderflow",{minValue:s.format(t.toDate(c))})),i&&null!=r&&l.push(n.format("rangeOverflow",{maxValue:s.format(r.toDate(c))})),u&&l.push(n.format("unavailableDate"))}return{isInvalid:s,validationErrors:l,validationDetails:{badInput:u,customError:!1,patternMismatch:!1,rangeOverflow:i,rangeUnderflow:a,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valueMissing:!1,valid:!s}}}let uq={year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"2-digit",second:"2-digit"},uZ={year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"};function uY(e,t){var r;e={...t.shouldForceLeadingZeros?uZ:uq,...e};let n=t.granularity||"minute",o=Object.keys(e),i=o.indexOf(null!=(r=t.maxGranularity)?r:"year");i<0&&(i=0);let a=o.indexOf(n);if(a<0&&(a=2),i>a)throw Error("maxGranularity must be greater than granularity");let u=o.slice(i,a+1).reduce((t,r)=>(t[r]=e[r],t),{});return null!=t.hourCycle&&(u.hour12=12===t.hourCycle),u.timeZone=t.timeZone||"UTC",("hour"===n||"minute"===n||"second"===n)&&t.timeZone&&!t.hideTimeZone&&(u.timeZoneName="short"),t.showEra&&0===i&&(u.era="short"),u}function uJ(e){return e&&"hour"in e?e:new oQ}function uX(e,t){return null===e?null:e?ii(e,t):void 0}function uQ(e,t,r,n){if(e)return uX(e,r);let o=ii(ip(null!=n?n:iv()).set({hour:0,minute:0,second:0,millisecond:0}),r);return"year"===t||"month"===t||"day"===t?ir(o):n?o:io(o)}function u0(e,t){let r=e&&"timeZone"in e?e.timeZone:void 0,n=e&&"minute"in e?"minute":"day";if(e&&t&&!(t in e))throw Error("Invalid granularity "+t+" for value "+e.toString());let[o,i]=(0,em.useState)([n,r]);return e&&(o[0]!==n||o[1]!==r)&&i([n,r]),t||(t=e?n:o[0]),[t,e?r:o[1]]}let u1=new i_({ach:{year:"mwaka",month:"dwe",day:"nino"},af:{year:"jjjj",month:"mm",day:"dd"},am:{year:"ዓዓዓዓ",month:"ሚሜ",day:"ቀቀ"},an:{year:"aaaa",month:"mm",day:"dd"},ar:{year:"سنة",month:"شهر",day:"يوم"},ast:{year:"aaaa",month:"mm",day:"dd"},az:{year:"iiii",month:"aa",day:"gg"},be:{year:"гггг",month:"мм",day:"дд"},bg:{year:"гггг",month:"мм",day:"дд"},bn:{year:"yyyy",month:"মিমি",day:"dd"},br:{year:"bbbb",month:"mm",day:"dd"},bs:{year:"gggg",month:"mm",day:"dd"},ca:{year:"aaaa",month:"mm",day:"dd"},cak:{year:"jjjj",month:"ii",day:"q'q'"},ckb:{year:"ساڵ",month:"مانگ",day:"ڕۆژ"},cs:{year:"rrrr",month:"mm",day:"dd"},cy:{year:"bbbb",month:"mm",day:"dd"},da:{year:"\xe5\xe5\xe5\xe5",month:"mm",day:"dd"},de:{year:"jjjj",month:"mm",day:"tt"},dsb:{year:"llll",month:"mm",day:"źź"},el:{year:"εεεε",month:"μμ",day:"ηη"},en:{year:"yyyy",month:"mm",day:"dd"},eo:{year:"jjjj",month:"mm",day:"tt"},es:{year:"aaaa",month:"mm",day:"dd"},et:{year:"aaaa",month:"kk",day:"pp"},eu:{year:"uuuu",month:"hh",day:"ee"},fa:{year:"سال",month:"ماه",day:"روز"},ff:{year:"hhhh",month:"ll",day:"\xf1\xf1"},fi:{year:"vvvv",month:"kk",day:"pp"},fr:{year:"aaaa",month:"mm",day:"jj"},fy:{year:"jjjj",month:"mm",day:"dd"},ga:{year:"bbbb",month:"mm",day:"ll"},gd:{year:"bbbb",month:"mm",day:"ll"},gl:{year:"aaaa",month:"mm",day:"dd"},he:{year:"שנה",month:"חודש",day:"יום"},hr:{year:"gggg",month:"mm",day:"dd"},hsb:{year:"llll",month:"mm",day:"dd"},hu:{year:"\xe9\xe9\xe9\xe9",month:"hh",day:"nn"},ia:{year:"aaaa",month:"mm",day:"dd"},id:{year:"tttt",month:"bb",day:"hh"},it:{year:"aaaa",month:"mm",day:"gg"},ja:{year:"年",month:"月",day:"日"},ka:{year:"წწწწ",month:"თთ",day:"რრ"},kk:{year:"жжжж",month:"аа",day:"кк"},kn:{year:"ವವವವ",month:"ಮಿಮೀ",day:"ದಿದಿ"},ko:{year:"연도",month:"월",day:"일"},lb:{year:"jjjj",month:"mm",day:"dd"},lo:{year:"ປປປປ",month:"ດດ",day:"ວວ"},lt:{year:"mmmm",month:"mm",day:"dd"},lv:{year:"gggg",month:"mm",day:"dd"},meh:{year:"aaaa",month:"mm",day:"dd"},ml:{year:"വർഷം",month:"മാസം",day:"തീയതി"},ms:{year:"tttt",month:"mm",day:"hh"},nl:{year:"jjjj",month:"mm",day:"dd"},nn:{year:"\xe5\xe5\xe5\xe5",month:"mm",day:"dd"},no:{year:"\xe5\xe5\xe5\xe5",month:"mm",day:"dd"},oc:{year:"aaaa",month:"mm",day:"jj"},pl:{year:"rrrr",month:"mm",day:"dd"},pt:{year:"aaaa",month:"mm",day:"dd"},rm:{year:"oooo",month:"mm",day:"dd"},ro:{year:"aaaa",month:"ll",day:"zz"},ru:{year:"гггг",month:"мм",day:"дд"},sc:{year:"aaaa",month:"mm",day:"dd"},scn:{year:"aaaa",month:"mm",day:"jj"},sk:{year:"rrrr",month:"mm",day:"dd"},sl:{year:"llll",month:"mm",day:"dd"},sr:{year:"гггг",month:"мм",day:"дд"},sv:{year:"\xe5\xe5\xe5\xe5",month:"mm",day:"dd"},szl:{year:"rrrr",month:"mm",day:"dd"},tg:{year:"сссс",month:"мм",day:"рр"},th:{year:"ปปปป",month:"ดด",day:"วว"},tr:{year:"yyyy",month:"aa",day:"gg"},uk:{year:"рррр",month:"мм",day:"дд"},"zh-CN":{year:"年",month:"月",day:"日"},"zh-TW":{year:"年",month:"月",day:"日"}},"en"),u2={year:!0,month:!0,day:!0,hour:!0,minute:!0,second:!0,dayPeriod:!0,era:!0},u3={year:5,month:2,day:7,hour:2,minute:15,second:15},u4={dayperiod:"dayPeriod"};function u6(e){var t,r;let{locale:n,createCalendar:o,hideTimeZone:i,isDisabled:a=!1,isReadOnly:u=!1,isRequired:s=!1,minValue:l,maxValue:c,isDateUnavailable:d}=e,f=e.value||e.defaultValue||e.placeholderValue||null,[p,h]=u0(f,e.granularity),m=h||"UTC";if(f&&!(p in f))throw Error("Invalid granularity "+p+" for value "+f.toString());let y=(0,em.useMemo)(()=>new iF(n),[n]),b=(0,em.useMemo)(()=>o(y.resolvedOptions().calendar),[o,y]),[v,g]=aH(e.value,null!=(t=e.defaultValue)?t:null,e.onChange),w=(0,em.useMemo)(()=>{var e;return null!=(e=uX(v,b))?e:null},[v,b]),[E,S]=(0,em.useState)(()=>uQ(e.placeholderValue,p,b,h)),O="gregory"===b.identifier&&"BC"===(w||E).era,A=(0,em.useMemo)(()=>{var t;return{granularity:p,maxGranularity:null!=(t=e.maxGranularity)?t:"year",timeZone:h,hideTimeZone:i,hourCycle:e.hourCycle,showEra:O,shouldForceLeadingZeros:e.shouldForceLeadingZeros}},[e.maxGranularity,p,e.hourCycle,e.shouldForceLeadingZeros,h,i,O]),x=(0,em.useMemo)(()=>uY({},A),[A]),D=(0,em.useMemo)(()=>new iF(n,x),[n,x]),j=(0,em.useMemo)(()=>D.resolvedOptions(),[D]),C=(0,em.useMemo)(()=>D.formatToParts(new Date).filter(e=>u2[e.type]).reduce((e,t)=>(e[t.type]=!0,e),{}),[D]),[P,k]=(0,em.useState)(()=>e.value||e.defaultValue?{...C}:{}),I=(0,em.useRef)(null),T=(0,em.useRef)(b);(0,em.useEffect)(()=>{il(b,T.current)||(T.current=b,S(t=>Object.keys(P).length>0?ii(t,b):uQ(e.placeholderValue,p,b,h)))},[b,p,P,h,e.placeholderValue]),v&&Object.keys(P).length<Object.keys(C).length&&k(P={...C}),null==v&&Object.keys(P).length===Object.keys(C).length&&(k(P={}),S(uQ(e.placeholderValue,p,b,h)));let R=w&&Object.keys(P).length>=Object.keys(C).length?w:E,F=t=>{if(e.isDisabled||e.isReadOnly)return;let r=Object.keys(P),n=Object.keys(C);null==t?(g(null),S(uQ(e.placeholderValue,p,b,h)),k({})):r.length>=n.length||r.length===n.length-1&&C.dayPeriod&&!P.dayPeriod&&"dayPeriod"!==I.current?g(t=ii(t,(null==f?void 0:f.calendar)||new oC)):S(t),I.current=null},N=(0,em.useMemo)(()=>R.toDate(m),[R,m]),M=(0,em.useMemo)(()=>(function(e,t,r,n,o,i,a,u){let s=["hour","minute","second"],l=r.formatToParts(e),c=[];for(let e of l){var d,f;let r=u2[e.type];"era"===e.type&&1===i.getEras().length&&(r=!1);let l=u2[e.type]&&!t[e.type],p=u2[e.type]?(d=e.type,f=e.value,"era"===d||"dayPeriod"===d?f:"year"===d||"month"===d||"day"===d?u1.getStringForLocale(d,a):"––"):null,h={type:u4[e.type]||e.type,text:l?p:e.value,...u5(o,e.type,n),isPlaceholder:l,placeholder:p,isEditable:r};"hour"===e.type?(c.push({type:"literal",text:"⁦",...u5(o,"literal",n),isPlaceholder:!1,placeholder:"",isEditable:!1}),c.push(h),e.type===u&&c.push({type:"literal",text:"⁩",...u5(o,"literal",n),isPlaceholder:!1,placeholder:"",isEditable:!1})):s.includes(e.type)&&e.type===u?(c.push(h),c.push({type:"literal",text:"⁩",...u5(o,"literal",n),isPlaceholder:!1,placeholder:"",isEditable:!1})):c.push(h)}return c})(N,P,D,j,R,b,n,p),[N,P,D,j,R,b,n,p]);C.era&&P.year&&!P.era?(P.era=!0,k({...P})):!C.era&&P.era&&(delete P.era,k({...P}));let B=e=>{P[e]=!0,"year"===e&&C.era&&(P.era=!0),k({...P})},L=(e,t)=>{if(P[e])F(function(e,t,r,n){switch(t){case"era":case"year":case"month":case"day":return e.cycle(t,r,{round:"year"===t})}if("hour"in e)switch(t){case"dayPeriod":{let t=e.hour;return e.set({hour:t>=12?t-12:t+12})}case"hour":case"minute":case"second":return e.cycle(t,r,{round:"hour"!==t,hourCycle:n.hour12?12:24})}throw Error("Unknown segment: "+t)}(R,e,t,j));else{B(e);let t=Object.keys(P),r=Object.keys(C);(t.length>=r.length||t.length===r.length-1&&C.dayPeriod&&!P.dayPeriod)&&F(R)}},V=(0,em.useMemo)(()=>uG(v,l,c,d,A),[v,l,c,d,A]),U=uV({...e,value:v,builtinValidation:V}),$=U.displayValidation.isInvalid,W=e.validationState||($?"invalid":null);return{...U,value:w,dateValue:N,calendar:b,setValue:F,segments:M,dateFormatter:D,validationState:W,isInvalid:$,granularity:p,maxGranularity:null!=(r=e.maxGranularity)?r:"year",isDisabled:a,isReadOnly:u,isRequired:s,increment(e){L(e,1)},decrement(e){L(e,-1)},incrementPage(e){L(e,u3[e]||1)},decrementPage(e){L(e,-(u3[e]||1))},setSegment(e,t){B(e),F(function(e,t,r,n){switch(t){case"day":case"month":case"year":case"era":return e.set({[t]:r})}if("hour"in e&&"number"==typeof r)switch(t){case"dayPeriod":{let t=e.hour,n=t>=12;if(r>=12===n)return e;return e.set({hour:n?t-12:t+12})}case"hour":if(n.hour12){let t=e.hour>=12;t||12!==r||(r=0),t&&r<12&&(r+=12)}case"minute":case"second":return e.set({[t]:r})}throw Error("Unknown segment: "+t)}(R,e,t,j))},confirmPlaceholder(){if(e.isDisabled||e.isReadOnly)return;let t=Object.keys(P),r=Object.keys(C);t.length===r.length-1&&C.dayPeriod&&!P.dayPeriod&&(k(P={...C}),F(R.copy()))},clearSegment(t){delete P[t],I.current=t,k({...P});let r=uQ(e.placeholderValue,p,b,h),n=R;if("dayPeriod"===t&&"hour"in R&&"hour"in r){let e=R.hour>=12,t=r.hour>=12;e&&!t?n=R.set({hour:R.hour-12}):!e&&t&&(n=R.set({hour:R.hour+12}))}else"hour"===t&&"hour"in R&&R.hour>=12&&P.dayPeriod?n=R.set({hour:r.hour+12}):t in R&&(n=R.set({[t]:r[t]}));g(null),F(n)},formatValue:e=>w?new iF(n,uY(e,A)).format(N):"",getDateFormatter:(e,t)=>new iF(e,uY({},{...A,...t}))}}function u5(e,t,r){switch(t){case"era":{let t=e.calendar.getEras();return{value:t.indexOf(e.era),minValue:0,maxValue:t.length-1}}case"year":return{value:e.year,minValue:1,maxValue:e.calendar.getYearsInEra(e)};case"month":return{value:e.month,minValue:e.calendar.getMinimumMonthInYear?e.calendar.getMinimumMonthInYear(e):1,maxValue:e.calendar.getMonthsInYear(e)};case"day":return{value:e.day,minValue:e.calendar.getMinimumDayInMonth?e.calendar.getMinimumDayInMonth(e):1,maxValue:e.calendar.getDaysInMonth(e)}}if("hour"in e)switch(t){case"dayPeriod":return{value:12*(e.hour>=12),minValue:0,maxValue:12};case"hour":if(r.hour12){let t=e.hour>=12;return{value:e.hour,minValue:12*!!t,maxValue:t?23:11}}return{value:e.hour,minValue:0,maxValue:23};case"minute":return{value:e.minute,minValue:0,maxValue:59};case"second":return{value:e.second,minValue:0,maxValue:59}}return{}}let u8=(0,em.createContext)(null),u7=(0,em.createContext)(null),u9=(0,em.createContext)(null),se=(0,em.forwardRef)(function(e,t){let r=(0,em.useContext)(u7),n=(0,em.useContext)(u9);return r||n?ey().createElement(sr,{...e,ref:t}):ey().createElement(st,{...e,ref:t})}),st=(0,em.forwardRef)((e,t)=>{let[r,n]=rN({slot:e.slot},t,u8),{locale:o}=oE(),i=u6({...r,locale:o,createCalendar:aB}),a=(0,em.useRef)(null),{fieldProps:u,inputProps:s}=uT({...r,inputRef:a},i,n);return ey().createElement(rT,{values:[[u7,i],[ur,{...s,ref:a}],[ue,{...u,ref:n,isInvalid:i.isInvalid,isDisabled:i.isDisabled}]]},ey().createElement(sr,e))}),sr=(0,em.forwardRef)((e,t)=>{let{className:r,children:n}=e,o=(0,em.useContext)(u7),i=(0,em.useContext)(u9),a=null!=o?o:i;return ey().createElement(ey().Fragment,null,ey().createElement(ut,{...e,ref:t,slot:e.slot||void 0,className:null!=r?r:"react-aria-DateInput",isInvalid:a.isInvalid,isDisabled:a.isDisabled},a.segments.map((e,t)=>(0,em.cloneElement)(n(e),{key:t}))),ey().createElement(un,null))}),sn=(0,em.createContext)({});function so({children:e}){let t=(0,em.useMemo)(()=>({register:()=>{}}),[]);return ey().createElement(ny.Provider,{value:t},e)}ey().forwardRef(({children:e,...t},r)=>{let n=(0,em.useRef)(!1),o=(0,em.useContext)(ny);r=rp(r||(null==o?void 0:o.ref));let i=rk(o||{},{...t,ref:r,register(){n.current=!0,o&&o.register()}});return nw(o,r),(0,em.useEffect)(()=>{n.current||(n.current=!0)},[]),ey().createElement(ny.Provider,{value:i},e)});let si=ey().createContext(null);function sa(e){var t;let r=rx(),{portalContainer:n=r?null:document.body,isExiting:o}=e,[i,a]=(0,em.useState)(!1),u=(0,em.useMemo)(()=>({contain:i,setContain:a}),[i,a]),{getContainer:s}=null!=(t=(0,em.useContext)(sn))?t:{};if(!e.portalContainer&&s&&(n=s()),!n)return null;let l=e.children;return e.disableFocusManagement||(l=ey().createElement(us,{restoreFocus:!0,contain:(e.shouldContainFocus||i)&&!o},l)),l=ey().createElement(si.Provider,{value:u},ey().createElement(so,null,l)),n_().createPortal(l,n)}let su=(0,em.createContext)(null),ss=(0,em.createContext)(null),sl=(0,em.forwardRef)(function(e,t){let r=e["aria-labelledby"];[e,t]=rN(e,t,su);let{dialogProps:n,titleProps:o}=function(e,t){let r,n,{role:o="dialog"}=e,i=rC();i=e["aria-label"]?void 0:i;let a=(0,em.useRef)(!1);return(0,em.useEffect)(()=>{if(t.current&&!t.current.contains(document.activeElement)){n0(t.current);let e=setTimeout(()=>{document.activeElement===t.current&&(a.current=!0,t.current&&(t.current.blur(),n0(t.current)),a.current=!1)},500);return()=>{clearTimeout(e)}}},[t]),rm(()=>{null==n||n(!0)},[n=null==(r=(0,em.useContext)(si))?void 0:r.setContain]),{dialogProps:{...rG(e,{labelable:!0}),role:o,tabIndex:-1,"aria-labelledby":e["aria-labelledby"]||i,onBlur:e=>{a.current&&e.stopPropagation()}},titleProps:{id:i}}}({...e,"aria-labelledby":r},t),i=(0,em.useContext)(ss);n["aria-label"]||n["aria-labelledby"]||e["aria-labelledby"]&&(n["aria-labelledby"]=e["aria-labelledby"]);let a=rR({defaultClassName:"react-aria-Dialog",className:e.className,style:e.style,children:e.children,values:{close:(null==i?void 0:i.close)||(()=>{})}});return ey().createElement("section",{...rG(e),...n,...a,ref:t,slot:e.slot||void 0},ey().createElement(rT,{values:[[ou,{slots:{[rI]:{},title:{...o,level:2}}}],[oi,{slots:{[rI]:{},close:{onPress:()=>null==i?void 0:i.close()}}}]]},a.children))}),sc=(0,em.createContext)(null),sd=(0,em.forwardRef)(function(e,t){let r=(0,em.useContext)(sc);return(null==r?void 0:r.isInvalid)?ey().createElement(sf,{...e,ref:t}):null}),sf=(0,em.forwardRef)((e,t)=>{let r=(0,em.useContext)(sc),n=rG(e),o=rR({...e,defaultClassName:"react-aria-FieldError",defaultChildren:0===r.validationErrors.length?void 0:r.validationErrors.join(" "),values:r});return null==o.children?null:ey().createElement(ol,{slot:"errorMessage",...n,...o,ref:t})}),sp=(0,em.createContext)(null),sh=(0,em.createContext)({}),sm=on(function(e,t){[e,t]=rN(e,t,sh);let{elementType:r="label",...n}=e;return ey().createElement(r,{className:"react-aria-Label",...n,ref:t})}),sy=(0,em.createContext)({placement:"bottom"}),sb=new WeakMap,sv=[];function sg(e,t=-1/0,r=1/0){return Math.min(Math.max(e,t),r)}function sw(e,t){let r=e,n=t.toString(),o=n.indexOf("."),i=o>=0?n.length-o:0;if(i>0){let e=Math.pow(10,i);r=Math.round(r*e)/e}return r}function sE(e,t,r,n){t=Number(t),r=Number(r);let o=(e-(isNaN(t)?0:t))%n,i=sw(2*Math.abs(o)>=n?e+Math.sign(o)*(n-Math.abs(o)):e-o,n);return isNaN(t)?!isNaN(r)&&i>r&&(i=Math.floor(sw(r/n,n))*n):i<t?i=t:!isNaN(r)&&i>r&&(i=t+Math.floor(sw((r-t)/n,n))*n),i=sw(i,n)}let sS={top:"top",bottom:"top",left:"left",right:"left"},sO={top:"bottom",bottom:"top",left:"right",right:"left"},sA={top:"left",left:"top"},sx={top:"height",left:"width"},sD={width:"totalWidth",height:"totalHeight"},s_={},sj="u">typeof document?window.visualViewport:null;function sC(e){var t,r,n,o,i;let a=0,u=0,s=0,l=0,c=0,d=0,f={},p=(null!=(t=null==sj?void 0:sj.scale)?t:1)>1;if("BODY"===e.tagName){let t=document.documentElement;s=t.clientWidth,l=t.clientHeight,a=null!=(r=null==sj?void 0:sj.width)?r:s,u=null!=(n=null==sj?void 0:sj.height)?n:l,f.top=t.scrollTop||e.scrollTop,f.left=t.scrollLeft||e.scrollLeft,sj&&(c=sj.offsetTop,d=sj.offsetLeft)}else({width:a,height:u,top:c,left:d}=sR(e)),f.top=e.scrollTop,f.left=e.scrollLeft,s=a,l=u;return no()&&("BODY"===e.tagName||"HTML"===e.tagName)&&p&&(f.top=0,f.left=0,c=null!=(o=null==sj?void 0:sj.pageTop)?o:0,d=null!=(i=null==sj?void 0:sj.pageLeft)?i:0),{width:a,height:u,totalWidth:s,totalHeight:l,scroll:f,top:c,left:d}}function sP(e,t,r,n,o,i,a){var u;let s=null!=(u=o.scroll[e])?u:0,l=n[sx[e]],c=n.scroll[sS[e]]+i,d=l+n.scroll[sS[e]]-i,f=t-s+a[e]-n[sS[e]],p=t-s+r+a[e]-n[sS[e]];return f<c?c-f:p>d?Math.max(d-p,c-f):0}function sk(e){if(s_[e])return s_[e];let[t,r]=e.split(" "),n=sS[t]||"right",o=sA[n];sS[r]||(r="center");let i=sx[n],a=sx[o];return s_[e]={placement:t,crossPlacement:r,axis:n,crossAxis:o,size:i,crossSize:a},s_[e]}function sI(e,t,r,n,o,i,a,u,s,l){var c,d,f,p,h;let{placement:m,crossPlacement:y,axis:b,crossAxis:v,size:g,crossSize:w}=n,E={};E[v]=null!=(c=e[v])?c:0,"center"===y?E[v]+=((null!=(d=e[w])?d:0)-(null!=(f=r[w])?f:0))/2:y!==v&&(E[v]+=(null!=(p=e[w])?p:0)-(null!=(h=r[w])?h:0)),E[v]+=i;let S=e[v]-r[w]+s+l,O=e[v]+e[w]-s-l;if(E[v]=sg(E[v],S,O),m===b){let r=u?a[g]:t[sD[g]];E[sO[b]]=Math.floor(r-e[b]+o)}else E[b]=Math.floor(e[b]+e[g]+o);return E}function sT(e,t,r,n,o,i){var a,u,s;let{placement:l,axis:c,size:d}=i;return l===c?Math.max(0,r[c]-e[c]-(null!=(a=e.scroll[c])?a:0)+t[c]-(null!=(u=n[c])?u:0)-n[sO[c]]-o):Math.max(0,e[d]+e[c]+e.scroll[c]-t[c]-r[c]-r[d]-(null!=(s=n[c])?s:0)-n[sO[c]]-o)}function sR(e){let{top:t,left:r,width:n,height:o}=e.getBoundingClientRect(),{scrollTop:i,scrollLeft:a,clientTop:u,clientLeft:s}=document.documentElement;return{top:t+i-u,left:r+a-s,width:n,height:o}}function sF(e,t){let r,n=window.getComputedStyle(e);if("fixed"===n.position){let{top:t,left:n,width:o,height:i}=e.getBoundingClientRect();r={top:t,left:n,width:o,height:i}}else{r=sR(e);let n=sR(t),o=window.getComputedStyle(t);n.top+=(parseInt(o.borderTopWidth,10)||0)-t.scrollTop,n.left+=(parseInt(o.borderLeftWidth,10)||0)-t.scrollLeft,r.top-=n.top,r.left-=n.left}return r.top-=parseInt(n.marginTop,10)||0,r.left-=parseInt(n.marginLeft,10)||0,r}function sN(e){let t=window.getComputedStyle(e);return"none"!==t.transform||/transform|perspective/.test(t.willChange)||"none"!==t.filter||"paint"===t.contain||"backdropFilter"in t&&"none"!==t.backdropFilter||"WebkitBackdropFilter"in t&&"none"!==t.WebkitBackdropFilter}let sM=new WeakMap;function sB(e){let{ref:t,box:r,onResize:n}=e;(0,em.useEffect)(()=>{let e=null==t?void 0:t.current;if(e)if(void 0===window.ResizeObserver)return window.addEventListener("resize",n,!1),()=>{window.removeEventListener("resize",n,!1)};else{let t=new window.ResizeObserver(e=>{e.length&&n()});return t.observe(e,{box:r}),()=>{e&&t.unobserve(e)}}},[n,t,r])}let sL="u">typeof document?window.visualViewport:null;function sV(e,t){if(e.button>0)return!1;if(e.target){let t=e.target.ownerDocument;if(!t||!t.documentElement.contains(e.target)||e.target.closest("[data-react-aria-top-layer]"))return!1}return!!t.current&&!e.composedPath().includes(t.current)}let sU=[],s$="u">typeof document&&window.visualViewport,sW=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]),sz=0;function sK(e,t,r){let n=e.style[t];return e.style[t]=r,()=>{e.style[t]=n}}function sH(e,t,r,n){return e.addEventListener(t,r,n),()=>{e.removeEventListener(t,r,n)}}function sG(e){let t=document.scrollingElement||document.documentElement,r=e;for(;r&&r!==t;){let e=i5(r);if(e!==document.documentElement&&e!==document.body&&e!==r){let t=e.getBoundingClientRect().top,n=r.getBoundingClientRect().top;n>t+r.clientHeight&&(e.scrollTop+=n-t)}r=e.parentElement}}var sq={};function sZ(e){var t;let{onDismiss:r,...n}=e,o=iZ(n,iT((t=sq)&&t.__esModule?t.default:t,"@react-aria/overlays").format("dismiss"));return ey().createElement(iX,null,ey().createElement("button",{...o,tabIndex:-1,onClick:()=>{r&&r()},style:{width:1,height:1}}))}function sY(e,t,r){rm(()=>{if(t&&e.current){if(!("getAnimations"in e.current))return void r();let t=e.current.getAnimations();if(0===t.length)return void r();let n=!1;return Promise.all(t.map(e=>e.finished)).then(()=>{n||(0,nD.flushSync)(()=>{r()})}).catch(()=>{}),()=>{n=!0}}},[e,t,r])}function sJ(e){let[t,r]=aH(e.isOpen,e.defaultOpen||!1,e.onOpenChange),n=(0,em.useCallback)(()=>{r(!0)},[r]),o=(0,em.useCallback)(()=>{r(!1)},[r]),i=(0,em.useCallback)(()=>{r(!t)},[r,t]);return{isOpen:t,setOpen:r,open:n,close:o,toggle:i}}sq={"ar-AE":{dismiss:"تجاهل"},"bg-BG":{dismiss:"Отхвърляне"},"cs-CZ":{dismiss:"Odstranit"},"da-DK":{dismiss:"Luk"},"de-DE":{dismiss:"Schlie\xdfen"},"el-GR":{dismiss:"Απόρριψη"},"en-US":{dismiss:"Dismiss"},"es-ES":{dismiss:"Descartar"},"et-EE":{dismiss:"L\xf5peta"},"fi-FI":{dismiss:"Hylk\xe4\xe4"},"fr-FR":{dismiss:"Rejeter"},"he-IL":{dismiss:"התעלם"},"hr-HR":{dismiss:"Odbaci"},"hu-HU":{dismiss:"Elutas\xedt\xe1s"},"it-IT":{dismiss:"Ignora"},"ja-JP":{dismiss:"閉じる"},"ko-KR":{dismiss:"무시"},"lt-LT":{dismiss:"Atmesti"},"lv-LV":{dismiss:"Nerādīt"},"nb-NO":{dismiss:"Lukk"},"nl-NL":{dismiss:"Negeren"},"pl-PL":{dismiss:"Zignoruj"},"pt-BR":{dismiss:"Descartar"},"pt-PT":{dismiss:"Dispensar"},"ro-RO":{dismiss:"Revocare"},"ru-RU":{dismiss:"Пропустить"},"sk-SK":{dismiss:"Zrušiť"},"sl-SI":{dismiss:"Opusti"},"sr-SP":{dismiss:"Odbaci"},"sv-SE":{dismiss:"Avvisa"},"tr-TR":{dismiss:"Kapat"},"uk-UA":{dismiss:"Скасувати"},"zh-CN":{dismiss:"取消"},"zh-TW":{dismiss:"關閉"}};let sX=(0,em.createContext)(null),sQ=(0,em.createContext)(null),s0=(0,em.forwardRef)(function(e,t){[e,t]=rN(e,t,sX);let r=(0,em.useContext)(ss),n=sJ(e),o=null==e.isOpen&&null==e.defaultOpen&&r?r:n,i=function(e,t){let[r,n]=(0,em.useState)(t?"open":"closed");switch(r){case"open":t||n("exiting");break;case"closed":case"exiting":t&&n("open")}let o="exiting"===r;return sY(e,o,(0,em.useCallback)(()=>{n(e=>"exiting"===e?"closed":e)},[])),o}(t,o.isOpen)||e.isExiting||!1,a=(0,em.useContext)(or),{direction:u}=oE();if(a){let t=e.children;return"function"==typeof t&&(t=t({trigger:e.trigger||null,placement:"bottom",isEntering:!1,isExiting:!1,defaultChildren:null})),ey().createElement(ey().Fragment,null,t)}return!o||o.isOpen||i?ey().createElement(s1,{...e,triggerRef:e.triggerRef,state:o,popoverRef:t,isExiting:i,dir:u}):null});function s1({state:e,isExiting:t,UNSTABLE_portalContainer:r,...n}){var o,i;let u=(0,em.useRef)(null),[s,l]=(0,em.useState)(0),c=(0,em.useRef)(null),d=(0,em.useContext)(sQ),f=d&&"SubmenuTrigger"===n.trigger;rm(()=>{u.current&&e.isOpen&&l(u.current.getBoundingClientRect().width)},[e.isOpen,u]);let{popoverProps:p,underlayProps:h,arrowProps:m,placement:y}=function(e,t){let{triggerRef:r,popoverRef:n,groupRef:o,isNonModal:i,isKeyboardDismissDisabled:u,shouldCloseOnInteractOutside:s,...l}=e,c="SubmenuTrigger"===l.trigger,{overlayProps:d,underlayProps:f}=function(e,t){let{onClose:r,shouldCloseOnBlur:n,isOpen:o,isDismissable:i=!1,isKeyboardDismissDisabled:a=!1,shouldCloseOnInteractOutside:u}=e;(0,em.useEffect)(()=>{if(o&&!sU.includes(t))return sU.push(t),()=>{let e=sU.indexOf(t);e>=0&&sU.splice(e,1)}},[o,t]);let s=()=>{sU[sU.length-1]===t&&r&&r()};!function(e){let{ref:t,onInteractOutside:r,isDisabled:n,onInteractOutsideStart:o}=e,i=(0,em.useRef)({isPointerDown:!1,ignoreEmulatedMouseEvents:!1}),a=ry(e=>{r&&sV(e,t)&&(o&&o(e),i.current.isPointerDown=!0)}),u=ry(e=>{r&&r(e)});(0,em.useEffect)(()=>{let e=i.current;if(n)return;let r=rQ(t.current);if("u">typeof PointerEvent){let n=r=>{e.isPointerDown&&sV(r,t)&&u(r),e.isPointerDown=!1};return r.addEventListener("pointerdown",a,!0),r.addEventListener("pointerup",n,!0),()=>{r.removeEventListener("pointerdown",a,!0),r.removeEventListener("pointerup",n,!0)}}},[t,n,a,u])}({ref:t,onInteractOutside:i&&o?e=>{(!u||u(e.target))&&(sU[sU.length-1]===t&&(e.stopPropagation(),e.preventDefault()),s())}:void 0,onInteractOutsideStart:e=>{(!u||u(e.target))&&sU[sU.length-1]===t&&(e.stopPropagation(),e.preventDefault())}});let{focusWithinProps:l}=n6({isDisabled:!n,onBlurWithin:e=>{!(!e.relatedTarget||uf(e.relatedTarget,uu))&&(!u||u(e.relatedTarget))&&(null==r||r())}});return{overlayProps:{onKeyDown:e=>{"Escape"!==e.key||a||e.nativeEvent.isComposing||(e.stopPropagation(),e.preventDefault(),s())},...l},underlayProps:{onPointerDown:e=>{e.target===e.currentTarget&&e.preventDefault()}}}}({isOpen:t.isOpen,onClose:t.close,shouldCloseOnBlur:!0,isDismissable:!i||c,isKeyboardDismissDisabled:u,shouldCloseOnInteractOutside:s},null!=o?o:n),{overlayProps:p,arrowProps:h,placement:m}=function(e){var t,r,n;let{direction:o}=oE(),{arrowSize:i=0,targetRef:a,overlayRef:u,scrollRef:s=u,placement:l="bottom",containerPadding:c=12,shouldFlip:d=!0,boundaryElement:f="u">typeof document?document.body:null,offset:p=0,crossOffset:h=0,shouldUpdatePosition:m=!0,isOpen:y=!0,onClose:b,maxHeight:v,arrowBoundaryOffset:g=0}=e,[w,E]=(0,em.useState)(null),S=[m,l,u.current,a.current,s.current,c,d,f,p,h,y,o,v,g,i],O=(0,em.useRef)(null==sL?void 0:sL.scale);(0,em.useEffect)(()=>{y&&(O.current=null==sL?void 0:sL.scale)},[y]);let A=(0,em.useCallback)(()=>{var e,t,r,n,b,w;if(!1===m||!y||!u.current||!a.current||!f||(null==sL?void 0:sL.scale)!==O.current)return;let S=null;if(s.current&&s.current.contains(document.activeElement)){let n=null==(e=document.activeElement)?void 0:e.getBoundingClientRect(),o=s.current.getBoundingClientRect();(S={type:"top",offset:(null!=(t=null==n?void 0:n.top)?t:0)-o.top}).offset>o.height/2&&(S.type="bottom",S.offset=(null!=(r=null==n?void 0:n.bottom)?r:0)-o.bottom)}let A=u.current;!v&&u.current&&(A.style.top="0px",A.style.bottom="",A.style.maxHeight=(null!=(b=null==(n=window.visualViewport)?void 0:n.height)?b:window.innerHeight)+"px");let x=function(e){var t,r,n,o;let i,{placement:a,targetNode:u,overlayNode:s,scrollNode:l,padding:c,shouldFlip:d,boundaryElement:f,offset:p,crossOffset:h,maxHeight:m,arrowSize:y=0,arrowBoundaryOffset:b=0}=e,v=s instanceof HTMLElement?function(e){let t=e.offsetParent;if(t&&t===document.body&&"static"===window.getComputedStyle(t).position&&!sN(t)&&(t=document.documentElement),null==t)for(t=e.parentElement;t&&!sN(t);)t=t.parentElement;return t||document.documentElement}(s):document.documentElement,g=v===document.documentElement,w=window.getComputedStyle(v).position,E=g?sR(u):sF(u,v);if(!g){let{marginTop:e,marginLeft:t}=window.getComputedStyle(u);E.top+=parseInt(e,10)||0,E.left+=parseInt(t,10)||0}let S=sR(s),O={top:parseInt((i=window.getComputedStyle(s)).marginTop,10)||0,bottom:parseInt(i.marginBottom,10)||0,left:parseInt(i.marginLeft,10)||0,right:parseInt(i.marginRight,10)||0};S.width+=(null!=(t=O.left)?t:0)+(null!=(r=O.right)?r:0),S.height+=(null!=(n=O.top)?n:0)+(null!=(o=O.bottom)?o:0);let A={top:l.scrollTop,left:l.scrollLeft,width:l.scrollWidth,height:l.scrollHeight},x=sC(f),D=sC(v),j="BODY"===f.tagName?sR(v):sF(v,f);return"HTML"===v.tagName&&"BODY"===f.tagName&&(D.scroll.top=0,D.scroll.left=0),function(e,t,r,n,o,i,a,u,s,l,c,d,f,p,h,m){var y,b,v,g,w,E,S,O,A,x,D,j,C,P;let k,I,T,R=sk(e),{size:F,crossAxis:N,crossSize:M,placement:B,crossPlacement:L}=R,V=sI(t,u,r,R,c,d,l,f,h,m),U=c,$=sT(u,l,t,o,i+c,R);if(a&&n[F]>$){let e=sk(`${sO[B]} ${L}`),n=sI(t,u,r,e,c,d,l,f,h,m);sT(u,l,t,o,i+c,e)>$&&(R=e,V=n,U=c)}let W="bottom";"top"===R.axis?"top"===R.placement?W="top":"bottom"===R.placement&&(W="bottom"):"top"===R.crossAxis&&("top"===R.crossPlacement?W="bottom":"bottom"===R.crossPlacement&&(W="top"));let z=sP(N,V[N],r[M],u,s,i,l);V[N]+=z;let K=(w=V,E=r.height,S=W,k=f?l.height:u[sD.height],I=null!=w.top?l.top+w.top:l.top+(k-(null!=(O=w.bottom)?O:0)-E),T="top"!==S?Math.max(0,u.height+u.top+(null!=(A=u.scroll.top)?A:0)-I-((null!=(x=o.top)?x:0)+(null!=(D=o.bottom)?D:0)+i)):Math.max(0,I+E-(u.top+(null!=(j=u.scroll.top)?j:0))-((null!=(C=o.top)?C:0)+(null!=(P=o.bottom)?P:0)+i)),Math.min(u.height-2*i,T));p&&p<K&&(K=p),r.height=Math.min(r.height,K),z=sP(N,(V=sI(t,u,r,R,U,d,l,f,h,m))[N],r[M],u,s,i,l),V[N]+=z;let H={},G=t[N]+.5*t[M]-V[N]-o[sS[N]],q=h/2+m,Z="left"===sS[N]?(null!=(y=o.left)?y:0)+(null!=(b=o.right)?b:0):(null!=(v=o.top)?v:0)+(null!=(g=o.bottom)?g:0),Y=r[M]-Z-h/2-m,J=sg(G,t[N]+h/2-(V[N]+o[sS[N]]),t[N]+t[M]-h/2-(V[N]+o[sS[N]]));return H[N]=sg(J,q,Y),{position:V,maxHeight:K,arrowOffsetLeft:H.left,arrowOffsetTop:H.top,placement:R.placement}}(a,E,S,A,O,c,d,x,D,j,p,h,!!w&&"static"!==w,m,y,b)}({placement:(w=l,"rtl"===o?w.replace("start","right").replace("end","left"):w.replace("start","left").replace("end","right")),overlayNode:u.current,targetNode:a.current,scrollNode:s.current||u.current,padding:c,shouldFlip:d,boundaryElement:f,offset:p,crossOffset:h,maxHeight:v,arrowSize:i,arrowBoundaryOffset:g});if(x.position){if(A.style.top="",A.style.bottom="",A.style.left="",A.style.right="",Object.keys(x.position).forEach(e=>A.style[e]=x.position[e]+"px"),A.style.maxHeight=null!=x.maxHeight?x.maxHeight+"px":"",S&&document.activeElement&&s.current){let e=document.activeElement.getBoundingClientRect(),t=s.current.getBoundingClientRect(),r=e[S.type]-t[S.type];s.current.scrollTop+=r-S.offset}E(x)}},S);rm(A,S),rm(()=>(window.addEventListener("resize",n,!1),()=>{window.removeEventListener("resize",n,!1)}),[n=A]),sB({ref:u,onResize:A}),sB({ref:a,onResize:A});let x=(0,em.useRef)(!1);rm(()=>{let e,t=()=>{x.current=!0,clearTimeout(e),e=setTimeout(()=>{x.current=!1},500),A()},r=()=>{x.current&&t()};return null==sL||sL.addEventListener("resize",t),null==sL||sL.addEventListener("scroll",r),()=>{null==sL||sL.removeEventListener("resize",t),null==sL||sL.removeEventListener("scroll",r)}},[A]);let D=(0,em.useCallback)(()=>{x.current||null==b||b()},[b,x]);return!function(e){let{triggerRef:t,isOpen:r,onClose:n}=e;(0,em.useEffect)(()=>{if(!r||null===n)return;let e=e=>{let r=e.target;if(!t.current||r instanceof Node&&!r.contains(t.current)||e.target instanceof HTMLInputElement||e.target instanceof HTMLTextAreaElement)return;let o=n||sM.get(t.current);o&&o()};return window.addEventListener("scroll",e,!0),()=>{window.removeEventListener("scroll",e,!0)}},[r,n,t])}({triggerRef:a,isOpen:y,onClose:b&&D}),{overlayProps:{style:{position:"absolute",zIndex:1e5,...null==w?void 0:w.position,maxHeight:null!=(t=null==w?void 0:w.maxHeight)?t:"100vh"}},placement:null!=(r=null==w?void 0:w.placement)?r:null,arrowProps:{"aria-hidden":"true",role:"presentation",style:{left:null==w?void 0:w.arrowOffsetLeft,top:null==w?void 0:w.arrowOffsetTop}},updatePosition:A}}({...l,targetRef:r,overlayRef:n,isOpen:t.isOpen,onClose:i&&!c?t.close:null});return!function(e={}){let{isDisabled:t}=e;rm(()=>{if(!t){let e,t,r,n;return 1==++sz&&(a=nn()?(r=null,n=rh(sH(document,"touchstart",r=>{((e=i5(r.target,!0))!==document.documentElement||e!==document.body)&&e instanceof HTMLElement&&"auto"===window.getComputedStyle(e).overscrollBehavior&&(t=sK(e,"overscrollBehavior","contain"))},{passive:!1,capture:!0}),sH(document,"touchmove",t=>{e&&e!==document.documentElement&&e!==document.body?e.scrollHeight===e.clientHeight&&e.scrollWidth===e.clientWidth&&t.preventDefault():t.preventDefault()},{passive:!1,capture:!0}),sH(document,"touchend",()=>{t&&t()},{passive:!1,capture:!0}),sH(document,"focus",e=>{var t;let n=e.target;((t=n)instanceof HTMLInputElement&&!sW.has(t.type)||t instanceof HTMLTextAreaElement||t instanceof HTMLElement&&t.isContentEditable)&&((()=>{if(r)return;let e=window.pageXOffset,t=window.pageYOffset;r=rh(sH(window,"scroll",()=>{window.scrollTo(0,0)}),sK(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),sK(document.documentElement,"overflow","hidden"),sK(document.body,"marginTop",`-${t}px`),()=>{window.scrollTo(e,t)}),window.scrollTo(0,0)})(),n.style.transform="translateY(-2000px)",requestAnimationFrame(()=>{n.style.transform="",s$&&(s$.height<window.innerHeight?requestAnimationFrame(()=>{sG(n)}):s$.addEventListener("resize",()=>sG(n),{once:!0}))}))},!0)),()=>{null==t||t(),null==r||r(),n()}):rh(sK(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),sK(document.documentElement,"overflow","hidden"))),()=>{0==--sz&&a()}}},[t])}({isDisabled:i||!t.isOpen}),rm(()=>{if(t.isOpen&&n.current){if(!i)return function(e,t=document.body){let r=new Set(e),n=new Set,o=e=>{for(let t of e.querySelectorAll("[data-live-announcer], [data-react-aria-top-layer]"))r.add(t);let t=e=>{if(r.has(e)||e.parentElement&&n.has(e.parentElement)&&"row"!==e.parentElement.getAttribute("role"))return NodeFilter.FILTER_REJECT;for(let t of r)if(e.contains(t))return NodeFilter.FILTER_SKIP;return NodeFilter.FILTER_ACCEPT},o=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:t}),a=t(e);if(a===NodeFilter.FILTER_ACCEPT&&i(e),a!==NodeFilter.FILTER_REJECT){let e=o.nextNode();for(;null!=e;)i(e),e=o.nextNode()}},i=e=>{var t;let r=null!=(t=sb.get(e))?t:0;("true"!==e.getAttribute("aria-hidden")||0!==r)&&(0===r&&e.setAttribute("aria-hidden","true"),n.add(e),sb.set(e,r+1))};sv.length&&sv[sv.length-1].disconnect(),o(t);let a=new MutationObserver(e=>{for(let t of e)if("childList"===t.type&&0!==t.addedNodes.length&&![...r,...n].some(e=>e.contains(t.target))){for(let e of t.removedNodes)e instanceof Element&&(r.delete(e),n.delete(e));for(let e of t.addedNodes)(e instanceof HTMLElement||e instanceof SVGElement)&&("true"===e.dataset.liveAnnouncer||"true"===e.dataset.reactAriaTopLayer)?r.add(e):e instanceof Element&&o(e)}});a.observe(t,{childList:!0,subtree:!0});let u={visibleNodes:r,hiddenNodes:n,observe(){a.observe(t,{childList:!0,subtree:!0})},disconnect(){a.disconnect()}};return sv.push(u),()=>{for(let e of(a.disconnect(),n)){let t=sb.get(e);null!=t&&(1===t?(e.removeAttribute("aria-hidden"),sb.delete(e)):sb.set(e,t-1))}u===sv[sv.length-1]?(sv.pop(),sv.length&&sv[sv.length-1].observe()):sv.splice(sv.indexOf(u),1)}}([null!=(r=null==o?void 0:o.current)?r:n.current]);var e,r,a=null!=(e=null==o?void 0:o.current)?e:n.current;let t=sv[sv.length-1];return t&&!t.visibleNodes.has(a)?(t.visibleNodes.add(a),()=>{t.visibleNodes.delete(a)}):void 0}},[i,t.isOpen,n,o]),{popoverProps:rk(d,p),arrowProps:h,underlayProps:f,placement:m}}({...n,offset:null!=(o=n.offset)?o:8,arrowSize:s,groupRef:f?d:c},e),b=n.popoverRef,v=function(e,t=!0){let[r,n]=(0,em.useState)(!0),o=r&&t;return rm(()=>{if(o&&e.current&&"getAnimations"in e.current)for(let t of e.current.getAnimations())t instanceof CSSTransition&&t.cancel()},[e,o]),sY(e,o,(0,em.useCallback)(()=>n(!1),[])),o}(b,!!y)||n.isEntering||!1,g=rR({...n,defaultClassName:"react-aria-Popover",values:{trigger:n.trigger||null,placement:y,isEntering:v,isExiting:t}}),w=!n.isNonModal||"SubmenuTrigger"===n.trigger,[E,S]=(0,em.useState)(!1);rm(()=>{b.current&&S(w&&!b.current.querySelector("[role=dialog]"))},[b,w]),(0,em.useEffect)(()=>{E&&b.current&&!b.current.contains(document.activeElement)&&n0(b.current)},[E,b]);let O={...p.style,...g.style},A=ey().createElement("div",{...rk(rG(n),p),...g,role:E?"dialog":void 0,tabIndex:E?-1:void 0,"aria-label":n["aria-label"],"aria-labelledby":n["aria-labelledby"],ref:b,slot:n.slot||void 0,style:O,dir:n.dir,"data-trigger":n.trigger,"data-placement":y,"data-entering":v||void 0,"data-exiting":t||void 0},!n.isNonModal&&ey().createElement(sZ,{onDismiss:e.close}),ey().createElement(sy.Provider,{value:{...m,placement:y,ref:u}},g.children),ey().createElement(sZ,{onDismiss:e.close}));return f?ey().createElement(sa,{...n,shouldContainFocus:E,isExiting:t,portalContainer:null!=(i=null!=r?r:null==d?void 0:d.current)?i:void 0},A):ey().createElement(sa,{...n,shouldContainFocus:E,isExiting:t,portalContainer:r},!n.isNonModal&&e.isOpen&&ey().createElement("div",{"data-testid":"underlay",...h,style:{position:"fixed",inset:0}}),ey().createElement("div",{ref:c,style:{display:"contents"}},ey().createElement(sQ.Provider,{value:c},A)))}function s2(e){return(null==e?void 0:e.start)!=null&&null!=e.end}let s3=(0,em.createContext)(null),s4=(0,em.createContext)(null),s6=(0,em.createContext)(null),s5=(0,em.createContext)(null),s8=(0,em.forwardRef)(function(e,t){var r,n;[e,t]=rN(e,t,s3);let{validationBehavior:o}=rF(sp)||{},i=null!=(n=null!=(r=e.validationBehavior)?r:o)?n:"native",a=function(e){var t;let r=sJ(e),[n,o]=aH(e.value,e.defaultValue||null,e.onChange),i=n||e.placeholderValue||null,[a,u]=u0(i,e.granularity),s=null!=n?n.toDate(null!=u?u:"UTC"):null,l="hour"===a||"minute"===a||"second"===a,c=null==(t=e.shouldCloseOnSelect)||t,[d,f]=(0,em.useState)(null),[p,h]=(0,em.useState)(null);if(n&&(d=n,"hour"in n&&(p=n)),i&&!(a in i))throw Error("Invalid granularity "+a+" for value "+i.toString());let m=(null==n?void 0:n.calendar.identifier)==="gregory"&&"BC"===n.era,y=(0,em.useMemo)(()=>({granularity:a,timeZone:u,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,shouldForceLeadingZeros:e.shouldForceLeadingZeros,showEra:m}),[a,e.hourCycle,e.shouldForceLeadingZeros,u,e.hideTimeZone,m]),{minValue:b,maxValue:v,isDateUnavailable:g}=e,w=(0,em.useMemo)(()=>uG(n,b,v,g,y),[n,b,v,g,y]),E=uV({...e,value:n,builtinValidation:w}),S=E.displayValidation.isInvalid,O=e.validationState||(S?"invalid":null),A=(e,t)=>{o("timeZone"in t?t.set(ir(e)):io(e,t)),f(null),h(null),E.commitValidation()};return{...E,value:n,setValue:o,dateValue:d,timeValue:p,setDateValue:t=>{let n="function"==typeof c?c():c;l?p||n?A(t,p||uJ(e.defaultValue||e.placeholderValue)):f(t):(o(t),E.commitValidation()),n&&r.setOpen(!1)},setTimeValue:e=>{d&&e?A(d,e):h(e)},granularity:a,hasTime:l,...r,setOpen(t){!t&&!n&&d&&l&&A(d,p||uJ(e.defaultValue||e.placeholderValue)),r.setOpen(t)},validationState:O,isInvalid:S,formatValue:(e,t)=>s?new iF(e,uY(t,y)).format(s):"",getDateFormatter:(e,t)=>new iF(e,uY({},{...y,...t}))}}({...e,validationBehavior:i}),u=(0,em.useRef)(null),[s,l]=rM(!e["aria-label"]&&!e["aria-labelledby"]),{groupProps:c,labelProps:d,fieldProps:f,buttonProps:p,dialogProps:h,calendarProps:m,descriptionProps:y,errorMessageProps:b,...v}=function(e,t,r){var n;let o=rj(),i=rj(),a=rj(),u=iT((n=uo)&&n.__esModule?n.default:n,"@react-aria/datepicker"),{isInvalid:s,validationErrors:l,validationDetails:c}=t.displayValidation,{labelProps:d,fieldProps:f,descriptionProps:p,errorMessageProps:h}=uj({...e,labelElementType:"span",isInvalid:s,errorMessage:e.errorMessage||l}),m=ux(t,r),y=f["aria-labelledby"]||f.id,{locale:b}=oE(),v=t.formatValue(b,{month:"long"}),g=i2(v?u.format("selectedDateDescription",{date:v}):""),w=[g["aria-describedby"],f["aria-describedby"]].filter(Boolean).join(" ")||void 0,E=rG(e),S=(0,em.useMemo)(()=>uw(r),[r]),O=(0,em.useRef)(!1),{focusWithinProps:A}=n6({...e,isDisabled:t.isOpen,onBlurWithin:t=>{let r=document.getElementById(i);if(!(null==r?void 0:r.contains(t.relatedTarget))){var n,o;O.current=!1,null==(n=e.onBlur)||n.call(e,t),null==(o=e.onFocusChange)||o.call(e,!1)}},onFocusWithin:t=>{if(!O.current){var r,n;O.current=!0,null==(r=e.onFocus)||r.call(e,t),null==(n=e.onFocusChange)||n.call(e,!0)}}});return{groupProps:rk(E,m,f,g,A,{role:"group","aria-disabled":e.isDisabled||null,"aria-labelledby":y,"aria-describedby":w,onKeyDown(r){!t.isOpen&&e.onKeyDown&&e.onKeyDown(r)},onKeyUp(r){!t.isOpen&&e.onKeyUp&&e.onKeyUp(r)}}),labelProps:{...d,onClick:()=>{S.focusFirst()}},fieldProps:{...f,id:a,[uk]:"presentation","aria-describedby":w,value:t.value,onChange:t.setValue,placeholderValue:e.placeholderValue,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,shouldForceLeadingZeros:e.shouldForceLeadingZeros,granularity:e.granularity,isDisabled:e.isDisabled,isReadOnly:e.isReadOnly,isRequired:e.isRequired,validationBehavior:e.validationBehavior,[uL]:t,autoFocus:e.autoFocus,name:e.name},descriptionProps:p,errorMessageProps:h,buttonProps:{...g,id:o,"aria-haspopup":"dialog","aria-label":u.format("calendar"),"aria-labelledby":`${o} ${y}`,"aria-describedby":w,"aria-expanded":t.isOpen,isDisabled:e.isDisabled||e.isReadOnly,onPress:()=>t.setOpen(!0)},dialogProps:{id:i,"aria-labelledby":`${o} ${y}`},calendarProps:{autoFocus:!0,value:t.dateValue,onChange:t.setDateValue,minValue:e.minValue,maxValue:e.maxValue,isDisabled:e.isDisabled,isReadOnly:e.isReadOnly,isDateUnavailable:e.isDateUnavailable,defaultFocusedValue:t.dateValue?void 0:e.placeholderValue,isInvalid:t.isInvalid,errorMessage:"function"==typeof e.errorMessage?e.errorMessage(t.displayValidation):e.errorMessage||t.displayValidation.validationErrors.join(" ")},isInvalid:s,validationErrors:l,validationDetails:c}}({...rB(e),label:l,validationBehavior:i},a,u),[g,w]=(0,em.useState)(null),E=(0,em.useCallback)(()=>{u.current&&w(u.current.offsetWidth+"px")},[]);sB({ref:u,onResize:E});let{focusProps:S,isFocused:O,isFocusVisible:A}=n5({within:!0}),x=rR({...e,values:{state:a,isFocusWithin:O,isFocusVisible:A,isDisabled:e.isDisabled||!1,isInvalid:a.isInvalid,isOpen:a.isOpen},defaultClassName:"react-aria-DatePicker"}),D=rG(e);return delete D.id,ey().createElement(rT,{values:[[s6,a],[ue,{...c,ref:u,isInvalid:a.isInvalid}],[u8,f],[oi,{...p,isPressed:a.isOpen}],[sh,{...d,ref:s,elementType:"span"}],[aX,m],[ss,a],[sX,{trigger:"DatePicker",triggerRef:u,placement:"bottom start",style:{"--trigger-width":g}}],[su,h],[os,{slots:{description:y,errorMessage:b}}],[sc,v]]},ey().createElement("div",{...S,...D,...x,ref:t,slot:e.slot||void 0,"data-focus-within":O||void 0,"data-invalid":a.isInvalid||void 0,"data-focus-visible":A||void 0,"data-disabled":e.isDisabled||void 0,"data-open":a.isOpen||void 0}))}),s7=(0,em.forwardRef)(function(e,t){var r,n;[e,t]=rN(e,t,s4);let{validationBehavior:o}=rF(sp)||{},i=null!=(n=null!=(r=e.validationBehavior)?r:o)?n:"native",a=function(e){var t,r,n;let o=sJ(e),[i,a]=aH(e.value,e.defaultValue||null,e.onChange),[u,s]=(0,em.useState)(()=>i||{start:null,end:null});null==i&&u.start&&u.end&&s(u={start:null,end:null});let l=i||u,c=e=>{s(e||{start:null,end:null}),s2(e)?a(e):a(null)},[d,f]=u0((null==l?void 0:l.start)||(null==l?void 0:l.end)||e.placeholderValue||null,e.granularity),p="hour"===d||"minute"===d||"second"===d,h=null==(n=e.shouldCloseOnSelect)||n,[m,y]=(0,em.useState)(null),[b,v]=(0,em.useState)(null);l&&s2(l)&&(m=l,"hour"in l.start&&(b=l));let g=(e,t)=>{c({start:"timeZone"in t.start?t.start.set(ir(e.start)):io(e.start,t.start),end:"timeZone"in t.end?t.end.set(ir(e.end)):io(e.end,t.end)}),y(null),v(null),C.commitValidation()},w=t=>{let r="function"==typeof h?h():h;p?s2(t)&&(null==b?void 0:b.start)&&(null==b?void 0:b.end)?g(t,{start:(null==b?void 0:b.start)||uJ(e.placeholderValue),end:(null==b?void 0:b.end)||uJ(e.placeholderValue)}):y(t):s2(t)?(c(t),C.commitValidation()):y(t),r&&o.setOpen(!1)},E=e=>{s2(m)&&s2(e)?g(m,e):v(e)},S=(null==l||null==(t=l.start)?void 0:t.calendar.identifier)==="gregory"&&"BC"===l.start.era||(null==l||null==(r=l.end)?void 0:r.calendar.identifier)==="gregory"&&"BC"===l.end.era,O=(0,em.useMemo)(()=>({granularity:d,timeZone:f,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,shouldForceLeadingZeros:e.shouldForceLeadingZeros,showEra:S}),[d,e.hourCycle,e.shouldForceLeadingZeros,f,e.hideTimeZone,S]),{minValue:A,maxValue:x,isDateUnavailable:D}=e,j=(0,em.useMemo)(()=>{var e,t;let r;return r=uz(uG(null!=(e=null==l?void 0:l.start)?e:null,A,x,D,O),uG(null!=(t=null==l?void 0:l.end)?t:null,A,x,D,O)),(null==l?void 0:l.end)!=null&&null!=l.start&&0>l.end.compare(l.start)&&(r=uz(r,{isInvalid:!0,validationErrors:[(i_.getGlobalDictionaryForPackage("@react-stately/datepicker")||uK).getStringForLocale("rangeReversed",uH())],validationDetails:{...uF,rangeUnderflow:!0,rangeOverflow:!0,valid:!1}})),r},[l,A,x,D,O]),C=uV({...e,value:i,name:(0,em.useMemo)(()=>[e.startName,e.endName].filter(e=>null!=e),[e.startName,e.endName]),builtinValidation:j}),P=C.displayValidation.isInvalid,k=e.validationState||(P?"invalid":null);return{...C,value:l,setValue:c,dateRange:m,timeRange:b,granularity:d,hasTime:p,setDate(e,t){var r,n;"start"===e?w({start:t,end:null!=(r=null==m?void 0:m.end)?r:null}):w({start:null!=(n=null==m?void 0:m.start)?n:null,end:t})},setTime(e,t){var r,n;"start"===e?E({start:t,end:null!=(r=null==b?void 0:b.end)?r:null}):E({start:null!=(n=null==b?void 0:b.start)?n:null,end:t})},setDateTime(e,t){var r,n;"start"===e?c({start:t,end:null!=(r=null==l?void 0:l.end)?r:null}):c({start:null!=(n=null==l?void 0:l.start)?n:null,end:t})},setDateRange:w,setTimeRange:E,...o,setOpen(t){!t&&!((null==l?void 0:l.start)&&(null==l?void 0:l.end))&&s2(m)&&p&&g(m,{start:(null==b?void 0:b.start)||uJ(e.placeholderValue),end:(null==b?void 0:b.end)||uJ(e.placeholderValue)}),o.setOpen(t)},validationState:k,isInvalid:P,formatValue(t,r){let n;if(!l||!l.start||!l.end)return null;let o="timeZone"in l.start?l.start.timeZone:void 0,i=e.granularity||(l.start&&"minute"in l.start?"minute":"day"),a="timeZone"in l.end?l.end.timeZone:void 0,u=e.granularity||(l.end&&"minute"in l.end?"minute":"day"),s=uY(r,{granularity:i,timeZone:o,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,showEra:"gregory"===l.start.calendar.identifier&&"BC"===l.start.era||"gregory"===l.end.calendar.identifier&&"BC"===l.end.era}),c=l.start.toDate(o||"UTC"),d=l.end.toDate(a||"UTC"),f=new iF(t,s);if(o===a&&i===u&&0!==l.start.compare(l.end)){try{let e=f.formatRangeToParts(c,d),t=-1;for(let r=0;r<e.length;r++){let n=e[r];if("shared"===n.source&&"literal"===n.type)t=r;else if("endRange"===n.source)break}let r="",n="";for(let o=0;o<e.length;o++)o<t?r+=e[o].value:o>t&&(n+=e[o].value);return{start:r,end:n}}catch{}n=f}else n=new iF(t,uY(r,{granularity:u,timeZone:a,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle}));return{start:f.format(c),end:n.format(d)}},getDateFormatter:(e,t)=>new iF(e,uY({},{...O,...t}))}}({...e,validationBehavior:i}),u=(0,em.useRef)(null),[s,l]=rM(!e["aria-label"]&&!e["aria-labelledby"]),{groupProps:c,labelProps:d,startFieldProps:f,endFieldProps:p,buttonProps:h,dialogProps:m,calendarProps:y,descriptionProps:b,errorMessageProps:v,...g}=function(e,t,r){var n,o,i,a,u,s;let l=iT((s=uo)&&s.__esModule?s.default:s,"@react-aria/datepicker"),{isInvalid:c,validationErrors:d,validationDetails:f}=t.displayValidation,{labelProps:p,fieldProps:h,descriptionProps:m,errorMessageProps:y}=uj({...e,labelElementType:"span",isInvalid:c,errorMessage:e.errorMessage||d}),b=h["aria-labelledby"]||h.id,{locale:v}=oE(),g=t.formatValue(v,{month:"long"}),w=i2(g?l.format("selectedRangeDescription",{startDate:g.start,endDate:g.end}):""),E={"aria-label":l.format("startDate"),"aria-labelledby":b},S={"aria-label":l.format("endDate"),"aria-labelledby":b},O=rj(),A=rj(),x=ux(t,r),D=[w["aria-describedby"],h["aria-describedby"]].filter(Boolean).join(" ")||void 0,j=(0,em.useMemo)(()=>uw(r,{accept:e=>e.id!==O}),[r,O]),C={[uI]:j,[uk]:"presentation","aria-describedby":D,placeholderValue:e.placeholderValue,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,granularity:e.granularity,shouldForceLeadingZeros:e.shouldForceLeadingZeros,isDisabled:e.isDisabled,isReadOnly:e.isReadOnly,isRequired:e.isRequired,validationBehavior:e.validationBehavior},P=rG(e),k=(0,em.useRef)(!1),{focusWithinProps:I}=n6({...e,isDisabled:t.isOpen,onBlurWithin:t=>{let r=document.getElementById(A);if(!(null==r?void 0:r.contains(t.relatedTarget))){var n,o;k.current=!1,null==(n=e.onBlur)||n.call(e,t),null==(o=e.onFocusChange)||o.call(e,!1)}},onFocusWithin:t=>{if(!k.current){var r,n;k.current=!0,null==(r=e.onFocus)||r.call(e,t),null==(n=e.onFocusChange)||n.call(e,!0)}}}),T=(0,em.useRef)(uM),R=(0,em.useRef)(uM);return{groupProps:rk(P,x,h,w,I,{role:"group","aria-disabled":e.isDisabled||null,"aria-describedby":D,onKeyDown(r){!t.isOpen&&e.onKeyDown&&e.onKeyDown(r)},onKeyUp(r){!t.isOpen&&e.onKeyUp&&e.onKeyUp(r)}}),labelProps:{...p,onClick:()=>{j.focusFirst()}},buttonProps:{...w,id:O,"aria-haspopup":"dialog","aria-label":l.format("calendar"),"aria-labelledby":`${O} ${b}`,"aria-describedby":D,"aria-expanded":t.isOpen,isDisabled:e.isDisabled||e.isReadOnly,onPress:()=>t.setOpen(!0)},dialogProps:{id:A,"aria-labelledby":`${O} ${b}`},startFieldProps:{...E,...C,value:null!=(a=null==(n=t.value)?void 0:n.start)?a:null,onChange:e=>t.setDateTime("start",e),autoFocus:e.autoFocus,name:e.startName,[uL]:{realtimeValidation:t.realtimeValidation,displayValidation:t.displayValidation,updateValidation(e){T.current=e,t.updateValidation(uz(e,R.current))},resetValidation:t.resetValidation,commitValidation:t.commitValidation}},endFieldProps:{...S,...C,value:null!=(u=null==(o=t.value)?void 0:o.end)?u:null,onChange:e=>t.setDateTime("end",e),name:e.endName,[uL]:{realtimeValidation:t.realtimeValidation,displayValidation:t.displayValidation,updateValidation(e){R.current=e,t.updateValidation(uz(T.current,e))},resetValidation:t.resetValidation,commitValidation:t.commitValidation}},descriptionProps:m,errorMessageProps:y,calendarProps:{autoFocus:!0,value:(null==(i=t.dateRange)?void 0:i.start)&&t.dateRange.end?t.dateRange:null,onChange:t.setDateRange,minValue:e.minValue,maxValue:e.maxValue,isDisabled:e.isDisabled,isReadOnly:e.isReadOnly,isDateUnavailable:e.isDateUnavailable,allowsNonContiguousRanges:e.allowsNonContiguousRanges,defaultFocusedValue:t.dateRange?void 0:e.placeholderValue,isInvalid:t.isInvalid,errorMessage:"function"==typeof e.errorMessage?e.errorMessage(t.displayValidation):e.errorMessage||t.displayValidation.validationErrors.join(" ")},isInvalid:c,validationErrors:d,validationDetails:f}}({...rB(e),label:l,validationBehavior:i},a,u),[w,E]=(0,em.useState)(null),S=(0,em.useCallback)(()=>{u.current&&E(u.current.offsetWidth+"px")},[]);sB({ref:u,onResize:S});let{focusProps:O,isFocused:A,isFocusVisible:x}=n5({within:!0}),D=rR({...e,values:{state:a,isFocusWithin:A,isFocusVisible:x,isDisabled:e.isDisabled||!1,isInvalid:a.isInvalid,isOpen:a.isOpen},defaultClassName:"react-aria-DateRangePicker"}),j=rG(e);return delete j.id,ey().createElement(rT,{values:[[s5,a],[ue,{...c,ref:u,isInvalid:a.isInvalid}],[oi,{...h,isPressed:a.isOpen}],[sh,{...d,ref:s,elementType:"span"}],[aQ,y],[ss,a],[sX,{trigger:"DateRangePicker",triggerRef:u,placement:"bottom start",style:{"--trigger-width":w}}],[su,m],[u8,{slots:{start:f,end:p}}],[os,{slots:{description:b,errorMessage:v}}],[sc,g]]},ey().createElement("div",{...O,...j,...D,ref:t,slot:e.slot||void 0,"data-focus-within":A||void 0,"data-invalid":a.isInvalid||void 0,"data-focus-visible":x||void 0,"data-disabled":e.isDisabled||void 0,"data-open":a.isOpen||void 0}))});function s9(e){return ey().createElement(ow,e)}var le=r(1712),lt=r.n(le);function lr(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}function ln(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(null==e)return r?e:void 0;if("string"==typeof e&&!e)return r?null:void 0;if(lr(e,oJ)||lr(e,o1)||lr(e,o3))return t?ii(e,t):e;var n=lt()(e).toDate(),o=new oJ(n.getFullYear(),n.getMonth()+1,n.getDate());return t?ii(o,t):o}function lo(e){if(e)return e.toDate(iv())}function li(){var e=window.i18next.language;return"ht"===(e=e.replace("_","-"))&&(e="fr-HT"),e}if("u">typeof navigator){let e=navigator;c=Array.isArray(e.languages)?e.languages[0]:e.language}else if("u">typeof process){let e=process.env;c=e.LC_ALL||e.LC_MESSAGES||e.LANG||e.LANGUAGE}var la=function(e){e=(e=e.replace(/_/g,"-")).replace(/[.:][\w-]*$/,"");try{return new Intl.Locale(e).baseName}catch(e){return"en-US"}}(c||"en-US"),lu=class extends Date{invalid=null;isValid(){return!Number.isNaN(this.valueOf())}},ls={};for(let e=0;e<100;e++)ls[(e<=9?"0":"")+e]=e+(e>51?1900:2e3);var ll={arab:1632,arabext:1776,bali:6992,beng:2534,deva:2406,fullwide:65296,gujr:2790,khmr:6112,knda:3302,laoo:3792,limb:6470,mlym:3430,mong:6160,mymr:4160,orya:2918,tamldec:3046,telu:3174,thai:3664,tibt:3872},lc="[1234567890一二三四五六七八九〇\\d]",ld={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,"0":0,"1":1,"2":2,"3":3,"4":4,"5":5,"6":6,"7":7,"8":8,"9":9,〇:0,一:1,二:2,三:3,四:4,五:5,六:6,七:7,八:8,九:9},lf={},lp={"Eastern Daylight Time":-240,"Eastern Standard Time":-300,"Central Daylight Time":-300,"Central Standard Time":-360,"Mountain Daylight Time":-360,"Mountain Standard Time":-420,"Pacific Daylight Time":-420,"Pacific Standard Time":-480,"Coordinated Universal Time":0,ACDT:630,ACST:570,ACT:480,ADT:-180,AEDT:660,AEST:600,AFT:270,AKDT:-480,AKST:-540,AMST:-180,AMT:-240,ART:-180,AST:180,AWDT:540,AWST:480,AZOST:-60,AZT:240,BDT:360,BIOT:360,BIT:-720,BOT:-240,BRST:-120,BRT:-180,BTT:360,CAT:120,CCT:390,CDT:-300,CEDT:120,CEST:120,CET:60,CHADT:825,CHAST:765,CHOT:480,ChST:600,CHUT:600,CIST:-480,CIT:480,CKT:-600,CLST:-180,CLT:-240,COST:-240,COT:-300,CST:-360,CT:480,CVT:-60,CXT:420,DAVT:420,DDUT:600,DFT:60,EASST:-300,EAST:-360,EAT:180,ECT:-300,EDT:-240,EEDT:180,EEST:180,EET:120,EGST:0,EGT:-60,EIT:540,EST:-300,FET:180,FJT:720,FKST:-180,FKT:-240,FNT:-120,GALT:-360,GAMT:-540,GET:240,GFT:-180,GILT:720,GIT:-540,GMT:0,GST:-120,GYT:-240,HADT:-540,HAEC:120,HAST:-600,HKT:480,HMT:300,HOVT:420,HST:-600,IBST:0,ICT:420,IDT:180,IOT:180,IRDT:270,IRKT:480,IRST:210,IST:120,JST:540,KGT:360,KOST:660,KRAT:420,KST:540,LHST:630,LINT:840,MAGT:720,MART:-510,MAWT:300,MDT:-360,MET:60,MEST:120,MHT:720,MIST:660,MIT:-510,MMT:390,MSK:180,MST:-420,MUT:240,MVT:300,MYT:480,NCT:660,NDT:-90,NFT:660,NPT:345,NST:-150,NT:-150,NUT:-660,NZDT:780,NZST:720,OMST:360,ORAT:300,PDT:-420,PET:-300,PETT:720,PGT:600,PHOT:780,PKT:300,PMDT:-120,PMST:-180,PONT:660,PST:-480,PYST:-180,PYT:-240,RET:240,ROTT:-180,SAKT:660,SAMT:240,SAST:120,SBT:660,SCT:240,SGT:480,SLST:330,SRET:660,SRT:-180,SST:480,SYOT:180,TAHT:-600,THA:420,TFT:300,TJT:300,TKT:780,TLT:540,TMT:300,TOT:780,TVT:720,UCT:0,ULAT:480,USZ1:120,UTC:0,UYST:-120,UYT:-180,UZT:300,VET:-240,VLAT:600,VOLT:240,VOST:360,VUT:660,WAKT:720,WAST:120,WAT:60,WEDT:60,WEST:60,WET:0,WIT:420,WST:480,YAKT:540,YEKT:300},lh={zone:lp,year:ls,meridiem:{am:0,pm:12,"a.m.":0,"p.m.":12},month:{january:1,jan:1,february:2,feb:2,march:3,mar:3,april:4,apr:4,may:5,june:6,jun:6,july:7,jul:7,august:8,aug:8,september:9,sep:9,october:10,oct:10,november:11,nov:11,december:12,dec:12},dayname:{sunday:0,sun:0,monday:1,mon:1,tuesday:2,tue:2,wednesday:3,wed:3,thursday:4,thu:4,friday:5,fri:5,saturday:6,sat:6},digit:{}},lm={MONTHNAME:"january|february|march|april|may|june|july|august|september|october|november|december|jan\\.?|feb\\.?|mar\\.?|apr\\.?|may\\.?|jun\\.?|jul\\.?|aug\\.?|sep\\.?|oct\\.?|nov\\.?|dec\\.?",DAYNAME:"sunday|monday|tuesday|wednesday|thursday|friday|saturday|sun\\.?|mon\\.?|tue\\.?|wed\\.?|thu\\.?|fri\\.?|sat\\.?",ZONE:"\\(?(?:"+Object.keys(lp).join("|")+")\\)?",MERIDIEM:"am|pm|a.m.|p.m.",ORDINAL:"st|nd|rd|th|\\.",YEAR:"\\d{4}|\\d{2}",YEAR2:"\\d{2}",YEAR4:"\\d{4}",YEAR6:"-\\d{6}|\\+?\\d{5,6}",MONTH:"1[0-2]|0?[1-9]",MONTH2:"1[0-2]|0[1-9]",DAY:"3[01]|[12]\\d|0?[1-9]",DAY2:"3[01]|[12]\\d|0[1-9]",OFFSET:"(?:GMT)?[\xb1−+-](?:[01]\\d[0-5]\\d|[01]\\d:[0-5]\\d|[01]?\\d)",H24:"[01]\\d|2[0-3]",H12:"0?[1-9]|1[012]",MIN:"[0-5]\\d",SEC:"[0-5]\\d|60",MS:"\\d{9}|\\d{6}|\\d{1,3}",GAP:"[\\s/.,-]{1,}"},ly={...lm,YEAR:"*{4}|*{2}",YEAR4:"*{4}",YEAR6:"-*{6}|\\+?*{5,6}",MONTH:"*{1,2}",MONTH2:"*{2}",DAY:"*{1,2}",DAY2:"*{2}",OFFSET:"(?:GMT)?[\xb1−+-](?:*{4}|*{2}:*{2}|*{1,2})",H24:"*{2}",H12:"*{1,2}",MIN:"*{2}",SEC:"*{2}",MS:"*{9}|*{6}|*{3}"},lb={},lv=class e{locale;lookups;vars;numberingSystem;baseName;dateOptions;static factory(t=la){return lb[t.toLowerCase()]||(lb[t.toLowerCase()]=new e(t)),lb[t.toLowerCase()]}constructor(e=la){this.locale=e,this.lookups={...lh},this.vars={...lm};const t=new Intl.NumberFormat(this.locale);this.numberingSystem=t.resolvedOptions().numberingSystem,this.dateOptions=new Intl.DateTimeFormat(this.locale).resolvedOptions(),this.baseName=new Intl.Locale(this.locale).baseName,this.build()}toInt(e){if("number"==typeof e)return e;if("string"!=typeof e)return;if("latn"===this.numberingSystem&&!this.baseName.startsWith("zh")){let t=parseInt(e,10);if(!isNaN(t))return t}let t="";for(let r=0;r<e.length;r++)t+=String(this.lookups.digit[e[r]]);return parseInt(t,10)}millisecondToInt(e){if("number"==typeof e)return e;if("string"!=typeof e)return;let t=e.slice(0,3);return 1===t.length?100*this.toInt(t):2===t.length?10*this.toInt(t):this.toInt(t)}monthNameToInt(e){if("string"!=typeof e)return;let t=e.toLocaleLowerCase(this.locale).replace(/\.$/,"");return this.lookups.month[t]||12}h12ToInt(e,t){if("string"!=typeof e)return;let r=this.lookups.meridiem[t?.toLowerCase()]||0,n=this.toInt(e);return n<12&&12===r&&(n+=12),12===n&&0===r&&(n=0),n}zoneToOffset(e){if("string"==typeof e)return e=e.replace(/[^a-z\s]/gi,""),this.lookups.zone[e]}offsetToMinutes(e){if("string"!=typeof e)return;let t=e.match(/^(?:GMT)?([±−+-])(..?):?(..)?$/);if(t){let[,e,r,n]=t;return("-"===e||"−"===e?-1:1)*(60*this.toInt(r)+this.toInt(n||0))}return 0}build(){"latn"===this.dateOptions.numberingSystem?this.lookups.digit=ld:this.buildNumbers(),!/^en/i.test(this.locale)&&(this.buildMonthNames(),this.buildDaynames(),/zh/i.test(this.locale)||this.buildMeridiems())}buildNumbers(){let{group:e,lookup:t}=function(e){if(lf[e])return lf[e];if("fullwide"===e||"hanidec"===e)return{group:lc,lookup:{...ld}};let t=ll[e];if(!t)return{group:"\\d",lookup:{...ld}};let r=String.fromCharCode(t),n=String.fromCharCode(t+9),o={};for(let e=0;e<10;e++)o[String.fromCharCode(t+e)]=e;return lf[e]={group:`[${r}-${n}]`,lookup:o},lf[e]}(this.numberingSystem);for(let r in this.lookups.digit=t,ly)ly.hasOwnProperty(r)&&(this.vars[r]=ly[r].replace(/\*/g,e))}buildMonthNames(){let e={},t={};if(/^fi/i.test(this.locale))"tammi|helmi|maalis|huhti|touko|kes\xe4|hein\xe4|elo|syys|loka|marras|joulu".split("|").forEach((r,n)=>{["","k","kuu","kuuta"].forEach((o,i)=>{e[r+o+(i<2?"\\.?":"")]=!0,t[r+o]=n+1})});else{let r=[],n=e=>"month"===e.type;for(let e=0;e<12;e++)r.push(new Date(2017,e,1));for(let o of["full","long","medium"]){let i=Intl.DateTimeFormat(this.locale,{dateStyle:o});for(let a=0;a<12;a++){let u=i.formatToParts(r[a]).find(n).value.toLocaleLowerCase(this.locale);/^\d+$/.test(u)||(/^ko/i.test(this.locale)&&(u+="월"),"medium"===o?(u=u.replace(/\.$/,""),e[`${u}\\.?`]=!0):e[u]=!0,t[u]=a+1)}}let o=Intl.DateTimeFormat(this.locale,{month:"short"});for(let i=0;i<12;i++){let a=o.formatToParts(r[i]).find(n).value.toLocaleLowerCase(this.locale);a=a.replace(/\.$/,""),e[`${a}\\.?`]=!0,t[a]=i+1}}this.vars.MONTHNAME=Object.keys(e).join("|"),this.lookups.month=t}buildDaynames(){let e=[],t=e=>"weekday"===e.type;for(let t=0;t<7;t++)e.push(new Date(2017,0,t+1));let r=[],n={};for(let o of["long","short"]){let i=Intl.DateTimeFormat(this.locale,{weekday:o});for(let a=0;a<7;a++){let u=i.formatToParts(e[a]).find(t).value.toLocaleLowerCase(this.locale);"short"===o?(u=u.replace(/\.$/,""),r.push(`${u}\\.?`)):r.push(u),n[u]=a}}this.vars.DAYNAME=r.join("|"),this.lookups.dayname=n}buildMeridiems(){let e=[new Date(2017,0,1),new Date(2017,0,1,23,0,0)],t=e=>"dayPeriod"===e.type,r=[],n={},o=Intl.DateTimeFormat(this.locale,{timeStyle:"long"});for(let i=0;i<2;i++){let a=o.formatToParts(e[i]).find(t);if(!a)return;let u=a.value.toLocaleLowerCase(this.locale);r.push(u),n[u]=12*i}this.vars.MERIDIEM=r.join("|"),this.lookups.meridiem=n}compile(e){return RegExp(e.replace(/_([A-Z0-9]+)_/g,(e,t)=>{if(!this.vars[t])throw Error(`Template string contains invalid variable _${t}_`);return this.vars[t]}),"i")}},lg=["ee-TG","en-AS","en-CA","en-FM","en-GH","en-GU","en-KE","en-KY","en-MH","en-MP","en-US","en-VI","en-WS","jp-JP","sm-AS","sm-SM"],lw={y:"year",M:"month",d:"day",w:"week",h:"hour",m:"minute",s:"second",ms:"millisecond"},lE=()=>new Date;function lS(e){return function(t){let r={};for(let n=0,o=e.length;n<o;n++){let o=e[n];o&&(r[o]=t[n])}return r}}var lO=class{doneChecker;fallback;patterns;formatter;constructor({doneChecker:e,fallback:t,patterns:r,formatter:n}){this.doneChecker=e,this.fallback=t,this.patterns=r,this.formatter=n}attempt(e){if("string"!=typeof e)return this.fallback(e);let t=e.trim(),r={},n=!1;for(let e of this.patterns){let o=t.match(e.regex);if(!o)continue;n=!0;let i=e.handler(o);if(i){for(let[e,t]of Object.entries(i))e in r||void 0===t||(r[e]=t);if(t=(t=t.slice(0,o.index)+t.slice(o.index+o[0].length+1)).trim(),this.doneChecker(r,t))break}}return n?this.formatter(r):this.fallback(e)}},lA=["year","month","day","hour","minute","second","millisecond","offset"],lx={};function lD(e,t){return""===t||/^\s+$/.test(t)||"year"in e&&("month"in e||"monthname"in e)&&"day"in e&&"hour"in e&&"minute"in e&&"second"in e&&"millisecond"in e&&("zone"in e||"offset"in e)}var l_=[[/([^\d.]+)(\d{1,2})\.(\d{2})\.(\d{2})(\D|$)/,"$1$2:$3:$4$5"],[/([^\d.]+)(\d{1,2})\.(\d{2})(\D|$)/,"$1$2:$3$4"]],lj={ar:[[/ /g," "]],bn:[[/,/g,""]],zh:[[/早上\s*([\d:]+)/,"$1am"],[/凌晨\s*([\d:]+)/,"$1am"],[/上午\s*([\d:]+)/,"$1am"],[/下午\s*([\d:]+)/,"$1pm"],[/晚上\s*([\d:]+)/,"$1pm"]],he:[[/ב/gi,""]],de:[[/ um /g," "]],pt:[[/\sde /gi," "]],es:[[/\sde /gi," "]],da:[[/\sden /gi," "],...l_],ru:[[/ г\./g,""]],th:[[/\s*นาฬิกา\s*/i,":"],[/\s*นาที\s*/i,":"],[/\s*วินาที\s*/i," "]],ko:[[/\s*시\s*/,":"],[/\s*분\s*/,":"],[/\s*초\s*/,""],[/(오전|오후)\s*([\d:]+)/,"$2$1"],[/(\d{4})\. (\d{1,2})\. (\d{1,2})\./,"$1-$2-$3"]],fi:l_,id:l_,fr:[[/(\d{2}) h /,"$1:"],[/(\d{2}) min /,"$1:"],[/(\d{2}) s /,"$1"]]};function lC(e,t=la){let r=function(e){if(!lx[e]){var t,r;let n,o,i=lv.factory(e);lx[e]=new lO({doneChecker:lD,fallback:(t=e,function(e){let r=String(e).slice(0,50);return""===r&&(r="(empty string)"),{invalid:`Unable to parse "${r}" with locale "${t}"`}}),patterns:(n=[{name:"timestampWithOffset",regex:i.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? ?(_OFFSET_|Z)?$"),handler:lS(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"timestampWithZone",regex:i.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))?\\s*(_ZONE_)$"),handler:lS(["","year","month","day","hour","minute","second","millisecond","zone"])},{name:"timestampWithOffsetAndZone",regex:i.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? (_OFFSET_|Z)\\s*(_ZONE_)$"),handler:lS(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"chinese",regex:i.compile(`^(${lc}{2,4})\\s*\u5E74\\s*(${lc}{1,2})\\s*\u6708\\s*(${lc}{1,2})\\s*\u65E5$`),handler:lS(["","year","month","day"])},{name:"korean",regex:i.compile("^(_YEAR_)년\\s*(_MONTH_)월\\s*(_DAY_)일$"),handler:lS(["","year","month","day"])},{name:"twitter",regex:/^(?:sun|mon|tue|wed|thu|fri|sat) (jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec) (\d{2}) (\d{2}):(\d{2}):(\d{2}) ([+-]\d{4}) (\d{4})$/i,handler:lS(["","monthname","day","hour","minute","second","offset","year"])},{name:"today",regex:/^(now|today|tomorrow|yesterday)$/i,handler:function(e){let t=lE(),r=e[0].toLowerCase(),n={now:0,today:0,tomorrow:864e5,yesterday:-864e5}[r];0!==n&&t.setTime(t.getTime()+n);let o={year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()};return"now"===r?{...o,hour:t.getHours(),minute:t.getMinutes(),second:t.getSeconds(),millisecond:t.getMilliseconds()}:o}},{name:"ago",regex:/^(\+|-|in|) ?([\d.]+) ?(years?|months?|weeks?|days?|hours?|minutes?|seconds?|milliseconds?|ms|s|m|h|w|d|M|y)( ago)?$/i,handler:function([,e,t,r,n]){t=parseFloat(t),"week"===(r=r.length<=2?lw[r]:(r=r.replace(/s$/,"")).toLowerCase())&&(r="day",t*=7),("-"===e||n)&&(t*=-1);let o=lE();return"millisecond"===r?o.setUTCMilliseconds(o.getUTCMilliseconds()+t):"second"===r?o.setUTCSeconds(o.getUTCSeconds()+t):"minute"===r?o.setUTCMinutes(o.getUTCMinutes()+t):"hour"===r?o.setUTCHours(o.getUTCHours()+t):"day"===r?o.setUTCDate(o.getUTCDate()+t):"month"===r?o.setUTCMonth(o.getUTCMonth()+t):"year"===r&&o.setUTCFullYear(o.getUTCFullYear()+t),{year:o.getUTCFullYear(),month:o.getUTCMonth()+1,day:o.getUTCDate(),hour:o.getUTCHours(),minute:o.getUTCMinutes(),second:o.getUTCSeconds(),millisecond:o.getUTCMilliseconds()}}},{name:"atSeconds",regex:/^@(\d+)$/,handler:function(e){let t=new Date(1e3*parseInt(e[1],10));return{year:t.getUTCFullYear(),month:t.getUTCMonth()+1,day:t.getUTCDate(),hour:t.getUTCHours(),minute:t.getUTCMinutes(),second:t.getUTCSeconds()}}},{name:"microsoftJson",regex:/^\/Date\((\d+)([+-]\d{4})?\)\/$/,handler:function(e){let t=new Date(parseInt(e[1],10));return{year:t.getUTCFullYear(),month:t.getUTCMonth()+1,day:t.getUTCDate(),hour:t.getUTCHours(),minute:t.getUTCMinutes(),second:t.getUTCSeconds(),millisecond:t.getUTCMilliseconds(),offset:e[2]}}},{name:"full24",regex:i.compile("(?:^|[\\sT])(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?(Z)?$"),handler:lS(["","hour","minute","second","millisecond","zone"])},{name:"zone24",regex:i.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?[\\s\\[(]*(_ZONE_)?[\\s\\])]*$"),handler:lS(["","hour","minute","second","millisecond","zone"])},{name:"hms12WithOffset",regex:i.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)\\s*(_OFFSET_)"),handler:lS(["","hour","minute","second","meridiem","offset"])},{name:"hms12",regex:i.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)"),handler:lS(["","hour","minute","second","meridiem"])},{name:"hms24",regex:i.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?"),handler:lS(["","hour","minute","second","millisecond"])},{name:"hm12",regex:i.compile("(_H12_):(_MIN_)\\s*(_MERIDIEM_)"),handler:lS(["","hour","minute","meridiem"])},{name:"hm24",regex:i.compile("(_H24_):(_MIN_)"),handler:lS(["","hour","minute"])},{name:"h12",regex:i.compile("(_H12_)\\s*(_MERIDIEM_)"),handler:lS(["","hour","meridiem"])},{name:"8digit",regex:/^((?:19|20)\d{2})(\d{2})(\d{2})$/,handler:lS(["","year","month","day"])},{name:"yearMonthnameDay",regex:i.compile("(_YEAR4_)[\\s.-]+(_MONTHNAME_)[\\s,.-]+(_DAY_)(_ORDINAL_)?"),handler:lS(["","year","monthname","day"])},{name:"dayMonthnameYear",regex:i.compile("(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)[\\s,.-]+(_YEAR_)"),handler:lS(["","day","","monthname","year"])},{name:"monthnameDayYear",regex:i.compile("(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?[\\s,.-]+(_YEAR_)"),handler:lS(["","monthname","day","","year"])},{name:"dayMonthname",regex:i.compile("\\b(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)\\b"),handler:lS(["","day","","monthname"])},{name:"monthnameDay",regex:i.compile("\\b(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?\\b"),handler:lS(["","monthname","day"])},{name:"hmsNoMeridiem",regex:i.compile("\\b(_H12_|_H24_):(_MIN_):(_SEC_)\\b"),handler:lS(["","hour","minute","second"])},{name:"hmNoMeridiem",regex:i.compile("\\b(_H12_|_H24_):(_MIN_)\\b"),handler:lS(["","hour","minute"])},{name:"ymd",regex:i.compile("(_YEAR4_)([./-])(_MONTH_)\\2+(_DAY_)"),handler:lS(["","year","","month","day"])},{name:"mdy",regex:i.compile("(_MONTH_)([/-])(_DAY_)\\2(_YEAR_)"),handler:lS(["","month","","day","year"])},{name:"dmy",regex:i.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)[./\\s-]+(_YEAR_)"),handler:lS(["","day","month","year"])},{name:"yearLoose",regex:i.compile("_YEAR4_"),handler:lS(["year"])},{name:"dayMonthnameLoose",regex:i.compile("(_DAY_)[\\s.]*(_MONTHNAME_)"),handler:lS(["","day","monthname"])},{name:"monthnameDayLoose",regex:i.compile("(_MONTHNAME_)[\\s.]*(_DAY_)"),handler:lS(["","monthname","day"])},{name:"monthname",regex:i.compile("_MONTHNAME_"),handler:lS(["monthname"])},{name:"year4",regex:i.compile("_YEAR4_"),handler:lS(["year"])},{name:"md",regex:i.compile("(_MONTH_)[/-](_DAY_)"),handler:lS(["","month","day"])},{name:"dm",regex:i.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)"),handler:lS(["","day","month"])},{name:"day",regex:i.compile("_DAY_"),handler:lS(["day"])},{name:"year2",regex:i.compile("_YEAR2_"),handler:lS(["year"])},{name:"onlyZone",regex:i.compile("_ZONE_"),handler:lS(["zone"])},{name:"onlyOffset",regex:i.compile("_OFFSET_"),handler:lS(["offset"])}],o=i.baseName.slice(0,5),lg.includes(o)?n:n.filter(e=>!["mdy","md"].includes(e.name))),formatter:(r=i,function(e){let t={};for(let[n,o]of Object.entries(e))if("monthname"===n){if(o){let e=r.monthNameToInt(o);void 0!==e&&(t.month=e)}}else if("hour"===n&&e.meridiem){let n=r.h12ToInt(o,e.meridiem);void 0!==n&&(t.hour=n)}else if("zone"===n){if(o){let e=r.zoneToOffset(o);void 0!==e&&(t.offset=e)}}else if("offset"===n){let e=r.offsetToMinutes(o);void 0!==e&&(t.offset=e)}else if("millisecond"===n){let e=r.millisecondToInt(o);"number"==typeof e&&(t.millisecond=e)}else if(lA.includes(n)){let e=r.toInt(o);"number"==typeof e&&(t[n]=e)}return t.year<100&&(t.year=ls[e.year]),t.year&&"buddhist"===r.dateOptions.calendar&&(t.year-=543),t})})}return lx[e]}(t),n=function(e,t){let r=lj[t.slice(0,2).toLowerCase()];if(!r)return e;for(let[t,n]of r)e=e.replace(t,n);return e}(e,t);return r.attempt(n)}function lP(e){e.month&&e.day&&void 0===e.year&&(e.year=new Date().getFullYear()),60===e.second&&(e.second=59);let t=new lu(e.year,e.month-1,e.day,e.hour||0,e.minute||0,e.second||0,e.millisecond||0);return"number"==typeof e.offset?new lu(t.valueOf()-60*e.offset*1e3):t}function lk(e,t=la){let r=lC(e,t),n=r.invalid?new lu(NaN):lP(r);return n.isValid()||(n.invalid=`Unable to parse date "${e}"`),n}function lI(e,t=la){return e instanceof Date?new lu(e.valueOf()):"number"==typeof e?new lu(e):lk(e,t)}Date.fromString=lu.fromString=lk,Date.fromAny=lu.fromAny=lI,"u">typeof window&&(window.anyDateParser={fromString:lk,fromAny:lI,fromObject:lP,attempt:lC});var lT=r(648),lR=r(6871),lF=r(2147);let lN=function(e){return null==e};var lM=r(313);function lB(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function lL(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function lV(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){lL(e,t,r[t])})}return e}function lU(e,t){var r=function(e,t){if(!t.has(e))throw TypeError("attempted to get private field on non-instance");return t.get(e)}(e,t);return r.get?r.get.call(e):r.value}lt().extend(lT),lt().extend(lF),lt().extend(lR);var l$="YYYY-MM-DDTHH:mm:ss.SSSZZ";function lW(e){return null!=e&&28===e.trim().length&&"T"===(e=e.trim())[10]&&":"===e[13]&&":"===e[16]&&"."===e[19]&&("+"===e[23]||"-"===e[23])&&lt()(e,l$).isValid()}function lz(e){return lt()(e).isToday()}function lK(e){return lW(e)?lt()(e,l$).toDate():null}function lH(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=lt()(e);return t&&(r=r.utc()),r.format(l$)}function lG(e){return lt()(e).toDate()}var lq=new WeakMap,lZ=new(function(){var e;function t(){if(!(this instanceof t))throw TypeError("Cannot call a class as a function");var e=this,r=lq,n={writable:!0,value:new Map};if(r.has(e))throw TypeError("Cannot initialize the same private elements twice on an object");r.set(e,n)}return e=[{key:"register",value:function(e,t){lU(this,lq).set(e,t)}},{key:"getCalendar",value:function(e){if(e){if(e.calendar)return e.calendar;if(e.region){var t="".concat(e.language,"-").concat(e.region);if(lU(this,lq).has(t))return lU(this,lq).get(t)}if(e.language&&lU(this,lq).has(e.language))return lU(this,lq).get(e.language);var r=new Intl.DateTimeFormat(e.toString()).resolvedOptions().calendar;return lU(this,lq).set("".concat(e.language).concat(e.region?"-".concat(e.region):""),r),r}}}],function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,e),t}());function lY(e,t){lZ.register(e,t)}function lJ(e){var t,r=null!=e?e:li();return lZ.getCalendar((null!=(t=Intl.Locale)&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](r):r instanceof t)?r:new Intl.Locale(r))}var lX={mode:"standard",time:"for today",day:!0,month:!0,year:!0,noToday:!1};function lQ(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=lC(e,li());if(r.invalid)return console.warn("Could not parse invalid date '".concat(e,"'")),null;!lN(r.day)&&lN(r.month)&&(r=Object.assign({},(0,lM.A)(r,"day"),{month:r.day})),r.month&&(r.month-=1),r.day&&(r=Object.assign({},(0,lM.A)(r,"day"),{date:r.day}));var n=lt()().set(r).toDate();return lN(r.year)&&(t.year=!1),lN(r.month)&&(t.month=!1),lN(r.date)&&(t.day=!1),l0(n,t)}function l0(e,t){var r,n,o=null!=(r=null==t?void 0:t.locale)?r:li(),i=new Intl.Locale(o),a=lV({},lX,{noToday:"am"===i.language},t),u=a.calendar,s=a.mode,l=a.time,c=a.day,d=a.month,f=a.year,p=a.noToday,h=a.numberingSystem,m={calendar:null!=u?u:lJ(i),year:f?"numeric":void 0,month:d?"short":void 0,day:c?"2-digit":void 0,numberingSystem:h},y=lt()(e).isToday();if(y&&!p)n=(n=new Intl.RelativeTimeFormat(o,{numeric:"auto"}).format(0,"day"))[0].toLocaleUpperCase(o)+n.slice(1);else{"en"===i.language&&(o="en-GB");var b=new Intl.DateTimeFormat(o,m).formatToParts(e);("en"===i.language||"am"===i.language)&&"standard"==s&&f&&c&&(b=b.map(l1("-"))),"wide"==s&&(b=b.map(l1(" — "))),"ethiopic"===m.calendar&&(b=b.filter(function(e,t,r){return"era"!==e.type&&("literal"!==e.type||!(t<r.length-1)||"era"!==r[t+1].type)})),n=b.map(function(e){return e.value}).join("")}return(!0===l||y&&"for today"===l)&&(n+=", ".concat(l2(e))),n}var l1=function(e){return function(t,r,n){return"literal"!==t.type||" "!==t.value||r<n.length-1&&"era"===n[r+1].type?t:{type:"literal",value:e}}};function l2(e){return e.toLocaleTimeString(li(),{hour:"2-digit",minute:"2-digit"})}function l3(e,t){var r,n;return l0(e,(r=lV({},t),n=n={time:!0},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))}function l4(e,t){var r=lJ("string"==typeof t?new Intl.Locale(t):t);return r?ii(e,aB(r)):e}function l6(e,t){return new Intl.DurationFormat(li(),t).format(e)}function l5(e,t){if(null==e)return null;if("string"==typeof e){var r=lC(e,li());return r.invalid?(console.warn("Could not interpret '".concat(e,"' as a date")),null):(r.day&&!r.month&&(r=lV({},(0,lM.A)(r,"day"),{month:r.day})),r.month&&(r.month-=1),r.day&&(r=lV({},(0,lM.A)(r,"day"),{date:r.day})),lt()(t).set(r))}return lt()(e)}var l8=["years","months","days","hours","minutes","seconds"],l7={second:"seconds",minute:"minutes",hour:"hours",day:"days",month:"months",year:"years"};function l9(e){var t;return null!=(t=l7[e])?t:e}var ce={seconds:45,minutes:45,hours:22,days:26,months:11,years:1/0};function ct(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:lt()(),n=arguments.length>2?arguments[2]:void 0,o=lt()(r),i=l5(e,o);if(null==i)return null;if("string"==typeof n){var a=l9(n);return lL({},a,o.diff(i,a))}var u=null!=n?n:{},s=u.thresholds,l=u.largestUnit,c=u.smallestUnit;if(void 0!==l||void 0!==c){var d,f=c?l9(c):void 0;return d="auto"===l||void 0===l?function(e,t,r){for(var n=l8.indexOf(r),o=0;o<l8.length;o++){var i=l8[o];if(t.diff(e,i)>0)return o<=n?i:r}return r}(i,o,null!=f?f:"seconds"):l9(l),function(e,t,r,n){var o=l8.indexOf(r),i=l8.indexOf(n),a=l8.slice(o,i+1),u={},s=e,l=!0,c=!1,d=void 0;try{for(var f,p=a[Symbol.iterator]();!(l=(f=p.next()).done);l=!0){var h=f.value,m=t.diff(s,h);u[h]=m,s=s.add(m,h)}}catch(e){c=!0,d=e}finally{try{l||null==p.return||p.return()}finally{if(c)throw d}}return u}(i,o,d,null!=f?f:d)}var p=(t=function(e){var t=lV({},ce);if(e){var r=!0,n=!1,o=void 0;try{for(var i,a=Object.entries(e)[Symbol.iterator]();!(r=(i=a.next()).done);r=!0){var u,s=(u=i.value,function(e){if(Array.isArray(e))return e}(u)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(u)||function(e){if(e){if("string"==typeof e)return lB(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return lB(e,2)}}(u)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),l=s[0],c=s[1];void 0!==c&&(t[l9(l)]=c)}}catch(e){n=!0,o=e}finally{try{r||null==a.return||a.return()}finally{if(n)throw o}}}return t}(s),o.diff(i,"seconds")<t.seconds?"seconds":o.diff(i,"minutes")<t.minutes?"minutes":o.diff(i,"hours")<t.hours?"hours":o.diff(i,"days")<t.days?"days":o.diff(i,"months")<t.months?"months":"years");return lL({},p,o.diff(i,p))}var cr={style:"short",localeMatcher:"lookup"};function cn(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:lt()(),r=arguments.length>2?arguments[2]:void 0,n=ct(e,t,r);return null==n?null:l6(n,(void 0===r?"undefined":r&&"u">typeof Symbol&&r.constructor===Symbol?"symbol":typeof r)=="object"&&r.formatOptions?lV({},cr,r.formatOptions):cr)}function co(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function ci(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var ca=(0,em.createContext)(null);function cu(){var e=(0,L.UK)({externalModuleName:"@openmrs/esm-styleguide"}).preferredDateLocale,t=(0,em.useMemo)(function(){var t=li();return e[t]&&(t=e[t]),t},[window.i18next.language]),r=(0,em.useMemo)(function(){var e=lJ(t);return void 0!==e?aB(e):void 0},[t]),n=(0,em.useMemo)(function(){return new Intl.Locale(t,{calendar:null==r?void 0:r.identifier})},[t,r]),o=(0,em.useMemo)(function(){return r?ii(ih(iv()),r):ih(iv())},[r]);return{calendar:r,intlLocale:n,today_:o}}var cs=new oJ(1793,1,1),cl={};function cc(){return"u">typeof window&&window.InputEvent&&"function"==typeof InputEvent.prototype.getTargetRanges}cl={"ar-AE":{decrease:e=>`\u{62E}\u{641}\u{636} ${e.fieldLabel}`,increase:e=>`\u{632}\u{64A}\u{627}\u{62F}\u{629} ${e.fieldLabel}`,numberField:"حقل رقمي"},"bg-BG":{decrease:e=>`\u{41D}\u{430}\u{43C}\u{430}\u{43B}\u{44F}\u{432}\u{430}\u{43D}\u{435} ${e.fieldLabel}`,increase:e=>`\u{423}\u{441}\u{438}\u{43B}\u{432}\u{430}\u{43D}\u{435} ${e.fieldLabel}`,numberField:"Номер на полето"},"cs-CZ":{decrease:e=>`Sn\xed\u{17E}it ${e.fieldLabel}`,increase:e=>`Zv\xfd\u{161}it ${e.fieldLabel}`,numberField:"Č\xedseln\xe9 pole"},"da-DK":{decrease:e=>`Reducer ${e.fieldLabel}`,increase:e=>`\xd8g ${e.fieldLabel}`,numberField:"Talfelt"},"de-DE":{decrease:e=>`${e.fieldLabel} verringern`,increase:e=>`${e.fieldLabel} erh\xf6hen`,numberField:"Nummernfeld"},"el-GR":{decrease:e=>`\u{39C}\u{3B5}\u{3AF}\u{3C9}\u{3C3}\u{3B7} ${e.fieldLabel}`,increase:e=>`\u{391}\u{3CD}\u{3BE}\u{3B7}\u{3C3}\u{3B7} ${e.fieldLabel}`,numberField:"Πεδίο αριθμού"},"en-US":{decrease:e=>`Decrease ${e.fieldLabel}`,increase:e=>`Increase ${e.fieldLabel}`,numberField:"Number field"},"es-ES":{decrease:e=>`Reducir ${e.fieldLabel}`,increase:e=>`Aumentar ${e.fieldLabel}`,numberField:"Campo de n\xfamero"},"et-EE":{decrease:e=>`V\xe4henda ${e.fieldLabel}`,increase:e=>`Suurenda ${e.fieldLabel}`,numberField:"Numbri v\xe4li"},"fi-FI":{decrease:e=>`V\xe4henn\xe4 ${e.fieldLabel}`,increase:e=>`Lis\xe4\xe4 ${e.fieldLabel}`,numberField:"Numerokentt\xe4"},"fr-FR":{decrease:e=>`Diminuer ${e.fieldLabel}`,increase:e=>`Augmenter ${e.fieldLabel}`,numberField:"Champ de nombre"},"he-IL":{decrease:e=>`\u{5D4}\u{5E7}\u{5D8}\u{5DF} ${e.fieldLabel}`,increase:e=>`\u{5D4}\u{5D2}\u{5D3}\u{5DC} ${e.fieldLabel}`,numberField:"שדה מספר"},"hr-HR":{decrease:e=>`Smanji ${e.fieldLabel}`,increase:e=>`Pove\u{107}aj ${e.fieldLabel}`,numberField:"Polje broja"},"hu-HU":{decrease:e=>`${e.fieldLabel} cs\xf6kkent\xe9se`,increase:e=>`${e.fieldLabel} n\xf6vel\xe9se`,numberField:"Sz\xe1mmező"},"it-IT":{decrease:e=>`Riduci ${e.fieldLabel}`,increase:e=>`Aumenta ${e.fieldLabel}`,numberField:"Campo numero"},"ja-JP":{decrease:e=>`${e.fieldLabel}\u{3092}\u{7E2E}\u{5C0F}`,increase:e=>`${e.fieldLabel}\u{3092}\u{62E1}\u{5927}`,numberField:"数値フィールド"},"ko-KR":{decrease:e=>`${e.fieldLabel} \u{AC10}\u{C18C}`,increase:e=>`${e.fieldLabel} \u{C99D}\u{AC00}`,numberField:"번호 필드"},"lt-LT":{decrease:e=>`Suma\u{17E}inti ${e.fieldLabel}`,increase:e=>`Padidinti ${e.fieldLabel}`,numberField:"Numerio laukas"},"lv-LV":{decrease:e=>`Samazin\u{101}\u{161}ana ${e.fieldLabel}`,increase:e=>`Palielin\u{101}\u{161}ana ${e.fieldLabel}`,numberField:"Skaitļu lauks"},"nb-NO":{decrease:e=>`Reduser ${e.fieldLabel}`,increase:e=>`\xd8k ${e.fieldLabel}`,numberField:"Tallfelt"},"nl-NL":{decrease:e=>`${e.fieldLabel} verlagen`,increase:e=>`${e.fieldLabel} verhogen`,numberField:"Getalveld"},"pl-PL":{decrease:e=>`Zmniejsz ${e.fieldLabel}`,increase:e=>`Zwi\u{119}ksz ${e.fieldLabel}`,numberField:"Pole numeru"},"pt-BR":{decrease:e=>`Diminuir ${e.fieldLabel}`,increase:e=>`Aumentar ${e.fieldLabel}`,numberField:"Campo de n\xfamero"},"pt-PT":{decrease:e=>`Diminuir ${e.fieldLabel}`,increase:e=>`Aumentar ${e.fieldLabel}`,numberField:"Campo num\xe9rico"},"ro-RO":{decrease:e=>`Sc\u{103}dere ${e.fieldLabel}`,increase:e=>`Cre\u{219}tere ${e.fieldLabel}`,numberField:"C\xe2mp numeric"},"ru-RU":{decrease:e=>`\u{423}\u{43C}\u{435}\u{43D}\u{44C}\u{448}\u{435}\u{43D}\u{438}\u{435} ${e.fieldLabel}`,increase:e=>`\u{423}\u{432}\u{435}\u{43B}\u{438}\u{447}\u{435}\u{43D}\u{438}\u{435} ${e.fieldLabel}`,numberField:"Числовое поле"},"sk-SK":{decrease:e=>`Zn\xed\u{17E}i\u{165} ${e.fieldLabel}`,increase:e=>`Zv\xfd\u{161}i\u{165} ${e.fieldLabel}`,numberField:"Č\xedseln\xe9 pole"},"sl-SI":{decrease:e=>`Upadati ${e.fieldLabel}`,increase:e=>`Pove\u{10D}ajte ${e.fieldLabel}`,numberField:"Številčno polje"},"sr-SP":{decrease:e=>`Smanji ${e.fieldLabel}`,increase:e=>`Pove\u{107}aj ${e.fieldLabel}`,numberField:"Polje broja"},"sv-SE":{decrease:e=>`Minska ${e.fieldLabel}`,increase:e=>`\xd6ka ${e.fieldLabel}`,numberField:"Nummerf\xe4lt"},"tr-TR":{decrease:e=>`${e.fieldLabel} azalt`,increase:e=>`${e.fieldLabel} artt\u{131}r`,numberField:"Sayı alanı"},"uk-UA":{decrease:e=>`\u{417}\u{43C}\u{435}\u{43D}\u{448}\u{438}\u{442}\u{438} ${e.fieldLabel}`,increase:e=>`\u{417}\u{431}\u{456}\u{43B}\u{44C}\u{448}\u{438}\u{442}\u{438} ${e.fieldLabel}`,numberField:"Поле номера"},"zh-CN":{decrease:e=>`\u{964D}\u{4F4E} ${e.fieldLabel}`,increase:e=>`\u{63D0}\u{9AD8} ${e.fieldLabel}`,numberField:"数字字段"},"zh-TW":{decrease:e=>`\u{7E2E}\u{5C0F} ${e.fieldLabel}`,increase:e=>`\u{653E}\u{5927} ${e.fieldLabel}`,numberField:"數字欄位"}};var cd=r(7941);function cf(e={}){let{locale:t}=oE();return(0,em.useMemo)(()=>new(0,cd.K)(t,e),[t,e])}var cp={};function ch(e){var t;let r=(0,em.useRef)(void 0),{value:n,textValue:o,minValue:i,maxValue:a,isDisabled:u,isReadOnly:s,isRequired:l,onIncrement:c,onIncrementPage:d,onDecrement:f,onDecrementPage:p,onDecrementToMin:h,onIncrementToMax:m}=e,y=iT((t=cp)&&t.__esModule?t.default:t,"@react-aria/spinbutton");(0,em.useEffect)(()=>()=>clearTimeout(r.current),[]);let b=(0,em.useRef)(!1),v=()=>{b.current=!0},g=()=>{b.current=!1},w=""===o?y.format("Empty"):(o||`${n}`).replace("-","−");(0,em.useEffect)(()=>{b.current&&(rV&&rV.clear("assertive"),rU(w,"assertive"))},[w]);let E=ry(e=>{clearTimeout(r.current),null==c||c(),r.current=window.setTimeout(()=>{(void 0===a||isNaN(a)||void 0===n||isNaN(n)||n<a)&&E(60)},e)}),S=ry(e=>{clearTimeout(r.current),null==f||f(),r.current=window.setTimeout(()=>{(void 0===i||isNaN(i)||void 0===n||isNaN(n)||n>i)&&S(60)},e)}),O=e=>{e.preventDefault()},{addGlobalListener:A,removeAllGlobalListeners:x}=nE();return{spinButtonProps:{role:"spinbutton","aria-valuenow":void 0===n||isNaN(n)?void 0:n,"aria-valuetext":w,"aria-valuemin":i,"aria-valuemax":a,"aria-disabled":u||void 0,"aria-readonly":s||void 0,"aria-required":l||void 0,onKeyDown:e=>{if(!e.ctrlKey&&!e.metaKey&&!e.shiftKey&&!e.altKey&&!s)switch(e.key){case"PageUp":if(d){e.preventDefault(),null==d||d();break}case"ArrowUp":case"Up":c&&(e.preventDefault(),null==c||c());break;case"PageDown":if(p){e.preventDefault(),null==p||p();break}case"ArrowDown":case"Down":f&&(e.preventDefault(),null==f||f());break;case"Home":h&&(e.preventDefault(),null==h||h());break;case"End":m&&(e.preventDefault(),null==m||m())}},onFocus:v,onBlur:g},incrementButtonProps:{onPressStart:()=>{E(400),A(window,"contextmenu",O)},onPressEnd:()=>{clearTimeout(r.current),x()},onFocus:v,onBlur:g},decrementButtonProps:{onPressStart:()=>{S(400),A(window,"contextmenu",O)},onPressEnd:()=>{clearTimeout(r.current),x()},onFocus:v,onBlur:g}}}cp={"ar-AE":{Empty:"فارغ"},"bg-BG":{Empty:"Изпразни"},"cs-CZ":{Empty:"Pr\xe1zdn\xe9"},"da-DK":{Empty:"Tom"},"de-DE":{Empty:"Leer"},"el-GR":{Empty:"Άδειο"},"en-US":{Empty:"Empty"},"es-ES":{Empty:"Vac\xedo"},"et-EE":{Empty:"T\xfchjenda"},"fi-FI":{Empty:"Tyhj\xe4"},"fr-FR":{Empty:"Vide"},"he-IL":{Empty:"ריק"},"hr-HR":{Empty:"Prazno"},"hu-HU":{Empty:"\xdcres"},"it-IT":{Empty:"Vuoto"},"ja-JP":{Empty:"空"},"ko-KR":{Empty:"비어 있음"},"lt-LT":{Empty:"Tuščias"},"lv-LV":{Empty:"Tukšs"},"nb-NO":{Empty:"Tom"},"nl-NL":{Empty:"Leeg"},"pl-PL":{Empty:"Pusty"},"pt-BR":{Empty:"Vazio"},"pt-PT":{Empty:"Vazio"},"ro-RO":{Empty:"Gol"},"ru-RU":{Empty:"Не заполнено"},"sk-SK":{Empty:"Pr\xe1zdne"},"sl-SI":{Empty:"Prazen"},"sr-SP":{Empty:"Prazno"},"sv-SE":{Empty:"Tomt"},"tr-TR":{Empty:"Boş"},"uk-UA":{Empty:"Пусто"},"zh-CN":{Empty:"空"},"zh-TW":{Empty:"空白"}};var cm=r(5084);function cy(e,t,r){let n="+"===e?t+r:t-r;if(t%1!=0||r%1!=0){let o=t.toString().split("."),i=r.toString().split("."),a=Math.pow(10,Math.max(o[1]&&o[1].length||0,i[1]&&i[1].length||0));t=Math.round(t*a),r=Math.round(r*a),n=("+"===e?t+r:t-r)/a}return n}let cb=(0,em.createContext)(null),cv=(0,em.createContext)(null),cg=(0,em.forwardRef)(function(e,t){var r,n;[e,t]=rN(e,t,cb);let{validationBehavior:o}=rF(sp)||{},i=null!=(n=null!=(r=e.validationBehavior)?r:o)?n:"native",{locale:a}=oE(),u=function(e){let{minValue:t,maxValue:r,step:n,formatOptions:o,value:i,defaultValue:a=NaN,onChange:u,locale:s,isDisabled:l,isReadOnly:c}=e;null===i&&(i=NaN),void 0===i||isNaN(i)||(i=void 0===n||isNaN(n)?sg(i,t,r):sE(i,t,r,n)),isNaN(a)||(a=void 0===n||isNaN(n)?sg(a,t,r):sE(a,t,r,n));let[d,f]=aH(i,isNaN(a)?NaN:a,u),[p,h]=(0,em.useState)(()=>isNaN(d)?"":new(0,cd.K)(s,o).format(d)),m=(0,em.useMemo)(()=>new(0,cm.d)(s,o),[s,o]),y=(0,em.useMemo)(()=>m.getNumberingSystem(p),[m,p]),b=(0,em.useMemo)(()=>new(0,cd.K)(s,{...o,numberingSystem:y}),[s,o,y]),v=(0,em.useMemo)(()=>b.resolvedOptions(),[b]),g=(0,em.useCallback)(e=>isNaN(e)||null===e?"":b.format(e),[b]),w=uV({...e,value:d}),E=void 0===n||isNaN(n)?1:n;"percent"===v.style&&(void 0===n||isNaN(n))&&(E=.01);let[S,O]=(0,em.useState)(d),[A,x]=(0,em.useState)(s),[D,j]=(0,em.useState)(o);Object.is(d,S)&&s===A&&o===D||(h(g(d)),O(d),x(s),j(o));let C=(0,em.useMemo)(()=>m.parse(p),[m,p]),P=(e,n=0)=>{if(isNaN(C))return sE(isNaN(n)?0:n,t,r,E);{let n=sE(C,t,r,E);return"+"===e&&n>C||"-"===e&&n<C?n:sE(cy(e,C,E),t,r,E)}},k=(0,em.useMemo)(()=>!l&&!c&&(isNaN(C)||void 0===r||isNaN(r)||sE(C,t,r,E)>C||cy("+",C,E)<=r),[l,c,t,r,E,C]),I=(0,em.useMemo)(()=>!l&&!c&&(isNaN(C)||void 0===t||isNaN(t)||sE(C,t,r,E)<C||cy("-",C,E)>=t),[l,c,t,r,E,C]);return{...w,validate:e=>m.isValidPartialNumber(e,t,r),increment:()=>{let e=P("+",t);e===d&&h(g(e)),f(e),w.commitValidation()},incrementToMax:()=>{null!=r&&(f(sE(r,t,r,E)),w.commitValidation())},decrement:()=>{let e=P("-",r);e===d&&h(g(e)),f(e),w.commitValidation()},decrementToMin:()=>{null!=t&&(f(t),w.commitValidation())},canIncrement:k,canDecrement:I,minValue:t,maxValue:r,numberValue:C,setNumberValue:f,setInputValue:h,inputValue:p,commit:()=>{let e;if(!p.length){f(NaN),h(void 0===i?"":g(d));return}isNaN(C)?h(g(d)):(e=void 0===n||isNaN(n)?sg(C,t,r):sE(C,t,r,n),f(e=m.parse(g(e))),h(g(void 0===i?e:d)))}}}({...e,locale:a,validationBehavior:i}),s=(0,em.useRef)(null),[l,c]=rM(!e["aria-label"]&&!e["aria-labelledby"]),{labelProps:d,groupProps:f,inputProps:p,incrementButtonProps:h,decrementButtonProps:m,descriptionProps:y,errorMessageProps:b,...v}=function(e,t,r){var n,o;let i,{id:a,decrementAriaLabel:u,incrementAriaLabel:s,isDisabled:l,isReadOnly:c,isRequired:d,minValue:f,maxValue:p,autoFocus:h,label:m,formatOptions:y,onBlur:b=()=>{},onFocus:v,onFocusChange:g,onKeyDown:w,onKeyUp:E,description:S,errorMessage:O,isWheelDisabled:A,...x}=e,{increment:D,incrementToMax:j,decrement:C,decrementToMin:P,numberValue:k,inputValue:I,commit:T,commitValidation:R}=t,F=iT((o=cl)&&o.__esModule?o.default:o,"@react-aria/numberfield"),N=rj(a),{focusProps:M}=n1({onBlur(){T()}}),B=cf(y),L=(0,em.useMemo)(()=>B.resolvedOptions(),[B]),V=cf({...y,currencySign:void 0}),U=(0,em.useMemo)(()=>isNaN(k)?"":V.format(k),[V,k]),{spinButtonProps:$,incrementButtonProps:W,decrementButtonProps:z}=ch({isDisabled:l,isReadOnly:c,isRequired:d,maxValue:p,minValue:f,onIncrement:D,onIncrementToMax:j,onDecrement:C,onDecrementToMin:P,value:k,textValue:U}),[K,H]=(0,em.useState)(!1),{focusWithinProps:G}=n6({isDisabled:l,onFocusWithinChange:H});!function(e,t){let{onScroll:r,isDisabled:n}=e,o=(0,em.useCallback)(e=>{!e.ctrlKey&&(e.preventDefault(),e.stopPropagation(),r&&r({deltaX:e.deltaX,deltaY:e.deltaY}))},[r]);iQ(t,"wheel",n?void 0:o)}({onScroll:(0,em.useCallback)(e=>{!(Math.abs(e.deltaY)<=Math.abs(e.deltaX))&&(e.deltaY>0?D():e.deltaY<0&&C())},[C,D]),isDisabled:A||l||c||!K},r);let q=(null!=(n=L.maximumFractionDigits)?n:0)>0,Z=void 0===t.minValue||isNaN(t.minValue)||t.minValue<0,Y="numeric";nt()?Z?Y="text":q&&(Y="decimal"):na()&&(Z?Y="numeric":q&&(Y="decimal"));let J=rG(e),X=(0,em.useCallback)(e=>{"Enter"===e.key?(T(),R()):e.continuePropagation()},[T,R]),{isInvalid:Q,validationErrors:ee,validationDetails:et}=t.displayValidation,{labelProps:er,inputProps:en,descriptionProps:eo,errorMessageProps:ei}=function(e,t,r){let n=ry(e=>{let n=r.current;if(!n)return;let o=null;switch(e.inputType){case"historyUndo":case"historyRedo":case"insertLineBreak":return;case"deleteContent":case"deleteByCut":case"deleteByDrag":o=n.value.slice(0,n.selectionStart)+n.value.slice(n.selectionEnd);break;case"deleteContentForward":o=n.selectionEnd===n.selectionStart?n.value.slice(0,n.selectionStart)+n.value.slice(n.selectionEnd+1):n.value.slice(0,n.selectionStart)+n.value.slice(n.selectionEnd);break;case"deleteContentBackward":o=n.selectionEnd===n.selectionStart?n.value.slice(0,n.selectionStart-1)+n.value.slice(n.selectionStart):n.value.slice(0,n.selectionStart)+n.value.slice(n.selectionEnd);break;case"deleteSoftLineBackward":case"deleteHardLineBackward":o=n.value.slice(n.selectionStart);break;default:null!=e.data&&(o=n.value.slice(0,n.selectionStart)+e.data+n.value.slice(n.selectionEnd))}null!=o&&t.validate(o)||e.preventDefault()});(0,em.useEffect)(()=>{if(!cc()||!r.current)return;let e=r.current;return e.addEventListener("beforeinput",n,!1),()=>{e.removeEventListener("beforeinput",n,!1)}},[r,n]);let o=cc()?null:e=>{let r=e.target.value.slice(0,e.target.selectionStart)+e.data+e.target.value.slice(e.target.selectionEnd);t.validate(r)||e.preventDefault()},{labelProps:i,inputProps:a,descriptionProps:u,errorMessageProps:s,...l}=function(e,t){let{inputElementType:r="input",isDisabled:n=!1,isRequired:o=!1,isReadOnly:i=!1,type:a="text",validationBehavior:u="aria"}=e,[s,l]=aH(e.value,e.defaultValue||"",e.onChange),{focusableProps:c}=n4(e,t),d=uV({...e,value:s}),{isInvalid:f,validationErrors:p,validationDetails:h}=d.displayValidation,{labelProps:m,fieldProps:y,descriptionProps:b,errorMessageProps:v}=uj({...e,isInvalid:f,errorMessage:e.errorMessage||p}),g=rG(e,{labelable:!0}),w={type:a,pattern:e.pattern};return u_(t,s,l),uC(e,d,t),(0,em.useEffect)(()=>{if(t.current instanceof r0(t.current).HTMLTextAreaElement){let e=t.current;Object.defineProperty(e,"defaultValue",{get:()=>e.value,set:()=>{},configurable:!0})}},[t]),{labelProps:m,inputProps:rk(g,"input"===r?w:void 0,{disabled:n,readOnly:i,required:o&&"native"===u,"aria-required":o&&"aria"===u||void 0,"aria-invalid":f||void 0,"aria-errormessage":e["aria-errormessage"],"aria-activedescendant":e["aria-activedescendant"],"aria-autocomplete":e["aria-autocomplete"],"aria-haspopup":e["aria-haspopup"],"aria-controls":e["aria-controls"],value:s,onChange:e=>l(e.target.value),autoComplete:e.autoComplete,autoCapitalize:e.autoCapitalize,maxLength:e.maxLength,minLength:e.minLength,name:e.name,placeholder:e.placeholder,inputMode:e.inputMode,autoCorrect:e.autoCorrect,spellCheck:e.spellCheck,[parseInt(ey().version,10)>=17?"enterKeyHint":"enterkeyhint"]:e.enterKeyHint,onCopy:e.onCopy,onCut:e.onCut,onPaste:e.onPaste,onCompositionEnd:e.onCompositionEnd,onCompositionStart:e.onCompositionStart,onCompositionUpdate:e.onCompositionUpdate,onSelect:e.onSelect,onBeforeInput:e.onBeforeInput,onInput:e.onInput,...c,...y}),descriptionProps:b,errorMessageProps:v,isInvalid:f,validationErrors:p,validationDetails:h}}(e,r),c=(0,em.useRef)(null);return{inputProps:rk(a,{onBeforeInput:o,onCompositionStart(){let{value:e,selectionStart:t,selectionEnd:n}=r.current;c.current={value:e,selectionStart:t,selectionEnd:n}},onCompositionEnd(){if(r.current&&!t.validate(r.current.value)){let{value:e,selectionStart:n,selectionEnd:o}=c.current;r.current.value=e,r.current.setSelectionRange(n,o),t.setInputValue(e)}}}),labelProps:i,descriptionProps:u,errorMessageProps:s,...l}}({...x,...J,name:void 0,label:m,autoFocus:h,isDisabled:l,isReadOnly:c,isRequired:d,validate:void 0,[uL]:t,value:I,defaultValue:void 0,autoComplete:"off","aria-label":e["aria-label"]||void 0,"aria-labelledby":e["aria-labelledby"]||void 0,id:N,type:"text",inputMode:Y,onChange:e=>{t.validate(e)&&t.setInputValue(e)},onBlur:b,onFocus:v,onFocusChange:g,onKeyDown:(0,em.useMemo)(()=>rh(X,w),[X,w]),onKeyUp:E,description:S,errorMessage:O},t,r);u_(r,t.numberValue,t.setNumberValue);let ea=rk($,M,en,{role:null,"aria-roledescription":nn()?null:F.format("numberField"),"aria-valuemax":null,"aria-valuemin":null,"aria-valuenow":null,"aria-valuetext":null,autoCorrect:"off",spellCheck:"false"});"native"===e.validationBehavior&&(ea["aria-required"]=void 0);let eu=e=>{var t;document.activeElement!==r.current&&("mouse"===e.pointerType?null==(t=r.current)||t.focus():e.target.focus())},es=e["aria-label"]||("string"==typeof e.label?e.label:"");es||(i=null!=e.label?er.id:e["aria-labelledby"]);let el=rj(),ec=rj(),ed=rk(W,{"aria-label":s||F.format("increase",{fieldLabel:es}).trim(),id:i&&!s?el:null,"aria-labelledby":i&&!s?`${el} ${i}`:null,"aria-controls":N,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!t.canIncrement,onPressStart:eu}),ef=rk(z,{"aria-label":u||F.format("decrease",{fieldLabel:es}).trim(),id:i&&!u?ec:null,"aria-labelledby":i&&!u?`${ec} ${i}`:null,"aria-controls":N,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!t.canDecrement,onPressStart:eu});return{groupProps:{...G,role:"group","aria-disabled":l,"aria-invalid":Q?"true":void 0},labelProps:er,inputProps:ea,incrementButtonProps:ed,decrementButtonProps:ef,errorMessageProps:ei,descriptionProps:eo,isInvalid:Q,validationErrors:ee,validationDetails:et}}({...rB(e),label:c,validationBehavior:i},u,s),g=rR({...e,values:{state:u,isDisabled:e.isDisabled||!1,isInvalid:v.isInvalid||!1,isRequired:e.isRequired||!1},defaultClassName:"react-aria-NumberField"}),w=rG(e);return delete w.id,ey().createElement(rT,{values:[[cv,u],[ue,f],[ur,{...p,ref:s}],[sh,{...d,ref:l}],[oi,{slots:{increment:h,decrement:m}}],[os,{slots:{description:y,errorMessage:b}}],[sc,v]]},ey().createElement("div",{...w,...g,ref:t,slot:e.slot||void 0,"data-disabled":e.isDisabled||void 0,"data-required":e.isRequired||void 0,"data-invalid":v.isInvalid||void 0}),e.name&&ey().createElement("input",{type:"hidden",name:e.name,value:isNaN(u.numberValue)?"":u.numberValue}))});function cw(e,t){return Number.parseInt(l0(e,{calendar:t.calendar,locale:t.baseName,day:!1,month:!1,noToday:!0,numberingSystem:"latn"}))}var cE=(0,em.forwardRef)(function(e,t){var r=e.className,n=(0,em.useContext)(a0),o=(0,em.useContext)(a1),i=null!=n?n:o,a=(0,em.useContext)(ca),u=iv(),s=l0(i.visibleRange.start.toDate(u),{calendar:a.calendar,locale:a.baseName,day:!1,year:!1,noToday:!0}),l=cw(i.visibleRange.start.toDate(u),a),c=i.maxValue?cw(i.maxValue.toDate(u),a):void 0,d=i.minValue?cw(i.minValue.toDate(u),a):void 0,f=(0,em.useCallback)(function(e){i.setFocusedDate(i.focusedDate.cycle("year",e-i.focusedDate.year))},[]);return i&&(0,eh.jsxs)("span",{ref:t,className:r,children:[(0,eh.jsx)("span",{children:s}),(0,eh.jsxs)(cg,{formatOptions:{useGrouping:!1},maxValue:c,minValue:d,onChange:f,value:l,children:[(0,eh.jsx)(un,{}),(0,eh.jsxs)(ut,{children:[(0,eh.jsx)(oa,{slot:"increment",children:(0,eh.jsx)(e0,{size:8})}),(0,eh.jsx)(oa,{slot:"decrement",children:(0,eh.jsx)(eJ,{size:8})})]})]})]})});let cS="+4zksyca-I5VROi6oiQzJQ==",cO="wiExnFcGq1fPxn+K4eWeig==",cA="uiyACHcxSXjudv9HIlh57w==",cx="SxtTLfuOGW-Mst6POMWfQA==",cD="UU1QpNunTQCrdkAN2b2Ecg==",c_="fhR-1dd9yTq-5JUfl4REqA==";function cj(e){var t=e.children,r=(0,em.useContext)(s6),n=(0,em.useContext)(s5),o=null!=r?r:n,i=(0,L.Wr)(function(){return null==o?void 0:o.close()});return(0,eh.jsx)(sl,{className:"qllIfMFRvFHzGUeuOQ+PpA==",ref:i,children:t})}function cC(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var cP=(0,em.forwardRef)(function(e,t){var r,n,o=e.variant,i=e.today_,a=e.minDate,u=e.maxDate,s="range"===o;return(0,eh.jsx)(s0,{ref:t,className:"_16UMXpLD7yf8iGA5mGYNeA==",placement:"bottom start",offset:1,isNonModal:!0,children:(0,eh.jsx)(cj,{children:(0,eh.jsxs)(s?a3:a2,(r=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){cC(e,t,r[t])})}return e}({},s?{minValue:void 0===a?void 0:a,maxValue:void 0===u?void 0:u,className:"cds--date-picker__calendar"}:{}),n=n={children:[(0,eh.jsxs)("header",{className:"WAVlDbzjKhHAlu18b5VwWw==",children:[(0,eh.jsx)(oa,{className:ev()(cD,c_),slot:"previous",children:(0,eh.jsx)(e8,{size:16})}),(0,eh.jsx)(cE,{className:"A3aKFbSSeqZsllm0oKdxgg=="}),(0,eh.jsx)(oa,{className:ev()(cD,c_),slot:"next",children:(0,eh.jsx)(e7,{size:16})})]}),(0,eh.jsx)(a6,{className:"_6qRB2DssZC4NegdCeg1ktQ==",children:function(e){return(0,eh.jsx)(a9,{className:ev()("cds--date-picker__day",cC({},"TZl6MCGNAAF8bYh2zSUQ2w==",0===i.compare(e))),date:e},e.toString())}})]},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))})})});function ck(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function cI(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function cT(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var cR=(0,em.forwardRef)(function(e,t){var r,n=(0,em.useContext)(s6),o=function(e){if(Array.isArray(e))return e}(r=rN({slot:e.slot},t,u8))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(r)||function(e){if(e){if("string"==typeof e)return ck(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return ck(e,2)}}(r)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=o[0],a=o[1],u=oE().locale,s=u6(cT(cI({},i),{locale:u,createCalendar:aB})),l=(0,em.useRef)(null),c=uT(cT(cI({},i),{inputRef:l}),s,a),d=c.fieldProps,f=c.inputProps,p=(0,em.useCallback)(function(){s.isDisabled||n.toggle()},[]);return(0,eh.jsxs)(rT,{values:[[u7,s],[ur,cT(cI({},f),{ref:l})],[ue,cT(cI({},d),{ref:a,isInvalid:s.isInvalid})]],children:[(0,eh.jsx)(ut,cT(cI({},e),{id:e.id,ref:t,slot:e.slot||void 0,className:e.className,isDisabled:s.isDisabled,isInvalid:s.isInvalid,onClick:p,children:s.segments.map(function(t,r){return(0,em.cloneElement)(e.children(t),{key:r})})})),(0,eh.jsx)(un,{})]})});function cF(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}var cN=(0,em.forwardRef)(function(e,t){var r=(0,em.useContext)(s6),n=(0,em.useContext)(s5);return(null!=r?r:n).isInvalid?(0,eh.jsx)(rn,cF({ref:t,size:16},e)):(0,eh.jsx)(eY,cF({ref:t,size:16},e))});class cM{of(e){return this.dictionary.getStringForLocale(e,this.locale)}constructor(e,t){this.locale=e,this.dictionary=t}}let cB=new Map;function cL(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function cV(e){if(Array.isArray(e))return e}function cU(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function c$(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function cW(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function cz(e,t){if(e){if("string"==typeof e)return cL(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return cL(e,t)}}var cK=(0,em.forwardRef)(function(e,t){var r,n,o,i,a,u,s,l,c,d,f,p=cV(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||cz(r)||cU(),h=p[0],m=p.slice(1),y=h.segment,b=function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(h,["segment"]),v=(cV(m)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),1!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(m)||cz(m,1)||cU())[0],g=(0,em.useContext)(u7),w=rp(v),E=function(e,t,r){let n,o,i,a,u=(0,em.useRef)(""),{locale:s,direction:l}=oE(),c=function(){var e;let{locale:t}=oE(),r=iI((e=uo)&&e.__esModule?e.default:e,"@react-aria/datepicker");return(0,em.useMemo)(()=>{try{return new Intl.DisplayNames(t,{type:"dateTimeField"})}catch{return new cM(t,r)}},[t,r])}(),{ariaLabel:d,ariaLabelledBy:f,ariaDescribedBy:p,focusManager:h}=uP.get(t),m=e.isPlaceholder?"":e.text,y=(0,em.useMemo)(()=>t.dateFormatter.resolvedOptions(),[t.dateFormatter]),b=iU({month:"long",timeZone:y.timeZone}),v=iU({hour:"numeric",hour12:y.hour12,timeZone:y.timeZone});if("month"!==e.type||e.isPlaceholder)"hour"!==e.type||e.isPlaceholder||(m=v.format(t.dateValue));else{let e=b.format(t.dateValue);m=e!==m?`${m} \u{2013} ${e}`:e}let{spinButtonProps:g}=ch({value:e.value,textValue:m,minValue:e.minValue,maxValue:e.maxValue,isDisabled:t.isDisabled,isReadOnly:t.isReadOnly||!e.isEditable,isRequired:t.isRequired,onIncrement:()=>{u.current="",t.increment(e.type)},onDecrement:()=>{u.current="",t.decrement(e.type)},onIncrementPage:()=>{u.current="",t.incrementPage(e.type)},onDecrementPage:()=>{u.current="",t.decrementPage(e.type)},onIncrementToMax:()=>{u.current="",void 0!==e.maxValue&&t.setSegment(e.type,e.maxValue)},onDecrementToMin:()=>{u.current="",void 0!==e.minValue&&t.setSegment(e.type,e.minValue)}}),w=(0,em.useMemo)(()=>new(0,cm.d)(s,{maximumFractionDigits:0}),[s]),E=()=>{if(e.text===e.placeholder&&h.focusPrevious(),!w.isValidPartialNumber(e.text)||t.isReadOnly||e.isPlaceholder)"dayPeriod"===e.type&&t.clearSegment(e.type);else{let r=e.text.slice(0,-1),n=w.parse(r);0===(r=0===n?"":r).length||0===n?t.clearSegment(e.type):t.setSegment(e.type,n),u.current=r}},{startsWith:S}=(n=function(e){let{locale:t}=oE(),r=t+(e?Object.entries(e).sort((e,t)=>e[0]<t[0]?-1:1).join():"");if(cB.has(r))return cB.get(r);let n=new Intl.Collator(t,e);return cB.set(r,n),n}({usage:"search",sensitivity:"base"}),o=(0,em.useCallback)((e,t)=>0===t.length||(e=e.normalize("NFC"),t=t.normalize("NFC"),0===n.compare(e.slice(0,t.length),t)),[n]),i=(0,em.useCallback)((e,t)=>0===t.length||(e=e.normalize("NFC"),t=t.normalize("NFC"),0===n.compare(e.slice(-t.length),t)),[n]),a=(0,em.useCallback)((e,t)=>{if(0===t.length)return!0;e=e.normalize("NFC");let r=0,o=(t=t.normalize("NFC")).length;for(;r+o<=e.length;r++){let i=e.slice(r,r+o);if(0===n.compare(t,i))return!0}return!1},[n]),(0,em.useMemo)(()=>({startsWith:o,endsWith:i,contains:a}),[o,i,a])),O=iU({hour:"numeric",hour12:!0}),A=(0,em.useMemo)(()=>{let e=new Date;return e.setHours(0),O.formatToParts(e).find(e=>"dayPeriod"===e.type).value},[O]),x=(0,em.useMemo)(()=>{let e=new Date;return e.setHours(12),O.formatToParts(e).find(e=>"dayPeriod"===e.type).value},[O]),D=iU({year:"numeric",era:"narrow",timeZone:"UTC"}),j=(0,em.useMemo)(()=>{if("era"!==e.type)return[];let r=ii(new oJ(1,1,1),t.calendar),n=t.calendar.getEras().map(e=>{let t=r.set({year:1,month:1,day:1,era:e}).toDate("UTC");return{era:e,formatted:D.formatToParts(t).find(e=>"era"===e.type).value}}),o=function(e){e.sort();let t=e[0],r=e[e.length-1];for(let e=0;e<t.length;e++)if(t[e]!==r[e])return e;return 0}(n.map(e=>e.formatted));if(o)for(let e of n)e.formatted=e.formatted.slice(o);return n},[D,t.calendar,e.type]),C=r=>{if(t.isDisabled||t.isReadOnly)return;let n=u.current+r;switch(e.type){case"dayPeriod":if(S(A,r))t.setSegment("dayPeriod",0);else if(S(x,r))t.setSegment("dayPeriod",12);else break;h.focusNext();break;case"era":{let e=j.find(e=>S(e.formatted,r));e&&(t.setSegment("era",e.era),h.focusNext());break}case"day":case"hour":case"minute":case"second":case"month":case"year":{if(!w.isValidPartialNumber(n))return;let o=w.parse(n),i=o,a=0===e.minValue;if("hour"===e.type&&t.dateFormatter.resolvedOptions().hour12){switch(t.dateFormatter.resolvedOptions().hourCycle){case"h11":o>11&&(i=w.parse(r));break;case"h12":a=!1,o>12&&(i=w.parse(r))}void 0!==e.value&&e.value>=12&&o>1&&(o+=12)}else void 0!==e.maxValue&&o>e.maxValue&&(i=w.parse(r));if(isNaN(o))return;let s=0!==i||a;s&&t.setSegment(e.type,i),void 0!==e.maxValue&&(Number(o+"0")>e.maxValue||n.length>=String(e.maxValue).length)?(u.current="",s&&h.focusNext()):u.current=n}}};iQ((0,em.useRef)("u">typeof document?document:null),"selectionchange",()=>{var e;let t=window.getSelection();(null==t?void 0:t.anchorNode)&&(null==(e=r.current)?void 0:e.contains(null==t?void 0:t.anchorNode))&&t.collapse(r.current)});let P=(0,em.useRef)("");iQ(r,"beforeinput",n=>{if(r.current)switch(n.preventDefault(),n.inputType){case"deleteContentBackward":case"deleteContentForward":w.isValidPartialNumber(e.text)&&!t.isReadOnly&&E();break;case"insertCompositionText":P.current=r.current.textContent,r.current.textContent=r.current.textContent;break;default:null!=n.data&&C(n.data)}}),iQ(r,"input",e=>{let{inputType:t,data:n}=e;"insertCompositionText"===t&&(r.current&&(r.current.textContent=P.current),null!=n&&(S(A,n)||S(x,n))&&C(n))}),rm(()=>{let e=r.current;return()=>{document.activeElement===e&&(h.focusPrevious()||h.focusNext())}},[r,h]);let k=nn()||"timeZoneName"===e.type?{role:"textbox","aria-valuemax":null,"aria-valuemin":null,"aria-valuetext":null,"aria-valuenow":null}:{};e===(0,em.useMemo)(()=>t.segments.find(e=>e.isEditable),[t.segments])||t.isInvalid||(p=void 0);let I=rj(),T=!t.isDisabled&&!t.isReadOnly&&e.isEditable,R="literal"===e.type?"":c.of(e.type),F=iZ({"aria-label":`${R}${d?`, ${d}`:""}${f?", ":""}`,"aria-labelledby":f});if("literal"===e.type)return{segmentProps:{"aria-hidden":!0}};let N={caretColor:"transparent"};if("rtl"===l){N.unicodeBidi="embed";let t=y[e.type];("numeric"===t||"2-digit"===t)&&(N.direction="ltr")}return{segmentProps:rk(g,F,{id:I,...k,"aria-invalid":t.isInvalid?"true":void 0,"aria-describedby":p,"aria-readonly":t.isReadOnly||!e.isEditable?"true":void 0,"data-placeholder":e.isPlaceholder||void 0,contentEditable:T,suppressContentEditableWarning:T,spellCheck:T?"false":void 0,autoCorrect:T?"off":void 0,[parseInt(ey().version,10)>=17?"enterKeyHint":"enterkeyhint"]:T?"next":void 0,inputMode:t.isDisabled||"dayPeriod"===e.type||"era"===e.type||!T?void 0:"numeric",tabIndex:t.isDisabled?void 0:0,onKeyDown:e=>{if("a"===e.key&&(ne()?e.metaKey:e.ctrlKey)&&e.preventDefault(),!e.ctrlKey&&!e.metaKey&&!e.shiftKey&&!e.altKey)switch(e.key){case"Backspace":case"Delete":e.preventDefault(),e.stopPropagation(),E()}},onFocus:()=>{u.current="",r.current&&i6(r.current,{containingElement:i5(r.current)});let e=window.getSelection();null==e||e.collapse(r.current)},style:N,onPointerDown(e){e.stopPropagation()},onMouseDown(e){e.stopPropagation()}})}}(y,g,w).segmentProps,S=n5(),O=S.focusProps,A=S.isFocused,x=S.isFocusVisible,D=ot(cW(c$({},b),{isDisabled:g.isDisabled||"literal"===y.type})),j=D.hoverProps,C=D.isHovered,P=(o=(n=cW(c$({},b),{values:cW(c$({},y),{isReadOnly:!y.isEditable,isInvalid:g.isInvalid,isDisabled:g.isDisabled,isHovered:C,isFocused:A,isFocusVisible:x}),defaultChildren:y.text})).className,i=n.style,a=n.children,s=void 0===(u=n.defaultClassName)?void 0:u,c=void 0===(l=n.defaultChildren)?void 0:l,d=n.defaultStyle,f=n.values,(0,em.useMemo)(function(){var e,t,r;return e="function"==typeof o?o(ci(co({},f),{defaultClassName:s})):o,t="function"==typeof i?i(ci(co({},f),{defaultStyle:d||{}})):i,r="function"==typeof a?a(ci(co({},f),{defaultChildren:c})):null==a?c:a,{className:null!=e?e:s,style:t||d?co({},d,t):void 0,children:null!=r?r:c,"data-rac":""}},[o,i,a,s,c,d,f])),k=(0,em.useCallback)(function(e){e.stopPropagation()},[]);return(0,eh.jsx)("span",cW(c$({},rk(rG(b),E,O,j),P),{ref:w,style:E.style,"data-placeholder":y.isPlaceholder||void 0,"data-invalid":g.isInvalid||void 0,"data-readonly":!y.isEditable||void 0,"data-disabled":g.isDisabled||void 0,"data-type":y.type,"data-hovered":C||void 0,"data-focused":A||void 0,"data-focus-visible":x||void 0,onClick:k}))});function cH(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function cG(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){cH(e,t,r[t])})}return e}var cq={short:!1,size:"md"},cZ=(0,em.forwardRef)(function(e,t){var r,n,o,i=cG({},cq,e),a=i.className,u=i.defaultValue,s=i.isDisabled,l=i.invalid,c=i.invalidText,d=i.isInvalid,f=i.label,p=i.labelText,h=i.light,m=i.maxDate,y=i.minDate,b=i.onChange,v=i.onChangeRaw,g=i.short,w=i.size,E=i.value,S=function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(i,["className","defaultValue","isDisabled","invalid","invalidText","isInvalid","label","labelText","light","maxDate","minDate","onChange","onChangeRaw","short","size","value"]),O=cu(),A=O.calendar,x=O.intlLocale,D=O.today_,j=(0,em.useId)(),C=!!(null!=p?p:f),P=(0,em.useMemo)(function(){return ln(u,A)},[u,A]),k=(0,em.useMemo)(function(){return ln(E,A,!0)},[E,A]),I=(0,em.useMemo)(function(){return ln(m,A)},[m,A]),T=(0,em.useMemo)(function(){return ln(null!=y?y:cs,A)},[y,A]),R=(0,em.useMemo)(function(){return l||d},[l,d]),F=(0,em.useMemo)(function(){return v&&b&&console.error("An OpenmrsDatePicker component was created with both onChange and onChangeRaw handlers defined. Only onChangeRaw will be used."),null!=v?v:function(e){return null==b?void 0:b(lo(e))}},[v,b]);return(0,eh.jsx)(s9,{locale:x.toString(),children:(0,eh.jsx)("div",{className:ev()("cds--form-item",a),children:(0,eh.jsx)(rT,{values:[[ca,x]],children:(0,eh.jsxs)(s8,(r=cG({className:ev()("cds--date-picker","cds--date-picker--single",(cH(o={},"cds--date-picker--short",g),cH(o,"cds--date-picker--light",h),o)),defaultValue:P,isDisabled:s,isInvalid:R,maxValue:I,minValue:T,value:k,shouldForceLeadingZeros:"en"===x.language||void 0},S),n=n={onChange:F,children:[(0,eh.jsxs)("div",{className:"cds--date-picker-container",children:[C&&(0,eh.jsx)(sm,{className:ev()("cds--label",{"cds--label--disabled":s}),htmlFor:j,children:null!=p?p:f}),(0,eh.jsxs)(ut,{className:cS,children:[(0,eh.jsx)(cR,{id:C?j:void 0,ref:t,className:ev()("cds--date-picker-input__wrapper","kykar4EZi79xhpVitgu-vg==",cH({},"ablE9mmlFsZsPekwcW7jjQ==","md"===w||!w||0===w.length)),children:function(e){return"era"!==e.type?(0,eh.jsx)(cK,{className:cO,segment:e}):(0,eh.jsx)(ey().Fragment,{})}}),(0,eh.jsx)(oa,{className:ev()(cD,c_),children:(0,eh.jsx)(cN,{})})]}),(0,eh.jsx)(sd,{className:cx,children:c})]}),(0,eh.jsx)(cP,{variant:"single",today_:D})]},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))})})})});function cY(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function cJ(e){if(Array.isArray(e))return e}function cX(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function cQ(e,t){if(e){if("string"==typeof e)return cY(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return cY(e,t)}}var c0=(0,em.forwardRef)(function(e,t){var r,n,o,i=cJ(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||cQ(r)||cX(),a=i[0],u=i.slice(1),s=a.className,l=a.defaultValue,c=a.invalid,d=a.invalidText,f=a.isDisabled,p=a.isInvalid,h=a.label,m=a.labelText,y=a.light,b=a.maxDate,v=a.minDate,g=a.onChange,w=a.onChangeRaw,E=a.value,S=function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(a,["className","defaultValue","invalid","invalidText","isDisabled","isInvalid","label","labelText","light","maxDate","minDate","onChange","onChangeRaw","value"]),O=(cJ(u)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),1!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(u)||cQ(u,1)||cX())[0],A=cu(),x=A.calendar,D=A.intlLocale,j=A.today_,C=(0,em.useId)(),P=!!(null!=m?m:h),k=(0,em.useMemo)(function(){if(E)return{start:ln(E[0],x,!1),end:ln(E[1],x,!1)}},[E,x]),I=(0,em.useMemo)(function(){if(l)return{start:ln(l[0],x,!1),end:ln(l[1],x,!1)}},[l,x]),T=(0,em.useMemo)(function(){return ln(null!=v?v:cs,x,!0)},[v,x]),R=(0,em.useMemo)(function(){return ln(b,x,!0)},[b,x]),F=(0,em.useMemo)(function(){return c||p},[c,p]),N=(0,em.useMemo)(function(){return w&&g&&console.error("An OpenmrsDateRangePicker component was created with both onChange and onChangeRaw handlers defined. Only onChangeRaw will be used."),null!=w?w:function(e){return null==g?void 0:g([lo(e.start),lo(e.end)])}},[w,g]);return(0,eh.jsx)(s9,{locale:D.toString(),children:(0,eh.jsx)("div",{className:ev()("cds--form-item",s),children:(0,eh.jsx)(rT,{values:[[ca,D]],children:(0,eh.jsx)(s7,(n=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({id:P?C:void 0,className:ev()("cds--date-picker",{"cds--date-picker--light":y,"cds--date-picker--disabled":f}),isInvalid:F,shouldForceLeadingZeros:"en"===D.language||void 0,maxValue:R,minValue:T,value:k,defaultValue:I,ref:O,isDisabled:f},S),o=o={onChange:N,children:(0,eh.jsxs)("div",{className:"cds--date-picker-container",children:[P&&(0,eh.jsx)(sm,{className:ev()("cds--label",{"cds--label--disabled":f}),htmlFor:C,children:null!=m?m:h}),(0,eh.jsxs)(ut,{className:cS,children:[(0,eh.jsxs)("div",{className:"YlkGhdQcBgSDJNSlS1cQnw==",children:[(0,eh.jsx)(se,{className:ev()("cds--date-picker-input__wrapper","qgbQm03oBFnWnXNV1GFW6Q==",cA),slot:"start",children:function(e){return(0,eh.jsx)(cK,{className:cO,segment:e})}}),(0,eh.jsx)("div",{className:"_79vXZ2hgTRvmmxREZu5WGw==",children:(0,eh.jsx)("span",{"aria-hidden":"true","data-readonly":!0,children:"–"})}),(0,eh.jsx)(se,{className:ev()("cds--date-picker-input__wrapper","huv7xQjo+RZmT7LsDwVMdw==",cA),slot:"end",children:function(e){return(0,eh.jsx)(cK,{className:cO,segment:e})}})]}),(0,eh.jsx)(oa,{className:ev()(cD,c_),children:(0,eh.jsx)(cN,{})})]}),(0,eh.jsx)(sd,{className:cx,children:d}),(0,eh.jsx)(cP,{variant:"range",today_:j,minDate:T,maxDate:R})]})},Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(o)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(o)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(o,e))}),n))})})})}),c1=function(e){var t=e.diagnoses,r=(0,L.UK)({externalModuleName:"@openmrs/esm-styleguide"}).diagnosisTags;return(0,eh.jsx)("div",{className:"_8kut8cACHJrbzESyXn6V0A==",children:t.map(function(e){var t=e.rank,n=e.uuid,o=e.display,i=r[1===t?"primaryColor":"secondaryColor"];return(0,eh.jsx)(eS.Tag,{type:i,children:o},n)})})};let c2={action:"Y0dulYR6B5fprvtdpjGfEg==",content:"fo0nBB+424Kd5d6PQgXSNw==",heading:"sxyN788Qj+7TLTeyCjE6bw==",tile:"QB8Ldd7u7gkdqC6n-YSg0Q=="};var c3=function(e){var t=e.width,r=e.height;return(0,eh.jsx)("svg",{width:void 0===t?"64":t,height:void 0===r?"64":r,viewBox:"0 0 64 64",children:(0,eh.jsx)("use",{href:"#omrs-empty-data-illustration"})})},c4=function(e){var t="tablet"===(0,L.qv)(),r=e.launchForm;return(0,eh.jsx)(eS.Layer,{className:c2.layer,children:(0,eh.jsxs)(eS.Tile,{className:c2.tile,children:[(0,eh.jsx)(ew,{title:e.headerTitle}),(0,eh.jsx)(c3,{}),(0,eh.jsx)("p",{className:c2.content,children:(0,h.V)("emptyStateText","There are no {{displayText}} to display",{displayText:e.displayText})}),(0,eh.jsx)("p",{className:c2.action,children:r&&(0,eh.jsx)(eS.Button,{onClick:function(){return r()},kind:"ghost",size:t?"lg":"sm",children:(0,h.V)("recordNewEntry","Record {{ displayText }}",{displayText:e.displayText})})})]})})},c6=function(e){var t,r,n=e.error,o=e.headerTitle;return(0,eh.jsx)(eS.Layer,{children:(0,eh.jsxs)(eS.Tile,{className:"dd4186Mm5sjs8UUsDMSW1g==",children:[(0,eh.jsx)(ew,{title:o}),(0,eh.jsxs)("p",{className:"z2RiNHQhCUYOlXJFOX2flg==",children:[(0,h.V)("error","Error")," ","".concat(null==n||null==(t=n.response)?void 0:t.status,": "),null==n||null==(r=n.response)?void 0:r.statusText]}),(0,eh.jsx)("p",{className:"dq+e2AreXbyoxopCEZRwXA==",children:(0,h.V)("errorCopy")})]})})},c5=c6;function c8(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}var c7=ey().forwardRef(function(e,t){var r,n,o,i=(0,L.TA)(),a=i.slotName,u=i.basePath,s=i.componentContext,l=i.state,c=null!=(o=window.location)?o:{pathname:""},d=(0,L.CX)(null!=a?a:"");return e.isChildOfHeader&&a&&d.length>0?(0,eh.jsxs)(eS.SideNav,(r=c8({"aria-label":(0,h.V)("leftNavigation","Left navigation"),className:"jzTJKtCPCooU36+y+NwbPQ==",expanded:!0,isFixedNav:!0,ref:t},e),n=n={children:[(0,eh.jsx)(L.W3,{name:"global-nav-menu-slot"}),a?(0,eh.jsx)(L.fS,{value:s,fallback:(0,eh.jsx)(L.W3,{name:a,state:c8({basePath:u,currentPath:c},l)}),children:(0,eh.jsx)(L.zq.Provider,{value:s,children:(0,eh.jsx)(L.W3,{name:a,state:c8({basePath:u,currentPath:c},l)})})}):null]},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r)):null}),c9=r(6269),de=r(3709);function dt(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function dr(e,t){if(e){if("string"==typeof e)return dt(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return dt(e,t)}}var dn=function(e){var t,r,n,o,i,a,u=e.selectedLocationUuid,s=e.defaultLocationUuid,l=e.locationTag,c=e.locationsPerRequest,f=void 0===c?50:c,p=e.onChange,m=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)(""))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||dr(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),y=m[0],b=m[1],v=(0,em.useId)(),g=(r=s?"/ws/fhir2/R4/Location?_id=".concat(s):null,o=(n=(0,c9.A)(r,d.lo,{shouldRetryOnError:function(e){var t;return null!=e&&null!=(t=e.response)&&!!t.status&&e.response.status>=500}})).data,i=n.error,a=n.isLoading,(0,em.useMemo)(function(){var e;return{location:(null==o||null==(e=o.data)?void 0:e.entry)?o.data.entry[0]:null,error:r?i:null,isLoading:!!r&&a}},[o,a,i,r])).location,w=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=(0,L.d7)(r),o=(0,de.Ay)(function(r,o){if(o){var i,a,u=null==(a=o.data)||null==(i=a.link)?void 0:i.find(function(e){return"next"===e.relation});if(!u)return null;var s=new URL(u.url);return s.origin===window.location.origin?u.url:new URL("".concat(s.pathname).concat(s.search?"?".concat(s.search):""),window.location.origin).toString()}var l="".concat(d.IU,"/Location?"),c=new URLSearchParams;return c.append("_summary","data"),t&&c.append("_count",""+t),r&&c.append("_getpagesoffset",""+r*t),e&&c.append("_tag",e),"string"==typeof n&&""!==n&&c.append("name:contains",n),l+c.toString()},d.lo),i=o.data,a=o.isLoading,u=o.isValidating,s=o.setSize,l=o.error;return(0,em.useMemo)(function(){var e,t,r,n,o;return{locations:(null==i?void 0:i.length)?null==i?void 0:i.flatMap(function(e){var t,r;return null!=(t=null==e||null==(r=e.data)?void 0:r.entry)?t:[]}):[],isLoading:a,totalResults:null==i||null==(t=i[0])||null==(e=t.data)?void 0:e.total,hasMore:null!=i&&!!i.length&&(null==i||null==(o=i[i.length-1])||null==(n=o.data)||null==(r=n.link)?void 0:r.some(function(e){return"next"===e.relation})),loadingNewData:u,error:l||null,setPage:s}},[a,i,u,s,l])}(l,f,y),E=w.locations,S=w.isLoading,O=w.hasMore,A=w.loadingNewData,x=w.error,D=w.setPage,j=(0,em.useMemo)(function(){if(g&&!y&&s){var e;return[g].concat(function(e){if(Array.isArray(e))return dt(e)}(e=E.filter(function(e){return e.resource.id!==s}))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||dr(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())}return null!=E?E:[]},[g,E,s,y]),C=(0,em.useCallback)(function(e){p(),b(e.trim())},[p]),P=(0,em.useCallback)(function(){!A&&O&&D(function(e){return e+1})},[A,O,D]),k=(0,L.Jm)(P),I=O?Math.max(0,Math.floor(j.length-f/2)):-1;return(0,eh.jsxs)(eh.Fragment,{children:[(0,eh.jsx)(eS.Search,{"aria-describedby":x?"".concat(v,"-error"):void 0,labelText:(0,h.V)("searchForLocation"),id:v,placeholder:(0,h.V)("searchForLocation"),onChange:function(e){return C(e.target.value)},size:"lg"}),x&&(0,eh.jsx)("div",{className:"vWBFDqCDM8BcQhePvfa35g==",id:"".concat(v,"-error"),children:(0,eh.jsx)(eS.InlineNotification,{kind:"error",subtitle:(0,h.V)("errorLoadingLoginLocations","Unable to load login locations. Please try again or contact support if the problem persists."),title:(0,h.V)("error","Error")})}),(0,eh.jsx)("div",{className:"Gbet+W1fVEk45aZli6JbrA==",children:S?(0,eh.jsx)("div",{className:"QO-zjOxMSWAzXY-PMrSiwQ==",children:Array.from({length:5}).map(function(e,t){return(0,eh.jsx)(eS.RadioButtonSkeleton,{className:"otoCykP+JQHrsIsgKUOd7A==",role:"progressbar"},t)})}):(0,eh.jsxs)(eh.Fragment,{children:[(0,eh.jsx)("div",{className:"_6PasfpnQ738RjzgXBzAQpw==",children:j.length>0?(0,eh.jsx)(eS.RadioButtonGroup,{name:"loginLocations",onChange:function(e){p(null==e?void 0:e.toString())},orientation:"vertical",valueSelected:u,children:j.map(function(e,t){return(0,eh.jsx)(eS.RadioButton,{className:"rTDPjXuaGJbz9KhOf57M3g==",id:e.resource.id,labelText:(0,eh.jsx)("span",{ref:t===I?k:null,children:e.resource.name}),name:e.resource.name,value:e.resource.id},e.resource.id)})}):(0,eh.jsx)("div",{className:"w4-CatRLHH3loLqlunOalg==",children:(0,eh.jsx)("p",{className:"Of2MJqhAMKF7nrwI5bKckw==",children:(0,h.V)("noResultsToDisplay")})})}),A&&(0,eh.jsx)("div",{className:"NAwSBETYamP9uMuJE63U-w==",children:(0,eh.jsx)(eS.InlineLoading,{description:(0,h.V)("loading")})})]})})]})};function di(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function da(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function du(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function ds(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function dl(e,t){if(e){if("string"==typeof e)return di(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return di(e,t)}}var dc=(0,el.Zd)("modalState",{modalContainer:null,modalStack:[]}),dd=0,df=window.getComputedStyle(document.body).overflow;function dp(e){var t=e.modalStack,r=e.modalContainer;r&&(t.length?(r.style.visibility||(addEventListener("keydown",dm),document.body.style.overflow="hidden",r.style.visibility="unset"),t.forEach(function(e,n){switch(e.state){case"NEW":var o,i,a,u,s,l,c,d=(o=({size:null!=(l=null==(c=e.props)?void 0:c.size)?l:"md"}).size,(i=document.createElement("div")).className="cds--modal-container cds--modal-container--".concat(o),i.setAttribute("role","dialog"),i.setAttribute("tabindex","-1"),i.setAttribute("aria-modal","true"),i);e.container=d,(function(e,t){var r;return(r=function(e,t){var r,n,o,i,a,u=arguments;return function(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(s){switch(s.label){case 0:if(r=u.length>2&&void 0!==u[2]?u[2]:{},n=(0,F.Fg)(t),o=null,!e)return[3,2];if(!n)throw Error("No modal named '".concat(t,"' has been registered."));return[4,(0,n.load)()];case 1:return i=s.sent(),a=dd++,o=(0,U.mountRootParcel)(ds(du({},i),{name:"".concat(t,"-").concat(a)}),ds(du({},r),{domElement:e})),[3,3];case 2:(0,x.N)("Failed to launch modal. Please notify your administrator. Modal name: ".concat(t)),s.label=3;case 3:return[2,o]}})},function(){var e=this,t=arguments;return new Promise(function(n,o){var i=r.apply(e,t);function a(e){da(i,n,o,a,u,"next",e)}function u(e){da(i,n,o,a,u,"throw",e)}a(void 0)})}).apply(this,arguments)})(d,e.modalName,e.props).then(function(t){e.parcel=t,e.state="MOUNTED",r.prepend(d),d.style.visibility="unset"});break;case"MOUNTED":e.container&&(e.container.style.visibility=n?"hidden":"unset");break;case"TO_BE_DELETED":e.onClose(),null==(u=e.parcel)||null==(a=u.unmount)||a.call(u),null==(s=e.container)||s.remove(),setTimeout(function(){dc.setState({modalContainer:r,modalStack:t.filter(function(t){return t!==e})})},0)}})):(r.style.removeProperty("visibility"),document.body.style.overflow=df,removeEventListener("keydown",dm)))}function dh(e){var t=dc.getState(),r=t.modalStack.map(function(t){return t===e?ds(du({},t),{state:"TO_BE_DELETED"}):t});dc.setState(ds(du({},t),{modalStack:r}))}function dm(e){var t,r;"Escape"===e.key&&(r=(function(e){if(Array.isArray(e))return e}(t=dc.getState().modalStack)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),1!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||dl(t,1)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0])&&dh(r)}function dy(e){dc.subscribe(dp),dc.setState(ds(du({},dc.getState()),{modalContainer:e}))}function db(e){var t,r,n,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){},a=function(){var e=dc.getState().modalStack.find(function(e){return e.onClose===i});e&&dh(e)};return(0,F.Fg)(e)?(n=[{state:"NEW",onClose:i,modalName:e,props:du({close:a},o)}].concat(function(e){if(Array.isArray(e))return di(e)}(r=(t=dc.getState()).modalStack)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||dl(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),dc.setState(ds(du({},t),{modalStack:n}))):(0,x.N)('Failed to launch modal. Please notify your administrator. Modal name: "'.concat(e,'"')),a}var dv=r(7436),dg=function(e){var t=e.notification,r=t.description,n=t.action,o=t.kind,i=t.critical,a=t.title,u=t.onAction;return(0,eh.jsx)(eS.ActionableNotification,{actionButtonLabel:n,kind:o||"info",lowContrast:i,subtitle:r,title:a||"",inline:!0,onActionButtonClick:u})};function dw(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function dE(e,t){if(e){if("string"==typeof e)return dw(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return dw(e,t)}}let dS=function(e){var t,r=e.subject,n=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)([]))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||dE(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),o=n[0],i=n[1];return(0,em.useEffect)(function(){var e=r.subscribe(function(e){return i(function(t){var r;return((function(e){if(Array.isArray(e))return dw(e)})(r=t.filter(function(t){return t.description!==e.description||t.action!==e.action||t.kind!==e.kind||t.title!==e.title}))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||dE(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e])})});return function(){return e.unsubscribe()}},[r]),(0,eh.jsx)(eh.Fragment,{children:o.map(function(e){return(0,eh.jsx)(dg,{notification:e},e.id)})})};function dO(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var dA=function(e){var t,r=e.notification,n=r.actionButtonLabel,o=r.onActionButtonClick,i=void 0===o?function(){}:o,a=r.subtitle,u=r.kind,s=r.title,l=r.critical,c=r.progressActionLabel,d=(r.id,function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(r,["actionButtonLabel","onActionButtonClick","subtitle","kind","title","critical","progressActionLabel","id"])),f=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)(n))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return dO(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return dO(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),p=f[0],m=f[1];return(0,eh.jsx)(eS.ActionableNotification,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({kind:u||"info",actionButtonLabel:p,ariaLabel:(0,h.V)("closesActionableNotification","Closes actionable notification"),onActionButtonClick:function(){i(),c&&m(c)},statusIconDescription:(0,h.V)("actionableNotification","Actionable notification"),subtitle:a,title:s,lowContrast:l,inline:!0},d))};function dx(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function dD(e,t){if(e){if("string"==typeof e)return dx(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return dx(e,t)}}let d_=function(e){var t,r=e.subject,n=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)([]))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||dD(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),o=n[0],i=n[1];return(0,em.useEffect)(function(){var e=r.subscribe(function(e){return i(function(t){var r;return((function(e){if(Array.isArray(e))return dx(e)})(r=t.filter(function(t){return t.subtitle!==e.subtitle||t.actionButtonLabel!==e.actionButtonLabel||t.onActionButtonClick!==e.onActionButtonClick||t.kind!==e.kind||t.title!==e.title}))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||dD(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e])})});return function(){return e.unsubscribe()}},[r]),(0,eh.jsx)(eh.Fragment,{children:o.map(function(e){return(0,eh.jsx)(dA,{notification:e},e.id)})})};var dj=r(5217),dC=r(72),dP=r(2797),dk=r(8206),dI=r(3497),dT=r(8134),dR=r(4666),dF=r(7931),dN=Object.prototype.hasOwnProperty;let dM=function(e){if(null==e)return!0;if((0,dI.A)(e)&&((0,dk.A)(e)||"string"==typeof e||"function"==typeof e.splice||(0,dT.A)(e)||(0,dF.A)(e)||(0,dP.A)(e)))return!e.length;var t=(0,dC.A)(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if((0,dR.A)(e))return!(0,dj.A)(e).length;for(var r in e)if(dN.call(e,r))return!1;return!0};var dB=r(8279);function dL(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}function dV(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function dU(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function d$(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}var dW=new dv.Subject,dz=0,dK=new dv.Subject,dH=0;function dG(e){e&&(0,dB.createRoot)(e).render((0,eh.jsx)(dS,{subject:dW}))}function dq(e){var t;e&&("string"==typeof(t=e.description)?t.trim().length>0:(void 0===t?"undefined":d$(t))==="object"&&(dL(t,Error)||!dM(t)))?(dL(e.description,Error)&&(e.description=e.description.toLocaleString()),setTimeout(function(){dW.next(dU(dV({},e),{id:dz++}))},0)):console.error("showNotification must be called with an object having a 'description' property that is a non-empty string or object")}function dZ(e){e&&(0,dB.createRoot)(e).render((0,eh.jsx)(d_,{subject:dK}))}function dY(e){var t;e&&("string"==typeof(t=e.actionButtonLabel)?t.trim().length>0:(void 0===t?"undefined":d$(t))==="object"&&!dM(t))?setTimeout(function(){dK.next(dU(dV({},e),{id:dH++}))},0):console.error("showActionableNotification must be called with an actionButtonLabel that is a non-empty string")}var dJ=["NORMAL","HIGH","CRITICALLY_HIGH","OFF_SCALE_HIGH","LOW","CRITICALLY_LOW","OFF_SCALE_LOW"],dX=["critically_low","critically_high","high","low","normal","off_scale_low","off_scale_high"];let dQ={container:"NfxbHD-wnMrBzBk69SCjYQ==",card:"_9oQAhF55AGaJdV52G-wqjg==","abnormal-value":"drvEiwdbggDi0fbHudAK8A==","critical-value":"JAIHtThObGIUDziDrI7NEw==",cell:"lTunWbcsMBJlcgcQcM49VQ==","critically-high":"aDUjcSFuBLWzHLB6F2ZL0w==","critically-low":"_5srAKYBlbvz1g2GZM1ESig==",high:"_7KiyKNoFp9yrwGOfblyG2A==",low:"Zs2ctcOpDW7uCL3jkar-mA==","label-container":"lGnGHj+yIJy++XiPwZ7Nzw==","value-container":"hHPXtsgUdZ4GZ-eQwkTLgQ==",label:"WFuxkvDaJtvRG1q-haHcBQ==",value:"_6fHUr05hAbo85hI967ByDg==",units:"EdVuwD5UxHNRKpAyfNSWGg==","pad-right":"_6T9CddK+8fdeyqNlwc4v4Q==","off-scale-low":"Sc1CVNBCBJ6DIhtHUAQbCg==","off-scale-high":"cWpU2bqU5X9eYPOfFJtE4g==",arrow:"SLGUhJysawfaXr-VtuJBYg=="};function d0(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var d1=function(e){var t,r,n,o,i,a,u,s,l,c,f,p,m,y,b,v,g,w,E=e.value,S=e.unit,O=e.label,A=e.interpretation,x=e.referenceRange,D=e.conceptUuid,j=e.variant,C=e.patientUuid,P=(0,em.useId)(),k=(c=null,(t=x||A?void 0:D)&&(c=C?"".concat(d.Jj,"/conceptreferencerange/?patient=").concat(C,"&concept=").concat(t,"&v=full"):"".concat(d.Jj,"/conceptreferencerange/?concept=").concat(t,"&v=full")),p=(f=(0,c9.A)(c,d.lo)).data,m=f.error,y=f.isLoading,{referenceRange:(b=null==p||null==(l=p.data)||null==(s=l.results)?void 0:s[0])?{hiNormal:null!=(r=b.hiNormal)?r:null,hiAbsolute:null!=(n=b.hiAbsolute)?n:null,hiCritical:null!=(o=b.hiCritical)?o:null,lowNormal:null!=(i=b.lowNormal)?i:null,lowAbsolute:null!=(a=b.lowAbsolute)?a:null,lowCritical:null!=(u=b.lowCritical)?u:null}:void 0,error:m,isLoading:y}),I=k.referenceRange,T=k.isLoading,R=null!=x?x:I,F=(0,em.useMemo)(function(){if(A)return A?"--"===A?"normal":dJ.includes(A)?A.toLowerCase():dX.includes(A)?A:"normal":void 0;if(R&&!T){if(!R||null==E||""===E)return"normal";var e="string"==typeof E?Number.parseFloat(E):E;return Number.isNaN(e)?"normal":null!==R.hiAbsolute&&void 0!==R.hiAbsolute&&e>R.hiAbsolute?"off_scale_high":null!==R.hiCritical&&void 0!==R.hiCritical&&e>=R.hiCritical?"critically_high":null!==R.hiNormal&&void 0!==R.hiNormal&&e>R.hiNormal?"high":null!==R.lowAbsolute&&void 0!==R.lowAbsolute&&e<R.lowAbsolute?"off_scale_low":null!==R.lowCritical&&void 0!==R.lowCritical&&e<=R.lowCritical?"critically_low":null!==R.lowNormal&&void 0!==R.lowNormal&&e<R.lowNormal?"low":"normal"}return"normal"},[A,R,E,T]),N=null!=F?F:"normal",M="critically_low"===N||"critically_high"===N||"off_scale_low"===N||"off_scale_high"===N,B="normal"!==N,L=O?"omrs-numeric-obs-label-".concat(O.replaceAll(/\s+/g,"-").toLowerCase(),"-").concat(P):void 0,V="omrs-numeric-obs-value-".concat(P),U="omrs-numeric-obs-unit-".concat(P),$=null!=E&&""!==E,W=$?E:(0,h.V)("notAvailable","Not available"),z=ev()((d0(v={},dQ["critically-low"],"critically_low"===N||"off_scale_low"===N),d0(v,dQ["critically-high"],"critically_high"===N||"off_scale_high"===N),d0(v,dQ.low,"low"===N),d0(v,dQ.high,"high"===N),d0(v,dQ["off-scale-low"],"off_scale_low"===N),d0(v,dQ["off-scale-high"],"off_scale_high"===N),v)),K=ev()((d0(g={},dQ.container,!0),d0(g,dQ.card,!0),d0(g,dQ["critical-value"],M),d0(g,dQ["abnormal-value"],B&&!M),g)),H=ev()((d0(w={},dQ.cell,!0),d0(w,z,!0),w));return"cell"===(void 0===j?"card":j)?(0,eh.jsxs)("div",{className:H,children:[W,$&&S?" ".concat(S):""]}):(0,eh.jsxs)("section",{className:K,"data-testid":"numeric-observation-card",children:[O&&(0,eh.jsxs)("div",{className:dQ["label-container"],children:[(0,eh.jsx)("span",{id:L,className:dQ.label,children:O}),B&&(0,eh.jsx)("span",{className:dQ[N.replace("_","-")],title:(0,h.V)("abnormalValue","Abnormal value")})]}),(0,eh.jsxs)("div",{className:dQ["value-container"],children:[(0,eh.jsx)("span",{id:V,"aria-labelledby":L&&U?"".concat(L," ").concat(U):L||U||void 0,className:dQ.value,children:W}),$&&S&&(0,eh.jsx)("span",{id:U,className:dQ.units,children:S})]})]})};let d2="YOpQLiaTysM+swWB7ATzKw==";function d3(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function d4(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function d6(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function d5(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}var d8=function(e){if("children"in e){var t=e.children,r=e.className,n=d5(e,["children","className"]);return(0,eh.jsx)("div",d6(d4({className:ev()(d2,r)},n),{children:t}))}var o=e.title,i=e.illustration,a=e.className,u=d5(e,["title","illustration","className"]);return(0,eh.jsx)("div",d6(d4({className:ev()(d2,a)},u),{children:(0,eh.jsx)(d7,{title:o,illustration:i})}))},d7=function(e){var t,r=e.title,n=e.illustration,o=e.className,i=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)(null))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return d3(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return d3(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),a=i[0],u=i[1];return(0,em.useEffect)(function(){(0,f.zj)("@openmrs/esm-styleguide").then(function(e){u(e)})},[]),(0,eh.jsxs)("div",{className:ev()("PjsJmcqHjhav+51GzX5n1A==",o),children:[n,(0,eh.jsxs)("div",{className:"pPcKj1kNkKP4cQZUtFRU5g==",children:[(null==a?void 0:a.implementationName)&&(0,eh.jsx)("p",{children:(0,h.V)(a.implementationName)}),(0,eh.jsx)("p",{className:"_3d4ICXZtVrDwUYN1iMMJCA==",children:r})]})]})};function d9(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var fe=function(e){var t,r=e.totalItems,n=e.pageSize,o=e.onPageNumberChange,i=e.pageNumber,a=e.dashboardLinkUrl,u=e.currentItems,s=e.dashboardLinkLabel,l=(0,L.WK)(n,r,i,u),c=l.pageSizes,d=l.pageItemsCount,f="tablet"===(0,L.qv)(),p=(0,h.V)("paginationItemsCount","{{pageItemsCount}} / {{totalItems}} items",{totalItems:r,pageItemsCount:d});return(0,eh.jsx)(eh.Fragment,{children:r>0&&(0,eh.jsxs)("div",{className:ev()((d9(t={},"lQ3akicW2mAhjncqby7nDA==",f),d9(t,"HfUTYLFumnQ+awk4OaX1Dg==",!f),t)),children:[(0,eh.jsxs)("div",{children:[p,a&&(0,eh.jsx)(L.i_,{to:a,className:"NM9v7zGqLsggVcQgLFigdA==",children:null!=s?s:(0,h.V)("seeAll","See all")})]}),(0,eh.jsx)(eS.Pagination,{className:"WzkBsEFtArGu5wzXr0lPcA==",page:i,pageSize:n,pageSizes:c,totalItems:r,onChange:o,pageRangeText:function(e,t){return(0,h.V)("paginationOfPages","of {{count}} pages",{count:t})},size:f?"lg":"sm"})]})})};function ft(e){return fn(fi(e,"usual","official"))}function fr(e){return ft(e)}function fn(e){var t,r,n,o;return e?null!=(t=e.text)?t:(o=null!=(n=(r=e).given)?n:[],(r.family?o.concat(r.family):o).join(" ")):""}function fo(e){return fn(e)}function fi(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];0==r.length&&(r=["usual"]);var o=!0,i=!1,a=void 0;try{for(var u,s=r[Symbol.iterator]();!(o=(u=s.next()).done);o=!0){var l=function(){var t,r=u.value,n=null==(t=e.name)?void 0:t.find(function(e){var t,n;return t=e,n=r,t.use?t.use===n:"usual"===n});if(n)return{v:n}}();if("object"==(l&&"u">typeof Symbol&&l.constructor===Symbol?"symbol":typeof l))return l.v}}catch(e){i=!0,a=e}finally{try{o||null==s.return||s.return()}finally{if(i)throw a}}}function fa(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:lt()(),r=lt()(t),n=l5(e,r);if(null==n)return null;var o=r.diff(n,"hours"),i=r.diff(n,"days"),a=r.diff(n,"weeks"),u=r.diff(n,"months"),s=r.diff(n,"years"),l={};if(o<2)l.minutes=r.diff(n,"minutes");else if(i<2)l.hours=o;else if(a<4)l.days=i;else if(s<1){var c=r.subtract(a,"weeks").diff(n,"days");l.weeks=a,l.days=c}else if(s<2){var d=r.subtract(u,"months").diff(n,"days");l.months=u,l.days=d}else if(s<18){var f=r.subtract(s,"year").diff(n,"months");l.years=s,l.months=f}else l.years=s;return l}function fu(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:lt()(),r=fa(e,t);if(null==r)return null;var n={style:"short",localeMatcher:"lookup"};return"minutes"in r&&0===r.minutes&&(n.minutesDisplay="always"),l6(r,n)}let fs={container:"Gjd-4rKbEfNJ1EnpVM5fDg==",activePatientContainer:"QLcpgcrRf24FIBxfL-Reow==",patientBanner:"_7nrgC9D3asLAi-n1Cu-+aQ==",patientName:"-bF9a-l+JKDw4GnX6Iibsw==",patientAvatar:"AkN3HR6abRKcGhD1xnV8+w==",patientAvatarButton:"KDxA6I0UaFgLEI3mjex7Sg==",patientInfo:"+WtDB+1dogKuMZh79ffYHA==",demographics:"Vtf3vivMNnVD8Iw8FKnzIg==",row:"NIOYIHZjX3g7f-6H9EkSAg==",flexRow:"VxdGBrkVaGOrwx9RLt5iGA==",tagsSlot:"lU6+4m9TGusLI5P4rs2PxQ==",identifiers:"tehd8btQy-Upd-+nQmM3Ng==",identifier:"bSJIFK4yvsj7cwSGcOeCeg==",primaryIdentifier:"yOV1BITeMsXWDZ0-ZuNmRA==",secondaryIdentifier:"WvJbhTqh9ZSXAOeO7O+qjw==",value:"sBM-qDgU2-uAwtlPf+7gjA==",tag:"BEvEVs8H7vGP3H5V4Ec7VA==",gender:"_4XkLqr-02wazwbUoUfB7ow==",separator:"iYBA3rO3YNmv7d1qmnvvcA==",tooltipPadding:"EWVCKw9MY3VDbqwyPpZwyA==",tooltipSmallText:"yDmRU9+68HwaptpjumYB7w==",actionsButtonText:"mn139IetW5A5xAlW5YMrZQ=="};function fl(e){var t=e.showIdentifierLabel,r=e.type,n=e.value;return(0,eh.jsx)("span",{className:fs.primaryIdentifier,children:(0,eh.jsxs)(eS.Tag,{className:fs.tag,type:"gray",children:[t&&(null==r?void 0:r.text)&&(0,eh.jsxs)("span",{className:fs.label,children:[r.text,": "]}),(0,eh.jsx)("span",{className:fs.value,children:n})]})})}function fc(e){var t=e.showIdentifierLabel,r=e.type,n=e.value;return(0,eh.jsxs)(eS.FormLabel,{className:fs.secondaryIdentifier,id:"patient-banner-identifier-".concat(n),children:[t&&(0,eh.jsxs)("span",{className:fs.label,children:[null==r?void 0:r.text,": "]}),(0,eh.jsx)("span",{className:fs.value,children:n})]})}function fd(e){var t,r=e.identifiers,n=e.showIdentifierLabel,o=(0,L.UK)().excludePatientIdentifierCodeTypes,i=(0,L.wJ)().primaryIdentifierCode,a=null!=(t=null==r?void 0:r.filter(function(e){var t,r,n,i=null==(n=e.type)||null==(r=n.coding)||null==(t=r[0])?void 0:t.code;return i&&!(null==o?void 0:o.uuids.includes(i))}))?t:[];return(0,eh.jsx)(eh.Fragment,{children:(null==a?void 0:a.length)?a.map(function(e,t){var r,o,u=e.value,s=e.type;return(0,eh.jsxs)(ey().Fragment,{children:[(0,eh.jsx)("span",{className:fs.identifier,children:(null==s||null==(o=s.coding)||null==(r=o[0])?void 0:r.code)===i?(0,eh.jsx)(fl,{showIdentifierLabel:n,type:s,value:u}):(0,eh.jsx)(fc,{showIdentifierLabel:n,type:s,value:u})}),t<a.length-1&&(0,eh.jsx)("span",{className:fs.separator,children:"\xb7"})]},u)}):""})}var ff={Female:tc,Male:td,Other:tf,Unknown:tp},fp=function(e){var t=ff[e.gender];return t?(0,eh.jsx)(t,{fill:"#525252"}):null},fh={male:"Male",female:"Female",other:"Other",unknown:"Unknown"},fm=function(e){var t,r=e.toLowerCase(),n=null!=(t=fh[r])?t:"Unknown";return{displayText:(0,h.V)(r,e),iconKey:n}};function fy(e){var t=e.patient,r=e.renderedFrom,n=ft(t),o=(null==t?void 0:t.gender)&&fm(t.gender),i=(0,em.useMemo)(function(){return{patientUuid:t.id,patient:t,renderedFrom:r}},[t.id,t,r]);return(0,eh.jsxs)("div",{className:fs.patientInfo,children:[(0,eh.jsx)("div",{className:ev()(fs.row,fs.patientNameRow),children:(0,eh.jsxs)("div",{className:fs.flexRow,children:[(0,eh.jsx)("span",{className:fs.patientName,children:n}),o&&(0,eh.jsxs)("div",{className:fs.gender,children:[(0,eh.jsx)(fp,{gender:o.iconKey}),(0,eh.jsx)("span",{children:o.displayText})]}),(0,eh.jsx)(L.W3,{className:fs.tagsSlot,name:"patient-banner-tags-slot",state:i})]})}),(0,eh.jsxs)("div",{className:fs.demographics,children:[t.birthDate&&(0,eh.jsxs)(eh.Fragment,{children:[(0,eh.jsx)("span",{children:fu(t.birthDate)}),(0,eh.jsx)("span",{className:fs.separator,children:"\xb7"}),(0,eh.jsx)("span",{children:lQ(t.birthDate,{time:!1})}),(0,eh.jsx)("span",{className:fs.separator,children:"\xb7"})]}),(0,eh.jsx)(fd,{identifiers:t.identifier,showIdentifierLabel:!0}),(0,eh.jsx)(L.W3,{className:fs.extensionSlot,name:"patient-banner-bottom-slot",state:i})]})]})}var fb=r(5284);function fv(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function fg(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function fw(e){var t,r=e.patient,n=e.patientUuid,o=e.actionsSlotName,i=e.additionalActionsSlotState,a=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return fv(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return fv(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),u=a[0],s=a[1],l=(0,L.br)(o).extensions,c="tablet"===(0,L.qv)(),d=(0,L.Wr)(function(){return s(!1)},u),f=(0,em.useRef)(null),p=(0,em.useRef)(null),m=(0,em.useId)(),y="patient-actions-menu-trigger-".concat(m),b="patient-actions-menu-".concat(m),v=(0,em.useCallback)(function(){return s(function(e){return!e})},[]),g=(0,em.useCallback)(function(){var e;s(!1),null==(e=f.current)||e.focus()},[]),w=(0,em.useCallback)(function(e){if("Escape"===e.key&&u){e.stopPropagation(),g();return}if(("ArrowDown"===e.key||"ArrowUp"===e.key)&&u){e.preventDefault();var t,r,n,o,i,a,s=null==(r=p.current)?void 0:r.querySelectorAll('[role="menuitem"]:not([disabled])');if(!(null==s?void 0:s.length))return;var l=null!=(t=null==(o=document.activeElement)||null==(n=o.closest)?void 0:n.call(o,'[role="menuitem"]'))?t:document.activeElement,c=Array.from(s).indexOf(l);if(-1===c){null==(a=s["ArrowDown"===e.key?0:s.length-1])||a.focus();return}var d=c+("ArrowDown"===e.key?1:-1),f=d<0?s.length-1:d>=s.length?0:d;null==(i=s[f])||i.focus()}},[g,u]);(0,em.useEffect)(function(){if(u&&p.current){var e=p.current.querySelector('[role="menuitem"]:not([disabled])');null==e||e.focus()}},[u]);var E=(0,em.useMemo)(function(){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){fg(e,t,r[t])})}return e}({patientUuid:n,patient:r,closeMenu:g},i)},[n,r,g,i]);return 0===l.length?null:(0,eh.jsx)("div",{className:"lXHHD93To9w3SyNIoCMHSQ==",children:(0,eh.jsxs)("div",{"data-overflow-menu":!0,className:ev()("cds--overflow-menu",ex),ref:d,children:[(0,eh.jsxs)("button",{className:ev()("cds--btn","cds--btn--ghost","cds--overflow-menu__trigger",{"cds--overflow-menu--open":u},ej),"aria-controls":b,"aria-expanded":u,"aria-haspopup":"true",id:y,onClick:v,onKeyDown:w,ref:f,children:[(0,eh.jsx)("span",{className:"SdOyMS1Pdej4TaBLRHDong==",children:(0,h.V)("actions","Actions")})," ",(0,eh.jsx)(fb.CH,{size:16,style:{marginLeft:"0.5rem",fill:"#78A9FF"}})]}),(0,eh.jsxs)("div",{className:ev()("cds--overflow-menu-options","cds--overflow-menu--flip",eD,fg({},e_,u)),"aria-labelledby":y,"data-floating-menu-direction":"bottom",id:b,onKeyDown:w,ref:p,role:"menu",tabIndex:-1,children:[(0,eh.jsx)("ul",{className:ev()("cds--overflow-menu-options__content",{"cds--overflow-menu-options--lg":c}),children:(0,eh.jsx)(L.W3,{name:o,state:E},o)}),(0,eh.jsx)("span",{})]})]})})}var fE=r(6768),fS=r.n(fE),fO=r(7488);function fA(e){var t,r,n,o=(0,L.UK)({externalModuleName:"@openmrs/esm-styleguide"}).patientPhotoConceptUuid,i=o?"".concat(d.Jj,"/obs?patient=").concat(e,"&concept=").concat(o,"&v=full"):null,a=(0,fO.Ay)(e?i:null,d.lo),u=a.data,s=a.error,l=a.isLoading,c=null==u||null==(t=u.data)?void 0:t.results[0];return{data:c?{dateTime:null==c?void 0:c.obsDatetime,imageSrc:null==c||null==(n=c.value)||null==(r=n.links)?void 0:r.uri}:null,error:s,isLoading:l}}let fx=function(e){var t=e.width,r=e.height,n=e["aria-label"],o=(0,eF.useTranslation)().t;return(0,eh.jsxs)("svg",{"aria-label":null!=n?n:o("patientPhotoPlaceholder","Patient photo placeholder"),width:void 0===t?56:t,height:void 0===r?56:r,fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,eh.jsx)("path",{fill:"#ffffff",d:"M0 0h56v56H0z"}),(0,eh.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"m36.75 20.134-.884-.884L19.25 35.866l.884.884 1.25-1.25H34.25a1.252 1.252 0 0 0 1.25-1.25V21.384l1.25-1.25Zm-2.5 14.116H22.634l4.87-4.87 1.487 1.486a1.25 1.25 0 0 0 1.768 0l.991-.991 2.5 2.498v1.877Zm0-3.645-1.616-1.616a1.25 1.25 0 0 0-1.768 0l-.991.991-1.486-1.486 5.861-5.86v7.971Zm-12.5 1.145v-1.875l3.125-3.123.858.859.885-.885-.86-.86a1.25 1.25 0 0 0-1.767 0l-2.241 2.242V21.75h10V20.5h-10c-.69 0-1.25.56-1.25 1.25v10h1.25Z",fill:"#8D8D8D"})]})},fD="t5TmZmWjzvbCohKkMNbM-g==";function f_(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function fj(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],a=!0,u=!1;try{for(o=o.call(e);!(a=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){u=!0,n=e}finally{try{a||null==o.return||o.return()}finally{if(u)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return f_(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return f_(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function fC(e){var t=e.patientUuid,r=e.patientName,n=e.alt,o=fA(t),i=o.data,a=o.isLoading,u=fj((0,em.useState)(null),2),s=u[0],l=u[1],c=fj((0,em.useState)(!1),2),d=c[0],f=c[1],p=(0,em.useMemo)(function(){return fS().generate(t)},[t]);(0,em.useEffect)(function(){if(null==i?void 0:i.imageSrc){var e=new URL(i.imageSrc,window.location.origin).pathname;f(!0);var t=!1,r=new Image;return r.onload=function(){t||(l(e),f(!1))},r.onerror=function(){t||(l(null),f(!1))},r.src=e,function(){t=!0}}l(null),f(!1)},[null==i?void 0:i.imageSrc]);var m=(0,em.useMemo)(function(){return n||(s?(0,h.V)("patientPhotoAlt","Profile photo of {{patientName}}",{patientName:r}):(0,h.V)("patientAvatarAlt","Avatar for {{patientName}}",{patientName:r}))},[n,s,r]);return a||d?(0,eh.jsx)(eS.SkeletonIcon,{className:"ueN8QhkAPVeVEePyTHkCOg==","data-testid":"skeleton-icon"}):(null==i?void 0:i.imageSrc)&&!s?(0,eh.jsx)(fx,{"aria-label":(0,h.V)("patientPhotoPlaceholder","Photo placeholder for {{patientName}}",{patientName:r})}):s?(0,eh.jsx)("div",{"aria-label":m,children:(0,eh.jsx)("img",{className:fD,src:s,alt:m,title:r})}):(0,eh.jsx)("div",{"aria-label":m,children:(0,eh.jsx)("div",{className:fD,title:r,style:{backgroundImage:p.toDataUrl(),backgroundRepeat:"no-repeat",backgroundSize:"cover"},children:(0,eh.jsx)("span",{className:"-k9HvZjk0UAVuy9F8zZz0w==",children:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3;return e.split(/\s+/).filter(Boolean).slice(0,t).map(function(e){return e[0]}).join("")}(r)})})})}function fP(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function fk(e){if(Array.isArray(e))return e}function fI(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function fT(e,t){if(e){if("string"==typeof e)return fP(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return fP(e,t)}}var fR=["omrs-pict-appointments","omrs-pict-assessment-1","omrs-pict-assessment-2","omrs-pict-blood-bank","omrs-pict-cardiology","omrs-pict-ct-scan","omrs-pict-dentistry","omrs-pict-emergency-department","omrs-pict-facility","omrs-pict-geriatrics","omrs-pict-gynaecology","omrs-pict-in-patient","omrs-pict-laboratory","omrs-pict-labs-2","omrs-pict-obstetrics","omrs-pict-patient-search","omrs-pict-patients","omrs-pict-payments-desk","omrs-pict-pharmacy","omrs-pict-pharmacy-2","omrs-pict-registration","omrs-pict-service-queues","omrs-pict-stock-management","omrs-pict-transfer","omrs-pict-triage","omrs-pict-x-ray"],fF=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-appointments",pictogramProps:e})})),fN=fF,fM=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-assessment-1",pictogramProps:e})})),fB=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-assessment-2",pictogramProps:e})})),fL=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-blood-bank",pictogramProps:e})})),fV=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-cardiology",pictogramProps:e})})),fU=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-ct-scan",pictogramProps:e})})),f$=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-dentistry",pictogramProps:e})})),fW=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-emergency-department",pictogramProps:e})})),fz=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-facility",pictogramProps:e})})),fK=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-geriatrics",pictogramProps:e})})),fH=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-gynaecology",pictogramProps:e})})),fG=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-in-patient",pictogramProps:e})})),fq=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-laboratory",pictogramProps:e})})),fZ=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-labs-2",pictogramProps:e})})),fY=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-obstetrics",pictogramProps:e})})),fJ=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-patient-search",pictogramProps:e})})),fX=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-patients",pictogramProps:e})})),fQ=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-payments-desk",pictogramProps:e})})),f0=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-pharmacy",pictogramProps:e})})),f1=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-pharmacy-2",pictogramProps:e})})),f2=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-registration",pictogramProps:e})})),f3=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-service-queues",pictogramProps:e})})),f4=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-stock-management",pictogramProps:e})})),f6=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-transfer",pictogramProps:e})})),f5=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-triage",pictogramProps:e})})),f8=(0,em.memo)((0,em.forwardRef)(function(e,t){return(0,eh.jsx)(pt,{ref:t,pictogram:"omrs-pict-x-ray",pictogramProps:e})})),f7=fz,f9=fX,pe=(0,em.memo)((0,em.forwardRef)(function(e,t){var r,n=fk(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||fT(r)||fI(),o=n[0],i=n.slice(1),a=o.pictogram,u=o.fallback,s=function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(o,["pictogram","fallback"]),l=(fk(i)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),1!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(i)||fT(i,1)||fI())[0],c=(0,em.useRef)(document.getElementById(a));return(0,em.useEffect)(function(){var e=document.getElementById("omrs-svgs-container"),t=new MutationObserver(function(e){var t=!0,r=!1,n=void 0;try{for(var o,i=e[Symbol.iterator]();!(t=(o=i.next()).done);t=!0){var u=o.value;"childList"===u.type&&(c.current=document.getElementById(a))}}catch(e){r=!0,n=e}finally{try{t||null==i.return||i.return()}finally{if(r)throw n}}});return e&&t.observe(e,{childList:!0}),function(){return t.disconnect()}},[a]),(0,eh.jsx)(L.fS,{value:c.current,fallback:u,children:(0,eh.jsx)(pt,{ref:l,pictogram:a,pictogramProps:s})})})),pt=(0,em.memo)((0,em.forwardRef)(function(e,t){var r=e.pictogram,n=Object.assign({},{size:92},e.pictogramProps),o=n.className,i=n.size;return(i<=26||i>144)&&(console.error("Invalid size '".concat(i,"' specified for ").concat(r,". Defaulting to 92.")),i=92),(0,eh.jsx)("svg",{ref:t,className:ev()("wXX7tgyTzQUB487Ai2jwkw==",o),height:i,width:i,children:(0,eh.jsx)("use",{href:"#".concat(r)})})})),pr=function(e){var t=e.children;return"tablet"===(0,L.qv)()?(0,eh.jsx)(eS.Layer,{children:t}):(0,eh.jsx)(eh.Fragment,{children:t})};function pn(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function po(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function pi(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],a=!0,u=!1;try{for(o=o.call(e);!(a=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){u=!0,n=e}finally{try{a||null==o.return||o.return()}finally{if(u)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return pn(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return pn(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var pa=function(e){var t,r=e.snackbar,n=e.closeSnackbar,o=r.actionButtonLabel,i=r.kind,a=void 0===i?"success":i,u=r.onActionButtonClick,s=void 0===u?function(){}:u,l=r.isLowContrast,c=r.progressActionLabel,d=r.subtitle,f=r.timeoutInMs,p=void 0===f?5e3:f,m=r.autoClose,y=void 0===m?"error"!==a:m,b=r.title,v=(r.id,function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(r,["actionButtonLabel","kind","onActionButtonClick","isLowContrast","progressActionLabel","subtitle","timeoutInMs","autoClose","title","id"])),g=pi((0,em.useState)(void 0===o?"":o),2),w=g[0],E=g[1],S=pi((0,em.useState)(!0),2),O=S[0],A=S[1],x=pi((0,em.useState)(!1),2),D=x[0],j=x[1],C=(0,em.useCallback)(function(){setTimeout(n,250)},[n]),P=(0,em.useCallback)(function(){j(!0),C()},[C]);return(0,em.useEffect)(function(){if(y){var e=setTimeout(P,p);return function(){return clearTimeout(e)}}},[p,y,P]),(0,em.useEffect)(function(){A(!1),window.setTimeout(function(){A(!0)},0)},[]),(0,eh.jsx)(eS.ActionableNotification,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){po(e,t,r[t])})}return e}({actionButtonLabel:w,"aria-label":(0,h.V)("closeSnackbar","Close snackbar"),className:ev()("-oZItDje+VqIMbRFsj0vKg==",(po(t={},"M2YBUemKsEmA3Eg4hsWRFQ==",O),po(t,"yEmGTBZUeA8w30tHbNSn5g==",D),t)),kind:a,lowContrast:void 0===l?"error"!==a:l,onActionButtonClick:function(){s(),P(),c&&E(c)},onClose:C,statusIconDescription:(0,h.V)("snackbarNotification","Snackbar notification"),subtitle:void 0===d?"":d,title:b},v))};function pu(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function ps(e,t){if(e){if("string"==typeof e)return pu(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return pu(e,t)}}let pl=function(e){var t,r=e.subject,n=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)([]))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||ps(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),o=n[0],i=n[1],a=(0,em.useCallback)(function(e){i(function(t){return t.filter(function(t){return t!==e})})},[]);return(0,em.useEffect)(function(){var e=r.subscribe(function(e){return i(function(t){var r;return((function(e){if(Array.isArray(e))return pu(e)})(r=t.filter(function(t){return t.subtitle!==e.subtitle||t.actionButtonLabel!==e.actionButtonLabel||t.onActionButtonClick!==e.onActionButtonClick||t.kind!==e.kind||t.title!==e.title}))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||ps(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e])})});return function(){return e.unsubscribe()}},[r]),(0,eh.jsx)(eh.Fragment,{children:o.map(function(e){return(0,eh.jsx)(pa,{snackbar:e,closeSnackbar:function(){return a(e)}},e.id)})})};var pc=new dv.Subject,pd=0;function pf(e){e&&(0,dB.createRoot)(e).render((0,eh.jsx)(pl,{subject:pc}))}function pp(e){var t;e&&"string"==typeof(t=e.title)&&t.trim().length>0?setTimeout(function(){var t,r;pc.next((t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},e),r=r={id:pd++},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))},0):console.error("showSnackbar must be called with an object having a 'title' property that is a non-empty string")}var ph=function(e){var t=e.toast,r=e.closeToast,n=t.description,o=t.kind,i=t.critical,a=t.title,u=t.actionButtonLabel,s=t.onActionButtonClick,l=void 0===s?function(){}:s,c=(0,em.useCallback)(function(){l(),r()},[r,l]);return(0,eh.jsx)("div",{children:(0,eh.jsx)(eS.ActionableNotification,{actionButtonLabel:u,kind:o||"info",lowContrast:i,subtitle:n,title:a||"",onActionButtonClick:c,onClose:r})})};function pm(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function py(e,t){if(e){if("string"==typeof e)return pm(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return pm(e,t)}}let pb=function(e){var t,r=e.subject,n=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)([]))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||py(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),o=n[0],i=n[1],a=(0,em.useCallback)(function(e){i(function(t){return t.filter(function(t){return t!==e})})},[]);return(0,em.useEffect)(function(){var e=r.subscribe(function(e){return i(function(t){var r;return((function(e){if(Array.isArray(e))return pm(e)})(r=t.filter(function(t){return t.description!==e.description||t.kind!==e.kind||t.title!==e.title||t.actionButtonLabel!==e.actionButtonLabel||t.onActionButtonClick!==e.onActionButtonClick}))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||py(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e])})});return function(){return e.unsubscribe()}},[r]),(0,eh.jsx)(eh.Fragment,{children:o.map(function(e){return(0,eh.jsx)(ph,{toast:e,closeToast:function(){return a(e)}},e.id)})})};var pv=new dv.Subject,pg=0;function pw(e){e&&(0,dB.createRoot)(e).render((0,eh.jsx)(pb,{subject:pv}))}function pE(e){var t;e&&("string"==typeof(t=e.description)?t.trim().length>0:(void 0===t?"undefined":t&&"u">typeof Symbol&&t.constructor===Symbol?"symbol":typeof t)=="object"&&!dM(t))?setTimeout(function(){var t,r;pv.next((t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},e),r=r={id:pg++},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))},0):console.error("showToast must be called with an object having a 'description' property that is a non-empty string or object")}function pS(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function pO(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function pA(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function px(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(t)return!0;var r=pP[e];return!r||!r()}function pD(e,t){var r,n=null==(r=pB.getState())?void 0:r.workspaceGroup,o=null==n?void 0:n.name;o&&e===o&&p$(function(){var r=pG(e);r&&(r.setState({},!0),r.subscribe(function(){})()),"function"==typeof(null==n?void 0:n.cleanup)&&n.cleanup(),pB.setState(function(e){return pA(pO({},e),{workspaceGroup:void 0})}),"function"==typeof t&&t()},o?function(e){return e.currentWorkspaceGroup===o}:function(){return!0})}function p_(e,t){var r,n=t.name,o=t.additionalProps;(0,F.Xb)(n);var i=function(){pF(e.name,{ignoreChanges:!0,onWorkspaceClose:function(){return pj(n,o)},closeWorkspaceGroup:!1})};px(e.name)?i():pz("closing-workspace-launching-new-workspace",i,null!=(r=e.title)?r:e.name)}function pj(e,t){var r,n,o=(0,F.Xb)(e),i=pB.getState().workspaceGroup;if(i&&!(null==(r=i.members)?void 0:r.includes(e)))return void pD(i.name,function(){pj(e,t)});var a=null==(n=pB.getState().workspaceGroup)?void 0:n.name,u=pA(pO({},o),{title:pK(o,t),closeWorkspace:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return pF(e,t)},closeWorkspaceWithSavedChanges:function(t){return pF(e,pO({ignoreChanges:!0},t))},promptBeforeClosing:function(t){var r,n;return r=e,n=t,void(pP[r]=n)},setTitle:function(t,r){u.title=t,u.titleNode=r,pB.setState(function(t){var r=t.openWorkspaces.map(function(t){return t.name===e?u:t});return pA(pO({},t),{openWorkspaces:r})})},currentWorkspaceGroup:a,additionalProps:null!=t?t:{}});function s(e,t){pB.setState(function(r){var n,o=[e].concat(function(e){if(Array.isArray(e))return pS(e)}(n=null!=t?t:r.openWorkspaces)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(n)||function(e){if(e){if("string"==typeof e)return pS(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return pS(e,void 0)}}(n)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),i=pU(e);return pA(pO({},r),{openWorkspaces:o,workspaceWindowState:i})})}a&&pG(a,t);var l=pB.getState().openWorkspaces,c=l.findIndex(function(t){return t.name===e}),d=l.find(function(e){return e.type==u.type});if(0===l.length)s(u);else if(l[0].canHide||0===c)if(c>=0){var f=l[c];s(pO(pA(pO({},f),{additionalProps:u.additionalProps}),f.title===pK(f,f.additionalProps)&&{title:pK(u,u.additionalProps)}),l.filter(function(t){return t.name!=e}))}else d?(s(d,pB.getState().openWorkspaces.filter(function(e){return e.type!=u.type})),p_(d,{name:e,additionalProps:t})):s(u);else p_(l[0],{name:e,additionalProps:t})}function pC(e){var t=e.targetUrl,r=e.contextKey,n=e.workspaceName,o=e.additionalProps;pN(r),pj(n,o),(0,M.oo)({to:t})}var pP={};function pk(e,t){pP[e]=t}function pI(e){return pP[e]}function pT(){var e=pB.getState();pB.setState(pA(pO({},e),{prompt:null}))}var pR={ignoreChanges:!1,onWorkspaceClose:function(){},closeWorkspaceGroup:!0};function pF(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};r=pO({},pR,r);var n=function(){var t,n,o=pB.getState();o.openWorkspaces.find(function(t){return t.name===e});var i=o.openWorkspaces.filter(function(t){return t.name!=e}),a=null==(t=pB.getState().workspaceGroup)?void 0:t.name;a&&r.closeWorkspaceGroup&&pD(a),pP[e]=function(){return!1},pB.setState(function(e){return pA(pO({},e),{prompt:null,openWorkspaces:i,workspaceWindowState:pU(null==i?void 0:i[0])})}),null==r||null==(n=r.onWorkspaceClose)||n.call(r)};return px(e,null==r?void 0:r.ignoreChanges)?(n(),!0):(pz("closing-workspace",n,null!=(t=(0,F.Xb)(e).title)?t:e),!1)}function pN(e){pB.getState().context!=e&&pB.setState({context:e,openWorkspaces:[],prompt:null})}var pM={context:"",openWorkspaces:[],prompt:null,workspaceWindowState:"normal",workspaceGroup:void 0},pB=(0,el.Zd)("workspace",pM);function pL(){return pB}function pV(e){var t=pB.getState();pB.setState(pA(pO({},t),{workspaceWindowState:e}))}function pU(e){var t;return null!=(t=null==e?void 0:e.preferredWindowSize)?t:"normal"}function p$(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(){},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){return!0},r=pB.getState().openWorkspaces.filter(t).every(function(e){return px(e.name)}),n=function(){pH(),null==e||e()};r?n():pz("closing-all-workspaces",n)}function pW(){var e=(0,L.Pj)(pB),t=e.workspaceWindowState,r=e.openWorkspaces,n=e.prompt,o=e.workspaceGroup;return(0,em.useMemo)(function(){return{active:r.length>0,prompt:n,workspaceWindowState:t,workspaces:r,workspaceGroup:o}},[r,t,n,o])}function pz(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";switch(e){case"closing-workspace":t={title:(0,h.V)("unsavedChangesTitleText","Unsaved changes"),body:(0,h.V)("unsavedChangesInOpenedWorkspace","You may have unsaved changes in the opened workspace. Do you want to discard these changes?"),onConfirm:function(){null==r||r()},confirmText:(0,h.V)("discard","Discard")};break;case"closing-all-workspaces":var o=pB.getState().openWorkspaces.filter(function(e){return!px(e.name)}).map(function(e,t){var r=e.title;return"".concat(t+1,". ").concat(r)});t={title:(0,h.V)("closingAllWorkspacesPromptTitle","You have unsaved changes"),body:(0,h.V)("closingAllWorkspacesPromptBody","There may be unsaved changes in the following workspaces. Do you want to discard changes in the following workspaces? {{workspaceNames}}",{workspaceNames:o.join(",")}),onConfirm:function(){null==r||r()},confirmText:(0,h.V)("closeAllOpenedWorkspaces","Discard changes in {{count}} workspaces",{count:o.length})};break;case"closing-workspace-launching-new-workspace":t={title:(0,h.V)("unsavedChangesTitleText","Unsaved changes"),body:(0,h.V)("unsavedChangesInWorkspace",'There may be unsaved changes in "{{workspaceName}}". Please save them before opening another workspace.',{workspaceName:n}),onConfirm:function(){pB.setState(function(e){return pA(pO({},e),{prompt:null})}),null==r||r()},confirmText:(0,h.V)("openAnyway","Open anyway")};break;default:console.error('Workspace system trying to open unknown prompt type "'.concat(e,'" in function "showWorkspacePrompts"')),null==r||r();return}pB.setState(function(e){return pA(pO({},e),{prompt:t})})}function pK(e,t){var r;return null!=(r=null==t?void 0:t.workspaceTitle)?r:e.title}function pH(){pB.setState(pM)}function pG(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e&&"default"!==e){var r=(0,el.jf)(e,{});return t&&r.setState(function(e){return pO({},e,t)}),r}}let pq="f7spBy3jUTfjOH25a05A1A==",pZ="ZROo9Y2WovRqEcmbEXN7sQ==",pY="+mcQhrE2BMNqPBknif4FqQ==";function pJ(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function pX(e){var t=e.getIcon,r=e.formOpenInTheBackground,n=e.tagContent;return(0,eh.jsxs)(eh.Fragment,{children:[t({size:16}),r?(0,eh.jsx)("span",{className:"_7695LgJosRmkPmkyVGdZ-g==",children:"!"}):(0,eh.jsx)("span",{className:"vo9ZXEHO6camG8qEsBCH8A==",children:n})]})}var pQ=function(e){var t,r=e.getIcon,n=e.label,o=e.iconDescription,i=e.handler,a=e.type,u=e.tagContent,s=(0,L.qv)(),l=pW(),c=l.workspaces,d=l.workspaceWindowState,f=null!=(t=null==c?void 0:c.findIndex(function(e){return e.type===a}))?t:-1,p="hidden"!==d&&0===f,h=f>0||0===f&&"hidden"===d;return"tablet"===s||"phone"===s?(0,eh.jsxs)(eS.Button,{className:ev()(pq,pJ({},pY,p)),iconDescription:o,kind:"ghost",onClick:i,role:"button",tabIndex:0,size:"md",children:[(0,eh.jsx)("span",{className:pZ,children:(0,eh.jsx)(pX,{formOpenInTheBackground:h,getIcon:r,tagContent:u})}),(0,eh.jsx)("span",{children:n})]}):(0,eh.jsx)(eS.IconButton,{align:"left","aria-label":o,className:ev()(pq,pJ({},pY,p)),enterDelayMs:300,kind:"ghost",label:n,onClick:i,size:"md",children:(0,eh.jsx)("div",{className:pZ,children:(0,eh.jsx)(pX,{formOpenInTheBackground:h,getIcon:r,tagContent:u})})})},p0=r(3486),p1=r(2164),p2=r(2768),p3=/[\\^$.*+?()[\]{}|]/g,p4=RegExp(p3.source);let p6=function(e){return(e=(0,p2.A)(e))&&p4.test(e)?e.replace(p3,"\\$&"):e};function p5(e){var t,r,n=e.contextKey,o=pW().prompt;return(0,em.useEffect)(function(){new RegExp("/".concat(p6(n),"(/|$)")).test(window.location.pathname)||console.warn('WorkspaceContainer has provided an invalid context key: "'.concat(n,'". The context key must be part of the URL path, with no initial or trailing slash.'))},[]),(0,em.useEffect)(function(){return pN(n),function(){pN(null)}},[n]),(0,em.useEffect)(function(){var e=function(e){var t=e.detail,r=t.cancelNavigation,o=t.newUrl,i=new RegExp("/".concat(p6(n),"(/|$)")),a=new URL(o),u=i.test(a.pathname),s=pB.getState().openWorkspaces.every(function(e){return px(e.name)});u||(s?pH():(null==r||r(),p$(function(){(0,M.oo)({to:o})})))};return window.addEventListener("single-spa:before-routing-event",e),function(){window.removeEventListener("single-spa:before-routing-event",e)}},[]),null!=o?(0,eh.jsxs)(eS.ComposedModal,{open:!0,onClose:pT,children:[(0,eh.jsx)(eS.ModalHeader,{title:o.title}),(0,eh.jsx)(eS.ModalBody,{children:(0,eh.jsx)("p",{className:"+SBeVyf3Vs1HLINqeNxwCA==",children:o.body})}),(0,eh.jsxs)(eS.ModalFooter,{children:[(0,eh.jsx)(eS.Button,{kind:"secondary",onClick:pT,children:null!=(t=o.cancelText)?t:(0,h.V)("cancel")}),(0,eh.jsx)(eS.Button,{kind:"danger",onClick:o.onConfirm,children:null!=(r=o.confirmText)?r:(0,h.V)("confirm")})]})]}):null}var p8=r(2879);function p7(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function p9(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?p7(Object(r),!0).forEach(function(t){ht(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):p7(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function he(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function ht(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hr(e){return(hr=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function hn(e,t){return(hn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function ho(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var hi=function(e){var t=em.Component;if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");a.prototype=Object.create(t&&t.prototype,{constructor:{value:a,writable:!0,configurable:!0}}),t&&hn(a,t);var r,n,o,i=(r=function(){if("u"<typeof Reflect||!Reflect.construct||Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}(),function(){var e,t=hr(a);e=r?Reflect.construct(t,arguments,hr(this).constructor):t.apply(this,arguments);if(e&&("object"==(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)||"function"==typeof e))return e;if(void 0!==e)throw TypeError("Derived constructors may only return object or undefined");return ho(this)});function a(e){var t;if(function(e,t){if(null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!t[Symbol.hasInstance](e):!(e instanceof t))throw TypeError("Cannot call a class as a function")}(this,a),ht(ho(t=i.call(this,e)),"handleRef",function(e){t.el=e}),ht(ho(t),"addThingToDo",function(e,r){t.state.hasError&&"unmount"!==e||(t.nextThingToDo=(t.nextThingToDo||Promise.resolve()).then(function(){if(!t.unmounted||"unmount"===e)return r.apply(void 0,arguments)}).catch(function(r){throw t.nextThingToDo=Promise.resolve(),t.setState({hasError:!0}),r&&r.message&&(r.message="During '".concat(e,"', parcel threw an error: ").concat(r.message)),t.props.handleError?t.props.handleError(r):setTimeout(function(){throw r}),r}))}),ht(ho(t),"getParcelProps",function(){var e=p9(p9({},t.props),{},{domElement:t.el});return delete e.mountParcel,delete e.config,delete e.wrapWith,delete e.wrapStyle,delete e.appendTo,delete e.handleError,delete e.parcelDidMount,e}),t.state={hasError:!1},!e.config)throw Error("single-spa-react's Parcel component requires the 'config' prop to either be a parcel config or a loading function that returns a promise. See https://github.com/single-spa/single-spa-react");return t}return n=[{key:"componentDidMount",value:function(){var e=this;this.unmounted=!1,this.addThingToDo("mount",function(){var t,r=e.props.mountParcel||e.mountParcel;if(!r)throw Error("\n <Parcel /> was not passed a mountParcel prop, nor is it rendered where mountParcel is within the React context.\n If you are using <Parcel /> within a module that is not a single-spa application, you will need to import mountRootParcel from single-spa and pass it into <Parcel /> as a mountParcel prop \n ");return e.el?t=e.el:(e.createdDomElement=t=document.createElement(e.props.wrapWith),Object.keys(e.props.wrapStyle).forEach(function(r){t.style[r]=e.props.wrapStyle[r]}),e.props.appendTo.appendChild(t)),e.parcel=r(e.props.config,p9({domElement:t},e.getParcelProps())),e.parcel.mountPromise.then(e.props.parcelDidMount),e.parcel.mountPromise})}},{key:"componentDidUpdate",value:function(){var e=this;this.addThingToDo("update",function(){if(e.parcel&&e.parcel.update)return e.parcel.update(e.getParcelProps())})}},{key:"componentWillUnmount",value:function(){var e=this;this.addThingToDo("unmount",function(){if(e.parcel&&"MOUNTED"===e.parcel.getStatus())return e.parcel.unmount()}),this.createdDomElement&&this.createdDomElement.parentNode.removeChild(this.createdDomElement),this.unmounted=!0}},{key:"render",value:function(){var e=this;if(this.props.appendTo)return p8.i&&p8.i.Consumer?em.createElement(p8.i.Consumer,null,function(t){return e.mountParcel=t?t.mountParcel:null,null}):null;var t=p8.i&&p8.i.Consumer?em.createElement(p8.i.Consumer,null,function(t){return e.mountParcel=t?t.mountParcel:null,null}):void 0;return em.createElement(this.props.wrapWith,{ref:this.handleRef,style:this.props.wrapStyle,className:this.props.wrapClassName},t)}}],he(a.prototype,n),o&&he(a,o),a}();ht(hi,"defaultProps",{wrapWith:"div",wrapStyle:{},parcelDidMount:function(){}});function ha(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function hu(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],a=!0,u=!1;try{for(o=o.call(e);!(a=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){u=!0,n=e}finally{try{a||null==o.return||o.return()}finally{if(u)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return ha(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ha(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function hs(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function hl(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function hc(e){var t,r,n,o,i,a,u,s,l=e.workspace,c=e.additionalPropsFromPage,d=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)())||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return hs(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return hs(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),f=d[0],p=d[1],m=(r=l.currentWorkspaceGroup,o=(n=hu((0,em.useState)({}),2))[0],i=n[1],u=(a=hu((0,em.useState)(r),2))[0],s=a[1],(0,em.useEffect)(function(){u!==r&&s(r)},[r]),(0,em.useEffect)(function(){var e,t=pG(u);return t&&(i(t.getState()),e=t.subscribe(i)),function(){t&&(null==e||e())}},[u]),o);(0,em.useEffect)(function(){var e=!0;return l.load().then(function(t){e&&p(t)}),function(){e=!1}},[l]);var y=(0,em.useMemo)(function(){return l&&hl({closeWorkspace:l.closeWorkspace,closeWorkspaceWithSavedChanges:l.closeWorkspaceWithSavedChanges,promptBeforeClosing:l.promptBeforeClosing,setTitle:l.setTitle},c,m,l.additionalProps)},[l,c,m]);return f?(0,eh.jsx)(hi,hl({config:f,mountParcel:U.mountRootParcel},y),l.name):(0,eh.jsx)(eS.InlineLoading,{className:"H6dHj0oBasuEG5BThmRHhw==",description:"".concat((0,h.V)("loading","Loading")," ...")})}function hd(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function hf(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hp(e){var t,r,n=e.isWithinWorkspace,o=e.name,i=e.actionMenuProps,a=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return hd(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return hd(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),u=a[0],s=a[1],l=(0,em.useRef)(window.innerHeight),c=(0,em.useContext)(L.zq).featureName,d=(0,L.qv)();return(0,em.useEffect)(function(){var e=function(){s(!(0,L.xl)(d)&&l.current>window.innerHeight),l.current!=window.innerHeight&&(l.current=window.innerHeight)};return window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}},[l]),(0,eh.jsx)("aside",{className:ev()("GJUJ7TWs47hZNAq1HgT48A==",(hf(r={},"_7+TCfrT4vrpC5TH4e1by0w==",n),hf(r,"bQ0UMzF1JBk1bcCogWlGrw==",u),hf(r,"v-1cRnDYDLbApkU1gJodvg==",!u),r)),children:(0,eh.jsx)("div",{className:"WocuWYX1W7JwP94ypr0B8A==",children:(0,eh.jsx)(L.W3,{className:"Cn3Jbzq8LOgwfW4fj6XYSQ==",name:"action-menu-".concat(o&&"default"!=o?o:c,"-items-slot"),state:void 0===i?{}:i})})})}function hh(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hm(e){var t,r,n,o=e.contextKey,i=e.overlay,a=e.showSiderailAndBottomNav,u=e.additionalWorkspaceProps,s=e.actionMenuProps,l=(0,L.qv)(),c=pW(),d=c.workspaces,f=c.workspaceWindowState,p=c.workspaceGroup,h=null==p?void 0:p.name,m=d[0],y="hidden"===f||null==m,b=null!=(t=null==m?void 0:m.width)?t:i?"wider":"narrow",v=(0,em.useMemo)(function(){return a||h&&!y},[h,y,a]);return(0,L.yJ)(!y&&!(0,L.xl)(l)),(0,eh.jsxs)(eh.Fragment,{children:[(0,eh.jsxs)("div",{className:a?"AHHuuXanpv12GtwxcK3ogA==":"E7yiHjGY1d2E+4Abx0jh7g==",children:[(0,eh.jsx)("aside",{className:ev()(i?"_7nS969hUMMe36pOPOtI3Fg==":"l+rgkmJVqlq3O++ce09vbA==",(hh(r={},"AJHmQ2iPp0Yic2jCrU6NIA==",y),hh(r,"Vb16L-oIiZ74fu1QQMOirg==","narrow"===b),hh(r,"Bn7v8I0voAWdRO7H9eKQiw==","wider"===b),hh(r,"vN8kIRmjOaaBlFkAfGVJ5g==","extra-wide"===b),r)),children:(0,eh.jsx)("div",{className:ev()("pBPmoo5CjBr1d116v8KrrA==",(hh(n={},"Sew5FCwW7FqufRz17h2owg==","maximized"===f),hh(n,"BxutHfy6GErdVMJpbvmkVg==",y),n)),children:d.map(function(e,t){return(0,eh.jsx)("div",{className:ev()("tYaVVyyd6Tcv58Bbo4mkcw==",hh({},"lBaWeq3srAzA5Ngk2dm0kQ==",0!==t)),children:(0,eh.jsx)(em.Suspense,{fallback:null,children:(0,eh.jsx)(eF.I18nextProvider,{i18n:window.i18next,defaultNS:e.moduleName,children:(0,eh.jsx)(hy,{workspaceInstance:e,additionalWorkspaceProps:u})})})},"workspace-container-".concat(e?e.name:"empty-".concat(t)))})})}),(0,eh.jsx)(p5,{contextKey:o})]}),v&&(0,eh.jsx)(hp,{name:h,isWithinWorkspace:!a,actionMenuProps:s})]})}function hy(e){var t,r=e.workspaceInstance,n=e.additionalWorkspaceProps,o=(0,eF.useTranslation)().t,i=(0,L.qv)(),a=pW(),u=a.workspaceWindowState,s=a.workspaceGroup,l=null==s?void 0:s.name,c="maximized"===u;(0,em.useEffect)(function(){var e=o(r.title);e!==r.title&&r.setTitle(e)},[r.title,o,r.setTitle]);var d=(0,em.useContext)(L.zq).featureName,f=(0,em.useCallback)(function(){pV(c?"normal":"maximized")},[c]),p=(0,em.useMemo)(function(){return null!=r?r:{}},[r]),m=p.canHide,y=void 0!==m&&m,b=p.canMaximize,v=p.currentWorkspaceGroup,g=p.closeWorkspace,w=(0,em.useMemo)(function(){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){hh(e,t,r[t])})}return e}({},n,null==r?void 0:r.additionalProps)},[n,r]);return r&&(0,eh.jsxs)(eh.Fragment,{children:[(0,eh.jsxs)(eS.Header,{"aria-label":(0,h.V)("workspaceHeader","Workspace Header"),className:"-3kjtr5uYox3-kZnfzcNuw==",children:[!(0,L.xl)(i)&&!y&&(0,eh.jsx)(eS.HeaderMenuButton,{"aria-label":(0,h.V)("close","Close"),renderMenuIcon:(0,eh.jsx)(eK,{}),onClick:function(){return g()}}),(0,eh.jsx)(eS.HeaderName,{prefix:"",children:null!=(t=r.titleNode)?t:o(r.title)}),(0,eh.jsx)("div",{className:"_2Zd7JZN89pW2XY09qZBAAw=="}),(0,eh.jsxs)(eS.HeaderGlobalBar,{className:"ppNsYZC7Z00KBemD1lNxQA==",children:[(0,eh.jsx)(L.W3,{name:"workspace-header-group-".concat(r.currentWorkspaceGroup,"-slot"),state:w}),(0,eh.jsx)(L.W3,{name:"workspace-header-type-".concat(r.type,"-slot"),state:w}),(0,eh.jsx)(L.W3,{name:"workspace-header-".concat(d,"-slot"),state:w}),(0,L.xl)(i)&&(0,eh.jsxs)(eh.Fragment,{children:[(void 0!==b&&b||c)&&(0,eh.jsx)(eS.HeaderGlobalAction,{"aria-label":c?(0,h.V)("minimize","Minimize"):(0,h.V)("maximize","Maximize"),onClick:f,children:c?(0,eh.jsx)(p0.Xj,{}):(0,eh.jsx)(p0.hz,{})}),y&&!l?(0,eh.jsx)(eS.HeaderGlobalAction,{"aria-label":(0,h.V)("hide","Hide"),onClick:function(){return pV("hidden")},children:(0,eh.jsx)(eH,{})}):(0,eh.jsx)(eS.HeaderGlobalAction,{"aria-label":(0,h.V)("close","Close"),onClick:function(){return null==g?void 0:g()},children:(0,eh.jsx)(te,{})})]}),"tablet"===i&&y&&(0,eh.jsx)(eS.HeaderGlobalAction,{"aria-label":(0,h.V)("close","Close"),onClick:function(){return null==g?void 0:g()},children:(0,eh.jsx)(p1.d3,{})})]})]}),(0,eh.jsx)("div",{className:ev()("cNdK12M+p0cj6LR0VGui6A==",hh({},"RXftxuAFC8bU7RXpujMdHA==",!!(void 0===v?"":v))),children:(0,eh.jsx)(hc,{workspace:r,additionalPropsFromPage:n},r.name)})]})}var hb=r(188),hv=r(8254);function hg(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function hw(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function hE(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){hw(i,n,o,a,u,"next",e)}function u(e){hw(i,n,o,a,u,"throw",e)}a(void 0)})}}function hS(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function hO(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function hA(e){return function(e){if(Array.isArray(e))return hg(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e){if(e){if("string"==typeof e)return hg(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return hg(e,void 0)}}(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function hx(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}function hD(e,t){return hE(function(){var r;return hx(this,function(n){switch(n.label){case 0:if(!(r=F.J_.getState().openedGroup))return[3,3];if(!(r.groupName!==e||!hC(r.props,t)))return[3,2];return[4,hP({reason:"CLOSE_WORKSPACE_GROUP",explicit:!1})];case 1:if(!n.sent())return[2,!1];return[3,3];case 2:return[2,!0];case 3:return F.J_.setState(function(r){return hO(hS({},r),{openedGroup:{groupName:e,props:t},openedWindows:[]})}),[2,!0]}})})()}function h_(e){return hE(function(){var t,r,n,o;return hx(this,function(i){switch(i.label){case 0:if(r=(t=F.J_.getState()).openedGroup,n=t.openedWindows,!r)return[3,4];if(!(n.length>0))return[3,3];if(o=e)return[3,2];return[4,hP({reason:"CLOSE_WORKSPACE_GROUP",explicit:!0})];case 1:o=i.sent(),i.label=2;case 2:if(!o)return[2,!1];i.label=3;case 3:return F.J_.setState(function(e){return hO(hS({},e),{openedGroup:null,openedWindows:[]})}),[2,!0];case 4:return[2,!0]}})})()}function hj(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;return hE(function(){var o,i,a,u,s,l,c,d,f,p,h,m,y,b,v,g,w,E,S,O,A,x;return hx(this,function(D){switch(D.label){case 0:if(!(o=F.J_.getState()).registeredWorkspacesByName[e])throw Error("Unable to launch workspace ".concat(e,". Workspace is not registered"));if(!(i=(0,F.Ml)(e)))throw Error("Unable to launch workspace ".concat(e,". Workspace is not registered to a workspace window"));if(a=o.openedGroup,u=i.name,!(s=(0,F.o1)(u)))throw Error("Unable to launch workspace ".concat(e,". Workspace window ").concat(i.name," is not registered to a workspace group"));if(c=(l=(0,F.YX)(e))>=0,!(a&&(a.groupName!==s.name||!hC(a.props,n))))return[3,2];return[4,hP({reason:"CLOSE_WORKSPACE_GROUP",explicit:!0})];case 1:if(D.sent())return F.J_.setState(hO(hS({},o),{openedGroup:{groupName:s.name,props:n},openedWindows:[{windowName:u,openedWorkspaces:[hF(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1})),[2,!0];return[2,!1];case 2:if(!c)return[3,9];if(p=o.openedWindows[l],h=null!=(d=null==(f=o.openedGroup)?void 0:f.props)?d:{},m=o.isMostRecentlyOpenedWindowHidden,y=p.openedWorkspaces,!hC(p.props,r))return[3,6];if(!((b=y.find(function(t){return t.workspaceName===e}))&&hC(b.props,t)))return[3,3];return(m||l!==o.openedWindows.length-1)&&F.J_.setState(hk.restoreWindow(o,u)),[2,!0];case 3:return[4,hP({reason:"CLOSE_WORKSPACE",explicit:!1,windowName:u,workspaceName:e})];case 4:if(D.sent())return F.J_.setState(hO(hS({},o),{openedGroup:{groupName:s.name,props:null!=(v=null==o||null==(w=o.openedGroup)?void 0:w.props)?v:h},openedWindows:hA(o.openedWindows.filter(function(e,t){return t!==l})).concat([{windowName:u,openedWorkspaces:[hF(e,t)],props:null!=(g=null==p?void 0:p.props)?g:r,maximized:!1}]),isMostRecentlyOpenedWindowHidden:!1})),[2,!0];return[2,!1];case 5:return[3,8];case 6:return[4,hP({reason:"CLOSE_WINDOW",explicit:!1,windowName:u})];case 7:if(D.sent())return F.J_.setState(hO(hS({},o),{openedGroup:{groupName:s.name,props:null!=h?h:null==o||null==(E=o.openedGroup)?void 0:E.props},openedWindows:hA(o.openedWindows.filter(function(e,t){return t!==l})).concat([{windowName:u,openedWorkspaces:[hF(e,t)],props:r,maximized:!1}]),isMostRecentlyOpenedWindowHidden:!1})),[2,!0];return[2,!1];case 8:return[3,12];case 9:if("closable"!=s.persistence)return[3,11];return[4,hP({reason:"CLOSE_OTHER_WINDOWS",explicit:!1,windowNameToSpare:i.name})];case 10:if(D.sent())return F.J_.setState(hO(hS({},o),{openedGroup:{groupName:s.name,props:null!=(S=null!=n?n:null==o||null==(O=o.openedGroup)?void 0:O.props)?S:null},openedWindows:[{windowName:u,openedWorkspaces:[hF(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1})),[2,!0];return[2,!1];case 11:return F.J_.setState(hO(hS({},o),{openedGroup:{groupName:s.name,props:null!=(A=null!=n?n:null==o||null==(x=o.openedGroup)?void 0:x.props)?A:null},openedWindows:hA(o.openedWindows).concat([{windowName:u,openedWorkspaces:[hF(e,t)],props:r,maximized:!1}]),isMostRecentlyOpenedWindowHidden:!1})),[2,!0];case 12:return[2]}})})()}function hC(e,t){return null==e||null==t||(0,hv.b)(e,t)}function hP(e){function t(e,t){for(var r=[],n=e.openedWorkspaces.length-1;n>=0;n--){var o=e.openedWorkspaces[n];if(o.hasUnsavedChanges&&r.push(o),t&&o.workspaceName===t)break}return r}var r=F.J_.getState(),n=r.openedWindows,o=r.workspaceTitleByWorkspaceName,i=[];switch(e.reason){case"CLOSE_WORKSPACE_GROUP":i=n.flatMap(function(e){return t(e)});break;case"CLOSE_WINDOW":var a=n.find(function(t){return t.windowName===e.windowName});if(!a)throw Error("Window ".concat(e.windowName," not found in opened windows."));i=t(a);break;case"CLOSE_WORKSPACE":var u=n.find(function(t){return t.windowName===e.windowName});if(!u)throw Error("Window ".concat(e.windowName," not found in opened windows."));i=t(u,e.workspaceName);break;case"CLOSE_OTHER_WINDOWS":i=n.filter(function(t){return t.windowName!==e.windowNameToSpare}).flatMap(function(e){return t(e)})}return 0===i.length?Promise.resolve(!0):new Promise(function(e){var t=db("workspace2-close-prompt",{onConfirm:function(){t(),e(!0)},onCancel:function(){t(),e(!1)},affectedWorkspaceTitles:i.map(function(e){return o[e.workspaceName]})})})}var hk={setWindowMaximized:function(e,t,r){var n=e.openedWindows.findIndex(function(e){return e.windowName===t}),o=hA(e.openedWindows),i=hO(hS({},o[n]),{maximized:r});return o[n]=i,hO(hS({},e),{openedWindows:o})},hideWindow:function(e){return hO(hS({},e),{isMostRecentlyOpenedWindowHidden:!0})},restoreWindow:function(e,t){var r=e.openedWindows.findIndex(function(e){return e.windowName===t}),n=e.openedWindows[r],o=hA(e.openedWindows.filter(function(e,t){return t!==r})).concat([n]);return hO(hS({},e),{openedWindows:o,isMostRecentlyOpenedWindowHidden:!1})},closeWorkspace:function(e,t){var r=(0,F.YX)(t);if(r<0)return e;var n=hS({},e.openedWindows[r]),o=n.openedWorkspaces.findIndex(function(e){return e.workspaceName===t}),i=hA(e.openedWindows);n.openedWorkspaces=n.openedWorkspaces.slice(0,o);var a=e.isMostRecentlyOpenedWindowHidden;if(0===n.openedWorkspaces.length){var u=r===e.openedWindows.length-1;i.splice(r,1),u&&i.length>0&&(a=!1)}else i[r]=n;return hO(hS({},e),{openedWindows:i,isMostRecentlyOpenedWindowHidden:a})},openChildWorkspace:function(e,t,r,n){var o=e.registeredWorkspacesByName[r];if(!o)throw Error('No workspace named "'.concat(r,'" registered'));var i=e.registeredWorkspacesByName[t];if(!i)throw Error('No workspace named "'.concat(t,'" registered'));if(i.window!==o.window)throw Error("Child workspace ".concat(r," does not belong to the same workspace window as parent workspace ").concat(t));var a=e.openedWindows.findIndex(function(e){return e.windowName===o.window});if(-1==a)throw Error("Cannot open child workspace ".concat(r," as window ").concat(o.window," is not opened"));var u=e.openedWindows[a].openedWorkspaces,s=u.findIndex(function(e){return e.workspaceName===t});if(-1===s)throw Error("Cannot open child workspace ".concat(r," from parent workspace ").concat(t," as the parent is not opened within the workspace window"));var l=u.slice(0,s+1);return{openedWindows:e.openedWindows.map(function(e,t){return t==a?hO(hS({},e),{openedWorkspaces:hA(l).concat([hF(r,n)])}):e})}},setHasUnsavedChanges:function(e,t,r){var n=(0,F.YX)(t);if(n<0)return e;var o=hS({},e.openedWindows[n]),i=o.openedWorkspaces.findIndex(function(e){return e.workspaceName===t});if(i<0)return e;o.openedWorkspaces[i]=hO(hS({},o.openedWorkspaces[i]),{hasUnsavedChanges:r});var a=hA(e.openedWindows);return a[n]=o,hO(hS({},e),{openedWindows:a})},setWorkspaceTitle:function(e,t,r){var n=hS({},e.workspaceTitleByWorkspaceName);return null===r?delete n[t]:n[t]=r,hO(hS({},e),{workspaceTitleByWorkspaceName:n})}};function hI(){return(0,L.mQ)(F.J_,hk)}var hT=function(){return(0,em.useContext)(p8.i)},hR=function(){return Object.keys(F.J_.getState().registeredWorkspacesByName)};function hF(e,t){return{workspaceName:e,props:null!=t?t:{},hasUnsavedChanges:!1,uuid:(0,hb.A)()}}let hN={workspaceOuterContainer:"bPVpyfZzXGTGRy6q-9pUCQ==",narrowWorkspace:"kSYS7aTPRggp+MU8vlcg9Q==",widerWorkspace:"nW2HBDZ0RgkGRkWQv4sdoQ==",extraWideWorkspace:"em5yAU5C7oWbHDo0sV+3mw==",workspaceMiddleContainer:"Bx1i6z+7q-g19Un039FkIw==",maximized:"Kfygrk5eNBXuECXupuCX8g==",hidden:"RPimX0oediR2hea+lS-OuQ==",workspaceInnerContainer:"_5zxptoWhQKImthth5lAP+g==",workspaceSpacer:"E+9820x1sb5UGVFe-CBnKA==",loader:"vmBQnPcRkkl1-BXrxfe78A==",hiddenExtraWorkspace:"qkbMGOnFdM1xyc3yNGcang==",header:"IZ-2+-SpwQ-zVx81DihBdw==",headerButtons:"_81a2NYhmPVTD24yRK8d2FQ==",workspaceContent:"eetPy90L7DgJzpdTBFH3sg==",overlayHeaderSpacer:"ruc6rYzwbrMxADrXzvYMPA==",isActionMenuOpened:"XgCkc1lLTADQAwD3tG9jVA==",showActionMenu:"sHRt1Fx7e+48j2yyo8ktzg==",marginWorkspaceContent:"TN+S+hiol289+iSd7tDjwA==",workspaceContainerWithActionMenu:"xLg8emf8GoZJo-KsUJV1QQ==",workspaceFixedContainer:"W9cgZ7vfCSiTpKs+aaYksQ==",workspaceContainerWithoutActionMenu:"fRrxdLWEtrSuNfqGjVjqVA=="};function hM(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var hB=function(e){var t,r,n,o,i=e.title,a=e.children,u=e.hasUnsavedChanges,s=void 0!==u&&u,l=(0,L.qv)(),c=hI(),d=c.setWindowMaximized,f=c.hideWindow,p=c.setHasUnsavedChanges,m=c.openedWindows,y=c.openedGroup,b=c.registeredGroupsByName,v=c.registeredWindowsByName,g=c.registeredWorkspacesByName,w=c.workspaceTitleByWorkspaceName,E=c.setWorkspaceTitle,S=c.isMostRecentlyOpenedWindowHidden,O=hT(),A=O.workspaceName,x=O.isRootWorkspace,D=O.closeWorkspace,j=O.showActionMenu,C=(0,F.YX)(A),P=m[C],k=null==P?void 0:P.openedWorkspaces.find(function(e){return e.workspaceName===A});if((0,em.useEffect)(function(){(null==k?void 0:k.hasUnsavedChanges)!=s&&p(A,null!=s&&s)},[null==k?void 0:k.hasUnsavedChanges,s,A,p]),(0,em.useEffect)(function(){w[A]!==i&&E(A,i)},[w,A,i,E]),C<0||null==y||null==k)return null;var I=b[y.groupName];if(!I)throw Error("Cannot find registered workspace group ".concat(y.groupName));var T=g[A].window,R=v[T];if(!R)throw Error("Cannot find registered workspace window ".concat(T));var N=R.icon,M=R.canMaximize,B="closable"===I.persistence,V=!!N&&!B,U=P.maximized,$=null!=(t=null==R?void 0:R.width)?t:"narrow",W=Object.values(v).some(function(e){return e.group===y.groupName&&void 0!==e.icon}),z=C<m.length-1||S;return(0,eh.jsxs)("div",{className:ev()(hN.workspaceOuterContainer,(hM(r={},hN.narrowWorkspace,"narrow"===$),hM(r,hN.widerWorkspace,"wider"===$),hM(r,hN.extraWideWorkspace,"extra-wide"===$),hM(r,hN.isActionMenuOpened,W),r)),children:[(0,eh.jsx)("div",{className:ev()(hN.workspaceSpacer,hM({},hN.hidden,z))}),(0,eh.jsx)("div",{className:ev()(hN.workspaceMiddleContainer,(hM(n={},hN.maximized,U),hM(n,hN.hidden,z),hM(n,hN.isRootWorkspace,x),hM(n,hN.showActionMenu,j),n)),children:(0,eh.jsxs)("div",{className:ev()(hN.workspaceInnerContainer,(hM(o={},hN.maximized,U),hM(o,hN.hidden,z),hM(o,hN.isRootWorkspace,x),o)),children:[(0,eh.jsxs)(eS.Header,{"aria-label":(0,h.V)("workspaceHeader"),className:hN.header,children:[(0,eh.jsx)(eS.HeaderName,{prefix:"",children:i}),(0,eh.jsx)("div",{className:hN.overlayHeaderSpacer}),(0,eh.jsx)(eS.HeaderGlobalBar,{className:hN.headerButtons,children:(0,L.xl)(l)?(0,eh.jsxs)(eh.Fragment,{children:[(M||U)&&(0,eh.jsx)(eS.HeaderGlobalAction,{"aria-label":U?(0,h.V)("minimize"):(0,h.V)("maximize"),onClick:function(){return d(T,!U)},children:U?(0,eh.jsx)(p0.Xj,{}):(0,eh.jsx)(p0.hz,{})}),V&&(0,eh.jsx)(eS.HeaderGlobalAction,{"aria-label":(0,h.V)("hide"),onClick:function(){return f()},children:(0,eh.jsx)(eH,{})}),!B&&(0,eh.jsx)(eS.HeaderGlobalAction,{"aria-label":(0,h.V)("close"),onClick:function(){return D({closeWindow:!0})},children:(0,eh.jsx)(te,{})})]}):(0,eh.jsxs)(eh.Fragment,{children:[V&&(0,eh.jsx)(eS.HeaderGlobalAction,{"aria-label":(0,h.V)("hide"),onClick:function(){return f()},children:(0,eh.jsx)(p1.d3,{})}),(0,eh.jsx)(eS.HeaderGlobalAction,{"aria-label":(0,h.V)("close"),onClick:function(){B?h_():D({closeWindow:!0})},children:(0,eh.jsx)(te,{})})]})})]}),(0,eh.jsx)("div",{className:ev()(hN.workspaceContent),children:a})]})})]})};let hL="jc6--ve4CL-z756RWjy-Gg==",hV="whLL8QyjyxlJqTQo67X7BQ==",hU="fbyFm5PlSWWUnG9aPE8kTg==",h$="+aVpzvvOae5n83hGlMESXg==";function hW(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function hz(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function hK(e){var t=e.getIcon,r=e.hasUnsavedChanges,n=e.tagContent;return(0,eh.jsxs)(eh.Fragment,{children:[t({size:16}),r?(0,eh.jsx)("span",{className:"sRkvSBatkOj+HMw7m2i81Q==",children:"!"}):(0,eh.jsx)("span",{className:"XMH0DAK2HUw4W4tYCVa-Fg==",children:n})]})}var hH=function(e){var t,r,n,o=e.icon,i=e.label,a=e.tagContent,u=e.workspaceToLaunch,s=e.onBeforeWorkspaceLaunch,l=(0,L.qv)(),c=hI(),d=c.openedWindows,f=c.restoreWindow,p=c.hideWindow,h=c.isMostRecentlyOpenedWindowHidden,m=(0,em.useContext)(L.zq).extension,y=d.findIndex(function(e){return e.windowName===(null==m?void 0:m.extensionId)}),b=d[y],v=null!=b,g=v&&(y<d.length-1||h),w=v&&!g,E=null!=(t=null==b?void 0:b.openedWorkspaces.some(function(e){return e.hasUnsavedChanges}))&&t,S=function(){var e;return(e=function(){var e,t;return function(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(r){switch(r.label){case 0:if(!v)return[3,1];return g?f(b.windowName):p(),[3,3];case 1:return[4,null==(e=null==s?void 0:s())||e];case 2:r.sent()&&(t=u.workspaceName,hj(t,u.workspaceProps,u.windowProps)),r.label=3;case 3:return[2]}})},function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){hW(i,n,o,a,u,"next",e)}function u(e){hW(i,n,o,a,u,"throw",e)}a(void 0)})})()};return"tablet"===l||"phone"===l?(0,eh.jsxs)(eS.Button,{className:ev()(hL,(hz(r={},hU,v&&!w),hz(r,h$,w),r)),iconDescription:i,kind:"ghost",onClick:S,role:"button",tabIndex:0,size:"md",children:[(0,eh.jsx)("span",{className:hV,children:(0,eh.jsx)(hK,{hasUnsavedChanges:E,getIcon:o,tagContent:a})}),(0,eh.jsx)("span",{children:i})]}):(0,eh.jsx)(eS.IconButton,{align:"left","aria-label":i,className:ev()(hL,(hz(n={},hU,v&&!w),hz(n,h$,w),n)),enterDelayMs:300,kind:"ghost",label:i,onClick:S,size:"md",children:(0,eh.jsx)("div",{className:hV,children:(0,eh.jsx)(hK,{hasUnsavedChanges:E,getIcon:o,tagContent:a})})})};function hG(e){var t=e.showContactDetails,r=e.toggleContactDetails,n=e.className;return(0,eh.jsx)(eS.Button,{className:n,iconDescription:"Toggle contact details",kind:"ghost",onClick:r,renderIcon:t?e9:e5,children:t?(0,h.V)("showLess","Show less"):(0,h.V)("showMore","Show more")})}var hq=function(e){var t,r=(0,c9.A)("".concat(d.Jj,"/patient/").concat(e,"?v=").concat("custom:(uuid,display,identifiers:(identifier,uuid,preferred,location:(uuid,name),identifierType:(uuid,name,format,formatDescription,validator)),person:(uuid,display,gender,birthdate,dead,age,deathDate,birthdateEstimated,causeOfDeath,preferredName:(uuid,preferred,givenName,middleName,familyName),attributes,preferredAddress:(uuid,preferred,address1,address2,cityVillage,longitude,stateProvince,latitude,country,postalCode,countyDistrict,address3,address4,address5,address6,address7)))"),d.lo),n=r.data,o=r.error;return{isLoading:r.isLoading,attributes:null!=(t=null==n?void 0:n.data.person.attributes)?t:[],error:o}},hZ=function(e){var t=(0,L.UK)({externalModuleName:"@openmrs/esm-patient-banner-app"}).contactAttributeTypes,r=void 0===t?[]:t,n=hq(e),o=n.attributes,i=n.error,a=n.isLoading;return{contactAttributes:(0,em.useMemo)(function(){return o.filter(function(e){var t=e.attributeType;return null==r?void 0:r.some(function(e){return t.uuid===e})})},[o,r]),isLoading:a,error:i}};let hY={contactDetails:"R7vfY7Iaw0lD8ocVMwqawA==",deceased:"nTt+luUWofi9sOTbqKrEMQ==",heading:"x7UoTntwbhzXmMIis3mxBw==",row:"qFgIi9mOLR8Ix3ZH8vrDYA==",col:"JXUlg85aLlEdoM3F7PHY9A==",relationship:"T3LO-FI5uzpceBz7W+qY3w=="};function hJ(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function hX(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],a=!0,u=!1;try{for(o=o.call(e);!(a=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){u=!0,n=e}finally{try{a||null==o.return||o.return()}finally{if(u)throw n}}return i}}(e,t)||hQ(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function hQ(e,t){if(e){if("string"==typeof e)return hJ(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return hJ(e,t)}}var h0=function(e){var t,r,n,o,i,a,u,s,l=(o=(r=e.patientUuid)?"".concat(d.Jj,"/cohortm/cohortmember?patient=").concat(r,"&v=").concat("custom:(uuid,patient:ref,cohort:(uuid,name,startDate,endDate))"):null,a=(i=(0,fO.Ay)(o,d.lo)).data,u=i.isLoading,s=null==a||null==(n=a.data)?void 0:n.results.map(function(e){return{uuid:e.cohort.uuid,name:e.cohort.name,startDate:e.cohort.startDate,endDate:e.cohort.endDate}}),(0,em.useMemo)(function(){return{cohorts:s,isLoading:u}},[u,s])),c=l.cohorts,f=void 0===c?[]:c,p=l.isLoading;return(0,eh.jsxs)(eh.Fragment,{children:[(0,eh.jsxs)("p",{className:hY.heading,children:[(0,h.V)("patientLists","Patient Lists")," (",null!=(t=null==f?void 0:f.length)?t:0,")"]}),p?(0,eh.jsx)(eS.InlineLoading,{description:"".concat((0,h.V)("loading","Loading")," ..."),role:"progressbar"}):(0,eh.jsxs)("ul",{children:[function(){if((null==f?void 0:f.length)>0){var e=f.sort(function(e,t){return lG(null==e?void 0:e.startDate).getTime()-lG(null==t?void 0:t.startDate).getTime()}).slice(0,3);return null==e?void 0:e.map(function(e){return(0,eh.jsx)("li",{children:(0,eh.jsx)(L.i_,{to:"".concat(window.spaBase,"/home/patient-lists/").concat(e.uuid),children:e.name},e.uuid)},e.uuid)})}return(0,eh.jsx)("li",{children:"--"})}(),f.length>3&&(0,eh.jsx)("li",{className:hY.link,children:(0,eh.jsx)(L.i_,{to:"".concat(window.spaBase,"/home/patient-lists"),children:(0,h.V)("seeMoreLists","See {{count}} more lists",{count:(null==f?void 0:f.length)-3})})})]})]})},h1=function(e){var t,r=e.patientId,n=(0,L.tQ)(r),o=n.patient,i=n.isLoading,a=null==o||null==(t=o.address)?void 0:t.find(function(e){return"home"===e.use}),u=function(e){return e.split("#")[1]};return i?(0,eh.jsx)(eS.InlineLoading,{description:"".concat((0,h.V)("loading","Loading")," ..."),role:"progressbar"}):(0,eh.jsxs)(eh.Fragment,{children:[(0,eh.jsx)("p",{className:hY.heading,children:(0,h.V)("address","Address")}),(0,eh.jsx)("ul",{children:a?Object.entries(a).filter(function(e){var t=hX(e,1)[0];return"id"!==t&&"use"!==t}).map(function(e){var t,r,n,o=hX(e,2),i=o[0],s=o[1];return"extension"===i?null==(n=a.extension)||null==(r=n[0])||null==(t=r.extension)?void 0:t.map(function(e,t){return(0,eh.jsxs)("li",{children:[(0,h.V)(u(e.url),u(e.url)),": ",e.valueString]},"address-".concat(i,"-").concat(t))}):(0,eh.jsxs)("li",{children:[(0,h.V)(i,i),": ",s]},"address-".concat(i))}):(0,eh.jsx)("li",{children:"--"})})]})},h2=function(e){var t=hZ(e.patientUuid),r=t.isLoading,n=t.contactAttributes,o=(0,em.useMemo)(function(){var e;return n?function(e){if(Array.isArray(e))return hJ(e)}(e=null==n?void 0:n.map(function(e){return[e.attributeType.display?(0,h.V)(e.attributeType.display,e.attributeType.display):"",e.value]}))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||hQ(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}():[]},[n]);return(0,eh.jsxs)(eh.Fragment,{children:[(0,eh.jsx)("p",{className:hY.heading,children:(0,h.V)("contactDetails","Contact Details")}),r?(0,eh.jsx)(eS.InlineLoading,{description:"".concat((0,h.V)("loading","Loading")," ..."),role:"progressbar"}):(0,eh.jsx)("ul",{children:o.length?o.map(function(e,t){var r=hX(e,2),n=r[0],o=r[1];return(0,eh.jsxs)("li",{children:[n,": ",o]},"".concat(n,"-").concat(o,"-").concat(t))}):(0,eh.jsx)("li",{children:"--"})})]})},h3=function(e){var t,r,n,o,i,a,u,s,l,c,f=(t=e.patientId,o="".concat(d.Jj,"/relationship?v=").concat("custom:(display,uuid,personA:(age,display,birthdate,uuid),personB:(age,display,birthdate,uuid),relationshipType:(uuid,display,description,aIsToB,bIsToA))","&person=").concat(t),a=(i=(0,fO.Ay)(t?o:null,d.lo)).data,u=i.error,s=i.isLoading,l=i.isValidating,c=(null==a||null==(n=a.data)||null==(r=n.results)?void 0:r.length)?function(e,t){var r=[],n=!0,o=!1,i=void 0;try{for(var a,u=t[Symbol.iterator]();!(n=(a=u.next()).done);n=!0){var s=a.value;e===s.personA.uuid?r.push({uuid:"".concat(s.uuid),display:s.personB.display,relativeAge:s.personB.age,relativeUuid:s.personB.uuid,relationshipType:s.relationshipType.bIsToA}):r.push({uuid:"".concat(s.uuid),display:s.personA.display,relativeAge:s.personA.age,relativeUuid:s.personA.uuid,relationshipType:s.relationshipType.aIsToB})}}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}return r}(t,a.data.results):null,{data:a?c:null,error:u,isLoading:s,isValidating:l}),p=f.data,m=f.isLoading;return(0,eh.jsxs)(eh.Fragment,{children:[(0,eh.jsx)("p",{className:hY.heading,children:(0,h.V)("relationships","Relationships")}),m?(0,eh.jsx)(eS.InlineLoading,{description:"".concat((0,h.V)("loading","Loading")," ..."),role:"progressbar"}):(0,eh.jsx)("ul",{children:p&&p.length>0?(0,eh.jsx)(eh.Fragment,{children:p.map(function(e){return(0,eh.jsxs)("li",{className:hY.relationship,children:[(0,eh.jsx)("div",{children:(0,eh.jsx)(L.i_,{to:"".concat(window.spaBase,"/patient/").concat(e.relativeUuid,"/chart"),children:e.display})}),(0,eh.jsx)("div",{children:e.relationshipType}),(0,eh.jsx)("div",{children:"".concat(e.relativeAge?e.relativeAge:"--"," ").concat(e.relativeAge?1===e.relativeAge?(0,h.V)("yearAbbreviation","yr"):(0,h.V)("yearsAbbreviation","yrs"):"")})]},e.uuid)})}):(0,eh.jsx)("li",{children:"--"})})]})};function h4(e){var t,r,n=e.patientId,o=e.deceased;return(0,eh.jsxs)("div",{className:ev()(hY.contactDetails,(t={},r=hY.deceased,r in t?Object.defineProperty(t,r,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[r]=o,t)),children:[(0,eh.jsxs)("div",{className:hY.row,children:[(0,eh.jsx)("div",{className:hY.col,children:(0,eh.jsx)(h1,{patientId:n})}),(0,eh.jsx)("div",{className:hY.col,children:(0,eh.jsx)(h2,{patientUuid:n})})]}),(0,eh.jsxs)("div",{className:hY.row,children:[(0,eh.jsx)("div",{className:hY.col,children:(0,eh.jsx)(h3,{patientId:n})}),(0,eh.jsx)("div",{className:hY.col,children:(0,eh.jsx)(h0,{patientUuid:n})})]})]})}function h6(e){var t=document.querySelector("template#loading-spinner");if(t){var r=t.content.cloneNode(!0),n=Array.prototype.map.call(r.childNodes,function(e){return e});return e.appendChild(r),function(){return n.forEach(function(e){return e.remove()})}}return function(){}}let h5="_6Gke0iocK8-7xF6UDXtjtQ==";function h8(e){var t=e.workspaceGroup,r=e.groupProps,n=(0,L.qv)(),o=t.persistence;return(0,eh.jsx)("aside",{className:"T2lMV3y-c2DH29-1sQdY7g==",children:(0,eh.jsxs)("div",{className:h5,children:["closable"==o&&(0,L.xl)(n)&&(0,eh.jsx)(eS.IconButton,{align:"left",onClick:function(){return h_()},label:(0,h.V)("close"),kind:"ghost",children:(0,eh.jsx)(te,{})}),(0,eh.jsx)(L.zq.Provider,{value:{moduleName:t.moduleName,featureName:t.name},children:(0,eh.jsx)(L.W3,{className:h5,name:t.name,state:{groupProps:r}})})]})})}function h7(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function h9(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function me(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){h9(i,n,o,a,u,"next",e)}function u(e){h9(i,n,o,a,u,"throw",e)}a(void 0)})}}function mt(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function mr(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}var mn=function(e){var t=e.lifeCycle,r=e.openedWorkspace,n=e.openedWindow,o=e.isRootWorkspace,i=e.isLeafWorkspace,a=e.showActionMenu,u=hI(),s=u.openedGroup,l=u.closeWorkspace,c=u.openChildWorkspace,d=(0,em.useMemo)(function(){return r&&{closeWorkspace:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return me(function(){var t,o,i,a,u,s;return mr(this,function(c){switch(c.label){case 0:if(o=void 0!==(t=e.closeWindow)&&t,a=void 0!==(i=e.discardUnsavedChanges)&&i,!o)return[3,3];if(u=a)return[3,2];return[4,hP({reason:"CLOSE_WINDOW",explicit:!0,windowName:n.windowName})];case 1:u=c.sent(),c.label=2;case 2:if(u)return l(n.openedWorkspaces[0].workspaceName),[2,!0];return[2,!1];case 3:if(s=a)return[3,5];return[4,hP({reason:"CLOSE_WORKSPACE",explicit:!0,windowName:n.windowName,workspaceName:r.workspaceName})];case 4:s=c.sent(),c.label=5;case 5:if(s)return l(r.workspaceName),[2,!0];return[2,!1];case 6:return[2]}})})()},launchChildWorkspace:function(e,t){return me(function(){var o,i,a;return mr(this,function(u){switch(u.label){case 0:if(o=r.workspaceName,-1===(a=(i=n.openedWorkspaces).findIndex(function(e){return e.workspaceName===o})))return[2];if(a===i.length-1||!i.slice(a+1).some(function(e){return e.hasUnsavedChanges}))return[3,2];return[4,hP({reason:"CLOSE_WORKSPACE",explicit:!0,windowName:n.windowName,workspaceName:i[a+1].workspaceName})];case 1:if(!u.sent())return[2];u.label=2;case 2:return c(o,e,t||{}),[2]}})})()},workspaceName:r.workspaceName,workspaceProps:r.props,windowProps:n.props,groupProps:s&&s.props?s.props:null,isRootWorkspace:o,isLeafWorkspace:i,windowName:n.windowName,showActionMenu:a}},[r,l,s,n]);if(!t){var f,p,m=F.J_.getState().registeredWorkspacesByName[r.workspaceName],y=m&&m.window?m.window:void 0,b=F.J_.getState().registeredWindowsByName,v=y?b[y]:void 0,g=v&&v.width?v.width:"narrow",w=Object.values(b).some(function(e){return e.group===(null==s?void 0:s.groupName)&&void 0!==e.icon});return(0,eh.jsxs)("div",{className:ev()(hN.workspaceOuterContainer,(mt(f={},hN.narrowWorkspace,"narrow"===g),mt(f,hN.widerWorkspace,"wider"===g),mt(f,hN.extraWideWorkspace,"extra-wide"===g),mt(f,hN.isActionMenuOpened,w),f)),children:[(0,eh.jsx)("div",{className:hN.workspaceSpacer}),(0,eh.jsx)("div",{className:ev()(hN.workspaceMiddleContainer,(mt(p={},hN.isRootWorkspace,o),mt(p,hN.showActionMenu,a),p)),children:(0,eh.jsx)("div",{className:ev()(hN.workspaceInnerContainer,mt({},hN.isRootWorkspace,o)),children:(0,eh.jsx)(eS.InlineLoading,{className:hN.loader,description:"".concat((0,h.V)("loading")," ...")})})})]})}return(0,eh.jsx)(hi,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){mt(e,t,r[t])})}return e}({config:t,mountParcel:U.mountRootParcel},d),r.workspaceName)};let mo=function(e){var t,r=e.openedWindow,n=e.showActionMenu,o=r.openedWorkspaces,i=function(e){if(Array.isArray(e))return e}(t=(0,em.useState)())||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return h7(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return h7(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),a=i[0],u=i[1],s=F.J_.getState().registeredWorkspacesByName;return(0,em.useEffect)(function(){Promise.all(o.map(function(e){var t=s[e.workspaceName];return H(t.moduleName,t.component)})).then(u)},[o]),(0,eh.jsx)(eh.Fragment,{children:o.map(function(e,t){return(0,eh.jsx)(mn,{openedWorkspace:e,openedWindow:r,lifeCycle:a&&a[t]?a[t]:void 0,isRootWorkspace:0===t,isLeafWorkspace:t===o.length-1,showActionMenu:n},e.uuid)})})};function mi(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ma(e){e&&(0,dB.createRoot)(e).render((0,eh.jsx)(mu,{}))}function mu(){var e,t=hI(),r=t.openedGroup,n=t.openedWindows,o=t.registeredGroupsByName,i=t.registeredWindowsByName;if((0,em.useEffect)(function(){return(0,A.$y)("before-page-changed",function(e){var t=e.newPage,n=e.cancelNavigation,i=e.oldUrl,a=e.newUrl;if(r){if(t)return void n(h_().then(function(e){return!e}));var u=o[r.groupName],s=null==u?void 0:u.scopePattern;s&&function(e,t,r){try{var n=new URL(t,window.location.origin).pathname,o=new URL(r,window.location.origin).pathname,i=new RegExp(e),a=n.match(i),u=o.match(i);if(!a||!u)return!0;if(a.length>1)return!a.slice(1).every(function(e,t){return e===u[t+1]});return!1}catch(e){return!0}}(s,i,a)&&n(h_().then(function(e){return!e}))}})},[r,o]),!r)return null;var a=o[r.groupName],u=n.some(function(e){return e.maximized}),s=a.name,l=Object.values(i).filter(function(e){return e.group===s&&void 0!==e.icon}).sort(function(e,t){var r,n;return(null!=(r=e.order)?r:Number.MAX_VALUE)-(null!=(n=t.order)?n:Number.MAX_VALUE)}).length>0;return(0,eh.jsxs)("div",{className:ev()("_2u2mcnHqn77Jo33H5a1H2g==",(mi(e={},"_7RHYZQ-hEc8EPJUY-c9Hpg==",a.overlay),mi(e,"gvJRdHcF9cqv2qaFk6opjw==",u),e)),children:[(0,eh.jsx)("div",{className:"_40ITOKKqqE8nvSQt409qiA==",children:n.map(function(e){return(0,eh.jsx)(mo,{openedWindow:e,showActionMenu:l},e.windowName)})}),l&&(0,eh.jsx)(h8,{workspaceGroup:a,groupProps:r.props})]})}var ms=r(2316);function ml(e){return!!e&&e.constructor===Object}var mc=r(8164);function md(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function mf(e){var t,r=function(e){if(Array.isArray(e))return e}(t=e.split("."))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),3!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return md(e,3);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return md(e,3)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),n=r[0],o=r[1],i=r[2];return"".concat(n,".").concat(o,".").concat(i)}function mp(e,t){var r=function(e){var t=e.indexOf("-");if(t>=0){var r=mf(e.slice(0,t)),n=e.slice(t+1);return"".concat(r,"-").concat(n)}return mf(e)}(t);return mc.satisfies(r,e,{includePrerelease:!0})}function mh(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function mm(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){mh(i,n,o,a,u,"next",e)}function u(e){mh(i,n,o,a,u,"throw",e)}a(void 0)})}}function my(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}function mb(e){return mm(function(e){var t,r,n,o,i,a,u,s=arguments;return my(this,function(l){switch(l.label){case 0:r=(t=s.length>1&&void 0!==s[1]?s[1]:{}).shouldRetry,n=t.getDelay,o=t.onError,r=null!=r?r:function(e){return e<=5},n=null!=n?n:function(e){return function(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return t*Math.pow(2,r?e+1:e)}(e,1e3)},i=0,a=void 0,l.label=1;case 1:var c;return l.trys.push([1,4,,5]),[4,(c=n(i),mm(function(){return my(this,function(e){return c<=0?[2]:[2,new Promise(function(e){return setTimeout(e,c)})]})})())];case 2:return l.sent(),[4,e()];case 3:return[2,l.sent()];case 4:return u=l.sent(),null==o||o(u,i),a=u,[3,5];case 5:if(r(i++))return[3,1];l.label=6;case 6:throw a}})}).apply(this,arguments)}},9726(e,t,r){"use strict";r.d(t,{$3:()=>y,FI:()=>h,LQ:()=>m,Vt:()=>b,Yt:()=>o,bJ:()=>v,bK:()=>g,dX:()=>w,ff:()=>l,gj:()=>i,ls:()=>E,pc:()=>s,sT:()=>a});var n="openmrs:connectivity-changed";function o(e){window.dispatchEvent(new CustomEvent(n,{detail:{online:e}}))}function i(e){if(!window.offlineEnabled)return function(){};var t=function(t){return e(t.detail)};return window.addEventListener(n,t),function(){return window.removeEventListener(n,t)}}function a(e){return e({online:!window.offlineEnabled||navigator.onLine}),i(e)}var u="openmrs:precache-static-dependencies";function s(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};window.dispatchEvent(new CustomEvent(u,{detail:e}))}function l(e){var t=function(t){return e(t.detail)};return window.addEventListener(u,t),function(){return window.removeEventListener(u,t)}}var c="openmrs:notification-shown",d="openmrs:actionable-notification-shown",f="openmrs:toast-shown",p="openmrs:snack-bar-shown";function h(e){window.dispatchEvent(new CustomEvent(c,{detail:e}))}function m(e){window.dispatchEvent(new CustomEvent(d,{detail:e}))}function y(e){window.dispatchEvent(new CustomEvent(p,{detail:e}))}function b(e){window.dispatchEvent(new CustomEvent(f,{detail:e}))}function v(e){var t=function(t){return e(t.detail)};return window.addEventListener(c,t),function(){return window.removeEventListener(c,t)}}function g(e){var t=function(t){return e(t.detail)};return window.addEventListener(d,t),function(){return window.removeEventListener(d,t)}}function w(e){var t=function(t){return e(t.detail)};return window.addEventListener(f,t),function(){return window.removeEventListener(f,t)}}function E(e){var t=function(t){return e(t.detail)};return window.addEventListener(p,t),function(){return window.removeEventListener(p,t)}}},7774(e,t,r){"use strict";r.d(t,{tA:()=>S,JK:()=>E,g4:()=>O,vf:()=>u,MY:()=>s,Wh:()=>w,qh:()=>p,lz:()=>l,D_:()=>f,JG:()=>m,oo:()=>b,zl:()=>y});var n=r(2992);function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function i(e){return function(e){if(Array.isArray(e))return o(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e){if(e){if("string"==typeof e)return o(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return o(e,void 0)}}(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var a=(0,r(2883).Zd)("breadcrumbs",[]);function u(e){return s([e])}function s(e){var t=l(),r=e.map(function(e){var t,r;return{matcher:(t=e.matcher,null!=(r=RegExp)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](t):t instanceof r)?e.matcher:"string"==typeof e.matcher?(0,n.pathToRegexp)(e.matcher).regexp:(0,n.pathToRegexp)(e.path).regexp,settings:e}}),o=i(t).concat(i(r));a.setState(o,!0)}function l(){return a.getState()}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function d(e,t){if(t){var r;return(function(e){if(Array.isArray(e))return e}(r=e.filter(function(e){return e.matcher.test(t)}))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),1!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(r)||function(e){if(e){if("string"==typeof e)return c(e,1);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return c(e,1)}}(r)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0]||function(e,t){for(var r=t.split("/");r.length>1;){r.pop();var n=d(e,r.join("/"));if(n)return n}}(e,t)}}function f(e,t){if(e.length>0){var r=d(e,t);if(r){for(var n=[r],o=d(e,r.settings.parent);void 0!==o;)n.push(o),o=d(e,o.settings.parent);return n.reverse()}}return[]}function p(e){return f(l(),e)}var h=r(480);function m(e,t){var r=window.getOpenmrsSpaBase().replace(/\/$/,"");return y(e,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({openmrsBase:window.openmrsBase,openmrsSpaBase:r},t)).replace(/^\/\//,"/")}function y(e,t){return Object.keys(t).reduce(function(e,r){return e.split("${"+r+"}").join(t[r])},e)}function b(e){var t=e.to,r=e.templateParams,n=window.getOpenmrsSpaBase().replace(/\/$/,""),o=m(t,r).replace(window.location.origin,"");o.startsWith(n)?(0,h.navigateToUrl)(o):window.location.assign(o)}var v="openmrs:history";function g(e){var t,r=JSON.parse(null!=(t=sessionStorage.getItem(v))?t:"[]")||[];r.push(e),r.length>50&&(r=r.slice(-50)),sessionStorage.setItem(v,JSON.stringify(r))}function w(){var e;0===JSON.parse(null!=(e=sessionStorage.getItem(v))?e:"[]").length&&document.referrer&&g(document.referrer),window.addEventListener("single-spa:routing-event",function(e){var t,r,n=E();(null==(t=e.detail.originalEvent)?void 0:t.singleSpaTrigger)=="replaceState"?(n[n.length-1]=window.location.href,sessionStorage.setItem(v,JSON.stringify(n))):!(null==(r=e.detail.originalEvent)?void 0:r.singleSpa)&&n.includes(window.location.href)?S({toUrl:window.location.href}):n[n.length-1]!==window.location.href&&g(window.location.href)})}function E(){var e;return JSON.parse(null!=(e=sessionStorage.getItem(v))?e:"[]")}function S(e){var t=e.toUrl,r=E(),n=r.lastIndexOf(t);if(-1!=n){var o=r.slice(0,n+1);b({to:r[n]}),sessionStorage.setItem(v,JSON.stringify(o))}else throw Error("URL ".concat(t," not found in history; cannot go back to it."))}function O(){sessionStorage.removeItem(v)}},7426(e,t,r){"use strict";let n;r.d(t,{nr:()=>k,xN:()=>no,u1:()=>nD,KG:()=>nk,FO:()=>ni,FE:()=>ng,LM:()=>r4,sA:()=>nc,Rs:()=>b,ff:()=>nS,wn:()=>nA,sK:()=>nI,lY:()=>na,ms:()=>S,Zr:()=>r7,WK:()=>nP,WA:()=>nw,UH:()=>v,cy:()=>nu,Gp:()=>nn,jU:()=>nl,Og:()=>P,iD:()=>nv,C$:()=>nr,qb:()=>nb,Iq:()=>r8,NU:()=>nO,sZ:()=>y,yD:()=>nE,Io:()=>r9,wJ:()=>C,JC:()=>w,e:()=>rZ,xc:()=>ne,pb:()=>nt,bO:()=>nd,AO:()=>r6,Td:()=>nx,Gj:()=>g});try{self["workbox:window:6.5.4"]&&_()}catch(e){}function o(e,t){return new Promise(function(r){var n=new MessageChannel;n.port1.onmessage=function(e){r(e.data)},e.postMessage(t,[n.port2])})}function i(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}try{self["workbox:core:6.5.4"]&&_()}catch(e){}var u=function(){var e=this;this.promise=new Promise(function(t,r){e.resolve=t,e.reject=r})};function s(e,t){var r=location.href;return new URL(e,r).href===new URL(t,r).href}var l=function(e,t){this.type=e,Object.assign(this,t)};function c(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}function d(){}var f={type:"SKIP_WAITING"};function p(e,t){if(!t)return e&&e.then?e.then(d):Promise.resolve()}var h=function(e){function t(t,r){var n,o;return void 0===r&&(r={}),(n=e.call(this)||this).nn={},n.tn=0,n.rn=new u,n.en=new u,n.on=new u,n.un=0,n.an=new Set,n.cn=function(){var e=n.fn,t=e.installing;n.tn>0||!s(t.scriptURL,n.sn.toString())||performance.now()>n.un+6e4?(n.vn=t,e.removeEventListener("updatefound",n.cn)):(n.hn=t,n.an.add(t),n.rn.resolve(t)),++n.tn,t.addEventListener("statechange",n.ln)},n.ln=function(e){var t=n.fn,r=e.target,o=r.state,i=r===n.vn,a={sw:r,isExternal:i,originalEvent:e};!i&&n.mn&&(a.isUpdate=!0),n.dispatchEvent(new l(o,a)),"installed"===o?n.wn=self.setTimeout(function(){"installed"===o&&t.waiting===r&&n.dispatchEvent(new l("waiting",a))},200):"activating"===o&&(clearTimeout(n.wn),i||n.en.resolve(r))},n.dn=function(e){var t=n.hn,r=t!==navigator.serviceWorker.controller;n.dispatchEvent(new l("controlling",{isExternal:r,originalEvent:e,sw:t,isUpdate:n.mn})),r||n.on.resolve(t)},o=function(e){var t=e.data,r=e.ports,o=e.source;return c(n.getSW(),function(){n.an.has(o)&&n.dispatchEvent(new l("message",{data:t,originalEvent:e,ports:r,sw:o}))})},n.gn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];try{return Promise.resolve(o.apply(this,e))}catch(e){return Promise.reject(e)}},n.sn=t,n.nn=r,navigator.serviceWorker.addEventListener("message",n.gn),n}t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e;var r,n,a=t.prototype;return a.register=function(e){var t=(void 0===e?{}:e).immediate,r=void 0!==t&&t;try{var n,o,i,a=this;return n=function(){if(!r&&"complete"!==document.readyState)return p(new Promise(function(e){return window.addEventListener("load",e)}))},o=function(){return a.mn=!!navigator.serviceWorker.controller,a.yn=a.pn(),c(a.bn(),function(e){a.fn=e,a.yn&&(a.hn=a.yn,a.en.resolve(a.yn),a.on.resolve(a.yn),a.yn.addEventListener("statechange",a.ln,{once:!0}));var t=a.fn.waiting;return t&&s(t.scriptURL,a.sn.toString())&&(a.hn=t,Promise.resolve().then(function(){a.dispatchEvent(new l("waiting",{sw:t,wasWaitingBeforeRegister:!0}))}).then(function(){})),a.hn&&(a.rn.resolve(a.hn),a.an.add(a.hn)),a.fn.addEventListener("updatefound",a.cn),navigator.serviceWorker.addEventListener("controllerchange",a.dn),a.fn})},(i=n())&&i.then?i.then(o):o(i)}catch(e){return Promise.reject(e)}},a.update=function(){try{return this.fn?p(this.fn.update()):void 0}catch(e){return Promise.reject(e)}},a.getSW=function(){return void 0!==this.hn?Promise.resolve(this.hn):this.rn.promise},a.messageSW=function(e){try{return c(this.getSW(),function(t){return o(t,e)})}catch(e){return Promise.reject(e)}},a.messageSkipWaiting=function(){this.fn&&this.fn.waiting&&o(this.fn.waiting,f)},a.pn=function(){var e=navigator.serviceWorker.controller;return e&&s(e.scriptURL,this.sn.toString())?e:void 0},a.bn=function(){try{var e=this;return function(e,t){try{var r=e()}catch(e){return t(e)}return r&&r.then?r.then(void 0,t):r}(function(){return c(navigator.serviceWorker.register(e.sn,e.nn),function(t){return e.un=performance.now(),t})},function(e){throw e})}catch(e){return Promise.reject(e)}},r=[{key:"active",get:function(){return this.en.promise}},{key:"controlling",get:function(){return this.on.promise}}],i(t.prototype,r),n&&i(t,n),t}(function(){function e(){this.Pn=new Map}var t=e.prototype;return t.addEventListener=function(e,t){this.Sn(e).add(t)},t.removeEventListener=function(e,t){this.Sn(e).delete(t)},t.dispatchEvent=function(e){e.target=this;for(var t,r=function(e){var t;if("u"<typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(t=function(e){if(e){if("string"==typeof e)return a(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?a(e,void 0):void 0}}(e))){t&&(e=t);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(t=e[Symbol.iterator]()).next.bind(t)}(this.Sn(e.type));!(t=r()).done;)(0,t.value)(e)},t.Sn=function(e){return this.Pn.has(e)||this.Pn.set(e,new Set),this.Pn.get(e)},e}()),m=void 0;function y(e,t){if(void 0!==m)return console.warn("The application's Service Worker has already been registered. The new service worker at ".concat(e," will not be registered.")),m;if(!("serviceWorker"in navigator))throw Error("Registering the Service Worker is not possible due to missing browser capabilities.");var r=new h(e,t);return m=r.register().then(function(){return r.controlling.then(function(){return r})})}function b(){return null!=m?m:Promise.resolve(void 0)}var v="x-omrs-offline-response-body",g="x-omrs-offline-response-status",w="x-omrs-offline-caching-strategy";function E(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function S(e){var t;return(t=function(){var t,r;return function(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(n){switch(n.label){case 0:return[4,b()];case 1:if(!(t=n.sent()))return[3,3];return[4,t.messageSW(e)];case 2:return r=n.sent(),[3,4];case 3:r={success:!1,result:void 0,error:"No service worker has been registered. This is typically the case when the application has been built without offline-related features."},n.label=4;case 4:return[2,r]}})},function(){var e=this,r=arguments;return new Promise(function(n,o){var i=t.apply(e,r);function a(e){E(i,n,o,a,u,"next",e)}function u(e){E(i,n,o,a,u,"throw",e)}a(void 0)})})()}function O(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function A(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){O(i,n,o,a,u,"next",e)}function u(e){O(i,n,o,a,u,"throw",e)}a(void 0)})}}function x(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}var D="openmrs3:offline-mode",j="unavailable";function C(){return{current:j,notAvailable:"unavailable"===j,active:"on"===j}}function P(e){"unavailable"!==j&&"unavailable"!==e&&(localStorage.setItem(D,"on"===e?"active":"disabled"),j=e)}function k(){return A(function(){return x(this,function(e){switch(e.label){case 0:return[4,A(function(){var e,t;return x(this,function(r){switch(r.label){case 0:return[4,A(function(){return x(this,function(e){return[2,new Promise(function(e){var t=indexedDB.open("test");t.onerror=function(){return e(!0)},t.onsuccess=function(){return e(!1)}})]})})()];case 1:if(t=r.sent())return[3,3];return[4,A(function(){return x(this,function(e){return[2,!window.indexedDB]})})()];case 2:t=r.sent(),r.label=3;case 3:if(e=t)return[3,5];return[4,A(function(){var e;return x(this,function(t){e=window.sessionStorage;try{e.setItem("someKeyHere","test"),e.removeItem("someKeyHere")}catch(t){if(t.code===DOMException.QUOTA_EXCEEDED_ERR&&0===e.length)return[2,!0]}return[2,!1]})})()];case 4:e=r.sent(),r.label=5;case 5:return[2,e]}})})()];case 1:return e.sent()||(j="active"===localStorage.getItem(D)?"on":"off"),navigator.onLine,[2]}})})()}let I="u">typeof globalThis?globalThis:"u">typeof self?self:"u">typeof window?window:global,T=Object.keys,R=Array.isArray;function F(e,t){return"object"!=typeof t||T(t).forEach(function(r){e[r]=t[r]}),e}"u"<typeof Promise||I.Promise||(I.Promise=Promise);let N=Object.getPrototypeOf,M={}.hasOwnProperty;function B(e,t){return M.call(e,t)}function L(e,t){"function"==typeof t&&(t=t(N(e))),("u"<typeof Reflect?T:Reflect.ownKeys)(t).forEach(r=>{U(e,r,t[r])})}let V=Object.defineProperty;function U(e,t,r,n){V(e,t,F(r&&B(r,"get")&&"function"==typeof r.get?{get:r.get,set:r.set,configurable:!0}:{value:r,configurable:!0,writable:!0},n))}function $(e){return{from:function(t){return e.prototype=Object.create(t.prototype),U(e.prototype,"constructor",e),{extend:L.bind(null,e.prototype)}}}}let W=Object.getOwnPropertyDescriptor;function z(e,t){let r;return W(e,t)||(r=N(e))&&z(r,t)}let K=[].slice;function H(e,t,r){return K.call(e,t,r)}function G(e,t){return t(e)}function q(e){if(!e)throw Error("Assertion Failed")}function Z(e){I.setImmediate?setImmediate(e):setTimeout(e,0)}function Y(e,t){return e.reduce((e,r,n)=>{var o=t(r,n);return o&&(e[o[0]]=o[1]),e},{})}function J(e,t){if(B(e,t))return e[t];if(!t)return e;if("string"!=typeof t){for(var r=[],n=0,o=t.length;n<o;++n){var i=J(e,t[n]);r.push(i)}return r}var a=t.indexOf(".");if(-1!==a){var u=e[t.substr(0,a)];return void 0===u?void 0:J(u,t.substr(a+1))}}function X(e,t,r){if(e&&void 0!==t&&(!("isFrozen"in Object)||!Object.isFrozen(e)))if("string"!=typeof t&&"length"in t){q("string"!=typeof r&&"length"in r);for(var n=0,o=t.length;n<o;++n)X(e,t[n],r[n])}else{var i=t.indexOf(".");if(-1!==i){var a=t.substr(0,i),u=t.substr(i+1);if(""===u)void 0===r?R(e)&&!isNaN(parseInt(a))?e.splice(a,1):delete e[a]:e[a]=r;else{var s=e[a];s&&B(e,a)||(s=e[a]={}),X(s,u,r)}}else void 0===r?R(e)&&!isNaN(parseInt(t))?e.splice(t,1):delete e[t]:e[t]=r}}function Q(e){var t={};for(var r in e)B(e,r)&&(t[r]=e[r]);return t}let ee=[].concat;function et(e){return ee.apply([],e)}let er="Boolean,String,Date,RegExp,Blob,File,FileList,FileSystemFileHandle,ArrayBuffer,DataView,Uint8ClampedArray,ImageBitmap,ImageData,Map,Set,CryptoKey".split(",").concat(et([8,16,32,64].map(e=>["Int","Uint","Float"].map(t=>t+e+"Array")))).filter(e=>I[e]),en=er.map(e=>I[e]);Y(er,e=>[e,!0]);let eo=null;function ei(e){eo="u">typeof WeakMap&&new WeakMap;let t=function e(t){if(!t||"object"!=typeof t)return t;let r=eo&&eo.get(t);if(r)return r;if(R(t)){r=[],eo&&eo.set(t,r);for(var n=0,o=t.length;n<o;++n)r.push(e(t[n]))}else if(en.indexOf(t.constructor)>=0)r=t;else{let n=N(t);for(var i in r=n===Object.prototype?{}:Object.create(n),eo&&eo.set(t,r),t)B(t,i)&&(r[i]=e(t[i]))}return r}(e);return eo=null,t}let{toString:ea}={};function eu(e){return ea.call(e).slice(8,-1)}let es="u">typeof Symbol?Symbol.iterator:"@@iterator",el="symbol"==typeof es?function(e){var t;return null!=e&&(t=e[es])&&t.apply(e)}:function(){return null},ec={};function ed(e){var t,r,n,o;if(1==arguments.length){if(R(e))return e.slice();if(this===ec&&"string"==typeof e)return[e];if(o=el(e)){for(r=[];!(n=o.next()).done;)r.push(n.value);return r}if(null==e)return[e];if("number"==typeof(t=e.length)){for(r=Array(t);t--;)r[t]=e[t];return r}return[e]}for(t=arguments.length,r=Array(t);t--;)r[t]=arguments[t];return r}let ef="u">typeof Symbol?e=>"AsyncFunction"===e[Symbol.toStringTag]:()=>!1;var ep="u">typeof location&&/^(http|https):\/\/(localhost|127\.0\.0\.1)/.test(location.href),eh=()=>!0;let em=!Error("").stack;function ey(){if(em)try{throw ey.arguments,Error()}catch(e){return e}return Error()}function eb(e,t){var r=e.stack;return r?(t=t||0,0===r.indexOf(e.name)&&(t+=(e.name+e.message).split("\n").length),r.split("\n").slice(t).filter(eh).map(e=>"\n"+e).join("")):""}var ev=["Unknown","Constraint","Data","TransactionInactive","ReadOnly","Version","NotFound","InvalidState","InvalidAccess","Abort","Timeout","QuotaExceeded","Syntax","DataClone"],eg=["Modify","Bulk","OpenFailed","VersionChange","Schema","Upgrade","InvalidTable","MissingAPI","NoSuchDatabase","InvalidArgument","SubTransaction","Unsupported","Internal","DatabaseClosed","PrematureCommit","ForeignAwait"].concat(ev),ew={VersionChanged:"Database version changed by other database connection",DatabaseClosed:"Database has been closed",Abort:"Transaction aborted",TransactionInactive:"Transaction has already completed or failed",MissingAPI:"IndexedDB API missing. Please visit https://tinyurl.com/y2uuvskb"};function eE(e,t){this._e=ey(),this.name=e,this.message=t}function eS(e,t){return e+". Errors: "+Object.keys(t).map(e=>t[e].toString()).filter((e,t,r)=>r.indexOf(e)===t).join("\n")}function eO(e,t,r,n){this._e=ey(),this.failures=t,this.failedKeys=n,this.successCount=r,this.message=eS(e,t)}function eA(e,t){this._e=ey(),this.name="BulkError",this.failures=Object.keys(t).map(e=>t[e]),this.failuresByPos=t,this.message=eS(e,t)}$(eE).from(Error).extend({stack:{get:function(){return this._stack||(this._stack=this.name+": "+this.message+eb(this._e,2))}},toString:function(){return this.name+": "+this.message}}),$(eO).from(eE),$(eA).from(eE);var ex=eg.reduce((e,t)=>(e[t]=t+"Error",e),{}),eD=eg.reduce((e,t)=>{var r=t+"Error";function n(e,n){this._e=ey(),this.name=r,e?"string"==typeof e?(this.message=`${e}${n?"\n "+n:""}`,this.inner=n||null):"object"==typeof e&&(this.message=`${e.name} ${e.message}`,this.inner=e):(this.message=ew[t]||r,this.inner=null)}return $(n).from(eE),e[t]=n,e},{});eD.Syntax=SyntaxError,eD.Type=TypeError,eD.Range=RangeError;var e_=ev.reduce((e,t)=>(e[t+"Error"]=eD[t],e),{}),ej=eg.reduce((e,t)=>(-1===["Syntax","Type","Range"].indexOf(t)&&(e[t+"Error"]=eD[t]),e),{});function eC(){}function eP(e){return e}function ek(e,t){return null==e||e===eP?t:function(r){return t(e(r))}}function eI(e,t){return function(){e.apply(this,arguments),t.apply(this,arguments)}}function eT(e,t){return e===eC?t:function(){var r=e.apply(this,arguments);void 0!==r&&(arguments[0]=r);var n=this.onsuccess,o=this.onerror;this.onsuccess=null,this.onerror=null;var i=t.apply(this,arguments);return n&&(this.onsuccess=this.onsuccess?eI(n,this.onsuccess):n),o&&(this.onerror=this.onerror?eI(o,this.onerror):o),void 0!==i?i:r}}function eR(e,t){return e===eC?t:function(){e.apply(this,arguments);var r=this.onsuccess,n=this.onerror;this.onsuccess=this.onerror=null,t.apply(this,arguments),r&&(this.onsuccess=this.onsuccess?eI(r,this.onsuccess):r),n&&(this.onerror=this.onerror?eI(n,this.onerror):n)}}function eF(e,t){return e===eC?t:function(r){var n=e.apply(this,arguments);F(r,n);var o=this.onsuccess,i=this.onerror;this.onsuccess=null,this.onerror=null;var a=t.apply(this,arguments);return o&&(this.onsuccess=this.onsuccess?eI(o,this.onsuccess):o),i&&(this.onerror=this.onerror?eI(i,this.onerror):i),void 0===n?void 0===a?void 0:a:F(n,a)}}function eN(e,t){return e===eC?t:function(){return!1!==t.apply(this,arguments)&&e.apply(this,arguments)}}function eM(e,t){return e===eC?t:function(){var r=e.apply(this,arguments);if(r&&"function"==typeof r.then){for(var n=this,o=arguments.length,i=Array(o);o--;)i[o]=arguments[o];return r.then(function(){return t.apply(n,i)})}return t.apply(this,arguments)}}ej.ModifyError=eO,ej.DexieError=eE,ej.BulkError=eA;var eB={};let[eL,eV,eU]="u"<typeof Promise?[]:(()=>{let e=Promise.resolve();if("u"<typeof crypto||!crypto.subtle)return[e,N(e),e];let t=crypto.subtle.digest("SHA-512",new Uint8Array([0]));return[t,N(t),e]})(),e$=eV&&eV.then,eW=eL&&eL.constructor,ez=!!eU;var eK=!1,eH=eU?()=>{eU.then(tn)}:I.setImmediate?setImmediate.bind(null,tn):I.MutationObserver?()=>{var e=document.createElement("div");new MutationObserver(()=>{tn(),e=null}).observe(e,{attributes:!0}),e.setAttribute("i","1")}:()=>{setTimeout(tn,0)},eG=function(e,t){e2.push([e,t]),eZ&&(eH(),eZ=!1)},eq=!0,eZ=!0,eY=[],eJ=[],eX=null,eQ=eP,e0={id:"global",global:!0,ref:0,unhandleds:[],onunhandled:tD,pgp:!1,env:{},finalize:function(){this.unhandleds.forEach(e=>{try{tD(e[0],e[1])}catch(e){}})}},e1=e0,e2=[],e3=0,e4=[];function e6(e){if("object"!=typeof this)throw TypeError("Promises must be constructed via new");this._listeners=[],this.onuncatched=eC,this._lib=!1;var t=this._PSD=e1;if(ep&&(this._stackHolder=ey(),this._prev=null,this._numPrev=0),"function"!=typeof e){if(e!==eB)throw TypeError("Not a function");return this._state=arguments[1],this._value=arguments[2],void(!1===this._state&&e7(this,this._value))}this._state=null,this._value=null,++t.ref,function e(t,r){try{r(r=>{if(null===t._state){if(r===t)throw TypeError("A promise cannot be resolved with itself.");var n=t._lib&&to();r&&"function"==typeof r.then?e(t,(e,t)=>{r instanceof e6?r._then(e,t):r.then(e,t)}):(t._state=!0,t._value=r,e9(t)),n&&ti()}},e7.bind(null,t))}catch(e){e7(t,e)}}(this,e)}let e5={get:function(){var e=e1,t=tp;function r(r,n){var o=!e.global&&(e!==e1||t!==tp);let i=o&&!tb();var a=new e6((t,a)=>{te(this,new e8(tA(r,e,o,i),tA(n,e,o,i),t,a,e))});return ep&&tr(a,this),a}return r.prototype=eB,r},set:function(e){U(this,"then",e&&e.prototype===eB?e5:{get:function(){return e},set:e5.set})}};function e8(e,t,r,n,o){this.onFulfilled="function"==typeof e?e:null,this.onRejected="function"==typeof t?t:null,this.resolve=r,this.reject=n,this.psd=o}function e7(e,t){if(eJ.push(t),null===e._state){var r=e._lib&&to();t=eQ(t),e._state=!1,e._value=t,ep&&null!==t&&"object"==typeof t&&!t._promise&&function(e){try{e.apply(null,void 0)}catch(e){}}(()=>{var r=z(t,"stack");t._promise=e,U(t,"stack",{get:()=>eK?r&&(r.get?r.get.apply(t):r.value):e.stack})}),eY.some(t=>t._value===e._value)||eY.push(e),e9(e),r&&ti()}}function e9(e){var t=e._listeners;e._listeners=[];for(var r=0,n=t.length;r<n;++r)te(e,t[r]);var o=e._PSD;--o.ref||o.finalize(),0===e3&&(++e3,eG(()=>{0==--e3&&ta()},[]))}function te(e,t){if(null!==e._state){var r=e._state?t.onFulfilled:t.onRejected;if(null===r)return(e._state?t.resolve:t.reject)(e._value);++t.psd.ref,++e3,eG(tt,[r,e,t])}else e._listeners.push(t)}function tt(e,t,r){try{eX=t;var n,o=t._value;t._state?n=e(o):(eJ.length&&(eJ=[]),n=e(o),-1===eJ.indexOf(o)&&function(e){for(var t=eY.length;t;)if(eY[--t]._value===e._value)return void eY.splice(t,1)}(t)),r.resolve(n)}catch(e){r.reject(e)}finally{eX=null,0==--e3&&ta(),--r.psd.ref||r.psd.finalize()}}function tr(e,t){var r=t?t._numPrev+1:0;r<100&&(e._prev=t,e._numPrev=r)}function tn(){to()&&ti()}function to(){var e=eq;return eq=!1,eZ=!1,e}function ti(){var e,t,r;do for(;e2.length>0;)for(e=e2,e2=[],r=e.length,t=0;t<r;++t){var n=e[t];n[0].apply(null,n[1])}while(e2.length>0);eq=!0,eZ=!0}function ta(){var e=eY;eY=[],e.forEach(e=>{e._PSD.onunhandled.call(null,e._value,e)});for(var t=e4.slice(0),r=t.length;r;)t[--r]()}function tu(e){return new e6(eB,!1,e)}function ts(e,t){var r=e1;return function(){var n=to(),o=e1;try{return tE(r,!0),e.apply(this,arguments)}catch(e){t&&t(e)}finally{tE(o,!1),n&&ti()}}}L(e6.prototype,{then:e5,_then:function(e,t){te(this,new e8(null,null,e,t,e1))},catch:function(e){if(1==arguments.length)return this.then(null,e);var t=arguments[0],r=arguments[1];return"function"==typeof t?this.then(null,e=>e instanceof t?r(e):tu(e)):this.then(null,e=>e&&e.name===t?r(e):tu(e))},finally:function(e){return this.then(t=>(e(),t),t=>(e(),tu(t)))},stack:{get:function(){if(this._stack)return this._stack;try{eK=!0;var e=(function e(t,r,n){if(r.length===n)return r;var o="";if(!1===t._state){var i,a,u=t._value;null!=u?(i=u.name||"Error",a=u.message||u,o=eb(u,0)):(i=u,a=""),r.push(i+(a?": "+a:"")+o)}return ep&&((o=eb(t._stackHolder,2))&&-1===r.indexOf(o)&&r.push(o),t._prev&&e(t._prev,r,n)),r})(this,[],20).join("\nFrom previous: ");return null!==this._state&&(this._stack=e),e}finally{eK=!1}}},timeout:function(e,t){return e<1/0?new e6((r,n)=>{var o=setTimeout(()=>n(new eD.Timeout(t)),e);this.then(r,n).finally(clearTimeout.bind(null,o))}):this}}),"u">typeof Symbol&&Symbol.toStringTag&&U(e6.prototype,Symbol.toStringTag,"Dexie.Promise"),e0.env=tS(),L(e6,{all:function(){var e=ed.apply(null,arguments).map(tv);return new e6(function(t,r){0===e.length&&t([]);var n=e.length;e.forEach((o,i)=>e6.resolve(o).then(r=>{e[i]=r,--n||t(e)},r))})},resolve:e=>{if(e instanceof e6)return e;if(e&&"function"==typeof e.then)return new e6((t,r)=>{e.then(t,r)});var t=new e6(eB,!0,e);return tr(t,eX),t},reject:tu,race:function(){var e=ed.apply(null,arguments).map(tv);return new e6((t,r)=>{e.map(e=>e6.resolve(e).then(t,r))})},PSD:{get:()=>e1,set:e=>e1=e},totalEchoes:{get:()=>tp},newPSD:tm,usePSD:tO,scheduler:{get:()=>eG,set:e=>{eG=e}},rejectionMapper:{get:()=>eQ,set:e=>{eQ=e}},follow:(e,t)=>new e6((r,n)=>tm((t,r)=>{var n=e1;n.unhandleds=[],n.onunhandled=r,n.finalize=eI(function(){var e;e=()=>{0===this.unhandleds.length?t():r(this.unhandleds[0])},e4.push(function t(){e(),e4.splice(e4.indexOf(t),1)}),++e3,eG(()=>{0==--e3&&ta()},[])},n.finalize),e()},t,r,n))}),eW&&(eW.allSettled&&U(e6,"allSettled",function(){let e=ed.apply(null,arguments).map(tv);return new e6(t=>{0===e.length&&t([]);let r=e.length,n=Array(r);e.forEach((e,o)=>e6.resolve(e).then(e=>n[o]={status:"fulfilled",value:e},e=>n[o]={status:"rejected",reason:e}).then(()=>--r||t(n)))})}),eW.any&&"u">typeof AggregateError&&U(e6,"any",function(){let e=ed.apply(null,arguments).map(tv);return new e6((t,r)=>{0===e.length&&r(AggregateError([]));let n=e.length,o=Array(n);e.forEach((e,i)=>e6.resolve(e).then(e=>t(e),e=>{o[i]=e,--n||r(AggregateError(o))}))})}));let tl={awaits:0,echoes:0,id:0};var tc=0,td=[],tf=0,tp=0,th=0;function tm(e,t,r,n){var o=e1,i=Object.create(o);i.parent=o,i.ref=0,i.global=!1,i.id=++th;var a=e0.env;i.env=ez?{Promise:e6,PromiseProp:{value:e6,configurable:!0,writable:!0},all:e6.all,race:e6.race,allSettled:e6.allSettled,any:e6.any,resolve:e6.resolve,reject:e6.reject,nthen:tx(a.nthen,i),gthen:tx(a.gthen,i)}:{},t&&F(i,t),++o.ref,i.finalize=function(){--this.parent.ref||this.parent.finalize()};var u=tO(i,e,r,n);return 0===i.ref&&i.finalize(),u}function ty(){return tl.id||(tl.id=++tc),++tl.awaits,tl.echoes+=100,tl.id}function tb(){return!!tl.awaits&&(0==--tl.awaits&&(tl.id=0),tl.echoes=100*tl.awaits,!0)}function tv(e){return tl.echoes&&e&&e.constructor===eW?(ty(),e.then(e=>(tb(),e),e=>(tb(),t_(e)))):e}function tg(e){++tp,tl.echoes&&0!=--tl.echoes||(tl.echoes=tl.id=0),td.push(e1),tE(e,!0)}function tw(){var e=td[td.length-1];td.pop(),tE(e,!1)}function tE(e,t){var r,n=e1;if((t?!tl.echoes||tf++&&e===e1:!tf||--tf&&e===e1)||(r=t?tg.bind(null,e):tw,e$.call(eL,r)),e!==e1&&(e1=e,n===e0&&(e0.env=tS()),ez)){var o=e0.env.Promise,i=e.env;eV.then=i.nthen,o.prototype.then=i.gthen,(n.global||e.global)&&(Object.defineProperty(I,"Promise",i.PromiseProp),o.all=i.all,o.race=i.race,o.resolve=i.resolve,o.reject=i.reject,i.allSettled&&(o.allSettled=i.allSettled),i.any&&(o.any=i.any))}}function tS(){var e=I.Promise;return ez?{Promise:e,PromiseProp:Object.getOwnPropertyDescriptor(I,"Promise"),all:e.all,race:e.race,allSettled:e.allSettled,any:e.any,resolve:e.resolve,reject:e.reject,nthen:eV.then,gthen:e.prototype.then}:{}}function tO(e,t,r,n,o){var i=e1;try{return tE(e,!0),t(r,n,o)}finally{tE(i,!1)}}function tA(e,t,r,n){return"function"!=typeof e?e:function(){var o,i=e1;r&&ty(),tE(t,!0);try{return e.apply(this,arguments)}finally{tE(i,!1),n&&(o=tb,e$.call(eL,o))}}}function tx(e,t){return function(r,n){return e.call(this,tA(r,t),tA(n,t))}}function tD(e,t){var r;try{r=t.onuncatched(e)}catch(e){}if(!1!==r)try{var n,o={promise:t,reason:e};if(I.document&&document.createEvent?((n=document.createEvent("Event")).initEvent("unhandledrejection",!0,!0),F(n,o)):I.CustomEvent&&F(n=new CustomEvent("unhandledrejection",{detail:o}),o),n&&I.dispatchEvent&&(dispatchEvent(n),!I.PromiseRejectionEvent&&I.onunhandledrejection))try{I.onunhandledrejection(n)}catch(e){}ep&&n&&!n.defaultPrevented&&console.warn(`Unhandled rejection: ${e.stack||e}`)}catch(e){}}-1===(""+e$).indexOf("[native code]")&&(ty=tb=eC);var t_=e6.reject;let tj=String.fromCharCode(65535),tC="Invalid key provided. Keys must be of type string, number, Date or Array<string | number | Date>.",tP=[],tk="u">typeof navigator&&/(MSIE|Trident|Edge)/.test(navigator.userAgent),tI=e=>!/(dexie\.js|dexie\.min\.js)/.test(e);function tT(e,t){return e?t?function(){return e.apply(this,arguments)&&t.apply(this,arguments)}:e:t}let tR={type:3,lower:-1/0,lowerOpen:!1,upper:[[]],upperOpen:!1};function tF(e){return"string"!=typeof e||/\./.test(e)?e=>e:t=>(void 0===t[e]&&e in t&&delete(t=ei(t))[e],t)}class tN{_trans(e,t,r){let n=this._tx||e1.trans,o=this.name;function i(e,r,n){if(!n.schema[o])throw new eD.NotFound("Table "+o+" not part of transaction");return t(n.idbtrans,n)}let a=to();try{return n&&n.db===this.db?n===e1.trans?n._promise(e,i,r):tm(()=>n._promise(e,i,r),{trans:n,transless:e1.transless||e1}):function e(t,r,n,o){if(t.idbdb&&(t._state.openComplete||e1.letThrough||t._vip)){var i=t._createTransaction(r,n,t._dbSchema);try{i.create(),t._state.PR1398_maxLoop=3}catch(i){return i.name===ex.InvalidState&&t.isOpen()&&--t._state.PR1398_maxLoop>0?(console.warn("Dexie: Need to reopen db"),t._close(),t.open().then(()=>e(t,r,n,o))):t_(i)}return i._promise(r,(e,t)=>tm(()=>(e1.trans=i,o(e,t,i)))).then(e=>i._completion.then(()=>e))}if(t._state.openComplete)return t_(new eD.DatabaseClosed(t._state.dbOpenError));if(!t._state.isBeingOpened){if(!t._options.autoOpen)return t_(new eD.DatabaseClosed);t.open().catch(eC)}return t._state.dbReadyPromise.then(()=>e(t,r,n,o))}(this.db,e,[this.name],i)}finally{a&&ti()}}get(e,t){return e&&e.constructor===Object?this.where(e).first(t):this._trans("readonly",t=>this.core.get({trans:t,key:e}).then(e=>this.hook.reading.fire(e))).then(t)}where(e){if("string"==typeof e)return new this.db.WhereClause(this,e);if(R(e))return new this.db.WhereClause(this,`[${e.join("+")}]`);let t=T(e);if(1===t.length)return this.where(t[0]).equals(e[t[0]]);let r=this.schema.indexes.concat(this.schema.primKey).filter(e=>e.compound&&t.every(t=>e.keyPath.indexOf(t)>=0)&&e.keyPath.every(e=>t.indexOf(e)>=0))[0];if(r&&this.db._maxKey!==tj)return this.where(r.name).equals(r.keyPath.map(t=>e[t]));!r&&ep&&console.warn(`The query ${JSON.stringify(e)} on ${this.name} would benefit of a compound index [${t.join("+")}]`);let{idxByName:n}=this.schema,o=this.db._deps.indexedDB;function i(e,t){try{return 0===o.cmp(e,t)}catch(e){return!1}}let[a,u]=t.reduce(([t,r],o)=>{let a=n[o],u=e[o];return[t||a,t||!a?tT(r,a&&a.multi?e=>{let t=J(e,o);return R(t)&&t.some(e=>i(u,e))}:e=>i(u,J(e,o))):r]},[null,null]);return a?this.where(a.name).equals(e[a.keyPath]).filter(u):r?this.filter(u):this.where(t).equals("")}filter(e){return this.toCollection().and(e)}count(e){return this.toCollection().count(e)}offset(e){return this.toCollection().offset(e)}limit(e){return this.toCollection().limit(e)}each(e){return this.toCollection().each(e)}toArray(e){return this.toCollection().toArray(e)}toCollection(){return new this.db.Collection(new this.db.WhereClause(this))}orderBy(e){return new this.db.Collection(new this.db.WhereClause(this,R(e)?`[${e.join("+")}]`:e))}reverse(){return this.toCollection().reverse()}mapToClass(e){this.schema.mappedClass=e;let t=t=>{if(!t)return t;let r=Object.create(e.prototype);for(var n in t)if(B(t,n))try{r[n]=t[n]}catch(e){}return r};return this.schema.readHook&&this.hook.reading.unsubscribe(this.schema.readHook),this.schema.readHook=t,this.hook("reading",t),e}defineClass(){return this.mapToClass(function(e){F(this,e)})}add(e,t){let{auto:r,keyPath:n}=this.schema.primKey,o=e;return n&&r&&(o=tF(n)(e)),this._trans("readwrite",e=>this.core.mutate({trans:e,type:"add",keys:null!=t?[t]:null,values:[o]})).then(e=>e.numFailures?e6.reject(e.failures[0]):e.lastResult).then(t=>{if(n)try{X(e,n,t)}catch(e){}return t})}update(e,t){if("object"!=typeof e||R(e))return this.where(":id").equals(e).modify(t);{let r=J(e,this.schema.primKey.keyPath);if(void 0===r)return t_(new eD.InvalidArgument("Given object does not contain its primary key"));try{"function"!=typeof t?T(t).forEach(r=>{X(e,r,t[r])}):t(e,{value:e,primKey:r})}catch(e){}return this.where(":id").equals(r).modify(t)}}put(e,t){let{auto:r,keyPath:n}=this.schema.primKey,o=e;return n&&r&&(o=tF(n)(e)),this._trans("readwrite",e=>this.core.mutate({trans:e,type:"put",values:[o],keys:null!=t?[t]:null})).then(e=>e.numFailures?e6.reject(e.failures[0]):e.lastResult).then(t=>{if(n)try{X(e,n,t)}catch(e){}return t})}delete(e){return this._trans("readwrite",t=>this.core.mutate({trans:t,type:"delete",keys:[e]})).then(e=>e.numFailures?e6.reject(e.failures[0]):void 0)}clear(){return this._trans("readwrite",e=>this.core.mutate({trans:e,type:"deleteRange",range:tR})).then(e=>e.numFailures?e6.reject(e.failures[0]):void 0)}bulkGet(e){return this._trans("readonly",t=>this.core.getMany({keys:e,trans:t}).then(e=>e.map(e=>this.hook.reading.fire(e))))}bulkAdd(e,t,r){let n=Array.isArray(t)?t:void 0,o=(r=r||(n?void 0:t))?r.allKeys:void 0;return this._trans("readwrite",t=>{let{auto:r,keyPath:i}=this.schema.primKey;if(i&&n)throw new eD.InvalidArgument("bulkAdd(): keys argument invalid on tables with inbound keys");if(n&&n.length!==e.length)throw new eD.InvalidArgument("Arguments objects and keys must have the same length");let a=e.length,u=i&&r?e.map(tF(i)):e;return this.core.mutate({trans:t,type:"add",keys:n,values:u,wantResults:o}).then(({numFailures:e,results:t,lastResult:r,failures:n})=>{if(0===e)return o?t:r;throw new eA(`${this.name}.bulkAdd(): ${e} of ${a} operations failed`,n)})})}bulkPut(e,t,r){let n=Array.isArray(t)?t:void 0,o=(r=r||(n?void 0:t))?r.allKeys:void 0;return this._trans("readwrite",t=>{let{auto:r,keyPath:i}=this.schema.primKey;if(i&&n)throw new eD.InvalidArgument("bulkPut(): keys argument invalid on tables with inbound keys");if(n&&n.length!==e.length)throw new eD.InvalidArgument("Arguments objects and keys must have the same length");let a=e.length,u=i&&r?e.map(tF(i)):e;return this.core.mutate({trans:t,type:"put",keys:n,values:u,wantResults:o}).then(({numFailures:e,results:t,lastResult:r,failures:n})=>{if(0===e)return o?t:r;throw new eA(`${this.name}.bulkPut(): ${e} of ${a} operations failed`,n)})})}bulkDelete(e){let t=e.length;return this._trans("readwrite",t=>this.core.mutate({trans:t,type:"delete",keys:e})).then(({numFailures:e,lastResult:r,failures:n})=>{if(0===e)return r;throw new eA(`${this.name}.bulkDelete(): ${e} of ${t} operations failed`,n)})}}function tM(e){var t={},r=function(r,n){if(n){for(var o=arguments.length,i=Array(o-1);--o;)i[o-1]=arguments[o];return t[r].subscribe.apply(null,i),e}if("string"==typeof r)return t[r]};r.addEventType=i;for(var n=1,o=arguments.length;n<o;++n)i(arguments[n]);return r;function i(e,n,o){if("object"==typeof e){var a;return void T(a=e).forEach(function(e){var t=a[e];if(R(t))i(e,a[e][0],a[e][1]);else{if("asap"!==t)throw new eD.InvalidArgument("Invalid event config");var r=i(e,eP,function(){for(var e=arguments.length,t=Array(e);e--;)t[e]=arguments[e];r.subscribers.forEach(function(e){Z(function(){e.apply(null,t)})})})}})}n||(n=eN),o||(o=eC);var u={subscribers:[],fire:o,subscribe:function(e){-1===u.subscribers.indexOf(e)&&(u.subscribers.push(e),u.fire=n(u.fire,e))},unsubscribe:function(e){u.subscribers=u.subscribers.filter(function(t){return t!==e}),u.fire=u.subscribers.reduce(n,o)}};return t[e]=r[e]=u,u}}function tB(e,t){return $(t).from({prototype:e}),t}function tL(e,t){return!(e.filter||e.algorithm||e.or)&&(t?e.justLimit:!e.replayFilter)}function tV(e,t){e.filter=tT(e.filter,t)}function tU(e,t,r){var n=e.replayFilter;e.replayFilter=n?()=>tT(n(),t()):t,e.justLimit=r&&!n}function t$(e,t){if(e.isPrimKey)return t.primaryKey;let r=t.getIndexByKeyPath(e.index);if(!r)throw new eD.Schema("KeyPath "+e.index+" on object store "+t.name+" is not indexed");return r}function tW(e,t,r){let n=t$(e,t.schema);return t.openCursor({trans:r,values:!e.keysOnly,reverse:"prev"===e.dir,unique:!!e.unique,query:{index:n,range:e.range}})}function tz(e,t,r,n){let o=e.replayFilter?tT(e.filter,e.replayFilter()):e.filter;if(e.or){let i={},a=(e,r,n)=>{if(!o||o(r,n,e=>r.stop(e),e=>r.fail(e))){var a=r.primaryKey,u=""+a;"[object ArrayBuffer]"===u&&(u=""+new Uint8Array(a)),B(i,u)||(i[u]=!0,t(e,r,n))}};return Promise.all([e.or._iterate(a,r),tK(tW(e,n,r),e.algorithm,a,!e.keysOnly&&e.valueMapper)])}return tK(tW(e,n,r),tT(e.algorithm,o),t,!e.keysOnly&&e.valueMapper)}function tK(e,t,r,n){var o=ts(n?(e,t,o)=>r(n(e),t,o):r);return e.then(e=>{if(e)return e.start(()=>{var r=()=>e.continue();t&&!t(e,e=>r=e,t=>{e.stop(t),r=eC},t=>{e.fail(t),r=eC})||o(e.value,e,e=>r=e),r()})})}function tH(e,t){try{let r=tG(e),n=tG(t);if(r!==n)return"Array"===r?1:"Array"===n?-1:"binary"===r?1:"binary"===n?-1:"string"===r?1:"string"===n?-1:"Date"===r?1:"Date"!==n?NaN:-1;switch(r){case"number":case"Date":case"string":return e>t?1:e<t?-1:0;case"binary":return function(e,t){let r=e.length,n=t.length,o=r<n?r:n;for(let r=0;r<o;++r)if(e[r]!==t[r])return e[r]<t[r]?-1:1;return r===n?0:r<n?-1:1}(tq(e),tq(t));case"Array":return function(e,t){let r=e.length,n=t.length,o=r<n?r:n;for(let r=0;r<o;++r){let n=tH(e[r],t[r]);if(0!==n)return n}return r===n?0:r<n?-1:1}(e,t)}}catch(e){}return NaN}function tG(e){let t=typeof e;if("object"!==t)return t;if(ArrayBuffer.isView(e))return"binary";let r=eu(e);return"ArrayBuffer"===r?"binary":r}function tq(e){return e instanceof Uint8Array?e:ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e)}class tZ{_read(e,t){var r=this._ctx;return r.error?r.table._trans(null,t_.bind(null,r.error)):r.table._trans("readonly",e).then(t)}_write(e){var t=this._ctx;return t.error?t.table._trans(null,t_.bind(null,t.error)):t.table._trans("readwrite",e,"locked")}_addAlgorithm(e){var t=this._ctx;t.algorithm=tT(t.algorithm,e)}_iterate(e,t){return tz(this._ctx,e,t,this._ctx.table.core)}clone(e){var t=Object.create(this.constructor.prototype),r=Object.create(this._ctx);return e&&F(r,e),t._ctx=r,t}raw(){return this._ctx.valueMapper=null,this}each(e){var t=this._ctx;return this._read(r=>tz(t,e,r,t.table.core))}count(e){return this._read(e=>{let t=this._ctx,r=t.table.core;if(tL(t,!0))return r.count({trans:e,query:{index:t$(t,r.schema),range:t.range}}).then(e=>Math.min(e,t.limit));var n=0;return tz(t,()=>(++n,!1),e,r).then(()=>n)}).then(e)}sortBy(e,t){let r=e.split(".").reverse(),n=r[0],o=r.length-1;function i(e,t){return t?i(e[r[t]],t-1):e[n]}var a="next"===this._ctx.dir?1:-1;function u(e,t){var r=i(e,o),n=i(t,o);return r<n?-a:r>n?a:0}return this.toArray(function(e){return e.sort(u)}).then(t)}toArray(e){return this._read(e=>{var t=this._ctx;if("next"===t.dir&&tL(t,!0)&&t.limit>0){let{valueMapper:r}=t,n=t$(t,t.table.core.schema);return t.table.core.query({trans:e,limit:t.limit,values:!0,query:{index:n,range:t.range}}).then(({result:e})=>r?e.map(r):e)}{let r=[];return tz(t,e=>r.push(e),e,t.table.core).then(()=>r)}},e)}offset(e){var t=this._ctx;return e<=0||(t.offset+=e,tL(t)?tU(t,()=>{var t=e;return(e,r)=>0===t||(1===t?--t:r(()=>{e.advance(t),t=0}),!1)}):tU(t,()=>{var t=e;return()=>--t<0})),this}limit(e){return this._ctx.limit=Math.min(this._ctx.limit,e),tU(this._ctx,()=>{var t=e;return function(e,r,n){return--t<=0&&r(n),t>=0}},!0),this}until(e,t){return tV(this._ctx,function(r,n,o){return!e(r.value)||(n(o),t)}),this}first(e){return this.limit(1).toArray(function(e){return e[0]}).then(e)}last(e){return this.reverse().first(e)}filter(e){var t;return tV(this._ctx,function(t){return e(t.value)}),(t=this._ctx).isMatch=tT(t.isMatch,e),this}and(e){return this.filter(e)}or(e){return new this.db.WhereClause(this._ctx.table,e,this)}reverse(){return this._ctx.dir="prev"===this._ctx.dir?"next":"prev",this._ondirectionchange&&this._ondirectionchange(this._ctx.dir),this}desc(){return this.reverse()}eachKey(e){var t=this._ctx;return t.keysOnly=!t.isMatch,this.each(function(t,r){e(r.key,r)})}eachUniqueKey(e){return this._ctx.unique="unique",this.eachKey(e)}eachPrimaryKey(e){var t=this._ctx;return t.keysOnly=!t.isMatch,this.each(function(t,r){e(r.primaryKey,r)})}keys(e){var t=this._ctx;t.keysOnly=!t.isMatch;var r=[];return this.each(function(e,t){r.push(t.key)}).then(function(){return r}).then(e)}primaryKeys(e){var t=this._ctx;if("next"===t.dir&&tL(t,!0)&&t.limit>0)return this._read(e=>{var r=t$(t,t.table.core.schema);return t.table.core.query({trans:e,values:!1,limit:t.limit,query:{index:r,range:t.range}})}).then(({result:e})=>e).then(e);t.keysOnly=!t.isMatch;var r=[];return this.each(function(e,t){r.push(t.primaryKey)}).then(function(){return r}).then(e)}uniqueKeys(e){return this._ctx.unique="unique",this.keys(e)}firstKey(e){return this.limit(1).keys(function(e){return e[0]}).then(e)}lastKey(e){return this.reverse().firstKey(e)}distinct(){var e=this._ctx,t=e.index&&e.table.schema.idxByName[e.index];if(!t||!t.multi)return this;var r={};return tV(this._ctx,function(e){var t=e.primaryKey.toString(),n=B(r,t);return r[t]=!0,!n}),this}modify(e){var t=this._ctx;return this._write(r=>{var n;if("function"==typeof e)n=e;else{var o=T(e),i=o.length;n=function(t){for(var r=!1,n=0;n<i;++n){var a=o[n],u=e[a];J(t,a)!==u&&(X(t,a,u),r=!0)}return r}}let a=t.table.core,{outbound:u,extractKey:s}=a.schema.primaryKey,l=this.db._options.modifyChunkSize||200,c=[],d=0,f=[],p=(e,t)=>{let{failures:r,numFailures:n}=t;for(let t of(d+=e-n,T(r)))c.push(r[t])};return this.clone().primaryKeys().then(o=>{let i=c=>{let d=Math.min(l,o.length-c);return a.getMany({trans:r,keys:o.slice(c,c+d),cache:"immutable"}).then(f=>{let h=[],m=[],y=u?[]:null,b=[];for(let e=0;e<d;++e){let t=f[e],r={value:ei(t),primKey:o[c+e]};!1!==n.call(r,r.value,r)&&(null==r.value?b.push(o[c+e]):u||0===tH(s(t),s(r.value))?(m.push(r.value),u&&y.push(o[c+e])):(b.push(o[c+e]),h.push(r.value)))}let v=tL(t)&&t.limit===1/0&&("function"!=typeof e||e===tY)&&{index:t.index,range:t.range};return Promise.resolve(h.length>0&&a.mutate({trans:r,type:"add",values:h}).then(e=>{for(let t in e.failures)b.splice(parseInt(t),1);p(h.length,e)})).then(()=>(m.length>0||v&&"object"==typeof e)&&a.mutate({trans:r,type:"put",keys:y,values:m,criteria:v,changeSpec:"function"!=typeof e&&e}).then(e=>p(m.length,e))).then(()=>(b.length>0||v&&e===tY)&&a.mutate({trans:r,type:"delete",keys:b,criteria:v}).then(e=>p(b.length,e))).then(()=>o.length>c+d&&i(c+l))})};return i(0).then(()=>{if(c.length>0)throw new eO("Error modifying one or more objects",c,d,f);return o.length})})})}delete(){var e=this._ctx,t=e.range;return tL(e)&&(e.isPrimKey&&!tk||3===t.type)?this._write(r=>{let{primaryKey:n}=e.table.core.schema;return e.table.core.count({trans:r,query:{index:n,range:t}}).then(n=>e.table.core.mutate({trans:r,type:"deleteRange",range:t}).then(({failures:e,lastResult:t,results:r,numFailures:o})=>{if(o)throw new eO("Could not delete some values",Object.keys(e).map(t=>e[t]),n-o);return n-o}))}):this.modify(tY)}}let tY=(e,t)=>t.value=null;function tJ(e,t){return e<t?-1:+(e!==t)}function tX(e,t){return e>t?-1:+(e!==t)}function tQ(e,t,r){var n=e instanceof t4?new e.Collection(e):e;return n._ctx.error=r?new r(t):TypeError(t),n}function t0(e){return new e.Collection(e,()=>t3("")).limit(0)}function t1(e,t,r,n){var o,i,a,u,s,l,c,d=r.length;if(!r.every(e=>"string"==typeof e))return tQ(e,"String expected.");function f(e){o="next"===e?e=>e.toUpperCase():e=>e.toLowerCase(),i="next"===e?e=>e.toLowerCase():e=>e.toUpperCase(),a="next"===e?tJ:tX;var t=r.map(function(e){return{lower:i(e),upper:o(e)}}).sort(function(e,t){return a(e.lower,t.lower)});u=t.map(function(e){return e.upper}),s=t.map(function(e){return e.lower}),l=e,c="next"===e?"":n}f("next");var p=new e.Collection(e,()=>t2(u[0],s[d-1]+n));p._ondirectionchange=function(e){f(e)};var h=0;return p._addAlgorithm(function(e,r,n){var o=e.key;if("string"!=typeof o)return!1;var f=i(o);if(t(f,s,h))return!0;for(var p=null,m=h;m<d;++m){var y=function(e,t,r,n,o,i){for(var a=Math.min(e.length,n.length),u=-1,s=0;s<a;++s){var l=t[s];if(l!==n[s])return 0>o(e[s],r[s])?e.substr(0,s)+r[s]+r.substr(s+1):0>o(e[s],n[s])?e.substr(0,s)+n[s]+r.substr(s+1):u>=0?e.substr(0,u)+t[u]+r.substr(u+1):null;0>o(e[s],l)&&(u=s)}return a<n.length&&"next"===i?e+r.substr(e.length):a<e.length&&"prev"===i?e.substr(0,r.length):u<0?null:e.substr(0,u)+n[u]+r.substr(u+1)}(o,f,u[m],s[m],a,l);null===y&&null===p?h=m+1:(null===p||a(p,y)>0)&&(p=y)}return r(null!==p?function(){e.continue(p+c)}:n),!1}),p}function t2(e,t,r,n){return{type:2,lower:e,upper:t,lowerOpen:r,upperOpen:n}}function t3(e){return{type:1,lower:e,upper:e}}class t4{get Collection(){return this._ctx.table.db.Collection}between(e,t,r,n){r=!1!==r,n=!0===n;try{return this._cmp(e,t)>0||0===this._cmp(e,t)&&(r||n)&&(!r||!n)?t0(this):new this.Collection(this,()=>t2(e,t,!r,!n))}catch(e){return tQ(this,tC)}}equals(e){return null==e?tQ(this,tC):new this.Collection(this,()=>t3(e))}above(e){return null==e?tQ(this,tC):new this.Collection(this,()=>t2(e,void 0,!0))}aboveOrEqual(e){return null==e?tQ(this,tC):new this.Collection(this,()=>t2(e,void 0,!1))}below(e){return null==e?tQ(this,tC):new this.Collection(this,()=>t2(void 0,e,!1,!0))}belowOrEqual(e){return null==e?tQ(this,tC):new this.Collection(this,()=>t2(void 0,e))}startsWith(e){return"string"!=typeof e?tQ(this,"String expected."):this.between(e,e+tj,!0,!0)}startsWithIgnoreCase(e){return""===e?this.startsWith(e):t1(this,(e,t)=>0===e.indexOf(t[0]),[e],tj)}equalsIgnoreCase(e){return t1(this,(e,t)=>e===t[0],[e],"")}anyOfIgnoreCase(){var e=ed.apply(ec,arguments);return 0===e.length?t0(this):t1(this,(e,t)=>-1!==t.indexOf(e),e,"")}startsWithAnyOfIgnoreCase(){var e=ed.apply(ec,arguments);return 0===e.length?t0(this):t1(this,(e,t)=>t.some(t=>0===e.indexOf(t)),e,tj)}anyOf(){let e=ed.apply(ec,arguments),t=this._cmp;try{e.sort(t)}catch(e){return tQ(this,tC)}if(0===e.length)return t0(this);let r=new this.Collection(this,()=>t2(e[0],e[e.length-1]));r._ondirectionchange=r=>{t="next"===r?this._ascending:this._descending,e.sort(t)};let n=0;return r._addAlgorithm((r,o,i)=>{let a=r.key;for(;t(a,e[n])>0;)if(++n===e.length)return o(i),!1;return 0===t(a,e[n])||(o(()=>{r.continue(e[n])}),!1)}),r}notEqual(e){return this.inAnyRange([[-1/0,e],[e,this.db._maxKey]],{includeLowers:!1,includeUppers:!1})}noneOf(){let e=ed.apply(ec,arguments);if(0===e.length)return new this.Collection(this);try{e.sort(this._ascending)}catch(e){return tQ(this,tC)}let t=e.reduce((e,t)=>e?e.concat([[e[e.length-1][1],t]]):[[-1/0,t]],null);return t.push([e[e.length-1],this.db._maxKey]),this.inAnyRange(t,{includeLowers:!1,includeUppers:!1})}inAnyRange(e,t){let r=this._cmp,n=this._ascending,o=this._descending,i=this._min,a=this._max;if(0===e.length)return t0(this);if(!e.every(e=>void 0!==e[0]&&void 0!==e[1]&&0>=n(e[0],e[1])))return tQ(this,"First argument to inAnyRange() must be an Array of two-value Arrays [lower,upper] where upper must not be lower than lower",eD.InvalidArgument);let u=!t||!1!==t.includeLowers,s=t&&!0===t.includeUppers,l,c=n;function d(e,t){return c(e[0],t[0])}try{(l=e.reduce(function(e,t){let n=0,o=e.length;for(;n<o;++n){let o=e[n];if(0>r(t[0],o[1])&&r(t[1],o[0])>0){o[0]=i(o[0],t[0]),o[1]=a(o[1],t[1]);break}}return n===o&&e.push(t),e},[])).sort(d)}catch(e){return tQ(this,tC)}let f=0,p=s?e=>n(e,l[f][1])>0:e=>n(e,l[f][1])>=0,h=u?e=>o(e,l[f][0])>0:e=>o(e,l[f][0])>=0,m=p,y=new this.Collection(this,()=>t2(l[0][0],l[l.length-1][1],!u,!s));return y._ondirectionchange=e=>{"next"===e?(m=p,c=n):(m=h,c=o),l.sort(d)},y._addAlgorithm((e,t,r)=>{for(var o=e.key;m(o);)if(++f===l.length)return t(r),!1;return!!(!p(o)&&!h(o))||(0===this._cmp(o,l[f][1])||0===this._cmp(o,l[f][0])||t(()=>{c===n?e.continue(l[f][0]):e.continue(l[f][1])}),!1)}),y}startsWithAnyOf(){let e=ed.apply(ec,arguments);return e.every(e=>"string"==typeof e)?0===e.length?t0(this):this.inAnyRange(e.map(e=>[e,e+tj])):tQ(this,"startsWithAnyOf() only works with strings")}}function t6(e){return ts(function(t){return t5(t),e(t.target.error),!1})}function t5(e){e.stopPropagation&&e.stopPropagation(),e.preventDefault&&e.preventDefault()}let t8=tM(null,"storagemutated");class t7{_lock(){return q(!e1.global),++this._reculock,1!==this._reculock||e1.global||(e1.lockOwnerFor=this),this}_unlock(){if(q(!e1.global),0==--this._reculock)for(e1.global||(e1.lockOwnerFor=null);this._blockedFuncs.length>0&&!this._locked();){var e=this._blockedFuncs.shift();try{tO(e[1],e[0])}catch(e){}}return this}_locked(){return this._reculock&&e1.lockOwnerFor!==this}create(e){if(!this.mode)return this;let t=this.db.idbdb,r=this.db._state.dbOpenError;if(q(!this.idbtrans),!e&&!t)switch(r&&r.name){case"DatabaseClosedError":throw new eD.DatabaseClosed(r);case"MissingAPIError":throw new eD.MissingAPI(r.message,r);default:throw new eD.OpenFailed(r)}if(!this.active)throw new eD.TransactionInactive;return q(null===this._completion._state),(e=this.idbtrans=e||(this.db.core?this.db.core.transaction(this.storeNames,this.mode,{durability:this.chromeTransactionDurability}):t.transaction(this.storeNames,this.mode,{durability:this.chromeTransactionDurability}))).onerror=ts(t=>{t5(t),this._reject(e.error)}),e.onabort=ts(t=>{t5(t),this.active&&this._reject(new eD.Abort(e.error)),this.active=!1,this.on("abort").fire(t)}),e.oncomplete=ts(()=>{this.active=!1,this._resolve(),"mutatedParts"in e&&t8.storagemutated.fire(e.mutatedParts)}),this}_promise(e,t,r){if("readwrite"===e&&"readwrite"!==this.mode)return t_(new eD.ReadOnly("Transaction is readonly"));if(!this.active)return t_(new eD.TransactionInactive);if(this._locked())return new e6((n,o)=>{this._blockedFuncs.push([()=>{this._promise(e,t,r).then(n,o)},e1])});if(r)return tm(()=>{var e=new e6((e,r)=>{this._lock();let n=t(e,r,this);n&&n.then&&n.then(e,r)});return e.finally(()=>this._unlock()),e._lib=!0,e});var n=new e6((e,r)=>{var n=t(e,r,this);n&&n.then&&n.then(e,r)});return n._lib=!0,n}_root(){return this.parent?this.parent._root():this}waitFor(e){var t=this._root();let r=e6.resolve(e);if(t._waitingFor)t._waitingFor=t._waitingFor.then(()=>r);else{t._waitingFor=r,t._waitingQueue=[];var n=t.idbtrans.objectStore(t.storeNames[0]);!function e(){for(++t._spinCount;t._waitingQueue.length;)t._waitingQueue.shift()();t._waitingFor&&(n.get(-1/0).onsuccess=e)}()}var o=t._waitingFor;return new e6((e,n)=>{r.then(r=>t._waitingQueue.push(ts(e.bind(null,r))),e=>t._waitingQueue.push(ts(n.bind(null,e)))).finally(()=>{t._waitingFor===o&&(t._waitingFor=null)})})}abort(){this.active&&(this.active=!1,this.idbtrans&&this.idbtrans.abort(),this._reject(new eD.Abort))}table(e){let t=this._memoizedTables||(this._memoizedTables={});if(B(t,e))return t[e];let r=this.schema[e];if(!r)throw new eD.NotFound("Table "+e+" not part of transaction");let n=new this.db.Table(e,r,this);return n.core=this.db.core.table(e),t[e]=n,n}}function t9(e,t,r,n,o,i,a){return{name:e,keyPath:t,unique:r,multi:n,auto:o,compound:i,src:(r&&!a?"&":"")+(n?"*":"")+(o?"++":"")+re(t)}}function re(e){return"string"==typeof e?e:e?"["+[].join.call(e,"+")+"]":""}function rt(e,t,r){return{name:e,primKey:t,indexes:r,mappedClass:null,idxByName:Y(r,e=>[e.name,e])}}let rr=e=>{try{return e.only([[]]),rr=()=>[[]],[[]]}catch(e){return rr=()=>tj,tj}};function rn(e){return null==e?()=>{}:"string"==typeof e?1===e.split(".").length?t=>t[e]:t=>J(t,e):t=>J(t,e)}function ro(e){return[].slice.call(e)}let ri=0;function ra(e){return null==e?":id":"string"==typeof e?e:`[${e.join("+")}]`}function ru({_novip:e},t){let r=t.db,n=function(e,t,{IDBKeyRange:r,indexedDB:n},o){var i;return{dbcore:(i=function(e,t,r){let n;function o(e){if(3===e.type)return null;if(4===e.type)throw Error("Cannot convert never type to IDBKeyRange");let{lower:r,upper:n,lowerOpen:o,upperOpen:i}=e;return void 0===r?void 0===n?null:t.upperBound(n,!!i):void 0===n?t.lowerBound(r,!!o):t.bound(r,n,!!o,!!i)}let{schema:i,hasGetAll:a}=(n=ro(e.objectStoreNames),{schema:{name:e.name,tables:n.map(e=>r.objectStore(e)).map(e=>{let{keyPath:t,autoIncrement:r}=e,n=R(t),o=null==t,i={},a={name:e.name,primaryKey:{name:null,isPrimaryKey:!0,outbound:o,compound:n,keyPath:t,autoIncrement:r,unique:!0,extractKey:rn(t)},indexes:ro(e.indexNames).map(t=>e.index(t)).map(e=>{let{name:t,unique:r,multiEntry:n,keyPath:o}=e,a={name:t,compound:R(o),keyPath:o,unique:r,multiEntry:n,extractKey:rn(o)};return i[ra(o)]=a,a}),getIndexByKeyPath:e=>i[ra(e)]};return i[":id"]=a.primaryKey,null!=t&&(i[ra(t)]=a.primaryKey),a})},hasGetAll:n.length>0&&"getAll"in r.objectStore(n[0])&&!("u">typeof navigator&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604)}),u=i.tables.map(e=>{let t;return{name:t=e.name,schema:e,mutate:function({trans:e,type:r,keys:n,values:i,range:a}){return new Promise((u,s)=>{let l;u=ts(u);let c=e.objectStore(t),d=null==c.keyPath,f="put"===r||"add"===r;if(!f&&"delete"!==r&&"deleteRange"!==r)throw Error("Invalid operation type: "+r);let{length:p}=n||i||{length:1};if(n&&i&&n.length!==i.length)throw Error("Given keys array must have same length as given values array.");if(0===p)return u({numFailures:0,failures:{},results:[],lastResult:void 0});let h=[],m=[],y=0,b=e=>{++y,t5(e)};if("deleteRange"===r){if(4===a.type)return u({numFailures:y,failures:m,results:[],lastResult:void 0});3===a.type?h.push(l=c.clear()):h.push(l=c.delete(o(a)))}else{let[e,t]=f?d?[i,n]:[i,null]:[n,null];if(f)for(let n=0;n<p;++n)h.push(l=t&&void 0!==t[n]?c[r](e[n],t[n]):c[r](e[n])),l.onerror=b;else for(let t=0;t<p;++t)h.push(l=c[r](e[t])),l.onerror=b}let v=e=>{let t=e.target.result;h.forEach((e,t)=>null!=e.error&&(m[t]=e.error)),u({numFailures:y,failures:m,results:"delete"===r?n:h.map(e=>e.result),lastResult:t})};l.onerror=e=>{b(e),v(e)},l.onsuccess=v})},getMany:({trans:e,keys:r})=>new Promise((n,o)=>{n=ts(n);let i=e.objectStore(t),a=r.length,u=Array(a),s,l=0,c=0,d=e=>{let t=e.target;u[t._pos]=t.result,++c===l&&n(u)},f=t6(o);for(let e=0;e<a;++e)null!=r[e]&&((s=i.get(r[e]))._pos=e,s.onsuccess=d,s.onerror=f,++l);0===l&&n(u)}),get:({trans:e,key:r})=>new Promise((n,o)=>{n=ts(n);let i=e.objectStore(t).get(r);i.onsuccess=e=>n(e.target.result),i.onerror=t6(o)}),query:e=>new Promise((r,n)=>{r=ts(r);let{trans:i,values:u,limit:s,query:l}=e,c=s===1/0?void 0:s,{index:d,range:f}=l,p=i.objectStore(t),h=d.isPrimaryKey?p:p.index(d.name),m=o(f);if(0===s)return r({result:[]});if(a){let e=u?h.getAll(m,c):h.getAllKeys(m,c);e.onsuccess=e=>r({result:e.target.result}),e.onerror=t6(n)}else{let e=0,t=!u&&"openKeyCursor"in h?h.openKeyCursor(m):h.openCursor(m),o=[];t.onsuccess=n=>{let i=t.result;return i?(o.push(u?i.value:i.primaryKey),++e===s?r({result:o}):void i.continue()):r({result:o})},t.onerror=t6(n)}}),openCursor:function({trans:e,values:r,query:n,reverse:i,unique:a}){return new Promise((u,s)=>{u=ts(u);let{index:l,range:c}=n,d=e.objectStore(t),f=l.isPrimaryKey?d:d.index(l.name),p=i?a?"prevunique":"prev":a?"nextunique":"next",h=!r&&"openKeyCursor"in f?f.openKeyCursor(o(c),p):f.openCursor(o(c),p);h.onerror=t6(s),h.onsuccess=ts(t=>{let r=h.result;if(!r)return void u(null);r.___id=++ri,r.done=!1;let n=r.continue.bind(r),o=r.continuePrimaryKey;o&&(o=o.bind(r));let i=r.advance.bind(r),a=()=>{throw Error("Cursor not stopped")};r.trans=e,r.stop=r.continue=r.continuePrimaryKey=r.advance=()=>{throw Error("Cursor not started")},r.fail=ts(s),r.next=function(){let e=1;return this.start(()=>e--?this.continue():this.stop()).then(()=>this)},r.start=e=>{let t=new Promise((e,t)=>{e=ts(e),h.onerror=t6(t),r.fail=t,r.stop=t=>{r.stop=r.continue=r.continuePrimaryKey=r.advance=a,e(t)}}),u=()=>{if(h.result)try{e()}catch(e){r.fail(e)}else r.done=!0,r.start=()=>{throw Error("Cursor behind last entry")},r.stop()};return h.onsuccess=ts(e=>{h.onsuccess=u,u()}),r.continue=n,r.continuePrimaryKey=o,r.advance=i,u(),t},u(r)},s)})},count({query:e,trans:r}){let{index:n,range:i}=e;return new Promise((e,a)=>{let u=r.objectStore(t),s=n.isPrimaryKey?u:u.index(n.name),l=o(i),c=l?s.count(l):s.count();c.onsuccess=ts(t=>e(t.target.result)),c.onerror=t6(a)})}}}),s={};return u.forEach(e=>s[e.name]=e),{stack:"dbcore",transaction:e.transaction.bind(e),table(e){if(!s[e])throw Error(`Table '${e}' not found`);return s[e]},MIN_KEY:-1/0,MAX_KEY:rr(t),schema:i}}(t,r,o),e.dbcore.reduce((e,{create:t})=>({...e,...t(e)}),i))}}(e._middlewares,r,e._deps,t);e.core=n.dbcore,e.tables.forEach(t=>{let r=t.name;e.core.schema.tables.some(e=>e.name===r)&&(t.core=e.core.table(r),e[r]instanceof e.Table&&(e[r].core=t.core))})}function rs({_novip:e},t,r,n){r.forEach(r=>{let o=n[r];t.forEach(t=>{let n=z(t,r);(!n||"value"in n&&void 0===n.value)&&(t===e.Transaction.prototype||t instanceof e.Transaction?U(t,r,{get(){return this.table(r)},set(e){V(this,r,{value:e,writable:!0,configurable:!0,enumerable:!0})}}):t[r]=new e.Table(r,o))})})}function rl({_novip:e},t){t.forEach(t=>{for(let r in t)t[r]instanceof e.Table&&delete t[r]})}function rc(e,t){return e._cfg.version-t._cfg.version}function rd(e,t){let r,n={del:[],add:[],change:[]};for(r in e)t[r]||n.del.push(r);for(r in t){let o=e[r],i=t[r];if(o){let e={name:r,def:i,recreate:!1,del:[],add:[],change:[]};if(""+(o.primKey.keyPath||"")==""+(i.primKey.keyPath||"")&&(o.primKey.auto===i.primKey.auto||tk)){let t,r=o.idxByName,a=i.idxByName;for(t in r)a[t]||e.del.push(t);for(t in a){let n=r[t],o=a[t];n?n.src!==o.src&&e.change.push(o):e.add.push(o)}(e.del.length>0||e.add.length>0||e.change.length>0)&&n.change.push(e)}else e.recreate=!0,n.change.push(e)}else n.add.push([r,i])}return n}function rf(e,t,r,n){let o=e.db.createObjectStore(t,r.keyPath?{keyPath:r.keyPath,autoIncrement:r.auto}:{autoIncrement:r.auto});return n.forEach(e=>rp(o,e)),o}function rp(e,t){e.createIndex(t.name,t.keyPath,{unique:t.unique,multiEntry:t.multi})}function rh(e,t,r){let n={};return H(t.objectStoreNames,0).forEach(e=>{let t=r.objectStore(e),o=t.keyPath,i=t9(re(o),o||"",!1,!1,!!t.autoIncrement,o&&"string"!=typeof o,!0),a=[];for(let e=0;e<t.indexNames.length;++e){let r=t.index(t.indexNames[e]);o=r.keyPath;var u=t9(r.name,o,!!r.unique,!!r.multiEntry,!1,o&&"string"!=typeof o,!1);a.push(u)}n[e]=rt(e,i,a)}),n}function rm({_novip:e},t,r){let n=r.db.objectStoreNames;for(let o=0;o<n.length;++o){let i=n[o],a=r.objectStore(i);e._hasGetAll="getAll"in a;for(let e=0;e<a.indexNames.length;++e){let r=a.indexNames[e],n=a.index(r).keyPath,o="string"==typeof n?n:"["+H(n).join("+")+"]";if(t[i]){let e=t[i].idxByName[o];e&&(e.name=r,delete t[i].idxByName[o],t[i].idxByName[r]=e)}}}"u">typeof navigator&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&I.WorkerGlobalScope&&I instanceof I.WorkerGlobalScope&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604&&(e._hasGetAll=!1)}class ry{_parseStoresSpec(e,t){T(e).forEach(r=>{if(null!==e[r]){var n=e[r].split(",").map((e,t)=>{let r=(e=e.trim()).replace(/([&*]|\+\+)/g,""),n=/^\[/.test(r)?r.match(/^\[(.*)\]$/)[1].split("+"):r;return t9(r,n||null,/\&/.test(e),/\*/.test(e),/\+\+/.test(e),R(n),0===t)}),o=n.shift();if(o.multi)throw new eD.Schema("Primary key cannot be multi-valued");n.forEach(e=>{if(e.auto)throw new eD.Schema("Only primary key can be marked as autoIncrement (++)");if(!e.keyPath)throw new eD.Schema("Index must have a name and cannot be an empty string")}),t[r]=rt(r,o,n)}})}stores(e){let t=this.db;this._cfg.storesSource=this._cfg.storesSource?F(this._cfg.storesSource,e):e;let r=t._versions,n={},o={};return r.forEach(e=>{F(n,e._cfg.storesSource),o=e._cfg.dbschema={},e._parseStoresSpec(n,o)}),t._dbSchema=o,rl(t,[t._allTables,t,t.Transaction.prototype]),rs(t,[t._allTables,t,t.Transaction.prototype,this._cfg.tables],T(o),o),t._storeNames=T(o),this}upgrade(e){return this._cfg.contentUpgrade=eM(this._cfg.contentUpgrade||eC,e),this}}function rb(e,t){let r=e._dbNamesDB;return r||(r=e._dbNamesDB=new rN("__dbnames",{addons:[],indexedDB:e,IDBKeyRange:t})).version(1).stores({dbnames:"name"}),r.table("dbnames")}function rv(e){return e&&"function"==typeof e.databases}function rg(e){return tm(function(){return e1.letThrough=!0,e()})}function rw(e){var t=t=>e.next(t),r=o(t),n=o(t=>e.throw(t));function o(e){return t=>{var o=e(t),i=o.value;return o.done?i:i&&"function"==typeof i.then?i.then(r,n):R(i)?Promise.all(i).then(r,n):r(i)}}return o(t)()}function rE(e,t,r){var n=arguments.length;if(n<2)throw new eD.InvalidArgument("Too few arguments");for(var o=Array(n-1);--n;)o[n-1]=arguments[n];return r=o.pop(),[e,et(o),r]}function rS(e,t,r){let n=R(e)?e.slice():[e];for(let e=0;e<r;++e)n.push(t);return n}let rO={stack:"dbcore",name:"VirtualIndexMiddleware",level:1,create:function(e){return{...e,table(t){let r=e.table(t),{schema:n}=r,o={},i=[];function a(e,t,r){let n=ra(e),u=o[n]=o[n]||[],s=null==e?0:"string"==typeof e?1:e.length,l=t>0,c={...r,isVirtual:l,keyTail:t,keyLength:s,extractKey:rn(e),unique:!l&&r.unique};return u.push(c),c.isPrimaryKey||i.push(c),s>1&&a(2===s?e[0]:e.slice(0,s-1),t+1,r),u.sort((e,t)=>e.keyTail-t.keyTail),c}let u=a(n.primaryKey.keyPath,0,n.primaryKey);for(let e of(o[":id"]=[u],n.indexes))a(e.keyPath,0,e);function s(t){var r,n;let o=t.query.index;return o.isVirtual?{...t,query:{index:o,range:(r=t.query.range,n=o.keyTail,{type:1===r.type?2:r.type,lower:rS(r.lower,r.lowerOpen?e.MAX_KEY:e.MIN_KEY,n),lowerOpen:!0,upper:rS(r.upper,r.upperOpen?e.MIN_KEY:e.MAX_KEY,n),upperOpen:!0})}}:t}return{...r,schema:{...n,primaryKey:u,indexes:i,getIndexByKeyPath:function(e){let t=o[ra(e)];return t&&t[0]}},count:e=>r.count(s(e)),query:e=>r.query(s(e)),openCursor(t){let{keyTail:n,isVirtual:o,keyLength:i}=t.query.index;return o?r.openCursor(s(t)).then(r=>r&&Object.create(r,{continue:{value:function(o){null!=o?r.continue(rS(o,t.reverse?e.MAX_KEY:e.MIN_KEY,n)):t.unique?r.continue(r.key.slice(0,i).concat(t.reverse?e.MIN_KEY:e.MAX_KEY,n)):r.continue()}},continuePrimaryKey:{value(t,o){r.continuePrimaryKey(rS(t,e.MAX_KEY,n),o)}},primaryKey:{get:()=>r.primaryKey},key:{get(){let e=r.key;return 1===i?e[0]:e.slice(0,i)}},value:{get:()=>r.value}})):r.openCursor(t)}}}}}};function rA(e,t,r,n){return r=r||{},n=n||"",T(e).forEach(o=>{if(B(t,o)){var i=e[o],a=t[o];if("object"==typeof i&&"object"==typeof a&&i&&a){let e=eu(i);e!==eu(a)?r[n+o]=t[o]:"Object"===e?rA(i,a,r,n+o+"."):i!==a&&(r[n+o]=t[o])}else i!==a&&(r[n+o]=t[o])}else r[n+o]=void 0}),T(t).forEach(o=>{B(e,o)||(r[n+o]=t[o])}),r}let rx={stack:"dbcore",name:"HooksMiddleware",level:2,create:e=>({...e,table(t){let r=e.table(t),{primaryKey:n}=r.schema;return{...r,mutate(e){let o=e1.trans,{deleting:i,creating:a,updating:u}=o.table(t).hook;switch(e.type){case"add":if(a.fire===eC)break;return o._promise("readwrite",()=>s(e),!0);case"put":if(a.fire===eC&&u.fire===eC)break;return o._promise("readwrite",()=>s(e),!0);case"delete":if(i.fire===eC)break;return o._promise("readwrite",()=>s(e),!0);case"deleteRange":if(i.fire===eC)break;return o._promise("readwrite",()=>(function e(t,o,i){return r.query({trans:t,values:!1,query:{index:n,range:o},limit:i}).then(({result:r})=>s({type:"delete",keys:r,trans:t}).then(n=>n.numFailures>0?Promise.reject(n.failures[0]):r.length<i?{failures:[],numFailures:0,lastResult:void 0}:e(t,{...o,lower:r[r.length-1],lowerOpen:!0},i)))})(e.trans,e.range,1e4),!0)}return r.mutate(e);function s(e){var t,o;let s=e1.trans,l=e.keys||("delete"===(t=e).type?t.keys:t.keys||t.values.map(n.extractKey));if(!l)throw Error("Keys missing");return"delete"!==(e="add"===e.type||"put"===e.type?{...e,keys:l}:{...e}).type&&(e.values=[...e.values]),e.keys&&(e.keys=[...e.keys]),("add"===(o=e).type?Promise.resolve([]):r.getMany({trans:o.trans,keys:l,cache:"immutable"})).then(t=>{let o=l.map((r,o)=>{let l=t[o],c={onerror:null,onsuccess:null};if("delete"===e.type)i.fire.call(c,r,l,s);else if("add"===e.type||void 0===l){let t=a.fire.call(c,r,e.values[o],s);null==r&&null!=t&&(r=t,e.keys[o]=r,n.outbound||X(e.values[o],n.keyPath,r))}else{let t=rA(l,e.values[o]),n=u.fire.call(c,t,r,l,s);if(n){let t=e.values[o];Object.keys(n).forEach(e=>{B(t,e)?t[e]=n[e]:X(t,e,n[e])})}}return c});return r.mutate(e).then(({failures:r,results:n,numFailures:i,lastResult:a})=>{for(let i=0;i<l.length;++i){let a=n?n[i]:l[i],u=o[i];null==a?u.onerror&&u.onerror(r[i]):u.onsuccess&&u.onsuccess("put"===e.type&&t[i]?e.values[i]:a)}return{failures:r,results:n,numFailures:i,lastResult:a}}).catch(e=>(o.forEach(t=>t.onerror&&t.onerror(e)),Promise.reject(e)))})}}}}})};function rD(e,t,r){try{if(!t||t.keys.length<e.length)return null;let n=[];for(let o=0,i=0;o<t.keys.length&&i<e.length;++o)0===tH(t.keys[o],e[i])&&(n.push(r?ei(t.values[o]):t.values[o]),++i);return n.length===e.length?n:null}catch(e){return null}}let r_={stack:"dbcore",level:-1,create:e=>({table:t=>{let r=e.table(t);return{...r,getMany:e=>{if(!e.cache)return r.getMany(e);let t=rD(e.keys,e.trans._cache,"clone"===e.cache);return t?e6.resolve(t):r.getMany(e).then(t=>(e.trans._cache={keys:e.keys,values:"clone"===e.cache?ei(t):t},t))},mutate:e=>("add"!==e.type&&(e.trans._cache=null),r.mutate(e))}}})};function rj(e){return!("from"in e)}let rC=function(e,t){if(!this){let t=new rC;return e&&"d"in e&&F(t,e),t}F(this,arguments.length?{d:1,from:e,to:arguments.length>1?t:e}:{d:0})};function rP(e,t,r){let n=tH(t,r);if(isNaN(n))return;if(n>0)throw RangeError();if(rj(e))return F(e,{from:t,to:r,d:1});let o=e.l,i=e.r;if(0>tH(r,e.from))return o?rP(o,t,r):e.l={from:t,to:r,d:1,l:null,r:null},rT(e);if(tH(t,e.to)>0)return i?rP(i,t,r):e.r={from:t,to:r,d:1,l:null,r:null},rT(e);0>tH(t,e.from)&&(e.from=t,e.l=null,e.d=i?i.d+1:1),tH(r,e.to)>0&&(e.to=r,e.r=null,e.d=e.l?e.l.d+1:1);let a=!e.r;o&&!e.l&&rk(e,o),i&&a&&rk(e,i)}function rk(e,t){rj(t)||function e(t,{from:r,to:n,l:o,r:i}){rP(t,r,n),o&&e(t,o),i&&e(t,i)}(e,t)}function rI(e){let t=rj(e)?null:{s:0,n:e};return{next(e){let r=arguments.length>0;for(;t;)switch(t.s){case 0:if(t.s=1,r)for(;t.n.l&&0>tH(e,t.n.from);)t={up:t,n:t.n.l,s:1};else for(;t.n.l;)t={up:t,n:t.n.l,s:1};case 1:if(t.s=2,!r||0>=tH(e,t.n.to))return{value:t.n,done:!1};case 2:if(t.n.r){t.s=3,t={up:t,n:t.n.r,s:0};continue}case 3:t=t.up}return{done:!0}}}}function rT(e){var t,r;let n=((null==(t=e.r)?void 0:t.d)||0)-((null==(r=e.l)?void 0:r.d)||0),o=n>1?"r":n<-1?"l":"";if(o){let t="r"===o?"l":"r",r={...e},n=e[o];e.from=n.from,e.to=n.to,e[o]=n[o],r[o]=n[t],e[t]=r,r.d=rR(r)}e.d=rR(e)}function rR({r:e,l:t}){return(e?t?Math.max(e.d,t.d):e.d:t?t.d:0)+1}L(rC.prototype,{add(e){return rk(this,e),this},addKey(e){return rP(this,e,e),this},addKeys(e){return e.forEach(e=>rP(this,e,e)),this},[es](){return rI(this)}});let rF={stack:"dbcore",level:0,create:e=>{let t=e.schema.name,r=new rC(e.MIN_KEY,e.MAX_KEY);return{...e,table:n=>{let o=e.table(n),{schema:i}=o,{primaryKey:a}=i,{extractKey:u,outbound:s}=a,l={...o,mutate:e=>{let a=e.trans,u=a.mutatedParts||(a.mutatedParts={}),s=e=>{let r=`idb://${t}/${n}/${e}`;return u[r]||(u[r]=new rC)},l=s(""),c=s(":dels"),{type:d}=e,[f,p]="deleteRange"===e.type?[e.range]:"delete"===e.type?[e.keys]:e.values.length<50?[[],e.values]:[],h=e.trans._cache;return o.mutate(e).then(e=>{if(R(f)){"delete"!==d&&(f=e.results),l.addKeys(f);let t=rD(f,h);t||"add"===d||c.addKeys(f),(t||p)&&i.indexes.forEach(function(e){let r=s(e.name||"");function n(t){return null!=t?e.extractKey(t):null}let o=t=>e.multiEntry&&R(t)?t.forEach(e=>r.addKey(e)):r.addKey(t);(t||p).forEach((e,r)=>{let i=t&&n(t[r]),a=p&&n(p[r]);0!==tH(i,a)&&(null!=i&&o(i),null!=a&&o(a))})})}else if(f){let e={from:f.lower,to:f.upper};c.add(e),l.add(e)}else l.add(r),c.add(r),i.indexes.forEach(e=>s(e.name).add(r));return e})}},c=({query:{index:t,range:r}})=>{var n,o;return[t,new rC(null!=(n=r.lower)?n:e.MIN_KEY,null!=(o=r.upper)?o:e.MAX_KEY)]},d={get:e=>[a,new rC(e.key)],getMany:e=>[a,(new rC).addKeys(e.keys)],count:c,query:c,openCursor:c};return T(d).forEach(e=>{l[e]=function(i){let{subscr:a}=e1;if(a){let l=e=>{let r=`idb://${t}/${n}/${e}`;return a[r]||(a[r]=new rC)},c=l(""),f=l(":dels"),[p,h]=d[e](i);if(l(p.name||"").add(h),!p.isPrimaryKey){if("count"!==e){let t="query"===e&&s&&i.values&&o.query({...i,values:!1});return o[e].apply(this,arguments).then(r=>{if("query"===e){if(s&&i.values)return t.then(({result:e})=>(c.addKeys(e),r));let e=i.values?r.result.map(u):r.result;i.values?c.addKeys(e):f.addKeys(e)}else if("openCursor"===e){let e=i.values;return r&&Object.create(r,{key:{get:()=>(f.addKey(r.primaryKey),r.key)},primaryKey:{get(){let e=r.primaryKey;return f.addKey(e),e}},value:{get:()=>(e&&c.addKey(r.primaryKey),r.value)}})}return r})}f.add(r)}}return o[e].apply(this,arguments)}}),l}}}};class rN{constructor(e,t){var r;this._middlewares={},this.verno=0;const n=rN.dependencies;this._options=t={addons:rN.addons,autoOpen:!0,indexedDB:n.indexedDB,IDBKeyRange:n.IDBKeyRange,...t},this._deps={indexedDB:t.indexedDB,IDBKeyRange:t.IDBKeyRange};const{addons:o}=t;this._dbSchema={},this._versions=[],this._storeNames=[],this._allTables={},this.idbdb=null,this._novip=this;const i={dbOpenError:null,isBeingOpened:!1,onReadyBeingFired:null,openComplete:!1,dbReadyResolve:eC,dbReadyPromise:null,cancelOpen:eC,openCanceller:null,autoSchema:!0,PR1398_maxLoop:3};i.dbReadyPromise=new e6(e=>{i.dbReadyResolve=e}),i.openCanceller=new e6((e,t)=>{i.cancelOpen=t}),this._state=i,this.name=e,this.on=tM(this,"populate","blocked","versionchange","close",{ready:[eM,eC]}),this.on.ready.subscribe=G(this.on.ready.subscribe,e=>(t,r)=>{rN.vip(()=>{let n=this._state;if(n.openComplete)n.dbOpenError||e6.resolve().then(t),r&&e(t);else if(n.onReadyBeingFired)n.onReadyBeingFired.push(t),r&&e(t);else{e(t);let n=this;r||e(function e(){n.on.ready.unsubscribe(t),n.on.ready.unsubscribe(e)})}})}),this.Collection=(r=this,tB(tZ.prototype,function(e,t){this.db=r;let n=tR,o=null;if(t)try{n=t()}catch(e){o=e}let i=e._ctx,a=i.table,u=a.hook.reading.fire;this._ctx={table:a,index:i.index,isPrimKey:!i.index||a.schema.primKey.keyPath&&i.index===a.schema.primKey.name,range:n,keysOnly:!1,dir:"next",unique:"",algorithm:null,filter:null,replayFilter:null,justLimit:!0,isMatch:null,offset:0,limit:1/0,error:o,or:i.or,valueMapper:u!==eP?u:null}})),this.Table=function(e){return tB(tN.prototype,function(t,r,n){this.db=e,this._tx=n,this.name=t,this.schema=r,this.hook=e._allTables[t]?e._allTables[t].hook:tM(null,{creating:[eT,eC],reading:[ek,eP],updating:[eF,eC],deleting:[eR,eC]})})}(this),this.Transaction=function(e){return tB(t7.prototype,function(t,r,n,o,i){this.db=e,this.mode=t,this.storeNames=r,this.schema=n,this.chromeTransactionDurability=o,this.idbtrans=null,this.on=tM(this,"complete","error","abort"),this.parent=i||null,this.active=!0,this._reculock=0,this._blockedFuncs=[],this._resolve=null,this._reject=null,this._waitingFor=null,this._waitingQueue=null,this._spinCount=0,this._completion=new e6((e,t)=>{this._resolve=e,this._reject=t}),this._completion.then(()=>{this.active=!1,this.on.complete.fire()},e=>{var t=this.active;return this.active=!1,this.on.error.fire(e),this.parent?this.parent._reject(e):t&&this.idbtrans&&this.idbtrans.abort(),t_(e)})})}(this),this.Version=function(e){return tB(ry.prototype,function(t){this.db=e,this._cfg={version:t,storesSource:null,dbschema:{},tables:{},contentUpgrade:null}})}(this),this.WhereClause=function(e){return tB(t4.prototype,function(t,r,n){this.db=e,this._ctx={table:t,index:":id"===r?null:r,or:n};let o=e._deps.indexedDB;if(!o)throw new eD.MissingAPI;this._cmp=this._ascending=o.cmp.bind(o),this._descending=(e,t)=>o.cmp(t,e),this._max=(e,t)=>o.cmp(e,t)>0?e:t,this._min=(e,t)=>0>o.cmp(e,t)?e:t,this._IDBKeyRange=e._deps.IDBKeyRange})}(this),this.on("versionchange",e=>{e.newVersion>0?console.warn(`Another connection wants to upgrade database '${this.name}'. Closing db now to resume the upgrade.`):console.warn(`Another connection wants to delete database '${this.name}'. Closing db now to resume the delete request.`),this.close()}),this.on("blocked",e=>{!e.newVersion||e.newVersion<e.oldVersion?console.warn(`Dexie.delete('${this.name}') was blocked`):console.warn(`Upgrade '${this.name}' blocked by other connection holding version ${e.oldVersion/10}`)}),this._maxKey=rr(t.IDBKeyRange),this._createTransaction=(e,t,r,n)=>new this.Transaction(e,t,r,this._options.chromeTransactionDurability,n),this._fireOnBlocked=e=>{this.on("blocked").fire(e),tP.filter(e=>e.name===this.name&&e!==this&&!e._state.vcFired).map(t=>t.on("versionchange").fire(e))},this.use(rO),this.use(rx),this.use(rF),this.use(r_),this.vip=Object.create(this,{_vip:{value:!0}}),o.forEach(e=>e(this))}version(e){if(isNaN(e)||e<.1)throw new eD.Type("Given version is not a positive number");if(e=Math.round(10*e)/10,this.idbdb||this._state.isBeingOpened)throw new eD.Schema("Cannot add version when database is open");this.verno=Math.max(this.verno,e);let t=this._versions;var r=t.filter(t=>t._cfg.version===e)[0];return r||(r=new this.Version(e),t.push(r),t.sort(rc),r.stores({}),this._state.autoSchema=!1,r)}_whenReady(e){return this.idbdb&&(this._state.openComplete||e1.letThrough||this._vip)?e():new e6((e,t)=>{if(this._state.openComplete)return t(new eD.DatabaseClosed(this._state.dbOpenError));if(!this._state.isBeingOpened){if(!this._options.autoOpen)return void t(new eD.DatabaseClosed);this.open().catch(eC)}this._state.dbReadyPromise.then(e,t)}).then(e)}use({stack:e,create:t,level:r,name:n}){n&&this.unuse({stack:e,name:n});let o=this._middlewares[e]||(this._middlewares[e]=[]);return o.push({stack:e,create:t,level:null==r?10:r,name:n}),o.sort((e,t)=>e.level-t.level),this}unuse({stack:e,name:t,create:r}){return e&&this._middlewares[e]&&(this._middlewares[e]=this._middlewares[e].filter(e=>r?e.create!==r:!!t&&e.name!==t)),this}open(){return function(e){var t;let r=e._state,{indexedDB:n}=e._deps;if(r.isBeingOpened||e.idbdb)return r.dbReadyPromise.then(()=>r.dbOpenError?t_(r.dbOpenError):e);ep&&(r.openCanceller._stackHolder=ey()),r.isBeingOpened=!0,r.dbOpenError=null,r.openComplete=!1;let o=r.openCanceller;function i(){if(r.openCanceller!==o)throw new eD.DatabaseClosed("db.open() was cancelled")}let a=r.dbReadyResolve,u=null,s=!1;return e6.race([o,("u"<typeof navigator?e6.resolve():!navigator.userAgentData&&/Safari\//.test(navigator.userAgent)&&!/Chrom(e|ium)\//.test(navigator.userAgent)&&indexedDB.databases?new Promise(function(e){var r=function(){return indexedDB.databases().finally(e)};t=setInterval(r,100),r()}).finally(function(){return clearInterval(t)}):Promise.resolve()).then(()=>new e6((t,o)=>{if(i(),!n)throw new eD.MissingAPI;let a=e.name,l=r.autoSchema?n.open(a):n.open(a,Math.round(10*e.verno));if(!l)throw new eD.MissingAPI;l.onerror=t6(o),l.onblocked=ts(e._fireOnBlocked),l.onupgradeneeded=ts(t=>{if(u=l.transaction,r.autoSchema&&!e._options.allowEmptyDB){l.onerror=t5,u.abort(),l.result.close();let e=n.deleteDatabase(a);e.onsuccess=e.onerror=ts(()=>{o(new eD.NoSuchDatabase(`Database ${a} doesnt exist`))})}else{let r,n,a,f;u.onerror=t6(o);var i,c,d=t.oldVersion>0x4000000000000000?0:t.oldVersion;s=d<1,e._novip.idbdb=l.result,i=d/10,c=u,r=e._dbSchema,(n=e._createTransaction("readwrite",e._storeNames,r)).create(c),n._completion.catch(o),a=n._reject.bind(n),f=e1.transless||e1,tm(()=>{e1.trans=n,e1.transless=f,0===i?(T(r).forEach(e=>{rf(c,e,r[e].primKey,r[e].indexes)}),ru(e,c),e6.follow(()=>e.on.populate.fire(n)).catch(a)):(function({_novip:e},t,r,n){let o=[],i=e._versions,a=e._dbSchema=rh(e,e.idbdb,n),u=!1;return i.filter(e=>e._cfg.version>=t).forEach(i=>{o.push(()=>{let o=a,s=i._cfg.dbschema;rm(e,o,n),rm(e,s,n),a=e._dbSchema=s;let l=rd(o,s);l.add.forEach(e=>{rf(n,e[0],e[1].primKey,e[1].indexes)}),l.change.forEach(e=>{if(e.recreate)throw new eD.Upgrade("Not yet support for changing primary key");{let t=n.objectStore(e.name);e.add.forEach(e=>rp(t,e)),e.change.forEach(e=>{t.deleteIndex(e.name),rp(t,e)}),e.del.forEach(e=>t.deleteIndex(e))}});let c=i._cfg.contentUpgrade;if(c&&i._cfg.version>t){let t;ru(e,n),r._memoizedTables={},u=!0;let i=Q(s);l.del.forEach(e=>{i[e]=o[e]}),rl(e,[e.Transaction.prototype]),rs(e,[e.Transaction.prototype],T(i),i),r.schema=i;let a=ef(c);a&&ty();let d=e6.follow(()=>{if((t=c(r))&&a){var e=tb.bind(null,null);t.then(e,e)}});return t&&"function"==typeof t.then?e6.resolve(t):d.then(()=>t)}}),o.push(t=>{var n;u&&tk||(n=i._cfg.dbschema,[].slice.call(t.db.objectStoreNames).forEach(e=>null==n[e]&&t.db.deleteObjectStore(e))),rl(e,[e.Transaction.prototype]),rs(e,[e.Transaction.prototype],e._storeNames,e._dbSchema),r.schema=e._dbSchema})}),(function e(){return o.length?e6.resolve(o.shift()(r.idbtrans)).then(e):e6.resolve()})().then(()=>{var e;T(e=a).forEach(t=>{n.db.objectStoreNames.contains(t)||rf(n,t,e[t].primKey,e[t].indexes)})})})(e,i,n,c).catch(a)})}},o),l.onsuccess=ts(()=>{u=null;let n=e._novip.idbdb=l.result,o=H(n.objectStoreNames);if(o.length>0)try{let t,i=n.transaction(1===o.length?o[0]:o,"readonly");r.autoSchema?function({_novip:e},t,r){e.verno=t.version/10;let n=e._dbSchema=rh(0,t,r);e._storeNames=H(t.objectStoreNames,0),rs(e,[e._allTables],T(n),n)}(e,n,i):(rm(e,e._dbSchema,i),((t=rd(rh(0,e.idbdb,i),e._dbSchema)).add.length||t.change.some(e=>e.add.length||e.change.length))&&console.warn("Dexie SchemaDiff: Schema was extended without increasing the number passed to db.version(). Some queries may fail.")),ru(e,i)}catch(e){}tP.push(e),n.onversionchange=ts(t=>{r.vcFired=!0,e.on("versionchange").fire(t)}),n.onclose=ts(t=>{e.on("close").fire(t)}),s&&function({indexedDB:e,IDBKeyRange:t},r){rv(e)||"__dbnames"===r||rb(e,t).put({name:r}).catch(eC)}(e._deps,a),t()},o)}))]).then(()=>(i(),r.onReadyBeingFired=[],e6.resolve(rg(()=>e.on.ready.fire(e.vip))).then(function t(){if(r.onReadyBeingFired.length>0){let n=r.onReadyBeingFired.reduce(eM,eC);return r.onReadyBeingFired=[],e6.resolve(rg(()=>n(e.vip))).then(t)}}))).finally(()=>{r.onReadyBeingFired=null,r.isBeingOpened=!1}).then(()=>e).catch(t=>{r.dbOpenError=t;try{u&&u.abort()}catch(e){}return o===r.openCanceller&&e._close(),t_(t)}).finally(()=>{r.openComplete=!0,a()})}(this)}_close(){let e=this._state,t=tP.indexOf(this);if(t>=0&&tP.splice(t,1),this.idbdb){try{this.idbdb.close()}catch(e){}this._novip.idbdb=null}e.dbReadyPromise=new e6(t=>{e.dbReadyResolve=t}),e.openCanceller=new e6((t,r)=>{e.cancelOpen=r})}close(){this._close();let e=this._state;this._options.autoOpen=!1,e.dbOpenError=new eD.DatabaseClosed,e.isBeingOpened&&e.cancelOpen(e.dbOpenError)}delete(){let e=arguments.length>0,t=this._state;return new e6((r,n)=>{let o=()=>{this.close();var e=this._deps.indexedDB.deleteDatabase(this.name);e.onsuccess=ts(()=>{!function({indexedDB:e,IDBKeyRange:t},r){rv(e)||"__dbnames"===r||rb(e,t).delete(r).catch(eC)}(this._deps,this.name),r()}),e.onerror=t6(n),e.onblocked=this._fireOnBlocked};if(e)throw new eD.InvalidArgument("Arguments not allowed in db.delete()");t.isBeingOpened?t.dbReadyPromise.then(o):o()})}backendDB(){return this.idbdb}isOpen(){return null!==this.idbdb}hasBeenClosed(){let e=this._state.dbOpenError;return e&&"DatabaseClosed"===e.name}hasFailed(){return null!==this._state.dbOpenError}dynamicallyOpened(){return this._state.autoSchema}get tables(){return T(this._allTables).map(e=>this._allTables[e])}transaction(){let e=rE.apply(this,arguments);return this._transaction.apply(this,e)}_transaction(e,t,r){let n,o,i=e1.trans;i&&i.db===this&&-1===e.indexOf("!")||(i=null);let a=-1!==e.indexOf("?");e=e.replace("!","").replace("?","");try{if(o=t.map(e=>{var t=e instanceof this.Table?e.name:e;if("string"!=typeof t)throw TypeError("Invalid table argument to Dexie.transaction(). Only Table or String are allowed");return t}),"r"==e||"readonly"===e)n="readonly";else{if("rw"!=e&&"readwrite"!=e)throw new eD.InvalidArgument("Invalid transaction mode: "+e);n="readwrite"}if(i){if("readonly"===i.mode&&"readwrite"===n){if(!a)throw new eD.SubTransaction("Cannot enter a sub-transaction with READWRITE mode when parent transaction is READONLY");i=null}i&&o.forEach(e=>{if(i&&-1===i.storeNames.indexOf(e)){if(!a)throw new eD.SubTransaction("Table "+e+" not included in parent transaction.");i=null}}),a&&i&&!i.active&&(i=null)}}catch(e){return i?i._promise(null,(t,r)=>{r(e)}):t_(e)}let u=(function e(t,r,n,o,i){return e6.resolve().then(()=>{let a,u=e1.transless||e1,s=t._createTransaction(r,n,t._dbSchema,o);if(o)s.idbtrans=o.idbtrans;else try{s.create(),t._state.PR1398_maxLoop=3}catch(o){return o.name===ex.InvalidState&&t.isOpen()&&--t._state.PR1398_maxLoop>0?(console.warn("Dexie: Need to reopen db"),t._close(),t.open().then(()=>e(t,r,n,null,i))):t_(o)}let l=ef(i);l&&ty();let c=e6.follow(()=>{if(a=i.call(s,s))if(l){var e=tb.bind(null,null);a.then(e,e)}else"function"==typeof a.next&&"function"==typeof a.throw&&(a=rw(a))},{trans:s,transless:u});return(a&&"function"==typeof a.then?e6.resolve(a).then(e=>s.active?e:t_(new eD.PrematureCommit("Transaction committed too early. See http://bit.ly/2kdckMn"))):c.then(()=>a)).then(e=>(o&&s._resolve(),s._completion.then(()=>e))).catch(e=>(s._reject(e),t_(e)))})}).bind(null,this,n,o,i,r);return i?i._promise(n,u,"lock"):e1.trans?tO(e1.transless,()=>this._whenReady(u)):this._whenReady(u)}table(e){if(!B(this._allTables,e))throw new eD.InvalidTable(`Table ${e} does not exist`);return this._allTables[e]}}let rM="u">typeof Symbol&&"observable"in Symbol?Symbol.observable:"@@observable";class rB{constructor(e){this._subscribe=e}subscribe(e,t,r){return this._subscribe(e&&"function"!=typeof e?e:{next:e,error:t,complete:r})}[rM](){return this}}function rL(e,t){return T(t).forEach(r=>{rk(e[r]||(e[r]=new rC),t[r])}),e}try{n={indexedDB:I.indexedDB||I.mozIndexedDB||I.webkitIndexedDB||I.msIndexedDB,IDBKeyRange:I.IDBKeyRange||I.webkitIDBKeyRange}}catch(e){n={indexedDB:null,IDBKeyRange:null}}function rV(e){let t=rU;try{rU=!0,t8.storagemutated.fire(e)}finally{rU=t}}L(rN,{...ej,delete:e=>new rN(e,{addons:[]}).delete(),exists:e=>new rN(e,{addons:[]}).open().then(e=>(e.close(),!0)).catch("NoSuchDatabaseError",()=>!1),getDatabaseNames(e){try{return(function({indexedDB:e,IDBKeyRange:t}){return rv(e)?Promise.resolve(e.databases()).then(e=>e.map(e=>e.name).filter(e=>"__dbnames"!==e)):rb(e,t).toCollection().primaryKeys()})(rN.dependencies).then(e)}catch(e){return t_(new eD.MissingAPI)}},defineClass:()=>function(e){F(this,e)},ignoreTransaction:e=>e1.trans?tO(e1.transless,e):e(),vip:rg,async:function(e){return function(){try{var t=rw(e.apply(this,arguments));return t&&"function"==typeof t.then?t:e6.resolve(t)}catch(e){return t_(e)}}},spawn:function(e,t,r){try{var n=rw(e.apply(r,t||[]));return n&&"function"==typeof n.then?n:e6.resolve(n)}catch(e){return t_(e)}},currentTransaction:{get:()=>e1.trans||null},waitFor:function(e,t){let r=e6.resolve("function"==typeof e?rN.ignoreTransaction(e):e).timeout(t||6e4);return e1.trans?e1.trans.waitFor(r):r},Promise:e6,debug:{get:()=>ep,set:e=>{ep=e,eh="dexie"===e?()=>!0:tI}},derive:$,extend:F,props:L,override:G,Events:tM,on:t8,liveQuery:function(e){return new rB(t=>{let r=ef(e),n=!1,o={},i={},a={get closed(){return n},unsubscribe:()=>{n=!0,t8.storagemutated.unsubscribe(c)}};t.start&&t.start(a);let u=!1,s=!1;function l(){return T(i).some(e=>o[e]&&function(e,t){let r=rI(t),n=r.next();if(n.done)return!1;let o=n.value,i=rI(e),a=i.next(o.from),u=a.value;for(;!n.done&&!a.done;){if(0>=tH(u.from,o.to)&&tH(u.to,o.from)>=0)return!0;0>tH(o.from,u.from)?o=(n=r.next(u.from)).value:u=(a=i.next(o.from)).value}return!1}(o[e],i[e]))}let c=e=>{rL(o,e),l()&&d()},d=()=>{let f,p;if(u||n)return;o={};let h={},m=(r&&ty(),f=()=>tm(e,{subscr:h,trans:null}),p=e1.trans?tO(e1.transless,f):f(),r&&p.then(tb,tb),p);s||(t8("storagemutated",c),s=!0),u=!0,Promise.resolve(m).then(e=>{u=!1,n||(l()?d():(o={},i=h,t.next&&t.next(e)))},e=>{u=!1,t.error&&t.error(e),a.unsubscribe()})};return d(),a})},extendObservabilitySet:rL,getByKeyPath:J,setByKeyPath:X,delByKeyPath:function(e,t){"string"==typeof t?X(e,t,void 0):"length"in t&&[].map.call(t,function(t){X(e,t,void 0)})},shallowClone:Q,deepClone:ei,getObjectDiff:rA,cmp:tH,asap:Z,minKey:-1/0,addons:[],connections:tP,errnames:ex,dependencies:n,semVer:"3.2.3",version:"3.2.3".split(".").map(e=>parseInt(e)).reduce((e,t,r)=>e+t/Math.pow(10,2*r))}),rN.maxKey=rr(rN.dependencies.IDBKeyRange),"u">typeof dispatchEvent&&"u">typeof addEventListener&&(t8("storagemutated",e=>{if(!rU){let t;tk?(t=document.createEvent("CustomEvent")).initCustomEvent("x-storagemutated-1",!0,!0,e):t=new CustomEvent("x-storagemutated-1",{detail:e}),rU=!0,dispatchEvent(t),rU=!1}}),addEventListener("x-storagemutated-1",({detail:e})=>{rU||rV(e)}));let rU=!1;if("u">typeof BroadcastChannel){let e=new BroadcastChannel("x-storagemutated-1");"function"==typeof e.unref&&e.unref(),t8("storagemutated",t=>{rU||e.postMessage(t)}),e.onmessage=e=>{e.data&&rV(e.data)}}else if("u">typeof self&&"u">typeof navigator){t8("storagemutated",e=>{try{rU||("u">typeof localStorage&&localStorage.setItem("x-storagemutated-1",JSON.stringify({trig:Math.random(),changedParts:e})),"object"==typeof self.clients&&[...self.clients.matchAll({includeUncontrolled:!0})].forEach(t=>t.postMessage({type:"x-storagemutated-1",changedParts:e})))}catch(e){}}),"u">typeof addEventListener&&addEventListener("storage",e=>{if("x-storagemutated-1"===e.key){let t=JSON.parse(e.newValue);t&&rV(t.changedParts)}});let e=self.document&&navigator.serviceWorker;e&&e.addEventListener("message",function({data:e}){e&&"x-storagemutated-1"===e.type&&rV(e.changedParts)})}e6.rejectionMapper=function(e,t){if(!e||e instanceof eE||e instanceof TypeError||e instanceof SyntaxError||!e.name||!e_[e.name])return e;var r=new e_[e.name](t||e.message,e);return"stack"in e&&U(r,"stack",{get:function(){return this.inner.stack}}),r},eh=tI;var r$=r(3058),rW=r(2883);function rz(e){return(rz=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function rK(e,t){return(rK=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function rH(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(rH=function(){return!!e})()}function rG(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var rq=function(e){if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function t(){var e,r,n;if(!(this instanceof t))throw TypeError("Cannot call a class as a function");return n=["EsmOffline"],r=rz(r=t),rG(e=function(e,t){var r;if(t&&("object"==((r=t)&&"u">typeof Symbol&&r.constructor===Symbol?"symbol":typeof r)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,rH()?Reflect.construct(r,n||[],rz(this).constructor):r.apply(this,n)),"syncQueue",void 0),rG(e,"dynamicOfflineData",void 0),e.version(4).stores({syncQueue:"++id,userId,type,[userId+type]",dynamicOfflineData:"++id,type,identifier,*users,&[type+identifier]"}),e.syncQueue=e.table("syncQueue"),e.dynamicOfflineData=e.table("dynamicOfflineData"),e}return t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&rK(t,e),t}(rN);function rZ(){return new rq}function rY(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function rJ(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function rX(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){rJ(i,n,o,a,u,"next",e)}function u(e){rJ(i,n,o,a,u,"throw",e)}a(void 0)})}}function rQ(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],a=!0,u=!1;try{for(o=o.call(e);!(a=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){u=!0,n=e}finally{try{a||null==o.return||o.return()}finally{if(u)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return rY(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return rY(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r0(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}var r1=new rq,r2={},r3=(0,rW.Zd)("offline-synchronization",{});function r4(){return r3}function r6(){return rX(function(){var e,t,r,n,o,i,a,u,s,l,c,d,f;return r0(this,function(p){switch(p.label){case 0:if(r3.getState().synchronization)return[2];return[4,r1.syncQueue.count()];case 1:e=p.sent(),t={},n=(r=Object.entries(r2)).length,o={},i=new AbortController,a=function(){var e,t,r=r3.getState().synchronization;r3.setState({synchronization:(e=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},r),t=t={pendingCount:r.pendingCount-1},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e)})},p.label=2;case 2:p.trys.push([2,,10,11]),r3.setState({synchronization:{totalCount:e,pendingCount:e,abortController:i}}),u=0,p.label=3;case 3:if(!(u<n&&r.length>0))return[3,8];s=r.length,p.label=4;case 4:if(!s--)return[3,7];if(c=(l=rQ(r[s],2))[0],!(f=(d=l[1]).dependsOn.map(function(e){return t[e]})).every(Boolean))return[3,6];return o[c]={},[4,Promise.all(f)];case 5:p.sent(),t[c]=function(e,t,r,n){return rX(function(e,t,r,n){var o,i,a,u,s,l,c,d,f,p,h,m,y,b,v,g,w;return r0(this,function(E){switch(E.label){case 0:return o=e.type,i=e.dependsOn,a=e.process,u=[],s=[],[4,r5()];case 1:return l=E.sent(),[4,r1.syncQueue.where({type:o,userId:l}).each(function(e,t){u.push([t.primaryKey,e.content,e.descriptor]),s.push(e.content)})];case 2:E.sent(),c=0,E.label=3;case 3:if(!(c<u.length))return[3,11];f=(d=rQ(u[c],3))[0],p=d[1],m=(h=d[2]).id,b=void 0===(y=h.dependencies)?[]:y,E.label=4;case 4:return E.trys.push([4,7,9,10]),[4,a(p,{abort:r,index:c,items:s,userId:l,dependencies:b.map(function(e){var r=e.id,n=e.type;return i.includes(n)?t[n][r]:void 0})})];case 5:return v=E.sent(),void 0!==m&&(t[o][m]=v),[4,r1.syncQueue.delete(f)];case 6:case 8:return E.sent(),[3,10];case 7:return g=E.sent(),[4,r1.syncQueue.update(f,{lastError:{name:null==g?void 0:g.name,message:null!=(w=null==g?void 0:g.message)?w:null==g?void 0:g.toString()}})];case 9:return n(),[7];case 10:return c++,[3,3];case 11:return[2]}})}).apply(this,arguments)}(d,o,i,a),r.splice(s,1),p.label=6;case 6:return[3,4];case 7:return u++,[3,3];case 8:return[4,Promise.allSettled(Object.values(t))];case 9:return p.sent(),[3,11];case 10:return r3.setState({synchronization:void 0}),[7];case 11:return[2]}})})()}function r5(){return rX(function(){var e;return r0(this,function(t){switch(t.label){case 0:return[4,(0,r$.xC)()];case 1:return[2,(null==(e=t.sent())?void 0:e.uuid)||"*"]}})})()}function r8(e,t,r,n){return rX(function(){var o;return r0(this,function(i){switch(i.label){case 0:if(void 0===(o=n&&n.id))return[3,2];return[4,r1.syncQueue.where({type:t,userId:e}).filter(function(e){return(null==e?void 0:e.descriptor.id)===o}).delete().catch(rN.errnames.DatabaseClosed)];case 1:i.sent(),i.label=2;case 2:return[4,r1.syncQueue.add({type:t,content:r,userId:e,descriptor:n||{},createdOn:new Date}).catch(rN.errnames.DatabaseClosed,function(){return -1})];case 3:return[2,i.sent()]}})})()}function r7(e,t,r){return rX(function(){return r0(this,function(n){switch(n.label){case 0:return[4,r5()];case 1:return[4,r8(n.sent(),e,t,r)];case 2:return[2,n.sent()]}})})()}function r9(e,t){return rX(function(){return r0(this,function(r){switch(r.label){case 0:return[4,ne(e,t)];case 1:return[2,r.sent().map(function(e){return e.content})]}})})()}function ne(e,t){return rX(function(){var r;return r0(this,function(n){switch(n.label){case 0:return r=t?{type:t,userId:e}:{userId:e},[4,r1.syncQueue.where(r).toArray().catch(rN.errnames.DatabaseClosed,function(){return[]})];case 1:return[2,n.sent()]}})})()}function nt(e){return rX(function(){return r0(this,function(t){switch(t.label){case 0:return[4,r5()];case 1:return[4,r9(t.sent(),e)];case 2:return[2,t.sent()]}})})()}function nr(e){return rX(function(){return r0(this,function(t){switch(t.label){case 0:return[4,r5()];case 1:return[4,ne(t.sent(),e)];case 2:return[2,t.sent()]}})})()}function nn(e){return rX(function(){return r0(this,function(t){switch(t.label){case 0:return[4,r1.syncQueue.get(e).catch(rN.errnames.DatabaseClosed,function(){})];case 1:return[2,t.sent()]}})})()}function no(e){var t;return!!(null==(t=r2[e])?void 0:t.options.onBeginEditSyncItem)}function ni(e){return rX(function(){var t,r,n;return r0(this,function(o){switch(o.label){case 0:return[4,nn(e)];case 1:if(!(r=o.sent()))throw Error("No sync item with the ID ".concat(e," exists."));if(!(n=null==(t=r2[r.type])?void 0:t.options.onBeginEditSyncItem))throw Error("A sync item with the ID ".concat(e,' exists, but the associated handler (if one exists) doesn\'t support editing the item. You can avoid this error by either verifying that sync items of this type can be edited via the "canEditSynchronizationItemsOfType(type: string)" function or alternatively ensure that the synchronizaton handler for sync items of type "').concat(r.type,'" supports editing items.'));return n(r),[2]}})})()}function na(e){return rX(function(){return r0(this,function(t){switch(t.label){case 0:return[4,r1.syncQueue.delete(e).catch(rN.errnames.DatabaseClosed)];case 1:return t.sent(),[2]}})})()}function nu(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};r2[e]={type:e,dependsOn:t,process:r,options:n}}var ns=r(188),nl="OFFLINE+";function nc(){return nl+(0,ns.A)()}function nd(e){return e.startsWith(nl)}function nf(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function np(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}function nh(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(e){np(i,n,o,a,u,"next",e)}function u(e){np(i,n,o,a,u,"throw",e)}a(void 0)})}}function nm(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}var ny={};function nb(){return Object.values(ny)}function nv(e){ny[e.id]&&console.warn('[setupDynamicOfflineDataHandler] Another second handler with the ID "'.concat(e.id,'" was registered. This handler will override the previous one. This could be unintended as the previous handler might run different flows than the newly registered one. If this is the case, ensure that you are setting up the handlers with different IDs.')),ny[e.id]=e}function ng(e){return nh(function(){return nm(this,function(t){switch(t.label){case 0:return[4,n_()];case 1:return[4,nw(t.sent(),e)];case 2:return[2,t.sent()]}})})()}function nw(e,t){return nh(function(){var r;return nm(this,function(n){switch(n.label){case 0:return r=t?{type:t,users:e}:{users:e},[4,new rq().dynamicOfflineData.where(r).toArray().catch(rN.errnames.DatabaseClosed,function(){return[]})];case 1:return[2,n.sent()]}})})()}function nE(e,t){return nh(function(){return nm(this,function(r){switch(r.label){case 0:return[4,n_()];case 1:return[4,nS(r.sent(),e,t)];case 2:return[2,r.sent()]}})})()}function nS(e,t,r){return nh(function(){var n,o;return nm(this,function(i){switch(i.label){case 0:return[4,(n=new rq).dynamicOfflineData.get({type:t,identifier:r}).catch(rN.errnames.DatabaseClosed,function(){})];case 1:if(o=i.sent())return[3,3];return[4,n.dynamicOfflineData.add({users:[e],type:t,identifier:r}).catch(rN.errnames.DatabaseClosed)];case 2:return i.sent(),[3,5];case 3:var a;if(o.users.includes(e))return[3,5];return[4,n.dynamicOfflineData.update(o.id,{users:((function(e){if(Array.isArray(e))return nf(e)})(a=o.users)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(a)||function(e){if(e){if("string"==typeof e)return nf(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return nf(e,void 0)}}(a)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e])}).catch(rN.errnames.DatabaseClosed)];case 4:i.sent(),i.label=5;case 5:return[2]}})})()}function nO(e,t){return nh(function(){return nm(this,function(r){switch(r.label){case 0:return[4,n_()];case 1:return[4,nA(r.sent(),e,t)];case 2:return[2,r.sent()]}})})()}function nA(e,t,r){return nh(function(){var n,o;return nm(this,function(i){switch(i.label){case 0:return[4,(n=new rq).dynamicOfflineData.get({type:t,identifier:r,users:e}).catch(rN.errnames.DatabaseClosed,function(){})];case 1:if(!(o=i.sent()))return[3,5];if(!(o.users.length>1))return[3,3];return[4,n.dynamicOfflineData.update(o.id,{users:o.users.filter(function(t){return t!==e})}).catch(rN.errnames.DatabaseClosed)];case 2:return i.sent(),[3,5];case 3:return[4,n.dynamicOfflineData.delete(o.id).catch(rN.errnames.DatabaseClosed)];case 4:i.sent(),i.label=5;case 5:return[2]}})})()}function nx(e,t){return nh(function(){return nm(this,function(r){switch(r.label){case 0:return[4,ng(e)];case 1:return[4,Promise.all(r.sent().map(function(e){return nh(function(){return nm(this,function(r){return[2,nD(e.type,e.identifier,t)]})})()}))];case 2:return r.sent(),[2]}})})()}function nD(e,t,r){return nh(function(){var n,o,i,a,u,s,l,c,d;return nm(this,function(f){switch(f.label){case 0:return[4,nE(e,t)];case 1:return f.sent(),n=new rq,[4,n_()];case 2:return o=f.sent(),[4,n.dynamicOfflineData.get({type:e,identifier:t}).catch(rN.errnames.DatabaseClosed,function(){})];case 3:if(i=f.sent(),a=nb().filter(function(t){return t.type===e}),!i)return[2];return[4,Promise.all(a.map(function(e){return nh(function(){var n,o,i;return nm(this,function(a){try{return e.sync(t,r),[2,{id:e.id,error:void 0}]}catch(t){return i=null!=(n=null==(o=t.message)?void 0:o.toString())?n:t.toString(),[2,{id:e.id,error:i}]}})})()}))];case 4:if(s=(u=f.sent()).filter(function(e){return!e.error}).map(function(e){return e.id}),l=u.filter(function(e){return e.error}).map(function(e){return e.id}),c=u.filter(function(e){return e.error}).map(function(e){return{handlerId:e.id,message:e.error}}),d={syncedOn:new Date,syncedBy:o,succeededHandlers:s,erroredHandlers:l,errors:c},!i.id)return[3,6];return[4,n.dynamicOfflineData.update(i.id,{syncState:d}).catch(rN.errnames.DatabaseClosed)];case 5:f.sent(),f.label=6;case 6:return[2]}})})()}function n_(){return nh(function(){var e;return nm(this,function(t){switch(t.label){case 0:return[4,(0,r$.xC)()];case 1:if(!(e=t.sent().uuid))throw Error("Using the dynamic offline data API requires a logged in user.");return[2,e]}})})()}function nj(e,t,r,n,o,i,a){try{var u=e[i](a),s=u.value}catch(e){r(e);return}u.done?t(s):Promise.resolve(s).then(n,o)}var nC=(0,rW.Zd)("offline-patients",{offlinePatientDataSyncState:{},handlers:{}});function nP(){return nT(),nC}function nk(e,t){nT(),nv({type:"patient",displayName:t.displayName,id:e,isSynced:function(){return Promise.resolve(!0)},sync:function(e,r){return t.onOfflinePatientAdded({patientUuid:e,signal:null!=r?r:new AbortController().signal})}})}function nI(e){var t;return(t=function(){return function(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),u=Object.defineProperty;return u(a,"next",{value:s(0)}),u(a,"throw",{value:s(1)}),u(a,"return",{value:s(2)}),"function"==typeof Symbol&&u(a,Symbol.iterator,{value:function(){return this}}),a;function s(u){return function(s){var l=[u,s];if(r)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&l[0]?n.return:l[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,l[1])).done)return o;switch(n=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,n=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],n=0}finally{r=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(t){switch(t.label){case 0:return nT(),[4,nD("patient",e)];case 1:return t.sent(),[2]}})},function(){var e=this,r=arguments;return new Promise(function(n,o){var i=t.apply(e,r);function a(e){nj(i,n,o,a,u,"next",e)}function u(e){nj(i,n,o,a,u,"throw",e)}a(void 0)})})()}function nT(){console.warn("The offline patient API has been deprecated and will be removed in a future release. To prevent future crashes, the functions remain available for the moment, but any invocations should be migrated ASAP.")}},6258(e,t,r){"use strict";r.d(t,{fq:()=>tm,JK:()=>V,if:()=>eX,tQ:()=>tt,YY:()=>d,E4:()=>eD,zD:()=>ey,g9:()=>$,uL:()=>w,kH:()=>e1,WK:()=>e7,br:()=>S,Gz:()=>eC,M3:()=>e4,qw:()=>tu,Wq:()=>ej,rr:()=>g,oU:()=>tn,wV:()=>ti,d7:()=>eS,Jm:()=>e3,xH:()=>th,W3:()=>x,zq:()=>a,Ie:()=>et,CH:()=>eT,ns:()=>U,vL:()=>eG,xl:()=>eJ,Us:()=>en,UK:()=>em,fS:()=>ee,yJ:()=>el,u:()=>ek,to:()=>eB,iy:()=>e$,_9:()=>es,Bf:()=>ez,Tt:()=>ea,CX:()=>E,Ed:()=>eF,p6:()=>Q,Wr:()=>e2,TA:()=>eQ,F7:()=>L,qv:()=>eY,sc:()=>W,WQ:()=>e5,Pj:()=>b,i_:()=>s,$B:()=>e_,oq:()=>eH,wJ:()=>tr,mQ:()=>v,wr:()=>tb,mw:()=>eL,jn:()=>X,Fx:()=>ew});var n,o=r(6925),i=r.n(o),a=(0,o.createContext)({moduleName:"",featureName:""}),u=r(7774);function s(e){var t=e.to,r=e.templateParams,n=e.onBeforeNavigate,a=e.children,s=function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["to","templateParams","onBeforeNavigate","children"]);return(0,o.useEffect)(function(){s.href&&console.warn("ConfigurableLink does not support the href prop. Use the 'to' prop instead. The provided href value is '".concat(s.href,"'")),s.onClick&&console.warn("ConfigurableLink does not support the onClick prop. Use the 'onBeforeNavigate' prop instead. The 'to' prop of the offending link is ".concat(t))},[]),i().createElement("a",function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({onClick:function(e){0===e.button&&!e.ctrlKey&&!e.shiftKey&&!e.altKey&&!e.metaKey&&(e.preventDefault(),null==n||n(e),(0,u.oo)({to:t,templateParams:r})),0===e.button&&(e.ctrlKey||e.metaKey)&&(null==n||n(e)),0===e.button&&e.shiftKey&&(null==n||n(e)),1===e.button&&(null==n||n(e))},href:(0,u.JG)(t,r)},s),a)}var l=r(7477);function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}var d=function(e){var t=e.state,r=(e.children,function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["state","children"])),n=(0,o.useContext)(a).extension,u=(0,o.useRef)(null),s=(0,o.useRef)(Promise.resolve()),d=(0,o.useCallback)(function(e){(null==n?void 0:n.extensionSlotName)&&n.extensionSlotModuleName&&n.extensionSlotModuleName&&!u.current&&(0,l.wG)(e,n.extensionSlotName,n.extensionSlotModuleName,n.extensionId,void 0,t).then(function(e){u.current=e})},[]);return(0,o.useEffect)(function(){return function(){if(u&&u.current)switch(u.current.getStatus()){case"MOUNTING":u.current.mountPromise.then(function(){var e;(null==(e=u.current)?void 0:e.getStatus())==="MOUNTED"&&u.current.unmount()});break;case"MOUNTED":u.current.unmount();break;case"UPDATING":s.current&&s.current.then(function(){var e;(null==(e=u.current)?void 0:e.getStatus())==="MOUNTED"&&u.current.unmount()})}}},[]),(0,o.useEffect)(function(){u.current&&u.current.update&&"UNMOUNTING"!==u.current.getStatus()&&Promise.all([u.current.mountPromise,s.current]).then(function(){var e;(null==u||null==(e=u.current)?void 0:e.getStatus())==="MOUNTED"&&u.current.update&&(s.current=u.current.update(c({},t)).catch(function(e){var t,r;if((null!=(r=Error)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!r[Symbol.hasInstance](e):!(e instanceof r))||!e.message.includes("minified message #32")||(null==(t=u.current)?void 0:t.getStatus())==="MOUNTED")throw e}))})},[t]),n?i().createElement("div",c({ref:d,"data-extension-id":null==n?void 0:n.extensionId,style:{position:"relative"}},r)):null};function f(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function p(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function h(e,t){if(e){if("string"==typeof e)return f(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return f(e,t)}}function m(e,t){"function"==typeof t&&(t=t(e));var r={},n=!0,o=!1,i=void 0;try{for(var a,u=Object.entries(t)[Symbol.iterator]();!(n=(a=u.next()).done);n=!0)!function(){var t,n=(t=a.value,function(e){if(Array.isArray(e))return e}(t)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||h(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),o=n[0],i=n[1];r[o]=function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];e.setState(function(e){return i.apply(void 0,[e].concat(function(e){if(Array.isArray(e))return f(e)}(r)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||h(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()))})}}()}catch(e){o=!0,i=e}finally{try{n||null==u.return||u.return()}finally{if(o)throw i}}return r}var y=function(){return function(e){return e}};function b(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:y(),r=arguments.length>2?arguments[2]:void 0,n=(0,o.useCallback)(function(t){return e.subscribe(t)},[e]),i=(0,o.useCallback)(function(){return t(e.getState())},[e,t]);return p({},(0,o.useSyncExternalStore)(n,i,i),(0,o.useMemo)(function(){return r?m(e,r):{}},[e,r]))}function v(e,t){return b(e,y(),t)}function g(e){return function(t){var r=(0,o.useCallback)(function(t){return e.subscribe(t)},[]),n=(0,o.useCallback)(function(){return e.getState()},[]);return p({},(0,o.useSyncExternalStore)(r,n,n),(0,o.useMemo)(function(){return t?m(e,t):{}},[t]))}}var w=function(e){return b((0,l.zF)(),function(t){var r;return null==(r=t.slots)?void 0:r[e]})};function E(e){var t,r=w(e);return null!=(t=null==r?void 0:r.assignedExtensions)?t:[]}function S(e,t){var r=(0,o.useContext)(a).moduleName,n=(0,o.useRef)(!0);if(!r)throw Error("ComponentContext has not been provided. This should come from @openmrs/esm-react-utils.");return(0,o.useEffect)(function(){(0,l.FY)(r,e,t),n.current=!1},[]),(0,o.useEffect)(function(){n.current||(0,l.ap)(e,t)},[e,t]),{extensions:E(e),extensionSlotName:e,extensionSlotModuleName:r}}function O(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function A(e){return e}function x(e){var t,r,n=e.name,u=e.extensionSlotName,s=e.select,l=void 0===s?A:s,c=e.children,f=e.state,p=e.style,h=function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["name","extensionSlotName","select","children","state","style"]);if(c&&f)throw Error("Both children and state have been provided. If children are provided, the state must be passed as a prop to the `Extension` component.");var m=null!=n?n:u,y=(0,o.useRef)(null),b=S(m,f),v=b.extensions,g=b.extensionSlotModuleName,w=(0,o.useMemo)(function(){return l(v)},[l,v]),E=(0,o.useMemo)(function(){if("function"==typeof c&&!i().isValidElement(c))return w.map(function(e){return c(e,f)})},[c,w]);return i().createElement("div",O({ref:y,"data-extension-slot-name":m,"data-extension-slot-module-name":g,style:(t=O({},p),r=r={position:"relative"},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t)},h),m&&(null==w?void 0:w.map(function(e,t){var r,n;return i().createElement(a.Provider,{key:e.id,value:{moduleName:g,featureName:"",extension:{extensionId:e.id,extensionSlotName:m,extensionSlotModuleName:g}}},null!=(r=null!=(n=null==E?void 0:E[t])?n:"function"!=typeof c?c:null)?r:i().createElement(d,{state:f}))})))}var D=r(8279),j=r(2879),C=r(9737),P=r(7488),k=r(3058);function I(e){return(I=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function T(e,t){return(T=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function R(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function F(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(F=function(){return!!e})()}var N={strictMode:!0,throwErrorsToConsole:!0,disableTranslations:!1},M=new Map,B={errorRetryCount:3,fetcher:k.lo,focusThrottleInterval:18e5,revalidateIfStale:!0,revalidateOnFocus:!1,revalidateOnReconnect:!1,refreshInterval:0,shouldRetryOnError:function(e){var t;if(null!=(t=k.$f)&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t){var r=e.response.status;return!!(r>=500)||401===r||403===r||429===r}return!0},provider:function(){return M}};function L(e){if((void 0===e?"undefined":R(e))!=="object"||"string"!=typeof e.featureName||"string"!=typeof e.moduleName)throw Error("Invalid options");var t=Object.assign({},N,e),r=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},B,t.swrConfig);return function(e){var n,u,s,l;return u=n=function(n){var u;if("function"!=typeof n&&null!==n)throw TypeError("Super expression must either be null or a function");function s(e){var r,n,o;if(!(this instanceof s))throw TypeError("Cannot call a class as a function");return n=s,o=[e],n=I(n),(r=function(e,t){if(t&&("object"===R(t)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,F()?Reflect.construct(n,o||[],I(this).constructor):n.apply(this,o))).state={caughtError:null,caughtErrorInfo:null,config:{moduleName:t.moduleName,featureName:t.featureName,extension:e._extensionContext}},r}return s.prototype=Object.create(n&&n.prototype,{constructor:{value:s,writable:!0,configurable:!0}}),n&&T(s,n),u=[{key:"componentDidCatch",value:function(e,r){r&&r.componentStack&&(e.extra=Object.assign(e.extra||{},{componentStack:r.componentStack})),t.throwErrorsToConsole&&setTimeout(function(){throw e}),this.setState({caughtError:e,caughtErrorInfo:r})}},{key:"render",value:function(){if(this.state.caughtError)return i().createElement("div",null,"An error has occurred. Please try reloading the page.");var n=i().createElement(o.Suspense,{fallback:null},i().createElement(P.BE,{value:r},i().createElement(a.Provider,{value:this.state.config},t.disableTranslations?i().createElement(e,this.props):i().createElement(C.I18nextProvider,{i18n:window.i18next,defaultNS:this.state.config.extension?"".concat(this.state.config.moduleName,"___").concat(this.state.config.extension.extensionSlotName,"___").concat(this.state.config.extension.extensionId):this.state.config.moduleName},i().createElement(e,this.props)))));return t.strictMode&&i().StrictMode?i().createElement(i().StrictMode,null,n):n}}],function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(s.prototype,u),s}(i().Component),s="displayName",l="OpenmrsReactComponent(".concat(t.featureName,")"),s in u?Object.defineProperty(u,s,{value:l,enumerable:!0,configurable:!0,writable:!0}):u[s]=l,n}}function V(e,t){return(0,j.A)({React:i(),ReactDOMClient:D,rootComponent:L(t)(e)})}function U(e,t){return function(){return e().then(function(e){return V(e.default,t)})}}function $(e,t){return function(){return Promise.resolve(V(e,t))}}var W=U,z=r(9167),K=r(2883),H=(0,z.y)()(function(){return{}});(0,K.CE)("openmrs-app-context",H);var G={};function q(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return e},r=H.getState();return e in r?Object.freeze(Object.assign({},t?t(r[e]):r[e])):null}function Z(e,t){H.setState(function(r){return e in r||(r[e]={}),r[e]=t(r[e]),Object.assign({},r)})}var Y=r(8254),J=new Map;function X(e,t){var r=(0,o.useRef)(null!=t?t:{}),n=(0,o.useRef)(function(t){return Z(e,t)}),i=(0,o.useRef)(Symbol());return(0,o.useEffect)(function(){var r=null!=t?t:{},n=i.current;return null===q(e)?!function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:G;H.setState(function(r){var n,o;if(e in r)throw Error("Attempted to re-register namespace ".concat(e," in the app context. Each namespace must be unregistered before the name can be registered again."));return Object.assign({},r,(n={},o=t===G?{}:t,e in n?Object.defineProperty(n,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):n[e]=o,n))})}(e,r):(console.warn("Namespace ".concat(e," is already registered in the app context. ")+"This is likely a race condition during navigation, but may indicate two components are trying to own the same namespace. Updating the existing context."),Z(e,function(){return r})),J.set(e,n),function(){J.get(e)===n&&(H.setState(function(t){return e in t&&delete t[e],t}),J.delete(e))}},[e]),(0,o.useEffect)(function(){var n=null!=t?t:{};(0,Y.b)(r.current,n)||(Z(e,function(){return n}),r.current=n)},[t]),n.current}function Q(e){return X(e.namespace,e.value),null}var ee=function(e){var t=e.children,r=e.value,n=e.fallback;return r?i().createElement(i().Fragment,null,t):n?i().createElement(i().Fragment,null,n):null};function et(){var e=(0,o.useRef)();return(!e.current||e.current.signal.aborted)&&(e.current=new AbortController),(0,o.useEffect)(function(){var t=e.current;return function(){return null==t?void 0:t.abort()}},[]),e.current}function er(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function en(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return null!=e?e:{}},n=function(e){if(Array.isArray(e))return e}(t=(0,o.useState)())||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return er(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return er(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=n[0],a=n[1];return(0,o.useEffect)(function(){if(null==e||""===e.replace(" ",""))throw Error('The namespace supplied to useAppContext must be a non-empty string, but was "'.concat(e,'".'))},[e]),(0,o.useEffect)(function(){var t,n;return(t=function(e){if(void 0!==e){var t=r?r(e):null!=e?e:{};(0,Y.b)(i,t)||a(t)}})(Object.freeze(Object.assign({},n=q(e)))),H.subscribe(function(r){var o=e in r?r[e]:null;o!==n&&(n=o,t(Object.freeze(Object.assign({},o))))})},[]),i}var eo=r(4809);function ei(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function ea(e){var t,r=function(e){if(Array.isArray(e))return e}(t=(0,o.useState)([]))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return ei(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return ei(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),n=r[0],i=r[1];return(0,o.useEffect)(function(){return(0,l.zF)().subscribe(function(t){var r,o,a=null!=(r=null==(o=t.slots[e])?void 0:o.assignedExtensions.map(function(e){return e.id}))?r:[];(0,eo.A)(a,n)||i(a)})},[]),n}var eu=r(1265);function es(e,t){var r=(0,P.Ay)("".concat(eu.Zu,"?patient=").concat(e,"&includeEncounterless=").concat(t),k.lo),n=r.data,i=r.error,a=r.mutate,u=r.isLoading,s=r.isValidating;return(0,o.useMemo)(function(){var e;return{isLoading:u,data:null!=(e=null==n?void 0:n.data.results)?e:[],error:i,mutate:a,isValidating:s}},[n,i,u,s,a])}function el(e){(0,o.useEffect)(function(){if(e){var t=window.getComputedStyle(document.body).overflow;return document.body.style.overflow="hidden",function(){document.body.style.overflow=t}}},[e])}var ec=r(7994);function ed(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function ef(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function ep(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],a=!0,u=!1;try{for(o=o.call(e);!(a=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){u=!0,n=e}finally{try{a||null==o.return||o.return()}finally{if(u)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return ed(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ed(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var eh={};function em(e){var t,r=(0,o.useContext)(a),n=r.moduleName,i=r.extension,u=null!=(t=null==e?void 0:e.externalModuleName)?t:n;if(!u&&!i)throw Error('No ComponentContext has been provided. This should come from "openmrsComponentDecorator".\nUsually this is already applied when using "getAsyncLifecycle" or "getSyncLifecycle".');var s=function(e){var t,r,n,i=(0,o.useMemo)(function(){return(0,ec.IS)(e)},[e]),a=(r=(t=ep((0,o.useState)(function(){var e=i.getState();return e.loaded&&e.config?e.config:null}),2))[0],n=t[1],(0,o.useEffect)(function(){return null==i?void 0:i.subscribe(function(e){e.loaded&&e.config&&n(e.config)})},[i]),r);if(!a)throw eh[e]||(eh[e]=new Promise(function(e){var t=i.subscribe(function(r){r.loaded&&r.config&&(e(r.config),t())})})),eh[e];return a}(u),l=function(e){var t=(0,o.useMemo)(ec.GI,[]),r=(i=(n=ep((0,o.useState)(e?function(){var r=t.getState(),n=(0,ec.P0)(r,e.extensionSlotName,e.extensionId);if(n.loaded&&n.config)return n.config}:null),2))[0],a=n[1],(0,o.useEffect)(function(){if(e)return t.subscribe(function(t){var r=(0,ec.P0)(t,e.extensionSlotName,e.extensionId);r.loaded&&r.config&&!(0,eo.A)(r.config,i)&&a(r.config)})},[t,e,i]),i);if(!r&&e){var n,i,a,u="".concat(e.extensionSlotName,"-").concat(e.extensionId);throw!eh[u]&&t&&(eh[u]=new Promise(function(r){var n=t.subscribe(function(t){var o=(0,ec.P0)(t,e.extensionSlotName,e.extensionId);o.loaded&&o.config&&(r(o.config),n())})})),eh[u]}return r||{}}(i);return(0,o.useMemo)(function(){return(null==e?void 0:e.externalModuleName)&&u===e.externalModuleName?ef({},s):ef({},s,l)},[u,null==e?void 0:e.externalModuleName,s,l])}var ey=E,eb=r(9726),ev=r(2316);function eg(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function ew(){var e,t=function(e){if(Array.isArray(e))return e}(e=(0,o.useState)((0,ev.s)()))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return eg(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return eg(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],n=t[1];return(0,o.useEffect)(function(){return(0,eb.gj)(function(e){return n(e.online)})},[]),r}function eE(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function eS(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:300,n=function(e){if(Array.isArray(e))return e}(t=(0,o.useState)(e))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return eE(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return eE(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=n[0],a=n[1];return(0,o.useEffect)(function(){var t=setTimeout(function(){a(e)},r);return function(){clearTimeout(t)}},[e,r]),i}var eO=r(6269);function eA(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var ex="custom:".concat([["admissionDecisionConcept","ref"],["admissionEncounterType","ref"],["admissionForm","ref"],["atFacilityVisitType","ref"],["bedAssignmentEncounterType","ref"],["cancelADTRequestEncounterType","ref"],["checkInClerkEncounterRole","ref"],["checkInEncounterType","ref"],["clinicianEncounterRole","ref"],["conceptSourcesForDiagnosisSearch","ref"],["consultEncounterType","ref"],["consultFreeTextCommentsConcept","ref"],["denyAdmissionConcept","ref"],["diagnosisMetadata","ref"],["diagnosisSets","ref"],["dischargeForm","ref"],["dispositionDescriptor","ref"],["dispositions","ref"],["emrApiConceptSource","ref"],["exitFromInpatientEncounterType","ref"],["extraPatientIdentifierTypes","ref"],["fullPrivilegeLevel","ref"],["highPrivilegeLevel","ref"],["identifierTypesToSearch","ref"],["inpatientNoteEncounterType","ref"],["lastViewedPatientSizeLimit","ref"],["metadataSourceName","ref"],["motherChildRelationshipType","ref"],["narrowerThanConceptMapType","ref"],["nonDiagnosisConceptSets","ref"],["orderingProviderEncounterRole","ref"],["patientDiedConcept","ref"],["personImageDirectory","ref"],["primaryIdentifierType","ref"],["sameAsConceptMapType","ref"],["suppressedDiagnosisConcepts","ref"],["supportsAdmissionLocationTag","(uuid,display,name,links)"],["supportsLoginLocationTag","(uuid,display,name,links)"],["supportsTransferLocationTag","(uuid,display,name,links)"],["supportsVisitsLocationTag","(uuid,display,name,links)"],["telephoneAttributeType","ref"],["testPatientPersonAttributeType","ref"],["transferForm","ref"],["transferRequestEncounterType","ref"],["transferWithinHospitalEncounterType","ref"],["unknownCauseOfDeathConcept","ref"],["unknownLocation","ref"],["unknownPatientPersonAttributeType","ref"],["unknownProvider","ref"],["visitAssignmentHandlerAdjustEncounterTimeOfDayIfNecessary","ref"],["visitExpireHours","ref"],["visitNoteEncounterType","ref"]].map(function(e){var t=function(e){if(Array.isArray(e))return e}(e)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return eA(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return eA(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],n=t[1];return"".concat(r,":").concat(n)}).join(","));function eD(){var e="".concat(k.Jj,"/emrapi/configuration?v=").concat(ex),t=(0,eO.A)(e,k.lo);return(0,o.useMemo)(function(){var e;return{emrConfiguration:null==(e=t.data)?void 0:e.data,isLoadingEmrConfiguration:t.isLoading,mutateEmrConfiguration:t.mutate,errorFetchingEmrConfiguration:t.error}},[t])}var e_=g((0,l.a9)());function ej(e){var t=E(e);return(0,o.useMemo)(function(){return Object.fromEntries(t.map(function(e){return[e.name,e.meta]}))},[t])}var eC=g((0,l.zF)()),eP=r(5794);function ek(e){var t,r;return null!=(t=null==(r=b(eP.jX).flags[e])?void 0:r.enabled)&&t}function eI(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function eT(){var e,t=(function(e){if(Array.isArray(e))return e}(e=(0,o.useState)(0))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return eI(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return eI(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[1];return(0,o.useCallback)(function(){t(function(e){return e+1})},[])}function eR(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function eF(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return eM(e,t,eN,r)}var eN={getPaginatedUrl:function(e,t,r){if(!e)return null;var n=new URL((0,k.Gm)(e.toString()),window.location.toString());return n.searchParams.set("limit",""+t),n.searchParams.set("startIndex",""+r),n.searchParams.set("totalCount","true"),n.toString()},getNextUrl:function(e){var t,r,n=null==e||null==(r=e.links)||null==(t=r.find(function(e){return"next"==e.rel}))?void 0:t.uri;if(!n)return null;var o=new URL(n);return o.host=window.location.host,o.protocol=window.location.protocol,o.toString()},getTotalCount:function(e){var t;return null!=(t=null==e?void 0:e.totalCount)?t:NaN},getCurrentPageSize:function(e){var t,r;return null!=(t=null==e||null==(r=e.results)?void 0:r.length)?t:NaN},getData:function(e){return null==e?void 0:e.results}};function eM(e,t,r){var n,i,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},u=r.getPaginatedUrl,s=r.getTotalCount,l=r.getCurrentPageSize,c=r.getData,d=a.immutable,f=a.swrConfig,p=null!=(i=a.fetcher)?i:k.lo,h=function(e){if(Array.isArray(e))return e}(n=(0,o.useState)(1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(n)||function(e){if(e){if("string"==typeof e)return eR(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return eR(e,2)}}(n)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),m=h[0],y=h[1],b=(0,o.useRef)(NaN),v=(0,o.useRef)(NaN),g=(m-1)*t,w=(0,o.useMemo)(function(){return u(e,t,g)},[e,t,g]),E=(d?eO.A:P.Ay)(w,p,f),S=E.data,O=function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(E,["data"]);(null==S?void 0:S.data)&&(b.current=s(null==S?void 0:S.data),v.current=l(null==S?void 0:S.data));var A=Math.ceil(b.current/t),x=(0,o.useCallback)(function(e){0<e&&e<=A?y(e):console.warn("Invalid attempt to go to out of bounds page: "+e)},[e,m,A]),D=(0,o.useCallback)(function(){x(m+1)},[e,m,A]),j=(0,o.useCallback)(function(){x(m-1)},[e,m,A]);return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({data:c(null==S?void 0:S.data),totalPages:A,totalCount:b.current,currentPage:m,currentPageSize:v,paginated:A>1,showNextButton:m<A,showPreviousButton:m>1,goTo:x,goToNext:D,goToPrevious:j},O)}function eB(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return eM(e,t,eL(),r)}function eL(){return{getPaginatedUrl:function(e,t,r){if(!e)return null;var n=new URL((0,k.Gm)(e.toString()),window.location.toString());return n.searchParams.set("_count",""+t),n.searchParams.set("_getpagesoffset",""+r),n.toString()},getNextUrl:function(e){var t,r,n=null==e||null==(r=e.link)||null==(t=r.find(function(e){return"next"==e.relation}))?void 0:t.url;if(!n)return null;var o=new URL(n);return o.host=window.location.host,o.protocol=window.location.protocol,o.toString()},getTotalCount:function(e){var t;return null!=(t=null==e?void 0:e.total)?t:NaN},getCurrentPageSize:function(e){var t,r;return null!=(t=null==e||null==(r=e.entry)?void 0:r.length)?t:NaN},getData:function(e){var t;return null==e||null==(t=e.entry)?void 0:t.map(function(e){return e.resource})}}}var eV=r(3709);function eU(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function e$(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return eW(e,eN,t)}function eW(e,t){var r,n,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=i.swrInfiniteConfig,u=i.immutable,s=t.getNextUrl,l=t.getTotalCount,c=t.getData,d=null!=(r=i.fetcher)?r:k.lo,f=(0,o.useCallback)(function(r,n){var o;return 0!=r?t.getNextUrl(n.data):null!=(o=null==e?void 0:e.toString())?o:null},[e]),p=(0,eV.Ay)(f,d,eU({},a,u?{revalidateIfStale:!1,revalidateOnFocus:!1,revalidateOnReconnect:!1}:{})),h=p.data,m=(p.size,p.setSize),y=function(e,t){if(null==e)return{};var r,n,o,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,r=Reflect.ownKeys(Object(e));o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,o={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)n=r[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(p,["data","size","setSize"]),b=s(null==h?void 0:h[h.length-1].data),v=l(null==h||null==(n=h[0])?void 0:n.data);return eU({data:null==h?void 0:h.flatMap(function(e){return c(e.data)}),totalCount:v,hasMore:null!=b,loadMore:function(){var e;m((null!=(e=null==h?void 0:h.length)?e:0)+1)},nextUri:b},y)}function ez(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return eK(e,eN,t)}function eK(e,t){var r,n,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=eW(e,t,i),u=a.hasMore,s=a.error,l=a.data,c=a.loadMore,d=a.isLoading,f=a.nextUri;return((0,o.useEffect)(function(){u&&!s&&c()},[u,f]),i.partialData)?a:(r=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},a),n=n={data:u||s?void 0:l,isLoading:d||u},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r)}function eH(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return eK(e,eL(),t)}function eG(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return eW(e,eL(),t)}function eq(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function eZ(){var e="tablet";return document.body.classList.forEach(function(t){switch(t){case"omrs-breakpoint-lt-tablet":e="phone";break;case"omrs-breakpoint-gt-small-desktop":e="large-desktop";break;case"omrs-breakpoint-gt-tablet":e="small-desktop"}}),e}function eY(){var e,t=function(e){if(Array.isArray(e))return e}(e=(0,o.useState)(eZ))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return eq(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return eq(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],n=t[1];return(0,o.useEffect)(function(){var e=function(){n(eZ())};return window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}},[]),r}var eJ=function(e){return"small-desktop"===e||"large-desktop"===e};function eX(e){var t=(0,o.useContext)(a);(0,o.useEffect)(function(){return t&&t.moduleName&&(e.componentContext=t),(0,l.Vx)(e),function(){(0,l.sr)(e.name)}},[t,e])}function eQ(){return b(l.Gp)}function e0(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function e1(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=function(e){if(Array.isArray(e))return e}(e=(0,o.useState)([]))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return e0(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return e0(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=n[0],a=n[1];return(0,o.useEffect)(function(){var e=(0,eu.Vs)(t,r).subscribe(function(e){a(e)},function(e){console.error(e)});return function(){return e.unsubscribe()}},[t,r]),i}function e2(e){var t=!(arguments.length>1)||void 0===arguments[1]||arguments[1],r=(0,o.useRef)(null);return(0,o.useEffect)(function(){var n=function(n){var o,i;t&&r.current&&n.target&&(o=n.target,null!=(i=Node)&&"u">typeof Symbol&&i[Symbol.hasInstance]?i[Symbol.hasInstance](o):o instanceof i)&&(r.current.contains(n.target)||e(n))};return window.addEventListener("mousedown",n),window.addEventListener("touchstart",n),function(){window.removeEventListener("mousedown",n),window.removeEventListener("touchstart",n)}},[e,t]),r}function e3(e){var t=(0,o.useRef)();return(0,o.useEffect)(function(){var r=new IntersectionObserver(function(t){var r=!0,n=!1,o=void 0;try{for(var i,a=t[Symbol.iterator]();!(r=(i=a.next()).done);r=!0)if(i.value.isIntersecting)return void e()}catch(e){n=!0,o=e}finally{try{r||null==a.return||a.return()}finally{if(n)throw o}}},{threshold:1});return t.current&&r.observe(t.current),function(){t.current&&r.unobserve(t.current)}},[t.current,e]),t}function e4(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.abortController,n=t.fetchInit,i=t.url,a=t.swrConfig,u=et(),s=(0,o.useMemo)(function(){var e,t;return null!=(e=null!=(t=null==n?void 0:n.signal)?t:null==r?void 0:r.signal)?e:u.signal},[null==r?void 0:r.signal,null==n?void 0:n.signal,u.signal]),l=(0,o.useCallback)(function(e){var t,r,o=function(e,t){if(t)return"function"==typeof t?t(e):t;if("string"==typeof e)return e;throw Error("When using useOpenmrsSWR with a key that is not a string, you must provide a url() function that converts the key to a valid url. The key for this hook is ".concat(e,"."))}(e,i);return(0,k.lo)(o,(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},n),r=r={signal:s},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))},[s,n,i]);return(0,P.Ay)(e,l,a)}function e6(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function e5(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:10,n=function(e){if(Array.isArray(e))return e}(e=(0,o.useState)(1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return e6(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return e6(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=n[0],a=n[1],u=(0,o.useMemo)(function(){return"number"==typeof r&&r>0?Math.max(1,Math.ceil(t.length/r)):1},[t.length,r]),s=(0,o.useMemo)(function(){var e=(i-1)*r,n=(i+0)*r;return t.slice(e,n)},[t,i,r]),l=(0,o.useCallback)(function(e){a(Math.max(1,Math.min(u,e)))},[a,u]),c=(0,o.useCallback)(function(){i<u&&a(i+1)},[i,u,a]),d=(0,o.useCallback)(function(){i>1&&a(i-1)},[i,a]);return(0,o.useMemo)(function(){return{results:s,totalPages:u,currentPage:i,paginated:t.length>r,showNextButton:i<u,showPreviousButton:i>1,goTo:l,goToNext:c,goToPrevious:d}},[s,u,t.length,r,i,l,c,d])}function e8(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function e7(e,t,r,n){return{pageSizes:(0,o.useMemo)(function(){var r,n=Math.ceil(t/e);return isNaN(n)&&(n=0),((function(e){if(Array.isArray(e))return e8(e)})(r=Array(n).keys())||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||function(e){if(e){if("string"==typeof e)return e8(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return e8(e,void 0)}}(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).map(function(t){return(t+1)*e})},[e,t]),pageItemsCount:(0,o.useMemo)(function(){return e>t?t:e*r>t?e*(r-1)+n:e*r},[e,t,r,n])}}function e9(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function te(){var e=/\/patient\/([a-zA-Z0-9\-]+)\/?/.exec(location.pathname);return e&&e[1]}function tt(e){var t,r=function(e){if(Array.isArray(e))return e}(t=(0,o.useState)(null!=e?e:te()))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return e9(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return e9(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),n=r[0],i=r[1],a=(0,P.Ay)(n?["patient",n]:null,function(){return(0,eu.hG)(n,{})}),u=a.data,s=a.error,l=a.isValidating;return(0,o.useEffect)(function(){var e=function(){var e=te();e!==n&&i(e)};return window.addEventListener("single-spa:routing-event",e),function(){return window.removeEventListener("single-spa:routing-event",e)}},[n]),(0,o.useMemo)(function(){return{isLoading:l&&!s&&!u,patient:u,patientUuid:n,error:s}},[l,s,u,n])}function tr(){var e="".concat(k.Jj,"/metadatamapping/termmapping?v=custom:(metadataUuid)&code=emr.primaryIdentifierType"),t=(0,P.Ay)(e,k.lo),r=t.data,n=t.error,i=t.isLoading;return(0,o.useMemo)(function(){var e,t;return{primaryIdentifierCode:null==r||null==(t=r.data)||null==(e=t.results[0])?void 0:e.metadataUuid,isLoading:i,error:n}},[r,n,i])}function tn(e){var t=S(e),r=t.extensions,n=t.extensionSlotModuleName;return e?r.map(function(t){return function(r){var o=r.state;return i().createElement(a.Provider,{value:{moduleName:n,featureName:"",extension:{extensionId:t.id,extensionSlotName:e,extensionSlotModuleName:n}}},i().createElement(d,{state:o}))}}):[]}function to(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function ti(){var e,t=(0,o.useRef)(),r=function(e){if(Array.isArray(e))return e}(e=(0,o.useState)(null))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return to(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return to(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=r[0],a=r[1],u=null;if(!i){if(n){var s=(0,k.EW)().getState();s.loaded&&(u=s.session)}else n=new Promise(function(e){var r=function(r){var n=r.loaded,o=r.session;n&&(e(o),u=o,t.current&&(t.current(),t.current=void 0))};r((0,k.EW)().getState()),u||(t.current=(0,k.EW)().subscribe(r))});if(u)a(u);else throw n}(0,o.useEffect)(function(){return t.current||(t.current=(0,k.EW)().subscribe(function(e){var t=e.loaded,r=e.session;t&&(u=r,a(r))})),function(){t.current&&(t.current(),t.current=void 0)}},[]);var l=i||u;if(!l)if(n)throw console.warn("useSession is in an unexpected state. Attempting to recover."),n;else throw Error("useSession is in an invalid state.");return l}function ta(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var tu=function(e){var t,r=e.privilege,n=e.fallback,a=e.children,u=function(e){if(Array.isArray(e))return e}(t=(0,o.useState)(null))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return ta(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return ta(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),s=u[0],l=u[1];return((0,o.useEffect)(function(){var e=(0,k.HW)({includeAuthStatus:!1}).subscribe(l);return function(){return e.unsubscribe()}},[]),s&&(0,k.st)(r,s))?i().createElement(i().Fragment,null,a):n?i().createElement(i().Fragment,null,n):null},ts=r(1712),tl=r.n(ts),tc=r(648);function td(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function tf(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){td(e,t,r[t])})}return e}var tp={setVisitContext:function(e,t){var r;return null==t?{manuallySetVisitUuid:null}:{manuallySetVisitUuid:t.uuid,patientUuid:null==(r=t.patient)?void 0:r.uuid}},mutateVisit:function(e){var t=!0,r=!1,n=void 0;try{for(var o,i,a=Object.values(null!=(o=e.mutateVisitCallbacks)?o:{})[Symbol.iterator]();!(t=(i=a.next()).done);t=!0)(0,i.value)()}catch(e){r=!0,n=e}finally{try{t||null==a.return||a.return()}finally{if(r)throw n}}return{}}};function th(e){var t=(0,o.useId)();return(0,o.useEffect)(function(){var r,n,o=(0,eu.BX)();return e&&o.setState({mutateVisitCallbacks:(r=tf({},o.getState().mutateVisitCallbacks),n=null!=(n=td({},t,e))?n:{},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r)}),function(){if(e){var r=tf({},o.getState().mutateVisitCallbacks);delete r[t],o.setState({mutateVisitCallbacks:r})}}},[t,e]),v((0,eu.BX)(),tp)}function tm(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:eu.Rb,r=th(),n=r.patientUuid,i=r.manuallySetVisitUuid,a=r.setVisitContext,u=e&&n==e?i:null,s="?patient=".concat(e,"&v=").concat(t,"&includeInactive=false"),l="/".concat(u,"?v=").concat(t),c=(0,P.Ay)(e?"".concat(k.Jj,"/visit").concat(s):null,k.lo),d=c.data,f=c.error,p=c.mutate,h=c.isValidating,m=(0,P.Ay)(e&&u?"".concat(k.Jj,"/visit").concat(l):null,k.lo),y=m.data,b=m.error,v=m.mutate,g=m.isValidating,w=(0,o.useMemo)(function(){var e;return null!=(e=null==d?void 0:d.data.results.find(function(e){return null===e.stopDatetime}))?e:null},[d]),E=(0,o.useMemo)(function(){return u&&y?y.data:null},[y,u]),S=(0,o.useRef)(null);(0,o.useEffect)(function(){!h&&w&&n===e&&null===i&&a(w),g||(S.current&&E&&S.current.uuid===E.uuid&&!S.current.stopDatetime&&E.stopDatetime&&a(null),S.current=E)},[E,i,w,h,g,n]);var O=(0,o.useCallback)(function(){p(),v()},[p,v]);th(O);var A=!!(!d||u&&!y),x=!!(u?b:f);return{error:f||b,mutate:O,isValidating:h||g,activeVisit:w,currentVisit:E,currentVisitIsRetrospective:!!u,isLoading:A&&!x}}function ty(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function tb(){var e,t=function(e){if(Array.isArray(e))return e}(e=(0,o.useState)([]))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(e)||function(e){if(e){if("string"==typeof e)return ty(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return ty(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],n=t[1];return(0,o.useEffect)(function(){var e=(0,eu.Pu)().subscribe(function(e){n(e)},function(e){return console.error(e)});return function(){return e.unsubscribe()}},[]),r}tl().extend(tc)},2883(e,t,r){"use strict";r.d(t,{i7:()=>m,jf:()=>h,CE:()=>p,Zd:()=>f});var n,o,i=r(8254);function a(e,t){let r;try{r=e()}catch(e){return}return{getItem:e=>{var n;let o=e=>null===e?null:JSON.parse(e,null==t?void 0:t.reviver),i=null!=(n=r.getItem(e))?n:null;return i instanceof Promise?i.then(o):o(i)},setItem:(e,n)=>r.setItem(e,JSON.stringify(n,null==t?void 0:t.replacer)),removeItem:e=>r.removeItem(e)}}let u=e=>t=>{try{let r=e(t);if(r instanceof Promise)return r;return{then:e=>u(e)(r),catch(e){return this}}}catch(e){return{then(e){return this},catch:t=>u(t)(e)}}};var s=r(9167);function l(){try{return"u">typeof process&&("true"===process.env.VITEST||void 0!==process.env.JEST_WORKER_ID)||"u">typeof globalThis&&("__vitest_worker__"in globalThis||"__jest__"in globalThis)}catch(e){return!1}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var d={};function f(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"none",n=d[e];if(n)return n.active?l()||console.error("Attempted to override the existing store ".concat(e,". Make sure that stores are only created once.")):n.value.setState(t,!0),n.active=!0,n.value;var o=y(e,t,r);return d[e]={value:o,active:!0},o}function p(e,t){var r=d[e];return r?(r.active?l()||console.error("Attempted to override the existing store ".concat(e,". Make sure that stores are only created once.")):r.value=t,r.active=!0,r.value):(d[e]={value:t,active:!0},t)}function h(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"none",n=d[e];if(!n){var o=y(e,null!=t?t:{},r);return d[e]={value:o,active:!1},o}return n.value}function m(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];var n=function(e){if(Array.isArray(e))return e}(t)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,a=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),3!==o.length);i=!0);}catch(e){a=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(a)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return c(e,3);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return c(e,3)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),o=n[0],a=n[1],u=n[2],s=void 0===u?a:u,l=void 0===u?function(e){return e}:a,d=l(o.getState());return s(d),o.subscribe(function(e){var t=l(e);(0,i.b)(d,t)||(d=t,s(t))})}function y(e,t,r){return"sessionStorage"===r?(0,s.y)()(((e,t)=>{if("getStorage"in t||"serialize"in t||"deserialize"in t)return console.warn("[DEPRECATED] `getStorage`, `serialize` and `deserialize` options are deprecated. Use `storage` option instead."),(r,n,o)=>{let i,a,s={getStorage:()=>localStorage,serialize:JSON.stringify,deserialize:JSON.parse,partialize:e=>e,version:0,merge:(e,t)=>({...t,...e}),...t},l=!1,c=new Set,d=new Set;try{i=s.getStorage()}catch(e){}if(!i)return e((...e)=>{console.warn(`[zustand persist middleware] Unable to update item '${s.name}', the given storage is currently unavailable.`),r(...e)},n,o);let f=u(s.serialize),p=()=>{let e,t=f({state:s.partialize({...n()}),version:s.version}).then(e=>i.setItem(s.name,e)).catch(t=>{e=t});if(e)throw e;return t},h=o.setState;o.setState=(e,t)=>{h(e,t),p()};let m=e((...e)=>{r(...e),p()},n,o),y=()=>{var e;if(!i)return;l=!1,c.forEach(e=>e(n()));let t=(null==(e=s.onRehydrateStorage)?void 0:e.call(s,n()))||void 0;return u(i.getItem.bind(i))(s.name).then(e=>{if(e)return s.deserialize(e)}).then(e=>{if(e)if("number"!=typeof e.version||e.version===s.version)return e.state;else{if(s.migrate)return s.migrate(e.state,e.version);console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}}).then(e=>{var t;return r(a=s.merge(e,null!=(t=n())?t:m),!0),p()}).then(()=>{null==t||t(a,void 0),l=!0,d.forEach(e=>e(a))}).catch(e=>{null==t||t(void 0,e)})};return o.persist={setOptions:e=>{s={...s,...e},e.getStorage&&(i=e.getStorage())},clearStorage:()=>{null==i||i.removeItem(s.name)},getOptions:()=>s,rehydrate:()=>y(),hasHydrated:()=>l,onHydrate:e=>(c.add(e),()=>{c.delete(e)}),onFinishHydration:e=>(d.add(e),()=>{d.delete(e)})},y(),a||m};return(r,n,o)=>{let i,s={storage:a(()=>localStorage),partialize:e=>e,version:0,merge:(e,t)=>({...t,...e}),...t},l=!1,c=new Set,d=new Set,f=s.storage;if(!f)return e((...e)=>{console.warn(`[zustand persist middleware] Unable to update item '${s.name}', the given storage is currently unavailable.`),r(...e)},n,o);let p=()=>{let e=s.partialize({...n()});return f.setItem(s.name,{state:e,version:s.version})},h=o.setState;o.setState=(e,t)=>{h(e,t),p()};let m=e((...e)=>{r(...e),p()},n,o);o.getInitialState=()=>m;let y=()=>{var e,t;if(!f)return;l=!1,c.forEach(e=>{var t;return e(null!=(t=n())?t:m)});let o=(null==(t=s.onRehydrateStorage)?void 0:t.call(s,null!=(e=n())?e:m))||void 0;return u(f.getItem.bind(f))(s.name).then(e=>{if(e)if("number"!=typeof e.version||e.version===s.version)return[!1,e.state];else{if(s.migrate)return[!0,s.migrate(e.state,e.version)];console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}return[!1,void 0]}).then(e=>{var t;let[o,a]=e;if(r(i=s.merge(a,null!=(t=n())?t:m),!0),o)return p()}).then(()=>{null==o||o(i,void 0),i=n(),l=!0,d.forEach(e=>e(i))}).catch(e=>{null==o||o(void 0,e)})};return o.persist={setOptions:e=>{s={...s,...e},e.storage&&(f=e.storage)},clearStorage:()=>{null==f||f.removeItem(s.name)},getOptions:()=>s,rehydrate:()=>y(),hasHydrated:()=>l,onHydrate:e=>(c.add(e),()=>{c.delete(e)}),onFinishHydration:e=>(d.add(e),()=>{d.delete(e)})},s.skipHydration||y(),i||m}})(function(){return t},{name:e,storage:a(function(){return sessionStorage})})):(0,s.y)()(function(){return t})}null==(n=(o=globalThis).setTimeout)||n.call(o,function(){"u">typeof window&&"development"===window.spaEnv&&(window.stores=d)},1e3)},5565(e,t,r){"use strict";r.d(t,{V:()=>c,t:()=>l});var n,o,i=(n=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},{address1:"Address line 1",address2:"Address line 2",address3:"Address line 3",address4:"Address line 4",address5:"Address line 5",address6:"Address line 6",city:"City",cityVillage:"City",country:"Country",countyDistrict:"District",district:"District",postalCode:"Postal code",state:"State",stateProvince:"State"},{closeAllOpenedWorkspaces:"Discard changes in {{count}} workspaces",closingAllWorkspacesPromptBody:"There may be unsaved changes in the following workspaces. Do you want to discard changes in the following workspaces? {{workspaceNames}}",closingAllWorkspacesPromptTitle:"You have unsaved changes",discard:"Discard",hide:"Hide",maximize:"Maximize",minimize:"Minimize",openAnyway:"Open anyway",unsavedChangesInOpenedWorkspace:"You may have unsaved changes in the opened workspace. Do you want to discard these changes?",unsavedChangesInWorkspace:'There may be unsaved changes in "{{workspaceName}}". Please save them before opening another workspace.',unsavedChangesTitleText:"Unsaved changes",workspaceHeader:"Workspace header"},{closeWorkspaces2PromptTitle:"Close workspace(s)",closeWorkspaces2PromptBody:"You are about to close the following workspace(s), which might have unsaved changes:"}),o=o={abnormalValue:"Abnormal value",actions:"Actions",actionableNotification:"Actionable notification",address:"Address",age:"Age",batchActionItemSelected:"{{totalSelected}} item selected",batchActionsItemsSelected:"{{totalSelected}} items selected",cancel:"Cancel",change:"Change",Clinic:"Clinic",close:"Close",closesActionableNotification:"Close actionable notification",closeSnackbar:"Close snackbar",confirm:"Confirm",contactAdministratorIfIssuePersists:"Contact your system administrator if the problem persists.",contactDetails:"Contact details",delete:"Delete",discardChanges:"Discard changes",edit:"Edit",emptyStateText:"There are no {{displayText}} to display",error:"Error",errorCopy:"Sorry, there was a problem displaying this information. You can try to reload this page, or contact the site administrator and quote the error code above.",errorLoadingLoginLocations:"Unable to load login locations. Please try again or contact support if the problem persists.",female:"Female",leftNavigation:"Left navigation",loading:"Loading",male:"Male",noResultsToDisplay:"No results to display",notAvailable:"Not available",other:"Other",paginationItemsCount:"{{pageItemsCount}} / {{totalItems}} items",paginationOfPages:"of {{count}} pages",patientAvatarAlt:"Avatar for {{patientName}}",patientIdentifierSticker:"Patient identifier sticker",patientLists:"Patient lists",patientPhotoAlt:"Profile photo of {{patientName}}",patientPhotoPlaceholder:"Photo placeholder for {{patientName}}",print:"Print",printError:"Print error",printErrorExplainer:"An error occurred in {{errorLocation}}",printIdentifierSticker:"Print identifier sticker",printing:"Printing",recordNewEntry:"Record {{displayText}}",relationships:"Relationships",resetOverrides:"Reset overrides",save:"Save",scriptLoadingFailed:"Error: Script failed to load",scriptLoadingError:"Failed to load overridden script from {{url}}. Please check that the bundled script is available at the expected URL. Click the button below to reset all import map overrides.",searchForLocation:"Search for a location",seeAll:"See all",seeMoreLists:"See {{count}} more lists",selectAll:"Select all",sex:"Sex",showLess:"Show less",showMore:"Show more",snackbarNotification:"Snackbar notification",toggleDevTools:"Toggle dev tools",unknown:"Unknown",yearAbbreviation:"yr",yearsAbbreviation:"yrs"},Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(o)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(o)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(o,e))}),n),a=r(6543),u=r.n(a),s=u().default||u();function l(e,t,r,n){return s.t(t,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({ns:e,defaultValue:r},n))}function c(e,t,r){return i[e]?l("core",e,null!=t?t:i[e],r):(console.error("O3 Core Translations does not provide key '".concat(e,"'. The key itself is being rendered as text.")),e)}s.on("initialized",function(){window.i18next.loadNamespaces(["core"])})},2316(e,t,r){"use strict";function n(e){return!window.offlineEnabled||(null!=e?e:navigator.onLine)}r.d(t,{s:()=>n})},8254(e,t,r){"use strict";function n(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function o(e,t){if(e===t||Object.is(e,t))return!0;if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;for(var r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}if(Array.isArray(t)||(void 0===e?"undefined":n(e))!=="object"||null===e||(void 0===t?"undefined":n(t))!=="object"||null===t)return!1;var o=Object.getOwnPropertyNames(e),i=Object.getOwnPropertyNames(t);return o.length===i.length&&o.every(function(r){return e[r]===t[r]})}r.d(t,{b:()=>o})}}]);