@openmrs/esm-cohort-builder-app 4.0.7-pre.1507 → 4.0.7-pre.1512
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.
package/dist/719.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(globalThis.webpackChunk_openmrs_esm_cohort_builder_app=globalThis.webpackChunk_openmrs_esm_cohort_builder_app||[]).push([["719"],{7581(e){e.exports=function(e,t,r){t.prototype.isToday=function(){var e="YYYY-MM-DD",t=r();return this.format(e)===t.format(e)}}},5238(e){e.exports=function(e,t,r){var n=t.prototype,o=function(e){var t=e.date,o=e.utc,a={};if(!(null===t||t instanceof Date||t instanceof Array||n.$utils().u(t)||"Object"!==t.constructor.name)){if(!Object.keys(t).length)return new Date;var i=o?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:i.date()),l=a.year||i.year(),u=a.month>=0?a.month:a.year||a.day?0:i.month(),c=a.hour||0,d=a.minute||0,f=a.second||0,p=a.millisecond||0;return o?new Date(Date.UTC(l,u,s,c,d,f,p)):new Date(l,u,s,c,d,f,p)}return t},a=n.parse;n.parse=function(e){e.date=o.bind(this)(e),a.bind(this)(e)};var i=n.set,s=n.add,l=n.subtract,u=function(e,t,r,n){void 0===n&&(n=1);var o=Object.keys(t),a=this;return o.forEach(function(r){a=e.bind(a)(t[r]*n,r)}),a};n.set=function(e,t){return t=void 0===t?e:t,"Object"===e.constructor.name?u.bind(this)(function(e,t){return i.bind(this)(t,e)},t,e):i.bind(this)(e,t)},n.add=function(e,t){return"Object"===e.constructor.name?u.bind(this)(s,e,t):s.bind(this)(e,t)},n.subtract=function(e,t){return"Object"===e.constructor.name?u.bind(this)(s,e,t,-1):l.bind(this)(e,t)}}},3826(e){e.exports=function(){"use strict";var e="minute",t=/[+-]\d\d(?::?\d\d)?/g,r=/([+-]|\d\d)/g;return function(n,o,a){var i=o.prototype;a.utc=function(e){var t={date:e,utc:!0,args:arguments};return new o(t)},i.utc=function(t){var r=a(this.toDate(),{locale:this.$L,utc:!0});return t?r.add(this.utcOffset(),e):r},i.local=function(){return a(this.toDate(),{locale:this.$L,utc:!1})};var s=i.parse;i.parse=function(e){e.utc&&(this.$u=!0),this.$utils().u(e.$offset)||(this.$offset=e.$offset),s.call(this,e)};var l=i.init;i.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 l.call(this)};var u=i.utcOffset;i.utcOffset=function(n,o){var a=this.$utils().u;if(a(n))return this.$u?0:a(this.$offset)?u.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],a=o[0],i=60*o[1]+ +o[2];return 0===i?0:"+"===a?i:-i}(n)))return this;var i=16>=Math.abs(n)?60*n:n,s=this;if(o)return s.$offset=i,s.$u=0===n,s;if(0!==n){var l=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(s=this.local().add(i+l,e)).$offset=i,s.$x.$localOffset=l}else s=this.utc();return s};var c=i.format;i.format=function(e){var t=e||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return c.call(this,t)},i.valueOf=function(){var e=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*e},i.isUTC=function(){return!!this.$u},i.toISOString=function(){return this.toDate().toISOString()},i.toString=function(){return this.toDate().toUTCString()};var d=i.toDate;i.toDate=function(e){return"s"===e&&this.$offset?a(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():d.call(this)};var f=i.diff;i.diff=function(e,t,r){if(e&&this.$u===e.$u)return f.call(this,e,t,r);var n=this.local(),o=a(e).local();return f.call(n,o,t,r)}}}()},2849(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"),a=t.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!o&&!a)return!1;for(n in e);return void 0===n||t.call(e,n)}e.exports=function e(){var t,r,o,a,i,s,l=arguments[0]||{},u=1,c=arguments.length,d=!1;for("boolean"==typeof l&&(d=l,l=arguments[1]||{},u=2),"object"!=typeof l&&"function"!=typeof l&&(l={});u<c;u++)if(null!=(t=arguments[u]))for(r in t)o=l[r],l!==(a=t[r])&&(d&&a&&(n(a)||(i=Array.isArray(a)))?(i?(i=!1,s=o&&Array.isArray(o)?o:[]):s=o&&n(o)?o:{},l[r]=e(d,s,a)):void 0!==a&&(l[r]=a));return l}},6767(e,t,r){!function(t){"use strict";var n=r(6974);function o(e){return function(t,r){return"object"==typeof t&&(r=t,t=null),null==t&&(t=new Date().toString()),r||(r={}),e.call(this,t,r)}}var a=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=a.generate(e,r);t(this).css("background-image",o.toDataUrl())})}))}("u">typeof jQuery?jQuery:null)},2467(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,a=e.b,i=Math.max(n/=255,o/=255,a/=255),s=Math.min(n,o,a),l=(i+s)/2;if(i===s)t=r=0;else{var u=i-s;switch(r=l>.5?u/(2-i-s):u/(i+s),i){case n:t=(o-a)/u+6*(o<a);break;case o:t=(a-n)/u+2;break;case a:t=(n-o)/u+4}t/=6}return{h:t,s:r,l:l}},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,a=e.h,i=e.s,s=e.l;if(0===i)r=n=o=s;else{var l=s<.5?s*(1+i):s+i-s*i,u=2*s-l;r=t(u,l,a+1/3),n=t(u,l,a),o=t(u,l,a-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(",")+")"}}},6974(e,t,r){"use strict";var n=r(2849),o=r(2467),a=r(6743),i=r(8502),s={baseColor:"#933c3c"},l=["octogons","overlappingCircles","plusSigns","xes","sineWaves","hexagons","overlappingRings","plaid","triangles","squares","concentricCircles","diamonds","tessellation","nestedSquares","mosaicSquares","chevrons"],u="#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 m=e.exports=function(e,t){return this.opts=n({},s,t),this.hash=t.hash||a(e),this.svg=new i,this.generateBackground(),this.generatePattern(),this};function h(e){return[[e,0,e,3*e],[0,e,3*e,e]]}function g(e){return[0,0,e,e,0,e,0,0].join(",")}function y(e,t,r,n,o){var a=g(n),i=p(o[0]),s=f(o[0]),l={stroke:u,"stroke-opacity":.02,"fill-opacity":i,fill:s};e.polyline(a,l).transform({translate:[t+n,r],scale:[-1,1]}),e.polyline(a,l).transform({translate:[t+n,r+2*n],scale:[1,-1]}),l={stroke:u,"stroke-opacity":.02,"fill-opacity":i=p(o[1]),fill:s=f(o[1])},e.polyline(a,l).transform({translate:[t+n,r+2*n],scale:[-1,-1]}),e.polyline(a,l).transform({translate:[t+n,r],scale:[1,1]})}function v(e,t,r,n,o){var a=p(o),i=f(o),s=g(n),l={stroke:u,"stroke-opacity":.02,"fill-opacity":a,fill:i};e.polyline(s,l).transform({translate:[t,r+n],scale:[1,-1]}),e.polyline(s,l).transform({translate:[t+2*n,r+n],scale:[-1,-1]}),e.polyline(s,l).transform({translate:[t,r+n],scale:[1,1]}),e.polyline(s,l).transform({translate:[t+2*n,r+n],scale:[-1,1]})}m.prototype.toSvg=function(){return this.svg.toString()},m.prototype.toString=function(){return this.toSvg()},m.prototype.toBase64=function(){var e=this.toSvg();return"u">typeof window&&"function"==typeof window.btoa?window.btoa(e):new Buffer(e).toString("base64")},m.prototype.toDataUri=function(){return"data:image/svg+xml;base64,"+this.toBase64()},m.prototype.toDataUrl=function(){return'url("'+this.toDataUri()+'")'},m.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)})},m.prototype.generatePattern=function(){var e=this.opts.generator;if(e){if(0>l.indexOf(e))throw Error("The generator "+e+" does not exist.")}else e=l[c(this.hash,20)];return this["geo"+e.slice(0,1).toUpperCase()+e.slice(1)]()},m.prototype.geoHexagons=function(){var e,t,r,n,o,a,i,s,l,m=d(c(this.hash,0),0,15,8,60),h=m*Math.sqrt(3),g=2*m,y=(s=m/2,[0,l=Math.sin(60*Math.PI/180)*m,s,0,s+m,0,2*m,l,s+m,2*l,s,2*l,0,l].join(","));for(this.svg.setWidth(3*g+3*m),this.svg.setHeight(6*h),t=0,i=0;i<6;i++)for(a=0;a<6;a++)o=c(this.hash,t),e=a%2==0?i*h:i*h+h/2,r=p(o),n={fill:f(o),"fill-opacity":r,stroke:u,"stroke-opacity":.02},this.svg.polyline(y,n).transform({translate:[a*m*1.5-g/2,e-h/2]}),0===a&&this.svg.polyline(y,n).transform({translate:[6*m*1.5-g/2,e-h/2]}),0===i&&(e=a%2==0?6*h:6*h+h/2,this.svg.polyline(y,n).transform({translate:[a*m*1.5-g/2,e-h/2]})),0===a&&0===i&&this.svg.polyline(y,n).transform({translate:[6*m*1.5-g/2,5*h+h/2]}),t++},m.prototype.geoSineWaves=function(){var e,t,r,n,o,a,i,s=Math.floor(d(c(this.hash,0),0,15,100,400)),l=Math.floor(d(c(this.hash,1),0,15,30,100)),u=Math.floor(d(c(this.hash,2),0,15,3,30));for(this.svg.setWidth(s),this.svg.setHeight(36*u),t=0;t<36;t++)r=p(a=c(this.hash,t)),e=f(a),i=s/4*.7,o={fill:"none",stroke:e,opacity:r,"stroke-width":""+u+"px"},n="M0 "+l+" C "+i+" 0, "+(s/2-i)+" 0, "+s/2+" "+l+" S "+(s-i)+" "+2*l+", "+s+" "+l+" S "+(1.5*s-i)+" 0, "+1.5*s+", "+l,this.svg.path(n,o).transform({translate:[-s/4,u*t-1.5*l]}),this.svg.path(n,o).transform({translate:[-s/4,u*t-1.5*l+36*u]})},m.prototype.geoChevrons=function(){var e,t,r,n,o,a,i,s=d(c(this.hash,0),0,15,30,80),l=d(c(this.hash,0),0,15,30,80),m=(e=.66*l,[[0,0,s/2,l-e,s/2,l,0,e,0,0],[s/2,l-e,s,0,s,e,s/2,l,s/2,l-e]].map(function(e){return e.join(",")}));for(this.svg.setWidth(6*s),this.svg.setHeight(6*l*.66),t=0,i=0;i<6;i++)for(a=0;a<6;a++)r=p(o=c(this.hash,t)),n={stroke:u,"stroke-opacity":.02,fill:f(o),"fill-opacity":r,"stroke-width":1},this.svg.group(n).transform({translate:[a*s,i*l*.66-l/2]}).polyline(m).end(),0===i&&this.svg.group(n).transform({translate:[a*s,6*l*.66-l/2]}).polyline(m).end(),t+=1},m.prototype.geoPlusSigns=function(){var e,t,r,n,o,a,i,s,l=d(c(this.hash,0),0,15,10,25),m=3*l,g=h(l);for(this.svg.setWidth(12*l),this.svg.setHeight(12*l),r=0,s=0;s<6;s++)for(i=0;i<6;i++)n=p(a=c(this.hash,r)),t=f(a),e=+(s%2!=0),o={fill:t,stroke:u,"stroke-opacity":.02,"fill-opacity":n},this.svg.group(o).transform({translate:[i*m-i*l+e*l-l,s*m-s*l-m/2]}).rect(g).end(),0===i&&this.svg.group(o).transform({translate:[4*m-i*l+e*l-l,s*m-s*l-m/2]}).rect(g).end(),0===s&&this.svg.group(o).transform({translate:[i*m-i*l+e*l-l,4*m-s*l-m/2]}).rect(g).end(),0===i&&0===s&&this.svg.group(o).transform({translate:[4*m-i*l+e*l-l,4*m-s*l-m/2]}).rect(g).end(),r++},m.prototype.geoXes=function(){var e,t,r,n,o,a,i,s=d(c(this.hash,0),0,15,10,25),l=h(s),u=3*s*.943;for(this.svg.setWidth(3*u),this.svg.setHeight(3*u),t=0,i=0;i<6;i++)for(a=0;a<6;a++)r=p(o=c(this.hash,t)),e=a%2==0?i*u-.5*u:i*u-.5*u+u/4,n={fill:f(o),opacity:r},this.svg.group(n).transform({translate:[a*u/2-u/2,e-i*u/2],rotate:[45,u/2,u/2]}).rect(l).end(),0===a&&this.svg.group(n).transform({translate:[6*u/2-u/2,e-i*u/2],rotate:[45,u/2,u/2]}).rect(l).end(),0===i&&(e=a%2==0?6*u-u/2:6*u-u/2+u/4,this.svg.group(n).transform({translate:[a*u/2-u/2,e-6*u/2],rotate:[45,u/2,u/2]}).rect(l).end()),5===i&&this.svg.group(n).transform({translate:[a*u/2-u/2,e-11*u/2],rotate:[45,u/2,u/2]}).rect(l).end(),0===a&&0===i&&this.svg.group(n).transform({translate:[6*u/2-u/2,e-6*u/2],rotate:[45,u/2,u/2]}).rect(l).end(),t++},m.prototype.geoOverlappingCircles=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,25,200)/2;for(this.svg.setWidth(6*i),this.svg.setHeight(6*i),e=0,a=0;a<6;a++)for(o=0;o<6;o++)t=p(n=c(this.hash,e)),r={fill:f(n),opacity:t},this.svg.circle(o*i,a*i,i,r),0===o&&this.svg.circle(6*i,a*i,i,r),0===a&&this.svg.circle(o*i,6*i,i,r),0===o&&0===a&&this.svg.circle(6*i,6*i,i,r),e++},m.prototype.geoOctogons=function(){var e,t,r,n,o,a,i,s=d(c(this.hash,0),0,15,10,60),l=[e=.33*s,0,s-e,0,s,e,s,s-e,s-e,s,e,s,0,s-e,0,e,e,0].join(",");for(this.svg.setWidth(6*s),this.svg.setHeight(6*s),r=0,i=0;i<6;i++)for(a=0;a<6;a++)n=p(o=c(this.hash,r)),t=f(o),this.svg.polyline(l,{fill:t,"fill-opacity":n,stroke:u,"stroke-opacity":.02}).transform({translate:[a*s,i*s]}),r+=1},m.prototype.geoSquares=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,10,60);for(this.svg.setWidth(6*i),this.svg.setHeight(6*i),t=0,a=0;a<6;a++)for(o=0;o<6;o++)r=p(n=c(this.hash,t)),e=f(n),this.svg.rect(o*i,a*i,i,i,{fill:e,"fill-opacity":r,stroke:u,"stroke-opacity":.02}),t+=1},m.prototype.geoConcentricCircles=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,10,60),s=i/5;for(this.svg.setWidth((i+s)*6),this.svg.setHeight((i+s)*6),t=0,a=0;a<6;a++)for(o=0;o<6;o++)r=p(n=c(this.hash,t)),e=f(n),this.svg.circle(o*i+o*s+(i+s)/2,a*i+a*s+(i+s)/2,i/2,{fill:"none",stroke:e,opacity:r,"stroke-width":s+"px"}),r=p(n=c(this.hash,39-t)),e=f(n),this.svg.circle(o*i+o*s+(i+s)/2,a*i+a*s+(i+s)/2,i/4,{fill:e,"fill-opacity":r}),t+=1},m.prototype.geoOverlappingRings=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,10,60),s=i/4;for(this.svg.setWidth(6*i),this.svg.setHeight(6*i),e=0,a=0;a<6;a++)for(o=0;o<6;o++)t=p(n=c(this.hash,e)),r={fill:"none",stroke:f(n),opacity:t,"stroke-width":s+"px"},this.svg.circle(o*i,a*i,i-s/2,r),0===o&&this.svg.circle(6*i,a*i,i-s/2,r),0===a&&this.svg.circle(o*i,6*i,i-s/2,r),0===o&&0===a&&this.svg.circle(6*i,6*i,i-s/2,r),e+=1},m.prototype.geoTriangles=function(){var e,t,r,n,o,a,i,s,l=d(c(this.hash,0),0,15,15,80),m=l/2*Math.sqrt(3),h=[s=l/2,0,l,m,0,m,s,0].join(",");for(this.svg.setWidth(3*l),this.svg.setHeight(6*m),e=0,i=0;i<6;i++)for(a=0;a<6;a++)t=p(o=c(this.hash,e)),n={fill:f(o),"fill-opacity":t,stroke:u,"stroke-opacity":.02},r=i%2==0?180*(a%2==0):180*(a%2!=0),this.svg.polyline(h,n).transform({translate:[a*l*.5-l/2,m*i],rotate:[r,l/2,m/2]}),0===a&&this.svg.polyline(h,n).transform({translate:[6*l*.5-l/2,m*i],rotate:[r,l/2,m/2]}),e+=1},m.prototype.geoDiamonds=function(){var e,t,r,n,o,a,i,s=d(c(this.hash,0),0,15,10,50),l=d(c(this.hash,1),0,15,10,50),m=[s/2,0,s,l/2,s/2,l,0,l/2].join(",");for(this.svg.setWidth(6*s),this.svg.setHeight(3*l),t=0,i=0;i<6;i++)for(a=0;a<6;a++)r=p(o=c(this.hash,t)),n={fill:f(o),"fill-opacity":r,stroke:u,"stroke-opacity":.02},e=i%2==0?0:s/2,this.svg.polyline(m,n).transform({translate:[a*s-s/2+e,l/2*i-l/2]}),0===a&&this.svg.polyline(m,n).transform({translate:[6*s-s/2+e,l/2*i-l/2]}),0===i&&this.svg.polyline(m,n).transform({translate:[a*s-s/2+e,l/2*6-l/2]}),0===a&&0===i&&this.svg.polyline(m,n).transform({translate:[6*s-s/2+e,l/2*6-l/2]}),t+=1},m.prototype.geoNestedSquares=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,4,12),s=7*i;for(this.svg.setWidth((s+i)*6+6*i),this.svg.setHeight((s+i)*6+6*i),e=0,a=0;a<6;a++)for(o=0;o<6;o++)t=p(n=c(this.hash,e)),r={fill:"none",stroke:f(n),opacity:t,"stroke-width":i+"px"},this.svg.rect(o*s+o*i*2+i/2,a*s+a*i*2+i/2,s,s,r),t=p(n=c(this.hash,39-e)),r={fill:"none",stroke:f(n),opacity:t,"stroke-width":i+"px"},this.svg.rect(o*s+o*i*2+i/2+2*i,a*s+a*i*2+i/2+2*i,3*i,3*i,r),e+=1},m.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)):y(this.svg,t*n*2,r*n*2,n,[c(this.hash,e),c(this.hash,e+1)]):r%2==0?y(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},m.prototype.geoPlaid=function(){var e,t,r,n,o,a,i=0,s=0;for(t=0;t<36;)i+=c(this.hash,t)+5,r=p(a=c(this.hash,t+1)),e=f(a),n=a+5,this.svg.rect(0,i,"100%",n,{opacity:r,fill:e}),i+=n,t+=2;for(t=0;t<36;)s+=c(this.hash,t)+5,r=p(a=c(this.hash,t+1)),e=f(a),o=a+5,this.svg.rect(s,0,o,"100%",{opacity:r,fill:e}),s+=o,t+=2;this.svg.setWidth(s),this.svg.setHeight(i)},m.prototype.geoTessellation=function(){var e,t,r,n,o=d(c(this.hash,0),0,15,5,40),a=o*Math.sqrt(3),i=2*o,s=o/2*Math.sqrt(3),l=[0,0,s,o/2,0,o,0,0].join(","),m=3*o+2*s,h=2*a+2*o;for(this.svg.setWidth(m),this.svg.setHeight(h),e=0;e<20;e++)switch(t=p(n=c(this.hash,e)),r={stroke:u,"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(m-o/2,-o/2,o,o,r),this.svg.rect(-o/2,h-o/2,o,o,r),this.svg.rect(m-o/2,h-o/2,o,o,r);break;case 1:this.svg.rect(i/2+s,a/2,o,o,r);break;case 2:this.svg.rect(-o/2,h/2-o/2,o,o,r),this.svg.rect(m-o/2,h/2-o/2,o,o,r);break;case 3:this.svg.rect(i/2+s,1.5*a+o,o,o,r);break;case 4:this.svg.polyline(l,r).transform({translate:[o/2,-o/2],rotate:[0,o/2,s/2]}),this.svg.polyline(l,r).transform({translate:[o/2,h- -o/2],rotate:[0,o/2,s/2],scale:[1,-1]});break;case 5:this.svg.polyline(l,r).transform({translate:[m-o/2,-o/2],rotate:[0,o/2,s/2],scale:[-1,1]}),this.svg.polyline(l,r).transform({translate:[m-o/2,h+o/2],rotate:[0,o/2,s/2],scale:[-1,-1]});break;case 6:this.svg.polyline(l,r).transform({translate:[m/2+o/2,a/2]});break;case 7:this.svg.polyline(l,r).transform({translate:[m-m/2-o/2,a/2],scale:[-1,1]});break;case 8:this.svg.polyline(l,r).transform({translate:[m/2+o/2,h-a/2],scale:[1,-1]});break;case 9:this.svg.polyline(l,r).transform({translate:[m-m/2-o/2,h-a/2],scale:[-1,-1]});break;case 10:this.svg.polyline(l,r).transform({translate:[o/2,h/2-o/2]});break;case 11:this.svg.polyline(l,r).transform({translate:[m-o/2,h/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:[-m+o/2,o/2],rotate:[-30,0,0]});break;case 14:this.svg.rect(0,0,o,o,r).transform({translate:[o/2,h/2-o/2-o],rotate:[30,0,o]});break;case 15:this.svg.rect(0,0,o,o,r).transform({scale:[-1,1],translate:[-m+o/2,h/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,-h+h/2-o/2-o],rotate:[30,0,o]});break;case 17:this.svg.rect(0,0,o,o,r).transform({scale:[-1,-1],translate:[-m+o/2,-h+h/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,-h+o/2],rotate:[-30,0,0]});break;case 19:this.svg.rect(0,0,o,o,r).transform({scale:[-1,-1],translate:[-m+o/2,-h+o/2],rotate:[-30,0,0]})}}},6743(e){"use strict";function t(){var e=0x67452301,t=0xefcdab89,r=0x98badcfe,n=0x10325476,o=0xc3d2e1f0,a=new Uint32Array(80),i=0,s=24,l=0;function u(){for(var s,l,u=16;u<80;u++){var c=a[u-3]^a[u-8]^a[u-14]^a[u-16];a[u]=c<<1|c>>>31}var d=e,f=t,p=r,m=n,h=o;for(u=0;u<80;u++){u<20?(s=m^f&(p^m),l=0x5a827999):u<40?(s=f^p^m,l=0x6ed9eba1):u<60?(s=f&p|m&(f|p),l=0x8f1bbcdc):(s=f^p^m,l=0xca62c1d6);var g=(d<<5|d>>>27)+s+h+l+(0|a[u]);h=m,m=p,p=f<<30|f>>>2,f=d,d=g}for(u=0,e=e+d|0,t=t+f|0,r=r+p|0,n=n+m|0,o=o+h|0,i=0;u<16;u++)a[u]=0}function c(e){a[i]|=(255&e)<<s,s?s-=8:(i++,s=24),16===i&&u()}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;l+=8*t;for(var r=0;r<t;r++)c(e.charCodeAt(r));return}var n=e.length;l+=8*n;for(var o=0;o<n;o++)c(e[o])},digest:function(){c(128),(i>14||14===i&&s<24)&&u(),i=14,s=24,c(0),c(0),c(l>0xffffffffff?l/0x10000000000:0),c(l>0xffffffff?l/0x100000000:0);for(var a=24;a>=0;a-=8)c(l>>a);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()}},8502(e,t,r){"use strict";var n=r(2849),o=r(6541);function a(){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=a,a.prototype.currentContext=function(){return this.context[this.context.length-1]||this.svg},a.prototype.end=function(){return this.context.pop(),this},a.prototype.currentNode=function(){var e=this.currentContext();return e.lastChild||e},a.prototype.transform=function(e){return this.currentNode().setAttribute("transform",Object.keys(e).map(function(t){return t+"("+e[t].join(",")+")"}).join(" ")),this},a.prototype.setAttributes=function(e,t){Object.keys(t).forEach(function(r){e.setAttribute(r,t[r])})},a.prototype.setWidth=function(e){this.svg.setAttribute("width",Math.floor(e))},a.prototype.setHeight=function(e){this.svg.setAttribute("height",Math.floor(e))},a.prototype.toString=function(){return this.svg.toString()},a.prototype.rect=function(e,t,r,a,i){var s=this;if(Array.isArray(e))return e.forEach(function(e){s.rect.apply(s,e.concat(i))}),this;var l=o("rect");return this.currentContext().appendChild(l),this.setAttributes(l,n({x:e,y:t,width:r,height:a},i)),this},a.prototype.circle=function(e,t,r,a){var i=o("circle");return this.currentContext().appendChild(i),this.setAttributes(i,n({cx:e,cy:t,r:r},a)),this},a.prototype.path=function(e,t){var r=o("path");return this.currentContext().appendChild(r),this.setAttributes(r,n({d:e},t)),this},a.prototype.polyline=function(e,t){var r=this;if(Array.isArray(e))return e.forEach(function(e){r.polyline(e,t)}),this;var a=o("polyline");return this.currentContext().appendChild(a),this.setAttributes(a,n({points:e},t)),this},a.prototype.group=function(e){var t=o("g");return this.currentContext().appendChild(t),this.context.push(t),this.setAttributes(t,n({},e)),this}},6541(e){"use strict";var t=e.exports=function(e){return 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("")}},8067(e,t){"use strict";t.pathToRegexp=function(e,t={}){let{delimiter:u="/",end:c=!0,sensitive:d=!1,trailing:f=!0}=t,p=[],m=[];for(let c of function e(t,r){if(Array.isArray(t))for(let n of t)e(n,r);else r.push(t);return r}(e,[])){let e="object"==typeof c?c:function(e,t={}){let{encodePath:i=r}=t,u=[...e],c=[],d=0,f=0;function p(){let t="";if(n.test(u[d]))do t+=u[d++];while(o.test(u[d]));else if('"'===u[d]){let r=d;for(;d++<u.length;){if('"'===u[d]){d++,r=0;break}"\\"===u[d]&&d++,t+=u[d]}if(r)throw new l(`Unterminated quote at index ${r}`,e)}if(!t)throw new l(`Missing parameter name at index ${d}`,e);return t}for(;d<u.length;){let e=u[d],t=a[e];t?c.push({type:t,index:d++,value:e}):"\\"===e?c.push({type:"escape",index:d++,value:u[d++]}):":"===e?c.push({type:"param",index:d++,value:p()}):"*"===e?c.push({type:"wildcard",index:d++,value:p()}):c.push({type:"char",index:d++,value:e})}return c.push({type:"end",index:d,value:""}),new s(function t(r){let n=[];for(;;){let o=c[f++];if(o.type===r)break;if("char"===o.type||"escape"===o.type){let e=o.value,t=c[f];for(;"char"===t.type||"escape"===t.type;)e+=t.value,t=c[++f];n.push({type:"text",value:i(e)});continue}if("param"===o.type||"wildcard"===o.type){n.push({type:o.type,name:o.value});continue}if("{"===o.type){n.push({type:"group",tokens:t("}")});continue}throw new l(`Unexpected ${o.type} at index ${o.index}, expected ${r}`,e)}return n}("end"),e)}(c,t);for(let t of function* e(t,r,n){if(r===t.length)return yield n;let o=t[r];if("group"===o.type)for(let a of e(o.tokens,0,n.slice()))yield*e(t,r+1,a);else n.push(o);yield*e(t,r+1,n)}(e.tokens,0,[]))m.push(function(e,t,r,n){let o="",a="",s=!0;for(let d of e){if("text"===d.type){o+=i(d.value),a+=d.value,s||(s=d.value.includes(t));continue}if("param"===d.type||"wildcard"===d.type){var u,c;if(!s&&!a)throw new l(`Missing text before "${d.name}" ${d.type}`,n);"param"===d.type?o+=`(${u=t,(c=s?"":a).length<2?u.length<2?`[^${i(u+c)}]`:`(?:(?!${i(u)})[^${i(c)}])`:u.length<2?`(?:(?!${i(c)})[^${i(u)}])`:`(?:(?!${i(c)}|${i(u)})[\\s\\S])`}+)`:o+="([\\s\\S]+)",r.push(d),a="",s=!1;continue}}return o}(t,u,p,e.originalPath))}let h=`^(?:${m.join("|")})`;return f&&(h+=`(?:${i(u)}$)?`),{regexp:new RegExp(h+=c?"$":`(?=${i(u)}|$)`,d?"":"i"),keys:p}};let r=e=>e,n=/^[$_\p{ID_Start}]$/u,o=/^[$\u200c\u200d\p{ID_Continue}]$/u,a={"{":"{","}":"}","(":"(",")":")","[":"[","]":"]","+":"+","?":"?","!":"!"};function i(e){return e.replace(/[.+*?^${}()[\]|/\\]/g,"\\$&")}class s{constructor(e,t){this.tokens=e,this.originalPath=t}}class l extends TypeError{constructor(e,t){let r=e;t&&(r+=`: ${t}`),super(r+="; visit https://git.new/pathToRegexpError for info"),this.originalPath=t}}},5338(e,t,r){"use strict";var n=r(1779);t.createRoot=n.createRoot,t.hydrateRoot=n.hydrateRoot},3904(e,t,r){"use strict";let n=Symbol("SemVer ANY");class o{static get ANY(){return n}constructor(e,t){if(t=a(t),e instanceof o)if(!!t.loose===e.loose)return e;else e=e.value;u("comparator",e=e.trim().split(/\s+/).join(" "),t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===n?this.value="":this.value=this.operator+this.semver.version,u("comp",this)}parse(e){let t=this.options.loose?i[s.COMPARATORLOOSE]:i[s.COMPARATOR],r=e.match(t);if(!r)throw TypeError(`Invalid comparator: ${e}`);this.operator=void 0!==r[1]?r[1]:"","="===this.operator&&(this.operator=""),r[2]?this.semver=new c(r[2],this.options.loose):this.semver=n}toString(){return this.value}test(e){if(u("Comparator.test",e,this.options.loose),this.semver===n||e===n)return!0;if("string"==typeof e)try{e=new c(e,this.options)}catch(e){return!1}return l(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof o))throw TypeError("a Comparator is required");return""===this.operator?""===this.value||new d(e.value,t).test(this.value):""===e.operator?""===e.value||new d(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("=")||l(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<")||l(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">"))}}e.exports=o;let a=r(968),{safeRe:i,t:s}=r(9718),l=r(2111),u=r(7272),c=r(3908),d=r(8311)},8311(e,t,r){"use strict";let n=/\s+/g;class o{constructor(e,t){if(t=i(t),e instanceof o)if(!!t.loose===e.loose&&!!t.includePrerelease===e.includePrerelease)return e;else return new o(e.raw,t);if(e instanceof s)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e.trim().replace(n," "),this.set=this.raw.split("||").map(e=>this.parseRange(e.trim())).filter(e=>e.length),!this.set.length)throw TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const e=this.set[0];if(this.set=this.set.filter(e=>!y(e[0])),0===this.set.length)this.set=[e];else if(this.set.length>1){for(const e of this.set)if(1===e.length&&v(e[0])){this.set=[e];break}}}this.formatted=void 0}get range(){if(void 0===this.formatted){this.formatted="";for(let e=0;e<this.set.length;e++){e>0&&(this.formatted+="||");let t=this.set[e];for(let e=0;e<t.length;e++)e>0&&(this.formatted+=" "),this.formatted+=t[e].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){let t=((this.options.includePrerelease&&h)|(this.options.loose&&g))+":"+e,r=a.get(t);if(r)return r;let n=this.options.loose,o=n?c[d.HYPHENRANGELOOSE]:c[d.HYPHENRANGE];l("hyphen replace",e=e.replace(o,R(this.options.includePrerelease))),l("comparator trim",e=e.replace(c[d.COMPARATORTRIM],f)),l("tilde trim",e=e.replace(c[d.TILDETRIM],p)),l("caret trim",e=e.replace(c[d.CARETTRIM],m));let i=e.split(" ").map(e=>w(e,this.options)).join(" ").split(/\s+/).map(e=>O(e,this.options));n&&(i=i.filter(e=>(l("loose invalid filter",e,this.options),!!e.match(c[d.COMPARATORLOOSE])))),l("range list",i);let u=new Map;for(let e of i.map(e=>new s(e,this.options))){if(y(e))return[e];u.set(e.value,e)}u.size>1&&u.has("")&&u.delete("");let v=[...u.values()];return a.set(t,v),v}intersects(e,t){if(!(e instanceof o))throw TypeError("a Range is required");return this.set.some(r=>b(r,t)&&e.set.some(e=>b(e,t)&&r.every(r=>e.every(e=>r.intersects(e,t)))))}test(e){if(!e)return!1;if("string"==typeof e)try{e=new u(e,this.options)}catch(e){return!1}for(let t=0;t<this.set.length;t++)if(T(this.set[t],e,this.options))return!0;return!1}}e.exports=o;let a=new(r(8794)),i=r(968),s=r(3904),l=r(7272),u=r(3908),{safeRe:c,t:d,comparatorTrimReplace:f,tildeTrimReplace:p,caretTrimReplace:m}=r(9718),{FLAG_INCLUDE_PRERELEASE:h,FLAG_LOOSE:g}=r(6874),y=e=>"<0.0.0-0"===e.value,v=e=>""===e.value,b=(e,t)=>{let r=!0,n=e.slice(),o=n.pop();for(;r&&n.length;)r=n.every(e=>o.intersects(e,t)),o=n.pop();return r},w=(e,t)=>(l("comp",e=e.replace(c[d.BUILD],""),t),l("caret",e=_(e,t)),l("tildes",e=x(e,t)),l("xrange",e=C(e,t)),l("stars",e=P(e,t)),e),E=e=>!e||"x"===e.toLowerCase()||"*"===e,x=(e,t)=>e.trim().split(/\s+/).map(e=>D(e,t)).join(" "),D=(e,t)=>{let r=t.loose?c[d.TILDELOOSE]:c[d.TILDE];return e.replace(r,(t,r,n,o,a)=>{let i;return l("tilde",e,t,r,n,o,a),E(r)?i="":E(n)?i=`>=${r}.0.0 <${+r+1}.0.0-0`:E(o)?i=`>=${r}.${n}.0 <${r}.${+n+1}.0-0`:a?(l("replaceTilde pr",a),i=`>=${r}.${n}.${o}-${a} <${r}.${+n+1}.0-0`):i=`>=${r}.${n}.${o} <${r}.${+n+1}.0-0`,l("tilde return",i),i})},_=(e,t)=>e.trim().split(/\s+/).map(e=>S(e,t)).join(" "),S=(e,t)=>{l("caret",e,t);let r=t.loose?c[d.CARETLOOSE]:c[d.CARET],n=t.includePrerelease?"-0":"";return e.replace(r,(t,r,o,a,i)=>{let s;return l("caret",e,t,r,o,a,i),E(r)?s="":E(o)?s=`>=${r}.0.0${n} <${+r+1}.0.0-0`:E(a)?s="0"===r?`>=${r}.${o}.0${n} <${r}.${+o+1}.0-0`:`>=${r}.${o}.0${n} <${+r+1}.0.0-0`:i?(l("replaceCaret pr",i),s="0"===r?"0"===o?`>=${r}.${o}.${a}-${i} <${r}.${o}.${+a+1}-0`:`>=${r}.${o}.${a}-${i} <${r}.${+o+1}.0-0`:`>=${r}.${o}.${a}-${i} <${+r+1}.0.0-0`):(l("no pr"),s="0"===r?"0"===o?`>=${r}.${o}.${a}${n} <${r}.${o}.${+a+1}-0`:`>=${r}.${o}.${a}${n} <${r}.${+o+1}.0-0`:`>=${r}.${o}.${a} <${+r+1}.0.0-0`),l("caret return",s),s})},C=(e,t)=>(l("replaceXRanges",e,t),e.split(/\s+/).map(e=>k(e,t)).join(" ")),k=(e,t)=>{e=e.trim();let r=t.loose?c[d.XRANGELOOSE]:c[d.XRANGE];return e.replace(r,(r,n,o,a,i,s)=>{l("xRange",e,r,n,o,a,i,s);let u=E(o),c=u||E(a),d=c||E(i);return"="===n&&d&&(n=""),s=t.includePrerelease?"-0":"",u?r=">"===n||"<"===n?"<0.0.0-0":"*":n&&d?(c&&(a=0),i=0,">"===n?(n=">=",c?(o=+o+1,a=0):a=+a+1,i=0):"<="===n&&(n="<",c?o=+o+1:a=+a+1),"<"===n&&(s="-0"),r=`${n+o}.${a}.${i}${s}`):c?r=`>=${o}.0.0${s} <${+o+1}.0.0-0`:d&&(r=`>=${o}.${a}.0${s} <${o}.${+a+1}.0-0`),l("xRange return",r),r})},P=(e,t)=>(l("replaceStars",e,t),e.trim().replace(c[d.STAR],"")),O=(e,t)=>(l("replaceGTE0",e,t),e.trim().replace(c[t.includePrerelease?d.GTE0PRE:d.GTE0],"")),R=e=>(t,r,n,o,a,i,s,l,u,c,d,f)=>(r=E(n)?"":E(o)?`>=${n}.0.0${e?"-0":""}`:E(a)?`>=${n}.${o}.0${e?"-0":""}`:i?`>=${r}`:`>=${r}${e?"-0":""}`,l=E(u)?"":E(c)?`<${+u+1}.0.0-0`:E(d)?`<${u}.${+c+1}.0-0`:f?`<=${u}.${c}.${d}-${f}`:e?`<${u}.${c}.${+d+1}-0`:`<=${l}`,`${r} ${l}`.trim()),T=(e,t,r)=>{for(let r=0;r<e.length;r++)if(!e[r].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(let r=0;r<e.length;r++)if(l(e[r].semver),e[r].semver!==s.ANY&&e[r].semver.prerelease.length>0){let n=e[r].semver;if(n.major===t.major&&n.minor===t.minor&&n.patch===t.patch)return!0}return!1}return!0}},3908(e,t,r){"use strict";let n=r(7272),{MAX_LENGTH:o,MAX_SAFE_INTEGER:a}=r(6874),{safeRe:i,t:s}=r(9718),l=r(968),{compareIdentifiers:u}=r(1123);class c{constructor(e,t){if(t=l(t),e instanceof c)if(!!t.loose===e.loose&&!!t.includePrerelease===e.includePrerelease)return e;else e=e.version;else if("string"!=typeof e)throw TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>o)throw TypeError(`version is longer than ${o} characters`);n("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;const r=e.trim().match(t.loose?i[s.LOOSE]:i[s.FULL]);if(!r)throw TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+r[1],this.minor=+r[2],this.patch=+r[3],this.major>a||this.major<0)throw TypeError("Invalid major version");if(this.minor>a||this.minor<0)throw TypeError("Invalid minor version");if(this.patch>a||this.patch<0)throw TypeError("Invalid patch version");r[4]?this.prerelease=r[4].split(".").map(e=>{if(/^[0-9]+$/.test(e)){let t=+e;if(t>=0&&t<a)return t}return e}):this.prerelease=[],this.build=r[5]?r[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(n("SemVer.compare",this.version,this.options,e),!(e instanceof c)){if("string"==typeof e&&e===this.version)return 0;e=new c(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return(e instanceof c||(e=new c(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)}comparePre(e){if(e instanceof c||(e=new c(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;let t=0;do{let r=this.prerelease[t],o=e.prerelease[t];if(n("prerelease compare",t,r,o),void 0===r&&void 0===o)return 0;if(void 0===o)return 1;if(void 0===r)return -1;else if(r===o)continue;else return u(r,o)}while(++t)}compareBuild(e){e instanceof c||(e=new c(e,this.options));let t=0;do{let r=this.build[t],o=e.build[t];if(n("build compare",t,r,o),void 0===r&&void 0===o)return 0;if(void 0===o)return 1;if(void 0===r)return -1;else if(r===o)continue;else return u(r,o)}while(++t)}inc(e,t,r){if(e.startsWith("pre")){if(!t&&!1===r)throw Error("invalid increment argument: identifier is empty");if(t){let e=`-${t}`.match(this.options.loose?i[s.PRERELEASELOOSE]:i[s.PRERELEASE]);if(!e||e[1]!==t)throw Error(`invalid identifier: ${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 ${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":{let e=+!!Number(r);if(0===this.prerelease.length)this.prerelease=[e];else{let n=this.prerelease.length;for(;--n>=0;)"number"==typeof this.prerelease[n]&&(this.prerelease[n]++,n=-2);if(-1===n){if(t===this.prerelease.join(".")&&!1===r)throw Error("invalid increment argument: identifier already exists");this.prerelease.push(e)}}if(t){let n=[t,e];!1===r&&(n=[t]),0===u(this.prerelease[0],t)?isNaN(this.prerelease[1])&&(this.prerelease=n):this.prerelease=n}break}default:throw Error(`invalid increment argument: ${e}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}}e.exports=c},2111(e,t,r){"use strict";let n=r(4641),o=r(3999),a=r(5580),i=r(4089),s=r(7059),l=r(5200);e.exports=(e,t,r,u)=>{switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e===r;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e!==r;case"":case"=":case"==":return n(e,r,u);case"!=":return o(e,r,u);case">":return a(e,r,u);case">=":return i(e,r,u);case"<":return s(e,r,u);case"<=":return l(e,r,u);default:throw TypeError(`Invalid operator: ${t}`)}}},560(e,t,r){"use strict";let n=r(3908);e.exports=(e,t,r)=>new n(e,r).compare(new n(t,r))},4641(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>0===n(e,t,r)},5580(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>n(e,t,r)>0},4089(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>n(e,t,r)>=0},7059(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>0>n(e,t,r)},5200(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>0>=n(e,t,r)},3999(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>0!==n(e,t,r)},7638(e,t,r){"use strict";let n=r(8311);e.exports=(e,t,r)=>{try{t=new n(t,r)}catch(e){return!1}return t.test(e)}},6874(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}},7272(e){"use strict";e.exports="object"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{}},1123(e){"use strict";let t=/^[0-9]+$/,r=(e,r)=>{if("number"==typeof e&&"number"==typeof r)return e===r?0:e<r?-1:1;let 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:(e,t)=>r(t,e)}},8794(e){"use strict";e.exports=class{constructor(){this.max=1e3,this.map=new Map}get(e){let t=this.map.get(e);if(void 0!==t)return this.map.delete(e),this.map.set(e,t),t}delete(e){return this.map.delete(e)}set(e,t){if(!this.delete(e)&&void 0!==t){if(this.map.size>=this.max){let e=this.map.keys().next().value;this.delete(e)}this.map.set(e,t)}return this}}},968(e){"use strict";let t=Object.freeze({loose:!0}),r=Object.freeze({});e.exports=e=>e?"object"!=typeof e?t:e:r},9718(e,t,r){"use strict";let{MAX_SAFE_COMPONENT_LENGTH:n,MAX_SAFE_BUILD_LENGTH:o,MAX_LENGTH:a}=r(6874),i=r(7272),s=(t=e.exports={}).re=[],l=t.safeRe=[],u=t.src=[],c=t.safeSrc=[],d=t.t={},f=0,p="[a-zA-Z0-9-]",m=[["\\s",1],["\\d",a],[p,o]],h=(e,t,r)=>{let n=(e=>{for(let[t,r]of m)e=e.split(`${t}*`).join(`${t}{0,${r}}`).split(`${t}+`).join(`${t}{1,${r}}`);return e})(t),o=f++;i(e,o,t),d[e]=o,u[o]=t,c[o]=n,s[o]=new RegExp(t,r?"g":void 0),l[o]=new RegExp(n,r?"g":void 0)};h("NUMERICIDENTIFIER","0|[1-9]\\d*"),h("NUMERICIDENTIFIERLOOSE","\\d+"),h("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${p}*`),h("MAINVERSION",`(${u[d.NUMERICIDENTIFIER]})\\.(${u[d.NUMERICIDENTIFIER]})\\.(${u[d.NUMERICIDENTIFIER]})`),h("MAINVERSIONLOOSE",`(${u[d.NUMERICIDENTIFIERLOOSE]})\\.(${u[d.NUMERICIDENTIFIERLOOSE]})\\.(${u[d.NUMERICIDENTIFIERLOOSE]})`),h("PRERELEASEIDENTIFIER",`(?:${u[d.NONNUMERICIDENTIFIER]}|${u[d.NUMERICIDENTIFIER]})`),h("PRERELEASEIDENTIFIERLOOSE",`(?:${u[d.NONNUMERICIDENTIFIER]}|${u[d.NUMERICIDENTIFIERLOOSE]})`),h("PRERELEASE",`(?:-(${u[d.PRERELEASEIDENTIFIER]}(?:\\.${u[d.PRERELEASEIDENTIFIER]})*))`),h("PRERELEASELOOSE",`(?:-?(${u[d.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${u[d.PRERELEASEIDENTIFIERLOOSE]})*))`),h("BUILDIDENTIFIER",`${p}+`),h("BUILD",`(?:\\+(${u[d.BUILDIDENTIFIER]}(?:\\.${u[d.BUILDIDENTIFIER]})*))`),h("FULLPLAIN",`v?${u[d.MAINVERSION]}${u[d.PRERELEASE]}?${u[d.BUILD]}?`),h("FULL",`^${u[d.FULLPLAIN]}$`),h("LOOSEPLAIN",`[v=\\s]*${u[d.MAINVERSIONLOOSE]}${u[d.PRERELEASELOOSE]}?${u[d.BUILD]}?`),h("LOOSE",`^${u[d.LOOSEPLAIN]}$`),h("GTLT","((?:<|>)?=?)"),h("XRANGEIDENTIFIERLOOSE",`${u[d.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),h("XRANGEIDENTIFIER",`${u[d.NUMERICIDENTIFIER]}|x|X|\\*`),h("XRANGEPLAIN",`[v=\\s]*(${u[d.XRANGEIDENTIFIER]})(?:\\.(${u[d.XRANGEIDENTIFIER]})(?:\\.(${u[d.XRANGEIDENTIFIER]})(?:${u[d.PRERELEASE]})?${u[d.BUILD]}?)?)?`),h("XRANGEPLAINLOOSE",`[v=\\s]*(${u[d.XRANGEIDENTIFIERLOOSE]})(?:\\.(${u[d.XRANGEIDENTIFIERLOOSE]})(?:\\.(${u[d.XRANGEIDENTIFIERLOOSE]})(?:${u[d.PRERELEASELOOSE]})?${u[d.BUILD]}?)?)?`),h("XRANGE",`^${u[d.GTLT]}\\s*${u[d.XRANGEPLAIN]}$`),h("XRANGELOOSE",`^${u[d.GTLT]}\\s*${u[d.XRANGEPLAINLOOSE]}$`),h("COERCEPLAIN",`(^|[^\\d])(\\d{1,${n}})(?:\\.(\\d{1,${n}}))?(?:\\.(\\d{1,${n}}))?`),h("COERCE",`${u[d.COERCEPLAIN]}(?:$|[^\\d])`),h("COERCEFULL",u[d.COERCEPLAIN]+`(?:${u[d.PRERELEASE]})?`+`(?:${u[d.BUILD]})?`+"(?:$|[^\\d])"),h("COERCERTL",u[d.COERCE],!0),h("COERCERTLFULL",u[d.COERCEFULL],!0),h("LONETILDE","(?:~>?)"),h("TILDETRIM",`(\\s*)${u[d.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",h("TILDE",`^${u[d.LONETILDE]}${u[d.XRANGEPLAIN]}$`),h("TILDELOOSE",`^${u[d.LONETILDE]}${u[d.XRANGEPLAINLOOSE]}$`),h("LONECARET","(?:\\^)"),h("CARETTRIM",`(\\s*)${u[d.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",h("CARET",`^${u[d.LONECARET]}${u[d.XRANGEPLAIN]}$`),h("CARETLOOSE",`^${u[d.LONECARET]}${u[d.XRANGEPLAINLOOSE]}$`),h("COMPARATORLOOSE",`^${u[d.GTLT]}\\s*(${u[d.LOOSEPLAIN]})$|^$`),h("COMPARATOR",`^${u[d.GTLT]}\\s*(${u[d.FULLPLAIN]})$|^$`),h("COMPARATORTRIM",`(\\s*)${u[d.GTLT]}\\s*(${u[d.LOOSEPLAIN]}|${u[d.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",h("HYPHENRANGE",`^\\s*(${u[d.XRANGEPLAIN]})\\s+-\\s+(${u[d.XRANGEPLAIN]})\\s*$`),h("HYPHENRANGELOOSE",`^\\s*(${u[d.XRANGEPLAINLOOSE]})\\s+-\\s+(${u[d.XRANGEPLAINLOOSE]})\\s*$`),h("STAR","(<|>)?=?\\s*\\*"),h("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),h("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")},6369(e,t,r){"use strict";function n(e){if(Array.isArray(e))return e}r.d(t,{A:()=>n})},3029(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}r.d(t,{A:()=>n})},2901(e,t,r){"use strict";r.d(t,{A:()=>a});var n=r(6192);function o(e,t){for(var r=0;r<t.length;r++){var o=t[r];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(0,n.A)(o.key),o)}}function a(e,t,r){return t&&o(e.prototype,t),r&&o(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}},4467(e,t,r){"use strict";r.d(t,{A:()=>o});var n=r(6192);function o(e,t,r){return(t=(0,n.A)(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}},6562(e,t,r){"use strict";function n(){throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}r.d(t,{A:()=>n})},6192(e,t,r){"use strict";r.d(t,{A:()=>o});var n=r(2284);function o(e){var t=function(e,t){if("object"!=(0,n.A)(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=(0,n.A)(o))return o;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==(0,n.A)(t)?t:t+""}},2284(e,t,r){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}r.d(t,{A:()=>n})},3612(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){if("string"==typeof e)return n(e,t);var r=({}).toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}}r.d(t,{A:()=>o})},4106(e,t,r){"use strict";let n,o,a,i,s,l,u,c,d,f,p;r.r(t),r.d(t,{GenderUnknownIcon:()=>pp,evaluateAsNumber:()=>lB,getImportMapOverrideMap:()=>sM,StockManagementPictogram:()=>D9,ChemistryIcon:()=>f6,BabyIcon:()=>fZ,DashboardExtension:()=>mp,openmrsComponentDecorator:()=>cY,tryRegisterExtension:()=>fn,pictogramIds:()=>DA,ActivityIcon:()=>fV,compile:()=>lH,removeRouteMapOverride:()=>ln,TableBatchActions:()=>fw,getAsyncLifecycle:()=>cJ,subscribeOpenmrsEvent:()=>lh,PasswordIcon:()=>pM,Assessment2Pictogram:()=>DL,CloseIcon:()=>pe,setupRouteMapOverrides:()=>li,useFeatureFlag:()=>dw,reset:()=>uJ,LabOrderIcon:()=>pD,VisitMode:()=>lE,useLocations:()=>dU,getLifecycle:()=>cq,formatDatetime:()=>EJ,getVisitsForPatient:()=>lO,formatPartialDate:()=>EG,CustomOverflowMenu:()=>fk,LocationIcon:()=>pS,GroupIcon:()=>ph,createUseStore:()=>cb,VisitStatus:()=>lx,getSessionLocation:()=>sf,getCurrentImportMap:()=>sY,usePatient:()=>dZ,useRenderableExtensions:()=>dq,getOpenedWindowIndexByWorkspace:()=>u9,setLeftNav:()=>uQ,clearHistory:()=>i1,clearConfigErrors:()=>oo,formatTime:()=>Eq,isDevEnabled:()=>sE,closeWorkspaceGroup2:()=>_S,getCurrentRouteMap:()=>s8,ConfigurableLink:()=>cf,sessionStore:()=>st,setSessionLocale:()=>sm,subscribeSnackbarShown:()=>S,getLoggedInUser:()=>sd,GenderMaleIcon:()=>pd,getExtensionSlotConfigFromStore:()=>ny,evaluateAsNumberAsync:()=>lU,getImportMapDefaultMap:()=>s$,unregisterExtensionRendering:()=>uy,implementerToolsConfigStore:()=>nT,Type:()=>nn,InPatientPictogram:()=>DZ,cleanupObsoleteFeatureFlags:()=>ur,getAttachmentsUrl:()=>lc,showSnackbar:()=>_d,PatientBannerActionsMenu:()=>Dk,PatientSearchPictogram:()=>D0,DocumentAttachmentIcon:()=>po,Snackbar:()=>_i,CardiologyPictogram:()=>DB,ImageMedicalIcon:()=>pv,ActionableNotificationComponent:()=>x2,DiagnosisTags:()=>xT,iconIds:()=>fU,PatientsPictogram:()=>D1,interpolateUrl:()=>iG,setupHistory:()=>iX,subscribeToastShown:()=>_,detachAll:()=>uK,convertToLocaleCalendar:()=>EX,DocumentIcon:()=>pn,configInternalStore:()=>nd,ActionMenuButton2:()=>_U,setupDynamicOfflineDataHandler:()=>Sc,makeUrl:()=>i8,oneOf:()=>od,selectPreferredName:()=>Dh,MobileCheckIcon:()=>pT,createErrorHandler:()=>P,parseDate:()=>EU,getAttachmentByUuid:()=>ll,LeftNavMenu:()=>xM,getExtensionRegistration:()=>uV,ShoppingCartAddItemIcon:()=>mc,ReferralOrderIcon:()=>pW,ReportIcon:()=>pz,dispatchToastShown:()=>E,getImportMapNextPageMap:()=>sI,registerExtension:()=>uW,setupOfflineSync:()=>Su,DownloadIcon:()=>pa,useConnectivity:()=>Sh,provide:()=>nG,ShoppingCartArrowDownIcon:()=>pX,featureFlagsStore:()=>ue,jsep:()=>lT,GeriatricsPictogram:()=>DK,SearchIcon:()=>pZ,reportError:()=>k,slugify:()=>sK,isOmrsDateToday:()=>EL,getExtensionStore:()=>uv,BloodBankPictogram:()=>DF,TriagePictogram:()=>D7,Workspace2:()=>_$,refetchCurrentUser:()=>sl,CheckmarkOutlineIcon:()=>f3,registerExtensionSlot:()=>uq,AllergiesIcon:()=>mi,ArrowDownIcon:()=>fH,useOpenmrsInfinite:()=>dO,getExtensionConfigFromExtensionSlotStore:()=>nE,OpenmrsDatePicker:()=>xO,getExtensionConfigFromStore:()=>nw,getDynamicOfflineDataEntries:()=>Sd,getLocaleDisplayName:()=>En,messageOmrsServiceWorker:()=>Sp,navigate:()=>iY,launchWorkspace2:()=>_C,getGroupByWindowName:()=>u5,CustomOverflowMenuItem:()=>fP,isUrl:()=>oc,CaretDownIcon:()=>fJ,ArrowLeftIcon:()=>fz,FacilityPictogram:()=>Dz,ViewOffIcon:()=>mn,updateInternalExtensionStore:()=>ud,dispatchActionableNotificationShown:()=>b,resetRouteMapOverrides:()=>lo,formatDurationBetween:()=>E5,defaultVisitCustomRepresentation:()=>lD,getBreadcrumbsFor:()=>ow,useOpenmrsPagination:()=>dx,Pagination:()=>Dc,CheckmarkFilledIcon:()=>f4,clearCurrentUser:()=>su,showModal:()=>xJ,ChevronUpIcon:()=>f7,saveVisit:()=>lk,useAttachments:()=>da,Pictogram:()=>_o,useExtensionSlot:()=>cS,ChevronDownIcon:()=>f5,OpenmrsDateRangePicker:()=>xR,deleteAttachmentPermanently:()=>lf,getVisitTypes:()=>lw,OverflowMenuHorizontalIcon:()=>p$,EventScheduleIcon:()=>pl,getSessionStore:()=>si,ProcedureOrderIcon:()=>pU,preloadImport:()=>sZ,registerWorkspaceWindows2:()=>u7,useOnVisible:()=>dW,setSessionLocation:()=>sp,userHasAccess:()=>sc,ChartAverageIcon:()=>f1,getFeatureFlag:()=>un,UserAvatarIcon:()=>p7,renderExtension:()=>cl,useFhirInfinite:()=>dA,toVisitTypeObject:()=>lv,useSession:()=>dJ,EmergencyDepartmentPictogram:()=>DH,Notification:()=>x0,dispatchSnackbarShown:()=>w,formatDate:()=>EZ,workspace2StoreActions:()=>_O,SwitcherIcon:()=>pq,esmStyleGuideSchema:()=>fy,getImportMapDisabledOverrides:()=>sL,useAssignedExtensionIds:()=>dr,CaretRightIcon:()=>fQ,evaluateAsType:()=>lV,PageHeader:()=>Dl,TranslateIcon:()=>p6,setUserProperties:()=>sh,MovementIcon:()=>pA,renderInlineNotifications:()=>x7,subscribePrecacheStaticDependencies:()=>Sm,PaymentsDeskPictogram:()=>D2,usePrimaryIdentifierCode:()=>dY,useLayoutType:()=>dI,getCurrentUser:()=>sa,XrayPictogram:()=>_e,CaretUpIcon:()=>f0,renderActionableNotifications:()=>Dt,OpenmrsAppContext:()=>c9,setupModals:()=>xq,getDefaultsFromConfigSchema:()=>function e(t){let r={};for(let n of Object.keys(t))if(Sn(t[n])&&t[n].hasOwnProperty("_default"))r[n]=t[n]._default;else{if(n.startsWith("_"))continue;Sn(t[n])?r[n]=e(t[n]):r[n]=t[n]}return r},subscribeTo:()=>W,recordConfigDerivationError:()=>nO,useAbortController:()=>c7,Extension:()=>cp,getFhirServerPaginationHandlers:()=>dC,useConnectedExtensions:()=>dc,registerApp:()=>fa,HospitalBedIcon:()=>py,useExtensionInternalStore:()=>dy,configExtensionStore:()=>np,getSynchronizationItems:()=>Sf,getExtensionSlotsConfigStore:()=>nh,registerExtensionRendering:()=>ug,RenderIfValueIsTruthy:()=>c8,registerFeatureFlag:()=>ut,useFhirFetchAll:()=>dj,restBaseUrl:()=>i6,CalendarHeatMapIcon:()=>fY,isImportMapOverrideDisabled:()=>sF,resetConfigSystem:()=>oa,getExtensionInternalStore:()=>uu,registerGlobalStore:()=>U,evaluateAsBoolean:()=>lL,PatientBannerPatientInfo:()=>DS,addRouteMapOverride:()=>lr,getDefaultCalendar:()=>Ez,SettingsIcon:()=>pY,DrugOrderIcon:()=>pi,ProgramsIcon:()=>pV,useAssignedExtensions:()=>c_,CloseFilledIcon:()=>pt,canAccessStorage:()=>Sr,registerDefaultCalendar:()=>EH,TreeViewAltIcon:()=>p9,OverflowMenuVerticalIcon:()=>pI,clearConfigDerivationError:()=>nR,getConfigStore:()=>nm,InformationSquareIcon:()=>pE,EmptyCard:()=>xA,ChevronLeftIcon:()=>f9,RadiologyIcon:()=>mu,useCandidateExtensions:()=>dn,renderToasts:()=>_g,isDesktop:()=>dM,integrateBreakpoints:()=>fc,RegistrationPictogram:()=>D6,CardHeader:()=>fm,getExtensionRegistrationFrom:()=>uU,InformationIcon:()=>pb,TrashCanIcon:()=>p5,useShallowStableValue:()=>cm,PatientDocumentsPictogram:()=>DQ,useOpenmrsSWR:()=>dH,Assessment1Pictogram:()=>DM,finishRegisteringAllApps:()=>fi,importDynamic:()=>sG,useFhirPagination:()=>dS,useVisitContextStore:()=>d6,ArrowUpIcon:()=>fG,showActionableNotification:()=>Dr,useForceUpdate:()=>dE,useVisit:()=>d5,PatientBannerPatientIdentifiers:()=>DE,TransferPictogram:()=>D8,usePagination:()=>dz,Breakpoint:()=>fs,PatientBannerToggleContactDetailsButton:()=>_V,CloseOutlineIcon:()=>pr,ObstetricsPictogram:()=>DX,parseDateInput:()=>E0,getConfig:()=>nY,attach:()=>uH,getLocale:()=>Eo,isUrlWithTemplateParameters:()=>ou,useEmrConfiguration:()=>dh,useLeftNav:()=>dL,ToolsIcon:()=>p3,ErrorState:()=>x$,detach:()=>uz,setCurrentVisit:()=>lC,ConditionsIcon:()=>ml,SaveIcon:()=>pG,useConfig:()=>du,validator:()=>no,CalendarIcon:()=>fq,getHistory:()=>iQ,StickyNoteAddIcon:()=>pQ,useWorkspace2Store:()=>_R,getPatientName:()=>Dd,getVisitStore:()=>lS,getCoreTranslation:()=>iK,registerModuleWithConfigSystem:()=>nW,registerModuleLoad:()=>nH,getBreadcrumbs:()=>oy,extractVariableNames:()=>l9,translateFrom:()=>iz,useStoreWithActions:()=>cv,EditIcon:()=>ps,getCandidateExtensions:()=>uY,shallowEqual:()=>R,subscribeNotificationShown:()=>x,MaximizeIcon:()=>pk,promptForClosingWorkspaces:()=>_P,WarningIcon:()=>ma,fhirBaseUrl:()=>i5,matchLocale:()=>St,usePatientPhoto:()=>DR,registerBreadcrumb:()=>oh,EventsIcon:()=>pu,createGlobalStore:()=>B,subscribeToFeatureFlag:()=>uo,useExtensionStore:()=>db,createAttachment:()=>ld,useLeftNavStore:()=>dF,TableIcon:()=>p2,Icon:()=>mf,InformationFilledIcon:()=>pw,getCurrentPageMap:()=>sA,LaboratoryPictogram:()=>DY,temporaryConfigStore:()=>nf,toDateObjectStrict:()=>EF,defineConfigSchema:()=>nV,filterBreadcrumbs:()=>ob,invalidateImplementerToolsConfig:()=>nk,PatientBannerContactDetails:()=>_Z,getAssignedExtensions:()=>uZ,PatientPhoto:()=>Dj,MaterialOrderIcon:()=>pC,MicroscopeIcon:()=>pR,visitTypesUrl:()=>lb,scheduleRecomputation:()=>uD,PharmacyPictogram:()=>D4,AttachmentIcon:()=>ms,MoneyIcon:()=>pN,getAttachments:()=>lu,PageHeaderContent:()=>Du,MedicationIcon:()=>pP,PrinterIcon:()=>pB,PatientListsPictogram:()=>_r,useAppContext:()=>de,isOpenmrsRoutes:()=>sX,AppointmentsAltPictogram:()=>DI,GenericOrderTypeIcon:()=>pm,batchExtensionUpdates:()=>uE,useExtensionSlotStore:()=>cx,ViewIcon:()=>mo,formattedName:()=>Dm,sessionEndpoint:()=>i9,duration:()=>E3,resetImportMapOverrides:()=>sV,TableOfContentsIcon:()=>p1,CaretLeftIcon:()=>fX,getTranslationOverrides:()=>nq,isVersionSatisfied:()=>Si,EmptyCardIllustration:()=>xj,PenIcon:()=>pF,verifyTotpCode:()=>sg,validators:()=>of,setupImportMapOverrides:()=>sz,showToast:()=>_y,useDefineAppContext:()=>c5,getGlobalStore:()=>V,useOnClickOutside:()=>dV,getWindowByWorkspaceName:()=>u6,ArrowRightIcon:()=>fK,loadLifeCycles:()=>fe,registerBreadcrumbs:()=>og,MotherIcon:()=>pj,fetchCurrentPatient:()=>lp,Toast:()=>_f,MessageQueueIcon:()=>pO,TwoFactorAuthenticationIcon:()=>p8,Pharmacy2Pictogram:()=>D3,goBackInHistory:()=>i0,GroupAccessIcon:()=>pg,getExtensionRenderingsStore:()=>uc,setImplementerToolsConfigRecomputer:()=>nC,getAsyncExtensionLifecycle:()=>cQ,setupApiModule:()=>sD,renderLoadingSpinner:()=>_Y,showNotification:()=>De,getModalRegistration:()=>u4,ListCheckedIcon:()=>p_,ResponsiveWrapper:()=>_a,GynaecologyPictogram:()=>DG,ShoppingCartIcon:()=>pJ,getRouteMapNextPageMap:()=>le,MetadataExportPictogram:()=>DJ,updateVisit:()=>lP,backendDependencies:()=>sx,MaybePictogram:()=>_n,createParcelMounter:()=>ci,openmrsFetch:()=>i7,useStore:()=>cy,isOpenmrsAppRoutes:()=>sJ,HomePictogram:()=>_t,DentistryPictogram:()=>DV,ServiceQueuesPictogram:()=>D5,toLanguageTag:()=>Er,setFeatureFlag:()=>ua,DigitalTrustPictogram:()=>DW,NumericObservation:()=>Di,attachmentUrl:()=>ls,interpolateString:()=>iZ,inRange:()=>ol,useExtensionSlotMeta:()=>dv,AppointmentsPictogram:()=>D$,renderSnackbars:()=>_c,getRegisteredWorkspace2Names:()=>_N,logout:()=>sy,toLocationObject:()=>lg,ChartLineIcon:()=>f2,UserHasAccess:()=>dX,evaluateAsBooleanAsync:()=>lF,createDashboard:()=>mm,getLocations:()=>ly,useExtensionContext:()=>dg,getExtensionsConfigStore:()=>nv,getRouteMapDefaultMap:()=>s7,age:()=>Dy,isOmrsDateStrict:()=>EM,registerWorkspaceGroups2:()=>u8,usePaginationInfo:()=>dK,evaluateAsync:()=>lM,useOpenmrsFetchAll:()=>dT,removeImportMapOverride:()=>sU,useVisitTypes:()=>d8,ageAsDuration:()=>Dg,getExtensionNameFromId:()=>uB,renderParcel:()=>ca,useWorkspace2Context:()=>_T,ResetIcon:()=>pK,RenewIcon:()=>pH,subscribeActionableNotificationShown:()=>D,ErrorCard:()=>xI,GenderFemaleIcon:()=>pc,enableImportMapOverride:()=>sW,retry:()=>Ss,ComponentContext:()=>cd,ExtensionSlot:()=>ck,unsetLeftNav:()=>u0,addImportMapOverride:()=>sB,MaybeIcon:()=>md,useCustomOverflowMenu:()=>fC,PedestrianFamilyIcon:()=>pL,CtScanPictogram:()=>DU,dispatchNotificationShown:()=>v,leftNavStore:()=>uX,OpenmrsFetchError:()=>se,UserFollowIcon:()=>me,launchWorkspaceGroup2:()=>__,ChevronRightIcon:()=>f8,UserXrayIcon:()=>mt,GenderOtherIcon:()=>pf,formatDuration:()=>EQ,toOmrsIsoString:()=>EB,Labs2Pictogram:()=>Dq,workspace2Store:()=>u3,setUserLanguage:()=>ss,useBodyScrollLock:()=>di,getExtensionConfig:()=>nb,SyringeIcon:()=>p0,LocationPicker:()=>xL,useDebounce:()=>dd,TimeIcon:()=>p4,getExtensionSlotConfig:()=>ng,AddIcon:()=>fW,getRouteMapOverrideMap:()=>lt,processConfig:()=>nJ,InventoryManagementIcon:()=>px,registerWorkspaces2:()=>ce,UserIcon:()=>mr,formatPatientName:()=>Dp,fireOpenmrsEvent:()=>lm,registerModal:()=>u2,registerTranslationNamespace:()=>nz,displayName:()=>Df,evaluate:()=>lI,defineExtensionConfigSchema:()=>nK,renderWorkspaceWindowsAndMenu:()=>_7,getSyncLifecycle:()=>cX,evaluateAsTypeAsync:()=>lW});let m="openmrs:notification-shown",h="openmrs:actionable-notification-shown",g="openmrs:toast-shown",y="openmrs:snack-bar-shown";function v(e){window.dispatchEvent(new CustomEvent(m,{detail:e}))}function b(e){window.dispatchEvent(new CustomEvent(h,{detail:e}))}function w(e){window.dispatchEvent(new CustomEvent(y,{detail:e}))}function E(e){window.dispatchEvent(new CustomEvent(g,{detail:e}))}function x(e){let t=t=>e(t.detail);return window.addEventListener(m,t),()=>window.removeEventListener(m,t)}function D(e){let t=t=>e(t.detail);return window.addEventListener(h,t),()=>window.removeEventListener(h,t)}function _(e){let t=t=>e(t.detail);return window.addEventListener(g,t),()=>window.removeEventListener(g,t)}function S(e){let t=t=>e(t.detail);return window.addEventListener(y,t),()=>window.removeEventListener(y,t)}function C(e,t){let{message:r}=O(e);return"string"==typeof r&&r?r:t}function k(e){let t=O(e);setTimeout(()=>{throw t})}function P(){let e=Error();return t=>{let r=O(t);r.stack+=`
|
|
1
|
+
(globalThis.webpackChunk_openmrs_esm_cohort_builder_app=globalThis.webpackChunk_openmrs_esm_cohort_builder_app||[]).push([["719"],{7581(e){e.exports=function(e,t,r){t.prototype.isToday=function(){var e="YYYY-MM-DD",t=r();return this.format(e)===t.format(e)}}},5238(e){e.exports=function(e,t,r){var n=t.prototype,o=function(e){var t=e.date,o=e.utc,a={};if(!(null===t||t instanceof Date||t instanceof Array||n.$utils().u(t)||"Object"!==t.constructor.name)){if(!Object.keys(t).length)return new Date;var i=o?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:i.date()),l=a.year||i.year(),u=a.month>=0?a.month:a.year||a.day?0:i.month(),c=a.hour||0,d=a.minute||0,f=a.second||0,p=a.millisecond||0;return o?new Date(Date.UTC(l,u,s,c,d,f,p)):new Date(l,u,s,c,d,f,p)}return t},a=n.parse;n.parse=function(e){e.date=o.bind(this)(e),a.bind(this)(e)};var i=n.set,s=n.add,l=n.subtract,u=function(e,t,r,n){void 0===n&&(n=1);var o=Object.keys(t),a=this;return o.forEach(function(r){a=e.bind(a)(t[r]*n,r)}),a};n.set=function(e,t){return t=void 0===t?e:t,"Object"===e.constructor.name?u.bind(this)(function(e,t){return i.bind(this)(t,e)},t,e):i.bind(this)(e,t)},n.add=function(e,t){return"Object"===e.constructor.name?u.bind(this)(s,e,t):s.bind(this)(e,t)},n.subtract=function(e,t){return"Object"===e.constructor.name?u.bind(this)(s,e,t,-1):l.bind(this)(e,t)}}},3826(e){e.exports=function(){"use strict";var e="minute",t=/[+-]\d\d(?::?\d\d)?/g,r=/([+-]|\d\d)/g;return function(n,o,a){var i=o.prototype;a.utc=function(e){var t={date:e,utc:!0,args:arguments};return new o(t)},i.utc=function(t){var r=a(this.toDate(),{locale:this.$L,utc:!0});return t?r.add(this.utcOffset(),e):r},i.local=function(){return a(this.toDate(),{locale:this.$L,utc:!1})};var s=i.parse;i.parse=function(e){e.utc&&(this.$u=!0),this.$utils().u(e.$offset)||(this.$offset=e.$offset),s.call(this,e)};var l=i.init;i.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 l.call(this)};var u=i.utcOffset;i.utcOffset=function(n,o){var a=this.$utils().u;if(a(n))return this.$u?0:a(this.$offset)?u.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],a=o[0],i=60*o[1]+ +o[2];return 0===i?0:"+"===a?i:-i}(n)))return this;var i=16>=Math.abs(n)?60*n:n,s=this;if(o)return s.$offset=i,s.$u=0===n,s;if(0!==n){var l=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(s=this.local().add(i+l,e)).$offset=i,s.$x.$localOffset=l}else s=this.utc();return s};var c=i.format;i.format=function(e){var t=e||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return c.call(this,t)},i.valueOf=function(){var e=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*e},i.isUTC=function(){return!!this.$u},i.toISOString=function(){return this.toDate().toISOString()},i.toString=function(){return this.toDate().toUTCString()};var d=i.toDate;i.toDate=function(e){return"s"===e&&this.$offset?a(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():d.call(this)};var f=i.diff;i.diff=function(e,t,r){if(e&&this.$u===e.$u)return f.call(this,e,t,r);var n=this.local(),o=a(e).local();return f.call(n,o,t,r)}}}()},2849(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"),a=t.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!o&&!a)return!1;for(n in e);return void 0===n||t.call(e,n)}e.exports=function e(){var t,r,o,a,i,s,l=arguments[0]||{},u=1,c=arguments.length,d=!1;for("boolean"==typeof l&&(d=l,l=arguments[1]||{},u=2),"object"!=typeof l&&"function"!=typeof l&&(l={});u<c;u++)if(null!=(t=arguments[u]))for(r in t)o=l[r],l!==(a=t[r])&&(d&&a&&(n(a)||(i=Array.isArray(a)))?(i?(i=!1,s=o&&Array.isArray(o)?o:[]):s=o&&n(o)?o:{},l[r]=e(d,s,a)):void 0!==a&&(l[r]=a));return l}},6767(e,t,r){!function(t){"use strict";var n=r(6974);function o(e){return function(t,r){return"object"==typeof t&&(r=t,t=null),null==t&&(t=new Date().toString()),r||(r={}),e.call(this,t,r)}}var a=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=a.generate(e,r);t(this).css("background-image",o.toDataUrl())})}))}("u">typeof jQuery?jQuery:null)},2467(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,a=e.b,i=Math.max(n/=255,o/=255,a/=255),s=Math.min(n,o,a),l=(i+s)/2;if(i===s)t=r=0;else{var u=i-s;switch(r=l>.5?u/(2-i-s):u/(i+s),i){case n:t=(o-a)/u+6*(o<a);break;case o:t=(a-n)/u+2;break;case a:t=(n-o)/u+4}t/=6}return{h:t,s:r,l:l}},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,a=e.h,i=e.s,s=e.l;if(0===i)r=n=o=s;else{var l=s<.5?s*(1+i):s+i-s*i,u=2*s-l;r=t(u,l,a+1/3),n=t(u,l,a),o=t(u,l,a-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(",")+")"}}},6974(e,t,r){"use strict";var n=r(2849),o=r(2467),a=r(6743),i=r(8502),s={baseColor:"#933c3c"},l=["octogons","overlappingCircles","plusSigns","xes","sineWaves","hexagons","overlappingRings","plaid","triangles","squares","concentricCircles","diamonds","tessellation","nestedSquares","mosaicSquares","chevrons"],u="#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 m=e.exports=function(e,t){return this.opts=n({},s,t),this.hash=t.hash||a(e),this.svg=new i,this.generateBackground(),this.generatePattern(),this};function h(e){return[[e,0,e,3*e],[0,e,3*e,e]]}function g(e){return[0,0,e,e,0,e,0,0].join(",")}function y(e,t,r,n,o){var a=g(n),i=p(o[0]),s=f(o[0]),l={stroke:u,"stroke-opacity":.02,"fill-opacity":i,fill:s};e.polyline(a,l).transform({translate:[t+n,r],scale:[-1,1]}),e.polyline(a,l).transform({translate:[t+n,r+2*n],scale:[1,-1]}),l={stroke:u,"stroke-opacity":.02,"fill-opacity":i=p(o[1]),fill:s=f(o[1])},e.polyline(a,l).transform({translate:[t+n,r+2*n],scale:[-1,-1]}),e.polyline(a,l).transform({translate:[t+n,r],scale:[1,1]})}function v(e,t,r,n,o){var a=p(o),i=f(o),s=g(n),l={stroke:u,"stroke-opacity":.02,"fill-opacity":a,fill:i};e.polyline(s,l).transform({translate:[t,r+n],scale:[1,-1]}),e.polyline(s,l).transform({translate:[t+2*n,r+n],scale:[-1,-1]}),e.polyline(s,l).transform({translate:[t,r+n],scale:[1,1]}),e.polyline(s,l).transform({translate:[t+2*n,r+n],scale:[-1,1]})}m.prototype.toSvg=function(){return this.svg.toString()},m.prototype.toString=function(){return this.toSvg()},m.prototype.toBase64=function(){var e=this.toSvg();return"u">typeof window&&"function"==typeof window.btoa?window.btoa(e):new Buffer(e).toString("base64")},m.prototype.toDataUri=function(){return"data:image/svg+xml;base64,"+this.toBase64()},m.prototype.toDataUrl=function(){return'url("'+this.toDataUri()+'")'},m.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)})},m.prototype.generatePattern=function(){var e=this.opts.generator;if(e){if(0>l.indexOf(e))throw Error("The generator "+e+" does not exist.")}else e=l[c(this.hash,20)];return this["geo"+e.slice(0,1).toUpperCase()+e.slice(1)]()},m.prototype.geoHexagons=function(){var e,t,r,n,o,a,i,s,l,m=d(c(this.hash,0),0,15,8,60),h=m*Math.sqrt(3),g=2*m,y=(s=m/2,[0,l=Math.sin(60*Math.PI/180)*m,s,0,s+m,0,2*m,l,s+m,2*l,s,2*l,0,l].join(","));for(this.svg.setWidth(3*g+3*m),this.svg.setHeight(6*h),t=0,i=0;i<6;i++)for(a=0;a<6;a++)o=c(this.hash,t),e=a%2==0?i*h:i*h+h/2,r=p(o),n={fill:f(o),"fill-opacity":r,stroke:u,"stroke-opacity":.02},this.svg.polyline(y,n).transform({translate:[a*m*1.5-g/2,e-h/2]}),0===a&&this.svg.polyline(y,n).transform({translate:[6*m*1.5-g/2,e-h/2]}),0===i&&(e=a%2==0?6*h:6*h+h/2,this.svg.polyline(y,n).transform({translate:[a*m*1.5-g/2,e-h/2]})),0===a&&0===i&&this.svg.polyline(y,n).transform({translate:[6*m*1.5-g/2,5*h+h/2]}),t++},m.prototype.geoSineWaves=function(){var e,t,r,n,o,a,i,s=Math.floor(d(c(this.hash,0),0,15,100,400)),l=Math.floor(d(c(this.hash,1),0,15,30,100)),u=Math.floor(d(c(this.hash,2),0,15,3,30));for(this.svg.setWidth(s),this.svg.setHeight(36*u),t=0;t<36;t++)r=p(a=c(this.hash,t)),e=f(a),i=s/4*.7,o={fill:"none",stroke:e,opacity:r,"stroke-width":""+u+"px"},n="M0 "+l+" C "+i+" 0, "+(s/2-i)+" 0, "+s/2+" "+l+" S "+(s-i)+" "+2*l+", "+s+" "+l+" S "+(1.5*s-i)+" 0, "+1.5*s+", "+l,this.svg.path(n,o).transform({translate:[-s/4,u*t-1.5*l]}),this.svg.path(n,o).transform({translate:[-s/4,u*t-1.5*l+36*u]})},m.prototype.geoChevrons=function(){var e,t,r,n,o,a,i,s=d(c(this.hash,0),0,15,30,80),l=d(c(this.hash,0),0,15,30,80),m=(e=.66*l,[[0,0,s/2,l-e,s/2,l,0,e,0,0],[s/2,l-e,s,0,s,e,s/2,l,s/2,l-e]].map(function(e){return e.join(",")}));for(this.svg.setWidth(6*s),this.svg.setHeight(6*l*.66),t=0,i=0;i<6;i++)for(a=0;a<6;a++)r=p(o=c(this.hash,t)),n={stroke:u,"stroke-opacity":.02,fill:f(o),"fill-opacity":r,"stroke-width":1},this.svg.group(n).transform({translate:[a*s,i*l*.66-l/2]}).polyline(m).end(),0===i&&this.svg.group(n).transform({translate:[a*s,6*l*.66-l/2]}).polyline(m).end(),t+=1},m.prototype.geoPlusSigns=function(){var e,t,r,n,o,a,i,s,l=d(c(this.hash,0),0,15,10,25),m=3*l,g=h(l);for(this.svg.setWidth(12*l),this.svg.setHeight(12*l),r=0,s=0;s<6;s++)for(i=0;i<6;i++)n=p(a=c(this.hash,r)),t=f(a),e=+(s%2!=0),o={fill:t,stroke:u,"stroke-opacity":.02,"fill-opacity":n},this.svg.group(o).transform({translate:[i*m-i*l+e*l-l,s*m-s*l-m/2]}).rect(g).end(),0===i&&this.svg.group(o).transform({translate:[4*m-i*l+e*l-l,s*m-s*l-m/2]}).rect(g).end(),0===s&&this.svg.group(o).transform({translate:[i*m-i*l+e*l-l,4*m-s*l-m/2]}).rect(g).end(),0===i&&0===s&&this.svg.group(o).transform({translate:[4*m-i*l+e*l-l,4*m-s*l-m/2]}).rect(g).end(),r++},m.prototype.geoXes=function(){var e,t,r,n,o,a,i,s=d(c(this.hash,0),0,15,10,25),l=h(s),u=3*s*.943;for(this.svg.setWidth(3*u),this.svg.setHeight(3*u),t=0,i=0;i<6;i++)for(a=0;a<6;a++)r=p(o=c(this.hash,t)),e=a%2==0?i*u-.5*u:i*u-.5*u+u/4,n={fill:f(o),opacity:r},this.svg.group(n).transform({translate:[a*u/2-u/2,e-i*u/2],rotate:[45,u/2,u/2]}).rect(l).end(),0===a&&this.svg.group(n).transform({translate:[6*u/2-u/2,e-i*u/2],rotate:[45,u/2,u/2]}).rect(l).end(),0===i&&(e=a%2==0?6*u-u/2:6*u-u/2+u/4,this.svg.group(n).transform({translate:[a*u/2-u/2,e-6*u/2],rotate:[45,u/2,u/2]}).rect(l).end()),5===i&&this.svg.group(n).transform({translate:[a*u/2-u/2,e-11*u/2],rotate:[45,u/2,u/2]}).rect(l).end(),0===a&&0===i&&this.svg.group(n).transform({translate:[6*u/2-u/2,e-6*u/2],rotate:[45,u/2,u/2]}).rect(l).end(),t++},m.prototype.geoOverlappingCircles=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,25,200)/2;for(this.svg.setWidth(6*i),this.svg.setHeight(6*i),e=0,a=0;a<6;a++)for(o=0;o<6;o++)t=p(n=c(this.hash,e)),r={fill:f(n),opacity:t},this.svg.circle(o*i,a*i,i,r),0===o&&this.svg.circle(6*i,a*i,i,r),0===a&&this.svg.circle(o*i,6*i,i,r),0===o&&0===a&&this.svg.circle(6*i,6*i,i,r),e++},m.prototype.geoOctogons=function(){var e,t,r,n,o,a,i,s=d(c(this.hash,0),0,15,10,60),l=[e=.33*s,0,s-e,0,s,e,s,s-e,s-e,s,e,s,0,s-e,0,e,e,0].join(",");for(this.svg.setWidth(6*s),this.svg.setHeight(6*s),r=0,i=0;i<6;i++)for(a=0;a<6;a++)n=p(o=c(this.hash,r)),t=f(o),this.svg.polyline(l,{fill:t,"fill-opacity":n,stroke:u,"stroke-opacity":.02}).transform({translate:[a*s,i*s]}),r+=1},m.prototype.geoSquares=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,10,60);for(this.svg.setWidth(6*i),this.svg.setHeight(6*i),t=0,a=0;a<6;a++)for(o=0;o<6;o++)r=p(n=c(this.hash,t)),e=f(n),this.svg.rect(o*i,a*i,i,i,{fill:e,"fill-opacity":r,stroke:u,"stroke-opacity":.02}),t+=1},m.prototype.geoConcentricCircles=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,10,60),s=i/5;for(this.svg.setWidth((i+s)*6),this.svg.setHeight((i+s)*6),t=0,a=0;a<6;a++)for(o=0;o<6;o++)r=p(n=c(this.hash,t)),e=f(n),this.svg.circle(o*i+o*s+(i+s)/2,a*i+a*s+(i+s)/2,i/2,{fill:"none",stroke:e,opacity:r,"stroke-width":s+"px"}),r=p(n=c(this.hash,39-t)),e=f(n),this.svg.circle(o*i+o*s+(i+s)/2,a*i+a*s+(i+s)/2,i/4,{fill:e,"fill-opacity":r}),t+=1},m.prototype.geoOverlappingRings=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,10,60),s=i/4;for(this.svg.setWidth(6*i),this.svg.setHeight(6*i),e=0,a=0;a<6;a++)for(o=0;o<6;o++)t=p(n=c(this.hash,e)),r={fill:"none",stroke:f(n),opacity:t,"stroke-width":s+"px"},this.svg.circle(o*i,a*i,i-s/2,r),0===o&&this.svg.circle(6*i,a*i,i-s/2,r),0===a&&this.svg.circle(o*i,6*i,i-s/2,r),0===o&&0===a&&this.svg.circle(6*i,6*i,i-s/2,r),e+=1},m.prototype.geoTriangles=function(){var e,t,r,n,o,a,i,s,l=d(c(this.hash,0),0,15,15,80),m=l/2*Math.sqrt(3),h=[s=l/2,0,l,m,0,m,s,0].join(",");for(this.svg.setWidth(3*l),this.svg.setHeight(6*m),e=0,i=0;i<6;i++)for(a=0;a<6;a++)t=p(o=c(this.hash,e)),n={fill:f(o),"fill-opacity":t,stroke:u,"stroke-opacity":.02},r=i%2==0?180*(a%2==0):180*(a%2!=0),this.svg.polyline(h,n).transform({translate:[a*l*.5-l/2,m*i],rotate:[r,l/2,m/2]}),0===a&&this.svg.polyline(h,n).transform({translate:[6*l*.5-l/2,m*i],rotate:[r,l/2,m/2]}),e+=1},m.prototype.geoDiamonds=function(){var e,t,r,n,o,a,i,s=d(c(this.hash,0),0,15,10,50),l=d(c(this.hash,1),0,15,10,50),m=[s/2,0,s,l/2,s/2,l,0,l/2].join(",");for(this.svg.setWidth(6*s),this.svg.setHeight(3*l),t=0,i=0;i<6;i++)for(a=0;a<6;a++)r=p(o=c(this.hash,t)),n={fill:f(o),"fill-opacity":r,stroke:u,"stroke-opacity":.02},e=i%2==0?0:s/2,this.svg.polyline(m,n).transform({translate:[a*s-s/2+e,l/2*i-l/2]}),0===a&&this.svg.polyline(m,n).transform({translate:[6*s-s/2+e,l/2*i-l/2]}),0===i&&this.svg.polyline(m,n).transform({translate:[a*s-s/2+e,l/2*6-l/2]}),0===a&&0===i&&this.svg.polyline(m,n).transform({translate:[6*s-s/2+e,l/2*6-l/2]}),t+=1},m.prototype.geoNestedSquares=function(){var e,t,r,n,o,a,i=d(c(this.hash,0),0,15,4,12),s=7*i;for(this.svg.setWidth((s+i)*6+6*i),this.svg.setHeight((s+i)*6+6*i),e=0,a=0;a<6;a++)for(o=0;o<6;o++)t=p(n=c(this.hash,e)),r={fill:"none",stroke:f(n),opacity:t,"stroke-width":i+"px"},this.svg.rect(o*s+o*i*2+i/2,a*s+a*i*2+i/2,s,s,r),t=p(n=c(this.hash,39-e)),r={fill:"none",stroke:f(n),opacity:t,"stroke-width":i+"px"},this.svg.rect(o*s+o*i*2+i/2+2*i,a*s+a*i*2+i/2+2*i,3*i,3*i,r),e+=1},m.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)):y(this.svg,t*n*2,r*n*2,n,[c(this.hash,e),c(this.hash,e+1)]):r%2==0?y(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},m.prototype.geoPlaid=function(){var e,t,r,n,o,a,i=0,s=0;for(t=0;t<36;)i+=c(this.hash,t)+5,r=p(a=c(this.hash,t+1)),e=f(a),n=a+5,this.svg.rect(0,i,"100%",n,{opacity:r,fill:e}),i+=n,t+=2;for(t=0;t<36;)s+=c(this.hash,t)+5,r=p(a=c(this.hash,t+1)),e=f(a),o=a+5,this.svg.rect(s,0,o,"100%",{opacity:r,fill:e}),s+=o,t+=2;this.svg.setWidth(s),this.svg.setHeight(i)},m.prototype.geoTessellation=function(){var e,t,r,n,o=d(c(this.hash,0),0,15,5,40),a=o*Math.sqrt(3),i=2*o,s=o/2*Math.sqrt(3),l=[0,0,s,o/2,0,o,0,0].join(","),m=3*o+2*s,h=2*a+2*o;for(this.svg.setWidth(m),this.svg.setHeight(h),e=0;e<20;e++)switch(t=p(n=c(this.hash,e)),r={stroke:u,"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(m-o/2,-o/2,o,o,r),this.svg.rect(-o/2,h-o/2,o,o,r),this.svg.rect(m-o/2,h-o/2,o,o,r);break;case 1:this.svg.rect(i/2+s,a/2,o,o,r);break;case 2:this.svg.rect(-o/2,h/2-o/2,o,o,r),this.svg.rect(m-o/2,h/2-o/2,o,o,r);break;case 3:this.svg.rect(i/2+s,1.5*a+o,o,o,r);break;case 4:this.svg.polyline(l,r).transform({translate:[o/2,-o/2],rotate:[0,o/2,s/2]}),this.svg.polyline(l,r).transform({translate:[o/2,h- -o/2],rotate:[0,o/2,s/2],scale:[1,-1]});break;case 5:this.svg.polyline(l,r).transform({translate:[m-o/2,-o/2],rotate:[0,o/2,s/2],scale:[-1,1]}),this.svg.polyline(l,r).transform({translate:[m-o/2,h+o/2],rotate:[0,o/2,s/2],scale:[-1,-1]});break;case 6:this.svg.polyline(l,r).transform({translate:[m/2+o/2,a/2]});break;case 7:this.svg.polyline(l,r).transform({translate:[m-m/2-o/2,a/2],scale:[-1,1]});break;case 8:this.svg.polyline(l,r).transform({translate:[m/2+o/2,h-a/2],scale:[1,-1]});break;case 9:this.svg.polyline(l,r).transform({translate:[m-m/2-o/2,h-a/2],scale:[-1,-1]});break;case 10:this.svg.polyline(l,r).transform({translate:[o/2,h/2-o/2]});break;case 11:this.svg.polyline(l,r).transform({translate:[m-o/2,h/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:[-m+o/2,o/2],rotate:[-30,0,0]});break;case 14:this.svg.rect(0,0,o,o,r).transform({translate:[o/2,h/2-o/2-o],rotate:[30,0,o]});break;case 15:this.svg.rect(0,0,o,o,r).transform({scale:[-1,1],translate:[-m+o/2,h/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,-h+h/2-o/2-o],rotate:[30,0,o]});break;case 17:this.svg.rect(0,0,o,o,r).transform({scale:[-1,-1],translate:[-m+o/2,-h+h/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,-h+o/2],rotate:[-30,0,0]});break;case 19:this.svg.rect(0,0,o,o,r).transform({scale:[-1,-1],translate:[-m+o/2,-h+o/2],rotate:[-30,0,0]})}}},6743(e){"use strict";function t(){var e=0x67452301,t=0xefcdab89,r=0x98badcfe,n=0x10325476,o=0xc3d2e1f0,a=new Uint32Array(80),i=0,s=24,l=0;function u(){for(var s,l,u=16;u<80;u++){var c=a[u-3]^a[u-8]^a[u-14]^a[u-16];a[u]=c<<1|c>>>31}var d=e,f=t,p=r,m=n,h=o;for(u=0;u<80;u++){u<20?(s=m^f&(p^m),l=0x5a827999):u<40?(s=f^p^m,l=0x6ed9eba1):u<60?(s=f&p|m&(f|p),l=0x8f1bbcdc):(s=f^p^m,l=0xca62c1d6);var g=(d<<5|d>>>27)+s+h+l+(0|a[u]);h=m,m=p,p=f<<30|f>>>2,f=d,d=g}for(u=0,e=e+d|0,t=t+f|0,r=r+p|0,n=n+m|0,o=o+h|0,i=0;u<16;u++)a[u]=0}function c(e){a[i]|=(255&e)<<s,s?s-=8:(i++,s=24),16===i&&u()}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;l+=8*t;for(var r=0;r<t;r++)c(e.charCodeAt(r));return}var n=e.length;l+=8*n;for(var o=0;o<n;o++)c(e[o])},digest:function(){c(128),(i>14||14===i&&s<24)&&u(),i=14,s=24,c(0),c(0),c(l>0xffffffffff?l/0x10000000000:0),c(l>0xffffffff?l/0x100000000:0);for(var a=24;a>=0;a-=8)c(l>>a);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()}},8502(e,t,r){"use strict";var n=r(2849),o=r(6541);function a(){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=a,a.prototype.currentContext=function(){return this.context[this.context.length-1]||this.svg},a.prototype.end=function(){return this.context.pop(),this},a.prototype.currentNode=function(){var e=this.currentContext();return e.lastChild||e},a.prototype.transform=function(e){return this.currentNode().setAttribute("transform",Object.keys(e).map(function(t){return t+"("+e[t].join(",")+")"}).join(" ")),this},a.prototype.setAttributes=function(e,t){Object.keys(t).forEach(function(r){e.setAttribute(r,t[r])})},a.prototype.setWidth=function(e){this.svg.setAttribute("width",Math.floor(e))},a.prototype.setHeight=function(e){this.svg.setAttribute("height",Math.floor(e))},a.prototype.toString=function(){return this.svg.toString()},a.prototype.rect=function(e,t,r,a,i){var s=this;if(Array.isArray(e))return e.forEach(function(e){s.rect.apply(s,e.concat(i))}),this;var l=o("rect");return this.currentContext().appendChild(l),this.setAttributes(l,n({x:e,y:t,width:r,height:a},i)),this},a.prototype.circle=function(e,t,r,a){var i=o("circle");return this.currentContext().appendChild(i),this.setAttributes(i,n({cx:e,cy:t,r:r},a)),this},a.prototype.path=function(e,t){var r=o("path");return this.currentContext().appendChild(r),this.setAttributes(r,n({d:e},t)),this},a.prototype.polyline=function(e,t){var r=this;if(Array.isArray(e))return e.forEach(function(e){r.polyline(e,t)}),this;var a=o("polyline");return this.currentContext().appendChild(a),this.setAttributes(a,n({points:e},t)),this},a.prototype.group=function(e){var t=o("g");return this.currentContext().appendChild(t),this.context.push(t),this.setAttributes(t,n({},e)),this}},6541(e){"use strict";var t=e.exports=function(e){return 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("")}},8067(e,t){"use strict";t.pathToRegexp=function(e,t={}){let{delimiter:u="/",end:c=!0,sensitive:d=!1,trailing:f=!0}=t,p=[],m=[];for(let c of function e(t,r){if(Array.isArray(t))for(let n of t)e(n,r);else r.push(t);return r}(e,[])){let e="object"==typeof c?c:function(e,t={}){let{encodePath:i=r}=t,u=[...e],c=[],d=0,f=0;function p(){let t="";if(n.test(u[d]))do t+=u[d++];while(o.test(u[d]));else if('"'===u[d]){let r=d;for(;d++<u.length;){if('"'===u[d]){d++,r=0;break}"\\"===u[d]&&d++,t+=u[d]}if(r)throw new l(`Unterminated quote at index ${r}`,e)}if(!t)throw new l(`Missing parameter name at index ${d}`,e);return t}for(;d<u.length;){let e=u[d],t=a[e];t?c.push({type:t,index:d++,value:e}):"\\"===e?c.push({type:"escape",index:d++,value:u[d++]}):":"===e?c.push({type:"param",index:d++,value:p()}):"*"===e?c.push({type:"wildcard",index:d++,value:p()}):c.push({type:"char",index:d++,value:e})}return c.push({type:"end",index:d,value:""}),new s(function t(r){let n=[];for(;;){let o=c[f++];if(o.type===r)break;if("char"===o.type||"escape"===o.type){let e=o.value,t=c[f];for(;"char"===t.type||"escape"===t.type;)e+=t.value,t=c[++f];n.push({type:"text",value:i(e)});continue}if("param"===o.type||"wildcard"===o.type){n.push({type:o.type,name:o.value});continue}if("{"===o.type){n.push({type:"group",tokens:t("}")});continue}throw new l(`Unexpected ${o.type} at index ${o.index}, expected ${r}`,e)}return n}("end"),e)}(c,t);for(let t of function* e(t,r,n){if(r===t.length)return yield n;let o=t[r];if("group"===o.type)for(let a of e(o.tokens,0,n.slice()))yield*e(t,r+1,a);else n.push(o);yield*e(t,r+1,n)}(e.tokens,0,[]))m.push(function(e,t,r,n){let o="",a="",s=!0;for(let d of e){if("text"===d.type){o+=i(d.value),a+=d.value,s||(s=d.value.includes(t));continue}if("param"===d.type||"wildcard"===d.type){var u,c;if(!s&&!a)throw new l(`Missing text before "${d.name}" ${d.type}`,n);"param"===d.type?o+=`(${u=t,(c=s?"":a).length<2?u.length<2?`[^${i(u+c)}]`:`(?:(?!${i(u)})[^${i(c)}])`:u.length<2?`(?:(?!${i(c)})[^${i(u)}])`:`(?:(?!${i(c)}|${i(u)})[\\s\\S])`}+)`:o+="([\\s\\S]+)",r.push(d),a="",s=!1;continue}}return o}(t,u,p,e.originalPath))}let h=`^(?:${m.join("|")})`;return f&&(h+=`(?:${i(u)}$)?`),{regexp:new RegExp(h+=c?"$":`(?=${i(u)}|$)`,d?"":"i"),keys:p}};let r=e=>e,n=/^[$_\p{ID_Start}]$/u,o=/^[$\u200c\u200d\p{ID_Continue}]$/u,a={"{":"{","}":"}","(":"(",")":")","[":"[","]":"]","+":"+","?":"?","!":"!"};function i(e){return e.replace(/[.+*?^${}()[\]|/\\]/g,"\\$&")}class s{constructor(e,t){this.tokens=e,this.originalPath=t}}class l extends TypeError{constructor(e,t){let r=e;t&&(r+=`: ${t}`),super(r+="; visit https://git.new/pathToRegexpError for info"),this.originalPath=t}}},5338(e,t,r){"use strict";var n=r(1779);t.createRoot=n.createRoot,t.hydrateRoot=n.hydrateRoot},3904(e,t,r){"use strict";let n=Symbol("SemVer ANY");class o{static get ANY(){return n}constructor(e,t){if(t=a(t),e instanceof o)if(!!t.loose===e.loose)return e;else e=e.value;u("comparator",e=e.trim().split(/\s+/).join(" "),t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===n?this.value="":this.value=this.operator+this.semver.version,u("comp",this)}parse(e){let t=this.options.loose?i[s.COMPARATORLOOSE]:i[s.COMPARATOR],r=e.match(t);if(!r)throw TypeError(`Invalid comparator: ${e}`);this.operator=void 0!==r[1]?r[1]:"","="===this.operator&&(this.operator=""),r[2]?this.semver=new c(r[2],this.options.loose):this.semver=n}toString(){return this.value}test(e){if(u("Comparator.test",e,this.options.loose),this.semver===n||e===n)return!0;if("string"==typeof e)try{e=new c(e,this.options)}catch(e){return!1}return l(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof o))throw TypeError("a Comparator is required");return""===this.operator?""===this.value||new d(e.value,t).test(this.value):""===e.operator?""===e.value||new d(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("=")||l(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<")||l(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">"))}}e.exports=o;let a=r(968),{safeRe:i,t:s}=r(9718),l=r(2111),u=r(7272),c=r(3908),d=r(8311)},8311(e,t,r){"use strict";let n=/\s+/g;class o{constructor(e,t){if(t=i(t),e instanceof o)if(!!t.loose===e.loose&&!!t.includePrerelease===e.includePrerelease)return e;else return new o(e.raw,t);if(e instanceof s)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e.trim().replace(n," "),this.set=this.raw.split("||").map(e=>this.parseRange(e.trim())).filter(e=>e.length),!this.set.length)throw TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const e=this.set[0];if(this.set=this.set.filter(e=>!y(e[0])),0===this.set.length)this.set=[e];else if(this.set.length>1){for(const e of this.set)if(1===e.length&&v(e[0])){this.set=[e];break}}}this.formatted=void 0}get range(){if(void 0===this.formatted){this.formatted="";for(let e=0;e<this.set.length;e++){e>0&&(this.formatted+="||");let t=this.set[e];for(let e=0;e<t.length;e++)e>0&&(this.formatted+=" "),this.formatted+=t[e].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){let t=((this.options.includePrerelease&&h)|(this.options.loose&&g))+":"+e,r=a.get(t);if(r)return r;let n=this.options.loose,o=n?c[d.HYPHENRANGELOOSE]:c[d.HYPHENRANGE];l("hyphen replace",e=e.replace(o,R(this.options.includePrerelease))),l("comparator trim",e=e.replace(c[d.COMPARATORTRIM],f)),l("tilde trim",e=e.replace(c[d.TILDETRIM],p)),l("caret trim",e=e.replace(c[d.CARETTRIM],m));let i=e.split(" ").map(e=>w(e,this.options)).join(" ").split(/\s+/).map(e=>O(e,this.options));n&&(i=i.filter(e=>(l("loose invalid filter",e,this.options),!!e.match(c[d.COMPARATORLOOSE])))),l("range list",i);let u=new Map;for(let e of i.map(e=>new s(e,this.options))){if(y(e))return[e];u.set(e.value,e)}u.size>1&&u.has("")&&u.delete("");let v=[...u.values()];return a.set(t,v),v}intersects(e,t){if(!(e instanceof o))throw TypeError("a Range is required");return this.set.some(r=>b(r,t)&&e.set.some(e=>b(e,t)&&r.every(r=>e.every(e=>r.intersects(e,t)))))}test(e){if(!e)return!1;if("string"==typeof e)try{e=new u(e,this.options)}catch(e){return!1}for(let t=0;t<this.set.length;t++)if(T(this.set[t],e,this.options))return!0;return!1}}e.exports=o;let a=new(r(8794)),i=r(968),s=r(3904),l=r(7272),u=r(3908),{safeRe:c,t:d,comparatorTrimReplace:f,tildeTrimReplace:p,caretTrimReplace:m}=r(9718),{FLAG_INCLUDE_PRERELEASE:h,FLAG_LOOSE:g}=r(6874),y=e=>"<0.0.0-0"===e.value,v=e=>""===e.value,b=(e,t)=>{let r=!0,n=e.slice(),o=n.pop();for(;r&&n.length;)r=n.every(e=>o.intersects(e,t)),o=n.pop();return r},w=(e,t)=>(l("comp",e=e.replace(c[d.BUILD],""),t),l("caret",e=_(e,t)),l("tildes",e=x(e,t)),l("xrange",e=C(e,t)),l("stars",e=P(e,t)),e),E=e=>!e||"x"===e.toLowerCase()||"*"===e,x=(e,t)=>e.trim().split(/\s+/).map(e=>D(e,t)).join(" "),D=(e,t)=>{let r=t.loose?c[d.TILDELOOSE]:c[d.TILDE];return e.replace(r,(t,r,n,o,a)=>{let i;return l("tilde",e,t,r,n,o,a),E(r)?i="":E(n)?i=`>=${r}.0.0 <${+r+1}.0.0-0`:E(o)?i=`>=${r}.${n}.0 <${r}.${+n+1}.0-0`:a?(l("replaceTilde pr",a),i=`>=${r}.${n}.${o}-${a} <${r}.${+n+1}.0-0`):i=`>=${r}.${n}.${o} <${r}.${+n+1}.0-0`,l("tilde return",i),i})},_=(e,t)=>e.trim().split(/\s+/).map(e=>S(e,t)).join(" "),S=(e,t)=>{l("caret",e,t);let r=t.loose?c[d.CARETLOOSE]:c[d.CARET],n=t.includePrerelease?"-0":"";return e.replace(r,(t,r,o,a,i)=>{let s;return l("caret",e,t,r,o,a,i),E(r)?s="":E(o)?s=`>=${r}.0.0${n} <${+r+1}.0.0-0`:E(a)?s="0"===r?`>=${r}.${o}.0${n} <${r}.${+o+1}.0-0`:`>=${r}.${o}.0${n} <${+r+1}.0.0-0`:i?(l("replaceCaret pr",i),s="0"===r?"0"===o?`>=${r}.${o}.${a}-${i} <${r}.${o}.${+a+1}-0`:`>=${r}.${o}.${a}-${i} <${r}.${+o+1}.0-0`:`>=${r}.${o}.${a}-${i} <${+r+1}.0.0-0`):(l("no pr"),s="0"===r?"0"===o?`>=${r}.${o}.${a}${n} <${r}.${o}.${+a+1}-0`:`>=${r}.${o}.${a}${n} <${r}.${+o+1}.0-0`:`>=${r}.${o}.${a} <${+r+1}.0.0-0`),l("caret return",s),s})},C=(e,t)=>(l("replaceXRanges",e,t),e.split(/\s+/).map(e=>k(e,t)).join(" ")),k=(e,t)=>{e=e.trim();let r=t.loose?c[d.XRANGELOOSE]:c[d.XRANGE];return e.replace(r,(r,n,o,a,i,s)=>{l("xRange",e,r,n,o,a,i,s);let u=E(o),c=u||E(a),d=c||E(i);return"="===n&&d&&(n=""),s=t.includePrerelease?"-0":"",u?r=">"===n||"<"===n?"<0.0.0-0":"*":n&&d?(c&&(a=0),i=0,">"===n?(n=">=",c?(o=+o+1,a=0):a=+a+1,i=0):"<="===n&&(n="<",c?o=+o+1:a=+a+1),"<"===n&&(s="-0"),r=`${n+o}.${a}.${i}${s}`):c?r=`>=${o}.0.0${s} <${+o+1}.0.0-0`:d&&(r=`>=${o}.${a}.0${s} <${o}.${+a+1}.0-0`),l("xRange return",r),r})},P=(e,t)=>(l("replaceStars",e,t),e.trim().replace(c[d.STAR],"")),O=(e,t)=>(l("replaceGTE0",e,t),e.trim().replace(c[t.includePrerelease?d.GTE0PRE:d.GTE0],"")),R=e=>(t,r,n,o,a,i,s,l,u,c,d,f)=>(r=E(n)?"":E(o)?`>=${n}.0.0${e?"-0":""}`:E(a)?`>=${n}.${o}.0${e?"-0":""}`:i?`>=${r}`:`>=${r}${e?"-0":""}`,l=E(u)?"":E(c)?`<${+u+1}.0.0-0`:E(d)?`<${u}.${+c+1}.0-0`:f?`<=${u}.${c}.${d}-${f}`:e?`<${u}.${c}.${+d+1}-0`:`<=${l}`,`${r} ${l}`.trim()),T=(e,t,r)=>{for(let r=0;r<e.length;r++)if(!e[r].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(let r=0;r<e.length;r++)if(l(e[r].semver),e[r].semver!==s.ANY&&e[r].semver.prerelease.length>0){let n=e[r].semver;if(n.major===t.major&&n.minor===t.minor&&n.patch===t.patch)return!0}return!1}return!0}},3908(e,t,r){"use strict";let n=r(7272),{MAX_LENGTH:o,MAX_SAFE_INTEGER:a}=r(6874),{safeRe:i,t:s}=r(9718),l=r(968),{compareIdentifiers:u}=r(1123);class c{constructor(e,t){if(t=l(t),e instanceof c)if(!!t.loose===e.loose&&!!t.includePrerelease===e.includePrerelease)return e;else e=e.version;else if("string"!=typeof e)throw TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>o)throw TypeError(`version is longer than ${o} characters`);n("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;const r=e.trim().match(t.loose?i[s.LOOSE]:i[s.FULL]);if(!r)throw TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+r[1],this.minor=+r[2],this.patch=+r[3],this.major>a||this.major<0)throw TypeError("Invalid major version");if(this.minor>a||this.minor<0)throw TypeError("Invalid minor version");if(this.patch>a||this.patch<0)throw TypeError("Invalid patch version");r[4]?this.prerelease=r[4].split(".").map(e=>{if(/^[0-9]+$/.test(e)){let t=+e;if(t>=0&&t<a)return t}return e}):this.prerelease=[],this.build=r[5]?r[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(n("SemVer.compare",this.version,this.options,e),!(e instanceof c)){if("string"==typeof e&&e===this.version)return 0;e=new c(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return(e instanceof c||(e=new c(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)}comparePre(e){if(e instanceof c||(e=new c(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;let t=0;do{let r=this.prerelease[t],o=e.prerelease[t];if(n("prerelease compare",t,r,o),void 0===r&&void 0===o)return 0;if(void 0===o)return 1;if(void 0===r)return -1;else if(r===o)continue;else return u(r,o)}while(++t)}compareBuild(e){e instanceof c||(e=new c(e,this.options));let t=0;do{let r=this.build[t],o=e.build[t];if(n("build compare",t,r,o),void 0===r&&void 0===o)return 0;if(void 0===o)return 1;if(void 0===r)return -1;else if(r===o)continue;else return u(r,o)}while(++t)}inc(e,t,r){if(e.startsWith("pre")){if(!t&&!1===r)throw Error("invalid increment argument: identifier is empty");if(t){let e=`-${t}`.match(this.options.loose?i[s.PRERELEASELOOSE]:i[s.PRERELEASE]);if(!e||e[1]!==t)throw Error(`invalid identifier: ${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 ${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":{let e=+!!Number(r);if(0===this.prerelease.length)this.prerelease=[e];else{let n=this.prerelease.length;for(;--n>=0;)"number"==typeof this.prerelease[n]&&(this.prerelease[n]++,n=-2);if(-1===n){if(t===this.prerelease.join(".")&&!1===r)throw Error("invalid increment argument: identifier already exists");this.prerelease.push(e)}}if(t){let n=[t,e];!1===r&&(n=[t]),0===u(this.prerelease[0],t)?isNaN(this.prerelease[1])&&(this.prerelease=n):this.prerelease=n}break}default:throw Error(`invalid increment argument: ${e}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}}e.exports=c},2111(e,t,r){"use strict";let n=r(4641),o=r(3999),a=r(5580),i=r(4089),s=r(7059),l=r(5200);e.exports=(e,t,r,u)=>{switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e===r;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e!==r;case"":case"=":case"==":return n(e,r,u);case"!=":return o(e,r,u);case">":return a(e,r,u);case">=":return i(e,r,u);case"<":return s(e,r,u);case"<=":return l(e,r,u);default:throw TypeError(`Invalid operator: ${t}`)}}},560(e,t,r){"use strict";let n=r(3908);e.exports=(e,t,r)=>new n(e,r).compare(new n(t,r))},4641(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>0===n(e,t,r)},5580(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>n(e,t,r)>0},4089(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>n(e,t,r)>=0},7059(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>0>n(e,t,r)},5200(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>0>=n(e,t,r)},3999(e,t,r){"use strict";let n=r(560);e.exports=(e,t,r)=>0!==n(e,t,r)},7638(e,t,r){"use strict";let n=r(8311);e.exports=(e,t,r)=>{try{t=new n(t,r)}catch(e){return!1}return t.test(e)}},6874(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}},7272(e){"use strict";e.exports="object"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{}},1123(e){"use strict";let t=/^[0-9]+$/,r=(e,r)=>{if("number"==typeof e&&"number"==typeof r)return e===r?0:e<r?-1:1;let 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:(e,t)=>r(t,e)}},8794(e){"use strict";e.exports=class{constructor(){this.max=1e3,this.map=new Map}get(e){let t=this.map.get(e);if(void 0!==t)return this.map.delete(e),this.map.set(e,t),t}delete(e){return this.map.delete(e)}set(e,t){if(!this.delete(e)&&void 0!==t){if(this.map.size>=this.max){let e=this.map.keys().next().value;this.delete(e)}this.map.set(e,t)}return this}}},968(e){"use strict";let t=Object.freeze({loose:!0}),r=Object.freeze({});e.exports=e=>e?"object"!=typeof e?t:e:r},9718(e,t,r){"use strict";let{MAX_SAFE_COMPONENT_LENGTH:n,MAX_SAFE_BUILD_LENGTH:o,MAX_LENGTH:a}=r(6874),i=r(7272),s=(t=e.exports={}).re=[],l=t.safeRe=[],u=t.src=[],c=t.safeSrc=[],d=t.t={},f=0,p="[a-zA-Z0-9-]",m=[["\\s",1],["\\d",a],[p,o]],h=(e,t,r)=>{let n=(e=>{for(let[t,r]of m)e=e.split(`${t}*`).join(`${t}{0,${r}}`).split(`${t}+`).join(`${t}{1,${r}}`);return e})(t),o=f++;i(e,o,t),d[e]=o,u[o]=t,c[o]=n,s[o]=new RegExp(t,r?"g":void 0),l[o]=new RegExp(n,r?"g":void 0)};h("NUMERICIDENTIFIER","0|[1-9]\\d*"),h("NUMERICIDENTIFIERLOOSE","\\d+"),h("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${p}*`),h("MAINVERSION",`(${u[d.NUMERICIDENTIFIER]})\\.(${u[d.NUMERICIDENTIFIER]})\\.(${u[d.NUMERICIDENTIFIER]})`),h("MAINVERSIONLOOSE",`(${u[d.NUMERICIDENTIFIERLOOSE]})\\.(${u[d.NUMERICIDENTIFIERLOOSE]})\\.(${u[d.NUMERICIDENTIFIERLOOSE]})`),h("PRERELEASEIDENTIFIER",`(?:${u[d.NONNUMERICIDENTIFIER]}|${u[d.NUMERICIDENTIFIER]})`),h("PRERELEASEIDENTIFIERLOOSE",`(?:${u[d.NONNUMERICIDENTIFIER]}|${u[d.NUMERICIDENTIFIERLOOSE]})`),h("PRERELEASE",`(?:-(${u[d.PRERELEASEIDENTIFIER]}(?:\\.${u[d.PRERELEASEIDENTIFIER]})*))`),h("PRERELEASELOOSE",`(?:-?(${u[d.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${u[d.PRERELEASEIDENTIFIERLOOSE]})*))`),h("BUILDIDENTIFIER",`${p}+`),h("BUILD",`(?:\\+(${u[d.BUILDIDENTIFIER]}(?:\\.${u[d.BUILDIDENTIFIER]})*))`),h("FULLPLAIN",`v?${u[d.MAINVERSION]}${u[d.PRERELEASE]}?${u[d.BUILD]}?`),h("FULL",`^${u[d.FULLPLAIN]}$`),h("LOOSEPLAIN",`[v=\\s]*${u[d.MAINVERSIONLOOSE]}${u[d.PRERELEASELOOSE]}?${u[d.BUILD]}?`),h("LOOSE",`^${u[d.LOOSEPLAIN]}$`),h("GTLT","((?:<|>)?=?)"),h("XRANGEIDENTIFIERLOOSE",`${u[d.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),h("XRANGEIDENTIFIER",`${u[d.NUMERICIDENTIFIER]}|x|X|\\*`),h("XRANGEPLAIN",`[v=\\s]*(${u[d.XRANGEIDENTIFIER]})(?:\\.(${u[d.XRANGEIDENTIFIER]})(?:\\.(${u[d.XRANGEIDENTIFIER]})(?:${u[d.PRERELEASE]})?${u[d.BUILD]}?)?)?`),h("XRANGEPLAINLOOSE",`[v=\\s]*(${u[d.XRANGEIDENTIFIERLOOSE]})(?:\\.(${u[d.XRANGEIDENTIFIERLOOSE]})(?:\\.(${u[d.XRANGEIDENTIFIERLOOSE]})(?:${u[d.PRERELEASELOOSE]})?${u[d.BUILD]}?)?)?`),h("XRANGE",`^${u[d.GTLT]}\\s*${u[d.XRANGEPLAIN]}$`),h("XRANGELOOSE",`^${u[d.GTLT]}\\s*${u[d.XRANGEPLAINLOOSE]}$`),h("COERCEPLAIN",`(^|[^\\d])(\\d{1,${n}})(?:\\.(\\d{1,${n}}))?(?:\\.(\\d{1,${n}}))?`),h("COERCE",`${u[d.COERCEPLAIN]}(?:$|[^\\d])`),h("COERCEFULL",u[d.COERCEPLAIN]+`(?:${u[d.PRERELEASE]})?`+`(?:${u[d.BUILD]})?`+"(?:$|[^\\d])"),h("COERCERTL",u[d.COERCE],!0),h("COERCERTLFULL",u[d.COERCEFULL],!0),h("LONETILDE","(?:~>?)"),h("TILDETRIM",`(\\s*)${u[d.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",h("TILDE",`^${u[d.LONETILDE]}${u[d.XRANGEPLAIN]}$`),h("TILDELOOSE",`^${u[d.LONETILDE]}${u[d.XRANGEPLAINLOOSE]}$`),h("LONECARET","(?:\\^)"),h("CARETTRIM",`(\\s*)${u[d.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",h("CARET",`^${u[d.LONECARET]}${u[d.XRANGEPLAIN]}$`),h("CARETLOOSE",`^${u[d.LONECARET]}${u[d.XRANGEPLAINLOOSE]}$`),h("COMPARATORLOOSE",`^${u[d.GTLT]}\\s*(${u[d.LOOSEPLAIN]})$|^$`),h("COMPARATOR",`^${u[d.GTLT]}\\s*(${u[d.FULLPLAIN]})$|^$`),h("COMPARATORTRIM",`(\\s*)${u[d.GTLT]}\\s*(${u[d.LOOSEPLAIN]}|${u[d.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",h("HYPHENRANGE",`^\\s*(${u[d.XRANGEPLAIN]})\\s+-\\s+(${u[d.XRANGEPLAIN]})\\s*$`),h("HYPHENRANGELOOSE",`^\\s*(${u[d.XRANGEPLAINLOOSE]})\\s+-\\s+(${u[d.XRANGEPLAINLOOSE]})\\s*$`),h("STAR","(<|>)?=?\\s*\\*"),h("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),h("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")},6369(e,t,r){"use strict";function n(e){if(Array.isArray(e))return e}r.d(t,{A:()=>n})},3029(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}r.d(t,{A:()=>n})},2901(e,t,r){"use strict";r.d(t,{A:()=>a});var n=r(6192);function o(e,t){for(var r=0;r<t.length;r++){var o=t[r];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(0,n.A)(o.key),o)}}function a(e,t,r){return t&&o(e.prototype,t),r&&o(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}},4467(e,t,r){"use strict";r.d(t,{A:()=>o});var n=r(6192);function o(e,t,r){return(t=(0,n.A)(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}},6562(e,t,r){"use strict";function n(){throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}r.d(t,{A:()=>n})},6192(e,t,r){"use strict";r.d(t,{A:()=>o});var n=r(2284);function o(e){var t=function(e,t){if("object"!=(0,n.A)(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=(0,n.A)(o))return o;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==(0,n.A)(t)?t:t+""}},2284(e,t,r){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}r.d(t,{A:()=>n})},3612(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){if("string"==typeof e)return n(e,t);var r=({}).toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}}r.d(t,{A:()=>o})},4106(e,t,r){"use strict";let n,o,a,i,s,l,u,c,d,f,p;r.r(t),r.d(t,{GenderUnknownIcon:()=>pp,evaluateAsNumber:()=>lB,getImportMapOverrideMap:()=>sM,StockManagementPictogram:()=>_t,ChemistryIcon:()=>f6,BabyIcon:()=>fZ,DashboardExtension:()=>mp,openmrsComponentDecorator:()=>cY,tryRegisterExtension:()=>fn,pictogramIds:()=>DA,ActivityIcon:()=>fV,compile:()=>lH,removeRouteMapOverride:()=>ln,TableBatchActions:()=>fw,getAsyncLifecycle:()=>cJ,subscribeOpenmrsEvent:()=>lh,PasswordIcon:()=>pM,Assessment2Pictogram:()=>DL,CloseIcon:()=>pe,setupRouteMapOverrides:()=>li,useFeatureFlag:()=>dw,reset:()=>uJ,ConceptDictionaryPictogram:()=>DV,LabOrderIcon:()=>pD,VisitMode:()=>lE,useLocations:()=>dU,getLifecycle:()=>cq,formatDatetime:()=>EJ,getVisitsForPatient:()=>lO,formatPartialDate:()=>EG,CustomOverflowMenu:()=>fk,LocationIcon:()=>pS,GroupIcon:()=>ph,createUseStore:()=>cb,VisitStatus:()=>lx,getSessionLocation:()=>sf,getCurrentImportMap:()=>sY,usePatient:()=>dZ,useRenderableExtensions:()=>dq,getOpenedWindowIndexByWorkspace:()=>u9,setLeftNav:()=>uQ,clearHistory:()=>i1,clearConfigErrors:()=>oo,formatTime:()=>Eq,isDevEnabled:()=>sE,CohortsPictogram:()=>DU,closeWorkspaceGroup2:()=>_O,getCurrentRouteMap:()=>s8,ConfigurableLink:()=>cf,sessionStore:()=>st,setSessionLocale:()=>sm,subscribeSnackbarShown:()=>S,getLoggedInUser:()=>sd,GenderMaleIcon:()=>pd,getExtensionSlotConfigFromStore:()=>ny,evaluateAsNumberAsync:()=>lU,getImportMapDefaultMap:()=>s$,unregisterExtensionRendering:()=>uy,implementerToolsConfigStore:()=>nT,Type:()=>nn,InPatientPictogram:()=>DJ,cleanupObsoleteFeatureFlags:()=>ur,getAttachmentsUrl:()=>lc,showSnackbar:()=>_h,PatientBannerActionsMenu:()=>Dk,PatientSearchPictogram:()=>D4,DocumentAttachmentIcon:()=>po,Snackbar:()=>_c,CardiologyPictogram:()=>DB,ImageMedicalIcon:()=>pv,ActionableNotificationComponent:()=>x2,DiagnosisTags:()=>xT,iconIds:()=>fU,PatientsPictogram:()=>D3,interpolateUrl:()=>iG,setupHistory:()=>iX,subscribeToastShown:()=>_,detachAll:()=>uK,convertToLocaleCalendar:()=>EX,DocumentIcon:()=>pn,configInternalStore:()=>nd,ActionMenuButton2:()=>_z,setupDynamicOfflineDataHandler:()=>Sm,makeUrl:()=>i8,oneOf:()=>od,selectPreferredName:()=>Dh,MobileCheckIcon:()=>pT,createErrorHandler:()=>P,parseDate:()=>EU,getAttachmentByUuid:()=>ll,LeftNavMenu:()=>xM,getExtensionRegistration:()=>uV,ShoppingCartAddItemIcon:()=>mc,ReferralOrderIcon:()=>pW,ReportIcon:()=>pz,dispatchToastShown:()=>E,getImportMapNextPageMap:()=>sI,registerExtension:()=>uW,setupOfflineSync:()=>Sp,DownloadIcon:()=>pa,useConnectivity:()=>Sb,provide:()=>nG,ShoppingCartArrowDownIcon:()=>pX,featureFlagsStore:()=>ue,jsep:()=>lT,GeriatricsPictogram:()=>DY,SearchIcon:()=>pZ,reportError:()=>k,slugify:()=>sK,isOmrsDateToday:()=>EL,getExtensionStore:()=>uv,BloodBankPictogram:()=>DF,TriagePictogram:()=>_n,Workspace2:()=>_F,refetchCurrentUser:()=>sl,CheckmarkOutlineIcon:()=>f3,registerExtensionSlot:()=>uq,AllergiesIcon:()=>mi,ArrowDownIcon:()=>fH,useOpenmrsInfinite:()=>dO,getExtensionConfigFromExtensionSlotStore:()=>nE,OpenmrsDatePicker:()=>xO,getExtensionConfigFromStore:()=>nw,getDynamicOfflineDataEntries:()=>Sh,getLocaleDisplayName:()=>En,messageOmrsServiceWorker:()=>Sy,navigate:()=>iY,launchWorkspace2:()=>_R,getGroupByWindowName:()=>u5,CustomOverflowMenuItem:()=>fP,isUrl:()=>oc,CaretDownIcon:()=>fJ,ArrowLeftIcon:()=>fz,FacilityPictogram:()=>DZ,ViewOffIcon:()=>mn,updateInternalExtensionStore:()=>ud,dispatchActionableNotificationShown:()=>b,resetRouteMapOverrides:()=>lo,formatDurationBetween:()=>E5,defaultVisitCustomRepresentation:()=>lD,getBreadcrumbsFor:()=>ow,useOpenmrsPagination:()=>dx,Pagination:()=>Dc,CheckmarkFilledIcon:()=>f4,clearCurrentUser:()=>su,showModal:()=>xJ,ChevronUpIcon:()=>f7,saveVisit:()=>lk,useAttachments:()=>da,Pictogram:()=>_l,useExtensionSlot:()=>cS,ChevronDownIcon:()=>f5,OpenmrsDateRangePicker:()=>xR,deleteAttachmentPermanently:()=>lf,getVisitTypes:()=>lw,OverflowMenuHorizontalIcon:()=>p$,EventScheduleIcon:()=>pl,getSessionStore:()=>si,ProcedureOrderIcon:()=>pU,preloadImport:()=>sZ,registerWorkspaceWindows2:()=>u7,useOnVisible:()=>dW,setSessionLocation:()=>sp,userHasAccess:()=>sc,ChartAverageIcon:()=>f1,getFeatureFlag:()=>un,UserAvatarIcon:()=>p7,renderExtension:()=>cl,useFhirInfinite:()=>dA,toVisitTypeObject:()=>lv,useSession:()=>dJ,EmergencyDepartmentPictogram:()=>DG,Notification:()=>x0,dispatchSnackbarShown:()=>w,formatDate:()=>EZ,workspace2StoreActions:()=>_j,SwitcherIcon:()=>pq,esmStyleGuideSchema:()=>fy,getImportMapDisabledOverrides:()=>sL,useAssignedExtensionIds:()=>dr,CaretRightIcon:()=>fQ,evaluateAsType:()=>lV,PageHeader:()=>Dl,TranslateIcon:()=>p6,setUserProperties:()=>sh,MovementIcon:()=>pA,renderInlineNotifications:()=>x7,subscribePrecacheStaticDependencies:()=>Sv,PaymentsDeskPictogram:()=>D6,usePrimaryIdentifierCode:()=>dY,useLayoutType:()=>dI,getCurrentUser:()=>sa,XrayPictogram:()=>_o,CaretUpIcon:()=>f0,renderActionableNotifications:()=>Dt,OpenmrsAppContext:()=>c9,setupModals:()=>xq,getDefaultsFromConfigSchema:()=>function e(t){let r={};for(let n of Object.keys(t))if(Ss(t[n])&&t[n].hasOwnProperty("_default"))r[n]=t[n]._default;else{if(n.startsWith("_"))continue;Ss(t[n])?r[n]=e(t[n]):r[n]=t[n]}return r},subscribeTo:()=>W,recordConfigDerivationError:()=>nO,useAbortController:()=>c7,Extension:()=>cp,getFhirServerPaginationHandlers:()=>dC,useConnectedExtensions:()=>dc,registerApp:()=>fa,HospitalBedIcon:()=>py,useExtensionInternalStore:()=>dy,configExtensionStore:()=>np,getSynchronizationItems:()=>Sg,getExtensionSlotsConfigStore:()=>nh,registerExtensionRendering:()=>ug,RenderIfValueIsTruthy:()=>c8,registerFeatureFlag:()=>ut,useFhirFetchAll:()=>dj,restBaseUrl:()=>i6,CalendarHeatMapIcon:()=>fY,isImportMapOverrideDisabled:()=>sF,resetConfigSystem:()=>oa,getExtensionInternalStore:()=>uu,registerGlobalStore:()=>U,evaluateAsBoolean:()=>lL,PatientBannerPatientInfo:()=>DS,addRouteMapOverride:()=>lr,getDefaultCalendar:()=>Ez,SettingsIcon:()=>pY,DrugOrderIcon:()=>pi,ProgramsIcon:()=>pV,useAssignedExtensions:()=>c_,CloseFilledIcon:()=>pt,canAccessStorage:()=>Si,registerDefaultCalendar:()=>EH,TreeViewAltIcon:()=>p9,OverflowMenuVerticalIcon:()=>pI,clearConfigDerivationError:()=>nR,getConfigStore:()=>nm,InformationSquareIcon:()=>pE,EmptyCard:()=>xA,ChevronLeftIcon:()=>f9,RadiologyIcon:()=>mu,useCandidateExtensions:()=>dn,renderToasts:()=>_w,isDesktop:()=>dM,integrateBreakpoints:()=>fc,RegistrationPictogram:()=>D8,CardHeader:()=>fm,getExtensionRegistrationFrom:()=>uU,InformationIcon:()=>pb,TrashCanIcon:()=>p5,useShallowStableValue:()=>cm,PatientDocumentsPictogram:()=>D2,useOpenmrsSWR:()=>dH,Assessment1Pictogram:()=>DM,finishRegisteringAllApps:()=>fi,importDynamic:()=>sG,useFhirPagination:()=>dS,useVisitContextStore:()=>d6,ArrowUpIcon:()=>fG,showActionableNotification:()=>Dr,useForceUpdate:()=>dE,useVisit:()=>d5,PatientBannerPatientIdentifiers:()=>DE,TransferPictogram:()=>_r,usePagination:()=>dz,Breakpoint:()=>fs,PatientBannerToggleContactDetailsButton:()=>_K,CloseOutlineIcon:()=>pr,ObstetricsPictogram:()=>D1,parseDateInput:()=>E0,ReportsPictogram:()=>D7,getConfig:()=>nY,attach:()=>uH,getLocale:()=>Eo,isUrlWithTemplateParameters:()=>ou,useEmrConfiguration:()=>dh,useLeftNav:()=>dL,ToolsIcon:()=>p3,ErrorState:()=>x$,detach:()=>uz,setCurrentVisit:()=>lC,ConditionsIcon:()=>ml,SaveIcon:()=>pG,useConfig:()=>du,validator:()=>no,CalendarIcon:()=>fq,getHistory:()=>iQ,StickyNoteAddIcon:()=>pQ,useWorkspace2Store:()=>_A,getPatientName:()=>Dd,getVisitStore:()=>lS,getCoreTranslation:()=>iK,registerModuleWithConfigSystem:()=>nW,registerModuleLoad:()=>nH,getBreadcrumbs:()=>oy,extractVariableNames:()=>l9,translateFrom:()=>iz,useStoreWithActions:()=>cv,EditIcon:()=>ps,getCandidateExtensions:()=>uY,shallowEqual:()=>R,subscribeNotificationShown:()=>x,MaximizeIcon:()=>pk,promptForClosingWorkspaces:()=>_N,WarningIcon:()=>ma,fhirBaseUrl:()=>i5,matchLocale:()=>Sa,usePatientPhoto:()=>DR,registerBreadcrumb:()=>oh,EventsIcon:()=>pu,createGlobalStore:()=>B,subscribeToFeatureFlag:()=>uo,useExtensionStore:()=>db,createAttachment:()=>ld,useLeftNavStore:()=>dF,TableIcon:()=>p2,Icon:()=>mf,InformationFilledIcon:()=>pw,getCurrentPageMap:()=>sA,LaboratoryPictogram:()=>DX,temporaryConfigStore:()=>nf,toDateObjectStrict:()=>EF,defineConfigSchema:()=>nV,filterBreadcrumbs:()=>ob,invalidateImplementerToolsConfig:()=>nk,PatientBannerContactDetails:()=>_X,getAssignedExtensions:()=>uZ,PatientPhoto:()=>Dj,MaterialOrderIcon:()=>pC,MicroscopeIcon:()=>pR,visitTypesUrl:()=>lb,scheduleRecomputation:()=>uD,PharmacyPictogram:()=>D5,AttachmentIcon:()=>ms,MoneyIcon:()=>pN,getAttachments:()=>lu,PageHeaderContent:()=>Du,MedicationIcon:()=>pP,PrinterIcon:()=>pB,PatientListsPictogram:()=>_i,useAppContext:()=>de,isOpenmrsRoutes:()=>sX,AppointmentsAltPictogram:()=>DI,GenericOrderTypeIcon:()=>pm,batchExtensionUpdates:()=>uE,useExtensionSlotStore:()=>cx,ViewIcon:()=>mo,formattedName:()=>Dm,sessionEndpoint:()=>i9,duration:()=>E3,resetImportMapOverrides:()=>sV,TableOfContentsIcon:()=>p1,CaretLeftIcon:()=>fX,getTranslationOverrides:()=>nq,isVersionSatisfied:()=>Sc,EmptyCardIllustration:()=>xj,PenIcon:()=>pF,verifyTotpCode:()=>sg,validators:()=>of,setupImportMapOverrides:()=>sz,showToast:()=>_E,useDefineAppContext:()=>c5,getGlobalStore:()=>V,useOnClickOutside:()=>dV,getWindowByWorkspaceName:()=>u6,ArrowRightIcon:()=>fK,loadLifeCycles:()=>fe,registerBreadcrumbs:()=>og,MotherIcon:()=>pj,fetchCurrentPatient:()=>lp,Toast:()=>_g,MessageQueueIcon:()=>pO,TwoFactorAuthenticationIcon:()=>p8,Pharmacy2Pictogram:()=>D9,goBackInHistory:()=>i0,GroupAccessIcon:()=>pg,getExtensionRenderingsStore:()=>uc,setImplementerToolsConfigRecomputer:()=>nC,getAsyncExtensionLifecycle:()=>cQ,setupApiModule:()=>sD,renderLoadingSpinner:()=>_Q,showNotification:()=>De,getModalRegistration:()=>u4,ListCheckedIcon:()=>p_,ResponsiveWrapper:()=>_u,GynaecologyPictogram:()=>Dq,ShoppingCartIcon:()=>pJ,getRouteMapNextPageMap:()=>le,MetadataExportPictogram:()=>D0,updateVisit:()=>lP,backendDependencies:()=>sx,MaybePictogram:()=>_s,createParcelMounter:()=>ci,openmrsFetch:()=>i7,useStore:()=>cy,isOpenmrsAppRoutes:()=>sJ,HomePictogram:()=>_a,DentistryPictogram:()=>Dz,ServiceQueuesPictogram:()=>_e,toLanguageTag:()=>Er,setFeatureFlag:()=>ua,DigitalTrustPictogram:()=>DK,NumericObservation:()=>Di,attachmentUrl:()=>ls,interpolateString:()=>iZ,inRange:()=>ol,useExtensionSlotMeta:()=>dv,AppointmentsPictogram:()=>D$,renderSnackbars:()=>_m,getRegisteredWorkspace2Names:()=>_I,logout:()=>sy,toLocationObject:()=>lg,ChartLineIcon:()=>f2,UserHasAccess:()=>dX,evaluateAsBooleanAsync:()=>lF,createDashboard:()=>mm,getLocations:()=>ly,useExtensionContext:()=>dg,getExtensionsConfigStore:()=>nv,getRouteMapDefaultMap:()=>s7,age:()=>Dy,isOmrsDateStrict:()=>EM,registerWorkspaceGroups2:()=>u8,usePaginationInfo:()=>dK,evaluateAsync:()=>lM,useOpenmrsFetchAll:()=>dT,removeImportMapOverride:()=>sU,useVisitTypes:()=>d8,ageAsDuration:()=>Dg,getExtensionNameFromId:()=>uB,DataEntryPictogram:()=>DH,renderParcel:()=>ca,ResetIcon:()=>pK,RenewIcon:()=>pH,useWorkspace2Context:()=>_$,subscribeActionableNotificationShown:()=>D,ErrorCard:()=>xI,GenderFemaleIcon:()=>pc,enableImportMapOverride:()=>sW,retry:()=>Sd,ComponentContext:()=>cd,ExtensionSlot:()=>ck,unsetLeftNav:()=>u0,addImportMapOverride:()=>sB,MaybeIcon:()=>md,useCustomOverflowMenu:()=>fC,PedestrianFamilyIcon:()=>pL,CtScanPictogram:()=>DW,dispatchNotificationShown:()=>v,leftNavStore:()=>uX,OpenmrsFetchError:()=>se,UserFollowIcon:()=>me,launchWorkspaceGroup2:()=>_P,ChevronRightIcon:()=>f8,UserXrayIcon:()=>mt,GenderOtherIcon:()=>pf,formatDuration:()=>EQ,toOmrsIsoString:()=>EB,Labs2Pictogram:()=>DQ,workspace2Store:()=>u3,setUserLanguage:()=>ss,useBodyScrollLock:()=>di,getExtensionConfig:()=>nb,SyringeIcon:()=>p0,LocationPicker:()=>xL,useDebounce:()=>dd,TimeIcon:()=>p4,getExtensionSlotConfig:()=>ng,AddIcon:()=>fW,getRouteMapOverrideMap:()=>lt,processConfig:()=>nJ,InventoryManagementIcon:()=>px,registerWorkspaces2:()=>ce,UserIcon:()=>mr,formatPatientName:()=>Dp,fireOpenmrsEvent:()=>lm,registerModal:()=>u2,registerTranslationNamespace:()=>nz,displayName:()=>Df,evaluate:()=>lI,defineExtensionConfigSchema:()=>nK,renderWorkspaceWindowsAndMenu:()=>Sn,getSyncLifecycle:()=>cX,evaluateAsTypeAsync:()=>lW});let m="openmrs:notification-shown",h="openmrs:actionable-notification-shown",g="openmrs:toast-shown",y="openmrs:snack-bar-shown";function v(e){window.dispatchEvent(new CustomEvent(m,{detail:e}))}function b(e){window.dispatchEvent(new CustomEvent(h,{detail:e}))}function w(e){window.dispatchEvent(new CustomEvent(y,{detail:e}))}function E(e){window.dispatchEvent(new CustomEvent(g,{detail:e}))}function x(e){let t=t=>e(t.detail);return window.addEventListener(m,t),()=>window.removeEventListener(m,t)}function D(e){let t=t=>e(t.detail);return window.addEventListener(h,t),()=>window.removeEventListener(h,t)}function _(e){let t=t=>e(t.detail);return window.addEventListener(g,t),()=>window.removeEventListener(g,t)}function S(e){let t=t=>e(t.detail);return window.addEventListener(y,t),()=>window.removeEventListener(y,t)}function C(e,t){let{message:r}=O(e);return"string"==typeof r&&r?r:t}function k(e){let t=O(e);setTimeout(()=>{throw t})}function P(){let e=Error();return t=>{let r=O(t);r.stack+=`
|
|
2
2
|
Async stacktrace:
|
|
3
3
|
${e.stack}`,k(t)}}function O(e){let t;if(e instanceof Error)return e;if(null===e)return Error("'null' was thrown as an error");if("object"==typeof e){try{t=`Object thrown as error: ${JSON.stringify(e)}`}catch(r){t=`Object thrown as error with the following properties: ${Object.keys(e)}`}return Error(t)}if(void 0===e)return Error("'undefined' was thrown as an error");return Error(e.toString())}function R(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(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}if(Array.isArray(t)||"object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;let r=Object.getOwnPropertyNames(e),n=Object.getOwnPropertyNames(t);return r.length===n.length&&r.every(r=>e[r]===t[r])}function T(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),a=null!=(n=r.getItem(e))?n:null;return a instanceof Promise?a.then(o):o(a)},setItem:(e,n)=>r.setItem(e,JSON.stringify(n,null==t?void 0:t.replacer)),removeItem:e=>r.removeItem(e)}}window.onerror=function(e,t,r,n,o){return console.error("Unexpected error: ",o??e),E({description:C(o,"Oops! An unexpected error occurred."),kind:"error",title:"Error"}),!1},window.onunhandledrejection=function(e){console.error("Unhandled rejection: ",e.reason),E({description:C(e.reason,"Oops! An unhandled promise rejection occurred."),kind:"error",title:"Error"})};let N=e=>t=>{try{let r=e(t);if(r instanceof Promise)return r;return{then:e=>N(e)(r),catch(e){return this}}}catch(e){return{then(e){return this},catch:t=>N(t)(e)}}},j=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,a={setState:n,getState:o,getInitialState:()=>i,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()}},i=t=e(n,o,a);return a},A=e=>e?j(e):j;function $(){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{return!1}}let I={},M=Symbol.for("openmrs.esm-state.instanceCount"),L=globalThis,F=(L[M]??0)+1;function B(e,t,r="none"){let n=I[e];if(n)return n.active?$()||console.error(`Attempted to override the existing store ${e}. Make sure that stores are only created once.`):n.value.setState(t,!0),n.active=!0,n.value;{let n=H(e,t,r);return I[e]={value:n,active:!0},n}}function U(e,t){let r=I[e];return r?(r.active?$()||console.error(`Attempted to override the existing store ${e}. Make sure that stores are only created once.`):r.value=t,r.active=!0,r.value):(I[e]={value:t,active:!0},t)}function V(e,t,r="none"){let n=I[e];if(!n){let n=H(e,t??{},r);return I[e]={value:n,active:!1},n}return n.value}function W(...e){let[t,r,n]=e,o=void 0===n?r:n,a=void 0===n?e=>e:r,i=a(t.getState());return o(i),t.subscribe(e=>{let t=a(e);R(i,t)||(i=t,o(t))})}function H(e,t,r){return"sessionStorage"===r?A()(((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 a,i,s={getStorage:()=>localStorage,serialize:JSON.stringify,deserialize:JSON.parse,partialize:e=>e,version:0,merge:(e,t)=>({...t,...e}),...t},l=!1,u=new Set,c=new Set;try{a=s.getStorage()}catch(e){}if(!a)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 d=N(s.serialize),f=()=>{let e,t=d({state:s.partialize({...n()}),version:s.version}).then(e=>a.setItem(s.name,e)).catch(t=>{e=t});if(e)throw e;return t},p=o.setState;o.setState=(e,t)=>{p(e,t),f()};let m=e((...e)=>{r(...e),f()},n,o),h=()=>{var e;if(!a)return;l=!1,u.forEach(e=>e(n()));let t=(null==(e=s.onRehydrateStorage)?void 0:e.call(s,n()))||void 0;return N(a.getItem.bind(a))(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(i=s.merge(e,null!=(t=n())?t:m),!0),f()}).then(()=>{null==t||t(i,void 0),l=!0,c.forEach(e=>e(i))}).catch(e=>{null==t||t(void 0,e)})};return o.persist={setOptions:e=>{s={...s,...e},e.getStorage&&(a=e.getStorage())},clearStorage:()=>{null==a||a.removeItem(s.name)},getOptions:()=>s,rehydrate:()=>h(),hasHydrated:()=>l,onHydrate:e=>(u.add(e),()=>{u.delete(e)}),onFinishHydration:e=>(c.add(e),()=>{c.delete(e)})},h(),i||m};return(r,n,o)=>{let a,i={storage:T(()=>localStorage),partialize:e=>e,version:0,merge:(e,t)=>({...t,...e}),...t},s=!1,l=new Set,u=new Set,c=i.storage;if(!c)return e((...e)=>{console.warn(`[zustand persist middleware] Unable to update item '${i.name}', the given storage is currently unavailable.`),r(...e)},n,o);let d=()=>{let e=i.partialize({...n()});return c.setItem(i.name,{state:e,version:i.version})},f=o.setState;o.setState=(e,t)=>{f(e,t),d()};let p=e((...e)=>{r(...e),d()},n,o);o.getInitialState=()=>p;let m=()=>{var e,t;if(!c)return;s=!1,l.forEach(e=>{var t;return e(null!=(t=n())?t:p)});let o=(null==(t=i.onRehydrateStorage)?void 0:t.call(i,null!=(e=n())?e:p))||void 0;return N(c.getItem.bind(c))(i.name).then(e=>{if(e)if("number"!=typeof e.version||e.version===i.version)return[!1,e.state];else{if(i.migrate)return[!0,i.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,s]=e;if(r(a=i.merge(s,null!=(t=n())?t:p),!0),o)return d()}).then(()=>{null==o||o(a,void 0),a=n(),s=!0,u.forEach(e=>e(a))}).catch(e=>{null==o||o(void 0,e)})};return o.persist={setOptions:e=>{i={...i,...e},e.storage&&(c=e.storage)},clearStorage:()=>{null==c||c.removeItem(i.name)},getOptions:()=>i,rehydrate:()=>m(),hasHydrated:()=>s,onHydrate:e=>(l.add(e),()=>{l.delete(e)}),onFinishHydration:e=>(u.add(e),()=>{u.delete(e)})},i.skipHydration||m(),a||p}})(()=>t,{name:e,storage:T(()=>sessionStorage)})):A()(()=>t)}L[M]=F,F>1&&!$()&&console.error(`Detected ${F} copies of @openmrs/esm-framework running on this page. Each copy keeps its own store registry, so stores, configuration and extension state are not shared between them. This usually means a frontend module loaded its own bundled framework instead of the one the app shell provides.`),globalThis.setTimeout?.(()=>{"u">typeof window&&"development"===window.spaEnv&&(window.stores=I)},1e3);let z=function(e){return void 0===e};var K,G,Z,Y,q,J,X,Q,ee,et,er,en,eo,ea,ei=r(8348);let es=function(e,t){return function(r){return e(t(r))}};var el=es(Object.getPrototypeOf,Object),eu=r(3098),ec=Object.prototype,ed=Function.prototype.toString,ef=ec.hasOwnProperty,ep=ed.call(Object);let em=function(e){if(!(0,eu.A)(e)||"[object Object]"!=(0,ei.A)(e))return!1;var t=el(e);if(null===t)return!0;var r=ef.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&ed.call(r)==ep},eh=function(e,t){return e===t||e!=e&&t!=t},eg=function(e,t){for(var r=e.length;r--;)if(eh(e[r][0],t))return r;return -1};var ey=Array.prototype.splice;function ev(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])}}ev.prototype.clear=function(){this.__data__=[],this.size=0},ev.prototype.delete=function(e){var t=this.__data__,r=eg(t,e);return!(r<0)&&(r==t.length-1?t.pop():ey.call(t,r,1),--this.size,!0)},ev.prototype.get=function(e){var t=this.__data__,r=eg(t,e);return r<0?void 0:t[r][1]},ev.prototype.has=function(e){return eg(this.__data__,e)>-1},ev.prototype.set=function(e,t){var r=this.__data__,n=eg(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this};var eb=r(3149);let ew=function(e){if(!(0,eb.A)(e))return!1;var t=(0,ei.A)(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t};var eE=r(1917),ex=eE.A["__core-js_shared__"],eD=(K=/[^.]+$/.exec(ex&&ex.keys&&ex.keys.IE_PROTO||""))?"Symbol(src)_1."+K:"",e_=Function.prototype.toString;let eS=function(e){if(null!=e){try{return e_.call(e)}catch(e){}try{return e+""}catch(e){}}return""};var eC=/^\[object .+?Constructor\]$/,ek=Object.prototype,eP=Function.prototype.toString,eO=ek.hasOwnProperty,eR=RegExp("^"+eP.call(eO).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");let eT=function(e){return!!(0,eb.A)(e)&&(!eD||!(eD in e))&&(ew(e)?eR:eC).test(eS(e))},eN=function(e,t){var r=null==e?void 0:e[t];return eT(r)?r:void 0};var ej=eN(eE.A,"Map"),eA=eN(Object,"create"),e$=Object.prototype.hasOwnProperty,eI=Object.prototype.hasOwnProperty;function eM(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])}}eM.prototype.clear=function(){this.__data__=eA?eA(null):{},this.size=0},eM.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=!!t,t},eM.prototype.get=function(e){var t=this.__data__;if(eA){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return e$.call(t,e)?t[e]:void 0},eM.prototype.has=function(e){var t=this.__data__;return eA?void 0!==t[e]:eI.call(t,e)},eM.prototype.set=function(e,t){var r=this.__data__;return this.size+=+!this.has(e),r[e]=eA&&void 0===t?"__lodash_hash_undefined__":t,this};let eL=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e},eF=function(e,t){var r=e.__data__;return eL(t)?r["string"==typeof t?"string":"hash"]:r.map};function eB(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])}}function eU(e){var t=this.__data__=new ev(e);this.size=t.size}eB.prototype.clear=function(){this.size=0,this.__data__={hash:new eM,map:new(ej||ev),string:new eM}},eB.prototype.delete=function(e){var t=eF(this,e).delete(e);return this.size-=!!t,t},eB.prototype.get=function(e){return eF(this,e).get(e)},eB.prototype.has=function(e){return eF(this,e).has(e)},eB.prototype.set=function(e,t){var r=eF(this,e),n=r.size;return r.set(e,t),this.size+=+(r.size!=n),this},eU.prototype.clear=function(){this.__data__=new ev,this.size=0},eU.prototype.delete=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r},eU.prototype.get=function(e){return this.__data__.get(e)},eU.prototype.has=function(e){return this.__data__.has(e)},eU.prototype.set=function(e,t){var r=this.__data__;if(r instanceof ev){var n=r.__data__;if(!ej||n.length<199)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new eB(n)}return r.set(e,t),this.size=r.size,this};var eV=function(){try{var e=eN(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();let eW=function(e,t,r){"__proto__"==t&&eV?eV(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r},eH=function(e,t,r){(void 0===r||eh(e[t],r))&&(void 0!==r||t in e)||eW(e,t,r)},ez=function(e,t,r){for(var n=-1,o=Object(e),a=r(e),i=a.length;i--;){var s=a[++n];if(!1===t(o[s],s,o))break}return e};var eK="object"==typeof exports&&exports&&!exports.nodeType&&exports,eG=eK&&"object"==typeof module&&module&&!module.nodeType&&module,eZ=eG&&eG.exports===eK?eE.A.Buffer:void 0,eY=eZ?eZ.allocUnsafe:void 0;let eq=function(e,t){if(t)return e.slice();var r=e.length,n=eY?eY(r):new e.constructor(r);return e.copy(n),n};var eJ=eE.A.Uint8Array;let eX=function(e){var t=new e.constructor(e.byteLength);return new eJ(t).set(new eJ(e)),t},eQ=function(e,t){var r=t?eX(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)},e0=function(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t};var e1=Object.create,e2=function(){function e(){}return function(t){if(!(0,eb.A)(t))return{};if(e1)return e1(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}(),e4=Object.prototype;let e3=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||e4)},e6=function(e){return"function"!=typeof e.constructor||e3(e)?{}:e2(el(e))},e5=function(e){return(0,eu.A)(e)&&"[object Arguments]"==(0,ei.A)(e)};var e9=Object.prototype,e8=e9.hasOwnProperty,e7=e9.propertyIsEnumerable,te=e5(function(){return arguments}())?e5:function(e){return(0,eu.A)(e)&&e8.call(e,"callee")&&!e7.call(e,"callee")},tt=Array.isArray;let tr=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=0x1fffffffffffff},tn=function(e){return null!=e&&tr(e.length)&&!ew(e)};var to="object"==typeof exports&&exports&&!exports.nodeType&&exports,ta=to&&"object"==typeof module&&module&&!module.nodeType&&module,ti=ta&&ta.exports===to?eE.A.Buffer:void 0;let ts=(ti?ti.isBuffer:void 0)||function(){return!1};var tl={};tl["[object Float32Array]"]=tl["[object Float64Array]"]=tl["[object Int8Array]"]=tl["[object Int16Array]"]=tl["[object Int32Array]"]=tl["[object Uint8Array]"]=tl["[object Uint8ClampedArray]"]=tl["[object Uint16Array]"]=tl["[object Uint32Array]"]=!0,tl["[object Arguments]"]=tl["[object Array]"]=tl["[object ArrayBuffer]"]=tl["[object Boolean]"]=tl["[object DataView]"]=tl["[object Date]"]=tl["[object Error]"]=tl["[object Function]"]=tl["[object Map]"]=tl["[object Number]"]=tl["[object Object]"]=tl["[object RegExp]"]=tl["[object Set]"]=tl["[object String]"]=tl["[object WeakMap]"]=!1;let tu=function(e){return function(t){return e(t)}};var tc=r(2136),td="object"==typeof exports&&exports&&!exports.nodeType&&exports,tf=td&&"object"==typeof module&&module&&!module.nodeType&&module,tp=tf&&tf.exports===td&&tc.A.process,tm=function(){try{var e=tf&&tf.require&&tf.require("util").types;if(e)return e;return tp&&tp.binding&&tp.binding("util")}catch(e){}}(),th=tm&&tm.isTypedArray,tg=th?tu(th):function(e){return(0,eu.A)(e)&&tr(e.length)&&!!tl[(0,ei.A)(e)]};let ty=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]};var tv=Object.prototype.hasOwnProperty;let tb=function(e,t,r){var n=e[t];tv.call(e,t)&&eh(n,r)&&(void 0!==r||t in e)||eW(e,t,r)},tw=function(e,t,r,n){var o=!r;r||(r={});for(var a=-1,i=t.length;++a<i;){var s=t[a],l=n?n(r[s],e[s],s,r,e):void 0;void 0===l&&(l=e[s]),o?eW(r,s,l):tb(r,s,l)}return r},tE=function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n};var tx=/^(?:0|[1-9]\d*)$/;let tD=function(e,t){var r=typeof e;return!!(t=null==t?0x1fffffffffffff:t)&&("number"==r||"symbol"!=r&&tx.test(e))&&e>-1&&e%1==0&&e<t};var t_=Object.prototype.hasOwnProperty;let tS=function(e,t){var r=tt(e),n=!r&&te(e),o=!r&&!n&&ts(e),a=!r&&!n&&!o&&tg(e),i=r||n||o||a,s=i?tE(e.length,String):[],l=s.length;for(var u in e)(t||t_.call(e,u))&&!(i&&("length"==u||o&&("offset"==u||"parent"==u)||a&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||tD(u,l)))&&s.push(u);return s},tC=function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t};var tk=Object.prototype.hasOwnProperty;let tP=function(e){if(!(0,eb.A)(e))return tC(e);var t=e3(e),r=[];for(var n in e)"constructor"==n&&(t||!tk.call(e,n))||r.push(n);return r},tO=function(e){return tn(e)?tS(e,!0):tP(e)},tR=function(e,t,r,n,o,a,i){var s=ty(e,r),l=ty(t,r),u=i.get(l);if(u)return void eH(e,r,u);var c=a?a(s,l,r+"",e,t,i):void 0,d=void 0===c;if(d){var f=tt(l),p=!f&&ts(l),m=!f&&!p&&tg(l);(c=l,f||p||m)?tt(s)?c=s:(0,eu.A)(s)&&tn(s)?c=e0(s):p?(d=!1,c=eq(l,!0)):m?(d=!1,c=eQ(l,!0)):c=[]:em(l)||te(l)?(c=s,te(s))?c=tw(s,tO(s)):(!(0,eb.A)(s)||ew(s))&&(c=e6(l)):d=!1}d&&(i.set(l,c),o(c,l,n,a,i),i.delete(l)),eH(e,r,c)},tT=function e(t,r,n,o,a){t!==r&&ez(r,function(i,s){if(a||(a=new eU),(0,eb.A)(i))tR(t,r,s,n,e,o,a);else{var l=o?o(ty(t,s),i,s+"",t,r,a):void 0;void 0===l&&(l=i),eH(t,s,l)}},tO)},tN=function(e){return e},tj=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 tA=Math.max;let t$=function(e,t,r){return t=tA(void 0===t?e.length-1:t,0),function(){for(var n=arguments,o=-1,a=tA(n.length-t,0),i=Array(a);++o<a;)i[o]=n[t+o];o=-1;for(var s=Array(t+1);++o<t;)s[o]=n[o];return s[t]=r(i),tj(e,this,s)}};var tI=Date.now,tM=(G=eV?function(e,t){return eV(e,"toString",{configurable:!0,enumerable:!1,value:function(){return t},writable:!0})}:tN,Z=0,Y=0,function(){var e=tI(),t=16-(e-Y);if(Y=e,t>0){if(++Z>=800)return arguments[0]}else Z=0;return G.apply(void 0,arguments)});let tL=function(e,t,r){if(!(0,eb.A)(r))return!1;var n=typeof t;return("number"==n?!!(tn(r)&&tD(t,r.length)):"string"==n&&t in r)&&eh(r[t],e)},tF=function(e){var t;return tM(t$(t=function(t,r){var n=-1,o=r.length,a=o>1?r[o-1]:void 0,i=o>2?r[2]:void 0;for(a=e.length>3&&"function"==typeof a?(o--,a):void 0,i&&tL(r[0],r[1],i)&&(a=o<3?void 0:a,o=1),t=Object(t);++n<o;){var s=r[n];s&&e(t,s,n,a)}return t},void 0,tN),t+"")};var tB=tF(function(e,t,r,n){tT(e,t,r,n)});function tU(e){var t=-1,r=null==e?0:e.length;for(this.__data__=new eB;++t<r;)this.add(e[t])}tU.prototype.add=tU.prototype.push=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},tU.prototype.has=function(e){return this.__data__.has(e)};let tV=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},tW=function(e,t,r,n,o,a){var i=1&r,s=e.length,l=t.length;if(s!=l&&!(i&&l>s))return!1;var u=a.get(e),c=a.get(t);if(u&&c)return u==t&&c==e;var d=-1,f=!0,p=2&r?new tU:void 0;for(a.set(e,t),a.set(t,e);++d<s;){var m=e[d],h=t[d];if(n)var g=i?n(h,m,d,t,e,a):n(m,h,d,e,t,a);if(void 0!==g){if(g)continue;f=!1;break}if(p){if(!tV(t,function(e,t){if(!p.has(t)&&(m===e||o(m,e,r,n,a)))return p.push(t)})){f=!1;break}}else if(!(m===h||o(m,h,r,n,a))){f=!1;break}}return a.delete(e),a.delete(t),f};var tH=r(241);let tz=function(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r},tK=function(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r};var tG=tH.A?tH.A.prototype:void 0,tZ=tG?tG.valueOf:void 0;let tY=function(e,t,r,n,o,a,i){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||!a(new eJ(e),new eJ(t)))break;return!0;case"[object Boolean]":case"[object Date]":case"[object Number]":return eh(+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=tz;case"[object Set]":var l=1&n;if(s||(s=tK),e.size!=t.size&&!l)break;var u=i.get(e);if(u)return u==t;n|=2,i.set(e,t);var c=tW(s(e),s(t),n,o,a,i);return i.delete(e),c;case"[object Symbol]":if(tZ)return tZ.call(e)==tZ.call(t)}return!1},tq=function(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e},tJ=function(e,t,r){var n=t(e);return tt(e)?n:tq(n,r(e))},tX=function(e,t){for(var r=-1,n=null==e?0:e.length,o=0,a=[];++r<n;){var i=e[r];t(i,r,e)&&(a[o++]=i)}return a},tQ=function(){return[]};var t0=Object.prototype.propertyIsEnumerable,t1=Object.getOwnPropertySymbols,t2=t1?function(e){return null==e?[]:tX(t1(e=Object(e)),function(t){return t0.call(e,t)})}:tQ,t4=es(Object.keys,Object),t3=Object.prototype.hasOwnProperty;let t6=function(e){if(!e3(e))return t4(e);var t=[];for(var r in Object(e))t3.call(e,r)&&"constructor"!=r&&t.push(r);return t},t5=function(e){return tn(e)?tS(e):t6(e)},t9=function(e){return tJ(e,t5,t2)};var t8=Object.prototype.hasOwnProperty;let t7=function(e,t,r,n,o,a){var i=1&r,s=t9(e),l=s.length;if(l!=t9(t).length&&!i)return!1;for(var u=l;u--;){var c=s[u];if(!(i?c in t:t8.call(t,c)))return!1}var d=a.get(e),f=a.get(t);if(d&&f)return d==t&&f==e;var p=!0;a.set(e,t),a.set(t,e);for(var m=i;++u<l;){var h=e[c=s[u]],g=t[c];if(n)var y=i?n(g,h,c,t,e,a):n(h,g,c,e,t,a);if(!(void 0===y?h===g||o(h,g,r,n,a):y)){p=!1;break}m||(m="constructor"==c)}if(p&&!m){var v=e.constructor,b=t.constructor;v!=b&&"constructor"in e&&"constructor"in t&&!("function"==typeof v&&v instanceof v&&"function"==typeof b&&b instanceof b)&&(p=!1)}return a.delete(e),a.delete(t),p};var re=eN(eE.A,"DataView"),rt=eN(eE.A,"Promise"),rr=eN(eE.A,"Set"),rn=eN(eE.A,"WeakMap"),ro="[object Map]",ra="[object Promise]",ri="[object Set]",rs="[object WeakMap]",rl="[object DataView]",ru=eS(re),rc=eS(ej),rd=eS(rt),rf=eS(rr),rp=eS(rn),rm=ei.A;(re&&rm(new re(new ArrayBuffer(1)))!=rl||ej&&rm(new ej)!=ro||rt&&rm(rt.resolve())!=ra||rr&&rm(new rr)!=ri||rn&&rm(new rn)!=rs)&&(rm=function(e){var t=(0,ei.A)(e),r="[object Object]"==t?e.constructor:void 0,n=r?eS(r):"";if(n)switch(n){case ru:return rl;case rc:return ro;case rd:return ra;case rf:return ri;case rp:return rs}return t});let rh=rm;var rg="[object Arguments]",ry="[object Array]",rv="[object Object]",rb=Object.prototype.hasOwnProperty;let rw=function(e,t,r,n,o,a){var i=tt(e),s=tt(t),l=i?ry:rh(e),u=s?ry:rh(t);l=l==rg?rv:l,u=u==rg?rv:u;var c=l==rv,d=u==rv,f=l==u;if(f&&ts(e)){if(!ts(t))return!1;i=!0,c=!1}if(f&&!c)return a||(a=new eU),i||tg(e)?tW(e,t,r,n,o,a):tY(e,t,l,r,n,o,a);if(!(1&r)){var p=c&&rb.call(e,"__wrapped__"),m=d&&rb.call(t,"__wrapped__");if(p||m){var h=p?e.value():e,g=m?t.value():t;return a||(a=new eU),o(h,g,r,n,a)}}return!!f&&(a||(a=new eU),t7(e,t,r,n,o,a))},rE=function(e,t){return function e(t,r,n,o,a){return t===r||(null!=t&&null!=r&&((0,eu.A)(t)||(0,eu.A)(r))?rw(t,r,n,o,e,a):t!=t&&r!=r)}(e,t)},rx=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},rD=function(e,t){for(var r=-1,n=null==e?0:e.length;++r<n&&!1!==t(e[r],r,e););return e};var r_=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)tq(t,t2(e)),e=el(e);return t}:tQ;let rS=function(e){return tJ(e,tO,r_)};var rC=Object.prototype.hasOwnProperty;let rk=function(e){var t=e.length,r=new e.constructor(t);return t&&"string"==typeof e[0]&&rC.call(e,"index")&&(r.index=e.index,r.input=e.input),r},rP=function(e,t){var r=t?eX(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)};var rO=/\w*$/;let rR=function(e){var t=new e.constructor(e.source,rO.exec(e));return t.lastIndex=e.lastIndex,t};var rT=tH.A?tH.A.prototype:void 0,rN=rT?rT.valueOf:void 0;let rj=function(e,t,r){var n=e.constructor;switch(t){case"[object ArrayBuffer]":return eX(e);case"[object Boolean]":case"[object Date]":return new n(+e);case"[object DataView]":return rP(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 eQ(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 rR(e);case"[object Symbol]":return rN?Object(rN.call(e)):{}}};var rA=tm&&tm.isMap,r$=rA?tu(rA):function(e){return(0,eu.A)(e)&&"[object Map]"==rh(e)},rI=tm&&tm.isSet,rM=rI?tu(rI):function(e){return(0,eu.A)(e)&&"[object Set]"==rh(e)},rL="[object Arguments]",rF="[object Function]",rB="[object Object]",rU={};rU[rL]=rU["[object Array]"]=rU["[object ArrayBuffer]"]=rU["[object DataView]"]=rU["[object Boolean]"]=rU["[object Date]"]=rU["[object Float32Array]"]=rU["[object Float64Array]"]=rU["[object Int8Array]"]=rU["[object Int16Array]"]=rU["[object Int32Array]"]=rU["[object Map]"]=rU["[object Number]"]=rU[rB]=rU["[object RegExp]"]=rU["[object Set]"]=rU["[object String]"]=rU["[object Symbol]"]=rU["[object Uint8Array]"]=rU["[object Uint8ClampedArray]"]=rU["[object Uint16Array]"]=rU["[object Uint32Array]"]=!0,rU["[object Error]"]=rU[rF]=rU["[object WeakMap]"]=!1;let rV=function e(t,r,n,o,a,i){var s,l=1&r,u=2&r,c=4&r;if(n&&(s=a?n(t,o,a,i):n(t)),void 0!==s)return s;if(!(0,eb.A)(t))return t;var d=tt(t);if(d){if(s=rk(t),!l)return e0(t,s)}else{var f,p,m,h,g=rh(t),y=g==rF||"[object GeneratorFunction]"==g;if(ts(t))return eq(t,l);if(g==rB||g==rL||y&&!a){if(s=u||y?{}:e6(t),!l)return u?(p=(f=s)&&tw(t,tO(t),f),tw(t,r_(t),p)):(h=(m=s)&&tw(t,t5(t),m),tw(t,t2(t),h))}else{if(!rU[g])return a?t:{};s=rj(t,g,l)}}i||(i=new eU);var v=i.get(t);if(v)return v;i.set(t,s),rM(t)?t.forEach(function(o){s.add(e(o,r,n,o,t,i))}):r$(t)&&t.forEach(function(o,a){s.set(a,e(o,r,n,a,t,i))});var b=c?u?rS:t9:u?tO:t5,w=d?void 0:b(t);return rD(w||t,function(o,a){w&&(o=t[a=o]),tb(s,a,e(o,r,n,a,t,i))}),s};var rW=r(1882),rH=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,rz=/^\w*$/;let rK=function(e,t){if(tt(e))return!1;var r=typeof e;return!!("number"==r||"symbol"==r||"boolean"==r||null==e||(0,rW.A)(e))||rz.test(e)||!rH.test(e)||null!=t&&e in Object(t)};function rG(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],a=r.cache;if(a.has(o))return a.get(o);var i=e.apply(this,n);return r.cache=a.set(o,i)||a,i};return r.cache=new(rG.Cache||eB),r}rG.Cache=eB;var rZ=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,rY=/\\(\\)?/g,rq=(J=(q=rG(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(rZ,function(e,r,n,o){t.push(n?o.replace(rY,"$1"):r||e)}),t},function(e){return 500===J.size&&J.clear(),e})).cache,q),rJ=1/0,rX=tH.A?tH.A.prototype:void 0,rQ=rX?rX.toString:void 0;let r0=function e(t){if("string"==typeof t)return t;if(tt(t))return rx(t,e)+"";if((0,rW.A)(t))return rQ?rQ.call(t):"";var r=t+"";return"0"==r&&1/t==-rJ?"-0":r},r1=function(e,t){return tt(e)?e:rK(e,t)?[e]:rq(null==e?"":r0(e))},r2=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0};var r4=1/0;let r3=function(e){if("string"==typeof e||(0,rW.A)(e))return e;var t=e+"";return"0"==t&&1/e==-r4?"-0":t},r6=function(e,t){t=r1(t,e);for(var r=0,n=t.length;null!=e&&r<n;)e=e[r3(t[r++])];return r&&r==n?e:void 0},r5=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 a=Array(o);++n<o;)a[n]=e[n+t];return a},r9=function(e,t){var r,n;return t=r1(t,e),r=e,null==(e=(n=t).length<2?r:r6(r,r5(n,0,-1)))||delete e[r3(r2(t))]},r8=function(e){return em(e)?void 0:e};var r7=tH.A?tH.A.isConcatSpreadable:void 0;let ne=function(e){return tt(e)||te(e)||!!(r7&&e&&e[r7])},nt=function e(t,r,n,o,a){var i=-1,s=t.length;for(n||(n=ne),a||(a=[]);++i<s;){var l=t[i];r>0&&n(l)?r>1?e(l,r-1,n,o,a):tq(a,l):o||(a[a.length]=l)}return a};var nr=tM(t$(X=function(e,t){var r={};if(null==e)return r;var n=!1;t=rx(t,function(t){return t=r1(t,e),n||(n=t.length>1),t}),tw(e,rS(e),r),n&&(r=rV(r,7,r8));for(var o=t.length;o--;)r9(r,t[o]);return r},void 0,function(e){return(null==e?0:e.length)?nt(e,1):[]}),X+""),nn=((Q={}).Array="Array",Q.Boolean="Boolean",Q.ConceptUuid="ConceptUuid",Q.Number="Number",Q.Object="Object",Q.String="String",Q.UUID="UUID",Q.PersonAttributeTypeUuid="PersonAttributeTypeUuid",Q.PatientIdentifierTypeUuid="PatientIdentifierTypeUuid",Q);function no(e,t){return r=>{if(!e(r))if("function"==typeof t)return t(r);else return t}}let na=no(e=>Array.isArray(e),"must be an array"),ni=no(e=>"boolean"==typeof e,"must be a boolean"),ns=no(e=>"number"==typeof e,"must be a number"),nl=no(e=>"string"==typeof e,"must be a string"),nu=no(e=>"object"==typeof e&&!Array.isArray(e)&&null!==e,"must be an object (not an array or null)"),nc=no(e=>/^[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"),nd=B("config-internal",{providedConfigs:[],schemas:{},moduleLoaded:{}}),nf=B("temporary-config",{config:function(){try{return JSON.parse(localStorage.getItem("openmrs:temporaryConfig")||"{}")}catch(e){return{}}}()});nf.subscribe(e=>{var t=e.config;try{localStorage.setItem("openmrs:temporaryConfig",JSON.stringify(t))}catch(e){}});let np=B("config-store-of-extension-state",{mountedExtensions:[]});function nm(e){return V(`config-module-${e}`,{config:null,loaded:!1,translationOverridesLoaded:!1})}function nh(){return V("config-extension-slots",{slots:{}})}function ng(e){return ny(nh().getState(),e)}function ny(e,t){return e.slots[t]??{loaded:!1,config:{}}}function nv(){return V("config-extensions",{configs:{}})}function nb(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");let r=nv(),n=r=>r.configs[e]?.[t];return{getInitialState:()=>n(r.getInitialState()),getState:()=>n(r.getState())??{loaded:!1,config:null},subscribe:e=>r.subscribe((t,r)=>{let o=n(t),a=n(r);R(o,a)||e(o,a)})}}function nw(e,t,r){return e.configs[t]?.[r]??{loaded:!1,config:null}}function nE(e,t,r){return e.configure?.[r]??null}let nx=A()(()=>({config:{}})),nD=0,n_=!0,nS=!1;function nC(e){n=e}function nk(){n_=!0,nD>0&&nP()}function nP(){if(n_&&n&&!nS){nS=!0,n_=!1;try{n()}catch(e){n_=!0,nO(e),console.error("Failed to derive the implementer tools config",e)}finally{nS=!1}}}function nO(e){nx.setState({derivationError:e instanceof Error?e.message:String(e)})}function nR(){nx.getState().derivationError&&nx.setState({derivationError:void 0})}let nT=U("config-implementer-tools",{...nx,getState:()=>(0===nD&&nP(),nx.getState()),setState:(...e)=>(n_=!1,nx.setState(...e)),subscribe(e){nD++,nP();let t=nx.subscribe(e),r=!1;return()=>{!r&&(r=!0,nD--),t()}}});function nN(e,t){if(Array.isArray(t))return t}function nj(e,t){return tB({},e,t,nN)}let nA=[];function n$(){let e=nd.getState(),t=nf.getState(),r=np.getState();if(nI?.configState===e&&nI.tempConfigState===t)return void nU(e,r,t,nI.slotConfigs,!0);!function(e,t){for(let r of Object.keys(e.schemas)){let n,o=nm(r),a=e.schemas[r],i=!!e.moduleLoaded[r],s=nB.get(r);if(s&&s.schema===a&&s.moduleLoaded===i&&s.providedConfigs===e.providedConfigs&&s.temporaryConfig===t.config)n=s.state;else{let o=i?function(e,t,r){let n=t.schemas[e],o=n4(e,n1(t,r));n6(n,o,e);let a=n7(n,o);return n5(n,a,e),delete a.extensionSlots,a}(r,e,t):function(e,t,r){let n=n7(os,n4(e,n1(t,r)));return n5(os,n,e),delete n.extensionSlots,n}(r,e,t);n={translationOverridesLoaded:!0,loaded:i,config:o},nB.set(r,{schema:a,moduleLoaded:i,providedConfigs:e.providedConfigs,temporaryConfig:t.config,state:n})}let l=o.getState();l.loaded===n.loaded&&l.translationOverridesLoaded===n.translationOverridesLoaded&&rE(l.config,n.config)||o.setState(n)}}(e,t);let n=function(e,t){let r=n3(n1(e,t)),n=Object.keys(r).reduce((e,t)=>(r[t]?.extensionSlots&&(e[t]=r[t]?.extensionSlots),e),{});var o=n;for(let[e,t]of Object.entries(o))for(let[r,n]of Object.entries(t))!function(e,t,r){let n=`${t}.extensionSlots.${r}`,o=`Extension slot config '${n}'`,a=Object.keys(e).filter(e=>!["add","remove","order","configure"].includes(e));a.length&&on(n,o+`' contains invalid keys '${a.join("', '")}'`),!e.add||Array.isArray(e.add)&&e.add.every(e=>"string"==typeof e)||on(n,o+".add' is invalid. Must be an array of strings (extension IDs)"),!e.remove||Array.isArray(e.remove)&&e.remove.every(e=>"string"==typeof e)||on(n,o+".remove' is invalid. Must be an array of strings (extension IDs)"),!e.order||Array.isArray(e.order)&&e.order.every(e=>"string"==typeof e)||on(n,o+".order' is invalid. Must be an array of strings (extension IDs)"),e.configure&&!ot(e.configure)&&on(n,o+".configure' is invalid. Must be an object with extension IDs for keys")}(n,e,r);let a={},i={};for(let e of Object.values(n))for(let[t,r]of Object.entries(e))a[t]=r,r.configure&&(i[t]??(i[t]=[])).push(r.configure);for(let[e,t]of Object.entries(i)){let r=1===t.length?t[0]:n3(t);a[e].configure!==r&&(a[e]={...a[e],configure:r})}return a}(e,t);(function(e){let t=nh(),r=t.getState().slots,n={},o=!1;for(let[t,a]of Object.entries(e)){let e=r[t];e?.loaded&&rE(e.config,a)?n[t]=e:(n[t]={loaded:!0,config:a},o=!0)}(o||Object.keys(r).length!==Object.keys(n).length)&&t.setState({slots:n})})(n),nU(e,r,t,n,!1),nI={configState:e,tempConfigState:t,slotConfigs:n},nk()}let nI=null,nM=new WeakMap;function nL(){n=()=>{var e,t;let r,n;return e=nd.getState(),t=nf.getState(),r=nT.getState(),n={config:function(e,t){let r=function(e){let t={};for(let[r,n]of Object.entries(e)){let e=n0.get(r);if(e&&e.schema===n)t[r]=e.annotated;else{let e=function e(t){return t.hasOwnProperty("_default")?{...t,_value:t._default,_source:"default"}:ot(t)?Object.keys(t).reduce((r,n)=>(r[n]=e(t[n]),r),{}):{}}(rV(n,5));n0.set(r,{schema:n,annotated:e}),t[r]=e}}return t}(e.schemas),n=[...e.providedConfigs.map(e=>[e.config,e.source]),[t.config,"temporary config"]],o=new Set(Object.keys(r));for(let[e]of n)for(let t of Object.keys(e))o.add(t);let a={};for(let e of o){let t=r[e],o=n.map(([t])=>t[e]),i=n.map(([,e])=>e),s=nQ.get(e);if(s&&s.annotatedSchema===t&&s.configSlices.length===o.length&&s.configSlices.every((e,t)=>e===o[t])&&s.sources.every((e,t)=>e===i[t])){a[e]=s.result;continue}let l=t??{};n.forEach(([,e],t)=>{let r=o[t];void 0!==r&&(l=nj(l,function e(t,r){return ot(t)?Object.keys(t).reduce((n,o)=>(n[o]=e(t[o],r),n),{}):{_value:t,_source:r}}(r,e)))}),nQ.set(e,{annotatedSchema:t,configSlices:o,sources:i,result:l}),a[e]=l}return a}(e,t)},void(rE(r.config,n.config)||nT.setState(n))},n$(),nA.push(nd.subscribe(nF),nf.subscribe(nF),np.subscribe(nF))}function nF(){nR();try{n$()}catch(e){nO(e),console.error("Failed to recompute the configuration",e)}}nL();let nB=new Map;function nU(e,t,r,n,o){let a=nv(),i=a.getState().configs,s={},l=!1,u=0;for(let a of t.mountedExtensions){let t,c=i[a.slotName]?.[a.extensionId],d=c&&nM.get(c);if(o&&c?.loaded&&d?.slotModuleName===a.slotModuleName&&d.extensionModuleName===a.extensionModuleName)t=c;else{let o=function(e,t,r,n,o,a,i){let s=function(e){let[t]=e.split("#");return t}(n),l=o.schemas[s],u=JSON.stringify([r,n,e,t]),c=nX.get(u);if(c&&c.extensionSchema===l&&c.extensionModuleSchema===o.schemas[t]&&c.providedConfigs===o.providedConfigs&&c.temporaryConfig===a.config)return c.config;let d=l?s:t,f=n1(o,a),p=i?.configure?.[n]??{},m=n4(e,f),h=m?.extensionSlots?.[r]?.configure?.[n]??{},g=n3([n4(d,f),p,h]),y=l??o.schemas[t];n6(y,g,d);let v=n7(y,g);return n5(y,v,d),delete v.extensionSlots,nX.set(u,{extensionSchema:l,extensionModuleSchema:o.schemas[t],providedConfigs:o.providedConfigs,temporaryConfig:a.config,config:v}),v}(a.slotModuleName,a.extensionModuleName,a.slotName,a.extensionId,e,r,n[a.slotName]);t=c?.loaded&&rE(c.config,o)?c:{config:o,loaded:!0}}nM.set(t,a),t!==c&&(l=!0),s[a.slotName]||(s[a.slotName]={}),s[a.slotName][a.extensionId]=t,u++}for(let[e,t]of Object.entries(s)){let r=i[e];r&&Object.keys(r).length===Object.keys(t).length&&Object.entries(t).every(([e,t])=>r[e]===t)&&(s[e]=r)}l||(l=Object.keys(i).length!==Object.keys(s).length||Object.values(i).reduce((e,t)=>e+Object.keys(t).length,0)!==u),l&&a.setState({configs:s})}function nV(e,t){n2(e,t);let r=nj(t,os);nd.setState(t=>({...t,schemas:{...t.schemas,[e]:r},moduleLoaded:{...t.moduleLoaded,[e]:!0}}))}function nW(e){nd.setState(t=>({...t,schemas:{...t.schemas,[e]:os}}))}function nH(e){nd.setState(t=>({...t,moduleLoaded:{...t.moduleLoaded,[e]:!0}}))}function nz(e){nd.setState(t=>({...t,schemas:{...t.schemas,[e]:oi}}))}function nK(e,t){n2(e,t);let r=nj(t,os);nd.getState().schemas[e]&&console.error(`Config schema for extension ${e} already exists. If there are multiple extensions with this same name, one will probably crash.`),nd.setState(t=>({...t,schemas:{...t.schemas,[e]:r}}))}function nG(e,t="provided"){nd.setState(r=>({...r,providedConfigs:[...r.providedConfigs,{source:t,config:e}]}))}function nZ(e,t,r){return new Promise(n=>{let o,a=!1;function i(e){!a&&t(e)&&(a=!0,n(r(e)),o?.())}i(e.getState()),a||(o=e.subscribe(i))})}function nY(e){return nZ(nm(e),e=>!!(e.loaded&&e.config),e=>nr(e.config,["Display conditions","Translation overrides"]))}function nq(e,t,r){let n=[nZ(nm(e),e=>!!(e.translationOverridesLoaded&&e.config),e=>e.config["Translation overrides"]??{})];return t&&r&&n.push(nZ(nb(t,r),e=>!!(e.loaded&&e.config),e=>e.config["Translation overrides"]??{})),Promise.all(n)}function nJ(e,t,r){n6(e,t,r);let n=n7(e,t);return n5(e,n,r),n}let nX=new Map,nQ=new Map,n0=new Map;function n1(e,t){return[...e.providedConfigs.map(e=>e.config),t.config]}function n2(e,t,r=""){let n="Please verify that you are running the latest version and, if so, alert the maintainer.";for(let o of Object.keys(t).filter(e=>!e.startsWith("_"))){let a=r+(r&&".")+o,i=t[o];if("Display conditions"===a&&console.error(`${e} declares a configuration option called "Display conditions"; the "Display conditions" option is a reserved name. ${n}`),"Translation overrides"===a&&console.error(`${e} declares a configuration option called "Translation overrides"; the "Translation overrides" option is a reserved name. ${n}`),!ot(i)){console.error(`${e} has bad config schema definition for key '${a}'. ${n}`);continue}i.hasOwnProperty("_default")||n2(e,i,a);let s=i._elements;if(oe(s)&&n2(e,s,a+"._elements"),i._validators)for(let t of i._validators)"function"!=typeof t&&console.error(`${e} has invalid validator for key '${a}' ${n}.
|
|
4
4
|
|
|
@@ -25,4 +25,4 @@ To fix this, ensure that you define the "description" field inside the feature f
|
|
|
25
25
|
To fix this, ensure that you define the "label" field inside the feature flag definition.`,t):console.error(`A feature flag definition in ${e} is missing a name and thus cannot be registered.
|
|
26
26
|
To fix this, ensure that you define the "name" field inside the feature flag definition.`,t);else console.warn(`A feature flag for ${e} could not be registered as it does not appear to have the required properties`,t)})}})(e,t))}function fi(){fo.sort((e,t)=>e.appName.localeCompare(t.appName,"en"));let e=new Map;for(let t of fo){e.has(t.appName)?e.set(t.appName,e.get(t.appName)+1):e.set(t.appName,0);let r=e.get(t.appName),n=`${t.appName}-page-${r}`,o=t.containerDomId??"omrs-apps-container",a=document.getElementById(o),i=`single-spa-application:${n}`;if(a){let e=document.createElement("div");e.id=i,a?.appendChild(e)}else throw Error(`${t.appName} ${t.component} cannot be mounted to "${o}"; DOM element does not exist.`);!function(e,t){let r=void 0!==t.route?t.route:void 0!==t.routeRegex&&new RegExp(t.routeRegex);!1===r?console.warn(`A registered page definition is missing a route and thus cannot be registered.
|
|
27
27
|
To fix this, ensure that you define the "route" (or alternatively the "routeRegex") field inside the extension definition.`,e):t.component?aT(e,()=>fe(t.appName,t.component),function(e,{featureFlag:t}){return t?r=>!!un(t)&&e(r):e}(function e(t){if(Array.isArray(t)){let r=t.map(e);return e=>r.some(t=>t(e))}return"string"==typeof t?aM(window.getOpenmrsSpaBase()+t):t instanceof RegExp?e=>t.test(e.pathname.replace(window.getOpenmrsSpaBase(),"")):()=>t}(r),t)):console.warn(`A registered page definition is missing a component and thus cannot be registered.
|
|
28
|
-
To fix this, ensure that you define the "component" field inside the page definition.`,e)}(n,t)}}let fs={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 fl(){document.body.classList.toggle("omrs-breakpoint-lt-tablet",window.innerWidth<fs.TABLET_MIN),document.body.classList.toggle("omrs-breakpoint-gt-phone",window.innerWidth>fs.PHONE_MAX),document.body.classList.toggle("omrs-breakpoint-gt-tablet",window.innerWidth>fs.TABLET_MAX),document.body.classList.toggle("omrs-breakpoint-lt-desktop",window.innerWidth<fs.SMALL_DESKTOP_MIN),document.body.classList.toggle("omrs-breakpoint-lt-small-desktop",window.innerWidth<fs.SMALL_DESKTOP_MIN),document.body.classList.toggle("omrs-breakpoint-lt-large-desktop",window.innerWidth<fs.LARGE_DESKTOP_MIN),document.body.classList.toggle("omrs-breakpoint-gt-small-desktop",window.innerWidth>fs.SMALL_DESKTOP_MAX)}let fu=!1;function fc(){fu||(window.addEventListener("resize",fl),fl(),fu=!0)}var fd=r(4848),ff=r(6942),fp=r.n(ff);function fm({title:e,children:t}){let r="tablet"===dI();return(0,fd.jsxs)("div",{className:fp()({"-esm-cohort-builder__card-header-module__tabletHeader___rUYi0":r,"-esm-cohort-builder__card-header-module__desktopHeader___CDa37":!r}),children:[(0,fd.jsx)("h4",{children:e}),t]})}let fh=["red","magenta","purple","blue","teal","cyan","gray","green","warm-gray","cool-gray","high-contrast","outline"],fg={primaryColor:{_type:nn.String,_description:"The color for displaying primary diagnoses tags",_default:"red",_validators:[of.oneOf(fh)]},secondaryColor:{_type:nn.String,_description:"The color for displaying secondary diagnoses tags",_default:"blue",_validators:[of.oneOf(fh)]}},fy={"Brand color #1":{_default:"#005d5d",_type:nn.String},"Brand color #2":{_default:"#004144",_type:nn.String},"Brand color #3":{_default:"#007d79",_type:nn.String},excludePatientIdentifierCodeTypes:{uuids:{_type:nn.Array,_description:"List of UUIDs of patient identifier types to exclude from rendering in the patient banner",_default:[],_elements:{_type:nn.UUID}}},implementationName:{_type:nn.String,_description:"A name of the place (or authority) where all possible locations a user can choose are located.",_default:"Clinic"},logo:{src:{_type:nn.String,_default:"",_description:"The path or URL to the logo shown on the login page and while the server is starting up. If set to an empty string, the default OpenMRS logo is used.",_validators:[of.isUrl]},alt:{_type:nn.String,_default:"Logo",_description:"The alternative text for the logo image, displayed when the image cannot be loaded or on hover."}},patientPhotoConceptUuid:{_type:nn.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:nn.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:[of.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:nn.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:nn.String}},diagnosisTags:fg};var fv=r(9536);let fb={"carbon.table.batch.cancel":"cancel","carbon.table.batch.items.selected":"batchActionsItemsSelected","carbon.table.batch.item.selected":"batchActionItemSelected","carbon.table.batch.selectAll":"selectAll"},fw=e=>(0,fd.jsx)(fv.TableBatchActions,{translateWithId:(e,t)=>{let r=fb[e];return r?iK(r,e,t):e},...e}),fE="-esm-cohort-builder__custom-overflow-menu-module__container___lY3iq",fx="-esm-cohort-builder__custom-overflow-menu-module__menu___dReHr",fD="-esm-cohort-builder__custom-overflow-menu-module__show___48R0e",f_="-esm-cohort-builder__custom-overflow-menu-module__overflowMenuButton___tsY8r",fS=(0,cu.createContext)(null);function fC(){let e=(0,cu.useContext)(fS);if(!e)throw Error("useCustomOverflowMenu must be used within a CustomOverflowMenu");return e}function fk({menuTitle:e,children:t}){let[r,n]=cc().useState(!1),o=dV(()=>n(!1),r),a="tablet"===dI(),i=(0,cu.useCallback)(()=>n(e=>!e),[]),s=(0,cu.useRef)(null),l=(0,cu.useRef)(null),u=(0,cu.useId)(),c=`custom-overflow-menu-trigger-${u}`,d=`custom-overflow-menu-${u}`,f=(0,cu.useCallback)(()=>{n(!1),s.current?.focus()},[]),p=(0,cu.useMemo)(()=>({closeMenu:f}),[f]),m=(0,cu.useCallback)(e=>{"Escape"===e.key&&r&&(e.stopPropagation(),f())},[f,r]),h=cu.Children.toArray(t);(0,cu.useEffect)(()=>{if(r&&l.current){let e=l.current.querySelector('[role="menuitem"]:not([disabled])');e?.focus()}},[r]);let g=(0,cu.useCallback)(({currentIndex:e,direction:t})=>{let r=l.current?.querySelectorAll('[role="menuitem"]:not([disabled])');if(!r?.length)return;let n=document.activeElement?.closest?.('[role="menuitem"]')??document.activeElement,o=Array.from(r).indexOf(n);if(-1===o)return void r[t>0?0:r.length-1]?.focus();let a=o+t,i=a<0?r.length-1:a>=r.length?0:a;r[i]?.focus()},[]),y=h.map((e,t)=>(0,cu.isValidElement)(e)?(0,cu.cloneElement)(e,{closeMenu:f,handleOverflowMenuItemFocus:g,index:t}):e);return(0,fd.jsxs)("div",{"data-overflow-menu":!0,className:fp()("cds--overflow-menu",fE),ref:o,children:[(0,fd.jsx)("button",{className:fp()("cds--btn","cds--btn--ghost","cds--overflow-menu__trigger",{"cds--overflow-menu--open":r},f_),"aria-controls":d,"aria-expanded":r,"aria-haspopup":"true",id:c,onClick:i,onKeyDown:m,ref:s,children:e}),(0,fd.jsxs)("div",{className:fp()("cds--overflow-menu-options","cds--overflow-menu--flip",fx,{[fD]:r}),"aria-labelledby":c,"data-floating-menu-direction":"bottom",id:d,onKeyDown:m,ref:l,role:"menu",tabIndex:-1,children:[(0,fd.jsx)("ul",{className:fp()("cds--overflow-menu-options__content",{"cds--overflow-menu-options--lg":a}),children:(0,fd.jsx)(fS.Provider,{value:p,children:y})}),(0,fd.jsx)("span",{})]})]})}function fP(e){let t=(0,cu.useContext)(fS);return(0,fd.jsx)(fv.OverflowMenuItem,{...e,closeMenu:t?.closeMenu})}var fO=r(8168);(er=eo||(eo={})).Pop="POP",er.Push="PUSH",er.Replace="REPLACE";var fR=function(e){return e},fT="beforeunload";function fN(e){e.preventDefault(),e.returnValue=""}function fj(){var e=[];return{get length(){return e.length},push:function(t){return e.push(t),function(){e=e.filter(function(e){return e!==t})}},call:function(t){e.forEach(function(e){return e&&e(t)})}}}function fA(e){var t={};if(e){var r=e.indexOf("#");r>=0&&(t.hash=e.substr(r),e=e.substr(0,r));var n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}let f$=(0,cu.createContext)(null),fI=(0,cu.createContext)(null);function fM(e,t){if(!e)throw Error(t)}function fL(){return null!=(0,cu.useContext)(fI)}function fF(e){let{basename:t="/",children:r=null,location:n,navigationType:o=eo.Pop,navigator:a,static:i=!1}=e;fL()&&fM(!1);let s=t.replace(/\/+$/,"").replace(/^\/*/,"/"),l=(0,cu.useMemo)(()=>({basename:s,navigator:a,static:i}),[s,a,i]);"string"==typeof n&&(n=fA(n));let{pathname:u="/",search:c="",hash:d="",state:f=null,key:p="default"}=n,m=(0,cu.useMemo)(()=>{let e=function(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=e.charAt(t.length);return r&&"/"!==r?null:e.slice(t.length)||"/"}(u,s);return null==e?null:{pathname:e,search:c,hash:d,state:f,key:p}},[s,u,c,d,f,p]);return null==m?null:(0,cu.createElement)(f$.Provider,{value:l},(0,cu.createElement)(fI.Provider,{children:r,value:{location:m,navigationType:o}}))}function fB(e){let{basename:t,children:r,window:n}=e,o=(0,cu.useRef)();null==o.current&&(o.current=function(e){void 0===e&&(e={});var t=e.window,r=void 0===t?document.defaultView:t,n=r.history;function o(){var e=r.location,t=e.pathname,o=e.search,a=e.hash,i=n.state||{};return[i.idx,fR({pathname:t,search:o,hash:a,state:i.usr||null,key:i.key||"default"})]}var a=null;r.addEventListener("popstate",function(){if(a)d.call(a),a=null;else{var e=eo.Pop,t=o(),r=t[0],n=t[1];if(d.length){if(null!=r){var i=l-r;i&&(a={action:e,location:n,retry:function(){y(-1*i)}},y(i))}}else g(e)}});var i=eo.Pop,s=o(),l=s[0],u=s[1],c=fj(),d=fj();function f(e){var t,r,n,o,a,i,s;return"string"==typeof e?e:(n=void 0===(r=(t=e).pathname)?"/":r,a=void 0===(o=t.search)?"":o,s=void 0===(i=t.hash)?"":i,a&&"?"!==a&&(n+="?"===a.charAt(0)?a:"?"+a),s&&"#"!==s&&(n+="#"===s.charAt(0)?s:"#"+s),n)}function p(e,t){return void 0===t&&(t=null),fR((0,fO.A)({pathname:u.pathname,hash:"",search:""},"string"==typeof e?fA(e):e,{state:t,key:Math.random().toString(36).substr(2,8)}))}function m(e,t){return[{usr:e.state,key:e.key,idx:t},f(e)]}function h(e,t,r){return!d.length||(d.call({action:e,location:t,retry:r}),!1)}function g(e){i=e;var t=o();l=t[0],u=t[1],c.call({action:i,location:u})}function y(e){n.go(e)}return null==l&&(l=0,n.replaceState((0,fO.A)({},n.state,{idx:l}),"")),{get action(){return i},get location(){return u},createHref:f,push:function e(t,o){var a=eo.Push,i=p(t,o);if(h(a,i,function(){e(t,o)})){var s=m(i,l+1),u=s[0],c=s[1];try{n.pushState(u,"",c)}catch(e){r.location.assign(c)}g(a)}},replace:function e(t,r){var o=eo.Replace,a=p(t,r);if(h(o,a,function(){e(t,r)})){var i=m(a,l),s=i[0],u=i[1];n.replaceState(s,"",u),g(o)}},go:y,back:function(){y(-1)},forward:function(){y(1)},listen:function(e){return c.push(e)},block:function(e){var t=d.push(e);return 1===d.length&&r.addEventListener(fT,fN),function(){t(),d.length||r.removeEventListener(fT,fN)}}}}({window:n}));let a=o.current,[i,s]=(0,cu.useState)({action:a.action,location:a.location});return(0,cu.useLayoutEffect)(()=>a.listen(s),[a]),(0,cu.createElement)(fF,{basename:t,children:r,location:i.location,navigationType:i.action,navigator:a})}let fU=["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-mobile-check","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-two-factor-authentication","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"],fV=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-activity",iconProps:e})})),fW=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-add",iconProps:e})})),fH=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-arrow-down",iconProps:e})})),fz=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-arrow-left",iconProps:e})})),fK=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-arrow-right",iconProps:e})})),fG=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-arrow-up",iconProps:e})})),fZ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-baby",iconProps:e})})),fY=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-calendar-heat-map",iconProps:e})})),fq=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-calendar",iconProps:e})})),fJ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-caret-down",iconProps:e})})),fX=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-caret-left",iconProps:e})})),fQ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-caret-right",iconProps:e})})),f0=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-caret-up",iconProps:e})})),f1=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chart-average",iconProps:e})})),f2=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chart-line",iconProps:e})})),f4=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-checkmark-filled",iconProps:e})})),f3=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-checkmark-outline",iconProps:e})})),f6=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chemistry",iconProps:e})})),f5=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chevron-down",iconProps:e})})),f9=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chevron-left",iconProps:e})})),f8=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chevron-right",iconProps:e})})),f7=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chevron-up",iconProps:e})})),pe=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-close",iconProps:e})})),pt=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-close-filled",iconProps:e})})),pr=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-close-outline",iconProps:e})})),pn=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-document",iconProps:e})})),po=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-document-attachment",iconProps:e})})),pa=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-download",iconProps:e})})),pi=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-drug-order",iconProps:e})})),ps=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-edit",iconProps:e})})),pl=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-event-schedule",iconProps:e})})),pu=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-events",iconProps:e})})),pc=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-gender-female",iconProps:e})})),pd=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-gender-male",iconProps:e})})),pf=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-gender-other",iconProps:e})})),pp=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-gender-unknown",iconProps:e})})),pm=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-generic-order-type",iconProps:e})})),ph=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-group",iconProps:e})})),pg=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-group-access",iconProps:e})})),py=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-hospital-bed",iconProps:e})})),pv=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-image-medical",iconProps:e})})),pb=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-information",iconProps:e})})),pw=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-information-filled",iconProps:e})})),pE=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-information-square",iconProps:e})})),px=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-inventory-management",iconProps:e})})),pD=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-lab-order",iconProps:e})})),p_=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-list-checked",iconProps:e})})),pS=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-location",iconProps:e})})),pC=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-material-order",iconProps:e})})),pk=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-maximize",iconProps:e})})),pP=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-medication",iconProps:e})})),pO=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-message-queue",iconProps:e})})),pR=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-microscope",iconProps:e})})),pT=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-mobile-check",iconProps:e})})),pN=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-money",iconProps:e})})),pj=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-mother",iconProps:e})})),pA=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-movement",iconProps:e})})),p$=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-overflow-menu--horizontal",iconProps:e})})),pI=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-overflow-menu--horizontal",iconProps:e})})),pM=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-password",iconProps:e})})),pL=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-pedestrian-family",iconProps:e})})),pF=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-pen",iconProps:e})})),pB=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-printer",iconProps:e})})),pU=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-procedure-order",iconProps:e})})),pV=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-programs",iconProps:e})})),pW=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-referral-order",iconProps:e})})),pH=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-renew",iconProps:e})})),pz=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-report",iconProps:e})})),pK=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-reset",iconProps:e})})),pG=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-save",iconProps:e})})),pZ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-search",iconProps:e})})),pY=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-settings",iconProps:e})})),pq=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-switcher",iconProps:e})})),pJ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-shopping-cart",iconProps:e})})),pX=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-shopping-cart--arrow-down",iconProps:e})})),pQ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-sticky-note-add",iconProps:e})})),p0=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-syringe",iconProps:e})})),p1=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-table-of-contents",iconProps:e})})),p2=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-table",iconProps:e})})),p4=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-time",iconProps:e})})),p3=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-tools",iconProps:e})})),p6=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-translate",iconProps:e})})),p5=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-trash-can",iconProps:e})})),p9=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-tree-view--alt",iconProps:e})})),p8=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-two-factor-authentication",iconProps:e})})),p7=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-user-avatar",iconProps:e})})),me=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-user-follow",iconProps:e})})),mt=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-user-xray",iconProps:e})})),mr=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-user",iconProps:e})})),mn=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-view-off",iconProps:e})})),mo=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-view",iconProps:e})})),ma=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-warning",iconProps:e})})),mi=ma,ms=po,ml=p_,mu=pv,mc=pX,md=(0,cu.memo)((0,cu.forwardRef)(function({icon:e,fallback:t,...r},n){let o=(0,cu.useRef)(e?document.getElementById(e):void 0);return(0,cu.useEffect)(()=>{let t=document.getElementById("omrs-svgs-container"),r=new MutationObserver(t=>{for(let r of t)"childList"===r.type&&(o.current=e?document.getElementById(e):void 0)});return t&&r.observe(t,{childList:!0}),()=>r.disconnect()},[e]),(0,fd.jsx)(c8,{value:o.current,fallback:t,children:(0,fd.jsx)(mf,{ref:n,icon:e,iconProps:r})})})),mf=(0,cu.memo)((0,cu.forwardRef)(function({icon:e,iconProps:t},r){let{className:n,fill:o,size:a}=Object.assign({},{fill:"currentColor",size:20},t);(a<=0||a>72)&&(console.error(`Invalid size '${a}' specified for ${e}. Defaulting to 20.`),a=20);let i=(0,cu.useRef)(null);return(0,cu.useImperativeHandle)(r,()=>i.current),(0,cu.useEffect)(()=>{i.current&&"currentColor"!==o&&i.current.style.setProperty("--omrs-icon-fill",o)},[]),(0,fd.jsx)("svg",{ref:i,className:fp()("omrs-icon","-esm-cohort-builder__icons-module__icon___sq7Qp",n),height:a,width:a,viewBox:"0 0 16 16",children:(0,fd.jsx)("use",{href:`#${e}`})})})),mp=({path:e,title:t,basePath:r,icon:n})=>{let{t:o}=(0,cV.useTranslation)(),a=(fL()||fM(!1),(0,cu.useContext)(fI).location),i=(0,cu.useMemo)(()=>{if(!e)return!1;let t=e.startsWith("/")?e.slice(1):e;if(t.startsWith("http"))return t===window.location.href;let r=t.split("/").map(e=>decodeURIComponent(e)),n=(a.pathname??"").split("/").slice(1).map(e=>decodeURIComponent(e));return n.some((e,t)=>r.every((e,r)=>n[t+r]===e))},[a.pathname,e]);return(0,fd.jsx)("div",{children:(0,fd.jsx)(cf,{className:fp()("cds--side-nav__link",{"active-left-nav-link":i}),to:`${r}/${encodeURIComponent(e)}`,children:(0,fd.jsxs)("span",{className:"-esm-cohort-builder__dashboard-module__menu___Lg1M+",children:[(0,fd.jsx)(md,{icon:n,className:"-esm-cohort-builder__dashboard-module__icon___Y2DxK",size:16}),(0,fd.jsx)("span",{children:o(t)})]})})},e)};function mm(e){return function({basePath:t}){return(0,fd.jsx)(fB,{children:(0,fd.jsx)(mp,{basePath:t,...e})})}}function mh(e){let t=(0,cu.useRef)(null);return(0,cu.useMemo)(()=>({get current(){return t.current},set current(value){t.current=value,"function"==typeof e?e(value):e&&(e.current=value)}}),[e])}function mg(...e){return(...t)=>{for(let r of e)"function"==typeof r&&r(...t)}}let my="u">typeof document?cc().useLayoutEffect:()=>{};function mv(e){let t=(0,cu.useRef)(null);return my(()=>{t.current=e},[e]),(0,cu.useCallback)((...e)=>{let r=t.current;return null==r?void 0:r(...e)},[])}let mb={prefix:String(Math.round(1e10*Math.random())),current:0},mw=cc().createContext(mb),mE=cc().createContext(!1),mx=("u">typeof window&&window.document&&window.document.createElement,new WeakMap),mD="function"==typeof cc().useId?function(e){let t=cc().useId(),[r]=(0,cu.useState)(mk()),n=r?"react-aria":`react-aria${mb.prefix}`;return e||`${n}-${t}`}:function(e){let t=(0,cu.useContext)(mw),r=function(e=!1){let t=(0,cu.useContext)(mw),r=(0,cu.useRef)(null);if(null===r.current&&!e){var n,o;let e=null==(o=cc().__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED)||null==(n=o.ReactCurrentOwner)?void 0:n.current;if(e){let r=mx.get(e);null==r?mx.set(e,{id:t.current,state:e.memoizedState}):e.memoizedState!==r.state&&(t.current=r.id,mx.delete(e))}r.current=++t.current}return r.current}(!!e),n=`react-aria${t.prefix}`;return e||`${n}-${r}`};function m_(){return!1}function mS(){return!0}function mC(e){return()=>{}}function mk(){return"function"==typeof cc().useSyncExternalStore?cc().useSyncExternalStore(mC,m_,mS):(0,cu.useContext)(mE)}let mP=!!("u">typeof window&&window.document&&window.document.createElement),mO=new Map;function mR(e){let[t,r]=(0,cu.useState)(e),n=(0,cu.useRef)(null),o=mD(t),a=(0,cu.useRef)(null);if(s&&s.register(a,o),mP){let e=mO.get(o);e&&!e.includes(n)?e.push(n):mO.set(o,[n])}return my(()=>()=>{s&&s.unregister(a),mO.delete(o)},[o]),(0,cu.useEffect)(()=>{let e=n.current;return e&&r(e),()=>{e&&(n.current=null)}}),o}function mT(e=[]){let t=mR(),[r,n]=function(e){let[t,r]=(0,cu.useState)(e),n=(0,cu.useRef)(null),o=mv(()=>{if(!n.current)return;let e=n.current.next();if(e.done){n.current=null;return}t===e.value?o():r(e.value)});my(()=>{n.current&&o()});let a=mv(e=>{n.current=e(t),o()});return[t,a]}(t),o=(0,cu.useCallback)(()=>{n(function*(){yield t,yield document.getElementById(t)?t:void 0})},[t,n]);return my(o,[t,o,...e]),r}"u">typeof FinalizationRegistry&&(s=new FinalizationRegistry(e=>{mO.delete(e)}));let mN=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 a=t.length;for(r=0;r<a;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 mj(...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]=mg(r,o):("className"===e||"UNSAFE_className"===e)&&"string"==typeof r&&"string"==typeof o?t[e]=mN(r,o):"id"===e&&r&&o?t.id=function(e,t){if(e===t)return e;let r=mO.get(e);if(r)return r.forEach(e=>e.current=t),t;let n=mO.get(t);return n?(n.forEach(t=>t.current=e),e):t}(r,o):t[e]=void 0!==o?o:r}}return t}let mA=Symbol("default");function m$({values:e,children:t}){for(let[r,n]of e)t=cc().createElement(r.Provider,{value:n},t);return t}function mI(e){let{className:t,style:r,children:n,defaultClassName:o,defaultChildren:a,defaultStyle:i,values:s}=e;return(0,cu.useMemo)(()=>{let e,l,u;return e="function"==typeof t?t({...s,defaultClassName:o}):t,l="function"==typeof r?r({...s,defaultStyle:i||{}}):r,u="function"==typeof n?n({...s,defaultChildren:a}):null==n?a:n,{className:null!=e?e:o,style:l||i?{...i,...l}:void 0,children:null!=u?u:a,"data-rac":""}},[t,r,n,o,a,i,s])}function mM(e,t){let r=(0,cu.useContext)(e);if(null===t)return null;if(r&&"object"==typeof r&&"slots"in r&&r.slots){let e=t||mA;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 mL(e,t,r){let{ref:n,...o}=mM(r,e.slot)||{},a=mh((0,cu.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])),i=mj(o,e);return"style"in o&&o.style&&"style"in e&&e.style&&("function"==typeof o.style||"function"==typeof e.style?i.style=t=>{let r="function"==typeof o.style?o.style(t):o.style,n={...t.defaultStyle,...r},a="function"==typeof e.style?e.style({...t,defaultStyle:n}):e.style;return{...n,...a}}:i.style={...o.style,...e.style}),[i,a]}function mF(e=!0){let[t,r]=(0,cu.useState)(e),n=(0,cu.useRef)(!1),o=(0,cu.useCallback)(e=>{n.current=!0,r(!!e)},[]);return my(()=>{n.current||r(!1)},[]),[o,t]}function mB(e){let t=/^(data-.*)$/,r={};for(let n in e)t.test(n)||(r[n]=e[n]);return r}let mU=(0,cu.createContext)(null),mV=null;function mW(e,t="assertive",r=7e3){mV?mV.announce(e,t,r):(mV=new mH,("boolean"==typeof IS_REACT_ACT_ENVIRONMENT?IS_REACT_ACT_ENVIRONMENT:"u">typeof jest)?mV.announce(e,t,r):setTimeout(()=>{(null==mV?void 0:mV.isAttached())&&(null==mV||mV.announce(e,t,r))},100))}class mH{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 a=document.createElement("div");"object"==typeof e?(a.setAttribute("role","img"),a.setAttribute("aria-labelledby",e["aria-labelledby"])):a.textContent=e,"assertive"===t?null==(n=this.assertiveLog)||n.appendChild(a):null==(o=this.politeLog)||o.appendChild(a),""!==e&&setTimeout(()=>{a.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 mz=new Set(["id"]),mK=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),mG=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),mZ=/^(data-.*)$/;function mY(e,t={}){let{labelable:r,isLink:n,propNames:o}=t,a={};for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(mz.has(t)||r&&mK.has(t)||n&&mG.has(t)||(null==o?void 0:o.has(t))||mZ.test(t))&&(a[t]=e[t]);return a}let mq=["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"])'],mJ=mq.join(":not([hidden]),")+",[tabindex]:not([disabled]):not([hidden])";mq.push('[tabindex]:not([tabindex="-1"]):not([disabled])');let mX=mq.join(':not([hidden]):not([tabindex="-1"]),');function mQ(e){return e.matches(mJ)}function m0(e){return e.matches(mX)}let m1=e=>{var t;return null!=(t=null==e?void 0:e.ownerDocument)?t:document},m2=e=>e&&"window"in e&&e.window===e?e:m1(e).defaultView||window;function m4(e){if(function(){if(null==m3){m3=!1;try{document.createElement("div").focus({get preventScroll(){return m3=!0,!0}})}catch{}}return m3}())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 m3=null;function m6(e){return e.nativeEvent=e,e.isDefaultPrevented=()=>e.defaultPrevented,e.isPropagationStopped=()=>e.cancelBubble,e.persist=()=>{},e}function m5(e,t){Object.defineProperty(e,"target",{value:t}),Object.defineProperty(e,"currentTarget",{value:t})}function m9(e){let t=(0,cu.useRef)({isFocused:!1,observer:null});my(()=>{let e=t.current;return()=>{e.observer&&(e.observer.disconnect(),e.observer=null)}},[]);let r=mv(t=>{null==e||e(t)});return(0,cu.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(m6(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 m8=!1;function m7(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 he(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 ht(e){let t=null;return()=>(null==t&&(t=e()),t)}let hr=ht(function(){return he(/^Mac/i)}),hn=ht(function(){return he(/^iPhone/i)}),ho=ht(function(){return he(/^iPad/i)||hr()&&navigator.maxTouchPoints>1}),ha=ht(function(){return hn()||ho()});ht(function(){return hr()||ha()});let hi=ht(function(){return m7(/AppleWebKit/i)&&!hs()}),hs=ht(function(){return m7(/Chrome/i)}),hl=ht(function(){return m7(/Android/i)}),hu=ht(function(){return m7(/Firefox/i)}),hc=new Map,hd=new Set;function hf(){if("u"<typeof window)return;function e(e){return"propertyName"in e}let t=r=>{if(!e(r)||!r.target)return;let n=hc.get(r.target);if(n&&(n.delete(r.propertyName),0===n.size&&(r.target.removeEventListener("transitioncancel",t),hc.delete(r.target)),0===hc.size)){for(let e of hd)e();hd.clear()}};document.body.addEventListener("transitionrun",r=>{if(!e(r)||!r.target)return;let n=hc.get(r.target);n||(n=new Set,hc.set(r.target,n),r.target.addEventListener("transitioncancel",t,{once:!0})),n.add(r.propertyName)}),document.body.addEventListener("transitionend",t)}function hp(e){requestAnimationFrame(()=>{0===hc.size?e():hd.add(e)})}"u">typeof document&&("loading"!==document.readyState?hf():document.addEventListener("DOMContentLoaded",hf));let hm="default",hh="",hg=new WeakMap;function hy(e){if(ha())"disabled"===hm&&(hm="restoring",setTimeout(()=>{hp(()=>{if("restoring"===hm){let t=m1(e);"none"===t.documentElement.style.webkitUserSelect&&(t.documentElement.style.webkitUserSelect=hh||""),hh="",hm="default"}})},300));else if((e instanceof HTMLElement||e instanceof SVGElement)&&e&&hg.has(e)){let t=hg.get(e),r="userSelect"in e.style?"userSelect":"webkitUserSelect";"none"===e.style[r]&&(e.style[r]=t),""===e.getAttribute("style")&&e.removeAttribute("style"),hg.delete(e)}}let hv=cc().createContext({register:()=>{}});function hb(e,t,r){if(!t.has(e))throw TypeError("attempted to "+r+" private field on non-instance");return t.get(e)}function hw(e,t,r){if(t.has(e))throw TypeError("Cannot initialize the same private elements twice on an object");t.set(e,r)}function hE(e,t,r){var n=hb(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 hx(e,t){my(()=>{if(e&&e.ref&&t)return e.ref.current=t.current,()=>{e.ref&&(e.ref.current=null)}})}function hD(){let e=(0,cu.useRef)(new Map),t=(0,cu.useCallback)((t,r,n,o)=>{let a=(null==o?void 0:o.once)?(...t)=>{e.current.delete(n),n(...t)}:n;e.current.set(n,{type:r,eventTarget:t,fn:a,options:o}),t.addEventListener(r,a,o)},[]),r=(0,cu.useCallback)((t,r,n,o)=>{var a;let i=(null==(a=e.current.get(n))?void 0:a.fn)||n;t.removeEventListener(r,i,o),e.current.delete(n)},[]),n=(0,cu.useCallback)(()=>{e.current.forEach((e,t)=>{r(e.eventTarget,e.type,t,e.options)})},[r]);return(0,cu.useEffect)(()=>n,[n]),{addGlobalListener:t,removeGlobalListener:r,removeAllGlobalListeners:n}}hv.displayName="PressResponderContext";function h_(e,t){return!!t&&!!e&&e.contains(t)}function hS(e){return e.target}function hC(e,t,r=!0){var n,o;let{metaKey:a,ctrlKey:i,altKey:s,shiftKey:l}=t;hu()&&(null==(o=window.event)||null==(n=o.type)?void 0:n.startsWith("key"))&&"_blank"===e.target&&(hr()?a=!0:i=!0);let u=hi()&&hr()&&!ho()&&1?new KeyboardEvent("keydown",{keyIdentifier:"Enter",metaKey:a,ctrlKey:i,altKey:s,shiftKey:l}):new MouseEvent("click",{metaKey:a,ctrlKey:i,altKey:s,shiftKey:l,bubbles:!0,cancelable:!0});hC.isOpening=r,m4(e),e.dispatchEvent(u),hC.isOpening=!1}function hk(e){return 0===e.mozInputSource&&!!e.isTrusted||(hl()&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType)}hC.isOpening=!1;var hP=r(1779),hO=r.n(hP),hR=new WeakMap;class hT{continuePropagation(){hE(this,hR,!1)}get shouldStopPropagation(){var e;return e=hb(this,hR,"get"),e.get?e.get.call(this):e.value}constructor(e,t,r,n){var o;hw(this,hR,{writable:!0,value:void 0}),hE(this,hR,!0);let a=null!=(o=null==n?void 0:n.target)?o:r.currentTarget;const i=null==a?void 0:a.getBoundingClientRect();let s,l=0,u,c=null;null!=r.clientX&&null!=r.clientY&&(u=r.clientX,c=r.clientY),i&&(null!=u&&null!=c?(s=u-i.left,l=c-i.top):(s=i.width/2,l=i.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=s,this.y=l}}let hN=Symbol("linkClicked");function hj(e){let{onPress:t,onPressChange:r,onPressStart:n,onPressEnd:o,onPressUp:a,onClick:i,isDisabled:s,isPressed:l,preventFocusOnPress:u,shouldCancelOnPointerExit:c,allowTextSelectionOnPress:d,ref:f,...p}=function(e){let t=(0,cu.useContext)(hv);if(t){let{register:r,...n}=t;e=mj(n,e),r()}return hx(t,e.ref),e}(e),[m,h]=(0,cu.useState)(!1),g=(0,cu.useRef)({isPressed:!1,ignoreEmulatedMouseEvents:!1,didFirePressStart:!1,isTriggeringEvent:!1,activePointerId:null,target:null,isOverTarget:!1,pointerType:null,disposables:[]}),{addGlobalListener:y,removeAllGlobalListeners:v}=hD(),b=mv((e,t)=>{let o=g.current;if(s||o.didFirePressStart)return!1;let a=!0;if(o.isTriggeringEvent=!0,n){let r=new hT("pressstart",t,e);n(r),a=r.shouldStopPropagation}return r&&r(!0),o.isTriggeringEvent=!1,o.didFirePressStart=!0,h(!0),a}),w=mv((e,n,a=!0)=>{let i=g.current;if(!i.didFirePressStart)return!1;i.didFirePressStart=!1,i.isTriggeringEvent=!0;let l=!0;if(o){let t=new hT("pressend",n,e);o(t),l=t.shouldStopPropagation}if(r&&r(!1),h(!1),t&&a&&!s){let r=new hT("press",n,e);t(r),l&&(l=r.shouldStopPropagation)}return i.isTriggeringEvent=!1,l}),E=mv((e,t)=>{let r=g.current;if(s)return!1;if(a){r.isTriggeringEvent=!0;let n=new hT("pressup",t,e);return a(n),r.isTriggeringEvent=!1,n.shouldStopPropagation}return!0}),x=mv(e=>{let t=g.current;if(t.isPressed&&t.target){for(let r of(t.didFirePressStart&&null!=t.pointerType&&w(hI(t.target,e),t.pointerType,!1),t.isPressed=!1,t.isOverTarget=!1,t.activePointerId=null,t.pointerType=null,v(),d||hy(t.target),t.disposables))r();t.disposables=[]}}),D=mv(e=>{c&&x(e)}),_=mv(e=>{null==i||i(e)}),S=mv((e,t)=>{if(i){let r=new MouseEvent("click",e);m5(r,t),i(m6(r))}}),C=(0,cu.useMemo)(()=>{let e=g.current,t={onKeyDown(t){if(h$(t.nativeEvent,t.currentTarget)&&h_(t.currentTarget,hS(t.nativeEvent))){var n;hM(hS(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=b(t,"keyboard");let n=t.currentTarget;y(m1(t.currentTarget),"keyup",mg(t=>{h$(t,n)&&!t.repeat&&h_(n,hS(t))&&e.target&&E(hI(e.target,t),"keyboard")},r),!0)}o&&t.stopPropagation(),t.metaKey&&hr()&&(null==(n=e.metaKeyEvents)||n.set(t.key,t.nativeEvent))}else"Meta"===t.key&&(e.metaKeyEvents=new Map)},onClick(t){if((!t||h_(t.currentTarget,hS(t.nativeEvent)))&&t&&0===t.button&&!e.isTriggeringEvent&&!hC.isOpening){let r=!0;if(s&&t.preventDefault(),!e.ignoreEmulatedMouseEvents&&!e.isPressed&&("virtual"===e.pointerType||hk(t.nativeEvent))){let e=b(t,"virtual"),n=E(t,"virtual"),o=w(t,"virtual");_(t),r=e&&n&&o}else if(e.isPressed&&"keyboard"!==e.pointerType){let n=e.pointerType||t.nativeEvent.pointerType||"virtual";r=w(hI(t.currentTarget,t),n,!0),e.isOverTarget=!1,_(t),x(t)}e.ignoreEmulatedMouseEvents=!1,r&&t.stopPropagation()}}},r=t=>{var r,n,o;if(e.isPressed&&e.target&&h$(t,e.target)){hM(hS(t),t.key)&&t.preventDefault();let r=hS(t),o=h_(e.target,hS(t));w(hI(e.target,t),"keyboard",o),o&&S(t,e.target),v(),"Enter"!==t.key&&hA(e.target)&&h_(e.target,r)&&!t[hN]&&(t[hN]=!0,hC(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||!h_(t.currentTarget,hS(t.nativeEvent)))return;if(o=t.nativeEvent,!hl()&&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 a=!0;if(!e.isPressed){e.isPressed=!0,e.isOverTarget=!0,e.activePointerId=t.pointerId,e.target=t.currentTarget,d||function(e){if(ha()){if("default"===hm){let t=m1(e);hh=t.documentElement.style.webkitUserSelect,t.documentElement.style.webkitUserSelect="none"}hm="disabled"}else if(e instanceof HTMLElement||e instanceof SVGElement){let t="userSelect"in e.style?"userSelect":"webkitUserSelect";hg.set(e,e.style[t]),e.style[t]="none"}}(e.target),a=b(t,e.pointerType);let o=hS(t.nativeEvent);"releasePointerCapture"in o&&o.releasePointerCapture(t.pointerId),y(m1(t.currentTarget),"pointerup",r,!1),y(m1(t.currentTarget),"pointercancel",n,!1)}a&&t.stopPropagation()},t.onMouseDown=t=>{if(h_(t.currentTarget,hS(t.nativeEvent))&&0===t.button){if(u){let r=function(e){for(;e&&!mQ(e);)e=e.parentElement;let t=m2(e),r=t.document.activeElement;if(!r||r===e)return;m8=!0;let n=!1,o=e=>{(e.target===r||n)&&e.stopImmediatePropagation()},a=t=>{(t.target===r||n)&&(t.stopImmediatePropagation(),e||n||(n=!0,m4(r),l()))},i=t=>{(t.target===e||n)&&t.stopImmediatePropagation()},s=t=>{(t.target===e||n)&&(t.stopImmediatePropagation(),n||(n=!0,m4(r),l()))};t.addEventListener("blur",o,!0),t.addEventListener("focusout",a,!0),t.addEventListener("focusin",s,!0),t.addEventListener("focus",i,!0);let l=()=>{cancelAnimationFrame(u),t.removeEventListener("blur",o,!0),t.removeEventListener("focusout",a,!0),t.removeEventListener("focusin",s,!0),t.removeEventListener("focus",i,!0),m8=!1,n=!1},u=requestAnimationFrame(l);return l}(t.target);r&&e.disposables.push(r)}t.stopPropagation()}},t.onPointerUp=t=>{h_(t.currentTarget,hS(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,b(hI(e.target,t),e.pointerType))},t.onPointerLeave=t=>{t.pointerId===e.activePointerId&&e.target&&e.isOverTarget&&null!=e.pointerType&&(e.isOverTarget=!1,w(hI(e.target,t),e.pointerType,!1),D(t))};let r=t=>{if(t.pointerId===e.activePointerId&&e.isPressed&&0===t.button&&e.target){if(h_(e.target,hS(t))&&null!=e.pointerType){let r=!1,n=setTimeout(()=>{e.isPressed&&e.target instanceof HTMLElement&&(r?x(t):(m4(e.target),e.target.click()))},80);y(t.currentTarget,"click",()=>r=!0,!0),e.disposables.push(()=>clearTimeout(n))}else x(t);e.isOverTarget=!1}},n=e=>{x(e)};t.onDragStart=e=>{h_(e.currentTarget,hS(e.nativeEvent))&&x(e)}}return t},[y,s,u,v,d,x,D,w,b,E,_,S]);return(0,cu.useEffect)(()=>{let e=null==f?void 0:f.current;e&&e instanceof m2(e).Element&&"auto"===m2(e).getComputedStyle(e).touchAction&&(e.style.touchAction="pan-x pan-y pinch-zoom")},[f]),(0,cu.useEffect)(()=>{let e=g.current;return()=>{var t;for(let r of(d||hy(null!=(t=e.target)?t:void 0),e.disposables))r();e.disposables=[]}},[d]),{isPressed:l||m,pressProps:mj(p,C)}}function hA(e){return"A"===e.tagName&&e.hasAttribute("href")}function h$(e,t){let{key:r,code:n}=e,o=t.getAttribute("role");return("Enter"===r||" "===r||"Spacebar"===r||"Space"===n)&&!(t instanceof m2(t).HTMLInputElement&&!hF(t,r)||t instanceof m2(t).HTMLTextAreaElement||t.isContentEditable)&&!(("link"===o||!o&&hA(t))&&"Enter"!==r)}function hI(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 hM(e,t){return e instanceof HTMLInputElement?!hF(e,t):!(e instanceof HTMLInputElement)&&(e instanceof HTMLButtonElement?"submit"!==e.type&&"reset"!==e.type:!hA(e))}let hL=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function hF(e,t){return"checkbox"===e.type||"radio"===e.type?" "===t:hL.has(e.type)}let hB=null,hU=new Set,hV=new Map,hW=!1,hH=!1,hz={Tab:!0,Escape:!0};function hK(e,t){for(let r of hU)r(e,t)}function hG(e){hW=!0,e.metaKey||!hr()&&e.altKey||e.ctrlKey||"Control"===e.key||"Shift"===e.key||"Meta"===e.key||(hB="keyboard",hK("keyboard",e))}function hZ(e){hB="pointer",("mousedown"===e.type||"pointerdown"===e.type)&&(hW=!0,hK("pointer",e))}function hY(e){hk(e)&&(hW=!0,hB="virtual")}function hq(e){e.target!==window&&e.target!==document&&!m8&&e.isTrusted&&(hW||hH||(hB="virtual",hK("virtual",e)),hW=!1,hH=!1)}function hJ(){m8||(hW=!1,hH=!0)}function hX(e){if("u"<typeof window||hV.get(m2(e)))return;let t=m2(e),r=m1(e),n=t.HTMLElement.prototype.focus;t.HTMLElement.prototype.focus=function(){hW=!0,n.apply(this,arguments)},r.addEventListener("keydown",hG,!0),r.addEventListener("keyup",hG,!0),r.addEventListener("click",hY,!0),t.addEventListener("focus",hq,!0),t.addEventListener("blur",hJ,!1),"u">typeof PointerEvent&&(r.addEventListener("pointerdown",hZ,!0),r.addEventListener("pointermove",hZ,!0),r.addEventListener("pointerup",hZ,!0)),t.addEventListener("beforeunload",()=>{hQ(e)},{once:!0}),hV.set(t,{focus:n})}let hQ=(e,t)=>{let r=m2(e),n=m1(e);t&&n.removeEventListener("DOMContentLoaded",t),hV.has(r)&&(r.HTMLElement.prototype.focus=hV.get(r).focus,n.removeEventListener("keydown",hG,!0),n.removeEventListener("keyup",hG,!0),n.removeEventListener("click",hY,!0),r.removeEventListener("focus",hq,!0),r.removeEventListener("blur",hJ,!1),"u">typeof PointerEvent&&(n.removeEventListener("pointerdown",hZ,!0),n.removeEventListener("pointermove",hZ,!0),n.removeEventListener("pointerup",hZ,!0)),hV.delete(r))};function h0(){return"pointer"!==hB}"u">typeof document&&("loading"!==(f=m1(void 0)).readyState?hX(void 0):f.addEventListener("DOMContentLoaded",()=>{hX(void 0)}));let h1=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function h2(e){let t=m1(e),r=((e=document)=>e.activeElement)(t);"virtual"===hB?hp(()=>{((e=document)=>e.activeElement)(t)===r&&e.isConnected&&m4(e)}):m4(e)}function h4(e){let{isDisabled:t,onFocus:r,onBlur:n,onFocusChange:o}=e,a=(0,cu.useCallback)(e=>{if(e.target===e.currentTarget)return n&&n(e),o&&o(!1),!0},[n,o]),i=m9(a),s=(0,cu.useCallback)(e=>{let t=m1(e.target),n=t?((e=document)=>e.activeElement)(t):((e=document)=>e.activeElement)();e.target===e.currentTarget&&n===hS(e.nativeEvent)&&(r&&r(e),o&&o(!0),i(e))},[o,r,i]);return{focusProps:{onFocus:!t&&(r||o||n)?s:void 0,onBlur:!t&&(n||o)?a:void 0}}}function h3(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 h6=cc().createContext(null);function h5(e,t){let{focusProps:r}=h4(e),{keyboardProps:n}={keyboardProps:e.isDisabled?{}:{onKeyDown:h3(e.onKeyDown),onKeyUp:h3(e.onKeyUp)}},o=mj(r,n),a=function(e){let t=(0,cu.useContext)(h6)||{};hx(t,e);let{ref:r,...n}=t;return n}(t),i=e.isDisabled?{}:a,s=(0,cu.useRef)(e.autoFocus);(0,cu.useEffect)(()=>{s.current&&t.current&&h2(t.current),s.current=!1},[t]);let l=e.excludeFromTabOrder?-1:0;return e.isDisabled&&(l=void 0),{focusableProps:mj({...o,tabIndex:l},i)}}function h9(e){let{isDisabled:t,onBlurWithin:r,onFocusWithin:n,onFocusWithinChange:o}=e,a=(0,cu.useRef)({isFocusWithin:!1}),{addGlobalListener:i,removeAllGlobalListeners:s}=hD(),l=(0,cu.useCallback)(e=>{e.currentTarget.contains(e.target)&&a.current.isFocusWithin&&!e.currentTarget.contains(e.relatedTarget)&&(a.current.isFocusWithin=!1,s(),r&&r(e),o&&o(!1))},[r,o,a,s]),u=m9(l),c=(0,cu.useCallback)(e=>{if(!e.currentTarget.contains(e.target))return;let t=m1(e.target),r=((e=document)=>e.activeElement)(t);if(!a.current.isFocusWithin&&r===hS(e.nativeEvent)){n&&n(e),o&&o(!0),a.current.isFocusWithin=!0,u(e);let r=e.currentTarget;i(t,"focus",e=>{if(a.current.isFocusWithin&&!h_(r,e.target)){let n=new t.defaultView.FocusEvent("blur",{relatedTarget:e.target});m5(n,r),l(m6(n))}},{capture:!0})}},[n,o,u,i,l]);return t?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:c,onBlur:l}}}function h8(e={}){var t;let{autoFocus:r=!1,isTextInput:n,within:o}=e,a=(0,cu.useRef)({isFocused:!1,isFocusVisible:r||h0()}),[i,s]=(0,cu.useState)(!1),[l,u]=(0,cu.useState)(()=>a.current.isFocused&&a.current.isFocusVisible),c=(0,cu.useCallback)(()=>u(a.current.isFocused&&a.current.isFocusVisible),[]),d=(0,cu.useCallback)(e=>{a.current.isFocused=e,s(e),c()},[c]);t={isTextInput:n},hX(),(0,cu.useEffect)(()=>{let e=(e,r)=>{var n;let o,i,s,l,u;n=!!(null==t?void 0:t.isTextInput),o=m1(null==r?void 0:r.target),i="u">typeof window?m2(null==r?void 0:r.target).HTMLInputElement:HTMLInputElement,s="u">typeof window?m2(null==r?void 0:r.target).HTMLTextAreaElement:HTMLTextAreaElement,l="u">typeof window?m2(null==r?void 0:r.target).HTMLElement:HTMLElement,u="u">typeof window?m2(null==r?void 0:r.target).KeyboardEvent:KeyboardEvent,(n=n||o.activeElement instanceof i&&!h1.has(o.activeElement.type)||o.activeElement instanceof s||o.activeElement instanceof l&&o.activeElement.isContentEditable)&&"keyboard"===e&&r instanceof u&&!hz[r.key]||(e=>{a.current.isFocusVisible=e,c()})(h0())};return hU.add(e),()=>{hU.delete(e)}},[]);let{focusProps:f}=h4({isDisabled:o,onFocusChange:d}),{focusWithinProps:p}=h9({isDisabled:!o,onFocusWithinChange:d});return{isFocused:i,isFocusVisible:l,focusProps:o?p:f}}cc().forwardRef(function(e,t){let{children:r,...n}=e,o=mh(t),a={...n,ref:o};return cc().createElement(h6.Provider,{value:a},r)});let h7=!1,ge=0;function gt(e){"touch"===e.pointerType&&(h7=!0,setTimeout(()=>{h7=!1},50))}function gr(){if("u">typeof document)return"u">typeof PointerEvent&&document.addEventListener("pointerup",gt),ge++,()=>{!(--ge>0)&&"u">typeof PointerEvent&&document.removeEventListener("pointerup",gt)}}function gn(e){let{onHoverStart:t,onHoverChange:r,onHoverEnd:n,isDisabled:o}=e,[a,i]=(0,cu.useState)(!1),s=(0,cu.useRef)({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;(0,cu.useEffect)(gr,[]);let{addGlobalListener:l,removeAllGlobalListeners:u}=hD(),{hoverProps:c,triggerHoverEnd:d}=(0,cu.useMemo)(()=>{let e=(e,t)=>{let o=s.target;s.pointerType="",s.target=null,"touch"!==t&&s.isHovered&&o&&(s.isHovered=!1,u(),n&&n({type:"hoverend",target:o,pointerType:t}),r&&r(!1),i(!1))},a={};return"u">typeof PointerEvent&&(a.onPointerEnter=n=>{h7&&"mouse"===n.pointerType||((n,a)=>{if(s.pointerType=a,o||"touch"===a||s.isHovered||!n.currentTarget.contains(n.target))return;s.isHovered=!0;let u=n.currentTarget;s.target=u,l(m1(n.target),"pointerover",t=>{s.isHovered&&s.target&&!h_(s.target,t.target)&&e(t,t.pointerType)},{capture:!0}),t&&t({type:"hoverstart",target:u,pointerType:a}),r&&r(!0),i(!0)})(n,n.pointerType)},a.onPointerLeave=t=>{!o&&t.currentTarget.contains(t.target)&&e(t,t.pointerType)}),{hoverProps:a,triggerHoverEnd:e}},[t,r,n,o,s,l,u]);return(0,cu.useEffect)(()=>{o&&d({currentTarget:s.target},s.pointerType)},[o]),{hoverProps:c,isHovered:a}}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 go=(0,cu.createContext)(!1);function ga(e){let t=(t,r)=>(0,cu.useContext)(go)?null:e(t,r);return t.displayName=e.displayName||e.name,(0,cu.forwardRef)(t)}let gi=new Set(["form","formAction","formEncType","formMethod","formNoValidate","formTarget","name","value"]),gs=(0,cu.createContext)({}),gl=ga(function(e,t){var r;[e,t]=mL(e,t,gs);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:a,isPressed:i}=function(e,t){let r,{elementType:n="button",isDisabled:o,onPress:a,onPressStart:i,onPressEnd:s,onPressUp:l,onPressChange:u,preventFocusOnPress:c,allowFocusWhenDisabled:d,onClick:f,href:p,target:m,rel:h,type:g="button"}=e;r="button"===n?{type:g,disabled:o}:{role:"button",href:"a"!==n||o?void 0:p,target:"a"===n?m:void 0,type:"input"===n?g:void 0,disabled:"input"===n?o:void 0,"aria-disabled":o&&"input"!==n?o:void 0,rel:"a"===n?h:void 0};let{pressProps:y,isPressed:v}=hj({onPressStart:i,onPressEnd:s,onPressChange:u,onPress:a,onPressUp:l,onClick:f,isDisabled:o,preventFocusOnPress:c,ref:t}),{focusableProps:b}=h5(e,t);d&&(b.tabIndex=o?-1:b.tabIndex);let w=mj(b,y,mY(e,{labelable:!0}));return{isPressed:v,buttonProps:mj(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:s,isFocused:l,isFocusVisible:u}=h8(e),{hoverProps:c,isHovered:d}=gn({...e,isDisabled:e.isDisabled||o}),f={isHovered:d,isPressed:(n.isPressed||i)&&!o,isFocused:l,isFocusVisible:u,isDisabled:e.isDisabled||!1,isPending:null!=o&&o},p=mI({...e,values:f,defaultClassName:"react-aria-Button"}),m=mR(a.id),h=mR(),g=a["aria-labelledby"];o&&(g?g=`${g} ${h}`:a["aria-label"]&&(g=`${m} ${h}`));let y=(0,cu.useRef)(o);return(0,cu.useEffect)(()=>{let e={"aria-labelledby":g||m};!y.current&&l&&o?mW(e,"assertive"):y.current&&l&&!o&&mW(e,"assertive"),y.current=o},[o,l,g,m]),cc().createElement("button",{...mY(e,{propNames:gi}),...mj(a,s,c),...p,type:"submit"===a.type&&o?"button":a.type,id:m,ref:t,"aria-labelledby":g,slot:e.slot||void 0,"aria-disabled":o?"true":a["aria-disabled"],"data-disabled":e.isDisabled||void 0,"data-pressed":f.isPressed||void 0,"data-hovered":d||void 0,"data-focused":l||void 0,"data-pending":o||void 0,"data-focus-visible":u||void 0},cc().createElement(mU.Provider,{value:{id:h}},p.children))});(0,cu.createContext)(null),(0,cu.createContext)(null),(0,cu.createContext)(null),(0,cu.createContext)(null),(0,cu.createContext)(null);let gu=(0,cu.createContext)({}),gc=(0,cu.createContext)({}),gd=(0,cu.forwardRef)(function(e,t){[e,t]=mL(e,t,gc);let{elementType:r="span",...n}=e;return cc().createElement(r,{className:"react-aria-Text",...n,ref:t})}),gf=new Set(["Arab","Syrc","Samr","Mand","Thaa","Mend","Nkoo","Adlm","Rohg","Hebr"]),gp=new Set(["ae","ar","arc","bcc","bqi","ckb","dv","fa","glk","he","ku","mzn","nqo","pnb","ps","sd","ug","ur","yi"]);function gm(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 gf.has(t.script)}let t=e.split("-")[0];return gp.has(t)}let gh=Symbol.for("react-aria.i18n.locale");function gg(){let e="u">typeof window&&window[gh]||"u">typeof navigator&&(navigator.language||navigator.userLanguage)||"en-US";try{Intl.DateTimeFormat.supportedLocalesOf([e])}catch{e="en-US"}return{locale:e,direction:gm(e)?"rtl":"ltr"}}let gy=gg(),gv=new Set;function gb(){for(let e of(gy=gg(),gv))e(gy)}function gw(){let e=mk(),[t,r]=(0,cu.useState)(gy);return((0,cu.useEffect)(()=>(0===gv.size&&window.addEventListener("languagechange",gb),gv.add(r),()=>{gv.delete(r),0===gv.size&&window.removeEventListener("languagechange",gb)}),[]),e)?{locale:"en-US",direction:"ltr"}:t}let gE=cc().createContext(null);function gx(e){let{locale:t,children:r}=e,n=gw(),o=cc().useMemo(()=>t?{locale:t,direction:gm(t)?"rtl":"ltr"}:n,[n,t]);return cc().createElement(gE.Provider,{value:o},r)}function gD(){let e=gw();return(0,cu.useContext)(gE)||e}var g_={};function gS(e,t){return e-t*Math.floor(e/t)}function gC(e,t,r,n){let o=(t=gP(e,t))-1,a=-2;return r<=2?a=0:gk(t)&&(a=-1),1721425+365*o+Math.floor(o/4)-Math.floor(o/100)+Math.floor(o/400)+Math.floor((367*r-362)/12+a+n)}function gk(e){return e%4==0&&(e%100!=0||e%400==0)}function gP(e,t){return"BC"===e?1-t:t}function gO(e){let t="AD";return e<=0&&(t="BC",e=1-e),[t,e]}g_={"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 gR={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 gT{fromJulianDay(e){let t=e-1721426,r=Math.floor(t/146097),n=gS(t,146097),o=Math.floor(n/36524),a=gS(n,36524),i=Math.floor(a/1461),s=Math.floor(gS(a,1461)/365),[l,u]=gO(400*r+100*o+4*i+s+ +(4!==o&&4!==s)),c=e-gC(l,u,1,1),d=2;e<gC(l,u,3,1)?d=0:gk(u)&&(d=1);let f=Math.floor(((c+d)*12+373)/367),p=e-gC(l,u,f,1)+1;return new gQ(l,u,f,p)}toJulianDay(e){return gC(e.era,e.year,e.month,e.day)}getDaysInMonth(e){return gR[gk(e.year)?"leapyear":"standard"][e.month-1]}getMonthsInYear(e){return 12}getDaysInYear(e){return gk(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 gN(e,t){let r=e.copy(),n="hour"in r?gV(r,t):0;gj(r,t.years||0),r.calendar.balanceYearMonth&&r.calendar.balanceYearMonth(r,e),r.month+=t.months||0,gA(r),g$(r),r.day+=7*(t.weeks||0),r.day+=t.days||0,r.day+=n,function(e){for(;e.day<1;)e.month--,gA(e),e.day+=e.calendar.getDaysInMonth(e);for(;e.day>e.calendar.getDaysInMonth(e);)e.day-=e.calendar.getDaysInMonth(e),e.month++,gA(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 a,i;let e=null==(a=(i=r.calendar).isInverseEra)?void 0:a.call(i,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 s=r.calendar.getMonthsInYear(r);return r.month>s&&(r.month=s,r.day=r.calendar.getDaysInMonth(r)),r.day=Math.max(1,Math.min(r.calendar.getDaysInMonth(r),r.day)),r}function gj(e,t){var r,n;(null==(r=(n=e.calendar).isInverseEra)?void 0:r.call(n,e))&&(t=-t),e.year+=t}function gA(e){for(;e.month<1;)gj(e,-1),e.month+=e.calendar.getMonthsInYear(e);let t=0;for(;e.month>(t=e.calendar.getMonthsInYear(e));)e.month-=t,gj(e,1)}function g$(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 gI(e){e.calendar.constrainDate&&e.calendar.constrainDate(e),e.year=Math.max(1,Math.min(e.calendar.getYearsInEra(e),e.year)),g$(e)}function gM(e){let t={};for(let r in e)"number"==typeof e[r]&&(t[r]=-e[r]);return t}function gL(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),gI(r),r}function gF(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),gB(r),r}function gB(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 gU(e,t){let r=e%t;return r<0&&(r+=t),r}function gV(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=gU(e.millisecond,1e3),e.minute+=Math.floor(e.second/60),e.second=gU(e.second,60),e.hour+=Math.floor(e.minute/60),e.minute=gU(e.minute,60),r=Math.floor(e.hour/24),e.hour=gU(e.hour,24),r}function gW(e,t){let r=e.copy();return gV(r,t),r}function gH(e,t,r,n){let o=e.copy();switch(t){case"era":{let t=e.calendar.getEras(),a=t.indexOf(e.era);if(a<0)throw Error("Invalid era: "+e.era);a=gK(a,r,0,t.length-1,null==n?void 0:n.round),o.era=t[a],gI(o);break}case"year":var a,i;(null==(a=(i=o.calendar).isInverseEra)?void 0:a.call(i,o))&&(r=-r),o.year=gK(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=gK(e.month,r,1,e.calendar.getMonthsInYear(e),null==n?void 0:n.round);break;case"day":o.day=gK(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),gI(o),o}function gz(e,t,r,n){let o=e.copy();switch(t){case"hour":{let t=e.hour,a=0,i=23;if((null==n?void 0:n.hourCycle)===12){let e=t>=12;a=12*!!e,i=e?23:11}o.hour=gK(t,r,a,i,null==n?void 0:n.round);break}case"minute":o.minute=gK(e.minute,r,0,59,null==n?void 0:n.round);break;case"second":o.second=gK(e.second,r,0,59,null==n?void 0:n.round);break;case"millisecond":o.millisecond=gK(e.millisecond,r,0,999,null==n?void 0:n.round);break;default:throw Error("Unsupported field "+t)}return o}function gK(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 gG(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?yt(gN(ya(e),{years:t.years,months:t.months,weeks:t.weeks,days:t.days}),e.timeZone):g5(e)-e.offset)+(t.milliseconds||0),r+=1e3*(t.seconds||0),r+=6e4*(t.minutes||0),yi(yn(r+=36e5*(t.hours||0),e.timeZone),e.calendar)}function gZ(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 gY(e){let t,r=yi(e,new gT);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 gq(e){return`${gY(e)}T${gZ(e)}`}function gJ(e){let t,r="object"==typeof e[0]?e.shift():new gT;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 gX=new WeakMap;class gQ{copy(){return this.era?new gQ(this.calendar,this.era,this.year,this.month,this.day):new gQ(this.calendar,this.year,this.month,this.day)}add(e){return gN(this,e)}subtract(e){return gN(this,gM(e))}set(e){return gL(this,e)}cycle(e,t,r){return gH(this,e,t,r)}toDate(e){return yr(this,e)}toString(){return gY(this)}compare(e){return yh(this,e)}constructor(...e){hw(this,gX,{writable:!0,value:void 0});let[t,r,n,o,a]=gJ(e);this.calendar=t,this.era=r,this.year=n,this.month=o,this.day=a,gI(this)}}var g0=new WeakMap;class g1{copy(){return new g1(this.hour,this.minute,this.second,this.millisecond)}add(e){return gW(this,e)}subtract(e){return gW(this,gM(e))}set(e){return gF(this,e)}cycle(e,t,r){return gz(this,e,t,r)}toString(){return gZ(this)}compare(e){var t,r;return t=this,r=e,yg(t)-yg(r)}constructor(e=0,t=0,r=0,n=0){hw(this,g0,{writable:!0,value:void 0}),this.hour=e,this.minute=t,this.second=r,this.millisecond=n,gB(this)}}var g2=new WeakMap;class g4{copy(){return this.era?new g4(this.calendar,this.era,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond):new g4(this.calendar,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond)}add(e){return gN(this,e)}subtract(e){return gN(this,gM(e))}set(e){return gL(gF(this,e),e)}cycle(e,t,r){switch(e){case"era":case"year":case"month":case"day":return gH(this,e,t,r);default:return gz(this,e,t,r)}}toDate(e,t){return yr(this,e,t)}toString(){return gq(this)}compare(e){var t,r;let n=yh(this,e);return 0===n?(t=this,r=ya(e),yg(t)-yg(r)):n}constructor(...e){hw(this,g2,{writable:!0,value:void 0});let[t,r,n,o,a]=gJ(e);this.calendar=t,this.era=r,this.year=n,this.month=o,this.day=a,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,gI(this)}}var g3=new WeakMap;class g6{copy(){return this.era?new g6(this.calendar,this.era,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond):new g6(this.calendar,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond)}add(e){return gG(this,e)}subtract(e){return gG(this,gM(e))}set(e,t){let r,n;return 0===(n=gF(gL(r=ya(this),e),e)).compare(r)?this:yi(yn(yt(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 a=ya(e),i=yi(gF(a,{hour:t}),new gT),s=[yt(i,e.timeZone,"earlier"),yt(i,e.timeZone,"later")].filter(t=>yn(t,e.timeZone).day===i.day)[0],l=yi(gF(a,{hour:o}),new gT),u=[yt(l,e.timeZone,"earlier"),yt(l,e.timeZone,"later")].filter(t=>yn(t,e.timeZone).day===l.day).pop(),c=g5(e)-e.offset,d=Math.floor(c/36e5),f=c%36e5;return yi(yn(c=36e5*gK(d,r,Math.floor(s/36e5),Math.floor(u/36e5),null==n?void 0:n.round)+f,e.timeZone),e.calendar)}case"minute":case"second":case"millisecond":return gz(e,t,r,n);case"era":case"year":case"month":case"day":return yi(yn(yt(gH(ya(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(g5(e)-e.offset)}toString(){var e;let t,r,n;return`${gq(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 g6){var r,n;return e.timeZone===t?e:(r=e,n=t,yi(yn(g5(r)-r.offset,n),r.calendar))}return yn(yt(e,t,void 0),t)})(e,this.timeZone).toDate().getTime()}constructor(...e){hw(this,g3,{writable:!0,value:void 0});let[t,r,n,o,a]=gJ(e),i=e.shift(),s=e.shift();this.calendar=t,this.era=r,this.year=n,this.month=o,this.day=a,this.timeZone=i,this.offset=s,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,gI(this)}}function g5(e){return g9(gP((e=yi(e,new gT)).era,e.year),e.month,e.day,e.hour,e.minute,e.second,e.millisecond)}function g9(e,t,r,n,o,a,i){let s=new Date;return s.setUTCHours(n,o,a,i),s.setUTCFullYear(e,t-1,r),s.getTime()}function g8(e,t){if("UTC"===t)return 0;if(e>0&&t===yv())return -6e4*new Date(e).getTimezoneOffset();let{year:r,month:n,day:o,hour:a,minute:i,second:s}=ye(e,t);return g9(r,n,o,a,i,s,0)-1e3*Math.floor(e/1e3)}let g7=new Map;function ye(e,t){let r=g7.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"}),g7.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 yt(e,t,r="compatible"){var n,o,a;let i=ya(e);if("UTC"===t)return g5(i);if(t===yv()&&"compatible"===r){i=yi(i,new gT);let e=new Date,t=gP(i.era,i.year);return e.setFullYear(t,i.month-1,i.day),e.setHours(i.hour,i.minute,i.second,i.millisecond),e.getTime()}let s=g5(i),l=g8(s-864e5,t),u=g8(s+864e5,t),c=(n=i,((o=s-l)==(a=s-u)?[o]:[o,a]).filter(e=>{var r;let o;return r=n,o=ye(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(s-l,s-u);case"compatible":case"later":return Math.max(s-l,s-u);case"reject":throw RangeError("No such absolute time found")}}function yr(e,t,r="compatible"){return new Date(yt(e,t,r))}function yn(e,t){let r=g8(e,t),n=new Date(e+r),o=n.getUTCFullYear();return new g6(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 yo(e){return new gQ(e.calendar,e.era,e.year,e.month,e.day)}function ya(e,t){let r=0,n=0,o=0,a=0;if("timeZone"in e)({hour:r,minute:n,second:o,millisecond:a}=e);else if("hour"in e&&!t)return e;return t&&({hour:r,minute:n,second:o,millisecond:a}=t),new g4(e.calendar,e.era,e.year,e.month,e.day,r,n,o,a)}function yi(e,t){if(yc(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,gI(n),n}let ys={"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 yl(e,t){return t=yi(t,e.calendar),e.era===t.era&&e.year===t.year&&e.month===t.month&&e.day===t.day}function yu(e,t){return yc(e.calendar,t.calendar)&&yl(e,t)}function yc(e,t){var r,n,o,a;return null!=(a=null!=(o=null==(r=e.isEqual)?void 0:r.call(e,t))?o:null==(n=t.isEqual)?void 0:n.call(t,e))?a:e.identifier===t.identifier}let yd={sun:0,mon:1,tue:2,wed:3,thu:4,fri:5,sat:6};function yf(e,t,r){let n,o=Math.ceil(e.calendar.toJulianDay(e)+1-(r?yd[r]:(n=function(e){if(Intl.Locale){let t=yx.get(e);return!t&&(t=new Intl.Locale(e).maximize().region)&&yx.set(e,t),t}let t=e.split("-")[1];return"u"===t?void 0:t}(t))&&ys[n]||0))%7;return o<0&&(o+=7),o}function yp(e){return yn(Date.now(),e)}function ym(e){return yo(yp(e))}function yh(e,t){return e.calendar.toJulianDay(e)-t.calendar.toJulianDay(t)}function yg(e){return 36e5*e.hour+6e4*e.minute+1e3*e.second+e.millisecond}let yy=null;function yv(){return null==yy&&(yy=new Intl.DateTimeFormat().resolvedOptions().timeZone),yy}function yb(e){return e.subtract({days:e.day-1})}function yw(e){return e.add({days:e.calendar.getDaysInMonth(e)-e.day})}function yE(e,t,r){let n=yf(e,t,r);return e.subtract({days:n})}let yx=new Map;function yD(e,t){return e&&t?0>=e.compare(t)?e:t:e||t}function y_(e,t){return e&&t?e.compare(t)>=0?e:t:e||t}let yS=Symbol.for("react-aria.i18n.locale"),yC=Symbol.for("react-aria.i18n.strings");class yk{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[yS];if(void 0===p){let e=window[yC];if(!e)return null;for(let r in p={},e)p[r]=new yk({[t]:e[r]},t)}let r=null==p?void 0:p[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 yP=new Map,yO=new Map;class yR{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,a=yP.get(o);return a||(a=new Intl.PluralRules(this.locale,{type:r}),yP.set(o,a)),"function"==typeof(n=t[a.select(e)]||t.other)?n():n}number(e){let t=yO.get(this.locale);return t||(t=new Intl.NumberFormat(this.locale),yO.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 yT=new WeakMap;function yN(e,t){let r;return t&&yk.getGlobalDictionaryForPackage(t)||((r=yT.get(e))||(r=new yk(e),yT.set(e,r)),r)}function yj(e,t){let{locale:r}=gD(),n=yN(e,t);return(0,cu.useMemo)(()=>new yR(r,n),[r,n])}let yA=new Map;class y${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==yF&&(yF="h12"===new Intl.DateTimeFormat("fr",{hour:"numeric",hour12:!1}).resolvedOptions().hourCycle),yF&&(this.resolvedHourCycle||(this.resolvedHourCycle=function(e,t){if(!t.timeStyle&&!t.hour)return;e=e.replace(/(-u-)?-nu-[a-zA-Z0-9]+/,"");let r=yM(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=yM(e,t),this.options=t}}let yI={true:{ja:"h11"},false:{}};function yM(e,t={}){if("boolean"==typeof t.hour12&&(null==yL&&(yL="24"===new Intl.DateTimeFormat("en-US",{hour:"numeric",hour12:!1}).format(new Date(2020,2,3,0))),yL)){let r=yI[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(yA.has(r))return yA.get(r);let n=new Intl.DateTimeFormat(e,t);return yA.set(r,n),n}let yL=null,yF=null;function yB(e,t){let r=(0,cu.useRef)(null);return e&&r.current&&t(e,r.current)&&(e=r.current),r.current=e,e}function yU(e){e=yB(null!=e?e:{},yV);let{locale:t}=gD();return(0,cu.useMemo)(()=>new y$(t,e),[t,e])}function yV(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 yW(e){return e&&e.__esModule?e.default:e}let yH=new WeakMap;function yz(e){return(null==e?void 0:e.calendar.identifier)==="gregory"&&"BC"===e.era?"short":void 0}function yK(e,t,r,n){let o=yj(yW(g_),"@react-aria/calendar"),a=yz(e)||yz(t),i=yU({month:"long",year:"numeric",era:a,calendar:e.calendar.identifier,timeZone:r}),s=yU({month:"long",year:"numeric",day:"numeric",era:a,calendar:e.calendar.identifier,timeZone:r});return(0,cu.useMemo)(()=>{if(yl(e,yb(e))){let a=e,s=t;if(e.calendar.getFormattableMonth&&(a=e.calendar.getFormattableMonth(e)),t.calendar.getFormattableMonth&&(s=t.calendar.getFormattableMonth(t)),yl(t,yw(e)))return i.format(a.toDate(r));if(yl(t,yw(t)))return n?yG(i,o,a,s,r):i.formatRange(a.toDate(r),s.toDate(r))}return n?yG(s,o,e,t,r):s.formatRange(e.toDate(r),t.toDate(r))},[e,t,i,s,o,r,n])}function yG(e,t,r,n,o){let a=e.formatRangeToParts(r.toDate(o),n.toDate(o)),i=-1;for(let e=0;e<a.length;e++){let t=a[e];if("shared"===t.source&&"literal"===t.type)i=e;else if("endRange"===t.source)break}let s="",l="";for(let e=0;e<a.length;e++)e<i?s+=a[e].value:e>i&&(l+=a[e].value);return t.format("dateRange",{startDate:s,endDate:l})}function yZ(e,t){let r=(0,cu.useRef)(!0),n=(0,cu.useRef)(null);(0,cu.useEffect)(()=>(r.current=!0,()=>{r.current=!1}),[]),(0,cu.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 yY(e,t){let{id:r,"aria-label":n,"aria-labelledby":o}=e;return r=mR(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 yq(e,t){var r,n;let o,a,i,s,l,u=yj((r=g_)&&r.__esModule?r.default:r,"@react-aria/calendar"),c=mY(e),d=yK(t.visibleRange.start,t.visibleRange.end,t.timeZone,!1),f=yK(t.visibleRange.start,t.visibleRange.end,t.timeZone,!0);yZ(()=>{t.isFocused||mW(f)},[f]);let p=(i=yj(yW(g_),"@react-aria/calendar"),"highlightedRange"in t?{start:o,end:a}=t.highlightedRange||{}:o=a=null!=(n=t.value)?n:void 0,s=yU({weekday:"long",month:"long",year:"numeric",day:"numeric",era:yz(o)||yz(a),timeZone:t.timeZone}),l="anchorDate"in t?t.anchorDate:null,(0,cu.useMemo)(()=>{if(!l&&o&&a)if(yl(o,a)){let e=s.format(o.toDate(t.timeZone));return i.format("selectedDateDescription",{date:e})}else{let e=yG(s,i,o,a,t.timeZone);return i.format("selectedRangeDescription",{dateRange:e})}return""},[o,a,l,t.timeZone,i,s]));yZ(()=>{p&&mW(p,"polite",4e3)},[p]);let m=mT([!!e.errorMessage,e.isInvalid,e.validationState]);yH.set(t,{ariaLabel:e["aria-label"],ariaLabelledBy:e["aria-labelledby"],errorMessageId:m,selectedDateDescription:p});let[h,g]=(0,cu.useState)(!1),y=e.isDisabled||t.isNextVisibleRangeInvalid();y&&h&&(g(!1),t.setFocused(!0));let[v,b]=(0,cu.useState)(!1),w=e.isDisabled||t.isPreviousVisibleRangeInvalid();return w&&v&&(b(!1),t.setFocused(!0)),{calendarProps:mj(c,yY({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":u.format("next"),isDisabled:y,onFocusChange:g},prevButtonProps:{onPress:()=>t.focusPreviousPage(),"aria-label":u.format("previous"),isDisabled:w,onFocusChange:b},errorMessageProps:{id:m},title:d}}let yJ={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 yX(e){let{children:t,elementType:r="div",isFocusable:n,style:o,...a}=e,{visuallyHiddenProps:i}=function(e={}){let{style:t,isFocusable:r}=e,[n,o]=(0,cu.useState)(!1),{focusWithinProps:a}=h9({isDisabled:!r,onFocusWithinChange:e=>o(e)}),i=(0,cu.useMemo)(()=>n?t:t?{...yJ,...t}:yJ,[n]);return{visuallyHiddenProps:{...a,style:i}}}(e);return cc().createElement(r,mj(a,i),t)}function yQ(e,t,r,n){let o=mv(r),a=null==r;(0,cu.useEffect)(()=>{if(a||!e.current)return;let r=e.current;return r.addEventListener(t,o,n),()=>{r.removeEventListener(t,o,n)}},[e,t,n,a,o])}let y0=0,y1=new Map;function y2(e){let[t,r]=(0,cu.useState)();return my(()=>{if(!e)return;let t=y1.get(e);if(t)r(t.element.id);else{let n=`react-aria-description-${y0++}`;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},y1.set(e,t)}return t.refCount++,()=>{t&&0==--t.refCount&&(t.element.remove(),y1.delete(e))}},[e]),{"aria-describedby":e?t:void 0}}function y4(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 y3(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 y6(e,t){if(e&&document.contains(e)){let i=document.scrollingElement||document.documentElement;if("hidden"===window.getComputedStyle(i).overflow)for(let t of function(e){let t=[];for(;e&&e!==document.documentElement;)y4(e,void 0)&&t.push(e),e=e.parentElement;return t}(e))!function(e,t){let r=y3(e,t,"left"),n=y3(e,t,"top"),o=t.offsetWidth,a=t.offsetHeight,i=e.scrollLeft,s=e.scrollTop,{borderTopWidth:l,borderLeftWidth:u,scrollPaddingTop:c,scrollPaddingRight:d,scrollPaddingBottom:f,scrollPaddingLeft:p}=getComputedStyle(e),m=i+parseInt(u,10),h=s+parseInt(l,10),g=m+e.clientWidth,y=h+e.clientHeight,v=parseInt(c,10)||0,b=parseInt(f,10)||0,w=parseInt(d,10)||0,E=parseInt(p,10)||0;r<=i+E?i=r-parseInt(u,10)-E:r+o>g-w&&(i+=r+o-g+w),n<=h+v?s=n-parseInt(l,10)-v:n+a>y-b&&(s+=n+a-y+b),e.scrollLeft=i,e.scrollTop=s}(t,e);else{var r,n,o,a;let{left:i,top:s}=e.getBoundingClientRect();null==e||null==(r=e.scrollIntoView)||r.call(e,{block:"nearest"});let{left:l,top:u}=e.getBoundingClientRect();(Math.abs(i-l)>1||Math.abs(s-u)>1)&&(null==t||null==(o=t.containingElement)||null==(n=o.scrollIntoView)||n.call(o,{block:"center",inline:"center"}),null==(a=e.scrollIntoView)||a.call(e,{block:"nearest"}))}}}function y5(e,t){let r=e;for(y4(r,t)&&(r=r.parentElement);r&&!y4(r,t);)r=r.parentElement;return r||document.scrollingElement||document.documentElement}class y9 extends gT{fromJulianDay(e){let t=super.fromJulianDay(e);return new gQ(this,gP(t.era,t.year)- -543,t.month,t.day)}toJulianDay(e){return super.toJulianDay(y8(e))}getEras(){return["BE"]}getDaysInMonth(e){return super.getDaysInMonth(y8(e))}balanceDate(){}constructor(...e){super(...e),this.identifier="buddhist"}}function y8(e){let[t,r]=gO(e.year+-543);return new gQ(t,r,e.month,e.day)}function y7(e,t,r,n){return e+365*t+Math.floor(t/4)+30*(r-1)+n-1}function ve(e,t){let r=Math.floor(4*(t-e)/1461),n=1+Math.floor((t-y7(e,r,1,1))/30),o=t+1-y7(e,r,n,1);return[r,n,o]}function vt(e){return Math.floor(e%4/3)}function vr(e,t){return t%13!=0?30:vt(e)+5}class vn{fromJulianDay(e){let[t,r,n]=ve(1723856,e),o="AM";return t<=0&&(o="AA",t+=5500),new gQ(this,o,t,r,n)}toJulianDay(e){let t=e.year;return"AA"===e.era&&(t-=5500),y7(1723856,t,e.month,e.day)}getDaysInMonth(e){return vr(e.year,e.month)}getMonthsInYear(){return 13}getDaysInYear(e){return 365+vt(e.year)}getYearsInEra(e){return"AA"===e.era?9999:9991}getEras(){return["AA","AM"]}constructor(){this.identifier="ethiopic"}}class vo extends vn{fromJulianDay(e){let[t,r,n]=ve(1723856,e);return new gQ(this,"AA",t+=5500,r,n)}getEras(){return["AA"]}getYearsInEra(){return 9999}constructor(...e){super(...e),this.identifier="ethioaa"}}class va extends vn{fromJulianDay(e){let[t,r,n]=ve(1824665,e),o="CE";return t<=0&&(o="BCE",t=1-t),new gQ(this,o,t,r,n)}toJulianDay(e){let t=e.year;return"BCE"===e.era&&(t=1-t),y7(1824665,t,e.month,e.day)}getDaysInMonth(e){let t=e.year;return"BCE"===e.era&&(t=1-t),vr(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 vi=765433;function vs(e){return 7>gS(7*e+1,19)}function vl(e){let t=Math.floor((235*e-234)/19),r=29*t+Math.floor((12084+13753*t)/25920);return 3>gS(3*(r+1),7)&&(r+=1),r}function vu(e){let t,r;return vl(e)+(t=vl(e-1),r=vl(e),vl(e+1)-r==356?2:+(r-t==382))}function vc(e){return vu(e+1)-vu(e)}function vd(e,t){if(t>=6&&!vs(e)&&t++,4===t||7===t||9===t||11===t||13===t)return 29;let r=function(e){let t=vc(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*!!vs(e):30}class vf{fromJulianDay(e){let t=e-347997,r=Math.floor((25920*t/vi*19+234)/235)+1,n=vu(r),o=Math.floor(t-n);for(;o<1;)o=Math.floor(t-(n=vu(--r)));let a=1,i=0;for(;i<o;)i+=vd(r,a),a++;let s=o-(i-=vd(r,--a));return new gQ(this,r,a,s)}toJulianDay(e){let t=vu(e.year);for(let r=1;r<e.month;r++)t+=vd(e.year,r);return t+e.day+347997}getDaysInMonth(e){return vd(e.year,e.month)}getMonthsInYear(e){return vs(e.year)?13:12}getDaysInYear(e){return vc(e.year)}getYearsInEra(){return 9999}getEras(){return["AM"]}balanceYearMonth(e,t){t.year!==e.year&&(vs(t.year)&&!vs(e.year)&&t.month>6?e.month--:!vs(t.year)&&vs(e.year)&&t.month>6&&e.month++)}constructor(){this.identifier="hebrew"}}class vp extends gT{fromJulianDay(e){let t,r,n,o=super.fromJulianDay(e),a=o.year-78,i=e-gC(o.era,o.year,1,1);if(i<80?(a--,i+=(t=gk(o.year-1)?31:30)+155+90+10):(t=gk(o.year)?31:30,i-=80),i<t)r=1,n=i+1;else{let e=i-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 gQ(this,a,r,n)}toJulianDay(e){let t,r,[n,o]=gO(e.year+78);return(gk(o)?(t=31,r=gC(n,o,3,21)):(t=30,r=gC(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&&gk(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 vm(e,t,r,n){return n+Math.ceil(29.5*(r-1))+(t-1)*354+Math.floor((3+11*t)/30)+e-1}function vh(e,t,r){let n=Math.floor((30*(r-t)+10646)/10631),o=Math.min(12,Math.ceil((r-(29+vm(t,n,1,1)))/29.5)+1),a=r-vm(t,n,o,1)+1;return new gQ(e,n,o,a)}function vg(e){return(14+11*e)%30<11}class vy{fromJulianDay(e){return vh(this,1948440,e)}toJulianDay(e){return vm(1948440,e.year,e.month,e.day)}getDaysInMonth(e){let t=29+e.month%2;return 12===e.month&&vg(e.year)&&t++,t}getMonthsInYear(){return 12}getDaysInYear(e){return vg(e.year)?355:354}getYearsInEra(){return 9665}getEras(){return["AH"]}constructor(){this.identifier="islamic-civil"}}class vv extends vy{fromJulianDay(e){return vh(this,1948439,e)}toJulianDay(e){return vm(1948439,e.year,e.month,e.day)}constructor(...e){super(...e),this.identifier="islamic-tbla"}}function vb(e){return 460322+u[e-1300]}function vw(e,t){return(l[e-1300]&1<<11-(t-1))==0?29:30}function vE(e,t){let r=vb(e);for(let n=1;n<t;n++)r+=vw(e,n);return r}function vx(e){return u[e+1-1300]-u[e-1300]}class vD extends vy{fromJulianDay(e){let t=e-1948440,r=vb(1300),n=vb(1600);if(t<r||t>n)return super.fromJulianDay(e);{let e=1299,r=1,n=1;for(;n>0;){n=t-vb(++e)+1;let o=vx(e);if(n===o){r=12;break}if(n<o){let t=vw(e,r);for(r=1;n>t;)n-=t,t=vw(e,++r);break}}return new gQ(this,e,r,t-vE(e,r)+1)}}toJulianDay(e){return e.year<1300||e.year>1600?super.toJulianDay(e):1948440+vE(e.year,e.month)+(e.day-1)}getDaysInMonth(e){return e.year<1300||e.year>1600?super.getDaysInMonth(e):vw(e.year,e.month)}getDaysInYear(e){return e.year<1300||e.year>1600?super.getDaysInYear(e):vx(e.year)}constructor(){if(super(),this.identifier="islamic-umalqura",l||(l=new Uint16Array(Uint8Array.from(atob("qgpUDckO1AbqBmwDrQpVBakGkgepC9QF2gpcBS0NlQZKB1QLagutBa4ETwoXBYsGpQbVCtYCWwmdBE0KJg2VDawFtgm6AlsKKwWVCsoG6Qr0AnYJtgJWCcoKpAvSC9kF3AJtCU0FpQpSC6ULtAW2CVcFlwJLBaMGUgdlC2oFqworBZUMSg2lDcoF1gpXCasESwmlClILagt1BXYCtwhbBFUFqQW0BdoJ3QRuAjYJqgpUDbIN1QXaAlsJqwRVCkkLZAtxC7QFtQpVCiUNkg7JDtQG6QprCasEkwpJDaQNsg25CroEWworBZUKKgtVC1wFvQQ9Ah0JlQpKC1oLbQW2AjsJmwRVBqkGVAdqC2wFrQpVBSkLkgupC9QF2gpaBasKlQVJB2QHqgu1BbYCVgpNDiULUgtqC60FrgIvCZcESwalBqwG1gpdBZ0ETQoWDZUNqgW1BdoCWwmtBJUFygbkBuoK9QS2AlYJqgpUC9IL2QXqAm0JrQSVCkoLpQuyBbUJ1gSXCkcFkwZJB1ULagVrCisFiwpGDaMNygXWCtsEawJLCaUKUgtpC3UFdgG3CFsCKwVlBbQF2gntBG0BtgimClINqQ3UBdoKWwmrBFMGKQdiB6kLsgW1ClUFJQuSDckO0gbpCmsFqwRVCikNVA2qDbUJugQ7CpsETQqqCtUK2gJdCV4ELgqaDFUNsga5BroEXQotBZUKUguoC7QLuQXaAloJSgukDdEO6AZqC20FNQWVBkoNqA3UDdoGWwWdAisGFQtKC5ULqgWuCi4JjwwnBZUGqgbWCl0FnQI="),e=>e.charCodeAt(0)).buffer)),!u){u=new Uint32Array(301);let e=0;for(let t=1300;t<=1600;t++){u[t-1300]=e;for(let r=1;r<=12;r++)e+=vw(t,r)}}}}let v_=[[1868,9,8],[1912,7,30],[1926,12,25],[1989,1,8],[2019,5,1]],vS=[[1912,7,29],[1926,12,24],[1989,1,7],[2019,4,30]],vC=[1867,1911,1925,1988,2018],vk=["meiji","taisho","showa","heisei","reiwa"];function vP(e){let t=v_.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?v_.length-1:0===t?0:t-1}function vO(e){let t=vC[vk.indexOf(e.era)];if(!t)throw Error("Unknown era: "+e.era);return new gQ(e.year+t,e.month,e.day)}class vR extends gT{fromJulianDay(e){let t=super.fromJulianDay(e),r=vP(t);return new gQ(this,vk[r],t.year-vC[r],t.month,t.day)}toJulianDay(e){return super.toJulianDay(vO(e))}balanceDate(e){let t=vO(e),r=vP(t);vk[r]!==e.era&&(e.era=vk[r],e.year=t.year-vC[r]),this.constrainDate(e)}constrainDate(e){let t=vk.indexOf(e.era),r=vS[t];if(null!=r){let[n,o,a]=r,i=n-vC[t];e.year=Math.max(1,Math.min(i,e.year)),e.year===i&&(e.month=Math.min(o,e.month),e.month===o&&(e.day=Math.min(a,e.day)))}if(1===e.year&&t>=0){let[,r,n]=v_[t];e.month=Math.max(r,e.month),e.month===r&&(e.day=Math.max(n,e.day))}}getEras(){return vk}getYearsInEra(e){let t=vk.indexOf(e.era),r=v_[t],n=v_[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(vO(e))}getMinimumMonthInYear(e){let t=vT(e);return t?t[1]:1}getMinimumDayInMonth(e){let t=vT(e);return t&&e.month===t[1]?t[2]:1}constructor(...e){super(...e),this.identifier="japanese"}}function vT(e){if(1===e.year)return v_[vk.indexOf(e.era)]}let vN=[0,31,62,93,124,155,186,216,246,276,306,336];class vj{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),a=n-vN[o]+1;return new gQ(this,r,o+1,a)}toJulianDay(e){let t=1948319+365*(e.year-1)+Math.floor((8*e.year+21)/33);return t+=vN[e.month-1],t+=e.day}getMonthsInYear(){return 12}getDaysInMonth(e){return e.month<=6?31:e.month<=11||8>gS(25*e.year+11,33)?30:29}getEras(){return["AP"]}getYearsInEra(){return 9377}constructor(){this.identifier="persian"}}function vA(e){return"minguo"===e.era?e.year+1911:1-e.year+1911}function v$(e){let t=e-1911;return t>0?["minguo",t]:["before_minguo",1-t]}class vI extends gT{fromJulianDay(e){let t=super.fromJulianDay(e),[r,n]=v$(gP(t.era,t.year));return new gQ(this,r,n,t.month,t.day)}toJulianDay(e){return super.toJulianDay(vM(e))}getEras(){return["before_minguo","minguo"]}balanceDate(e){let[t,r]=v$(vA(e));e.era=t,e.year=r}isInverseEra(e){return"before_minguo"===e.era}getDaysInMonth(e){return super.getDaysInMonth(vM(e))}getYearsInEra(e){return"before_minguo"===e.era?9999:8088}constructor(...e){super(...e),this.identifier="roc"}}function vM(e){let[t,r]=gO(vA(e));return new gQ(t,r,e.month,e.day)}function vL(e){switch(e){case"buddhist":return new y9;case"ethiopic":return new vn;case"ethioaa":return new vo;case"coptic":return new va;case"hebrew":return new vf;case"indian":return new vp;case"islamic-civil":return new vy;case"islamic-tbla":return new vv;case"islamic-umalqura":return new vD;case"japanese":return new vR;case"persian":return new vj;case"roc":return new vI;default:return new gT}}function vF(e,t,r){return null!=t&&0>e.compare(t)||null!=r&&e.compare(r)>0}function vB(e,t,r,n,o){let a={};for(let e in t)a[e]=Math.floor(t[e]/2),a[e]>0&&t[e]%2==0&&a[e]--;let i=vU(e,t,r).subtract(a);return vW(e,i,t,r,n,o)}function vU(e,t,r,n,o){let a=e;if(t.years)a=yb(e.subtract({months:e.month-1}));else t.months?a=yb(e):t.weeks&&(a=yE(e,r));return vW(e,a,t,r,n,o)}function vV(e,t,r,n,o){let a={...t};a.days?a.days--:a.weeks?a.weeks--:a.months?a.months--:a.years&&a.years--;let i=vU(e,t,r).subtract(a);return vW(e,i,t,r,n,o)}function vW(e,t,r,n,o,a){if(o&&e.compare(o)>=0){let e=y_(t,vU(yo(o),r,n));e&&(t=e)}if(a&&0>=e.compare(a)){let e=yD(t,vV(yo(a),r,n));e&&(t=e)}return t}function vH(e,t,r){if(t){let r=y_(e,yo(t));r&&(e=r)}if(r){let t=yD(e,yo(r));t&&(e=t)}return e}function vz(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 vK(e,t,r){let[n,o]=(0,cu.useState)(e||t),a=(0,cu.useRef)(void 0!==e),i=void 0!==e;(0,cu.useEffect)(()=>{a.current,a.current=i},[i]);let s=i?e:n,l=(0,cu.useCallback)((e,...t)=>{let n=(e,...t)=>{r&&!Object.is(s,e)&&r(e,...t),i||(s=e)};"function"==typeof e?o((r,...o)=>{let a=e(i?s:r,...o);return(n(a,...t),i)?r:a}):(i||o(e),n(e,...t))},[i,s,r]);return[s,l]}function vG(e){var t,r,n;let o=(0,cu.useMemo)(()=>new y$(e.locale),[e.locale]),a=(0,cu.useMemo)(()=>o.resolvedOptions(),[o]),{locale:i,createCalendar:s,visibleDuration:l={months:1},minValue:u,maxValue:c,selectionAlignment:d,isDateUnavailable:f,pageBehavior:p="visible",firstDayOfWeek:m}=e,h=(0,cu.useMemo)(()=>s(a.calendar),[s,a.calendar]),[g,y]=vK(e.value,null!=(t=e.defaultValue)?t:null,e.onChange),v=(0,cu.useMemo)(()=>g?yi(yo(g),h):null,[g,h]),b=(0,cu.useMemo)(()=>g&&"timeZone"in g?g.timeZone:a.timeZone,[g,a.timeZone]),[w,E]=vK((0,cu.useMemo)(()=>e.focusedValue?vH(yi(yo(e.focusedValue),h),u,c):void 0,[e.focusedValue,h,u,c]),(0,cu.useMemo)(()=>vH(e.defaultFocusedValue?yi(yo(e.defaultFocusedValue),h):v||yi(ym(b),h),u,c),[e.defaultFocusedValue,v,b,h,u,c]),e.onFocusChange),[x,D]=(0,cu.useState)(()=>{switch(d){case"start":return vU(w,l,i,u,c);case"end":return vV(w,l,i,u,c);default:return vB(w,l,i,u,c)}}),[_,S]=(0,cu.useState)(e.autoFocus||!1),C=(0,cu.useMemo)(()=>{let e={...l};return e.days?e.days--:e.days=-1,x.add(e)},[x,l]),[k,P]=(0,cu.useState)(h);if(!yc(h,k)){let e=yi(w,h);D(vB(e,l,i,u,c)),E(e),P(h)}function O(e){E(e=vH(e,u,c))}function R(t){if(!e.isDisabled&&!e.isReadOnly){let e=t;if(null===e)return void y(null);(e=vz(e=vH(e,u,c),x,f))&&(e=yi(e,(null==g?void 0:g.calendar)||new gT),g&&"hour"in g?y(g.set(e)):y(e))}}vF(w,u,c)?E(vH(w,u,c)):0>w.compare(x)?D(vV(w,l,i,u,c)):w.compare(C)>0&&D(vU(w,l,i,u,c));let T=(0,cu.useMemo)(()=>!!v&&(!!(f&&f(v))||vF(v,u,c)),[v,f,u,c]),N=e.isInvalid||"invalid"===e.validationState||T,j=(0,cu.useMemo)(()=>"visible"===p?l:vZ(l),[p,l]);return{isDisabled:null!=(r=e.isDisabled)&&r,isReadOnly:null!=(n=e.isReadOnly)&&n,value:v,setValue:R,visibleRange:{start:x,end:C},minValue:u,maxValue:c,focusedDate:w,timeZone:b,validationState:N?"invalid":null,isValueInvalid:N,setFocusedDate(e){O(e),S(!0)},focusNextDay(){O(w.add({days:1}))},focusPreviousDay(){O(w.subtract({days:1}))},focusNextRow(){l.days?this.focusNextPage():(l.weeks||l.months||l.years)&&O(w.add({weeks:1}))},focusPreviousRow(){l.days?this.focusPreviousPage():(l.weeks||l.months||l.years)&&O(w.subtract({weeks:1}))},focusNextPage(){let e=x.add(j);E(vH(w.add(j),u,c)),D(vU(vW(w,e,j,i,u,c),j,i))},focusPreviousPage(){let e=x.subtract(j);E(vH(w.subtract(j),u,c)),D(vU(vW(w,e,j,i,u,c),j,i))},focusSectionStart(){l.days?O(x):l.weeks?O(yE(w,i)):(l.months||l.years)&&O(yb(w))},focusSectionEnd(){l.days?O(C):l.weeks?O(yE(w,i,void 0).add({days:6})):(l.months||l.years)&&O(yw(w))},focusNextSection(e){e||l.days?l.days?this.focusNextPage():l.weeks?O(w.add({months:1})):(l.months||l.years)&&O(w.add({years:1})):O(w.add(vZ(l)))},focusPreviousSection(e){e||l.days?l.days?this.focusPreviousPage():l.weeks?O(w.subtract({months:1})):(l.months||l.years)&&O(w.subtract({years:1})):O(w.subtract(vZ(l)))},selectFocusedDate(){f&&f(w)||R(w)},selectDate(e){R(e)},isFocused:_,setFocused:S,isInvalid:e=>vF(e,u,c),isSelected(e){return null!=v&&yl(e,v)&&!this.isCellDisabled(e)&&!this.isCellUnavailable(e)},isCellFocused:e=>_&&w&&yl(e,w),isCellDisabled(t){return e.isDisabled||0>t.compare(x)||t.compare(C)>0||this.isInvalid(t)},isCellUnavailable:t=>!!e.isDateUnavailable&&e.isDateUnavailable(t),isPreviousVisibleRangeInvalid(){let e=x.subtract({days:1});return yl(e,x)||this.isInvalid(e)},isNextVisibleRangeInvalid(){let e=C.add({days:1});return yl(e,C)||this.isInvalid(e)},getDatesInWeek(e,t=x){let r=t.add({weeks:e}),n=[],o=yf(r=yE(r,i,m),i,m);for(let e=0;e<o;e++)n.push(null);for(;n.length<7;){n.push(r);let e=r.add({days:1});if(yl(r,e))break;r=e}for(;n.length<7;)n.push(null);return n}}}function vZ(e){let t={...e};for(let r in e)t[r]=1;return t}function vY(e,t){return e&&t?(0>t.compare(e)&&([e,t]=[t,e]),{start:yo(e),end:yo(t)}):null}function vq(e,t){return(e=yi(e,(null==t?void 0:t.calendar)||new gT),t&&"hour"in t)?t.set(e):e}function vJ(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 vX=(0,cu.createContext)(null),vQ=(0,cu.createContext)(null),v0=(0,cu.createContext)(null),v1=(0,cu.createContext)(null),v2=(0,cu.forwardRef)(function(e,t){[e,t]=mL(e,t,vX);let{locale:r}=gD(),n=vG({...e,locale:r,createCalendar:e.createCalendar||vL}),{calendarProps:o,prevButtonProps:a,nextButtonProps:i,errorMessageProps:s,title:l}=yq(e,n),u=mI({...e,values:{state:n,isDisabled:e.isDisabled||!1,isInvalid:n.isValueInvalid},defaultClassName:"react-aria-Calendar"});return cc().createElement("div",{...u,...o,ref:t,slot:e.slot||void 0,"data-disabled":e.isDisabled||void 0,"data-invalid":n.isValueInvalid||void 0},cc().createElement(m$,{values:[[gs,{slots:{previous:a,next:i}}],[gu,{"aria-hidden":!0,level:2,children:l}],[v0,n],[vX,e],[gc,{slots:{errorMessage:s}}]]},cc().createElement(yX,null,cc().createElement("h2",null,o["aria-label"])),u.children,cc().createElement(yX,null,cc().createElement("button",{"aria-label":i["aria-label"],disabled:i.isDisabled,onClick:()=>n.focusNextPage(),tabIndex:-1}))))}),v4=(0,cu.forwardRef)(function(e,t){var r,n;let o,a,i;[e,t]=mL(e,t,vQ);let{locale:s}=gD(),l=function(e){let{value:t,defaultValue:r,onChange:n,createCalendar:o,locale:a,visibleDuration:i={months:1},minValue:s,maxValue:l,...u}=e,[c,d]=vK(t,r||null,n),[f,p]=(0,cu.useState)(null),m="center";if(c&&c.start&&c.end){let e=vB(yo(c.start),i,a,s,l).add(i).subtract({days:1});c.end.compare(e)>0&&(m="start")}let h=(0,cu.useRef)(null),[g,y]=(0,cu.useState)(null),v=(0,cu.useMemo)(()=>y_(s,null==g?void 0:g.start),[s,g]),b=(0,cu.useMemo)(()=>yD(l,null==g?void 0:g.end),[l,g]),w=vG({...u,value:c&&c.start,createCalendar:o,locale:a,visibleDuration:i,minValue:v,maxValue:b,selectionAlignment:m}),E=t=>{t&&e.isDateUnavailable&&!e.allowsNonContiguousRanges?(h.current={start:vJ(t,w,-1),end:vJ(t,w,1)},y(h.current)):(h.current=null,y(null))},[x,D]=(0,cu.useState)(w.visibleRange);yu(w.visibleRange.start,x.start)&&yu(w.visibleRange.end,x.end)||(E(f),D(w.visibleRange));let _=e=>{e?(p(e),E(e)):(p(null),E(null))},S=f?vY(f,w.focusedDate):c&&vY(c.start,c.end),C=t=>{if(e.isReadOnly)return;let r=vz(vH(t,v,b),w.visibleRange.start,e.isDateUnavailable);if(r)if(f){let e=vY(f,r);e&&d({start:vq(e.start,null==c?void 0:c.start),end:vq(e.end,null==c?void 0:c.end)}),_(null)}else _(r)},[k,P]=(0,cu.useState)(!1),{isDateUnavailable:O}=e,R=(0,cu.useMemo)(()=>!!c&&!f&&(!!(O&&(O(c.start)||O(c.end)))||vF(c.start,s,l)||vF(c.end,s,l)),[O,c,f,s,l]),T=e.isInvalid||"invalid"===e.validationState||R;return{...w,value:c,setValue:d,anchorDate:f,setAnchorDate:_,highlightedRange:S,validationState:T?"invalid":null,isValueInvalid:T,selectFocusedDate(){C(w.focusedDate)},selectDate:C,highlightDate(e){f&&w.setFocusedDate(e)},isSelected:e=>!!(S&&e.compare(S.start)>=0&&0>=e.compare(S.end)&&!w.isCellDisabled(e)&&!w.isCellUnavailable(e)),isInvalid(e){var t,r;return w.isInvalid(e)||vF(e,null==(t=h.current)?void 0:t.start,null==(r=h.current)?void 0:r.end)},isDragging:k,setDragging:P}}({...e,locale:s,createCalendar:e.createCalendar||vL}),{calendarProps:u,prevButtonProps:c,nextButtonProps:d,errorMessageProps:f,title:p}=(r=e,n=t,o=yq(r,l),a=(0,cu.useRef)(!1),yQ(i=(0,cu.useRef)("u">typeof window?window:null),"pointerdown",e=>{a.current=0===e.width&&0===e.height}),yQ(i,"pointerup",e=>{if(a.current){a.current=!1;return}if(l.setDragging(!1),!l.anchorDate)return;let t=e.target;n.current&&n.current.contains(document.activeElement)&&(!n.current.contains(t)||!t.closest('button, [role="button"]'))&&l.selectFocusedDate()}),o.calendarProps.onBlur=e=>{n.current&&(e.relatedTarget&&n.current.contains(e.relatedTarget)||!l.anchorDate||l.selectFocusedDate())},yQ(n,"touchmove",e=>{l.isDragging&&e.preventDefault()},{passive:!1,capture:!0}),o),m=mI({...e,values:{state:l,isDisabled:e.isDisabled||!1,isInvalid:l.isValueInvalid},defaultClassName:"react-aria-RangeCalendar"});return cc().createElement("div",{...m,...u,ref:t,slot:e.slot||void 0,"data-disabled":e.isDisabled||void 0,"data-invalid":l.isValueInvalid||void 0},cc().createElement(m$,{values:[[gs,{slots:{previous:c,next:d}}],[gu,{"aria-hidden":!0,level:2,children:p}],[v1,l],[vQ,e],[gc,{slots:{errorMessage:f}}]]},cc().createElement(yX,null,cc().createElement("h2",null,u["aria-label"])),m.children,cc().createElement(yX,null,cc().createElement("button",{"aria-label":d["aria-label"],disabled:d.isDisabled,onClick:()=>l.focusNextPage(),tabIndex:-1}))))}),v3=(0,cu.createContext)(null),v6=(0,cu.forwardRef)(function(e,t){var r,n;let o=(0,cu.useContext)(v0),a=(0,cu.useContext)(v1),i=mM(vX),s=mM(vQ),l=null!=o?o:a,u=l.visibleRange.start;e.offset&&(u=u.add(e.offset));let c=null!=(r=null==i?void 0:i.firstDayOfWeek)?r:null==s?void 0:s.firstDayOfWeek,{gridProps:d,headerProps:f,weekDays:p,weeksInMonth:m}=function(e,t){let r,{startDate:n=t.visibleRange.start,endDate:o=t.visibleRange.end,firstDayOfWeek:a}=e,{direction:i}=gD(),s=yK(n,o,t.timeZone,!0),{ariaLabel:l,ariaLabelledBy:u}=yH.get(t),c=yY({"aria-label":[l,s].filter(Boolean).join(", "),"aria-labelledby":u}),d=yU({weekday:e.weekdayStyle||"narrow",timeZone:t.timeZone}),{locale:f}=gD(),p=(0,cu.useMemo)(()=>{let e=yE(ym(t.timeZone),f,a);return[...Array(7).keys()].map(r=>{let n=e.add({days:r}).toDate(t.timeZone);return d.format(n)})},[f,t.timeZone,d,a]),m=(r=n.calendar.getDaysInMonth(n),Math.ceil((yf(yb(n),f,a)+r)/7));return{gridProps:mj(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"===i?t.focusNextDay():t.focusPreviousDay();break;case"ArrowUp":e.preventDefault(),e.stopPropagation(),t.focusPreviousRow();break;case"ArrowRight":e.preventDefault(),e.stopPropagation(),"rtl"===i?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:m}}({startDate:u,endDate:yw(u),weekdayStyle:e.weekdayStyle,firstDayOfWeek:c},l);return cc().createElement(v3.Provider,{value:{headerProps:f,weekDays:p,startDate:u,weeksInMonth:m}},cc().createElement("table",{...mY(e),...d,ref:t,style:e.style,className:null!=(n=e.className)?n:"react-aria-CalendarGrid"},"function"!=typeof e.children?e.children:cc().createElement(cc().Fragment,null,cc().createElement(v5,null,e=>cc().createElement(v9,null,e)),cc().createElement(v8,null,e.children))))}),v5=(0,cu.forwardRef)(function(e,t){let{children:r,style:n,className:o}=e,{headerProps:a,weekDays:i}=(0,cu.useContext)(v3);return cc().createElement("thead",{...mY(e),...a,ref:t,style:n,className:o||"react-aria-CalendarGridHeader"},cc().createElement("tr",null,i.map((e,t)=>cc().cloneElement(r(e),{key:t}))))}),v9=(0,cu.forwardRef)(function(e,t){let{children:r,style:n,className:o}=e;return cc().createElement("th",{...mY(e),ref:t,style:n,className:o||"react-aria-CalendarHeaderCell"},r)}),v8=(0,cu.forwardRef)(function(e,t){let{children:r,style:n,className:o}=e,a=(0,cu.useContext)(v0),i=(0,cu.useContext)(v1),s=null!=a?a:i,{startDate:l,weeksInMonth:u}=(0,cu.useContext)(v3);return cc().createElement("tbody",{...mY(e),ref:t,style:n,className:o||"react-aria-CalendarGridBody"},[...Array(u).keys()].map(e=>cc().createElement("tr",{key:e},s.getDatesInWeek(e,l).map((e,t)=>e?cc().cloneElement(r(e),{key:t}):cc().createElement("td",{key:t})))))}),v7=(0,cu.forwardRef)(function({date:e,...t},r){var n,o,a;let i=(0,cu.useContext)(v0),s=(0,cu.useContext)(v1),l=null!=i?i:s,{startDate:u}=null!=(n=(0,cu.useContext)(v3))?n:{startDate:l.visibleRange.start},c=(0,cu.useRef)(null),{cellProps:d,buttonProps:f,...p}=function(e,t,r){var n;let o,{date:a,isDisabled:i}=e,{errorMessageId:s,selectedDateDescription:l}=yH.get(t),u=yj((n=g_)&&n.__esModule?n.default:n,"@react-aria/calendar"),c=yU({weekday:"long",day:"numeric",month:"long",year:"numeric",era:yz(a),timeZone:t.timeZone}),d=t.isSelected(a),f=t.isCellFocused(a);i=i||t.isCellDisabled(a);let p=t.isCellUnavailable(a),m=!i&&!p,h=t.isValueInvalid&&!!("highlightedRange"in t?!t.anchorDate&&t.highlightedRange&&a.compare(t.highlightedRange.start)>=0&&0>=a.compare(t.highlightedRange.end):t.value&&yl(t.value,a));h&&(d=!0),a=yB(a,yu);let g=(0,cu.useMemo)(()=>a.toDate(t.timeZone),[a,t.timeZone]),y=yl(a,ym(t.timeZone)),v=(0,cu.useMemo)(()=>{let e="";return"highlightedRange"in t&&t.value&&!t.anchorDate&&(yl(a,t.value.start)||yl(a,t.value.end))&&(e=l+", "),e+=c.format(g),y?e=u.format(d?"todayDateSelected":"todayDate",{date:e}):d&&(e=u.format("dateSelected",{date:e})),t.minValue&&yl(a,t.minValue)?e+=", "+u.format("minimumDate"):t.maxValue&&yl(a,t.maxValue)&&(e+=", "+u.format("maximumDate")),e},[c,g,u,d,y,a,t,l]),b="";"anchorDate"in t&&f&&!t.isReadOnly&&m&&(b=t.anchorDate?u.format("finishRangeSelectionPrompt"):u.format("startRangeSelectionPrompt"));let w=y2(b),E=(0,cu.useRef)(!1),x=(0,cu.useRef)(!1),D=(0,cu.useRef)(void 0),{pressProps:_,isPressed:S}=hj({shouldCancelOnPointerExit:"anchorDate"in t&&!!t.anchorDate,preventFocusOnPress:!0,isDisabled:!m||t.isReadOnly,onPressStart(e){if(t.isReadOnly)return void t.setFocusedDate(a);if("highlightedRange"in t&&!t.anchorDate&&("mouse"===e.pointerType||"touch"===e.pointerType)){if(t.highlightedRange&&!h){if(yl(a,t.highlightedRange.start)){t.setAnchorDate(t.highlightedRange.end),t.setFocusedDate(a),t.setDragging(!0),x.current=!0;return}else if(yl(a,t.highlightedRange.end)){t.setAnchorDate(t.highlightedRange.start),t.setFocusedDate(a),t.setDragging(!0),x.current=!0;return}}let r=()=>{t.setDragging(!0),D.current=void 0,t.selectDate(a),t.setFocusedDate(a),E.current=!0};"touch"===e.pointerType?D.current=setTimeout(r,200):r()}},onPressEnd(){x.current=!1,E.current=!1,clearTimeout(D.current),D.current=void 0},onPress(){"anchorDate"in t||t.isReadOnly||(t.selectDate(a),t.setFocusedDate(a))},onPressUp(e){if(!t.isReadOnly&&("anchorDate"in t&&D.current&&(t.selectDate(a),t.setFocusedDate(a)),"anchorDate"in t))if(x.current)t.setAnchorDate(a);else if(t.anchorDate&&!E.current)t.selectDate(a),t.setFocusedDate(a);else if("keyboard"!==e.pointerType||t.anchorDate)"virtual"===e.pointerType&&(t.selectDate(a),t.setFocusedDate(a));else{t.selectDate(a);let e=a.add({days:1});t.isInvalid(e)&&(e=a.subtract({days:1})),t.isInvalid(e)||t.setFocusedDate(e)}}});i||(o=yl(a,t.focusedDate)?0:-1),(0,cu.useEffect)(()=>{f&&r.current&&(m4(r.current),"pointer"!==hB&&document.activeElement===r.current&&y6(r.current,{containingElement:y5(r.current)}))},[f,r]);let C=yU({day:"numeric",timeZone:t.timeZone,calendar:a.calendar.identifier}),k=(0,cu.useMemo)(()=>C.formatToParts(g).find(e=>"day"===e.type).value,[C,g]);return{cellProps:{role:"gridcell","aria-disabled":!m||void 0,"aria-selected":d||void 0,"aria-invalid":h||void 0},buttonProps:mj(_,{onFocus(){i||t.setFocusedDate(a)},tabIndex:o,role:"button","aria-disabled":!m||void 0,"aria-label":v,"aria-invalid":h||void 0,"aria-describedby":[h?s:void 0,w["aria-describedby"]].filter(Boolean).join(" ")||void 0,onPointerEnter(e){"highlightDate"in t&&("touch"!==e.pointerType||t.isDragging)&&m&&t.highlightDate(a)},onPointerDown(e){"releasePointerCapture"in e.target&&e.target.releasePointerCapture(e.pointerId)},onContextMenu(e){e.preventDefault()}}),isPressed:S,isFocused:f,isSelected:d,isDisabled:i,isUnavailable:p,isOutsideVisibleRange:0>a.compare(t.visibleRange.start)||a.compare(t.visibleRange.end)>0,isInvalid:h,formattedDate:k}}({date:e},l,c),{hoverProps:m,isHovered:h}=gn({...t,isDisabled:p.isDisabled}),{focusProps:g,isFocusVisible:y}=h8();y&&(y=p.isFocused);let v=(o=u,a=yi(a=e,o.calendar),o=yb(o),a=yb(a),o.era!==a.era||o.year!==a.year||o.month!==a.month),b=!1,w=!1;"highlightedRange"in l&&l.highlightedRange&&(b=yl(e,l.highlightedRange.start),w=yl(e,l.highlightedRange.end));let E=mI({...t,defaultChildren:p.formattedDate,defaultClassName:"react-aria-CalendarCell",values:{date:e,isHovered:h,isOutsideMonth:v,isFocusVisible:y,isSelectionStart:b,isSelectionEnd:w,...p}}),x={"data-focused":p.isFocused||void 0,"data-hovered":h||void 0,"data-pressed":p.isPressed||void 0,"data-unavailable":p.isUnavailable||void 0,"data-disabled":p.isDisabled||void 0,"data-focus-visible":y||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":b||void 0,"data-selection-end":w||void 0,"data-invalid":p.isInvalid||void 0};return cc().createElement("td",{...d,ref:r},cc().createElement("div",{...mj(mY(t),f,g,m,x,E),ref:c}))}),be=(0,cu.createContext)({}),bt=(0,cu.forwardRef)(function(e,t){var r,n;[e,t]=mL(e,t,be);let{isDisabled:o,isInvalid:a,onHoverStart:i,onHoverChange:s,onHoverEnd:l,...u}=e,{hoverProps:c,isHovered:d}=gn({onHoverStart:i,onHoverChange:s,onHoverEnd:l,isDisabled:o}),{isFocused:f,isFocusVisible:p,focusProps:m}=h8({within:!0});null!=o||(o=!!e["aria-disabled"]&&"false"!==e["aria-disabled"]),null!=a||(a=!!e["aria-invalid"]&&"false"!==e["aria-invalid"]);let h=mI({...e,values:{isHovered:d,isFocusWithin:f,isFocusVisible:p,isDisabled:o,isInvalid:a},defaultClassName:"react-aria-Group"});return cc().createElement("div",{...mj(u,m,c),...h,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":a||void 0},h.children)}),br=(0,cu.createContext)({}),bn=ga(function(e,t){[e,t]=mL(e,t,br);let{hoverProps:r,isHovered:n}=gn(e),{isFocused:o,isFocusVisible:a,focusProps:i}=h8({isTextInput:!0,autoFocus:e.autoFocus}),s=!!e["aria-invalid"]&&"false"!==e["aria-invalid"],l=mI({...e,values:{isHovered:n,isFocused:o,isFocusVisible:a,isDisabled:e.disabled||!1,isInvalid:s},defaultClassName:"react-aria-Input"});return cc().createElement("input",{...mj((e=>{let{onHoverStart:t,onHoverChange:r,onHoverEnd:n,...o}=e;return o})(e),i,r),...l,ref:t,"data-focused":o||void 0,"data-disabled":e.disabled||void 0,"data-hovered":n||void 0,"data-focus-visible":a||void 0,"data-invalid":s||void 0})});var bo={};bo={"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 ba=cc().createContext(null),bi="react-aria-focus-scope-restore",bs=null;function bl(e){var t,r,n,o,a,i,s,l,u,c;let d,f,p,m,{children:h,contain:g,restoreFocus:y,autoFocus:v}=e,b=(0,cu.useRef)(null),w=(0,cu.useRef)(null),E=(0,cu.useRef)([]),{parentNode:x}=(0,cu.useContext)(ba)||{},D=(0,cu.useMemo)(()=>new bD({scopeRef:E}),[E]);my(()=>{let e=x||b_.root;if(b_.getTreeNode(e.scopeRef)&&bs&&!bp(bs,e.scopeRef)){let t=b_.getTreeNode(bs);t&&(e=t)}e.addChild(D),b_.addNode(D)},[D,x]),my(()=>{let e=b_.getTreeNode(E);e&&(e.contain=!!g)},[g]),my(()=>{var e;let t=null==(e=b.current)?void 0:e.nextSibling,r=[],n=e=>e.stopPropagation();for(;t&&t!==w.current;)r.push(t),t.addEventListener(bi,n),t=t.nextSibling;return E.current=r,()=>{for(let e of r)e.removeEventListener(bi,n)}},[h]),my(()=>{if(r||n)return;let e=t.current,o=m1(e?e[0]:void 0),a=e=>{let r=hS(e);bd(r,t.current)?bs=t:bf(r)||(bs=null)};return o.addEventListener("focusin",a,!1),null==e||e.forEach(e=>e.addEventListener("focusin",a,!1)),()=>{o.removeEventListener("focusin",a,!1),null==e||e.forEach(e=>e.removeEventListener("focusin",a,!1))}},[t=E,r=y,n=g]),o=E,a=g,d=(0,cu.useRef)(void 0),f=(0,cu.useRef)(void 0),my(()=>{let e=o.current;if(!a){f.current&&(cancelAnimationFrame(f.current),f.current=void 0);return}let t=m1(e?e[0]:void 0),r=e=>{if("Tab"!==e.key||e.altKey||e.ctrlKey||e.metaKey||!bc(o)||e.isComposing)return;let r=((e=document)=>e.activeElement)(t),n=o.current;if(!n||!bd(r,n))return;let a=bb(bu(n),{tabbable:!0},n);if(!r)return;a.currentNode=r;let i=e.shiftKey?a.previousNode():a.nextNode();i||(a.currentNode=e.shiftKey?n[n.length-1].nextElementSibling:n[0].previousElementSibling,i=e.shiftKey?a.previousNode():a.nextNode()),e.preventDefault(),i&&bm(i,!0)},n=e=>{(!bs||bp(bs,o))&&bd(hS(e),o.current)?(bs=o,d.current=hS(e)):bc(o)&&!bf(hS(e),o)?d.current?d.current.focus():bs&&bs.current&&bg(bs.current):bc(o)&&(d.current=hS(e))},i=e=>{f.current&&cancelAnimationFrame(f.current),f.current=requestAnimationFrame(()=>{let r=hB,n=("virtual"===r||null===r)&&hl()&&hs(),a=((e=document)=>e.activeElement)(t);if(!n&&a&&bc(o)&&!bf(a,o)){bs=o;let t=hS(e);if(t&&t.isConnected){var i;d.current=t,null==(i=d.current)||i.focus()}else bs.current&&bg(bs.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",i,!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",i,!1))}},[o,a]),my(()=>()=>{f.current&&cancelAnimationFrame(f.current)},[f]),i=E,s=y,l=g,p=(0,cu.useRef)("u">typeof document?((e=document)=>e.activeElement)(m1(i.current?i.current[0]:void 0)):null),my(()=>{let e=i.current,t=m1(e?e[0]:void 0);if(!s||l)return;let r=()=>{(!bs||bp(bs,i))&&bd(((e=document)=>e.activeElement)(t),i.current)&&(bs=i)};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))}},[i,l]),my(()=>{let e=m1(i.current?i.current[0]:void 0);if(!s)return;let t=t=>{if("Tab"!==t.key||t.altKey||t.ctrlKey||t.metaKey||!bc(i)||t.isComposing)return;let r=e.activeElement;if(!bf(r,i)||!by(i))return;let n=b_.getTreeNode(i);if(!n)return;let o=n.nodeToRestore,a=bb(e.body,{tabbable:!0});a.currentNode=r;let s=t.shiftKey?a.previousNode():a.nextNode();if(o&&o.isConnected&&o!==e.body||(o=void 0,n.nodeToRestore=void 0),(!s||!bf(s,i))&&o){a.currentNode=o;do s=t.shiftKey?a.previousNode():a.nextNode();while(bf(s,i));(t.preventDefault(),t.stopPropagation(),s)?bm(s,!0):bf(o)?bm(o,!0):r.blur()}};return l||e.addEventListener("keydown",t,!0),()=>{l||e.removeEventListener("keydown",t,!0)}},[i,s,l]),my(()=>{var e;let t=m1(i.current?i.current[0]:void 0);if(!s)return;let r=b_.getTreeNode(i);if(r)return r.nodeToRestore=null!=(e=p.current)?e:void 0,()=>{let e=b_.getTreeNode(i);if(!e)return;let r=e.nodeToRestore,n=((e=document)=>e.activeElement)(t);if(s&&r&&(n&&bf(n,i)||n===t.body&&by(i))){let e=b_.clone();requestAnimationFrame(()=>{if(t.activeElement===t.body){let t=e.getTreeNode(i);for(;t;){if(t.nodeToRestore&&t.nodeToRestore.isConnected)return void bv(t.nodeToRestore);t=t.parent}for(t=e.getTreeNode(i);t;){if(t.scopeRef&&t.scopeRef.current&&b_.getTreeNode(t.scopeRef))return void bv(bh(t.scopeRef.current,!0));t=t.parent}}})}}},[i,s]),u=E,c=v,m=cc().useRef(c),(0,cu.useEffect)(()=>{m.current&&(bs=u,!bd(((e=document)=>e.activeElement)(m1(u.current?u.current[0]:void 0)),bs.current)&&u.current&&bg(u.current)),m.current=!1},[u]),(0,cu.useEffect)(()=>{let e=((e=document)=>e.activeElement)(m1(E.current?E.current[0]:void 0)),t=null;if(bd(e,E.current)){for(let r of b_.traverse())r.scopeRef&&bd(e,r.scopeRef.current)&&(t=r);t===b_.getTreeNode(E)&&(bs=t.scopeRef)}},[E]),my(()=>()=>{var e,t,r;let n=null!=(r=null==(t=b_.getTreeNode(E))||null==(e=t.parent)?void 0:e.scopeRef)?r:null;(E===bs||bp(E,bs))&&(!n||b_.getTreeNode(n))&&(bs=n),b_.removeTreeNode(E)},[E]);let _=(0,cu.useMemo)(()=>{var e;return e=E,{focusNext(t={}){var r;let n=e.current,{from:o,tabbable:a,wrap:i,accept:s}=t,l=o||((e=document)=>e.activeElement)(m1(null!=(r=n[0])?r:void 0)),u=n[0].previousElementSibling,c=bb(bu(n),{tabbable:a,accept:s},n);c.currentNode=bd(l,n)?l:u;let d=c.nextNode();return!d&&i&&(c.currentNode=u,d=c.nextNode()),d&&bm(d,!0),d},focusPrevious(t={}){var r;let n=e.current,{from:o,tabbable:a,wrap:i,accept:s}=t,l=o||((e=document)=>e.activeElement)(m1(null!=(r=n[0])?r:void 0)),u=n[n.length-1].nextElementSibling,c=bb(bu(n),{tabbable:a,accept:s},n);c.currentNode=bd(l,n)?l:u;let d=c.previousNode();return!d&&i&&(c.currentNode=u,d=c.previousNode()),d&&bm(d,!0),d},focusFirst(t={}){let r=e.current,{tabbable:n,accept:o}=t,a=bb(bu(r),{tabbable:n,accept:o},r);a.currentNode=r[0].previousElementSibling;let i=a.nextNode();return i&&bm(i,!0),i},focusLast(t={}){let r=e.current,{tabbable:n,accept:o}=t,a=bb(bu(r),{tabbable:n,accept:o},r);a.currentNode=r[r.length-1].nextElementSibling;let i=a.previousNode();return i&&bm(i,!0),i}}},[]),S=(0,cu.useMemo)(()=>({focusManager:_,parentNode:D}),[D,_]);return cc().createElement(ba.Provider,{value:S},cc().createElement("span",{"data-focus-scope-start":!0,hidden:!0,ref:b}),h,cc().createElement("span",{"data-focus-scope-end":!0,hidden:!0,ref:w}))}function bu(e){return e[0].parentElement}function bc(e){let t=b_.getTreeNode(bs);for(;t&&t.scopeRef!==e;){if(t.contain)return!1;t=t.parent}return!0}function bd(e,t){return!!e&&!!t&&t.some(t=>t.contains(e))}function bf(e,t=null){if(e instanceof Element&&e.closest("[data-react-aria-top-layer]"))return!0;for(let{scopeRef:r}of b_.traverse(b_.getTreeNode(t)))if(r&&bd(e,r.current))return!0;return!1}function bp(e,t){var r;let n=null==(r=b_.getTreeNode(t))?void 0:r.parent;for(;n;){if(n.scopeRef===e)return!0;n=n.parent}return!1}function bm(e,t=!1){if(null==e||t){if(null!=e)try{e.focus()}catch{}}else try{h2(e)}catch{}}function bh(e,t=!0){let r=e[0].previousElementSibling,n=bu(e),o=bb(n,{tabbable:t},e);o.currentNode=r;let a=o.nextNode();return t&&!a&&((o=bb(n=bu(e),{tabbable:!1},e)).currentNode=r,a=o.nextNode()),a}function bg(e,t=!0){bm(bh(e,t))}function by(e){let t=b_.getTreeNode(bs);for(;t&&t.scopeRef!==e;){if(t.nodeToRestore)return!1;t=t.parent}return(null==t?void 0:t.scopeRef)===e}function bv(e){e.dispatchEvent(new CustomEvent(bi,{bubbles:!0,cancelable:!0}))&&bm(e)}function bb(e,t,r){var n,o,a;let i=(null==t?void 0:t.tabbable)?m0:mQ,s=m1((null==e?void 0:e.nodeType)===Node.ELEMENT_NODE?e:null),l=(n=e||s,o=NodeFilter.SHOW_ELEMENT,a={acceptNode(e){var n;return(null==t||null==(n=t.from)?void 0:n.contains(e))?NodeFilter.FILTER_REJECT:i(e)&&function e(t,r){return"#comment"!==t.nodeName&&function(e){let t=m2(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||bd(e,r))&&(!(null==t?void 0:t.accept)||t.accept(e))?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}},s.createTreeWalker(n,o,a));return(null==t?void 0:t.from)&&(l.currentNode=t.from),l}function bw(e,t={}){return{focusNext(r={}){let n=e.current;if(!n)return null;let{from:o,tabbable:a=t.tabbable,wrap:i=t.wrap,accept:s=t.accept}=r,l=o||((e=document)=>e.activeElement)(m1(n)),u=bb(n,{tabbable:a,accept:s});n.contains(l)&&(u.currentNode=l);let c=u.nextNode();return!c&&i&&(u.currentNode=n,c=u.nextNode()),c&&bm(c,!0),c},focusPrevious(r=t){let n=e.current;if(!n)return null;let{from:o,tabbable:a=t.tabbable,wrap:i=t.wrap,accept:s=t.accept}=r,l=o||((e=document)=>e.activeElement)(m1(n)),u=bb(n,{tabbable:a,accept:s});if(n.contains(l))u.currentNode=l;else{let e=bE(u);return e&&bm(e,!0),null!=e?e:null}let c=u.previousNode();if(!c&&i){u.currentNode=n;let e=bE(u);if(!e)return null;c=e}return c&&bm(c,!0),null!=c?c:null},focusFirst(r=t){let n=e.current;if(!n)return null;let{tabbable:o=t.tabbable,accept:a=t.accept}=r,i=bb(n,{tabbable:o,accept:a}).nextNode();return i&&bm(i,!0),i},focusLast(r=t){let n=e.current;if(!n)return null;let{tabbable:o=t.tabbable,accept:a=t.accept}=r,i=bE(bb(n,{tabbable:o,accept:a}));return i&&bm(i,!0),null!=i?i:null}}}function bE(e){let t,r;do(t=e.lastChild())&&(r=t);while(t);return r}class bx{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 bD({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&&bd(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 bx;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 bD({scopeRef:null}),this.fastMap.set(null,this.root)}}class bD{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 b_=new bx;function bS(e,t,r){let{direction:n}=gD(),o=(0,cu.useMemo)(()=>bw(t),[t]),a=()=>{var e;if(!t.current)return;let r=null==(e=window.event)?void 0:e.target,n=bb(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:i}=hj({preventFocusOnPress:!0,allowTextSelectionOnPress:!0,onPressStart(e){"mouse"===e.pointerType&&a()},onPress(e){"mouse"!==e.pointerType&&a()}});return mj(i,{onKeyDown:a=>{if(a.currentTarget.contains(a.target)&&(a.altKey&&("ArrowDown"===a.key||"ArrowUp"===a.key)&&"setOpen"in e&&(a.preventDefault(),a.stopPropagation(),e.setOpen(!0)),!r))switch(a.key){case"ArrowLeft":if(a.preventDefault(),a.stopPropagation(),"rtl"===n){if(t.current){let e=a.target,r=bC(t.current,e.getBoundingClientRect().left,-1);r&&r.focus()}}else o.focusPrevious();break;case"ArrowRight":if(a.preventDefault(),a.stopPropagation(),"rtl"===n){if(t.current){let e=a.target,r=bC(t.current,e.getBoundingClientRect().left,1);r&&r.focus()}}else o.focusNext()}}})}function bC(e,t,r){let n=bb(e,{tabbable:!0}),o=n.nextNode(),a=null,i=1/0;for(;o;){let e=o.getBoundingClientRect().left-t,s=Math.abs(e);Math.sign(e)===r&&s<i&&(a=o,i=s),o=n.nextNode()}return a}function bk(e,t,r){let n=(0,cu.useRef)(t),o=mv(()=>{r&&r(n.current)});(0,cu.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 bP(e){let{description:t,errorMessage:r,isInvalid:n,validationState:o}=e,{labelProps:a,fieldProps:i}=function(e){let{id:t,label:r,"aria-labelledby":n,"aria-label":o,labelElementType:a="label"}=e;t=mR(t);let i=mR(),s={};return r&&(n=n?`${i} ${n}`:i,s={id:i,htmlFor:"label"===a?t:void 0}),{labelProps:s,fieldProps:yY({id:t,"aria-label":o,"aria-labelledby":n})}}(e),s=mT([!!t,!!r,n,o]),l=mT([!!t,!!r,n,o]);return{labelProps:a,fieldProps:i=mj(i,{"aria-describedby":[s,l,e["aria-describedby"]].filter(Boolean).join(" ")||void 0}),descriptionProps:{id:s},errorMessageProps:{id:l}}}function bO(e,t,r){let{validationBehavior:n,focus:o}=e;my(()=>{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 a=mv(()=>{t.resetValidation()}),i=mv(e=>{var n,a;t.displayValidation.isInvalid||t.commitValidation();let i=null==r||null==(n=r.current)?void 0:n.form;!e.defaultPrevented&&r&&i&&function(e){for(let t=0;t<e.elements.length;t++){let r=e.elements[t];if(!r.validity.valid)return r}return null}(i)===r.current&&(o?o():null==(a=r.current)||a.focus(),hB="keyboard",hK("keyboard",null)),e.preventDefault()}),s=mv(()=>{t.commitValidation()});(0,cu.useEffect)(()=>{let e=null==r?void 0:r.current;if(!e)return;let t=e.form;return e.addEventListener("invalid",i),e.addEventListener("change",s),null==t||t.addEventListener("reset",a),()=>{e.removeEventListener("invalid",i),e.removeEventListener("change",s),null==t||t.removeEventListener("reset",a)}},[r,i,s,a,n])}let bR=new WeakMap,bT="__role_"+Date.now(),bN="__focusManager_"+Date.now();function bj(e,t,r){var n,o;let a,{isInvalid:i,validationErrors:s,validationDetails:l}=t.displayValidation,{labelProps:u,fieldProps:c,descriptionProps:d,errorMessageProps:f}=bP({...e,labelElementType:"span",isInvalid:i,errorMessage:e.errorMessage||s}),p=(0,cu.useRef)(null),{focusWithinProps:m}=h9({...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}),h=yj((o=bo)&&o.__esModule?o.default:o,"@react-aria/datepicker"),g="hour"===t.maxGranularity?"selectedTimeDescription":"selectedDateDescription",y="hour"===t.maxGranularity?"time":"date",v=y2(t.value?h.format(g,{[y]:t.formatValue({month:"long"})}):""),b="presentation"===e[bT]?c["aria-describedby"]:[v["aria-describedby"],c["aria-describedby"]].filter(Boolean).join(" ")||void 0,w=e[bN],E=(0,cu.useMemo)(()=>w||bw(r),[w,r]),x=bS(t,r,"presentation"===e[bT]);bR.set(t,{ariaLabel:e["aria-label"],ariaLabelledBy:[u.id,e["aria-labelledby"]].filter(Boolean).join(" ")||void 0,ariaDescribedBy:b,focusManager:E});let D=(0,cu.useRef)(e.autoFocus);a="presentation"===e[bT]?{role:"presentation"}:mj(c,{role:"group","aria-disabled":e.isDisabled||void 0,"aria-describedby":b}),(0,cu.useEffect)(()=>{D.current&&E.focusFirst(),D.current=!1},[E]),bk(e.inputRef,t.value,t.setValue),bO({...e,focus(){E.focusFirst()}},t,e.inputRef);let _={type:"hidden",name:e.name,value:(null==(n=t.value)?void 0:n.toString())||"",disabled:e.isDisabled};"native"===e.validationBehavior&&(_.type="text",_.hidden=!0,_.required=e.isRequired,_.onChange=()=>{});let S=mY(e);return{labelProps:{...u,onClick:()=>{E.focusFirst()}},fieldProps:mj(S,a,x,m,{onKeyDown(t){e.onKeyDown&&e.onKeyDown(t)},onKeyUp(t){e.onKeyUp&&e.onKeyUp(t)},style:{unicodeBidi:"isolate"}}),inputProps:_,descriptionProps:d,errorMessageProps:f,isInvalid:i,validationErrors:s,validationDetails:l}}var bA={};bA={"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 b$={badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valueMissing:!1,valid:!0},bI={...b$,customError:!0,valid:!1},bM={isInvalid:!1,validationDetails:b$,validationErrors:[]},bL=(0,cu.createContext)({}),bF="__formValidationState"+Date.now();function bB(e){if(e[bF]){let{realtimeValidation:t,displayValidation:r,updateValidation:n,resetValidation:o,commitValidation:a}=e[bF];return{realtimeValidation:t,displayValidation:r,updateValidation:n,resetValidation:o,commitValidation:a}}return function(e){let{isInvalid:t,validationState:r,name:n,value:o,builtinValidation:a,validate:i,validationBehavior:s="aria"}=e;r&&(t||(t="invalid"===r));let l=void 0!==t?{isInvalid:t,validationErrors:[],validationDetails:bI}:null,u=(0,cu.useMemo)(()=>i&&null!=o?bV(function(e,t){if("function"==typeof e){let r=e(t);if(r&&"boolean"!=typeof r)return bU(r)}return[]}(i,o)):null,[i,o]);(null==a?void 0:a.validationDetails.valid)&&(a=void 0);let c=(0,cu.useContext)(bL),d=(0,cu.useMemo)(()=>n?Array.isArray(n)?n.flatMap(e=>bU(c[e])):bU(c[n]):[],[c,n]),[f,p]=(0,cu.useState)(c),[m,h]=(0,cu.useState)(!1);c!==f&&(p(c),h(!1));let g=(0,cu.useMemo)(()=>bV(m?[]:d),[m,d]),y=(0,cu.useRef)(bM),[v,b]=(0,cu.useState)(bM),w=(0,cu.useRef)(bM),[E,x]=(0,cu.useState)(!1);return(0,cu.useEffect)(()=>{if(!E)return;x(!1);let e=u||a||y.current;bW(e,w.current)||(w.current=e,b(e))}),{realtimeValidation:l||g||u||a||bM,displayValidation:"native"===s?l||g||v:l||g||u||a||v,updateValidation(e){"aria"!==s||bW(v,e)?y.current=e:b(e)},resetValidation(){bW(bM,w.current)||(w.current=bM,b(bM)),"native"===s&&x(!1),h(!0)},commitValidation(){"native"===s&&x(!0),h(!0)}}}(e)}function bU(e){return e?Array.isArray(e)?e:[e]:[]}function bV(e){return e.length?{isInvalid:!0,validationErrors:e,validationDetails:bI}:null}function bW(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 bH(...e){let t=new Set,r=!1,n={...b$};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 bz=new yk((en=bA)&&en.__esModule?en.default:en);function bK(){return"u">typeof navigator&&(navigator.language||navigator.userLanguage)||"en-US"}function bG(e,t,r,n,o){let a=null!=e&&null!=r&&e.compare(r)>0,i=null!=e&&null!=t&&0>e.compare(t),s=null!=e&&(null==n?void 0:n(e))||!1,l=a||i||s,u=[];if(l){let e=bK(),n=new yR(e,yk.getGlobalDictionaryForPackage("@react-stately/datepicker")||bz),l=new y$(e,bq({},o)),c=l.resolvedOptions().timeZone;i&&null!=t&&u.push(n.format("rangeUnderflow",{minValue:l.format(t.toDate(c))})),a&&null!=r&&u.push(n.format("rangeOverflow",{maxValue:l.format(r.toDate(c))})),s&&u.push(n.format("unavailableDate"))}return{isInvalid:l,validationErrors:u,validationDetails:{badInput:s,customError:!1,patternMismatch:!1,rangeOverflow:a,rangeUnderflow:i,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valueMissing:!1,valid:!l}}}let bZ={year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"2-digit",second:"2-digit"},bY={year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"};function bq(e,t){var r;e={...t.shouldForceLeadingZeros?bY:bZ,...e};let n=t.granularity||"minute",o=Object.keys(e),a=o.indexOf(null!=(r=t.maxGranularity)?r:"year");a<0&&(a=0);let i=o.indexOf(n);if(i<0&&(i=2),a>i)throw Error("maxGranularity must be greater than granularity");let s=o.slice(a,i+1).reduce((t,r)=>(t[r]=e[r],t),{});return null!=t.hourCycle&&(s.hour12=12===t.hourCycle),s.timeZone=t.timeZone||"UTC",("hour"===n||"minute"===n||"second"===n)&&t.timeZone&&!t.hideTimeZone&&(s.timeZoneName="short"),t.showEra&&0===a&&(s.era="short"),s}function bJ(e){return e&&"hour"in e?e:new g1}function bX(e,t){return null===e?null:e?yi(e,t):void 0}function bQ(e,t,r,n){if(e)return bX(e,r);let o=yi(yp(null!=n?n:yv()).set({hour:0,minute:0,second:0,millisecond:0}),r);return"year"===t||"month"===t||"day"===t?yo(o):n?o:ya(o)}function b0(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,a]=(0,cu.useState)([n,r]);return e&&(o[0]!==n||o[1]!==r)&&a([n,r]),t||(t=e?n:o[0]),[t,e?r:o[1]]}let b1=new yk({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"),b2={year:!0,month:!0,day:!0,hour:!0,minute:!0,second:!0,dayPeriod:!0,era:!0},b4={year:5,month:2,day:7,hour:2,minute:15,second:15},b3={dayperiod:"dayPeriod"};function b6(e){var t,r;let{locale:n,createCalendar:o,hideTimeZone:a,isDisabled:i=!1,isReadOnly:s=!1,isRequired:l=!1,minValue:u,maxValue:c,isDateUnavailable:d}=e,f=e.value||e.defaultValue||e.placeholderValue||null,[p,m]=b0(f,e.granularity),h=m||"UTC";if(f&&!(p in f))throw Error("Invalid granularity "+p+" for value "+f.toString());let g=(0,cu.useMemo)(()=>new y$(n),[n]),y=(0,cu.useMemo)(()=>o(g.resolvedOptions().calendar),[o,g]),[v,b]=vK(e.value,null!=(t=e.defaultValue)?t:null,e.onChange),w=(0,cu.useMemo)(()=>{var e;return null!=(e=bX(v,y))?e:null},[v,y]),[E,x]=(0,cu.useState)(()=>bQ(e.placeholderValue,p,y,m)),D="gregory"===y.identifier&&"BC"===(w||E).era,_=(0,cu.useMemo)(()=>{var t;return{granularity:p,maxGranularity:null!=(t=e.maxGranularity)?t:"year",timeZone:m,hideTimeZone:a,hourCycle:e.hourCycle,showEra:D,shouldForceLeadingZeros:e.shouldForceLeadingZeros}},[e.maxGranularity,p,e.hourCycle,e.shouldForceLeadingZeros,m,a,D]),S=(0,cu.useMemo)(()=>bq({},_),[_]),C=(0,cu.useMemo)(()=>new y$(n,S),[n,S]),k=(0,cu.useMemo)(()=>C.resolvedOptions(),[C]),P=(0,cu.useMemo)(()=>C.formatToParts(new Date).filter(e=>b2[e.type]).reduce((e,t)=>(e[t.type]=!0,e),{}),[C]),[O,R]=(0,cu.useState)(()=>e.value||e.defaultValue?{...P}:{}),T=(0,cu.useRef)(null),N=(0,cu.useRef)(y);(0,cu.useEffect)(()=>{yc(y,N.current)||(N.current=y,x(t=>Object.keys(O).length>0?yi(t,y):bQ(e.placeholderValue,p,y,m)))},[y,p,O,m,e.placeholderValue]),v&&Object.keys(O).length<Object.keys(P).length&&R(O={...P}),null==v&&Object.keys(O).length===Object.keys(P).length&&(R(O={}),x(bQ(e.placeholderValue,p,y,m)));let j=w&&Object.keys(O).length>=Object.keys(P).length?w:E,A=t=>{if(e.isDisabled||e.isReadOnly)return;let r=Object.keys(O),n=Object.keys(P);null==t?(b(null),x(bQ(e.placeholderValue,p,y,m)),R({})):r.length>=n.length||r.length===n.length-1&&P.dayPeriod&&!O.dayPeriod&&"dayPeriod"!==T.current?b(t=yi(t,(null==f?void 0:f.calendar)||new gT)):x(t),T.current=null},$=(0,cu.useMemo)(()=>j.toDate(h),[j,h]),I=(0,cu.useMemo)(()=>(function(e,t,r,n,o,a,i,s){let l=["hour","minute","second"],u=r.formatToParts(e),c=[];for(let e of u){var d,f;let r=b2[e.type];"era"===e.type&&1===a.getEras().length&&(r=!1);let u=b2[e.type]&&!t[e.type],p=b2[e.type]?(d=e.type,f=e.value,"era"===d||"dayPeriod"===d?f:"year"===d||"month"===d||"day"===d?b1.getStringForLocale(d,i):"––"):null,m={type:b3[e.type]||e.type,text:u?p:e.value,...b5(o,e.type,n),isPlaceholder:u,placeholder:p,isEditable:r};"hour"===e.type?(c.push({type:"literal",text:"",...b5(o,"literal",n),isPlaceholder:!1,placeholder:"",isEditable:!1}),c.push(m),e.type===s&&c.push({type:"literal",text:"",...b5(o,"literal",n),isPlaceholder:!1,placeholder:"",isEditable:!1})):l.includes(e.type)&&e.type===s?(c.push(m),c.push({type:"literal",text:"",...b5(o,"literal",n),isPlaceholder:!1,placeholder:"",isEditable:!1})):c.push(m)}return c})($,O,C,k,j,y,n,p),[$,O,C,k,j,y,n,p]);P.era&&O.year&&!O.era?(O.era=!0,R({...O})):!P.era&&O.era&&(delete O.era,R({...O}));let M=e=>{O[e]=!0,"year"===e&&P.era&&(O.era=!0),R({...O})},L=(e,t)=>{if(O[e])A(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)}(j,e,t,k));else{M(e);let t=Object.keys(O),r=Object.keys(P);(t.length>=r.length||t.length===r.length-1&&P.dayPeriod&&!O.dayPeriod)&&A(j)}},F=(0,cu.useMemo)(()=>bG(v,u,c,d,_),[v,u,c,d,_]),B=bB({...e,value:v,builtinValidation:F}),U=B.displayValidation.isInvalid,V=e.validationState||(U?"invalid":null);return{...B,value:w,dateValue:$,calendar:y,setValue:A,segments:I,dateFormatter:C,validationState:V,isInvalid:U,granularity:p,maxGranularity:null!=(r=e.maxGranularity)?r:"year",isDisabled:i,isReadOnly:s,isRequired:l,increment(e){L(e,1)},decrement(e){L(e,-1)},incrementPage(e){L(e,b4[e]||1)},decrementPage(e){L(e,-(b4[e]||1))},setSegment(e,t){M(e),A(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)}(j,e,t,k))},confirmPlaceholder(){if(e.isDisabled||e.isReadOnly)return;let t=Object.keys(O),r=Object.keys(P);t.length===r.length-1&&P.dayPeriod&&!O.dayPeriod&&(R(O={...P}),A(j.copy()))},clearSegment(t){delete O[t],T.current=t,R({...O});let r=bQ(e.placeholderValue,p,y,m),n=j;if("dayPeriod"===t&&"hour"in j&&"hour"in r){let e=j.hour>=12,t=r.hour>=12;e&&!t?n=j.set({hour:j.hour-12}):!e&&t&&(n=j.set({hour:j.hour+12}))}else"hour"===t&&"hour"in j&&j.hour>=12&&O.dayPeriod?n=j.set({hour:r.hour+12}):t in j&&(n=j.set({[t]:r[t]}));b(null),A(n)},formatValue:e=>w?new y$(n,bq(e,_)).format($):"",getDateFormatter:(e,t)=>new y$(e,bq({},{..._,...t}))}}function b5(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 b9=(0,cu.createContext)(null),b8=(0,cu.createContext)(null),b7=(0,cu.createContext)(null),we=(0,cu.forwardRef)(function(e,t){let r=(0,cu.useContext)(b8),n=(0,cu.useContext)(b7);return r||n?cc().createElement(wr,{...e,ref:t}):cc().createElement(wt,{...e,ref:t})}),wt=(0,cu.forwardRef)((e,t)=>{let[r,n]=mL({slot:e.slot},t,b9),{locale:o}=gD(),a=b6({...r,locale:o,createCalendar:vL}),i=(0,cu.useRef)(null),{fieldProps:s,inputProps:l}=bj({...r,inputRef:i},a,n);return cc().createElement(m$,{values:[[b8,a],[br,{...l,ref:i}],[be,{...s,ref:n,isInvalid:a.isInvalid,isDisabled:a.isDisabled}]]},cc().createElement(wr,e))}),wr=(0,cu.forwardRef)((e,t)=>{let{className:r,children:n}=e,o=(0,cu.useContext)(b8),a=(0,cu.useContext)(b7),i=null!=o?o:a;return cc().createElement(cc().Fragment,null,cc().createElement(bt,{...e,ref:t,slot:e.slot||void 0,className:null!=r?r:"react-aria-DateInput",isInvalid:i.isInvalid,isDisabled:i.isDisabled},i.segments.map((e,t)=>(0,cu.cloneElement)(n(e),{key:t}))),cc().createElement(bn,null))}),wn=(0,cu.createContext)({});function wo({children:e}){let t=(0,cu.useMemo)(()=>({register:()=>{}}),[]);return cc().createElement(hv.Provider,{value:t},e)}cc().forwardRef(({children:e,...t},r)=>{let n=(0,cu.useRef)(!1),o=(0,cu.useContext)(hv);r=mh(r||(null==o?void 0:o.ref));let a=mj(o||{},{...t,ref:r,register(){n.current=!0,o&&o.register()}});return hx(o,r),(0,cu.useEffect)(()=>{n.current||(n.current=!0)},[]),cc().createElement(hv.Provider,{value:a},e)});let wa=cc().createContext(null);function wi(e){var t;let r=mk(),{portalContainer:n=r?null:document.body,isExiting:o}=e,[a,i]=(0,cu.useState)(!1),s=(0,cu.useMemo)(()=>({contain:a,setContain:i}),[a,i]),{getContainer:l}=null!=(t=(0,cu.useContext)(wn))?t:{};if(!e.portalContainer&&l&&(n=l()),!n)return null;let u=e.children;return e.disableFocusManagement||(u=cc().createElement(bl,{restoreFocus:!0,contain:(e.shouldContainFocus||a)&&!o},u)),u=cc().createElement(wa.Provider,{value:s},cc().createElement(wo,null,u)),hO().createPortal(u,n)}let ws=(0,cu.createContext)(null),wl=(0,cu.createContext)(null),wu=(0,cu.forwardRef)(function(e,t){let r=e["aria-labelledby"];[e,t]=mL(e,t,ws);let{dialogProps:n,titleProps:o}=function(e,t){let r,n,{role:o="dialog"}=e,a=mT();a=e["aria-label"]?void 0:a;let i=(0,cu.useRef)(!1);return(0,cu.useEffect)(()=>{if(t.current&&!t.current.contains(document.activeElement)){h2(t.current);let e=setTimeout(()=>{document.activeElement===t.current&&(i.current=!0,t.current&&(t.current.blur(),h2(t.current)),i.current=!1)},500);return()=>{clearTimeout(e)}}},[t]),my(()=>{null==n||n(!0)},[n=null==(r=(0,cu.useContext)(wa))?void 0:r.setContain]),{dialogProps:{...mY(e,{labelable:!0}),role:o,tabIndex:-1,"aria-labelledby":e["aria-labelledby"]||a,onBlur:e=>{i.current&&e.stopPropagation()}},titleProps:{id:a}}}({...e,"aria-labelledby":r},t),a=(0,cu.useContext)(wl);n["aria-label"]||n["aria-labelledby"]||e["aria-labelledby"]&&(n["aria-labelledby"]=e["aria-labelledby"]);let i=mI({defaultClassName:"react-aria-Dialog",className:e.className,style:e.style,children:e.children,values:{close:(null==a?void 0:a.close)||(()=>{})}});return cc().createElement("section",{...mY(e),...n,...i,ref:t,slot:e.slot||void 0},cc().createElement(m$,{values:[[gu,{slots:{[mA]:{},title:{...o,level:2}}}],[gs,{slots:{[mA]:{},close:{onPress:()=>null==a?void 0:a.close()}}}]]},i.children))}),wc=(0,cu.createContext)(null),wd=(0,cu.forwardRef)(function(e,t){let r=(0,cu.useContext)(wc);return(null==r?void 0:r.isInvalid)?cc().createElement(wf,{...e,ref:t}):null}),wf=(0,cu.forwardRef)((e,t)=>{let r=(0,cu.useContext)(wc),n=mY(e),o=mI({...e,defaultClassName:"react-aria-FieldError",defaultChildren:0===r.validationErrors.length?void 0:r.validationErrors.join(" "),values:r});return null==o.children?null:cc().createElement(gd,{slot:"errorMessage",...n,...o,ref:t})}),wp=(0,cu.createContext)(null),wm=(0,cu.createContext)({}),wh=ga(function(e,t){[e,t]=mL(e,t,wm);let{elementType:r="label",...n}=e;return cc().createElement(r,{className:"react-aria-Label",...n,ref:t})}),wg=(0,cu.createContext)({placement:"bottom"}),wy=new WeakMap,wv=[];function wb(e,t=-1/0,r=1/0){return Math.min(Math.max(e,t),r)}function ww(e,t){let r=e,n=t.toString(),o=n.indexOf("."),a=o>=0?n.length-o:0;if(a>0){let e=Math.pow(10,a);r=Math.round(r*e)/e}return r}function wE(e,t,r,n){t=Number(t),r=Number(r);let o=(e-(isNaN(t)?0:t))%n,a=ww(2*Math.abs(o)>=n?e+Math.sign(o)*(n-Math.abs(o)):e-o,n);return isNaN(t)?!isNaN(r)&&a>r&&(a=Math.floor(ww(r/n,n))*n):a<t?a=t:!isNaN(r)&&a>r&&(a=t+Math.floor(ww((r-t)/n,n))*n),a=ww(a,n)}let wx={top:"top",bottom:"top",left:"left",right:"left"},wD={top:"bottom",bottom:"top",left:"right",right:"left"},w_={top:"left",left:"top"},wS={top:"height",left:"width"},wC={width:"totalWidth",height:"totalHeight"},wk={},wP="u">typeof document?window.visualViewport:null;function wO(e){var t,r,n,o,a;let i=0,s=0,l=0,u=0,c=0,d=0,f={},p=(null!=(t=null==wP?void 0:wP.scale)?t:1)>1;if("BODY"===e.tagName){let t=document.documentElement;l=t.clientWidth,u=t.clientHeight,i=null!=(r=null==wP?void 0:wP.width)?r:l,s=null!=(n=null==wP?void 0:wP.height)?n:u,f.top=t.scrollTop||e.scrollTop,f.left=t.scrollLeft||e.scrollLeft,wP&&(c=wP.offsetTop,d=wP.offsetLeft)}else({width:i,height:s,top:c,left:d}=wA(e)),f.top=e.scrollTop,f.left=e.scrollLeft,l=i,u=s;return hi()&&("BODY"===e.tagName||"HTML"===e.tagName)&&p&&(f.top=0,f.left=0,c=null!=(o=null==wP?void 0:wP.pageTop)?o:0,d=null!=(a=null==wP?void 0:wP.pageLeft)?a:0),{width:i,height:s,totalWidth:l,totalHeight:u,scroll:f,top:c,left:d}}function wR(e,t,r,n,o,a,i){var s;let l=null!=(s=o.scroll[e])?s:0,u=n[wS[e]],c=n.scroll[wx[e]]+a,d=u+n.scroll[wx[e]]-a,f=t-l+i[e]-n[wx[e]],p=t-l+r+i[e]-n[wx[e]];return f<c?c-f:p>d?Math.max(d-p,c-f):0}function wT(e){if(wk[e])return wk[e];let[t,r]=e.split(" "),n=wx[t]||"right",o=w_[n];wx[r]||(r="center");let a=wS[n],i=wS[o];return wk[e]={placement:t,crossPlacement:r,axis:n,crossAxis:o,size:a,crossSize:i},wk[e]}function wN(e,t,r,n,o,a,i,s,l,u){var c,d,f,p,m;let{placement:h,crossPlacement:g,axis:y,crossAxis:v,size:b,crossSize:w}=n,E={};E[v]=null!=(c=e[v])?c:0,"center"===g?E[v]+=((null!=(d=e[w])?d:0)-(null!=(f=r[w])?f:0))/2:g!==v&&(E[v]+=(null!=(p=e[w])?p:0)-(null!=(m=r[w])?m:0)),E[v]+=a;let x=e[v]-r[w]+l+u,D=e[v]+e[w]-l-u;if(E[v]=wb(E[v],x,D),h===y){let r=s?i[b]:t[wC[b]];E[wD[y]]=Math.floor(r-e[y]+o)}else E[y]=Math.floor(e[y]+e[b]+o);return E}function wj(e,t,r,n,o,a){var i,s,l;let{placement:u,axis:c,size:d}=a;return u===c?Math.max(0,r[c]-e[c]-(null!=(i=e.scroll[c])?i:0)+t[c]-(null!=(s=n[c])?s:0)-n[wD[c]]-o):Math.max(0,e[d]+e[c]+e.scroll[c]-t[c]-r[c]-r[d]-(null!=(l=n[c])?l:0)-n[wD[c]]-o)}function wA(e){let{top:t,left:r,width:n,height:o}=e.getBoundingClientRect(),{scrollTop:a,scrollLeft:i,clientTop:s,clientLeft:l}=document.documentElement;return{top:t+a-s,left:r+i-l,width:n,height:o}}function w$(e,t){let r,n=window.getComputedStyle(e);if("fixed"===n.position){let{top:t,left:n,width:o,height:a}=e.getBoundingClientRect();r={top:t,left:n,width:o,height:a}}else{r=wA(e);let n=wA(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 wI(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 wM=new WeakMap;function wL(e){let{ref:t,box:r,onResize:n}=e;(0,cu.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 wF="u">typeof document?window.visualViewport:null;function wB(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 wU=[],wV="u">typeof document&&window.visualViewport,wW=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]),wH=0;function wz(e,t,r){let n=e.style[t];return e.style[t]=r,()=>{e.style[t]=n}}function wK(e,t,r,n){return e.addEventListener(t,r,n),()=>{e.removeEventListener(t,r,n)}}function wG(e){let t=document.scrollingElement||document.documentElement,r=e;for(;r&&r!==t;){let e=y5(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 wZ={};function wY(e){var t;let{onDismiss:r,...n}=e,o=yY(n,yj((t=wZ)&&t.__esModule?t.default:t,"@react-aria/overlays").format("dismiss"));return cc().createElement(yX,null,cc().createElement("button",{...o,tabIndex:-1,onClick:()=>{r&&r()},style:{width:1,height:1}}))}function wq(e,t,r){my(()=>{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,hP.flushSync)(()=>{r()})}).catch(()=>{}),()=>{n=!0}}},[e,t,r])}function wJ(e){let[t,r]=vK(e.isOpen,e.defaultOpen||!1,e.onOpenChange),n=(0,cu.useCallback)(()=>{r(!0)},[r]),o=(0,cu.useCallback)(()=>{r(!1)},[r]),a=(0,cu.useCallback)(()=>{r(!t)},[r,t]);return{isOpen:t,setOpen:r,open:n,close:o,toggle:a}}wZ={"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 wX=(0,cu.createContext)(null),wQ=(0,cu.createContext)(null),w0=(0,cu.forwardRef)(function(e,t){[e,t]=mL(e,t,wX);let r=(0,cu.useContext)(wl),n=wJ(e),o=null==e.isOpen&&null==e.defaultOpen&&r?r:n,a=function(e,t){let[r,n]=(0,cu.useState)(t?"open":"closed");switch(r){case"open":t||n("exiting");break;case"closed":case"exiting":t&&n("open")}let o="exiting"===r;return wq(e,o,(0,cu.useCallback)(()=>{n(e=>"exiting"===e?"closed":e)},[])),o}(t,o.isOpen)||e.isExiting||!1,i=(0,cu.useContext)(go),{direction:s}=gD();if(i){let t=e.children;return"function"==typeof t&&(t=t({trigger:e.trigger||null,placement:"bottom",isEntering:!1,isExiting:!1,defaultChildren:null})),cc().createElement(cc().Fragment,null,t)}return!o||o.isOpen||a?cc().createElement(w1,{...e,triggerRef:e.triggerRef,state:o,popoverRef:t,isExiting:a,dir:s}):null});function w1({state:e,isExiting:t,UNSTABLE_portalContainer:r,...n}){var o,a;let i=(0,cu.useRef)(null),[s,l]=(0,cu.useState)(0),u=(0,cu.useRef)(null),d=(0,cu.useContext)(wQ),f=d&&"SubmenuTrigger"===n.trigger;my(()=>{i.current&&e.isOpen&&l(i.current.getBoundingClientRect().width)},[e.isOpen,i]);let{popoverProps:p,underlayProps:m,arrowProps:h,placement:g}=function(e,t){let{triggerRef:r,popoverRef:n,groupRef:o,isNonModal:a,isKeyboardDismissDisabled:i,shouldCloseOnInteractOutside:s,...l}=e,u="SubmenuTrigger"===l.trigger,{overlayProps:d,underlayProps:f}=function(e,t){let{onClose:r,shouldCloseOnBlur:n,isOpen:o,isDismissable:a=!1,isKeyboardDismissDisabled:i=!1,shouldCloseOnInteractOutside:s}=e;(0,cu.useEffect)(()=>{if(o&&!wU.includes(t))return wU.push(t),()=>{let e=wU.indexOf(t);e>=0&&wU.splice(e,1)}},[o,t]);let l=()=>{wU[wU.length-1]===t&&r&&r()};!function(e){let{ref:t,onInteractOutside:r,isDisabled:n,onInteractOutsideStart:o}=e,a=(0,cu.useRef)({isPointerDown:!1,ignoreEmulatedMouseEvents:!1}),i=mv(e=>{r&&wB(e,t)&&(o&&o(e),a.current.isPointerDown=!0)}),s=mv(e=>{r&&r(e)});(0,cu.useEffect)(()=>{let e=a.current;if(n)return;let r=m1(t.current);if("u">typeof PointerEvent){let n=r=>{e.isPointerDown&&wB(r,t)&&s(r),e.isPointerDown=!1};return r.addEventListener("pointerdown",i,!0),r.addEventListener("pointerup",n,!0),()=>{r.removeEventListener("pointerdown",i,!0),r.removeEventListener("pointerup",n,!0)}}},[t,n,i,s])}({ref:t,onInteractOutside:a&&o?e=>{(!s||s(e.target))&&(wU[wU.length-1]===t&&(e.stopPropagation(),e.preventDefault()),l())}:void 0,onInteractOutsideStart:e=>{(!s||s(e.target))&&wU[wU.length-1]===t&&(e.stopPropagation(),e.preventDefault())}});let{focusWithinProps:u}=h9({isDisabled:!n,onBlurWithin:e=>{!(!e.relatedTarget||bf(e.relatedTarget,bs))&&(!s||s(e.relatedTarget))&&(null==r||r())}});return{overlayProps:{onKeyDown:e=>{"Escape"!==e.key||i||e.nativeEvent.isComposing||(e.stopPropagation(),e.preventDefault(),l())},...u},underlayProps:{onPointerDown:e=>{e.target===e.currentTarget&&e.preventDefault()}}}}({isOpen:t.isOpen,onClose:t.close,shouldCloseOnBlur:!0,isDismissable:!a||u,isKeyboardDismissDisabled:i,shouldCloseOnInteractOutside:s},null!=o?o:n),{overlayProps:p,arrowProps:m,placement:h}=function(e){var t,r,n;let{direction:o}=gD(),{arrowSize:a=0,targetRef:i,overlayRef:s,scrollRef:l=s,placement:u="bottom",containerPadding:c=12,shouldFlip:d=!0,boundaryElement:f="u">typeof document?document.body:null,offset:p=0,crossOffset:m=0,shouldUpdatePosition:h=!0,isOpen:g=!0,onClose:y,maxHeight:v,arrowBoundaryOffset:b=0}=e,[w,E]=(0,cu.useState)(null),x=[h,u,s.current,i.current,l.current,c,d,f,p,m,g,o,v,b,a],D=(0,cu.useRef)(null==wF?void 0:wF.scale);(0,cu.useEffect)(()=>{g&&(D.current=null==wF?void 0:wF.scale)},[g]);let _=(0,cu.useCallback)(()=>{var e,t,r,n,y,w;if(!1===h||!g||!s.current||!i.current||!f||(null==wF?void 0:wF.scale)!==D.current)return;let x=null;if(l.current&&l.current.contains(document.activeElement)){let n=null==(e=document.activeElement)?void 0:e.getBoundingClientRect(),o=l.current.getBoundingClientRect();(x={type:"top",offset:(null!=(t=null==n?void 0:n.top)?t:0)-o.top}).offset>o.height/2&&(x.type="bottom",x.offset=(null!=(r=null==n?void 0:n.bottom)?r:0)-o.bottom)}let _=s.current;!v&&s.current&&(_.style.top="0px",_.style.bottom="",_.style.maxHeight=(null!=(y=null==(n=window.visualViewport)?void 0:n.height)?y:window.innerHeight)+"px");let S=function(e){var t,r,n,o;let a,{placement:i,targetNode:s,overlayNode:l,scrollNode:u,padding:c,shouldFlip:d,boundaryElement:f,offset:p,crossOffset:m,maxHeight:h,arrowSize:g=0,arrowBoundaryOffset:y=0}=e,v=l instanceof HTMLElement?function(e){let t=e.offsetParent;if(t&&t===document.body&&"static"===window.getComputedStyle(t).position&&!wI(t)&&(t=document.documentElement),null==t)for(t=e.parentElement;t&&!wI(t);)t=t.parentElement;return t||document.documentElement}(l):document.documentElement,b=v===document.documentElement,w=window.getComputedStyle(v).position,E=b?wA(s):w$(s,v);if(!b){let{marginTop:e,marginLeft:t}=window.getComputedStyle(s);E.top+=parseInt(e,10)||0,E.left+=parseInt(t,10)||0}let x=wA(l),D={top:parseInt((a=window.getComputedStyle(l)).marginTop,10)||0,bottom:parseInt(a.marginBottom,10)||0,left:parseInt(a.marginLeft,10)||0,right:parseInt(a.marginRight,10)||0};x.width+=(null!=(t=D.left)?t:0)+(null!=(r=D.right)?r:0),x.height+=(null!=(n=D.top)?n:0)+(null!=(o=D.bottom)?o:0);let _={top:u.scrollTop,left:u.scrollLeft,width:u.scrollWidth,height:u.scrollHeight},S=wO(f),C=wO(v),k="BODY"===f.tagName?wA(v):w$(v,f);return"HTML"===v.tagName&&"BODY"===f.tagName&&(C.scroll.top=0,C.scroll.left=0),function(e,t,r,n,o,a,i,s,l,u,c,d,f,p,m,h){var g,y,v,b,w,E,x,D,_,S,C,k,P,O;let R,T,N,j=wT(e),{size:A,crossAxis:$,crossSize:I,placement:M,crossPlacement:L}=j,F=wN(t,s,r,j,c,d,u,f,m,h),B=c,U=wj(s,u,t,o,a+c,j);if(i&&n[A]>U){let e=wT(`${wD[M]} ${L}`),n=wN(t,s,r,e,c,d,u,f,m,h);wj(s,u,t,o,a+c,e)>U&&(j=e,F=n,B=c)}let V="bottom";"top"===j.axis?"top"===j.placement?V="top":"bottom"===j.placement&&(V="bottom"):"top"===j.crossAxis&&("top"===j.crossPlacement?V="bottom":"bottom"===j.crossPlacement&&(V="top"));let W=wR($,F[$],r[I],s,l,a,u);F[$]+=W;let H=(w=F,E=r.height,x=V,R=f?u.height:s[wC.height],T=null!=w.top?u.top+w.top:u.top+(R-(null!=(D=w.bottom)?D:0)-E),N="top"!==x?Math.max(0,s.height+s.top+(null!=(_=s.scroll.top)?_:0)-T-((null!=(S=o.top)?S:0)+(null!=(C=o.bottom)?C:0)+a)):Math.max(0,T+E-(s.top+(null!=(k=s.scroll.top)?k:0))-((null!=(P=o.top)?P:0)+(null!=(O=o.bottom)?O:0)+a)),Math.min(s.height-2*a,N));p&&p<H&&(H=p),r.height=Math.min(r.height,H),W=wR($,(F=wN(t,s,r,j,B,d,u,f,m,h))[$],r[I],s,l,a,u),F[$]+=W;let z={},K=t[$]+.5*t[I]-F[$]-o[wx[$]],G=m/2+h,Z="left"===wx[$]?(null!=(g=o.left)?g:0)+(null!=(y=o.right)?y:0):(null!=(v=o.top)?v:0)+(null!=(b=o.bottom)?b:0),Y=r[I]-Z-m/2-h,q=wb(K,t[$]+m/2-(F[$]+o[wx[$]]),t[$]+t[I]-m/2-(F[$]+o[wx[$]]));return z[$]=wb(q,G,Y),{position:F,maxHeight:H,arrowOffsetLeft:z.left,arrowOffsetTop:z.top,placement:j.placement}}(i,E,x,_,D,c,d,S,C,k,p,m,!!w&&"static"!==w,h,g,y)}({placement:(w=u,"rtl"===o?w.replace("start","right").replace("end","left"):w.replace("start","left").replace("end","right")),overlayNode:s.current,targetNode:i.current,scrollNode:l.current||s.current,padding:c,shouldFlip:d,boundaryElement:f,offset:p,crossOffset:m,maxHeight:v,arrowSize:a,arrowBoundaryOffset:b});if(S.position){if(_.style.top="",_.style.bottom="",_.style.left="",_.style.right="",Object.keys(S.position).forEach(e=>_.style[e]=S.position[e]+"px"),_.style.maxHeight=null!=S.maxHeight?S.maxHeight+"px":"",x&&document.activeElement&&l.current){let e=document.activeElement.getBoundingClientRect(),t=l.current.getBoundingClientRect(),r=e[x.type]-t[x.type];l.current.scrollTop+=r-x.offset}E(S)}},x);my(_,x),my(()=>(window.addEventListener("resize",n,!1),()=>{window.removeEventListener("resize",n,!1)}),[n=_]),wL({ref:s,onResize:_}),wL({ref:i,onResize:_});let S=(0,cu.useRef)(!1);my(()=>{let e,t=()=>{S.current=!0,clearTimeout(e),e=setTimeout(()=>{S.current=!1},500),_()},r=()=>{S.current&&t()};return null==wF||wF.addEventListener("resize",t),null==wF||wF.addEventListener("scroll",r),()=>{null==wF||wF.removeEventListener("resize",t),null==wF||wF.removeEventListener("scroll",r)}},[_]);let C=(0,cu.useCallback)(()=>{S.current||null==y||y()},[y,S]);return!function(e){let{triggerRef:t,isOpen:r,onClose:n}=e;(0,cu.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||wM.get(t.current);o&&o()};return window.addEventListener("scroll",e,!0),()=>{window.removeEventListener("scroll",e,!0)}},[r,n,t])}({triggerRef:i,isOpen:g,onClose:y&&C}),{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:_}}({...l,targetRef:r,overlayRef:n,isOpen:t.isOpen,onClose:a&&!u?t.close:null});return!function(e={}){let{isDisabled:t}=e;my(()=>{if(!t){let e,t,r,n;return 1==++wH&&(c=ha()?(r=null,n=mg(wK(document,"touchstart",r=>{((e=y5(r.target,!0))!==document.documentElement||e!==document.body)&&e instanceof HTMLElement&&"auto"===window.getComputedStyle(e).overscrollBehavior&&(t=wz(e,"overscrollBehavior","contain"))},{passive:!1,capture:!0}),wK(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}),wK(document,"touchend",()=>{t&&t()},{passive:!1,capture:!0}),wK(document,"focus",e=>{var t;let n=e.target;((t=n)instanceof HTMLInputElement&&!wW.has(t.type)||t instanceof HTMLTextAreaElement||t instanceof HTMLElement&&t.isContentEditable)&&((()=>{if(r)return;let e=window.pageXOffset,t=window.pageYOffset;r=mg(wK(window,"scroll",()=>{window.scrollTo(0,0)}),wz(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),wz(document.documentElement,"overflow","hidden"),wz(document.body,"marginTop",`-${t}px`),()=>{window.scrollTo(e,t)}),window.scrollTo(0,0)})(),n.style.transform="translateY(-2000px)",requestAnimationFrame(()=>{n.style.transform="",wV&&(wV.height<window.innerHeight?requestAnimationFrame(()=>{wG(n)}):wV.addEventListener("resize",()=>wG(n),{once:!0}))}))},!0)),()=>{null==t||t(),null==r||r(),n()}):mg(wz(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),wz(document.documentElement,"overflow","hidden"))),()=>{0==--wH&&c()}}},[t])}({isDisabled:a||!t.isOpen}),my(()=>{if(t.isOpen&&n.current){if(!a)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}),i=t(e);if(i===NodeFilter.FILTER_ACCEPT&&a(e),i!==NodeFilter.FILTER_REJECT){let e=o.nextNode();for(;null!=e;)a(e),e=o.nextNode()}},a=e=>{var t;let r=null!=(t=wy.get(e))?t:0;("true"!==e.getAttribute("aria-hidden")||0!==r)&&(0===r&&e.setAttribute("aria-hidden","true"),n.add(e),wy.set(e,r+1))};wv.length&&wv[wv.length-1].disconnect(),o(t);let i=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)}});i.observe(t,{childList:!0,subtree:!0});let s={visibleNodes:r,hiddenNodes:n,observe(){i.observe(t,{childList:!0,subtree:!0})},disconnect(){i.disconnect()}};return wv.push(s),()=>{for(let e of(i.disconnect(),n)){let t=wy.get(e);null!=t&&(1===t?(e.removeAttribute("aria-hidden"),wy.delete(e)):wy.set(e,t-1))}s===wv[wv.length-1]?(wv.pop(),wv.length&&wv[wv.length-1].observe()):wv.splice(wv.indexOf(s),1)}}([null!=(r=null==o?void 0:o.current)?r:n.current]);var e,r,i=null!=(e=null==o?void 0:o.current)?e:n.current;let t=wv[wv.length-1];return t&&!t.visibleNodes.has(i)?(t.visibleNodes.add(i),()=>{t.visibleNodes.delete(i)}):void 0}},[a,t.isOpen,n,o]),{popoverProps:mj(d,p),arrowProps:m,underlayProps:f,placement:h}}({...n,offset:null!=(o=n.offset)?o:8,arrowSize:s,groupRef:f?d:u},e),y=n.popoverRef,v=function(e,t=!0){let[r,n]=(0,cu.useState)(!0),o=r&&t;return my(()=>{if(o&&e.current&&"getAnimations"in e.current)for(let t of e.current.getAnimations())t instanceof CSSTransition&&t.cancel()},[e,o]),wq(e,o,(0,cu.useCallback)(()=>n(!1),[])),o}(y,!!g)||n.isEntering||!1,b=mI({...n,defaultClassName:"react-aria-Popover",values:{trigger:n.trigger||null,placement:g,isEntering:v,isExiting:t}}),w=!n.isNonModal||"SubmenuTrigger"===n.trigger,[E,x]=(0,cu.useState)(!1);my(()=>{y.current&&x(w&&!y.current.querySelector("[role=dialog]"))},[y,w]),(0,cu.useEffect)(()=>{E&&y.current&&!y.current.contains(document.activeElement)&&h2(y.current)},[E,y]);let D={...p.style,...b.style},_=cc().createElement("div",{...mj(mY(n),p),...b,role:E?"dialog":void 0,tabIndex:E?-1:void 0,"aria-label":n["aria-label"],"aria-labelledby":n["aria-labelledby"],ref:y,slot:n.slot||void 0,style:D,dir:n.dir,"data-trigger":n.trigger,"data-placement":g,"data-entering":v||void 0,"data-exiting":t||void 0},!n.isNonModal&&cc().createElement(wY,{onDismiss:e.close}),cc().createElement(wg.Provider,{value:{...h,placement:g,ref:i}},b.children),cc().createElement(wY,{onDismiss:e.close}));return f?cc().createElement(wi,{...n,shouldContainFocus:E,isExiting:t,portalContainer:null!=(a=null!=r?r:null==d?void 0:d.current)?a:void 0},_):cc().createElement(wi,{...n,shouldContainFocus:E,isExiting:t,portalContainer:r},!n.isNonModal&&e.isOpen&&cc().createElement("div",{"data-testid":"underlay",...m,style:{position:"fixed",inset:0}}),cc().createElement("div",{ref:u,style:{display:"contents"}},cc().createElement(wQ.Provider,{value:u},_)))}function w2(e){return(null==e?void 0:e.start)!=null&&null!=e.end}let w4=(0,cu.createContext)(null),w3=(0,cu.createContext)(null),w6=(0,cu.createContext)(null),w5=(0,cu.createContext)(null),w9=(0,cu.forwardRef)(function(e,t){var r,n;[e,t]=mL(e,t,w4);let{validationBehavior:o}=mM(wp)||{},a=null!=(n=null!=(r=e.validationBehavior)?r:o)?n:"native",i=function(e){var t;let r=wJ(e),[n,o]=vK(e.value,e.defaultValue||null,e.onChange),a=n||e.placeholderValue||null,[i,s]=b0(a,e.granularity),l=null!=n?n.toDate(null!=s?s:"UTC"):null,u="hour"===i||"minute"===i||"second"===i,c=null==(t=e.shouldCloseOnSelect)||t,[d,f]=(0,cu.useState)(null),[p,m]=(0,cu.useState)(null);if(n&&(d=n,"hour"in n&&(p=n)),a&&!(i in a))throw Error("Invalid granularity "+i+" for value "+a.toString());let h=(null==n?void 0:n.calendar.identifier)==="gregory"&&"BC"===n.era,g=(0,cu.useMemo)(()=>({granularity:i,timeZone:s,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,shouldForceLeadingZeros:e.shouldForceLeadingZeros,showEra:h}),[i,e.hourCycle,e.shouldForceLeadingZeros,s,e.hideTimeZone,h]),{minValue:y,maxValue:v,isDateUnavailable:b}=e,w=(0,cu.useMemo)(()=>bG(n,y,v,b,g),[n,y,v,b,g]),E=bB({...e,value:n,builtinValidation:w}),x=E.displayValidation.isInvalid,D=e.validationState||(x?"invalid":null),_=(e,t)=>{o("timeZone"in t?t.set(yo(e)):ya(e,t)),f(null),m(null),E.commitValidation()};return{...E,value:n,setValue:o,dateValue:d,timeValue:p,setDateValue:t=>{let n="function"==typeof c?c():c;u?p||n?_(t,p||bJ(e.defaultValue||e.placeholderValue)):f(t):(o(t),E.commitValidation()),n&&r.setOpen(!1)},setTimeValue:e=>{d&&e?_(d,e):m(e)},granularity:i,hasTime:u,...r,setOpen(t){!t&&!n&&d&&u&&_(d,p||bJ(e.defaultValue||e.placeholderValue)),r.setOpen(t)},validationState:D,isInvalid:x,formatValue:(e,t)=>l?new y$(e,bq(t,g)).format(l):"",getDateFormatter:(e,t)=>new y$(e,bq({},{...g,...t}))}}({...e,validationBehavior:a}),s=(0,cu.useRef)(null),[l,u]=mF(!e["aria-label"]&&!e["aria-labelledby"]),{groupProps:c,labelProps:d,fieldProps:f,buttonProps:p,dialogProps:m,calendarProps:h,descriptionProps:g,errorMessageProps:y,...v}=function(e,t,r){var n;let o=mR(),a=mR(),i=mR(),s=yj((n=bo)&&n.__esModule?n.default:n,"@react-aria/datepicker"),{isInvalid:l,validationErrors:u,validationDetails:c}=t.displayValidation,{labelProps:d,fieldProps:f,descriptionProps:p,errorMessageProps:m}=bP({...e,labelElementType:"span",isInvalid:l,errorMessage:e.errorMessage||u}),h=bS(t,r),g=f["aria-labelledby"]||f.id,{locale:y}=gD(),v=t.formatValue(y,{month:"long"}),b=y2(v?s.format("selectedDateDescription",{date:v}):""),w=[b["aria-describedby"],f["aria-describedby"]].filter(Boolean).join(" ")||void 0,E=mY(e),x=(0,cu.useMemo)(()=>bw(r),[r]),D=(0,cu.useRef)(!1),{focusWithinProps:_}=h9({...e,isDisabled:t.isOpen,onBlurWithin:t=>{let r=document.getElementById(a);if(!(null==r?void 0:r.contains(t.relatedTarget))){var n,o;D.current=!1,null==(n=e.onBlur)||n.call(e,t),null==(o=e.onFocusChange)||o.call(e,!1)}},onFocusWithin:t=>{if(!D.current){var r,n;D.current=!0,null==(r=e.onFocus)||r.call(e,t),null==(n=e.onFocusChange)||n.call(e,!0)}}});return{groupProps:mj(E,h,f,b,_,{role:"group","aria-disabled":e.isDisabled||null,"aria-labelledby":g,"aria-describedby":w,onKeyDown(r){!t.isOpen&&e.onKeyDown&&e.onKeyDown(r)},onKeyUp(r){!t.isOpen&&e.onKeyUp&&e.onKeyUp(r)}}),labelProps:{...d,onClick:()=>{x.focusFirst()}},fieldProps:{...f,id:i,[bT]:"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,[bF]:t,autoFocus:e.autoFocus,name:e.name},descriptionProps:p,errorMessageProps:m,buttonProps:{...b,id:o,"aria-haspopup":"dialog","aria-label":s.format("calendar"),"aria-labelledby":`${o} ${g}`,"aria-describedby":w,"aria-expanded":t.isOpen,isDisabled:e.isDisabled||e.isReadOnly,onPress:()=>t.setOpen(!0)},dialogProps:{id:a,"aria-labelledby":`${o} ${g}`},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:l,validationErrors:u,validationDetails:c}}({...mB(e),label:u,validationBehavior:a},i,s),[b,w]=(0,cu.useState)(null),E=(0,cu.useCallback)(()=>{s.current&&w(s.current.offsetWidth+"px")},[]);wL({ref:s,onResize:E});let{focusProps:x,isFocused:D,isFocusVisible:_}=h8({within:!0}),S=mI({...e,values:{state:i,isFocusWithin:D,isFocusVisible:_,isDisabled:e.isDisabled||!1,isInvalid:i.isInvalid,isOpen:i.isOpen},defaultClassName:"react-aria-DatePicker"}),C=mY(e);return delete C.id,cc().createElement(m$,{values:[[w6,i],[be,{...c,ref:s,isInvalid:i.isInvalid}],[b9,f],[gs,{...p,isPressed:i.isOpen}],[wm,{...d,ref:l,elementType:"span"}],[vX,h],[wl,i],[wX,{trigger:"DatePicker",triggerRef:s,placement:"bottom start",style:{"--trigger-width":b}}],[ws,m],[gc,{slots:{description:g,errorMessage:y}}],[wc,v]]},cc().createElement("div",{...x,...C,...S,ref:t,slot:e.slot||void 0,"data-focus-within":D||void 0,"data-invalid":i.isInvalid||void 0,"data-focus-visible":_||void 0,"data-disabled":e.isDisabled||void 0,"data-open":i.isOpen||void 0}))}),w8=(0,cu.forwardRef)(function(e,t){var r,n;[e,t]=mL(e,t,w3);let{validationBehavior:o}=mM(wp)||{},a=null!=(n=null!=(r=e.validationBehavior)?r:o)?n:"native",i=function(e){var t,r,n;let o=wJ(e),[a,i]=vK(e.value,e.defaultValue||null,e.onChange),[s,l]=(0,cu.useState)(()=>a||{start:null,end:null});null==a&&s.start&&s.end&&l(s={start:null,end:null});let u=a||s,c=e=>{l(e||{start:null,end:null}),w2(e)?i(e):i(null)},[d,f]=b0((null==u?void 0:u.start)||(null==u?void 0:u.end)||e.placeholderValue||null,e.granularity),p="hour"===d||"minute"===d||"second"===d,m=null==(n=e.shouldCloseOnSelect)||n,[h,g]=(0,cu.useState)(null),[y,v]=(0,cu.useState)(null);u&&w2(u)&&(h=u,"hour"in u.start&&(y=u));let b=(e,t)=>{c({start:"timeZone"in t.start?t.start.set(yo(e.start)):ya(e.start,t.start),end:"timeZone"in t.end?t.end.set(yo(e.end)):ya(e.end,t.end)}),g(null),v(null),P.commitValidation()},w=t=>{let r="function"==typeof m?m():m;p?w2(t)&&(null==y?void 0:y.start)&&(null==y?void 0:y.end)?b(t,{start:(null==y?void 0:y.start)||bJ(e.placeholderValue),end:(null==y?void 0:y.end)||bJ(e.placeholderValue)}):g(t):w2(t)?(c(t),P.commitValidation()):g(t),r&&o.setOpen(!1)},E=e=>{w2(h)&&w2(e)?b(h,e):v(e)},x=(null==u||null==(t=u.start)?void 0:t.calendar.identifier)==="gregory"&&"BC"===u.start.era||(null==u||null==(r=u.end)?void 0:r.calendar.identifier)==="gregory"&&"BC"===u.end.era,D=(0,cu.useMemo)(()=>({granularity:d,timeZone:f,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,shouldForceLeadingZeros:e.shouldForceLeadingZeros,showEra:x}),[d,e.hourCycle,e.shouldForceLeadingZeros,f,e.hideTimeZone,x]),{minValue:_,maxValue:S,isDateUnavailable:C}=e,k=(0,cu.useMemo)(()=>{var e,t;let r;return r=bH(bG(null!=(e=null==u?void 0:u.start)?e:null,_,S,C,D),bG(null!=(t=null==u?void 0:u.end)?t:null,_,S,C,D)),(null==u?void 0:u.end)!=null&&null!=u.start&&0>u.end.compare(u.start)&&(r=bH(r,{isInvalid:!0,validationErrors:[(yk.getGlobalDictionaryForPackage("@react-stately/datepicker")||bz).getStringForLocale("rangeReversed",bK())],validationDetails:{...b$,rangeUnderflow:!0,rangeOverflow:!0,valid:!1}})),r},[u,_,S,C,D]),P=bB({...e,value:a,name:(0,cu.useMemo)(()=>[e.startName,e.endName].filter(e=>null!=e),[e.startName,e.endName]),builtinValidation:k}),O=P.displayValidation.isInvalid,R=e.validationState||(O?"invalid":null);return{...P,value:u,setValue:c,dateRange:h,timeRange:y,granularity:d,hasTime:p,setDate(e,t){var r,n;"start"===e?w({start:t,end:null!=(r=null==h?void 0:h.end)?r:null}):w({start:null!=(n=null==h?void 0:h.start)?n:null,end:t})},setTime(e,t){var r,n;"start"===e?E({start:t,end:null!=(r=null==y?void 0:y.end)?r:null}):E({start:null!=(n=null==y?void 0:y.start)?n:null,end:t})},setDateTime(e,t){var r,n;"start"===e?c({start:t,end:null!=(r=null==u?void 0:u.end)?r:null}):c({start:null!=(n=null==u?void 0:u.start)?n:null,end:t})},setDateRange:w,setTimeRange:E,...o,setOpen(t){!t&&!((null==u?void 0:u.start)&&(null==u?void 0:u.end))&&w2(h)&&p&&b(h,{start:(null==y?void 0:y.start)||bJ(e.placeholderValue),end:(null==y?void 0:y.end)||bJ(e.placeholderValue)}),o.setOpen(t)},validationState:R,isInvalid:O,formatValue(t,r){let n;if(!u||!u.start||!u.end)return null;let o="timeZone"in u.start?u.start.timeZone:void 0,a=e.granularity||(u.start&&"minute"in u.start?"minute":"day"),i="timeZone"in u.end?u.end.timeZone:void 0,s=e.granularity||(u.end&&"minute"in u.end?"minute":"day"),l=bq(r,{granularity:a,timeZone:o,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,showEra:"gregory"===u.start.calendar.identifier&&"BC"===u.start.era||"gregory"===u.end.calendar.identifier&&"BC"===u.end.era}),c=u.start.toDate(o||"UTC"),d=u.end.toDate(i||"UTC"),f=new y$(t,l);if(o===i&&a===s&&0!==u.start.compare(u.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 y$(t,bq(r,{granularity:s,timeZone:i,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle}));return{start:f.format(c),end:n.format(d)}},getDateFormatter:(e,t)=>new y$(e,bq({},{...D,...t}))}}({...e,validationBehavior:a}),s=(0,cu.useRef)(null),[l,u]=mF(!e["aria-label"]&&!e["aria-labelledby"]),{groupProps:c,labelProps:d,startFieldProps:f,endFieldProps:p,buttonProps:m,dialogProps:h,calendarProps:g,descriptionProps:y,errorMessageProps:v,...b}=function(e,t,r){var n,o,a,i,s,l;let u=yj((l=bo)&&l.__esModule?l.default:l,"@react-aria/datepicker"),{isInvalid:c,validationErrors:d,validationDetails:f}=t.displayValidation,{labelProps:p,fieldProps:m,descriptionProps:h,errorMessageProps:g}=bP({...e,labelElementType:"span",isInvalid:c,errorMessage:e.errorMessage||d}),y=m["aria-labelledby"]||m.id,{locale:v}=gD(),b=t.formatValue(v,{month:"long"}),w=y2(b?u.format("selectedRangeDescription",{startDate:b.start,endDate:b.end}):""),E={"aria-label":u.format("startDate"),"aria-labelledby":y},x={"aria-label":u.format("endDate"),"aria-labelledby":y},D=mR(),_=mR(),S=bS(t,r),C=[w["aria-describedby"],m["aria-describedby"]].filter(Boolean).join(" ")||void 0,k=(0,cu.useMemo)(()=>bw(r,{accept:e=>e.id!==D}),[r,D]),P={[bN]:k,[bT]:"presentation","aria-describedby":C,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},O=mY(e),R=(0,cu.useRef)(!1),{focusWithinProps:T}=h9({...e,isDisabled:t.isOpen,onBlurWithin:t=>{let r=document.getElementById(_);if(!(null==r?void 0:r.contains(t.relatedTarget))){var n,o;R.current=!1,null==(n=e.onBlur)||n.call(e,t),null==(o=e.onFocusChange)||o.call(e,!1)}},onFocusWithin:t=>{if(!R.current){var r,n;R.current=!0,null==(r=e.onFocus)||r.call(e,t),null==(n=e.onFocusChange)||n.call(e,!0)}}}),N=(0,cu.useRef)(bM),j=(0,cu.useRef)(bM);return{groupProps:mj(O,S,m,w,T,{role:"group","aria-disabled":e.isDisabled||null,"aria-describedby":C,onKeyDown(r){!t.isOpen&&e.onKeyDown&&e.onKeyDown(r)},onKeyUp(r){!t.isOpen&&e.onKeyUp&&e.onKeyUp(r)}}),labelProps:{...p,onClick:()=>{k.focusFirst()}},buttonProps:{...w,id:D,"aria-haspopup":"dialog","aria-label":u.format("calendar"),"aria-labelledby":`${D} ${y}`,"aria-describedby":C,"aria-expanded":t.isOpen,isDisabled:e.isDisabled||e.isReadOnly,onPress:()=>t.setOpen(!0)},dialogProps:{id:_,"aria-labelledby":`${D} ${y}`},startFieldProps:{...E,...P,value:null!=(i=null==(n=t.value)?void 0:n.start)?i:null,onChange:e=>t.setDateTime("start",e),autoFocus:e.autoFocus,name:e.startName,[bF]:{realtimeValidation:t.realtimeValidation,displayValidation:t.displayValidation,updateValidation(e){N.current=e,t.updateValidation(bH(e,j.current))},resetValidation:t.resetValidation,commitValidation:t.commitValidation}},endFieldProps:{...x,...P,value:null!=(s=null==(o=t.value)?void 0:o.end)?s:null,onChange:e=>t.setDateTime("end",e),name:e.endName,[bF]:{realtimeValidation:t.realtimeValidation,displayValidation:t.displayValidation,updateValidation(e){j.current=e,t.updateValidation(bH(N.current,e))},resetValidation:t.resetValidation,commitValidation:t.commitValidation}},descriptionProps:h,errorMessageProps:g,calendarProps:{autoFocus:!0,value:(null==(a=t.dateRange)?void 0:a.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}}({...mB(e),label:u,validationBehavior:a},i,s),[w,E]=(0,cu.useState)(null),x=(0,cu.useCallback)(()=>{s.current&&E(s.current.offsetWidth+"px")},[]);wL({ref:s,onResize:x});let{focusProps:D,isFocused:_,isFocusVisible:S}=h8({within:!0}),C=mI({...e,values:{state:i,isFocusWithin:_,isFocusVisible:S,isDisabled:e.isDisabled||!1,isInvalid:i.isInvalid,isOpen:i.isOpen},defaultClassName:"react-aria-DateRangePicker"}),k=mY(e);return delete k.id,cc().createElement(m$,{values:[[w5,i],[be,{...c,ref:s,isInvalid:i.isInvalid}],[gs,{...m,isPressed:i.isOpen}],[wm,{...d,ref:l,elementType:"span"}],[vQ,g],[wl,i],[wX,{trigger:"DateRangePicker",triggerRef:s,placement:"bottom start",style:{"--trigger-width":w}}],[ws,h],[b9,{slots:{start:f,end:p}}],[gc,{slots:{description:y,errorMessage:v}}],[wc,b]]},cc().createElement("div",{...D,...k,...C,ref:t,slot:e.slot||void 0,"data-focus-within":_||void 0,"data-invalid":i.isInvalid||void 0,"data-focus-visible":S||void 0,"data-disabled":e.isDisabled||void 0,"data-open":i.isOpen||void 0}))});function w7(e){return cc().createElement(gx,e)}function Ee(e,t,r=!1){if(null==e)return r?e:void 0;if("string"==typeof e&&!e)return r?null:void 0;if(e instanceof gQ||e instanceof g4||e instanceof g6)return t?yi(e,t):e;{let r=d0()(e).toDate(),n=new gQ(r.getFullYear(),r.getMonth()+1,r.getDate());return t?yi(n,t):n}}function Et(e){if(e)return e.toDate(yv())}function Er(e){if("string"==typeof e&&0!==e.trim().length)try{return new Intl.Locale(e.replace(/[_@]/g,"-")).toString()}catch{return}}function En(e){let t=e??"",r=Er(t);if(!r)return t;try{return new Intl.DisplayNames([r],{type:"language"}).of(r)??t}catch{return t}}function Eo(){let e=window.i18next.language,t=Er(e)??e;return"ht"===t&&(t="fr-HT"),t}if("u">typeof navigator){let e=navigator;ea=Array.isArray(e.languages)?e.languages[0]:e.language}else if("u">typeof process){let e=process.env;ea=e.LC_ALL||e.LC_MESSAGES||e.LANG||e.LANGUAGE}var Ea=function(e){e=(e=e.replace(/_/g,"-")).replace(/[.:][\w-]*$/,"");try{return new Intl.Locale(e).baseName}catch(e){return"en-US"}}(ea||"en-US"),Ei=class extends Date{invalid=null;isValid(){return!Number.isNaN(this.valueOf())}},Es={};for(let e=1;e<100;e++)Es[(e<=9?"0":"")+e]=e+(e>51?1900:2e3);var El={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},Eu="[1234567890一二三四五六七八九〇\\d]",Ec={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},Ed={},Ef={"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},Ep={zone:Ef,year:Es,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:{}},Em={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(Ef).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,}"},Eh={...Em,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}"},Eg={},Ey=class e{locale;lookups;vars;numberingSystem;baseName;dateOptions;static factory(t=Ea){return Eg[t.toLowerCase()]||(Eg[t.toLowerCase()]=new e(t)),Eg[t.toLowerCase()]}constructor(e=Ea){this.locale=e,this.lookups={...Ep},this.vars={...Em};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=Ec: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(Ed[e])return Ed[e];if("fullwide"===e||"hanidec"===e)return{group:Eu,lookup:{...Ec}};let t=El[e];if(!t)return{group:"\\d",lookup:{...Ec}};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 Ed[e]={group:`[${r}-${n}]`,lookup:o},Ed[e]}(this.numberingSystem);for(let r in this.lookups.digit=t,Eh)Eh.hasOwnProperty(r)&&(this.vars[r]=Eh[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,a)=>{e[r+o+(a<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 a=Intl.DateTimeFormat(this.locale,{dateStyle:o});for(let i=0;i<12;i++){let s=a.formatToParts(r[i]).find(n).value.toLocaleLowerCase(this.locale);/^\d+$/.test(s)||(/^ko/i.test(this.locale)&&(s+="월"),"medium"===o?(s=s.replace(/\.$/,""),e[`${s}\\.?`]=!0):e[s]=!0,t[s]=i+1)}}let o=Intl.DateTimeFormat(this.locale,{month:"short"});for(let a=0;a<12;a++){let i=o.formatToParts(r[a]).find(n).value.toLocaleLowerCase(this.locale);i=i.replace(/\.$/,""),e[`${i}\\.?`]=!0,t[i]=a+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 a=Intl.DateTimeFormat(this.locale,{weekday:o});for(let i=0;i<7;i++){let s=a.formatToParts(e[i]).find(t).value.toLocaleLowerCase(this.locale);"short"===o?(s=s.replace(/\.$/,""),r.push(`${s}\\.?`)):r.push(s),n[s]=i}}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 a=0;a<2;a++){let i=o.formatToParts(e[a]).find(t);if(!i)return;let s=i.value.toLocaleLowerCase(this.locale);r.push(s),n[s]=12*a}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")}},Ev=["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"],Eb={y:"year",M:"month",d:"day",w:"week",h:"hour",m:"minute",s:"second",ms:"millisecond"},Ew=()=>new Date;function EE(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 Ex=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 a=e.handler(o);if(a){for(let[e,t]of Object.entries(a))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)}},ED=["year","month","day","hour","minute","second","millisecond","offset"],E_={};function ES(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 EC=[[/([^\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"]],Ek={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," "],...EC],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:EC,id:EC,fr:[[/(\d{2}) h /,"$1:"],[/(\d{2}) min /,"$1:"],[/(\d{2}) s /,"$1"]]};function EP(e,t=Ea){let r=function(e){if(!E_[e]){var t,r;let n,o,a=Ey.factory(e);E_[e]=new Ex({doneChecker:ES,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:a.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? ?(_OFFSET_|Z)?$"),handler:EE(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"timestampWithZone",regex:a.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))?\\s*(_ZONE_)$"),handler:EE(["","year","month","day","hour","minute","second","millisecond","zone"])},{name:"timestampWithOffsetAndZone",regex:a.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? (_OFFSET_|Z)\\s*(_ZONE_)$"),handler:EE(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"chinese",regex:a.compile(`^(${Eu}{2,4})\\s*\u5E74\\s*(${Eu}{1,2})\\s*\u6708\\s*(${Eu}{1,2})\\s*\u65E5$`),handler:EE(["","year","month","day"])},{name:"korean",regex:a.compile("^(_YEAR_)년\\s*(_MONTH_)월\\s*(_DAY_)일$"),handler:EE(["","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:EE(["","monthname","day","hour","minute","second","offset","year"])},{name:"today",regex:/^(now|today|tomorrow|yesterday)$/i,handler:function(e){let t=Ew(),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?Eb[r]:(r=r.replace(/s$/,"")).toLowerCase())&&(r="day",t*=7),("-"===e||n)&&(t*=-1);let o=Ew();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:a.compile("(?:^|[\\sT])(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?(Z)?$"),handler:EE(["","hour","minute","second","millisecond","zone"])},{name:"zone24",regex:a.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?[\\s\\[(]*(_ZONE_)?[\\s\\])]*$"),handler:EE(["","hour","minute","second","millisecond","zone"])},{name:"hms12WithOffset",regex:a.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)\\s*(_OFFSET_)"),handler:EE(["","hour","minute","second","meridiem","offset"])},{name:"hms12",regex:a.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)"),handler:EE(["","hour","minute","second","meridiem"])},{name:"hms24",regex:a.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?"),handler:EE(["","hour","minute","second","millisecond"])},{name:"hm12",regex:a.compile("(_H12_):(_MIN_)\\s*(_MERIDIEM_)"),handler:EE(["","hour","minute","meridiem"])},{name:"hm24",regex:a.compile("(_H24_):(_MIN_)"),handler:EE(["","hour","minute"])},{name:"h12",regex:a.compile("(_H12_)\\s*(_MERIDIEM_)"),handler:EE(["","hour","meridiem"])},{name:"8digit",regex:/^((?:19|20)\d{2})(\d{2})(\d{2})$/,handler:EE(["","year","month","day"])},{name:"yearMonthnameDay",regex:a.compile("(_YEAR4_)[\\s.-]+(_MONTHNAME_)[\\s,.-]+(_DAY_)(_ORDINAL_)?"),handler:EE(["","year","monthname","day"])},{name:"dayMonthnameYear",regex:a.compile("(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)[\\s,.-]+(_YEAR_)"),handler:EE(["","day","","monthname","year"])},{name:"monthnameDayYear",regex:a.compile("(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?[\\s,.-]+(_YEAR_)"),handler:EE(["","monthname","day","","year"])},{name:"dayMonthname",regex:a.compile("\\b(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)\\b"),handler:EE(["","day","","monthname"])},{name:"monthnameDay",regex:a.compile("\\b(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?\\b"),handler:EE(["","monthname","day"])},{name:"hmsNoMeridiem",regex:a.compile("\\b(_H12_|_H24_):(_MIN_):(_SEC_)\\b"),handler:EE(["","hour","minute","second"])},{name:"hmNoMeridiem",regex:a.compile("\\b(_H12_|_H24_):(_MIN_)\\b"),handler:EE(["","hour","minute"])},{name:"ymd",regex:a.compile("(_YEAR4_)([.-])(_MONTH_)\\2+(_DAY_)"),handler:EE(["","year","","month","day"])},{name:"mdy",regex:a.compile("(_MONTH_)([/-])(_DAY_)\\2(_YEAR_)"),handler:EE(["","month","","day","year"])},{name:"dmy",regex:a.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)[./\\s-]+(_YEAR_)"),handler:EE(["","day","month","year"])},{name:"yearLoose",regex:a.compile("_YEAR4_"),handler:EE(["year"])},{name:"dayMonthnameLoose",regex:a.compile("(_DAY_)[\\s.]*(_MONTHNAME_)"),handler:EE(["","day","monthname"])},{name:"monthnameDayLoose",regex:a.compile("(_MONTHNAME_)[\\s.]*(_DAY_)"),handler:EE(["","monthname","day"])},{name:"monthname",regex:a.compile("_MONTHNAME_"),handler:EE(["monthname"])},{name:"year4",regex:a.compile("_YEAR4_"),handler:EE(["year"])},{name:"md",regex:a.compile("(_MONTH_)[/-](_DAY_)"),handler:EE(["","month","day"])},{name:"dm",regex:a.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)"),handler:EE(["","day","month"])},{name:"day",regex:a.compile("_DAY_"),handler:EE(["day"])},{name:"year2",regex:a.compile("_YEAR2_"),handler:EE(["year"])},{name:"onlyZone",regex:a.compile("_ZONE_"),handler:EE(["zone"])},{name:"onlyOffset",regex:a.compile("_OFFSET_"),handler:EE(["offset"])}],o=a.baseName.slice(0,5),Ev.includes(o)?n:n.filter(e=>!["mdy","md"].includes(e.name))),formatter:(r=a,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(ED.includes(n)){let e=r.toInt(o);"number"==typeof e&&(t[n]=e)}return t.year<100&&(t.year=Es[t.year]),t.year&&"buddhist"===r.dateOptions.calendar&&(t.year-=543),t})})}return E_[e]}(t),n=function(e,t){let r=Ek[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 EO(e){e.month&&e.day&&void 0===e.year&&(e.year=new Date().getFullYear()),60===e.second&&(e.second=59);let t=new Ei(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 Ei(t.valueOf()-60*e.offset*1e3):t}function ER(e,t=Ea){let r=EP(e,t),n=r.invalid?new Ei(NaN):EO(r);return n.isValid()||(n.invalid=`Unable to parse date "${e}"`),n}function ET(e,t=Ea){return e instanceof Date?new Ei(e.valueOf()):"number"==typeof e?new Ei(e):ER(e,t)}Date.fromString=Ei.fromString=ER,Date.fromAny=Ei.fromAny=ET,"u">typeof window&&(window.anyDateParser={fromString:ER,fromAny:ET,fromObject:EO,attempt:EP});var EN=r(5238),Ej=r(3826);let EA=function(e){return null==e};function E$(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}dQ.extend(d1),dQ.extend(Ej),dQ.extend(EN);let EI="YYYY-MM-DDTHH:mm:ss.SSSZZ";function EM(e){return null!=e&&28===e.trim().length&&"T"===(e=e.trim())[10]&&":"===e[13]&&":"===e[16]&&"."===e[19]&&("+"===e[23]||"-"===e[23])&&dQ(e,EI).isValid()}function EL(e){return dQ(e).isToday()}function EF(e){return EM(e)?dQ(e,EI).toDate():null}function EB(e,t=!1){let r=dQ(e);return t&&(r=r.utc()),r.format(EI)}function EU(e){return dQ(e).toDate()}var EV=new WeakMap;let EW=new class{register(e,t){E$(this,EV).set(e,t)}getCalendar(e){if(!e)return;if(e.calendar)return e.calendar;if(e.region){let t=`${e.language}-${e.region}`;if(E$(this,EV).has(t))return E$(this,EV).get(t)}if(e.language&&E$(this,EV).has(e.language))return E$(this,EV).get(e.language);let t=new Intl.DateTimeFormat(e.toString()).resolvedOptions().calendar;return E$(this,EV).set(`${e.language}${e.region?`-${e.region}`:""}`,t),t}constructor(){!function(e,t,r){if(t.has(e))throw TypeError("Cannot initialize the same private elements twice on an object");t.set(e,r)}(this,EV,{writable:!0,value:new Map})}};function EH(e,t){EW.register(e,t)}function Ez(e){let t=e??Eo();return EW.getCalendar(t instanceof Intl.Locale?t:new Intl.Locale(t))}let EK={mode:"standard",time:"for today",day:!0,month:!0,year:!0,noToday:!1};function EG(e,t={}){let r=EP(e,Eo());if(r.invalid)return console.warn(`Could not parse invalid date '${e}'`),null;!EA(r.day)&&EA(r.month)&&(r=Object.assign({},nr(r,"day"),{month:r.day})),r.month&&(r.month-=1),r.day&&(r=Object.assign({},nr(r,"day"),{date:r.day}));let n=dQ().set(r).toDate();return EA(r.year)&&(t.year=!1),EA(r.month)&&(t.month=!1),EA(r.date)&&(t.day=!1),EZ(n,t)}function EZ(e,t){let r,n=t?.locale??Eo(),o=new Intl.Locale(n),{calendar:a,mode:i,time:s,day:l,month:u,year:c,noToday:d,numberingSystem:f}={...EK,...{noToday:"am"===o.language},...t},p={calendar:a??Ez(o),year:c?"numeric":void 0,month:u?"short":void 0,day:l?"2-digit":void 0,numberingSystem:f},m=dQ(e).isToday();if(m&&!d)r=(r=new Intl.RelativeTimeFormat(n,{numeric:"auto"}).format(0,"day"))[0].toLocaleUpperCase(n)+r.slice(1);else{"en"===o.language&&(n="en-GB");let t=new Intl.DateTimeFormat(n,p).formatToParts(e);("en"===o.language||"am"===o.language)&&"standard"==i&&c&&l&&(t=t.map(EY("-"))),"wide"==i&&(t=t.map(EY(" — "))),"ethiopic"===p.calendar&&(t=t.filter((e,t,r)=>"era"!==e.type&&("literal"!==e.type||!(t<r.length-1)||"era"!==r[t+1].type))),r=t.map(e=>e.value).join("")}return(!0===s||m&&"for today"===s)&&(r+=`, ${Eq(e)}`),r}let EY=e=>(t,r,n)=>"literal"!==t.type||" "!==t.value||r<n.length-1&&"era"===n[r+1].type?t:{type:"literal",value:e};function Eq(e){return e.toLocaleTimeString(Eo(),{hour:"2-digit",minute:"2-digit"})}function EJ(e,t){return EZ(e,{...t,time:!0})}function EX(e,t){let r=Ez("string"==typeof t?new Intl.Locale(t):t);return r?yi(e,vL(r)):e}function EQ(e,t){return new Intl.DurationFormat(Eo(),t).format(e)}function E0(e,t){if(null==e)return null;if("string"==typeof e){let r=EP(e,Eo());return r.invalid?(console.warn(`Could not interpret '${e}' as a date`),null):(r.day&&!r.month&&(r={...nr(r,"day"),...{month:r.day}}),r.month&&(r.month-=1),r.day&&(r={...nr(r,"day"),...{date:r.day}}),dQ(t).set(r))}return dQ(e)}let E1=["years","months","days","hours","minutes","seconds"],E2={second:"seconds",minute:"minutes",hour:"hours",day:"days",month:"months",year:"years"},E4={seconds:45,minutes:45,hours:22,days:26,months:11,years:1/0};function E3(e,t=dQ(),r){let n,o=dQ(t),a=E0(e,o);if(null==a)return null;if("string"==typeof r){let e=E2[r]??r;return{[e]:o.diff(a,e)}}let{thresholds:i,largestUnit:s,smallestUnit:l}=r??{};if(void 0!==s||void 0!==l){let e,t=l?E2[l]??l:void 0;return e="auto"===s||void 0===s?function(e,t,r){let n=E1.indexOf(r);for(let o=0;o<E1.length;o++){let a=E1[o];if(t.diff(e,a)>0)return o<=n?a:r}return r}(a,o,t??"seconds"):E2[s]??s,function(e,t,r,n){let o=E1.indexOf(r),a=E1.indexOf(n),i=E1.slice(o,a+1),s={},l=e;for(let e of i){let r=t.diff(l,e);s[e]=r,l=l.add(r,e)}return s}(a,o,e,t??e)}let u=(n=function(e){let t={...E4};if(e)for(let[r,n]of Object.entries(e))void 0!==n&&(t[E2[r]??r]=n);return t}(i),o.diff(a,"seconds")<n.seconds?"seconds":o.diff(a,"minutes")<n.minutes?"minutes":o.diff(a,"hours")<n.hours?"hours":o.diff(a,"days")<n.days?"days":o.diff(a,"months")<n.months?"months":"years");return{[u]:o.diff(a,u)}}let E6={style:"short",localeMatcher:"lookup"};function E5(e,t=dQ(),r){let n=E3(e,t,r);return null==n?null:EQ(n,"object"==typeof r&&r.formatOptions?{...E6,...r.formatOptions}:E6)}let E9=(0,cu.createContext)(null);function E8(){let e=du({externalModuleName:"@openmrs/esm-styleguide"}).preferredDateLocale,t=(0,cu.useMemo)(()=>{let t=Eo();return e[t]&&(t=e[t]),t},[window.i18next.language]),r=(0,cu.useMemo)(()=>{let e=Ez(t);return void 0!==e?vL(e):void 0},[t]),n=(0,cu.useMemo)(()=>new Intl.Locale(t,{calendar:r?.identifier}),[t,r]),o=(0,cu.useMemo)(()=>r?yi(ym(yv()),r):ym(yv()),[r]);return{calendar:r,intlLocale:n,today_:o}}let E7=new gQ(1793,1,1);var xe={};function xt(){return"u">typeof window&&window.InputEvent&&"function"==typeof InputEvent.prototype.getTargetRanges}xe={"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 xr=r(137);function xn(e={}){let{locale:t}=gD();return(0,cu.useMemo)(()=>new(0,xr.K)(t,e),[t,e])}var xo={};function xa(e){var t;let r=(0,cu.useRef)(void 0),{value:n,textValue:o,minValue:a,maxValue:i,isDisabled:s,isReadOnly:l,isRequired:u,onIncrement:c,onIncrementPage:d,onDecrement:f,onDecrementPage:p,onDecrementToMin:m,onIncrementToMax:h}=e,g=yj((t=xo)&&t.__esModule?t.default:t,"@react-aria/spinbutton");(0,cu.useEffect)(()=>()=>clearTimeout(r.current),[]);let y=(0,cu.useRef)(!1),v=()=>{y.current=!0},b=()=>{y.current=!1},w=""===o?g.format("Empty"):(o||`${n}`).replace("-","−");(0,cu.useEffect)(()=>{y.current&&(mV&&mV.clear("assertive"),mW(w,"assertive"))},[w]);let E=mv(e=>{clearTimeout(r.current),null==c||c(),r.current=window.setTimeout(()=>{(void 0===i||isNaN(i)||void 0===n||isNaN(n)||n<i)&&E(60)},e)}),x=mv(e=>{clearTimeout(r.current),null==f||f(),r.current=window.setTimeout(()=>{(void 0===a||isNaN(a)||void 0===n||isNaN(n)||n>a)&&x(60)},e)}),D=e=>{e.preventDefault()},{addGlobalListener:_,removeAllGlobalListeners:S}=hD();return{spinButtonProps:{role:"spinbutton","aria-valuenow":void 0===n||isNaN(n)?void 0:n,"aria-valuetext":w,"aria-valuemin":a,"aria-valuemax":i,"aria-disabled":s||void 0,"aria-readonly":l||void 0,"aria-required":u||void 0,onKeyDown:e=>{if(!e.ctrlKey&&!e.metaKey&&!e.shiftKey&&!e.altKey&&!l)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":m&&(e.preventDefault(),null==m||m());break;case"End":h&&(e.preventDefault(),null==h||h())}},onFocus:v,onBlur:b},incrementButtonProps:{onPressStart:()=>{E(400),_(window,"contextmenu",D)},onPressEnd:()=>{clearTimeout(r.current),S()},onFocus:v,onBlur:b},decrementButtonProps:{onPressStart:()=>{x(400),_(window,"contextmenu",D)},onPressEnd:()=>{clearTimeout(r.current),S()},onFocus:v,onBlur:b}}}xo={"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 xi=r(7120);function xs(e,t,r){let n="+"===e?t+r:t-r;if(t%1!=0||r%1!=0){let o=t.toString().split("."),a=r.toString().split("."),i=Math.pow(10,Math.max(o[1]&&o[1].length||0,a[1]&&a[1].length||0));t=Math.round(t*i),r=Math.round(r*i),n=("+"===e?t+r:t-r)/i}return n}let xl=(0,cu.createContext)(null),xu=(0,cu.createContext)(null),xc=(0,cu.forwardRef)(function(e,t){var r,n;[e,t]=mL(e,t,xl);let{validationBehavior:o}=mM(wp)||{},a=null!=(n=null!=(r=e.validationBehavior)?r:o)?n:"native",{locale:i}=gD(),s=function(e){let{minValue:t,maxValue:r,step:n,formatOptions:o,value:a,defaultValue:i=NaN,onChange:s,locale:l,isDisabled:u,isReadOnly:c}=e;null===a&&(a=NaN),void 0===a||isNaN(a)||(a=void 0===n||isNaN(n)?wb(a,t,r):wE(a,t,r,n)),isNaN(i)||(i=void 0===n||isNaN(n)?wb(i,t,r):wE(i,t,r,n));let[d,f]=vK(a,isNaN(i)?NaN:i,s),[p,m]=(0,cu.useState)(()=>isNaN(d)?"":new(0,xr.K)(l,o).format(d)),h=(0,cu.useMemo)(()=>new(0,xi.d)(l,o),[l,o]),g=(0,cu.useMemo)(()=>h.getNumberingSystem(p),[h,p]),y=(0,cu.useMemo)(()=>new(0,xr.K)(l,{...o,numberingSystem:g}),[l,o,g]),v=(0,cu.useMemo)(()=>y.resolvedOptions(),[y]),b=(0,cu.useCallback)(e=>isNaN(e)||null===e?"":y.format(e),[y]),w=bB({...e,value:d}),E=void 0===n||isNaN(n)?1:n;"percent"===v.style&&(void 0===n||isNaN(n))&&(E=.01);let[x,D]=(0,cu.useState)(d),[_,S]=(0,cu.useState)(l),[C,k]=(0,cu.useState)(o);Object.is(d,x)&&l===_&&o===C||(m(b(d)),D(d),S(l),k(o));let P=(0,cu.useMemo)(()=>h.parse(p),[h,p]),O=(e,n=0)=>{if(isNaN(P))return wE(isNaN(n)?0:n,t,r,E);{let n=wE(P,t,r,E);return"+"===e&&n>P||"-"===e&&n<P?n:wE(xs(e,P,E),t,r,E)}},R=(0,cu.useMemo)(()=>!u&&!c&&(isNaN(P)||void 0===r||isNaN(r)||wE(P,t,r,E)>P||xs("+",P,E)<=r),[u,c,t,r,E,P]),T=(0,cu.useMemo)(()=>!u&&!c&&(isNaN(P)||void 0===t||isNaN(t)||wE(P,t,r,E)<P||xs("-",P,E)>=t),[u,c,t,r,E,P]);return{...w,validate:e=>h.isValidPartialNumber(e,t,r),increment:()=>{let e=O("+",t);e===d&&m(b(e)),f(e),w.commitValidation()},incrementToMax:()=>{null!=r&&(f(wE(r,t,r,E)),w.commitValidation())},decrement:()=>{let e=O("-",r);e===d&&m(b(e)),f(e),w.commitValidation()},decrementToMin:()=>{null!=t&&(f(t),w.commitValidation())},canIncrement:R,canDecrement:T,minValue:t,maxValue:r,numberValue:P,setNumberValue:f,setInputValue:m,inputValue:p,commit:()=>{let e;if(!p.length){f(NaN),m(void 0===a?"":b(d));return}isNaN(P)?m(b(d)):(e=void 0===n||isNaN(n)?wb(P,t,r):wE(P,t,r,n),f(e=h.parse(b(e))),m(b(void 0===a?e:d)))}}}({...e,locale:i,validationBehavior:a}),l=(0,cu.useRef)(null),[u,c]=mF(!e["aria-label"]&&!e["aria-labelledby"]),{labelProps:d,groupProps:f,inputProps:p,incrementButtonProps:m,decrementButtonProps:h,descriptionProps:g,errorMessageProps:y,...v}=function(e,t,r){var n,o;let a,{id:i,decrementAriaLabel:s,incrementAriaLabel:l,isDisabled:u,isReadOnly:c,isRequired:d,minValue:f,maxValue:p,autoFocus:m,label:h,formatOptions:g,onBlur:y=()=>{},onFocus:v,onFocusChange:b,onKeyDown:w,onKeyUp:E,description:x,errorMessage:D,isWheelDisabled:_,...S}=e,{increment:C,incrementToMax:k,decrement:P,decrementToMin:O,numberValue:R,inputValue:T,commit:N,commitValidation:j}=t,A=yj((o=xe)&&o.__esModule?o.default:o,"@react-aria/numberfield"),$=mR(i),{focusProps:I}=h4({onBlur(){N()}}),M=xn(g),L=(0,cu.useMemo)(()=>M.resolvedOptions(),[M]),F=xn({...g,currencySign:void 0}),B=(0,cu.useMemo)(()=>isNaN(R)?"":F.format(R),[F,R]),{spinButtonProps:U,incrementButtonProps:V,decrementButtonProps:W}=xa({isDisabled:u,isReadOnly:c,isRequired:d,maxValue:p,minValue:f,onIncrement:C,onIncrementToMax:k,onDecrement:P,onDecrementToMin:O,value:R,textValue:B}),[H,z]=(0,cu.useState)(!1),{focusWithinProps:K}=h9({isDisabled:u,onFocusWithinChange:z});!function(e,t){let{onScroll:r,isDisabled:n}=e,o=(0,cu.useCallback)(e=>{!e.ctrlKey&&(e.preventDefault(),e.stopPropagation(),r&&r({deltaX:e.deltaX,deltaY:e.deltaY}))},[r]);yQ(t,"wheel",n?void 0:o)}({onScroll:(0,cu.useCallback)(e=>{!(Math.abs(e.deltaY)<=Math.abs(e.deltaX))&&(e.deltaY>0?C():e.deltaY<0&&P())},[P,C]),isDisabled:_||u||c||!H},r);let G=(null!=(n=L.maximumFractionDigits)?n:0)>0,Z=void 0===t.minValue||isNaN(t.minValue)||t.minValue<0,Y="numeric";hn()?Z?Y="text":G&&(Y="decimal"):hl()&&(Z?Y="numeric":G&&(Y="decimal"));let q=mY(e),J=(0,cu.useCallback)(e=>{"Enter"===e.key?(N(),j()):e.continuePropagation()},[N,j]),{isInvalid:X,validationErrors:Q,validationDetails:ee}=t.displayValidation,{labelProps:et,inputProps:er,descriptionProps:en,errorMessageProps:eo}=function(e,t,r){let n=mv(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,cu.useEffect)(()=>{if(!xt()||!r.current)return;let e=r.current;return e.addEventListener("beforeinput",n,!1),()=>{e.removeEventListener("beforeinput",n,!1)}},[r,n]);let o=xt()?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:a,inputProps:i,descriptionProps:s,errorMessageProps:l,...u}=function(e,t){let{inputElementType:r="input",isDisabled:n=!1,isRequired:o=!1,isReadOnly:a=!1,type:i="text",validationBehavior:s="aria"}=e,[l,u]=vK(e.value,e.defaultValue||"",e.onChange),{focusableProps:c}=h5(e,t),d=bB({...e,value:l}),{isInvalid:f,validationErrors:p,validationDetails:m}=d.displayValidation,{labelProps:h,fieldProps:g,descriptionProps:y,errorMessageProps:v}=bP({...e,isInvalid:f,errorMessage:e.errorMessage||p}),b=mY(e,{labelable:!0}),w={type:i,pattern:e.pattern};return bk(t,l,u),bO(e,d,t),(0,cu.useEffect)(()=>{if(t.current instanceof m2(t.current).HTMLTextAreaElement){let e=t.current;Object.defineProperty(e,"defaultValue",{get:()=>e.value,set:()=>{},configurable:!0})}},[t]),{labelProps:h,inputProps:mj(b,"input"===r?w:void 0,{disabled:n,readOnly:a,required:o&&"native"===s,"aria-required":o&&"aria"===s||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:l,onChange:e=>u(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(cc().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,...g}),descriptionProps:y,errorMessageProps:v,isInvalid:f,validationErrors:p,validationDetails:m}}(e,r),c=(0,cu.useRef)(null);return{inputProps:mj(i,{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:a,descriptionProps:s,errorMessageProps:l,...u}}({...S,...q,name:void 0,label:h,autoFocus:m,isDisabled:u,isReadOnly:c,isRequired:d,validate:void 0,[bF]:t,value:T,defaultValue:void 0,autoComplete:"off","aria-label":e["aria-label"]||void 0,"aria-labelledby":e["aria-labelledby"]||void 0,id:$,type:"text",inputMode:Y,onChange:e=>{t.validate(e)&&t.setInputValue(e)},onBlur:y,onFocus:v,onFocusChange:b,onKeyDown:(0,cu.useMemo)(()=>mg(J,w),[J,w]),onKeyUp:E,description:x,errorMessage:D},t,r);bk(r,t.numberValue,t.setNumberValue);let ea=mj(U,I,er,{role:null,"aria-roledescription":ha()?null:A.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 ei=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||(a=null!=e.label?et.id:e["aria-labelledby"]);let el=mR(),eu=mR(),ec=mj(V,{"aria-label":l||A.format("increase",{fieldLabel:es}).trim(),id:a&&!l?el:null,"aria-labelledby":a&&!l?`${el} ${a}`:null,"aria-controls":$,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!t.canIncrement,onPressStart:ei}),ed=mj(W,{"aria-label":s||A.format("decrease",{fieldLabel:es}).trim(),id:a&&!s?eu:null,"aria-labelledby":a&&!s?`${eu} ${a}`:null,"aria-controls":$,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!t.canDecrement,onPressStart:ei});return{groupProps:{...K,role:"group","aria-disabled":u,"aria-invalid":X?"true":void 0},labelProps:et,inputProps:ea,incrementButtonProps:ec,decrementButtonProps:ed,errorMessageProps:eo,descriptionProps:en,isInvalid:X,validationErrors:Q,validationDetails:ee}}({...mB(e),label:c,validationBehavior:a},s,l),b=mI({...e,values:{state:s,isDisabled:e.isDisabled||!1,isInvalid:v.isInvalid||!1,isRequired:e.isRequired||!1},defaultClassName:"react-aria-NumberField"}),w=mY(e);return delete w.id,cc().createElement(m$,{values:[[xu,s],[be,f],[br,{...p,ref:l}],[wm,{...d,ref:u}],[gs,{slots:{increment:m,decrement:h}}],[gc,{slots:{description:g,errorMessage:y}}],[wc,v]]},cc().createElement("div",{...w,...b,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&&cc().createElement("input",{type:"hidden",name:e.name,value:isNaN(s.numberValue)?"":s.numberValue}))});function xd(e,t){return Number.parseInt(EZ(e,{calendar:t.calendar,locale:t.baseName,day:!1,month:!1,noToday:!0,numberingSystem:"latn"}))}let xf=(0,cu.forwardRef)(function(e,t){let{className:r}=e,n=(0,cu.useContext)(v0),o=(0,cu.useContext)(v1),a=n??o,i=(0,cu.useContext)(E9),s=yv(),l=EZ(a.visibleRange.start.toDate(s),{calendar:i.calendar,locale:i.baseName,day:!1,year:!1,noToday:!0}),u=xd(a.visibleRange.start.toDate(s),i),c=a.maxValue?xd(a.maxValue.toDate(s),i):void 0,d=a.minValue?xd(a.minValue.toDate(s),i):void 0,f=(0,cu.useCallback)(e=>{a.setFocusedDate(a.focusedDate.cycle("year",e-a.focusedDate.year))},[]);return a&&(0,fd.jsxs)("span",{ref:t,className:r,children:[(0,fd.jsx)("span",{children:l}),(0,fd.jsxs)(xc,{formatOptions:{useGrouping:!1},maxValue:c,minValue:d,onChange:f,value:u,children:[(0,fd.jsx)(bn,{}),(0,fd.jsxs)(bt,{children:[(0,fd.jsx)(gl,{slot:"increment",children:(0,fd.jsx)(f0,{size:8})}),(0,fd.jsx)(gl,{slot:"decrement",children:(0,fd.jsx)(fJ,{size:8})})]})]})]})}),xp="-esm-cohort-builder__datepicker-module__inputGroup___-wpzr",xm="-esm-cohort-builder__datepicker-module__inputSegment___ocu7L",xh="-esm-cohort-builder__datepicker-module__dateInputWrapper___909Km",xg="-esm-cohort-builder__datepicker-module__invalidText___oHJHi",xy="-esm-cohort-builder__datepicker-module__flatButton___i9LDo",xv="-esm-cohort-builder__datepicker-module__flatButtonMd___VZMkc",xb="-esm-cohort-builder__datepicker-module__flatButtonSm___VA5wy",xw="-esm-cohort-builder__datepicker-module__flatButtonLg___MnYLl";function xE({children:e}){let t=(0,cu.useContext)(w6),r=(0,cu.useContext)(w5),n=t??r,o=dV(()=>n?.close());return(0,fd.jsx)(wu,{className:"-esm-cohort-builder__datepicker-module__dialog___2pADb",ref:o,children:e})}let xx=(0,cu.forwardRef)(function({variant:e,today_:t,minDate:r,maxDate:n},o){let a="range"===e;return(0,fd.jsx)(w0,{ref:o,className:"-esm-cohort-builder__datepicker-module__popover___pb58i",placement:"bottom start",offset:1,isNonModal:!0,children:(0,fd.jsx)(xE,{children:(0,fd.jsxs)(a?v4:v2,{...a?{minValue:r,maxValue:n,className:"cds--date-picker__calendar"}:{},children:[(0,fd.jsxs)("header",{className:"-esm-cohort-builder__datepicker-module__header___+fi16",children:[(0,fd.jsx)(gl,{className:fp()(xy,xv),slot:"previous",children:(0,fd.jsx)(f9,{size:16})}),(0,fd.jsx)(xf,{className:"-esm-cohort-builder__datepicker-module__monthYear___mGhot"}),(0,fd.jsx)(gl,{className:fp()(xy,xv),slot:"next",children:(0,fd.jsx)(f8,{size:16})})]}),(0,fd.jsx)(v6,{className:"-esm-cohort-builder__datepicker-module__calendarGrid___z07wV",children:e=>(0,fd.jsx)(v7,{className:fp()("cds--date-picker__day",{"-esm-cohort-builder__datepicker-module__today___dNc4M":0===t.compare(e)}),date:e},e.toString())})]})})})}),xD=(0,cu.forwardRef)(function(e,t){let r=(0,cu.useContext)(w6),[n,o]=mL({slot:e.slot},t,b9),{locale:a}=gD(),i=b6({...n,locale:a,createCalendar:vL}),s=(0,cu.useRef)(null),{fieldProps:l,inputProps:u}=bj({...n,inputRef:s},i,o),c=(0,cu.useCallback)(()=>{i.isDisabled||r.toggle()},[]);return(0,fd.jsxs)(m$,{values:[[b8,i],[br,{...u,ref:s}],[be,{...l,ref:o,isInvalid:i.isInvalid}]],children:[(0,fd.jsx)(bt,{...e,id:e.id,ref:t,slot:e.slot||void 0,className:e.className,isDisabled:i.isDisabled,isInvalid:i.isInvalid,onClick:c,children:i.segments.map((t,r)=>(0,cu.cloneElement)(e.children(t),{key:r}))}),(0,fd.jsx)(bn,{})]})}),x_=(0,cu.forwardRef)(function(e,t){let r=(0,cu.useContext)(w6),n=(0,cu.useContext)(w5);return(r??n).isInvalid?(0,fd.jsx)(ma,{ref:t,size:16,...e}):(0,fd.jsx)(fq,{ref:t,size:16,...e})});class xS{of(e){return this.dictionary.getStringForLocale(e,this.locale)}constructor(e,t){this.locale=e,this.dictionary=t}}let xC=new Map,xk=(0,cu.forwardRef)(function({segment:e,...t},r){let n=(0,cu.useContext)(b8),o=mh(r),{segmentProps:a}=function(e,t,r){let n,o,a,i,s=(0,cu.useRef)(""),{locale:l,direction:u}=gD(),c=function(){var e;let{locale:t}=gD(),r=yN((e=bo)&&e.__esModule?e.default:e,"@react-aria/datepicker");return(0,cu.useMemo)(()=>{try{return new Intl.DisplayNames(t,{type:"dateTimeField"})}catch{return new xS(t,r)}},[t,r])}(),{ariaLabel:d,ariaLabelledBy:f,ariaDescribedBy:p,focusManager:m}=bR.get(t),h=e.isPlaceholder?"":e.text,g=(0,cu.useMemo)(()=>t.dateFormatter.resolvedOptions(),[t.dateFormatter]),y=yU({month:"long",timeZone:g.timeZone}),v=yU({hour:"numeric",hour12:g.hour12,timeZone:g.timeZone});if("month"!==e.type||e.isPlaceholder)"hour"!==e.type||e.isPlaceholder||(h=v.format(t.dateValue));else{let e=y.format(t.dateValue);h=e!==h?`${h} \u{2013} ${e}`:e}let{spinButtonProps:b}=xa({value:e.value,textValue:h,minValue:e.minValue,maxValue:e.maxValue,isDisabled:t.isDisabled,isReadOnly:t.isReadOnly||!e.isEditable,isRequired:t.isRequired,onIncrement:()=>{s.current="",t.increment(e.type)},onDecrement:()=>{s.current="",t.decrement(e.type)},onIncrementPage:()=>{s.current="",t.incrementPage(e.type)},onDecrementPage:()=>{s.current="",t.decrementPage(e.type)},onIncrementToMax:()=>{s.current="",void 0!==e.maxValue&&t.setSegment(e.type,e.maxValue)},onDecrementToMin:()=>{s.current="",void 0!==e.minValue&&t.setSegment(e.type,e.minValue)}}),w=(0,cu.useMemo)(()=>new(0,xi.d)(l,{maximumFractionDigits:0}),[l]),E=()=>{if(e.text===e.placeholder&&m.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),s.current=r}},{startsWith:x}=(n=function(e){let{locale:t}=gD(),r=t+(e?Object.entries(e).sort((e,t)=>e[0]<t[0]?-1:1).join():"");if(xC.has(r))return xC.get(r);let n=new Intl.Collator(t,e);return xC.set(r,n),n}({usage:"search",sensitivity:"base"}),o=(0,cu.useCallback)((e,t)=>0===t.length||(e=e.normalize("NFC"),t=t.normalize("NFC"),0===n.compare(e.slice(0,t.length),t)),[n]),a=(0,cu.useCallback)((e,t)=>0===t.length||(e=e.normalize("NFC"),t=t.normalize("NFC"),0===n.compare(e.slice(-t.length),t)),[n]),i=(0,cu.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 a=e.slice(r,r+o);if(0===n.compare(t,a))return!0}return!1},[n]),(0,cu.useMemo)(()=>({startsWith:o,endsWith:a,contains:i}),[o,a,i])),D=yU({hour:"numeric",hour12:!0}),_=(0,cu.useMemo)(()=>{let e=new Date;return e.setHours(0),D.formatToParts(e).find(e=>"dayPeriod"===e.type).value},[D]),S=(0,cu.useMemo)(()=>{let e=new Date;return e.setHours(12),D.formatToParts(e).find(e=>"dayPeriod"===e.type).value},[D]),C=yU({year:"numeric",era:"narrow",timeZone:"UTC"}),k=(0,cu.useMemo)(()=>{if("era"!==e.type)return[];let r=yi(new gQ(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:C.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},[C,t.calendar,e.type]),P=r=>{if(t.isDisabled||t.isReadOnly)return;let n=s.current+r;switch(e.type){case"dayPeriod":if(x(_,r))t.setSegment("dayPeriod",0);else if(x(S,r))t.setSegment("dayPeriod",12);else break;m.focusNext();break;case"era":{let e=k.find(e=>x(e.formatted,r));e&&(t.setSegment("era",e.era),m.focusNext());break}case"day":case"hour":case"minute":case"second":case"month":case"year":{if(!w.isValidPartialNumber(n))return;let o=w.parse(n),a=o,i=0===e.minValue;if("hour"===e.type&&t.dateFormatter.resolvedOptions().hour12){switch(t.dateFormatter.resolvedOptions().hourCycle){case"h11":o>11&&(a=w.parse(r));break;case"h12":i=!1,o>12&&(a=w.parse(r))}void 0!==e.value&&e.value>=12&&o>1&&(o+=12)}else void 0!==e.maxValue&&o>e.maxValue&&(a=w.parse(r));if(isNaN(o))return;let l=0!==a||i;l&&t.setSegment(e.type,a),void 0!==e.maxValue&&(Number(o+"0")>e.maxValue||n.length>=String(e.maxValue).length)?(s.current="",l&&m.focusNext()):s.current=n}}};yQ((0,cu.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 O=(0,cu.useRef)("");yQ(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":O.current=r.current.textContent,r.current.textContent=r.current.textContent;break;default:null!=n.data&&P(n.data)}}),yQ(r,"input",e=>{let{inputType:t,data:n}=e;"insertCompositionText"===t&&(r.current&&(r.current.textContent=O.current),null!=n&&(x(_,n)||x(S,n))&&P(n))}),my(()=>{let e=r.current;return()=>{document.activeElement===e&&(m.focusPrevious()||m.focusNext())}},[r,m]);let R=ha()||"timeZoneName"===e.type?{role:"textbox","aria-valuemax":null,"aria-valuemin":null,"aria-valuetext":null,"aria-valuenow":null}:{};e===(0,cu.useMemo)(()=>t.segments.find(e=>e.isEditable),[t.segments])||t.isInvalid||(p=void 0);let T=mR(),N=!t.isDisabled&&!t.isReadOnly&&e.isEditable,j="literal"===e.type?"":c.of(e.type),A=yY({"aria-label":`${j}${d?`, ${d}`:""}${f?", ":""}`,"aria-labelledby":f});if("literal"===e.type)return{segmentProps:{"aria-hidden":!0}};let $={caretColor:"transparent"};if("rtl"===u){$.unicodeBidi="embed";let t=g[e.type];("numeric"===t||"2-digit"===t)&&($.direction="ltr")}return{segmentProps:mj(b,A,{id:T,...R,"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:N,suppressContentEditableWarning:N,spellCheck:N?"false":void 0,autoCorrect:N?"off":void 0,[parseInt(cc().version,10)>=17?"enterKeyHint":"enterkeyhint"]:N?"next":void 0,inputMode:t.isDisabled||"dayPeriod"===e.type||"era"===e.type||!N?void 0:"numeric",tabIndex:t.isDisabled?void 0:0,onKeyDown:e=>{if("a"===e.key&&(hr()?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:()=>{s.current="",r.current&&y6(r.current,{containingElement:y5(r.current)});let e=window.getSelection();null==e||e.collapse(r.current)},style:$,onPointerDown(e){e.stopPropagation()},onMouseDown(e){e.stopPropagation()}})}}(e,n,o),{focusProps:i,isFocused:s,isFocusVisible:l}=h8(),{hoverProps:u,isHovered:c}=gn({...t,isDisabled:n.isDisabled||"literal"===e.type}),d=function(e){let{className:t,style:r,children:n,defaultClassName:o,defaultChildren:a,defaultStyle:i,values:s}=e;return(0,cu.useMemo)(()=>{let e,l,u;return e="function"==typeof t?t({...s,defaultClassName:o}):t,l="function"==typeof r?r({...s,defaultStyle:i||{}}):r,u="function"==typeof n?n({...s,defaultChildren:a}):null==n?a:n,{className:e??o,style:l||i?{...i,...l}:void 0,children:u??a,"data-rac":""}},[t,r,n,o,a,i,s])}({...t,values:{...e,isReadOnly:!e.isEditable,isInvalid:n.isInvalid,isDisabled:n.isDisabled,isHovered:c,isFocused:s,isFocusVisible:l},defaultChildren:e.text}),f=(0,cu.useCallback)(e=>{e.stopPropagation()},[]);return(0,fd.jsx)("span",{...mj(mY(t),a,i,u),...d,ref:o,style:a.style,"data-placeholder":e.isPlaceholder||void 0,"data-invalid":n.isInvalid||void 0,"data-readonly":!e.isEditable||void 0,"data-disabled":n.isDisabled||void 0,"data-type":e.type,"data-hovered":c||void 0,"data-focused":s||void 0,"data-focus-visible":l||void 0,onClick:f})}),xP={short:!1,size:"md"},xO=(0,cu.forwardRef)(function(e,t){let{className:r,defaultValue:n,isDisabled:o,invalid:a,invalidText:i,isInvalid:s,label:l,labelText:u,light:c,maxDate:d,minDate:f,onChange:p,onChangeRaw:m,short:h,size:g,value:y,...v}={...xP,...e},{calendar:b,intlLocale:w,today_:E}=E8(),x=(0,cu.useId)(),D=!!(u??l),_=(0,cu.useMemo)(()=>Ee(n,b),[n,b]),S=(0,cu.useMemo)(()=>Ee(y,b,!0),[y,b]),C=(0,cu.useMemo)(()=>Ee(d,b),[d,b]),k=(0,cu.useMemo)(()=>Ee(f??E7,b),[f,b]),P=(0,cu.useMemo)(()=>a||s,[a,s]),O=(0,cu.useMemo)(()=>(m&&p&&console.error("An OpenmrsDatePicker component was created with both onChange and onChangeRaw handlers defined. Only onChangeRaw will be used."),m??(e=>p?.(Et(e)))),[m,p]);return(0,fd.jsx)(w7,{locale:w.toString(),children:(0,fd.jsx)("div",{className:fp()("cds--form-item",r),children:(0,fd.jsx)(m$,{values:[[E9,w]],children:(0,fd.jsxs)(w9,{className:fp()("cds--date-picker","cds--date-picker--single",{"cds--date-picker--short":h,"cds--date-picker--light":c}),defaultValue:_,isDisabled:o,isInvalid:P,maxValue:C,minValue:k,value:S,shouldForceLeadingZeros:"en"===w.language||void 0,...v,onChange:O,children:[(0,fd.jsxs)("div",{className:"cds--date-picker-container",children:[D&&(0,fd.jsx)(wh,{className:fp()("cds--label",{"cds--label--disabled":o}),htmlFor:x,children:u??l}),(0,fd.jsxs)(bt,{className:xp,children:[(0,fd.jsx)(xD,{id:D?x:void 0,ref:t,className:fp()("cds--date-picker-input__wrapper","-esm-cohort-builder__datepicker-module__inputWrapper___MHJAy",{"-esm-cohort-builder__datepicker-module__inputWrapperSm___esx4E":"sm"===g,"-esm-cohort-builder__datepicker-module__inputWrapperMd___VQbzP":"md"===g||!g||0===g.length,"-esm-cohort-builder__datepicker-module__inputWrapperLg___Rk9Ce":"lg"===g}),children:e=>"era"!==e.type?(0,fd.jsx)(xk,{className:xm,segment:e}):(0,fd.jsx)(cc().Fragment,{})}),(0,fd.jsx)(gl,{className:fp()(xy,{[xb]:"sm"===g,[xv]:"md"===g||!g||0===g.length,[xw]:"lg"===g}),children:(0,fd.jsx)(x_,{})})]}),(0,fd.jsx)(wd,{className:xg,children:i})]}),(0,fd.jsx)(xx,{variant:"single",today_:E})]})})})})}),xR=(0,cu.forwardRef)(function({className:e,defaultValue:t,invalid:r,invalidText:n,isDisabled:o,isInvalid:a,label:i,labelText:s,light:l,maxDate:u,minDate:c,onChange:d,onChangeRaw:f,size:p="md",value:m,...h},g){let{calendar:y,intlLocale:v,today_:b}=E8(),w=(0,cu.useId)(),E=!!(s??i),x=(0,cu.useMemo)(()=>{if(m)return{start:Ee(m[0],y,!1),end:Ee(m[1],y,!1)}},[m,y]),D=(0,cu.useMemo)(()=>{if(t)return{start:Ee(t[0],y,!1),end:Ee(t[1],y,!1)}},[t,y]),_=(0,cu.useMemo)(()=>Ee(c??E7,y,!0),[c,y]),S=(0,cu.useMemo)(()=>Ee(u,y,!0),[u,y]),C=(0,cu.useMemo)(()=>r||a,[r,a]),k=(0,cu.useMemo)(()=>(f&&d&&console.error("An OpenmrsDateRangePicker component was created with both onChange and onChangeRaw handlers defined. Only onChangeRaw will be used."),f??(e=>d?.([Et(e.start),Et(e.end)]))),[f,d]);return(0,fd.jsx)(w7,{locale:v.toString(),children:(0,fd.jsx)("div",{className:fp()("cds--form-item",e),children:(0,fd.jsx)(m$,{values:[[E9,v]],children:(0,fd.jsx)(w8,{id:E?w:void 0,className:fp()("cds--date-picker",{"cds--date-picker--light":l,"cds--date-picker--disabled":o}),isInvalid:C,shouldForceLeadingZeros:"en"===v.language||void 0,maxValue:S,minValue:_,value:x,defaultValue:D,ref:g,isDisabled:o,...h,onChange:k,children:(0,fd.jsxs)("div",{className:"cds--date-picker-container",children:[E&&(0,fd.jsx)(wh,{className:fp()("cds--label",{"cds--label--disabled":o}),htmlFor:w,children:s??i}),(0,fd.jsxs)(bt,{className:xp,children:[(0,fd.jsxs)("div",{className:fp()("-esm-cohort-builder__datepicker-module__inputsWrapper___UyGoG",{"-esm-cohort-builder__datepicker-module__inputsWrapperSm___qrGsA":"sm"===p,"-esm-cohort-builder__datepicker-module__inputsWrapperMd___pofu4":"md"===p||!p||0===p.length,"-esm-cohort-builder__datepicker-module__inputsWrapperLg___eF1Im":"lg"===p}),children:[(0,fd.jsx)(we,{className:fp()("cds--date-picker-input__wrapper","-esm-cohort-builder__datepicker-module__startInput___C8vnM",xh),slot:"start",children:e=>(0,fd.jsx)(xk,{className:xm,segment:e})}),(0,fd.jsx)("div",{className:"-esm-cohort-builder__datepicker-module__separator___vHLFZ",children:(0,fd.jsx)("span",{"aria-hidden":"true","data-readonly":!0,children:"–"})}),(0,fd.jsx)(we,{className:fp()("cds--date-picker-input__wrapper","-esm-cohort-builder__datepicker-module__endInput___25OF9",xh),slot:"end",children:e=>(0,fd.jsx)(xk,{className:xm,segment:e})})]}),(0,fd.jsx)(gl,{className:fp()(xy,{[xb]:"sm"===p,[xv]:"md"===p||!p||0===p.length,[xw]:"lg"===p}),children:(0,fd.jsx)(x_,{})})]}),(0,fd.jsx)(wd,{className:xg,children:n}),(0,fd.jsx)(xx,{variant:"range",today_:b,minDate:_,maxDate:S})]})})})})})}),xT=({diagnoses:e})=>{let{diagnosisTags:t}=du({externalModuleName:"@openmrs/esm-styleguide"});return(0,fd.jsx)("div",{className:"-esm-cohort-builder__diagnosis-tags-module__container___l7XiW",children:e.map(e=>{let{rank:r,uuid:n,display:o}=e,a=t[1===r?"primaryColor":"secondaryColor"];return(0,fd.jsx)(fv.Tag,{type:a,children:o},n)})})},xN={action:"-esm-cohort-builder__empty-card-module__action___l4wUo",content:"-esm-cohort-builder__empty-card-module__content___XbsSJ",desktopHeading:"-esm-cohort-builder__empty-card-module__desktopHeading___0EPXX",tabletHeading:"-esm-cohort-builder__empty-card-module__tabletHeading___unl1F",tile:"-esm-cohort-builder__empty-card-module__tile___vS3Sj"},xj=({width:e="64",height:t="64"})=>(0,fd.jsx)("svg",{width:e,height:t,viewBox:"0 0 64 64",children:(0,fd.jsx)("use",{href:"#omrs-empty-data-illustration"})}),xA=e=>{let t="tablet"===dI(),r=e.launchForm;return(0,fd.jsx)(fv.Layer,{className:xN.layer,children:(0,fd.jsxs)(fv.Tile,{className:xN.tile,children:[(0,fd.jsx)("div",{className:t?xN.tabletHeading:xN.desktopHeading,children:(0,fd.jsx)("h4",{children:e.headerTitle})}),(0,fd.jsx)(xj,{}),(0,fd.jsx)("p",{className:xN.content,children:iK("emptyStateText","There are no {{displayText}} to display",{displayText:e.displayText})}),(0,fd.jsx)("p",{className:xN.action,children:r&&(0,fd.jsx)(fv.Button,{onClick:()=>r(),kind:"ghost",size:t?"lg":"sm",children:iK("recordNewEntry","Record {{ displayText }}",{displayText:e.displayText})})})]})})},x$=({error:e,headerTitle:t})=>{let r="tablet"===dI();return(0,fd.jsx)(fv.Layer,{children:(0,fd.jsxs)(fv.Tile,{className:"-esm-cohort-builder__error-state-module__tile___hHM56",children:[(0,fd.jsx)("div",{className:r?"-esm-cohort-builder__error-state-module__tabletHeading___W7a4U":"-esm-cohort-builder__error-state-module__desktopHeading___VL8Rv",children:(0,fd.jsx)("h4",{children:t})}),(0,fd.jsxs)("p",{className:"-esm-cohort-builder__error-state-module__errorMessage___IytZy",children:[iK("error","Error")," ",`${e?.response?.status}: `,e?.response?.statusText]}),(0,fd.jsx)("p",{className:"-esm-cohort-builder__error-state-module__errorCopy___E1yZO",children:iK("errorCopy")})]})})},xI=x$,xM=cc().forwardRef((e,t)=>{let{slotName:r,basePath:n,componentContext:o,state:a}=dF(),i=window.location??{pathname:""},s=c_(r??"");return e.isChildOfHeader&&r&&s.length>0?(0,fd.jsxs)(fv.SideNav,{"aria-label":iK("leftNavigation","Left navigation"),className:"-esm-cohort-builder__left-nav-module__leftNav___ZqLpw",expanded:!0,isFixedNav:!0,ref:t,...e,children:[(0,fd.jsx)(ck,{name:"global-nav-menu-slot"}),r?(0,fd.jsx)(c8,{value:o,fallback:(0,fd.jsx)(ck,{name:r,state:{basePath:n,currentPath:i,...a}}),children:(0,fd.jsx)(cd.Provider,{value:o,children:(0,fd.jsx)(ck,{name:r,state:{basePath:n,currentPath:i,...a}})})}):null]}):null}),xL=({selectedLocationUuid:e,defaultLocationUuid:t,locationTag:r,locationsPerRequest:n=50,onChange:o})=>{let[a,i]=(0,cu.useState)(""),s=(0,cu.useId)(),{location:l}=function(e){let t=e?`/ws/fhir2/R4/Location?_id=${e}`:null,{data:r,error:n,isLoading:o}=dp()(t,i7,{shouldRetryOnError:e=>!!e?.response?.status&&e.response.status>=500});return(0,cu.useMemo)(()=>({location:r?.data?.entry?r.data.entry[0]:null,error:t?n:null,isLoading:!!t&&o}),[r,o,n,t])}(t),{locations:u,isLoading:c,hasMore:d,loadingNewData:f,error:p,setPage:m}=function(e,t=0,r=""){let n=dd(r),{data:o,isLoading:a,isValidating:i,setSize:s,error:l}=dP()(function(r,o){if(o){let e=o.data?.link?.find(e=>"next"===e.relation);if(!e)return null;let t=new URL(e.url);return t.origin===window.location.origin?e.url:new URL(`${t.pathname}${t.search?`?${t.search}`:""}`,window.location.origin).toString()}let a=`${i5}/Location?`,i=new URLSearchParams;return i.append("_summary","data"),t&&i.append("_count",""+t),r&&i.append("_getpagesoffset",""+r*t),e&&i.append("_tag",e),"string"==typeof n&&""!==n&&i.append("name:contains",n),a+i.toString()},i7);return(0,cu.useMemo)(()=>({locations:o?.length?o?.flatMap(e=>e?.data?.entry??[]):[],isLoading:a,totalResults:o?.[0]?.data?.total,hasMore:!!o?.length&&o?.[o.length-1]?.data?.link?.some(e=>"next"===e.relation),loadingNewData:i,error:l||null,setPage:s}),[a,o,i,s,l])}(r,n,a),h=(0,cu.useMemo)(()=>l&&!a&&t?[l,...u.filter(({resource:e})=>e.id!==t)]:u??[],[l,u,t,a]),g=(0,cu.useCallback)(e=>{o(),i(e.trim())},[o]),y=dW((0,cu.useCallback)(()=>{!f&&d&&m(e=>e+1)},[f,d,m])),v=d?Math.max(0,Math.floor(h.length-n/2)):-1;return(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)(fv.Search,{"aria-describedby":p?`${s}-error`:void 0,labelText:iK("searchForLocation"),id:s,placeholder:iK("searchForLocation"),onChange:e=>g(e.target.value),size:"lg"}),p&&(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__errorNotification___MBWvf",id:`${s}-error`,children:(0,fd.jsx)(fv.InlineNotification,{kind:"error",subtitle:iK("errorLoadingLoginLocations","Unable to load login locations. Please try again or contact support if the problem persists."),title:iK("error","Error")})}),(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__searchResults___aCL93",children:c?(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__loadingContainer___Vn1H0",children:Array.from({length:5}).map((e,t)=>(0,fd.jsx)(fv.RadioButtonSkeleton,{className:"-esm-cohort-builder__location-picker-module__radioButtonSkeleton___RKMHj",role:"progressbar"},t))}):(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__locationResultsContainer___5yuvs",children:h.length>0?(0,fd.jsx)(fv.RadioButtonGroup,{name:"loginLocations",onChange:e=>{o(e?.toString())},orientation:"vertical",valueSelected:e,children:h.map((e,t)=>(0,fd.jsx)(fv.RadioButton,{className:"-esm-cohort-builder__location-picker-module__locationRadioButton___b52LI",id:e.resource.id,labelText:(0,fd.jsx)("span",{ref:t===v?y:null,children:e.resource.name}),name:e.resource.name,value:e.resource.id},e.resource.id))}):(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__emptyState___qiPqQ",children:(0,fd.jsx)("p",{className:"-esm-cohort-builder__location-picker-module__locationNotFound___tKDOJ",children:iK("noResultsToDisplay")})})}),f&&(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__loadingIcon___PGwvc",children:(0,fd.jsx)(fv.InlineLoading,{description:iK("loading")})})]})})]})},xF=B("modalState",{modalContainer:null,modalStack:[]}),xB=0;async function xU(e,t,r={}){let n=u4(t),o=null;if(e){if(!n)throw Error(`No modal named '${t}' has been registered.`);let{load:a}=n,i=await a(),s=xB++;o=await ca({...i,name:`${t}-${s}`},{...r,domElement:e})}else k(`Failed to launch modal. Please notify your administrator. Modal name: ${t}`);return o}function xV(e){return"TO_BE_DELETED"===e.state||"DELETED"===e.state}function xW(e,t){t?.unmount&&(t.unmountPromise?.catch(()=>{}),t.unmount().catch(t=>{console.error(`The modal '${e}' failed to unmount`,t)}))}function xH(e){return e.find(e=>!xV(e))}function xz(e,t){e.container&&(e.container.style.visibility=t?"unset":"hidden")}let xK=window.getComputedStyle(document.body).overflow;function xG({modalStack:e,modalContainer:t}){if(t)if(e.length){t.style.visibility||(addEventListener("keydown",xY),document.body.style.overflow="hidden",t.style.visibility="unset");let r=xH(e);e.forEach(e=>{switch(e.state){case"NEW":{let r=function({size:e}){let t=document.createElement("div");return t.className=`cds--modal-container cds--modal-container--${e}`,t.setAttribute("role","dialog"),t.setAttribute("tabindex","-1"),t.setAttribute("aria-modal","true"),t}({size:e.props?.size??"md"});e.container=r,e.state="MOUNTING",xU(r,e.modalName,e.props).then(n=>{xV(e)?xW(e.modalName,n):n?(e.parcel=n,t.prepend(r),xz(e,xH(xF.getState().modalStack)===e),n.mountPromise.then(()=>{xV(e)||(e.state="MOUNTED")},t=>{k(t),e.parcel=null,xZ(e)})):xZ(e)},t=>{k(t),xZ(e)});break}case"MOUNTING":case"MOUNTED":xz(e,e===r);break;case"TO_BE_DELETED":e.state="DELETED",e.onClose(),xW(e.modalName,e.parcel),e.container?.remove(),setTimeout(()=>{let t=xF.getState();xF.setState({...t,modalStack:t.modalStack.filter(t=>t!==e)})},0)}})}else t.style.removeProperty("visibility"),document.body.style.overflow=xK,removeEventListener("keydown",xY)}function xZ(e){if(xV(e))return;e.state="TO_BE_DELETED";let t=xF.getState();xF.setState({...t,modalStack:[...t.modalStack]})}function xY(e){"Escape"===e.key&&function(){let[e]=xF.getState().modalStack;e&&xZ(e)}()}function xq(e){xF.subscribe(xG),xF.setState({...xF.getState(),modalContainer:e})}function xJ(e,t={},r=()=>{}){let n=()=>{let e=xF.getState().modalStack.find(e=>e.onClose===r);e&&xZ(e)};if(u4(e)){var o;let a,i;o={state:"NEW",onClose:r,modalName:e,props:{close:n,...t}},i=[o,...(a=xF.getState()).modalStack],xF.setState({...a,modalStack:i})}else k(`Failed to launch modal. Please notify your administrator. Modal name: "${e}"`);return n}var xX=Object.prototype.hasOwnProperty;let xQ=function(e){if(null==e)return!0;if(tn(e)&&(tt(e)||"string"==typeof e||"function"==typeof e.splice||ts(e)||tg(e)||te(e)))return!e.length;var t=rh(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(e3(e))return!t6(e).length;for(var r in e)if(xX.call(e,r))return!1;return!0},x0=({notification:e})=>{let{description:t,action:r,kind:n,critical:o,title:a,onAction:i}=e;return(0,fd.jsx)(fv.ActionableNotification,{actionButtonLabel:r,kind:n||"info",lowContrast:o,subtitle:t,title:a||"",inline:!0,onActionButtonClick:i})},x1=({subject:e})=>{let[t,r]=(0,cu.useState)([]);return(0,cu.useEffect)(()=>{let t=e.subscribe(e=>r(t=>[...t.filter(t=>t.description!==e.description||t.action!==e.action||t.kind!==e.kind||t.title!==e.title),e]));return()=>t.unsubscribe()},[e]),(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsx)(x0,{notification:e},e.id))})},x2=({notification:e})=>{let{actionButtonLabel:t,onActionButtonClick:r=()=>{},subtitle:n,kind:o,title:a,critical:i,progressActionLabel:s,id:l,...u}=e,[c,d]=(0,cu.useState)(t);return(0,fd.jsx)(fv.ActionableNotification,{kind:o||"info",actionButtonLabel:c,ariaLabel:iK("closesActionableNotification","Closes actionable notification"),onActionButtonClick:()=>{r(),s&&d(s)},statusIconDescription:iK("actionableNotification","Actionable notification"),subtitle:n,title:a,lowContrast:i,inline:!0,...u})},x4=({subject:e})=>{let[t,r]=(0,cu.useState)([]);return(0,cu.useEffect)(()=>{let t=e.subscribe(e=>r(t=>[...t.filter(t=>t.subtitle!==e.subtitle||t.actionButtonLabel!==e.actionButtonLabel||t.onActionButtonClick!==e.onActionButtonClick||t.kind!==e.kind||t.title!==e.title),e]));return()=>t.unsubscribe()},[e]),(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsx)(x2,{notification:e},e.id))})};class x3{subscribe(e){return this.listeners.add(e),{unsubscribe:()=>{this.listeners.delete(e)}}}next(e){for(let t of[...this.listeners])t(e)}constructor(){!function(e,t,r){t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r}(this,"listeners",new Set)}}let x6=new x3,x5=0,x9=new x3,x8=0;function x7(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(x1,{subject:x6}))}function De(e){var t;e&&("string"==typeof(t=e.description)?t.trim().length>0:"object"==typeof t&&(t instanceof Error||!xQ(t)))?(e.description instanceof Error&&(e.description=e.description.toLocaleString()),setTimeout(()=>{x6.next({...e,id:x5++})},0)):console.error("showNotification must be called with an object having a 'description' property that is a non-empty string or object")}function Dt(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(x4,{subject:x9}))}function Dr(e){var t;e&&("string"==typeof(t=e.actionButtonLabel)?t.trim().length>0:"object"==typeof t&&!xQ(t))?setTimeout(()=>{x9.next({...e,id:x8++})},0):console.error("showActionableNotification must be called with an actionButtonLabel that is a non-empty string")}let Dn=["NORMAL","HIGH","CRITICALLY_HIGH","OFF_SCALE_HIGH","LOW","CRITICALLY_LOW","OFF_SCALE_LOW"],Do=["critically_low","critically_high","high","low","normal","off_scale_low","off_scale_high"],Da={container:"-esm-cohort-builder__numeric-observation-module__container___+Kqi9",card:"-esm-cohort-builder__numeric-observation-module__card___Q-ECG","abnormal-value":"-esm-cohort-builder__numeric-observation-module__abnormal-value___bx1h9","critical-value":"-esm-cohort-builder__numeric-observation-module__critical-value___nSKSX",cell:"-esm-cohort-builder__numeric-observation-module__cell___wc90e","critically-high":"-esm-cohort-builder__numeric-observation-module__critically-high___fmZfJ","critically-low":"-esm-cohort-builder__numeric-observation-module__critically-low___h9797",high:"-esm-cohort-builder__numeric-observation-module__high___0-YpP",low:"-esm-cohort-builder__numeric-observation-module__low___TuqAk","label-container":"-esm-cohort-builder__numeric-observation-module__label-container___FtozC","value-container":"-esm-cohort-builder__numeric-observation-module__value-container___R9qoY",label:"-esm-cohort-builder__numeric-observation-module__label___0DGA5",value:"-esm-cohort-builder__numeric-observation-module__value___ohqoh",units:"-esm-cohort-builder__numeric-observation-module__units___xvMd3","pad-right":"-esm-cohort-builder__numeric-observation-module__pad-right___umcen","off-scale-low":"-esm-cohort-builder__numeric-observation-module__off-scale-low___my+0i","off-scale-high":"-esm-cohort-builder__numeric-observation-module__off-scale-high___so9dv",arrow:"-esm-cohort-builder__numeric-observation-module__arrow___Agoh9"},Di=({value:e,unit:t,label:r,interpretation:n,referenceRange:o,conceptUuid:a,variant:i="card",patientUuid:s})=>{let l=(0,cu.useId)(),{referenceRange:u,isLoading:c}=function(e,t){let r=null;e&&(r=t?`${i6}/conceptreferencerange/?patient=${t}&concept=${e}&v=full`:`${i6}/conceptreferencerange/?concept=${e}&v=full`);let{data:n,error:o,isLoading:a}=dp()(r,i7),i=n?.data?.results?.[0];return{referenceRange:i?{hiNormal:i.hiNormal??null,hiAbsolute:i.hiAbsolute??null,hiCritical:i.hiCritical??null,lowNormal:i.lowNormal??null,lowAbsolute:i.lowAbsolute??null,lowCritical:i.lowCritical??null}:void 0,error:o,isLoading:a}}(o||n?void 0:a,s),d=o??u,f=(0,cu.useMemo)(()=>{if(n)return n?"--"===n?"normal":Dn.includes(n)?n.toLowerCase():Do.includes(n)?n:"normal":void 0;if(d&&!c){if(!d||null==e||""===e)return"normal";let t="string"==typeof e?Number.parseFloat(e):e;return Number.isNaN(t)?"normal":null!==d.hiAbsolute&&void 0!==d.hiAbsolute&&t>d.hiAbsolute?"off_scale_high":null!==d.hiCritical&&void 0!==d.hiCritical&&t>=d.hiCritical?"critically_high":null!==d.hiNormal&&void 0!==d.hiNormal&&t>d.hiNormal?"high":null!==d.lowAbsolute&&void 0!==d.lowAbsolute&&t<d.lowAbsolute?"off_scale_low":null!==d.lowCritical&&void 0!==d.lowCritical&&t<=d.lowCritical?"critically_low":null!==d.lowNormal&&void 0!==d.lowNormal&&t<d.lowNormal?"low":"normal"}return"normal"},[n,d,e,c])??"normal",p="critically_low"===f||"critically_high"===f||"off_scale_low"===f||"off_scale_high"===f,m="normal"!==f,h=r?`omrs-numeric-obs-label-${r.replaceAll(/\s+/g,"-").toLowerCase()}-${l}`:void 0,g=`omrs-numeric-obs-value-${l}`,y=`omrs-numeric-obs-unit-${l}`,v=null!=e&&""!==e,b=v?e:iK("notAvailable","Not available"),w=fp()({[Da["critically-low"]]:"critically_low"===f||"off_scale_low"===f,[Da["critically-high"]]:"critically_high"===f||"off_scale_high"===f,[Da.low]:"low"===f,[Da.high]:"high"===f,[Da["off-scale-low"]]:"off_scale_low"===f,[Da["off-scale-high"]]:"off_scale_high"===f}),E=fp()({[Da.container]:!0,[Da.card]:!0,[Da["critical-value"]]:p,[Da["abnormal-value"]]:m&&!p}),x=fp()({[Da.cell]:!0,[w]:!0});return"cell"===i?(0,fd.jsxs)("div",{className:x,children:[b,v&&t?` ${t}`:""]}):(0,fd.jsxs)("section",{className:E,"data-testid":"numeric-observation-card",children:[r&&(0,fd.jsxs)("div",{className:Da["label-container"],children:[(0,fd.jsx)("span",{id:h,className:Da.label,children:r}),m&&(0,fd.jsx)("span",{className:Da[f.replace("_","-")],title:iK("abnormalValue","Abnormal value")})]}),(0,fd.jsxs)("div",{className:Da["value-container"],children:[(0,fd.jsx)("span",{id:g,"aria-labelledby":h&&y?`${h} ${y}`:h||y||void 0,className:Da.value,children:b}),v&&t&&(0,fd.jsx)("span",{id:y,className:Da.units,children:t})]})]})},Ds="-esm-cohort-builder__page-header-module__pageHeader___XNJYe",Dl=e=>{if("children"in e){let{children:t,className:r,...n}=e;return(0,fd.jsx)("div",{className:fp()(Ds,r),...n,children:t})}{let{title:t,illustration:r,className:n,...o}=e;return(0,fd.jsx)("div",{className:fp()(Ds,n),...o,children:(0,fd.jsx)(Du,{title:t,illustration:r})})}},Du=({title:e,illustration:t,className:r})=>{let[n,o]=(0,cu.useState)(null);return(0,cu.useEffect)(()=>{nY("@openmrs/esm-styleguide").then(e=>{o(e)})},[]),(0,fd.jsxs)("div",{className:fp()("-esm-cohort-builder__page-header-module__pageHeaderContent___V-mTz",r),children:[t,(0,fd.jsxs)("div",{className:"-esm-cohort-builder__page-header-module__pageLabels___vGJvg",children:[n?.implementationName&&(0,fd.jsx)("p",{children:iK(n.implementationName)}),(0,fd.jsx)("p",{className:"-esm-cohort-builder__page-header-module__pageName___+eYMc",children:e})]})]})},Dc=({totalItems:e,pageSize:t,onPageNumberChange:r,pageNumber:n,dashboardLinkUrl:o,currentItems:a,dashboardLinkLabel:i})=>{let{pageSizes:s,pageItemsCount:l}=dK(t,e,n,a),u="tablet"===dI(),c=iK("paginationItemsCount","{{pageItemsCount}} / {{totalItems}} items",{totalItems:e,pageItemsCount:l});return(0,fd.jsx)(fd.Fragment,{children:e>0&&(0,fd.jsxs)("div",{className:fp()({"-esm-cohort-builder__pagination-module__tablet___DdaYk":u,"-esm-cohort-builder__pagination-module__desktop___rSwlo":!u}),children:[(0,fd.jsxs)("div",{children:[c,o&&(0,fd.jsx)(cf,{to:o,className:"-esm-cohort-builder__pagination-module__configurableLink___cTCLf",children:i??iK("seeAll","See all")})]}),(0,fd.jsx)(fv.Pagination,{className:"-esm-cohort-builder__pagination-module__pagination___U6anZ",page:n,pageSize:t,pageSizes:s,totalItems:e,onChange:r,pageRangeText:(e,t)=>iK("paginationOfPages","of {{count}} pages",{count:t}),size:u?"lg":"sm"})]})})};function Dd(e){return Dp(Dh(e,"usual","official"))}function Df(e){return Dd(e)}function Dp(e){var t;let r;return e?e.text??(r=(t=e).given??[],(t.family?r.concat(t.family):r).join(" ")):""}function Dm(e){return Dp(e)}function Dh(e,...t){for(let r of(0==t.length&&(t=["usual"]),t)){let t=e.name?.find(e=>{var t,n;return t=e,n=r,t.use?t.use===n:"usual"===n});if(t)return t}}function Dg(e,t=dQ()){let r=dQ(t),n=E0(e,r);if(null==n)return null;let o=r.diff(n,"hours"),a=r.diff(n,"days"),i=r.diff(n,"weeks"),s=r.diff(n,"months"),l=r.diff(n,"years"),u={};if(o<2)u.minutes=r.diff(n,"minutes");else if(a<2)u.hours=o;else if(i<4)u.days=a;else if(l<1){let e=r.subtract(i,"weeks").diff(n,"days");u.weeks=i,u.days=e}else if(l<2){let e=r.subtract(s,"months").diff(n,"days");u.months=s,u.days=e}else if(l<18){let e=r.subtract(l,"year").diff(n,"months");u.years=l,u.months=e}else u.years=l;return u}function Dy(e,t=dQ()){let r=Dg(e,t);if(null==r)return null;let n={style:"short",localeMatcher:"lookup"};return"minutes"in r&&0===r.minutes&&(n.minutesDisplay="always"),EQ(r,n)}let Dv={container:"-esm-cohort-builder__patient-banner-patient-info-module__container___WV40g",activePatientContainer:"-esm-cohort-builder__patient-banner-patient-info-module__activePatientContainer___YBgYK",patientBanner:"-esm-cohort-builder__patient-banner-patient-info-module__patientBanner___o-DQc",patientName:"-esm-cohort-builder__patient-banner-patient-info-module__patientName___KWLAJ",patientAvatar:"-esm-cohort-builder__patient-banner-patient-info-module__patientAvatar___gG4I3",patientAvatarButton:"-esm-cohort-builder__patient-banner-patient-info-module__patientAvatarButton___by4L9",patientInfo:"-esm-cohort-builder__patient-banner-patient-info-module__patientInfo___VU1fL",demographics:"-esm-cohort-builder__patient-banner-patient-info-module__demographics___xDHsd",row:"-esm-cohort-builder__patient-banner-patient-info-module__row___MlVwp",flexRow:"-esm-cohort-builder__patient-banner-patient-info-module__flexRow___9Aj3s",tagsSlot:"-esm-cohort-builder__patient-banner-patient-info-module__tagsSlot___PqCHJ",identifiers:"-esm-cohort-builder__patient-banner-patient-info-module__identifiers___bbREn",identifier:"-esm-cohort-builder__patient-banner-patient-info-module__identifier___HQzz8",primaryIdentifier:"-esm-cohort-builder__patient-banner-patient-info-module__primaryIdentifier___ocKCs",secondaryIdentifier:"-esm-cohort-builder__patient-banner-patient-info-module__secondaryIdentifier___4MLDH",value:"-esm-cohort-builder__patient-banner-patient-info-module__value___tkQTC",tag:"-esm-cohort-builder__patient-banner-patient-info-module__tag___u7Kco",gender:"-esm-cohort-builder__patient-banner-patient-info-module__gender___7eQuO",separator:"-esm-cohort-builder__patient-banner-patient-info-module__separator___CZBA8",tooltipPadding:"-esm-cohort-builder__patient-banner-patient-info-module__tooltipPadding___UQr5s",tooltipSmallText:"-esm-cohort-builder__patient-banner-patient-info-module__tooltipSmallText___MRUhY",actionsButtonText:"-esm-cohort-builder__patient-banner-patient-info-module__actionsButtonText___8ZC1R"};function Db({showIdentifierLabel:e,type:t,value:r}){return(0,fd.jsx)("span",{className:Dv.primaryIdentifier,children:(0,fd.jsxs)(fv.Tag,{className:Dv.tag,type:"gray",children:[e&&t?.text&&(0,fd.jsxs)("span",{className:Dv.label,children:[t.text,": "]}),(0,fd.jsx)("span",{className:Dv.value,children:r})]})})}function Dw({showIdentifierLabel:e,type:t,value:r}){return(0,fd.jsxs)(fv.FormLabel,{className:Dv.secondaryIdentifier,id:`patient-banner-identifier-${r}`,children:[e&&(0,fd.jsxs)("span",{className:Dv.label,children:[t?.text,": "]}),(0,fd.jsx)("span",{className:Dv.value,children:r})]})}function DE({identifiers:e,showIdentifierLabel:t}){let{excludePatientIdentifierCodeTypes:r}=du(),{primaryIdentifierCode:n}=dY(),o=e?.filter(e=>{let t=e.type?.coding?.[0]?.code;return t&&!r?.uuids.includes(t)})??[];return(0,fd.jsx)(fd.Fragment,{children:o?.length?o.map(({value:e,type:r},a)=>(0,fd.jsxs)(cc().Fragment,{children:[(0,fd.jsx)("span",{className:Dv.identifier,children:r?.coding?.[0]?.code===n?(0,fd.jsx)(Db,{showIdentifierLabel:t,type:r,value:e}):(0,fd.jsx)(Dw,{showIdentifierLabel:t,type:r,value:e})}),a<o.length-1&&(0,fd.jsx)("span",{className:Dv.separator,children:"\xb7"})]},e)):""})}let Dx={Female:pc,Male:pd,Other:pf,Unknown:pp},DD=({gender:e})=>{let t=Dx[e];return t?(0,fd.jsx)(t,{fill:"#525252"}):null},D_={male:"Male",female:"Female",other:"Other",unknown:"Unknown"};function DS({patient:e,renderedFrom:t}){var r;let n,o,a=Dd(e),i=e?.gender&&(o=D_[n=(r=e.gender).toLowerCase()]??"Unknown",{displayText:iK(n,r),iconKey:o}),s=(0,cu.useMemo)(()=>({patientUuid:e.id,patient:e,renderedFrom:t}),[e.id,e,t]);return(0,fd.jsxs)("div",{className:Dv.patientInfo,children:[(0,fd.jsx)("div",{className:fp()(Dv.row,Dv.patientNameRow),children:(0,fd.jsxs)("div",{className:Dv.flexRow,children:[(0,fd.jsx)("span",{className:Dv.patientName,children:a}),i&&(0,fd.jsxs)("div",{className:Dv.gender,children:[(0,fd.jsx)(DD,{gender:i.iconKey}),(0,fd.jsx)("span",{children:i.displayText})]}),(0,fd.jsx)(ck,{className:Dv.tagsSlot,name:"patient-banner-tags-slot",state:s})]})}),(0,fd.jsxs)("div",{className:Dv.demographics,children:[e.birthDate&&(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("span",{children:Dy(e.birthDate)}),(0,fd.jsx)("span",{className:Dv.separator,children:"\xb7"}),(0,fd.jsx)("span",{children:EG(e.birthDate,{time:!1})}),(0,fd.jsx)("span",{className:Dv.separator,children:"\xb7"})]}),(0,fd.jsx)(DE,{identifiers:e.identifier,showIdentifierLabel:!0}),(0,fd.jsx)(ck,{className:Dv.extensionSlot,name:"patient-banner-bottom-slot",state:s})]})]})}var DC=r(1673);function Dk({patient:e,patientUuid:t,actionsSlotName:r,additionalActionsSlotState:n}){let[o,a]=(0,cu.useState)(!1),{extensions:i}=cS(r),s="tablet"===dI(),l=dV(()=>a(!1),o),u=(0,cu.useRef)(null),c=(0,cu.useRef)(null),d=(0,cu.useId)(),f=`patient-actions-menu-trigger-${d}`,p=`patient-actions-menu-${d}`,m=(0,cu.useCallback)(()=>a(e=>!e),[]),h=(0,cu.useCallback)(()=>{a(!1),u.current?.focus()},[]),g=(0,cu.useCallback)(e=>{if("Escape"===e.key&&o){e.stopPropagation(),h();return}if(("ArrowDown"===e.key||"ArrowUp"===e.key)&&o){e.preventDefault();let t=c.current?.querySelectorAll('[role="menuitem"]:not([disabled])');if(!t?.length)return;let r=document.activeElement?.closest?.('[role="menuitem"]')??document.activeElement,n=Array.from(t).indexOf(r);if(-1===n)return void t["ArrowDown"===e.key?0:t.length-1]?.focus();let o=n+("ArrowDown"===e.key?1:-1),a=o<0?t.length-1:o>=t.length?0:o;t[a]?.focus()}},[h,o]);(0,cu.useEffect)(()=>{if(o&&c.current){let e=c.current.querySelector('[role="menuitem"]:not([disabled])');e?.focus()}},[o]);let y=(0,cu.useMemo)(()=>({patientUuid:t,patient:e,closeMenu:h,...n}),[t,e,h,n]);return 0===i.length?null:(0,fd.jsx)("div",{className:"-esm-cohort-builder__patient-banner-actions-menu-module__overflowMenuContainer___7eCLh",children:(0,fd.jsxs)("div",{"data-overflow-menu":!0,className:fp()("cds--overflow-menu",fE),ref:l,children:[(0,fd.jsxs)("button",{className:fp()("cds--btn","cds--btn--ghost","cds--overflow-menu__trigger",{"cds--overflow-menu--open":o},f_),"aria-controls":p,"aria-expanded":o,"aria-haspopup":"true",id:f,onClick:m,onKeyDown:g,ref:u,children:[(0,fd.jsx)("span",{className:"-esm-cohort-builder__patient-banner-actions-menu-module__actionsButtonText___TbM5a",children:iK("actions","Actions")})," ",(0,fd.jsx)(DC.CH,{size:16,style:{marginLeft:"0.5rem",fill:"#78A9FF"}})]}),(0,fd.jsxs)("div",{className:fp()("cds--overflow-menu-options","cds--overflow-menu--flip",fx,{[fD]:o}),"aria-labelledby":f,"data-floating-menu-direction":"bottom",id:p,onKeyDown:g,ref:c,role:"menu",tabIndex:-1,children:[(0,fd.jsx)("ul",{className:fp()("cds--overflow-menu-options__content",{"cds--overflow-menu-options--lg":s}),children:(0,fd.jsx)(ck,{name:r,state:y},r)}),(0,fd.jsx)("span",{})]})]})})}var DP=r(6767),DO=r.n(DP);function DR(e){let{patientPhotoConceptUuid:t}=du({externalModuleName:"@openmrs/esm-styleguide"}),r=t?`${i6}/obs?patient=${e}&concept=${t}&v=full`:null,{data:n,error:o,isLoading:a}=cH()(e?r:null,i7),i=n?.data?.results[0];return{data:i?{dateTime:i?.obsDatetime,imageSrc:i?.value?.links?.uri}:null,error:o,isLoading:a}}let DT=({width:e=56,height:t=56,"aria-label":r})=>{let{t:n}=(0,cV.useTranslation)();return(0,fd.jsxs)("svg",{"aria-label":r??n("patientPhotoPlaceholder","Patient photo placeholder"),width:e,height:t,fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,fd.jsx)("path",{fill:"#ffffff",d:"M0 0h56v56H0z"}),(0,fd.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"})]})},DN="-esm-cohort-builder__patient-photo-module__avatar___R93LX";function Dj({patientUuid:e,patientName:t,alt:r}){let{data:n,isLoading:o}=DR(e),[a,i]=(0,cu.useState)(null),[s,l]=(0,cu.useState)(!1),u=(0,cu.useMemo)(()=>DO().generate(e),[e]);(0,cu.useEffect)(()=>{if(n?.imageSrc){let e=new URL(n.imageSrc,window.location.origin).pathname;l(!0);let t=!1,r=new Image;return r.onload=()=>{t||(i(e),l(!1))},r.onerror=()=>{t||(i(null),l(!1))},r.src=e,()=>{t=!0}}i(null),l(!1)},[n?.imageSrc]);let c=(0,cu.useMemo)(()=>r||(a?iK("patientPhotoAlt","Profile photo of {{patientName}}",{patientName:t}):iK("patientAvatarAlt","Avatar for {{patientName}}",{patientName:t})),[r,a,t]);return o||s?(0,fd.jsx)(fv.SkeletonIcon,{className:"-esm-cohort-builder__patient-photo-module__skeleton___I-6iq","data-testid":"skeleton-icon"}):n?.imageSrc&&!a?(0,fd.jsx)(DT,{"aria-label":iK("patientPhotoPlaceholder","Photo placeholder for {{patientName}}",{patientName:t})}):a?(0,fd.jsx)("div",{"aria-label":c,children:(0,fd.jsx)("img",{className:DN,src:a,alt:c,title:t})}):(0,fd.jsx)("div",{"aria-label":c,children:(0,fd.jsx)("div",{className:DN,title:t,style:{backgroundImage:u.toDataUrl(),backgroundRepeat:"no-repeat",backgroundSize:"cover"},children:(0,fd.jsx)("span",{className:"-esm-cohort-builder__patient-photo-module__initials___JnUBD",children:function(e,t=3){return e.split(/\s+/).filter(Boolean).slice(0,t).map(e=>e[0]).join("")}(t)})})})}let DA=["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-digital-trust","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-metadata-export","omrs-pict-obstetrics","omrs-pict-patient-documents","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"],D$=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-appointments",pictogramProps:e})})),DI=D$,DM=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-assessment-1",pictogramProps:e})})),DL=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-assessment-2",pictogramProps:e})})),DF=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-blood-bank",pictogramProps:e})})),DB=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-cardiology",pictogramProps:e})})),DU=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-ct-scan",pictogramProps:e})})),DV=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-dentistry",pictogramProps:e})})),DW=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-digital-trust",pictogramProps:e})})),DH=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-emergency-department",pictogramProps:e})})),Dz=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-facility",pictogramProps:e})})),DK=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-geriatrics",pictogramProps:e})})),DG=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-gynaecology",pictogramProps:e})})),DZ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-in-patient",pictogramProps:e})})),DY=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-laboratory",pictogramProps:e})})),Dq=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-labs-2",pictogramProps:e})})),DJ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-metadata-export",pictogramProps:e})})),DX=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-obstetrics",pictogramProps:e})})),DQ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-patient-documents",pictogramProps:e})})),D0=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-patient-search",pictogramProps:e})})),D1=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-patients",pictogramProps:e})})),D2=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-payments-desk",pictogramProps:e})})),D4=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-pharmacy",pictogramProps:e})})),D3=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-pharmacy-2",pictogramProps:e})})),D6=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-registration",pictogramProps:e})})),D5=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-service-queues",pictogramProps:e})})),D9=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-stock-management",pictogramProps:e})})),D8=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-transfer",pictogramProps:e})})),D7=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-triage",pictogramProps:e})})),_e=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_o,{ref:t,pictogram:"omrs-pict-x-ray",pictogramProps:e})})),_t=Dz,_r=D1,_n=(0,cu.memo)((0,cu.forwardRef)(function({pictogram:e,fallback:t,...r},n){let o=(0,cu.useRef)(document.getElementById(e));return(0,cu.useEffect)(()=>{let t=document.getElementById("omrs-svgs-container"),r=new MutationObserver(t=>{for(let r of t)"childList"===r.type&&(o.current=document.getElementById(e))});return t&&r.observe(t,{childList:!0}),()=>r.disconnect()},[e]),(0,fd.jsx)(c8,{value:o.current,fallback:t,children:(0,fd.jsx)(_o,{ref:n,pictogram:e,pictogramProps:r})})})),_o=(0,cu.memo)((0,cu.forwardRef)(function({pictogram:e,pictogramProps:t},r){let{className:n,size:o}=Object.assign({},{size:92},t);return(o<=26||o>144)&&(console.error(`Invalid size '${o}' specified for ${e}. Defaulting to 92.`),o=92),(0,fd.jsx)("svg",{ref:r,className:fp()("-esm-cohort-builder__pictograms-module__pictogram___LTPzD",n),height:o,width:o,children:(0,fd.jsx)("use",{href:`#${e}`})})})),_a=({children:e})=>"tablet"===dI()?(0,fd.jsx)(fv.Layer,{children:e}):(0,fd.jsx)(fd.Fragment,{children:e}),_i=({snackbar:e,closeSnackbar:t})=>{let{actionButtonLabel:r="",kind:n="success",onActionButtonClick:o=()=>{},isLowContrast:a="error"!==n,progressActionLabel:i,subtitle:s="",timeoutInMs:l=5e3,autoClose:u="error"!==n,title:c,id:d,...f}=e,[p,m]=(0,cu.useState)(r),[h,g]=(0,cu.useState)(!0),[y,v]=(0,cu.useState)(!1),b=(0,cu.useCallback)(()=>{setTimeout(t,250)},[t]),w=(0,cu.useCallback)(()=>{v(!0),b()},[b]);return(0,cu.useEffect)(()=>{if(u){let e=setTimeout(w,l);return()=>clearTimeout(e)}},[l,u,w]),(0,cu.useEffect)(()=>{g(!1),window.setTimeout(()=>{g(!0)},0)},[]),(0,fd.jsx)(fv.ActionableNotification,{actionButtonLabel:p,"aria-label":iK("closeSnackbar","Close snackbar"),className:fp()("-esm-cohort-builder__snackbar-module__slideIn___TqSN-",{"-esm-cohort-builder__snackbar-module__animated___+XPKT":h,"-esm-cohort-builder__snackbar-module__slideOut___1cFIY":y}),kind:n,lowContrast:a,onActionButtonClick:()=>{o(),w(),i&&m(i)},onClose:b,statusIconDescription:iK("snackbarNotification","Snackbar notification"),subtitle:s,title:c,...f})},_s=({subject:e})=>{let[t,r]=(0,cu.useState)([]),n=(0,cu.useCallback)(e=>{r(t=>t.filter(t=>t!==e))},[]);return(0,cu.useEffect)(()=>{let t=e.subscribe(e=>r(t=>[...t.filter(t=>t.subtitle!==e.subtitle||t.actionButtonLabel!==e.actionButtonLabel||t.onActionButtonClick!==e.onActionButtonClick||t.kind!==e.kind||t.title!==e.title),e]));return()=>t.unsubscribe()},[e]),(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsx)(_i,{snackbar:e,closeSnackbar:()=>n(e)},e.id))})},_l=new x3,_u=0;function _c(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(_s,{subject:_l}))}function _d(e){var t;e&&"string"==typeof(t=e.title)&&t.trim().length>0?setTimeout(()=>{_l.next({...e,id:_u++})},0):console.error("showSnackbar must be called with an object having a 'title' property that is a non-empty string")}let _f=({toast:e,closeToast:t})=>{let{description:r,kind:n,critical:o,title:a,actionButtonLabel:i,onActionButtonClick:s=()=>{}}=e,l=(0,cu.useCallback)(()=>{s(),t()},[t,s]);return(0,fd.jsx)("div",{children:(0,fd.jsx)(fv.ActionableNotification,{actionButtonLabel:i,kind:n||"info",lowContrast:o,subtitle:r,title:a||"",onActionButtonClick:l,onClose:t})})},_p=({subject:e})=>{let[t,r]=(0,cu.useState)([]),n=(0,cu.useCallback)(e=>{r(t=>t.filter(t=>t!==e))},[]);return(0,cu.useEffect)(()=>{let t=e.subscribe(e=>r(t=>[...t.filter(t=>t.description!==e.description||t.kind!==e.kind||t.title!==e.title||t.actionButtonLabel!==e.actionButtonLabel||t.onActionButtonClick!==e.onActionButtonClick),e]));return()=>t.unsubscribe()},[e]),(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsx)(_f,{toast:e,closeToast:()=>n(e)},e.id))})},_m=new x3,_h=0;function _g(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(_p,{subject:_m}))}function _y(e){var t;e&&("string"==typeof(t=e.description)?t.trim().length>0:"object"==typeof t&&!xQ(t))?setTimeout(()=>{_m.next({...e,id:_h++})},0):console.error("showToast must be called with an object having a 'description' property that is a non-empty string or object")}var _v=r(4535),_b=r(771);let _w="u">typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),_E=new Uint8Array(16),_x=[];for(let e=0;e<256;++e)_x.push((e+256).toString(16).slice(1));let _D=function(e,t,r){if(_w&&!t&&!e)return _w();let n=(e=e||{}).random??e.rng?.()??function(){if(!d){if("u"<typeof crypto||!crypto.getRandomValues)throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");d=crypto.getRandomValues.bind(crypto)}return d(_E)}();if(n.length<16)throw Error("Random bytes length must be >= 16");if(n[6]=15&n[6]|64,n[8]=63&n[8]|128,t){if((r=r||0)<0||r+16>t.length)throw RangeError(`UUID byte range ${r}:${r+15} is out of buffer bounds`);for(let e=0;e<16;++e)t[r+e]=n[e];return t}return function(e,t=0){return(_x[e[t+0]]+_x[e[t+1]]+_x[e[t+2]]+_x[e[t+3]]+"-"+_x[e[t+4]]+_x[e[t+5]]+"-"+_x[e[t+6]]+_x[e[t+7]]+"-"+_x[e[t+8]]+_x[e[t+9]]+"-"+_x[e[t+10]]+_x[e[t+11]]+_x[e[t+12]]+_x[e[t+13]]+_x[e[t+14]]+_x[e[t+15]]).toLowerCase()}(n)};async function __(e,t){let{openedGroup:r}=u3.getState();if(r){if(r.groupName===e&&_k(r.props,t))return!0;else if(!await _P({reason:"CLOSE_WORKSPACE_GROUP",explicit:!1}))return!1}return u3.setState(r=>({...r,openedGroup:{groupName:e,props:t},openedWindows:[]})),!0}async function _S(e){let{openedGroup:t,openedWindows:r}=u3.getState();if(t){if(r.length>0&&!(e||await _P({reason:"CLOSE_WORKSPACE_GROUP",explicit:!0})))return!1;u3.setState(e=>({...e,openedGroup:null,openedWindows:[]}))}return!0}async function _C(e,t=null,r=null,n=null){let o=u3.getState();if(!o.registeredWorkspacesByName[e])throw Error(`Unable to launch workspace ${e}. Workspace is not registered`);let a=u6(e);if(!a)throw Error(`Unable to launch workspace ${e}. Workspace is not registered to a workspace window`);let{openedGroup:i}=o,{name:s}=a,l=u5(s);if(!l)throw Error(`Unable to launch workspace ${e}. Workspace window ${a.name} is not registered to a workspace group`);let u=u9(e);if(i&&(i.groupName!==l.name||!_k(i.props,n)))return!!await _P({reason:"CLOSE_WORKSPACE_GROUP",explicit:!0})&&(u3.setState({...o,openedGroup:{groupName:l.name,props:n},openedWindows:[{windowName:s,openedWorkspaces:[_j(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0);if(u>=0){let n=o.openedWindows[u],a=o.openedGroup?.props??{},i=o.isMostRecentlyOpenedWindowHidden,{openedWorkspaces:c}=n;if(_k(n.props,r)){let d=c.find(t=>t.workspaceName===e);return d&&_k(d.props,t)?((i||u!==o.openedWindows.length-1)&&u3.setState(_O.restoreWindow(o,s)),!0):!!await _P({reason:"CLOSE_WORKSPACE",explicit:!1,windowName:s,workspaceName:e})&&(u3.setState({...o,openedGroup:{groupName:l.name,props:o?.openedGroup?.props??a},openedWindows:[...o.openedWindows.filter((e,t)=>t!==u),{windowName:s,openedWorkspaces:[_j(e,t)],props:n?.props??r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0)}return!!await _P({reason:"CLOSE_WINDOW",explicit:!1,windowName:s})&&(u3.setState({...o,openedGroup:{groupName:l.name,props:a??o?.openedGroup?.props},openedWindows:[...o.openedWindows.filter((e,t)=>t!==u),{windowName:s,openedWorkspaces:[_j(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0)}return"closable"!=l.persistence?(u3.setState({...o,openedGroup:{groupName:l.name,props:n??o?.openedGroup?.props??null},openedWindows:[...o.openedWindows,{windowName:s,openedWorkspaces:[_j(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0):!!await _P({reason:"CLOSE_OTHER_WINDOWS",explicit:!1,windowNameToSpare:a.name})&&(u3.setState({...o,openedGroup:{groupName:l.name,props:n??o?.openedGroup?.props??null},openedWindows:[{windowName:s,openedWorkspaces:[_j(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0)}function _k(e,t){return null==e||null==t||R(e,t)}function _P(e){function t(e,t){let r=[];for(let n=e.openedWorkspaces.length-1;n>=0;n--){let o=e.openedWorkspaces[n];if(o.hasUnsavedChanges&&r.push(o),t&&o.workspaceName===t)break}return r}let{openedWindows:r,workspaceTitleByWorkspaceName:n}=u3.getState(),o=[];switch(e.reason){case"CLOSE_WORKSPACE_GROUP":o=r.flatMap(e=>t(e));break;case"CLOSE_WINDOW":{let n=r.find(t=>t.windowName===e.windowName);if(!n)throw Error(`Window ${e.windowName} not found in opened windows.`);o=t(n);break}case"CLOSE_WORKSPACE":{let n=r.find(t=>t.windowName===e.windowName);if(!n)throw Error(`Window ${e.windowName} not found in opened windows.`);o=t(n,e.workspaceName);break}case"CLOSE_OTHER_WINDOWS":o=r.filter(t=>t.windowName!==e.windowNameToSpare).flatMap(e=>t(e))}return 0===o.length?Promise.resolve(!0):new Promise(e=>{let t=xJ("workspace2-close-prompt",{size:"sm",onConfirm:()=>{t(),e(!0)},onCancel:()=>{t(),e(!1)},affectedWorkspaceTitles:o.map(e=>n[e.workspaceName])})})}let _O={setWindowMaximized(e,t,r){let n=e.openedWindows.findIndex(e=>e.windowName===t),o=[...e.openedWindows],a={...o[n],maximized:r};return o[n]=a,{...e,openedWindows:o}},hideWindow:e=>({...e,isMostRecentlyOpenedWindowHidden:!0}),restoreWindow(e,t){let r=e.openedWindows.findIndex(e=>e.windowName===t),n=e.openedWindows[r],o=[...e.openedWindows.filter((e,t)=>t!==r),n];return{...e,openedWindows:o,isMostRecentlyOpenedWindowHidden:!1}},closeWorkspace(e,t){let r=u9(t);if(r<0)return e;let n={...e.openedWindows[r]},o=n.openedWorkspaces.findIndex(e=>e.workspaceName===t),a=[...e.openedWindows];n.openedWorkspaces=n.openedWorkspaces.slice(0,o);let i=e.isMostRecentlyOpenedWindowHidden;if(0===n.openedWorkspaces.length){let t=r===e.openedWindows.length-1;a.splice(r,1),t&&a.length>0&&(i=!1)}else a[r]=n;return{...e,openedWindows:a,isMostRecentlyOpenedWindowHidden:i}},openChildWorkspace(e,t,r,n){let o=e.registeredWorkspacesByName[r];if(!o)throw Error(`No workspace named "${r}" registered`);let a=e.registeredWorkspacesByName[t];if(!a)throw Error(`No workspace named "${t}" registered`);if(a.window!==o.window)throw Error(`Child workspace ${r} does not belong to the same workspace window as parent workspace ${t}`);let i=e.openedWindows.findIndex(e=>e.windowName===o.window);if(-1==i)throw Error(`Cannot open child workspace ${r} as window ${o.window} is not opened`);let{openedWorkspaces:s}=e.openedWindows[i],l=s.findIndex(e=>e.workspaceName===t);if(-1===l)throw Error(`Cannot open child workspace ${r} from parent workspace ${t} as the parent is not opened within the workspace window`);let u=s.slice(0,l+1);return{openedWindows:e.openedWindows.map((e,t)=>t==i?{...e,openedWorkspaces:[...u,_j(r,n)]}:e)}},setHasUnsavedChanges(e,t,r){let n=u9(t);if(n<0)return e;let o={...e.openedWindows[n]},a=o.openedWorkspaces.findIndex(e=>e.workspaceName===t);if(a<0)return e;o.openedWorkspaces[a]={...o.openedWorkspaces[a],hasUnsavedChanges:r};let i=[...e.openedWindows];return i[n]=o,{...e,openedWindows:i}},setWorkspaceTitle(e,t,r){let n={...e.workspaceTitleByWorkspaceName};return null===r?delete n[t]:n[t]=r,{...e,workspaceTitleByWorkspaceName:n}}};function _R(){return cv(u3,_O)}let _T=()=>(0,cu.useContext)(cA),_N=()=>Object.keys(u3.getState().registeredWorkspacesByName);function _j(e,t){return{workspaceName:e,props:t??{},hasUnsavedChanges:!1,uuid:_D()}}let _A={workspaceOuterContainer:"-esm-cohort-builder__workspace2-module__workspaceOuterContainer___DLiCR",narrowWorkspace:"-esm-cohort-builder__workspace2-module__narrowWorkspace___VL0kF",widerWorkspace:"-esm-cohort-builder__workspace2-module__widerWorkspace___3QgrA",extraWideWorkspace:"-esm-cohort-builder__workspace2-module__extraWideWorkspace___s7nnh",workspaceMiddleContainer:"-esm-cohort-builder__workspace2-module__workspaceMiddleContainer___mTGNN",maximized:"-esm-cohort-builder__workspace2-module__maximized___-yo9l",hidden:"-esm-cohort-builder__workspace2-module__hidden___K2ryM",workspaceInnerContainer:"-esm-cohort-builder__workspace2-module__workspaceInnerContainer___o3zVl",workspaceSpacer:"-esm-cohort-builder__workspace2-module__workspaceSpacer___N6-ox",loader:"-esm-cohort-builder__workspace2-module__loader___29hpw",hiddenExtraWorkspace:"-esm-cohort-builder__workspace2-module__hiddenExtraWorkspace___-W7TY",header:"-esm-cohort-builder__workspace2-module__header___p0kuD",headerButtons:"-esm-cohort-builder__workspace2-module__headerButtons___hMydG",workspaceContent:"-esm-cohort-builder__workspace2-module__workspaceContent___uROr7",overlayHeaderSpacer:"-esm-cohort-builder__workspace2-module__overlayHeaderSpacer___zdrhx",isActionMenuOpened:"-esm-cohort-builder__workspace2-module__isActionMenuOpened___Wc1Il",showActionMenu:"-esm-cohort-builder__workspace2-module__showActionMenu___qCVQ-",marginWorkspaceContent:"-esm-cohort-builder__workspace2-module__marginWorkspaceContent___A+20C",workspaceContainerWithActionMenu:"-esm-cohort-builder__workspace2-module__workspaceContainerWithActionMenu___S98dq",workspaceFixedContainer:"-esm-cohort-builder__workspace2-module__workspaceFixedContainer___c9Uny",workspaceContainerWithoutActionMenu:"-esm-cohort-builder__workspace2-module__workspaceContainerWithoutActionMenu___u8FbT"},_$=({title:e,children:t,hasUnsavedChanges:r=!1})=>{let n=dI(),{setWindowMaximized:o,hideWindow:a,setHasUnsavedChanges:i,openedWindows:s,openedGroup:l,registeredGroupsByName:u,registeredWindowsByName:c,registeredWorkspacesByName:d,workspaceTitleByWorkspaceName:f,setWorkspaceTitle:p,isMostRecentlyOpenedWindowHidden:m}=_R(),{workspaceName:h,isRootWorkspace:g,closeWorkspace:y,showActionMenu:v}=_T(),b=u9(h),w=s[b],E=w?.openedWorkspaces.find(e=>e.workspaceName===h);if((0,cu.useEffect)(()=>{E?.hasUnsavedChanges!=r&&i(h,r??!1)},[E?.hasUnsavedChanges,r,h,i]),(0,cu.useEffect)(()=>{f[h]!==e&&p(h,e)},[f,h,e,p]),b<0||null==l||null==E)return null;let x=u[l.groupName];if(!x)throw Error(`Cannot find registered workspace group ${l.groupName}`);let D=d[h].window,_=c[D];if(!_)throw Error(`Cannot find registered workspace window ${D}`);let{icon:S,canMaximize:C}=_,k="closable"===x.persistence,P=!!S&&!k,{maximized:O}=w,R=_?.width??"narrow",T=Object.values(c).some(e=>e.group===l.groupName&&void 0!==e.icon),N=b<s.length-1||m;return(0,fd.jsxs)("div",{className:fp()(_A.workspaceOuterContainer,{[_A.narrowWorkspace]:"narrow"===R,[_A.widerWorkspace]:"wider"===R,[_A.extraWideWorkspace]:"extra-wide"===R,[_A.isActionMenuOpened]:T}),children:[(0,fd.jsx)("div",{className:fp()(_A.workspaceSpacer,{[_A.hidden]:N})}),(0,fd.jsx)("div",{className:fp()(_A.workspaceMiddleContainer,{[_A.maximized]:O,[_A.hidden]:N,[_A.isRootWorkspace]:g,[_A.showActionMenu]:v}),children:(0,fd.jsxs)("div",{className:fp()(_A.workspaceInnerContainer,{[_A.maximized]:O,[_A.hidden]:N,[_A.isRootWorkspace]:g}),children:[(0,fd.jsxs)(fv.Header,{"aria-label":iK("workspaceHeader"),className:_A.header,children:[(0,fd.jsx)(fv.HeaderName,{prefix:"",children:e}),(0,fd.jsx)("div",{className:_A.overlayHeaderSpacer}),(0,fd.jsx)(fv.HeaderGlobalBar,{className:_A.headerButtons,children:dM(n)?(0,fd.jsxs)(fd.Fragment,{children:[(C||O)&&(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":O?iK("minimize"):iK("maximize"),onClick:()=>o(D,!O),children:O?(0,fd.jsx)(_v.Xj,{}):(0,fd.jsx)(_v.hz,{})}),P&&(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":iK("hide"),onClick:()=>a(),children:(0,fd.jsx)(fK,{})}),!k&&(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":iK("close"),onClick:()=>y({closeWindow:!0}),children:(0,fd.jsx)(pe,{})})]}):(0,fd.jsxs)(fd.Fragment,{children:[P&&(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":iK("hide"),onClick:()=>a(),children:(0,fd.jsx)(_b.d3,{})}),(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":iK("close"),onClick:()=>{k?_S():y({closeWindow:!0})},children:(0,fd.jsx)(pe,{})})]})})]}),(0,fd.jsx)("div",{className:fp()(_A.workspaceContent),children:t})]})})]})},_I="-esm-cohort-builder__action-menu-button2-module__container___gYRoa",_M="-esm-cohort-builder__action-menu-button2-module__elementContainer___vBViO",_L="-esm-cohort-builder__action-menu-button2-module__active___uRJRA",_F="-esm-cohort-builder__action-menu-button2-module__focused___D4VYB";function _B({getIcon:e,hasUnsavedChanges:t,tagContent:r}){return(0,fd.jsxs)(fd.Fragment,{children:[e({size:16}),t?(0,fd.jsx)("span",{className:"-esm-cohort-builder__action-menu-button2-module__interruptedTag___35fO7",children:"!"}):(0,fd.jsx)("span",{className:"-esm-cohort-builder__action-menu-button2-module__countTag___l8lfc",children:r})]})}let _U=({icon:e,label:t,tagContent:r,workspaceToLaunch:n,onBeforeWorkspaceLaunch:o})=>{let a=dI(),{openedWindows:i,restoreWindow:s,hideWindow:l,isMostRecentlyOpenedWindowHidden:u}=_R(),{extension:c}=(0,cu.useContext)(cd),d=i.findIndex(e=>e.windowName===c?.extensionId),f=i[d],p=null!=f,m=p&&(d<i.length-1||u),h=p&&!m,g=f?.openedWorkspaces.some(e=>e.hasUnsavedChanges)??!1,y=async()=>{if(p)m?s(f.windowName):l();else if(await (o?.()??!0)){let{workspaceName:e,workspaceProps:t,windowProps:r}=n;_C(e,t,r)}};return"tablet"===a||"phone"===a?(0,fd.jsxs)(fv.Button,{className:fp()(_I,{[_L]:p&&!h,[_F]:h}),iconDescription:t,kind:"ghost",onClick:y,role:"button",tabIndex:0,size:"md",children:[(0,fd.jsx)("span",{className:_M,children:(0,fd.jsx)(_B,{hasUnsavedChanges:g,getIcon:e,tagContent:r})}),(0,fd.jsx)("span",{children:t})]}):(0,fd.jsx)(fv.IconButton,{align:"left","aria-label":t,className:fp()(_I,{[_L]:p&&!h,[_F]:h}),enterDelayMs:300,kind:"ghost",label:t,onClick:y,size:"md",children:(0,fd.jsx)("div",{className:_M,children:(0,fd.jsx)(_B,{hasUnsavedChanges:g,getIcon:e,tagContent:r})})})};function _V({showContactDetails:e,toggleContactDetails:t,className:r}){return(0,fd.jsx)(fv.Button,{className:r,iconDescription:"Toggle contact details",kind:"ghost",onClick:t,renderIcon:e?f7:f5,children:e?iK("showLess","Show less"):iK("showMore","Show more")})}let _W={contactDetails:"-esm-cohort-builder__patient-banner-contact-details-module__contactDetails___AvROu",deceased:"-esm-cohort-builder__patient-banner-contact-details-module__deceased___DDd39",heading:"-esm-cohort-builder__patient-banner-contact-details-module__heading___GGJyV",row:"-esm-cohort-builder__patient-banner-contact-details-module__row___8JcKK",col:"-esm-cohort-builder__patient-banner-contact-details-module__col___ct1O9",relationship:"-esm-cohort-builder__patient-banner-contact-details-module__relationship___GTTsg"},_H=({patientUuid:e})=>{let{cohorts:t=[],isLoading:r}=function(e){let t=e?`${i6}/cohortm/cohortmember?patient=${e}&v=custom:(uuid,patient:ref,cohort:(uuid,name,startDate,endDate))`:null,{data:r,isLoading:n}=cH()(t,i7),o=r?.data?.results.map(e=>({uuid:e.cohort.uuid,name:e.cohort.name,startDate:e.cohort.startDate,endDate:e.cohort.endDate}));return(0,cu.useMemo)(()=>({cohorts:o,isLoading:n}),[n,o])}(e);return(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsxs)("p",{className:_W.heading,children:[iK("patientLists","Patient Lists")," (",t?.length??0,")"]}),r?(0,fd.jsx)(fv.InlineLoading,{description:`${iK("loading","Loading")} ...`,role:"progressbar"}):(0,fd.jsxs)("ul",{children:[(()=>{if(t?.length>0){let e=t.sort((e,t)=>EU(e?.startDate).getTime()-EU(t?.startDate).getTime()).slice(0,3);return e?.map(e=>(0,fd.jsx)("li",{children:(0,fd.jsx)(cf,{to:`${window.spaBase}/home/patient-lists/${e.uuid}`,children:e.name},e.uuid)},e.uuid))}return(0,fd.jsx)("li",{children:"--"})})(),t.length>3&&(0,fd.jsx)("li",{className:_W.link,children:(0,fd.jsx)(cf,{to:`${window.spaBase}/home/patient-lists`,children:iK("seeMoreLists","See {{count}} more lists",{count:t?.length-3})})})]})]})},_z=({patientId:e})=>{let{patient:t,isLoading:r}=dZ(e),n=t?.address?.find(e=>"home"===e.use),o=e=>e.split("#")[1];return r?(0,fd.jsx)(fv.InlineLoading,{description:`${iK("loading","Loading")} ...`,role:"progressbar"}):(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("p",{className:_W.heading,children:iK("address","Address")}),(0,fd.jsx)("ul",{children:n?Object.entries(n).filter(([e])=>"id"!==e&&"use"!==e).map(([e,t])=>"extension"===e?n.extension?.[0]?.extension?.map((t,r)=>(0,fd.jsxs)("li",{children:[iK(o(t.url),o(t.url)),": ",t.valueString]},`address-${e}-${r}`)):(0,fd.jsxs)("li",{children:[iK(e,e),": ",t]},`address-${e}`)):(0,fd.jsx)("li",{children:"--"})})]})},_K=({patientUuid:e})=>{let{isLoading:t,contactAttributes:r}=(e=>{let{contactAttributeTypes:t=[]}=du({externalModuleName:"@openmrs/esm-patient-banner-app"}),{attributes:r,error:n,isLoading:o}=(e=>{let{data:t,error:r,isLoading:n}=dp()(`${i6}/patient/${e}?v=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)))`,i7);return{isLoading:n,attributes:t?.data.person.attributes??[],error:r}})(e);return{contactAttributes:(0,cu.useMemo)(()=>r.filter(({attributeType:e})=>t?.some(t=>e.uuid===t)),[r,t]),isLoading:o,error:n}})(e),n=(0,cu.useMemo)(()=>r?[...r?.map(e=>[e.attributeType.display?iK(e.attributeType.display,e.attributeType.display):"",e.value])]:[],[r]);return(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("p",{className:_W.heading,children:iK("contactDetails","Contact Details")}),t?(0,fd.jsx)(fv.InlineLoading,{description:`${iK("loading","Loading")} ...`,role:"progressbar"}):(0,fd.jsx)("ul",{children:n.length?n.map(([e,t],r)=>(0,fd.jsxs)("li",{children:[e,": ",t]},`${e}-${t}-${r}`)):(0,fd.jsx)("li",{children:"--"})})]})},_G=({patientId:e})=>{let{data:t,isLoading:r}=function(e){let t=`${i6}/relationship?v=custom:(display,uuid,personA:(age,display,birthdate,uuid),personB:(age,display,birthdate,uuid),relationshipType:(uuid,display,description,aIsToB,bIsToA))&person=${e}`,{data:r,error:n,isLoading:o,isValidating:a}=cH()(e?t:null,i7),i=r?.data?.results?.length?function(e,t){let r=[];for(let n of t)e===n.personA.uuid?r.push({uuid:`${n.uuid}`,display:n.personB.display,relativeAge:n.personB.age,relativeUuid:n.personB.uuid,relationshipType:n.relationshipType.bIsToA}):r.push({uuid:`${n.uuid}`,display:n.personA.display,relativeAge:n.personA.age,relativeUuid:n.personA.uuid,relationshipType:n.relationshipType.aIsToB});return r}(e,r.data.results):null;return{data:r?i:null,error:n,isLoading:o,isValidating:a}}(e);return(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("p",{className:_W.heading,children:iK("relationships","Relationships")}),r?(0,fd.jsx)(fv.InlineLoading,{description:`${iK("loading","Loading")} ...`,role:"progressbar"}):(0,fd.jsx)("ul",{children:t&&t.length>0?(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsxs)("li",{className:_W.relationship,children:[(0,fd.jsx)("div",{children:(0,fd.jsx)(cf,{to:`${window.spaBase}/patient/${e.relativeUuid}/chart`,children:e.display})}),(0,fd.jsx)("div",{children:e.relationshipType}),(0,fd.jsx)("div",{children:`${e.relativeAge?e.relativeAge:"--"} ${e.relativeAge?1===e.relativeAge?iK("yearAbbreviation","yr"):iK("yearsAbbreviation","yrs"):""}`})]},e.uuid))}):(0,fd.jsx)("li",{children:"--"})})]})};function _Z({patientId:e,deceased:t}){return(0,fd.jsxs)("div",{className:fp()(_W.contactDetails,{[_W.deceased]:t}),children:[(0,fd.jsxs)("div",{className:_W.row,children:[(0,fd.jsx)("div",{className:_W.col,children:(0,fd.jsx)(_z,{patientId:e})}),(0,fd.jsx)("div",{className:_W.col,children:(0,fd.jsx)(_K,{patientUuid:e})})]}),(0,fd.jsxs)("div",{className:_W.row,children:[(0,fd.jsx)("div",{className:_W.col,children:(0,fd.jsx)(_G,{patientId:e})}),(0,fd.jsx)("div",{className:_W.col,children:(0,fd.jsx)(_H,{patientUuid:e})})]})]})}function _Y(e){let t=document.querySelector("template#loading-spinner");if(t){let r=t.content.cloneNode(!0),n=Array.prototype.map.call(r.childNodes,e=>e);return e.appendChild(r),()=>n.forEach(e=>e.remove())}return()=>{}}let _q="-esm-cohort-builder__action-menu2-module__container___4aX3S";function _J({workspaceGroup:e,groupProps:t}){let r=dI(),{persistence:n}=e;return(0,fd.jsx)("aside",{className:"-esm-cohort-builder__action-menu2-module__sideRail___a7qg9",children:(0,fd.jsxs)("div",{className:_q,children:["closable"==n&&dM(r)&&(0,fd.jsx)(fv.IconButton,{align:"left",onClick:()=>_S(),label:iK("close"),kind:"ghost",children:(0,fd.jsx)(pe,{})}),(0,fd.jsx)(cd.Provider,{value:{moduleName:e.moduleName,featureName:e.name},children:(0,fd.jsx)(ck,{className:_q,name:e.name,state:{groupProps:t}})})]})})}function _X(e){let t=new URL(e,window.location.origin).pathname,r=new URL(window.getOpenmrsSpaBase?.()??"/",window.location.origin).pathname,n=r.endsWith("/")?r.slice(0,-1):r,o=null;return n?n===t?o="/":t.startsWith(`${n}/`)&&(o=t.slice(n.length)):o=t,{full:t,spaRelative:o}}function _Q(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 _0(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?_Q(Object(r),!0).forEach(function(t){_2(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):_Q(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function _1(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 _2(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function _4(e){return(_4=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function _3(e,t){return(_3=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function _6(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var _5=function(e){var t=cu.Component;if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");i.prototype=Object.create(t&&t.prototype,{constructor:{value:i,writable:!0,configurable:!0}}),t&&_3(i,t);var r,n,o,a=(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=_4(i);e=r?Reflect.construct(t,arguments,_4(this).constructor):t.apply(this,arguments);if(e&&("object"==typeof e||"function"==typeof e))return e;if(void 0!==e)throw TypeError("Derived constructors may only return object or undefined");return _6(this)});function i(e){var t;if(function(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}(this,i),_2(_6(t=a.call(this,e)),"handleRef",function(e){t.el=e}),_2(_6(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}))}),_2(_6(t),"getParcelProps",function(){var e=_0(_0({},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,_0({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 cA&&cA.Consumer?cu.createElement(cA.Consumer,null,function(t){return e.mountParcel=t?t.mountParcel:null,null}):null;var t=cA&&cA.Consumer?cu.createElement(cA.Consumer,null,function(t){return e.mountParcel=t?t.mountParcel:null,null}):void 0;return cu.createElement(this.props.wrapWith,{ref:this.handleRef,style:this.props.wrapStyle,className:this.props.wrapClassName},t)}}],_1(i.prototype,n),o&&_1(i,o),i}();_2(_5,"defaultProps",{wrapWith:"div",wrapStyle:{},parcelDidMount:function(){}});let _9=({lifeCycle:e,openedWorkspace:t,openedWindow:r,isRootWorkspace:n,isLeafWorkspace:o,showActionMenu:a})=>{let{openedGroup:i,closeWorkspace:s,openChildWorkspace:l}=_R(),u=(0,cu.useMemo)(()=>t&&{closeWorkspace:async(e={})=>{let{closeWindow:n=!1,discardUnsavedChanges:o=!1}=e;return n?!!(o||await _P({reason:"CLOSE_WINDOW",explicit:!0,windowName:r.windowName}))&&(s(r.openedWorkspaces[0].workspaceName),!0):!!(o||await _P({reason:"CLOSE_WORKSPACE",explicit:!0,windowName:r.windowName,workspaceName:t.workspaceName}))&&(s(t.workspaceName),!0)},launchChildWorkspace:async(e,n)=>{let o=t.workspaceName,{openedWorkspaces:a}=r,i=a.findIndex(e=>e.workspaceName===o);-1===i||i!==a.length-1&&a.slice(i+1).some(e=>e.hasUnsavedChanges)&&!await _P({reason:"CLOSE_WORKSPACE",explicit:!0,windowName:r.windowName,workspaceName:a[i+1].workspaceName})||l(o,e,n||{})},workspaceName:t.workspaceName,workspaceProps:t.props,windowProps:r.props,groupProps:i&&i.props?i.props:null,workspaceMeta:u3.getState().registeredWorkspacesByName[t.workspaceName]?.meta??{},isRootWorkspace:n,isLeafWorkspace:o,windowName:r.windowName,showActionMenu:a},[t,s,i,r]);if(!e){let{registeredWorkspacesByName:e}=u3.getState(),r=e[t.workspaceName],o=r&&r.window?r.window:void 0,{registeredWindowsByName:s}=u3.getState(),l=o?s[o]:void 0,u=l&&l.width?l.width:"narrow",c=Object.values(s).some(e=>e.group===i?.groupName&&void 0!==e.icon);return(0,fd.jsxs)("div",{className:fp()(_A.workspaceOuterContainer,{[_A.narrowWorkspace]:"narrow"===u,[_A.widerWorkspace]:"wider"===u,[_A.extraWideWorkspace]:"extra-wide"===u,[_A.isActionMenuOpened]:c}),children:[(0,fd.jsx)("div",{className:_A.workspaceSpacer}),(0,fd.jsx)("div",{className:fp()(_A.workspaceMiddleContainer,{[_A.isRootWorkspace]:n,[_A.showActionMenu]:a}),children:(0,fd.jsx)("div",{className:fp()(_A.workspaceInnerContainer,{[_A.isRootWorkspace]:n}),children:(0,fd.jsx)(fv.InlineLoading,{className:_A.loader,description:`${iK("loading")} ...`})})})]})}return(0,fd.jsx)(_5,{config:e,mountParcel:cs,...u},t.workspaceName)},_8=({openedWindow:e,showActionMenu:t})=>{let{openedWorkspaces:r}=e,[n,o]=(0,cu.useState)({}),{registeredWorkspacesByName:a}=u3.getState();return(0,cu.useEffect)(()=>{let e=!1;return Promise.all(r.map(async e=>{let{moduleName:t,component:r}=a[e.workspaceName];return[e.uuid,await fe(t,r)]})).then(t=>{e||o(Object.fromEntries(t))}),()=>{e=!0}},[r]),(0,fd.jsx)(fd.Fragment,{children:r.map((o,a)=>(0,fd.jsx)(_9,{openedWorkspace:o,openedWindow:e,lifeCycle:n[o.uuid],isRootWorkspace:0===a,isLeafWorkspace:a===r.length-1,showActionMenu:t},o.uuid))})};function _7(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(Se,{}))}function Se(){let{openedGroup:e,openedWindows:t,registeredGroupsByName:r,registeredWindowsByName:n}=_R();if((0,cu.useEffect)(()=>lh("before-page-changed",t=>{let{newPage:n,cancelNavigation:o,oldUrl:a,newUrl:i}=t;if(!e)return;if(n)return void o(_S().then(e=>!e));let s=r[e.groupName],l=s?.scopePattern;l&&function(e,t,r){try{let n=new RegExp(e),o=_X(t),a=_X(r);if(null===o.spaRelative||null===a.spaRelative)return!0;let i=n.exec(o.spaRelative),s=n.exec(a.spaRelative);if(i&&s||(i=n.exec(o.full),s=n.exec(a.full)),!i||!s)return!0;if(i.length>1)return!i.slice(1).every((e,t)=>e===s[t+1]);return!1}catch{return!0}}(l,a,i)&&o(_S().then(e=>!e))}),[e,r]),!e)return null;let o=r[e.groupName],a=t.some(e=>e.maximized),{name:i}=o,s=Object.values(n).filter(e=>e.group===i&&void 0!==e.icon).sort((e,t)=>(e.order??Number.MAX_VALUE)-(t.order??Number.MAX_VALUE)).length>0;return(0,fd.jsxs)("div",{className:fp()("-esm-cohort-builder__workspace-windows-and-menu-module__workspaceWindowsAndMenuContainer___crgqC",{"-esm-cohort-builder__workspace-windows-and-menu-module__overlay___FCMKG":o.overlay,"-esm-cohort-builder__workspace-windows-and-menu-module__hasMaximizedWindow___gk319":a}),children:[(0,fd.jsx)("div",{className:"-esm-cohort-builder__workspace-windows-and-menu-module__workspaceWindowsContainer___MrLlf",children:t.map(e=>(0,fd.jsx)(_8,{openedWindow:e,showActionMenu:s},e.windowName))}),s&&(0,fd.jsx)(_J,{workspaceGroup:o,groupProps:e.props})]})}function St(e,t,r){if(null==e)return r;let n=Er(e);if(!n)return console.warn(`matchLocale: invalid requested locale tag: ${JSON.stringify(e)}`),r;let o=[];for(let e of t){let t=Er(e);if(!t){console.warn(`matchLocale: skipping invalid available locale tag: ${JSON.stringify(e)}`);continue}o.push({canonical:t,original:e})}let a=n;for(;a;){let e=o.find(e=>e.canonical===a);if(e)return e.original;let t=a+"-",r=o.find(e=>e.canonical.startsWith(t));if(r)return r.original;if("ht"===a){a="fr-HT";continue}let n=a.lastIndexOf("-");if(-1===n)break;let i=(a=a.slice(0,n)).lastIndexOf("-");-1!==i&&a.length-i==2&&(a=a.slice(0,i))}return r}function Sr(e=window.localStorage){try{return e.getItem("test"),!0}catch{return!1}}function Sn(e){return!!e&&e.constructor===Object}var So=r(7638);function Sa(e){let[t,r,n]=e.split(".");return`${t}.${r}.${n}`}function Si(e,t){return So(function(e){let t=e.indexOf("-");if(t>=0){let r=Sa(e.slice(0,t)),n=e.slice(t+1);return`${r}-${n}`}return Sa(e)}(t),e,{includePrerelease:!0})}async function Ss(e,t={}){let r,{shouldRetry:n,getDelay:o,onError:a}=t;n=n??(e=>e<=5),o=o??(e=>(function(e,t=!1){return 1e3*Math.pow(2,t?e+1:e)})(e));let i=0;do try{return await Sl(o(i)),await e()}catch(e){a?.(e,i),r=e}while(n(i++));throw r}async function Sl(e){if(!(e<=0))return new Promise(t=>setTimeout(t,e))}function Su(e,t,r,n){}function Sc(e){}function Sd(e){return Promise.resolve([])}function Sf(e){return Promise.resolve([])}function Sp(e){return Promise.resolve({success:!1,result:void 0,error:"No service worker has been registered. Offline-related features have been removed from the framework."})}function Sm(e){return()=>{}}function Sh(){return!0}}}]);
|
|
28
|
+
To fix this, ensure that you define the "component" field inside the page definition.`,e)}(n,t)}}let fs={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 fl(){document.body.classList.toggle("omrs-breakpoint-lt-tablet",window.innerWidth<fs.TABLET_MIN),document.body.classList.toggle("omrs-breakpoint-gt-phone",window.innerWidth>fs.PHONE_MAX),document.body.classList.toggle("omrs-breakpoint-gt-tablet",window.innerWidth>fs.TABLET_MAX),document.body.classList.toggle("omrs-breakpoint-lt-desktop",window.innerWidth<fs.SMALL_DESKTOP_MIN),document.body.classList.toggle("omrs-breakpoint-lt-small-desktop",window.innerWidth<fs.SMALL_DESKTOP_MIN),document.body.classList.toggle("omrs-breakpoint-lt-large-desktop",window.innerWidth<fs.LARGE_DESKTOP_MIN),document.body.classList.toggle("omrs-breakpoint-gt-small-desktop",window.innerWidth>fs.SMALL_DESKTOP_MAX)}let fu=!1;function fc(){fu||(window.addEventListener("resize",fl),fl(),fu=!0)}var fd=r(4848),ff=r(6942),fp=r.n(ff);function fm({title:e,children:t}){let r="tablet"===dI();return(0,fd.jsxs)("div",{className:fp()({"-esm-cohort-builder__card-header-module__tabletHeader___rUYi0":r,"-esm-cohort-builder__card-header-module__desktopHeader___CDa37":!r}),children:[(0,fd.jsx)("h4",{children:e}),t]})}let fh=["red","magenta","purple","blue","teal","cyan","gray","green","warm-gray","cool-gray","high-contrast","outline"],fg={primaryColor:{_type:nn.String,_description:"The color for displaying primary diagnoses tags",_default:"red",_validators:[of.oneOf(fh)]},secondaryColor:{_type:nn.String,_description:"The color for displaying secondary diagnoses tags",_default:"blue",_validators:[of.oneOf(fh)]}},fy={"Brand color #1":{_default:"#005d5d",_type:nn.String},"Brand color #2":{_default:"#004144",_type:nn.String},"Brand color #3":{_default:"#007d79",_type:nn.String},excludePatientIdentifierCodeTypes:{uuids:{_type:nn.Array,_description:"List of UUIDs of patient identifier types to exclude from rendering in the patient banner",_default:[],_elements:{_type:nn.UUID}}},implementationName:{_type:nn.String,_description:"A name of the place (or authority) where all possible locations a user can choose are located.",_default:"Clinic"},logo:{src:{_type:nn.String,_default:"",_description:"The path or URL to the logo shown on the login page and while the server is starting up. If set to an empty string, the default OpenMRS logo is used.",_validators:[of.isUrl]},alt:{_type:nn.String,_default:"Logo",_description:"The alternative text for the logo image, displayed when the image cannot be loaded or on hover."}},patientPhotoConceptUuid:{_type:nn.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:nn.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:[of.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:nn.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:nn.String}},diagnosisTags:fg};var fv=r(9536);let fb={"carbon.table.batch.cancel":"cancel","carbon.table.batch.items.selected":"batchActionsItemsSelected","carbon.table.batch.item.selected":"batchActionItemSelected","carbon.table.batch.selectAll":"selectAll"},fw=e=>(0,fd.jsx)(fv.TableBatchActions,{translateWithId:(e,t)=>{let r=fb[e];return r?iK(r,e,t):e},...e}),fE="-esm-cohort-builder__custom-overflow-menu-module__container___lY3iq",fx="-esm-cohort-builder__custom-overflow-menu-module__menu___dReHr",fD="-esm-cohort-builder__custom-overflow-menu-module__show___48R0e",f_="-esm-cohort-builder__custom-overflow-menu-module__overflowMenuButton___tsY8r",fS=(0,cu.createContext)(null);function fC(){let e=(0,cu.useContext)(fS);if(!e)throw Error("useCustomOverflowMenu must be used within a CustomOverflowMenu");return e}function fk({menuTitle:e,children:t}){let[r,n]=cc().useState(!1),o=dV(()=>n(!1),r),a="tablet"===dI(),i=(0,cu.useCallback)(()=>n(e=>!e),[]),s=(0,cu.useRef)(null),l=(0,cu.useRef)(null),u=(0,cu.useId)(),c=`custom-overflow-menu-trigger-${u}`,d=`custom-overflow-menu-${u}`,f=(0,cu.useCallback)(()=>{n(!1),s.current?.focus()},[]),p=(0,cu.useMemo)(()=>({closeMenu:f}),[f]),m=(0,cu.useCallback)(e=>{"Escape"===e.key&&r&&(e.stopPropagation(),f())},[f,r]),h=cu.Children.toArray(t);(0,cu.useEffect)(()=>{if(r&&l.current){let e=l.current.querySelector('[role="menuitem"]:not([disabled])');e?.focus()}},[r]);let g=(0,cu.useCallback)(({currentIndex:e,direction:t})=>{let r=l.current?.querySelectorAll('[role="menuitem"]:not([disabled])');if(!r?.length)return;let n=document.activeElement?.closest?.('[role="menuitem"]')??document.activeElement,o=Array.from(r).indexOf(n);if(-1===o)return void r[t>0?0:r.length-1]?.focus();let a=o+t,i=a<0?r.length-1:a>=r.length?0:a;r[i]?.focus()},[]),y=h.map((e,t)=>(0,cu.isValidElement)(e)?(0,cu.cloneElement)(e,{closeMenu:f,handleOverflowMenuItemFocus:g,index:t}):e);return(0,fd.jsxs)("div",{"data-overflow-menu":!0,className:fp()("cds--overflow-menu",fE),ref:o,children:[(0,fd.jsx)("button",{className:fp()("cds--btn","cds--btn--ghost","cds--overflow-menu__trigger",{"cds--overflow-menu--open":r},f_),"aria-controls":d,"aria-expanded":r,"aria-haspopup":"true",id:c,onClick:i,onKeyDown:m,ref:s,children:e}),(0,fd.jsxs)("div",{className:fp()("cds--overflow-menu-options","cds--overflow-menu--flip",fx,{[fD]:r}),"aria-labelledby":c,"data-floating-menu-direction":"bottom",id:d,onKeyDown:m,ref:l,role:"menu",tabIndex:-1,children:[(0,fd.jsx)("ul",{className:fp()("cds--overflow-menu-options__content",{"cds--overflow-menu-options--lg":a}),children:(0,fd.jsx)(fS.Provider,{value:p,children:y})}),(0,fd.jsx)("span",{})]})]})}function fP(e){let t=(0,cu.useContext)(fS);return(0,fd.jsx)(fv.OverflowMenuItem,{...e,closeMenu:t?.closeMenu})}var fO=r(8168);(er=eo||(eo={})).Pop="POP",er.Push="PUSH",er.Replace="REPLACE";var fR=function(e){return e},fT="beforeunload";function fN(e){e.preventDefault(),e.returnValue=""}function fj(){var e=[];return{get length(){return e.length},push:function(t){return e.push(t),function(){e=e.filter(function(e){return e!==t})}},call:function(t){e.forEach(function(e){return e&&e(t)})}}}function fA(e){var t={};if(e){var r=e.indexOf("#");r>=0&&(t.hash=e.substr(r),e=e.substr(0,r));var n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}let f$=(0,cu.createContext)(null),fI=(0,cu.createContext)(null);function fM(e,t){if(!e)throw Error(t)}function fL(){return null!=(0,cu.useContext)(fI)}function fF(e){let{basename:t="/",children:r=null,location:n,navigationType:o=eo.Pop,navigator:a,static:i=!1}=e;fL()&&fM(!1);let s=t.replace(/\/+$/,"").replace(/^\/*/,"/"),l=(0,cu.useMemo)(()=>({basename:s,navigator:a,static:i}),[s,a,i]);"string"==typeof n&&(n=fA(n));let{pathname:u="/",search:c="",hash:d="",state:f=null,key:p="default"}=n,m=(0,cu.useMemo)(()=>{let e=function(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=e.charAt(t.length);return r&&"/"!==r?null:e.slice(t.length)||"/"}(u,s);return null==e?null:{pathname:e,search:c,hash:d,state:f,key:p}},[s,u,c,d,f,p]);return null==m?null:(0,cu.createElement)(f$.Provider,{value:l},(0,cu.createElement)(fI.Provider,{children:r,value:{location:m,navigationType:o}}))}function fB(e){let{basename:t,children:r,window:n}=e,o=(0,cu.useRef)();null==o.current&&(o.current=function(e){void 0===e&&(e={});var t=e.window,r=void 0===t?document.defaultView:t,n=r.history;function o(){var e=r.location,t=e.pathname,o=e.search,a=e.hash,i=n.state||{};return[i.idx,fR({pathname:t,search:o,hash:a,state:i.usr||null,key:i.key||"default"})]}var a=null;r.addEventListener("popstate",function(){if(a)d.call(a),a=null;else{var e=eo.Pop,t=o(),r=t[0],n=t[1];if(d.length){if(null!=r){var i=l-r;i&&(a={action:e,location:n,retry:function(){y(-1*i)}},y(i))}}else g(e)}});var i=eo.Pop,s=o(),l=s[0],u=s[1],c=fj(),d=fj();function f(e){var t,r,n,o,a,i,s;return"string"==typeof e?e:(n=void 0===(r=(t=e).pathname)?"/":r,a=void 0===(o=t.search)?"":o,s=void 0===(i=t.hash)?"":i,a&&"?"!==a&&(n+="?"===a.charAt(0)?a:"?"+a),s&&"#"!==s&&(n+="#"===s.charAt(0)?s:"#"+s),n)}function p(e,t){return void 0===t&&(t=null),fR((0,fO.A)({pathname:u.pathname,hash:"",search:""},"string"==typeof e?fA(e):e,{state:t,key:Math.random().toString(36).substr(2,8)}))}function m(e,t){return[{usr:e.state,key:e.key,idx:t},f(e)]}function h(e,t,r){return!d.length||(d.call({action:e,location:t,retry:r}),!1)}function g(e){i=e;var t=o();l=t[0],u=t[1],c.call({action:i,location:u})}function y(e){n.go(e)}return null==l&&(l=0,n.replaceState((0,fO.A)({},n.state,{idx:l}),"")),{get action(){return i},get location(){return u},createHref:f,push:function e(t,o){var a=eo.Push,i=p(t,o);if(h(a,i,function(){e(t,o)})){var s=m(i,l+1),u=s[0],c=s[1];try{n.pushState(u,"",c)}catch(e){r.location.assign(c)}g(a)}},replace:function e(t,r){var o=eo.Replace,a=p(t,r);if(h(o,a,function(){e(t,r)})){var i=m(a,l),s=i[0],u=i[1];n.replaceState(s,"",u),g(o)}},go:y,back:function(){y(-1)},forward:function(){y(1)},listen:function(e){return c.push(e)},block:function(e){var t=d.push(e);return 1===d.length&&r.addEventListener(fT,fN),function(){t(),d.length||r.removeEventListener(fT,fN)}}}}({window:n}));let a=o.current,[i,s]=(0,cu.useState)({action:a.action,location:a.location});return(0,cu.useLayoutEffect)(()=>a.listen(s),[a]),(0,cu.createElement)(fF,{basename:t,children:r,location:i.location,navigationType:i.action,navigator:a})}let fU=["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-mobile-check","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-two-factor-authentication","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"],fV=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-activity",iconProps:e})})),fW=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-add",iconProps:e})})),fH=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-arrow-down",iconProps:e})})),fz=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-arrow-left",iconProps:e})})),fK=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-arrow-right",iconProps:e})})),fG=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-arrow-up",iconProps:e})})),fZ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-baby",iconProps:e})})),fY=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-calendar-heat-map",iconProps:e})})),fq=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-calendar",iconProps:e})})),fJ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-caret-down",iconProps:e})})),fX=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-caret-left",iconProps:e})})),fQ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-caret-right",iconProps:e})})),f0=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-caret-up",iconProps:e})})),f1=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chart-average",iconProps:e})})),f2=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chart-line",iconProps:e})})),f4=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-checkmark-filled",iconProps:e})})),f3=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-checkmark-outline",iconProps:e})})),f6=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chemistry",iconProps:e})})),f5=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chevron-down",iconProps:e})})),f9=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chevron-left",iconProps:e})})),f8=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chevron-right",iconProps:e})})),f7=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-chevron-up",iconProps:e})})),pe=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-close",iconProps:e})})),pt=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-close-filled",iconProps:e})})),pr=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-close-outline",iconProps:e})})),pn=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-document",iconProps:e})})),po=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-document-attachment",iconProps:e})})),pa=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-download",iconProps:e})})),pi=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-drug-order",iconProps:e})})),ps=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-edit",iconProps:e})})),pl=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-event-schedule",iconProps:e})})),pu=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-events",iconProps:e})})),pc=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-gender-female",iconProps:e})})),pd=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-gender-male",iconProps:e})})),pf=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-gender-other",iconProps:e})})),pp=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-gender-unknown",iconProps:e})})),pm=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-generic-order-type",iconProps:e})})),ph=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-group",iconProps:e})})),pg=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-group-access",iconProps:e})})),py=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-hospital-bed",iconProps:e})})),pv=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-image-medical",iconProps:e})})),pb=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-information",iconProps:e})})),pw=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-information-filled",iconProps:e})})),pE=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-information-square",iconProps:e})})),px=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-inventory-management",iconProps:e})})),pD=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-lab-order",iconProps:e})})),p_=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-list-checked",iconProps:e})})),pS=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-location",iconProps:e})})),pC=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-material-order",iconProps:e})})),pk=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-maximize",iconProps:e})})),pP=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-medication",iconProps:e})})),pO=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-message-queue",iconProps:e})})),pR=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-microscope",iconProps:e})})),pT=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-mobile-check",iconProps:e})})),pN=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-money",iconProps:e})})),pj=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-mother",iconProps:e})})),pA=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-movement",iconProps:e})})),p$=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-overflow-menu--horizontal",iconProps:e})})),pI=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-overflow-menu--horizontal",iconProps:e})})),pM=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-password",iconProps:e})})),pL=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-pedestrian-family",iconProps:e})})),pF=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-pen",iconProps:e})})),pB=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-printer",iconProps:e})})),pU=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-procedure-order",iconProps:e})})),pV=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-programs",iconProps:e})})),pW=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-referral-order",iconProps:e})})),pH=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-renew",iconProps:e})})),pz=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-report",iconProps:e})})),pK=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-reset",iconProps:e})})),pG=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-save",iconProps:e})})),pZ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-search",iconProps:e})})),pY=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-settings",iconProps:e})})),pq=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-switcher",iconProps:e})})),pJ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-shopping-cart",iconProps:e})})),pX=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-shopping-cart--arrow-down",iconProps:e})})),pQ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-sticky-note-add",iconProps:e})})),p0=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-syringe",iconProps:e})})),p1=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-table-of-contents",iconProps:e})})),p2=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-table",iconProps:e})})),p4=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-time",iconProps:e})})),p3=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-tools",iconProps:e})})),p6=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-translate",iconProps:e})})),p5=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-trash-can",iconProps:e})})),p9=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-tree-view--alt",iconProps:e})})),p8=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-two-factor-authentication",iconProps:e})})),p7=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-user-avatar",iconProps:e})})),me=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-user-follow",iconProps:e})})),mt=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-user-xray",iconProps:e})})),mr=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-user",iconProps:e})})),mn=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-view-off",iconProps:e})})),mo=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-view",iconProps:e})})),ma=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(mf,{ref:t,icon:"omrs-icon-warning",iconProps:e})})),mi=ma,ms=po,ml=p_,mu=pv,mc=pX,md=(0,cu.memo)((0,cu.forwardRef)(function({icon:e,fallback:t,...r},n){let o=(0,cu.useRef)(e?document.getElementById(e):void 0);return(0,cu.useEffect)(()=>{let t=document.getElementById("omrs-svgs-container"),r=new MutationObserver(t=>{for(let r of t)"childList"===r.type&&(o.current=e?document.getElementById(e):void 0)});return t&&r.observe(t,{childList:!0}),()=>r.disconnect()},[e]),(0,fd.jsx)(c8,{value:o.current,fallback:t,children:(0,fd.jsx)(mf,{ref:n,icon:e,iconProps:r})})})),mf=(0,cu.memo)((0,cu.forwardRef)(function({icon:e,iconProps:t},r){let{className:n,fill:o,size:a}=Object.assign({},{fill:"currentColor",size:20},t);(a<=0||a>72)&&(console.error(`Invalid size '${a}' specified for ${e}. Defaulting to 20.`),a=20);let i=(0,cu.useRef)(null);return(0,cu.useImperativeHandle)(r,()=>i.current),(0,cu.useEffect)(()=>{i.current&&"currentColor"!==o&&i.current.style.setProperty("--omrs-icon-fill",o)},[]),(0,fd.jsx)("svg",{ref:i,className:fp()("omrs-icon","-esm-cohort-builder__icons-module__icon___sq7Qp",n),height:a,width:a,viewBox:"0 0 16 16",children:(0,fd.jsx)("use",{href:`#${e}`})})})),mp=({path:e,title:t,basePath:r,icon:n})=>{let{t:o}=(0,cV.useTranslation)(),a=(fL()||fM(!1),(0,cu.useContext)(fI).location),i=(0,cu.useMemo)(()=>{if(!e)return!1;let t=e.startsWith("/")?e.slice(1):e;if(t.startsWith("http"))return t===window.location.href;let r=t.split("/").map(e=>decodeURIComponent(e)),n=(a.pathname??"").split("/").slice(1).map(e=>decodeURIComponent(e));return n.some((e,t)=>r.every((e,r)=>n[t+r]===e))},[a.pathname,e]);return(0,fd.jsx)("div",{children:(0,fd.jsx)(cf,{className:fp()("cds--side-nav__link",{"active-left-nav-link":i}),to:`${r}/${encodeURIComponent(e)}`,children:(0,fd.jsxs)("span",{className:"-esm-cohort-builder__dashboard-module__menu___Lg1M+",children:[(0,fd.jsx)(md,{icon:n,className:"-esm-cohort-builder__dashboard-module__icon___Y2DxK",size:16}),(0,fd.jsx)("span",{children:o(t)})]})})},e)};function mm(e){return function({basePath:t}){return(0,fd.jsx)(fB,{children:(0,fd.jsx)(mp,{basePath:t,...e})})}}function mh(e){let t=(0,cu.useRef)(null);return(0,cu.useMemo)(()=>({get current(){return t.current},set current(value){t.current=value,"function"==typeof e?e(value):e&&(e.current=value)}}),[e])}function mg(...e){return(...t)=>{for(let r of e)"function"==typeof r&&r(...t)}}let my="u">typeof document?cc().useLayoutEffect:()=>{};function mv(e){let t=(0,cu.useRef)(null);return my(()=>{t.current=e},[e]),(0,cu.useCallback)((...e)=>{let r=t.current;return null==r?void 0:r(...e)},[])}let mb={prefix:String(Math.round(1e10*Math.random())),current:0},mw=cc().createContext(mb),mE=cc().createContext(!1),mx=("u">typeof window&&window.document&&window.document.createElement,new WeakMap),mD="function"==typeof cc().useId?function(e){let t=cc().useId(),[r]=(0,cu.useState)(mk()),n=r?"react-aria":`react-aria${mb.prefix}`;return e||`${n}-${t}`}:function(e){let t=(0,cu.useContext)(mw),r=function(e=!1){let t=(0,cu.useContext)(mw),r=(0,cu.useRef)(null);if(null===r.current&&!e){var n,o;let e=null==(o=cc().__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED)||null==(n=o.ReactCurrentOwner)?void 0:n.current;if(e){let r=mx.get(e);null==r?mx.set(e,{id:t.current,state:e.memoizedState}):e.memoizedState!==r.state&&(t.current=r.id,mx.delete(e))}r.current=++t.current}return r.current}(!!e),n=`react-aria${t.prefix}`;return e||`${n}-${r}`};function m_(){return!1}function mS(){return!0}function mC(e){return()=>{}}function mk(){return"function"==typeof cc().useSyncExternalStore?cc().useSyncExternalStore(mC,m_,mS):(0,cu.useContext)(mE)}let mP=!!("u">typeof window&&window.document&&window.document.createElement),mO=new Map;function mR(e){let[t,r]=(0,cu.useState)(e),n=(0,cu.useRef)(null),o=mD(t),a=(0,cu.useRef)(null);if(s&&s.register(a,o),mP){let e=mO.get(o);e&&!e.includes(n)?e.push(n):mO.set(o,[n])}return my(()=>()=>{s&&s.unregister(a),mO.delete(o)},[o]),(0,cu.useEffect)(()=>{let e=n.current;return e&&r(e),()=>{e&&(n.current=null)}}),o}function mT(e=[]){let t=mR(),[r,n]=function(e){let[t,r]=(0,cu.useState)(e),n=(0,cu.useRef)(null),o=mv(()=>{if(!n.current)return;let e=n.current.next();if(e.done){n.current=null;return}t===e.value?o():r(e.value)});my(()=>{n.current&&o()});let a=mv(e=>{n.current=e(t),o()});return[t,a]}(t),o=(0,cu.useCallback)(()=>{n(function*(){yield t,yield document.getElementById(t)?t:void 0})},[t,n]);return my(o,[t,o,...e]),r}"u">typeof FinalizationRegistry&&(s=new FinalizationRegistry(e=>{mO.delete(e)}));let mN=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 a=t.length;for(r=0;r<a;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 mj(...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]=mg(r,o):("className"===e||"UNSAFE_className"===e)&&"string"==typeof r&&"string"==typeof o?t[e]=mN(r,o):"id"===e&&r&&o?t.id=function(e,t){if(e===t)return e;let r=mO.get(e);if(r)return r.forEach(e=>e.current=t),t;let n=mO.get(t);return n?(n.forEach(t=>t.current=e),e):t}(r,o):t[e]=void 0!==o?o:r}}return t}let mA=Symbol("default");function m$({values:e,children:t}){for(let[r,n]of e)t=cc().createElement(r.Provider,{value:n},t);return t}function mI(e){let{className:t,style:r,children:n,defaultClassName:o,defaultChildren:a,defaultStyle:i,values:s}=e;return(0,cu.useMemo)(()=>{let e,l,u;return e="function"==typeof t?t({...s,defaultClassName:o}):t,l="function"==typeof r?r({...s,defaultStyle:i||{}}):r,u="function"==typeof n?n({...s,defaultChildren:a}):null==n?a:n,{className:null!=e?e:o,style:l||i?{...i,...l}:void 0,children:null!=u?u:a,"data-rac":""}},[t,r,n,o,a,i,s])}function mM(e,t){let r=(0,cu.useContext)(e);if(null===t)return null;if(r&&"object"==typeof r&&"slots"in r&&r.slots){let e=t||mA;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 mL(e,t,r){let{ref:n,...o}=mM(r,e.slot)||{},a=mh((0,cu.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])),i=mj(o,e);return"style"in o&&o.style&&"style"in e&&e.style&&("function"==typeof o.style||"function"==typeof e.style?i.style=t=>{let r="function"==typeof o.style?o.style(t):o.style,n={...t.defaultStyle,...r},a="function"==typeof e.style?e.style({...t,defaultStyle:n}):e.style;return{...n,...a}}:i.style={...o.style,...e.style}),[i,a]}function mF(e=!0){let[t,r]=(0,cu.useState)(e),n=(0,cu.useRef)(!1),o=(0,cu.useCallback)(e=>{n.current=!0,r(!!e)},[]);return my(()=>{n.current||r(!1)},[]),[o,t]}function mB(e){let t=/^(data-.*)$/,r={};for(let n in e)t.test(n)||(r[n]=e[n]);return r}let mU=(0,cu.createContext)(null),mV=null;function mW(e,t="assertive",r=7e3){mV?mV.announce(e,t,r):(mV=new mH,("boolean"==typeof IS_REACT_ACT_ENVIRONMENT?IS_REACT_ACT_ENVIRONMENT:"u">typeof jest)?mV.announce(e,t,r):setTimeout(()=>{(null==mV?void 0:mV.isAttached())&&(null==mV||mV.announce(e,t,r))},100))}class mH{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 a=document.createElement("div");"object"==typeof e?(a.setAttribute("role","img"),a.setAttribute("aria-labelledby",e["aria-labelledby"])):a.textContent=e,"assertive"===t?null==(n=this.assertiveLog)||n.appendChild(a):null==(o=this.politeLog)||o.appendChild(a),""!==e&&setTimeout(()=>{a.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 mz=new Set(["id"]),mK=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),mG=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),mZ=/^(data-.*)$/;function mY(e,t={}){let{labelable:r,isLink:n,propNames:o}=t,a={};for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(mz.has(t)||r&&mK.has(t)||n&&mG.has(t)||(null==o?void 0:o.has(t))||mZ.test(t))&&(a[t]=e[t]);return a}let mq=["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"])'],mJ=mq.join(":not([hidden]),")+",[tabindex]:not([disabled]):not([hidden])";mq.push('[tabindex]:not([tabindex="-1"]):not([disabled])');let mX=mq.join(':not([hidden]):not([tabindex="-1"]),');function mQ(e){return e.matches(mJ)}function m0(e){return e.matches(mX)}let m1=e=>{var t;return null!=(t=null==e?void 0:e.ownerDocument)?t:document},m2=e=>e&&"window"in e&&e.window===e?e:m1(e).defaultView||window;function m4(e){if(function(){if(null==m3){m3=!1;try{document.createElement("div").focus({get preventScroll(){return m3=!0,!0}})}catch{}}return m3}())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 m3=null;function m6(e){return e.nativeEvent=e,e.isDefaultPrevented=()=>e.defaultPrevented,e.isPropagationStopped=()=>e.cancelBubble,e.persist=()=>{},e}function m5(e,t){Object.defineProperty(e,"target",{value:t}),Object.defineProperty(e,"currentTarget",{value:t})}function m9(e){let t=(0,cu.useRef)({isFocused:!1,observer:null});my(()=>{let e=t.current;return()=>{e.observer&&(e.observer.disconnect(),e.observer=null)}},[]);let r=mv(t=>{null==e||e(t)});return(0,cu.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(m6(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 m8=!1;function m7(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 he(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 ht(e){let t=null;return()=>(null==t&&(t=e()),t)}let hr=ht(function(){return he(/^Mac/i)}),hn=ht(function(){return he(/^iPhone/i)}),ho=ht(function(){return he(/^iPad/i)||hr()&&navigator.maxTouchPoints>1}),ha=ht(function(){return hn()||ho()});ht(function(){return hr()||ha()});let hi=ht(function(){return m7(/AppleWebKit/i)&&!hs()}),hs=ht(function(){return m7(/Chrome/i)}),hl=ht(function(){return m7(/Android/i)}),hu=ht(function(){return m7(/Firefox/i)}),hc=new Map,hd=new Set;function hf(){if("u"<typeof window)return;function e(e){return"propertyName"in e}let t=r=>{if(!e(r)||!r.target)return;let n=hc.get(r.target);if(n&&(n.delete(r.propertyName),0===n.size&&(r.target.removeEventListener("transitioncancel",t),hc.delete(r.target)),0===hc.size)){for(let e of hd)e();hd.clear()}};document.body.addEventListener("transitionrun",r=>{if(!e(r)||!r.target)return;let n=hc.get(r.target);n||(n=new Set,hc.set(r.target,n),r.target.addEventListener("transitioncancel",t,{once:!0})),n.add(r.propertyName)}),document.body.addEventListener("transitionend",t)}function hp(e){requestAnimationFrame(()=>{0===hc.size?e():hd.add(e)})}"u">typeof document&&("loading"!==document.readyState?hf():document.addEventListener("DOMContentLoaded",hf));let hm="default",hh="",hg=new WeakMap;function hy(e){if(ha())"disabled"===hm&&(hm="restoring",setTimeout(()=>{hp(()=>{if("restoring"===hm){let t=m1(e);"none"===t.documentElement.style.webkitUserSelect&&(t.documentElement.style.webkitUserSelect=hh||""),hh="",hm="default"}})},300));else if((e instanceof HTMLElement||e instanceof SVGElement)&&e&&hg.has(e)){let t=hg.get(e),r="userSelect"in e.style?"userSelect":"webkitUserSelect";"none"===e.style[r]&&(e.style[r]=t),""===e.getAttribute("style")&&e.removeAttribute("style"),hg.delete(e)}}let hv=cc().createContext({register:()=>{}});function hb(e,t,r){if(!t.has(e))throw TypeError("attempted to "+r+" private field on non-instance");return t.get(e)}function hw(e,t,r){if(t.has(e))throw TypeError("Cannot initialize the same private elements twice on an object");t.set(e,r)}function hE(e,t,r){var n=hb(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 hx(e,t){my(()=>{if(e&&e.ref&&t)return e.ref.current=t.current,()=>{e.ref&&(e.ref.current=null)}})}function hD(){let e=(0,cu.useRef)(new Map),t=(0,cu.useCallback)((t,r,n,o)=>{let a=(null==o?void 0:o.once)?(...t)=>{e.current.delete(n),n(...t)}:n;e.current.set(n,{type:r,eventTarget:t,fn:a,options:o}),t.addEventListener(r,a,o)},[]),r=(0,cu.useCallback)((t,r,n,o)=>{var a;let i=(null==(a=e.current.get(n))?void 0:a.fn)||n;t.removeEventListener(r,i,o),e.current.delete(n)},[]),n=(0,cu.useCallback)(()=>{e.current.forEach((e,t)=>{r(e.eventTarget,e.type,t,e.options)})},[r]);return(0,cu.useEffect)(()=>n,[n]),{addGlobalListener:t,removeGlobalListener:r,removeAllGlobalListeners:n}}hv.displayName="PressResponderContext";function h_(e,t){return!!t&&!!e&&e.contains(t)}function hS(e){return e.target}function hC(e,t,r=!0){var n,o;let{metaKey:a,ctrlKey:i,altKey:s,shiftKey:l}=t;hu()&&(null==(o=window.event)||null==(n=o.type)?void 0:n.startsWith("key"))&&"_blank"===e.target&&(hr()?a=!0:i=!0);let u=hi()&&hr()&&!ho()&&1?new KeyboardEvent("keydown",{keyIdentifier:"Enter",metaKey:a,ctrlKey:i,altKey:s,shiftKey:l}):new MouseEvent("click",{metaKey:a,ctrlKey:i,altKey:s,shiftKey:l,bubbles:!0,cancelable:!0});hC.isOpening=r,m4(e),e.dispatchEvent(u),hC.isOpening=!1}function hk(e){return 0===e.mozInputSource&&!!e.isTrusted||(hl()&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType)}hC.isOpening=!1;var hP=r(1779),hO=r.n(hP),hR=new WeakMap;class hT{continuePropagation(){hE(this,hR,!1)}get shouldStopPropagation(){var e;return e=hb(this,hR,"get"),e.get?e.get.call(this):e.value}constructor(e,t,r,n){var o;hw(this,hR,{writable:!0,value:void 0}),hE(this,hR,!0);let a=null!=(o=null==n?void 0:n.target)?o:r.currentTarget;const i=null==a?void 0:a.getBoundingClientRect();let s,l=0,u,c=null;null!=r.clientX&&null!=r.clientY&&(u=r.clientX,c=r.clientY),i&&(null!=u&&null!=c?(s=u-i.left,l=c-i.top):(s=i.width/2,l=i.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=s,this.y=l}}let hN=Symbol("linkClicked");function hj(e){let{onPress:t,onPressChange:r,onPressStart:n,onPressEnd:o,onPressUp:a,onClick:i,isDisabled:s,isPressed:l,preventFocusOnPress:u,shouldCancelOnPointerExit:c,allowTextSelectionOnPress:d,ref:f,...p}=function(e){let t=(0,cu.useContext)(hv);if(t){let{register:r,...n}=t;e=mj(n,e),r()}return hx(t,e.ref),e}(e),[m,h]=(0,cu.useState)(!1),g=(0,cu.useRef)({isPressed:!1,ignoreEmulatedMouseEvents:!1,didFirePressStart:!1,isTriggeringEvent:!1,activePointerId:null,target:null,isOverTarget:!1,pointerType:null,disposables:[]}),{addGlobalListener:y,removeAllGlobalListeners:v}=hD(),b=mv((e,t)=>{let o=g.current;if(s||o.didFirePressStart)return!1;let a=!0;if(o.isTriggeringEvent=!0,n){let r=new hT("pressstart",t,e);n(r),a=r.shouldStopPropagation}return r&&r(!0),o.isTriggeringEvent=!1,o.didFirePressStart=!0,h(!0),a}),w=mv((e,n,a=!0)=>{let i=g.current;if(!i.didFirePressStart)return!1;i.didFirePressStart=!1,i.isTriggeringEvent=!0;let l=!0;if(o){let t=new hT("pressend",n,e);o(t),l=t.shouldStopPropagation}if(r&&r(!1),h(!1),t&&a&&!s){let r=new hT("press",n,e);t(r),l&&(l=r.shouldStopPropagation)}return i.isTriggeringEvent=!1,l}),E=mv((e,t)=>{let r=g.current;if(s)return!1;if(a){r.isTriggeringEvent=!0;let n=new hT("pressup",t,e);return a(n),r.isTriggeringEvent=!1,n.shouldStopPropagation}return!0}),x=mv(e=>{let t=g.current;if(t.isPressed&&t.target){for(let r of(t.didFirePressStart&&null!=t.pointerType&&w(hI(t.target,e),t.pointerType,!1),t.isPressed=!1,t.isOverTarget=!1,t.activePointerId=null,t.pointerType=null,v(),d||hy(t.target),t.disposables))r();t.disposables=[]}}),D=mv(e=>{c&&x(e)}),_=mv(e=>{null==i||i(e)}),S=mv((e,t)=>{if(i){let r=new MouseEvent("click",e);m5(r,t),i(m6(r))}}),C=(0,cu.useMemo)(()=>{let e=g.current,t={onKeyDown(t){if(h$(t.nativeEvent,t.currentTarget)&&h_(t.currentTarget,hS(t.nativeEvent))){var n;hM(hS(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=b(t,"keyboard");let n=t.currentTarget;y(m1(t.currentTarget),"keyup",mg(t=>{h$(t,n)&&!t.repeat&&h_(n,hS(t))&&e.target&&E(hI(e.target,t),"keyboard")},r),!0)}o&&t.stopPropagation(),t.metaKey&&hr()&&(null==(n=e.metaKeyEvents)||n.set(t.key,t.nativeEvent))}else"Meta"===t.key&&(e.metaKeyEvents=new Map)},onClick(t){if((!t||h_(t.currentTarget,hS(t.nativeEvent)))&&t&&0===t.button&&!e.isTriggeringEvent&&!hC.isOpening){let r=!0;if(s&&t.preventDefault(),!e.ignoreEmulatedMouseEvents&&!e.isPressed&&("virtual"===e.pointerType||hk(t.nativeEvent))){let e=b(t,"virtual"),n=E(t,"virtual"),o=w(t,"virtual");_(t),r=e&&n&&o}else if(e.isPressed&&"keyboard"!==e.pointerType){let n=e.pointerType||t.nativeEvent.pointerType||"virtual";r=w(hI(t.currentTarget,t),n,!0),e.isOverTarget=!1,_(t),x(t)}e.ignoreEmulatedMouseEvents=!1,r&&t.stopPropagation()}}},r=t=>{var r,n,o;if(e.isPressed&&e.target&&h$(t,e.target)){hM(hS(t),t.key)&&t.preventDefault();let r=hS(t),o=h_(e.target,hS(t));w(hI(e.target,t),"keyboard",o),o&&S(t,e.target),v(),"Enter"!==t.key&&hA(e.target)&&h_(e.target,r)&&!t[hN]&&(t[hN]=!0,hC(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||!h_(t.currentTarget,hS(t.nativeEvent)))return;if(o=t.nativeEvent,!hl()&&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 a=!0;if(!e.isPressed){e.isPressed=!0,e.isOverTarget=!0,e.activePointerId=t.pointerId,e.target=t.currentTarget,d||function(e){if(ha()){if("default"===hm){let t=m1(e);hh=t.documentElement.style.webkitUserSelect,t.documentElement.style.webkitUserSelect="none"}hm="disabled"}else if(e instanceof HTMLElement||e instanceof SVGElement){let t="userSelect"in e.style?"userSelect":"webkitUserSelect";hg.set(e,e.style[t]),e.style[t]="none"}}(e.target),a=b(t,e.pointerType);let o=hS(t.nativeEvent);"releasePointerCapture"in o&&o.releasePointerCapture(t.pointerId),y(m1(t.currentTarget),"pointerup",r,!1),y(m1(t.currentTarget),"pointercancel",n,!1)}a&&t.stopPropagation()},t.onMouseDown=t=>{if(h_(t.currentTarget,hS(t.nativeEvent))&&0===t.button){if(u){let r=function(e){for(;e&&!mQ(e);)e=e.parentElement;let t=m2(e),r=t.document.activeElement;if(!r||r===e)return;m8=!0;let n=!1,o=e=>{(e.target===r||n)&&e.stopImmediatePropagation()},a=t=>{(t.target===r||n)&&(t.stopImmediatePropagation(),e||n||(n=!0,m4(r),l()))},i=t=>{(t.target===e||n)&&t.stopImmediatePropagation()},s=t=>{(t.target===e||n)&&(t.stopImmediatePropagation(),n||(n=!0,m4(r),l()))};t.addEventListener("blur",o,!0),t.addEventListener("focusout",a,!0),t.addEventListener("focusin",s,!0),t.addEventListener("focus",i,!0);let l=()=>{cancelAnimationFrame(u),t.removeEventListener("blur",o,!0),t.removeEventListener("focusout",a,!0),t.removeEventListener("focusin",s,!0),t.removeEventListener("focus",i,!0),m8=!1,n=!1},u=requestAnimationFrame(l);return l}(t.target);r&&e.disposables.push(r)}t.stopPropagation()}},t.onPointerUp=t=>{h_(t.currentTarget,hS(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,b(hI(e.target,t),e.pointerType))},t.onPointerLeave=t=>{t.pointerId===e.activePointerId&&e.target&&e.isOverTarget&&null!=e.pointerType&&(e.isOverTarget=!1,w(hI(e.target,t),e.pointerType,!1),D(t))};let r=t=>{if(t.pointerId===e.activePointerId&&e.isPressed&&0===t.button&&e.target){if(h_(e.target,hS(t))&&null!=e.pointerType){let r=!1,n=setTimeout(()=>{e.isPressed&&e.target instanceof HTMLElement&&(r?x(t):(m4(e.target),e.target.click()))},80);y(t.currentTarget,"click",()=>r=!0,!0),e.disposables.push(()=>clearTimeout(n))}else x(t);e.isOverTarget=!1}},n=e=>{x(e)};t.onDragStart=e=>{h_(e.currentTarget,hS(e.nativeEvent))&&x(e)}}return t},[y,s,u,v,d,x,D,w,b,E,_,S]);return(0,cu.useEffect)(()=>{let e=null==f?void 0:f.current;e&&e instanceof m2(e).Element&&"auto"===m2(e).getComputedStyle(e).touchAction&&(e.style.touchAction="pan-x pan-y pinch-zoom")},[f]),(0,cu.useEffect)(()=>{let e=g.current;return()=>{var t;for(let r of(d||hy(null!=(t=e.target)?t:void 0),e.disposables))r();e.disposables=[]}},[d]),{isPressed:l||m,pressProps:mj(p,C)}}function hA(e){return"A"===e.tagName&&e.hasAttribute("href")}function h$(e,t){let{key:r,code:n}=e,o=t.getAttribute("role");return("Enter"===r||" "===r||"Spacebar"===r||"Space"===n)&&!(t instanceof m2(t).HTMLInputElement&&!hF(t,r)||t instanceof m2(t).HTMLTextAreaElement||t.isContentEditable)&&!(("link"===o||!o&&hA(t))&&"Enter"!==r)}function hI(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 hM(e,t){return e instanceof HTMLInputElement?!hF(e,t):!(e instanceof HTMLInputElement)&&(e instanceof HTMLButtonElement?"submit"!==e.type&&"reset"!==e.type:!hA(e))}let hL=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function hF(e,t){return"checkbox"===e.type||"radio"===e.type?" "===t:hL.has(e.type)}let hB=null,hU=new Set,hV=new Map,hW=!1,hH=!1,hz={Tab:!0,Escape:!0};function hK(e,t){for(let r of hU)r(e,t)}function hG(e){hW=!0,e.metaKey||!hr()&&e.altKey||e.ctrlKey||"Control"===e.key||"Shift"===e.key||"Meta"===e.key||(hB="keyboard",hK("keyboard",e))}function hZ(e){hB="pointer",("mousedown"===e.type||"pointerdown"===e.type)&&(hW=!0,hK("pointer",e))}function hY(e){hk(e)&&(hW=!0,hB="virtual")}function hq(e){e.target!==window&&e.target!==document&&!m8&&e.isTrusted&&(hW||hH||(hB="virtual",hK("virtual",e)),hW=!1,hH=!1)}function hJ(){m8||(hW=!1,hH=!0)}function hX(e){if("u"<typeof window||hV.get(m2(e)))return;let t=m2(e),r=m1(e),n=t.HTMLElement.prototype.focus;t.HTMLElement.prototype.focus=function(){hW=!0,n.apply(this,arguments)},r.addEventListener("keydown",hG,!0),r.addEventListener("keyup",hG,!0),r.addEventListener("click",hY,!0),t.addEventListener("focus",hq,!0),t.addEventListener("blur",hJ,!1),"u">typeof PointerEvent&&(r.addEventListener("pointerdown",hZ,!0),r.addEventListener("pointermove",hZ,!0),r.addEventListener("pointerup",hZ,!0)),t.addEventListener("beforeunload",()=>{hQ(e)},{once:!0}),hV.set(t,{focus:n})}let hQ=(e,t)=>{let r=m2(e),n=m1(e);t&&n.removeEventListener("DOMContentLoaded",t),hV.has(r)&&(r.HTMLElement.prototype.focus=hV.get(r).focus,n.removeEventListener("keydown",hG,!0),n.removeEventListener("keyup",hG,!0),n.removeEventListener("click",hY,!0),r.removeEventListener("focus",hq,!0),r.removeEventListener("blur",hJ,!1),"u">typeof PointerEvent&&(n.removeEventListener("pointerdown",hZ,!0),n.removeEventListener("pointermove",hZ,!0),n.removeEventListener("pointerup",hZ,!0)),hV.delete(r))};function h0(){return"pointer"!==hB}"u">typeof document&&("loading"!==(f=m1(void 0)).readyState?hX(void 0):f.addEventListener("DOMContentLoaded",()=>{hX(void 0)}));let h1=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function h2(e){let t=m1(e),r=((e=document)=>e.activeElement)(t);"virtual"===hB?hp(()=>{((e=document)=>e.activeElement)(t)===r&&e.isConnected&&m4(e)}):m4(e)}function h4(e){let{isDisabled:t,onFocus:r,onBlur:n,onFocusChange:o}=e,a=(0,cu.useCallback)(e=>{if(e.target===e.currentTarget)return n&&n(e),o&&o(!1),!0},[n,o]),i=m9(a),s=(0,cu.useCallback)(e=>{let t=m1(e.target),n=t?((e=document)=>e.activeElement)(t):((e=document)=>e.activeElement)();e.target===e.currentTarget&&n===hS(e.nativeEvent)&&(r&&r(e),o&&o(!0),i(e))},[o,r,i]);return{focusProps:{onFocus:!t&&(r||o||n)?s:void 0,onBlur:!t&&(n||o)?a:void 0}}}function h3(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 h6=cc().createContext(null);function h5(e,t){let{focusProps:r}=h4(e),{keyboardProps:n}={keyboardProps:e.isDisabled?{}:{onKeyDown:h3(e.onKeyDown),onKeyUp:h3(e.onKeyUp)}},o=mj(r,n),a=function(e){let t=(0,cu.useContext)(h6)||{};hx(t,e);let{ref:r,...n}=t;return n}(t),i=e.isDisabled?{}:a,s=(0,cu.useRef)(e.autoFocus);(0,cu.useEffect)(()=>{s.current&&t.current&&h2(t.current),s.current=!1},[t]);let l=e.excludeFromTabOrder?-1:0;return e.isDisabled&&(l=void 0),{focusableProps:mj({...o,tabIndex:l},i)}}function h9(e){let{isDisabled:t,onBlurWithin:r,onFocusWithin:n,onFocusWithinChange:o}=e,a=(0,cu.useRef)({isFocusWithin:!1}),{addGlobalListener:i,removeAllGlobalListeners:s}=hD(),l=(0,cu.useCallback)(e=>{e.currentTarget.contains(e.target)&&a.current.isFocusWithin&&!e.currentTarget.contains(e.relatedTarget)&&(a.current.isFocusWithin=!1,s(),r&&r(e),o&&o(!1))},[r,o,a,s]),u=m9(l),c=(0,cu.useCallback)(e=>{if(!e.currentTarget.contains(e.target))return;let t=m1(e.target),r=((e=document)=>e.activeElement)(t);if(!a.current.isFocusWithin&&r===hS(e.nativeEvent)){n&&n(e),o&&o(!0),a.current.isFocusWithin=!0,u(e);let r=e.currentTarget;i(t,"focus",e=>{if(a.current.isFocusWithin&&!h_(r,e.target)){let n=new t.defaultView.FocusEvent("blur",{relatedTarget:e.target});m5(n,r),l(m6(n))}},{capture:!0})}},[n,o,u,i,l]);return t?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:c,onBlur:l}}}function h8(e={}){var t;let{autoFocus:r=!1,isTextInput:n,within:o}=e,a=(0,cu.useRef)({isFocused:!1,isFocusVisible:r||h0()}),[i,s]=(0,cu.useState)(!1),[l,u]=(0,cu.useState)(()=>a.current.isFocused&&a.current.isFocusVisible),c=(0,cu.useCallback)(()=>u(a.current.isFocused&&a.current.isFocusVisible),[]),d=(0,cu.useCallback)(e=>{a.current.isFocused=e,s(e),c()},[c]);t={isTextInput:n},hX(),(0,cu.useEffect)(()=>{let e=(e,r)=>{var n;let o,i,s,l,u;n=!!(null==t?void 0:t.isTextInput),o=m1(null==r?void 0:r.target),i="u">typeof window?m2(null==r?void 0:r.target).HTMLInputElement:HTMLInputElement,s="u">typeof window?m2(null==r?void 0:r.target).HTMLTextAreaElement:HTMLTextAreaElement,l="u">typeof window?m2(null==r?void 0:r.target).HTMLElement:HTMLElement,u="u">typeof window?m2(null==r?void 0:r.target).KeyboardEvent:KeyboardEvent,(n=n||o.activeElement instanceof i&&!h1.has(o.activeElement.type)||o.activeElement instanceof s||o.activeElement instanceof l&&o.activeElement.isContentEditable)&&"keyboard"===e&&r instanceof u&&!hz[r.key]||(e=>{a.current.isFocusVisible=e,c()})(h0())};return hU.add(e),()=>{hU.delete(e)}},[]);let{focusProps:f}=h4({isDisabled:o,onFocusChange:d}),{focusWithinProps:p}=h9({isDisabled:!o,onFocusWithinChange:d});return{isFocused:i,isFocusVisible:l,focusProps:o?p:f}}cc().forwardRef(function(e,t){let{children:r,...n}=e,o=mh(t),a={...n,ref:o};return cc().createElement(h6.Provider,{value:a},r)});let h7=!1,ge=0;function gt(e){"touch"===e.pointerType&&(h7=!0,setTimeout(()=>{h7=!1},50))}function gr(){if("u">typeof document)return"u">typeof PointerEvent&&document.addEventListener("pointerup",gt),ge++,()=>{!(--ge>0)&&"u">typeof PointerEvent&&document.removeEventListener("pointerup",gt)}}function gn(e){let{onHoverStart:t,onHoverChange:r,onHoverEnd:n,isDisabled:o}=e,[a,i]=(0,cu.useState)(!1),s=(0,cu.useRef)({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;(0,cu.useEffect)(gr,[]);let{addGlobalListener:l,removeAllGlobalListeners:u}=hD(),{hoverProps:c,triggerHoverEnd:d}=(0,cu.useMemo)(()=>{let e=(e,t)=>{let o=s.target;s.pointerType="",s.target=null,"touch"!==t&&s.isHovered&&o&&(s.isHovered=!1,u(),n&&n({type:"hoverend",target:o,pointerType:t}),r&&r(!1),i(!1))},a={};return"u">typeof PointerEvent&&(a.onPointerEnter=n=>{h7&&"mouse"===n.pointerType||((n,a)=>{if(s.pointerType=a,o||"touch"===a||s.isHovered||!n.currentTarget.contains(n.target))return;s.isHovered=!0;let u=n.currentTarget;s.target=u,l(m1(n.target),"pointerover",t=>{s.isHovered&&s.target&&!h_(s.target,t.target)&&e(t,t.pointerType)},{capture:!0}),t&&t({type:"hoverstart",target:u,pointerType:a}),r&&r(!0),i(!0)})(n,n.pointerType)},a.onPointerLeave=t=>{!o&&t.currentTarget.contains(t.target)&&e(t,t.pointerType)}),{hoverProps:a,triggerHoverEnd:e}},[t,r,n,o,s,l,u]);return(0,cu.useEffect)(()=>{o&&d({currentTarget:s.target},s.pointerType)},[o]),{hoverProps:c,isHovered:a}}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 go=(0,cu.createContext)(!1);function ga(e){let t=(t,r)=>(0,cu.useContext)(go)?null:e(t,r);return t.displayName=e.displayName||e.name,(0,cu.forwardRef)(t)}let gi=new Set(["form","formAction","formEncType","formMethod","formNoValidate","formTarget","name","value"]),gs=(0,cu.createContext)({}),gl=ga(function(e,t){var r;[e,t]=mL(e,t,gs);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:a,isPressed:i}=function(e,t){let r,{elementType:n="button",isDisabled:o,onPress:a,onPressStart:i,onPressEnd:s,onPressUp:l,onPressChange:u,preventFocusOnPress:c,allowFocusWhenDisabled:d,onClick:f,href:p,target:m,rel:h,type:g="button"}=e;r="button"===n?{type:g,disabled:o}:{role:"button",href:"a"!==n||o?void 0:p,target:"a"===n?m:void 0,type:"input"===n?g:void 0,disabled:"input"===n?o:void 0,"aria-disabled":o&&"input"!==n?o:void 0,rel:"a"===n?h:void 0};let{pressProps:y,isPressed:v}=hj({onPressStart:i,onPressEnd:s,onPressChange:u,onPress:a,onPressUp:l,onClick:f,isDisabled:o,preventFocusOnPress:c,ref:t}),{focusableProps:b}=h5(e,t);d&&(b.tabIndex=o?-1:b.tabIndex);let w=mj(b,y,mY(e,{labelable:!0}));return{isPressed:v,buttonProps:mj(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:s,isFocused:l,isFocusVisible:u}=h8(e),{hoverProps:c,isHovered:d}=gn({...e,isDisabled:e.isDisabled||o}),f={isHovered:d,isPressed:(n.isPressed||i)&&!o,isFocused:l,isFocusVisible:u,isDisabled:e.isDisabled||!1,isPending:null!=o&&o},p=mI({...e,values:f,defaultClassName:"react-aria-Button"}),m=mR(a.id),h=mR(),g=a["aria-labelledby"];o&&(g?g=`${g} ${h}`:a["aria-label"]&&(g=`${m} ${h}`));let y=(0,cu.useRef)(o);return(0,cu.useEffect)(()=>{let e={"aria-labelledby":g||m};!y.current&&l&&o?mW(e,"assertive"):y.current&&l&&!o&&mW(e,"assertive"),y.current=o},[o,l,g,m]),cc().createElement("button",{...mY(e,{propNames:gi}),...mj(a,s,c),...p,type:"submit"===a.type&&o?"button":a.type,id:m,ref:t,"aria-labelledby":g,slot:e.slot||void 0,"aria-disabled":o?"true":a["aria-disabled"],"data-disabled":e.isDisabled||void 0,"data-pressed":f.isPressed||void 0,"data-hovered":d||void 0,"data-focused":l||void 0,"data-pending":o||void 0,"data-focus-visible":u||void 0},cc().createElement(mU.Provider,{value:{id:h}},p.children))});(0,cu.createContext)(null),(0,cu.createContext)(null),(0,cu.createContext)(null),(0,cu.createContext)(null),(0,cu.createContext)(null);let gu=(0,cu.createContext)({}),gc=(0,cu.createContext)({}),gd=(0,cu.forwardRef)(function(e,t){[e,t]=mL(e,t,gc);let{elementType:r="span",...n}=e;return cc().createElement(r,{className:"react-aria-Text",...n,ref:t})}),gf=new Set(["Arab","Syrc","Samr","Mand","Thaa","Mend","Nkoo","Adlm","Rohg","Hebr"]),gp=new Set(["ae","ar","arc","bcc","bqi","ckb","dv","fa","glk","he","ku","mzn","nqo","pnb","ps","sd","ug","ur","yi"]);function gm(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 gf.has(t.script)}let t=e.split("-")[0];return gp.has(t)}let gh=Symbol.for("react-aria.i18n.locale");function gg(){let e="u">typeof window&&window[gh]||"u">typeof navigator&&(navigator.language||navigator.userLanguage)||"en-US";try{Intl.DateTimeFormat.supportedLocalesOf([e])}catch{e="en-US"}return{locale:e,direction:gm(e)?"rtl":"ltr"}}let gy=gg(),gv=new Set;function gb(){for(let e of(gy=gg(),gv))e(gy)}function gw(){let e=mk(),[t,r]=(0,cu.useState)(gy);return((0,cu.useEffect)(()=>(0===gv.size&&window.addEventListener("languagechange",gb),gv.add(r),()=>{gv.delete(r),0===gv.size&&window.removeEventListener("languagechange",gb)}),[]),e)?{locale:"en-US",direction:"ltr"}:t}let gE=cc().createContext(null);function gx(e){let{locale:t,children:r}=e,n=gw(),o=cc().useMemo(()=>t?{locale:t,direction:gm(t)?"rtl":"ltr"}:n,[n,t]);return cc().createElement(gE.Provider,{value:o},r)}function gD(){let e=gw();return(0,cu.useContext)(gE)||e}var g_={};function gS(e,t){return e-t*Math.floor(e/t)}function gC(e,t,r,n){let o=(t=gP(e,t))-1,a=-2;return r<=2?a=0:gk(t)&&(a=-1),1721425+365*o+Math.floor(o/4)-Math.floor(o/100)+Math.floor(o/400)+Math.floor((367*r-362)/12+a+n)}function gk(e){return e%4==0&&(e%100!=0||e%400==0)}function gP(e,t){return"BC"===e?1-t:t}function gO(e){let t="AD";return e<=0&&(t="BC",e=1-e),[t,e]}g_={"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 gR={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 gT{fromJulianDay(e){let t=e-1721426,r=Math.floor(t/146097),n=gS(t,146097),o=Math.floor(n/36524),a=gS(n,36524),i=Math.floor(a/1461),s=Math.floor(gS(a,1461)/365),[l,u]=gO(400*r+100*o+4*i+s+ +(4!==o&&4!==s)),c=e-gC(l,u,1,1),d=2;e<gC(l,u,3,1)?d=0:gk(u)&&(d=1);let f=Math.floor(((c+d)*12+373)/367),p=e-gC(l,u,f,1)+1;return new gQ(l,u,f,p)}toJulianDay(e){return gC(e.era,e.year,e.month,e.day)}getDaysInMonth(e){return gR[gk(e.year)?"leapyear":"standard"][e.month-1]}getMonthsInYear(e){return 12}getDaysInYear(e){return gk(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 gN(e,t){let r=e.copy(),n="hour"in r?gV(r,t):0;gj(r,t.years||0),r.calendar.balanceYearMonth&&r.calendar.balanceYearMonth(r,e),r.month+=t.months||0,gA(r),g$(r),r.day+=7*(t.weeks||0),r.day+=t.days||0,r.day+=n,function(e){for(;e.day<1;)e.month--,gA(e),e.day+=e.calendar.getDaysInMonth(e);for(;e.day>e.calendar.getDaysInMonth(e);)e.day-=e.calendar.getDaysInMonth(e),e.month++,gA(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 a,i;let e=null==(a=(i=r.calendar).isInverseEra)?void 0:a.call(i,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 s=r.calendar.getMonthsInYear(r);return r.month>s&&(r.month=s,r.day=r.calendar.getDaysInMonth(r)),r.day=Math.max(1,Math.min(r.calendar.getDaysInMonth(r),r.day)),r}function gj(e,t){var r,n;(null==(r=(n=e.calendar).isInverseEra)?void 0:r.call(n,e))&&(t=-t),e.year+=t}function gA(e){for(;e.month<1;)gj(e,-1),e.month+=e.calendar.getMonthsInYear(e);let t=0;for(;e.month>(t=e.calendar.getMonthsInYear(e));)e.month-=t,gj(e,1)}function g$(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 gI(e){e.calendar.constrainDate&&e.calendar.constrainDate(e),e.year=Math.max(1,Math.min(e.calendar.getYearsInEra(e),e.year)),g$(e)}function gM(e){let t={};for(let r in e)"number"==typeof e[r]&&(t[r]=-e[r]);return t}function gL(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),gI(r),r}function gF(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),gB(r),r}function gB(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 gU(e,t){let r=e%t;return r<0&&(r+=t),r}function gV(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=gU(e.millisecond,1e3),e.minute+=Math.floor(e.second/60),e.second=gU(e.second,60),e.hour+=Math.floor(e.minute/60),e.minute=gU(e.minute,60),r=Math.floor(e.hour/24),e.hour=gU(e.hour,24),r}function gW(e,t){let r=e.copy();return gV(r,t),r}function gH(e,t,r,n){let o=e.copy();switch(t){case"era":{let t=e.calendar.getEras(),a=t.indexOf(e.era);if(a<0)throw Error("Invalid era: "+e.era);a=gK(a,r,0,t.length-1,null==n?void 0:n.round),o.era=t[a],gI(o);break}case"year":var a,i;(null==(a=(i=o.calendar).isInverseEra)?void 0:a.call(i,o))&&(r=-r),o.year=gK(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=gK(e.month,r,1,e.calendar.getMonthsInYear(e),null==n?void 0:n.round);break;case"day":o.day=gK(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),gI(o),o}function gz(e,t,r,n){let o=e.copy();switch(t){case"hour":{let t=e.hour,a=0,i=23;if((null==n?void 0:n.hourCycle)===12){let e=t>=12;a=12*!!e,i=e?23:11}o.hour=gK(t,r,a,i,null==n?void 0:n.round);break}case"minute":o.minute=gK(e.minute,r,0,59,null==n?void 0:n.round);break;case"second":o.second=gK(e.second,r,0,59,null==n?void 0:n.round);break;case"millisecond":o.millisecond=gK(e.millisecond,r,0,999,null==n?void 0:n.round);break;default:throw Error("Unsupported field "+t)}return o}function gK(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 gG(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?yt(gN(ya(e),{years:t.years,months:t.months,weeks:t.weeks,days:t.days}),e.timeZone):g5(e)-e.offset)+(t.milliseconds||0),r+=1e3*(t.seconds||0),r+=6e4*(t.minutes||0),yi(yn(r+=36e5*(t.hours||0),e.timeZone),e.calendar)}function gZ(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 gY(e){let t,r=yi(e,new gT);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 gq(e){return`${gY(e)}T${gZ(e)}`}function gJ(e){let t,r="object"==typeof e[0]?e.shift():new gT;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 gX=new WeakMap;class gQ{copy(){return this.era?new gQ(this.calendar,this.era,this.year,this.month,this.day):new gQ(this.calendar,this.year,this.month,this.day)}add(e){return gN(this,e)}subtract(e){return gN(this,gM(e))}set(e){return gL(this,e)}cycle(e,t,r){return gH(this,e,t,r)}toDate(e){return yr(this,e)}toString(){return gY(this)}compare(e){return yh(this,e)}constructor(...e){hw(this,gX,{writable:!0,value:void 0});let[t,r,n,o,a]=gJ(e);this.calendar=t,this.era=r,this.year=n,this.month=o,this.day=a,gI(this)}}var g0=new WeakMap;class g1{copy(){return new g1(this.hour,this.minute,this.second,this.millisecond)}add(e){return gW(this,e)}subtract(e){return gW(this,gM(e))}set(e){return gF(this,e)}cycle(e,t,r){return gz(this,e,t,r)}toString(){return gZ(this)}compare(e){var t,r;return t=this,r=e,yg(t)-yg(r)}constructor(e=0,t=0,r=0,n=0){hw(this,g0,{writable:!0,value:void 0}),this.hour=e,this.minute=t,this.second=r,this.millisecond=n,gB(this)}}var g2=new WeakMap;class g4{copy(){return this.era?new g4(this.calendar,this.era,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond):new g4(this.calendar,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond)}add(e){return gN(this,e)}subtract(e){return gN(this,gM(e))}set(e){return gL(gF(this,e),e)}cycle(e,t,r){switch(e){case"era":case"year":case"month":case"day":return gH(this,e,t,r);default:return gz(this,e,t,r)}}toDate(e,t){return yr(this,e,t)}toString(){return gq(this)}compare(e){var t,r;let n=yh(this,e);return 0===n?(t=this,r=ya(e),yg(t)-yg(r)):n}constructor(...e){hw(this,g2,{writable:!0,value:void 0});let[t,r,n,o,a]=gJ(e);this.calendar=t,this.era=r,this.year=n,this.month=o,this.day=a,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,gI(this)}}var g3=new WeakMap;class g6{copy(){return this.era?new g6(this.calendar,this.era,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond):new g6(this.calendar,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond)}add(e){return gG(this,e)}subtract(e){return gG(this,gM(e))}set(e,t){let r,n;return 0===(n=gF(gL(r=ya(this),e),e)).compare(r)?this:yi(yn(yt(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 a=ya(e),i=yi(gF(a,{hour:t}),new gT),s=[yt(i,e.timeZone,"earlier"),yt(i,e.timeZone,"later")].filter(t=>yn(t,e.timeZone).day===i.day)[0],l=yi(gF(a,{hour:o}),new gT),u=[yt(l,e.timeZone,"earlier"),yt(l,e.timeZone,"later")].filter(t=>yn(t,e.timeZone).day===l.day).pop(),c=g5(e)-e.offset,d=Math.floor(c/36e5),f=c%36e5;return yi(yn(c=36e5*gK(d,r,Math.floor(s/36e5),Math.floor(u/36e5),null==n?void 0:n.round)+f,e.timeZone),e.calendar)}case"minute":case"second":case"millisecond":return gz(e,t,r,n);case"era":case"year":case"month":case"day":return yi(yn(yt(gH(ya(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(g5(e)-e.offset)}toString(){var e;let t,r,n;return`${gq(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 g6){var r,n;return e.timeZone===t?e:(r=e,n=t,yi(yn(g5(r)-r.offset,n),r.calendar))}return yn(yt(e,t,void 0),t)})(e,this.timeZone).toDate().getTime()}constructor(...e){hw(this,g3,{writable:!0,value:void 0});let[t,r,n,o,a]=gJ(e),i=e.shift(),s=e.shift();this.calendar=t,this.era=r,this.year=n,this.month=o,this.day=a,this.timeZone=i,this.offset=s,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,gI(this)}}function g5(e){return g9(gP((e=yi(e,new gT)).era,e.year),e.month,e.day,e.hour,e.minute,e.second,e.millisecond)}function g9(e,t,r,n,o,a,i){let s=new Date;return s.setUTCHours(n,o,a,i),s.setUTCFullYear(e,t-1,r),s.getTime()}function g8(e,t){if("UTC"===t)return 0;if(e>0&&t===yv())return -6e4*new Date(e).getTimezoneOffset();let{year:r,month:n,day:o,hour:a,minute:i,second:s}=ye(e,t);return g9(r,n,o,a,i,s,0)-1e3*Math.floor(e/1e3)}let g7=new Map;function ye(e,t){let r=g7.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"}),g7.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 yt(e,t,r="compatible"){var n,o,a;let i=ya(e);if("UTC"===t)return g5(i);if(t===yv()&&"compatible"===r){i=yi(i,new gT);let e=new Date,t=gP(i.era,i.year);return e.setFullYear(t,i.month-1,i.day),e.setHours(i.hour,i.minute,i.second,i.millisecond),e.getTime()}let s=g5(i),l=g8(s-864e5,t),u=g8(s+864e5,t),c=(n=i,((o=s-l)==(a=s-u)?[o]:[o,a]).filter(e=>{var r;let o;return r=n,o=ye(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(s-l,s-u);case"compatible":case"later":return Math.max(s-l,s-u);case"reject":throw RangeError("No such absolute time found")}}function yr(e,t,r="compatible"){return new Date(yt(e,t,r))}function yn(e,t){let r=g8(e,t),n=new Date(e+r),o=n.getUTCFullYear();return new g6(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 yo(e){return new gQ(e.calendar,e.era,e.year,e.month,e.day)}function ya(e,t){let r=0,n=0,o=0,a=0;if("timeZone"in e)({hour:r,minute:n,second:o,millisecond:a}=e);else if("hour"in e&&!t)return e;return t&&({hour:r,minute:n,second:o,millisecond:a}=t),new g4(e.calendar,e.era,e.year,e.month,e.day,r,n,o,a)}function yi(e,t){if(yc(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,gI(n),n}let ys={"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 yl(e,t){return t=yi(t,e.calendar),e.era===t.era&&e.year===t.year&&e.month===t.month&&e.day===t.day}function yu(e,t){return yc(e.calendar,t.calendar)&&yl(e,t)}function yc(e,t){var r,n,o,a;return null!=(a=null!=(o=null==(r=e.isEqual)?void 0:r.call(e,t))?o:null==(n=t.isEqual)?void 0:n.call(t,e))?a:e.identifier===t.identifier}let yd={sun:0,mon:1,tue:2,wed:3,thu:4,fri:5,sat:6};function yf(e,t,r){let n,o=Math.ceil(e.calendar.toJulianDay(e)+1-(r?yd[r]:(n=function(e){if(Intl.Locale){let t=yx.get(e);return!t&&(t=new Intl.Locale(e).maximize().region)&&yx.set(e,t),t}let t=e.split("-")[1];return"u"===t?void 0:t}(t))&&ys[n]||0))%7;return o<0&&(o+=7),o}function yp(e){return yn(Date.now(),e)}function ym(e){return yo(yp(e))}function yh(e,t){return e.calendar.toJulianDay(e)-t.calendar.toJulianDay(t)}function yg(e){return 36e5*e.hour+6e4*e.minute+1e3*e.second+e.millisecond}let yy=null;function yv(){return null==yy&&(yy=new Intl.DateTimeFormat().resolvedOptions().timeZone),yy}function yb(e){return e.subtract({days:e.day-1})}function yw(e){return e.add({days:e.calendar.getDaysInMonth(e)-e.day})}function yE(e,t,r){let n=yf(e,t,r);return e.subtract({days:n})}let yx=new Map;function yD(e,t){return e&&t?0>=e.compare(t)?e:t:e||t}function y_(e,t){return e&&t?e.compare(t)>=0?e:t:e||t}let yS=Symbol.for("react-aria.i18n.locale"),yC=Symbol.for("react-aria.i18n.strings");class yk{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[yS];if(void 0===p){let e=window[yC];if(!e)return null;for(let r in p={},e)p[r]=new yk({[t]:e[r]},t)}let r=null==p?void 0:p[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 yP=new Map,yO=new Map;class yR{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,a=yP.get(o);return a||(a=new Intl.PluralRules(this.locale,{type:r}),yP.set(o,a)),"function"==typeof(n=t[a.select(e)]||t.other)?n():n}number(e){let t=yO.get(this.locale);return t||(t=new Intl.NumberFormat(this.locale),yO.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 yT=new WeakMap;function yN(e,t){let r;return t&&yk.getGlobalDictionaryForPackage(t)||((r=yT.get(e))||(r=new yk(e),yT.set(e,r)),r)}function yj(e,t){let{locale:r}=gD(),n=yN(e,t);return(0,cu.useMemo)(()=>new yR(r,n),[r,n])}let yA=new Map;class y${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==yF&&(yF="h12"===new Intl.DateTimeFormat("fr",{hour:"numeric",hour12:!1}).resolvedOptions().hourCycle),yF&&(this.resolvedHourCycle||(this.resolvedHourCycle=function(e,t){if(!t.timeStyle&&!t.hour)return;e=e.replace(/(-u-)?-nu-[a-zA-Z0-9]+/,"");let r=yM(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=yM(e,t),this.options=t}}let yI={true:{ja:"h11"},false:{}};function yM(e,t={}){if("boolean"==typeof t.hour12&&(null==yL&&(yL="24"===new Intl.DateTimeFormat("en-US",{hour:"numeric",hour12:!1}).format(new Date(2020,2,3,0))),yL)){let r=yI[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(yA.has(r))return yA.get(r);let n=new Intl.DateTimeFormat(e,t);return yA.set(r,n),n}let yL=null,yF=null;function yB(e,t){let r=(0,cu.useRef)(null);return e&&r.current&&t(e,r.current)&&(e=r.current),r.current=e,e}function yU(e){e=yB(null!=e?e:{},yV);let{locale:t}=gD();return(0,cu.useMemo)(()=>new y$(t,e),[t,e])}function yV(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 yW(e){return e&&e.__esModule?e.default:e}let yH=new WeakMap;function yz(e){return(null==e?void 0:e.calendar.identifier)==="gregory"&&"BC"===e.era?"short":void 0}function yK(e,t,r,n){let o=yj(yW(g_),"@react-aria/calendar"),a=yz(e)||yz(t),i=yU({month:"long",year:"numeric",era:a,calendar:e.calendar.identifier,timeZone:r}),s=yU({month:"long",year:"numeric",day:"numeric",era:a,calendar:e.calendar.identifier,timeZone:r});return(0,cu.useMemo)(()=>{if(yl(e,yb(e))){let a=e,s=t;if(e.calendar.getFormattableMonth&&(a=e.calendar.getFormattableMonth(e)),t.calendar.getFormattableMonth&&(s=t.calendar.getFormattableMonth(t)),yl(t,yw(e)))return i.format(a.toDate(r));if(yl(t,yw(t)))return n?yG(i,o,a,s,r):i.formatRange(a.toDate(r),s.toDate(r))}return n?yG(s,o,e,t,r):s.formatRange(e.toDate(r),t.toDate(r))},[e,t,i,s,o,r,n])}function yG(e,t,r,n,o){let a=e.formatRangeToParts(r.toDate(o),n.toDate(o)),i=-1;for(let e=0;e<a.length;e++){let t=a[e];if("shared"===t.source&&"literal"===t.type)i=e;else if("endRange"===t.source)break}let s="",l="";for(let e=0;e<a.length;e++)e<i?s+=a[e].value:e>i&&(l+=a[e].value);return t.format("dateRange",{startDate:s,endDate:l})}function yZ(e,t){let r=(0,cu.useRef)(!0),n=(0,cu.useRef)(null);(0,cu.useEffect)(()=>(r.current=!0,()=>{r.current=!1}),[]),(0,cu.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 yY(e,t){let{id:r,"aria-label":n,"aria-labelledby":o}=e;return r=mR(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 yq(e,t){var r,n;let o,a,i,s,l,u=yj((r=g_)&&r.__esModule?r.default:r,"@react-aria/calendar"),c=mY(e),d=yK(t.visibleRange.start,t.visibleRange.end,t.timeZone,!1),f=yK(t.visibleRange.start,t.visibleRange.end,t.timeZone,!0);yZ(()=>{t.isFocused||mW(f)},[f]);let p=(i=yj(yW(g_),"@react-aria/calendar"),"highlightedRange"in t?{start:o,end:a}=t.highlightedRange||{}:o=a=null!=(n=t.value)?n:void 0,s=yU({weekday:"long",month:"long",year:"numeric",day:"numeric",era:yz(o)||yz(a),timeZone:t.timeZone}),l="anchorDate"in t?t.anchorDate:null,(0,cu.useMemo)(()=>{if(!l&&o&&a)if(yl(o,a)){let e=s.format(o.toDate(t.timeZone));return i.format("selectedDateDescription",{date:e})}else{let e=yG(s,i,o,a,t.timeZone);return i.format("selectedRangeDescription",{dateRange:e})}return""},[o,a,l,t.timeZone,i,s]));yZ(()=>{p&&mW(p,"polite",4e3)},[p]);let m=mT([!!e.errorMessage,e.isInvalid,e.validationState]);yH.set(t,{ariaLabel:e["aria-label"],ariaLabelledBy:e["aria-labelledby"],errorMessageId:m,selectedDateDescription:p});let[h,g]=(0,cu.useState)(!1),y=e.isDisabled||t.isNextVisibleRangeInvalid();y&&h&&(g(!1),t.setFocused(!0));let[v,b]=(0,cu.useState)(!1),w=e.isDisabled||t.isPreviousVisibleRangeInvalid();return w&&v&&(b(!1),t.setFocused(!0)),{calendarProps:mj(c,yY({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":u.format("next"),isDisabled:y,onFocusChange:g},prevButtonProps:{onPress:()=>t.focusPreviousPage(),"aria-label":u.format("previous"),isDisabled:w,onFocusChange:b},errorMessageProps:{id:m},title:d}}let yJ={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 yX(e){let{children:t,elementType:r="div",isFocusable:n,style:o,...a}=e,{visuallyHiddenProps:i}=function(e={}){let{style:t,isFocusable:r}=e,[n,o]=(0,cu.useState)(!1),{focusWithinProps:a}=h9({isDisabled:!r,onFocusWithinChange:e=>o(e)}),i=(0,cu.useMemo)(()=>n?t:t?{...yJ,...t}:yJ,[n]);return{visuallyHiddenProps:{...a,style:i}}}(e);return cc().createElement(r,mj(a,i),t)}function yQ(e,t,r,n){let o=mv(r),a=null==r;(0,cu.useEffect)(()=>{if(a||!e.current)return;let r=e.current;return r.addEventListener(t,o,n),()=>{r.removeEventListener(t,o,n)}},[e,t,n,a,o])}let y0=0,y1=new Map;function y2(e){let[t,r]=(0,cu.useState)();return my(()=>{if(!e)return;let t=y1.get(e);if(t)r(t.element.id);else{let n=`react-aria-description-${y0++}`;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},y1.set(e,t)}return t.refCount++,()=>{t&&0==--t.refCount&&(t.element.remove(),y1.delete(e))}},[e]),{"aria-describedby":e?t:void 0}}function y4(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 y3(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 y6(e,t){if(e&&document.contains(e)){let i=document.scrollingElement||document.documentElement;if("hidden"===window.getComputedStyle(i).overflow)for(let t of function(e){let t=[];for(;e&&e!==document.documentElement;)y4(e,void 0)&&t.push(e),e=e.parentElement;return t}(e))!function(e,t){let r=y3(e,t,"left"),n=y3(e,t,"top"),o=t.offsetWidth,a=t.offsetHeight,i=e.scrollLeft,s=e.scrollTop,{borderTopWidth:l,borderLeftWidth:u,scrollPaddingTop:c,scrollPaddingRight:d,scrollPaddingBottom:f,scrollPaddingLeft:p}=getComputedStyle(e),m=i+parseInt(u,10),h=s+parseInt(l,10),g=m+e.clientWidth,y=h+e.clientHeight,v=parseInt(c,10)||0,b=parseInt(f,10)||0,w=parseInt(d,10)||0,E=parseInt(p,10)||0;r<=i+E?i=r-parseInt(u,10)-E:r+o>g-w&&(i+=r+o-g+w),n<=h+v?s=n-parseInt(l,10)-v:n+a>y-b&&(s+=n+a-y+b),e.scrollLeft=i,e.scrollTop=s}(t,e);else{var r,n,o,a;let{left:i,top:s}=e.getBoundingClientRect();null==e||null==(r=e.scrollIntoView)||r.call(e,{block:"nearest"});let{left:l,top:u}=e.getBoundingClientRect();(Math.abs(i-l)>1||Math.abs(s-u)>1)&&(null==t||null==(o=t.containingElement)||null==(n=o.scrollIntoView)||n.call(o,{block:"center",inline:"center"}),null==(a=e.scrollIntoView)||a.call(e,{block:"nearest"}))}}}function y5(e,t){let r=e;for(y4(r,t)&&(r=r.parentElement);r&&!y4(r,t);)r=r.parentElement;return r||document.scrollingElement||document.documentElement}class y9 extends gT{fromJulianDay(e){let t=super.fromJulianDay(e);return new gQ(this,gP(t.era,t.year)- -543,t.month,t.day)}toJulianDay(e){return super.toJulianDay(y8(e))}getEras(){return["BE"]}getDaysInMonth(e){return super.getDaysInMonth(y8(e))}balanceDate(){}constructor(...e){super(...e),this.identifier="buddhist"}}function y8(e){let[t,r]=gO(e.year+-543);return new gQ(t,r,e.month,e.day)}function y7(e,t,r,n){return e+365*t+Math.floor(t/4)+30*(r-1)+n-1}function ve(e,t){let r=Math.floor(4*(t-e)/1461),n=1+Math.floor((t-y7(e,r,1,1))/30),o=t+1-y7(e,r,n,1);return[r,n,o]}function vt(e){return Math.floor(e%4/3)}function vr(e,t){return t%13!=0?30:vt(e)+5}class vn{fromJulianDay(e){let[t,r,n]=ve(1723856,e),o="AM";return t<=0&&(o="AA",t+=5500),new gQ(this,o,t,r,n)}toJulianDay(e){let t=e.year;return"AA"===e.era&&(t-=5500),y7(1723856,t,e.month,e.day)}getDaysInMonth(e){return vr(e.year,e.month)}getMonthsInYear(){return 13}getDaysInYear(e){return 365+vt(e.year)}getYearsInEra(e){return"AA"===e.era?9999:9991}getEras(){return["AA","AM"]}constructor(){this.identifier="ethiopic"}}class vo extends vn{fromJulianDay(e){let[t,r,n]=ve(1723856,e);return new gQ(this,"AA",t+=5500,r,n)}getEras(){return["AA"]}getYearsInEra(){return 9999}constructor(...e){super(...e),this.identifier="ethioaa"}}class va extends vn{fromJulianDay(e){let[t,r,n]=ve(1824665,e),o="CE";return t<=0&&(o="BCE",t=1-t),new gQ(this,o,t,r,n)}toJulianDay(e){let t=e.year;return"BCE"===e.era&&(t=1-t),y7(1824665,t,e.month,e.day)}getDaysInMonth(e){let t=e.year;return"BCE"===e.era&&(t=1-t),vr(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 vi=765433;function vs(e){return 7>gS(7*e+1,19)}function vl(e){let t=Math.floor((235*e-234)/19),r=29*t+Math.floor((12084+13753*t)/25920);return 3>gS(3*(r+1),7)&&(r+=1),r}function vu(e){let t,r;return vl(e)+(t=vl(e-1),r=vl(e),vl(e+1)-r==356?2:+(r-t==382))}function vc(e){return vu(e+1)-vu(e)}function vd(e,t){if(t>=6&&!vs(e)&&t++,4===t||7===t||9===t||11===t||13===t)return 29;let r=function(e){let t=vc(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*!!vs(e):30}class vf{fromJulianDay(e){let t=e-347997,r=Math.floor((25920*t/vi*19+234)/235)+1,n=vu(r),o=Math.floor(t-n);for(;o<1;)o=Math.floor(t-(n=vu(--r)));let a=1,i=0;for(;i<o;)i+=vd(r,a),a++;let s=o-(i-=vd(r,--a));return new gQ(this,r,a,s)}toJulianDay(e){let t=vu(e.year);for(let r=1;r<e.month;r++)t+=vd(e.year,r);return t+e.day+347997}getDaysInMonth(e){return vd(e.year,e.month)}getMonthsInYear(e){return vs(e.year)?13:12}getDaysInYear(e){return vc(e.year)}getYearsInEra(){return 9999}getEras(){return["AM"]}balanceYearMonth(e,t){t.year!==e.year&&(vs(t.year)&&!vs(e.year)&&t.month>6?e.month--:!vs(t.year)&&vs(e.year)&&t.month>6&&e.month++)}constructor(){this.identifier="hebrew"}}class vp extends gT{fromJulianDay(e){let t,r,n,o=super.fromJulianDay(e),a=o.year-78,i=e-gC(o.era,o.year,1,1);if(i<80?(a--,i+=(t=gk(o.year-1)?31:30)+155+90+10):(t=gk(o.year)?31:30,i-=80),i<t)r=1,n=i+1;else{let e=i-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 gQ(this,a,r,n)}toJulianDay(e){let t,r,[n,o]=gO(e.year+78);return(gk(o)?(t=31,r=gC(n,o,3,21)):(t=30,r=gC(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&&gk(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 vm(e,t,r,n){return n+Math.ceil(29.5*(r-1))+(t-1)*354+Math.floor((3+11*t)/30)+e-1}function vh(e,t,r){let n=Math.floor((30*(r-t)+10646)/10631),o=Math.min(12,Math.ceil((r-(29+vm(t,n,1,1)))/29.5)+1),a=r-vm(t,n,o,1)+1;return new gQ(e,n,o,a)}function vg(e){return(14+11*e)%30<11}class vy{fromJulianDay(e){return vh(this,1948440,e)}toJulianDay(e){return vm(1948440,e.year,e.month,e.day)}getDaysInMonth(e){let t=29+e.month%2;return 12===e.month&&vg(e.year)&&t++,t}getMonthsInYear(){return 12}getDaysInYear(e){return vg(e.year)?355:354}getYearsInEra(){return 9665}getEras(){return["AH"]}constructor(){this.identifier="islamic-civil"}}class vv extends vy{fromJulianDay(e){return vh(this,1948439,e)}toJulianDay(e){return vm(1948439,e.year,e.month,e.day)}constructor(...e){super(...e),this.identifier="islamic-tbla"}}function vb(e){return 460322+u[e-1300]}function vw(e,t){return(l[e-1300]&1<<11-(t-1))==0?29:30}function vE(e,t){let r=vb(e);for(let n=1;n<t;n++)r+=vw(e,n);return r}function vx(e){return u[e+1-1300]-u[e-1300]}class vD extends vy{fromJulianDay(e){let t=e-1948440,r=vb(1300),n=vb(1600);if(t<r||t>n)return super.fromJulianDay(e);{let e=1299,r=1,n=1;for(;n>0;){n=t-vb(++e)+1;let o=vx(e);if(n===o){r=12;break}if(n<o){let t=vw(e,r);for(r=1;n>t;)n-=t,t=vw(e,++r);break}}return new gQ(this,e,r,t-vE(e,r)+1)}}toJulianDay(e){return e.year<1300||e.year>1600?super.toJulianDay(e):1948440+vE(e.year,e.month)+(e.day-1)}getDaysInMonth(e){return e.year<1300||e.year>1600?super.getDaysInMonth(e):vw(e.year,e.month)}getDaysInYear(e){return e.year<1300||e.year>1600?super.getDaysInYear(e):vx(e.year)}constructor(){if(super(),this.identifier="islamic-umalqura",l||(l=new Uint16Array(Uint8Array.from(atob("qgpUDckO1AbqBmwDrQpVBakGkgepC9QF2gpcBS0NlQZKB1QLagutBa4ETwoXBYsGpQbVCtYCWwmdBE0KJg2VDawFtgm6AlsKKwWVCsoG6Qr0AnYJtgJWCcoKpAvSC9kF3AJtCU0FpQpSC6ULtAW2CVcFlwJLBaMGUgdlC2oFqworBZUMSg2lDcoF1gpXCasESwmlClILagt1BXYCtwhbBFUFqQW0BdoJ3QRuAjYJqgpUDbIN1QXaAlsJqwRVCkkLZAtxC7QFtQpVCiUNkg7JDtQG6QprCasEkwpJDaQNsg25CroEWworBZUKKgtVC1wFvQQ9Ah0JlQpKC1oLbQW2AjsJmwRVBqkGVAdqC2wFrQpVBSkLkgupC9QF2gpaBasKlQVJB2QHqgu1BbYCVgpNDiULUgtqC60FrgIvCZcESwalBqwG1gpdBZ0ETQoWDZUNqgW1BdoCWwmtBJUFygbkBuoK9QS2AlYJqgpUC9IL2QXqAm0JrQSVCkoLpQuyBbUJ1gSXCkcFkwZJB1ULagVrCisFiwpGDaMNygXWCtsEawJLCaUKUgtpC3UFdgG3CFsCKwVlBbQF2gntBG0BtgimClINqQ3UBdoKWwmrBFMGKQdiB6kLsgW1ClUFJQuSDckO0gbpCmsFqwRVCikNVA2qDbUJugQ7CpsETQqqCtUK2gJdCV4ELgqaDFUNsga5BroEXQotBZUKUguoC7QLuQXaAloJSgukDdEO6AZqC20FNQWVBkoNqA3UDdoGWwWdAisGFQtKC5ULqgWuCi4JjwwnBZUGqgbWCl0FnQI="),e=>e.charCodeAt(0)).buffer)),!u){u=new Uint32Array(301);let e=0;for(let t=1300;t<=1600;t++){u[t-1300]=e;for(let r=1;r<=12;r++)e+=vw(t,r)}}}}let v_=[[1868,9,8],[1912,7,30],[1926,12,25],[1989,1,8],[2019,5,1]],vS=[[1912,7,29],[1926,12,24],[1989,1,7],[2019,4,30]],vC=[1867,1911,1925,1988,2018],vk=["meiji","taisho","showa","heisei","reiwa"];function vP(e){let t=v_.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?v_.length-1:0===t?0:t-1}function vO(e){let t=vC[vk.indexOf(e.era)];if(!t)throw Error("Unknown era: "+e.era);return new gQ(e.year+t,e.month,e.day)}class vR extends gT{fromJulianDay(e){let t=super.fromJulianDay(e),r=vP(t);return new gQ(this,vk[r],t.year-vC[r],t.month,t.day)}toJulianDay(e){return super.toJulianDay(vO(e))}balanceDate(e){let t=vO(e),r=vP(t);vk[r]!==e.era&&(e.era=vk[r],e.year=t.year-vC[r]),this.constrainDate(e)}constrainDate(e){let t=vk.indexOf(e.era),r=vS[t];if(null!=r){let[n,o,a]=r,i=n-vC[t];e.year=Math.max(1,Math.min(i,e.year)),e.year===i&&(e.month=Math.min(o,e.month),e.month===o&&(e.day=Math.min(a,e.day)))}if(1===e.year&&t>=0){let[,r,n]=v_[t];e.month=Math.max(r,e.month),e.month===r&&(e.day=Math.max(n,e.day))}}getEras(){return vk}getYearsInEra(e){let t=vk.indexOf(e.era),r=v_[t],n=v_[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(vO(e))}getMinimumMonthInYear(e){let t=vT(e);return t?t[1]:1}getMinimumDayInMonth(e){let t=vT(e);return t&&e.month===t[1]?t[2]:1}constructor(...e){super(...e),this.identifier="japanese"}}function vT(e){if(1===e.year)return v_[vk.indexOf(e.era)]}let vN=[0,31,62,93,124,155,186,216,246,276,306,336];class vj{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),a=n-vN[o]+1;return new gQ(this,r,o+1,a)}toJulianDay(e){let t=1948319+365*(e.year-1)+Math.floor((8*e.year+21)/33);return t+=vN[e.month-1],t+=e.day}getMonthsInYear(){return 12}getDaysInMonth(e){return e.month<=6?31:e.month<=11||8>gS(25*e.year+11,33)?30:29}getEras(){return["AP"]}getYearsInEra(){return 9377}constructor(){this.identifier="persian"}}function vA(e){return"minguo"===e.era?e.year+1911:1-e.year+1911}function v$(e){let t=e-1911;return t>0?["minguo",t]:["before_minguo",1-t]}class vI extends gT{fromJulianDay(e){let t=super.fromJulianDay(e),[r,n]=v$(gP(t.era,t.year));return new gQ(this,r,n,t.month,t.day)}toJulianDay(e){return super.toJulianDay(vM(e))}getEras(){return["before_minguo","minguo"]}balanceDate(e){let[t,r]=v$(vA(e));e.era=t,e.year=r}isInverseEra(e){return"before_minguo"===e.era}getDaysInMonth(e){return super.getDaysInMonth(vM(e))}getYearsInEra(e){return"before_minguo"===e.era?9999:8088}constructor(...e){super(...e),this.identifier="roc"}}function vM(e){let[t,r]=gO(vA(e));return new gQ(t,r,e.month,e.day)}function vL(e){switch(e){case"buddhist":return new y9;case"ethiopic":return new vn;case"ethioaa":return new vo;case"coptic":return new va;case"hebrew":return new vf;case"indian":return new vp;case"islamic-civil":return new vy;case"islamic-tbla":return new vv;case"islamic-umalqura":return new vD;case"japanese":return new vR;case"persian":return new vj;case"roc":return new vI;default:return new gT}}function vF(e,t,r){return null!=t&&0>e.compare(t)||null!=r&&e.compare(r)>0}function vB(e,t,r,n,o){let a={};for(let e in t)a[e]=Math.floor(t[e]/2),a[e]>0&&t[e]%2==0&&a[e]--;let i=vU(e,t,r).subtract(a);return vW(e,i,t,r,n,o)}function vU(e,t,r,n,o){let a=e;if(t.years)a=yb(e.subtract({months:e.month-1}));else t.months?a=yb(e):t.weeks&&(a=yE(e,r));return vW(e,a,t,r,n,o)}function vV(e,t,r,n,o){let a={...t};a.days?a.days--:a.weeks?a.weeks--:a.months?a.months--:a.years&&a.years--;let i=vU(e,t,r).subtract(a);return vW(e,i,t,r,n,o)}function vW(e,t,r,n,o,a){if(o&&e.compare(o)>=0){let e=y_(t,vU(yo(o),r,n));e&&(t=e)}if(a&&0>=e.compare(a)){let e=yD(t,vV(yo(a),r,n));e&&(t=e)}return t}function vH(e,t,r){if(t){let r=y_(e,yo(t));r&&(e=r)}if(r){let t=yD(e,yo(r));t&&(e=t)}return e}function vz(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 vK(e,t,r){let[n,o]=(0,cu.useState)(e||t),a=(0,cu.useRef)(void 0!==e),i=void 0!==e;(0,cu.useEffect)(()=>{a.current,a.current=i},[i]);let s=i?e:n,l=(0,cu.useCallback)((e,...t)=>{let n=(e,...t)=>{r&&!Object.is(s,e)&&r(e,...t),i||(s=e)};"function"==typeof e?o((r,...o)=>{let a=e(i?s:r,...o);return(n(a,...t),i)?r:a}):(i||o(e),n(e,...t))},[i,s,r]);return[s,l]}function vG(e){var t,r,n;let o=(0,cu.useMemo)(()=>new y$(e.locale),[e.locale]),a=(0,cu.useMemo)(()=>o.resolvedOptions(),[o]),{locale:i,createCalendar:s,visibleDuration:l={months:1},minValue:u,maxValue:c,selectionAlignment:d,isDateUnavailable:f,pageBehavior:p="visible",firstDayOfWeek:m}=e,h=(0,cu.useMemo)(()=>s(a.calendar),[s,a.calendar]),[g,y]=vK(e.value,null!=(t=e.defaultValue)?t:null,e.onChange),v=(0,cu.useMemo)(()=>g?yi(yo(g),h):null,[g,h]),b=(0,cu.useMemo)(()=>g&&"timeZone"in g?g.timeZone:a.timeZone,[g,a.timeZone]),[w,E]=vK((0,cu.useMemo)(()=>e.focusedValue?vH(yi(yo(e.focusedValue),h),u,c):void 0,[e.focusedValue,h,u,c]),(0,cu.useMemo)(()=>vH(e.defaultFocusedValue?yi(yo(e.defaultFocusedValue),h):v||yi(ym(b),h),u,c),[e.defaultFocusedValue,v,b,h,u,c]),e.onFocusChange),[x,D]=(0,cu.useState)(()=>{switch(d){case"start":return vU(w,l,i,u,c);case"end":return vV(w,l,i,u,c);default:return vB(w,l,i,u,c)}}),[_,S]=(0,cu.useState)(e.autoFocus||!1),C=(0,cu.useMemo)(()=>{let e={...l};return e.days?e.days--:e.days=-1,x.add(e)},[x,l]),[k,P]=(0,cu.useState)(h);if(!yc(h,k)){let e=yi(w,h);D(vB(e,l,i,u,c)),E(e),P(h)}function O(e){E(e=vH(e,u,c))}function R(t){if(!e.isDisabled&&!e.isReadOnly){let e=t;if(null===e)return void y(null);(e=vz(e=vH(e,u,c),x,f))&&(e=yi(e,(null==g?void 0:g.calendar)||new gT),g&&"hour"in g?y(g.set(e)):y(e))}}vF(w,u,c)?E(vH(w,u,c)):0>w.compare(x)?D(vV(w,l,i,u,c)):w.compare(C)>0&&D(vU(w,l,i,u,c));let T=(0,cu.useMemo)(()=>!!v&&(!!(f&&f(v))||vF(v,u,c)),[v,f,u,c]),N=e.isInvalid||"invalid"===e.validationState||T,j=(0,cu.useMemo)(()=>"visible"===p?l:vZ(l),[p,l]);return{isDisabled:null!=(r=e.isDisabled)&&r,isReadOnly:null!=(n=e.isReadOnly)&&n,value:v,setValue:R,visibleRange:{start:x,end:C},minValue:u,maxValue:c,focusedDate:w,timeZone:b,validationState:N?"invalid":null,isValueInvalid:N,setFocusedDate(e){O(e),S(!0)},focusNextDay(){O(w.add({days:1}))},focusPreviousDay(){O(w.subtract({days:1}))},focusNextRow(){l.days?this.focusNextPage():(l.weeks||l.months||l.years)&&O(w.add({weeks:1}))},focusPreviousRow(){l.days?this.focusPreviousPage():(l.weeks||l.months||l.years)&&O(w.subtract({weeks:1}))},focusNextPage(){let e=x.add(j);E(vH(w.add(j),u,c)),D(vU(vW(w,e,j,i,u,c),j,i))},focusPreviousPage(){let e=x.subtract(j);E(vH(w.subtract(j),u,c)),D(vU(vW(w,e,j,i,u,c),j,i))},focusSectionStart(){l.days?O(x):l.weeks?O(yE(w,i)):(l.months||l.years)&&O(yb(w))},focusSectionEnd(){l.days?O(C):l.weeks?O(yE(w,i,void 0).add({days:6})):(l.months||l.years)&&O(yw(w))},focusNextSection(e){e||l.days?l.days?this.focusNextPage():l.weeks?O(w.add({months:1})):(l.months||l.years)&&O(w.add({years:1})):O(w.add(vZ(l)))},focusPreviousSection(e){e||l.days?l.days?this.focusPreviousPage():l.weeks?O(w.subtract({months:1})):(l.months||l.years)&&O(w.subtract({years:1})):O(w.subtract(vZ(l)))},selectFocusedDate(){f&&f(w)||R(w)},selectDate(e){R(e)},isFocused:_,setFocused:S,isInvalid:e=>vF(e,u,c),isSelected(e){return null!=v&&yl(e,v)&&!this.isCellDisabled(e)&&!this.isCellUnavailable(e)},isCellFocused:e=>_&&w&&yl(e,w),isCellDisabled(t){return e.isDisabled||0>t.compare(x)||t.compare(C)>0||this.isInvalid(t)},isCellUnavailable:t=>!!e.isDateUnavailable&&e.isDateUnavailable(t),isPreviousVisibleRangeInvalid(){let e=x.subtract({days:1});return yl(e,x)||this.isInvalid(e)},isNextVisibleRangeInvalid(){let e=C.add({days:1});return yl(e,C)||this.isInvalid(e)},getDatesInWeek(e,t=x){let r=t.add({weeks:e}),n=[],o=yf(r=yE(r,i,m),i,m);for(let e=0;e<o;e++)n.push(null);for(;n.length<7;){n.push(r);let e=r.add({days:1});if(yl(r,e))break;r=e}for(;n.length<7;)n.push(null);return n}}}function vZ(e){let t={...e};for(let r in e)t[r]=1;return t}function vY(e,t){return e&&t?(0>t.compare(e)&&([e,t]=[t,e]),{start:yo(e),end:yo(t)}):null}function vq(e,t){return(e=yi(e,(null==t?void 0:t.calendar)||new gT),t&&"hour"in t)?t.set(e):e}function vJ(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 vX=(0,cu.createContext)(null),vQ=(0,cu.createContext)(null),v0=(0,cu.createContext)(null),v1=(0,cu.createContext)(null),v2=(0,cu.forwardRef)(function(e,t){[e,t]=mL(e,t,vX);let{locale:r}=gD(),n=vG({...e,locale:r,createCalendar:e.createCalendar||vL}),{calendarProps:o,prevButtonProps:a,nextButtonProps:i,errorMessageProps:s,title:l}=yq(e,n),u=mI({...e,values:{state:n,isDisabled:e.isDisabled||!1,isInvalid:n.isValueInvalid},defaultClassName:"react-aria-Calendar"});return cc().createElement("div",{...u,...o,ref:t,slot:e.slot||void 0,"data-disabled":e.isDisabled||void 0,"data-invalid":n.isValueInvalid||void 0},cc().createElement(m$,{values:[[gs,{slots:{previous:a,next:i}}],[gu,{"aria-hidden":!0,level:2,children:l}],[v0,n],[vX,e],[gc,{slots:{errorMessage:s}}]]},cc().createElement(yX,null,cc().createElement("h2",null,o["aria-label"])),u.children,cc().createElement(yX,null,cc().createElement("button",{"aria-label":i["aria-label"],disabled:i.isDisabled,onClick:()=>n.focusNextPage(),tabIndex:-1}))))}),v4=(0,cu.forwardRef)(function(e,t){var r,n;let o,a,i;[e,t]=mL(e,t,vQ);let{locale:s}=gD(),l=function(e){let{value:t,defaultValue:r,onChange:n,createCalendar:o,locale:a,visibleDuration:i={months:1},minValue:s,maxValue:l,...u}=e,[c,d]=vK(t,r||null,n),[f,p]=(0,cu.useState)(null),m="center";if(c&&c.start&&c.end){let e=vB(yo(c.start),i,a,s,l).add(i).subtract({days:1});c.end.compare(e)>0&&(m="start")}let h=(0,cu.useRef)(null),[g,y]=(0,cu.useState)(null),v=(0,cu.useMemo)(()=>y_(s,null==g?void 0:g.start),[s,g]),b=(0,cu.useMemo)(()=>yD(l,null==g?void 0:g.end),[l,g]),w=vG({...u,value:c&&c.start,createCalendar:o,locale:a,visibleDuration:i,minValue:v,maxValue:b,selectionAlignment:m}),E=t=>{t&&e.isDateUnavailable&&!e.allowsNonContiguousRanges?(h.current={start:vJ(t,w,-1),end:vJ(t,w,1)},y(h.current)):(h.current=null,y(null))},[x,D]=(0,cu.useState)(w.visibleRange);yu(w.visibleRange.start,x.start)&&yu(w.visibleRange.end,x.end)||(E(f),D(w.visibleRange));let _=e=>{e?(p(e),E(e)):(p(null),E(null))},S=f?vY(f,w.focusedDate):c&&vY(c.start,c.end),C=t=>{if(e.isReadOnly)return;let r=vz(vH(t,v,b),w.visibleRange.start,e.isDateUnavailable);if(r)if(f){let e=vY(f,r);e&&d({start:vq(e.start,null==c?void 0:c.start),end:vq(e.end,null==c?void 0:c.end)}),_(null)}else _(r)},[k,P]=(0,cu.useState)(!1),{isDateUnavailable:O}=e,R=(0,cu.useMemo)(()=>!!c&&!f&&(!!(O&&(O(c.start)||O(c.end)))||vF(c.start,s,l)||vF(c.end,s,l)),[O,c,f,s,l]),T=e.isInvalid||"invalid"===e.validationState||R;return{...w,value:c,setValue:d,anchorDate:f,setAnchorDate:_,highlightedRange:S,validationState:T?"invalid":null,isValueInvalid:T,selectFocusedDate(){C(w.focusedDate)},selectDate:C,highlightDate(e){f&&w.setFocusedDate(e)},isSelected:e=>!!(S&&e.compare(S.start)>=0&&0>=e.compare(S.end)&&!w.isCellDisabled(e)&&!w.isCellUnavailable(e)),isInvalid(e){var t,r;return w.isInvalid(e)||vF(e,null==(t=h.current)?void 0:t.start,null==(r=h.current)?void 0:r.end)},isDragging:k,setDragging:P}}({...e,locale:s,createCalendar:e.createCalendar||vL}),{calendarProps:u,prevButtonProps:c,nextButtonProps:d,errorMessageProps:f,title:p}=(r=e,n=t,o=yq(r,l),a=(0,cu.useRef)(!1),yQ(i=(0,cu.useRef)("u">typeof window?window:null),"pointerdown",e=>{a.current=0===e.width&&0===e.height}),yQ(i,"pointerup",e=>{if(a.current){a.current=!1;return}if(l.setDragging(!1),!l.anchorDate)return;let t=e.target;n.current&&n.current.contains(document.activeElement)&&(!n.current.contains(t)||!t.closest('button, [role="button"]'))&&l.selectFocusedDate()}),o.calendarProps.onBlur=e=>{n.current&&(e.relatedTarget&&n.current.contains(e.relatedTarget)||!l.anchorDate||l.selectFocusedDate())},yQ(n,"touchmove",e=>{l.isDragging&&e.preventDefault()},{passive:!1,capture:!0}),o),m=mI({...e,values:{state:l,isDisabled:e.isDisabled||!1,isInvalid:l.isValueInvalid},defaultClassName:"react-aria-RangeCalendar"});return cc().createElement("div",{...m,...u,ref:t,slot:e.slot||void 0,"data-disabled":e.isDisabled||void 0,"data-invalid":l.isValueInvalid||void 0},cc().createElement(m$,{values:[[gs,{slots:{previous:c,next:d}}],[gu,{"aria-hidden":!0,level:2,children:p}],[v1,l],[vQ,e],[gc,{slots:{errorMessage:f}}]]},cc().createElement(yX,null,cc().createElement("h2",null,u["aria-label"])),m.children,cc().createElement(yX,null,cc().createElement("button",{"aria-label":d["aria-label"],disabled:d.isDisabled,onClick:()=>l.focusNextPage(),tabIndex:-1}))))}),v3=(0,cu.createContext)(null),v6=(0,cu.forwardRef)(function(e,t){var r,n;let o=(0,cu.useContext)(v0),a=(0,cu.useContext)(v1),i=mM(vX),s=mM(vQ),l=null!=o?o:a,u=l.visibleRange.start;e.offset&&(u=u.add(e.offset));let c=null!=(r=null==i?void 0:i.firstDayOfWeek)?r:null==s?void 0:s.firstDayOfWeek,{gridProps:d,headerProps:f,weekDays:p,weeksInMonth:m}=function(e,t){let r,{startDate:n=t.visibleRange.start,endDate:o=t.visibleRange.end,firstDayOfWeek:a}=e,{direction:i}=gD(),s=yK(n,o,t.timeZone,!0),{ariaLabel:l,ariaLabelledBy:u}=yH.get(t),c=yY({"aria-label":[l,s].filter(Boolean).join(", "),"aria-labelledby":u}),d=yU({weekday:e.weekdayStyle||"narrow",timeZone:t.timeZone}),{locale:f}=gD(),p=(0,cu.useMemo)(()=>{let e=yE(ym(t.timeZone),f,a);return[...Array(7).keys()].map(r=>{let n=e.add({days:r}).toDate(t.timeZone);return d.format(n)})},[f,t.timeZone,d,a]),m=(r=n.calendar.getDaysInMonth(n),Math.ceil((yf(yb(n),f,a)+r)/7));return{gridProps:mj(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"===i?t.focusNextDay():t.focusPreviousDay();break;case"ArrowUp":e.preventDefault(),e.stopPropagation(),t.focusPreviousRow();break;case"ArrowRight":e.preventDefault(),e.stopPropagation(),"rtl"===i?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:m}}({startDate:u,endDate:yw(u),weekdayStyle:e.weekdayStyle,firstDayOfWeek:c},l);return cc().createElement(v3.Provider,{value:{headerProps:f,weekDays:p,startDate:u,weeksInMonth:m}},cc().createElement("table",{...mY(e),...d,ref:t,style:e.style,className:null!=(n=e.className)?n:"react-aria-CalendarGrid"},"function"!=typeof e.children?e.children:cc().createElement(cc().Fragment,null,cc().createElement(v5,null,e=>cc().createElement(v9,null,e)),cc().createElement(v8,null,e.children))))}),v5=(0,cu.forwardRef)(function(e,t){let{children:r,style:n,className:o}=e,{headerProps:a,weekDays:i}=(0,cu.useContext)(v3);return cc().createElement("thead",{...mY(e),...a,ref:t,style:n,className:o||"react-aria-CalendarGridHeader"},cc().createElement("tr",null,i.map((e,t)=>cc().cloneElement(r(e),{key:t}))))}),v9=(0,cu.forwardRef)(function(e,t){let{children:r,style:n,className:o}=e;return cc().createElement("th",{...mY(e),ref:t,style:n,className:o||"react-aria-CalendarHeaderCell"},r)}),v8=(0,cu.forwardRef)(function(e,t){let{children:r,style:n,className:o}=e,a=(0,cu.useContext)(v0),i=(0,cu.useContext)(v1),s=null!=a?a:i,{startDate:l,weeksInMonth:u}=(0,cu.useContext)(v3);return cc().createElement("tbody",{...mY(e),ref:t,style:n,className:o||"react-aria-CalendarGridBody"},[...Array(u).keys()].map(e=>cc().createElement("tr",{key:e},s.getDatesInWeek(e,l).map((e,t)=>e?cc().cloneElement(r(e),{key:t}):cc().createElement("td",{key:t})))))}),v7=(0,cu.forwardRef)(function({date:e,...t},r){var n,o,a;let i=(0,cu.useContext)(v0),s=(0,cu.useContext)(v1),l=null!=i?i:s,{startDate:u}=null!=(n=(0,cu.useContext)(v3))?n:{startDate:l.visibleRange.start},c=(0,cu.useRef)(null),{cellProps:d,buttonProps:f,...p}=function(e,t,r){var n;let o,{date:a,isDisabled:i}=e,{errorMessageId:s,selectedDateDescription:l}=yH.get(t),u=yj((n=g_)&&n.__esModule?n.default:n,"@react-aria/calendar"),c=yU({weekday:"long",day:"numeric",month:"long",year:"numeric",era:yz(a),timeZone:t.timeZone}),d=t.isSelected(a),f=t.isCellFocused(a);i=i||t.isCellDisabled(a);let p=t.isCellUnavailable(a),m=!i&&!p,h=t.isValueInvalid&&!!("highlightedRange"in t?!t.anchorDate&&t.highlightedRange&&a.compare(t.highlightedRange.start)>=0&&0>=a.compare(t.highlightedRange.end):t.value&&yl(t.value,a));h&&(d=!0),a=yB(a,yu);let g=(0,cu.useMemo)(()=>a.toDate(t.timeZone),[a,t.timeZone]),y=yl(a,ym(t.timeZone)),v=(0,cu.useMemo)(()=>{let e="";return"highlightedRange"in t&&t.value&&!t.anchorDate&&(yl(a,t.value.start)||yl(a,t.value.end))&&(e=l+", "),e+=c.format(g),y?e=u.format(d?"todayDateSelected":"todayDate",{date:e}):d&&(e=u.format("dateSelected",{date:e})),t.minValue&&yl(a,t.minValue)?e+=", "+u.format("minimumDate"):t.maxValue&&yl(a,t.maxValue)&&(e+=", "+u.format("maximumDate")),e},[c,g,u,d,y,a,t,l]),b="";"anchorDate"in t&&f&&!t.isReadOnly&&m&&(b=t.anchorDate?u.format("finishRangeSelectionPrompt"):u.format("startRangeSelectionPrompt"));let w=y2(b),E=(0,cu.useRef)(!1),x=(0,cu.useRef)(!1),D=(0,cu.useRef)(void 0),{pressProps:_,isPressed:S}=hj({shouldCancelOnPointerExit:"anchorDate"in t&&!!t.anchorDate,preventFocusOnPress:!0,isDisabled:!m||t.isReadOnly,onPressStart(e){if(t.isReadOnly)return void t.setFocusedDate(a);if("highlightedRange"in t&&!t.anchorDate&&("mouse"===e.pointerType||"touch"===e.pointerType)){if(t.highlightedRange&&!h){if(yl(a,t.highlightedRange.start)){t.setAnchorDate(t.highlightedRange.end),t.setFocusedDate(a),t.setDragging(!0),x.current=!0;return}else if(yl(a,t.highlightedRange.end)){t.setAnchorDate(t.highlightedRange.start),t.setFocusedDate(a),t.setDragging(!0),x.current=!0;return}}let r=()=>{t.setDragging(!0),D.current=void 0,t.selectDate(a),t.setFocusedDate(a),E.current=!0};"touch"===e.pointerType?D.current=setTimeout(r,200):r()}},onPressEnd(){x.current=!1,E.current=!1,clearTimeout(D.current),D.current=void 0},onPress(){"anchorDate"in t||t.isReadOnly||(t.selectDate(a),t.setFocusedDate(a))},onPressUp(e){if(!t.isReadOnly&&("anchorDate"in t&&D.current&&(t.selectDate(a),t.setFocusedDate(a)),"anchorDate"in t))if(x.current)t.setAnchorDate(a);else if(t.anchorDate&&!E.current)t.selectDate(a),t.setFocusedDate(a);else if("keyboard"!==e.pointerType||t.anchorDate)"virtual"===e.pointerType&&(t.selectDate(a),t.setFocusedDate(a));else{t.selectDate(a);let e=a.add({days:1});t.isInvalid(e)&&(e=a.subtract({days:1})),t.isInvalid(e)||t.setFocusedDate(e)}}});i||(o=yl(a,t.focusedDate)?0:-1),(0,cu.useEffect)(()=>{f&&r.current&&(m4(r.current),"pointer"!==hB&&document.activeElement===r.current&&y6(r.current,{containingElement:y5(r.current)}))},[f,r]);let C=yU({day:"numeric",timeZone:t.timeZone,calendar:a.calendar.identifier}),k=(0,cu.useMemo)(()=>C.formatToParts(g).find(e=>"day"===e.type).value,[C,g]);return{cellProps:{role:"gridcell","aria-disabled":!m||void 0,"aria-selected":d||void 0,"aria-invalid":h||void 0},buttonProps:mj(_,{onFocus(){i||t.setFocusedDate(a)},tabIndex:o,role:"button","aria-disabled":!m||void 0,"aria-label":v,"aria-invalid":h||void 0,"aria-describedby":[h?s:void 0,w["aria-describedby"]].filter(Boolean).join(" ")||void 0,onPointerEnter(e){"highlightDate"in t&&("touch"!==e.pointerType||t.isDragging)&&m&&t.highlightDate(a)},onPointerDown(e){"releasePointerCapture"in e.target&&e.target.releasePointerCapture(e.pointerId)},onContextMenu(e){e.preventDefault()}}),isPressed:S,isFocused:f,isSelected:d,isDisabled:i,isUnavailable:p,isOutsideVisibleRange:0>a.compare(t.visibleRange.start)||a.compare(t.visibleRange.end)>0,isInvalid:h,formattedDate:k}}({date:e},l,c),{hoverProps:m,isHovered:h}=gn({...t,isDisabled:p.isDisabled}),{focusProps:g,isFocusVisible:y}=h8();y&&(y=p.isFocused);let v=(o=u,a=yi(a=e,o.calendar),o=yb(o),a=yb(a),o.era!==a.era||o.year!==a.year||o.month!==a.month),b=!1,w=!1;"highlightedRange"in l&&l.highlightedRange&&(b=yl(e,l.highlightedRange.start),w=yl(e,l.highlightedRange.end));let E=mI({...t,defaultChildren:p.formattedDate,defaultClassName:"react-aria-CalendarCell",values:{date:e,isHovered:h,isOutsideMonth:v,isFocusVisible:y,isSelectionStart:b,isSelectionEnd:w,...p}}),x={"data-focused":p.isFocused||void 0,"data-hovered":h||void 0,"data-pressed":p.isPressed||void 0,"data-unavailable":p.isUnavailable||void 0,"data-disabled":p.isDisabled||void 0,"data-focus-visible":y||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":b||void 0,"data-selection-end":w||void 0,"data-invalid":p.isInvalid||void 0};return cc().createElement("td",{...d,ref:r},cc().createElement("div",{...mj(mY(t),f,g,m,x,E),ref:c}))}),be=(0,cu.createContext)({}),bt=(0,cu.forwardRef)(function(e,t){var r,n;[e,t]=mL(e,t,be);let{isDisabled:o,isInvalid:a,onHoverStart:i,onHoverChange:s,onHoverEnd:l,...u}=e,{hoverProps:c,isHovered:d}=gn({onHoverStart:i,onHoverChange:s,onHoverEnd:l,isDisabled:o}),{isFocused:f,isFocusVisible:p,focusProps:m}=h8({within:!0});null!=o||(o=!!e["aria-disabled"]&&"false"!==e["aria-disabled"]),null!=a||(a=!!e["aria-invalid"]&&"false"!==e["aria-invalid"]);let h=mI({...e,values:{isHovered:d,isFocusWithin:f,isFocusVisible:p,isDisabled:o,isInvalid:a},defaultClassName:"react-aria-Group"});return cc().createElement("div",{...mj(u,m,c),...h,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":a||void 0},h.children)}),br=(0,cu.createContext)({}),bn=ga(function(e,t){[e,t]=mL(e,t,br);let{hoverProps:r,isHovered:n}=gn(e),{isFocused:o,isFocusVisible:a,focusProps:i}=h8({isTextInput:!0,autoFocus:e.autoFocus}),s=!!e["aria-invalid"]&&"false"!==e["aria-invalid"],l=mI({...e,values:{isHovered:n,isFocused:o,isFocusVisible:a,isDisabled:e.disabled||!1,isInvalid:s},defaultClassName:"react-aria-Input"});return cc().createElement("input",{...mj((e=>{let{onHoverStart:t,onHoverChange:r,onHoverEnd:n,...o}=e;return o})(e),i,r),...l,ref:t,"data-focused":o||void 0,"data-disabled":e.disabled||void 0,"data-hovered":n||void 0,"data-focus-visible":a||void 0,"data-invalid":s||void 0})});var bo={};bo={"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 ba=cc().createContext(null),bi="react-aria-focus-scope-restore",bs=null;function bl(e){var t,r,n,o,a,i,s,l,u,c;let d,f,p,m,{children:h,contain:g,restoreFocus:y,autoFocus:v}=e,b=(0,cu.useRef)(null),w=(0,cu.useRef)(null),E=(0,cu.useRef)([]),{parentNode:x}=(0,cu.useContext)(ba)||{},D=(0,cu.useMemo)(()=>new bD({scopeRef:E}),[E]);my(()=>{let e=x||b_.root;if(b_.getTreeNode(e.scopeRef)&&bs&&!bp(bs,e.scopeRef)){let t=b_.getTreeNode(bs);t&&(e=t)}e.addChild(D),b_.addNode(D)},[D,x]),my(()=>{let e=b_.getTreeNode(E);e&&(e.contain=!!g)},[g]),my(()=>{var e;let t=null==(e=b.current)?void 0:e.nextSibling,r=[],n=e=>e.stopPropagation();for(;t&&t!==w.current;)r.push(t),t.addEventListener(bi,n),t=t.nextSibling;return E.current=r,()=>{for(let e of r)e.removeEventListener(bi,n)}},[h]),my(()=>{if(r||n)return;let e=t.current,o=m1(e?e[0]:void 0),a=e=>{let r=hS(e);bd(r,t.current)?bs=t:bf(r)||(bs=null)};return o.addEventListener("focusin",a,!1),null==e||e.forEach(e=>e.addEventListener("focusin",a,!1)),()=>{o.removeEventListener("focusin",a,!1),null==e||e.forEach(e=>e.removeEventListener("focusin",a,!1))}},[t=E,r=y,n=g]),o=E,a=g,d=(0,cu.useRef)(void 0),f=(0,cu.useRef)(void 0),my(()=>{let e=o.current;if(!a){f.current&&(cancelAnimationFrame(f.current),f.current=void 0);return}let t=m1(e?e[0]:void 0),r=e=>{if("Tab"!==e.key||e.altKey||e.ctrlKey||e.metaKey||!bc(o)||e.isComposing)return;let r=((e=document)=>e.activeElement)(t),n=o.current;if(!n||!bd(r,n))return;let a=bb(bu(n),{tabbable:!0},n);if(!r)return;a.currentNode=r;let i=e.shiftKey?a.previousNode():a.nextNode();i||(a.currentNode=e.shiftKey?n[n.length-1].nextElementSibling:n[0].previousElementSibling,i=e.shiftKey?a.previousNode():a.nextNode()),e.preventDefault(),i&&bm(i,!0)},n=e=>{(!bs||bp(bs,o))&&bd(hS(e),o.current)?(bs=o,d.current=hS(e)):bc(o)&&!bf(hS(e),o)?d.current?d.current.focus():bs&&bs.current&&bg(bs.current):bc(o)&&(d.current=hS(e))},i=e=>{f.current&&cancelAnimationFrame(f.current),f.current=requestAnimationFrame(()=>{let r=hB,n=("virtual"===r||null===r)&&hl()&&hs(),a=((e=document)=>e.activeElement)(t);if(!n&&a&&bc(o)&&!bf(a,o)){bs=o;let t=hS(e);if(t&&t.isConnected){var i;d.current=t,null==(i=d.current)||i.focus()}else bs.current&&bg(bs.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",i,!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",i,!1))}},[o,a]),my(()=>()=>{f.current&&cancelAnimationFrame(f.current)},[f]),i=E,s=y,l=g,p=(0,cu.useRef)("u">typeof document?((e=document)=>e.activeElement)(m1(i.current?i.current[0]:void 0)):null),my(()=>{let e=i.current,t=m1(e?e[0]:void 0);if(!s||l)return;let r=()=>{(!bs||bp(bs,i))&&bd(((e=document)=>e.activeElement)(t),i.current)&&(bs=i)};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))}},[i,l]),my(()=>{let e=m1(i.current?i.current[0]:void 0);if(!s)return;let t=t=>{if("Tab"!==t.key||t.altKey||t.ctrlKey||t.metaKey||!bc(i)||t.isComposing)return;let r=e.activeElement;if(!bf(r,i)||!by(i))return;let n=b_.getTreeNode(i);if(!n)return;let o=n.nodeToRestore,a=bb(e.body,{tabbable:!0});a.currentNode=r;let s=t.shiftKey?a.previousNode():a.nextNode();if(o&&o.isConnected&&o!==e.body||(o=void 0,n.nodeToRestore=void 0),(!s||!bf(s,i))&&o){a.currentNode=o;do s=t.shiftKey?a.previousNode():a.nextNode();while(bf(s,i));(t.preventDefault(),t.stopPropagation(),s)?bm(s,!0):bf(o)?bm(o,!0):r.blur()}};return l||e.addEventListener("keydown",t,!0),()=>{l||e.removeEventListener("keydown",t,!0)}},[i,s,l]),my(()=>{var e;let t=m1(i.current?i.current[0]:void 0);if(!s)return;let r=b_.getTreeNode(i);if(r)return r.nodeToRestore=null!=(e=p.current)?e:void 0,()=>{let e=b_.getTreeNode(i);if(!e)return;let r=e.nodeToRestore,n=((e=document)=>e.activeElement)(t);if(s&&r&&(n&&bf(n,i)||n===t.body&&by(i))){let e=b_.clone();requestAnimationFrame(()=>{if(t.activeElement===t.body){let t=e.getTreeNode(i);for(;t;){if(t.nodeToRestore&&t.nodeToRestore.isConnected)return void bv(t.nodeToRestore);t=t.parent}for(t=e.getTreeNode(i);t;){if(t.scopeRef&&t.scopeRef.current&&b_.getTreeNode(t.scopeRef))return void bv(bh(t.scopeRef.current,!0));t=t.parent}}})}}},[i,s]),u=E,c=v,m=cc().useRef(c),(0,cu.useEffect)(()=>{m.current&&(bs=u,!bd(((e=document)=>e.activeElement)(m1(u.current?u.current[0]:void 0)),bs.current)&&u.current&&bg(u.current)),m.current=!1},[u]),(0,cu.useEffect)(()=>{let e=((e=document)=>e.activeElement)(m1(E.current?E.current[0]:void 0)),t=null;if(bd(e,E.current)){for(let r of b_.traverse())r.scopeRef&&bd(e,r.scopeRef.current)&&(t=r);t===b_.getTreeNode(E)&&(bs=t.scopeRef)}},[E]),my(()=>()=>{var e,t,r;let n=null!=(r=null==(t=b_.getTreeNode(E))||null==(e=t.parent)?void 0:e.scopeRef)?r:null;(E===bs||bp(E,bs))&&(!n||b_.getTreeNode(n))&&(bs=n),b_.removeTreeNode(E)},[E]);let _=(0,cu.useMemo)(()=>{var e;return e=E,{focusNext(t={}){var r;let n=e.current,{from:o,tabbable:a,wrap:i,accept:s}=t,l=o||((e=document)=>e.activeElement)(m1(null!=(r=n[0])?r:void 0)),u=n[0].previousElementSibling,c=bb(bu(n),{tabbable:a,accept:s},n);c.currentNode=bd(l,n)?l:u;let d=c.nextNode();return!d&&i&&(c.currentNode=u,d=c.nextNode()),d&&bm(d,!0),d},focusPrevious(t={}){var r;let n=e.current,{from:o,tabbable:a,wrap:i,accept:s}=t,l=o||((e=document)=>e.activeElement)(m1(null!=(r=n[0])?r:void 0)),u=n[n.length-1].nextElementSibling,c=bb(bu(n),{tabbable:a,accept:s},n);c.currentNode=bd(l,n)?l:u;let d=c.previousNode();return!d&&i&&(c.currentNode=u,d=c.previousNode()),d&&bm(d,!0),d},focusFirst(t={}){let r=e.current,{tabbable:n,accept:o}=t,a=bb(bu(r),{tabbable:n,accept:o},r);a.currentNode=r[0].previousElementSibling;let i=a.nextNode();return i&&bm(i,!0),i},focusLast(t={}){let r=e.current,{tabbable:n,accept:o}=t,a=bb(bu(r),{tabbable:n,accept:o},r);a.currentNode=r[r.length-1].nextElementSibling;let i=a.previousNode();return i&&bm(i,!0),i}}},[]),S=(0,cu.useMemo)(()=>({focusManager:_,parentNode:D}),[D,_]);return cc().createElement(ba.Provider,{value:S},cc().createElement("span",{"data-focus-scope-start":!0,hidden:!0,ref:b}),h,cc().createElement("span",{"data-focus-scope-end":!0,hidden:!0,ref:w}))}function bu(e){return e[0].parentElement}function bc(e){let t=b_.getTreeNode(bs);for(;t&&t.scopeRef!==e;){if(t.contain)return!1;t=t.parent}return!0}function bd(e,t){return!!e&&!!t&&t.some(t=>t.contains(e))}function bf(e,t=null){if(e instanceof Element&&e.closest("[data-react-aria-top-layer]"))return!0;for(let{scopeRef:r}of b_.traverse(b_.getTreeNode(t)))if(r&&bd(e,r.current))return!0;return!1}function bp(e,t){var r;let n=null==(r=b_.getTreeNode(t))?void 0:r.parent;for(;n;){if(n.scopeRef===e)return!0;n=n.parent}return!1}function bm(e,t=!1){if(null==e||t){if(null!=e)try{e.focus()}catch{}}else try{h2(e)}catch{}}function bh(e,t=!0){let r=e[0].previousElementSibling,n=bu(e),o=bb(n,{tabbable:t},e);o.currentNode=r;let a=o.nextNode();return t&&!a&&((o=bb(n=bu(e),{tabbable:!1},e)).currentNode=r,a=o.nextNode()),a}function bg(e,t=!0){bm(bh(e,t))}function by(e){let t=b_.getTreeNode(bs);for(;t&&t.scopeRef!==e;){if(t.nodeToRestore)return!1;t=t.parent}return(null==t?void 0:t.scopeRef)===e}function bv(e){e.dispatchEvent(new CustomEvent(bi,{bubbles:!0,cancelable:!0}))&&bm(e)}function bb(e,t,r){var n,o,a;let i=(null==t?void 0:t.tabbable)?m0:mQ,s=m1((null==e?void 0:e.nodeType)===Node.ELEMENT_NODE?e:null),l=(n=e||s,o=NodeFilter.SHOW_ELEMENT,a={acceptNode(e){var n;return(null==t||null==(n=t.from)?void 0:n.contains(e))?NodeFilter.FILTER_REJECT:i(e)&&function e(t,r){return"#comment"!==t.nodeName&&function(e){let t=m2(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||bd(e,r))&&(!(null==t?void 0:t.accept)||t.accept(e))?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}},s.createTreeWalker(n,o,a));return(null==t?void 0:t.from)&&(l.currentNode=t.from),l}function bw(e,t={}){return{focusNext(r={}){let n=e.current;if(!n)return null;let{from:o,tabbable:a=t.tabbable,wrap:i=t.wrap,accept:s=t.accept}=r,l=o||((e=document)=>e.activeElement)(m1(n)),u=bb(n,{tabbable:a,accept:s});n.contains(l)&&(u.currentNode=l);let c=u.nextNode();return!c&&i&&(u.currentNode=n,c=u.nextNode()),c&&bm(c,!0),c},focusPrevious(r=t){let n=e.current;if(!n)return null;let{from:o,tabbable:a=t.tabbable,wrap:i=t.wrap,accept:s=t.accept}=r,l=o||((e=document)=>e.activeElement)(m1(n)),u=bb(n,{tabbable:a,accept:s});if(n.contains(l))u.currentNode=l;else{let e=bE(u);return e&&bm(e,!0),null!=e?e:null}let c=u.previousNode();if(!c&&i){u.currentNode=n;let e=bE(u);if(!e)return null;c=e}return c&&bm(c,!0),null!=c?c:null},focusFirst(r=t){let n=e.current;if(!n)return null;let{tabbable:o=t.tabbable,accept:a=t.accept}=r,i=bb(n,{tabbable:o,accept:a}).nextNode();return i&&bm(i,!0),i},focusLast(r=t){let n=e.current;if(!n)return null;let{tabbable:o=t.tabbable,accept:a=t.accept}=r,i=bE(bb(n,{tabbable:o,accept:a}));return i&&bm(i,!0),null!=i?i:null}}}function bE(e){let t,r;do(t=e.lastChild())&&(r=t);while(t);return r}class bx{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 bD({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&&bd(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 bx;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 bD({scopeRef:null}),this.fastMap.set(null,this.root)}}class bD{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 b_=new bx;function bS(e,t,r){let{direction:n}=gD(),o=(0,cu.useMemo)(()=>bw(t),[t]),a=()=>{var e;if(!t.current)return;let r=null==(e=window.event)?void 0:e.target,n=bb(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:i}=hj({preventFocusOnPress:!0,allowTextSelectionOnPress:!0,onPressStart(e){"mouse"===e.pointerType&&a()},onPress(e){"mouse"!==e.pointerType&&a()}});return mj(i,{onKeyDown:a=>{if(a.currentTarget.contains(a.target)&&(a.altKey&&("ArrowDown"===a.key||"ArrowUp"===a.key)&&"setOpen"in e&&(a.preventDefault(),a.stopPropagation(),e.setOpen(!0)),!r))switch(a.key){case"ArrowLeft":if(a.preventDefault(),a.stopPropagation(),"rtl"===n){if(t.current){let e=a.target,r=bC(t.current,e.getBoundingClientRect().left,-1);r&&r.focus()}}else o.focusPrevious();break;case"ArrowRight":if(a.preventDefault(),a.stopPropagation(),"rtl"===n){if(t.current){let e=a.target,r=bC(t.current,e.getBoundingClientRect().left,1);r&&r.focus()}}else o.focusNext()}}})}function bC(e,t,r){let n=bb(e,{tabbable:!0}),o=n.nextNode(),a=null,i=1/0;for(;o;){let e=o.getBoundingClientRect().left-t,s=Math.abs(e);Math.sign(e)===r&&s<i&&(a=o,i=s),o=n.nextNode()}return a}function bk(e,t,r){let n=(0,cu.useRef)(t),o=mv(()=>{r&&r(n.current)});(0,cu.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 bP(e){let{description:t,errorMessage:r,isInvalid:n,validationState:o}=e,{labelProps:a,fieldProps:i}=function(e){let{id:t,label:r,"aria-labelledby":n,"aria-label":o,labelElementType:a="label"}=e;t=mR(t);let i=mR(),s={};return r&&(n=n?`${i} ${n}`:i,s={id:i,htmlFor:"label"===a?t:void 0}),{labelProps:s,fieldProps:yY({id:t,"aria-label":o,"aria-labelledby":n})}}(e),s=mT([!!t,!!r,n,o]),l=mT([!!t,!!r,n,o]);return{labelProps:a,fieldProps:i=mj(i,{"aria-describedby":[s,l,e["aria-describedby"]].filter(Boolean).join(" ")||void 0}),descriptionProps:{id:s},errorMessageProps:{id:l}}}function bO(e,t,r){let{validationBehavior:n,focus:o}=e;my(()=>{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 a=mv(()=>{t.resetValidation()}),i=mv(e=>{var n,a;t.displayValidation.isInvalid||t.commitValidation();let i=null==r||null==(n=r.current)?void 0:n.form;!e.defaultPrevented&&r&&i&&function(e){for(let t=0;t<e.elements.length;t++){let r=e.elements[t];if(!r.validity.valid)return r}return null}(i)===r.current&&(o?o():null==(a=r.current)||a.focus(),hB="keyboard",hK("keyboard",null)),e.preventDefault()}),s=mv(()=>{t.commitValidation()});(0,cu.useEffect)(()=>{let e=null==r?void 0:r.current;if(!e)return;let t=e.form;return e.addEventListener("invalid",i),e.addEventListener("change",s),null==t||t.addEventListener("reset",a),()=>{e.removeEventListener("invalid",i),e.removeEventListener("change",s),null==t||t.removeEventListener("reset",a)}},[r,i,s,a,n])}let bR=new WeakMap,bT="__role_"+Date.now(),bN="__focusManager_"+Date.now();function bj(e,t,r){var n,o;let a,{isInvalid:i,validationErrors:s,validationDetails:l}=t.displayValidation,{labelProps:u,fieldProps:c,descriptionProps:d,errorMessageProps:f}=bP({...e,labelElementType:"span",isInvalid:i,errorMessage:e.errorMessage||s}),p=(0,cu.useRef)(null),{focusWithinProps:m}=h9({...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}),h=yj((o=bo)&&o.__esModule?o.default:o,"@react-aria/datepicker"),g="hour"===t.maxGranularity?"selectedTimeDescription":"selectedDateDescription",y="hour"===t.maxGranularity?"time":"date",v=y2(t.value?h.format(g,{[y]:t.formatValue({month:"long"})}):""),b="presentation"===e[bT]?c["aria-describedby"]:[v["aria-describedby"],c["aria-describedby"]].filter(Boolean).join(" ")||void 0,w=e[bN],E=(0,cu.useMemo)(()=>w||bw(r),[w,r]),x=bS(t,r,"presentation"===e[bT]);bR.set(t,{ariaLabel:e["aria-label"],ariaLabelledBy:[u.id,e["aria-labelledby"]].filter(Boolean).join(" ")||void 0,ariaDescribedBy:b,focusManager:E});let D=(0,cu.useRef)(e.autoFocus);a="presentation"===e[bT]?{role:"presentation"}:mj(c,{role:"group","aria-disabled":e.isDisabled||void 0,"aria-describedby":b}),(0,cu.useEffect)(()=>{D.current&&E.focusFirst(),D.current=!1},[E]),bk(e.inputRef,t.value,t.setValue),bO({...e,focus(){E.focusFirst()}},t,e.inputRef);let _={type:"hidden",name:e.name,value:(null==(n=t.value)?void 0:n.toString())||"",disabled:e.isDisabled};"native"===e.validationBehavior&&(_.type="text",_.hidden=!0,_.required=e.isRequired,_.onChange=()=>{});let S=mY(e);return{labelProps:{...u,onClick:()=>{E.focusFirst()}},fieldProps:mj(S,a,x,m,{onKeyDown(t){e.onKeyDown&&e.onKeyDown(t)},onKeyUp(t){e.onKeyUp&&e.onKeyUp(t)},style:{unicodeBidi:"isolate"}}),inputProps:_,descriptionProps:d,errorMessageProps:f,isInvalid:i,validationErrors:s,validationDetails:l}}var bA={};bA={"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 b$={badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valueMissing:!1,valid:!0},bI={...b$,customError:!0,valid:!1},bM={isInvalid:!1,validationDetails:b$,validationErrors:[]},bL=(0,cu.createContext)({}),bF="__formValidationState"+Date.now();function bB(e){if(e[bF]){let{realtimeValidation:t,displayValidation:r,updateValidation:n,resetValidation:o,commitValidation:a}=e[bF];return{realtimeValidation:t,displayValidation:r,updateValidation:n,resetValidation:o,commitValidation:a}}return function(e){let{isInvalid:t,validationState:r,name:n,value:o,builtinValidation:a,validate:i,validationBehavior:s="aria"}=e;r&&(t||(t="invalid"===r));let l=void 0!==t?{isInvalid:t,validationErrors:[],validationDetails:bI}:null,u=(0,cu.useMemo)(()=>i&&null!=o?bV(function(e,t){if("function"==typeof e){let r=e(t);if(r&&"boolean"!=typeof r)return bU(r)}return[]}(i,o)):null,[i,o]);(null==a?void 0:a.validationDetails.valid)&&(a=void 0);let c=(0,cu.useContext)(bL),d=(0,cu.useMemo)(()=>n?Array.isArray(n)?n.flatMap(e=>bU(c[e])):bU(c[n]):[],[c,n]),[f,p]=(0,cu.useState)(c),[m,h]=(0,cu.useState)(!1);c!==f&&(p(c),h(!1));let g=(0,cu.useMemo)(()=>bV(m?[]:d),[m,d]),y=(0,cu.useRef)(bM),[v,b]=(0,cu.useState)(bM),w=(0,cu.useRef)(bM),[E,x]=(0,cu.useState)(!1);return(0,cu.useEffect)(()=>{if(!E)return;x(!1);let e=u||a||y.current;bW(e,w.current)||(w.current=e,b(e))}),{realtimeValidation:l||g||u||a||bM,displayValidation:"native"===s?l||g||v:l||g||u||a||v,updateValidation(e){"aria"!==s||bW(v,e)?y.current=e:b(e)},resetValidation(){bW(bM,w.current)||(w.current=bM,b(bM)),"native"===s&&x(!1),h(!0)},commitValidation(){"native"===s&&x(!0),h(!0)}}}(e)}function bU(e){return e?Array.isArray(e)?e:[e]:[]}function bV(e){return e.length?{isInvalid:!0,validationErrors:e,validationDetails:bI}:null}function bW(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 bH(...e){let t=new Set,r=!1,n={...b$};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 bz=new yk((en=bA)&&en.__esModule?en.default:en);function bK(){return"u">typeof navigator&&(navigator.language||navigator.userLanguage)||"en-US"}function bG(e,t,r,n,o){let a=null!=e&&null!=r&&e.compare(r)>0,i=null!=e&&null!=t&&0>e.compare(t),s=null!=e&&(null==n?void 0:n(e))||!1,l=a||i||s,u=[];if(l){let e=bK(),n=new yR(e,yk.getGlobalDictionaryForPackage("@react-stately/datepicker")||bz),l=new y$(e,bq({},o)),c=l.resolvedOptions().timeZone;i&&null!=t&&u.push(n.format("rangeUnderflow",{minValue:l.format(t.toDate(c))})),a&&null!=r&&u.push(n.format("rangeOverflow",{maxValue:l.format(r.toDate(c))})),s&&u.push(n.format("unavailableDate"))}return{isInvalid:l,validationErrors:u,validationDetails:{badInput:s,customError:!1,patternMismatch:!1,rangeOverflow:a,rangeUnderflow:i,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valueMissing:!1,valid:!l}}}let bZ={year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"2-digit",second:"2-digit"},bY={year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"};function bq(e,t){var r;e={...t.shouldForceLeadingZeros?bY:bZ,...e};let n=t.granularity||"minute",o=Object.keys(e),a=o.indexOf(null!=(r=t.maxGranularity)?r:"year");a<0&&(a=0);let i=o.indexOf(n);if(i<0&&(i=2),a>i)throw Error("maxGranularity must be greater than granularity");let s=o.slice(a,i+1).reduce((t,r)=>(t[r]=e[r],t),{});return null!=t.hourCycle&&(s.hour12=12===t.hourCycle),s.timeZone=t.timeZone||"UTC",("hour"===n||"minute"===n||"second"===n)&&t.timeZone&&!t.hideTimeZone&&(s.timeZoneName="short"),t.showEra&&0===a&&(s.era="short"),s}function bJ(e){return e&&"hour"in e?e:new g1}function bX(e,t){return null===e?null:e?yi(e,t):void 0}function bQ(e,t,r,n){if(e)return bX(e,r);let o=yi(yp(null!=n?n:yv()).set({hour:0,minute:0,second:0,millisecond:0}),r);return"year"===t||"month"===t||"day"===t?yo(o):n?o:ya(o)}function b0(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,a]=(0,cu.useState)([n,r]);return e&&(o[0]!==n||o[1]!==r)&&a([n,r]),t||(t=e?n:o[0]),[t,e?r:o[1]]}let b1=new yk({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"),b2={year:!0,month:!0,day:!0,hour:!0,minute:!0,second:!0,dayPeriod:!0,era:!0},b4={year:5,month:2,day:7,hour:2,minute:15,second:15},b3={dayperiod:"dayPeriod"};function b6(e){var t,r;let{locale:n,createCalendar:o,hideTimeZone:a,isDisabled:i=!1,isReadOnly:s=!1,isRequired:l=!1,minValue:u,maxValue:c,isDateUnavailable:d}=e,f=e.value||e.defaultValue||e.placeholderValue||null,[p,m]=b0(f,e.granularity),h=m||"UTC";if(f&&!(p in f))throw Error("Invalid granularity "+p+" for value "+f.toString());let g=(0,cu.useMemo)(()=>new y$(n),[n]),y=(0,cu.useMemo)(()=>o(g.resolvedOptions().calendar),[o,g]),[v,b]=vK(e.value,null!=(t=e.defaultValue)?t:null,e.onChange),w=(0,cu.useMemo)(()=>{var e;return null!=(e=bX(v,y))?e:null},[v,y]),[E,x]=(0,cu.useState)(()=>bQ(e.placeholderValue,p,y,m)),D="gregory"===y.identifier&&"BC"===(w||E).era,_=(0,cu.useMemo)(()=>{var t;return{granularity:p,maxGranularity:null!=(t=e.maxGranularity)?t:"year",timeZone:m,hideTimeZone:a,hourCycle:e.hourCycle,showEra:D,shouldForceLeadingZeros:e.shouldForceLeadingZeros}},[e.maxGranularity,p,e.hourCycle,e.shouldForceLeadingZeros,m,a,D]),S=(0,cu.useMemo)(()=>bq({},_),[_]),C=(0,cu.useMemo)(()=>new y$(n,S),[n,S]),k=(0,cu.useMemo)(()=>C.resolvedOptions(),[C]),P=(0,cu.useMemo)(()=>C.formatToParts(new Date).filter(e=>b2[e.type]).reduce((e,t)=>(e[t.type]=!0,e),{}),[C]),[O,R]=(0,cu.useState)(()=>e.value||e.defaultValue?{...P}:{}),T=(0,cu.useRef)(null),N=(0,cu.useRef)(y);(0,cu.useEffect)(()=>{yc(y,N.current)||(N.current=y,x(t=>Object.keys(O).length>0?yi(t,y):bQ(e.placeholderValue,p,y,m)))},[y,p,O,m,e.placeholderValue]),v&&Object.keys(O).length<Object.keys(P).length&&R(O={...P}),null==v&&Object.keys(O).length===Object.keys(P).length&&(R(O={}),x(bQ(e.placeholderValue,p,y,m)));let j=w&&Object.keys(O).length>=Object.keys(P).length?w:E,A=t=>{if(e.isDisabled||e.isReadOnly)return;let r=Object.keys(O),n=Object.keys(P);null==t?(b(null),x(bQ(e.placeholderValue,p,y,m)),R({})):r.length>=n.length||r.length===n.length-1&&P.dayPeriod&&!O.dayPeriod&&"dayPeriod"!==T.current?b(t=yi(t,(null==f?void 0:f.calendar)||new gT)):x(t),T.current=null},$=(0,cu.useMemo)(()=>j.toDate(h),[j,h]),I=(0,cu.useMemo)(()=>(function(e,t,r,n,o,a,i,s){let l=["hour","minute","second"],u=r.formatToParts(e),c=[];for(let e of u){var d,f;let r=b2[e.type];"era"===e.type&&1===a.getEras().length&&(r=!1);let u=b2[e.type]&&!t[e.type],p=b2[e.type]?(d=e.type,f=e.value,"era"===d||"dayPeriod"===d?f:"year"===d||"month"===d||"day"===d?b1.getStringForLocale(d,i):"––"):null,m={type:b3[e.type]||e.type,text:u?p:e.value,...b5(o,e.type,n),isPlaceholder:u,placeholder:p,isEditable:r};"hour"===e.type?(c.push({type:"literal",text:"",...b5(o,"literal",n),isPlaceholder:!1,placeholder:"",isEditable:!1}),c.push(m),e.type===s&&c.push({type:"literal",text:"",...b5(o,"literal",n),isPlaceholder:!1,placeholder:"",isEditable:!1})):l.includes(e.type)&&e.type===s?(c.push(m),c.push({type:"literal",text:"",...b5(o,"literal",n),isPlaceholder:!1,placeholder:"",isEditable:!1})):c.push(m)}return c})($,O,C,k,j,y,n,p),[$,O,C,k,j,y,n,p]);P.era&&O.year&&!O.era?(O.era=!0,R({...O})):!P.era&&O.era&&(delete O.era,R({...O}));let M=e=>{O[e]=!0,"year"===e&&P.era&&(O.era=!0),R({...O})},L=(e,t)=>{if(O[e])A(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)}(j,e,t,k));else{M(e);let t=Object.keys(O),r=Object.keys(P);(t.length>=r.length||t.length===r.length-1&&P.dayPeriod&&!O.dayPeriod)&&A(j)}},F=(0,cu.useMemo)(()=>bG(v,u,c,d,_),[v,u,c,d,_]),B=bB({...e,value:v,builtinValidation:F}),U=B.displayValidation.isInvalid,V=e.validationState||(U?"invalid":null);return{...B,value:w,dateValue:$,calendar:y,setValue:A,segments:I,dateFormatter:C,validationState:V,isInvalid:U,granularity:p,maxGranularity:null!=(r=e.maxGranularity)?r:"year",isDisabled:i,isReadOnly:s,isRequired:l,increment(e){L(e,1)},decrement(e){L(e,-1)},incrementPage(e){L(e,b4[e]||1)},decrementPage(e){L(e,-(b4[e]||1))},setSegment(e,t){M(e),A(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)}(j,e,t,k))},confirmPlaceholder(){if(e.isDisabled||e.isReadOnly)return;let t=Object.keys(O),r=Object.keys(P);t.length===r.length-1&&P.dayPeriod&&!O.dayPeriod&&(R(O={...P}),A(j.copy()))},clearSegment(t){delete O[t],T.current=t,R({...O});let r=bQ(e.placeholderValue,p,y,m),n=j;if("dayPeriod"===t&&"hour"in j&&"hour"in r){let e=j.hour>=12,t=r.hour>=12;e&&!t?n=j.set({hour:j.hour-12}):!e&&t&&(n=j.set({hour:j.hour+12}))}else"hour"===t&&"hour"in j&&j.hour>=12&&O.dayPeriod?n=j.set({hour:r.hour+12}):t in j&&(n=j.set({[t]:r[t]}));b(null),A(n)},formatValue:e=>w?new y$(n,bq(e,_)).format($):"",getDateFormatter:(e,t)=>new y$(e,bq({},{..._,...t}))}}function b5(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 b9=(0,cu.createContext)(null),b8=(0,cu.createContext)(null),b7=(0,cu.createContext)(null),we=(0,cu.forwardRef)(function(e,t){let r=(0,cu.useContext)(b8),n=(0,cu.useContext)(b7);return r||n?cc().createElement(wr,{...e,ref:t}):cc().createElement(wt,{...e,ref:t})}),wt=(0,cu.forwardRef)((e,t)=>{let[r,n]=mL({slot:e.slot},t,b9),{locale:o}=gD(),a=b6({...r,locale:o,createCalendar:vL}),i=(0,cu.useRef)(null),{fieldProps:s,inputProps:l}=bj({...r,inputRef:i},a,n);return cc().createElement(m$,{values:[[b8,a],[br,{...l,ref:i}],[be,{...s,ref:n,isInvalid:a.isInvalid,isDisabled:a.isDisabled}]]},cc().createElement(wr,e))}),wr=(0,cu.forwardRef)((e,t)=>{let{className:r,children:n}=e,o=(0,cu.useContext)(b8),a=(0,cu.useContext)(b7),i=null!=o?o:a;return cc().createElement(cc().Fragment,null,cc().createElement(bt,{...e,ref:t,slot:e.slot||void 0,className:null!=r?r:"react-aria-DateInput",isInvalid:i.isInvalid,isDisabled:i.isDisabled},i.segments.map((e,t)=>(0,cu.cloneElement)(n(e),{key:t}))),cc().createElement(bn,null))}),wn=(0,cu.createContext)({});function wo({children:e}){let t=(0,cu.useMemo)(()=>({register:()=>{}}),[]);return cc().createElement(hv.Provider,{value:t},e)}cc().forwardRef(({children:e,...t},r)=>{let n=(0,cu.useRef)(!1),o=(0,cu.useContext)(hv);r=mh(r||(null==o?void 0:o.ref));let a=mj(o||{},{...t,ref:r,register(){n.current=!0,o&&o.register()}});return hx(o,r),(0,cu.useEffect)(()=>{n.current||(n.current=!0)},[]),cc().createElement(hv.Provider,{value:a},e)});let wa=cc().createContext(null);function wi(e){var t;let r=mk(),{portalContainer:n=r?null:document.body,isExiting:o}=e,[a,i]=(0,cu.useState)(!1),s=(0,cu.useMemo)(()=>({contain:a,setContain:i}),[a,i]),{getContainer:l}=null!=(t=(0,cu.useContext)(wn))?t:{};if(!e.portalContainer&&l&&(n=l()),!n)return null;let u=e.children;return e.disableFocusManagement||(u=cc().createElement(bl,{restoreFocus:!0,contain:(e.shouldContainFocus||a)&&!o},u)),u=cc().createElement(wa.Provider,{value:s},cc().createElement(wo,null,u)),hO().createPortal(u,n)}let ws=(0,cu.createContext)(null),wl=(0,cu.createContext)(null),wu=(0,cu.forwardRef)(function(e,t){let r=e["aria-labelledby"];[e,t]=mL(e,t,ws);let{dialogProps:n,titleProps:o}=function(e,t){let r,n,{role:o="dialog"}=e,a=mT();a=e["aria-label"]?void 0:a;let i=(0,cu.useRef)(!1);return(0,cu.useEffect)(()=>{if(t.current&&!t.current.contains(document.activeElement)){h2(t.current);let e=setTimeout(()=>{document.activeElement===t.current&&(i.current=!0,t.current&&(t.current.blur(),h2(t.current)),i.current=!1)},500);return()=>{clearTimeout(e)}}},[t]),my(()=>{null==n||n(!0)},[n=null==(r=(0,cu.useContext)(wa))?void 0:r.setContain]),{dialogProps:{...mY(e,{labelable:!0}),role:o,tabIndex:-1,"aria-labelledby":e["aria-labelledby"]||a,onBlur:e=>{i.current&&e.stopPropagation()}},titleProps:{id:a}}}({...e,"aria-labelledby":r},t),a=(0,cu.useContext)(wl);n["aria-label"]||n["aria-labelledby"]||e["aria-labelledby"]&&(n["aria-labelledby"]=e["aria-labelledby"]);let i=mI({defaultClassName:"react-aria-Dialog",className:e.className,style:e.style,children:e.children,values:{close:(null==a?void 0:a.close)||(()=>{})}});return cc().createElement("section",{...mY(e),...n,...i,ref:t,slot:e.slot||void 0},cc().createElement(m$,{values:[[gu,{slots:{[mA]:{},title:{...o,level:2}}}],[gs,{slots:{[mA]:{},close:{onPress:()=>null==a?void 0:a.close()}}}]]},i.children))}),wc=(0,cu.createContext)(null),wd=(0,cu.forwardRef)(function(e,t){let r=(0,cu.useContext)(wc);return(null==r?void 0:r.isInvalid)?cc().createElement(wf,{...e,ref:t}):null}),wf=(0,cu.forwardRef)((e,t)=>{let r=(0,cu.useContext)(wc),n=mY(e),o=mI({...e,defaultClassName:"react-aria-FieldError",defaultChildren:0===r.validationErrors.length?void 0:r.validationErrors.join(" "),values:r});return null==o.children?null:cc().createElement(gd,{slot:"errorMessage",...n,...o,ref:t})}),wp=(0,cu.createContext)(null),wm=(0,cu.createContext)({}),wh=ga(function(e,t){[e,t]=mL(e,t,wm);let{elementType:r="label",...n}=e;return cc().createElement(r,{className:"react-aria-Label",...n,ref:t})}),wg=(0,cu.createContext)({placement:"bottom"}),wy=new WeakMap,wv=[];function wb(e,t=-1/0,r=1/0){return Math.min(Math.max(e,t),r)}function ww(e,t){let r=e,n=t.toString(),o=n.indexOf("."),a=o>=0?n.length-o:0;if(a>0){let e=Math.pow(10,a);r=Math.round(r*e)/e}return r}function wE(e,t,r,n){t=Number(t),r=Number(r);let o=(e-(isNaN(t)?0:t))%n,a=ww(2*Math.abs(o)>=n?e+Math.sign(o)*(n-Math.abs(o)):e-o,n);return isNaN(t)?!isNaN(r)&&a>r&&(a=Math.floor(ww(r/n,n))*n):a<t?a=t:!isNaN(r)&&a>r&&(a=t+Math.floor(ww((r-t)/n,n))*n),a=ww(a,n)}let wx={top:"top",bottom:"top",left:"left",right:"left"},wD={top:"bottom",bottom:"top",left:"right",right:"left"},w_={top:"left",left:"top"},wS={top:"height",left:"width"},wC={width:"totalWidth",height:"totalHeight"},wk={},wP="u">typeof document?window.visualViewport:null;function wO(e){var t,r,n,o,a;let i=0,s=0,l=0,u=0,c=0,d=0,f={},p=(null!=(t=null==wP?void 0:wP.scale)?t:1)>1;if("BODY"===e.tagName){let t=document.documentElement;l=t.clientWidth,u=t.clientHeight,i=null!=(r=null==wP?void 0:wP.width)?r:l,s=null!=(n=null==wP?void 0:wP.height)?n:u,f.top=t.scrollTop||e.scrollTop,f.left=t.scrollLeft||e.scrollLeft,wP&&(c=wP.offsetTop,d=wP.offsetLeft)}else({width:i,height:s,top:c,left:d}=wA(e)),f.top=e.scrollTop,f.left=e.scrollLeft,l=i,u=s;return hi()&&("BODY"===e.tagName||"HTML"===e.tagName)&&p&&(f.top=0,f.left=0,c=null!=(o=null==wP?void 0:wP.pageTop)?o:0,d=null!=(a=null==wP?void 0:wP.pageLeft)?a:0),{width:i,height:s,totalWidth:l,totalHeight:u,scroll:f,top:c,left:d}}function wR(e,t,r,n,o,a,i){var s;let l=null!=(s=o.scroll[e])?s:0,u=n[wS[e]],c=n.scroll[wx[e]]+a,d=u+n.scroll[wx[e]]-a,f=t-l+i[e]-n[wx[e]],p=t-l+r+i[e]-n[wx[e]];return f<c?c-f:p>d?Math.max(d-p,c-f):0}function wT(e){if(wk[e])return wk[e];let[t,r]=e.split(" "),n=wx[t]||"right",o=w_[n];wx[r]||(r="center");let a=wS[n],i=wS[o];return wk[e]={placement:t,crossPlacement:r,axis:n,crossAxis:o,size:a,crossSize:i},wk[e]}function wN(e,t,r,n,o,a,i,s,l,u){var c,d,f,p,m;let{placement:h,crossPlacement:g,axis:y,crossAxis:v,size:b,crossSize:w}=n,E={};E[v]=null!=(c=e[v])?c:0,"center"===g?E[v]+=((null!=(d=e[w])?d:0)-(null!=(f=r[w])?f:0))/2:g!==v&&(E[v]+=(null!=(p=e[w])?p:0)-(null!=(m=r[w])?m:0)),E[v]+=a;let x=e[v]-r[w]+l+u,D=e[v]+e[w]-l-u;if(E[v]=wb(E[v],x,D),h===y){let r=s?i[b]:t[wC[b]];E[wD[y]]=Math.floor(r-e[y]+o)}else E[y]=Math.floor(e[y]+e[b]+o);return E}function wj(e,t,r,n,o,a){var i,s,l;let{placement:u,axis:c,size:d}=a;return u===c?Math.max(0,r[c]-e[c]-(null!=(i=e.scroll[c])?i:0)+t[c]-(null!=(s=n[c])?s:0)-n[wD[c]]-o):Math.max(0,e[d]+e[c]+e.scroll[c]-t[c]-r[c]-r[d]-(null!=(l=n[c])?l:0)-n[wD[c]]-o)}function wA(e){let{top:t,left:r,width:n,height:o}=e.getBoundingClientRect(),{scrollTop:a,scrollLeft:i,clientTop:s,clientLeft:l}=document.documentElement;return{top:t+a-s,left:r+i-l,width:n,height:o}}function w$(e,t){let r,n=window.getComputedStyle(e);if("fixed"===n.position){let{top:t,left:n,width:o,height:a}=e.getBoundingClientRect();r={top:t,left:n,width:o,height:a}}else{r=wA(e);let n=wA(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 wI(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 wM=new WeakMap;function wL(e){let{ref:t,box:r,onResize:n}=e;(0,cu.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 wF="u">typeof document?window.visualViewport:null;function wB(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 wU=[],wV="u">typeof document&&window.visualViewport,wW=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]),wH=0;function wz(e,t,r){let n=e.style[t];return e.style[t]=r,()=>{e.style[t]=n}}function wK(e,t,r,n){return e.addEventListener(t,r,n),()=>{e.removeEventListener(t,r,n)}}function wG(e){let t=document.scrollingElement||document.documentElement,r=e;for(;r&&r!==t;){let e=y5(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 wZ={};function wY(e){var t;let{onDismiss:r,...n}=e,o=yY(n,yj((t=wZ)&&t.__esModule?t.default:t,"@react-aria/overlays").format("dismiss"));return cc().createElement(yX,null,cc().createElement("button",{...o,tabIndex:-1,onClick:()=>{r&&r()},style:{width:1,height:1}}))}function wq(e,t,r){my(()=>{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,hP.flushSync)(()=>{r()})}).catch(()=>{}),()=>{n=!0}}},[e,t,r])}function wJ(e){let[t,r]=vK(e.isOpen,e.defaultOpen||!1,e.onOpenChange),n=(0,cu.useCallback)(()=>{r(!0)},[r]),o=(0,cu.useCallback)(()=>{r(!1)},[r]),a=(0,cu.useCallback)(()=>{r(!t)},[r,t]);return{isOpen:t,setOpen:r,open:n,close:o,toggle:a}}wZ={"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 wX=(0,cu.createContext)(null),wQ=(0,cu.createContext)(null),w0=(0,cu.forwardRef)(function(e,t){[e,t]=mL(e,t,wX);let r=(0,cu.useContext)(wl),n=wJ(e),o=null==e.isOpen&&null==e.defaultOpen&&r?r:n,a=function(e,t){let[r,n]=(0,cu.useState)(t?"open":"closed");switch(r){case"open":t||n("exiting");break;case"closed":case"exiting":t&&n("open")}let o="exiting"===r;return wq(e,o,(0,cu.useCallback)(()=>{n(e=>"exiting"===e?"closed":e)},[])),o}(t,o.isOpen)||e.isExiting||!1,i=(0,cu.useContext)(go),{direction:s}=gD();if(i){let t=e.children;return"function"==typeof t&&(t=t({trigger:e.trigger||null,placement:"bottom",isEntering:!1,isExiting:!1,defaultChildren:null})),cc().createElement(cc().Fragment,null,t)}return!o||o.isOpen||a?cc().createElement(w1,{...e,triggerRef:e.triggerRef,state:o,popoverRef:t,isExiting:a,dir:s}):null});function w1({state:e,isExiting:t,UNSTABLE_portalContainer:r,...n}){var o,a;let i=(0,cu.useRef)(null),[s,l]=(0,cu.useState)(0),u=(0,cu.useRef)(null),d=(0,cu.useContext)(wQ),f=d&&"SubmenuTrigger"===n.trigger;my(()=>{i.current&&e.isOpen&&l(i.current.getBoundingClientRect().width)},[e.isOpen,i]);let{popoverProps:p,underlayProps:m,arrowProps:h,placement:g}=function(e,t){let{triggerRef:r,popoverRef:n,groupRef:o,isNonModal:a,isKeyboardDismissDisabled:i,shouldCloseOnInteractOutside:s,...l}=e,u="SubmenuTrigger"===l.trigger,{overlayProps:d,underlayProps:f}=function(e,t){let{onClose:r,shouldCloseOnBlur:n,isOpen:o,isDismissable:a=!1,isKeyboardDismissDisabled:i=!1,shouldCloseOnInteractOutside:s}=e;(0,cu.useEffect)(()=>{if(o&&!wU.includes(t))return wU.push(t),()=>{let e=wU.indexOf(t);e>=0&&wU.splice(e,1)}},[o,t]);let l=()=>{wU[wU.length-1]===t&&r&&r()};!function(e){let{ref:t,onInteractOutside:r,isDisabled:n,onInteractOutsideStart:o}=e,a=(0,cu.useRef)({isPointerDown:!1,ignoreEmulatedMouseEvents:!1}),i=mv(e=>{r&&wB(e,t)&&(o&&o(e),a.current.isPointerDown=!0)}),s=mv(e=>{r&&r(e)});(0,cu.useEffect)(()=>{let e=a.current;if(n)return;let r=m1(t.current);if("u">typeof PointerEvent){let n=r=>{e.isPointerDown&&wB(r,t)&&s(r),e.isPointerDown=!1};return r.addEventListener("pointerdown",i,!0),r.addEventListener("pointerup",n,!0),()=>{r.removeEventListener("pointerdown",i,!0),r.removeEventListener("pointerup",n,!0)}}},[t,n,i,s])}({ref:t,onInteractOutside:a&&o?e=>{(!s||s(e.target))&&(wU[wU.length-1]===t&&(e.stopPropagation(),e.preventDefault()),l())}:void 0,onInteractOutsideStart:e=>{(!s||s(e.target))&&wU[wU.length-1]===t&&(e.stopPropagation(),e.preventDefault())}});let{focusWithinProps:u}=h9({isDisabled:!n,onBlurWithin:e=>{!(!e.relatedTarget||bf(e.relatedTarget,bs))&&(!s||s(e.relatedTarget))&&(null==r||r())}});return{overlayProps:{onKeyDown:e=>{"Escape"!==e.key||i||e.nativeEvent.isComposing||(e.stopPropagation(),e.preventDefault(),l())},...u},underlayProps:{onPointerDown:e=>{e.target===e.currentTarget&&e.preventDefault()}}}}({isOpen:t.isOpen,onClose:t.close,shouldCloseOnBlur:!0,isDismissable:!a||u,isKeyboardDismissDisabled:i,shouldCloseOnInteractOutside:s},null!=o?o:n),{overlayProps:p,arrowProps:m,placement:h}=function(e){var t,r,n;let{direction:o}=gD(),{arrowSize:a=0,targetRef:i,overlayRef:s,scrollRef:l=s,placement:u="bottom",containerPadding:c=12,shouldFlip:d=!0,boundaryElement:f="u">typeof document?document.body:null,offset:p=0,crossOffset:m=0,shouldUpdatePosition:h=!0,isOpen:g=!0,onClose:y,maxHeight:v,arrowBoundaryOffset:b=0}=e,[w,E]=(0,cu.useState)(null),x=[h,u,s.current,i.current,l.current,c,d,f,p,m,g,o,v,b,a],D=(0,cu.useRef)(null==wF?void 0:wF.scale);(0,cu.useEffect)(()=>{g&&(D.current=null==wF?void 0:wF.scale)},[g]);let _=(0,cu.useCallback)(()=>{var e,t,r,n,y,w;if(!1===h||!g||!s.current||!i.current||!f||(null==wF?void 0:wF.scale)!==D.current)return;let x=null;if(l.current&&l.current.contains(document.activeElement)){let n=null==(e=document.activeElement)?void 0:e.getBoundingClientRect(),o=l.current.getBoundingClientRect();(x={type:"top",offset:(null!=(t=null==n?void 0:n.top)?t:0)-o.top}).offset>o.height/2&&(x.type="bottom",x.offset=(null!=(r=null==n?void 0:n.bottom)?r:0)-o.bottom)}let _=s.current;!v&&s.current&&(_.style.top="0px",_.style.bottom="",_.style.maxHeight=(null!=(y=null==(n=window.visualViewport)?void 0:n.height)?y:window.innerHeight)+"px");let S=function(e){var t,r,n,o;let a,{placement:i,targetNode:s,overlayNode:l,scrollNode:u,padding:c,shouldFlip:d,boundaryElement:f,offset:p,crossOffset:m,maxHeight:h,arrowSize:g=0,arrowBoundaryOffset:y=0}=e,v=l instanceof HTMLElement?function(e){let t=e.offsetParent;if(t&&t===document.body&&"static"===window.getComputedStyle(t).position&&!wI(t)&&(t=document.documentElement),null==t)for(t=e.parentElement;t&&!wI(t);)t=t.parentElement;return t||document.documentElement}(l):document.documentElement,b=v===document.documentElement,w=window.getComputedStyle(v).position,E=b?wA(s):w$(s,v);if(!b){let{marginTop:e,marginLeft:t}=window.getComputedStyle(s);E.top+=parseInt(e,10)||0,E.left+=parseInt(t,10)||0}let x=wA(l),D={top:parseInt((a=window.getComputedStyle(l)).marginTop,10)||0,bottom:parseInt(a.marginBottom,10)||0,left:parseInt(a.marginLeft,10)||0,right:parseInt(a.marginRight,10)||0};x.width+=(null!=(t=D.left)?t:0)+(null!=(r=D.right)?r:0),x.height+=(null!=(n=D.top)?n:0)+(null!=(o=D.bottom)?o:0);let _={top:u.scrollTop,left:u.scrollLeft,width:u.scrollWidth,height:u.scrollHeight},S=wO(f),C=wO(v),k="BODY"===f.tagName?wA(v):w$(v,f);return"HTML"===v.tagName&&"BODY"===f.tagName&&(C.scroll.top=0,C.scroll.left=0),function(e,t,r,n,o,a,i,s,l,u,c,d,f,p,m,h){var g,y,v,b,w,E,x,D,_,S,C,k,P,O;let R,T,N,j=wT(e),{size:A,crossAxis:$,crossSize:I,placement:M,crossPlacement:L}=j,F=wN(t,s,r,j,c,d,u,f,m,h),B=c,U=wj(s,u,t,o,a+c,j);if(i&&n[A]>U){let e=wT(`${wD[M]} ${L}`),n=wN(t,s,r,e,c,d,u,f,m,h);wj(s,u,t,o,a+c,e)>U&&(j=e,F=n,B=c)}let V="bottom";"top"===j.axis?"top"===j.placement?V="top":"bottom"===j.placement&&(V="bottom"):"top"===j.crossAxis&&("top"===j.crossPlacement?V="bottom":"bottom"===j.crossPlacement&&(V="top"));let W=wR($,F[$],r[I],s,l,a,u);F[$]+=W;let H=(w=F,E=r.height,x=V,R=f?u.height:s[wC.height],T=null!=w.top?u.top+w.top:u.top+(R-(null!=(D=w.bottom)?D:0)-E),N="top"!==x?Math.max(0,s.height+s.top+(null!=(_=s.scroll.top)?_:0)-T-((null!=(S=o.top)?S:0)+(null!=(C=o.bottom)?C:0)+a)):Math.max(0,T+E-(s.top+(null!=(k=s.scroll.top)?k:0))-((null!=(P=o.top)?P:0)+(null!=(O=o.bottom)?O:0)+a)),Math.min(s.height-2*a,N));p&&p<H&&(H=p),r.height=Math.min(r.height,H),W=wR($,(F=wN(t,s,r,j,B,d,u,f,m,h))[$],r[I],s,l,a,u),F[$]+=W;let z={},K=t[$]+.5*t[I]-F[$]-o[wx[$]],G=m/2+h,Z="left"===wx[$]?(null!=(g=o.left)?g:0)+(null!=(y=o.right)?y:0):(null!=(v=o.top)?v:0)+(null!=(b=o.bottom)?b:0),Y=r[I]-Z-m/2-h,q=wb(K,t[$]+m/2-(F[$]+o[wx[$]]),t[$]+t[I]-m/2-(F[$]+o[wx[$]]));return z[$]=wb(q,G,Y),{position:F,maxHeight:H,arrowOffsetLeft:z.left,arrowOffsetTop:z.top,placement:j.placement}}(i,E,x,_,D,c,d,S,C,k,p,m,!!w&&"static"!==w,h,g,y)}({placement:(w=u,"rtl"===o?w.replace("start","right").replace("end","left"):w.replace("start","left").replace("end","right")),overlayNode:s.current,targetNode:i.current,scrollNode:l.current||s.current,padding:c,shouldFlip:d,boundaryElement:f,offset:p,crossOffset:m,maxHeight:v,arrowSize:a,arrowBoundaryOffset:b});if(S.position){if(_.style.top="",_.style.bottom="",_.style.left="",_.style.right="",Object.keys(S.position).forEach(e=>_.style[e]=S.position[e]+"px"),_.style.maxHeight=null!=S.maxHeight?S.maxHeight+"px":"",x&&document.activeElement&&l.current){let e=document.activeElement.getBoundingClientRect(),t=l.current.getBoundingClientRect(),r=e[x.type]-t[x.type];l.current.scrollTop+=r-x.offset}E(S)}},x);my(_,x),my(()=>(window.addEventListener("resize",n,!1),()=>{window.removeEventListener("resize",n,!1)}),[n=_]),wL({ref:s,onResize:_}),wL({ref:i,onResize:_});let S=(0,cu.useRef)(!1);my(()=>{let e,t=()=>{S.current=!0,clearTimeout(e),e=setTimeout(()=>{S.current=!1},500),_()},r=()=>{S.current&&t()};return null==wF||wF.addEventListener("resize",t),null==wF||wF.addEventListener("scroll",r),()=>{null==wF||wF.removeEventListener("resize",t),null==wF||wF.removeEventListener("scroll",r)}},[_]);let C=(0,cu.useCallback)(()=>{S.current||null==y||y()},[y,S]);return!function(e){let{triggerRef:t,isOpen:r,onClose:n}=e;(0,cu.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||wM.get(t.current);o&&o()};return window.addEventListener("scroll",e,!0),()=>{window.removeEventListener("scroll",e,!0)}},[r,n,t])}({triggerRef:i,isOpen:g,onClose:y&&C}),{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:_}}({...l,targetRef:r,overlayRef:n,isOpen:t.isOpen,onClose:a&&!u?t.close:null});return!function(e={}){let{isDisabled:t}=e;my(()=>{if(!t){let e,t,r,n;return 1==++wH&&(c=ha()?(r=null,n=mg(wK(document,"touchstart",r=>{((e=y5(r.target,!0))!==document.documentElement||e!==document.body)&&e instanceof HTMLElement&&"auto"===window.getComputedStyle(e).overscrollBehavior&&(t=wz(e,"overscrollBehavior","contain"))},{passive:!1,capture:!0}),wK(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}),wK(document,"touchend",()=>{t&&t()},{passive:!1,capture:!0}),wK(document,"focus",e=>{var t;let n=e.target;((t=n)instanceof HTMLInputElement&&!wW.has(t.type)||t instanceof HTMLTextAreaElement||t instanceof HTMLElement&&t.isContentEditable)&&((()=>{if(r)return;let e=window.pageXOffset,t=window.pageYOffset;r=mg(wK(window,"scroll",()=>{window.scrollTo(0,0)}),wz(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),wz(document.documentElement,"overflow","hidden"),wz(document.body,"marginTop",`-${t}px`),()=>{window.scrollTo(e,t)}),window.scrollTo(0,0)})(),n.style.transform="translateY(-2000px)",requestAnimationFrame(()=>{n.style.transform="",wV&&(wV.height<window.innerHeight?requestAnimationFrame(()=>{wG(n)}):wV.addEventListener("resize",()=>wG(n),{once:!0}))}))},!0)),()=>{null==t||t(),null==r||r(),n()}):mg(wz(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),wz(document.documentElement,"overflow","hidden"))),()=>{0==--wH&&c()}}},[t])}({isDisabled:a||!t.isOpen}),my(()=>{if(t.isOpen&&n.current){if(!a)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}),i=t(e);if(i===NodeFilter.FILTER_ACCEPT&&a(e),i!==NodeFilter.FILTER_REJECT){let e=o.nextNode();for(;null!=e;)a(e),e=o.nextNode()}},a=e=>{var t;let r=null!=(t=wy.get(e))?t:0;("true"!==e.getAttribute("aria-hidden")||0!==r)&&(0===r&&e.setAttribute("aria-hidden","true"),n.add(e),wy.set(e,r+1))};wv.length&&wv[wv.length-1].disconnect(),o(t);let i=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)}});i.observe(t,{childList:!0,subtree:!0});let s={visibleNodes:r,hiddenNodes:n,observe(){i.observe(t,{childList:!0,subtree:!0})},disconnect(){i.disconnect()}};return wv.push(s),()=>{for(let e of(i.disconnect(),n)){let t=wy.get(e);null!=t&&(1===t?(e.removeAttribute("aria-hidden"),wy.delete(e)):wy.set(e,t-1))}s===wv[wv.length-1]?(wv.pop(),wv.length&&wv[wv.length-1].observe()):wv.splice(wv.indexOf(s),1)}}([null!=(r=null==o?void 0:o.current)?r:n.current]);var e,r,i=null!=(e=null==o?void 0:o.current)?e:n.current;let t=wv[wv.length-1];return t&&!t.visibleNodes.has(i)?(t.visibleNodes.add(i),()=>{t.visibleNodes.delete(i)}):void 0}},[a,t.isOpen,n,o]),{popoverProps:mj(d,p),arrowProps:m,underlayProps:f,placement:h}}({...n,offset:null!=(o=n.offset)?o:8,arrowSize:s,groupRef:f?d:u},e),y=n.popoverRef,v=function(e,t=!0){let[r,n]=(0,cu.useState)(!0),o=r&&t;return my(()=>{if(o&&e.current&&"getAnimations"in e.current)for(let t of e.current.getAnimations())t instanceof CSSTransition&&t.cancel()},[e,o]),wq(e,o,(0,cu.useCallback)(()=>n(!1),[])),o}(y,!!g)||n.isEntering||!1,b=mI({...n,defaultClassName:"react-aria-Popover",values:{trigger:n.trigger||null,placement:g,isEntering:v,isExiting:t}}),w=!n.isNonModal||"SubmenuTrigger"===n.trigger,[E,x]=(0,cu.useState)(!1);my(()=>{y.current&&x(w&&!y.current.querySelector("[role=dialog]"))},[y,w]),(0,cu.useEffect)(()=>{E&&y.current&&!y.current.contains(document.activeElement)&&h2(y.current)},[E,y]);let D={...p.style,...b.style},_=cc().createElement("div",{...mj(mY(n),p),...b,role:E?"dialog":void 0,tabIndex:E?-1:void 0,"aria-label":n["aria-label"],"aria-labelledby":n["aria-labelledby"],ref:y,slot:n.slot||void 0,style:D,dir:n.dir,"data-trigger":n.trigger,"data-placement":g,"data-entering":v||void 0,"data-exiting":t||void 0},!n.isNonModal&&cc().createElement(wY,{onDismiss:e.close}),cc().createElement(wg.Provider,{value:{...h,placement:g,ref:i}},b.children),cc().createElement(wY,{onDismiss:e.close}));return f?cc().createElement(wi,{...n,shouldContainFocus:E,isExiting:t,portalContainer:null!=(a=null!=r?r:null==d?void 0:d.current)?a:void 0},_):cc().createElement(wi,{...n,shouldContainFocus:E,isExiting:t,portalContainer:r},!n.isNonModal&&e.isOpen&&cc().createElement("div",{"data-testid":"underlay",...m,style:{position:"fixed",inset:0}}),cc().createElement("div",{ref:u,style:{display:"contents"}},cc().createElement(wQ.Provider,{value:u},_)))}function w2(e){return(null==e?void 0:e.start)!=null&&null!=e.end}let w4=(0,cu.createContext)(null),w3=(0,cu.createContext)(null),w6=(0,cu.createContext)(null),w5=(0,cu.createContext)(null),w9=(0,cu.forwardRef)(function(e,t){var r,n;[e,t]=mL(e,t,w4);let{validationBehavior:o}=mM(wp)||{},a=null!=(n=null!=(r=e.validationBehavior)?r:o)?n:"native",i=function(e){var t;let r=wJ(e),[n,o]=vK(e.value,e.defaultValue||null,e.onChange),a=n||e.placeholderValue||null,[i,s]=b0(a,e.granularity),l=null!=n?n.toDate(null!=s?s:"UTC"):null,u="hour"===i||"minute"===i||"second"===i,c=null==(t=e.shouldCloseOnSelect)||t,[d,f]=(0,cu.useState)(null),[p,m]=(0,cu.useState)(null);if(n&&(d=n,"hour"in n&&(p=n)),a&&!(i in a))throw Error("Invalid granularity "+i+" for value "+a.toString());let h=(null==n?void 0:n.calendar.identifier)==="gregory"&&"BC"===n.era,g=(0,cu.useMemo)(()=>({granularity:i,timeZone:s,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,shouldForceLeadingZeros:e.shouldForceLeadingZeros,showEra:h}),[i,e.hourCycle,e.shouldForceLeadingZeros,s,e.hideTimeZone,h]),{minValue:y,maxValue:v,isDateUnavailable:b}=e,w=(0,cu.useMemo)(()=>bG(n,y,v,b,g),[n,y,v,b,g]),E=bB({...e,value:n,builtinValidation:w}),x=E.displayValidation.isInvalid,D=e.validationState||(x?"invalid":null),_=(e,t)=>{o("timeZone"in t?t.set(yo(e)):ya(e,t)),f(null),m(null),E.commitValidation()};return{...E,value:n,setValue:o,dateValue:d,timeValue:p,setDateValue:t=>{let n="function"==typeof c?c():c;u?p||n?_(t,p||bJ(e.defaultValue||e.placeholderValue)):f(t):(o(t),E.commitValidation()),n&&r.setOpen(!1)},setTimeValue:e=>{d&&e?_(d,e):m(e)},granularity:i,hasTime:u,...r,setOpen(t){!t&&!n&&d&&u&&_(d,p||bJ(e.defaultValue||e.placeholderValue)),r.setOpen(t)},validationState:D,isInvalid:x,formatValue:(e,t)=>l?new y$(e,bq(t,g)).format(l):"",getDateFormatter:(e,t)=>new y$(e,bq({},{...g,...t}))}}({...e,validationBehavior:a}),s=(0,cu.useRef)(null),[l,u]=mF(!e["aria-label"]&&!e["aria-labelledby"]),{groupProps:c,labelProps:d,fieldProps:f,buttonProps:p,dialogProps:m,calendarProps:h,descriptionProps:g,errorMessageProps:y,...v}=function(e,t,r){var n;let o=mR(),a=mR(),i=mR(),s=yj((n=bo)&&n.__esModule?n.default:n,"@react-aria/datepicker"),{isInvalid:l,validationErrors:u,validationDetails:c}=t.displayValidation,{labelProps:d,fieldProps:f,descriptionProps:p,errorMessageProps:m}=bP({...e,labelElementType:"span",isInvalid:l,errorMessage:e.errorMessage||u}),h=bS(t,r),g=f["aria-labelledby"]||f.id,{locale:y}=gD(),v=t.formatValue(y,{month:"long"}),b=y2(v?s.format("selectedDateDescription",{date:v}):""),w=[b["aria-describedby"],f["aria-describedby"]].filter(Boolean).join(" ")||void 0,E=mY(e),x=(0,cu.useMemo)(()=>bw(r),[r]),D=(0,cu.useRef)(!1),{focusWithinProps:_}=h9({...e,isDisabled:t.isOpen,onBlurWithin:t=>{let r=document.getElementById(a);if(!(null==r?void 0:r.contains(t.relatedTarget))){var n,o;D.current=!1,null==(n=e.onBlur)||n.call(e,t),null==(o=e.onFocusChange)||o.call(e,!1)}},onFocusWithin:t=>{if(!D.current){var r,n;D.current=!0,null==(r=e.onFocus)||r.call(e,t),null==(n=e.onFocusChange)||n.call(e,!0)}}});return{groupProps:mj(E,h,f,b,_,{role:"group","aria-disabled":e.isDisabled||null,"aria-labelledby":g,"aria-describedby":w,onKeyDown(r){!t.isOpen&&e.onKeyDown&&e.onKeyDown(r)},onKeyUp(r){!t.isOpen&&e.onKeyUp&&e.onKeyUp(r)}}),labelProps:{...d,onClick:()=>{x.focusFirst()}},fieldProps:{...f,id:i,[bT]:"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,[bF]:t,autoFocus:e.autoFocus,name:e.name},descriptionProps:p,errorMessageProps:m,buttonProps:{...b,id:o,"aria-haspopup":"dialog","aria-label":s.format("calendar"),"aria-labelledby":`${o} ${g}`,"aria-describedby":w,"aria-expanded":t.isOpen,isDisabled:e.isDisabled||e.isReadOnly,onPress:()=>t.setOpen(!0)},dialogProps:{id:a,"aria-labelledby":`${o} ${g}`},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:l,validationErrors:u,validationDetails:c}}({...mB(e),label:u,validationBehavior:a},i,s),[b,w]=(0,cu.useState)(null),E=(0,cu.useCallback)(()=>{s.current&&w(s.current.offsetWidth+"px")},[]);wL({ref:s,onResize:E});let{focusProps:x,isFocused:D,isFocusVisible:_}=h8({within:!0}),S=mI({...e,values:{state:i,isFocusWithin:D,isFocusVisible:_,isDisabled:e.isDisabled||!1,isInvalid:i.isInvalid,isOpen:i.isOpen},defaultClassName:"react-aria-DatePicker"}),C=mY(e);return delete C.id,cc().createElement(m$,{values:[[w6,i],[be,{...c,ref:s,isInvalid:i.isInvalid}],[b9,f],[gs,{...p,isPressed:i.isOpen}],[wm,{...d,ref:l,elementType:"span"}],[vX,h],[wl,i],[wX,{trigger:"DatePicker",triggerRef:s,placement:"bottom start",style:{"--trigger-width":b}}],[ws,m],[gc,{slots:{description:g,errorMessage:y}}],[wc,v]]},cc().createElement("div",{...x,...C,...S,ref:t,slot:e.slot||void 0,"data-focus-within":D||void 0,"data-invalid":i.isInvalid||void 0,"data-focus-visible":_||void 0,"data-disabled":e.isDisabled||void 0,"data-open":i.isOpen||void 0}))}),w8=(0,cu.forwardRef)(function(e,t){var r,n;[e,t]=mL(e,t,w3);let{validationBehavior:o}=mM(wp)||{},a=null!=(n=null!=(r=e.validationBehavior)?r:o)?n:"native",i=function(e){var t,r,n;let o=wJ(e),[a,i]=vK(e.value,e.defaultValue||null,e.onChange),[s,l]=(0,cu.useState)(()=>a||{start:null,end:null});null==a&&s.start&&s.end&&l(s={start:null,end:null});let u=a||s,c=e=>{l(e||{start:null,end:null}),w2(e)?i(e):i(null)},[d,f]=b0((null==u?void 0:u.start)||(null==u?void 0:u.end)||e.placeholderValue||null,e.granularity),p="hour"===d||"minute"===d||"second"===d,m=null==(n=e.shouldCloseOnSelect)||n,[h,g]=(0,cu.useState)(null),[y,v]=(0,cu.useState)(null);u&&w2(u)&&(h=u,"hour"in u.start&&(y=u));let b=(e,t)=>{c({start:"timeZone"in t.start?t.start.set(yo(e.start)):ya(e.start,t.start),end:"timeZone"in t.end?t.end.set(yo(e.end)):ya(e.end,t.end)}),g(null),v(null),P.commitValidation()},w=t=>{let r="function"==typeof m?m():m;p?w2(t)&&(null==y?void 0:y.start)&&(null==y?void 0:y.end)?b(t,{start:(null==y?void 0:y.start)||bJ(e.placeholderValue),end:(null==y?void 0:y.end)||bJ(e.placeholderValue)}):g(t):w2(t)?(c(t),P.commitValidation()):g(t),r&&o.setOpen(!1)},E=e=>{w2(h)&&w2(e)?b(h,e):v(e)},x=(null==u||null==(t=u.start)?void 0:t.calendar.identifier)==="gregory"&&"BC"===u.start.era||(null==u||null==(r=u.end)?void 0:r.calendar.identifier)==="gregory"&&"BC"===u.end.era,D=(0,cu.useMemo)(()=>({granularity:d,timeZone:f,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,shouldForceLeadingZeros:e.shouldForceLeadingZeros,showEra:x}),[d,e.hourCycle,e.shouldForceLeadingZeros,f,e.hideTimeZone,x]),{minValue:_,maxValue:S,isDateUnavailable:C}=e,k=(0,cu.useMemo)(()=>{var e,t;let r;return r=bH(bG(null!=(e=null==u?void 0:u.start)?e:null,_,S,C,D),bG(null!=(t=null==u?void 0:u.end)?t:null,_,S,C,D)),(null==u?void 0:u.end)!=null&&null!=u.start&&0>u.end.compare(u.start)&&(r=bH(r,{isInvalid:!0,validationErrors:[(yk.getGlobalDictionaryForPackage("@react-stately/datepicker")||bz).getStringForLocale("rangeReversed",bK())],validationDetails:{...b$,rangeUnderflow:!0,rangeOverflow:!0,valid:!1}})),r},[u,_,S,C,D]),P=bB({...e,value:a,name:(0,cu.useMemo)(()=>[e.startName,e.endName].filter(e=>null!=e),[e.startName,e.endName]),builtinValidation:k}),O=P.displayValidation.isInvalid,R=e.validationState||(O?"invalid":null);return{...P,value:u,setValue:c,dateRange:h,timeRange:y,granularity:d,hasTime:p,setDate(e,t){var r,n;"start"===e?w({start:t,end:null!=(r=null==h?void 0:h.end)?r:null}):w({start:null!=(n=null==h?void 0:h.start)?n:null,end:t})},setTime(e,t){var r,n;"start"===e?E({start:t,end:null!=(r=null==y?void 0:y.end)?r:null}):E({start:null!=(n=null==y?void 0:y.start)?n:null,end:t})},setDateTime(e,t){var r,n;"start"===e?c({start:t,end:null!=(r=null==u?void 0:u.end)?r:null}):c({start:null!=(n=null==u?void 0:u.start)?n:null,end:t})},setDateRange:w,setTimeRange:E,...o,setOpen(t){!t&&!((null==u?void 0:u.start)&&(null==u?void 0:u.end))&&w2(h)&&p&&b(h,{start:(null==y?void 0:y.start)||bJ(e.placeholderValue),end:(null==y?void 0:y.end)||bJ(e.placeholderValue)}),o.setOpen(t)},validationState:R,isInvalid:O,formatValue(t,r){let n;if(!u||!u.start||!u.end)return null;let o="timeZone"in u.start?u.start.timeZone:void 0,a=e.granularity||(u.start&&"minute"in u.start?"minute":"day"),i="timeZone"in u.end?u.end.timeZone:void 0,s=e.granularity||(u.end&&"minute"in u.end?"minute":"day"),l=bq(r,{granularity:a,timeZone:o,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle,showEra:"gregory"===u.start.calendar.identifier&&"BC"===u.start.era||"gregory"===u.end.calendar.identifier&&"BC"===u.end.era}),c=u.start.toDate(o||"UTC"),d=u.end.toDate(i||"UTC"),f=new y$(t,l);if(o===i&&a===s&&0!==u.start.compare(u.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 y$(t,bq(r,{granularity:s,timeZone:i,hideTimeZone:e.hideTimeZone,hourCycle:e.hourCycle}));return{start:f.format(c),end:n.format(d)}},getDateFormatter:(e,t)=>new y$(e,bq({},{...D,...t}))}}({...e,validationBehavior:a}),s=(0,cu.useRef)(null),[l,u]=mF(!e["aria-label"]&&!e["aria-labelledby"]),{groupProps:c,labelProps:d,startFieldProps:f,endFieldProps:p,buttonProps:m,dialogProps:h,calendarProps:g,descriptionProps:y,errorMessageProps:v,...b}=function(e,t,r){var n,o,a,i,s,l;let u=yj((l=bo)&&l.__esModule?l.default:l,"@react-aria/datepicker"),{isInvalid:c,validationErrors:d,validationDetails:f}=t.displayValidation,{labelProps:p,fieldProps:m,descriptionProps:h,errorMessageProps:g}=bP({...e,labelElementType:"span",isInvalid:c,errorMessage:e.errorMessage||d}),y=m["aria-labelledby"]||m.id,{locale:v}=gD(),b=t.formatValue(v,{month:"long"}),w=y2(b?u.format("selectedRangeDescription",{startDate:b.start,endDate:b.end}):""),E={"aria-label":u.format("startDate"),"aria-labelledby":y},x={"aria-label":u.format("endDate"),"aria-labelledby":y},D=mR(),_=mR(),S=bS(t,r),C=[w["aria-describedby"],m["aria-describedby"]].filter(Boolean).join(" ")||void 0,k=(0,cu.useMemo)(()=>bw(r,{accept:e=>e.id!==D}),[r,D]),P={[bN]:k,[bT]:"presentation","aria-describedby":C,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},O=mY(e),R=(0,cu.useRef)(!1),{focusWithinProps:T}=h9({...e,isDisabled:t.isOpen,onBlurWithin:t=>{let r=document.getElementById(_);if(!(null==r?void 0:r.contains(t.relatedTarget))){var n,o;R.current=!1,null==(n=e.onBlur)||n.call(e,t),null==(o=e.onFocusChange)||o.call(e,!1)}},onFocusWithin:t=>{if(!R.current){var r,n;R.current=!0,null==(r=e.onFocus)||r.call(e,t),null==(n=e.onFocusChange)||n.call(e,!0)}}}),N=(0,cu.useRef)(bM),j=(0,cu.useRef)(bM);return{groupProps:mj(O,S,m,w,T,{role:"group","aria-disabled":e.isDisabled||null,"aria-describedby":C,onKeyDown(r){!t.isOpen&&e.onKeyDown&&e.onKeyDown(r)},onKeyUp(r){!t.isOpen&&e.onKeyUp&&e.onKeyUp(r)}}),labelProps:{...p,onClick:()=>{k.focusFirst()}},buttonProps:{...w,id:D,"aria-haspopup":"dialog","aria-label":u.format("calendar"),"aria-labelledby":`${D} ${y}`,"aria-describedby":C,"aria-expanded":t.isOpen,isDisabled:e.isDisabled||e.isReadOnly,onPress:()=>t.setOpen(!0)},dialogProps:{id:_,"aria-labelledby":`${D} ${y}`},startFieldProps:{...E,...P,value:null!=(i=null==(n=t.value)?void 0:n.start)?i:null,onChange:e=>t.setDateTime("start",e),autoFocus:e.autoFocus,name:e.startName,[bF]:{realtimeValidation:t.realtimeValidation,displayValidation:t.displayValidation,updateValidation(e){N.current=e,t.updateValidation(bH(e,j.current))},resetValidation:t.resetValidation,commitValidation:t.commitValidation}},endFieldProps:{...x,...P,value:null!=(s=null==(o=t.value)?void 0:o.end)?s:null,onChange:e=>t.setDateTime("end",e),name:e.endName,[bF]:{realtimeValidation:t.realtimeValidation,displayValidation:t.displayValidation,updateValidation(e){j.current=e,t.updateValidation(bH(N.current,e))},resetValidation:t.resetValidation,commitValidation:t.commitValidation}},descriptionProps:h,errorMessageProps:g,calendarProps:{autoFocus:!0,value:(null==(a=t.dateRange)?void 0:a.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}}({...mB(e),label:u,validationBehavior:a},i,s),[w,E]=(0,cu.useState)(null),x=(0,cu.useCallback)(()=>{s.current&&E(s.current.offsetWidth+"px")},[]);wL({ref:s,onResize:x});let{focusProps:D,isFocused:_,isFocusVisible:S}=h8({within:!0}),C=mI({...e,values:{state:i,isFocusWithin:_,isFocusVisible:S,isDisabled:e.isDisabled||!1,isInvalid:i.isInvalid,isOpen:i.isOpen},defaultClassName:"react-aria-DateRangePicker"}),k=mY(e);return delete k.id,cc().createElement(m$,{values:[[w5,i],[be,{...c,ref:s,isInvalid:i.isInvalid}],[gs,{...m,isPressed:i.isOpen}],[wm,{...d,ref:l,elementType:"span"}],[vQ,g],[wl,i],[wX,{trigger:"DateRangePicker",triggerRef:s,placement:"bottom start",style:{"--trigger-width":w}}],[ws,h],[b9,{slots:{start:f,end:p}}],[gc,{slots:{description:y,errorMessage:v}}],[wc,b]]},cc().createElement("div",{...D,...k,...C,ref:t,slot:e.slot||void 0,"data-focus-within":_||void 0,"data-invalid":i.isInvalid||void 0,"data-focus-visible":S||void 0,"data-disabled":e.isDisabled||void 0,"data-open":i.isOpen||void 0}))});function w7(e){return cc().createElement(gx,e)}function Ee(e,t,r=!1){if(null==e)return r?e:void 0;if("string"==typeof e&&!e)return r?null:void 0;if(e instanceof gQ||e instanceof g4||e instanceof g6)return t?yi(e,t):e;{let r=d0()(e).toDate(),n=new gQ(r.getFullYear(),r.getMonth()+1,r.getDate());return t?yi(n,t):n}}function Et(e){if(e)return e.toDate(yv())}function Er(e){if("string"==typeof e&&0!==e.trim().length)try{return new Intl.Locale(e.replace(/[_@]/g,"-")).toString()}catch{return}}function En(e){let t=e??"",r=Er(t);if(!r)return t;try{return new Intl.DisplayNames([r],{type:"language"}).of(r)??t}catch{return t}}function Eo(){let e=window.i18next.language,t=Er(e)??e;return"ht"===t&&(t="fr-HT"),t}if("u">typeof navigator){let e=navigator;ea=Array.isArray(e.languages)?e.languages[0]:e.language}else if("u">typeof process){let e=process.env;ea=e.LC_ALL||e.LC_MESSAGES||e.LANG||e.LANGUAGE}var Ea=function(e){e=(e=e.replace(/_/g,"-")).replace(/[.:][\w-]*$/,"");try{return new Intl.Locale(e).baseName}catch(e){return"en-US"}}(ea||"en-US"),Ei=class extends Date{invalid=null;isValid(){return!Number.isNaN(this.valueOf())}},Es={};for(let e=1;e<100;e++)Es[(e<=9?"0":"")+e]=e+(e>51?1900:2e3);var El={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},Eu="[1234567890一二三四五六七八九〇\\d]",Ec={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},Ed={},Ef={"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},Ep={zone:Ef,year:Es,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:{}},Em={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(Ef).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,}"},Eh={...Em,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}"},Eg={},Ey=class e{locale;lookups;vars;numberingSystem;baseName;dateOptions;static factory(t=Ea){return Eg[t.toLowerCase()]||(Eg[t.toLowerCase()]=new e(t)),Eg[t.toLowerCase()]}constructor(e=Ea){this.locale=e,this.lookups={...Ep},this.vars={...Em};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=Ec: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(Ed[e])return Ed[e];if("fullwide"===e||"hanidec"===e)return{group:Eu,lookup:{...Ec}};let t=El[e];if(!t)return{group:"\\d",lookup:{...Ec}};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 Ed[e]={group:`[${r}-${n}]`,lookup:o},Ed[e]}(this.numberingSystem);for(let r in this.lookups.digit=t,Eh)Eh.hasOwnProperty(r)&&(this.vars[r]=Eh[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,a)=>{e[r+o+(a<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 a=Intl.DateTimeFormat(this.locale,{dateStyle:o});for(let i=0;i<12;i++){let s=a.formatToParts(r[i]).find(n).value.toLocaleLowerCase(this.locale);/^\d+$/.test(s)||(/^ko/i.test(this.locale)&&(s+="월"),"medium"===o?(s=s.replace(/\.$/,""),e[`${s}\\.?`]=!0):e[s]=!0,t[s]=i+1)}}let o=Intl.DateTimeFormat(this.locale,{month:"short"});for(let a=0;a<12;a++){let i=o.formatToParts(r[a]).find(n).value.toLocaleLowerCase(this.locale);i=i.replace(/\.$/,""),e[`${i}\\.?`]=!0,t[i]=a+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 a=Intl.DateTimeFormat(this.locale,{weekday:o});for(let i=0;i<7;i++){let s=a.formatToParts(e[i]).find(t).value.toLocaleLowerCase(this.locale);"short"===o?(s=s.replace(/\.$/,""),r.push(`${s}\\.?`)):r.push(s),n[s]=i}}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 a=0;a<2;a++){let i=o.formatToParts(e[a]).find(t);if(!i)return;let s=i.value.toLocaleLowerCase(this.locale);r.push(s),n[s]=12*a}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")}},Ev=["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"],Eb={y:"year",M:"month",d:"day",w:"week",h:"hour",m:"minute",s:"second",ms:"millisecond"},Ew=()=>new Date;function EE(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 Ex=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 a=e.handler(o);if(a){for(let[e,t]of Object.entries(a))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)}},ED=["year","month","day","hour","minute","second","millisecond","offset"],E_={};function ES(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 EC=[[/([^\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"]],Ek={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," "],...EC],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:EC,id:EC,fr:[[/(\d{2}) h /,"$1:"],[/(\d{2}) min /,"$1:"],[/(\d{2}) s /,"$1"]]};function EP(e,t=Ea){let r=function(e){if(!E_[e]){var t,r;let n,o,a=Ey.factory(e);E_[e]=new Ex({doneChecker:ES,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:a.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? ?(_OFFSET_|Z)?$"),handler:EE(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"timestampWithZone",regex:a.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))?\\s*(_ZONE_)$"),handler:EE(["","year","month","day","hour","minute","second","millisecond","zone"])},{name:"timestampWithOffsetAndZone",regex:a.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? (_OFFSET_|Z)\\s*(_ZONE_)$"),handler:EE(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"chinese",regex:a.compile(`^(${Eu}{2,4})\\s*\u5E74\\s*(${Eu}{1,2})\\s*\u6708\\s*(${Eu}{1,2})\\s*\u65E5$`),handler:EE(["","year","month","day"])},{name:"korean",regex:a.compile("^(_YEAR_)년\\s*(_MONTH_)월\\s*(_DAY_)일$"),handler:EE(["","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:EE(["","monthname","day","hour","minute","second","offset","year"])},{name:"today",regex:/^(now|today|tomorrow|yesterday)$/i,handler:function(e){let t=Ew(),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?Eb[r]:(r=r.replace(/s$/,"")).toLowerCase())&&(r="day",t*=7),("-"===e||n)&&(t*=-1);let o=Ew();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:a.compile("(?:^|[\\sT])(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?(Z)?$"),handler:EE(["","hour","minute","second","millisecond","zone"])},{name:"zone24",regex:a.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?[\\s\\[(]*(_ZONE_)?[\\s\\])]*$"),handler:EE(["","hour","minute","second","millisecond","zone"])},{name:"hms12WithOffset",regex:a.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)\\s*(_OFFSET_)"),handler:EE(["","hour","minute","second","meridiem","offset"])},{name:"hms12",regex:a.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)"),handler:EE(["","hour","minute","second","meridiem"])},{name:"hms24",regex:a.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?"),handler:EE(["","hour","minute","second","millisecond"])},{name:"hm12",regex:a.compile("(_H12_):(_MIN_)\\s*(_MERIDIEM_)"),handler:EE(["","hour","minute","meridiem"])},{name:"hm24",regex:a.compile("(_H24_):(_MIN_)"),handler:EE(["","hour","minute"])},{name:"h12",regex:a.compile("(_H12_)\\s*(_MERIDIEM_)"),handler:EE(["","hour","meridiem"])},{name:"8digit",regex:/^((?:19|20)\d{2})(\d{2})(\d{2})$/,handler:EE(["","year","month","day"])},{name:"yearMonthnameDay",regex:a.compile("(_YEAR4_)[\\s.-]+(_MONTHNAME_)[\\s,.-]+(_DAY_)(_ORDINAL_)?"),handler:EE(["","year","monthname","day"])},{name:"dayMonthnameYear",regex:a.compile("(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)[\\s,.-]+(_YEAR_)"),handler:EE(["","day","","monthname","year"])},{name:"monthnameDayYear",regex:a.compile("(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?[\\s,.-]+(_YEAR_)"),handler:EE(["","monthname","day","","year"])},{name:"dayMonthname",regex:a.compile("\\b(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)\\b"),handler:EE(["","day","","monthname"])},{name:"monthnameDay",regex:a.compile("\\b(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?\\b"),handler:EE(["","monthname","day"])},{name:"hmsNoMeridiem",regex:a.compile("\\b(_H12_|_H24_):(_MIN_):(_SEC_)\\b"),handler:EE(["","hour","minute","second"])},{name:"hmNoMeridiem",regex:a.compile("\\b(_H12_|_H24_):(_MIN_)\\b"),handler:EE(["","hour","minute"])},{name:"ymd",regex:a.compile("(_YEAR4_)([.-])(_MONTH_)\\2+(_DAY_)"),handler:EE(["","year","","month","day"])},{name:"mdy",regex:a.compile("(_MONTH_)([/-])(_DAY_)\\2(_YEAR_)"),handler:EE(["","month","","day","year"])},{name:"dmy",regex:a.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)[./\\s-]+(_YEAR_)"),handler:EE(["","day","month","year"])},{name:"yearLoose",regex:a.compile("_YEAR4_"),handler:EE(["year"])},{name:"dayMonthnameLoose",regex:a.compile("(_DAY_)[\\s.]*(_MONTHNAME_)"),handler:EE(["","day","monthname"])},{name:"monthnameDayLoose",regex:a.compile("(_MONTHNAME_)[\\s.]*(_DAY_)"),handler:EE(["","monthname","day"])},{name:"monthname",regex:a.compile("_MONTHNAME_"),handler:EE(["monthname"])},{name:"year4",regex:a.compile("_YEAR4_"),handler:EE(["year"])},{name:"md",regex:a.compile("(_MONTH_)[/-](_DAY_)"),handler:EE(["","month","day"])},{name:"dm",regex:a.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)"),handler:EE(["","day","month"])},{name:"day",regex:a.compile("_DAY_"),handler:EE(["day"])},{name:"year2",regex:a.compile("_YEAR2_"),handler:EE(["year"])},{name:"onlyZone",regex:a.compile("_ZONE_"),handler:EE(["zone"])},{name:"onlyOffset",regex:a.compile("_OFFSET_"),handler:EE(["offset"])}],o=a.baseName.slice(0,5),Ev.includes(o)?n:n.filter(e=>!["mdy","md"].includes(e.name))),formatter:(r=a,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(ED.includes(n)){let e=r.toInt(o);"number"==typeof e&&(t[n]=e)}return t.year<100&&(t.year=Es[t.year]),t.year&&"buddhist"===r.dateOptions.calendar&&(t.year-=543),t})})}return E_[e]}(t),n=function(e,t){let r=Ek[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 EO(e){e.month&&e.day&&void 0===e.year&&(e.year=new Date().getFullYear()),60===e.second&&(e.second=59);let t=new Ei(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 Ei(t.valueOf()-60*e.offset*1e3):t}function ER(e,t=Ea){let r=EP(e,t),n=r.invalid?new Ei(NaN):EO(r);return n.isValid()||(n.invalid=`Unable to parse date "${e}"`),n}function ET(e,t=Ea){return e instanceof Date?new Ei(e.valueOf()):"number"==typeof e?new Ei(e):ER(e,t)}Date.fromString=Ei.fromString=ER,Date.fromAny=Ei.fromAny=ET,"u">typeof window&&(window.anyDateParser={fromString:ER,fromAny:ET,fromObject:EO,attempt:EP});var EN=r(5238),Ej=r(3826);let EA=function(e){return null==e};function E$(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}dQ.extend(d1),dQ.extend(Ej),dQ.extend(EN);let EI="YYYY-MM-DDTHH:mm:ss.SSSZZ";function EM(e){return null!=e&&28===e.trim().length&&"T"===(e=e.trim())[10]&&":"===e[13]&&":"===e[16]&&"."===e[19]&&("+"===e[23]||"-"===e[23])&&dQ(e,EI).isValid()}function EL(e){return dQ(e).isToday()}function EF(e){return EM(e)?dQ(e,EI).toDate():null}function EB(e,t=!1){let r=dQ(e);return t&&(r=r.utc()),r.format(EI)}function EU(e){return dQ(e).toDate()}var EV=new WeakMap;let EW=new class{register(e,t){E$(this,EV).set(e,t)}getCalendar(e){if(!e)return;if(e.calendar)return e.calendar;if(e.region){let t=`${e.language}-${e.region}`;if(E$(this,EV).has(t))return E$(this,EV).get(t)}if(e.language&&E$(this,EV).has(e.language))return E$(this,EV).get(e.language);let t=new Intl.DateTimeFormat(e.toString()).resolvedOptions().calendar;return E$(this,EV).set(`${e.language}${e.region?`-${e.region}`:""}`,t),t}constructor(){!function(e,t,r){if(t.has(e))throw TypeError("Cannot initialize the same private elements twice on an object");t.set(e,r)}(this,EV,{writable:!0,value:new Map})}};function EH(e,t){EW.register(e,t)}function Ez(e){let t=e??Eo();return EW.getCalendar(t instanceof Intl.Locale?t:new Intl.Locale(t))}let EK={mode:"standard",time:"for today",day:!0,month:!0,year:!0,noToday:!1};function EG(e,t={}){let r=EP(e,Eo());if(r.invalid)return console.warn(`Could not parse invalid date '${e}'`),null;!EA(r.day)&&EA(r.month)&&(r=Object.assign({},nr(r,"day"),{month:r.day})),r.month&&(r.month-=1),r.day&&(r=Object.assign({},nr(r,"day"),{date:r.day}));let n=dQ().set(r).toDate();return EA(r.year)&&(t.year=!1),EA(r.month)&&(t.month=!1),EA(r.date)&&(t.day=!1),EZ(n,t)}function EZ(e,t){let r,n=t?.locale??Eo(),o=new Intl.Locale(n),{calendar:a,mode:i,time:s,day:l,month:u,year:c,noToday:d,numberingSystem:f}={...EK,...{noToday:"am"===o.language},...t},p={calendar:a??Ez(o),year:c?"numeric":void 0,month:u?"short":void 0,day:l?"2-digit":void 0,numberingSystem:f},m=dQ(e).isToday();if(m&&!d)r=(r=new Intl.RelativeTimeFormat(n,{numeric:"auto"}).format(0,"day"))[0].toLocaleUpperCase(n)+r.slice(1);else{"en"===o.language&&(n="en-GB");let t=new Intl.DateTimeFormat(n,p).formatToParts(e);("en"===o.language||"am"===o.language)&&"standard"==i&&c&&l&&(t=t.map(EY("-"))),"wide"==i&&(t=t.map(EY(" — "))),"ethiopic"===p.calendar&&(t=t.filter((e,t,r)=>"era"!==e.type&&("literal"!==e.type||!(t<r.length-1)||"era"!==r[t+1].type))),r=t.map(e=>e.value).join("")}return(!0===s||m&&"for today"===s)&&(r+=`, ${Eq(e)}`),r}let EY=e=>(t,r,n)=>"literal"!==t.type||" "!==t.value||r<n.length-1&&"era"===n[r+1].type?t:{type:"literal",value:e};function Eq(e){return e.toLocaleTimeString(Eo(),{hour:"2-digit",minute:"2-digit"})}function EJ(e,t){return EZ(e,{...t,time:!0})}function EX(e,t){let r=Ez("string"==typeof t?new Intl.Locale(t):t);return r?yi(e,vL(r)):e}function EQ(e,t){return new Intl.DurationFormat(Eo(),t).format(e)}function E0(e,t){if(null==e)return null;if("string"==typeof e){let r=EP(e,Eo());return r.invalid?(console.warn(`Could not interpret '${e}' as a date`),null):(r.day&&!r.month&&(r={...nr(r,"day"),...{month:r.day}}),r.month&&(r.month-=1),r.day&&(r={...nr(r,"day"),...{date:r.day}}),dQ(t).set(r))}return dQ(e)}let E1=["years","months","days","hours","minutes","seconds"],E2={second:"seconds",minute:"minutes",hour:"hours",day:"days",month:"months",year:"years"},E4={seconds:45,minutes:45,hours:22,days:26,months:11,years:1/0};function E3(e,t=dQ(),r){let n,o=dQ(t),a=E0(e,o);if(null==a)return null;if("string"==typeof r){let e=E2[r]??r;return{[e]:o.diff(a,e)}}let{thresholds:i,largestUnit:s,smallestUnit:l}=r??{};if(void 0!==s||void 0!==l){let e,t=l?E2[l]??l:void 0;return e="auto"===s||void 0===s?function(e,t,r){let n=E1.indexOf(r);for(let o=0;o<E1.length;o++){let a=E1[o];if(t.diff(e,a)>0)return o<=n?a:r}return r}(a,o,t??"seconds"):E2[s]??s,function(e,t,r,n){let o=E1.indexOf(r),a=E1.indexOf(n),i=E1.slice(o,a+1),s={},l=e;for(let e of i){let r=t.diff(l,e);s[e]=r,l=l.add(r,e)}return s}(a,o,e,t??e)}let u=(n=function(e){let t={...E4};if(e)for(let[r,n]of Object.entries(e))void 0!==n&&(t[E2[r]??r]=n);return t}(i),o.diff(a,"seconds")<n.seconds?"seconds":o.diff(a,"minutes")<n.minutes?"minutes":o.diff(a,"hours")<n.hours?"hours":o.diff(a,"days")<n.days?"days":o.diff(a,"months")<n.months?"months":"years");return{[u]:o.diff(a,u)}}let E6={style:"short",localeMatcher:"lookup"};function E5(e,t=dQ(),r){let n=E3(e,t,r);return null==n?null:EQ(n,"object"==typeof r&&r.formatOptions?{...E6,...r.formatOptions}:E6)}let E9=(0,cu.createContext)(null);function E8(){let e=du({externalModuleName:"@openmrs/esm-styleguide"}).preferredDateLocale,t=(0,cu.useMemo)(()=>{let t=Eo();return e[t]&&(t=e[t]),t},[window.i18next.language]),r=(0,cu.useMemo)(()=>{let e=Ez(t);return void 0!==e?vL(e):void 0},[t]),n=(0,cu.useMemo)(()=>new Intl.Locale(t,{calendar:r?.identifier}),[t,r]),o=(0,cu.useMemo)(()=>r?yi(ym(yv()),r):ym(yv()),[r]);return{calendar:r,intlLocale:n,today_:o}}let E7=new gQ(1793,1,1);var xe={};function xt(){return"u">typeof window&&window.InputEvent&&"function"==typeof InputEvent.prototype.getTargetRanges}xe={"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 xr=r(137);function xn(e={}){let{locale:t}=gD();return(0,cu.useMemo)(()=>new(0,xr.K)(t,e),[t,e])}var xo={};function xa(e){var t;let r=(0,cu.useRef)(void 0),{value:n,textValue:o,minValue:a,maxValue:i,isDisabled:s,isReadOnly:l,isRequired:u,onIncrement:c,onIncrementPage:d,onDecrement:f,onDecrementPage:p,onDecrementToMin:m,onIncrementToMax:h}=e,g=yj((t=xo)&&t.__esModule?t.default:t,"@react-aria/spinbutton");(0,cu.useEffect)(()=>()=>clearTimeout(r.current),[]);let y=(0,cu.useRef)(!1),v=()=>{y.current=!0},b=()=>{y.current=!1},w=""===o?g.format("Empty"):(o||`${n}`).replace("-","−");(0,cu.useEffect)(()=>{y.current&&(mV&&mV.clear("assertive"),mW(w,"assertive"))},[w]);let E=mv(e=>{clearTimeout(r.current),null==c||c(),r.current=window.setTimeout(()=>{(void 0===i||isNaN(i)||void 0===n||isNaN(n)||n<i)&&E(60)},e)}),x=mv(e=>{clearTimeout(r.current),null==f||f(),r.current=window.setTimeout(()=>{(void 0===a||isNaN(a)||void 0===n||isNaN(n)||n>a)&&x(60)},e)}),D=e=>{e.preventDefault()},{addGlobalListener:_,removeAllGlobalListeners:S}=hD();return{spinButtonProps:{role:"spinbutton","aria-valuenow":void 0===n||isNaN(n)?void 0:n,"aria-valuetext":w,"aria-valuemin":a,"aria-valuemax":i,"aria-disabled":s||void 0,"aria-readonly":l||void 0,"aria-required":u||void 0,onKeyDown:e=>{if(!e.ctrlKey&&!e.metaKey&&!e.shiftKey&&!e.altKey&&!l)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":m&&(e.preventDefault(),null==m||m());break;case"End":h&&(e.preventDefault(),null==h||h())}},onFocus:v,onBlur:b},incrementButtonProps:{onPressStart:()=>{E(400),_(window,"contextmenu",D)},onPressEnd:()=>{clearTimeout(r.current),S()},onFocus:v,onBlur:b},decrementButtonProps:{onPressStart:()=>{x(400),_(window,"contextmenu",D)},onPressEnd:()=>{clearTimeout(r.current),S()},onFocus:v,onBlur:b}}}xo={"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 xi=r(7120);function xs(e,t,r){let n="+"===e?t+r:t-r;if(t%1!=0||r%1!=0){let o=t.toString().split("."),a=r.toString().split("."),i=Math.pow(10,Math.max(o[1]&&o[1].length||0,a[1]&&a[1].length||0));t=Math.round(t*i),r=Math.round(r*i),n=("+"===e?t+r:t-r)/i}return n}let xl=(0,cu.createContext)(null),xu=(0,cu.createContext)(null),xc=(0,cu.forwardRef)(function(e,t){var r,n;[e,t]=mL(e,t,xl);let{validationBehavior:o}=mM(wp)||{},a=null!=(n=null!=(r=e.validationBehavior)?r:o)?n:"native",{locale:i}=gD(),s=function(e){let{minValue:t,maxValue:r,step:n,formatOptions:o,value:a,defaultValue:i=NaN,onChange:s,locale:l,isDisabled:u,isReadOnly:c}=e;null===a&&(a=NaN),void 0===a||isNaN(a)||(a=void 0===n||isNaN(n)?wb(a,t,r):wE(a,t,r,n)),isNaN(i)||(i=void 0===n||isNaN(n)?wb(i,t,r):wE(i,t,r,n));let[d,f]=vK(a,isNaN(i)?NaN:i,s),[p,m]=(0,cu.useState)(()=>isNaN(d)?"":new(0,xr.K)(l,o).format(d)),h=(0,cu.useMemo)(()=>new(0,xi.d)(l,o),[l,o]),g=(0,cu.useMemo)(()=>h.getNumberingSystem(p),[h,p]),y=(0,cu.useMemo)(()=>new(0,xr.K)(l,{...o,numberingSystem:g}),[l,o,g]),v=(0,cu.useMemo)(()=>y.resolvedOptions(),[y]),b=(0,cu.useCallback)(e=>isNaN(e)||null===e?"":y.format(e),[y]),w=bB({...e,value:d}),E=void 0===n||isNaN(n)?1:n;"percent"===v.style&&(void 0===n||isNaN(n))&&(E=.01);let[x,D]=(0,cu.useState)(d),[_,S]=(0,cu.useState)(l),[C,k]=(0,cu.useState)(o);Object.is(d,x)&&l===_&&o===C||(m(b(d)),D(d),S(l),k(o));let P=(0,cu.useMemo)(()=>h.parse(p),[h,p]),O=(e,n=0)=>{if(isNaN(P))return wE(isNaN(n)?0:n,t,r,E);{let n=wE(P,t,r,E);return"+"===e&&n>P||"-"===e&&n<P?n:wE(xs(e,P,E),t,r,E)}},R=(0,cu.useMemo)(()=>!u&&!c&&(isNaN(P)||void 0===r||isNaN(r)||wE(P,t,r,E)>P||xs("+",P,E)<=r),[u,c,t,r,E,P]),T=(0,cu.useMemo)(()=>!u&&!c&&(isNaN(P)||void 0===t||isNaN(t)||wE(P,t,r,E)<P||xs("-",P,E)>=t),[u,c,t,r,E,P]);return{...w,validate:e=>h.isValidPartialNumber(e,t,r),increment:()=>{let e=O("+",t);e===d&&m(b(e)),f(e),w.commitValidation()},incrementToMax:()=>{null!=r&&(f(wE(r,t,r,E)),w.commitValidation())},decrement:()=>{let e=O("-",r);e===d&&m(b(e)),f(e),w.commitValidation()},decrementToMin:()=>{null!=t&&(f(t),w.commitValidation())},canIncrement:R,canDecrement:T,minValue:t,maxValue:r,numberValue:P,setNumberValue:f,setInputValue:m,inputValue:p,commit:()=>{let e;if(!p.length){f(NaN),m(void 0===a?"":b(d));return}isNaN(P)?m(b(d)):(e=void 0===n||isNaN(n)?wb(P,t,r):wE(P,t,r,n),f(e=h.parse(b(e))),m(b(void 0===a?e:d)))}}}({...e,locale:i,validationBehavior:a}),l=(0,cu.useRef)(null),[u,c]=mF(!e["aria-label"]&&!e["aria-labelledby"]),{labelProps:d,groupProps:f,inputProps:p,incrementButtonProps:m,decrementButtonProps:h,descriptionProps:g,errorMessageProps:y,...v}=function(e,t,r){var n,o;let a,{id:i,decrementAriaLabel:s,incrementAriaLabel:l,isDisabled:u,isReadOnly:c,isRequired:d,minValue:f,maxValue:p,autoFocus:m,label:h,formatOptions:g,onBlur:y=()=>{},onFocus:v,onFocusChange:b,onKeyDown:w,onKeyUp:E,description:x,errorMessage:D,isWheelDisabled:_,...S}=e,{increment:C,incrementToMax:k,decrement:P,decrementToMin:O,numberValue:R,inputValue:T,commit:N,commitValidation:j}=t,A=yj((o=xe)&&o.__esModule?o.default:o,"@react-aria/numberfield"),$=mR(i),{focusProps:I}=h4({onBlur(){N()}}),M=xn(g),L=(0,cu.useMemo)(()=>M.resolvedOptions(),[M]),F=xn({...g,currencySign:void 0}),B=(0,cu.useMemo)(()=>isNaN(R)?"":F.format(R),[F,R]),{spinButtonProps:U,incrementButtonProps:V,decrementButtonProps:W}=xa({isDisabled:u,isReadOnly:c,isRequired:d,maxValue:p,minValue:f,onIncrement:C,onIncrementToMax:k,onDecrement:P,onDecrementToMin:O,value:R,textValue:B}),[H,z]=(0,cu.useState)(!1),{focusWithinProps:K}=h9({isDisabled:u,onFocusWithinChange:z});!function(e,t){let{onScroll:r,isDisabled:n}=e,o=(0,cu.useCallback)(e=>{!e.ctrlKey&&(e.preventDefault(),e.stopPropagation(),r&&r({deltaX:e.deltaX,deltaY:e.deltaY}))},[r]);yQ(t,"wheel",n?void 0:o)}({onScroll:(0,cu.useCallback)(e=>{!(Math.abs(e.deltaY)<=Math.abs(e.deltaX))&&(e.deltaY>0?C():e.deltaY<0&&P())},[P,C]),isDisabled:_||u||c||!H},r);let G=(null!=(n=L.maximumFractionDigits)?n:0)>0,Z=void 0===t.minValue||isNaN(t.minValue)||t.minValue<0,Y="numeric";hn()?Z?Y="text":G&&(Y="decimal"):hl()&&(Z?Y="numeric":G&&(Y="decimal"));let q=mY(e),J=(0,cu.useCallback)(e=>{"Enter"===e.key?(N(),j()):e.continuePropagation()},[N,j]),{isInvalid:X,validationErrors:Q,validationDetails:ee}=t.displayValidation,{labelProps:et,inputProps:er,descriptionProps:en,errorMessageProps:eo}=function(e,t,r){let n=mv(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,cu.useEffect)(()=>{if(!xt()||!r.current)return;let e=r.current;return e.addEventListener("beforeinput",n,!1),()=>{e.removeEventListener("beforeinput",n,!1)}},[r,n]);let o=xt()?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:a,inputProps:i,descriptionProps:s,errorMessageProps:l,...u}=function(e,t){let{inputElementType:r="input",isDisabled:n=!1,isRequired:o=!1,isReadOnly:a=!1,type:i="text",validationBehavior:s="aria"}=e,[l,u]=vK(e.value,e.defaultValue||"",e.onChange),{focusableProps:c}=h5(e,t),d=bB({...e,value:l}),{isInvalid:f,validationErrors:p,validationDetails:m}=d.displayValidation,{labelProps:h,fieldProps:g,descriptionProps:y,errorMessageProps:v}=bP({...e,isInvalid:f,errorMessage:e.errorMessage||p}),b=mY(e,{labelable:!0}),w={type:i,pattern:e.pattern};return bk(t,l,u),bO(e,d,t),(0,cu.useEffect)(()=>{if(t.current instanceof m2(t.current).HTMLTextAreaElement){let e=t.current;Object.defineProperty(e,"defaultValue",{get:()=>e.value,set:()=>{},configurable:!0})}},[t]),{labelProps:h,inputProps:mj(b,"input"===r?w:void 0,{disabled:n,readOnly:a,required:o&&"native"===s,"aria-required":o&&"aria"===s||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:l,onChange:e=>u(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(cc().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,...g}),descriptionProps:y,errorMessageProps:v,isInvalid:f,validationErrors:p,validationDetails:m}}(e,r),c=(0,cu.useRef)(null);return{inputProps:mj(i,{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:a,descriptionProps:s,errorMessageProps:l,...u}}({...S,...q,name:void 0,label:h,autoFocus:m,isDisabled:u,isReadOnly:c,isRequired:d,validate:void 0,[bF]:t,value:T,defaultValue:void 0,autoComplete:"off","aria-label":e["aria-label"]||void 0,"aria-labelledby":e["aria-labelledby"]||void 0,id:$,type:"text",inputMode:Y,onChange:e=>{t.validate(e)&&t.setInputValue(e)},onBlur:y,onFocus:v,onFocusChange:b,onKeyDown:(0,cu.useMemo)(()=>mg(J,w),[J,w]),onKeyUp:E,description:x,errorMessage:D},t,r);bk(r,t.numberValue,t.setNumberValue);let ea=mj(U,I,er,{role:null,"aria-roledescription":ha()?null:A.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 ei=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||(a=null!=e.label?et.id:e["aria-labelledby"]);let el=mR(),eu=mR(),ec=mj(V,{"aria-label":l||A.format("increase",{fieldLabel:es}).trim(),id:a&&!l?el:null,"aria-labelledby":a&&!l?`${el} ${a}`:null,"aria-controls":$,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!t.canIncrement,onPressStart:ei}),ed=mj(W,{"aria-label":s||A.format("decrease",{fieldLabel:es}).trim(),id:a&&!s?eu:null,"aria-labelledby":a&&!s?`${eu} ${a}`:null,"aria-controls":$,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!t.canDecrement,onPressStart:ei});return{groupProps:{...K,role:"group","aria-disabled":u,"aria-invalid":X?"true":void 0},labelProps:et,inputProps:ea,incrementButtonProps:ec,decrementButtonProps:ed,errorMessageProps:eo,descriptionProps:en,isInvalid:X,validationErrors:Q,validationDetails:ee}}({...mB(e),label:c,validationBehavior:a},s,l),b=mI({...e,values:{state:s,isDisabled:e.isDisabled||!1,isInvalid:v.isInvalid||!1,isRequired:e.isRequired||!1},defaultClassName:"react-aria-NumberField"}),w=mY(e);return delete w.id,cc().createElement(m$,{values:[[xu,s],[be,f],[br,{...p,ref:l}],[wm,{...d,ref:u}],[gs,{slots:{increment:m,decrement:h}}],[gc,{slots:{description:g,errorMessage:y}}],[wc,v]]},cc().createElement("div",{...w,...b,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&&cc().createElement("input",{type:"hidden",name:e.name,value:isNaN(s.numberValue)?"":s.numberValue}))});function xd(e,t){return Number.parseInt(EZ(e,{calendar:t.calendar,locale:t.baseName,day:!1,month:!1,noToday:!0,numberingSystem:"latn"}))}let xf=(0,cu.forwardRef)(function(e,t){let{className:r}=e,n=(0,cu.useContext)(v0),o=(0,cu.useContext)(v1),a=n??o,i=(0,cu.useContext)(E9),s=yv(),l=EZ(a.visibleRange.start.toDate(s),{calendar:i.calendar,locale:i.baseName,day:!1,year:!1,noToday:!0}),u=xd(a.visibleRange.start.toDate(s),i),c=a.maxValue?xd(a.maxValue.toDate(s),i):void 0,d=a.minValue?xd(a.minValue.toDate(s),i):void 0,f=(0,cu.useCallback)(e=>{a.setFocusedDate(a.focusedDate.cycle("year",e-a.focusedDate.year))},[]);return a&&(0,fd.jsxs)("span",{ref:t,className:r,children:[(0,fd.jsx)("span",{children:l}),(0,fd.jsxs)(xc,{formatOptions:{useGrouping:!1},maxValue:c,minValue:d,onChange:f,value:u,children:[(0,fd.jsx)(bn,{}),(0,fd.jsxs)(bt,{children:[(0,fd.jsx)(gl,{slot:"increment",children:(0,fd.jsx)(f0,{size:8})}),(0,fd.jsx)(gl,{slot:"decrement",children:(0,fd.jsx)(fJ,{size:8})})]})]})]})}),xp="-esm-cohort-builder__datepicker-module__inputGroup___-wpzr",xm="-esm-cohort-builder__datepicker-module__inputSegment___ocu7L",xh="-esm-cohort-builder__datepicker-module__dateInputWrapper___909Km",xg="-esm-cohort-builder__datepicker-module__invalidText___oHJHi",xy="-esm-cohort-builder__datepicker-module__flatButton___i9LDo",xv="-esm-cohort-builder__datepicker-module__flatButtonMd___VZMkc",xb="-esm-cohort-builder__datepicker-module__flatButtonSm___VA5wy",xw="-esm-cohort-builder__datepicker-module__flatButtonLg___MnYLl";function xE({children:e}){let t=(0,cu.useContext)(w6),r=(0,cu.useContext)(w5),n=t??r,o=dV(()=>n?.close());return(0,fd.jsx)(wu,{className:"-esm-cohort-builder__datepicker-module__dialog___2pADb",ref:o,children:e})}let xx=(0,cu.forwardRef)(function({variant:e,today_:t,minDate:r,maxDate:n},o){let a="range"===e;return(0,fd.jsx)(w0,{ref:o,className:"-esm-cohort-builder__datepicker-module__popover___pb58i",placement:"bottom start",offset:1,isNonModal:!0,children:(0,fd.jsx)(xE,{children:(0,fd.jsxs)(a?v4:v2,{...a?{minValue:r,maxValue:n,className:"cds--date-picker__calendar"}:{},children:[(0,fd.jsxs)("header",{className:"-esm-cohort-builder__datepicker-module__header___+fi16",children:[(0,fd.jsx)(gl,{className:fp()(xy,xv),slot:"previous",children:(0,fd.jsx)(f9,{size:16})}),(0,fd.jsx)(xf,{className:"-esm-cohort-builder__datepicker-module__monthYear___mGhot"}),(0,fd.jsx)(gl,{className:fp()(xy,xv),slot:"next",children:(0,fd.jsx)(f8,{size:16})})]}),(0,fd.jsx)(v6,{className:"-esm-cohort-builder__datepicker-module__calendarGrid___z07wV",children:e=>(0,fd.jsx)(v7,{className:fp()("cds--date-picker__day",{"-esm-cohort-builder__datepicker-module__today___dNc4M":0===t.compare(e)}),date:e},e.toString())})]})})})}),xD=(0,cu.forwardRef)(function(e,t){let r=(0,cu.useContext)(w6),[n,o]=mL({slot:e.slot},t,b9),{locale:a}=gD(),i=b6({...n,locale:a,createCalendar:vL}),s=(0,cu.useRef)(null),{fieldProps:l,inputProps:u}=bj({...n,inputRef:s},i,o),c=(0,cu.useCallback)(()=>{i.isDisabled||r.toggle()},[]);return(0,fd.jsxs)(m$,{values:[[b8,i],[br,{...u,ref:s}],[be,{...l,ref:o,isInvalid:i.isInvalid}]],children:[(0,fd.jsx)(bt,{...e,id:e.id,ref:t,slot:e.slot||void 0,className:e.className,isDisabled:i.isDisabled,isInvalid:i.isInvalid,onClick:c,children:i.segments.map((t,r)=>(0,cu.cloneElement)(e.children(t),{key:r}))}),(0,fd.jsx)(bn,{})]})}),x_=(0,cu.forwardRef)(function(e,t){let r=(0,cu.useContext)(w6),n=(0,cu.useContext)(w5);return(r??n).isInvalid?(0,fd.jsx)(ma,{ref:t,size:16,...e}):(0,fd.jsx)(fq,{ref:t,size:16,...e})});class xS{of(e){return this.dictionary.getStringForLocale(e,this.locale)}constructor(e,t){this.locale=e,this.dictionary=t}}let xC=new Map,xk=(0,cu.forwardRef)(function({segment:e,...t},r){let n=(0,cu.useContext)(b8),o=mh(r),{segmentProps:a}=function(e,t,r){let n,o,a,i,s=(0,cu.useRef)(""),{locale:l,direction:u}=gD(),c=function(){var e;let{locale:t}=gD(),r=yN((e=bo)&&e.__esModule?e.default:e,"@react-aria/datepicker");return(0,cu.useMemo)(()=>{try{return new Intl.DisplayNames(t,{type:"dateTimeField"})}catch{return new xS(t,r)}},[t,r])}(),{ariaLabel:d,ariaLabelledBy:f,ariaDescribedBy:p,focusManager:m}=bR.get(t),h=e.isPlaceholder?"":e.text,g=(0,cu.useMemo)(()=>t.dateFormatter.resolvedOptions(),[t.dateFormatter]),y=yU({month:"long",timeZone:g.timeZone}),v=yU({hour:"numeric",hour12:g.hour12,timeZone:g.timeZone});if("month"!==e.type||e.isPlaceholder)"hour"!==e.type||e.isPlaceholder||(h=v.format(t.dateValue));else{let e=y.format(t.dateValue);h=e!==h?`${h} \u{2013} ${e}`:e}let{spinButtonProps:b}=xa({value:e.value,textValue:h,minValue:e.minValue,maxValue:e.maxValue,isDisabled:t.isDisabled,isReadOnly:t.isReadOnly||!e.isEditable,isRequired:t.isRequired,onIncrement:()=>{s.current="",t.increment(e.type)},onDecrement:()=>{s.current="",t.decrement(e.type)},onIncrementPage:()=>{s.current="",t.incrementPage(e.type)},onDecrementPage:()=>{s.current="",t.decrementPage(e.type)},onIncrementToMax:()=>{s.current="",void 0!==e.maxValue&&t.setSegment(e.type,e.maxValue)},onDecrementToMin:()=>{s.current="",void 0!==e.minValue&&t.setSegment(e.type,e.minValue)}}),w=(0,cu.useMemo)(()=>new(0,xi.d)(l,{maximumFractionDigits:0}),[l]),E=()=>{if(e.text===e.placeholder&&m.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),s.current=r}},{startsWith:x}=(n=function(e){let{locale:t}=gD(),r=t+(e?Object.entries(e).sort((e,t)=>e[0]<t[0]?-1:1).join():"");if(xC.has(r))return xC.get(r);let n=new Intl.Collator(t,e);return xC.set(r,n),n}({usage:"search",sensitivity:"base"}),o=(0,cu.useCallback)((e,t)=>0===t.length||(e=e.normalize("NFC"),t=t.normalize("NFC"),0===n.compare(e.slice(0,t.length),t)),[n]),a=(0,cu.useCallback)((e,t)=>0===t.length||(e=e.normalize("NFC"),t=t.normalize("NFC"),0===n.compare(e.slice(-t.length),t)),[n]),i=(0,cu.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 a=e.slice(r,r+o);if(0===n.compare(t,a))return!0}return!1},[n]),(0,cu.useMemo)(()=>({startsWith:o,endsWith:a,contains:i}),[o,a,i])),D=yU({hour:"numeric",hour12:!0}),_=(0,cu.useMemo)(()=>{let e=new Date;return e.setHours(0),D.formatToParts(e).find(e=>"dayPeriod"===e.type).value},[D]),S=(0,cu.useMemo)(()=>{let e=new Date;return e.setHours(12),D.formatToParts(e).find(e=>"dayPeriod"===e.type).value},[D]),C=yU({year:"numeric",era:"narrow",timeZone:"UTC"}),k=(0,cu.useMemo)(()=>{if("era"!==e.type)return[];let r=yi(new gQ(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:C.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},[C,t.calendar,e.type]),P=r=>{if(t.isDisabled||t.isReadOnly)return;let n=s.current+r;switch(e.type){case"dayPeriod":if(x(_,r))t.setSegment("dayPeriod",0);else if(x(S,r))t.setSegment("dayPeriod",12);else break;m.focusNext();break;case"era":{let e=k.find(e=>x(e.formatted,r));e&&(t.setSegment("era",e.era),m.focusNext());break}case"day":case"hour":case"minute":case"second":case"month":case"year":{if(!w.isValidPartialNumber(n))return;let o=w.parse(n),a=o,i=0===e.minValue;if("hour"===e.type&&t.dateFormatter.resolvedOptions().hour12){switch(t.dateFormatter.resolvedOptions().hourCycle){case"h11":o>11&&(a=w.parse(r));break;case"h12":i=!1,o>12&&(a=w.parse(r))}void 0!==e.value&&e.value>=12&&o>1&&(o+=12)}else void 0!==e.maxValue&&o>e.maxValue&&(a=w.parse(r));if(isNaN(o))return;let l=0!==a||i;l&&t.setSegment(e.type,a),void 0!==e.maxValue&&(Number(o+"0")>e.maxValue||n.length>=String(e.maxValue).length)?(s.current="",l&&m.focusNext()):s.current=n}}};yQ((0,cu.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 O=(0,cu.useRef)("");yQ(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":O.current=r.current.textContent,r.current.textContent=r.current.textContent;break;default:null!=n.data&&P(n.data)}}),yQ(r,"input",e=>{let{inputType:t,data:n}=e;"insertCompositionText"===t&&(r.current&&(r.current.textContent=O.current),null!=n&&(x(_,n)||x(S,n))&&P(n))}),my(()=>{let e=r.current;return()=>{document.activeElement===e&&(m.focusPrevious()||m.focusNext())}},[r,m]);let R=ha()||"timeZoneName"===e.type?{role:"textbox","aria-valuemax":null,"aria-valuemin":null,"aria-valuetext":null,"aria-valuenow":null}:{};e===(0,cu.useMemo)(()=>t.segments.find(e=>e.isEditable),[t.segments])||t.isInvalid||(p=void 0);let T=mR(),N=!t.isDisabled&&!t.isReadOnly&&e.isEditable,j="literal"===e.type?"":c.of(e.type),A=yY({"aria-label":`${j}${d?`, ${d}`:""}${f?", ":""}`,"aria-labelledby":f});if("literal"===e.type)return{segmentProps:{"aria-hidden":!0}};let $={caretColor:"transparent"};if("rtl"===u){$.unicodeBidi="embed";let t=g[e.type];("numeric"===t||"2-digit"===t)&&($.direction="ltr")}return{segmentProps:mj(b,A,{id:T,...R,"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:N,suppressContentEditableWarning:N,spellCheck:N?"false":void 0,autoCorrect:N?"off":void 0,[parseInt(cc().version,10)>=17?"enterKeyHint":"enterkeyhint"]:N?"next":void 0,inputMode:t.isDisabled||"dayPeriod"===e.type||"era"===e.type||!N?void 0:"numeric",tabIndex:t.isDisabled?void 0:0,onKeyDown:e=>{if("a"===e.key&&(hr()?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:()=>{s.current="",r.current&&y6(r.current,{containingElement:y5(r.current)});let e=window.getSelection();null==e||e.collapse(r.current)},style:$,onPointerDown(e){e.stopPropagation()},onMouseDown(e){e.stopPropagation()}})}}(e,n,o),{focusProps:i,isFocused:s,isFocusVisible:l}=h8(),{hoverProps:u,isHovered:c}=gn({...t,isDisabled:n.isDisabled||"literal"===e.type}),d=function(e){let{className:t,style:r,children:n,defaultClassName:o,defaultChildren:a,defaultStyle:i,values:s}=e;return(0,cu.useMemo)(()=>{let e,l,u;return e="function"==typeof t?t({...s,defaultClassName:o}):t,l="function"==typeof r?r({...s,defaultStyle:i||{}}):r,u="function"==typeof n?n({...s,defaultChildren:a}):null==n?a:n,{className:e??o,style:l||i?{...i,...l}:void 0,children:u??a,"data-rac":""}},[t,r,n,o,a,i,s])}({...t,values:{...e,isReadOnly:!e.isEditable,isInvalid:n.isInvalid,isDisabled:n.isDisabled,isHovered:c,isFocused:s,isFocusVisible:l},defaultChildren:e.text}),f=(0,cu.useCallback)(e=>{e.stopPropagation()},[]);return(0,fd.jsx)("span",{...mj(mY(t),a,i,u),...d,ref:o,style:a.style,"data-placeholder":e.isPlaceholder||void 0,"data-invalid":n.isInvalid||void 0,"data-readonly":!e.isEditable||void 0,"data-disabled":n.isDisabled||void 0,"data-type":e.type,"data-hovered":c||void 0,"data-focused":s||void 0,"data-focus-visible":l||void 0,onClick:f})}),xP={short:!1,size:"md"},xO=(0,cu.forwardRef)(function(e,t){let{className:r,defaultValue:n,isDisabled:o,invalid:a,invalidText:i,isInvalid:s,label:l,labelText:u,light:c,maxDate:d,minDate:f,onChange:p,onChangeRaw:m,short:h,size:g,value:y,...v}={...xP,...e},{calendar:b,intlLocale:w,today_:E}=E8(),x=(0,cu.useId)(),D=!!(u??l),_=(0,cu.useMemo)(()=>Ee(n,b),[n,b]),S=(0,cu.useMemo)(()=>Ee(y,b,!0),[y,b]),C=(0,cu.useMemo)(()=>Ee(d,b),[d,b]),k=(0,cu.useMemo)(()=>Ee(f??E7,b),[f,b]),P=(0,cu.useMemo)(()=>a||s,[a,s]),O=(0,cu.useMemo)(()=>(m&&p&&console.error("An OpenmrsDatePicker component was created with both onChange and onChangeRaw handlers defined. Only onChangeRaw will be used."),m??(e=>p?.(Et(e)))),[m,p]);return(0,fd.jsx)(w7,{locale:w.toString(),children:(0,fd.jsx)("div",{className:fp()("cds--form-item",r),children:(0,fd.jsx)(m$,{values:[[E9,w]],children:(0,fd.jsxs)(w9,{className:fp()("cds--date-picker","cds--date-picker--single",{"cds--date-picker--short":h,"cds--date-picker--light":c}),defaultValue:_,isDisabled:o,isInvalid:P,maxValue:C,minValue:k,value:S,shouldForceLeadingZeros:"en"===w.language||void 0,...v,onChange:O,children:[(0,fd.jsxs)("div",{className:"cds--date-picker-container",children:[D&&(0,fd.jsx)(wh,{className:fp()("cds--label",{"cds--label--disabled":o}),htmlFor:x,children:u??l}),(0,fd.jsxs)(bt,{className:xp,children:[(0,fd.jsx)(xD,{id:D?x:void 0,ref:t,className:fp()("cds--date-picker-input__wrapper","-esm-cohort-builder__datepicker-module__inputWrapper___MHJAy",{"-esm-cohort-builder__datepicker-module__inputWrapperSm___esx4E":"sm"===g,"-esm-cohort-builder__datepicker-module__inputWrapperMd___VQbzP":"md"===g||!g||0===g.length,"-esm-cohort-builder__datepicker-module__inputWrapperLg___Rk9Ce":"lg"===g}),children:e=>"era"!==e.type?(0,fd.jsx)(xk,{className:xm,segment:e}):(0,fd.jsx)(cc().Fragment,{})}),(0,fd.jsx)(gl,{className:fp()(xy,{[xb]:"sm"===g,[xv]:"md"===g||!g||0===g.length,[xw]:"lg"===g}),children:(0,fd.jsx)(x_,{})})]}),(0,fd.jsx)(wd,{className:xg,children:i})]}),(0,fd.jsx)(xx,{variant:"single",today_:E})]})})})})}),xR=(0,cu.forwardRef)(function({className:e,defaultValue:t,invalid:r,invalidText:n,isDisabled:o,isInvalid:a,label:i,labelText:s,light:l,maxDate:u,minDate:c,onChange:d,onChangeRaw:f,size:p="md",value:m,...h},g){let{calendar:y,intlLocale:v,today_:b}=E8(),w=(0,cu.useId)(),E=!!(s??i),x=(0,cu.useMemo)(()=>{if(m)return{start:Ee(m[0],y,!1),end:Ee(m[1],y,!1)}},[m,y]),D=(0,cu.useMemo)(()=>{if(t)return{start:Ee(t[0],y,!1),end:Ee(t[1],y,!1)}},[t,y]),_=(0,cu.useMemo)(()=>Ee(c??E7,y,!0),[c,y]),S=(0,cu.useMemo)(()=>Ee(u,y,!0),[u,y]),C=(0,cu.useMemo)(()=>r||a,[r,a]),k=(0,cu.useMemo)(()=>(f&&d&&console.error("An OpenmrsDateRangePicker component was created with both onChange and onChangeRaw handlers defined. Only onChangeRaw will be used."),f??(e=>d?.([Et(e.start),Et(e.end)]))),[f,d]);return(0,fd.jsx)(w7,{locale:v.toString(),children:(0,fd.jsx)("div",{className:fp()("cds--form-item",e),children:(0,fd.jsx)(m$,{values:[[E9,v]],children:(0,fd.jsx)(w8,{id:E?w:void 0,className:fp()("cds--date-picker",{"cds--date-picker--light":l,"cds--date-picker--disabled":o}),isInvalid:C,shouldForceLeadingZeros:"en"===v.language||void 0,maxValue:S,minValue:_,value:x,defaultValue:D,ref:g,isDisabled:o,...h,onChange:k,children:(0,fd.jsxs)("div",{className:"cds--date-picker-container",children:[E&&(0,fd.jsx)(wh,{className:fp()("cds--label",{"cds--label--disabled":o}),htmlFor:w,children:s??i}),(0,fd.jsxs)(bt,{className:xp,children:[(0,fd.jsxs)("div",{className:fp()("-esm-cohort-builder__datepicker-module__inputsWrapper___UyGoG",{"-esm-cohort-builder__datepicker-module__inputsWrapperSm___qrGsA":"sm"===p,"-esm-cohort-builder__datepicker-module__inputsWrapperMd___pofu4":"md"===p||!p||0===p.length,"-esm-cohort-builder__datepicker-module__inputsWrapperLg___eF1Im":"lg"===p}),children:[(0,fd.jsx)(we,{className:fp()("cds--date-picker-input__wrapper","-esm-cohort-builder__datepicker-module__startInput___C8vnM",xh),slot:"start",children:e=>(0,fd.jsx)(xk,{className:xm,segment:e})}),(0,fd.jsx)("div",{className:"-esm-cohort-builder__datepicker-module__separator___vHLFZ",children:(0,fd.jsx)("span",{"aria-hidden":"true","data-readonly":!0,children:"–"})}),(0,fd.jsx)(we,{className:fp()("cds--date-picker-input__wrapper","-esm-cohort-builder__datepicker-module__endInput___25OF9",xh),slot:"end",children:e=>(0,fd.jsx)(xk,{className:xm,segment:e})})]}),(0,fd.jsx)(gl,{className:fp()(xy,{[xb]:"sm"===p,[xv]:"md"===p||!p||0===p.length,[xw]:"lg"===p}),children:(0,fd.jsx)(x_,{})})]}),(0,fd.jsx)(wd,{className:xg,children:n}),(0,fd.jsx)(xx,{variant:"range",today_:b,minDate:_,maxDate:S})]})})})})})}),xT=({diagnoses:e})=>{let{diagnosisTags:t}=du({externalModuleName:"@openmrs/esm-styleguide"});return(0,fd.jsx)("div",{className:"-esm-cohort-builder__diagnosis-tags-module__container___l7XiW",children:e.map(e=>{let{rank:r,uuid:n,display:o}=e,a=t[1===r?"primaryColor":"secondaryColor"];return(0,fd.jsx)(fv.Tag,{type:a,children:o},n)})})},xN={action:"-esm-cohort-builder__empty-card-module__action___l4wUo",content:"-esm-cohort-builder__empty-card-module__content___XbsSJ",desktopHeading:"-esm-cohort-builder__empty-card-module__desktopHeading___0EPXX",tabletHeading:"-esm-cohort-builder__empty-card-module__tabletHeading___unl1F",tile:"-esm-cohort-builder__empty-card-module__tile___vS3Sj"},xj=({width:e="64",height:t="64"})=>(0,fd.jsx)("svg",{width:e,height:t,viewBox:"0 0 64 64",children:(0,fd.jsx)("use",{href:"#omrs-empty-data-illustration"})}),xA=e=>{let t="tablet"===dI(),r=e.launchForm;return(0,fd.jsx)(fv.Layer,{className:xN.layer,children:(0,fd.jsxs)(fv.Tile,{className:xN.tile,children:[(0,fd.jsx)("div",{className:t?xN.tabletHeading:xN.desktopHeading,children:(0,fd.jsx)("h4",{children:e.headerTitle})}),(0,fd.jsx)(xj,{}),(0,fd.jsx)("p",{className:xN.content,children:iK("emptyStateText","There are no {{displayText}} to display",{displayText:e.displayText})}),(0,fd.jsx)("p",{className:xN.action,children:r&&(0,fd.jsx)(fv.Button,{onClick:()=>r(),kind:"ghost",size:t?"lg":"sm",children:iK("recordNewEntry","Record {{ displayText }}",{displayText:e.displayText})})})]})})},x$=({error:e,headerTitle:t})=>{let r="tablet"===dI();return(0,fd.jsx)(fv.Layer,{children:(0,fd.jsxs)(fv.Tile,{className:"-esm-cohort-builder__error-state-module__tile___hHM56",children:[(0,fd.jsx)("div",{className:r?"-esm-cohort-builder__error-state-module__tabletHeading___W7a4U":"-esm-cohort-builder__error-state-module__desktopHeading___VL8Rv",children:(0,fd.jsx)("h4",{children:t})}),(0,fd.jsxs)("p",{className:"-esm-cohort-builder__error-state-module__errorMessage___IytZy",children:[iK("error","Error")," ",`${e?.response?.status}: `,e?.response?.statusText]}),(0,fd.jsx)("p",{className:"-esm-cohort-builder__error-state-module__errorCopy___E1yZO",children:iK("errorCopy")})]})})},xI=x$,xM=cc().forwardRef((e,t)=>{let{slotName:r,basePath:n,componentContext:o,state:a}=dF(),i=window.location??{pathname:""},s=c_(r??"");return e.isChildOfHeader&&r&&s.length>0?(0,fd.jsxs)(fv.SideNav,{"aria-label":iK("leftNavigation","Left navigation"),className:"-esm-cohort-builder__left-nav-module__leftNav___ZqLpw",expanded:!0,isFixedNav:!0,ref:t,...e,children:[(0,fd.jsx)(ck,{name:"global-nav-menu-slot"}),r?(0,fd.jsx)(c8,{value:o,fallback:(0,fd.jsx)(ck,{name:r,state:{basePath:n,currentPath:i,...a}}),children:(0,fd.jsx)(cd.Provider,{value:o,children:(0,fd.jsx)(ck,{name:r,state:{basePath:n,currentPath:i,...a}})})}):null]}):null}),xL=({selectedLocationUuid:e,defaultLocationUuid:t,locationTag:r,locationsPerRequest:n=50,onChange:o})=>{let[a,i]=(0,cu.useState)(""),s=(0,cu.useId)(),{location:l}=function(e){let t=e?`/ws/fhir2/R4/Location?_id=${e}`:null,{data:r,error:n,isLoading:o}=dp()(t,i7,{shouldRetryOnError:e=>!!e?.response?.status&&e.response.status>=500});return(0,cu.useMemo)(()=>({location:r?.data?.entry?r.data.entry[0]:null,error:t?n:null,isLoading:!!t&&o}),[r,o,n,t])}(t),{locations:u,isLoading:c,hasMore:d,loadingNewData:f,error:p,setPage:m}=function(e,t=0,r=""){let n=dd(r),{data:o,isLoading:a,isValidating:i,setSize:s,error:l}=dP()(function(r,o){if(o){let e=o.data?.link?.find(e=>"next"===e.relation);if(!e)return null;let t=new URL(e.url);return t.origin===window.location.origin?e.url:new URL(`${t.pathname}${t.search?`?${t.search}`:""}`,window.location.origin).toString()}let a=`${i5}/Location?`,i=new URLSearchParams;return i.append("_summary","data"),t&&i.append("_count",""+t),r&&i.append("_getpagesoffset",""+r*t),e&&i.append("_tag",e),"string"==typeof n&&""!==n&&i.append("name:contains",n),a+i.toString()},i7);return(0,cu.useMemo)(()=>({locations:o?.length?o?.flatMap(e=>e?.data?.entry??[]):[],isLoading:a,totalResults:o?.[0]?.data?.total,hasMore:!!o?.length&&o?.[o.length-1]?.data?.link?.some(e=>"next"===e.relation),loadingNewData:i,error:l||null,setPage:s}),[a,o,i,s,l])}(r,n,a),h=(0,cu.useMemo)(()=>l&&!a&&t?[l,...u.filter(({resource:e})=>e.id!==t)]:u??[],[l,u,t,a]),g=(0,cu.useCallback)(e=>{o(),i(e.trim())},[o]),y=dW((0,cu.useCallback)(()=>{!f&&d&&m(e=>e+1)},[f,d,m])),v=d?Math.max(0,Math.floor(h.length-n/2)):-1;return(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)(fv.Search,{"aria-describedby":p?`${s}-error`:void 0,labelText:iK("searchForLocation"),id:s,placeholder:iK("searchForLocation"),onChange:e=>g(e.target.value),size:"lg"}),p&&(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__errorNotification___MBWvf",id:`${s}-error`,children:(0,fd.jsx)(fv.InlineNotification,{kind:"error",subtitle:iK("errorLoadingLoginLocations","Unable to load login locations. Please try again or contact support if the problem persists."),title:iK("error","Error")})}),(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__searchResults___aCL93",children:c?(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__loadingContainer___Vn1H0",children:Array.from({length:5}).map((e,t)=>(0,fd.jsx)(fv.RadioButtonSkeleton,{className:"-esm-cohort-builder__location-picker-module__radioButtonSkeleton___RKMHj",role:"progressbar"},t))}):(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__locationResultsContainer___5yuvs",children:h.length>0?(0,fd.jsx)(fv.RadioButtonGroup,{name:"loginLocations",onChange:e=>{o(e?.toString())},orientation:"vertical",valueSelected:e,children:h.map((e,t)=>(0,fd.jsx)(fv.RadioButton,{className:"-esm-cohort-builder__location-picker-module__locationRadioButton___b52LI",id:e.resource.id,labelText:(0,fd.jsx)("span",{ref:t===v?y:null,children:e.resource.name}),name:e.resource.name,value:e.resource.id},e.resource.id))}):(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__emptyState___qiPqQ",children:(0,fd.jsx)("p",{className:"-esm-cohort-builder__location-picker-module__locationNotFound___tKDOJ",children:iK("noResultsToDisplay")})})}),f&&(0,fd.jsx)("div",{className:"-esm-cohort-builder__location-picker-module__loadingIcon___PGwvc",children:(0,fd.jsx)(fv.InlineLoading,{description:iK("loading")})})]})})]})},xF=B("modalState",{modalContainer:null,modalStack:[]}),xB=0;async function xU(e,t,r={}){let n=u4(t),o=null;if(e){if(!n)throw Error(`No modal named '${t}' has been registered.`);let{load:a}=n,i=await a(),s=xB++;o=await ca({...i,name:`${t}-${s}`},{...r,domElement:e})}else k(`Failed to launch modal. Please notify your administrator. Modal name: ${t}`);return o}function xV(e){return"TO_BE_DELETED"===e.state||"DELETED"===e.state}function xW(e,t){t?.unmount&&(t.unmountPromise?.catch(()=>{}),t.unmount().catch(t=>{console.error(`The modal '${e}' failed to unmount`,t)}))}function xH(e){return e.find(e=>!xV(e))}function xz(e,t){e.container&&(e.container.style.visibility=t?"unset":"hidden")}let xK=window.getComputedStyle(document.body).overflow;function xG({modalStack:e,modalContainer:t}){if(t)if(e.length){t.style.visibility||(addEventListener("keydown",xY),document.body.style.overflow="hidden",t.style.visibility="unset");let r=xH(e);e.forEach(e=>{switch(e.state){case"NEW":{let r=function({size:e}){let t=document.createElement("div");return t.className=`cds--modal-container cds--modal-container--${e}`,t.setAttribute("role","dialog"),t.setAttribute("tabindex","-1"),t.setAttribute("aria-modal","true"),t}({size:e.props?.size??"md"});e.container=r,e.state="MOUNTING",xU(r,e.modalName,e.props).then(n=>{xV(e)?xW(e.modalName,n):n?(e.parcel=n,t.prepend(r),xz(e,xH(xF.getState().modalStack)===e),n.mountPromise.then(()=>{xV(e)||(e.state="MOUNTED")},t=>{k(t),e.parcel=null,xZ(e)})):xZ(e)},t=>{k(t),xZ(e)});break}case"MOUNTING":case"MOUNTED":xz(e,e===r);break;case"TO_BE_DELETED":e.state="DELETED",e.onClose(),xW(e.modalName,e.parcel),e.container?.remove(),setTimeout(()=>{let t=xF.getState();xF.setState({...t,modalStack:t.modalStack.filter(t=>t!==e)})},0)}})}else t.style.removeProperty("visibility"),document.body.style.overflow=xK,removeEventListener("keydown",xY)}function xZ(e){if(xV(e))return;e.state="TO_BE_DELETED";let t=xF.getState();xF.setState({...t,modalStack:[...t.modalStack]})}function xY(e){"Escape"===e.key&&function(){let[e]=xF.getState().modalStack;e&&xZ(e)}()}function xq(e){xF.subscribe(xG),xF.setState({...xF.getState(),modalContainer:e})}function xJ(e,t={},r=()=>{}){let n=()=>{let e=xF.getState().modalStack.find(e=>e.onClose===r);e&&xZ(e)};if(u4(e)){var o;let a,i;o={state:"NEW",onClose:r,modalName:e,props:{close:n,...t}},i=[o,...(a=xF.getState()).modalStack],xF.setState({...a,modalStack:i})}else k(`Failed to launch modal. Please notify your administrator. Modal name: "${e}"`);return n}var xX=Object.prototype.hasOwnProperty;let xQ=function(e){if(null==e)return!0;if(tn(e)&&(tt(e)||"string"==typeof e||"function"==typeof e.splice||ts(e)||tg(e)||te(e)))return!e.length;var t=rh(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(e3(e))return!t6(e).length;for(var r in e)if(xX.call(e,r))return!1;return!0},x0=({notification:e})=>{let{description:t,action:r,kind:n,critical:o,title:a,onAction:i}=e;return(0,fd.jsx)(fv.ActionableNotification,{actionButtonLabel:r,kind:n||"info",lowContrast:o,subtitle:t,title:a||"",inline:!0,onActionButtonClick:i})},x1=({subject:e})=>{let[t,r]=(0,cu.useState)([]);return(0,cu.useEffect)(()=>{let t=e.subscribe(e=>r(t=>[...t.filter(t=>t.description!==e.description||t.action!==e.action||t.kind!==e.kind||t.title!==e.title),e]));return()=>t.unsubscribe()},[e]),(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsx)(x0,{notification:e},e.id))})},x2=({notification:e})=>{let{actionButtonLabel:t,onActionButtonClick:r=()=>{},subtitle:n,kind:o,title:a,critical:i,progressActionLabel:s,id:l,...u}=e,[c,d]=(0,cu.useState)(t);return(0,fd.jsx)(fv.ActionableNotification,{kind:o||"info",actionButtonLabel:c,ariaLabel:iK("closesActionableNotification","Closes actionable notification"),onActionButtonClick:()=>{r(),s&&d(s)},statusIconDescription:iK("actionableNotification","Actionable notification"),subtitle:n,title:a,lowContrast:i,inline:!0,...u})},x4=({subject:e})=>{let[t,r]=(0,cu.useState)([]);return(0,cu.useEffect)(()=>{let t=e.subscribe(e=>r(t=>[...t.filter(t=>t.subtitle!==e.subtitle||t.actionButtonLabel!==e.actionButtonLabel||t.onActionButtonClick!==e.onActionButtonClick||t.kind!==e.kind||t.title!==e.title),e]));return()=>t.unsubscribe()},[e]),(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsx)(x2,{notification:e},e.id))})};class x3{subscribe(e){return this.listeners.add(e),{unsubscribe:()=>{this.listeners.delete(e)}}}next(e){for(let t of[...this.listeners])t(e)}constructor(){!function(e,t,r){t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r}(this,"listeners",new Set)}}let x6=new x3,x5=0,x9=new x3,x8=0;function x7(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(x1,{subject:x6}))}function De(e){var t;e&&("string"==typeof(t=e.description)?t.trim().length>0:"object"==typeof t&&(t instanceof Error||!xQ(t)))?(e.description instanceof Error&&(e.description=e.description.toLocaleString()),setTimeout(()=>{x6.next({...e,id:x5++})},0)):console.error("showNotification must be called with an object having a 'description' property that is a non-empty string or object")}function Dt(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(x4,{subject:x9}))}function Dr(e){var t;e&&("string"==typeof(t=e.actionButtonLabel)?t.trim().length>0:"object"==typeof t&&!xQ(t))?setTimeout(()=>{x9.next({...e,id:x8++})},0):console.error("showActionableNotification must be called with an actionButtonLabel that is a non-empty string")}let Dn=["NORMAL","HIGH","CRITICALLY_HIGH","OFF_SCALE_HIGH","LOW","CRITICALLY_LOW","OFF_SCALE_LOW"],Do=["critically_low","critically_high","high","low","normal","off_scale_low","off_scale_high"],Da={container:"-esm-cohort-builder__numeric-observation-module__container___+Kqi9",card:"-esm-cohort-builder__numeric-observation-module__card___Q-ECG","abnormal-value":"-esm-cohort-builder__numeric-observation-module__abnormal-value___bx1h9","critical-value":"-esm-cohort-builder__numeric-observation-module__critical-value___nSKSX",cell:"-esm-cohort-builder__numeric-observation-module__cell___wc90e","critically-high":"-esm-cohort-builder__numeric-observation-module__critically-high___fmZfJ","critically-low":"-esm-cohort-builder__numeric-observation-module__critically-low___h9797",high:"-esm-cohort-builder__numeric-observation-module__high___0-YpP",low:"-esm-cohort-builder__numeric-observation-module__low___TuqAk","label-container":"-esm-cohort-builder__numeric-observation-module__label-container___FtozC","value-container":"-esm-cohort-builder__numeric-observation-module__value-container___R9qoY",label:"-esm-cohort-builder__numeric-observation-module__label___0DGA5",value:"-esm-cohort-builder__numeric-observation-module__value___ohqoh",units:"-esm-cohort-builder__numeric-observation-module__units___xvMd3","pad-right":"-esm-cohort-builder__numeric-observation-module__pad-right___umcen","off-scale-low":"-esm-cohort-builder__numeric-observation-module__off-scale-low___my+0i","off-scale-high":"-esm-cohort-builder__numeric-observation-module__off-scale-high___so9dv",arrow:"-esm-cohort-builder__numeric-observation-module__arrow___Agoh9"},Di=({value:e,unit:t,label:r,interpretation:n,referenceRange:o,conceptUuid:a,variant:i="card",patientUuid:s})=>{let l=(0,cu.useId)(),{referenceRange:u,isLoading:c}=function(e,t){let r=null;e&&(r=t?`${i6}/conceptreferencerange/?patient=${t}&concept=${e}&v=full`:`${i6}/conceptreferencerange/?concept=${e}&v=full`);let{data:n,error:o,isLoading:a}=dp()(r,i7),i=n?.data?.results?.[0];return{referenceRange:i?{hiNormal:i.hiNormal??null,hiAbsolute:i.hiAbsolute??null,hiCritical:i.hiCritical??null,lowNormal:i.lowNormal??null,lowAbsolute:i.lowAbsolute??null,lowCritical:i.lowCritical??null}:void 0,error:o,isLoading:a}}(o||n?void 0:a,s),d=o??u,f=(0,cu.useMemo)(()=>{if(n)return n?"--"===n?"normal":Dn.includes(n)?n.toLowerCase():Do.includes(n)?n:"normal":void 0;if(d&&!c){if(!d||null==e||""===e)return"normal";let t="string"==typeof e?Number.parseFloat(e):e;return Number.isNaN(t)?"normal":null!==d.hiAbsolute&&void 0!==d.hiAbsolute&&t>d.hiAbsolute?"off_scale_high":null!==d.hiCritical&&void 0!==d.hiCritical&&t>=d.hiCritical?"critically_high":null!==d.hiNormal&&void 0!==d.hiNormal&&t>d.hiNormal?"high":null!==d.lowAbsolute&&void 0!==d.lowAbsolute&&t<d.lowAbsolute?"off_scale_low":null!==d.lowCritical&&void 0!==d.lowCritical&&t<=d.lowCritical?"critically_low":null!==d.lowNormal&&void 0!==d.lowNormal&&t<d.lowNormal?"low":"normal"}return"normal"},[n,d,e,c])??"normal",p="critically_low"===f||"critically_high"===f||"off_scale_low"===f||"off_scale_high"===f,m="normal"!==f,h=r?`omrs-numeric-obs-label-${r.replaceAll(/\s+/g,"-").toLowerCase()}-${l}`:void 0,g=`omrs-numeric-obs-value-${l}`,y=`omrs-numeric-obs-unit-${l}`,v=null!=e&&""!==e,b=v?e:iK("notAvailable","Not available"),w=fp()({[Da["critically-low"]]:"critically_low"===f||"off_scale_low"===f,[Da["critically-high"]]:"critically_high"===f||"off_scale_high"===f,[Da.low]:"low"===f,[Da.high]:"high"===f,[Da["off-scale-low"]]:"off_scale_low"===f,[Da["off-scale-high"]]:"off_scale_high"===f}),E=fp()({[Da.container]:!0,[Da.card]:!0,[Da["critical-value"]]:p,[Da["abnormal-value"]]:m&&!p}),x=fp()({[Da.cell]:!0,[w]:!0});return"cell"===i?(0,fd.jsxs)("div",{className:x,children:[b,v&&t?` ${t}`:""]}):(0,fd.jsxs)("section",{className:E,"data-testid":"numeric-observation-card",children:[r&&(0,fd.jsxs)("div",{className:Da["label-container"],children:[(0,fd.jsx)("span",{id:h,className:Da.label,children:r}),m&&(0,fd.jsx)("span",{className:Da[f.replace("_","-")],title:iK("abnormalValue","Abnormal value")})]}),(0,fd.jsxs)("div",{className:Da["value-container"],children:[(0,fd.jsx)("span",{id:g,"aria-labelledby":h&&y?`${h} ${y}`:h||y||void 0,className:Da.value,children:b}),v&&t&&(0,fd.jsx)("span",{id:y,className:Da.units,children:t})]})]})},Ds="-esm-cohort-builder__page-header-module__pageHeader___XNJYe",Dl=e=>{if("children"in e){let{children:t,className:r,...n}=e;return(0,fd.jsx)("div",{className:fp()(Ds,r),...n,children:t})}{let{title:t,illustration:r,className:n,...o}=e;return(0,fd.jsx)("div",{className:fp()(Ds,n),...o,children:(0,fd.jsx)(Du,{title:t,illustration:r})})}},Du=({title:e,illustration:t,className:r})=>{let[n,o]=(0,cu.useState)(null);return(0,cu.useEffect)(()=>{nY("@openmrs/esm-styleguide").then(e=>{o(e)})},[]),(0,fd.jsxs)("div",{className:fp()("-esm-cohort-builder__page-header-module__pageHeaderContent___V-mTz",r),children:[t,(0,fd.jsxs)("div",{className:"-esm-cohort-builder__page-header-module__pageLabels___vGJvg",children:[n?.implementationName&&(0,fd.jsx)("p",{children:iK(n.implementationName)}),(0,fd.jsx)("p",{className:"-esm-cohort-builder__page-header-module__pageName___+eYMc",children:e})]})]})},Dc=({totalItems:e,pageSize:t,onPageNumberChange:r,pageNumber:n,dashboardLinkUrl:o,currentItems:a,dashboardLinkLabel:i})=>{let{pageSizes:s,pageItemsCount:l}=dK(t,e,n,a),u="tablet"===dI(),c=iK("paginationItemsCount","{{pageItemsCount}} / {{totalItems}} items",{totalItems:e,pageItemsCount:l});return(0,fd.jsx)(fd.Fragment,{children:e>0&&(0,fd.jsxs)("div",{className:fp()({"-esm-cohort-builder__pagination-module__tablet___DdaYk":u,"-esm-cohort-builder__pagination-module__desktop___rSwlo":!u}),children:[(0,fd.jsxs)("div",{children:[c,o&&(0,fd.jsx)(cf,{to:o,className:"-esm-cohort-builder__pagination-module__configurableLink___cTCLf",children:i??iK("seeAll","See all")})]}),(0,fd.jsx)(fv.Pagination,{className:"-esm-cohort-builder__pagination-module__pagination___U6anZ",page:n,pageSize:t,pageSizes:s,totalItems:e,onChange:r,pageRangeText:(e,t)=>iK("paginationOfPages","of {{count}} pages",{count:t}),size:u?"lg":"sm"})]})})};function Dd(e){return Dp(Dh(e,"usual","official"))}function Df(e){return Dd(e)}function Dp(e){var t;let r;return e?e.text??(r=(t=e).given??[],(t.family?r.concat(t.family):r).join(" ")):""}function Dm(e){return Dp(e)}function Dh(e,...t){for(let r of(0==t.length&&(t=["usual"]),t)){let t=e.name?.find(e=>{var t,n;return t=e,n=r,t.use?t.use===n:"usual"===n});if(t)return t}}function Dg(e,t=dQ()){let r=dQ(t),n=E0(e,r);if(null==n)return null;let o=r.diff(n,"hours"),a=r.diff(n,"days"),i=r.diff(n,"weeks"),s=r.diff(n,"months"),l=r.diff(n,"years"),u={};if(o<2)u.minutes=r.diff(n,"minutes");else if(a<2)u.hours=o;else if(i<4)u.days=a;else if(l<1){let e=r.subtract(i,"weeks").diff(n,"days");u.weeks=i,u.days=e}else if(l<2){let e=r.subtract(s,"months").diff(n,"days");u.months=s,u.days=e}else if(l<18){let e=r.subtract(l,"year").diff(n,"months");u.years=l,u.months=e}else u.years=l;return u}function Dy(e,t=dQ()){let r=Dg(e,t);if(null==r)return null;let n={style:"short",localeMatcher:"lookup"};return"minutes"in r&&0===r.minutes&&(n.minutesDisplay="always"),EQ(r,n)}let Dv={container:"-esm-cohort-builder__patient-banner-patient-info-module__container___WV40g",activePatientContainer:"-esm-cohort-builder__patient-banner-patient-info-module__activePatientContainer___YBgYK",patientBanner:"-esm-cohort-builder__patient-banner-patient-info-module__patientBanner___o-DQc",patientName:"-esm-cohort-builder__patient-banner-patient-info-module__patientName___KWLAJ",patientAvatar:"-esm-cohort-builder__patient-banner-patient-info-module__patientAvatar___gG4I3",patientAvatarButton:"-esm-cohort-builder__patient-banner-patient-info-module__patientAvatarButton___by4L9",patientInfo:"-esm-cohort-builder__patient-banner-patient-info-module__patientInfo___VU1fL",demographics:"-esm-cohort-builder__patient-banner-patient-info-module__demographics___xDHsd",row:"-esm-cohort-builder__patient-banner-patient-info-module__row___MlVwp",flexRow:"-esm-cohort-builder__patient-banner-patient-info-module__flexRow___9Aj3s",tagsSlot:"-esm-cohort-builder__patient-banner-patient-info-module__tagsSlot___PqCHJ",identifiers:"-esm-cohort-builder__patient-banner-patient-info-module__identifiers___bbREn",identifier:"-esm-cohort-builder__patient-banner-patient-info-module__identifier___HQzz8",primaryIdentifier:"-esm-cohort-builder__patient-banner-patient-info-module__primaryIdentifier___ocKCs",secondaryIdentifier:"-esm-cohort-builder__patient-banner-patient-info-module__secondaryIdentifier___4MLDH",value:"-esm-cohort-builder__patient-banner-patient-info-module__value___tkQTC",tag:"-esm-cohort-builder__patient-banner-patient-info-module__tag___u7Kco",gender:"-esm-cohort-builder__patient-banner-patient-info-module__gender___7eQuO",separator:"-esm-cohort-builder__patient-banner-patient-info-module__separator___CZBA8",tooltipPadding:"-esm-cohort-builder__patient-banner-patient-info-module__tooltipPadding___UQr5s",tooltipSmallText:"-esm-cohort-builder__patient-banner-patient-info-module__tooltipSmallText___MRUhY",actionsButtonText:"-esm-cohort-builder__patient-banner-patient-info-module__actionsButtonText___8ZC1R"};function Db({showIdentifierLabel:e,type:t,value:r}){return(0,fd.jsx)("span",{className:Dv.primaryIdentifier,children:(0,fd.jsxs)(fv.Tag,{className:Dv.tag,type:"gray",children:[e&&t?.text&&(0,fd.jsxs)("span",{className:Dv.label,children:[t.text,": "]}),(0,fd.jsx)("span",{className:Dv.value,children:r})]})})}function Dw({showIdentifierLabel:e,type:t,value:r}){return(0,fd.jsxs)(fv.FormLabel,{className:Dv.secondaryIdentifier,id:`patient-banner-identifier-${r}`,children:[e&&(0,fd.jsxs)("span",{className:Dv.label,children:[t?.text,": "]}),(0,fd.jsx)("span",{className:Dv.value,children:r})]})}function DE({identifiers:e,showIdentifierLabel:t}){let{excludePatientIdentifierCodeTypes:r}=du(),{primaryIdentifierCode:n}=dY(),o=e?.filter(e=>{let t=e.type?.coding?.[0]?.code;return t&&!r?.uuids.includes(t)})??[];return(0,fd.jsx)(fd.Fragment,{children:o?.length?o.map(({value:e,type:r},a)=>(0,fd.jsxs)(cc().Fragment,{children:[(0,fd.jsx)("span",{className:Dv.identifier,children:r?.coding?.[0]?.code===n?(0,fd.jsx)(Db,{showIdentifierLabel:t,type:r,value:e}):(0,fd.jsx)(Dw,{showIdentifierLabel:t,type:r,value:e})}),a<o.length-1&&(0,fd.jsx)("span",{className:Dv.separator,children:"\xb7"})]},e)):""})}let Dx={Female:pc,Male:pd,Other:pf,Unknown:pp},DD=({gender:e})=>{let t=Dx[e];return t?(0,fd.jsx)(t,{fill:"#525252"}):null},D_={male:"Male",female:"Female",other:"Other",unknown:"Unknown"};function DS({patient:e,renderedFrom:t}){var r;let n,o,a=Dd(e),i=e?.gender&&(o=D_[n=(r=e.gender).toLowerCase()]??"Unknown",{displayText:iK(n,r),iconKey:o}),s=(0,cu.useMemo)(()=>({patientUuid:e.id,patient:e,renderedFrom:t}),[e.id,e,t]);return(0,fd.jsxs)("div",{className:Dv.patientInfo,children:[(0,fd.jsx)("div",{className:fp()(Dv.row,Dv.patientNameRow),children:(0,fd.jsxs)("div",{className:Dv.flexRow,children:[(0,fd.jsx)("span",{className:Dv.patientName,children:a}),i&&(0,fd.jsxs)("div",{className:Dv.gender,children:[(0,fd.jsx)(DD,{gender:i.iconKey}),(0,fd.jsx)("span",{children:i.displayText})]}),(0,fd.jsx)(ck,{className:Dv.tagsSlot,name:"patient-banner-tags-slot",state:s})]})}),(0,fd.jsxs)("div",{className:Dv.demographics,children:[e.birthDate&&(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("span",{children:Dy(e.birthDate)}),(0,fd.jsx)("span",{className:Dv.separator,children:"\xb7"}),(0,fd.jsx)("span",{children:EG(e.birthDate,{time:!1})}),(0,fd.jsx)("span",{className:Dv.separator,children:"\xb7"})]}),(0,fd.jsx)(DE,{identifiers:e.identifier,showIdentifierLabel:!0}),(0,fd.jsx)(ck,{className:Dv.extensionSlot,name:"patient-banner-bottom-slot",state:s})]})]})}var DC=r(1673);function Dk({patient:e,patientUuid:t,actionsSlotName:r,additionalActionsSlotState:n}){let[o,a]=(0,cu.useState)(!1),{extensions:i}=cS(r),s="tablet"===dI(),l=dV(()=>a(!1),o),u=(0,cu.useRef)(null),c=(0,cu.useRef)(null),d=(0,cu.useId)(),f=`patient-actions-menu-trigger-${d}`,p=`patient-actions-menu-${d}`,m=(0,cu.useCallback)(()=>a(e=>!e),[]),h=(0,cu.useCallback)(()=>{a(!1),u.current?.focus()},[]),g=(0,cu.useCallback)(e=>{if("Escape"===e.key&&o){e.stopPropagation(),h();return}if(("ArrowDown"===e.key||"ArrowUp"===e.key)&&o){e.preventDefault();let t=c.current?.querySelectorAll('[role="menuitem"]:not([disabled])');if(!t?.length)return;let r=document.activeElement?.closest?.('[role="menuitem"]')??document.activeElement,n=Array.from(t).indexOf(r);if(-1===n)return void t["ArrowDown"===e.key?0:t.length-1]?.focus();let o=n+("ArrowDown"===e.key?1:-1),a=o<0?t.length-1:o>=t.length?0:o;t[a]?.focus()}},[h,o]);(0,cu.useEffect)(()=>{if(o&&c.current){let e=c.current.querySelector('[role="menuitem"]:not([disabled])');e?.focus()}},[o]);let y=(0,cu.useMemo)(()=>({patientUuid:t,patient:e,closeMenu:h,...n}),[t,e,h,n]);return 0===i.length?null:(0,fd.jsx)("div",{className:"-esm-cohort-builder__patient-banner-actions-menu-module__overflowMenuContainer___7eCLh",children:(0,fd.jsxs)("div",{"data-overflow-menu":!0,className:fp()("cds--overflow-menu",fE),ref:l,children:[(0,fd.jsxs)("button",{className:fp()("cds--btn","cds--btn--ghost","cds--overflow-menu__trigger",{"cds--overflow-menu--open":o},f_),"aria-controls":p,"aria-expanded":o,"aria-haspopup":"true",id:f,onClick:m,onKeyDown:g,ref:u,children:[(0,fd.jsx)("span",{className:"-esm-cohort-builder__patient-banner-actions-menu-module__actionsButtonText___TbM5a",children:iK("actions","Actions")})," ",(0,fd.jsx)(DC.CH,{size:16,style:{marginLeft:"0.5rem",fill:"#78A9FF"}})]}),(0,fd.jsxs)("div",{className:fp()("cds--overflow-menu-options","cds--overflow-menu--flip",fx,{[fD]:o}),"aria-labelledby":f,"data-floating-menu-direction":"bottom",id:p,onKeyDown:g,ref:c,role:"menu",tabIndex:-1,children:[(0,fd.jsx)("ul",{className:fp()("cds--overflow-menu-options__content",{"cds--overflow-menu-options--lg":s}),children:(0,fd.jsx)(ck,{name:r,state:y},r)}),(0,fd.jsx)("span",{})]})]})})}var DP=r(6767),DO=r.n(DP);function DR(e){let{patientPhotoConceptUuid:t}=du({externalModuleName:"@openmrs/esm-styleguide"}),r=t?`${i6}/obs?patient=${e}&concept=${t}&v=full`:null,{data:n,error:o,isLoading:a}=cH()(e?r:null,i7),i=n?.data?.results[0];return{data:i?{dateTime:i?.obsDatetime,imageSrc:i?.value?.links?.uri}:null,error:o,isLoading:a}}let DT=({width:e=56,height:t=56,"aria-label":r})=>{let{t:n}=(0,cV.useTranslation)();return(0,fd.jsxs)("svg",{"aria-label":r??n("patientPhotoPlaceholder","Patient photo placeholder"),width:e,height:t,fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,fd.jsx)("path",{fill:"#ffffff",d:"M0 0h56v56H0z"}),(0,fd.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"})]})},DN="-esm-cohort-builder__patient-photo-module__avatar___R93LX";function Dj({patientUuid:e,patientName:t,alt:r}){let{data:n,isLoading:o}=DR(e),[a,i]=(0,cu.useState)(null),[s,l]=(0,cu.useState)(!1),u=(0,cu.useMemo)(()=>DO().generate(e),[e]);(0,cu.useEffect)(()=>{if(n?.imageSrc){let e=new URL(n.imageSrc,window.location.origin).pathname;l(!0);let t=!1,r=new Image;return r.onload=()=>{t||(i(e),l(!1))},r.onerror=()=>{t||(i(null),l(!1))},r.src=e,()=>{t=!0}}i(null),l(!1)},[n?.imageSrc]);let c=(0,cu.useMemo)(()=>r||(a?iK("patientPhotoAlt","Profile photo of {{patientName}}",{patientName:t}):iK("patientAvatarAlt","Avatar for {{patientName}}",{patientName:t})),[r,a,t]);return o||s?(0,fd.jsx)(fv.SkeletonIcon,{className:"-esm-cohort-builder__patient-photo-module__skeleton___I-6iq","data-testid":"skeleton-icon"}):n?.imageSrc&&!a?(0,fd.jsx)(DT,{"aria-label":iK("patientPhotoPlaceholder","Photo placeholder for {{patientName}}",{patientName:t})}):a?(0,fd.jsx)("div",{"aria-label":c,children:(0,fd.jsx)("img",{className:DN,src:a,alt:c,title:t})}):(0,fd.jsx)("div",{"aria-label":c,children:(0,fd.jsx)("div",{className:DN,title:t,style:{backgroundImage:u.toDataUrl(),backgroundRepeat:"no-repeat",backgroundSize:"cover"},children:(0,fd.jsx)("span",{className:"-esm-cohort-builder__patient-photo-module__initials___JnUBD",children:function(e,t=3){return e.split(/\s+/).filter(Boolean).slice(0,t).map(e=>e[0]).join("")}(t)})})})}let DA=["omrs-pict-appointments","omrs-pict-assessment-1","omrs-pict-assessment-2","omrs-pict-blood-bank","omrs-pict-cardiology","omrs-pict-cohorts","omrs-pict-concept-dictionary","omrs-pict-ct-scan","omrs-pict-data-entry","omrs-pict-dentistry","omrs-pict-digital-trust","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-metadata-export","omrs-pict-obstetrics","omrs-pict-patient-documents","omrs-pict-patient-search","omrs-pict-patients","omrs-pict-payments-desk","omrs-pict-pharmacy","omrs-pict-pharmacy-2","omrs-pict-registration","omrs-pict-reports","omrs-pict-service-queues","omrs-pict-stock-management","omrs-pict-transfer","omrs-pict-triage","omrs-pict-x-ray"],D$=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-appointments",pictogramProps:e})})),DI=D$,DM=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-assessment-1",pictogramProps:e})})),DL=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-assessment-2",pictogramProps:e})})),DF=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-blood-bank",pictogramProps:e})})),DB=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-cardiology",pictogramProps:e})})),DU=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-cohorts",pictogramProps:e})})),DV=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-concept-dictionary",pictogramProps:e})})),DW=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-ct-scan",pictogramProps:e})})),DH=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-data-entry",pictogramProps:e})})),Dz=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-dentistry",pictogramProps:e})})),DK=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-digital-trust",pictogramProps:e})})),DG=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-emergency-department",pictogramProps:e})})),DZ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-facility",pictogramProps:e})})),DY=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-geriatrics",pictogramProps:e})})),Dq=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-gynaecology",pictogramProps:e})})),DJ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-in-patient",pictogramProps:e})})),DX=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-laboratory",pictogramProps:e})})),DQ=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-labs-2",pictogramProps:e})})),D0=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-metadata-export",pictogramProps:e})})),D1=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-obstetrics",pictogramProps:e})})),D2=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-patient-documents",pictogramProps:e})})),D4=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-patient-search",pictogramProps:e})})),D3=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-patients",pictogramProps:e})})),D6=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-payments-desk",pictogramProps:e})})),D5=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-pharmacy",pictogramProps:e})})),D9=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-pharmacy-2",pictogramProps:e})})),D8=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-registration",pictogramProps:e})})),D7=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-reports",pictogramProps:e})})),_e=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-service-queues",pictogramProps:e})})),_t=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-stock-management",pictogramProps:e})})),_r=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-transfer",pictogramProps:e})})),_n=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-triage",pictogramProps:e})})),_o=(0,cu.memo)((0,cu.forwardRef)(function(e,t){return(0,fd.jsx)(_l,{ref:t,pictogram:"omrs-pict-x-ray",pictogramProps:e})})),_a=DZ,_i=D3,_s=(0,cu.memo)((0,cu.forwardRef)(function({pictogram:e,fallback:t,...r},n){let o=(0,cu.useRef)(document.getElementById(e));return(0,cu.useEffect)(()=>{let t=document.getElementById("omrs-svgs-container"),r=new MutationObserver(t=>{for(let r of t)"childList"===r.type&&(o.current=document.getElementById(e))});return t&&r.observe(t,{childList:!0}),()=>r.disconnect()},[e]),(0,fd.jsx)(c8,{value:o.current,fallback:t,children:(0,fd.jsx)(_l,{ref:n,pictogram:e,pictogramProps:r})})})),_l=(0,cu.memo)((0,cu.forwardRef)(function({pictogram:e,pictogramProps:t},r){let{className:n,size:o}=Object.assign({},{size:92},t);return(o<=26||o>144)&&(console.error(`Invalid size '${o}' specified for ${e}. Defaulting to 92.`),o=92),(0,fd.jsx)("svg",{ref:r,className:fp()("-esm-cohort-builder__pictograms-module__pictogram___LTPzD",n),height:o,width:o,children:(0,fd.jsx)("use",{href:`#${e}`})})})),_u=({children:e})=>"tablet"===dI()?(0,fd.jsx)(fv.Layer,{children:e}):(0,fd.jsx)(fd.Fragment,{children:e}),_c=({snackbar:e,closeSnackbar:t})=>{let{actionButtonLabel:r="",kind:n="success",onActionButtonClick:o=()=>{},isLowContrast:a="error"!==n,progressActionLabel:i,subtitle:s="",timeoutInMs:l=5e3,autoClose:u="error"!==n,title:c,id:d,...f}=e,[p,m]=(0,cu.useState)(r),[h,g]=(0,cu.useState)(!0),[y,v]=(0,cu.useState)(!1),b=(0,cu.useCallback)(()=>{setTimeout(t,250)},[t]),w=(0,cu.useCallback)(()=>{v(!0),b()},[b]);return(0,cu.useEffect)(()=>{if(u){let e=setTimeout(w,l);return()=>clearTimeout(e)}},[l,u,w]),(0,cu.useEffect)(()=>{g(!1),window.setTimeout(()=>{g(!0)},0)},[]),(0,fd.jsx)(fv.ActionableNotification,{actionButtonLabel:p,"aria-label":iK("closeSnackbar","Close snackbar"),className:fp()("-esm-cohort-builder__snackbar-module__slideIn___TqSN-",{"-esm-cohort-builder__snackbar-module__animated___+XPKT":h,"-esm-cohort-builder__snackbar-module__slideOut___1cFIY":y}),kind:n,lowContrast:a,onActionButtonClick:()=>{o(),w(),i&&m(i)},onClose:b,statusIconDescription:iK("snackbarNotification","Snackbar notification"),subtitle:s,title:c,...f})},_d=({subject:e})=>{let[t,r]=(0,cu.useState)([]),n=(0,cu.useCallback)(e=>{r(t=>t.filter(t=>t!==e))},[]);return(0,cu.useEffect)(()=>{let t=e.subscribe(e=>r(t=>[...t.filter(t=>t.subtitle!==e.subtitle||t.actionButtonLabel!==e.actionButtonLabel||t.onActionButtonClick!==e.onActionButtonClick||t.kind!==e.kind||t.title!==e.title),e]));return()=>t.unsubscribe()},[e]),(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsx)(_c,{snackbar:e,closeSnackbar:()=>n(e)},e.id))})},_f=new x3,_p=0;function _m(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(_d,{subject:_f}))}function _h(e){var t;e&&"string"==typeof(t=e.title)&&t.trim().length>0?setTimeout(()=>{_f.next({...e,id:_p++})},0):console.error("showSnackbar must be called with an object having a 'title' property that is a non-empty string")}let _g=({toast:e,closeToast:t})=>{let{description:r,kind:n,critical:o,title:a,actionButtonLabel:i,onActionButtonClick:s=()=>{}}=e,l=(0,cu.useCallback)(()=>{s(),t()},[t,s]);return(0,fd.jsx)("div",{children:(0,fd.jsx)(fv.ActionableNotification,{actionButtonLabel:i,kind:n||"info",lowContrast:o,subtitle:r,title:a||"",onActionButtonClick:l,onClose:t})})},_y=({subject:e})=>{let[t,r]=(0,cu.useState)([]),n=(0,cu.useCallback)(e=>{r(t=>t.filter(t=>t!==e))},[]);return(0,cu.useEffect)(()=>{let t=e.subscribe(e=>r(t=>[...t.filter(t=>t.description!==e.description||t.kind!==e.kind||t.title!==e.title||t.actionButtonLabel!==e.actionButtonLabel||t.onActionButtonClick!==e.onActionButtonClick),e]));return()=>t.unsubscribe()},[e]),(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsx)(_g,{toast:e,closeToast:()=>n(e)},e.id))})},_v=new x3,_b=0;function _w(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(_y,{subject:_v}))}function _E(e){var t;e&&("string"==typeof(t=e.description)?t.trim().length>0:"object"==typeof t&&!xQ(t))?setTimeout(()=>{_v.next({...e,id:_b++})},0):console.error("showToast must be called with an object having a 'description' property that is a non-empty string or object")}var _x=r(4535),_D=r(771);let __="u">typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),_S=new Uint8Array(16),_C=[];for(let e=0;e<256;++e)_C.push((e+256).toString(16).slice(1));let _k=function(e,t,r){if(__&&!t&&!e)return __();let n=(e=e||{}).random??e.rng?.()??function(){if(!d){if("u"<typeof crypto||!crypto.getRandomValues)throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");d=crypto.getRandomValues.bind(crypto)}return d(_S)}();if(n.length<16)throw Error("Random bytes length must be >= 16");if(n[6]=15&n[6]|64,n[8]=63&n[8]|128,t){if((r=r||0)<0||r+16>t.length)throw RangeError(`UUID byte range ${r}:${r+15} is out of buffer bounds`);for(let e=0;e<16;++e)t[r+e]=n[e];return t}return function(e,t=0){return(_C[e[t+0]]+_C[e[t+1]]+_C[e[t+2]]+_C[e[t+3]]+"-"+_C[e[t+4]]+_C[e[t+5]]+"-"+_C[e[t+6]]+_C[e[t+7]]+"-"+_C[e[t+8]]+_C[e[t+9]]+"-"+_C[e[t+10]]+_C[e[t+11]]+_C[e[t+12]]+_C[e[t+13]]+_C[e[t+14]]+_C[e[t+15]]).toLowerCase()}(n)};async function _P(e,t){let{openedGroup:r}=u3.getState();if(r){if(r.groupName===e&&_T(r.props,t))return!0;else if(!await _N({reason:"CLOSE_WORKSPACE_GROUP",explicit:!1}))return!1}return u3.setState(r=>({...r,openedGroup:{groupName:e,props:t},openedWindows:[]})),!0}async function _O(e){let{openedGroup:t,openedWindows:r}=u3.getState();if(t){if(r.length>0&&!(e||await _N({reason:"CLOSE_WORKSPACE_GROUP",explicit:!0})))return!1;u3.setState(e=>({...e,openedGroup:null,openedWindows:[]}))}return!0}async function _R(e,t=null,r=null,n=null){let o=u3.getState();if(!o.registeredWorkspacesByName[e])throw Error(`Unable to launch workspace ${e}. Workspace is not registered`);let a=u6(e);if(!a)throw Error(`Unable to launch workspace ${e}. Workspace is not registered to a workspace window`);let{openedGroup:i}=o,{name:s}=a,l=u5(s);if(!l)throw Error(`Unable to launch workspace ${e}. Workspace window ${a.name} is not registered to a workspace group`);let u=u9(e);if(i&&(i.groupName!==l.name||!_T(i.props,n)))return!!await _N({reason:"CLOSE_WORKSPACE_GROUP",explicit:!0})&&(u3.setState({...o,openedGroup:{groupName:l.name,props:n},openedWindows:[{windowName:s,openedWorkspaces:[_M(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0);if(u>=0){let n=o.openedWindows[u],a=o.openedGroup?.props??{},i=o.isMostRecentlyOpenedWindowHidden,{openedWorkspaces:c}=n;if(_T(n.props,r)){let d=c.find(t=>t.workspaceName===e);return d&&_T(d.props,t)?((i||u!==o.openedWindows.length-1)&&u3.setState(_j.restoreWindow(o,s)),!0):!!await _N({reason:"CLOSE_WORKSPACE",explicit:!1,windowName:s,workspaceName:e})&&(u3.setState({...o,openedGroup:{groupName:l.name,props:o?.openedGroup?.props??a},openedWindows:[...o.openedWindows.filter((e,t)=>t!==u),{windowName:s,openedWorkspaces:[_M(e,t)],props:n?.props??r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0)}return!!await _N({reason:"CLOSE_WINDOW",explicit:!1,windowName:s})&&(u3.setState({...o,openedGroup:{groupName:l.name,props:a??o?.openedGroup?.props},openedWindows:[...o.openedWindows.filter((e,t)=>t!==u),{windowName:s,openedWorkspaces:[_M(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0)}return"closable"!=l.persistence?(u3.setState({...o,openedGroup:{groupName:l.name,props:n??o?.openedGroup?.props??null},openedWindows:[...o.openedWindows,{windowName:s,openedWorkspaces:[_M(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0):!!await _N({reason:"CLOSE_OTHER_WINDOWS",explicit:!1,windowNameToSpare:a.name})&&(u3.setState({...o,openedGroup:{groupName:l.name,props:n??o?.openedGroup?.props??null},openedWindows:[{windowName:s,openedWorkspaces:[_M(e,t)],props:r,maximized:!1}],isMostRecentlyOpenedWindowHidden:!1}),!0)}function _T(e,t){return null==e||null==t||R(e,t)}function _N(e){function t(e,t){let r=[];for(let n=e.openedWorkspaces.length-1;n>=0;n--){let o=e.openedWorkspaces[n];if(o.hasUnsavedChanges&&r.push(o),t&&o.workspaceName===t)break}return r}let{openedWindows:r,workspaceTitleByWorkspaceName:n}=u3.getState(),o=[];switch(e.reason){case"CLOSE_WORKSPACE_GROUP":o=r.flatMap(e=>t(e));break;case"CLOSE_WINDOW":{let n=r.find(t=>t.windowName===e.windowName);if(!n)throw Error(`Window ${e.windowName} not found in opened windows.`);o=t(n);break}case"CLOSE_WORKSPACE":{let n=r.find(t=>t.windowName===e.windowName);if(!n)throw Error(`Window ${e.windowName} not found in opened windows.`);o=t(n,e.workspaceName);break}case"CLOSE_OTHER_WINDOWS":o=r.filter(t=>t.windowName!==e.windowNameToSpare).flatMap(e=>t(e))}return 0===o.length?Promise.resolve(!0):new Promise(e=>{let t=xJ("workspace2-close-prompt",{size:"sm",onConfirm:()=>{t(),e(!0)},onCancel:()=>{t(),e(!1)},affectedWorkspaceTitles:o.map(e=>n[e.workspaceName])})})}let _j={setWindowMaximized(e,t,r){let n=e.openedWindows.findIndex(e=>e.windowName===t),o=[...e.openedWindows],a={...o[n],maximized:r};return o[n]=a,{...e,openedWindows:o}},hideWindow:e=>({...e,isMostRecentlyOpenedWindowHidden:!0}),restoreWindow(e,t){let r=e.openedWindows.findIndex(e=>e.windowName===t),n=e.openedWindows[r],o=[...e.openedWindows.filter((e,t)=>t!==r),n];return{...e,openedWindows:o,isMostRecentlyOpenedWindowHidden:!1}},closeWorkspace(e,t){let r=u9(t);if(r<0)return e;let n={...e.openedWindows[r]},o=n.openedWorkspaces.findIndex(e=>e.workspaceName===t),a=[...e.openedWindows];n.openedWorkspaces=n.openedWorkspaces.slice(0,o);let i=e.isMostRecentlyOpenedWindowHidden;if(0===n.openedWorkspaces.length){let t=r===e.openedWindows.length-1;a.splice(r,1),t&&a.length>0&&(i=!1)}else a[r]=n;return{...e,openedWindows:a,isMostRecentlyOpenedWindowHidden:i}},openChildWorkspace(e,t,r,n){let o=e.registeredWorkspacesByName[r];if(!o)throw Error(`No workspace named "${r}" registered`);let a=e.registeredWorkspacesByName[t];if(!a)throw Error(`No workspace named "${t}" registered`);if(a.window!==o.window)throw Error(`Child workspace ${r} does not belong to the same workspace window as parent workspace ${t}`);let i=e.openedWindows.findIndex(e=>e.windowName===o.window);if(-1==i)throw Error(`Cannot open child workspace ${r} as window ${o.window} is not opened`);let{openedWorkspaces:s}=e.openedWindows[i],l=s.findIndex(e=>e.workspaceName===t);if(-1===l)throw Error(`Cannot open child workspace ${r} from parent workspace ${t} as the parent is not opened within the workspace window`);let u=s.slice(0,l+1);return{openedWindows:e.openedWindows.map((e,t)=>t==i?{...e,openedWorkspaces:[...u,_M(r,n)]}:e)}},setHasUnsavedChanges(e,t,r){let n=u9(t);if(n<0)return e;let o={...e.openedWindows[n]},a=o.openedWorkspaces.findIndex(e=>e.workspaceName===t);if(a<0)return e;o.openedWorkspaces[a]={...o.openedWorkspaces[a],hasUnsavedChanges:r};let i=[...e.openedWindows];return i[n]=o,{...e,openedWindows:i}},setWorkspaceTitle(e,t,r){let n={...e.workspaceTitleByWorkspaceName};return null===r?delete n[t]:n[t]=r,{...e,workspaceTitleByWorkspaceName:n}}};function _A(){return cv(u3,_j)}let _$=()=>(0,cu.useContext)(cA),_I=()=>Object.keys(u3.getState().registeredWorkspacesByName);function _M(e,t){return{workspaceName:e,props:t??{},hasUnsavedChanges:!1,uuid:_k()}}let _L={workspaceOuterContainer:"-esm-cohort-builder__workspace2-module__workspaceOuterContainer___DLiCR",narrowWorkspace:"-esm-cohort-builder__workspace2-module__narrowWorkspace___VL0kF",widerWorkspace:"-esm-cohort-builder__workspace2-module__widerWorkspace___3QgrA",extraWideWorkspace:"-esm-cohort-builder__workspace2-module__extraWideWorkspace___s7nnh",workspaceMiddleContainer:"-esm-cohort-builder__workspace2-module__workspaceMiddleContainer___mTGNN",maximized:"-esm-cohort-builder__workspace2-module__maximized___-yo9l",hidden:"-esm-cohort-builder__workspace2-module__hidden___K2ryM",workspaceInnerContainer:"-esm-cohort-builder__workspace2-module__workspaceInnerContainer___o3zVl",workspaceSpacer:"-esm-cohort-builder__workspace2-module__workspaceSpacer___N6-ox",loader:"-esm-cohort-builder__workspace2-module__loader___29hpw",hiddenExtraWorkspace:"-esm-cohort-builder__workspace2-module__hiddenExtraWorkspace___-W7TY",header:"-esm-cohort-builder__workspace2-module__header___p0kuD",headerButtons:"-esm-cohort-builder__workspace2-module__headerButtons___hMydG",workspaceContent:"-esm-cohort-builder__workspace2-module__workspaceContent___uROr7",overlayHeaderSpacer:"-esm-cohort-builder__workspace2-module__overlayHeaderSpacer___zdrhx",isActionMenuOpened:"-esm-cohort-builder__workspace2-module__isActionMenuOpened___Wc1Il",showActionMenu:"-esm-cohort-builder__workspace2-module__showActionMenu___qCVQ-",marginWorkspaceContent:"-esm-cohort-builder__workspace2-module__marginWorkspaceContent___A+20C",workspaceContainerWithActionMenu:"-esm-cohort-builder__workspace2-module__workspaceContainerWithActionMenu___S98dq",workspaceFixedContainer:"-esm-cohort-builder__workspace2-module__workspaceFixedContainer___c9Uny",workspaceContainerWithoutActionMenu:"-esm-cohort-builder__workspace2-module__workspaceContainerWithoutActionMenu___u8FbT"},_F=({title:e,children:t,hasUnsavedChanges:r=!1})=>{let n=dI(),{setWindowMaximized:o,hideWindow:a,setHasUnsavedChanges:i,openedWindows:s,openedGroup:l,registeredGroupsByName:u,registeredWindowsByName:c,registeredWorkspacesByName:d,workspaceTitleByWorkspaceName:f,setWorkspaceTitle:p,isMostRecentlyOpenedWindowHidden:m}=_A(),{workspaceName:h,isRootWorkspace:g,closeWorkspace:y,showActionMenu:v}=_$(),b=u9(h),w=s[b],E=w?.openedWorkspaces.find(e=>e.workspaceName===h);if((0,cu.useEffect)(()=>{E?.hasUnsavedChanges!=r&&i(h,r??!1)},[E?.hasUnsavedChanges,r,h,i]),(0,cu.useEffect)(()=>{f[h]!==e&&p(h,e)},[f,h,e,p]),b<0||null==l||null==E)return null;let x=u[l.groupName];if(!x)throw Error(`Cannot find registered workspace group ${l.groupName}`);let D=d[h].window,_=c[D];if(!_)throw Error(`Cannot find registered workspace window ${D}`);let{icon:S,canMaximize:C}=_,k="closable"===x.persistence,P=!!S&&!k,{maximized:O}=w,R=_?.width??"narrow",T=Object.values(c).some(e=>e.group===l.groupName&&void 0!==e.icon),N=b<s.length-1||m;return(0,fd.jsxs)("div",{className:fp()(_L.workspaceOuterContainer,{[_L.narrowWorkspace]:"narrow"===R,[_L.widerWorkspace]:"wider"===R,[_L.extraWideWorkspace]:"extra-wide"===R,[_L.isActionMenuOpened]:T}),children:[(0,fd.jsx)("div",{className:fp()(_L.workspaceSpacer,{[_L.hidden]:N})}),(0,fd.jsx)("div",{className:fp()(_L.workspaceMiddleContainer,{[_L.maximized]:O,[_L.hidden]:N,[_L.isRootWorkspace]:g,[_L.showActionMenu]:v}),children:(0,fd.jsxs)("div",{className:fp()(_L.workspaceInnerContainer,{[_L.maximized]:O,[_L.hidden]:N,[_L.isRootWorkspace]:g}),children:[(0,fd.jsxs)(fv.Header,{"aria-label":iK("workspaceHeader"),className:_L.header,children:[(0,fd.jsx)(fv.HeaderName,{prefix:"",children:e}),(0,fd.jsx)("div",{className:_L.overlayHeaderSpacer}),(0,fd.jsx)(fv.HeaderGlobalBar,{className:_L.headerButtons,children:dM(n)?(0,fd.jsxs)(fd.Fragment,{children:[(C||O)&&(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":O?iK("minimize"):iK("maximize"),onClick:()=>o(D,!O),children:O?(0,fd.jsx)(_x.Xj,{}):(0,fd.jsx)(_x.hz,{})}),P&&(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":iK("hide"),onClick:()=>a(),children:(0,fd.jsx)(fK,{})}),!k&&(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":iK("close"),onClick:()=>y({closeWindow:!0}),children:(0,fd.jsx)(pe,{})})]}):(0,fd.jsxs)(fd.Fragment,{children:[P&&(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":iK("hide"),onClick:()=>a(),children:(0,fd.jsx)(_D.d3,{})}),(0,fd.jsx)(fv.HeaderGlobalAction,{"aria-label":iK("close"),onClick:()=>{k?_O():y({closeWindow:!0})},children:(0,fd.jsx)(pe,{})})]})})]}),(0,fd.jsx)("div",{className:fp()(_L.workspaceContent),children:t})]})})]})},_B="-esm-cohort-builder__action-menu-button2-module__container___gYRoa",_U="-esm-cohort-builder__action-menu-button2-module__elementContainer___vBViO",_V="-esm-cohort-builder__action-menu-button2-module__active___uRJRA",_W="-esm-cohort-builder__action-menu-button2-module__focused___D4VYB";function _H({getIcon:e,hasUnsavedChanges:t,tagContent:r}){return(0,fd.jsxs)(fd.Fragment,{children:[e({size:16}),t?(0,fd.jsx)("span",{className:"-esm-cohort-builder__action-menu-button2-module__interruptedTag___35fO7",children:"!"}):(0,fd.jsx)("span",{className:"-esm-cohort-builder__action-menu-button2-module__countTag___l8lfc",children:r})]})}let _z=({icon:e,label:t,tagContent:r,workspaceToLaunch:n,onBeforeWorkspaceLaunch:o})=>{let a=dI(),{openedWindows:i,restoreWindow:s,hideWindow:l,isMostRecentlyOpenedWindowHidden:u}=_A(),{extension:c}=(0,cu.useContext)(cd),d=i.findIndex(e=>e.windowName===c?.extensionId),f=i[d],p=null!=f,m=p&&(d<i.length-1||u),h=p&&!m,g=f?.openedWorkspaces.some(e=>e.hasUnsavedChanges)??!1,y=async()=>{if(p)m?s(f.windowName):l();else if(await (o?.()??!0)){let{workspaceName:e,workspaceProps:t,windowProps:r}=n;_R(e,t,r)}};return"tablet"===a||"phone"===a?(0,fd.jsxs)(fv.Button,{className:fp()(_B,{[_V]:p&&!h,[_W]:h}),iconDescription:t,kind:"ghost",onClick:y,role:"button",tabIndex:0,size:"md",children:[(0,fd.jsx)("span",{className:_U,children:(0,fd.jsx)(_H,{hasUnsavedChanges:g,getIcon:e,tagContent:r})}),(0,fd.jsx)("span",{children:t})]}):(0,fd.jsx)(fv.IconButton,{align:"left","aria-label":t,className:fp()(_B,{[_V]:p&&!h,[_W]:h}),enterDelayMs:300,kind:"ghost",label:t,onClick:y,size:"md",children:(0,fd.jsx)("div",{className:_U,children:(0,fd.jsx)(_H,{hasUnsavedChanges:g,getIcon:e,tagContent:r})})})};function _K({showContactDetails:e,toggleContactDetails:t,className:r}){return(0,fd.jsx)(fv.Button,{className:r,iconDescription:"Toggle contact details",kind:"ghost",onClick:t,renderIcon:e?f7:f5,children:e?iK("showLess","Show less"):iK("showMore","Show more")})}let _G={contactDetails:"-esm-cohort-builder__patient-banner-contact-details-module__contactDetails___AvROu",deceased:"-esm-cohort-builder__patient-banner-contact-details-module__deceased___DDd39",heading:"-esm-cohort-builder__patient-banner-contact-details-module__heading___GGJyV",row:"-esm-cohort-builder__patient-banner-contact-details-module__row___8JcKK",col:"-esm-cohort-builder__patient-banner-contact-details-module__col___ct1O9",relationship:"-esm-cohort-builder__patient-banner-contact-details-module__relationship___GTTsg"},_Z=({patientUuid:e})=>{let{cohorts:t=[],isLoading:r}=function(e){let t=e?`${i6}/cohortm/cohortmember?patient=${e}&v=custom:(uuid,patient:ref,cohort:(uuid,name,startDate,endDate))`:null,{data:r,isLoading:n}=cH()(t,i7),o=r?.data?.results.map(e=>({uuid:e.cohort.uuid,name:e.cohort.name,startDate:e.cohort.startDate,endDate:e.cohort.endDate}));return(0,cu.useMemo)(()=>({cohorts:o,isLoading:n}),[n,o])}(e);return(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsxs)("p",{className:_G.heading,children:[iK("patientLists","Patient Lists")," (",t?.length??0,")"]}),r?(0,fd.jsx)(fv.InlineLoading,{description:`${iK("loading","Loading")} ...`,role:"progressbar"}):(0,fd.jsxs)("ul",{children:[(()=>{if(t?.length>0){let e=t.sort((e,t)=>EU(e?.startDate).getTime()-EU(t?.startDate).getTime()).slice(0,3);return e?.map(e=>(0,fd.jsx)("li",{children:(0,fd.jsx)(cf,{to:`${window.spaBase}/home/patient-lists/${e.uuid}`,children:e.name},e.uuid)},e.uuid))}return(0,fd.jsx)("li",{children:"--"})})(),t.length>3&&(0,fd.jsx)("li",{className:_G.link,children:(0,fd.jsx)(cf,{to:`${window.spaBase}/home/patient-lists`,children:iK("seeMoreLists","See {{count}} more lists",{count:t?.length-3})})})]})]})},_Y=({patientId:e})=>{let{patient:t,isLoading:r}=dZ(e),n=t?.address?.find(e=>"home"===e.use),o=e=>e.split("#")[1];return r?(0,fd.jsx)(fv.InlineLoading,{description:`${iK("loading","Loading")} ...`,role:"progressbar"}):(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("p",{className:_G.heading,children:iK("address","Address")}),(0,fd.jsx)("ul",{children:n?Object.entries(n).filter(([e])=>"id"!==e&&"use"!==e).map(([e,t])=>"extension"===e?n.extension?.[0]?.extension?.map((t,r)=>(0,fd.jsxs)("li",{children:[iK(o(t.url),o(t.url)),": ",t.valueString]},`address-${e}-${r}`)):(0,fd.jsxs)("li",{children:[iK(e,e),": ",t]},`address-${e}`)):(0,fd.jsx)("li",{children:"--"})})]})},_q=({patientUuid:e})=>{let{isLoading:t,contactAttributes:r}=(e=>{let{contactAttributeTypes:t=[]}=du({externalModuleName:"@openmrs/esm-patient-banner-app"}),{attributes:r,error:n,isLoading:o}=(e=>{let{data:t,error:r,isLoading:n}=dp()(`${i6}/patient/${e}?v=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)))`,i7);return{isLoading:n,attributes:t?.data.person.attributes??[],error:r}})(e);return{contactAttributes:(0,cu.useMemo)(()=>r.filter(({attributeType:e})=>t?.some(t=>e.uuid===t)),[r,t]),isLoading:o,error:n}})(e),n=(0,cu.useMemo)(()=>r?[...r?.map(e=>[e.attributeType.display?iK(e.attributeType.display,e.attributeType.display):"",e.value])]:[],[r]);return(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("p",{className:_G.heading,children:iK("contactDetails","Contact Details")}),t?(0,fd.jsx)(fv.InlineLoading,{description:`${iK("loading","Loading")} ...`,role:"progressbar"}):(0,fd.jsx)("ul",{children:n.length?n.map(([e,t],r)=>(0,fd.jsxs)("li",{children:[e,": ",t]},`${e}-${t}-${r}`)):(0,fd.jsx)("li",{children:"--"})})]})},_J=({patientId:e})=>{let{data:t,isLoading:r}=function(e){let t=`${i6}/relationship?v=custom:(display,uuid,personA:(age,display,birthdate,uuid),personB:(age,display,birthdate,uuid),relationshipType:(uuid,display,description,aIsToB,bIsToA))&person=${e}`,{data:r,error:n,isLoading:o,isValidating:a}=cH()(e?t:null,i7),i=r?.data?.results?.length?function(e,t){let r=[];for(let n of t)e===n.personA.uuid?r.push({uuid:`${n.uuid}`,display:n.personB.display,relativeAge:n.personB.age,relativeUuid:n.personB.uuid,relationshipType:n.relationshipType.bIsToA}):r.push({uuid:`${n.uuid}`,display:n.personA.display,relativeAge:n.personA.age,relativeUuid:n.personA.uuid,relationshipType:n.relationshipType.aIsToB});return r}(e,r.data.results):null;return{data:r?i:null,error:n,isLoading:o,isValidating:a}}(e);return(0,fd.jsxs)(fd.Fragment,{children:[(0,fd.jsx)("p",{className:_G.heading,children:iK("relationships","Relationships")}),r?(0,fd.jsx)(fv.InlineLoading,{description:`${iK("loading","Loading")} ...`,role:"progressbar"}):(0,fd.jsx)("ul",{children:t&&t.length>0?(0,fd.jsx)(fd.Fragment,{children:t.map(e=>(0,fd.jsxs)("li",{className:_G.relationship,children:[(0,fd.jsx)("div",{children:(0,fd.jsx)(cf,{to:`${window.spaBase}/patient/${e.relativeUuid}/chart`,children:e.display})}),(0,fd.jsx)("div",{children:e.relationshipType}),(0,fd.jsx)("div",{children:`${e.relativeAge?e.relativeAge:"--"} ${e.relativeAge?1===e.relativeAge?iK("yearAbbreviation","yr"):iK("yearsAbbreviation","yrs"):""}`})]},e.uuid))}):(0,fd.jsx)("li",{children:"--"})})]})};function _X({patientId:e,deceased:t}){return(0,fd.jsxs)("div",{className:fp()(_G.contactDetails,{[_G.deceased]:t}),children:[(0,fd.jsxs)("div",{className:_G.row,children:[(0,fd.jsx)("div",{className:_G.col,children:(0,fd.jsx)(_Y,{patientId:e})}),(0,fd.jsx)("div",{className:_G.col,children:(0,fd.jsx)(_q,{patientUuid:e})})]}),(0,fd.jsxs)("div",{className:_G.row,children:[(0,fd.jsx)("div",{className:_G.col,children:(0,fd.jsx)(_J,{patientId:e})}),(0,fd.jsx)("div",{className:_G.col,children:(0,fd.jsx)(_Z,{patientUuid:e})})]})]})}function _Q(e){let t=document.querySelector("template#loading-spinner");if(t){let r=t.content.cloneNode(!0),n=Array.prototype.map.call(r.childNodes,e=>e);return e.appendChild(r),()=>n.forEach(e=>e.remove())}return()=>{}}let _0="-esm-cohort-builder__action-menu2-module__container___4aX3S";function _1({workspaceGroup:e,groupProps:t}){let r=dI(),{persistence:n}=e;return(0,fd.jsx)("aside",{className:"-esm-cohort-builder__action-menu2-module__sideRail___a7qg9",children:(0,fd.jsxs)("div",{className:_0,children:["closable"==n&&dM(r)&&(0,fd.jsx)(fv.IconButton,{align:"left",onClick:()=>_O(),label:iK("close"),kind:"ghost",children:(0,fd.jsx)(pe,{})}),(0,fd.jsx)(cd.Provider,{value:{moduleName:e.moduleName,featureName:e.name},children:(0,fd.jsx)(ck,{className:_0,name:e.name,state:{groupProps:t}})})]})})}function _2(e){let t=new URL(e,window.location.origin).pathname,r=new URL(window.getOpenmrsSpaBase?.()??"/",window.location.origin).pathname,n=r.endsWith("/")?r.slice(0,-1):r,o=null;return n?n===t?o="/":t.startsWith(`${n}/`)&&(o=t.slice(n.length)):o=t,{full:t,spaRelative:o}}function _4(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 _3(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?_4(Object(r),!0).forEach(function(t){_5(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):_4(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function _6(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 _5(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function _9(e){return(_9=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function _8(e,t){return(_8=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function _7(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var Se=function(e){var t=cu.Component;if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");i.prototype=Object.create(t&&t.prototype,{constructor:{value:i,writable:!0,configurable:!0}}),t&&_8(i,t);var r,n,o,a=(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=_9(i);e=r?Reflect.construct(t,arguments,_9(this).constructor):t.apply(this,arguments);if(e&&("object"==typeof e||"function"==typeof e))return e;if(void 0!==e)throw TypeError("Derived constructors may only return object or undefined");return _7(this)});function i(e){var t;if(function(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}(this,i),_5(_7(t=a.call(this,e)),"handleRef",function(e){t.el=e}),_5(_7(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}))}),_5(_7(t),"getParcelProps",function(){var e=_3(_3({},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,_3({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 cA&&cA.Consumer?cu.createElement(cA.Consumer,null,function(t){return e.mountParcel=t?t.mountParcel:null,null}):null;var t=cA&&cA.Consumer?cu.createElement(cA.Consumer,null,function(t){return e.mountParcel=t?t.mountParcel:null,null}):void 0;return cu.createElement(this.props.wrapWith,{ref:this.handleRef,style:this.props.wrapStyle,className:this.props.wrapClassName},t)}}],_6(i.prototype,n),o&&_6(i,o),i}();_5(Se,"defaultProps",{wrapWith:"div",wrapStyle:{},parcelDidMount:function(){}});let St=({lifeCycle:e,openedWorkspace:t,openedWindow:r,isRootWorkspace:n,isLeafWorkspace:o,showActionMenu:a})=>{let{openedGroup:i,closeWorkspace:s,openChildWorkspace:l}=_A(),u=(0,cu.useMemo)(()=>t&&{closeWorkspace:async(e={})=>{let{closeWindow:n=!1,discardUnsavedChanges:o=!1}=e;return n?!!(o||await _N({reason:"CLOSE_WINDOW",explicit:!0,windowName:r.windowName}))&&(s(r.openedWorkspaces[0].workspaceName),!0):!!(o||await _N({reason:"CLOSE_WORKSPACE",explicit:!0,windowName:r.windowName,workspaceName:t.workspaceName}))&&(s(t.workspaceName),!0)},launchChildWorkspace:async(e,n)=>{let o=t.workspaceName,{openedWorkspaces:a}=r,i=a.findIndex(e=>e.workspaceName===o);-1===i||i!==a.length-1&&a.slice(i+1).some(e=>e.hasUnsavedChanges)&&!await _N({reason:"CLOSE_WORKSPACE",explicit:!0,windowName:r.windowName,workspaceName:a[i+1].workspaceName})||l(o,e,n||{})},workspaceName:t.workspaceName,workspaceProps:t.props,windowProps:r.props,groupProps:i&&i.props?i.props:null,workspaceMeta:u3.getState().registeredWorkspacesByName[t.workspaceName]?.meta??{},isRootWorkspace:n,isLeafWorkspace:o,windowName:r.windowName,showActionMenu:a},[t,s,i,r]);if(!e){let{registeredWorkspacesByName:e}=u3.getState(),r=e[t.workspaceName],o=r&&r.window?r.window:void 0,{registeredWindowsByName:s}=u3.getState(),l=o?s[o]:void 0,u=l&&l.width?l.width:"narrow",c=Object.values(s).some(e=>e.group===i?.groupName&&void 0!==e.icon);return(0,fd.jsxs)("div",{className:fp()(_L.workspaceOuterContainer,{[_L.narrowWorkspace]:"narrow"===u,[_L.widerWorkspace]:"wider"===u,[_L.extraWideWorkspace]:"extra-wide"===u,[_L.isActionMenuOpened]:c}),children:[(0,fd.jsx)("div",{className:_L.workspaceSpacer}),(0,fd.jsx)("div",{className:fp()(_L.workspaceMiddleContainer,{[_L.isRootWorkspace]:n,[_L.showActionMenu]:a}),children:(0,fd.jsx)("div",{className:fp()(_L.workspaceInnerContainer,{[_L.isRootWorkspace]:n}),children:(0,fd.jsx)(fv.InlineLoading,{className:_L.loader,description:`${iK("loading")} ...`})})})]})}return(0,fd.jsx)(Se,{config:e,mountParcel:cs,...u},t.workspaceName)},Sr=({openedWindow:e,showActionMenu:t})=>{let{openedWorkspaces:r}=e,[n,o]=(0,cu.useState)({}),{registeredWorkspacesByName:a}=u3.getState();return(0,cu.useEffect)(()=>{let e=!1;return Promise.all(r.map(async e=>{let{moduleName:t,component:r}=a[e.workspaceName];return[e.uuid,await fe(t,r)]})).then(t=>{e||o(Object.fromEntries(t))}),()=>{e=!0}},[r]),(0,fd.jsx)(fd.Fragment,{children:r.map((o,a)=>(0,fd.jsx)(St,{openedWorkspace:o,openedWindow:e,lifeCycle:n[o.uuid],isRootWorkspace:0===a,isLeafWorkspace:a===r.length-1,showActionMenu:t},o.uuid))})};function Sn(e){e&&(0,cP.createRoot)(e).render((0,fd.jsx)(So,{}))}function So(){let{openedGroup:e,openedWindows:t,registeredGroupsByName:r,registeredWindowsByName:n}=_A();if((0,cu.useEffect)(()=>lh("before-page-changed",t=>{let{newPage:n,cancelNavigation:o,oldUrl:a,newUrl:i}=t;if(!e)return;if(n)return void o(_O().then(e=>!e));let s=r[e.groupName],l=s?.scopePattern;l&&function(e,t,r){try{let n=new RegExp(e),o=_2(t),a=_2(r);if(null===o.spaRelative||null===a.spaRelative)return!0;let i=n.exec(o.spaRelative),s=n.exec(a.spaRelative);if(i&&s||(i=n.exec(o.full),s=n.exec(a.full)),!i||!s)return!0;if(i.length>1)return!i.slice(1).every((e,t)=>e===s[t+1]);return!1}catch{return!0}}(l,a,i)&&o(_O().then(e=>!e))}),[e,r]),!e)return null;let o=r[e.groupName],a=t.some(e=>e.maximized),{name:i}=o,s=Object.values(n).filter(e=>e.group===i&&void 0!==e.icon).sort((e,t)=>(e.order??Number.MAX_VALUE)-(t.order??Number.MAX_VALUE)).length>0;return(0,fd.jsxs)("div",{className:fp()("-esm-cohort-builder__workspace-windows-and-menu-module__workspaceWindowsAndMenuContainer___crgqC",{"-esm-cohort-builder__workspace-windows-and-menu-module__overlay___FCMKG":o.overlay,"-esm-cohort-builder__workspace-windows-and-menu-module__hasMaximizedWindow___gk319":a}),children:[(0,fd.jsx)("div",{className:"-esm-cohort-builder__workspace-windows-and-menu-module__workspaceWindowsContainer___MrLlf",children:t.map(e=>(0,fd.jsx)(Sr,{openedWindow:e,showActionMenu:s},e.windowName))}),s&&(0,fd.jsx)(_1,{workspaceGroup:o,groupProps:e.props})]})}function Sa(e,t,r){if(null==e)return r;let n=Er(e);if(!n)return console.warn(`matchLocale: invalid requested locale tag: ${JSON.stringify(e)}`),r;let o=[];for(let e of t){let t=Er(e);if(!t){console.warn(`matchLocale: skipping invalid available locale tag: ${JSON.stringify(e)}`);continue}o.push({canonical:t,original:e})}let a=n;for(;a;){let e=o.find(e=>e.canonical===a);if(e)return e.original;let t=a+"-",r=o.find(e=>e.canonical.startsWith(t));if(r)return r.original;if("ht"===a){a="fr-HT";continue}let n=a.lastIndexOf("-");if(-1===n)break;let i=(a=a.slice(0,n)).lastIndexOf("-");-1!==i&&a.length-i==2&&(a=a.slice(0,i))}return r}function Si(e=window.localStorage){try{return e.getItem("test"),!0}catch{return!1}}function Ss(e){return!!e&&e.constructor===Object}var Sl=r(7638);function Su(e){let[t,r,n]=e.split(".");return`${t}.${r}.${n}`}function Sc(e,t){return Sl(function(e){let t=e.indexOf("-");if(t>=0){let r=Su(e.slice(0,t)),n=e.slice(t+1);return`${r}-${n}`}return Su(e)}(t),e,{includePrerelease:!0})}async function Sd(e,t={}){let r,{shouldRetry:n,getDelay:o,onError:a}=t;n=n??(e=>e<=5),o=o??(e=>(function(e,t=!1){return 1e3*Math.pow(2,t?e+1:e)})(e));let i=0;do try{return await Sf(o(i)),await e()}catch(e){a?.(e,i),r=e}while(n(i++));throw r}async function Sf(e){if(!(e<=0))return new Promise(t=>setTimeout(t,e))}function Sp(e,t,r,n){}function Sm(e){}function Sh(e){return Promise.resolve([])}function Sg(e){return Promise.resolve([])}function Sy(e){return Promise.resolve({success:!1,result:void 0,error:"No service worker has been registered. Offline-related features have been removed from the framework."})}function Sv(e){return()=>{}}function Sb(){return!0}}}]);
|