(function(te){typeof define=="function"&&define.amd?define(te):te()})(function(){"use strict";var i8=Object.defineProperty,r8=Object.defineProperties;var s8=Object.getOwnPropertyDescriptors;var Ou=Object.getOwnPropertySymbols;var X$=Object.prototype.hasOwnProperty,Q$=Object.prototype.propertyIsEnumerable;var rm=(te,Z)=>(Z=Symbol[te])?Z:Symbol.for("Symbol."+te),o8=te=>{throw TypeError(te)},om=Math.pow,sm=(te,Z,he)=>Z in te?i8(te,Z,{enumerable:!0,configurable:!0,writable:!0,value:he}):te[Z]=he,k=(te,Z)=>{for(var he in Z||(Z={}))X$.call(Z,he)&&sm(te,he,Z[he]);if(Ou)for(var he of Ou(Z))Q$.call(Z,he)&&sm(te,he,Z[he]);return te},V=(te,Z)=>r8(te,s8(Z));var ee=(te,Z)=>{var he={};for(var Le in te)X$.call(te,Le)&&Z.indexOf(Le)<0&&(he[Le]=te[Le]);if(te!=null&&Ou)for(var Le of Ou(te))Z.indexOf(Le)<0&&Q$.call(te,Le)&&(he[Le]=te[Le]);return he};var G=(te,Z,he)=>sm(te,typeof Z!="symbol"?Z+"":Z,he);var a8=function(te,Z){this[0]=te,this[1]=Z};var os=te=>{var Z=te[rm("asyncIterator")],he=!1,Le,X={};return Z==null?(Z=te[rm("iterator")](),Le=nt=>X[nt]=xi=>Z[nt](xi)):(Z=Z.call(te),Le=nt=>X[nt]=xi=>{if(he){if(he=!1,nt==="throw")throw xi;return xi}return he=!0,{done:!1,value:new a8(new Promise(Vu=>{var Xo=Z[nt](xi);Xo instanceof Object||o8("Object expected"),Vu(Xo)}),1)}}),X[rm("iterator")]=()=>X,Le("next"),"throw"in Z?Le("throw"):X.throw=nt=>{throw nt},"return"in Z&&Le("return"),X};var Fu,bi;function te(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Z={exports:{}},he={},Le={exports:{}},X={};/** * @license React * react.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var nt=Symbol.for("react.element"),xi=Symbol.for("react.portal"),Vu=Symbol.for("react.fragment"),Xo=Symbol.for("react.strict_mode"),q$=Symbol.for("react.profiler"),Z$=Symbol.for("react.provider"),J$=Symbol.for("react.context"),ek=Symbol.for("react.forward_ref"),tk=Symbol.for("react.suspense"),nk=Symbol.for("react.memo"),ik=Symbol.for("react.lazy"),am=Symbol.iterator;function rk(t){return t===null||typeof t!="object"?null:(t=am&&t[am]||t["@@iterator"],typeof t=="function"?t:null)}var lm={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},um=Object.assign,cm={};function ir(t,e,n){this.props=t,this.context=e,this.refs=cm,this.updater=n||lm}ir.prototype.isReactComponent={},ir.prototype.setState=function(t,e){if(typeof t!="object"&&typeof t!="function"&&t!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,e,"setState")},ir.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")};function dm(){}dm.prototype=ir.prototype;function ju(t,e,n){this.props=t,this.context=e,this.refs=cm,this.updater=n||lm}var zu=ju.prototype=new dm;zu.constructor=ju,um(zu,ir.prototype),zu.isPureReactComponent=!0;var fm=Array.isArray,hm=Object.prototype.hasOwnProperty,Bu={current:null},pm={key:!0,ref:!0,__self:!0,__source:!0};function mm(t,e,n){var i,r={},s=null,o=null;if(e!=null)for(i in e.ref!==void 0&&(o=e.ref),e.key!==void 0&&(s=""+e.key),e)hm.call(e,i)&&!pm.hasOwnProperty(i)&&(r[i]=e[i]);var a=arguments.length-2;if(a===1)r.children=n;else if(1>>1,z=R[I];if(0>>1;Ir(J,H))cer($t,J)?(R[I]=$t,R[ce]=H,I=ce):(R[I]=J,R[K]=H,I=K);else if(cer($t,H))R[I]=$t,R[ce]=H,I=ce;else break e}}return j}function r(R,j){var H=R.sortIndex-j.sortIndex;return H!==0?H:R.id-j.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;t.unstable_now=function(){return s.now()}}else{var o=Date,a=o.now();t.unstable_now=function(){return o.now()-a}}var l=[],u=[],c=1,d=null,f=3,h=!1,g=!1,v=!1,b=typeof setTimeout=="function"?setTimeout:null,p=typeof clearTimeout=="function"?clearTimeout:null,m=typeof setImmediate!="undefined"?setImmediate:null;typeof navigator!="undefined"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function y(R){for(var j=n(u);j!==null;){if(j.callback===null)i(u);else if(j.startTime<=R)i(u),j.sortIndex=j.expirationTime,e(l,j);else break;j=n(u)}}function S(R){if(v=!1,y(R),!g)if(n(l)!==null)g=!0,E(P);else{var j=n(u);j!==null&&A(S,j.startTime-R)}}function P(R,j){g=!1,v&&(v=!1,p(_),_=-1),h=!0;var H=f;try{for(y(j),d=n(l);d!==null&&(!(d.expirationTime>j)||R&&!F());){var I=d.callback;if(typeof I=="function"){d.callback=null,f=d.priorityLevel;var z=I(d.expirationTime<=j);j=t.unstable_now(),typeof z=="function"?d.callback=z:d===n(l)&&i(l),y(j)}else i(l);d=n(l)}if(d!==null)var Q=!0;else{var K=n(u);K!==null&&A(S,K.startTime-j),Q=!1}return Q}finally{d=null,f=H,h=!1}}var C=!1,L=null,_=-1,w=5,$=-1;function F(){return!(t.unstable_now()-$R||125I?(R.sortIndex=H,e(u,R),n(l)===null&&R===n(u)&&(v?(p(_),_=-1):v=!0,A(S,H-I))):(R.sortIndex=z,e(l,R),g||h||(g=!0,E(P))),R},t.unstable_shouldYield=F,t.unstable_wrapCallback=function(R){var j=f;return function(){var H=f;f=j;try{return R.apply(this,arguments)}finally{f=H}}}})(wm),xm.exports=wm;var mk=xm.exports;/** * @license React * react-dom.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var gk=x,gt=mk;function B(t){for(var e="https://reactjs.org/docs/error-decoder.html?invariant="+t,n=1;ne}return!1}function Ze(t,e,n,i,r,s,o){this.acceptsBooleans=e===2||e===3||e===4,this.attributeName=i,this.attributeNamespace=r,this.mustUseProperty=n,this.propertyName=t,this.type=e,this.sanitizeURL=s,this.removeEmptyString=o}var Oe={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(t){Oe[t]=new Ze(t,0,!1,t,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var e=t[0];Oe[e]=new Ze(e,1,!1,t[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(t){Oe[t]=new Ze(t,2,!1,t.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){Oe[t]=new Ze(t,2,!1,t,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(t){Oe[t]=new Ze(t,3,!1,t.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(t){Oe[t]=new Ze(t,3,!0,t,null,!1,!1)}),["capture","download"].forEach(function(t){Oe[t]=new Ze(t,4,!1,t,null,!1,!1)}),["cols","rows","size","span"].forEach(function(t){Oe[t]=new Ze(t,6,!1,t,null,!1,!1)}),["rowSpan","start"].forEach(function(t){Oe[t]=new Ze(t,5,!1,t.toLowerCase(),null,!1,!1)});var Yu=/[\-:]([a-z])/g;function Gu(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(t){var e=t.replace(Yu,Gu);Oe[e]=new Ze(e,1,!1,t,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(t){var e=t.replace(Yu,Gu);Oe[e]=new Ze(e,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(t){var e=t.replace(Yu,Gu);Oe[e]=new Ze(e,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(t){Oe[t]=new Ze(t,1,!1,t.toLowerCase(),null,!1,!1)}),Oe.xlinkHref=new Ze("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(t){Oe[t]=new Ze(t,1,!1,t.toLowerCase(),null,!0,!0)});function Xu(t,e,n,i){var r=Oe.hasOwnProperty(e)?Oe[e]:null;(r!==null?r.type!==0:i||!(2a||r[o]!==s[a]){var l=` `+r[o].replace(" at new "," at ");return t.displayName&&l.includes("")&&(l=l.replace("",t.displayName)),l}while(1<=o&&0<=a);break}}}finally{ic=!1,Error.prepareStackTrace=n}return(t=t?t.displayName||t.name:"")?us(t):""}function wk(t){switch(t.tag){case 5:return us(t.type);case 16:return us("Lazy");case 13:return us("Suspense");case 19:return us("SuspenseList");case 0:case 2:case 15:return t=rc(t.type,!1),t;case 11:return t=rc(t.type.render,!1),t;case 1:return t=rc(t.type,!0),t;default:return""}}function sc(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case or:return"Fragment";case sr:return"Portal";case qu:return"Profiler";case Qu:return"StrictMode";case Ju:return"Suspense";case ec:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case Tm:return(t.displayName||"Context")+".Consumer";case km:return(t._context.displayName||"Context")+".Provider";case Zu:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case tc:return e=t.displayName||null,e!==null?e:sc(t.type)||"Memo";case In:e=t._payload,t=t._init;try{return sc(t(e))}catch(n){}}return null}function Sk(t){var e=t.type;switch(t.tag){case 24:return"Cache";case 9:return(e.displayName||"Context")+".Consumer";case 10:return(e._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=e.render,t=t.displayName||t.name||"",e.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return e;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return sc(e);case 8:return e===Qu?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e}return null}function Nn(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function _m(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function Pk(t){var e=_m(t)?"checked":"value",n=Object.getOwnPropertyDescriptor(t.constructor.prototype,e),i=""+t[e];if(!t.hasOwnProperty(e)&&typeof n!="undefined"&&typeof n.get=="function"&&typeof n.set=="function"){var r=n.get,s=n.set;return Object.defineProperty(t,e,{configurable:!0,get:function(){return r.call(this)},set:function(o){i=""+o,s.call(this,o)}}),Object.defineProperty(t,e,{enumerable:n.enumerable}),{getValue:function(){return i},setValue:function(o){i=""+o},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function ea(t){t._valueTracker||(t._valueTracker=Pk(t))}function Mm(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var n=e.getValue(),i="";return t&&(i=_m(t)?t.checked?"true":"false":t.value),t=i,t!==n?(e.setValue(t),!0):!1}function ta(t){if(t=t||(typeof document!="undefined"?document:void 0),typeof t=="undefined")return null;try{return t.activeElement||t.body}catch(e){return t.body}}function oc(t,e){var n=e.checked;return xe({},e,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n!=null?n:t._wrapperState.initialChecked})}function Dm(t,e){var n=e.defaultValue==null?"":e.defaultValue,i=e.checked!=null?e.checked:e.defaultChecked;n=Nn(e.value!=null?e.value:n),t._wrapperState={initialChecked:i,initialValue:n,controlled:e.type==="checkbox"||e.type==="radio"?e.checked!=null:e.value!=null}}function Lm(t,e){e=e.checked,e!=null&&Xu(t,"checked",e,!1)}function ac(t,e){Lm(t,e);var n=Nn(e.value),i=e.type;if(n!=null)i==="number"?(n===0&&t.value===""||t.value!=n)&&(t.value=""+n):t.value!==""+n&&(t.value=""+n);else if(i==="submit"||i==="reset"){t.removeAttribute("value");return}e.hasOwnProperty("value")?lc(t,e.type,n):e.hasOwnProperty("defaultValue")&&lc(t,e.type,Nn(e.defaultValue)),e.checked==null&&e.defaultChecked!=null&&(t.defaultChecked=!!e.defaultChecked)}function Am(t,e,n){if(e.hasOwnProperty("value")||e.hasOwnProperty("defaultValue")){var i=e.type;if(!(i!=="submit"&&i!=="reset"||e.value!==void 0&&e.value!==null))return;e=""+t._wrapperState.initialValue,n||e===t.value||(t.value=e),t.defaultValue=e}n=t.name,n!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,n!==""&&(t.name=n)}function lc(t,e,n){(e!=="number"||ta(t.ownerDocument)!==t)&&(n==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+n&&(t.defaultValue=""+n))}var cs=Array.isArray;function ar(t,e,n,i){if(t=t.options,e){e={};for(var r=0;r"+e.valueOf().toString()+"",e=na.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;e.firstChild;)t.appendChild(e.firstChild)}});function ds(t,e){if(e){var n=t.firstChild;if(n&&n===t.lastChild&&n.nodeType===3){n.nodeValue=e;return}}t.textContent=e}var fs={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},$k=["Webkit","ms","Moz","O"];Object.keys(fs).forEach(function(t){$k.forEach(function(e){e=e+t.charAt(0).toUpperCase()+t.substring(1),fs[e]=fs[t]})});function Vm(t,e,n){return e==null||typeof e=="boolean"||e===""?"":n||typeof e!="number"||e===0||fs.hasOwnProperty(t)&&fs[t]?(""+e).trim():e+"px"}function jm(t,e){t=t.style;for(var n in e)if(e.hasOwnProperty(n)){var i=n.indexOf("--")===0,r=Vm(n,e[n],i);n==="float"&&(n="cssFloat"),i?t.setProperty(n,r):t[n]=r}}var kk=xe({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function dc(t,e){if(e){if(kk[t]&&(e.children!=null||e.dangerouslySetInnerHTML!=null))throw Error(B(137,t));if(e.dangerouslySetInnerHTML!=null){if(e.children!=null)throw Error(B(60));if(typeof e.dangerouslySetInnerHTML!="object"||!("__html"in e.dangerouslySetInnerHTML))throw Error(B(61))}if(e.style!=null&&typeof e.style!="object")throw Error(B(62))}}function fc(t,e){if(t.indexOf("-")===-1)return typeof e.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var hc=null;function pc(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var mc=null,lr=null,ur=null;function zm(t){if(t=Rs(t)){if(typeof mc!="function")throw Error(B(280));var e=t.stateNode;e&&(e=ka(e),mc(t.stateNode,t.type,e))}}function Bm(t){lr?ur?ur.push(t):ur=[t]:lr=t}function Km(){if(lr){var t=lr,e=ur;if(ur=lr=null,zm(t),e)for(t=0;t>>=0,t===0?32:31-(Ik(t)/Nk|0)|0}var aa=64,la=4194304;function gs(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function ua(t,e){var n=t.pendingLanes;if(n===0)return 0;var i=0,r=t.suspendedLanes,s=t.pingedLanes,o=n&268435455;if(o!==0){var a=o&~r;a!==0?i=gs(a):(s&=o,s!==0&&(i=gs(s)))}else o=n&~r,o!==0?i=gs(o):s!==0&&(i=gs(s));if(i===0)return 0;if(e!==0&&e!==i&&!(e&r)&&(r=i&-i,s=e&-e,r>=s||r===16&&(s&4194240)!==0))return e;if(i&4&&(i|=n&16),e=t.entangledLanes,e!==0)for(t=t.entanglements,e&=i;0n;n++)e.push(t);return e}function vs(t,e,n){t.pendingLanes|=e,e!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,e=31-jt(e),t[e]=n}function zk(t,e){var n=t.pendingLanes&~e;t.pendingLanes=e,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=e,t.mutableReadLanes&=e,t.entangledLanes&=e,e=t.entanglements;var i=t.eventTimes;for(t=t.expirationTimes;0=ks),vg=" ",yg=!1;function bg(t,e){switch(t){case"keyup":return mT.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function xg(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var fr=!1;function vT(t,e){switch(t){case"compositionend":return xg(e);case"keypress":return e.which!==32?null:(yg=!0,vg);case"textInput":return t=e.data,t===vg&&yg?null:t;default:return null}}function yT(t,e){if(fr)return t==="compositionend"||!Ac&&bg(t,e)?(t=dg(),pa=Cc=Bn=null,fr=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1=e)return{node:n,offset:e-t};t=i}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Cg(n)}}function _g(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?_g(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function Mg(){for(var t=window,e=ta();e instanceof t.HTMLIFrameElement;){try{var n=typeof e.contentWindow.location.href=="string"}catch(i){n=!1}if(n)t=e.contentWindow;else break;e=ta(t.document)}return e}function Ic(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}function CT(t){var e=Mg(),n=t.focusedElem,i=t.selectionRange;if(e!==n&&n&&n.ownerDocument&&_g(n.ownerDocument.documentElement,n)){if(i!==null&&Ic(n)){if(e=i.start,t=i.end,t===void 0&&(t=e),"selectionStart"in n)n.selectionStart=e,n.selectionEnd=Math.min(t,n.value.length);else if(t=(e=n.ownerDocument||document)&&e.defaultView||window,t.getSelection){t=t.getSelection();var r=n.textContent.length,s=Math.min(i.start,r);i=i.end===void 0?s:Math.min(i.end,r),!t.extend&&s>i&&(r=i,i=s,s=r),r=Eg(n,s);var o=Eg(n,i);r&&o&&(t.rangeCount!==1||t.anchorNode!==r.node||t.anchorOffset!==r.offset||t.focusNode!==o.node||t.focusOffset!==o.offset)&&(e=e.createRange(),e.setStart(r.node,r.offset),t.removeAllRanges(),s>i?(t.addRange(e),t.extend(o.node,o.offset)):(e.setEnd(o.node,o.offset),t.addRange(e)))}}for(e=[],t=n;t=t.parentNode;)t.nodeType===1&&e.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,hr=null,Nc=null,_s=null,Oc=!1;function Dg(t,e,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Oc||hr==null||hr!==ta(i)||(i=hr,"selectionStart"in i&&Ic(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),_s&&Es(_s,i)||(_s=i,i=Sa(Nc,"onSelect"),0yr||(t.current=Qc[yr],Qc[yr]=null,yr--)}function fe(t,e){yr++,Qc[yr]=t.current,t.current=e}var Un={},He=Wn(Un),it=Wn(!1),$i=Un;function br(t,e){var n=t.type.contextTypes;if(!n)return Un;var i=t.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===e)return i.__reactInternalMemoizedMaskedChildContext;var r={},s;for(s in n)r[s]=e[s];return i&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=e,t.__reactInternalMemoizedMaskedChildContext=r),r}function rt(t){return t=t.childContextTypes,t!=null}function Ta(){me(it),me(He)}function Ug(t,e,n){if(He.current!==Un)throw Error(B(168));fe(He,e),fe(it,n)}function Yg(t,e,n){var i=t.stateNode;if(e=e.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var r in i)if(!(r in e))throw Error(B(108,Sk(t)||"Unknown",r));return xe({},n,i)}function Ca(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||Un,$i=He.current,fe(He,t),fe(it,it.current),!0}function Gg(t,e,n){var i=t.stateNode;if(!i)throw Error(B(169));n?(t=Yg(t,e,$i),i.__reactInternalMemoizedMergedChildContext=t,me(it),me(He),fe(He,t)):me(it),fe(it,n)}var pn=null,Ea=!1,qc=!1;function Xg(t){pn===null?pn=[t]:pn.push(t)}function VT(t){Ea=!0,Xg(t)}function Yn(){if(!qc&&pn!==null){qc=!0;var t=0,e=ue;try{var n=pn;for(ue=1;t>=o,r-=o,mn=1<<32-jt(e)+r|n<_?(w=L,L=null):w=L.sibling;var $=f(p,L,y[_],S);if($===null){L===null&&(L=w);break}t&&L&&$.alternate===null&&e(p,L),m=s($,m,_),C===null?P=$:C.sibling=$,C=$,L=w}if(_===y.length)return n(p,L),ye&&Ti(p,_),P;if(L===null){for(;__?(w=L,L=null):w=L.sibling;var F=f(p,L,$.value,S);if(F===null){L===null&&(L=w);break}t&&L&&F.alternate===null&&e(p,L),m=s(F,m,_),C===null?P=F:C.sibling=F,C=F,L=w}if($.done)return n(p,L),ye&&Ti(p,_),P;if(L===null){for(;!$.done;_++,$=y.next())$=d(p,$.value,S),$!==null&&(m=s($,m,_),C===null?P=$:C.sibling=$,C=$);return ye&&Ti(p,_),P}for(L=i(p,L);!$.done;_++,$=y.next())$=h(L,p,_,$.value,S),$!==null&&(t&&$.alternate!==null&&L.delete($.key===null?_:$.key),m=s($,m,_),C===null?P=$:C.sibling=$,C=$);return t&&L.forEach(function(T){return e(p,T)}),ye&&Ti(p,_),P}function b(p,m,y,S){if(typeof y=="object"&&y!==null&&y.type===or&&y.key===null&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case Jo:e:{for(var P=y.key,C=m;C!==null;){if(C.key===P){if(P=y.type,P===or){if(C.tag===7){n(p,C.sibling),m=r(C,y.props.children),m.return=p,p=m;break e}}else if(C.elementType===P||typeof P=="object"&&P!==null&&P.$$typeof===In&&tv(P)===C.type){n(p,C.sibling),m=r(C,y.props),m.ref=Fs(p,C,y),m.return=p,p=m;break e}n(p,C);break}else e(p,C);C=C.sibling}y.type===or?(m=Ri(y.props.children,p.mode,S,y.key),m.return=p,p=m):(S=nl(y.type,y.key,y.props,null,p.mode,S),S.ref=Fs(p,m,y),S.return=p,p=S)}return o(p);case sr:e:{for(C=y.key;m!==null;){if(m.key===C)if(m.tag===4&&m.stateNode.containerInfo===y.containerInfo&&m.stateNode.implementation===y.implementation){n(p,m.sibling),m=r(m,y.children||[]),m.return=p,p=m;break e}else{n(p,m);break}else e(p,m);m=m.sibling}m=Gd(y,p.mode,S),m.return=p,p=m}return o(p);case In:return C=y._init,b(p,m,C(y._payload),S)}if(cs(y))return g(p,m,y,S);if(ls(y))return v(p,m,y,S);La(p,y)}return typeof y=="string"&&y!==""||typeof y=="number"?(y=""+y,m!==null&&m.tag===6?(n(p,m.sibling),m=r(m,y),m.return=p,p=m):(n(p,m),m=Yd(y,p.mode,S),m.return=p,p=m),o(p)):n(p,m)}return b}var Pr=nv(!0),iv=nv(!1),Aa=Wn(null),Ra=null,$r=null,id=null;function rd(){id=$r=Ra=null}function sd(t){var e=Aa.current;me(Aa),t._currentValue=e}function od(t,e,n){for(;t!==null;){var i=t.alternate;if((t.childLanes&e)!==e?(t.childLanes|=e,i!==null&&(i.childLanes|=e)):i!==null&&(i.childLanes&e)!==e&&(i.childLanes|=e),t===n)break;t=t.return}}function kr(t,e){Ra=t,id=$r=null,t=t.dependencies,t!==null&&t.firstContext!==null&&(t.lanes&e&&(st=!0),t.firstContext=null)}function Et(t){var e=t._currentValue;if(id!==t)if(t={context:t,memoizedValue:e,next:null},$r===null){if(Ra===null)throw Error(B(308));$r=t,Ra.dependencies={lanes:0,firstContext:t}}else $r=$r.next=t;return e}var Ci=null;function ad(t){Ci===null?Ci=[t]:Ci.push(t)}function rv(t,e,n,i){var r=e.interleaved;return r===null?(n.next=n,ad(e)):(n.next=r.next,r.next=n),e.interleaved=n,vn(t,i)}function vn(t,e){t.lanes|=e;var n=t.alternate;for(n!==null&&(n.lanes|=e),n=t,t=t.return;t!==null;)t.childLanes|=e,n=t.alternate,n!==null&&(n.childLanes|=e),n=t,t=t.return;return n.tag===3?n.stateNode:null}var Gn=!1;function ld(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function sv(t,e){t=t.updateQueue,e.updateQueue===t&&(e.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,effects:t.effects})}function yn(t,e){return{eventTime:t,lane:e,tag:0,payload:null,callback:null,next:null}}function Xn(t,e,n){var i=t.updateQueue;if(i===null)return null;if(i=i.shared,ne&2){var r=i.pending;return r===null?e.next=e:(e.next=r.next,r.next=e),i.pending=e,vn(t,n)}return r=i.interleaved,r===null?(e.next=e,ad(i)):(e.next=r.next,r.next=e),i.interleaved=e,vn(t,n)}function Fa(t,e,n){if(e=e.updateQueue,e!==null&&(e=e.shared,(n&4194240)!==0)){var i=e.lanes;i&=t.pendingLanes,n|=i,e.lanes=n,Sc(t,n)}}function ov(t,e){var n=t.updateQueue,i=t.alternate;if(i!==null&&(i=i.updateQueue,n===i)){var r=null,s=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};s===null?r=s=o:s=s.next=o,n=n.next}while(n!==null);s===null?r=s=e:s=s.next=e}else r=s=e;n={baseState:i.baseState,firstBaseUpdate:r,lastBaseUpdate:s,shared:i.shared,effects:i.effects},t.updateQueue=n;return}t=n.lastBaseUpdate,t===null?n.firstBaseUpdate=e:t.next=e,n.lastBaseUpdate=e}function Ia(t,e,n,i){var r=t.updateQueue;Gn=!1;var s=r.firstBaseUpdate,o=r.lastBaseUpdate,a=r.shared.pending;if(a!==null){r.shared.pending=null;var l=a,u=l.next;l.next=null,o===null?s=u:o.next=u,o=l;var c=t.alternate;c!==null&&(c=c.updateQueue,a=c.lastBaseUpdate,a!==o&&(a===null?c.firstBaseUpdate=u:a.next=u,c.lastBaseUpdate=l))}if(s!==null){var d=r.baseState;o=0,c=u=l=null,a=s;do{var f=a.lane,h=a.eventTime;if((i&f)===f){c!==null&&(c=c.next={eventTime:h,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var g=t,v=a;switch(f=e,h=n,v.tag){case 1:if(g=v.payload,typeof g=="function"){d=g.call(h,d,f);break e}d=g;break e;case 3:g.flags=g.flags&-65537|128;case 0:if(g=v.payload,f=typeof g=="function"?g.call(h,d,f):g,f==null)break e;d=xe({},d,f);break e;case 2:Gn=!0}}a.callback!==null&&a.lane!==0&&(t.flags|=64,f=r.effects,f===null?r.effects=[a]:f.push(a))}else h={eventTime:h,lane:f,tag:a.tag,payload:a.payload,callback:a.callback,next:null},c===null?(u=c=h,l=d):c=c.next=h,o|=f;if(a=a.next,a===null){if(a=r.shared.pending,a===null)break;f=a,a=f.next,f.next=null,r.lastBaseUpdate=f,r.shared.pending=null}}while(!0);if(c===null&&(l=d),r.baseState=l,r.firstBaseUpdate=u,r.lastBaseUpdate=c,e=r.shared.interleaved,e!==null){r=e;do o|=r.lane,r=r.next;while(r!==e)}else s===null&&(r.shared.lanes=0);Mi|=o,t.lanes=o,t.memoizedState=d}}function av(t,e,n){if(t=e.effects,e.effects=null,t!==null)for(e=0;en?n:4,t(!0);var i=hd.transition;hd.transition={};try{t(!1),e()}finally{ue=n,hd.transition=i}}function Tv(){return _t().memoizedState}function KT(t,e,n){var i=Jn(t);if(n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},Cv(t))Ev(e,n);else if(n=rv(t,e,n,i),n!==null){var r=et();Ut(n,t,i,r),_v(n,e,i)}}function HT(t,e,n){var i=Jn(t),r={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if(Cv(t))Ev(e,r);else{var s=t.alternate;if(t.lanes===0&&(s===null||s.lanes===0)&&(s=e.lastRenderedReducer,s!==null))try{var o=e.lastRenderedState,a=s(o,n);if(r.hasEagerState=!0,r.eagerState=a,zt(a,o)){var l=e.interleaved;l===null?(r.next=r,ad(e)):(r.next=l.next,l.next=r),e.interleaved=r;return}}catch(u){}finally{}n=rv(t,e,r,i),n!==null&&(r=et(),Ut(n,t,i,r),_v(n,e,i))}}function Cv(t){var e=t.alternate;return t===Se||e!==null&&e===Se}function Ev(t,e){Vs=Va=!0;var n=t.pending;n===null?e.next=e:(e.next=n.next,n.next=e),t.pending=e}function _v(t,e,n){if(n&4194240){var i=e.lanes;i&=t.pendingLanes,n|=i,e.lanes=n,Sc(t,n)}}var Ba={readContext:Et,useCallback:We,useContext:We,useEffect:We,useImperativeHandle:We,useInsertionEffect:We,useLayoutEffect:We,useMemo:We,useReducer:We,useRef:We,useState:We,useDebugValue:We,useDeferredValue:We,useTransition:We,useMutableSource:We,useSyncExternalStore:We,useId:We,unstable_isNewReconciler:!1},WT={readContext:Et,useCallback:function(t,e){return Jt().memoizedState=[t,e===void 0?null:e],t},useContext:Et,useEffect:yv,useImperativeHandle:function(t,e,n){return n=n!=null?n.concat([t]):null,ja(4194308,4,wv.bind(null,e,t),n)},useLayoutEffect:function(t,e){return ja(4194308,4,t,e)},useInsertionEffect:function(t,e){return ja(4,2,t,e)},useMemo:function(t,e){var n=Jt();return e=e===void 0?null:e,t=t(),n.memoizedState=[t,e],t},useReducer:function(t,e,n){var i=Jt();return e=n!==void 0?n(e):e,i.memoizedState=i.baseState=e,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:e},i.queue=t,t=t.dispatch=KT.bind(null,Se,t),[i.memoizedState,t]},useRef:function(t){var e=Jt();return t={current:t},e.memoizedState=t},useState:gv,useDebugValue:xd,useDeferredValue:function(t){return Jt().memoizedState=t},useTransition:function(){var t=gv(!1),e=t[0];return t=BT.bind(null,t[1]),Jt().memoizedState=t,[e,t]},useMutableSource:function(){},useSyncExternalStore:function(t,e,n){var i=Se,r=Jt();if(ye){if(n===void 0)throw Error(B(407));n=n()}else{if(n=e(),Re===null)throw Error(B(349));_i&30||dv(i,e,n)}r.memoizedState=n;var s={value:n,getSnapshot:e};return r.queue=s,yv(hv.bind(null,i,s,t),[t]),i.flags|=2048,Bs(9,fv.bind(null,i,s,n,e),void 0,null),n},useId:function(){var t=Jt(),e=Re.identifierPrefix;if(ye){var n=gn,i=mn;n=(i&~(1<<32-jt(i)-1)).toString(32)+n,e=":"+e+"R"+n,n=js++,0<\/script>",t=t.removeChild(t.firstChild)):typeof i.is=="string"?t=o.createElement(n,{is:i.is}):(t=o.createElement(n),n==="select"&&(o=t,i.multiple?o.multiple=!0:i.size&&(o.size=i.size))):t=o.createElementNS(t,n),t[qt]=e,t[As]=i,Xv(t,e,!1,!1),e.stateNode=t;e:{switch(o=fc(n,i),n){case"dialog":pe("cancel",t),pe("close",t),r=i;break;case"iframe":case"object":case"embed":pe("load",t),r=i;break;case"video":case"audio":for(r=0;rMr&&(e.flags|=128,i=!0,Ks(s,!1),e.lanes=4194304)}else{if(!i)if(t=Na(o),t!==null){if(e.flags|=128,i=!0,n=t.updateQueue,n!==null&&(e.updateQueue=n,e.flags|=4),Ks(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!ye)return Ue(e),null}else 2*Te()-s.renderingStartTime>Mr&&n!==1073741824&&(e.flags|=128,i=!0,Ks(s,!1),e.lanes=4194304);s.isBackwards?(o.sibling=e.child,e.child=o):(n=s.last,n!==null?n.sibling=o:e.child=o,s.last=o)}return s.tail!==null?(e=s.tail,s.rendering=e,s.tail=e.sibling,s.renderingStartTime=Te(),e.sibling=null,n=we.current,fe(we,i?n&1|2:n&1),e):(Ue(e),null);case 22:case 23:return Hd(),i=e.memoizedState!==null,t!==null&&t.memoizedState!==null!==i&&(e.flags|=8192),i&&e.mode&1?xt&1073741824&&(Ue(e),e.subtreeFlags&6&&(e.flags|=8192)):Ue(e),null;case 24:return null;case 25:return null}throw Error(B(156,e.tag))}function JT(t,e){switch(Jc(e),e.tag){case 1:return rt(e.type)&&Ta(),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return Tr(),me(it),me(He),fd(),t=e.flags,t&65536&&!(t&128)?(e.flags=t&-65537|128,e):null;case 5:return cd(e),null;case 13:if(me(we),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(B(340));Sr()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return me(we),null;case 4:return Tr(),null;case 10:return sd(e.type._context),null;case 22:case 23:return Hd(),null;case 24:return null;default:return null}}var Ua=!1,Ye=!1,eC=typeof WeakSet=="function"?WeakSet:Set,U=null;function Er(t,e){var n=t.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){$e(t,e,i)}else n.current=null}function Ld(t,e,n){try{n()}catch(i){$e(t,e,i)}}var Zv=!1;function tC(t,e){if(Hc=fa,t=Mg(),Ic(t)){if("selectionStart"in t)var n={start:t.selectionStart,end:t.selectionEnd};else e:{n=(n=t.ownerDocument)&&n.defaultView||window;var i=n.getSelection&&n.getSelection();if(i&&i.rangeCount!==0){n=i.anchorNode;var r=i.anchorOffset,s=i.focusNode;i=i.focusOffset;try{n.nodeType,s.nodeType}catch(S){n=null;break e}var o=0,a=-1,l=-1,u=0,c=0,d=t,f=null;t:for(;;){for(var h;d!==n||r!==0&&d.nodeType!==3||(a=o+r),d!==s||i!==0&&d.nodeType!==3||(l=o+i),d.nodeType===3&&(o+=d.nodeValue.length),(h=d.firstChild)!==null;)f=d,d=h;for(;;){if(d===t)break t;if(f===n&&++u===r&&(a=o),f===s&&++c===i&&(l=o),(h=d.nextSibling)!==null)break;d=f,f=d.parentNode}d=h}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Wc={focusedElem:t,selectionRange:n},fa=!1,U=e;U!==null;)if(e=U,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,U=t;else for(;U!==null;){e=U;try{var g=e.alternate;if(e.flags&1024)switch(e.tag){case 0:case 11:case 15:break;case 1:if(g!==null){var v=g.memoizedProps,b=g.memoizedState,p=e.stateNode,m=p.getSnapshotBeforeUpdate(e.elementType===e.type?v:Kt(e.type,v),b);p.__reactInternalSnapshotBeforeUpdate=m}break;case 3:var y=e.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(B(163))}}catch(S){$e(e,e.return,S)}if(t=e.sibling,t!==null){t.return=e.return,U=t;break}U=e.return}return g=Zv,Zv=!1,g}function Hs(t,e,n){var i=e.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var r=i=i.next;do{if((r.tag&t)===t){var s=r.destroy;r.destroy=void 0,s!==void 0&&Ld(e,n,s)}r=r.next}while(r!==i)}}function Ya(t,e){if(e=e.updateQueue,e=e!==null?e.lastEffect:null,e!==null){var n=e=e.next;do{if((n.tag&t)===t){var i=n.create;n.destroy=i()}n=n.next}while(n!==e)}}function Ad(t){var e=t.ref;if(e!==null){var n=t.stateNode;switch(t.tag){case 5:t=n;break;default:t=n}typeof e=="function"?e(t):e.current=t}}function Jv(t){var e=t.alternate;e!==null&&(t.alternate=null,Jv(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&(delete e[qt],delete e[As],delete e[Xc],delete e[NT],delete e[OT])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function ey(t){return t.tag===5||t.tag===3||t.tag===4}function ty(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||ey(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Rd(t,e,n){var i=t.tag;if(i===5||i===6)t=t.stateNode,e?n.nodeType===8?n.parentNode.insertBefore(t,e):n.insertBefore(t,e):(n.nodeType===8?(e=n.parentNode,e.insertBefore(t,n)):(e=n,e.appendChild(t)),n=n._reactRootContainer,n!=null||e.onclick!==null||(e.onclick=$a));else if(i!==4&&(t=t.child,t!==null))for(Rd(t,e,n),t=t.sibling;t!==null;)Rd(t,e,n),t=t.sibling}function Fd(t,e,n){var i=t.tag;if(i===5||i===6)t=t.stateNode,e?n.insertBefore(t,e):n.appendChild(t);else if(i!==4&&(t=t.child,t!==null))for(Fd(t,e,n),t=t.sibling;t!==null;)Fd(t,e,n),t=t.sibling}var Ve=null,Ht=!1;function Qn(t,e,n){for(n=n.child;n!==null;)ny(t,e,n),n=n.sibling}function ny(t,e,n){if(Qt&&typeof Qt.onCommitFiberUnmount=="function")try{Qt.onCommitFiberUnmount(oa,n)}catch(a){}switch(n.tag){case 5:Ye||Er(n,e);case 6:var i=Ve,r=Ht;Ve=null,Qn(t,e,n),Ve=i,Ht=r,Ve!==null&&(Ht?(t=Ve,n=n.stateNode,t.nodeType===8?t.parentNode.removeChild(n):t.removeChild(n)):Ve.removeChild(n.stateNode));break;case 18:Ve!==null&&(Ht?(t=Ve,n=n.stateNode,t.nodeType===8?Gc(t.parentNode,n):t.nodeType===1&&Gc(t,n),Ss(t)):Gc(Ve,n.stateNode));break;case 4:i=Ve,r=Ht,Ve=n.stateNode.containerInfo,Ht=!0,Qn(t,e,n),Ve=i,Ht=r;break;case 0:case 11:case 14:case 15:if(!Ye&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){r=i=i.next;do{var s=r,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&Ld(n,e,o),r=r.next}while(r!==i)}Qn(t,e,n);break;case 1:if(!Ye&&(Er(n,e),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(a){$e(n,e,a)}Qn(t,e,n);break;case 21:Qn(t,e,n);break;case 22:n.mode&1?(Ye=(i=Ye)||n.memoizedState!==null,Qn(t,e,n),Ye=i):Qn(t,e,n);break;default:Qn(t,e,n)}}function iy(t){var e=t.updateQueue;if(e!==null){t.updateQueue=null;var n=t.stateNode;n===null&&(n=t.stateNode=new eC),e.forEach(function(i){var r=cC.bind(null,t,i);n.has(i)||(n.add(i),i.then(r,r))})}}function Wt(t,e){var n=e.deletions;if(n!==null)for(var i=0;ir&&(r=o),i&=~s}if(i=r,i=Te()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*iC(i/1960))-i,10t?16:t,Zn===null)var i=!1;else{if(t=Zn,Zn=null,Za=0,ne&6)throw Error(B(331));var r=ne;for(ne|=4,U=t.current;U!==null;){var s=U,o=s.child;if(U.flags&16){var a=s.deletions;if(a!==null){for(var l=0;lTe()-Od?Li(t,0):Nd|=n),at(t,e)}function gy(t,e){e===0&&(t.mode&1?(e=la,la<<=1,!(la&130023424)&&(la=4194304)):e=1);var n=et();t=vn(t,e),t!==null&&(vs(t,e,n),at(t,n))}function uC(t){var e=t.memoizedState,n=0;e!==null&&(n=e.retryLane),gy(t,n)}function cC(t,e){var n=0;switch(t.tag){case 13:var i=t.stateNode,r=t.memoizedState;r!==null&&(n=r.retryLane);break;case 19:i=t.stateNode;break;default:throw Error(B(314))}i!==null&&i.delete(e),gy(t,n)}var vy;vy=function(t,e,n){if(t!==null)if(t.memoizedProps!==e.pendingProps||it.current)st=!0;else{if(!(t.lanes&n)&&!(e.flags&128))return st=!1,qT(t,e,n);st=!!(t.flags&131072)}else st=!1,ye&&e.flags&1048576&&Qg(e,Ma,e.index);switch(e.lanes=0,e.tag){case 2:var i=e.type;Wa(t,e),t=e.pendingProps;var r=br(e,He.current);kr(e,n),r=md(null,e,i,t,r,n);var s=gd();return e.flags|=1,typeof r=="object"&&r!==null&&typeof r.render=="function"&&r.$$typeof===void 0?(e.tag=1,e.memoizedState=null,e.updateQueue=null,rt(i)?(s=!0,Ca(e)):s=!1,e.memoizedState=r.state!==null&&r.state!==void 0?r.state:null,ld(e),r.updater=Ka,e.stateNode=r,r._reactInternals=e,Sd(e,i,t,n),e=Td(null,e,i,!0,s,n)):(e.tag=0,ye&&s&&Zc(e),Je(null,e,r,n),e=e.child),e;case 16:i=e.elementType;e:{switch(Wa(t,e),t=e.pendingProps,r=i._init,i=r(i._payload),e.type=i,r=e.tag=fC(i),t=Kt(i,t),r){case 0:e=kd(null,e,i,t,n);break e;case 1:e=Kv(null,e,i,t,n);break e;case 11:e=Ov(null,e,i,t,n);break e;case 14:e=Vv(null,e,i,Kt(i.type,t),n);break e}throw Error(B(306,i,""))}return e;case 0:return i=e.type,r=e.pendingProps,r=e.elementType===i?r:Kt(i,r),kd(t,e,i,r,n);case 1:return i=e.type,r=e.pendingProps,r=e.elementType===i?r:Kt(i,r),Kv(t,e,i,r,n);case 3:e:{if(Hv(e),t===null)throw Error(B(387));i=e.pendingProps,s=e.memoizedState,r=s.element,sv(t,e),Ia(e,i,null,n);var o=e.memoizedState;if(i=o.element,s.isDehydrated)if(s={element:i,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},e.updateQueue.baseState=s,e.memoizedState=s,e.flags&256){r=Cr(Error(B(423)),e),e=Wv(t,e,i,n,r);break e}else if(i!==r){r=Cr(Error(B(424)),e),e=Wv(t,e,i,n,r);break e}else for(bt=Hn(e.stateNode.containerInfo.firstChild),yt=e,ye=!0,Bt=null,n=iv(e,null,i,n),e.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Sr(),i===r){e=bn(t,e,n);break e}Je(t,e,i,n)}e=e.child}return e;case 5:return lv(e),t===null&&td(e),i=e.type,r=e.pendingProps,s=t!==null?t.memoizedProps:null,o=r.children,Uc(i,r)?o=null:s!==null&&Uc(i,s)&&(e.flags|=32),Bv(t,e),Je(t,e,o,n),e.child;case 6:return t===null&&td(e),null;case 13:return Uv(t,e,n);case 4:return ud(e,e.stateNode.containerInfo),i=e.pendingProps,t===null?e.child=Pr(e,null,i,n):Je(t,e,i,n),e.child;case 11:return i=e.type,r=e.pendingProps,r=e.elementType===i?r:Kt(i,r),Ov(t,e,i,r,n);case 7:return Je(t,e,e.pendingProps,n),e.child;case 8:return Je(t,e,e.pendingProps.children,n),e.child;case 12:return Je(t,e,e.pendingProps.children,n),e.child;case 10:e:{if(i=e.type._context,r=e.pendingProps,s=e.memoizedProps,o=r.value,fe(Aa,i._currentValue),i._currentValue=o,s!==null)if(zt(s.value,o)){if(s.children===r.children&&!it.current){e=bn(t,e,n);break e}}else for(s=e.child,s!==null&&(s.return=e);s!==null;){var a=s.dependencies;if(a!==null){o=s.child;for(var l=a.firstContext;l!==null;){if(l.context===i){if(s.tag===1){l=yn(-1,n&-n),l.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}s.lanes|=n,l=s.alternate,l!==null&&(l.lanes|=n),od(s.return,n,e),a.lanes|=n;break}l=l.next}}else if(s.tag===10)o=s.type===e.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(B(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),od(o,n,e),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===e){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}Je(t,e,r.children,n),e=e.child}return e;case 9:return r=e.type,i=e.pendingProps.children,kr(e,n),r=Et(r),i=i(r),e.flags|=1,Je(t,e,i,n),e.child;case 14:return i=e.type,r=Kt(i,e.pendingProps),r=Kt(i.type,r),Vv(t,e,i,r,n);case 15:return jv(t,e,e.type,e.pendingProps,n);case 17:return i=e.type,r=e.pendingProps,r=e.elementType===i?r:Kt(i,r),Wa(t,e),e.tag=1,rt(i)?(t=!0,Ca(e)):t=!1,kr(e,n),Dv(e,i,r),Sd(e,i,r,n),Td(null,e,i,!0,t,n);case 19:return Gv(t,e,n);case 22:return zv(t,e,n)}throw Error(B(156,e.tag))};function yy(t,e){return qm(t,e)}function dC(t,e,n,i){this.tag=t,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Dt(t,e,n,i){return new dC(t,e,n,i)}function Ud(t){return t=t.prototype,!(!t||!t.isReactComponent)}function fC(t){if(typeof t=="function")return Ud(t)?1:0;if(t!=null){if(t=t.$$typeof,t===Zu)return 11;if(t===tc)return 14}return 2}function ti(t,e){var n=t.alternate;return n===null?(n=Dt(t.tag,e,t.key,t.mode),n.elementType=t.elementType,n.type=t.type,n.stateNode=t.stateNode,n.alternate=t,t.alternate=n):(n.pendingProps=e,n.type=t.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=t.flags&14680064,n.childLanes=t.childLanes,n.lanes=t.lanes,n.child=t.child,n.memoizedProps=t.memoizedProps,n.memoizedState=t.memoizedState,n.updateQueue=t.updateQueue,e=t.dependencies,n.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},n.sibling=t.sibling,n.index=t.index,n.ref=t.ref,n}function nl(t,e,n,i,r,s){var o=2;if(i=t,typeof t=="function")Ud(t)&&(o=1);else if(typeof t=="string")o=5;else e:switch(t){case or:return Ri(n.children,r,s,e);case Qu:o=8,r|=8;break;case qu:return t=Dt(12,n,e,r|2),t.elementType=qu,t.lanes=s,t;case Ju:return t=Dt(13,n,e,r),t.elementType=Ju,t.lanes=s,t;case ec:return t=Dt(19,n,e,r),t.elementType=ec,t.lanes=s,t;case Cm:return il(n,r,s,e);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case km:o=10;break e;case Tm:o=9;break e;case Zu:o=11;break e;case tc:o=14;break e;case In:o=16,i=null;break e}throw Error(B(130,t==null?t:typeof t,""))}return e=Dt(o,n,e,r),e.elementType=t,e.type=i,e.lanes=s,e}function Ri(t,e,n,i){return t=Dt(7,t,i,e),t.lanes=n,t}function il(t,e,n,i){return t=Dt(22,t,i,e),t.elementType=Cm,t.lanes=n,t.stateNode={isHidden:!1},t}function Yd(t,e,n){return t=Dt(6,t,null,e),t.lanes=n,t}function Gd(t,e,n){return e=Dt(4,t.children!==null?t.children:[],t.key,e),e.lanes=n,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}function hC(t,e,n,i,r){this.tag=e,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=wc(0),this.expirationTimes=wc(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=wc(0),this.identifierPrefix=i,this.onRecoverableError=r,this.mutableSourceEagerHydrationData=null}function Xd(t,e,n,i,r,s,o,a,l){return t=new hC(t,e,n,a,l),e===1?(e=1,s===!0&&(e|=8)):e=0,s=Dt(3,null,null,e),t.current=s,s.stateNode=t,s.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},ld(s),t}function pC(t,e,n){var i=3
Transition to Salesforce Agentforce assumed to happen over three years. Implementation costs not included. All calculations above done in US dollars.

The results of this tool are provided for illustrative purposes only to help you consider Agentforce as a business solution and should not be relied upon. Actual results may vary and are not a guarantee or commitment regarding any potential or actual financial results or other benefits you may achieve. Individual results depend on factors including but not limited to implementation practices, user adoption, configurations, business practices, market conditions, and external economic factors."},dl=({value:t,locale:e=ge.locale,currency:n=ge.currency})=>{const i=new Intl.NumberFormat(e,{style:"currency",currency:n,maximumFractionDigits:0}).format(t<0?0:t);return D.jsx("span",{children:i})};function bC(t){if(typeof Proxy=="undefined")return t;const e=new Map,n=(...i)=>t(...i);return new Proxy(n,{get:(i,r)=>r==="create"?t:(e.has(r)||e.set(r,t(r)),e.get(r))})}function Xs(t){return t!==null&&typeof t=="object"&&typeof t.start=="function"}const Jd=t=>Array.isArray(t);function Ty(t,e){if(!Array.isArray(e))return!1;const n=e.length;if(n!==t.length)return!1;for(let i=0;i{e[0][i]=n.get(),e[1][i]=n.getVelocity()}),e}function ef(t,e,n,i){if(typeof e=="function"){const[r,s]=Cy(i);e=e(n!==void 0?n:t.custom,r,s)}if(typeof e=="string"&&(e=t.variants&&t.variants[e]),typeof e=="function"){const[r,s]=Cy(i);e=e(n!==void 0?n:t.custom,r,s)}return e}function fl(t,e,n){const i=t.getProps();return ef(i,e,n!==void 0?n:i.custom,t)}const tf=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],nf=["initial",...tf],qs=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],ni=new Set(qs),wn=t=>t*1e3,Sn=t=>t/1e3,xC={type:"spring",stiffness:500,damping:25,restSpeed:10},wC=t=>({type:"spring",stiffness:550,damping:t===0?2*Math.sqrt(550):30,restSpeed:10}),SC={type:"keyframes",duration:.8},PC={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},$C=(t,{keyframes:e})=>e.length>2?SC:ni.has(t)?t.startsWith("scale")?wC(e[1]):xC:PC;function rf(t,e){return t?t[e]||t.default||t:void 0}const kC={skipAnimations:!1,useManualTiming:!1},TC=t=>t!==null;function hl(t,{repeat:e,repeatType:n="loop"},i){const r=t.filter(TC),s=e&&n!=="loop"&&e%2===1?0:r.length-1;return!s||i===void 0?r[s]:i}const ze=t=>t;function CC(t){let e=new Set,n=new Set,i=!1,r=!1;const s=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1};function a(u){s.has(u)&&(l.schedule(u),t()),u(o)}const l={schedule:(u,c=!1,d=!1)=>{const h=d&&i?e:n;return c&&s.add(u),h.has(u)||h.add(u),u},cancel:u=>{n.delete(u),s.delete(u)},process:u=>{if(o=u,i){r=!0;return}i=!0,[e,n]=[n,e],n.clear(),e.forEach(a),i=!1,r&&(r=!1,l.process(u))}};return l}const pl=["read","resolveKeyframes","update","preRender","render","postRender"],EC=40;function Ey(t,e){let n=!1,i=!0;const r={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,o=pl.reduce((p,m)=>(p[m]=CC(s),p),{}),{read:a,resolveKeyframes:l,update:u,preRender:c,render:d,postRender:f}=o,h=()=>{const p=performance.now();n=!1,r.delta=i?1e3/60:Math.max(Math.min(p-r.timestamp,EC),1),r.timestamp=p,r.isProcessing=!0,a.process(r),l.process(r),u.process(r),c.process(r),d.process(r),f.process(r),r.isProcessing=!1,n&&e&&(i=!1,t(h))},g=()=>{n=!0,i=!0,r.isProcessing||t(h)};return{schedule:pl.reduce((p,m)=>{const y=o[m];return p[m]=(S,P=!1,C=!1)=>(n||g(),y.schedule(S,P,C)),p},{}),cancel:p=>{for(let m=0;m(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t,_C=1e-7,MC=12;function DC(t,e,n,i,r){let s,o,a=0;do o=e+(n-e)/2,s=_y(o,i,r)-t,s>0?n=o:e=o;while(Math.abs(s)>_C&&++aDC(s,0,1,t,n);return s=>s===0||s===1?s:_y(r(s),e,i)}const My=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,Dy=t=>e=>1-t(1-e),Ly=Zs(.33,1.53,.69,.99),of=Dy(Ly),Ay=My(of),Ry=t=>(t*=2)<1?.5*of(t):.5*(2-Math.pow(2,-10*(t-1))),af=t=>1-Math.sin(Math.acos(t)),Fy=Dy(af),Iy=My(af),Ny=t=>/^0[^.\s]+$/u.test(t);function LC(t){return typeof t=="number"?t===0:t!==null?t==="none"||t==="0"||Ny(t):!0}let AC=ze,lf=ze;const Oy=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),Vy=t=>e=>typeof e=="string"&&e.startsWith(t),jy=Vy("--"),RC=Vy("var(--"),uf=t=>RC(t)?FC.test(t.split("/*")[0].trim()):!1,FC=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,IC=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function NC(t){const e=IC.exec(t);if(!e)return[,];const[,n,i,r]=e;return[`--${n!=null?n:i}`,r]}function zy(t,e,n=1){const[i,r]=NC(t);if(!i)return;const s=window.getComputedStyle(e).getPropertyValue(i);if(s){const o=s.trim();return Oy(o)?parseFloat(o):o}return uf(r)?zy(r,e,n+1):r}const ii=(t,e,n)=>n>e?e:ntypeof t=="number",parse:parseFloat,transform:t=>t},Js=V(k({},Lr),{transform:t=>ii(0,1,t)}),ml=V(k({},Lr),{default:1}),eo=t=>({test:e=>typeof e=="string"&&e.endsWith(t)&&e.split(" ").length===1,parse:parseFloat,transform:e=>`${e}${t}`}),ri=eo("deg"),nn=eo("%"),Y=eo("px"),OC=eo("vh"),VC=eo("vw"),By=V(k({},nn),{parse:t=>nn.parse(t)/100,transform:t=>nn.transform(t*100)}),jC=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),Ky=t=>t===Lr||t===Y,Hy=(t,e)=>parseFloat(t.split(", ")[e]),Wy=(t,e)=>(n,{transform:i})=>{if(i==="none"||!i)return 0;const r=i.match(/^matrix3d\((.+)\)$/u);if(r)return Hy(r[1],e);{const s=i.match(/^matrix\((.+)\)$/u);return s?Hy(s[1],t):0}},zC=new Set(["x","y","z"]),BC=qs.filter(t=>!zC.has(t));function KC(t){const e=[];return BC.forEach(n=>{const i=t.getValue(n);i!==void 0&&(e.push([n,i.get()]),i.set(n.startsWith("scale")?1:0))}),e}const Ar={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:Wy(4,13),y:Wy(5,14)};Ar.translateX=Ar.x,Ar.translateY=Ar.y;const Uy=t=>e=>e.test(t),Yy=[Lr,Y,nn,ri,VC,OC,{test:t=>t==="auto",parse:t=>t}],Gy=t=>Yy.find(Uy(t)),Fi=new Set;let cf=!1,df=!1;function Xy(){if(df){const t=Array.from(Fi).filter(i=>i.needsMeasurement),e=new Set(t.map(i=>i.element)),n=new Map;e.forEach(i=>{const r=KC(i);r.length&&(n.set(i,r),i.render())}),t.forEach(i=>i.measureInitialState()),e.forEach(i=>{i.render();const r=n.get(i);r&&r.forEach(([s,o])=>{var a;(a=i.getValue(s))===null||a===void 0||a.set(o)})}),t.forEach(i=>i.measureEndState()),t.forEach(i=>{i.suspendedScrollY!==void 0&&window.scrollTo(0,i.suspendedScrollY)})}df=!1,cf=!1,Fi.forEach(t=>t.complete()),Fi.clear()}function Qy(){Fi.forEach(t=>{t.readKeyframes(),t.needsMeasurement&&(df=!0)})}function HC(){Qy(),Xy()}class ff{constructor(e,n,i,r,s,o=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...e],this.onComplete=n,this.name=i,this.motionValue=r,this.element=s,this.isAsync=o}scheduleResolve(){this.isScheduled=!0,this.isAsync?(Fi.add(this),cf||(cf=!0,ie.read(Qy),ie.resolveKeyframes(Xy))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:e,name:n,element:i,motionValue:r}=this;for(let s=0;sMath.round(t*1e5)/1e5,hf=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function WC(t){return t==null}const UC=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,pf=(t,e)=>n=>!!(typeof n=="string"&&UC.test(n)&&n.startsWith(t)||e&&!WC(n)&&Object.prototype.hasOwnProperty.call(n,e)),qy=(t,e,n)=>i=>{if(typeof i!="string")return i;const[r,s,o,a]=i.match(hf);return{[t]:parseFloat(r),[e]:parseFloat(s),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},YC=t=>ii(0,255,t),mf=V(k({},Lr),{transform:t=>Math.round(YC(t))}),Ii={test:pf("rgb","red"),parse:qy("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:i=1})=>"rgba("+mf.transform(t)+", "+mf.transform(e)+", "+mf.transform(n)+", "+to(Js.transform(i))+")"};function GC(t){let e="",n="",i="",r="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),i=t.substring(5,7),r=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),i=t.substring(3,4),r=t.substring(4,5),e+=e,n+=n,i+=i,r+=r),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(i,16),alpha:r?parseInt(r,16)/255:1}}const gf={test:pf("#"),parse:GC,transform:Ii.transform},Rr={test:pf("hsl","hue"),parse:qy("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:i=1})=>"hsla("+Math.round(t)+", "+nn.transform(to(e))+", "+nn.transform(to(n))+", "+to(Js.transform(i))+")"},Ge={test:t=>Ii.test(t)||gf.test(t)||Rr.test(t),parse:t=>Ii.test(t)?Ii.parse(t):Rr.test(t)?Rr.parse(t):gf.parse(t),transform:t=>typeof t=="string"?t:t.hasOwnProperty("red")?Ii.transform(t):Rr.transform(t)},XC=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function QC(t){var e,n;return isNaN(t)&&typeof t=="string"&&(((e=t.match(hf))===null||e===void 0?void 0:e.length)||0)+(((n=t.match(XC))===null||n===void 0?void 0:n.length)||0)>0}const Zy="number",Jy="color",qC="var",ZC="var(",e0="${}",JC=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function no(t){const e=t.toString(),n=[],i={color:[],number:[],var:[]},r=[];let s=0;const a=e.replace(JC,l=>(Ge.test(l)?(i.color.push(s),r.push(Jy),n.push(Ge.parse(l))):l.startsWith(ZC)?(i.var.push(s),r.push(qC),n.push(l)):(i.number.push(s),r.push(Zy),n.push(parseFloat(l))),++s,e0)).split(e0);return{values:n,split:a,indexes:i,types:r}}function t0(t){return no(t).values}function n0(t){const{split:e,types:n}=no(t),i=e.length;return r=>{let s="";for(let o=0;otypeof t=="number"?0:t;function tE(t){const e=t0(t);return n0(t)(e.map(eE))}const si={test:QC,parse:t0,createTransformer:n0,getAnimatableNone:tE},nE=new Set(["brightness","contrast","saturate","opacity"]);function iE(t){const[e,n]=t.slice(0,-1).split("(");if(e==="drop-shadow")return t;const[i]=n.match(hf)||[];if(!i)return t;const r=n.replace(i,"");let s=nE.has(e)?1:0;return i!==n&&(s*=100),e+"("+s+r+")"}const rE=/\b([a-z-]*)\(.*?\)/gu,vf=V(k({},si),{getAnimatableNone:t=>{const e=t.match(rE);return e?e.map(iE).join(" "):t}}),sE={borderWidth:Y,borderTopWidth:Y,borderRightWidth:Y,borderBottomWidth:Y,borderLeftWidth:Y,borderRadius:Y,radius:Y,borderTopLeftRadius:Y,borderTopRightRadius:Y,borderBottomRightRadius:Y,borderBottomLeftRadius:Y,width:Y,maxWidth:Y,height:Y,maxHeight:Y,top:Y,right:Y,bottom:Y,left:Y,padding:Y,paddingTop:Y,paddingRight:Y,paddingBottom:Y,paddingLeft:Y,margin:Y,marginTop:Y,marginRight:Y,marginBottom:Y,marginLeft:Y,backgroundPositionX:Y,backgroundPositionY:Y},oE={rotate:ri,rotateX:ri,rotateY:ri,rotateZ:ri,scale:ml,scaleX:ml,scaleY:ml,scaleZ:ml,skew:ri,skewX:ri,skewY:ri,distance:Y,translateX:Y,translateY:Y,translateZ:Y,x:Y,y:Y,z:Y,perspective:Y,transformPerspective:Y,opacity:Js,originX:By,originY:By,originZ:Y},i0=V(k({},Lr),{transform:Math.round}),yf=V(k(k({},sE),oE),{zIndex:i0,size:Y,fillOpacity:Js,strokeOpacity:Js,numOctaves:i0}),aE=V(k({},yf),{color:Ge,backgroundColor:Ge,outlineColor:Ge,fill:Ge,stroke:Ge,borderColor:Ge,borderTopColor:Ge,borderRightColor:Ge,borderBottomColor:Ge,borderLeftColor:Ge,filter:vf,WebkitFilter:vf}),bf=t=>aE[t];function r0(t,e){let n=bf(t);return n!==vf&&(n=si),n.getAnimatableNone?n.getAnimatableNone(e):void 0}const lE=new Set(["auto","none","0"]);function uE(t,e,n){let i=0,r;for(;i{n.getValue(l).set(u)}),this.resolveNoneKeyframes()}}function xf(t){return typeof t=="function"}let gl;function cE(){gl=void 0}const rn={now:()=>(gl===void 0&&rn.set(Fe.isProcessing||kC.useManualTiming?Fe.timestamp:performance.now()),gl),set:t=>{gl=t,queueMicrotask(cE)}},o0=(t,e)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(si.test(t)||t==="0")&&!t.startsWith("url("));function dE(t){const e=t[0];if(t.length===1)return!0;for(let n=0;nhE?this.resolvedAt:this.createdAt:this.createdAt}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&HC(),this._resolved}onKeyframesResolved(e,n){this.resolvedAt=rn.now(),this.hasAttemptedResolve=!0;const{name:i,type:r,velocity:s,delay:o,onComplete:a,onUpdate:l,isGenerator:u}=this.options;if(!u&&!fE(e,i,r,s))if(o)this.options.duration=0;else{l==null||l(hl(e,this.options,n)),a==null||a(),this.resolveFinishedPromise();return}const c=this.initPlayback(e,n);c!==!1&&(this._resolved=k({keyframes:e,finalKeyframe:n},c),this.onPostResolved())}onPostResolved(){}then(e,n){return this.currentFinishedPromise.then(e,n)}updateFinishedPromise(){this.currentFinishedPromise=new Promise(e=>{this.resolveFinishedPromise=e})}}function wf(t,e){return e?t*(1e3/e):0}const pE=5;function l0(t,e,n){const i=Math.max(e-pE,0);return wf(n-t(i),e-i)}const Sf=.001,mE=.01,gE=10,vE=.05,yE=1;function bE({duration:t=800,bounce:e=.25,velocity:n=0,mass:i=1}){let r,s,o=1-e;o=ii(vE,yE,o),t=ii(mE,gE,Sn(t)),o<1?(r=u=>{const c=u*o,d=c*t,f=c-n,h=Pf(u,o),g=Math.exp(-d);return Sf-f/h*g},s=u=>{const d=u*o*t,f=d*n+n,h=Math.pow(o,2)*Math.pow(u,2)*t,g=Math.exp(-d),v=Pf(Math.pow(u,2),o);return(-r(u)+Sf>0?-1:1)*((f-h)*g)/v}):(r=u=>{const c=Math.exp(-u*t),d=(u-n)*t+1;return-Sf+c*d},s=u=>{const c=Math.exp(-u*t),d=(n-u)*(t*t);return c*d});const a=5/t,l=wE(r,s,a);if(t=wn(t),isNaN(l))return{stiffness:100,damping:10,duration:t};{const u=Math.pow(l,2)*i;return{stiffness:u,damping:o*2*Math.sqrt(i*u),duration:t}}}const xE=12;function wE(t,e,n){let i=n;for(let r=1;rt[n]!==void 0)}function $E(t){let e=k({velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1},t);if(!u0(t,PE)&&u0(t,SE)){const n=bE(t);e=V(k(k({},e),n),{mass:1}),e.isResolvedFromDuration=!0}return e}function c0(r){var s=r,{keyframes:t,restDelta:e,restSpeed:n}=s,i=ee(s,["keyframes","restDelta","restSpeed"]);const o=t[0],a=t[t.length-1],l={done:!1,value:o},{stiffness:u,damping:c,mass:d,duration:f,velocity:h,isResolvedFromDuration:g}=$E(V(k({},i),{velocity:-Sn(i.velocity||0)})),v=h||0,b=c/(2*Math.sqrt(u*d)),p=a-o,m=Sn(Math.sqrt(u/d)),y=Math.abs(p)<5;n||(n=y?.01:2),e||(e=y?.005:.5);let S;if(b<1){const P=Pf(m,b);S=C=>{const L=Math.exp(-b*m*C);return a-L*((v+b*m*p)/P*Math.sin(P*C)+p*Math.cos(P*C))}}else if(b===1)S=P=>a-Math.exp(-m*P)*(p+(v+m*p)*P);else{const P=m*Math.sqrt(b*b-1);S=C=>{const L=Math.exp(-b*m*C),_=Math.min(P*C,300);return a-L*((v+b*m*p)*Math.sinh(_)+P*p*Math.cosh(_))/P}}return{calculatedDuration:g&&f||null,next:P=>{const C=S(P);if(g)l.done=P>=f;else{let L=0;b<1&&(L=P===0?wn(v):l0(S,P,C));const _=Math.abs(L)<=n,w=Math.abs(a-C)<=e;l.done=_&&w}return l.value=l.done?a:C,l}}}function d0({keyframes:t,velocity:e=0,power:n=.8,timeConstant:i=325,bounceDamping:r=10,bounceStiffness:s=500,modifyTarget:o,min:a,max:l,restDelta:u=.5,restSpeed:c}){const d=t[0],f={done:!1,value:d},h=_=>a!==void 0&&_l,g=_=>a===void 0?l:l===void 0||Math.abs(a-_)-v*Math.exp(-_/i),y=_=>p+m(_),S=_=>{const w=m(_),$=y(_);f.done=Math.abs(w)<=u,f.value=f.done?p:$};let P,C;const L=_=>{h(f.value)&&(P=_,C=c0({keyframes:[f.value,g(f.value)],velocity:l0(y,_,f.value),damping:r,stiffness:s,restDelta:u,restSpeed:c}))};return L(0),{calculatedDuration:null,next:_=>{let w=!1;return!C&&P===void 0&&(w=!0,S(_),L(_)),P!==void 0&&_>=P?C.next(_-P):(!w&&S(_),f)}}}const kE=Zs(.42,0,1,1),TE=Zs(0,0,.58,1),f0=Zs(.42,0,.58,1),CE=t=>Array.isArray(t)&&typeof t[0]!="number",$f=t=>Array.isArray(t)&&typeof t[0]=="number",h0={linear:ze,easeIn:kE,easeInOut:f0,easeOut:TE,circIn:af,circInOut:Iy,circOut:Fy,backIn:of,backInOut:Ay,backOut:Ly,anticipate:Ry},p0=t=>{if($f(t)){lf(t.length===4);const[e,n,i,r]=t;return Zs(e,n,i,r)}else if(typeof t=="string")return lf(h0[t]!==void 0),h0[t];return t},EE=(t,e)=>n=>e(t(n)),Pn=(...t)=>t.reduce(EE),Ni=(t,e,n)=>{const i=e-t;return i===0?1:(n-t)/i},Pe=(t,e,n)=>t+(e-t)*n;function kf(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+(e-t)*6*n:n<1/2?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function _E({hue:t,saturation:e,lightness:n,alpha:i}){t/=360,e/=100,n/=100;let r=0,s=0,o=0;if(!e)r=s=o=n;else{const a=n<.5?n*(1+e):n+e-n*e,l=2*n-a;r=kf(l,a,t+1/3),s=kf(l,a,t),o=kf(l,a,t-1/3)}return{red:Math.round(r*255),green:Math.round(s*255),blue:Math.round(o*255),alpha:i}}function vl(t,e){return n=>n>0?e:t}const Tf=(t,e,n)=>{const i=t*t,r=n*(e*e-i)+i;return r<0?0:Math.sqrt(r)},ME=[gf,Ii,Rr],DE=t=>ME.find(e=>e.test(t));function m0(t){const e=DE(t);if(!e)return!1;let n=e.parse(t);return e===Rr&&(n=_E(n)),n}const g0=(t,e)=>{const n=m0(t),i=m0(e);if(!n||!i)return vl(t,e);const r=k({},n);return s=>(r.red=Tf(n.red,i.red,s),r.green=Tf(n.green,i.green,s),r.blue=Tf(n.blue,i.blue,s),r.alpha=Pe(n.alpha,i.alpha,s),Ii.transform(r))},Cf=new Set(["none","hidden"]);function LE(t,e){return Cf.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}function AE(t,e){return n=>Pe(t,e,n)}function Ef(t){return typeof t=="number"?AE:typeof t=="string"?uf(t)?vl:Ge.test(t)?g0:IE:Array.isArray(t)?v0:typeof t=="object"?Ge.test(t)?g0:RE:vl}function v0(t,e){const n=[...t],i=n.length,r=t.map((s,o)=>Ef(s)(s,e[o]));return s=>{for(let o=0;o{for(const s in i)n[s]=i[s](r);return n}}function FE(t,e){var n;const i=[],r={color:0,var:0,number:0};for(let s=0;s{const n=si.createTransformer(e),i=no(t),r=no(e);return i.indexes.var.length===r.indexes.var.length&&i.indexes.color.length===r.indexes.color.length&&i.indexes.number.length>=r.indexes.number.length?Cf.has(t)&&!r.values.length||Cf.has(e)&&!i.values.length?LE(t,e):Pn(v0(FE(i,r),r.values),n):vl(t,e)};function y0(t,e,n){return typeof t=="number"&&typeof e=="number"&&typeof n=="number"?Pe(t,e,n):Ef(t)(t,e)}function NE(t,e,n){const i=[],r=n||y0,s=t.length-1;for(let o=0;oe[0];if(s===2&&t[0]===t[1])return()=>e[1];t[0]>t[s-1]&&(t=[...t].reverse(),e=[...e].reverse());const o=NE(e,i,r),a=o.length,l=u=>{let c=0;if(a>1)for(;cl(ii(t[0],t[s-1],u)):l}function OE(t,e){const n=t[t.length-1];for(let i=1;i<=e;i++){const r=Ni(0,e,i);t.push(Pe(n,1,r))}}function x0(t){const e=[0];return OE(e,t.length-1),e}function VE(t,e){return t.map(n=>n*e)}function jE(t,e){return t.map(()=>e||f0).splice(0,t.length-1)}function yl({duration:t=300,keyframes:e,times:n,ease:i="easeInOut"}){const r=CE(i)?i.map(p0):p0(i),s={done:!1,value:e[0]},o=VE(n&&n.length===e.length?n:x0(e),t),a=b0(o,e,{ease:Array.isArray(r)?r:jE(e,r)});return{calculatedDuration:t,next:l=>(s.value=a(l),s.done=l>=t,s)}}const w0=2e4;function zE(t){let e=0;const n=50;let i=t.next(e);for(;!i.done&&e=w0?1/0:e}const BE=t=>{const e=({timestamp:n})=>t(n);return{start:()=>ie.update(e,!0),stop:()=>tn(e),now:()=>Fe.isProcessing?Fe.timestamp:rn.now()}},KE={decay:d0,inertia:d0,tween:yl,keyframes:yl,spring:c0},HE=t=>t/100;class _f extends a0{constructor(e){super(e),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();const{onStop:l}=this.options;l&&l()};const{name:n,motionValue:i,element:r,keyframes:s}=this.options,o=(r==null?void 0:r.KeyframeResolver)||ff,a=(l,u)=>this.onKeyframesResolved(l,u);this.resolver=new o(s,a,n,i,r),this.resolver.scheduleResolve()}initPlayback(e){const{type:n="keyframes",repeat:i=0,repeatDelay:r=0,repeatType:s,velocity:o=0}=this.options,a=xf(n)?n:KE[n]||yl;let l,u;a!==yl&&typeof e[0]!="number"&&(l=Pn(HE,y0(e[0],e[1])),e=[0,100]);const c=a(V(k({},this.options),{keyframes:e}));s==="mirror"&&(u=a(V(k({},this.options),{keyframes:[...e].reverse(),velocity:-o}))),c.calculatedDuration===null&&(c.calculatedDuration=zE(c));const{calculatedDuration:d}=c,f=d+r,h=f*(i+1)-r;return{generator:c,mirroredGenerator:u,mapPercentToKeyframes:l,calculatedDuration:d,resolvedDuration:f,totalDuration:h}}onPostResolved(){const{autoplay:e=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!e?this.pause():this.state=this.pendingPlayState}tick(e,n=!1){const{resolved:i}=this;if(!i){const{keyframes:_}=this.options;return{done:!0,value:_[_.length-1]}}const{finalKeyframe:r,generator:s,mirroredGenerator:o,mapPercentToKeyframes:a,keyframes:l,calculatedDuration:u,totalDuration:c,resolvedDuration:d}=i;if(this.startTime===null)return s.next(0);const{delay:f,repeat:h,repeatType:g,repeatDelay:v,onUpdate:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-c/this.speed,this.startTime)),n?this.currentTime=e:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(e-this.startTime)*this.speed;const p=this.currentTime-f*(this.speed>=0?1:-1),m=this.speed>=0?p<0:p>c;this.currentTime=Math.max(p,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=c);let y=this.currentTime,S=s;if(h){const _=Math.min(this.currentTime,c)/d;let w=Math.floor(_),$=_%1;!$&&_>=1&&($=1),$===1&&w--,w=Math.min(w,h+1),!!(w%2)&&(g==="reverse"?($=1-$,v&&($-=v/d)):g==="mirror"&&(S=o)),y=ii(0,1,$)*d}const P=m?{done:!1,value:l[0]}:S.next(y);a&&(P.value=a(P.value));let{done:C}=P;!m&&u!==null&&(C=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const L=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&C);return L&&r!==void 0&&(P.value=hl(l,this.options,r)),b&&b(P.value),L&&this.finish(),P}get duration(){const{resolved:e}=this;return e?Sn(e.calculatedDuration):0}get time(){return Sn(this.currentTime)}set time(e){e=wn(e),this.currentTime=e,this.holdTime!==null||this.speed===0?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.speed)}get speed(){return this.playbackSpeed}set speed(e){const n=this.playbackSpeed!==e;this.playbackSpeed=e,n&&(this.time=Sn(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;const{driver:e=BE,onPlay:n,startTime:i}=this.options;this.driver||(this.driver=e(s=>this.tick(s))),n&&n();const r=this.driver.now();this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime?this.state==="finished"&&(this.startTime=r):this.startTime=i!=null?i:this.calcStartTime(),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var e;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(e=this.currentTime)!==null&&e!==void 0?e:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:e}=this.options;e&&e()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}}const S0=new Set(["opacity","clipPath","filter","transform"]),WE=10,UE=(t,e)=>{let n="";const i=Math.max(Math.round(e/WE),2);for(let r=0;r(e===void 0&&(e=t()),e)}const YE={linearEasing:void 0};function GE(t,e){const n=Mf(t);return()=>{var i;return(i=YE[e])!==null&&i!==void 0?i:n()}}const bl=GE(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(t){return!1}return!0},"linearEasing");function P0(t){return!!(typeof t=="function"&&bl()||!t||typeof t=="string"&&(t in Df||bl())||$f(t)||Array.isArray(t)&&t.every(P0))}const io=([t,e,n,i])=>`cubic-bezier(${t}, ${e}, ${n}, ${i})`,Df={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:io([0,.65,.55,1]),circOut:io([.55,0,1,.45]),backIn:io([.31,.01,.66,-.59]),backOut:io([.33,1.53,.69,.99])};function $0(t,e){if(t)return typeof t=="function"&&bl()?UE(t,e):$f(t)?io(t):Array.isArray(t)?t.map(n=>$0(n,e)||Df.easeOut):Df[t]}function XE(t,e,n,{delay:i=0,duration:r=300,repeat:s=0,repeatType:o="loop",ease:a,times:l}={}){const u={[e]:n};l&&(u.offset=l);const c=$0(a,r);return Array.isArray(c)&&(u.easing=c),t.animate(u,{delay:i,duration:r,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:s+1,direction:o==="reverse"?"alternate":"normal"})}function k0(t,e){t.timeline=e,t.onfinish=null}const QE=Mf(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),xl=10,qE=2e4;function ZE(t){return xf(t.type)||t.type==="spring"||!P0(t.ease)}function JE(t,e){const n=new _f(V(k({},e),{keyframes:t,repeat:0,delay:0,isGenerator:!0}));let i={done:!1,value:t[0]};const r=[];let s=0;for(;!i.done&&sthis.onKeyframesResolved(o,a),n,i,r),this.resolver.scheduleResolve()}initPlayback(e,n){var i;let{duration:r=300,times:s,ease:o,type:a,motionValue:l,name:u,startTime:c}=this.options;if(!(!((i=l.owner)===null||i===void 0)&&i.current))return!1;if(typeof o=="string"&&bl()&&e2(o)&&(o=T0[o]),ZE(this.options)){const f=this.options,{onComplete:h,onUpdate:g,motionValue:v,element:b}=f,p=ee(f,["onComplete","onUpdate","motionValue","element"]),m=JE(e,p);e=m.keyframes,e.length===1&&(e[1]=e[0]),r=m.duration,s=m.times,o=m.ease,a="keyframes"}const d=XE(l.owner.current,u,e,V(k({},this.options),{duration:r,times:s,ease:o}));return d.startTime=c!=null?c:this.calcStartTime(),this.pendingTimeline?(k0(d,this.pendingTimeline),this.pendingTimeline=void 0):d.onfinish=()=>{const{onComplete:h}=this.options;l.set(hl(e,this.options,n)),h&&h(),this.cancel(),this.resolveFinishedPromise()},{animation:d,duration:r,times:s,type:a,ease:o,keyframes:e}}get duration(){const{resolved:e}=this;if(!e)return 0;const{duration:n}=e;return Sn(n)}get time(){const{resolved:e}=this;if(!e)return 0;const{animation:n}=e;return Sn(n.currentTime||0)}set time(e){const{resolved:n}=this;if(!n)return;const{animation:i}=n;i.currentTime=wn(e)}get speed(){const{resolved:e}=this;if(!e)return 1;const{animation:n}=e;return n.playbackRate}set speed(e){const{resolved:n}=this;if(!n)return;const{animation:i}=n;i.playbackRate=e}get state(){const{resolved:e}=this;if(!e)return"idle";const{animation:n}=e;return n.playState}get startTime(){const{resolved:e}=this;if(!e)return null;const{animation:n}=e;return n.startTime}attachTimeline(e){if(!this._resolved)this.pendingTimeline=e;else{const{resolved:n}=this;if(!n)return ze;const{animation:i}=n;k0(i,e)}return ze}play(){if(this.isStopped)return;const{resolved:e}=this;if(!e)return;const{animation:n}=e;n.playState==="finished"&&this.updateFinishedPromise(),n.play()}pause(){const{resolved:e}=this;if(!e)return;const{animation:n}=e;n.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:e}=this;if(!e)return;const{animation:n,keyframes:i,duration:r,type:s,ease:o,times:a}=e;if(n.playState==="idle"||n.playState==="finished")return;if(this.time){const u=this.options,{motionValue:c,onUpdate:d,onComplete:f,element:h}=u,g=ee(u,["motionValue","onUpdate","onComplete","element"]),v=new _f(V(k({},g),{keyframes:i,duration:r,type:s,ease:o,times:a,isGenerator:!0})),b=wn(this.time);c.setWithVelocity(v.sample(b-xl).value,v.sample(b).value,xl)}const{onStop:l}=this.options;l&&l(),this.cancel()}complete(){const{resolved:e}=this;e&&e.animation.finish()}cancel(){const{resolved:e}=this;e&&e.animation.cancel()}static supports(e){const{motionValue:n,name:i,repeatDelay:r,repeatType:s,damping:o,type:a}=e;return QE()&&i&&S0.has(i)&&n&&n.owner&&n.owner.current instanceof HTMLElement&&!n.owner.getProps().onUpdate&&!r&&s!=="mirror"&&o!==0&&a!=="inertia"}}const E0=Mf(()=>window.ScrollTimeline!==void 0);class t2{constructor(e){this.stop=()=>this.runAll("stop"),this.animations=e.filter(Boolean)}then(e,n){return Promise.all(this.animations).then(e).catch(n)}getAll(e){return this.animations[0][e]}setAll(e,n){for(let i=0;iE0()&&r.attachTimeline?r.attachTimeline(e):n(r));return()=>{i.forEach((r,s)=>{r&&r(),this.animations[s].stop()})}}get time(){return this.getAll("time")}set time(e){this.setAll("time",e)}get speed(){return this.getAll("speed")}set speed(e){this.setAll("speed",e)}get startTime(){return this.getAll("startTime")}get duration(){let e=0;for(let n=0;nn[e]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}function n2(d){var f=d,{when:t,delay:e,delayChildren:n,staggerChildren:i,staggerDirection:r,repeat:s,repeatType:o,repeatDelay:a,from:l,elapsed:u}=f,c=ee(f,["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);return!!Object.keys(c).length}const Lf=(t,e,n,i={},r,s)=>o=>{const a=rf(i,t)||{},l=a.delay||i.delay||0;let{elapsed:u=0}=i;u=u-wn(l);let c=V(k({keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:e.getVelocity()},a),{delay:-u,onUpdate:f=>{e.set(f),a.onUpdate&&a.onUpdate(f)},onComplete:()=>{o(),a.onComplete&&a.onComplete()},name:t,motionValue:e,element:s?void 0:r});n2(a)||(c=k(k({},c),$C(t,c))),c.duration&&(c.duration=wn(c.duration)),c.repeatDelay&&(c.repeatDelay=wn(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let d=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(c.duration=0,c.delay===0&&(d=!0)),d&&!s&&e.get()!==void 0){const f=hl(c.keyframes,a);if(f!==void 0)return ie.update(()=>{c.onUpdate(f),c.onComplete()}),new t2([])}return!s&&C0.supports(c)?new C0(c):new _f(c)},i2=t=>!!(t&&typeof t=="object"&&t.mix&&t.toValue),r2=t=>Jd(t)?t[t.length-1]||0:t;function Af(t,e){t.indexOf(e)===-1&&t.push(e)}function Rf(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}class Ff{constructor(){this.subscriptions=[]}add(e){return Af(this.subscriptions,e),()=>Rf(this.subscriptions,e)}notify(e,n,i){const r=this.subscriptions.length;if(r)if(r===1)this.subscriptions[0](e,n,i);else for(let s=0;s!isNaN(parseFloat(t));class o2{constructor(e,n={}){this.version="11.11.9",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(i,r=!0)=>{const s=rn.now();this.updatedAt!==s&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(i),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),r&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(e),this.owner=n.owner}setCurrent(e){this.current=e,this.updatedAt=rn.now(),this.canTrackVelocity===null&&e!==void 0&&(this.canTrackVelocity=s2(this.current))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,n){this.events[e]||(this.events[e]=new Ff);const i=this.events[e].add(n);return e==="change"?()=>{i(),ie.read(()=>{this.events.change.getSize()||this.stop()})}:i}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,n){this.passiveEffect=e,this.stopPassiveEffect=n}set(e,n=!0){!n||!this.passiveEffect?this.updateAndNotify(e,n):this.passiveEffect(e,this.updateAndNotify)}setWithVelocity(e,n,i){this.set(n),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-i}jump(e,n=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const e=rn.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||e-this.updatedAt>_0)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,_0);return wf(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(e){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=e(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function $n(t,e){return new o2(t,e)}function a2(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,$n(n))}function l2(t,e){let o=fl(t,e)||{},{transitionEnd:i={},transition:r={}}=o,s=ee(o,["transitionEnd","transition"]);s=k(k({},s),i);for(const a in s){const l=r2(s[a]);a2(t,a,l)}}const wl=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),M0="data-"+wl("framerAppearId");function D0(t){return t.props[M0]}const Xe=t=>!!(t&&t.getVelocity);function u2(t){return!!(Xe(t)&&t.add)}function If(t,e){if(!t.applyWillChange)return;const n=t.getValue("willChange");if(u2(n))return n.add(e)}function c2({protectedKeys:t,needsAnimating:e},n){const i=t.hasOwnProperty(n)&&e[n]!==!0;return e[n]=!1,i}function L0(t,e,{delay:n=0,transitionOverride:i,type:r}={}){var s;let d=e,{transition:o=t.getDefaultTransition(),transitionEnd:a}=d,l=ee(d,["transition","transitionEnd"]);i&&(o=i);const u=[],c=r&&t.animationState&&t.animationState.getState()[r];for(const f in l){const h=t.getValue(f,(s=t.latestValues[f])!==null&&s!==void 0?s:null),g=l[f];if(g===void 0||c&&c2(c,f))continue;const v=k({delay:n},rf(o||{},f));let b=!1;if(window.MotionHandoffAnimation){const m=D0(t);if(m){const y=window.MotionHandoffAnimation(m,f,ie);y!==null&&(v.startTime=y,b=!0)}}If(t,f),h.start(Lf(f,h,g,t.shouldReduceMotion&&ni.has(f)?{type:!1}:v,t,b));const p=h.animation;p&&u.push(p)}return a&&Promise.all(u).then(()=>{ie.update(()=>{a&&l2(t,a)})}),u}function Nf(t,e,n={}){var i;const r=fl(t,e,n.type==="exit"?(i=t.presenceContext)===null||i===void 0?void 0:i.custom:void 0);let{transition:s=t.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(s=n.transitionOverride);const o=r?()=>Promise.all(L0(t,r,n)):()=>Promise.resolve(),a=t.variantChildren&&t.variantChildren.size?(u=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:f}=s;return d2(t,e,c+u,d,f,n)}:()=>Promise.resolve(),{when:l}=s;if(l){const[u,c]=l==="beforeChildren"?[o,a]:[a,o];return u().then(()=>c())}else return Promise.all([o(),a(n.delay)])}function d2(t,e,n=0,i=0,r=1,s){const o=[],a=(t.variantChildren.size-1)*i,l=r===1?(u=0)=>u*i:(u=0)=>a-u*i;return Array.from(t.variantChildren).sort(f2).forEach((u,c)=>{u.notify("AnimationStart",e),o.push(Nf(u,e,V(k({},s),{delay:n+l(c)})).then(()=>u.notify("AnimationComplete",e)))}),Promise.all(o)}function f2(t,e){return t.sortNodePosition(e)}function h2(t,e,n={}){t.notify("AnimationStart",e);let i;if(Array.isArray(e)){const r=e.map(s=>Nf(t,s,n));i=Promise.all(r)}else if(typeof e=="string")i=Nf(t,e,n);else{const r=typeof e=="function"?fl(t,e,n.custom):e;i=Promise.all(L0(t,r,n))}return i.then(()=>{t.notify("AnimationComplete",e)})}const p2=nf.length;function A0(t){if(!t)return;if(!t.isControllingVariants){const n=t.parent?A0(t.parent)||{}:{};return t.props.initial!==void 0&&(n.initial=t.props.initial),n}const e={};for(let n=0;nPromise.all(e.map(({animation:n,options:i})=>h2(t,n,i)))}function y2(t){let e=v2(t),n=R0(),i=!0;const r=l=>(u,c)=>{var d;const f=fl(t,c,l==="exit"?(d=t.presenceContext)===null||d===void 0?void 0:d.custom:void 0);if(f){const h=f,{transition:g,transitionEnd:v}=h,b=ee(h,["transition","transitionEnd"]);u=k(k(k({},u),b),v)}return u};function s(l){e=l(t)}function o(l){const{props:u}=t,c=A0(t.parent)||{},d=[],f=new Set;let h={},g=1/0;for(let b=0;bg&&S,w=!1;const $=Array.isArray(y)?y:[y];let F=$.reduce(r(p),{});P===!1&&(F={});const{prevResolvedValues:T={}}=m,N=k(k({},T),F),M=A=>{_=!0,f.has(A)&&(w=!0,f.delete(A)),m.needsAnimating[A]=!0;const R=t.getValue(A);R&&(R.liveStyle=!1)};for(const A in N){const R=F[A],j=T[A];if(h.hasOwnProperty(A))continue;let H=!1;Jd(R)&&Jd(j)?H=!Ty(R,j):H=R!==j,H?R!=null?M(A):f.add(A):R!==void 0&&f.has(A)?M(A):m.protectedKeys[A]=!0}m.prevProp=y,m.prevResolvedValues=F,m.isActive&&(h=k(k({},h),F)),i&&t.blockInitialAnimation&&(_=!1),_&&(!(C&&L)||w)&&d.push(...$.map(A=>({animation:A,options:{type:p}})))}if(f.size){const b={};f.forEach(p=>{const m=t.getBaseTarget(p),y=t.getValue(p);y&&(y.liveStyle=!0),b[p]=m!=null?m:null}),d.push({animation:b})}let v=!!d.length;return i&&(u.initial===!1||u.initial===u.animate)&&!t.manuallyAnimateOnMount&&(v=!1),i=!1,v?e(d):Promise.resolve()}function a(l,u){var c;if(n[l].isActive===u)return Promise.resolve();(c=t.variantChildren)===null||c===void 0||c.forEach(f=>{var h;return(h=f.animationState)===null||h===void 0?void 0:h.setActive(l,u)}),n[l].isActive=u;const d=o(l);for(const f in n)n[f].protectedKeys={};return d}return{animateChanges:o,setActive:a,setAnimateFunction:s,getState:()=>n,reset:()=>{n=R0(),i=!0}}}function b2(t,e){return typeof e=="string"?e!==t:Array.isArray(e)?!Ty(e,t):!1}function Oi(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function R0(){return{animate:Oi(!0),whileInView:Oi(),whileHover:Oi(),whileTap:Oi(),whileDrag:Oi(),whileFocus:Oi(),exit:Oi()}}class oi{constructor(e){this.isMounted=!1,this.node=e}update(){}}class x2 extends oi{constructor(e){super(e),e.animationState||(e.animationState=y2(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();Xs(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:n}=this.node.prevProps||{};e!==n&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),(e=this.unmountControls)===null||e===void 0||e.call(this)}}let w2=0;class S2 extends oi{constructor(){super(...arguments),this.id=w2++}update(){if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:n}=this.node.presenceContext,{isPresent:i}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===i)return;const r=this.node.animationState.setActive("exit",!e);n&&!e&&r.then(()=>n(this.id))}mount(){const{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id))}unmount(){}}const P2={animation:{Feature:x2},exit:{Feature:S2}},F0=t=>t.pointerType==="mouse"?typeof t.button!="number"||t.button<=0:t.isPrimary!==!1;function Sl(t,e="page"){return{point:{x:t[`${e}X`],y:t[`${e}Y`]}}}const $2=t=>e=>F0(e)&&t(e,Sl(e));function kn(t,e,n,i={passive:!0}){return t.addEventListener(e,n,i),()=>t.removeEventListener(e,n)}function Tn(t,e,n,i){return kn(t,e,$2(n),i)}const I0=(t,e)=>Math.abs(t-e);function k2(t,e){const n=I0(t.x,e.x),i=I0(t.y,e.y);return Math.sqrt(om(n,2)+om(i,2))}class N0{constructor(e,n,{transformPagePoint:i,contextWindow:r,dragSnapToOrigin:s=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const d=Vf(this.lastMoveEventInfo,this.history),f=this.startEvent!==null,h=k2(d.offset,{x:0,y:0})>=3;if(!f&&!h)return;const{point:g}=d,{timestamp:v}=Fe;this.history.push(V(k({},g),{timestamp:v}));const{onStart:b,onMove:p}=this.handlers;f||(b&&b(this.lastMoveEvent,d),this.startEvent=this.lastMoveEvent),p&&p(this.lastMoveEvent,d)},this.handlePointerMove=(d,f)=>{this.lastMoveEvent=d,this.lastMoveEventInfo=Of(f,this.transformPagePoint),ie.update(this.updatePoint,!0)},this.handlePointerUp=(d,f)=>{this.end();const{onEnd:h,onSessionEnd:g,resumeAnimation:v}=this.handlers;if(this.dragSnapToOrigin&&v&&v(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const b=Vf(d.type==="pointercancel"?this.lastMoveEventInfo:Of(f,this.transformPagePoint),this.history);this.startEvent&&h&&h(d,b),g&&g(d,b)},!F0(e))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=i,this.contextWindow=r||window;const o=Sl(e),a=Of(o,this.transformPagePoint),{point:l}=a,{timestamp:u}=Fe;this.history=[V(k({},l),{timestamp:u})];const{onSessionStart:c}=n;c&&c(e,Vf(a,this.history)),this.removeListeners=Pn(Tn(this.contextWindow,"pointermove",this.handlePointerMove),Tn(this.contextWindow,"pointerup",this.handlePointerUp),Tn(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),tn(this.updatePoint)}}function Of(t,e){return e?{point:e(t.point)}:t}function O0(t,e){return{x:t.x-e.x,y:t.y-e.y}}function Vf({point:t},e){return{point:t,delta:O0(t,V0(e)),offset:O0(t,T2(e)),velocity:C2(e,.1)}}function T2(t){return t[0]}function V0(t){return t[t.length-1]}function C2(t,e){if(t.length<2)return{x:0,y:0};let n=t.length-1,i=null;const r=V0(t);for(;n>=0&&(i=t[n],!(r.timestamp-i.timestamp>wn(e)));)n--;if(!i)return{x:0,y:0};const s=Sn(r.timestamp-i.timestamp);if(s===0)return{x:0,y:0};const o={x:(r.x-i.x)/s,y:(r.y-i.y)/s};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function j0(t){let e=null;return()=>{const n=()=>{e=null};return e===null?(e=t,n):!1}}const z0=j0("dragHorizontal"),B0=j0("dragVertical");function K0(t){let e=!1;if(t==="y")e=B0();else if(t==="x")e=z0();else{const n=z0(),i=B0();n&&i?e=()=>{n(),i()}:(n&&n(),i&&i())}return e}function H0(){const t=K0(!0);return t?(t(),!1):!0}function Fr(t){return t&&typeof t=="object"&&Object.prototype.hasOwnProperty.call(t,"current")}const W0=1e-4,E2=1-W0,_2=1+W0,U0=.01,M2=0-U0,D2=0+U0;function wt(t){return t.max-t.min}function L2(t,e,n){return Math.abs(t-e)<=n}function Y0(t,e,n,i=.5){t.origin=i,t.originPoint=Pe(e.min,e.max,t.origin),t.scale=wt(n)/wt(e),t.translate=Pe(n.min,n.max,t.origin)-t.originPoint,(t.scale>=E2&&t.scale<=_2||isNaN(t.scale))&&(t.scale=1),(t.translate>=M2&&t.translate<=D2||isNaN(t.translate))&&(t.translate=0)}function ro(t,e,n,i){Y0(t.x,e.x,n.x,i?i.originX:void 0),Y0(t.y,e.y,n.y,i?i.originY:void 0)}function G0(t,e,n){t.min=n.min+e.min,t.max=t.min+wt(e)}function A2(t,e,n){G0(t.x,e.x,n.x),G0(t.y,e.y,n.y)}function X0(t,e,n){t.min=e.min-n.min,t.max=t.min+wt(e)}function so(t,e,n){X0(t.x,e.x,n.x),X0(t.y,e.y,n.y)}function R2(t,{min:e,max:n},i){return e!==void 0&&tn&&(t=i?Pe(n,t,i.max):Math.min(t,n)),t}function Q0(t,e,n){return{min:e!==void 0?t.min+e:void 0,max:n!==void 0?t.max+n-(t.max-t.min):void 0}}function F2(t,{top:e,left:n,bottom:i,right:r}){return{x:Q0(t.x,n,r),y:Q0(t.y,e,i)}}function q0(t,e){let n=e.min-t.min,i=e.max-t.max;return e.max-e.mini?n=Ni(e.min,e.max-i,t.min):i>r&&(n=Ni(t.min,t.max-r,e.min)),ii(0,1,n)}function O2(t,e){const n={};return e.min!==void 0&&(n.min=e.min-t.min),e.max!==void 0&&(n.max=e.max-t.min),n}const jf=.35;function V2(t=jf){return t===!1?t=0:t===!0&&(t=jf),{x:Z0(t,"left","right"),y:Z0(t,"top","bottom")}}function Z0(t,e,n){return{min:J0(t,e),max:J0(t,n)}}function J0(t,e){return typeof t=="number"?t:t[e]||0}const eb=()=>({translate:0,scale:1,origin:0,originPoint:0}),Ir=()=>({x:eb(),y:eb()}),tb=()=>({min:0,max:0}),Ce=()=>({x:tb(),y:tb()});function Lt(t){return[t("x"),t("y")]}function nb({top:t,left:e,right:n,bottom:i}){return{x:{min:e,max:n},y:{min:t,max:i}}}function j2({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}function z2(t,e){if(!e)return t;const n=e({x:t.left,y:t.top}),i=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:i.y,right:i.x}}function zf(t){return t===void 0||t===1}function Bf({scale:t,scaleX:e,scaleY:n}){return!zf(t)||!zf(e)||!zf(n)}function Vi(t){return Bf(t)||ib(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function ib(t){return rb(t.x)||rb(t.y)}function rb(t){return t&&t!=="0%"}function Pl(t,e,n){const i=t-n,r=e*i;return n+r}function sb(t,e,n,i,r){return r!==void 0&&(t=Pl(t,r,i)),Pl(t,n,i)+e}function Kf(t,e=0,n=1,i,r){t.min=sb(t.min,e,n,i,r),t.max=sb(t.max,e,n,i,r)}function ob(t,{x:e,y:n}){Kf(t.x,e.translate,e.scale,e.originPoint),Kf(t.y,n.translate,n.scale,n.originPoint)}const ab=.999999999999,lb=1.0000000000001;function B2(t,e,n,i=!1){const r=n.length;if(!r)return;e.x=e.y=1;let s,o;for(let a=0;aab&&(e.x=1),e.yab&&(e.y=1)}function Nr(t,e){t.min=t.min+e,t.max=t.max+e}function ub(t,e,n,i,r=.5){const s=Pe(t.min,t.max,r);Kf(t,e,n,s,i)}function Or(t,e){ub(t.x,e.x,e.scaleX,e.scale,e.originX),ub(t.y,e.y,e.scaleY,e.scale,e.originY)}function cb(t,e){return nb(z2(t.getBoundingClientRect(),e))}function K2(t,e,n){const i=cb(t,n),{scroll:r}=e;return r&&(Nr(i.x,r.offset.x),Nr(i.y,r.offset.y)),i}const db=({current:t})=>t?t.ownerDocument.defaultView:null,H2=new WeakMap;class W2{constructor(e){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Ce(),this.visualElement=e}start(e,{snapToCursor:n=!1}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const r=c=>{const{dragSnapToOrigin:d}=this.getProps();d?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(Sl(c,"page").point)},s=(c,d)=>{const{drag:f,dragPropagation:h,onDragStart:g}=this.getProps();if(f&&!h&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=K0(f),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Lt(b=>{let p=this.getAxisMotionValue(b).get()||0;if(nn.test(p)){const{projection:m}=this.visualElement;if(m&&m.layout){const y=m.layout.layoutBox[b];y&&(p=wt(y)*(parseFloat(p)/100))}}this.originPoint[b]=p}),g&&ie.postRender(()=>g(c,d)),If(this.visualElement,"transform");const{animationState:v}=this.visualElement;v&&v.setActive("whileDrag",!0)},o=(c,d)=>{const{dragPropagation:f,dragDirectionLock:h,onDirectionLock:g,onDrag:v}=this.getProps();if(!f&&!this.openGlobalLock)return;const{offset:b}=d;if(h&&this.currentDirection===null){this.currentDirection=U2(b),this.currentDirection!==null&&g&&g(this.currentDirection);return}this.updateAxis("x",d.point,b),this.updateAxis("y",d.point,b),this.visualElement.render(),v&&v(c,d)},a=(c,d)=>this.stop(c,d),l=()=>Lt(c=>{var d;return this.getAnimationState(c)==="paused"&&((d=this.getAxisMotionValue(c).animation)===null||d===void 0?void 0:d.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new N0(e,{onSessionStart:r,onStart:s,onMove:o,onSessionEnd:a,resumeAnimation:l},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,contextWindow:db(this.visualElement)})}stop(e,n){const i=this.isDragging;if(this.cancel(),!i)return;const{velocity:r}=n;this.startAnimation(r);const{onDragEnd:s}=this.getProps();s&&ie.postRender(()=>s(e,n))}cancel(){this.isDragging=!1;const{projection:e,animationState:n}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:i}=this.getProps();!i&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(e,n,i){const{drag:r}=this.getProps();if(!i||!$l(e,r,this.currentDirection))return;const s=this.getAxisMotionValue(e);let o=this.originPoint[e]+i[e];this.constraints&&this.constraints[e]&&(o=R2(o,this.constraints[e],this.elastic[e])),s.set(o)}resolveConstraints(){var e;const{dragConstraints:n,dragElastic:i}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(e=this.visualElement.projection)===null||e===void 0?void 0:e.layout,s=this.constraints;n&&Fr(n)?this.constraints||(this.constraints=this.resolveRefConstraints()):n&&r?this.constraints=F2(r.layoutBox,n):this.constraints=!1,this.elastic=V2(i),s!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Lt(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=O2(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:n}=this.getProps();if(!e||!Fr(e))return!1;const i=e.current,{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const s=K2(i,r.root,this.visualElement.getTransformPagePoint());let o=I2(r.layout.layoutBox,s);if(n){const a=n(j2(o));this.hasMutatedConstraints=!!a,a&&(o=nb(a))}return o}startAnimation(e){const{drag:n,dragMomentum:i,dragElastic:r,dragTransition:s,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},u=Lt(c=>{if(!$l(c,n,this.currentDirection))return;let d=l&&l[c]||{};o&&(d={min:0,max:0});const f=r?200:1e6,h=r?40:1e7,g=k(k({type:"inertia",velocity:i?e[c]:0,bounceStiffness:f,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10},s),d);return this.startAxisValueAnimation(c,g)});return Promise.all(u).then(a)}startAxisValueAnimation(e,n){const i=this.getAxisMotionValue(e);return If(this.visualElement,e),i.start(Lf(e,i,0,n,this.visualElement,!1))}stopAnimation(){Lt(e=>this.getAxisMotionValue(e).stop())}pauseAnimation(){Lt(e=>{var n;return(n=this.getAxisMotionValue(e).animation)===null||n===void 0?void 0:n.pause()})}getAnimationState(e){var n;return(n=this.getAxisMotionValue(e).animation)===null||n===void 0?void 0:n.state}getAxisMotionValue(e){const n=`_drag${e.toUpperCase()}`,i=this.visualElement.getProps(),r=i[n];return r||this.visualElement.getValue(e,(i.initial?i.initial[e]:void 0)||0)}snapToCursor(e){Lt(n=>{const{drag:i}=this.getProps();if(!$l(n,i,this.currentDirection))return;const{projection:r}=this.visualElement,s=this.getAxisMotionValue(n);if(r&&r.layout){const{min:o,max:a}=r.layout.layoutBox[n];s.set(e[n]-Pe(o,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:n}=this.getProps(),{projection:i}=this.visualElement;if(!Fr(n)||!i||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};Lt(o=>{const a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){const l=a.get();r[o]=N2({min:l,max:l},this.constraints[o])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",i.root&&i.root.updateScroll(),i.updateLayout(),this.resolveConstraints(),Lt(o=>{if(!$l(o,e,null))return;const a=this.getAxisMotionValue(o),{min:l,max:u}=this.constraints[o];a.set(Pe(l,u,r[o]))})}addListeners(){if(!this.visualElement.current)return;H2.set(this.visualElement,this);const e=this.visualElement.current,n=Tn(e,"pointerdown",l=>{const{drag:u,dragListener:c=!0}=this.getProps();u&&c&&this.start(l)}),i=()=>{const{dragConstraints:l}=this.getProps();Fr(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:r}=this.visualElement,s=r.addEventListener("measure",i);r&&!r.layout&&(r.root&&r.root.updateScroll(),r.updateLayout()),ie.read(i);const o=kn(window,"resize",()=>this.scalePositionWithinConstraints()),a=r.addEventListener("didUpdate",({delta:l,hasLayoutChanged:u})=>{this.isDragging&&u&&(Lt(c=>{const d=this.getAxisMotionValue(c);d&&(this.originPoint[c]+=l[c].translate,d.set(d.get()+l[c].translate))}),this.visualElement.render())});return()=>{o(),n(),s(),a&&a()}}getProps(){const e=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:i=!1,dragPropagation:r=!1,dragConstraints:s=!1,dragElastic:o=jf,dragMomentum:a=!0}=e;return V(k({},e),{drag:n,dragDirectionLock:i,dragPropagation:r,dragConstraints:s,dragElastic:o,dragMomentum:a})}}function $l(t,e,n){return(e===!0||e===t)&&(n===null||n===t)}function U2(t,e=10){let n=null;return Math.abs(t.y)>e?n="y":Math.abs(t.x)>e&&(n="x"),n}class Y2 extends oi{constructor(e){super(e),this.removeGroupControls=ze,this.removeListeners=ze,this.controls=new W2(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||ze}unmount(){this.removeGroupControls(),this.removeListeners()}}const fb=t=>(e,n)=>{t&&ie.postRender(()=>t(e,n))};class G2 extends oi{constructor(){super(...arguments),this.removePointerDownListener=ze}onPointerDown(e){this.session=new N0(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:db(this.node)})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:n,onPan:i,onPanEnd:r}=this.node.getProps();return{onSessionStart:fb(e),onStart:fb(n),onMove:i,onEnd:(s,o)=>{delete this.session,r&&ie.postRender(()=>r(s,o))}}}mount(){this.removePointerDownListener=Tn(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const Hf=x.createContext(null);function X2(){const t=x.useContext(Hf);if(t===null)return[!0,null];const{isPresent:e,onExitComplete:n,register:i}=t,r=x.useId();x.useEffect(()=>i(r),[]);const s=x.useCallback(()=>n&&n(r),[r,n]);return!e&&n?[!1,s]:[!0]}const hb=x.createContext({}),pb=x.createContext({}),kl={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function mb(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}const oo={correct:(t,e)=>{if(!e.target)return t;if(typeof t=="string")if(Y.test(t))t=parseFloat(t);else return t;const n=mb(t,e.target.x),i=mb(t,e.target.y);return`${n}% ${i}%`}},Q2={correct:(t,{treeScale:e,projectionDelta:n})=>{const i=t,r=si.parse(t);if(r.length>5)return i;const s=si.createTransformer(t),o=typeof r[0]!="number"?1:0,a=n.x.scale*e.x,l=n.y.scale*e.y;r[0+o]/=a,r[1+o]/=l;const u=Pe(a,l,.5);return typeof r[2+o]=="number"&&(r[2+o]/=u),typeof r[3+o]=="number"&&(r[3+o]/=u),s(r)}},Tl={};function q2(t){Object.assign(Tl,t)}const{schedule:Wf,cancel:F8}=Ey(queueMicrotask,!1);class Z2 extends x.Component{componentDidMount(){const{visualElement:e,layoutGroup:n,switchLayoutGroup:i,layoutId:r}=this.props,{projection:s}=e;q2(J2),s&&(n.group&&n.group.add(s),i&&i.register&&r&&i.register(s),s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions(V(k({},s.options),{onExitComplete:()=>this.safeToRemove()}))),kl.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:n,visualElement:i,drag:r,isPresent:s}=this.props,o=i.projection;return o&&(o.isPresent=s,r||e.layoutDependency!==n||n===void 0?o.willUpdate():this.safeToRemove(),e.isPresent!==s&&(s?o.promote():o.relegate()||ie.postRender(()=>{const a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),Wf.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:e,layoutGroup:n,switchLayoutGroup:i}=this.props,{projection:r}=e;r&&(r.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(r),i&&i.deregister&&i.deregister(r))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function gb(t){const[e,n]=X2(),i=x.useContext(hb);return D.jsx(Z2,V(k({},t),{layoutGroup:i,switchLayoutGroup:x.useContext(pb),isPresent:e,safeToRemove:n}))}const J2={borderRadius:V(k({},oo),{applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]}),borderTopLeftRadius:oo,borderTopRightRadius:oo,borderBottomLeftRadius:oo,borderBottomRightRadius:oo,boxShadow:Q2},vb=["TopLeft","TopRight","BottomLeft","BottomRight"],e_=vb.length,yb=t=>typeof t=="string"?parseFloat(t):t,bb=t=>typeof t=="number"||Y.test(t);function t_(t,e,n,i,r,s){r?(t.opacity=Pe(0,n.opacity!==void 0?n.opacity:1,n_(i)),t.opacityExit=Pe(e.opacity!==void 0?e.opacity:1,0,i_(i))):s&&(t.opacity=Pe(e.opacity!==void 0?e.opacity:1,n.opacity!==void 0?n.opacity:1,i));for(let o=0;oie?1:n(Ni(t,e,i))}function Sb(t,e){t.min=e.min,t.max=e.max}function At(t,e){Sb(t.x,e.x),Sb(t.y,e.y)}function Pb(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}function $b(t,e,n,i,r){return t-=e,t=Pl(t,1/n,i),r!==void 0&&(t=Pl(t,1/r,i)),t}function r_(t,e=0,n=1,i=.5,r,s=t,o=t){if(nn.test(e)&&(e=parseFloat(e),e=Pe(o.min,o.max,e/100)-o.min),typeof e!="number")return;let a=Pe(s.min,s.max,i);t===s&&(a-=e),t.min=$b(t.min,e,n,a,r),t.max=$b(t.max,e,n,a,r)}function kb(t,e,[n,i,r],s,o){r_(t,e[n],e[i],e[r],e.scale,s,o)}const s_=["x","scaleX","originX"],o_=["y","scaleY","originY"];function Tb(t,e,n,i){kb(t.x,e,s_,n?n.x:void 0,i?i.x:void 0),kb(t.y,e,o_,n?n.y:void 0,i?i.y:void 0)}function Cb(t){return t.translate===0&&t.scale===1}function Eb(t){return Cb(t.x)&&Cb(t.y)}function _b(t,e){return t.min===e.min&&t.max===e.max}function a_(t,e){return _b(t.x,e.x)&&_b(t.y,e.y)}function Mb(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}function Db(t,e){return Mb(t.x,e.x)&&Mb(t.y,e.y)}function Lb(t){return wt(t.x)/wt(t.y)}function Ab(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}class l_{constructor(){this.members=[]}add(e){Af(this.members,e),e.scheduleRender()}remove(e){if(Rf(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(e){const n=this.members.findIndex(r=>e===r);if(n===0)return!1;let i;for(let r=n;r>=0;r--){const s=this.members[r];if(s.isPresent!==!1){i=s;break}}return i?(this.promote(i),!0):!1}promote(e,n){const i=this.lead;if(e!==i&&(this.prevLead=i,this.lead=e,e.show(),i)){i.instance&&i.scheduleRender(),e.scheduleRender(),e.resumeFrom=i,n&&(e.resumeFrom.preserveOpacity=!0),i.snapshot&&(e.snapshot=i.snapshot,e.snapshot.latestValues=i.animationValues||i.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);const{crossfade:r}=e.options;r===!1&&i.hide()}}exitAnimationComplete(){this.members.forEach(e=>{const{options:n,resumingFrom:i}=e;n.onExitComplete&&n.onExitComplete(),i&&i.options.onExitComplete&&i.options.onExitComplete()})}scheduleRender(){this.members.forEach(e=>{e.instance&&e.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function u_(t,e,n){let i="";const r=t.x.translate/e.x,s=t.y.translate/e.y,o=(n==null?void 0:n.z)||0;if((r||s||o)&&(i=`translate3d(${r}px, ${s}px, ${o}px) `),(e.x!==1||e.y!==1)&&(i+=`scale(${1/e.x}, ${1/e.y}) `),n){const{transformPerspective:u,rotate:c,rotateX:d,rotateY:f,skewX:h,skewY:g}=n;u&&(i=`perspective(${u}px) ${i}`),c&&(i+=`rotate(${c}deg) `),d&&(i+=`rotateX(${d}deg) `),f&&(i+=`rotateY(${f}deg) `),h&&(i+=`skewX(${h}deg) `),g&&(i+=`skewY(${g}deg) `)}const a=t.x.scale*e.x,l=t.y.scale*e.y;return(a!==1||l!==1)&&(i+=`scale(${a}, ${l})`),i||"none"}const c_=(t,e)=>t.depth-e.depth;class d_{constructor(){this.children=[],this.isDirty=!1}add(e){Af(this.children,e),this.isDirty=!0}remove(e){Rf(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(c_),this.isDirty=!1,this.children.forEach(e)}}function Cl(t){const e=Xe(t)?t.get():t;return i2(e)?e.toValue():e}function f_(t,e){const n=rn.now(),i=({timestamp:r})=>{const s=r-n;s>=e&&(tn(i),t(s-e))};return ie.read(i,!0),()=>tn(i)}function h_(t){return t instanceof SVGElement&&t.tagName!=="svg"}function p_(t,e,n){const i=Xe(t)?t:$n(t);return i.start(Lf("",i,e,n)),i.animation}const ji={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},ao=typeof window!="undefined"&&window.MotionDebug!==void 0,Uf=["","X","Y","Z"],m_={visibility:"hidden"},Rb=1e3;let g_=0;function Yf(t,e,n,i){const{latestValues:r}=e;r[t]&&(n[t]=r[t],e.setStaticValue(t,0),i&&(i[t]=0))}function Fb(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;const{visualElement:e}=t.options;if(!e)return;const n=D0(e);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:r,layoutId:s}=t.options;window.MotionCancelOptimisedAnimation(n,"transform",ie,!(r||s))}const{parent:i}=t;i&&!i.hasCheckedOptimisedAppear&&Fb(i)}function Ib({attachResizeListener:t,defaultParent:e,measureScroll:n,checkIsScrollRoot:i,resetTransform:r}){return class{constructor(o={},a=e==null?void 0:e()){this.id=g_++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,ao&&(ji.totalNodes=ji.resolvedTargetDeltas=ji.recalculatedProjection=0),this.nodes.forEach(b_),this.nodes.forEach($_),this.nodes.forEach(k_),this.nodes.forEach(x_),ao&&window.MotionDebug.record(ji)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;lthis.root.updateBlockedByResize=!1;t(o,()=>{this.root.updateBlockedByResize=!0,d&&d(),d=f_(f,250),kl.hasAnimatedSinceResize&&(kl.hasAnimatedSinceResize=!1,this.nodes.forEach(Ob))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&c&&(l||u)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:f,hasRelativeTargetChanged:h,layout:g})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const v=this.options.transition||c.getDefaultTransition()||M_,{onLayoutAnimationStart:b,onLayoutAnimationComplete:p}=c.getProps(),m=!this.targetLayout||!Db(this.targetLayout,g)||h,y=!f&&h;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||y||f&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(d,y);const S=V(k({},rf(v,"layout")),{onPlay:b,onComplete:p});(c.shouldReduceMotion||this.options.layoutRoot)&&(S.delay=0,S.type=!1),this.startAnimation(S)}else f||Ob(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=g})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,tn(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(T_),this.animationId++)}getTransformTemplate(){const{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Fb(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l{const P=S/1e3;Vb(d.x,o.x,P),Vb(d.y,o.y,P),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(so(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),E_(this.relativeTarget,this.relativeTargetOrigin,f,P),y&&a_(this.relativeTarget,y)&&(this.isProjectionDirty=!1),y||(y=Ce()),At(y,this.relativeTarget)),v&&(this.animationValues=c,t_(c,u,this.latestValues,P,m,p)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=P},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(tn(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ie.update(()=>{kl.hasAnimatedSinceResize=!0,this.currentAnimation=p_(0,Rb,V(k({},o),{onUpdate:a=>{this.mixTargetDelta(a),o.onUpdate&&o.onUpdate(a)},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}})),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Rb),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const o=this.getLead();let{targetWithTransforms:a,target:l,layout:u,latestValues:c}=o;if(!(!a||!l||!u)){if(this!==o&&this.layout&&u&&Hb(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||Ce();const d=wt(this.layout.layoutBox.x);l.x.min=o.target.x.min,l.x.max=l.x.min+d;const f=wt(this.layout.layoutBox.y);l.y.min=o.target.y.min,l.y.max=l.y.min+f}At(a,l),Or(a,c),ro(this.projectionDeltaWithTransform,this.layoutCorrected,a,c)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new l_),this.sharedNodes.get(o).add(a);const u=a.options.initialPromotionConfig;a.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(a):void 0})}isLead(){const o=this.getStack();return o?o.lead===this:!0}getLead(){var o;const{layoutId:a}=this.options;return a?((o=this.getStack())===null||o===void 0?void 0:o.lead)||this:this}getPrevLead(){var o;const{layoutId:a}=this.options;return a?(o=this.getStack())===null||o===void 0?void 0:o.prevLead:void 0}getStack(){const{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:l}={}){const u=this.getStack();u&&u.promote(this,l),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){const{visualElement:o}=this.options;if(!o)return;let a=!1;const{latestValues:l}=o;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const u={};l.z&&Yf("z",o,u,this.animationValues);for(let c=0;c{var a;return(a=o.currentAnimation)===null||a===void 0?void 0:a.stop()}),this.root.nodes.forEach(Nb),this.root.sharedNodes.clear()}}}function v_(t){t.updateLayout()}function y_(t){var e;const n=((e=t.resumeFrom)===null||e===void 0?void 0:e.snapshot)||t.snapshot;if(t.isLead()&&t.layout&&n&&t.hasListeners("didUpdate")){const{layoutBox:i,measuredBox:r}=t.layout,{animationType:s}=t.options,o=n.source!==t.layout.source;s==="size"?Lt(d=>{const f=o?n.measuredBox[d]:n.layoutBox[d],h=wt(f);f.min=i[d].min,f.max=f.min+h}):Hb(s,n.layoutBox,i)&&Lt(d=>{const f=o?n.measuredBox[d]:n.layoutBox[d],h=wt(i[d]);f.max=f.min+h,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[d].max=t.relativeTarget[d].min+h)});const a=Ir();ro(a,i,n.layoutBox);const l=Ir();o?ro(l,t.applyTransform(r,!0),n.measuredBox):ro(l,i,n.layoutBox);const u=!Eb(a);let c=!1;if(!t.resumeFrom){const d=t.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:f,layout:h}=d;if(f&&h){const g=Ce();so(g,n.layoutBox,f.layoutBox);const v=Ce();so(v,i,h.layoutBox),Db(g,v)||(c=!0),d.options.layoutRoot&&(t.relativeTarget=v,t.relativeTargetOrigin=g,t.relativeParent=d)}}}t.notifyListeners("didUpdate",{layout:i,snapshot:n,delta:l,layoutDelta:a,hasLayoutChanged:u,hasRelativeTargetChanged:c})}else if(t.isLead()){const{onExitComplete:i}=t.options;i&&i()}t.options.transition=void 0}function b_(t){ao&&ji.totalNodes++,t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=!!(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function x_(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function w_(t){t.clearSnapshot()}function Nb(t){t.clearMeasurements()}function S_(t){t.isLayoutDirty=!1}function P_(t){const{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}function Ob(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function $_(t){t.resolveTargetDelta()}function k_(t){t.calcProjection()}function T_(t){t.resetSkewAndRotation()}function C_(t){t.removeLeadSnapshot()}function Vb(t,e,n){t.translate=Pe(e.translate,0,n),t.scale=Pe(e.scale,1,n),t.origin=e.origin,t.originPoint=e.originPoint}function jb(t,e,n,i){t.min=Pe(e.min,n.min,i),t.max=Pe(e.max,n.max,i)}function E_(t,e,n,i){jb(t.x,e.x,n.x,i),jb(t.y,e.y,n.y,i)}function __(t){return t.animationValues&&t.animationValues.opacityExit!==void 0}const M_={duration:.45,ease:[.4,0,.1,1]},zb=t=>typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),Bb=zb("applewebkit/")&&!zb("chrome/")?Math.round:ze;function Kb(t){t.min=Bb(t.min),t.max=Bb(t.max)}function D_(t){Kb(t.x),Kb(t.y)}function Hb(t,e,n){return t==="position"||t==="preserve-aspect"&&!L2(Lb(e),Lb(n),.2)}function L_(t){var e;return t!==t.root&&((e=t.scroll)===null||e===void 0?void 0:e.wasRoot)}const A_=Ib({attachResizeListener:(t,e)=>kn(t,"resize",e),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Gf={current:void 0},Wb=Ib({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!Gf.current){const t=new A_({});t.mount(window),t.setOptions({layoutScroll:!0}),Gf.current=t}return Gf.current},resetTransform:(t,e)=>{t.style.transform=e!==void 0?e:"none"},checkIsScrollRoot:t=>window.getComputedStyle(t).position==="fixed"}),R_={pan:{Feature:G2},drag:{Feature:Y2,ProjectionNode:Wb,MeasureLayout:gb}};function Ub(t,e){const n=e?"pointerenter":"pointerleave",i=e?"onHoverStart":"onHoverEnd",r=(s,o)=>{if(s.pointerType==="touch"||H0())return;const a=t.getProps();t.animationState&&a.whileHover&&t.animationState.setActive("whileHover",e);const l=a[i];l&&ie.postRender(()=>l(s,o))};return Tn(t.current,n,r,{passive:!t.getProps()[i]})}class F_ extends oi{mount(){this.unmount=Pn(Ub(this.node,!0),Ub(this.node,!1))}unmount(){}}class I_ extends oi{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(n){e=!0}!e||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Pn(kn(this.node.current,"focus",()=>this.onFocus()),kn(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}const Yb=(t,e)=>e?t===e?!0:Yb(t,e.parentElement):!1;function Xf(t,e){if(!e)return;const n=new PointerEvent("pointer"+t);e(n,Sl(n))}class N_ extends oi{constructor(){super(...arguments),this.removeStartListeners=ze,this.removeEndListeners=ze,this.removeAccessibleListeners=ze,this.startPointerPress=(e,n)=>{if(this.isPressing)return;this.removeEndListeners();const i=this.node.getProps(),s=Tn(window,"pointerup",(a,l)=>{if(!this.checkPressEnd())return;const{onTap:u,onTapCancel:c,globalTapTarget:d}=this.node.getProps(),f=!d&&!Yb(this.node.current,a.target)?c:u;f&&ie.update(()=>f(a,l))},{passive:!(i.onTap||i.onPointerUp)}),o=Tn(window,"pointercancel",(a,l)=>this.cancelPress(a,l),{passive:!(i.onTapCancel||i.onPointerCancel)});this.removeEndListeners=Pn(s,o),this.startPress(e,n)},this.startAccessiblePress=()=>{const e=s=>{if(s.key!=="Enter"||this.isPressing)return;const o=a=>{a.key!=="Enter"||!this.checkPressEnd()||Xf("up",(l,u)=>{const{onTap:c}=this.node.getProps();c&&ie.postRender(()=>c(l,u))})};this.removeEndListeners(),this.removeEndListeners=kn(this.node.current,"keyup",o),Xf("down",(a,l)=>{this.startPress(a,l)})},n=kn(this.node.current,"keydown",e),i=()=>{this.isPressing&&Xf("cancel",(s,o)=>this.cancelPress(s,o))},r=kn(this.node.current,"blur",i);this.removeAccessibleListeners=Pn(n,r)}}startPress(e,n){this.isPressing=!0;const{onTapStart:i,whileTap:r}=this.node.getProps();r&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),i&&ie.postRender(()=>i(e,n))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!H0()}cancelPress(e,n){if(!this.checkPressEnd())return;const{onTapCancel:i}=this.node.getProps();i&&ie.postRender(()=>i(e,n))}mount(){const e=this.node.getProps(),n=Tn(e.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(e.onTapStart||e.onPointerStart)}),i=kn(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Pn(n,i)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}const Qf=new WeakMap,qf=new WeakMap,O_=t=>{const e=Qf.get(t.target);e&&e(t)},V_=t=>{t.forEach(O_)};function j_(n){var i=n,{root:t}=i,e=ee(i,["root"]);const r=t||document;qf.has(r)||qf.set(r,{});const s=qf.get(r),o=JSON.stringify(e);return s[o]||(s[o]=new IntersectionObserver(V_,k({root:t},e))),s[o]}function z_(t,e,n){const i=j_(e);return Qf.set(t,n),i.observe(t),()=>{Qf.delete(t),i.unobserve(t)}}const B_={some:0,all:1};class K_ extends oi{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:e={}}=this.node.getProps(),{root:n,margin:i,amount:r="some",once:s}=e,o={root:n?n.current:void 0,rootMargin:i,threshold:typeof r=="number"?r:B_[r]},a=l=>{const{isIntersecting:u}=l;if(this.isInView===u||(this.isInView=u,s&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:c,onViewportLeave:d}=this.node.getProps(),f=u?c:d;f&&f(l)};return z_(this.node.current,o,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver=="undefined")return;const{props:e,prevProps:n}=this.node;["amount","margin","root"].some(H_(e,n))&&this.startObserver()}unmount(){}}function H_({viewport:t={}},{viewport:e={}}={}){return n=>t[n]!==e[n]}const W_={inView:{Feature:K_},tap:{Feature:N_},focus:{Feature:I_},hover:{Feature:F_}},U_={layout:{ProjectionNode:Wb,MeasureLayout:gb}},Gb=x.createContext({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),El=x.createContext({}),Zf=typeof window!="undefined",Xb=Zf?x.useLayoutEffect:x.useEffect,Qb=x.createContext({strict:!1});function Y_(t,e,n,i,r){var s,o;const{visualElement:a}=x.useContext(El),l=x.useContext(Qb),u=x.useContext(Hf),c=x.useContext(Gb).reducedMotion,d=x.useRef();i=i||l.renderer,!d.current&&i&&(d.current=i(t,{visualState:e,parent:a,props:n,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:c}));const f=d.current,h=x.useContext(pb);f&&!f.projection&&r&&(f.type==="html"||f.type==="svg")&&G_(d.current,n,r,h),x.useInsertionEffect(()=>{f&&f.update(n,u)});const g=n[M0],v=x.useRef(!!g&&!(!((s=window.MotionHandoffIsComplete)===null||s===void 0)&&s.call(window,g))&&((o=window.MotionHasOptimisedAnimation)===null||o===void 0?void 0:o.call(window,g)));return Xb(()=>{f&&(window.MotionIsMounted=!0,f.updateFeatures(),Wf.render(f.render),v.current&&f.animationState&&f.animationState.animateChanges())}),x.useEffect(()=>{f&&(!v.current&&f.animationState&&f.animationState.animateChanges(),v.current&&(queueMicrotask(()=>{var b;(b=window.MotionHandoffMarkAsComplete)===null||b===void 0||b.call(window,g)}),v.current=!1))}),f}function G_(t,e,n,i){const{layoutId:r,layout:s,drag:o,dragConstraints:a,layoutScroll:l,layoutRoot:u}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:qb(t.parent)),t.projection.setOptions({layoutId:r,layout:s,alwaysMeasureLayout:!!o||a&&Fr(a),visualElement:t,animationType:typeof s=="string"?s:"both",initialPromotionConfig:i,layoutScroll:l,layoutRoot:u})}function qb(t){if(t)return t.options.allowProjection!==!1?t.projection:qb(t.parent)}function X_(t,e,n){return x.useCallback(i=>{i&&t.mount&&t.mount(i),e&&(i?e.mount(i):e.unmount()),n&&(typeof n=="function"?n(i):Fr(n)&&(n.current=i))},[e])}function _l(t){return Xs(t.animate)||nf.some(e=>Qs(t[e]))}function Zb(t){return!!(_l(t)||t.variants)}function Q_(t,e){if(_l(t)){const{initial:n,animate:i}=t;return{initial:n===!1||Qs(n)?n:void 0,animate:Qs(i)?i:void 0}}return t.inherit!==!1?e:{}}function q_(t){const{initial:e,animate:n}=Q_(t,x.useContext(El));return x.useMemo(()=>({initial:e,animate:n}),[Jb(e),Jb(n)])}function Jb(t){return Array.isArray(t)?t.join(" "):t}const ex={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Vr={};for(const t in ex)Vr[t]={isEnabled:e=>ex[t].some(n=>!!e[n])};function Z_(t){for(const e in t)Vr[e]=k(k({},Vr[e]),t[e])}const J_=Symbol.for("motionComponentSymbol");function eM({preloadedFeatures:t,createVisualElement:e,useRender:n,useVisualState:i,Component:r}){t&&Z_(t);function s(a,l){let u;const c=V(k(k({},x.useContext(Gb)),a),{layoutId:tM(a)}),{isStatic:d}=c,f=q_(a),h=i(a,d);if(!d&&Zf){nM();const g=iM(c);u=g.MeasureLayout,f.visualElement=Y_(r,h,c,e,g.ProjectionNode)}return D.jsxs(El.Provider,{value:f,children:[u&&f.visualElement?D.jsx(u,k({visualElement:f.visualElement},c)):null,n(r,a,X_(h,f.visualElement,l),h,d,f.visualElement)]})}const o=x.forwardRef(s);return o[J_]=r,o}function tM({layoutId:t}){const e=x.useContext(hb).id;return e&&t!==void 0?e+"-"+t:t}function nM(t,e){x.useContext(Qb).strict}function iM(t){const{drag:e,layout:n}=Vr;if(!e&&!n)return{};const i=k(k({},e),n);return{MeasureLayout:e!=null&&e.isEnabled(t)||n!=null&&n.isEnabled(t)?i.MeasureLayout:void 0,ProjectionNode:i.ProjectionNode}}const rM=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Jf(t){return typeof t!="string"||t.includes("-")?!1:!!(rM.indexOf(t)>-1||/[A-Z]/u.test(t))}function tx(t,{style:e,vars:n},i,r){Object.assign(t.style,e,r&&r.getProjectionStyles(i));for(const s in n)t.style.setProperty(s,n[s])}const nx=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function ix(t,e,n,i){tx(t,e,void 0,i);for(const r in e.attrs)t.setAttribute(nx.has(r)?r:wl(r),e.attrs[r])}function rx(t,{layout:e,layoutId:n}){return ni.has(t)||t.startsWith("origin")||(e||n!==void 0)&&(!!Tl[t]||t==="opacity")}function eh(t,e,n){var i;const{style:r}=t,s={};for(const o in r)(Xe(r[o])||e.style&&Xe(e.style[o])||rx(o,t)||((i=n==null?void 0:n.getValue(o))===null||i===void 0?void 0:i.liveStyle)!==void 0)&&(s[o]=r[o]);return n&&r&&typeof r.willChange=="string"&&(n.applyWillChange=!1),s}function sx(t,e,n){const i=eh(t,e,n);for(const r in t)if(Xe(t[r])||Xe(e[r])){const s=qs.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;i[s]=t[r]}return i}function ox(t){const e=x.useRef(null);return e.current===null&&(e.current=t()),e.current}function sM(t){if(ni.has(t))return"transform";if(S0.has(t))return wl(t)}function oM({applyWillChange:t=!1,scrapeMotionValuesFromProps:e,createRenderState:n,onMount:i},r,s,o,a){const l={latestValues:aM(r,s,o,a?!1:t,e),renderState:n()};return i&&(l.mount=u=>i(r,u,l)),l}const ax=t=>(e,n)=>{const i=x.useContext(El),r=x.useContext(Hf),s=()=>oM(t,e,i,r,n);return n?s():ox(s)};function lx(t,e,n){const i=Array.isArray(e)?e:[e];for(let s=0;s{for(const m in b){let y=b[m];if(Array.isArray(y)){const S=g?y.length-1:0;y=y[S]}y!==null&&(o[m]=y)}for(const m in p)o[m]=p[m]}),l&&(d&&c!==!1&&!Xs(d)&&lx(t,d,b=>{for(const p in b){const m=sM(p);m&&a.add(m)}}),a.size&&(o.willChange=Array.from(a).join(","))),o}const th=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),ux=()=>V(k({},th()),{attrs:{}}),cx=(t,e)=>e&&typeof t=="number"?e.transform(t):t,lM={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},uM=qs.length;function cM(t,e,n){let i="",r=!0;for(let s=0;stypeof t=="string"&&t.toLowerCase()==="svg",mM={useVisualState:ax({scrapeMotionValuesFromProps:sx,createRenderState:ux,onMount:(t,e,{renderState:n,latestValues:i})=>{ie.read(()=>{try{n.dimensions=typeof e.getBBox=="function"?e.getBBox():e.getBoundingClientRect()}catch(r){n.dimensions={x:0,y:0,width:0,height:0}}}),ie.render(()=>{ih(n,i,rh(e.tagName),t.transformTemplate),ix(e,n)})}})},gM={useVisualState:ax({applyWillChange:!0,scrapeMotionValuesFromProps:eh,createRenderState:th})};function fx(t,e,n){for(const i in e)!Xe(e[i])&&!rx(i,n)&&(t[i]=e[i])}function vM({transformTemplate:t},e){return x.useMemo(()=>{const n=th();return nh(n,e,t),Object.assign({},n.vars,n.style)},[e])}function yM(t,e){const n=t.style||{},i={};return fx(i,n,t),Object.assign(i,vM(t,e)),i}function bM(t,e){const n={},i=yM(t,e);return t.drag&&t.dragListener!==!1&&(n.draggable=!1,i.userSelect=i.WebkitUserSelect=i.WebkitTouchCallout="none",i.touchAction=t.drag===!0?"none":`pan-${t.drag==="x"?"y":"x"}`),t.tabIndex===void 0&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=i,n}const xM=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Ml(t){return t.startsWith("while")||t.startsWith("drag")&&t!=="draggable"||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||xM.has(t)}let hx=t=>!Ml(t);function wM(t){t&&(hx=e=>e.startsWith("on")?!Ml(e):t(e))}try{wM(require("@emotion/is-prop-valid").default)}catch(t){}function SM(t,e,n){const i={};for(const r in t)r==="values"&&typeof t.values=="object"||(hx(r)||n===!0&&Ml(r)||!e&&!Ml(r)||t.draggable&&r.startsWith("onDrag"))&&(i[r]=t[r]);return i}function PM(t,e,n,i){const r=x.useMemo(()=>{const s=ux();return ih(s,e,rh(i),t.transformTemplate),V(k({},s.attrs),{style:k({},s.style)})},[e]);if(t.style){const s={};fx(s,t.style,t),r.style=k(k({},s),r.style)}return r}function $M(t=!1){return(n,i,r,{latestValues:s},o)=>{const l=(Jf(n)?PM:bM)(i,s,o,n),u=SM(i,typeof n=="string",t),c=n!==x.Fragment?V(k(k({},u),l),{ref:r}):{},{children:d}=i,f=x.useMemo(()=>Xe(d)?d.get():d,[d]);return x.createElement(n,V(k({},c),{children:f}))}}function kM(t,e){return function(i,{forwardMotionProps:r}={forwardMotionProps:!1}){const s=Jf(i)?mM:gM,o=V(k({},s),{preloadedFeatures:t,useRender:$M(r),createVisualElement:e,Component:i});return eM(o)}}const sh={current:null},px={current:!1};function TM(){if(px.current=!0,!!Zf)if(window.matchMedia){const t=window.matchMedia("(prefers-reduced-motion)"),e=()=>sh.current=t.matches;t.addListener(e),e()}else sh.current=!1}function CM(t,e,n){for(const i in e){const r=e[i],s=n[i];if(Xe(r))t.addValue(i,r);else if(Xe(s))t.addValue(i,$n(r,{owner:t}));else if(s!==r)if(t.hasValue(i)){const o=t.getValue(i);o.liveStyle===!0?o.jump(r):o.hasAnimated||o.set(r)}else{const o=t.getStaticValue(i);t.addValue(i,$n(o!==void 0?o:r,{owner:t}))}}for(const i in n)e[i]===void 0&&t.removeValue(i);return e}const mx=new WeakMap,EM=[...Yy,Ge,si],_M=t=>EM.find(Uy(t)),gx=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class MM{scrapeMotionValuesFromProps(e,n,i){return{}}constructor({parent:e,props:n,presenceContext:i,reducedMotionConfig:r,blockInitialAnimation:s,visualState:o},a={}){this.applyWillChange=!1,this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=ff,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const h=rn.now();this.renderScheduledAtthis.bindToMotionValue(i,n)),px.current||TM(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:sh.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){mx.delete(this.current),this.projection&&this.projection.unmount(),tn(this.notifyUpdate),tn(this.render),this.valueSubscriptions.forEach(e=>e()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const e in this.events)this.events[e].clear();for(const e in this.features){const n=this.features[e];n&&(n.unmount(),n.isMounted=!1)}this.current=null}bindToMotionValue(e,n){this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();const i=ni.has(e),r=n.on("change",a=>{this.latestValues[e]=a,this.props.onUpdate&&ie.preRender(this.notifyUpdate),i&&this.projection&&(this.projection.isTransformDirty=!0)}),s=n.on("renderRequest",this.scheduleRender);let o;window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,e,n)),this.valueSubscriptions.set(e,()=>{r(),s(),o&&o(),n.owner&&n.stop()})}sortNodePosition(e){return!this.current||!this.sortInstanceNodePosition||this.type!==e.type?0:this.sortInstanceNodePosition(this.current,e.current)}updateFeatures(){let e="animation";for(e in Vr){const n=Vr[e];if(!n)continue;const{isEnabled:i,Feature:r}=n;if(!this.features[e]&&r&&i(this.props)&&(this.features[e]=new r(this)),this.features[e]){const s=this.features[e];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Ce()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,n){this.latestValues[e]=n}update(e,n){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let i=0;in.variantChildren.delete(e)}addValue(e,n){const i=this.values.get(e);n!==i&&(i&&this.removeValue(e),this.bindToMotionValue(e,n),this.values.set(e,n),this.latestValues[e]=n.get())}removeValue(e){this.values.delete(e);const n=this.valueSubscriptions.get(e);n&&(n(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,n){if(this.props.values&&this.props.values[e])return this.props.values[e];let i=this.values.get(e);return i===void 0&&n!==void 0&&(i=$n(n===null?void 0:n,{owner:this}),this.addValue(e,i)),i}readValue(e,n){var i;let r=this.latestValues[e]!==void 0||!this.current?this.latestValues[e]:(i=this.getBaseTargetFromProps(this.props,e))!==null&&i!==void 0?i:this.readValueFromInstance(this.current,e,this.options);return r!=null&&(typeof r=="string"&&(Oy(r)||Ny(r))?r=parseFloat(r):!_M(r)&&si.test(n)&&(r=r0(e,n)),this.setBaseTarget(e,Xe(r)?r.get():r)),Xe(r)?r.get():r}setBaseTarget(e,n){this.baseTarget[e]=n}getBaseTarget(e){var n;const{initial:i}=this.props;let r;if(typeof i=="string"||typeof i=="object"){const o=ef(this.props,i,(n=this.presenceContext)===null||n===void 0?void 0:n.custom);o&&(r=o[e])}if(i&&r!==void 0)return r;const s=this.getBaseTargetFromProps(this.props,e);return s!==void 0&&!Xe(s)?s:this.initialValues[e]!==void 0&&r===void 0?void 0:this.baseTarget[e]}on(e,n){return this.events[e]||(this.events[e]=new Ff),this.events[e].add(n)}notify(e,...n){this.events[e]&&this.events[e].notify(...n)}}class vx extends MM{constructor(){super(...arguments),this.KeyframeResolver=s0}sortInstanceNodePosition(e,n){return e.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(e,n){return e.style?e.style[n]:void 0}removeValueFromRenderState(e,{vars:n,style:i}){delete n[e],delete i[e]}}function DM(t){return window.getComputedStyle(t)}class LM extends vx{constructor(){super(...arguments),this.type="html",this.applyWillChange=!0,this.renderInstance=tx}readValueFromInstance(e,n){if(ni.has(n)){const i=bf(n);return i&&i.default||0}else{const i=DM(e),r=(jy(n)?i.getPropertyValue(n):i[n])||0;return typeof r=="string"?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:n}){return cb(e,n)}build(e,n,i){nh(e,n,i.transformTemplate)}scrapeMotionValuesFromProps(e,n,i){return eh(e,n,i)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;Xe(e)&&(this.childSubscription=e.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class AM extends vx{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ce}getBaseTargetFromProps(e,n){return e[n]}readValueFromInstance(e,n){if(ni.has(n)){const i=bf(n);return i&&i.default||0}return n=nx.has(n)?n:wl(n),e.getAttribute(n)}scrapeMotionValuesFromProps(e,n,i){return sx(e,n,i)}build(e,n,i){ih(e,n,this.isSVGTag,i.transformTemplate)}renderInstance(e,n,i,r){ix(e,n,i,r)}mount(e){this.isSVGTag=rh(e.tagName),super.mount(e)}}const RM=(t,e)=>Jf(t)?new AM(e):new LM(e,{allowProjection:t!==x.Fragment}),FM=kM(k(k(k(k({},P2),W_),R_),U_),RM),oh=bC(FM);function IM(t,e,n){x.useInsertionEffect(()=>t.on(e,n),[t,e,n])}function NM(t,e,n){return typeof t=="string"?t=document.querySelectorAll(t):t instanceof Element&&(t=[t]),Array.from(t||[])}const Dl=new WeakMap;let ai;function OM(t,e){if(e){const{inlineSize:n,blockSize:i}=e[0];return{width:n,height:i}}else return t instanceof SVGElement&&"getBBox"in t?t.getBBox():{width:t.offsetWidth,height:t.offsetHeight}}function VM({target:t,contentRect:e,borderBoxSize:n}){var i;(i=Dl.get(t))===null||i===void 0||i.forEach(r=>{r({target:t,contentSize:e,get size(){return OM(t,n)}})})}function jM(t){t.forEach(VM)}function zM(){typeof ResizeObserver!="undefined"&&(ai=new ResizeObserver(jM))}function BM(t,e){ai||zM();const n=NM(t);return n.forEach(i=>{let r=Dl.get(i);r||(r=new Set,Dl.set(i,r)),r.add(e),ai==null||ai.observe(i)}),()=>{n.forEach(i=>{const r=Dl.get(i);r==null||r.delete(e),r!=null&&r.size||ai==null||ai.unobserve(i)})}}const Ll=new Set;let lo;function KM(){lo=()=>{const t={width:window.innerWidth,height:window.innerHeight},e={target:window,size:t,contentSize:t};Ll.forEach(n=>n(e))},window.addEventListener("resize",lo)}function HM(t){return Ll.add(t),lo||KM(),()=>{Ll.delete(t),!Ll.size&&lo&&(lo=void 0)}}function WM(t,e){return typeof t=="function"?HM(t):BM(t,e)}const UM=50,yx=()=>({current:0,offset:[],progress:0,scrollLength:0,targetOffset:0,targetLength:0,containerLength:0,velocity:0}),YM=()=>({time:0,x:yx(),y:yx()}),GM={x:{length:"Width",position:"Left"},y:{length:"Height",position:"Top"}};function bx(t,e,n,i){const r=n[e],{length:s,position:o}=GM[e],a=r.current,l=n.time;r.current=t[`scroll${o}`],r.scrollLength=t[`scroll${s}`]-t[`client${s}`],r.offset.length=0,r.offset[0]=0,r.offset[1]=r.scrollLength,r.progress=Ni(0,r.scrollLength,r.current);const u=i-l;r.velocity=u>UM?0:wf(r.current-a,u)}function XM(t,e,n){bx(t,"x",e,n),bx(t,"y",e,n),e.time=n}function QM(t,e){const n={x:0,y:0};let i=t;for(;i&&i!==e;)if(i instanceof HTMLElement)n.x+=i.offsetLeft,n.y+=i.offsetTop,i=i.offsetParent;else if(i.tagName==="svg"){const r=i.getBoundingClientRect();i=i.parentElement;const s=i.getBoundingClientRect();n.x+=r.left-s.left,n.y+=r.top-s.top}else if(i instanceof SVGGraphicsElement){const{x:r,y:s}=i.getBBox();n.x+=r,n.y+=s;let o=null,a=i.parentNode;for(;!o;)a.tagName==="svg"&&(o=a),a=i.parentNode;i=o}else break;return n}const qM={Enter:[[0,1],[1,1]],Exit:[[0,0],[1,0]],Any:[[1,0],[0,1]],All:[[0,0],[1,1]]},ah={start:0,center:.5,end:1};function xx(t,e,n=0){let i=0;if(t in ah&&(t=ah[t]),typeof t=="string"){const r=parseFloat(t);t.endsWith("px")?i=r:t.endsWith("%")?t=r/100:t.endsWith("vw")?i=r/100*document.documentElement.clientWidth:t.endsWith("vh")?i=r/100*document.documentElement.clientHeight:t=r}return typeof t=="number"&&(i=e*t),n+i}const ZM=[0,0];function JM(t,e,n,i){let r=Array.isArray(t)?t:ZM,s=0,o=0;return typeof t=="number"?r=[t,t]:typeof t=="string"&&(t=t.trim(),t.includes(" ")?r=t.split(" "):r=[t,ah[t]?t:"0"]),s=xx(r[0],n,i),o=xx(r[1],e),s-o}const eD={x:0,y:0};function tD(t){return"getBBox"in t&&t.tagName!=="svg"?t.getBBox():{width:t.clientWidth,height:t.clientHeight}}function nD(t,e,n){const{offset:i=qM.All}=n,{target:r=t,axis:s="y"}=n,o=s==="y"?"height":"width",a=r!==t?QM(r,t):eD,l=r===t?{width:t.scrollWidth,height:t.scrollHeight}:tD(r),u={width:t.clientWidth,height:t.clientHeight};e[s].offset.length=0;let c=!e[s].interpolate;const d=i.length;for(let f=0;fiD(t,i.target,n),update:r=>{XM(t,n,r),(i.offset||i.target)&&nD(t,n,i)},notify:()=>e(n)}}const uo=new WeakMap,wx=new WeakMap,lh=new WeakMap,Sx=t=>t===document.documentElement?window:t;function uh(t,i={}){var r=i,{container:e=document.documentElement}=r,n=ee(r,["container"]);let s=lh.get(e);s||(s=new Set,lh.set(e,s));const o=YM(),a=rD(e,t,o,n);if(s.add(a),!uo.has(e)){const u=()=>{for(const g of s)g.measure()},c=()=>{for(const g of s)g.update(Fe.timestamp)},d=()=>{for(const g of s)g.notify()},f=()=>{ie.read(u,!1,!0),ie.read(c,!1,!0),ie.update(d,!1,!0)};uo.set(e,f);const h=Sx(e);window.addEventListener("resize",f,{passive:!0}),e!==document.documentElement&&wx.set(e,WM(e,f)),h.addEventListener("scroll",f,{passive:!0})}const l=uo.get(e);return ie.read(l,!1,!0),()=>{var u;tn(l);const c=lh.get(e);if(!c||(c.delete(a),c.size))return;const d=uo.get(e);uo.delete(e),d&&(Sx(e).removeEventListener("scroll",d),(u=wx.get(e))===null||u===void 0||u(),window.removeEventListener("resize",d))}}function Px(t,e){let n;const i=()=>{const{currentTime:r}=e,o=(r===null?0:r.value)/100;n!==o&&t(o),n=o};return ie.update(i,!0),()=>tn(i)}function sD({source:t,container:e,axis:n="y"}){t&&(e=t);const i={value:0},r=uh(s=>{i.value=s[n].progress*100},{container:e,axis:n});return{currentTime:i,cancel:r}}const ch=new Map;function $x({source:t,container:e=document.documentElement,axis:n="y"}={}){t&&(e=t),ch.has(e)||ch.set(e,{});const i=ch.get(e);return i[n]||(i[n]=E0()?new ScrollTimeline({source:e,axis:n}):sD({source:e,axis:n})),i[n]}function oD(t){return t.length===2}function kx(t){return t&&(t.target||t.offset)}function aD(t,e){return oD(t)||kx(e)?uh(n=>{t(n[e.axis].progress,n)},e):Px(t,$x(e))}function lD(t,e){if(kx(e))return t.pause(),uh(n=>{t.time=t.duration*n[e.axis].progress},e);{const n=$x(e);return t.attachTimeline(n,i=>(i.pause(),Px(r=>{i.time=i.duration*r},n)))}}function uD(t,i={}){var r=i,{axis:e="y"}=r,n=ee(r,["axis"]);const s=k({axis:e},n);return typeof t=="function"?aD(t,s):lD(t,s)}function Tx(t,e){AC(!!(!e||e.current))}const cD=()=>({scrollX:$n(0),scrollY:$n(0),scrollXProgress:$n(0),scrollYProgress:$n(0)});function dD(r={}){var s=r,{container:t,target:e,layoutEffect:n=!0}=s,i=ee(s,["container","target","layoutEffect"]);const o=ox(cD);return(n?Xb:x.useEffect)(()=>(Tx("target",e),Tx("container",t),uD((l,{x:u,y:c})=>{o.scrollX.set(u.current),o.scrollXProgress.set(u.progress),o.scrollY.set(c.current),o.scrollYProgress.set(c.progress)},V(k({},i),{container:(t==null?void 0:t.current)||void 0,target:(e==null?void 0:e.current)||void 0}))),[t,e,JSON.stringify(i.offset)]),o}function fD({yearlyData:t}){const[e,n]=x.useState(!1),[i,r]=x.useState(!0),s=x.useRef(null),{scrollXProgress:o}=dD({container:s});return IM(o,"change",a=>{console.log(a),a>0&&n(!0),a===0&&n(!1),r(a!==1)}),D.jsxs("div",{className:"relative",children:[D.jsx(oh.div,{initial:{opacity:0},animate:{opacity:e?1:0},className:"scroll-fader absolute left-0 top-0 z-10 h-full w-[20px] bg-gradient-to-r from-[#ffffff] to-[#ffffff]/0 sm:visible md:visible lg:hidden xl:hidden"}),D.jsx(oh.section,{ref:s,layoutScroll:!0,className:"simpletable--blade relative overflow-x-auto",children:D.jsx("div",{className:"simpletable__table table",style:{padding:0},children:D.jsxs("table",{className:"table-auto border-collapse text-left",children:[D.jsx("thead",{children:D.jsxs("tr",{children:[D.jsx("th",{scope:"col",className:"inline-block min-w-[180px] items-start",children:ge.resultsTableHeader1}),D.jsx("th",{scope:"col",className:"inline-block min-w-[180px] items-start",children:ge.resultsTableHeader2}),D.jsx("th",{scope:"col",className:"inline-block min-w-[180px] items-start",children:ge.resultsTableHeader3}),D.jsx("th",{scope:"col",className:"inline-block min-w-[180px] items-start",children:ge.resultsTableHeader4})]})}),D.jsx("tbody",{children:t.map(a=>D.jsxs("tr",{role:"row",className:"last:bg-[#F1F3FB]",children:[D.jsx("td",{className:"inline-block min-w-[180px] items-start",role:"cell",children:a.year}),D.jsx("td",{className:"inline-block min-w-[180px] items-start",role:"cell",children:a.serviceRepCost!==void 0&&D.jsx(dl,{value:a.serviceRepCost})}),D.jsx("td",{className:"inline-block min-w-[180px] items-start",role:"cell",children:a.cost!==void 0&&D.jsx(dl,{value:a.cost})}),D.jsx("td",{className:"inline-block min-w-[180px] items-start",role:"cell",children:a.savings!==void 0&&D.jsx(dl,{value:a.savings})})]},a.year))})]})})}),D.jsx(oh.div,{initial:{opacity:0},animate:{opacity:i?1:0},className:"scroll-fader absolute right-0 top-0 z-10 h-full w-[20px] bg-gradient-to-l from-[#ffffff] to-[#ffffff]/0 sm:visible md:visible lg:hidden xl:hidden"})]})}class dh{get childNodes(){throw new Error("childNodes is not supported")}clone(){let e=new dh(this.type,this.key);return e.value=this.value,e.level=this.level,e.hasChildNodes=this.hasChildNodes,e.rendered=this.rendered,e.textValue=this.textValue,e["aria-label"]=this["aria-label"],e.index=this.index,e.parentKey=this.parentKey,e.prevKey=this.prevKey,e.nextKey=this.nextKey,e.firstChildKey=this.firstChildKey,e.lastChildKey=this.lastChildKey,e.props=this.props,e.render=this.render,e}constructor(e,n){this.value=null,this.level=0,this.hasChildNodes=!1,this.rendered=null,this.textValue="",this["aria-label"]=void 0,this.index=0,this.parentKey=null,this.prevKey=null,this.nextKey=null,this.firstChildKey=null,this.lastChildKey=null,this.props={},this.type=e,this.key=n}}class hD{get size(){return this.keyMap.size}getKeys(){return this.keyMap.keys()}*[Symbol.iterator](){let e=this.firstKey!=null?this.keyMap.get(this.firstKey):void 0;for(;e;)yield e,e=e.nextKey!=null?this.keyMap.get(e.nextKey):void 0}getChildren(e){let n=this.keyMap;return{*[Symbol.iterator](){let i=n.get(e),r=(i==null?void 0:i.firstChildKey)!=null?n.get(i.firstChildKey):null;for(;r;)yield r,r=r.nextKey!=null?n.get(r.nextKey):void 0}}}getKeyBefore(e){let n=this.keyMap.get(e);if(!n)return null;if(n.prevKey!=null){for(n=this.keyMap.get(n.prevKey);n&&n.type!=="item"&&n.lastChildKey!=null;)n=this.keyMap.get(n.lastChildKey);var i;return(i=n==null?void 0:n.key)!==null&&i!==void 0?i:null}return n.parentKey}getKeyAfter(e){let n=this.keyMap.get(e);if(!n)return null;if(n.type!=="item"&&n.firstChildKey!=null)return n.firstChildKey;for(;n;){if(n.nextKey!=null)return n.nextKey;if(n.parentKey!=null)n=this.keyMap.get(n.parentKey);else return null}return null}getFirstKey(){return this.firstKey}getLastKey(){let e=this.lastKey!=null?this.keyMap.get(this.lastKey):null;for(;(e==null?void 0:e.lastChildKey)!=null;)e=this.keyMap.get(e.lastChildKey);var n;return(n=e==null?void 0:e.key)!==null&&n!==void 0?n:null}getItem(e){var n;return(n=this.keyMap.get(e))!==null&&n!==void 0?n:null}at(){throw new Error("Not implemented")}clone(){let e=this.constructor,n=new e;return n.keyMap=new Map(this.keyMap),n.firstKey=this.firstKey,n.lastKey=this.lastKey,n}addNode(e){if(this.frozen)throw new Error("Cannot add a node to a frozen collection");this.keyMap.set(e.key,e)}removeNode(e){if(this.frozen)throw new Error("Cannot remove a node to a frozen collection");this.keyMap.delete(e)}commit(e,n,i=!1){if(this.frozen)throw new Error("Cannot commit a frozen collection");this.firstKey=e,this.lastKey=n,this.frozen=!i}constructor(){this.keyMap=new Map,this.firstKey=null,this.lastKey=null,this.frozen=!1}}class Cx{*[Symbol.iterator](){let e=this.firstChild;for(;e;)yield e,e=e.nextSibling}get firstChild(){return this._firstChild}set firstChild(e){this._firstChild=e,this.ownerDocument.markDirty(this)}get lastChild(){return this._lastChild}set lastChild(e){this._lastChild=e,this.ownerDocument.markDirty(this)}get previousSibling(){return this._previousSibling}set previousSibling(e){this._previousSibling=e,this.ownerDocument.markDirty(this)}get nextSibling(){return this._nextSibling}set nextSibling(e){this._nextSibling=e,this.ownerDocument.markDirty(this)}get parentNode(){return this._parentNode}set parentNode(e){this._parentNode=e,this.ownerDocument.markDirty(this)}get isConnected(){var e;return((e=this.parentNode)===null||e===void 0?void 0:e.isConnected)||!1}appendChild(e){this.ownerDocument.startTransaction(),e.parentNode&&e.parentNode.removeChild(e),this.firstChild==null&&(this.firstChild=e),this.lastChild?(this.lastChild.nextSibling=e,e.index=this.lastChild.index+1,e.previousSibling=this.lastChild):(e.previousSibling=null,e.index=0),e.parentNode=this,e.nextSibling=null,this.lastChild=e,this.ownerDocument.markDirty(this),e.hasSetProps&&this.ownerDocument.addNode(e),this.ownerDocument.endTransaction(),this.ownerDocument.queueUpdate()}insertBefore(e,n){if(n==null)return this.appendChild(e);this.ownerDocument.startTransaction(),e.parentNode&&e.parentNode.removeChild(e),e.nextSibling=n,e.previousSibling=n.previousSibling,e.index=n.index,this.firstChild===n?this.firstChild=e:n.previousSibling&&(n.previousSibling.nextSibling=e),n.previousSibling=e,e.parentNode=n.parentNode;let i=n;for(;i;)i.index++,i=i.nextSibling;e.hasSetProps&&this.ownerDocument.addNode(e),this.ownerDocument.endTransaction(),this.ownerDocument.queueUpdate()}removeChild(e){if(e.parentNode!==this||!this.ownerDocument.isMounted)return;this.ownerDocument.startTransaction();let n=e.nextSibling;for(;n;)n.index--,n=n.nextSibling;e.nextSibling&&(e.nextSibling.previousSibling=e.previousSibling),e.previousSibling&&(e.previousSibling.nextSibling=e.nextSibling),this.firstChild===e&&(this.firstChild=e.nextSibling),this.lastChild===e&&(this.lastChild=e.previousSibling),e.parentNode=null,e.nextSibling=null,e.previousSibling=null,e.index=0,this.ownerDocument.removeNode(e),this.ownerDocument.endTransaction(),this.ownerDocument.queueUpdate()}addEventListener(){}removeEventListener(){}constructor(e){this._firstChild=null,this._lastChild=null,this._previousSibling=null,this._nextSibling=null,this._parentNode=null,this.ownerDocument=e}}class co extends Cx{get index(){return this._index}set index(e){this._index=e,this.ownerDocument.markDirty(this)}get level(){return this.parentNode instanceof co?this.parentNode.level+(this.node.type==="item"?1:0):0}updateNode(){var e,n,i,r;let s=this.ownerDocument.getMutableNode(this);s.index=this.index,s.level=this.level,s.parentKey=this.parentNode instanceof co?this.parentNode.node.key:null;var o;s.prevKey=(o=(e=this.previousSibling)===null||e===void 0?void 0:e.node.key)!==null&&o!==void 0?o:null;var a;s.nextKey=(a=(n=this.nextSibling)===null||n===void 0?void 0:n.node.key)!==null&&a!==void 0?a:null,s.hasChildNodes=!!this.firstChild;var l;s.firstChildKey=(l=(i=this.firstChild)===null||i===void 0?void 0:i.node.key)!==null&&l!==void 0?l:null;var u;s.lastChildKey=(u=(r=this.lastChild)===null||r===void 0?void 0:r.node.key)!==null&&u!==void 0?u:null}setProps(e,n,i,r){let s=this.ownerDocument.getMutableNode(this),c=e,{value:o,textValue:a,id:l}=c,u=ee(c,["value","textValue","id"]);if(u.ref=n,s.props=u,s.rendered=i,s.render=r,s.value=o,s.textValue=a||(typeof u.children=="string"?u.children:"")||e["aria-label"]||"",l!=null&&l!==s.key){if(this.hasSetProps)throw new Error("Cannot change the id of an item");s.key=l}this.hasSetProps||(this.ownerDocument.addNode(this),this.ownerDocument.endTransaction(),this.hasSetProps=!0),this.ownerDocument.queueUpdate()}get style(){return{}}hasAttribute(){}setAttribute(){}setAttributeNS(){}removeAttribute(){}constructor(e,n){super(n),this.nodeType=8,this._index=0,this.hasSetProps=!1,this.node=new dh(e,`react-aria-${++n.nodeId}`),this.ownerDocument.startTransaction()}}class pD extends Cx{get isConnected(){return this.isMounted}createElement(e){return new co(e,this)}getMutableNode(e){let n=e.node;return this.mutatedNodes.has(e)||(n=e.node.clone(),this.mutatedNodes.add(e),e.node=n),this.markDirty(e),n}getMutableCollection(){return!this.isSSR&&!this.collectionMutated&&(this.collection=this.collection.clone(),this.collectionMutated=!0),this.collection}markDirty(e){this.dirtyNodes.add(e)}startTransaction(){this.transactionCount++}endTransaction(){this.transactionCount--}addNode(e){let n=this.getMutableCollection();if(!n.getItem(e.node.key)){n.addNode(e.node);for(let i of e)this.addNode(i)}this.markDirty(e)}removeNode(e){for(let i of e)this.removeNode(i);this.getMutableCollection().removeNode(e.node.key),this.markDirty(e)}getCollection(){return this.transactionCount>0?this.collection:(this.updateCollection(),this.collection)}updateCollection(){for(let s of this.dirtyNodes)s instanceof co&&s.isConnected&&s.updateNode();if(this.dirtyNodes.clear(),this.mutatedNodes.size||this.collectionMutated){var e,n;let s=this.getMutableCollection();for(let o of this.mutatedNodes)o.isConnected&&s.addNode(o.node);var i,r;s.commit((i=(e=this.firstChild)===null||e===void 0?void 0:e.node.key)!==null&&i!==void 0?i:null,(r=(n=this.lastChild)===null||n===void 0?void 0:n.node.key)!==null&&r!==void 0?r:null,this.isSSR),this.mutatedNodes.clear()}this.collectionMutated=!1}queueUpdate(){if(!(this.dirtyNodes.size===0||this.transactionCount>0))for(let e of this.subscriptions)e()}subscribe(e){return this.subscriptions.add(e),()=>this.subscriptions.delete(e)}resetAfterSSR(){this.isSSR&&(this.isSSR=!1,this.firstChild=null,this.lastChild=null,this.nodeId=0)}constructor(e){super(null),this.nodeType=11,this.ownerDocument=this,this.dirtyNodes=new Set,this.isSSR=!1,this.nodeId=0,this.nodesByProps=new WeakMap,this.isMounted=!0,this.mutatedNodes=new Set,this.subscriptions=new Set,this.transactionCount=0,this.collection=e,this.collectionMutated=!0}}function Ex(t){let{children:e,items:n,idScope:i,addIdAndValue:r,dependencies:s=[]}=t,o=x.useMemo(()=>new WeakMap,s);return x.useMemo(()=>{if(n&&typeof e=="function"){let u=[];for(let c of n){let d=o.get(c);if(!d){d=e(c);var a,l;let f=(l=(a=d.props.id)!==null&&a!==void 0?a:c.key)!==null&&l!==void 0?l:c.id;if(f==null)throw new Error("Could not determine key for item");i&&(f=i+":"+f),d=x.cloneElement(d,r?{key:f,id:f,value:c}:{key:f}),o.set(c,d)}u.push(d)}return u}else if(typeof e!="function")return e},[e,n,o,i,r])}const Al={prefix:String(Math.round(Math.random()*1e10)),current:0},_x=W.createContext(Al),mD=W.createContext(!1);let gD=!!(typeof window!="undefined"&&window.document&&window.document.createElement),fh=new WeakMap;function vD(t=!1){let e=x.useContext(_x),n=x.useRef(null);if(n.current===null&&!t){var i,r;let s=(r=W.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED)===null||r===void 0||(i=r.ReactCurrentOwner)===null||i===void 0?void 0:i.current;if(s){let o=fh.get(s);o==null?fh.set(s,{id:e.current,state:s.memoizedState}):s.memoizedState!==o.state&&(e.current=o.id,fh.delete(s))}n.current=++e.current}return n.current}function yD(t){let e=x.useContext(_x);e===Al&&!gD&&console.warn("When server rendering, you must wrap your application in an to ensure consistent ids are generated between the client and server.");let n=vD(!!t),i=`react-aria${e.prefix}`;return t||`${i}-${n}`}function bD(t){let e=W.useId(),[n]=x.useState(fo()),i=n?"react-aria":`react-aria${Al.prefix}`;return t||`${i}-${e}`}const xD=typeof W.useId=="function"?bD:yD;function wD(){return!1}function SD(){return!0}function PD(t){return()=>{}}function fo(){return typeof W.useSyncExternalStore=="function"?W.useSyncExternalStore(PD,wD,SD):x.useContext(mD)}if(typeof HTMLTemplateElement!="undefined"){const t=Object.getOwnPropertyDescriptor(Node.prototype,"firstChild").get;Object.defineProperty(HTMLTemplateElement.prototype,"firstChild",{configurable:!0,enumerable:!0,get:function(){return this.dataset.reactAriaHidden?this.content.firstChild:t.call(this)}})}const hh=x.createContext(!1),$D=typeof DocumentFragment!="undefined"?new DocumentFragment:null;function kD(t){let e=x.useContext(hh),n=fo();if(e)return W.createElement(W.Fragment,null,t.children);let i=W.createElement(hh.Provider,{value:!0},t.children);return n?W.createElement("template",{"data-react-aria-hidden":!0},i):cl.createPortal(i,$D)}function ph(t){let e=(n,i)=>x.useContext(hh)?null:t(n,i);return e.displayName=t.displayName||t.name,x.forwardRef(e)}const Yt=typeof document!="undefined"?W.useLayoutEffect:()=>{};function Ie(t){const e=x.useRef(null);return Yt(()=>{e.current=t},[t]),x.useCallback((...n)=>{const i=e.current;return i==null?void 0:i(...n)},[])}function TD(t){let[e,n]=x.useState(t),i=x.useRef(null),r=Ie(()=>{if(!i.current)return;let o=i.current.next();if(o.done){i.current=null;return}e===o.value?r():n(o.value)});Yt(()=>{i.current&&r()});let s=Ie(o=>{i.current=o(e),r()});return[e,s]}let CD=!!(typeof window!="undefined"&&window.document&&window.document.createElement),li=new Map;function ui(t){let[e,n]=x.useState(t),i=x.useRef(null),r=xD(e),s=x.useCallback(o=>{i.current=o},[]);return CD&&(li.has(r)&&!li.get(r).includes(s)?li.set(r,[...li.get(r),s]):li.set(r,[s])),Yt(()=>{let o=r;return()=>{li.delete(o)}},[r]),x.useEffect(()=>{let o=i.current;o&&(i.current=null,n(o))}),r}function ED(t,e){if(t===e)return t;let n=li.get(t);if(n)return n.forEach(r=>r(e)),e;let i=li.get(e);return i?(i.forEach(r=>r(t)),t):e}function Mx(t=[]){let e=ui(),[n,i]=TD(e),r=x.useCallback(()=>{i(function*(){yield e,yield document.getElementById(e)?e:void 0})},[e,i]);return Yt(r,[e,r,...t]),n}function mh(...t){return(...e)=>{for(let n of t)typeof n=="function"&&n(...e)}}const lt=t=>{var e;return(e=t==null?void 0:t.ownerDocument)!==null&&e!==void 0?e:document},Rt=t=>t&&"window"in t&&t.window===t?t:lt(t).defaultView||window;function Dx(t){var e,n,i="";if(typeof t=="string"||typeof t=="number")i+=t;else if(typeof t=="object")if(Array.isArray(t)){var r=t.length;for(e=0;e=65&&r.charCodeAt(2)<=90?e[r]=mh(s,o):(r==="className"||r==="UNSAFE_className")&&typeof s=="string"&&typeof o=="string"?e[r]=_D(s,o):r==="id"&&s&&o?e.id=ED(s,o):e[r]=o!==void 0?o:s}}return e}function MD(...t){return t.length===1&&t[0]?t[0]:e=>{for(let n of t)typeof n=="function"?n(e):n!=null&&(n.current=e)}}const DD=new Set(["id"]),LD=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),AD=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),RD=/^(data-.*)$/;function Gt(t,e={}){let{labelable:n,isLink:i,propNames:r}=e,s={};for(const o in t)Object.prototype.hasOwnProperty.call(t,o)&&(DD.has(o)||n&&LD.has(o)||i&&AD.has(o)||r!=null&&r.has(o)||RD.test(o))&&(s[o]=t[o]);return s}function sn(t){if(FD())t.focus({preventScroll:!0});else{let e=ID(t);t.focus(),ND(e)}}let Rl=null;function FD(){if(Rl==null){Rl=!1;try{document.createElement("div").focus({get preventScroll(){return Rl=!0,!0}})}catch(t){}}return Rl}function ID(t){let e=t.parentNode,n=[],i=document.scrollingElement||document.documentElement;for(;e instanceof HTMLElement&&e!==i;)(e.offsetHeightt.test(n.brand)))||t.test(window.navigator.userAgent)}function gh(t){var e;return typeof window!="undefined"&&window.navigator!=null?t.test(((e=window.navigator.userAgentData)===null||e===void 0?void 0:e.platform)||window.navigator.platform):!1}function Cn(t){let e=null;return()=>(e==null&&(e=t()),e)}const zi=Cn(function(){return gh(/^Mac/i)}),Lx=Cn(function(){return gh(/^iPhone/i)}),Ax=Cn(function(){return gh(/^iPad/i)||zi()&&navigator.maxTouchPoints>1}),Il=Cn(function(){return Lx()||Ax()}),OD=Cn(function(){return zi()||Il()}),VD=Cn(function(){return Fl(/AppleWebKit/i)&&!jD()}),jD=Cn(function(){return Fl(/Chrome/i)}),vh=Cn(function(){return Fl(/Android/i)}),zD=Cn(function(){return Fl(/Firefox/i)}),BD=x.createContext({isNative:!0,open:WD,useHref:t=>t});function Nl(){return x.useContext(BD)}function KD(t,e){let n=t.getAttribute("target");return(!n||n==="_self")&&t.origin===location.origin&&!t.hasAttribute("download")&&!e.metaKey&&!e.ctrlKey&&!e.altKey&&!e.shiftKey}function Bi(t,e,n=!0){var i,r;let{metaKey:s,ctrlKey:o,altKey:a,shiftKey:l}=e;zD()&&(!((r=window.event)===null||r===void 0||(i=r.type)===null||i===void 0)&&i.startsWith("key"))&&t.target==="_blank"&&(zi()?s=!0:o=!0);let u=VD()&&zi()&&!Ax()?new KeyboardEvent("keydown",{keyIdentifier:"Enter",metaKey:s,ctrlKey:o,altKey:a,shiftKey:l}):new MouseEvent("click",{metaKey:s,ctrlKey:o,altKey:a,shiftKey:l,bubbles:!0,cancelable:!0});Bi.isOpening=n,sn(t),t.dispatchEvent(u),Bi.isOpening=!1}Bi.isOpening=!1;function HD(t,e){if(t instanceof HTMLAnchorElement)e(t);else if(t.hasAttribute("data-href")){let n=document.createElement("a");n.href=t.getAttribute("data-href"),t.hasAttribute("data-target")&&(n.target=t.getAttribute("data-target")),t.hasAttribute("data-rel")&&(n.rel=t.getAttribute("data-rel")),t.hasAttribute("data-download")&&(n.download=t.getAttribute("data-download")),t.hasAttribute("data-ping")&&(n.ping=t.getAttribute("data-ping")),t.hasAttribute("data-referrer-policy")&&(n.referrerPolicy=t.getAttribute("data-referrer-policy")),t.appendChild(n),e(n),t.removeChild(n)}}function WD(t,e){HD(t,n=>Bi(n,e))}function Rx(t){let e=Nl();var n;const i=e.useHref((n=t==null?void 0:t.href)!==null&&n!==void 0?n:"");return{href:t!=null&&t.href?i:void 0,target:t==null?void 0:t.target,rel:t==null?void 0:t.rel,download:t==null?void 0:t.download,ping:t==null?void 0:t.ping,referrerPolicy:t==null?void 0:t.referrerPolicy}}let jr=new Map,yh=new Set;function Fx(){if(typeof window=="undefined")return;function t(i){return"propertyName"in i}let e=i=>{if(!t(i)||!i.target)return;let r=jr.get(i.target);r||(r=new Set,jr.set(i.target,r),i.target.addEventListener("transitioncancel",n,{once:!0})),r.add(i.propertyName)},n=i=>{if(!t(i)||!i.target)return;let r=jr.get(i.target);if(r&&(r.delete(i.propertyName),r.size===0&&(i.target.removeEventListener("transitioncancel",n),jr.delete(i.target)),jr.size===0)){for(let s of yh)s();yh.clear()}};document.body.addEventListener("transitionrun",e),document.body.addEventListener("transitionend",n)}typeof document!="undefined"&&(document.readyState!=="loading"?Fx():document.addEventListener("DOMContentLoaded",Fx));function Ix(t){requestAnimationFrame(()=>{jr.size===0?t():yh.add(t)})}function zr(){let t=x.useRef(new Map),e=x.useCallback((r,s,o,a)=>{let l=a!=null&&a.once?(...u)=>{t.current.delete(o),o(...u)}:o;t.current.set(o,{type:s,eventTarget:r,fn:l,options:a}),r.addEventListener(s,o,a)},[]),n=x.useCallback((r,s,o,a)=>{var l;let u=((l=t.current.get(o))===null||l===void 0?void 0:l.fn)||o;r.removeEventListener(s,u,a),t.current.delete(o)},[]),i=x.useCallback(()=>{t.current.forEach((r,s)=>{n(r.eventTarget,r.type,s,r.options)})},[n]);return x.useEffect(()=>i,[i]),{addGlobalListener:e,removeGlobalListener:n,removeAllGlobalListeners:i}}function bh(t,e){let{id:n,"aria-label":i,"aria-labelledby":r}=t;return n=ui(n),r&&i?r=[...new Set([n,...r.trim().split(/\s+/)])].join(" "):r&&(r=r.trim().split(/\s+/).join(" ")),!i&&!r&&e&&(i=e),{id:n,"aria-label":i,"aria-labelledby":r}}function Ol(t){const e=x.useRef(null);return x.useMemo(()=>({get current(){return e.current},set current(n){e.current=n,typeof t=="function"?t(n):t&&(t.current=n)}}),[t])}function Nx(t,e){Yt(()=>{if(t&&t.ref&&e)return t.ref.current=e.current,()=>{t.ref&&(t.ref.current=null)}})}function UD(t,e){let n=window.getComputedStyle(t),i=/(auto|scroll)/.test(n.overflow+n.overflowX+n.overflowY);return i&&e&&(i=t.scrollHeight!==t.clientHeight||t.scrollWidth!==t.clientWidth),i}function YD(t,e){const n=[];for(;t&&t!==document.documentElement;)UD(t,e)&&n.push(t),t=t.parentElement;return n}let GD=0;const xh=new Map;function XD(t){let[e,n]=x.useState();return Yt(()=>{if(!t)return;let i=xh.get(t);if(i)n(i.element.id);else{let r=`react-aria-description-${GD++}`;n(r);let s=document.createElement("div");s.id=r,s.style.display="none",s.textContent=t,document.body.appendChild(s),i={refCount:0,element:s},xh.set(t,i)}return i.refCount++,()=>{i&&--i.refCount===0&&(i.element.remove(),xh.delete(t))}},[t]),{"aria-describedby":t?e:void 0}}function wh(t,e,n,i){let r=Ie(n),s=n==null;x.useEffect(()=>{if(s||!t.current)return;let o=t.current;return o.addEventListener(e,r,i),()=>{o.removeEventListener(e,r,i)}},[t,e,i,s,r])}function Ox(t,e){let n=Vx(t,e,"left"),i=Vx(t,e,"top"),r=e.offsetWidth,s=e.offsetHeight,o=t.scrollLeft,a=t.scrollTop,{borderTopWidth:l,borderLeftWidth:u}=getComputedStyle(t),c=t.scrollLeft+parseInt(u,10),d=t.scrollTop+parseInt(l,10),f=c+t.clientWidth,h=d+t.clientHeight;n<=o?o=n-parseInt(u,10):n+r>f&&(o+=n+r-f),i<=d?a=i-parseInt(l,10):i+s>h&&(a+=i+s-h),t.scrollLeft=o,t.scrollTop=a}function Vx(t,e,n){const i=n==="left"?"offsetLeft":"offsetTop";let r=0;for(;e.offsetParent&&(r+=e[i],e.offsetParent!==t);){if(e.offsetParent.contains(t)){r-=t[i];break}e=e.offsetParent}return r}function jx(t,e){if(document.contains(t)){let o=document.scrollingElement||document.documentElement;if(window.getComputedStyle(o).overflow==="hidden"){let l=YD(t);for(let u of l)Ox(u,t)}else{var n;let{left:l,top:u}=t.getBoundingClientRect();t==null||(n=t.scrollIntoView)===null||n===void 0||n.call(t,{block:"nearest"});let{left:c,top:d}=t.getBoundingClientRect();if(Math.abs(l-c)>1||Math.abs(u-d)>1){var i,r,s;e==null||(r=e.containingElement)===null||r===void 0||(i=r.scrollIntoView)===null||i===void 0||i.call(r,{block:"center",inline:"center"}),(s=t.scrollIntoView)===null||s===void 0||s.call(t,{block:"nearest"})}}}}function Sh(t){return t.mozInputSource===0&&t.isTrusted?!0:vh()&&t.pointerType?t.type==="click"&&t.buttons===1:t.detail===0&&!t.pointerType}function QD(t){return!vh()&&t.width===0&&t.height===0||t.width===1&&t.height===1&&t.pressure===0&&t.detail===0&&t.pointerType==="mouse"}function Ph(t,e,n){let i=x.useRef(e),r=Ie(()=>{n&&n(i.current)});x.useEffect(()=>{var s;let o=t==null||(s=t.current)===null||s===void 0?void 0:s.form;return o==null||o.addEventListener("reset",r),()=>{o==null||o.removeEventListener("reset",r)}},[t,r])}function ho(t,e,n){let[i,r]=x.useState(t||e),s=x.useRef(t!==void 0),o=t!==void 0;x.useEffect(()=>{let u=s.current;u!==o&&console.warn(`WARN: A component changed from ${u?"controlled":"uncontrolled"} to ${o?"controlled":"uncontrolled"}.`),s.current=o},[o]);let a=o?t:i,l=x.useCallback((u,...c)=>{let d=(f,...h)=>{n&&(Object.is(a,f)||n(f,...h)),o||(a=f)};typeof u=="function"?(console.warn("We can not support a function callback. See Github Issues for details https://github.com/adobe/react-spectrum/issues/2320"),r((h,...g)=>{let v=u(o?a:h,...g);return d(v,...c),o?h:v})):(o||r(u),d(u,...c))},[o,a,n]);return[a,l]}function Br(t,e=-1/0,n=1/0){return Math.min(Math.max(t,e),n)}function Vl(t,e){let n=t,i=e.toString(),r=i.indexOf("."),s=r>=0?i.length-r:0;if(s>0){let o=Math.pow(10,s);n=Math.round(n*o)/o}return n}function ut(t,e,n,i){e=Number(e),n=Number(n);let r=(t-(isNaN(e)?0:e))%i,s=Vl(Math.abs(r)*2>=i?t+Math.sign(r)*(i-Math.abs(r)):t-r,i);return isNaN(e)?!isNaN(n)&&s>n&&(s=Math.floor(Vl(n/i,i))*i):sn&&(s=e+Math.floor(Vl((n-e)/i,i))*i),s=Vl(s,i),s}var zx={exports:{}},Bx={};/** * @license React * use-sync-external-store-shim.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Kr=x;function qD(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var ZD=typeof Object.is=="function"?Object.is:qD,JD=Kr.useState,e4=Kr.useEffect,t4=Kr.useLayoutEffect,n4=Kr.useDebugValue;function i4(t,e){var n=e(),i=JD({inst:{value:n,getSnapshot:e}}),r=i[0].inst,s=i[1];return t4(function(){r.value=n,r.getSnapshot=e,$h(r)&&s({inst:r})},[t,n,e]),e4(function(){return $h(r)&&s({inst:r}),t(function(){$h(r)&&s({inst:r})})},[t]),n4(n),n}function $h(t){var e=t.getSnapshot;t=t.value;try{var n=e();return!ZD(t,n)}catch(i){return!0}}function r4(t,e){return e()}var s4=typeof window=="undefined"||typeof window.document=="undefined"||typeof window.document.createElement=="undefined"?r4:i4;Bx.useSyncExternalStore=Kr.useSyncExternalStore!==void 0?Kr.useSyncExternalStore:s4,zx.exports=Bx;var o4=zx.exports;const Kx=x.createContext(!1),po=x.createContext(null);function a4(t){if(x.useContext(po))return t.content;let{collection:n,document:i}=d4(t.createCollection);return W.createElement(W.Fragment,null,W.createElement(kD,null,W.createElement(po.Provider,{value:i},t.content)),W.createElement(l4,{render:t.children,collection:n}))}function l4({collection:t,render:e}){return e(t)}function u4(t,e,n){let i=fo(),r=x.useRef(i);r.current=i;let s=x.useCallback(()=>r.current?n():e(),[e,n]);return o4.useSyncExternalStore(t,s)}const c4=typeof W.useSyncExternalStore=="function"?W.useSyncExternalStore:u4;function d4(t){let[e]=x.useState(()=>new pD((t==null?void 0:t())||new hD)),n=x.useCallback(o=>e.subscribe(o),[e]),i=x.useCallback(()=>{let o=e.getCollection();return e.isSSR&&e.resetAfterSSR(),o},[e]),r=x.useCallback(()=>(e.isSSR=!0,e.getCollection()),[e]),s=c4(n,i,r);return Yt(()=>(e.isMounted=!0,()=>{e.isMounted=!1}),[e]),{collection:s,document:e}}const kh=x.createContext(null);function f4(t,e,n,i,r,s){let o=x.useCallback(l=>{l==null||l.setProps(e,n,i,s)},[e,n,i,s]),a=x.useContext(kh);if(a){let l=a.ownerDocument.nodesByProps.get(e);return l||(l=a.ownerDocument.createElement(t),l.setProps(e,n,i,s),a.appendChild(l),a.ownerDocument.updateCollection(),a.ownerDocument.nodesByProps.set(e,l)),r?W.createElement(kh.Provider,{value:l},r):null}return W.createElement(t,{ref:o},r)}function h4(t,e){let n=({node:r})=>e(r.props,r.props.ref,r),i=x.forwardRef((r,s)=>{if(!x.useContext(Kx)){if(e.length>=3)throw new Error(e.name+" cannot be rendered outside a collection.");return e(r,s)}return f4(t,r,s,"children"in r?r.children:null,null,a=>W.createElement(n,{node:a}))});return i.displayName=e.name,i}function p4(t){return Ex(V(k({},t),{addIdAndValue:!0}))}const Hx=x.createContext(null);function m4(t){let e=x.useContext(Hx),n=((e==null?void 0:e.dependencies)||[]).concat(t.dependencies),i=t.idScope||(e==null?void 0:e.idScope),r=p4(V(k({},t),{idScope:i,dependencies:n}));return x.useContext(po)&&(r=W.createElement(g4,null,r)),e=x.useMemo(()=>({dependencies:n,idScope:i}),[i,...n]),W.createElement(Hx.Provider,{value:e},r)}function g4({children:t}){let e=x.useContext(po),n=x.useMemo(()=>W.createElement(po.Provider,{value:null},W.createElement(Kx.Provider,{value:!0},t)),[t]);return fo()?W.createElement(kh.Provider,{value:e},n):cl.createPortal(n,e)}const v4={CollectionRoot({collection:t,renderDropIndicator:e}){return Wx(t,null,e)},CollectionBranch({collection:t,parent:e,renderDropIndicator:n}){return Wx(t,e,n)}};function Wx(t,e,n){return Ex({items:e?t.getChildren(e.key):t,dependencies:[n],children(i){var r;let s=i.render(i);if(!n||i.type!=="item")return s;let o=i.key,a=t.getKeyAfter(o);return W.createElement(W.Fragment,null,n({type:"item",key:o,dropPosition:"before"}),s,(a==null||((r=t.getItem(a))===null||r===void 0?void 0:r.type)!=="item")&&n({type:"item",key:o,dropPosition:"after"}))}})}const y4=x.createContext(v4);function b4(t){return x.useMemo(()=>t!=null?new Set([t]):null,[t])}const Ux=Symbol("default");function mo({values:t,children:e}){for(let[n,i]of t)e=W.createElement(n.Provider,{value:i},e);return e}function St(t){let{className:e,style:n,children:i,defaultClassName:r,defaultChildren:s,defaultStyle:o,values:a}=t;return x.useMemo(()=>{let l,u,c;return typeof e=="function"?l=e(V(k({},a),{defaultClassName:r})):l=e,typeof n=="function"?u=n(V(k({},a),{defaultStyle:o||{}})):u=n,typeof i=="function"?c=i(V(k({},a),{defaultChildren:s})):i==null?c=s:c=i,{className:l!=null?l:r,style:u||o?k(k({},o),u):void 0,children:c!=null?c:s,"data-rac":""}},[e,n,i,r,s,o,a])}function jl(t,e){let n=x.useContext(t);if(e===null)return null;if(n&&typeof n=="object"&&"slots"in n&&n.slots){let i=new Intl.ListFormat().format(Object.keys(n.slots).map(s=>`"${s}"`));if(!e&&!n.slots[Ux])throw new Error(`A slot prop is required. Valid slot names are ${i}.`);let r=e||Ux;if(!n.slots[r])throw new Error(`Invalid slot "${e}". Valid slot names are ${i}.`);return n.slots[r]}return n}function on(t,e,n){let l=jl(n,t.slot)||{},{ref:r}=l,s=ee(l,["ref"]),o=Ol(x.useMemo(()=>MD(e,r),[e,r])),a=se(s,t);return"style"in s&&s.style&&"style"in t&&t.style&&(typeof s.style=="function"||typeof t.style=="function"?a.style=u=>{let c=typeof s.style=="function"?s.style(u):s.style,d=k(k({},u.defaultStyle),c),f=typeof t.style=="function"?t.style(V(k({},u),{defaultStyle:d})):t.style;return k(k({},d),f)}:a.style=k(k({},s.style),t.style)),[a,o]}function Th(){let[t,e]=x.useState(!0),n=x.useRef(!1),i=x.useCallback(r=>{n.current=!0,e(!!r)},[]);return Yt(()=>{n.current||e(!1)},[]),[i,t]}function x4(t){const e=/^(data-.*)$/;let n={};for(const i in t)e.test(i)||(n[i]=t[i]);return n}let Hr="default",Ch="",zl=new WeakMap;function Eh(t){if(Il()){if(Hr==="default"){const e=lt(t);Ch=e.documentElement.style.webkitUserSelect,e.documentElement.style.webkitUserSelect="none"}Hr="disabled"}else(t instanceof HTMLElement||t instanceof SVGElement)&&(zl.set(t,t.style.userSelect),t.style.userSelect="none")}function go(t){if(Il()){if(Hr!=="disabled")return;Hr="restoring",setTimeout(()=>{Ix(()=>{if(Hr==="restoring"){const e=lt(t);e.documentElement.style.webkitUserSelect==="none"&&(e.documentElement.style.webkitUserSelect=Ch||""),Ch="",Hr="default"}})},300)}else if((t instanceof HTMLElement||t instanceof SVGElement)&&t&&zl.has(t)){let e=zl.get(t);t.style.userSelect==="none"&&(t.style.userSelect=e),t.getAttribute("style")===""&&t.removeAttribute("style"),zl.delete(t)}}const Yx=W.createContext({register:()=>{}});Yx.displayName="PressResponderContext";function w4(t,e){return e.get?e.get.call(t):e.value}function Gx(t,e,n){if(!e.has(t))throw new TypeError("attempted to "+n+" private field on non-instance");return e.get(t)}function S4(t,e){var n=Gx(t,e,"get");return w4(t,n)}function P4(t,e){if(e.has(t))throw new TypeError("Cannot initialize the same private elements twice on an object")}function $4(t,e,n){P4(t,e),e.set(t,n)}function k4(t,e,n){if(e.set)e.set.call(t,n);else{if(!e.writable)throw new TypeError("attempted to set read only private field");e.value=n}}function Xx(t,e,n){var i=Gx(t,e,"set");return k4(t,i,n),n}function T4(t){let e=x.useContext(Yx);if(e){let n=e,{register:i}=n,r=ee(n,["register"]);t=se(r,t),i()}return Nx(e,t.ref),t}var Bl=new WeakMap;class Kl{continuePropagation(){Xx(this,Bl,!1)}get shouldStopPropagation(){return S4(this,Bl)}constructor(e,n,i,r){$4(this,Bl,{writable:!0,value:void 0}),Xx(this,Bl,!0);var s;let o=(s=r==null?void 0:r.target)!==null&&s!==void 0?s:i.currentTarget;const a=o==null?void 0:o.getBoundingClientRect();let l,u=0,c,d=null;i.clientX!=null&&i.clientY!=null&&(c=i.clientX,d=i.clientY),a&&(c!=null&&d!=null?(l=c-a.left,u=d-a.top):(l=a.width/2,u=a.height/2)),this.type=e,this.pointerType=n,this.target=i.currentTarget,this.shiftKey=i.shiftKey,this.metaKey=i.metaKey,this.ctrlKey=i.ctrlKey,this.altKey=i.altKey,this.x=l,this.y=u}}const Qx=Symbol("linkClicked");function _h(t){let _=T4(t),{onPress:e,onPressChange:n,onPressStart:i,onPressEnd:r,onPressUp:s,isDisabled:o,isPressed:a,preventFocusOnPress:l,shouldCancelOnPointerExit:u,allowTextSelectionOnPress:c,ref:d}=_,f=ee(_,["onPress","onPressChange","onPressStart","onPressEnd","onPressUp","isDisabled","isPressed","preventFocusOnPress","shouldCancelOnPointerExit","allowTextSelectionOnPress","ref"]),[h,g]=x.useState(!1),v=x.useRef({isPressed:!1,ignoreEmulatedMouseEvents:!1,ignoreClickAfterPress:!1,didFirePressStart:!1,isTriggeringEvent:!1,activePointerId:null,target:null,isOverTarget:!1,pointerType:null}),{addGlobalListener:b,removeAllGlobalListeners:p}=zr(),m=Ie((w,$)=>{let F=v.current;if(o||F.didFirePressStart)return!1;let T=!0;if(F.isTriggeringEvent=!0,i){let N=new Kl("pressstart",$,w);i(N),T=N.shouldStopPropagation}return n&&n(!0),F.isTriggeringEvent=!1,F.didFirePressStart=!0,g(!0),T}),y=Ie((w,$,F=!0)=>{let T=v.current;if(!T.didFirePressStart)return!1;T.ignoreClickAfterPress=!0,T.didFirePressStart=!1,T.isTriggeringEvent=!0;let N=!0;if(r){let M=new Kl("pressend",$,w);r(M),N=M.shouldStopPropagation}if(n&&n(!1),g(!1),e&&F&&!o){let M=new Kl("press",$,w);e(M),N&&(N=M.shouldStopPropagation)}return T.isTriggeringEvent=!1,N}),S=Ie((w,$)=>{let F=v.current;if(o)return!1;if(s){F.isTriggeringEvent=!0;let T=new Kl("pressup",$,w);return s(T),F.isTriggeringEvent=!1,T.shouldStopPropagation}return!0}),P=Ie(w=>{let $=v.current;$.isPressed&&$.target&&($.isOverTarget&&$.pointerType!=null&&y(En($.target,w),$.pointerType,!1),$.isPressed=!1,$.isOverTarget=!1,$.activePointerId=null,$.pointerType=null,p(),c||go($.target))}),C=Ie(w=>{u&&P(w)}),L=x.useMemo(()=>{let w=v.current,$={onKeyDown(T){if(Dh(T.nativeEvent,T.currentTarget)&&T.currentTarget.contains(T.target)){var N;Jx(T.target,T.key)&&T.preventDefault();let M=!0;if(!w.isPressed&&!T.repeat){w.target=T.currentTarget,w.isPressed=!0,M=m(T,"keyboard");let O=T.currentTarget,E=A=>{Dh(A,O)&&!A.repeat&&O.contains(A.target)&&w.target&&S(En(w.target,A),"keyboard")};b(lt(T.currentTarget),"keyup",mh(E,F),!0)}M&&T.stopPropagation(),T.metaKey&&zi()&&((N=w.metaKeyEvents)===null||N===void 0||N.set(T.key,T.nativeEvent))}else T.key==="Meta"&&(w.metaKeyEvents=new Map)},onClick(T){if(!(T&&!T.currentTarget.contains(T.target))&&T&&T.button===0&&!w.isTriggeringEvent&&!Bi.isOpening){let N=!0;if(o&&T.preventDefault(),!w.ignoreClickAfterPress&&!w.ignoreEmulatedMouseEvents&&!w.isPressed&&(w.pointerType==="virtual"||Sh(T.nativeEvent))){!o&&!l&&sn(T.currentTarget);let M=m(T,"virtual"),O=S(T,"virtual"),E=y(T,"virtual");N=M&&O&&E}w.ignoreEmulatedMouseEvents=!1,w.ignoreClickAfterPress=!1,N&&T.stopPropagation()}}},F=T=>{var N;if(w.isPressed&&w.target&&Dh(T,w.target)){var M;Jx(T.target,T.key)&&T.preventDefault();let E=T.target;y(En(w.target,T),"keyboard",w.target.contains(E)),p(),T.key!=="Enter"&&Mh(w.target)&&w.target.contains(E)&&!T[Qx]&&(T[Qx]=!0,Bi(w.target,T,!1)),w.isPressed=!1,(M=w.metaKeyEvents)===null||M===void 0||M.delete(T.key)}else if(T.key==="Meta"&&(!((N=w.metaKeyEvents)===null||N===void 0)&&N.size)){var O;let E=w.metaKeyEvents;w.metaKeyEvents=void 0;for(let A of E.values())(O=w.target)===null||O===void 0||O.dispatchEvent(new KeyboardEvent("keyup",A))}};if(typeof PointerEvent!="undefined"){$.onPointerDown=E=>{if(E.button!==0||!E.currentTarget.contains(E.target))return;if(QD(E.nativeEvent)){w.pointerType="virtual";return}Lh(E.currentTarget)&&E.preventDefault(),w.pointerType=E.pointerType;let A=!0;w.isPressed||(w.isPressed=!0,w.isOverTarget=!0,w.activePointerId=E.pointerId,w.target=E.currentTarget,!o&&!l&&sn(E.currentTarget),c||Eh(w.target),A=m(E,w.pointerType),b(lt(E.currentTarget),"pointermove",T,!1),b(lt(E.currentTarget),"pointerup",N,!1),b(lt(E.currentTarget),"pointercancel",O,!1)),A&&E.stopPropagation()},$.onMouseDown=E=>{E.currentTarget.contains(E.target)&&E.button===0&&(Lh(E.currentTarget)&&E.preventDefault(),E.stopPropagation())},$.onPointerUp=E=>{!E.currentTarget.contains(E.target)||w.pointerType==="virtual"||E.button===0&&Wr(E,E.currentTarget)&&S(E,w.pointerType||E.pointerType)};let T=E=>{E.pointerId===w.activePointerId&&(w.target&&Wr(E,w.target)?!w.isOverTarget&&w.pointerType!=null&&(w.isOverTarget=!0,m(En(w.target,E),w.pointerType)):w.target&&w.isOverTarget&&w.pointerType!=null&&(w.isOverTarget=!1,y(En(w.target,E),w.pointerType,!1),C(E)))},N=E=>{E.pointerId===w.activePointerId&&w.isPressed&&E.button===0&&w.target&&(Wr(E,w.target)&&w.pointerType!=null?y(En(w.target,E),w.pointerType):w.isOverTarget&&w.pointerType!=null&&y(En(w.target,E),w.pointerType,!1),w.isPressed=!1,w.isOverTarget=!1,w.activePointerId=null,w.pointerType=null,p(),c||go(w.target),"ontouchend"in w.target&&E.pointerType!=="mouse"&&b(w.target,"touchend",M,{once:!0}))},M=E=>{Zx(E.currentTarget)&&E.preventDefault()},O=E=>{P(E)};$.onDragStart=E=>{E.currentTarget.contains(E.target)&&P(E)}}else{$.onMouseDown=M=>{if(M.button!==0||!M.currentTarget.contains(M.target))return;if(Lh(M.currentTarget)&&M.preventDefault(),w.ignoreEmulatedMouseEvents){M.stopPropagation();return}w.isPressed=!0,w.isOverTarget=!0,w.target=M.currentTarget,w.pointerType=Sh(M.nativeEvent)?"virtual":"mouse",!o&&!l&&sn(M.currentTarget),m(M,w.pointerType)&&M.stopPropagation(),b(lt(M.currentTarget),"mouseup",T,!1)},$.onMouseEnter=M=>{if(!M.currentTarget.contains(M.target))return;let O=!0;w.isPressed&&!w.ignoreEmulatedMouseEvents&&w.pointerType!=null&&(w.isOverTarget=!0,O=m(M,w.pointerType)),O&&M.stopPropagation()},$.onMouseLeave=M=>{if(!M.currentTarget.contains(M.target))return;let O=!0;w.isPressed&&!w.ignoreEmulatedMouseEvents&&w.pointerType!=null&&(w.isOverTarget=!1,O=y(M,w.pointerType,!1),C(M)),O&&M.stopPropagation()},$.onMouseUp=M=>{M.currentTarget.contains(M.target)&&!w.ignoreEmulatedMouseEvents&&M.button===0&&S(M,w.pointerType||"mouse")};let T=M=>{if(M.button===0){if(w.isPressed=!1,p(),w.ignoreEmulatedMouseEvents){w.ignoreEmulatedMouseEvents=!1;return}w.target&&Wr(M,w.target)&&w.pointerType!=null?y(En(w.target,M),w.pointerType):w.target&&w.isOverTarget&&w.pointerType!=null&&y(En(w.target,M),w.pointerType,!1),w.isOverTarget=!1}};$.onTouchStart=M=>{if(!M.currentTarget.contains(M.target))return;let O=C4(M.nativeEvent);if(!O)return;w.activePointerId=O.identifier,w.ignoreEmulatedMouseEvents=!0,w.isOverTarget=!0,w.isPressed=!0,w.target=M.currentTarget,w.pointerType="touch",!o&&!l&&sn(M.currentTarget),c||Eh(w.target),m(ci(w.target,M),w.pointerType)&&M.stopPropagation(),b(Rt(M.currentTarget),"scroll",N,!0)},$.onTouchMove=M=>{if(!M.currentTarget.contains(M.target))return;if(!w.isPressed){M.stopPropagation();return}let O=qx(M.nativeEvent,w.activePointerId),E=!0;O&&Wr(O,M.currentTarget)?!w.isOverTarget&&w.pointerType!=null&&(w.isOverTarget=!0,E=m(ci(w.target,M),w.pointerType)):w.isOverTarget&&w.pointerType!=null&&(w.isOverTarget=!1,E=y(ci(w.target,M),w.pointerType,!1),C(ci(w.target,M))),E&&M.stopPropagation()},$.onTouchEnd=M=>{if(!M.currentTarget.contains(M.target))return;if(!w.isPressed){M.stopPropagation();return}let O=qx(M.nativeEvent,w.activePointerId),E=!0;O&&Wr(O,M.currentTarget)&&w.pointerType!=null?(S(ci(w.target,M),w.pointerType),E=y(ci(w.target,M),w.pointerType)):w.isOverTarget&&w.pointerType!=null&&(E=y(ci(w.target,M),w.pointerType,!1)),E&&M.stopPropagation(),w.isPressed=!1,w.activePointerId=null,w.isOverTarget=!1,w.ignoreEmulatedMouseEvents=!0,w.target&&!c&&go(w.target),p()},$.onTouchCancel=M=>{M.currentTarget.contains(M.target)&&(M.stopPropagation(),w.isPressed&&P(ci(w.target,M)))};let N=M=>{w.isPressed&&M.target.contains(w.target)&&P({currentTarget:w.target,shiftKey:!1,ctrlKey:!1,metaKey:!1,altKey:!1})};$.onDragStart=M=>{M.currentTarget.contains(M.target)&&P(M)}}return $},[b,o,l,p,c,P,C,y,m,S]);return x.useEffect(()=>()=>{var w;c||go((w=v.current.target)!==null&&w!==void 0?w:void 0)},[c]),{isPressed:a||h,pressProps:se(f,L)}}function Mh(t){return t.tagName==="A"&&t.hasAttribute("href")}function Dh(t,e){const{key:n,code:i}=t,r=e,s=r.getAttribute("role");return(n==="Enter"||n===" "||n==="Spacebar"||i==="Space")&&!(r instanceof Rt(r).HTMLInputElement&&!e1(r,n)||r instanceof Rt(r).HTMLTextAreaElement||r.isContentEditable)&&!((s==="link"||!s&&Mh(r))&&n!=="Enter")}function C4(t){const{targetTouches:e}=t;return e.length>0?e[0]:null}function qx(t,e){const n=t.changedTouches;for(let i=0;ie.right||e.left>t.right||t.top>e.bottom||e.top>t.bottom)}function Wr(t,e){let n=e.getBoundingClientRect(),i=E4(t);return _4(n,i)}function Lh(t){return!(t instanceof HTMLElement)||!t.hasAttribute("draggable")}function Zx(t){return t instanceof HTMLInputElement?!1:t instanceof HTMLButtonElement?t.type!=="submit"&&t.type!=="reset":!Mh(t)}function Jx(t,e){return t instanceof HTMLInputElement?!e1(t,e):Zx(t)}const M4=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function e1(t,e){return t.type==="checkbox"||t.type==="radio"?e===" ":M4.has(t.type)}class D4{isDefaultPrevented(){return this.nativeEvent.defaultPrevented}preventDefault(){this.defaultPrevented=!0,this.nativeEvent.preventDefault()}stopPropagation(){this.nativeEvent.stopPropagation(),this.isPropagationStopped=()=>!0}isPropagationStopped(){return!1}persist(){}constructor(e,n){this.nativeEvent=n,this.target=n.target,this.currentTarget=n.currentTarget,this.relatedTarget=n.relatedTarget,this.bubbles=n.bubbles,this.cancelable=n.cancelable,this.defaultPrevented=n.defaultPrevented,this.eventPhase=n.eventPhase,this.isTrusted=n.isTrusted,this.timeStamp=n.timeStamp,this.type=e}}function t1(t){let e=x.useRef({isFocused:!1,observer:null});Yt(()=>{const i=e.current;return()=>{i.observer&&(i.observer.disconnect(),i.observer=null)}},[]);let n=Ie(i=>{t==null||t(i)});return x.useCallback(i=>{if(i.target instanceof HTMLButtonElement||i.target instanceof HTMLInputElement||i.target instanceof HTMLTextAreaElement||i.target instanceof HTMLSelectElement){e.current.isFocused=!0;let r=i.target,s=o=>{e.current.isFocused=!1,r.disabled&&n(new D4("blur",o)),e.current.observer&&(e.current.observer.disconnect(),e.current.observer=null)};r.addEventListener("focusout",s,{once:!0}),e.current.observer=new MutationObserver(()=>{if(e.current.isFocused&&r.disabled){var o;(o=e.current.observer)===null||o===void 0||o.disconnect();let a=r===document.activeElement?null:document.activeElement;r.dispatchEvent(new FocusEvent("blur",{relatedTarget:a})),r.dispatchEvent(new FocusEvent("focusout",{bubbles:!0,relatedTarget:a}))}}),e.current.observer.observe(r,{attributes:!0,attributeFilter:["disabled"]})}},[n])}function Ah(t){let{isDisabled:e,onFocus:n,onBlur:i,onFocusChange:r}=t;const s=x.useCallback(l=>{if(l.target===l.currentTarget)return i&&i(l),r&&r(!1),!0},[i,r]),o=t1(s),a=x.useCallback(l=>{const u=lt(l.target);l.target===l.currentTarget&&u.activeElement===l.target&&(n&&n(l),r&&r(!0),o(l))},[r,n,o]);return{focusProps:{onFocus:!e&&(n||r||i)?a:void 0,onBlur:!e&&(i||r)?s:void 0}}}let Ki=null,Rh=new Set,vo=new Map,Hi=!1,Fh=!1;const L4={Tab:!0,Escape:!0};function Hl(t,e){for(let n of Rh)n(t,e)}function A4(t){return!(t.metaKey||!zi()&&t.altKey||t.ctrlKey||t.key==="Control"||t.key==="Shift"||t.key==="Meta")}function Wl(t){Hi=!0,A4(t)&&(Ki="keyboard",Hl("keyboard",t))}function Ft(t){Ki="pointer",(t.type==="mousedown"||t.type==="pointerdown")&&(Hi=!0,Hl("pointer",t))}function n1(t){Sh(t)&&(Hi=!0,Ki="virtual")}function i1(t){t.target===window||t.target===document||(!Hi&&!Fh&&(Ki="virtual",Hl("virtual",t)),Hi=!1,Fh=!1)}function r1(){Hi=!1,Fh=!0}function Ih(t){if(typeof window=="undefined"||vo.get(Rt(t)))return;const e=Rt(t),n=lt(t);let i=e.HTMLElement.prototype.focus;e.HTMLElement.prototype.focus=function(){Hi=!0,i.apply(this,arguments)},n.addEventListener("keydown",Wl,!0),n.addEventListener("keyup",Wl,!0),n.addEventListener("click",n1,!0),e.addEventListener("focus",i1,!0),e.addEventListener("blur",r1,!1),typeof PointerEvent!="undefined"?(n.addEventListener("pointerdown",Ft,!0),n.addEventListener("pointermove",Ft,!0),n.addEventListener("pointerup",Ft,!0)):(n.addEventListener("mousedown",Ft,!0),n.addEventListener("mousemove",Ft,!0),n.addEventListener("mouseup",Ft,!0)),e.addEventListener("beforeunload",()=>{s1(t)},{once:!0}),vo.set(e,{focus:i})}const s1=(t,e)=>{const n=Rt(t),i=lt(t);e&&i.removeEventListener("DOMContentLoaded",e),vo.has(n)&&(n.HTMLElement.prototype.focus=vo.get(n).focus,i.removeEventListener("keydown",Wl,!0),i.removeEventListener("keyup",Wl,!0),i.removeEventListener("click",n1,!0),n.removeEventListener("focus",i1,!0),n.removeEventListener("blur",r1,!1),typeof PointerEvent!="undefined"?(i.removeEventListener("pointerdown",Ft,!0),i.removeEventListener("pointermove",Ft,!0),i.removeEventListener("pointerup",Ft,!0)):(i.removeEventListener("mousedown",Ft,!0),i.removeEventListener("mousemove",Ft,!0),i.removeEventListener("mouseup",Ft,!0)),vo.delete(n))};function R4(t){const e=lt(t);let n;return e.readyState!=="loading"?Ih(t):(n=()=>{Ih(t)},e.addEventListener("DOMContentLoaded",n)),()=>s1(t,n)}typeof document!="undefined"&&R4();function o1(){return Ki!=="pointer"}function Nh(){return Ki}function a1(t){Ki=t,Hl(t,null)}const F4=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function I4(t,e,n){var i;const r=typeof window!="undefined"?Rt(n==null?void 0:n.target).HTMLInputElement:HTMLInputElement,s=typeof window!="undefined"?Rt(n==null?void 0:n.target).HTMLTextAreaElement:HTMLTextAreaElement,o=typeof window!="undefined"?Rt(n==null?void 0:n.target).HTMLElement:HTMLElement,a=typeof window!="undefined"?Rt(n==null?void 0:n.target).KeyboardEvent:KeyboardEvent;return t=t||(n==null?void 0:n.target)instanceof r&&!F4.has(n==null||(i=n.target)===null||i===void 0?void 0:i.type)||(n==null?void 0:n.target)instanceof s||(n==null?void 0:n.target)instanceof o&&(n==null?void 0:n.target.isContentEditable),!(t&&e==="keyboard"&&n instanceof a&&!L4[n.key])}function N4(t,e,n){Ih(),x.useEffect(()=>{let i=(r,s)=>{I4(!!(n!=null&&n.isTextInput),r,s)&&t(o1())};return Rh.add(i),()=>{Rh.delete(i)}},e)}function Oh(t){let{isDisabled:e,onBlurWithin:n,onFocusWithin:i,onFocusWithinChange:r}=t,s=x.useRef({isFocusWithin:!1}),o=x.useCallback(u=>{s.current.isFocusWithin&&!u.currentTarget.contains(u.relatedTarget)&&(s.current.isFocusWithin=!1,n&&n(u),r&&r(!1))},[n,r,s]),a=t1(o),l=x.useCallback(u=>{!s.current.isFocusWithin&&document.activeElement===u.target&&(i&&i(u),r&&r(!0),s.current.isFocusWithin=!0,a(u))},[i,r,a]);return e?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:l,onBlur:o}}}let Ul=!1,Vh=0;function jh(){Ul=!0,setTimeout(()=>{Ul=!1},50)}function l1(t){t.pointerType==="touch"&&jh()}function O4(){if(typeof document!="undefined")return typeof PointerEvent!="undefined"?document.addEventListener("pointerup",l1):document.addEventListener("touchend",jh),Vh++,()=>{Vh--,!(Vh>0)&&(typeof PointerEvent!="undefined"?document.removeEventListener("pointerup",l1):document.removeEventListener("touchend",jh))}}function Ur(t){let{onHoverStart:e,onHoverChange:n,onHoverEnd:i,isDisabled:r}=t,[s,o]=x.useState(!1),a=x.useRef({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;x.useEffect(O4,[]);let{hoverProps:l,triggerHoverEnd:u}=x.useMemo(()=>{let c=(h,g)=>{if(a.pointerType=g,r||g==="touch"||a.isHovered||!h.currentTarget.contains(h.target))return;a.isHovered=!0;let v=h.currentTarget;a.target=v,e&&e({type:"hoverstart",target:v,pointerType:g}),n&&n(!0),o(!0)},d=(h,g)=>{if(a.pointerType="",a.target=null,g==="touch"||!a.isHovered)return;a.isHovered=!1;let v=h.currentTarget;i&&i({type:"hoverend",target:v,pointerType:g}),n&&n(!1),o(!1)},f={};return typeof PointerEvent!="undefined"?(f.onPointerEnter=h=>{Ul&&h.pointerType==="mouse"||c(h,h.pointerType)},f.onPointerLeave=h=>{!r&&h.currentTarget.contains(h.target)&&d(h,h.pointerType)}):(f.onTouchStart=()=>{a.ignoreEmulatedMouseEvents=!0},f.onMouseEnter=h=>{!a.ignoreEmulatedMouseEvents&&!Ul&&c(h,"mouse"),a.ignoreEmulatedMouseEvents=!1},f.onMouseLeave=h=>{!r&&h.currentTarget.contains(h.target)&&d(h,"mouse")}),{hoverProps:f,triggerHoverEnd:d}},[e,n,i,r,a]);return x.useEffect(()=>{r&&u({currentTarget:a.target},a.pointerType)},[r]),{hoverProps:l,isHovered:s}}function u1(t){if(!t)return;let e=!0;return n=>{let i=V(k({},n),{preventDefault(){n.preventDefault()},isDefaultPrevented(){return n.isDefaultPrevented()},stopPropagation(){console.error("stopPropagation is now the default behavior for events in React Spectrum. You can use continuePropagation() to revert this behavior.")},continuePropagation(){e=!1}});t(i),e&&n.stopPropagation()}}function c1(t){return{keyboardProps:t.isDisabled?{}:{onKeyDown:u1(t.onKeyDown),onKeyUp:u1(t.onKeyUp)}}}function d1(t){let{onMoveStart:e,onMove:n,onMoveEnd:i}=t,r=x.useRef({didMove:!1,lastPosition:null,id:null}),{addGlobalListener:s,removeGlobalListener:o}=zr(),a=Ie((c,d,f,h)=>{f===0&&h===0||(r.current.didMove||(r.current.didMove=!0,e==null||e({type:"movestart",pointerType:d,shiftKey:c.shiftKey,metaKey:c.metaKey,ctrlKey:c.ctrlKey,altKey:c.altKey})),n==null||n({type:"move",pointerType:d,deltaX:f,deltaY:h,shiftKey:c.shiftKey,metaKey:c.metaKey,ctrlKey:c.ctrlKey,altKey:c.altKey}))}),l=Ie((c,d)=>{go(),r.current.didMove&&(i==null||i({type:"moveend",pointerType:d,shiftKey:c.shiftKey,metaKey:c.metaKey,ctrlKey:c.ctrlKey,altKey:c.altKey}))});return{moveProps:x.useMemo(()=>{let c={},d=()=>{Eh(),r.current.didMove=!1};if(typeof PointerEvent=="undefined"){let h=p=>{if(p.button===0){var m,y,S,P;a(p,"mouse",p.pageX-((S=(m=r.current.lastPosition)===null||m===void 0?void 0:m.pageX)!==null&&S!==void 0?S:0),p.pageY-((P=(y=r.current.lastPosition)===null||y===void 0?void 0:y.pageY)!==null&&P!==void 0?P:0)),r.current.lastPosition={pageX:p.pageX,pageY:p.pageY}}},g=p=>{p.button===0&&(l(p,"mouse"),o(window,"mousemove",h,!1),o(window,"mouseup",g,!1))};c.onMouseDown=p=>{p.button===0&&(d(),p.stopPropagation(),p.preventDefault(),r.current.lastPosition={pageX:p.pageX,pageY:p.pageY},s(window,"mousemove",h,!1),s(window,"mouseup",g,!1))};let v=p=>{let m=[...p.changedTouches].findIndex(({identifier:L})=>L===r.current.id);if(m>=0){var y,S;let{pageX:L,pageY:_}=p.changedTouches[m];var P,C;a(p,"touch",L-((P=(y=r.current.lastPosition)===null||y===void 0?void 0:y.pageX)!==null&&P!==void 0?P:0),_-((C=(S=r.current.lastPosition)===null||S===void 0?void 0:S.pageY)!==null&&C!==void 0?C:0)),r.current.lastPosition={pageX:L,pageY:_}}},b=p=>{[...p.changedTouches].findIndex(({identifier:y})=>y===r.current.id)>=0&&(l(p,"touch"),r.current.id=null,o(window,"touchmove",v),o(window,"touchend",b),o(window,"touchcancel",b))};c.onTouchStart=p=>{if(p.changedTouches.length===0||r.current.id!=null)return;let{pageX:m,pageY:y,identifier:S}=p.changedTouches[0];d(),p.stopPropagation(),p.preventDefault(),r.current.lastPosition={pageX:m,pageY:y},r.current.id=S,s(window,"touchmove",v,!1),s(window,"touchend",b,!1),s(window,"touchcancel",b,!1)}}else{let h=v=>{if(v.pointerId===r.current.id){var b,p;let S=v.pointerType||"mouse";var m,y;a(v,S,v.pageX-((m=(b=r.current.lastPosition)===null||b===void 0?void 0:b.pageX)!==null&&m!==void 0?m:0),v.pageY-((y=(p=r.current.lastPosition)===null||p===void 0?void 0:p.pageY)!==null&&y!==void 0?y:0)),r.current.lastPosition={pageX:v.pageX,pageY:v.pageY}}},g=v=>{if(v.pointerId===r.current.id){let b=v.pointerType||"mouse";l(v,b),r.current.id=null,o(window,"pointermove",h,!1),o(window,"pointerup",g,!1),o(window,"pointercancel",g,!1)}};c.onPointerDown=v=>{v.button===0&&r.current.id==null&&(d(),v.stopPropagation(),v.preventDefault(),r.current.lastPosition={pageX:v.pageX,pageY:v.pageY},r.current.id=v.pointerId,s(window,"pointermove",h,!1),s(window,"pointerup",g,!1),s(window,"pointercancel",g,!1))}}let f=(h,g,v)=>{d(),a(h,"keyboard",g,v),l(h,"keyboard")};return c.onKeyDown=h=>{switch(h.key){case"Left":case"ArrowLeft":h.preventDefault(),h.stopPropagation(),f(h,-1,0);break;case"Right":case"ArrowRight":h.preventDefault(),h.stopPropagation(),f(h,1,0);break;case"Up":case"ArrowUp":h.preventDefault(),h.stopPropagation(),f(h,0,-1);break;case"Down":case"ArrowDown":h.preventDefault(),h.stopPropagation(),f(h,0,1);break}},c},[r,s,o,a,l])}}function V4(t,e){let{onScroll:n,isDisabled:i}=t,r=x.useCallback(s=>{s.ctrlKey||(s.preventDefault(),s.stopPropagation(),n&&n({deltaX:s.deltaX,deltaY:s.deltaY}))},[n]);wh(e,"wheel",i?void 0:r)}const j4=500;function z4(t){let{isDisabled:e,onLongPressStart:n,onLongPressEnd:i,onLongPress:r,threshold:s=j4,accessibilityDescription:o}=t;const a=x.useRef(void 0);let{addGlobalListener:l,removeGlobalListener:u}=zr(),{pressProps:c}=_h({isDisabled:e,onPressStart(f){if(f.continuePropagation(),(f.pointerType==="mouse"||f.pointerType==="touch")&&(n&&n(V(k({},f),{type:"longpressstart"})),a.current=setTimeout(()=>{f.target.dispatchEvent(new PointerEvent("pointercancel",{bubbles:!0})),r&&r(V(k({},f),{type:"longpress"})),a.current=void 0},s),f.pointerType==="touch")){let h=g=>{g.preventDefault()};l(f.target,"contextmenu",h,{once:!0}),l(window,"pointerup",()=>{setTimeout(()=>{u(f.target,"contextmenu",h)},30)},{once:!0})}},onPressEnd(f){a.current&&clearTimeout(a.current),i&&(f.pointerType==="mouse"||f.pointerType==="touch")&&i(V(k({},f),{type:"longpressend"}))}}),d=XD(r&&!e?o:void 0);return{longPressProps:se(c,d)}}function Yl(t){const e=lt(t);if(Nh()==="virtual"){let n=e.activeElement;Ix(()=>{e.activeElement===n&&t.isConnected&&sn(t)})}else sn(t)}function B4(t){const e=Rt(t);if(!(t instanceof e.HTMLElement)&&!(t instanceof e.SVGElement))return!1;let{display:n,visibility:i}=t.style,r=n!=="none"&&i!=="hidden"&&i!=="collapse";if(r){const{getComputedStyle:s}=t.ownerDocument.defaultView;let{display:o,visibility:a}=s(t);r=o!=="none"&&a!=="hidden"&&a!=="collapse"}return r}function K4(t,e){return!t.hasAttribute("hidden")&&!t.hasAttribute("data-react-aria-prevent-focus")&&(t.nodeName==="DETAILS"&&e&&e.nodeName!=="SUMMARY"?t.hasAttribute("open"):!0)}function f1(t,e){return t.nodeName!=="#comment"&&B4(t)&&K4(t,e)&&(!t.parentElement||f1(t.parentElement,t))}const zh=["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]"],H4=zh.join(":not([hidden]),")+",[tabindex]:not([disabled]):not([hidden])";zh.push('[tabindex]:not([tabindex="-1"]):not([disabled])');const W4=zh.join(':not([hidden]):not([tabindex="-1"]),');function h1(t,e){return!t||!e?!1:e.some(n=>n.contains(t))}function p1(t,e,n){let i=e!=null&&e.tabbable?W4:H4,r=lt(t).createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode(s){var o;return!(e==null||(o=e.from)===null||o===void 0)&&o.contains(s)?NodeFilter.FILTER_REJECT:s.matches(i)&&f1(s)&&(!n||h1(s,n))&&(!(e!=null&&e.accept)||e.accept(s))?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});return e!=null&&e.from&&(r.currentNode=e.from),r}class Bh{get size(){return this.fastMap.size}getTreeNode(e){return this.fastMap.get(e)}addTreeNode(e,n,i){let r=this.fastMap.get(n!=null?n:null);if(!r)return;let s=new m1({scopeRef:e});r.addChild(s),s.parent=r,this.fastMap.set(e,s),i&&(s.nodeToRestore=i)}addNode(e){this.fastMap.set(e.scopeRef,e)}removeTreeNode(e){if(e===null)return;let n=this.fastMap.get(e);if(!n)return;let i=n.parent;for(let s of this.traverse())s!==n&&n.nodeToRestore&&s.nodeToRestore&&n.scopeRef&&n.scopeRef.current&&h1(s.nodeToRestore,n.scopeRef.current)&&(s.nodeToRestore=n.nodeToRestore);let r=n.children;i&&(i.removeChild(n),r.size>0&&r.forEach(s=>i&&i.addChild(s))),this.fastMap.delete(n.scopeRef)}*traverse(e=this.root){if(e.scopeRef!=null&&(yield e),e.children.size>0)for(let n of e.children)yield*os(this.traverse(n))}clone(){var e;let n=new Bh;var i;for(let r of this.traverse())n.addTreeNode(r.scopeRef,(i=(e=r.parent)===null||e===void 0?void 0:e.scopeRef)!==null&&i!==void 0?i:null,r.nodeToRestore);return n}constructor(){this.fastMap=new Map,this.root=new m1({scopeRef:null}),this.fastMap.set(null,this.root)}}class m1{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}}new Bh;function Wi(t={}){let{autoFocus:e=!1,isTextInput:n,within:i}=t,r=x.useRef({isFocused:!1,isFocusVisible:e||o1()}),[s,o]=x.useState(!1),[a,l]=x.useState(()=>r.current.isFocused&&r.current.isFocusVisible),u=x.useCallback(()=>l(r.current.isFocused&&r.current.isFocusVisible),[]),c=x.useCallback(h=>{r.current.isFocused=h,o(h),u()},[u]);N4(h=>{r.current.isFocusVisible=h,u()},[],{isTextInput:n});let{focusProps:d}=Ah({isDisabled:i,onFocusChange:c}),{focusWithinProps:f}=Oh({isDisabled:!i,onFocusWithinChange:c});return{isFocused:s,isFocusVisible:a,focusProps:i?f:d}}let U4=W.createContext(null);function Y4(t){let e=x.useContext(U4)||{};Nx(e,t);let r=e,{ref:n}=r;return ee(r,["ref"])}function Kh(t,e){let{focusProps:n}=Ah(t),{keyboardProps:i}=c1(t),r=se(n,i),s=Y4(e),o=t.isDisabled?{}:s,a=x.useRef(t.autoFocus);return x.useEffect(()=>{a.current&&e.current&&Yl(e.current),a.current=!1},[e]),{focusableProps:se(V(k({},r),{tabIndex:t.excludeFromTabOrder&&!t.isDisabled?-1:void 0}),o)}}function G4(t,e){let n=e==null?void 0:e.isDisabled,[i,r]=x.useState(!1);return Yt(()=>{if(t!=null&&t.current&&!n){let s=()=>{if(t.current){let a=p1(t.current,{tabbable:!0});r(!!a.nextNode())}};s();let o=new MutationObserver(s);return o.observe(t.current,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["tabIndex","disabled"]}),()=>{o.disconnect()}}}),n?!1:i}function X4(t,e){let p=t,{elementType:n="a",onPress:i,onPressStart:r,onPressEnd:s,onClick:o,isDisabled:a}=p,l=ee(p,["elementType","onPress","onPressStart","onPressEnd","onClick","isDisabled"]),u={};n!=="a"&&(u={role:"link",tabIndex:a?void 0:0});let{focusableProps:c}=Kh(t,e),{pressProps:d,isPressed:f}=_h({onPress:i,onPressStart:r,onPressEnd:s,isDisabled:a,ref:e}),h=Gt(l,{labelable:!0}),g=se(c,d),v=Nl(),b=Rx(t);return{isPressed:f,linkProps:se(h,b,V(k(k({},g),u),{"aria-disabled":a||void 0,"aria-current":t["aria-current"],onClick:m=>{var y;(y=d.onClick)===null||y===void 0||y.call(d,m),o&&(o(m),console.warn("onClick is deprecated, please use onPress")),!v.isNative&&m.currentTarget instanceof HTMLAnchorElement&&m.currentTarget.href&&!m.isDefaultPrevented()&&KD(m.currentTarget,m)&&t.href&&(m.preventDefault(),v.open(m.currentTarget,m,t.href,t.routerOptions))}}))}}const Q4=new Set(["Arab","Syrc","Samr","Mand","Thaa","Mend","Nkoo","Adlm","Rohg","Hebr"]),q4=new Set(["ae","ar","arc","bcc","bqi","ckb","dv","fa","glk","he","ku","mzn","nqo","pnb","ps","sd","ug","ur","yi"]);function Z4(t){if(Intl.Locale){let n=new Intl.Locale(t).maximize(),i=typeof n.getTextInfo=="function"?n.getTextInfo():n.textInfo;if(i)return i.direction==="rtl";if(n.script)return Q4.has(n.script)}let e=t.split("-")[0];return q4.has(e)}const J4=Symbol.for("react-aria.i18n.locale");function g1(){let t=typeof window!="undefined"&&window[J4]||typeof navigator!="undefined"&&(navigator.language||navigator.userLanguage)||"en-US";try{Intl.DateTimeFormat.supportedLocalesOf([t])}catch(e){t="en-US"}return{locale:t,direction:Z4(t)?"rtl":"ltr"}}let Hh=g1(),yo=new Set;function v1(){Hh=g1();for(let t of yo)t(Hh)}function e5(){let t=fo(),[e,n]=x.useState(Hh);return x.useEffect(()=>(yo.size===0&&window.addEventListener("languagechange",v1),yo.add(n),()=>{yo.delete(n),yo.size===0&&window.removeEventListener("languagechange",v1)}),[]),t?{locale:"en-US",direction:"ltr"}:e}const t5=W.createContext(null);function Ui(){let t=e5();return x.useContext(t5)||t}const n5=Symbol.for("react-aria.i18n.locale"),i5=Symbol.for("react-aria.i18n.strings");let Yr;class Gl{getStringForLocale(e,n){let r=this.getStringsForLocale(n)[e];if(!r)throw new Error(`Could not find intl message ${e} in ${n} locale`);return r}getStringsForLocale(e){let n=this.strings[e];return n||(n=r5(e,this.strings,this.defaultLocale),this.strings[e]=n),n}static getGlobalDictionaryForPackage(e){if(typeof window=="undefined")return null;let n=window[n5];if(Yr===void 0){let r=window[i5];if(!r)return null;Yr={};for(let s in r)Yr[s]=new Gl({[n]:r[s]},n)}let i=Yr==null?void 0:Yr[e];if(!i)throw new Error(`Strings for package "${e}" were not included by LocalizedStringProvider. Please add it to the list passed to createLocalizedStringDictionary.`);return i}constructor(e,n="en-US"){this.strings=Object.fromEntries(Object.entries(e).filter(([,i])=>i)),this.defaultLocale=n}}function r5(t,e,n="en-US"){if(e[t])return e[t];let i=s5(t);if(e[i])return e[i];for(let r in e)if(r.startsWith(i+"-"))return e[r];return e[n]}function s5(t){return Intl.Locale?new Intl.Locale(t).language:t.split("-")[0]}const y1=new Map,b1=new Map;class o5{format(e,n){let i=this.strings.getStringForLocale(e,this.locale);return typeof i=="function"?i(n,this):i}plural(e,n,i="cardinal"){let r=n["="+e];if(r)return typeof r=="function"?r():r;let s=this.locale+":"+i,o=y1.get(s);o||(o=new Intl.PluralRules(this.locale,{type:i}),y1.set(s,o));let a=o.select(e);return r=n[a]||n.other,typeof r=="function"?r():r}number(e){let n=b1.get(this.locale);return n||(n=new Intl.NumberFormat(this.locale),b1.set(this.locale,n)),n.format(e)}select(e,n){let i=e[n]||e.other;return typeof i=="function"?i():i}constructor(e,n){this.locale=e,this.strings=n}}const x1=new WeakMap;function a5(t){let e=x1.get(t);return e||(e=new Gl(t),x1.set(t,e)),e}function l5(t,e){return e&&Gl.getGlobalDictionaryForPackage(e)||a5(t)}function w1(t,e){let{locale:n}=Ui(),i=l5(t,e);return x.useMemo(()=>new o5(n,i),[n,i])}let Wh=new Map,Uh=!1;try{Uh=new Intl.NumberFormat("de-DE",{signDisplay:"exceptZero"}).resolvedOptions().signDisplay==="exceptZero"}catch(t){}let Xl=!1;try{Xl=new Intl.NumberFormat("de-DE",{style:"unit",unit:"degree"}).resolvedOptions().style==="unit"}catch(t){}const S1={degree:{narrow:{default:"°","ja-JP":" 度","zh-TW":"度","sl-SI":" °"}}};class Ql{format(e){let n="";if(!Uh&&this.options.signDisplay!=null?n=c5(this.numberFormatter,this.options.signDisplay,e):n=this.numberFormatter.format(e),this.options.style==="unit"&&!Xl){var i;let{unit:r,unitDisplay:s="short",locale:o}=this.resolvedOptions();if(!r)return n;let a=(i=S1[r])===null||i===void 0?void 0:i[s];n+=a[o]||a.default}return n}formatToParts(e){return this.numberFormatter.formatToParts(e)}formatRange(e,n){if(typeof this.numberFormatter.formatRange=="function")return this.numberFormatter.formatRange(e,n);if(n= start date");return`${this.format(e)} – ${this.format(n)}`}formatRangeToParts(e,n){if(typeof this.numberFormatter.formatRangeToParts=="function")return this.numberFormatter.formatRangeToParts(e,n);if(n= start date");let i=this.numberFormatter.formatToParts(e),r=this.numberFormatter.formatToParts(n);return[...i.map(s=>V(k({},s),{source:"startRange"})),{type:"literal",value:" – ",source:"shared"},...r.map(s=>V(k({},s),{source:"endRange"}))]}resolvedOptions(){let e=this.numberFormatter.resolvedOptions();return!Uh&&this.options.signDisplay!=null&&(e=V(k({},e),{signDisplay:this.options.signDisplay})),!Xl&&this.options.style==="unit"&&(e=V(k({},e),{style:"unit",unit:this.options.unit,unitDisplay:this.options.unitDisplay})),e}constructor(e,n={}){this.numberFormatter=u5(e,n),this.options=n}}function u5(t,e={}){let{numberingSystem:n}=e;if(n&&t.includes("-nu-")&&(t.includes("-u-")||(t+="-u-"),t+=`-nu-${n}`),e.style==="unit"&&!Xl){var i;let{unit:o,unitDisplay:a="short"}=e;if(!o)throw new Error('unit option must be provided with style: "unit"');if(!(!((i=S1[o])===null||i===void 0)&&i[a]))throw new Error(`Unsupported unit ${o} with unitDisplay = ${a}`);e=V(k({},e),{style:"decimal"})}let r=t+(e?Object.entries(e).sort((o,a)=>o[0]0||Object.is(n,0):e==="exceptZero"&&(Object.is(n,-0)||Object.is(n,0)?n=Math.abs(n):i=n>0),i){let r=t.format(-n),s=t.format(n),o=r.replace(s,"").replace(/\u200e|\u061C/,"");return[...o].length!==1&&console.warn("@react-aria/i18n polyfill for NumberFormat signDisplay: Unsupported case"),r.replace(s,"!!!").replace(o,"+").replace("!!!",s)}else return t.format(n)}}const d5=new RegExp("^.*\\(.*\\).*$"),f5=["latn","arab","hanidec"];class P1{parse(e){return Yh(this.locale,this.options,e).parse(e)}isValidPartialNumber(e,n,i){return Yh(this.locale,this.options,e).isValidPartialNumber(e,n,i)}getNumberingSystem(e){return Yh(this.locale,this.options,e).options.numberingSystem}constructor(e,n={}){this.locale=e,this.options=n}}const $1=new Map;function Yh(t,e,n){let i=k1(t,e);if(!t.includes("-nu-")&&!i.isValidPartialNumber(n)){for(let r of f5)if(r!==i.options.numberingSystem){let s=k1(t+(t.includes("-u-")?"-nu-":"-u-nu-")+r,e);if(s.isValidPartialNumber(n))return s}}return i}function k1(t,e){let n=t+(e?Object.entries(e).sort((r,s)=>r[0]-1&&(n=`-${n}`)}let i=n?+n:NaN;if(isNaN(i))return NaN;if(this.options.style==="percent"){var r,s;let o=V(k({},this.options),{style:"decimal",minimumFractionDigits:Math.min(((r=this.options.minimumFractionDigits)!==null&&r!==void 0?r:0)+2,20),maximumFractionDigits:Math.min(((s=this.options.maximumFractionDigits)!==null&&s!==void 0?s:0)+2,20)});return new P1(this.locale,o).parse(new Ql(this.locale,o).format(i))}return this.options.currencySign==="accounting"&&d5.test(e)&&(i=-1*i),i}sanitize(e){return e=e.replace(this.symbols.literals,""),this.symbols.minusSign&&(e=e.replace("-",this.symbols.minusSign)),this.options.numberingSystem==="arab"&&(this.symbols.decimal&&(e=e.replace(",",this.symbols.decimal),e=e.replace("،",this.symbols.decimal)),this.symbols.group&&(e=ql(e,".",this.symbols.group))),this.options.locale==="fr-FR"&&(e=ql(e,"."," ")),e}isValidPartialNumber(e,n=-1/0,i=1/0){return e=this.sanitize(e),this.symbols.minusSign&&e.startsWith(this.symbols.minusSign)&&n<0?e=e.slice(this.symbols.minusSign.length):this.symbols.plusSign&&e.startsWith(this.symbols.plusSign)&&i>0&&(e=e.slice(this.symbols.plusSign.length)),this.symbols.group&&e.startsWith(this.symbols.group)||this.symbols.decimal&&e.indexOf(this.symbols.decimal)>-1&&this.options.maximumFractionDigits===0?!1:(this.symbols.group&&(e=ql(e,this.symbols.group,"")),e=e.replace(this.symbols.numeral,""),this.symbols.decimal&&(e=e.replace(this.symbols.decimal,"")),e.length===0)}constructor(e,n={}){this.locale=e,this.formatter=new Intl.NumberFormat(e,n),this.options=this.formatter.resolvedOptions(),this.symbols=m5(e,this.formatter,this.options,n);var i,r;this.options.style==="percent"&&(((i=this.options.minimumFractionDigits)!==null&&i!==void 0?i:0)>18||((r=this.options.maximumFractionDigits)!==null&&r!==void 0?r:0)>18)&&console.warn("NumberParser cannot handle percentages with greater than 18 decimal places, please reduce the number in your options.")}}const T1=new Set(["decimal","fraction","integer","minusSign","plusSign","group"]),p5=[0,4,2,1,11,20,3,7,100,21,.1,1.1];function m5(t,e,n,i){var r,s,o,a;let l=new Intl.NumberFormat(t,V(k({},n),{minimumSignificantDigits:1,maximumSignificantDigits:21})),u=l.formatToParts(-10000.111),c=l.formatToParts(10000.111),d=p5.map($=>l.formatToParts($));var f;let h=(f=(r=u.find($=>$.type==="minusSign"))===null||r===void 0?void 0:r.value)!==null&&f!==void 0?f:"-",g=(s=c.find($=>$.type==="plusSign"))===null||s===void 0?void 0:s.value;!g&&((i==null?void 0:i.signDisplay)==="exceptZero"||(i==null?void 0:i.signDisplay)==="always")&&(g="+");let b=(o=new Intl.NumberFormat(t,V(k({},n),{minimumFractionDigits:2,maximumFractionDigits:2})).formatToParts(.001).find($=>$.type==="decimal"))===null||o===void 0?void 0:o.value,p=(a=u.find($=>$.type==="group"))===null||a===void 0?void 0:a.value,m=u.filter($=>!T1.has($.type)).map($=>C1($.value)),y=d.flatMap($=>$.filter(F=>!T1.has(F.type)).map(F=>C1(F.value))),S=[...new Set([...m,...y])].sort(($,F)=>F.length-$.length),P=S.length===0?new RegExp("[\\p{White_Space}]","gu"):new RegExp(`${S.join("|")}|[\\p{White_Space}]`,"gu"),C=[...new Intl.NumberFormat(n.locale,{useGrouping:!1}).format(9876543210)].reverse(),L=new Map(C.map(($,F)=>[$,F])),_=new RegExp(`[${C.join("")}]`,"g");return{minusSign:h,plusSign:g,decimal:b,group:p,literals:P,numeral:_,index:$=>String(L.get($))}}function ql(t,e,n){return t.replaceAll?t.replaceAll(e,n):t.split(e).join(n)}function C1(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Gh(t={}){let{locale:e}=Ui();return x.useMemo(()=>new Ql(e,t),[e,t])}const E1=7e3;let It=null;function g5(t,e="assertive",n=E1){It?It.announce(t,e,n):(It=new y5,(typeof IS_REACT_ACT_ENVIRONMENT=="boolean"?IS_REACT_ACT_ENVIRONMENT:typeof jest!="undefined")?It.announce(t,e,n):setTimeout(()=>{It!=null&&It.isAttached()&&(It==null||It.announce(t,e,n))},100))}function v5(t){It&&It.clear(t)}class y5{isAttached(){var e;return(e=this.node)===null||e===void 0?void 0:e.isConnected}createLog(e){let n=document.createElement("div");return n.setAttribute("role","log"),n.setAttribute("aria-live",e),n.setAttribute("aria-relevant","additions"),n}destroy(){this.node&&(document.body.removeChild(this.node),this.node=null)}announce(e,n="assertive",i=E1){var r,s;if(!this.node)return;let o=document.createElement("div");typeof e=="object"?(o.setAttribute("role","img"),o.setAttribute("aria-labelledby",e["aria-labelledby"])):o.textContent=e,n==="assertive"?(r=this.assertiveLog)===null||r===void 0||r.appendChild(o):(s=this.politeLog)===null||s===void 0||s.appendChild(o),e!==""&&setTimeout(()=>{o.remove()},i)}clear(e){this.node&&((!e||e==="assertive")&&this.assertiveLog&&(this.assertiveLog.innerHTML=""),(!e||e==="polite")&&this.politeLog&&(this.politeLog.innerHTML=""))}constructor(){this.node=null,this.assertiveLog=null,this.politeLog=null,typeof document!="undefined"&&(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))}}function b5(t,e,n){let{validationBehavior:i,focus:r}=t;Yt(()=>{if(i==="native"&&(n!=null&&n.current)){let l=e.realtimeValidation.isInvalid?e.realtimeValidation.validationErrors.join(" ")||"Invalid value.":"";n.current.setCustomValidity(l),n.current.hasAttribute("title")||(n.current.title=""),e.realtimeValidation.isInvalid||e.updateValidation(w5(n.current))}});let s=Ie(()=>{e.resetValidation()}),o=Ie(l=>{var u;e.displayValidation.isInvalid||e.commitValidation();let c=n==null||(u=n.current)===null||u===void 0?void 0:u.form;if(!l.defaultPrevented&&n&&c&&S5(c)===n.current){var d;r?r():(d=n.current)===null||d===void 0||d.focus(),a1("keyboard")}l.preventDefault()}),a=Ie(()=>{e.commitValidation()});x.useEffect(()=>{let l=n==null?void 0:n.current;if(!l)return;let u=l.form;return l.addEventListener("invalid",o),l.addEventListener("change",a),u==null||u.addEventListener("reset",s),()=>{l.removeEventListener("invalid",o),l.removeEventListener("change",a),u==null||u.removeEventListener("reset",s)}},[n,o,a,s,i])}function x5(t){let e=t.validity;return{badInput:e.badInput,customError:e.customError,patternMismatch:e.patternMismatch,rangeOverflow:e.rangeOverflow,rangeUnderflow:e.rangeUnderflow,stepMismatch:e.stepMismatch,tooLong:e.tooLong,tooShort:e.tooShort,typeMismatch:e.typeMismatch,valueMissing:e.valueMissing,valid:e.valid}}function w5(t){return{isInvalid:!t.validity.valid,validationDetails:x5(t),validationErrors:t.validationMessage?[t.validationMessage]:[]}}function S5(t){for(let e=0;eL1(k5(o,r)),[o,r]);s!=null&&s.validationDetails.valid&&(s=null);let c=x.useContext(P5),d=x.useMemo(()=>i?Array.isArray(i)?i.flatMap($=>Qh(c[$])):Qh(c[i]):[],[c,i]),[f,h]=x.useState(c),[g,v]=x.useState(!1);c!==f&&(h(c),v(!1));let b=x.useMemo(()=>L1(g?[]:d),[g,d]),p=x.useRef(bo),[m,y]=x.useState(bo),S=x.useRef(bo),P=()=>{if(!C)return;L(!1);let $=u||s||p.current;qh($,S.current)||(S.current=$,y($))},[C,L]=x.useState(!1);return x.useEffect(P),{realtimeValidation:l||b||u||s||bo,displayValidation:a==="native"?l||b||m:l||b||u||s||m,updateValidation($){a==="aria"&&!qh(m,$)?y($):p.current=$},resetValidation(){let $=bo;qh($,S.current)||(S.current=$,y($)),a==="native"&&L(!1),v(!0)},commitValidation(){a==="native"&&L(!0),v(!0)}}}function Qh(t){return t?Array.isArray(t)?t:[t]:[]}function k5(t,e){if(typeof t=="function"){let n=t(e);if(n&&typeof n!="boolean")return Qh(n)}return[]}function L1(t){return t.length?{isInvalid:!0,validationErrors:t,validationDetails:M1}:null}function qh(t,e){return t===e?!0:t&&e&&t.isInvalid===e.isInvalid&&t.validationErrors.length===e.validationErrors.length&&t.validationErrors.every((n,i)=>n===e.validationErrors[i])&&Object.entries(t.validationDetails).every(([n,i])=>e.validationDetails[n]===i)}function Zh(t){let{id:e,label:n,"aria-labelledby":i,"aria-label":r,labelElementType:s="label"}=t;e=ui(e);let o=ui(),a={};n?(i=i?`${o} ${i}`:o,a={id:o,htmlFor:s==="label"?e:void 0}):!i&&!r&&console.warn("If you do not provide a visible label, you must specify an aria-label or aria-labelledby attribute for accessibility");let l=bh({id:e,"aria-label":r,"aria-labelledby":i});return{labelProps:a,fieldProps:l}}function T5(t){let{description:e,errorMessage:n,isInvalid:i,validationState:r}=t,{labelProps:s,fieldProps:o}=Zh(t),a=Mx([!!e,!!n,i,r]),l=Mx([!!e,!!n,i,r]);return o=se(o,{"aria-describedby":[a,l,t["aria-describedby"]].filter(Boolean).join(" ")||void 0}),{labelProps:s,fieldProps:o,descriptionProps:{id:a},errorMessageProps:{id:l}}}const C5=0,E5=100,_5=1;function M5(t){const{isDisabled:e=!1,minValue:n=C5,maxValue:i=E5,numberFormatter:r,step:s=_5,orientation:o="horizontal"}=t;let a=x.useMemo(()=>{let I=(i-n)/10;return I=ut(I,0,I+s,s),Math.max(I,s)},[s,i,n]),l=x.useCallback(I=>I==null?void 0:I.map((z,Q)=>{let K=Q===0?n:z[Q-1],J=Q===I.length-1?i:z[Q+1];return ut(z,K,J,s)}),[n,i,s]),u=x.useMemo(()=>l(R1(t.value)),[t.value]),c=x.useMemo(()=>{var I;return l((I=R1(t.defaultValue))!==null&&I!==void 0?I:[n])},[t.defaultValue,n]),d=F1(t.value,t.defaultValue,t.onChange),f=F1(t.value,t.defaultValue,t.onChangeEnd);const[h,g]=ho(u,c,d),[v,b]=x.useState(new Array(h.length).fill(!1)),p=x.useRef(new Array(h.length).fill(!0)),[m,y]=x.useState(void 0),S=x.useRef(h),P=x.useRef(v);let C=I=>{S.current=I,g(I)},L=I=>{P.current=I,b(I)};function _(I){return(I-n)/(i-n)}function w(I){return I===0?n:h[I-1]}function $(I){return I===h.length-1?i:h[I+1]}function F(I){return p.current[I]}function T(I,z){p.current[I]=z}function N(I,z){if(e||!F(I))return;const Q=w(I),K=$(I);z=ut(z,Q,K,s);let J=A1(S.current,I,z);C(J)}function M(I,z){if(e||!F(I))return;z&&(S.current=h);const Q=P.current[I];P.current=A1(P.current,I,z),L(P.current),f&&Q&&!P.current.some(Boolean)&&f(S.current)}function O(I){return r.format(I)}function E(I,z){N(I,R(z))}function A(I){return Math.round((I-n)/s)*s+n}function R(I){const z=I*(i-n)+n;return Br(A(z),n,i)}function j(I,z=1){let Q=Math.max(z,s);N(I,ut(h[I]+Q,n,i,s))}function H(I,z=1){let Q=Math.max(z,s);N(I,ut(h[I]-Q,n,i,s))}return{values:h,getThumbValue:I=>h[I],setThumbValue:N,setThumbPercent:E,isThumbDragging:I=>v[I],setThumbDragging:M,focusedThumb:m,setFocusedThumb:y,getThumbPercent:I=>_(h[I]),getValuePercent:_,getThumbValueLabel:I=>O(h[I]),getFormattedValue:O,getThumbMinValue:w,getThumbMaxValue:$,getPercentValue:R,isThumbEditable:F,setThumbEditable:T,incrementThumb:j,decrementThumb:H,step:s,pageSize:a,orientation:o,isDisabled:e}}function A1(t,e,n){return t[e]===n?t:[...t.slice(0,e),n,...t.slice(e+1)]}function R1(t){if(t!=null)return Array.isArray(t)?t:[t]}function F1(t,e,n){return i=>{typeof t=="number"||typeof e=="number"?n==null||n(i[0]):n==null||n(i)}}function D5(t){let{minValue:e,maxValue:n,step:i,formatOptions:r,value:s,defaultValue:o=NaN,onChange:a,locale:l,isDisabled:u,isReadOnly:c}=t;s===null&&(s=NaN),s!==void 0&&!isNaN(s)&&(i!==void 0&&!isNaN(i)?s=ut(s,e,n,i):s=Br(s,e,n)),isNaN(o)||(i!==void 0&&!isNaN(i)?o=ut(o,e,n,i):o=Br(o,e,n));let[d,f]=ho(s,isNaN(o)?NaN:o,a),[h,g]=x.useState(()=>isNaN(d)?"":new Ql(l,r).format(d)),v=x.useMemo(()=>new P1(l,r),[l,r]),b=x.useMemo(()=>v.getNumberingSystem(h),[v,h]),p=x.useMemo(()=>new Ql(l,V(k({},r),{numberingSystem:b})),[l,r,b]),m=x.useMemo(()=>p.resolvedOptions(),[p]),y=x.useCallback(z=>isNaN(z)||z===null?"":p.format(z),[p]),S=D1(V(k({},t),{value:d})),P=i!==void 0&&!isNaN(i)?i:1;m.style==="percent"&&(i===void 0||isNaN(i))&&(P=.01);let[C,L]=x.useState(d),[_,w]=x.useState(l),[$,F]=x.useState(r);(!Object.is(d,C)||l!==_||r!==$)&&(g(y(d)),L(d),w(l),F(r));let T=x.useMemo(()=>v.parse(h),[v,h]),N=()=>{if(!h.length){f(NaN),g(s===void 0?"":y(d));return}if(isNaN(T)){g(y(d));return}let z;i===void 0||isNaN(i)?z=Br(T,e,n):z=ut(T,e,n,i),z=v.parse(y(z)),f(z),g(y(s===void 0?z:d))},M=(z,Q=0)=>{let K=T;if(isNaN(K)){let J=isNaN(Q)?0:Q;return ut(J,e,n,P)}else{let J=ut(K,e,n,P);return z==="+"&&J>K||z==="-"&&J{let z=M("+",e);z===d&&g(y(z)),f(z),S.commitValidation()},E=()=>{let z=M("-",n);z===d&&g(y(z)),f(z),S.commitValidation()},A=()=>{n!=null&&(f(ut(n,e,n,P)),S.commitValidation())},R=()=>{e!=null&&(f(e),S.commitValidation())},j=x.useMemo(()=>!u&&!c&&(isNaN(T)||n===void 0||isNaN(n)||ut(T,e,n,P)>T||Jh("+",T,P)<=n),[u,c,e,n,P,T]),H=x.useMemo(()=>!u&&!c&&(isNaN(T)||e===void 0||isNaN(e)||ut(T,e,n,P)=e),[u,c,e,n,P,T]),I=z=>v.isValidPartialNumber(z,e,n);return V(k({},S),{validate:I,increment:O,incrementToMax:A,decrement:E,decrementToMin:R,canIncrement:j,canDecrement:H,minValue:e,maxValue:n,numberValue:T,setNumberValue:f,setInputValue:g,inputValue:h,commit:N})}function Jh(t,e,n){let i=t==="+"?e+n:e-n;if(e%1!==0||n%1!==0){const r=e.toString().split("."),s=n.toString().split("."),o=r[1]&&r[1].length||0,a=s[1]&&s[1].length||0,l=Math.pow(10,Math.max(o,a));e=Math.round(e*l),n=Math.round(n*l),i=t==="+"?e+n:e-n,i/=l}return i}const I1={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 L5(t={}){let{style:e,isFocusable:n}=t,[i,r]=x.useState(!1),{focusWithinProps:s}=Oh({isDisabled:!n,onFocusWithinChange:a=>r(a)}),o=x.useMemo(()=>i?e:e?k(k({},I1),e):I1,[i]);return{visuallyHiddenProps:V(k({},s),{style:o})}}function A5(t){let a=t,{children:e,elementType:n="div",isFocusable:i,style:r}=a,s=ee(a,["children","elementType","isFocusable","style"]),{visuallyHiddenProps:o}=L5(t);return W.createElement(n,se(s,o),e)}const ep=new WeakMap;function tp(t,e){let n=ep.get(t);if(!n)throw new Error("Unknown slider state");return`${n.id}-${e}`}function R5(t,e,n){let{labelProps:i,fieldProps:r}=Zh(t),s=t.orientation==="vertical";var o;ep.set(e,{id:(o=i.id)!==null&&o!==void 0?o:r.id,"aria-describedby":t["aria-describedby"],"aria-details":t["aria-details"]});let{direction:a}=Ui(),{addGlobalListener:l,removeGlobalListener:u}=zr();const c=x.useRef(null),d=a==="rtl",f=x.useRef(null),{moveProps:h}=d1({onMoveStart(){f.current=null},onMove({deltaX:p,deltaY:m}){let{height:y,width:S}=n.current.getBoundingClientRect(),P=s?y:S;f.current==null&&(f.current=e.getThumbPercent(c.current)*P);let C=s?m:p;if((s||d)&&(C=-C),f.current+=C,c.current!=null&&n.current){const L=Br(f.current/P,0,1);e.setThumbPercent(c.current,L)}},onMoveEnd(){c.current!=null&&(e.setThumbDragging(c.current,!1),c.current=null)}});let g=x.useRef(void 0),v=(p,m,y,S)=>{if(n.current&&!t.isDisabled&&e.values.every((P,C)=>!e.isThumbDragging(C))){let{height:P,width:C,top:L,left:_}=n.current.getBoundingClientRect(),w=s?P:C,N=((s?S:y)-(s?L:_))/w;(a==="rtl"||s)&&(N=1-N);let M=e.getPercentValue(N),O,E=e.values.findIndex(A=>M-A<0);if(E===0)O=E;else if(E===-1)O=e.values.length-1;else{let A=e.values[E-1],R=e.values[E];Math.abs(A-M)=0&&e.isThumbEditable(O)?(p.preventDefault(),c.current=O,e.setFocusedThumb(O),g.current=m,e.setThumbDragging(c.current,!0),e.setThumbValue(O,M),l(window,"mouseup",b,!1),l(window,"touchend",b,!1),l(window,"pointerup",b,!1)):c.current=null}},b=p=>{var m,y;((y=p.pointerId)!==null&&y!==void 0?y:(m=p.changedTouches)===null||m===void 0?void 0:m[0].identifier)===g.current&&(c.current!=null&&(e.setThumbDragging(c.current,!1),c.current=null),u(window,"mouseup",b,!1),u(window,"touchend",b,!1),u(window,"pointerup",b,!1))};return"htmlFor"in i&&i.htmlFor&&(delete i.htmlFor,i.onClick=()=>{var p;(p=document.getElementById(tp(e,0)))===null||p===void 0||p.focus(),a1("keyboard")}),{labelProps:i,groupProps:k({role:"group"},r),trackProps:se({onMouseDown(p){p.button!==0||p.altKey||p.ctrlKey||p.metaKey||v(p,void 0,p.clientX,p.clientY)},onPointerDown(p){p.pointerType==="mouse"&&(p.button!==0||p.altKey||p.ctrlKey||p.metaKey)||v(p,p.pointerId,p.clientX,p.clientY)},onTouchStart(p){v(p,p.changedTouches[0].identifier,p.changedTouches[0].clientX,p.changedTouches[0].clientY)},style:{position:"relative",touchAction:"none"}},h),outputProps:{htmlFor:e.values.map((p,m)=>tp(e,m)).join(" "),"aria-live":"off"}}}function F5(t,e){let{index:n=0,isRequired:i,validationState:r,isInvalid:s,trackRef:o,inputRef:a,orientation:l=e.orientation,name:u}=t,c=t.isDisabled||e.isDisabled,d=l==="vertical",{direction:f}=Ui(),{addGlobalListener:h,removeGlobalListener:g}=zr(),v=ep.get(e);var b;const{labelProps:p,fieldProps:m}=Zh(V(k({},t),{id:tp(e,n),"aria-labelledby":`${v.id} ${(b=t["aria-labelledby"])!==null&&b!==void 0?b:""}`.trim()})),y=e.values[n],S=x.useCallback(()=>{a.current&&sn(a.current)},[a]),P=e.focusedThumb===n;x.useEffect(()=>{P&&S()},[P,S]);let C=f==="rtl",L=x.useRef(null),{keyboardProps:_}=c1({onKeyDown(E){let{getThumbMaxValue:A,getThumbMinValue:R,decrementThumb:j,incrementThumb:H,setThumbValue:I,setThumbDragging:z,pageSize:Q}=e;if(!/^(PageUp|PageDown|Home|End)$/.test(E.key)){E.continuePropagation();return}switch(E.preventDefault(),z(n,!0),E.key){case"PageUp":H(n,Q);break;case"PageDown":j(n,Q);break;case"Home":I(n,R(n));break;case"End":I(n,A(n));break}z(n,!1)}}),{moveProps:w}=d1({onMoveStart(){L.current=null,e.setThumbDragging(n,!0)},onMove({deltaX:E,deltaY:A,pointerType:R,shiftKey:j}){const{getThumbPercent:H,setThumbPercent:I,decrementThumb:z,incrementThumb:Q,step:K,pageSize:J}=e;let{width:ce,height:$t}=o.current.getBoundingClientRect(),Iu=d?$t:ce;if(L.current==null&&(L.current=H(n)*Iu),R==="keyboard")E>0&&C||E<0&&!C||A>0?z(n,j?J:K):Q(n,j?J:K);else{let Nu=d?A:E;(d||C)&&(Nu=-Nu),L.current+=Nu,I(n,Br(L.current/Iu,0,1))}},onMoveEnd(){e.setThumbDragging(n,!1)}});e.setThumbEditable(n,!c);const{focusableProps:$}=Kh(se(t,{onFocus:()=>e.setFocusedThumb(n),onBlur:()=>e.setFocusedThumb(void 0)}),a);let F=x.useRef(void 0),T=E=>{S(),F.current=E,e.setThumbDragging(n,!0),h(window,"mouseup",N,!1),h(window,"touchend",N,!1),h(window,"pointerup",N,!1)},N=E=>{var A,R;((R=E.pointerId)!==null&&R!==void 0?R:(A=E.changedTouches)===null||A===void 0?void 0:A[0].identifier)===F.current&&(S(),e.setThumbDragging(n,!1),g(window,"mouseup",N,!1),g(window,"touchend",N,!1),g(window,"pointerup",N,!1))},M=e.getThumbPercent(n);(d||f==="rtl")&&(M=1-M);let O=c?{}:se(_,w,{onMouseDown:E=>{E.button!==0||E.altKey||E.ctrlKey||E.metaKey||T()},onPointerDown:E=>{E.button!==0||E.altKey||E.ctrlKey||E.metaKey||T(E.pointerId)},onTouchStart:E=>{T(E.changedTouches[0].identifier)}});return Ph(a,y,E=>{e.setThumbValue(n,E)}),{inputProps:se($,m,{type:"range",tabIndex:c?void 0:0,min:e.getThumbMinValue(n),max:e.getThumbMaxValue(n),step:e.step,value:y,name:u,disabled:c,"aria-orientation":l,"aria-valuetext":e.getThumbValueLabel(n),"aria-required":i||void 0,"aria-invalid":s||r==="invalid"||void 0,"aria-errormessage":t["aria-errormessage"],"aria-describedby":[v["aria-describedby"],t["aria-describedby"]].filter(Boolean).join(" "),"aria-details":[v["aria-details"],t["aria-details"]].filter(Boolean).join(" "),onChange:E=>{e.setThumbValue(n,parseFloat(E.target.value))}}),thumbProps:V(k({},O),{style:{position:"absolute",[d?"top":"left"]:`${M*100}%`,transform:"translate(-50%, -50%)",touchAction:"none"}}),labelProps:p,isDragging:e.isThumbDragging(n),isDisabled:c,isFocused:P}}function I5(t,e){let{inputElementType:n="input",isDisabled:i=!1,isRequired:r=!1,isReadOnly:s=!1,type:o="text",validationBehavior:a="aria"}=t,[l,u]=ho(t.value,t.defaultValue||"",t.onChange),{focusableProps:c}=Kh(t,e),d=D1(V(k({},t),{value:l})),{isInvalid:f,validationErrors:h,validationDetails:g}=d.displayValidation,{labelProps:v,fieldProps:b,descriptionProps:p,errorMessageProps:m}=T5(V(k({},t),{isInvalid:f,errorMessage:t.errorMessage||h})),y=Gt(t,{labelable:!0});const S={type:o,pattern:t.pattern};return Ph(e,l,u),b5(t,d,e),x.useEffect(()=>{if(e.current instanceof Rt(e.current).HTMLTextAreaElement){let P=e.current;Object.defineProperty(P,"defaultValue",{get:()=>P.value,set:()=>{},configurable:!0})}},[e]),{labelProps:v,inputProps:se(y,n==="input"?S:void 0,k(k({disabled:i,readOnly:s,required:r&&a==="native","aria-required":r&&a==="aria"||void 0,"aria-invalid":f||void 0,"aria-errormessage":t["aria-errormessage"],"aria-activedescendant":t["aria-activedescendant"],"aria-autocomplete":t["aria-autocomplete"],"aria-haspopup":t["aria-haspopup"],value:l,onChange:P=>u(P.target.value),autoComplete:t.autoComplete,autoCapitalize:t.autoCapitalize,maxLength:t.maxLength,minLength:t.minLength,name:t.name,placeholder:t.placeholder,inputMode:t.inputMode,onCopy:t.onCopy,onCut:t.onCut,onPaste:t.onPaste,onCompositionEnd:t.onCompositionEnd,onCompositionStart:t.onCompositionStart,onCompositionUpdate:t.onCompositionUpdate,onSelect:t.onSelect,onBeforeInput:t.onBeforeInput,onInput:t.onInput},c),b)),descriptionProps:p,errorMessageProps:m,isInvalid:f,validationErrors:h,validationDetails:g}}function N1(){return typeof window!="undefined"&&window.InputEvent&&typeof InputEvent.prototype.getTargetRanges=="function"}function N5(t,e,n){let i=Ie(f=>{let h=n.current,g;switch(f.inputType){case"historyUndo":case"historyRedo":return;case"insertLineBreak":return;case"deleteContent":case"deleteByCut":case"deleteByDrag":g=h.value.slice(0,h.selectionStart)+h.value.slice(h.selectionEnd);break;case"deleteContentForward":g=h.selectionEnd===h.selectionStart?h.value.slice(0,h.selectionStart)+h.value.slice(h.selectionEnd+1):h.value.slice(0,h.selectionStart)+h.value.slice(h.selectionEnd);break;case"deleteContentBackward":g=h.selectionEnd===h.selectionStart?h.value.slice(0,h.selectionStart-1)+h.value.slice(h.selectionStart):h.value.slice(0,h.selectionStart)+h.value.slice(h.selectionEnd);break;case"deleteSoftLineBackward":case"deleteHardLineBackward":g=h.value.slice(h.selectionStart);break;default:f.data!=null&&(g=h.value.slice(0,h.selectionStart)+f.data+h.value.slice(h.selectionEnd));break}(g==null||!e.validate(g))&&f.preventDefault()});x.useEffect(()=>{if(!N1())return;let f=n.current;return f.addEventListener("beforeinput",i,!1),()=>{f.removeEventListener("beforeinput",i,!1)}},[n,i]);let r=N1()?null:f=>{let h=f.target.value.slice(0,f.target.selectionStart)+f.data+f.target.value.slice(f.target.selectionEnd);e.validate(h)||f.preventDefault()},d=I5(t,n),{labelProps:s,inputProps:o,descriptionProps:a,errorMessageProps:l}=d,u=ee(d,["labelProps","inputProps","descriptionProps","errorMessageProps"]),c=x.useRef(null);return k({inputProps:se(o,{onBeforeInput:r,onCompositionStart(){let{value:f,selectionStart:h,selectionEnd:g}=n.current;c.current={value:f,selectionStart:h,selectionEnd:g}},onCompositionEnd(){if(!e.validate(n.current.value)){let{value:f,selectionStart:h,selectionEnd:g}=c.current;n.current.value=f,n.current.setSelectionRange(h,g),e.setInputValue(f)}}}),labelProps:s,descriptionProps:a,errorMessageProps:l},u)}var O1={};O1={Empty:"فارغ"};var V1={};V1={Empty:"Изпразни"};var j1={};j1={Empty:"Prázdné"};var z1={};z1={Empty:"Tom"};var B1={};B1={Empty:"Leer"};var K1={};K1={Empty:"Άδειο"};var H1={};H1={Empty:"Empty"};var W1={};W1={Empty:"Vacío"};var U1={};U1={Empty:"Tühjenda"};var Y1={};Y1={Empty:"Tyhjä"};var G1={};G1={Empty:"Vide"};var X1={};X1={Empty:"ריק"};var Q1={};Q1={Empty:"Prazno"};var q1={};q1={Empty:"Üres"};var Z1={};Z1={Empty:"Vuoto"};var J1={};J1={Empty:"空"};var ew={};ew={Empty:"비어 있음"};var tw={};tw={Empty:"Tuščias"};var nw={};nw={Empty:"Tukšs"};var iw={};iw={Empty:"Tom"};var rw={};rw={Empty:"Leeg"};var sw={};sw={Empty:"Pusty"};var ow={};ow={Empty:"Vazio"};var aw={};aw={Empty:"Vazio"};var lw={};lw={Empty:"Gol"};var uw={};uw={Empty:"Не заполнено"};var cw={};cw={Empty:"Prázdne"};var dw={};dw={Empty:"Prazen"};var fw={};fw={Empty:"Prazno"};var hw={};hw={Empty:"Tomt"};var pw={};pw={Empty:"Boş"};var mw={};mw={Empty:"Пусто"};var gw={};gw={Empty:"空"};var vw={};vw={Empty:"空白"};var yw={};yw={"ar-AE":O1,"bg-BG":V1,"cs-CZ":j1,"da-DK":z1,"de-DE":B1,"el-GR":K1,"en-US":H1,"es-ES":W1,"et-EE":U1,"fi-FI":Y1,"fr-FR":G1,"he-IL":X1,"hr-HR":Q1,"hu-HU":q1,"it-IT":Z1,"ja-JP":J1,"ko-KR":ew,"lt-LT":tw,"lv-LV":nw,"nb-NO":iw,"nl-NL":rw,"pl-PL":sw,"pt-BR":ow,"pt-PT":aw,"ro-RO":lw,"ru-RU":uw,"sk-SK":cw,"sl-SI":dw,"sr-SP":fw,"sv-SE":hw,"tr-TR":pw,"uk-UA":mw,"zh-CN":gw,"zh-TW":vw};function O5(t){return t&&t.__esModule?t.default:t}function V5(t){const e=x.useRef(void 0);let{value:n,textValue:i,minValue:r,maxValue:s,isDisabled:o,isReadOnly:a,isRequired:l,onIncrement:u,onIncrementPage:c,onDecrement:d,onDecrementPage:f,onDecrementToMin:h,onIncrementToMax:g}=t;const v=w1(O5(yw),"@react-aria/spinbutton"),b=()=>clearTimeout(e.current);x.useEffect(()=>()=>b(),[]);let p=F=>{if(!(F.ctrlKey||F.metaKey||F.shiftKey||F.altKey||a))switch(F.key){case"PageUp":if(c){F.preventDefault(),c==null||c();break}case"ArrowUp":case"Up":u&&(F.preventDefault(),u==null||u());break;case"PageDown":if(f){F.preventDefault(),f==null||f();break}case"ArrowDown":case"Down":d&&(F.preventDefault(),d==null||d());break;case"Home":h&&(F.preventDefault(),h==null||h());break;case"End":g&&(F.preventDefault(),g==null||g());break}},m=x.useRef(!1),y=()=>{m.current=!0},S=()=>{m.current=!1},P=i===""?v.format("Empty"):(i||`${n}`).replace("-","−");x.useEffect(()=>{m.current&&(v5("assertive"),g5(P,"assertive"))},[P]);const C=Ie(F=>{b(),u==null||u(),e.current=window.setTimeout(()=>{(s===void 0||isNaN(s)||n===void 0||isNaN(n)||n{b(),d==null||d(),e.current=window.setTimeout(()=>{(r===void 0||isNaN(r)||n===void 0||isNaN(n)||n>r)&&L(60)},F)});let _=F=>{F.preventDefault()},{addGlobalListener:w,removeAllGlobalListeners:$}=zr();return{spinButtonProps:{role:"spinbutton","aria-valuenow":n!==void 0&&!isNaN(n)?n:void 0,"aria-valuetext":P,"aria-valuemin":r,"aria-valuemax":s,"aria-disabled":o||void 0,"aria-readonly":a||void 0,"aria-required":l||void 0,onKeyDown:p,onFocus:y,onBlur:S},incrementButtonProps:{onPressStart:()=>{C(400),w(window,"contextmenu",_)},onPressEnd:()=>{b(),$()},onFocus:y,onBlur:S},decrementButtonProps:{onPressStart:()=>{L(400),w(window,"contextmenu",_)},onPressEnd:()=>{b(),$()},onFocus:y,onBlur:S}}}var bw={};bw={decrease:t=>`خفض ${t.fieldLabel}`,increase:t=>`زيادة ${t.fieldLabel}`,numberField:"حقل رقمي"};var xw={};xw={decrease:t=>`Намаляване ${t.fieldLabel}`,increase:t=>`Усилване ${t.fieldLabel}`,numberField:"Номер на полето"};var ww={};ww={decrease:t=>`Snížit ${t.fieldLabel}`,increase:t=>`Zvýšit ${t.fieldLabel}`,numberField:"Číselné pole"};var Sw={};Sw={decrease:t=>`Reducer ${t.fieldLabel}`,increase:t=>`Øg ${t.fieldLabel}`,numberField:"Talfelt"};var Pw={};Pw={decrease:t=>`${t.fieldLabel} verringern`,increase:t=>`${t.fieldLabel} erhöhen`,numberField:"Nummernfeld"};var $w={};$w={decrease:t=>`Μείωση ${t.fieldLabel}`,increase:t=>`Αύξηση ${t.fieldLabel}`,numberField:"Πεδίο αριθμού"};var kw={};kw={decrease:t=>`Decrease ${t.fieldLabel}`,increase:t=>`Increase ${t.fieldLabel}`,numberField:"Number field"};var Tw={};Tw={decrease:t=>`Reducir ${t.fieldLabel}`,increase:t=>`Aumentar ${t.fieldLabel}`,numberField:"Campo de número"};var Cw={};Cw={decrease:t=>`Vähenda ${t.fieldLabel}`,increase:t=>`Suurenda ${t.fieldLabel}`,numberField:"Numbri väli"};var Ew={};Ew={decrease:t=>`Vähennä ${t.fieldLabel}`,increase:t=>`Lisää ${t.fieldLabel}`,numberField:"Numerokenttä"};var _w={};_w={decrease:t=>`Diminuer ${t.fieldLabel}`,increase:t=>`Augmenter ${t.fieldLabel}`,numberField:"Champ de nombre"};var Mw={};Mw={decrease:t=>`הקטן ${t.fieldLabel}`,increase:t=>`הגדל ${t.fieldLabel}`,numberField:"שדה מספר"};var Dw={};Dw={decrease:t=>`Smanji ${t.fieldLabel}`,increase:t=>`Povećaj ${t.fieldLabel}`,numberField:"Polje broja"};var Lw={};Lw={decrease:t=>`${t.fieldLabel} csökkentése`,increase:t=>`${t.fieldLabel} növelése`,numberField:"Számmező"};var Aw={};Aw={decrease:t=>`Riduci ${t.fieldLabel}`,increase:t=>`Aumenta ${t.fieldLabel}`,numberField:"Campo numero"};var Rw={};Rw={decrease:t=>`${t.fieldLabel}を縮小`,increase:t=>`${t.fieldLabel}を拡大`,numberField:"数値フィールド"};var Fw={};Fw={decrease:t=>`${t.fieldLabel} 감소`,increase:t=>`${t.fieldLabel} 증가`,numberField:"번호 필드"};var Iw={};Iw={decrease:t=>`Sumažinti ${t.fieldLabel}`,increase:t=>`Padidinti ${t.fieldLabel}`,numberField:"Numerio laukas"};var Nw={};Nw={decrease:t=>`Samazināšana ${t.fieldLabel}`,increase:t=>`Palielināšana ${t.fieldLabel}`,numberField:"Skaitļu lauks"};var Ow={};Ow={decrease:t=>`Reduser ${t.fieldLabel}`,increase:t=>`Øk ${t.fieldLabel}`,numberField:"Tallfelt"};var Vw={};Vw={decrease:t=>`${t.fieldLabel} verlagen`,increase:t=>`${t.fieldLabel} verhogen`,numberField:"Getalveld"};var jw={};jw={decrease:t=>`Zmniejsz ${t.fieldLabel}`,increase:t=>`Zwiększ ${t.fieldLabel}`,numberField:"Pole numeru"};var zw={};zw={decrease:t=>`Diminuir ${t.fieldLabel}`,increase:t=>`Aumentar ${t.fieldLabel}`,numberField:"Campo de número"};var Bw={};Bw={decrease:t=>`Diminuir ${t.fieldLabel}`,increase:t=>`Aumentar ${t.fieldLabel}`,numberField:"Campo numérico"};var Kw={};Kw={decrease:t=>`Scădere ${t.fieldLabel}`,increase:t=>`Creștere ${t.fieldLabel}`,numberField:"Câmp numeric"};var Hw={};Hw={decrease:t=>`Уменьшение ${t.fieldLabel}`,increase:t=>`Увеличение ${t.fieldLabel}`,numberField:"Числовое поле"};var Ww={};Ww={decrease:t=>`Znížiť ${t.fieldLabel}`,increase:t=>`Zvýšiť ${t.fieldLabel}`,numberField:"Číselné pole"};var Uw={};Uw={decrease:t=>`Upadati ${t.fieldLabel}`,increase:t=>`Povečajte ${t.fieldLabel}`,numberField:"Številčno polje"};var Yw={};Yw={decrease:t=>`Smanji ${t.fieldLabel}`,increase:t=>`Povećaj ${t.fieldLabel}`,numberField:"Polje broja"};var Gw={};Gw={decrease:t=>`Minska ${t.fieldLabel}`,increase:t=>`Öka ${t.fieldLabel}`,numberField:"Nummerfält"};var Xw={};Xw={decrease:t=>`${t.fieldLabel} azalt`,increase:t=>`${t.fieldLabel} arttır`,numberField:"Sayı alanı"};var Qw={};Qw={decrease:t=>`Зменшити ${t.fieldLabel}`,increase:t=>`Збільшити ${t.fieldLabel}`,numberField:"Поле номера"};var qw={};qw={decrease:t=>`降低 ${t.fieldLabel}`,increase:t=>`提高 ${t.fieldLabel}`,numberField:"数字字段"};var Zw={};Zw={decrease:t=>`縮小 ${t.fieldLabel}`,increase:t=>`放大 ${t.fieldLabel}`,numberField:"數字欄位"};var Jw={};Jw={"ar-AE":bw,"bg-BG":xw,"cs-CZ":ww,"da-DK":Sw,"de-DE":Pw,"el-GR":$w,"en-US":kw,"es-ES":Tw,"et-EE":Cw,"fi-FI":Ew,"fr-FR":_w,"he-IL":Mw,"hr-HR":Dw,"hu-HU":Lw,"it-IT":Aw,"ja-JP":Rw,"ko-KR":Fw,"lt-LT":Iw,"lv-LV":Nw,"nb-NO":Ow,"nl-NL":Vw,"pl-PL":jw,"pt-BR":zw,"pt-PT":Bw,"ro-RO":Kw,"ru-RU":Hw,"sk-SK":Ww,"sl-SI":Uw,"sr-SP":Yw,"sv-SE":Gw,"tr-TR":Xw,"uk-UA":Qw,"zh-CN":qw,"zh-TW":Zw};function j5(t){return t&&t.__esModule?t.default:t}function z5(t,e,n){let G$=t,{id:i,decrementAriaLabel:r,incrementAriaLabel:s,isDisabled:o,isReadOnly:a,isRequired:l,minValue:u,maxValue:c,autoFocus:d,label:f,formatOptions:h,onBlur:g=()=>{},onFocus:v,onFocusChange:b,onKeyDown:p,onKeyUp:m,description:y,errorMessage:S,isWheelDisabled:P}=G$,C=ee(G$,["id","decrementAriaLabel","incrementAriaLabel","isDisabled","isReadOnly","isRequired","minValue","maxValue","autoFocus","label","formatOptions","onBlur","onFocus","onFocusChange","onKeyDown","onKeyUp","description","errorMessage","isWheelDisabled"]),{increment:L,incrementToMax:_,decrement:w,decrementToMin:$,numberValue:F,inputValue:T,commit:N,commitValidation:M}=e;const O=w1(j5(Jw),"@react-aria/numberfield");let E=ui(i),{focusProps:A}=Ah({onBlur(){N()}}),R=Gh(h),j=x.useMemo(()=>R.resolvedOptions(),[R]),H=Gh(V(k({},h),{currencySign:void 0})),I=x.useMemo(()=>isNaN(F)?"":H.format(F),[H,F]),{spinButtonProps:z,incrementButtonProps:Q,decrementButtonProps:K}=V5({isDisabled:o,isReadOnly:a,isRequired:l,maxValue:c,minValue:u,onIncrement:L,onIncrementToMax:_,onDecrement:w,onDecrementToMin:$,value:F,textValue:I}),[J,ce]=x.useState(!1),{focusWithinProps:$t}=Oh({isDisabled:o,onFocusWithinChange:ce}),Iu=x.useCallback(kt=>{Math.abs(kt.deltaY)<=Math.abs(kt.deltaX)||(kt.deltaY>0?L():kt.deltaY<0&&w())},[w,L]);V4({onScroll:Iu,isDisabled:P||o||a||!J},n);var tm;let V$=((tm=j.maximumFractionDigits)!==null&&tm!==void 0?tm:0)>0,j$=e.minValue===void 0||isNaN(e.minValue)||e.minValue<0,Go="numeric";Lx()?j$?Go="text":V$&&(Go="decimal"):vh()&&(j$?Go="numeric":V$&&(Go="decimal"));let GF=kt=>{e.validate(kt)&&e.setInputValue(kt)},XF=Gt(t),z$=x.useCallback(kt=>{kt.key==="Enter"?(N(),M()):kt.continuePropagation()},[N,M]),{isInvalid:B$,validationErrors:QF,validationDetails:qF}=e.displayValidation,{labelProps:K$,inputProps:ZF,descriptionProps:JF,errorMessageProps:e8}=N5(V(k(k({},C),XF),{name:void 0,label:f,autoFocus:d,isDisabled:o,isReadOnly:a,isRequired:l,validate:void 0,[Xh]:e,value:T,defaultValue:void 0,autoComplete:"off","aria-label":t["aria-label"]||void 0,"aria-labelledby":t["aria-labelledby"]||void 0,id:E,type:"text",inputMode:Go,onChange:GF,onBlur:g,onFocus:v,onFocusChange:b,onKeyDown:x.useMemo(()=>mh(z$,p),[z$,p]),onKeyUp:m,description:y,errorMessage:S}),e,n);Ph(n,e.numberValue,e.setNumberValue);let H$=se(z,A,ZF,{role:null,"aria-roledescription":Il()?null:O.format("numberField"),"aria-valuemax":null,"aria-valuemin":null,"aria-valuenow":null,"aria-valuetext":null,autoCorrect:"off",spellCheck:"false"});t.validationBehavior==="native"&&(H$["aria-required"]=void 0);let W$=kt=>{var im;document.activeElement!==n.current&&(kt.pointerType==="mouse"?(im=n.current)===null||im===void 0||im.focus():kt.target.focus())},nm=t["aria-label"]||(typeof t.label=="string"?t.label:""),nr;nm||(nr=t.label!=null?K$.id:t["aria-labelledby"]);let U$=ui(),Y$=ui(),t8=se(Q,{"aria-label":s||O.format("increase",{fieldLabel:nm}).trim(),id:nr&&!s?U$:null,"aria-labelledby":nr&&!s?`${U$} ${nr}`:null,"aria-controls":E,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!e.canIncrement,onPressStart:W$}),n8=se(K,{"aria-label":r||O.format("decrease",{fieldLabel:nm}).trim(),id:nr&&!r?Y$:null,"aria-labelledby":nr&&!r?`${Y$} ${nr}`:null,"aria-controls":E,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!e.canDecrement,onPressStart:W$});return{groupProps:V(k({},$t),{role:"group","aria-disabled":o,"aria-invalid":B$?"true":void 0}),labelProps:K$,inputProps:H$,incrementButtonProps:t8,decrementButtonProps:n8,errorMessageProps:e8,descriptionProps:JF,isInvalid:B$,validationErrors:QF,validationDetails:qF}}function np(t){return OD()?t.altKey:t.ctrlKey}function Gr(t){return zi()?t.metaKey:t.ctrlKey}const B5=1e3;function K5(t){let{keyboardDelegate:e,selectionManager:n,onTypeSelect:i}=t,r=x.useRef({search:"",timeout:null}).current,s=o=>{let a=H5(o.key);if(!a||o.ctrlKey||o.metaKey||!o.currentTarget.contains(o.target))return;a===" "&&r.search.trim().length>0&&(o.preventDefault(),"continuePropagation"in o||o.stopPropagation()),r.search+=a;let l=e.getKeyForSearch(r.search,n.focusedKey);l==null&&(l=e.getKeyForSearch(r.search)),l!=null&&(n.setFocusedKey(l),i&&i(l)),clearTimeout(r.timeout),r.timeout=setTimeout(()=>{r.search=""},B5)};return{typeSelectProps:{onKeyDownCapture:e.getKeyForSearch?s:null}}}function H5(t){return t.length===1||!/^[A-Z]/i.test(t)?t:""}function W5(t){let{selectionManager:e,keyboardDelegate:n,ref:i,autoFocus:r=!1,shouldFocusWrap:s=!1,disallowEmptySelection:o=!1,disallowSelectAll:a=!1,selectOnFocus:l=e.selectionBehavior==="replace",disallowTypeAhead:u=!1,shouldUseVirtualFocus:c,allowsTabNavigation:d=!1,isVirtualized:f,scrollRef:h=i,linkBehavior:g="action"}=t,{direction:v}=Ui(),b=Nl(),p=$=>{if($.altKey&&$.key==="Tab"&&$.preventDefault(),!i.current.contains($.target))return;const F=(K,J)=>{if(K!=null){if(e.isLink(K)&&g==="selection"&&l&&!np($)){cl.flushSync(()=>{e.setFocusedKey(K,J)});let ce=h.current.querySelector(`[data-key="${CSS.escape(K.toString())}"]`),$t=e.getItemProps(K);b.open(ce,$,$t.href,$t.routerOptions);return}if(e.setFocusedKey(K,J),e.isLink(K)&&g==="override")return;$.shiftKey&&e.selectionMode==="multiple"?e.extendSelection(K):l&&!np($)&&e.replaceSelection(K)}};switch($.key){case"ArrowDown":if(n.getKeyBelow){var T,N,M;let K=e.focusedKey!=null?(T=n.getKeyBelow)===null||T===void 0?void 0:T.call(n,e.focusedKey):(N=n.getFirstKey)===null||N===void 0?void 0:N.call(n);K==null&&s&&(K=(M=n.getFirstKey)===null||M===void 0?void 0:M.call(n,e.focusedKey)),K!=null&&($.preventDefault(),F(K))}break;case"ArrowUp":if(n.getKeyAbove){var O,E,A;let K=e.focusedKey!=null?(O=n.getKeyAbove)===null||O===void 0?void 0:O.call(n,e.focusedKey):(E=n.getLastKey)===null||E===void 0?void 0:E.call(n);K==null&&s&&(K=(A=n.getLastKey)===null||A===void 0?void 0:A.call(n,e.focusedKey)),K!=null&&($.preventDefault(),F(K))}break;case"ArrowLeft":if(n.getKeyLeftOf){var R,j,H;let K=(R=n.getKeyLeftOf)===null||R===void 0?void 0:R.call(n,e.focusedKey);K==null&&s&&(K=v==="rtl"?(j=n.getFirstKey)===null||j===void 0?void 0:j.call(n,e.focusedKey):(H=n.getLastKey)===null||H===void 0?void 0:H.call(n,e.focusedKey)),K!=null&&($.preventDefault(),F(K,v==="rtl"?"first":"last"))}break;case"ArrowRight":if(n.getKeyRightOf){var I,z,Q;let K=(I=n.getKeyRightOf)===null||I===void 0?void 0:I.call(n,e.focusedKey);K==null&&s&&(K=v==="rtl"?(z=n.getLastKey)===null||z===void 0?void 0:z.call(n,e.focusedKey):(Q=n.getFirstKey)===null||Q===void 0?void 0:Q.call(n,e.focusedKey)),K!=null&&($.preventDefault(),F(K,v==="rtl"?"last":"first"))}break;case"Home":if(n.getFirstKey){$.preventDefault();let K=n.getFirstKey(e.focusedKey,Gr($));e.setFocusedKey(K),Gr($)&&$.shiftKey&&e.selectionMode==="multiple"?e.extendSelection(K):l&&e.replaceSelection(K)}break;case"End":if(n.getLastKey){$.preventDefault();let K=n.getLastKey(e.focusedKey,Gr($));e.setFocusedKey(K),Gr($)&&$.shiftKey&&e.selectionMode==="multiple"?e.extendSelection(K):l&&e.replaceSelection(K)}break;case"PageDown":if(n.getKeyPageBelow){let K=n.getKeyPageBelow(e.focusedKey);K!=null&&($.preventDefault(),F(K))}break;case"PageUp":if(n.getKeyPageAbove){let K=n.getKeyPageAbove(e.focusedKey);K!=null&&($.preventDefault(),F(K))}break;case"a":Gr($)&&e.selectionMode==="multiple"&&a!==!0&&($.preventDefault(),e.selectAll());break;case"Escape":!o&&e.selectedKeys.size!==0&&($.stopPropagation(),$.preventDefault(),e.clearSelection());break;case"Tab":if(!d){if($.shiftKey)i.current.focus();else{let K=p1(i.current,{tabbable:!0}),J,ce;do ce=K.lastChild(),ce&&(J=ce);while(ce);J&&!J.contains(document.activeElement)&&sn(J)}break}}},m=x.useRef({top:0,left:0});wh(h,"scroll",f?null:()=>{m.current={top:h.current.scrollTop,left:h.current.scrollLeft}});let y=$=>{if(e.isFocused){$.currentTarget.contains($.target)||e.setFocused(!1);return}if($.currentTarget.contains($.target)){if(e.setFocused(!0),e.focusedKey==null){let N=O=>{O!=null&&(e.setFocusedKey(O),l&&e.replaceSelection(O))},M=$.relatedTarget;var F,T;M&&$.currentTarget.compareDocumentPosition(M)&Node.DOCUMENT_POSITION_FOLLOWING?N((F=e.lastSelectedKey)!==null&&F!==void 0?F:n.getLastKey()):N((T=e.firstSelectedKey)!==null&&T!==void 0?T:n.getFirstKey())}else f||(h.current.scrollTop=m.current.top,h.current.scrollLeft=m.current.left);if(e.focusedKey!=null){let N=h.current.querySelector(`[data-key="${CSS.escape(e.focusedKey.toString())}"]`);N&&(N.contains(document.activeElement)||sn(N),Nh()==="keyboard"&&jx(N,{containingElement:i.current}))}}},S=$=>{$.currentTarget.contains($.relatedTarget)||e.setFocused(!1)};const P=x.useRef(r);x.useEffect(()=>{if(P.current){let $=null;r==="first"&&($=n.getFirstKey()),r==="last"&&($=n.getLastKey());let F=e.selectedKeys;if(F.size){for(let T of F)if(e.canSelectItem(T)){$=T;break}}e.setFocused(!0),e.setFocusedKey($),$==null&&!c&&Yl(i.current)}},[]);let C=x.useRef(e.focusedKey);x.useEffect(()=>{if(e.isFocused&&e.focusedKey!=null&&(e.focusedKey!==C.current||P.current)&&(h!=null&&h.current)){let $=Nh(),F=i.current.querySelector(`[data-key="${CSS.escape(e.focusedKey.toString())}"]`);if(!F)return;($==="keyboard"||P.current)&&(Ox(h.current,F),$!=="virtual"&&jx(F,{containingElement:i.current}))}!c&&e.isFocused&&e.focusedKey==null&&C.current!=null&&Yl(i.current),C.current=e.focusedKey,P.current=!1}),wh(i,"react-aria-focus-scope-restore",$=>{$.preventDefault(),e.setFocused(!0)});let L={onKeyDown:p,onFocus:y,onBlur:S,onMouseDown($){h.current===$.target&&$.preventDefault()}},{typeSelectProps:_}=K5({keyboardDelegate:n,selectionManager:e});u||(L=se(_,L));let w;return c||(w=e.focusedKey==null?0:-1),{collectionProps:V(k({},L),{tabIndex:w})}}function U5(t){let{selectionManager:e,key:n,ref:i,shouldSelectOnPressUp:r,shouldUseVirtualFocus:s,focus:o,isDisabled:a,onAction:l,allowsDifferentPressOrigin:u,linkBehavior:c="action"}=t,d=Nl(),f=A=>{if(A.pointerType==="keyboard"&&np(A))e.toggleSelection(n);else{if(e.selectionMode==="none")return;if(e.isLink(n)){if(c==="selection"){let R=e.getItemProps(n);d.open(i.current,A,R.href,R.routerOptions),e.setSelectedKeys(e.selectedKeys);return}else if(c==="override"||c==="none")return}e.selectionMode==="single"?e.isSelected(n)&&!e.disallowEmptySelection?e.toggleSelection(n):e.replaceSelection(n):A&&A.shiftKey?e.extendSelection(n):e.selectionBehavior==="toggle"||A&&(Gr(A)||A.pointerType==="touch"||A.pointerType==="virtual")?e.toggleSelection(n):e.replaceSelection(n)}};x.useEffect(()=>{n===e.focusedKey&&e.isFocused&&!s&&(o?o():document.activeElement!==i.current&&Yl(i.current))},[i,n,e.focusedKey,e.childFocusStrategy,e.isFocused,s]),a=a||e.isDisabled(n);let h={};!s&&!a?h={tabIndex:n===e.focusedKey?0:-1,onFocus(A){A.target===i.current&&e.setFocusedKey(n)}}:a&&(h.onMouseDown=A=>{A.preventDefault()});let g=e.isLink(n)&&c==="override",v=e.isLink(n)&&c!=="selection"&&c!=="none",b=!a&&e.canSelectItem(n)&&!g,p=(l||v)&&!a,m=p&&(e.selectionBehavior==="replace"?!b:!b||e.isEmpty),y=p&&b&&e.selectionBehavior==="replace",S=m||y,P=x.useRef(null),C=S&&b,L=x.useRef(!1),_=x.useRef(!1),w=A=>{if(l&&l(),v){let R=e.getItemProps(n);d.open(i.current,A,R.href,R.routerOptions)}},$={};r?($.onPressStart=A=>{P.current=A.pointerType,L.current=C,A.pointerType==="keyboard"&&(!S||tS())&&f(A)},u?($.onPressUp=m?null:A=>{A.pointerType!=="keyboard"&&b&&f(A)},$.onPress=m?w:null):$.onPress=A=>{if(m||y&&A.pointerType!=="mouse"){if(A.pointerType==="keyboard"&&!eS())return;w(A)}else A.pointerType!=="keyboard"&&b&&f(A)}):($.onPressStart=A=>{P.current=A.pointerType,L.current=C,_.current=m,b&&(A.pointerType==="mouse"&&!m||A.pointerType==="keyboard"&&(!p||tS()))&&f(A)},$.onPress=A=>{(A.pointerType==="touch"||A.pointerType==="pen"||A.pointerType==="virtual"||A.pointerType==="keyboard"&&S&&eS()||A.pointerType==="mouse"&&_.current)&&(S?w(A):b&&f(A))}),h["data-key"]=n,$.preventFocusOnPress=s;let{pressProps:F,isPressed:T}=_h($),N=y?A=>{P.current==="mouse"&&(A.stopPropagation(),A.preventDefault(),w(A))}:void 0,{longPressProps:M}=z4({isDisabled:!C,onLongPress(A){A.pointerType==="touch"&&(f(A),e.setSelectionBehavior("toggle"))}}),O=A=>{P.current==="touch"&&L.current&&A.preventDefault()},E=e.isLink(n)?A=>{Bi.isOpening||A.preventDefault()}:void 0;return{itemProps:se(h,b||m?F:{},C?M:{},{onDoubleClick:N,onDragStartCapture:O,onClick:E}),isPressed:T,isSelected:e.isSelected(n),isFocused:e.isFocused&&e.focusedKey===n,isDisabled:a,allowsSelection:b,hasAction:S}}function eS(){let t=window.event;return(t==null?void 0:t.key)==="Enter"}function tS(){let t=window.event;return(t==null?void 0:t.key)===" "||(t==null?void 0:t.code)==="Space"}class Y5{build(e,n){return this.context=n,nS(()=>this.iterateCollection(e))}*iterateCollection(e){let{children:n,items:i}=e;if(W.isValidElement(n)&&n.type===W.Fragment)yield*os(this.iterateCollection({children:n.props.children,items:i}));else if(typeof n=="function"){if(!i)throw new Error("props.children was a function but props.items is missing");for(let r of e.items)yield*os(this.getFullNode({value:r},{renderer:n}))}else{let r=[];W.Children.forEach(n,o=>{r.push(o)});let s=0;for(let o of r){let a=this.getFullNode({element:o,index:s},{});for(let l of a)s++,yield l}}}getKey(e,n,i,r){if(e.key!=null)return e.key;if(n.type==="cell"&&n.key!=null)return`${r}${n.key}`;let s=n.value;if(s!=null){var o;let a=(o=s.key)!==null&&o!==void 0?o:s.id;if(a==null)throw new Error("No key found for item");return a}return r?`${r}.${n.index}`:`$.${n.index}`}getChildState(e,n){return{renderer:n.renderer||e.renderer}}*getFullNode(e,n,i,r){if(W.isValidElement(e.element)&&e.element.type===W.Fragment){let l=[];W.Children.forEach(e.element.props.children,c=>{l.push(c)});let u=e.index;for(const c of l)yield*os(this.getFullNode({element:c,index:u++},n,i,r));return}let s=e.element;if(!s&&e.value&&n&&n.renderer){let l=this.cache.get(e.value);if(l&&(!l.shouldInvalidate||!l.shouldInvalidate(this.context))){l.index=e.index,l.parentKey=r?r.key:null,yield l;return}s=n.renderer(e.value)}if(W.isValidElement(s)){let l=s.type;if(typeof l!="function"&&typeof l.getCollectionNode!="function"){let f=typeof s.type=="function"?s.type.name:s.type;throw new Error(`Unknown element <${f}> in collection.`)}let u=l.getCollectionNode(s.props,this.context),c=e.index,d=u.next();for(;!d.done&&d.value;){let f=d.value;e.index=c;let h=f.key;h||(h=f.element?null:this.getKey(s,e,n,i));let v=[...this.getFullNode(V(k({},f),{key:h,index:c,wrapper:G5(e.wrapper,f.wrapper)}),this.getChildState(n,f),i?`${i}${s.key}`:s.key,r)];for(let b of v){if(b.value=f.value||e.value,b.value&&this.cache.set(b.value,b),e.type&&b.type!==e.type)throw new Error(`Unsupported type <${ip(b.type)}> in <${ip(r.type)}>. Only <${ip(e.type)}> is supported.`);c++,yield b}d=u.next(v)}return}if(e.key==null)return;let o=this,a={type:e.type,props:e.props,key:e.key,parentKey:r?r.key:null,value:e.value,level:r?r.level+1:0,index:e.index,rendered:e.rendered,textValue:e.textValue,"aria-label":e["aria-label"],wrapper:e.wrapper,shouldInvalidate:e.shouldInvalidate,hasChildNodes:e.hasChildNodes,childNodes:nS(function*(){if(!e.hasChildNodes)return;let l=0;for(let u of e.childNodes()){u.key!=null&&(u.key=`${a.key}${u.key}`),u.index=l;let c=o.getFullNode(u,o.getChildState(n,u),a.key,a);for(let d of c)l++,yield d}})};yield a}constructor(){this.cache=new WeakMap}}function nS(t){let e=[],n=null;return{*[Symbol.iterator](){for(let i of e)yield i;n||(n=t());for(let i of n)e.push(i),yield i}}}function G5(t,e){if(t&&e)return n=>t(e(n));if(t)return t;if(e)return e}function ip(t){return t[0].toUpperCase()+t.slice(1)}function X5(t,e,n){let i=x.useMemo(()=>new Y5,[]),{children:r,items:s,collection:o}=t;return x.useMemo(()=>{if(o)return o;let l=i.build({children:r,items:s},n);return e(l)},[i,r,s,o,n,e])}function Q5(t,e){return typeof e.getChildren=="function"?e.getChildren(t.key):t.childNodes}function q5(t){return Z5(t)}function Z5(t,e){for(let n of t)return n}function rp(t,e,n){if(e.parentKey===n.parentKey)return e.index-n.index;let i=[...iS(t,e),e],r=[...iS(t,n),n],s=i.slice(0,r.length).findIndex((o,a)=>o!==r[a]);return s!==-1?(e=i[s],n=r[s],e.index-n.index):i.findIndex(o=>o===n)>=0?1:(r.findIndex(o=>o===e)>=0,-1)}function iS(t,e){let n=[];for(;(e==null?void 0:e.parentKey)!=null;)e=t.getItem(e.parentKey),n.unshift(e);return n}const rS=new WeakMap;function Zl(t,e,n){return t?(typeof e=="string"&&(e=e.replace(/\s+/g,"")),`${rS.get(t)}-${n}-${e}`):""}function J5(t,e,n){let{key:i,isDisabled:r,shouldSelectOnPressUp:s}=t,{selectionManager:o,selectedKey:a}=e,l=i===a,u=r||e.isDisabled||e.selectionManager.isDisabled(i),{itemProps:c,isPressed:d}=U5({selectionManager:o,key:i,ref:n,isDisabled:u,shouldSelectOnPressUp:s,linkBehavior:"selection"}),f=Zl(e,i,"tab"),h=Zl(e,i,"tabpanel"),{tabIndex:g}=c,v=e.collection.getItem(i),b=Gt(v==null?void 0:v.props,{labelable:!0});delete b.id;let p=Rx(v==null?void 0:v.props);return{tabProps:se(b,p,c,{id:f,"aria-selected":l,"aria-disabled":u||void 0,"aria-controls":l?h:void 0,tabIndex:u?void 0:g,role:"tab"}),isSelected:l,isDisabled:u,isPressed:d}}function e3(t,e,n){let i=G4(n)?void 0:0;var r;const s=Zl(e,(r=t.id)!==null&&r!==void 0?r:e==null?void 0:e.selectedKey,"tabpanel"),o=bh(V(k({},t),{id:s,"aria-labelledby":Zl(e,e==null?void 0:e.selectedKey,"tab")}));return{tabPanelProps:se(o,{tabIndex:i,role:"tabpanel","aria-describedby":t["aria-describedby"],"aria-details":t["aria-details"]})}}class t3{getKeyLeftOf(e){return this.flipDirection?this.getNextKey(e):this.getPreviousKey(e)}getKeyRightOf(e){return this.flipDirection?this.getPreviousKey(e):this.getNextKey(e)}isDisabled(e){var n,i;return this.disabledKeys.has(e)||!!(!((i=this.collection.getItem(e))===null||i===void 0||(n=i.props)===null||n===void 0)&&n.isDisabled)}getFirstKey(){let e=this.collection.getFirstKey();return e!=null&&this.isDisabled(e)&&(e=this.getNextKey(e)),e}getLastKey(){let e=this.collection.getLastKey();return e!=null&&this.isDisabled(e)&&(e=this.getPreviousKey(e)),e}getKeyAbove(e){return this.tabDirection?null:this.getPreviousKey(e)}getKeyBelow(e){return this.tabDirection?null:this.getNextKey(e)}getNextKey(e){do e=this.collection.getKeyAfter(e),e==null&&(e=this.collection.getFirstKey());while(this.isDisabled(e));return e}getPreviousKey(e){do e=this.collection.getKeyBefore(e),e==null&&(e=this.collection.getLastKey());while(this.isDisabled(e));return e}constructor(e,n,i,r=new Set){this.collection=e,this.flipDirection=n==="rtl"&&i==="horizontal",this.disabledKeys=r,this.tabDirection=i==="horizontal"}}function n3(t,e,n){let{orientation:i="horizontal",keyboardActivation:r="automatic"}=t,{collection:s,selectionManager:o,disabledKeys:a}=e,{direction:l}=Ui(),u=x.useMemo(()=>new t3(s,l,i,a),[s,a,i,l]),{collectionProps:c}=W5({ref:n,selectionManager:o,keyboardDelegate:u,selectOnFocus:r==="automatic",disallowEmptySelection:!0,scrollRef:n,linkBehavior:"selection"}),d=ui();rS.set(e,d);let f=bh(V(k({},t),{id:d}));return{tabListProps:V(k({},se(c,f)),{role:"tablist","aria-orientation":i,tabIndex:void 0})}}const i3=x.createContext(null);function r3(t,e){[t,e]=on(t,e,i3);let n=t.href&&!t.isDisabled?"a":"span",{linkProps:i,isPressed:r}=X4(V(k({},t),{elementType:n}),e),{hoverProps:s,isHovered:o}=Ur(t),{focusProps:a,isFocused:l,isFocusVisible:u}=Wi(),c=St(V(k({},t),{defaultClassName:"react-aria-Link",values:{isCurrent:!!t["aria-current"],isDisabled:t.isDisabled||!1,isPressed:r,isHovered:o,isFocused:l,isFocusVisible:u}}));return W.createElement(n,V(k({ref:e,slot:t.slot||void 0},se(c,i,s,a)),{"data-focused":l||void 0,"data-hovered":o||void 0,"data-pressed":r||void 0,"data-focus-visible":u||void 0,"data-current":!!t["aria-current"]||void 0,"data-disabled":t.isDisabled||void 0}),c.children)}const s3=x.forwardRef(r3),Jl=x.createContext({});function o3(t,e){[t,e]=on(t,e,Jl);let r=t,{elementType:n="label"}=r,i=ee(r,["elementType"]);return W.createElement(n,V(k({className:"react-aria-Label"},i),{ref:e}))}const sS=ph(o3),a3=x.createContext({}),oS=x.createContext({});function l3(t,e){[t,e]=on(t,e,oS);let r=t,{elementType:n="span"}=r,i=ee(r,["elementType"]);return W.createElement(n,V(k({className:"react-aria-Text"},i),{ref:e}))}const u3=x.forwardRef(l3);class aS{*[Symbol.iterator](){yield*os(this.iterable)}get size(){return this.keyMap.size}getKeys(){return this.keyMap.keys()}getKeyBefore(e){let n=this.keyMap.get(e);var i;return n&&(i=n.prevKey)!==null&&i!==void 0?i:null}getKeyAfter(e){let n=this.keyMap.get(e);var i;return n&&(i=n.nextKey)!==null&&i!==void 0?i:null}getFirstKey(){return this.firstKey}getLastKey(){return this.lastKey}getItem(e){var n;return(n=this.keyMap.get(e))!==null&&n!==void 0?n:null}at(e){const n=[...this.getKeys()];return this.getItem(n[e])}getChildren(e){let n=this.keyMap.get(e);return(n==null?void 0:n.childNodes)||[]}constructor(e){this.keyMap=new Map,this.firstKey=null,this.lastKey=null,this.iterable=e;let n=o=>{if(this.keyMap.set(o.key,o),o.childNodes&&o.type==="section")for(let a of o.childNodes)n(a)};for(let o of e)n(o);let i=null,r=0;for(let[o,a]of this.keyMap)i?(i.nextKey=o,a.prevKey=i.key):(this.firstKey=o,a.prevKey=void 0),a.type==="item"&&(a.index=r++),i=a,i.nextKey=void 0;var s;this.lastKey=(s=i==null?void 0:i.key)!==null&&s!==void 0?s:null}}class Xt extends Set{constructor(e,n,i){super(e),e instanceof Xt?(this.anchorKey=n!=null?n:e.anchorKey,this.currentKey=i!=null?i:e.currentKey):(this.anchorKey=n,this.currentKey=i)}}function c3(t,e){if(t.size!==e.size)return!1;for(let n of t)if(!e.has(n))return!1;return!0}function d3(t){let{selectionMode:e="none",disallowEmptySelection:n,allowDuplicateSelectionEvents:i,selectionBehavior:r="toggle",disabledBehavior:s="all"}=t,o=x.useRef(!1),[,a]=x.useState(!1),l=x.useRef(null),u=x.useRef(null),[,c]=x.useState(null),d=x.useMemo(()=>lS(t.selectedKeys),[t.selectedKeys]),f=x.useMemo(()=>lS(t.defaultSelectedKeys,new Xt),[t.defaultSelectedKeys]),[h,g]=ho(d,f,t.onSelectionChange),v=x.useMemo(()=>t.disabledKeys?new Set(t.disabledKeys):new Set,[t.disabledKeys]),[b,p]=x.useState(r);r==="replace"&&b==="toggle"&&typeof h=="object"&&h.size===0&&p("replace");let m=x.useRef(r);return x.useEffect(()=>{r!==m.current&&(p(r),m.current=r)},[r]),{selectionMode:e,disallowEmptySelection:n,selectionBehavior:b,setSelectionBehavior:p,get isFocused(){return o.current},setFocused(y){o.current=y,a(y)},get focusedKey(){return l.current},get childFocusStrategy(){return u.current},setFocusedKey(y,S="first"){l.current=y,u.current=S,c(y)},selectedKeys:h,setSelectedKeys(y){(i||!c3(y,h))&&g(y)},disabledKeys:v,disabledBehavior:s}}function lS(t,e){return t?t==="all"?"all":new Xt(t):e}class f3{get selectionMode(){return this.state.selectionMode}get disallowEmptySelection(){return this.state.disallowEmptySelection}get selectionBehavior(){return this.state.selectionBehavior}setSelectionBehavior(e){this.state.setSelectionBehavior(e)}get isFocused(){return this.state.isFocused}setFocused(e){this.state.setFocused(e)}get focusedKey(){return this.state.focusedKey}get childFocusStrategy(){return this.state.childFocusStrategy}setFocusedKey(e,n){(e==null||this.collection.getItem(e))&&this.state.setFocusedKey(e,n)}get selectedKeys(){return this.state.selectedKeys==="all"?new Set(this.getSelectAllKeys()):this.state.selectedKeys}get rawSelection(){return this.state.selectedKeys}isSelected(e){return this.state.selectionMode==="none"?!1:(e=this.getKey(e),this.state.selectedKeys==="all"?this.canSelectItem(e):this.state.selectedKeys.has(e))}get isEmpty(){return this.state.selectedKeys!=="all"&&this.state.selectedKeys.size===0}get isSelectAll(){if(this.isEmpty)return!1;if(this.state.selectedKeys==="all")return!0;if(this._isSelectAll!=null)return this._isSelectAll;let e=this.getSelectAllKeys(),n=this.state.selectedKeys;return this._isSelectAll=e.every(i=>n.has(i)),this._isSelectAll}get firstSelectedKey(){let e=null;for(let n of this.state.selectedKeys){let i=this.collection.getItem(n);(!e||i&&rp(this.collection,i,e)<0)&&(e=i)}return e==null?void 0:e.key}get lastSelectedKey(){let e=null;for(let n of this.state.selectedKeys){let i=this.collection.getItem(n);(!e||i&&rp(this.collection,i,e)>0)&&(e=i)}return e==null?void 0:e.key}get disabledKeys(){return this.state.disabledKeys}get disabledBehavior(){return this.state.disabledBehavior}extendSelection(e){if(this.selectionMode==="none")return;if(this.selectionMode==="single"){this.replaceSelection(e);return}e=this.getKey(e);let n;if(this.state.selectedKeys==="all")n=new Xt([e],e,e);else{let s=this.state.selectedKeys;var i;let o=(i=s.anchorKey)!==null&&i!==void 0?i:e;n=new Xt(s,o,e);var r;for(let a of this.getKeyRange(o,(r=s.currentKey)!==null&&r!==void 0?r:e))n.delete(a);for(let a of this.getKeyRange(e,o))this.canSelectItem(a)&&n.add(a)}this.state.setSelectedKeys(n)}getKeyRange(e,n){let i=this.collection.getItem(e),r=this.collection.getItem(n);return i&&r?rp(this.collection,i,r)<=0?this.getKeyRangeInternal(e,n):this.getKeyRangeInternal(n,e):[]}getKeyRangeInternal(e,n){var i;if(!((i=this.layoutDelegate)===null||i===void 0)&&i.getKeyRange)return this.layoutDelegate.getKeyRange(e,n);let r=[],s=e;for(;s!=null;){let o=this.collection.getItem(s);if((o&&o.type==="item"||o.type==="cell"&&this.allowsCellSelection)&&r.push(s),s===n)return r;s=this.collection.getKeyAfter(s)}return[]}getKey(e){let n=this.collection.getItem(e);if(!n||n.type==="cell"&&this.allowsCellSelection)return e;for(;n.type!=="item"&&n.parentKey!=null;)n=this.collection.getItem(n.parentKey);return!n||n.type!=="item"?null:n.key}toggleSelection(e){if(this.selectionMode==="none")return;if(this.selectionMode==="single"&&!this.isSelected(e)){this.replaceSelection(e);return}if(e=this.getKey(e),e==null)return;let n=new Xt(this.state.selectedKeys==="all"?this.getSelectAllKeys():this.state.selectedKeys);n.has(e)?n.delete(e):this.canSelectItem(e)&&(n.add(e),n.anchorKey=e,n.currentKey=e),!(this.disallowEmptySelection&&n.size===0)&&this.state.setSelectedKeys(n)}replaceSelection(e){if(this.selectionMode==="none"||(e=this.getKey(e),e==null))return;let n=this.canSelectItem(e)?new Xt([e],e,e):new Xt;this.state.setSelectedKeys(n)}setSelectedKeys(e){if(this.selectionMode==="none")return;let n=new Xt;for(let i of e)if(i=this.getKey(i),i!=null&&(n.add(i),this.selectionMode==="single"))break;this.state.setSelectedKeys(n)}getSelectAllKeys(){let e=[],n=i=>{for(;i!=null;){if(this.canSelectItem(i)){let r=this.collection.getItem(i);r.type==="item"&&e.push(i),r.hasChildNodes&&(this.allowsCellSelection||r.type!=="item")&&n(q5(Q5(r,this.collection)).key)}i=this.collection.getKeyAfter(i)}};return n(this.collection.getFirstKey()),e}selectAll(){!this.isSelectAll&&this.selectionMode==="multiple"&&this.state.setSelectedKeys("all")}clearSelection(){!this.disallowEmptySelection&&(this.state.selectedKeys==="all"||this.state.selectedKeys.size>0)&&this.state.setSelectedKeys(new Xt)}toggleSelectAll(){this.isSelectAll?this.clearSelection():this.selectAll()}select(e,n){this.selectionMode!=="none"&&(this.selectionMode==="single"?this.isSelected(e)&&!this.disallowEmptySelection?this.toggleSelection(e):this.replaceSelection(e):this.selectionBehavior==="toggle"||n&&(n.pointerType==="touch"||n.pointerType==="virtual")?this.toggleSelection(e):this.replaceSelection(e))}isSelectionEqual(e){if(e===this.state.selectedKeys)return!0;let n=this.selectedKeys;if(e.size!==n.size)return!1;for(let i of e)if(!n.has(i))return!1;for(let i of n)if(!e.has(i))return!1;return!0}canSelectItem(e){var n;if(this.state.selectionMode==="none"||this.state.disabledKeys.has(e))return!1;let i=this.collection.getItem(e);return!(!i||!(i==null||(n=i.props)===null||n===void 0)&&n.isDisabled||i.type==="cell"&&!this.allowsCellSelection)}isDisabled(e){var n,i;return this.state.disabledBehavior==="all"&&(this.state.disabledKeys.has(e)||!!(!((i=this.collection.getItem(e))===null||i===void 0||(n=i.props)===null||n===void 0)&&n.isDisabled))}isLink(e){var n,i;return!!(!((i=this.collection.getItem(e))===null||i===void 0||(n=i.props)===null||n===void 0)&&n.href)}getItemProps(e){var n;return(n=this.collection.getItem(e))===null||n===void 0?void 0:n.props}constructor(e,n,i){this.collection=e,this.state=n;var r;this.allowsCellSelection=(r=i==null?void 0:i.allowsCellSelection)!==null&&r!==void 0?r:!1,this._isSelectAll=null,this.layoutDelegate=(i==null?void 0:i.layoutDelegate)||null}}function h3(t){let{filter:e,layoutDelegate:n}=t,i=d3(t),r=x.useMemo(()=>t.disabledKeys?new Set(t.disabledKeys):new Set,[t.disabledKeys]),s=x.useCallback(c=>e?new aS(e(c)):new aS(c),[e]),o=x.useMemo(()=>({suppressTextValueWarning:t.suppressTextValueWarning}),[t.suppressTextValueWarning]),a=X5(t,s,o),l=x.useMemo(()=>new f3(a,i,{layoutDelegate:n}),[a,i,n]);const u=x.useRef(null);return x.useEffect(()=>{if(i.focusedKey!=null&&!a.getItem(i.focusedKey)&&u.current){const p=u.current.getItem(i.focusedKey),m=[...u.current.getKeys()].map(_=>{const w=u.current.getItem(_);return(w==null?void 0:w.type)==="item"?w:null}).filter(_=>_!==null),y=[...a.getKeys()].map(_=>{const w=a.getItem(_);return(w==null?void 0:w.type)==="item"?w:null}).filter(_=>_!==null);var c,d;const S=((c=m==null?void 0:m.length)!==null&&c!==void 0?c:0)-((d=y==null?void 0:y.length)!==null&&d!==void 0?d:0);var f,h,g;let P=Math.min(S>1?Math.max(((f=p==null?void 0:p.index)!==null&&f!==void 0?f:0)-S+1,0):(h=p==null?void 0:p.index)!==null&&h!==void 0?h:0,((g=y==null?void 0:y.length)!==null&&g!==void 0?g:0)-1),C=null,L=!1;for(;P>=0;){if(!l.isDisabled(y[P].key)){C=y[P];break}if(P((v=p==null?void 0:p.index)!==null&&v!==void 0?v:0)&&(P=(b=p==null?void 0:p.index)!==null&&b!==void 0?b:0),P--}}i.setFocusedKey(C?C.key:null)}u.current=a},[a,l,i,i.focusedKey]),{collection:a,disabledKeys:r,selectionManager:l}}function p3(t){var e;let[n,i]=ho(t.selectedKey,(e=t.defaultSelectedKey)!==null&&e!==void 0?e:null,t.onSelectionChange),r=x.useMemo(()=>n!=null?[n]:[],[n]),{collection:s,disabledKeys:o,selectionManager:a}=h3(V(k({},t),{selectionMode:"single",disallowEmptySelection:!0,allowDuplicateSelectionEvents:!0,selectedKeys:r,onSelectionChange:u=>{if(u==="all")return;var c;let d=(c=u.values().next().value)!==null&&c!==void 0?c:null;d===n&&t.onSelectionChange&&t.onSelectionChange(d),i(d)}})),l=n!=null?s.getItem(n):null;return{collection:s,disabledKeys:o,selectionManager:a,selectedKey:n,setSelectedKey:i,selectedItem:l}}function m3(t){var e;let n=p3(V(k({},t),{suppressTextValueWarning:!0,defaultSelectedKey:(e=t.defaultSelectedKey)!==null&&e!==void 0?e:uS(t.collection,t.disabledKeys?new Set(t.disabledKeys):new Set)})),{selectionManager:i,collection:r,selectedKey:s}=n,o=x.useRef(s);return x.useEffect(()=>{let a=s;(i.isEmpty||!r.getItem(a))&&(a=uS(r,n.disabledKeys),a!=null&&i.setSelectedKeys([a])),(a!=null&&i.focusedKey==null||!i.isFocused&&a!==o.current)&&i.setFocusedKey(a),o.current=a}),V(k({},n),{isDisabled:t.isDisabled||!1})}function uS(t,e){let n=null;if(t){var i,r,s,o;for(n=t.getFirstKey();(e.has(n)||!((r=t.getItem(n))===null||r===void 0||(i=r.props)===null||i===void 0)&&i.isDisabled)&&n!==t.getLastKey();)n=t.getKeyAfter(n);(e.has(n)||!((o=t.getItem(n))===null||o===void 0||(s=o.props)===null||s===void 0)&&s.isDisabled)&&n===t.getLastKey()&&(n=t.getFirstKey())}return n}const sp=x.createContext(null);function g3(t,e){let n=x.useContext(sp);return n!=null&&n.isInvalid?W.createElement(y3,V(k({},t),{ref:e})):null}const v3=x.forwardRef(g3),y3=x.forwardRef((t,e)=>{let n=x.useContext(sp),i=Gt(t),r=St(V(k({},t),{defaultClassName:"react-aria-FieldError",defaultChildren:n.validationErrors.length===0?void 0:n.validationErrors.join(" "),values:n}));return r.children==null?null:W.createElement(u3,V(k(k({slot:"errorMessage"},i),r),{ref:e}))}),b3=x.createContext(null),cS=x.createContext({});let x3=t=>{let s=t,{onHoverStart:e,onHoverChange:n,onHoverEnd:i}=s;return ee(s,["onHoverStart","onHoverChange","onHoverEnd"])};function w3(t,e){[t,e]=on(t,e,cS);let{hoverProps:n,isHovered:i}=Ur(t),{isFocused:r,isFocusVisible:s,focusProps:o}=Wi({isTextInput:!0,autoFocus:t.autoFocus}),a=!!t["aria-invalid"]&&t["aria-invalid"]!=="false",l=St(V(k({},t),{values:{isHovered:i,isFocused:r,isFocusVisible:s,isDisabled:t.disabled||!1,isInvalid:a},defaultClassName:"react-aria-Input"}));return W.createElement("input",V(k(k({},se(x3(t),o,n)),l),{ref:e,"data-focused":r||void 0,"data-disabled":t.disabled||void 0,"data-hovered":i||void 0,"data-focus-visible":s||void 0,"data-invalid":a||void 0}))}const S3=ph(w3),P3=x.createContext(null),eu=x.createContext(null),op=x.createContext(null),dS=x.createContext(null);function $3(t,e){[t,e]=on(t,e,P3);let n=x.useRef(null),i=Gh(t.formatOptions),r=M5(V(k({},t),{numberFormatter:i})),[s,o]=Th(),{groupProps:a,trackProps:l,labelProps:u,outputProps:c}=R5(V(k({},t),{label:o}),r,n),d=St(V(k({},t),{values:{orientation:r.orientation,isDisabled:r.isDisabled,state:r},defaultClassName:"react-aria-Slider"})),f=Gt(t);return delete f.id,W.createElement(mo,{values:[[eu,r],[op,V(k({},l),{ref:n})],[dS,c],[Jl,V(k({},u),{ref:s})]]},W.createElement("div",V(k(k(k({},f),a),d),{ref:e,slot:t.slot||void 0,"data-orientation":r.orientation,"data-disabled":r.isDisabled||void 0})))}const k3=x.forwardRef($3);function T3(t,e){[t,e]=on(t,e,dS);let l=t,{children:n,style:i,className:r}=l,s=ee(l,["children","style","className"]),o=x.useContext(eu),a=St({className:r,style:i,children:n,defaultChildren:o.getThumbValueLabel(0),defaultClassName:"react-aria-SliderOutput",values:{orientation:o.orientation,isDisabled:o.isDisabled,state:o}});return W.createElement("output",V(k(k({},s),a),{ref:e,"data-orientation":o.orientation||void 0,"data-disabled":o.isDisabled||void 0}))}const C3=x.forwardRef(T3);function E3(t,e){[t,e]=on(t,e,op);let n=x.useContext(eu),c=t,{onHoverStart:i,onHoverEnd:r,onHoverChange:s}=c,o=ee(c,["onHoverStart","onHoverEnd","onHoverChange"]),{hoverProps:a,isHovered:l}=Ur({onHoverStart:i,onHoverEnd:r,onHoverChange:s}),u=St(V(k({},t),{defaultClassName:"react-aria-SliderTrack",values:{orientation:n.orientation,isDisabled:n.isDisabled,isHovered:l,state:n}}));return W.createElement("div",V(k(k({},se(o,a)),u),{ref:e,"data-hovered":l||void 0,"data-orientation":n.orientation||void 0,"data-disabled":n.isDisabled||void 0}))}const _3=x.forwardRef(E3);function M3(t,e){let{inputRef:n=null}=t,i=x.useContext(eu),{ref:r}=jl(op),{index:s=0}=t,o=x.useRef(null),a=n||o,[l,u]=Th(),{thumbProps:c,inputProps:d,labelProps:f,isDragging:h,isFocused:g,isDisabled:v}=F5(V(k({},t),{index:s,trackRef:r,inputRef:a,label:u}),i),{focusProps:b,isFocusVisible:p}=Wi(),{hoverProps:m,isHovered:y}=Ur(t),S=St(V(k({},t),{defaultClassName:"react-aria-SliderThumb",values:{state:i,isHovered:y,isDragging:h,isFocused:g,isFocusVisible:p,isDisabled:v}})),P=Gt(t);return delete P.id,W.createElement("div",V(k(k({},se(P,c,m)),S),{ref:e,style:k(k({},c.style),S.style),"data-hovered":y||void 0,"data-dragging":h||void 0,"data-focused":g||void 0,"data-focus-visible":p||void 0,"data-disabled":v||void 0}),W.createElement(A5,null,W.createElement("input",k({ref:a},se(d,b)))),W.createElement(mo,{values:[[Jl,V(k({},f),{ref:l})]]},S.children))}const D3=x.forwardRef(M3),fS=x.createContext({});function L3(t,e){[t,e]=on(t,e,fS);let b=t,{isDisabled:n,isInvalid:i,onHoverStart:r,onHoverChange:s,onHoverEnd:o}=b,a=ee(b,["isDisabled","isInvalid","onHoverStart","onHoverChange","onHoverEnd"]),{hoverProps:l,isHovered:u}=Ur({onHoverStart:r,onHoverChange:s,onHoverEnd:o,isDisabled:n}),{isFocused:c,isFocusVisible:d,focusProps:f}=Wi({within:!0});n!=null||(n=!!t["aria-disabled"]&&t["aria-disabled"]!=="false"),i!=null||(i=!!t["aria-invalid"]&&t["aria-invalid"]!=="false");let h=St(V(k({},t),{values:{isHovered:u,isFocusWithin:c,isFocusVisible:d,isDisabled:n,isInvalid:i},defaultClassName:"react-aria-Group"}));var g,v;return W.createElement("div",V(k(k({},se(a,f,l)),h),{ref:e,role:(g=t.role)!==null&&g!==void 0?g:"group",slot:(v=t.slot)!==null&&v!==void 0?v:void 0,"data-focus-within":c||void 0,"data-hovered":u||void 0,"data-focus-visible":d||void 0,"data-disabled":n||void 0,"data-invalid":i||void 0}),h.children)}const A3=x.forwardRef(L3),R3=x.createContext(null),F3=x.createContext(null);function I3(t,e){[t,e]=on(t,e,R3);let{validationBehavior:n}=jl(b3)||{};var i,r;let s=(r=(i=t.validationBehavior)!==null&&i!==void 0?i:n)!==null&&r!==void 0?r:"native",{locale:o}=Ui(),a=D5(V(k({},t),{locale:o,validationBehavior:s})),l=x.useRef(null),[u,c]=Th(),P=z5(V(k({},x4(t)),{label:c,validationBehavior:s}),a,l),{labelProps:d,groupProps:f,inputProps:h,incrementButtonProps:g,decrementButtonProps:v,descriptionProps:b,errorMessageProps:p}=P,m=ee(P,["labelProps","groupProps","inputProps","incrementButtonProps","decrementButtonProps","descriptionProps","errorMessageProps"]),y=St(V(k({},t),{values:{state:a,isDisabled:t.isDisabled||!1,isInvalid:m.isInvalid||!1},defaultClassName:"react-aria-NumberField"})),S=Gt(t);return delete S.id,W.createElement(mo,{values:[[F3,a],[fS,f],[cS,V(k({},h),{ref:l})],[Jl,V(k({},d),{ref:u})],[a3,{slots:{increment:g,decrement:v}}],[oS,{slots:{description:b,errorMessage:p}}],[sp,m]]},W.createElement("div",V(k(k({},S),y),{ref:e,slot:t.slot||void 0,"data-disabled":t.isDisabled||void 0,"data-invalid":m.isInvalid||void 0})),t.name&&W.createElement("input",{type:"hidden",name:t.name,value:isNaN(a.numberValue)?"":a.numberValue}))}const N3=x.forwardRef(I3),tu=x.createContext(null),Xr=x.createContext(null);function O3(t,e){[t,e]=on(t,e,tu);let{children:n,orientation:i="horizontal"}=t;return n=x.useMemo(()=>typeof n=="function"?n({orientation:i,defaultChildren:null}):n,[n,i]),W.createElement(a4,{content:n},r=>W.createElement(V3,{props:t,collection:r,tabsRef:e}))}function V3({props:t,tabsRef:e,collection:n}){let{orientation:i="horizontal"}=t,r=m3(V(k({},t),{collection:n,children:void 0})),{focusProps:s,isFocused:o,isFocusVisible:a}=Wi({within:!0}),l=x.useMemo(()=>({orientation:i,isFocusWithin:o,isFocusVisible:a}),[i,o,a]),u=St(V(k({},t),{defaultClassName:"react-aria-Tabs",values:l}));return W.createElement("div",V(k(k(k({},Gt(t)),s),u),{ref:e,slot:t.slot||void 0,"data-focused":o||void 0,"data-orientation":i,"data-focus-visible":a||void 0,"data-disabled":r.isDisabled||void 0}),W.createElement(mo,{values:[[tu,t],[Xr,r]]},u.children))}const j3=x.forwardRef(O3);function z3(t,e){return x.useContext(Xr)?W.createElement(B3,{props:t,forwardedRef:e}):W.createElement(m4,t)}function B3({props:t,forwardedRef:e}){let n=x.useContext(Xr),{CollectionRoot:i}=x.useContext(y4),{orientation:r="horizontal",keyboardActivation:s="automatic"}=jl(tu),o=Ol(e),{tabListProps:a}=n3(V(k({},t),{orientation:r,keyboardActivation:s}),n,o),l=St(V(k({},t),{children:null,defaultClassName:"react-aria-TabList",values:{orientation:r,state:n}})),u=Gt(t);return delete u.id,W.createElement("div",V(k(V(k(k({},u),a),{ref:o}),l),{"data-orientation":r||void 0}),W.createElement(i,{collection:n.collection,persistedKeys:b4(n.selectionManager.focusedKey)}))}const K3=x.forwardRef(z3),H3=h4("item",(t,e,n)=>{let i=x.useContext(Xr),r=Ol(e),{tabProps:s,isSelected:o,isDisabled:a,isPressed:l}=J5(k({key:n.key},t),i,r),{focusProps:u,isFocused:c,isFocusVisible:d}=Wi(),{hoverProps:f,isHovered:h}=Ur({isDisabled:a,onHoverStart:t.onHoverStart,onHoverEnd:t.onHoverEnd,onHoverChange:t.onHoverChange}),g=St(V(k({},t),{id:void 0,defaultClassName:"react-aria-Tab",values:{isSelected:o,isDisabled:a,isFocused:c,isFocusVisible:d,isPressed:l,isHovered:h}})),v=n.props.href?"a":"div";return W.createElement(v,V(k({},se(s,u,f,g)),{ref:r,"data-selected":o||void 0,"data-disabled":a||void 0,"data-focused":c||void 0,"data-focus-visible":d||void 0,"data-pressed":l||void 0,"data-hovered":h||void 0}))});function W3(t,e){const n=x.useContext(Xr);let i=Ol(e),{tabPanelProps:r}=e3(t,n,i),{focusProps:s,isFocused:o,isFocusVisible:a}=Wi(),l=n.selectedKey===t.id,u=St(V(k({},t),{defaultClassName:"react-aria-TabPanel",values:{isFocused:o,isFocusVisible:a,isInert:!l,state:n}}));if(!l&&!t.shouldForceMount)return null;let c=Gt(t);delete c.id;let d=l?se(c,r,s,u):u;return W.createElement("div",V(k({},d),{ref:i,"data-focused":o||void 0,"data-focus-visible":a||void 0,inert:l?void 0:"true","data-inert":l?void 0:"true"}),W.createElement(mo,{values:[[tu,null],[Xr,null]]},u.children))}const U3=ph(W3);function ap(s){var o=s,{label:t,description:e,errorMessage:n,info:i}=o,r=ee(o,["label","description","errorMessage","info"]);return D.jsx(N3,V(k({},r),{children:D.jsxs("div",{className:"flex flex-col gap-2",children:[D.jsx(sS,{className:"font-sans text-sm font-bold leading-tight text-neutral-700",children:t}),D.jsx(A3,{children:D.jsx(S3,{id:t,className:"w-full rounded border border-[#747474] p-2 text-lg focus:outline-none focus:ring-2 focus:ring-blue-500"})}),D.jsx(v3,{className:"font-sans text-sm leading-tight text-red-600",children:n})]})}))}function Y3({label:t,info:e,value:n,onChange:i,maxValue:r,prefix:s,suffix:o,step:a}){return D.jsx("div",{className:"flex justify-center",children:D.jsxs(k3,{value:n,onChange:l=>i(l),className:"w-full",maxValue:r!=null?r:100,step:a!=null?a:1,children:[D.jsx("div",{className:"flex font-sans text-sm font-bold leading-tight text-neutral-700",children:D.jsx(sS,{className:"flex-1",children:t})}),D.jsxs("div",{className:"mt-6 flex gap-4",children:[D.jsx(_3,{className:"relative flex h-7 w-full",children:({state:l})=>D.jsxs(D.Fragment,{children:[D.jsx("div",{className:"slider-track absolute top-[50%] h-1 w-full translate-y-[-50%] rounded-full bg-[#929292]"}),D.jsx("div",{className:"text-right font-sans text-sm font-bold leading-tight text-[#5867E8]",style:{position:"absolute",left:l.getThumbPercent(0)*100+"%",bottom:"20px",transform:"translate(-50%, -50%)",touchAction:"none"},children:D.jsx(C3,{})}),D.jsx("div",{className:"absolute top-[50%] h-1 translate-y-[-50%] rounded-full bg-[#5867E8]",style:{width:l.getThumbPercent(0)*100+"%"}}),D.jsx(D3,{className:"top-[50%] h-7 w-7 cursor-grab rounded-full border border-2 border-solid border-[#5867E8] bg-white shadow-lg outline-none ring-blue-600 transition active:cursor-grabbing focus-visible:ring-2 dragging:bg-gray-200"})]})}),D.jsx("div",{className:"font-sans text-lg font-normal leading-7 tracking-tight text-neutral-900",children:"%"})]})]})})}function G3({children:t}){return D.jsx("div",{className:"flex w-full justify-center border-b",children:D.jsx(j3,{className:"w-full",children:t})})}function X3({children:t}){return D.jsx("div",{className:"flex justify-start border-b",children:D.jsx(K3,{"aria-label":"Results",className:"flex space-x-1",children:t})})}function hS(t){return D.jsx(H3,V(k({},t),{className:({isSelected:e})=>`w-full cursor-pointer rounded-tl-lg rounded-tr-lg bg-white px-6 py-2 text-center font-display outline-none ring-[#0176D3] transition-colors focus-visible:ring-2 ${e?"border-b-4 border-[#0176D3] bg-white text-[#0176D3]":""} `}))}function pS(t){return D.jsx(U3,V(k({},t),{className:"mt-8 w-full rounded-2xl bg-white p-0 ring-[#0176D3] focus-visible:ring-2"}))}/*! * @kurkle/color v0.3.2 * https://github.com/kurkle/color#readme * (c) 2023 Jukka Kurkela * Released under the MIT License */function xo(t){return t+.5|0}const di=(t,e,n)=>Math.max(Math.min(t,n),e);function wo(t){return di(xo(t*2.55),0,255)}function fi(t){return di(xo(t*255),0,255)}function _n(t){return di(xo(t/2.55)/100,0,1)}function mS(t){return di(xo(t*100),0,100)}const Nt={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},lp=[..."0123456789ABCDEF"],Q3=t=>lp[t&15],q3=t=>lp[(t&240)>>4]+lp[t&15],nu=t=>(t&240)>>4===(t&15),Z3=t=>nu(t.r)&&nu(t.g)&&nu(t.b)&&nu(t.a);function J3(t){var e=t.length,n;return t[0]==="#"&&(e===4||e===5?n={r:255&Nt[t[1]]*17,g:255&Nt[t[2]]*17,b:255&Nt[t[3]]*17,a:e===5?Nt[t[4]]*17:255}:(e===7||e===9)&&(n={r:Nt[t[1]]<<4|Nt[t[2]],g:Nt[t[3]]<<4|Nt[t[4]],b:Nt[t[5]]<<4|Nt[t[6]],a:e===9?Nt[t[7]]<<4|Nt[t[8]]:255})),n}const eL=(t,e)=>t<255?e(t):"";function tL(t){var e=Z3(t)?Q3:q3;return t?"#"+e(t.r)+e(t.g)+e(t.b)+eL(t.a,e):void 0}const nL=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function gS(t,e,n){const i=e*Math.min(n,1-n),r=(s,o=(s+t/30)%12)=>n-i*Math.max(Math.min(o-3,9-o,1),-1);return[r(0),r(8),r(4)]}function iL(t,e,n){const i=(r,s=(r+t/60)%6)=>n-n*e*Math.max(Math.min(s,4-s,1),0);return[i(5),i(3),i(1)]}function rL(t,e,n){const i=gS(t,1,.5);let r;for(e+n>1&&(r=1/(e+n),e*=r,n*=r),r=0;r<3;r++)i[r]*=1-e-n,i[r]+=e;return i}function sL(t,e,n,i,r){return t===r?(e-n)/i+(e.5?c/(2-s-o):c/(s+o),l=sL(n,i,r,c,s),l=l*60+.5),[l|0,u||0,a]}function cp(t,e,n,i){return(Array.isArray(e)?t(e[0],e[1],e[2]):t(e,n,i)).map(fi)}function dp(t,e,n){return cp(gS,t,e,n)}function oL(t,e,n){return cp(rL,t,e,n)}function aL(t,e,n){return cp(iL,t,e,n)}function vS(t){return(t%360+360)%360}function lL(t){const e=nL.exec(t);let n=255,i;if(!e)return;e[5]!==i&&(n=e[6]?wo(+e[5]):fi(+e[5]));const r=vS(+e[2]),s=+e[3]/100,o=+e[4]/100;return e[1]==="hwb"?i=oL(r,s,o):e[1]==="hsv"?i=aL(r,s,o):i=dp(r,s,o),{r:i[0],g:i[1],b:i[2],a:n}}function uL(t,e){var n=up(t);n[0]=vS(n[0]+e),n=dp(n),t.r=n[0],t.g=n[1],t.b=n[2]}function cL(t){if(!t)return;const e=up(t),n=e[0],i=mS(e[1]),r=mS(e[2]);return t.a<255?`hsla(${n}, ${i}%, ${r}%, ${_n(t.a)})`:`hsl(${n}, ${i}%, ${r}%)`}const yS={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},bS={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};function dL(){const t={},e=Object.keys(bS),n=Object.keys(yS);let i,r,s,o,a;for(i=0;i>16&255,s>>8&255,s&255]}return t}let iu;function fL(t){iu||(iu=dL(),iu.transparent=[0,0,0,0]);const e=iu[t.toLowerCase()];return e&&{r:e[0],g:e[1],b:e[2],a:e.length===4?e[3]:255}}const hL=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;function pL(t){const e=hL.exec(t);let n=255,i,r,s;if(e){if(e[7]!==i){const o=+e[7];n=e[8]?wo(o):di(o*255,0,255)}return i=+e[1],r=+e[3],s=+e[5],i=255&(e[2]?wo(i):di(i,0,255)),r=255&(e[4]?wo(r):di(r,0,255)),s=255&(e[6]?wo(s):di(s,0,255)),{r:i,g:r,b:s,a:n}}}function mL(t){return t&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${_n(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`)}const fp=t=>t<=.0031308?t*12.92:Math.pow(t,1/2.4)*1.055-.055,Qr=t=>t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4);function gL(t,e,n){const i=Qr(_n(t.r)),r=Qr(_n(t.g)),s=Qr(_n(t.b));return{r:fi(fp(i+n*(Qr(_n(e.r))-i))),g:fi(fp(r+n*(Qr(_n(e.g))-r))),b:fi(fp(s+n*(Qr(_n(e.b))-s))),a:t.a+n*(e.a-t.a)}}function ru(t,e,n){if(t){let i=up(t);i[e]=Math.max(0,Math.min(i[e]+i[e]*n,e===0?360:1)),i=dp(i),t.r=i[0],t.g=i[1],t.b=i[2]}}function xS(t,e){return t&&Object.assign(e||{},t)}function wS(t){var e={r:0,g:0,b:0,a:255};return Array.isArray(t)?t.length>=3&&(e={r:t[0],g:t[1],b:t[2],a:255},t.length>3&&(e.a=fi(t[3]))):(e=xS(t,{r:0,g:0,b:0,a:1}),e.a=fi(e.a)),e}function vL(t){return t.charAt(0)==="r"?pL(t):lL(t)}class So{constructor(e){if(e instanceof So)return e;const n=typeof e;let i;n==="object"?i=wS(e):n==="string"&&(i=J3(e)||fL(e)||vL(e)),this._rgb=i,this._valid=!!i}get valid(){return this._valid}get rgb(){var e=xS(this._rgb);return e&&(e.a=_n(e.a)),e}set rgb(e){this._rgb=wS(e)}rgbString(){return this._valid?mL(this._rgb):void 0}hexString(){return this._valid?tL(this._rgb):void 0}hslString(){return this._valid?cL(this._rgb):void 0}mix(e,n){if(e){const i=this.rgb,r=e.rgb;let s;const o=n===s?.5:n,a=2*o-1,l=i.a-r.a,u=((a*l===-1?a:(a+l)/(1+a*l))+1)/2;s=1-u,i.r=255&u*i.r+s*r.r+.5,i.g=255&u*i.g+s*r.g+.5,i.b=255&u*i.b+s*r.b+.5,i.a=o*i.a+(1-o)*r.a,this.rgb=i}return this}interpolate(e,n){return e&&(this._rgb=gL(this._rgb,e._rgb,n)),this}clone(){return new So(this.rgb)}alpha(e){return this._rgb.a=fi(e),this}clearer(e){const n=this._rgb;return n.a*=1-e,this}greyscale(){const e=this._rgb,n=xo(e.r*.3+e.g*.59+e.b*.11);return e.r=e.g=e.b=n,this}opaquer(e){const n=this._rgb;return n.a*=1+e,this}negate(){const e=this._rgb;return e.r=255-e.r,e.g=255-e.g,e.b=255-e.b,this}lighten(e){return ru(this._rgb,2,e),this}darken(e){return ru(this._rgb,2,-e),this}saturate(e){return ru(this._rgb,1,e),this}desaturate(e){return ru(this._rgb,1,-e),this}rotate(e){return uL(this._rgb,e),this}}/*! * Chart.js v4.4.5 * https://www.chartjs.org * (c) 2024 Chart.js Contributors * Released under the MIT License */function Mn(){}const yL=(()=>{let t=0;return()=>t++})();function ae(t){return t===null||typeof t=="undefined"}function _e(t){if(Array.isArray&&Array.isArray(t))return!0;const e=Object.prototype.toString.call(t);return e.slice(0,7)==="[object"&&e.slice(-6)==="Array]"}function re(t){return t!==null&&Object.prototype.toString.call(t)==="[object Object]"}function Ot(t){return(typeof t=="number"||t instanceof Number)&&isFinite(+t)}function an(t,e){return Ot(t)?t:e}function oe(t,e){return typeof t=="undefined"?e:t}const bL=(t,e)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100*e:+t;function de(t,e,n){if(t&&typeof t.call=="function")return t.apply(n,e)}function le(t,e,n,i){let r,s,o;if(_e(t))for(s=t.length,r=0;rt,x:t=>t.x,y:t=>t.y};function SL(t){const e=t.split("."),n=[];let i="";for(const r of e)i+=r,i.endsWith("\\")?i=i.slice(0,-1)+".":(n.push(i),i="");return n}function PL(t){const e=SL(t);return n=>{for(const i of e){if(i==="")break;n=n&&n[i]}return n}}function qr(t,e){return(PS[e]||(PS[e]=PL(e)))(t)}function hp(t){return t.charAt(0).toUpperCase()+t.slice(1)}const $o=t=>typeof t!="undefined",hi=t=>typeof t=="function",$S=(t,e)=>{if(t.size!==e.size)return!1;for(const n of t)if(!e.has(n))return!1;return!0};function $L(t){return t.type==="mouseup"||t.type==="click"||t.type==="contextmenu"}const Ne=Math.PI,tt=2*Ne,au=Number.POSITIVE_INFINITY,kL=Ne/180,Be=Ne/2,Yi=Ne/4,kS=Ne*2/3,pp=Math.log10,pi=Math.sign;function lu(t,e,n){return Math.abs(t-e)r-s).pop(),e}function uu(t){return!isNaN(parseFloat(t))&&isFinite(t)}function CL(t,e){const n=Math.round(t);return n-e<=t&&n+e>=t}function EL(t,e,n){let i,r,s;for(i=0,r=t.length;il&&u=Math.min(e,n)-i&&t<=Math.max(e,n)+i}function mp(t,e,n){n=n||(o=>t[o]1;)s=r+i>>1,n(s)?r=s:i=s;return{lo:r,hi:i}}const gp=(t,e,n,i)=>mp(t,n,i?r=>{const s=t[r][e];return st[r][e]mp(t,n,i=>t[i][e]>=n);function AL(t,e,n){let i=0,r=t.length;for(;ii&&t[r-1]>n;)r--;return i>0||r{const i="_onData"+hp(n),r=t[n];Object.defineProperty(t,n,{configurable:!0,enumerable:!1,value(...s){const o=r.apply(this,s);return t._chartjs.listeners.forEach(a=>{typeof a[i]=="function"&&a[i](...s)}),o}})})}function DS(t,e){const n=t._chartjs;if(!n)return;const i=n.listeners,r=i.indexOf(e);r!==-1&&i.splice(r,1),!(i.length>0)&&(MS.forEach(s=>{delete t[s]}),delete t._chartjs)}function LS(t){const e=new Set(t);return e.size===t.length?t:Array.from(e)}const AS=function(){return typeof window=="undefined"?function(t){return t()}:window.requestAnimationFrame}();function RS(t,e){let n=[],i=!1;return function(...r){n=r,i||(i=!0,AS.call(window,()=>{i=!1,t.apply(e,n)}))}}function FL(t,e){let n;return function(...i){return e?(clearTimeout(n),n=setTimeout(t,e,i)):t.apply(this,i),e}}const vp=t=>t==="start"?"left":t==="end"?"right":"center",Qe=(t,e,n)=>t==="start"?e:t==="end"?n:(e+n)/2,IL=(t,e,n,i)=>t===(i?"left":"right")?n:t==="center"?(e+n)/2:e,cu=t=>t===0||t===1,FS=(t,e,n)=>-(Math.pow(2,10*(t-=1))*Math.sin((t-e)*tt/n)),IS=(t,e,n)=>Math.pow(2,-10*t)*Math.sin((t-e)*tt/n)+1,ko={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>(t-=1)*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-((t-=1)*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>(t-=1)*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>-Math.cos(t*Be)+1,easeOutSine:t=>Math.sin(t*Be),easeInOutSine:t=>-.5*(Math.cos(Ne*t)-1),easeInExpo:t=>t===0?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>t===1?1:-Math.pow(2,-10*t)+1,easeInOutExpo:t=>cu(t)?t:t<.5?.5*Math.pow(2,10*(t*2-1)):.5*(-Math.pow(2,-10*(t*2-1))+2),easeInCirc:t=>t>=1?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1-(t-=1)*t),easeInOutCirc:t=>(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>cu(t)?t:FS(t,.075,.3),easeOutElastic:t=>cu(t)?t:IS(t,.075,.3),easeInOutElastic(t){return cu(t)?t:t<.5?.5*FS(t*2,.1125,.45):.5+.5*IS(t*2-1,.1125,.45)},easeInBack(t){return t*t*((1.70158+1)*t-1.70158)},easeOutBack(t){return(t-=1)*t*((1.70158+1)*t+1.70158)+1},easeInOutBack(t){let e=1.70158;return(t/=.5)<1?.5*(t*t*(((e*=1.525)+1)*t-e)):.5*((t-=2)*t*(((e*=1.525)+1)*t+e)+2)},easeInBounce:t=>1-ko.easeOutBounce(1-t),easeOutBounce(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},easeInOutBounce:t=>t<.5?ko.easeInBounce(t*2)*.5:ko.easeOutBounce(t*2-1)*.5+.5};function NS(t){if(t&&typeof t=="object"){const e=t.toString();return e==="[object CanvasPattern]"||e==="[object CanvasGradient]"}return!1}function OS(t){return NS(t)?t:new So(t)}function yp(t){return NS(t)?t:new So(t).saturate(.5).darken(.1).hexString()}const NL=["x","y","borderWidth","radius","tension"],OL=["color","borderColor","backgroundColor"];function VL(t){t.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0}),t.describe("animation",{_fallback:!1,_indexable:!1,_scriptable:e=>e!=="onProgress"&&e!=="onComplete"&&e!=="fn"}),t.set("animations",{colors:{type:"color",properties:OL},numbers:{type:"number",properties:NL}}),t.describe("animations",{_fallback:"animation"}),t.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:e=>e|0}}}})}function jL(t){t.set("layout",{autoPadding:!0,padding:{top:0,right:0,bottom:0,left:0}})}const VS=new Map;function zL(t,e){e=e||{};const n=t+JSON.stringify(e);let i=VS.get(n);return i||(i=new Intl.NumberFormat(t,e),VS.set(n,i)),i}function jS(t,e,n){return zL(e,n).format(t)}const zS={values(t){return _e(t)?t:""+t},numeric(t,e,n){if(t===0)return"0";const i=this.chart.options.locale;let r,s=t;if(n.length>1){const u=Math.max(Math.abs(n[0].value),Math.abs(n[n.length-1].value));(u<1e-4||u>1e15)&&(r="scientific"),s=BL(t,n)}const o=pp(Math.abs(s)),a=isNaN(o)?1:Math.max(Math.min(-1*Math.floor(o),20),0),l={notation:r,minimumFractionDigits:a,maximumFractionDigits:a};return Object.assign(l,this.options.ticks.format),jS(t,i,l)},logarithmic(t,e,n){if(t===0)return"0";const i=n[e].significand||t/Math.pow(10,Math.floor(pp(t)));return[1,2,3,5,10,15].includes(i)||e>.8*n.length?zS.numeric.call(this,t,e,n):""}};function BL(t,e){let n=e.length>3?e[2].value-e[1].value:e[1].value-e[0].value;return Math.abs(n)>=1&&t!==Math.floor(t)&&(n=t-Math.floor(t)),n}var BS={formatters:zS};function KL(t){t.set("scale",{display:!0,offset:!1,reverse:!1,beginAtZero:!1,bounds:"ticks",clip:!0,grace:0,grid:{display:!0,lineWidth:1,drawOnChartArea:!0,drawTicks:!0,tickLength:8,tickWidth:(e,n)=>n.lineWidth,tickColor:(e,n)=>n.color,offset:!1},border:{display:!0,dash:[],dashOffset:0,width:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:BS.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),t.route("scale.ticks","color","","color"),t.route("scale.grid","color","","borderColor"),t.route("scale.border","color","","borderColor"),t.route("scale.title","color","","color"),t.describe("scale",{_fallback:!1,_scriptable:e=>!e.startsWith("before")&&!e.startsWith("after")&&e!=="callback"&&e!=="parser",_indexable:e=>e!=="borderDash"&&e!=="tickBorderDash"&&e!=="dash"}),t.describe("scales",{_fallback:"scale"}),t.describe("scale.ticks",{_scriptable:e=>e!=="backdropPadding"&&e!=="callback",_indexable:e=>e!=="backdropPadding"})}const qi=Object.create(null),bp=Object.create(null);function To(t,e){if(!e)return t;const n=e.split(".");for(let i=0,r=n.length;ii.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(i,r)=>yp(r.backgroundColor),this.hoverBorderColor=(i,r)=>yp(r.borderColor),this.hoverColor=(i,r)=>yp(r.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0,includeInvisible:!1},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(e),this.apply(n)}set(e,n){return xp(this,e,n)}get(e){return To(this,e)}describe(e,n){return xp(bp,e,n)}override(e,n){return xp(qi,e,n)}route(e,n,i,r){const s=To(this,e),o=To(this,i),a="_"+n;Object.defineProperties(s,{[a]:{value:s[n],writable:!0},[n]:{enumerable:!0,get(){const l=this[a],u=o[r];return re(l)?Object.assign({},u,l):oe(l,u)},set(l){this[a]=l}}})}apply(e){e.forEach(n=>n(this))}}var ke=new HL({_scriptable:t=>!t.startsWith("on"),_indexable:t=>t!=="events",hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}},[VL,jL,KL]);function WL(t){return!t||ae(t.size)||ae(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}function KS(t,e,n,i,r){let s=e[r];return s||(s=e[r]=t.measureText(r).width,n.push(r)),s>i&&(i=s),i}function Zi(t,e,n){const i=t.currentDevicePixelRatio,r=n!==0?Math.max(n/2,.5):0;return Math.round((e-r)*i)/i+r}function HS(t,e){!e&&!t||(e=e||t.getContext("2d"),e.save(),e.resetTransform(),e.clearRect(0,0,t.width,t.height),e.restore())}function wp(t,e,n,i){WS(t,e,n,i,null)}function WS(t,e,n,i,r){let s,o,a,l,u,c,d,f;const h=e.pointStyle,g=e.rotation,v=e.radius;let b=(g||0)*kL;if(h&&typeof h=="object"&&(s=h.toString(),s==="[object HTMLImageElement]"||s==="[object HTMLCanvasElement]")){t.save(),t.translate(n,i),t.rotate(b),t.drawImage(h,-h.width/2,-h.height/2,h.width,h.height),t.restore();return}if(!(isNaN(v)||v<=0)){switch(t.beginPath(),h){default:r?t.ellipse(n,i,r/2,v,0,0,tt):t.arc(n,i,v,0,tt),t.closePath();break;case"triangle":c=r?r/2:v,t.moveTo(n+Math.sin(b)*c,i-Math.cos(b)*v),b+=kS,t.lineTo(n+Math.sin(b)*c,i-Math.cos(b)*v),b+=kS,t.lineTo(n+Math.sin(b)*c,i-Math.cos(b)*v),t.closePath();break;case"rectRounded":u=v*.516,l=v-u,o=Math.cos(b+Yi)*l,d=Math.cos(b+Yi)*(r?r/2-u:l),a=Math.sin(b+Yi)*l,f=Math.sin(b+Yi)*(r?r/2-u:l),t.arc(n-d,i-a,u,b-Ne,b-Be),t.arc(n+f,i-o,u,b-Be,b),t.arc(n+d,i+a,u,b,b+Be),t.arc(n-f,i+o,u,b+Be,b+Ne),t.closePath();break;case"rect":if(!g){l=Math.SQRT1_2*v,c=r?r/2:l,t.rect(n-c,i-l,2*c,2*l);break}b+=Yi;case"rectRot":d=Math.cos(b)*(r?r/2:v),o=Math.cos(b)*v,a=Math.sin(b)*v,f=Math.sin(b)*(r?r/2:v),t.moveTo(n-d,i-a),t.lineTo(n+f,i-o),t.lineTo(n+d,i+a),t.lineTo(n-f,i+o),t.closePath();break;case"crossRot":b+=Yi;case"cross":d=Math.cos(b)*(r?r/2:v),o=Math.cos(b)*v,a=Math.sin(b)*v,f=Math.sin(b)*(r?r/2:v),t.moveTo(n-d,i-a),t.lineTo(n+d,i+a),t.moveTo(n+f,i-o),t.lineTo(n-f,i+o);break;case"star":d=Math.cos(b)*(r?r/2:v),o=Math.cos(b)*v,a=Math.sin(b)*v,f=Math.sin(b)*(r?r/2:v),t.moveTo(n-d,i-a),t.lineTo(n+d,i+a),t.moveTo(n+f,i-o),t.lineTo(n-f,i+o),b+=Yi,d=Math.cos(b)*(r?r/2:v),o=Math.cos(b)*v,a=Math.sin(b)*v,f=Math.sin(b)*(r?r/2:v),t.moveTo(n-d,i-a),t.lineTo(n+d,i+a),t.moveTo(n+f,i-o),t.lineTo(n-f,i+o);break;case"line":o=r?r/2:Math.cos(b)*v,a=Math.sin(b)*v,t.moveTo(n-o,i-a),t.lineTo(n+o,i+a);break;case"dash":t.moveTo(n,i),t.lineTo(n+Math.cos(b)*(r?r/2:v),i+Math.sin(b)*v);break;case!1:t.closePath();break}t.fill(),e.borderWidth>0&&t.stroke()}}function Sp(t,e,n){return n=n||.5,!e||t&&t.x>e.left-n&&t.xe.top-n&&t.y0&&s.strokeColor!=="";let l,u;for(t.save(),t.font=r.string,UL(t,s),l=0;l+t||0;function kp(t,e){const n={},i=re(e),r=i?Object.keys(e):e,s=re(t)?i?o=>oe(t[o],t[e[o]]):o=>t[o]:()=>t;for(const o of r)n[o]=ZL(s(o));return n}function US(t){return kp(t,{top:"y",right:"x",bottom:"y",left:"x"})}function Zr(t){return kp(t,["topLeft","topRight","bottomLeft","bottomRight"])}function Pt(t){const e=US(t);return e.width=e.left+e.right,e.height=e.top+e.bottom,e}function Ke(t,e){t=t||{},e=e||ke.font;let n=oe(t.size,e.size);typeof n=="string"&&(n=parseInt(n,10));let i=oe(t.style,e.style);i&&!(""+i).match(QL)&&(console.warn('Invalid font style specified: "'+i+'"'),i=void 0);const r={family:oe(t.family,e.family),lineHeight:qL(oe(t.lineHeight,e.lineHeight),n),size:n,style:i,weight:oe(t.weight,e.weight),string:""};return r.string=WL(r),r}function be(t,e,n,i){let r,s,o;for(r=0,s=t.length;rn&&a===0?0:a+l;return{min:o(i,-Math.abs(s)),max:o(r,s)}}function Jr(t,e){return Object.assign(Object.create(t),e)}function Tp(t,e=[""],n,i,r=()=>t[0]){const s=n||t;typeof i=="undefined"&&(i=qS("_fallback",t));const o={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:t,_rootScopes:s,_fallback:i,_getTarget:r,override:a=>Tp([a,...t],e,s,i)};return new Proxy(o,{deleteProperty(a,l){return delete a[l],delete a._keys,delete t[0][l],!0},get(a,l){return GS(a,l,()=>aA(l,e,t,a))},getOwnPropertyDescriptor(a,l){return Reflect.getOwnPropertyDescriptor(a._scopes[0],l)},getPrototypeOf(){return Reflect.getPrototypeOf(t[0])},has(a,l){return ZS(a).includes(l)},ownKeys(a){return ZS(a)},set(a,l,u){const c=a._storage||(a._storage=r());return a[l]=c[l]=u,delete a._keys,!0}})}function es(t,e,n,i){const r={_cacheable:!1,_proxy:t,_context:e,_subProxy:n,_stack:new Set,_descriptors:YS(t,i),setContext:s=>es(t,s,n,i),override:s=>es(t.override(s),e,n,i)};return new Proxy(r,{deleteProperty(s,o){return delete s[o],delete t[o],!0},get(s,o,a){return GS(s,o,()=>tA(s,o,a))},getOwnPropertyDescriptor(s,o){return s._descriptors.allKeys?Reflect.has(t,o)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(t,o)},getPrototypeOf(){return Reflect.getPrototypeOf(t)},has(s,o){return Reflect.has(t,o)},ownKeys(){return Reflect.ownKeys(t)},set(s,o,a){return t[o]=a,delete s[o],!0}})}function YS(t,e={scriptable:!0,indexable:!0}){const{_scriptable:n=e.scriptable,_indexable:i=e.indexable,_allKeys:r=e.allKeys}=t;return{allKeys:r,scriptable:n,indexable:i,isScriptable:hi(n)?n:()=>n,isIndexable:hi(i)?i:()=>i}}const eA=(t,e)=>t?t+hp(e):e,Cp=(t,e)=>re(e)&&t!=="adapters"&&(Object.getPrototypeOf(e)===null||e.constructor===Object);function GS(t,e,n){if(Object.prototype.hasOwnProperty.call(t,e)||e==="constructor")return t[e];const i=n();return t[e]=i,i}function tA(t,e,n){const{_proxy:i,_context:r,_subProxy:s,_descriptors:o}=t;let a=i[e];return hi(a)&&o.isScriptable(e)&&(a=nA(e,a,t,n)),_e(a)&&a.length&&(a=iA(e,a,t,o.isIndexable)),Cp(e,a)&&(a=es(a,r,s&&s[e],o)),a}function nA(t,e,n,i){const{_proxy:r,_context:s,_subProxy:o,_stack:a}=n;if(a.has(t))throw new Error("Recursion detected: "+Array.from(a).join("->")+"->"+t);a.add(t);let l=e(s,o||i);return a.delete(t),Cp(t,l)&&(l=Ep(r._scopes,r,t,l)),l}function iA(t,e,n,i){const{_proxy:r,_context:s,_subProxy:o,_descriptors:a}=n;if(typeof s.index!="undefined"&&i(t))return e[s.index%e.length];if(re(e[0])){const l=e,u=r._scopes.filter(c=>c!==l);e=[];for(const c of l){const d=Ep(u,r,t,c);e.push(es(d,s,o&&o[t],a))}}return e}function XS(t,e,n){return hi(t)?t(e,n):t}const rA=(t,e)=>t===!0?e:typeof t=="string"?qr(e,t):void 0;function sA(t,e,n,i,r){for(const s of e){const o=rA(n,s);if(o){t.add(o);const a=XS(o._fallback,n,r);if(typeof a!="undefined"&&a!==n&&a!==i)return a}else if(o===!1&&typeof i!="undefined"&&n!==i)return null}return!1}function Ep(t,e,n,i){const r=e._rootScopes,s=XS(e._fallback,n,i),o=[...t,...r],a=new Set;a.add(i);let l=QS(a,o,n,s||n,i);return l===null||typeof s!="undefined"&&s!==n&&(l=QS(a,o,s,l,i),l===null)?!1:Tp(Array.from(a),[""],r,s,()=>oA(e,n,i))}function QS(t,e,n,i,r){for(;n;)n=sA(t,e,n,i,r);return n}function oA(t,e,n){const i=t._getTarget();e in i||(i[e]={});const r=i[e];return _e(r)&&re(n)?n:r||{}}function aA(t,e,n,i){let r;for(const s of e)if(r=qS(eA(s,t),n),typeof r!="undefined")return Cp(t,r)?Ep(n,i,t,r):r}function qS(t,e){for(const n of e){if(!n)continue;const i=n[t];if(typeof i!="undefined")return i}}function ZS(t){let e=t._keys;return e||(e=t._keys=lA(t._scopes)),e}function lA(t){const e=new Set;for(const n of t)for(const i of Object.keys(n).filter(r=>!r.startsWith("_")))e.add(i);return Array.from(e)}function _p(){return typeof window!="undefined"&&typeof document!="undefined"}function Mp(t){let e=t.parentNode;return e&&e.toString()==="[object ShadowRoot]"&&(e=e.host),e}function fu(t,e,n){let i;return typeof t=="string"?(i=parseInt(t,10),t.indexOf("%")!==-1&&(i=i/100*e.parentNode[n])):i=t,i}const hu=t=>t.ownerDocument.defaultView.getComputedStyle(t,null);function uA(t,e){return hu(t).getPropertyValue(e)}const cA=["top","right","bottom","left"];function Ji(t,e,n){const i={};n=n?"-"+n:"";for(let r=0;r<4;r++){const s=cA[r];i[s]=parseFloat(t[e+"-"+s+n])||0}return i.width=i.left+i.right,i.height=i.top+i.bottom,i}const dA=(t,e,n)=>(t>0||e>0)&&(!n||!n.shadowRoot);function fA(t,e){const n=t.touches,i=n&&n.length?n[0]:t,{offsetX:r,offsetY:s}=i;let o=!1,a,l;if(dA(r,s,t.target))a=r,l=s;else{const u=e.getBoundingClientRect();a=i.clientX-u.left,l=i.clientY-u.top,o=!0}return{x:a,y:l,box:o}}function er(t,e){if("native"in t)return t;const{canvas:n,currentDevicePixelRatio:i}=e,r=hu(n),s=r.boxSizing==="border-box",o=Ji(r,"padding"),a=Ji(r,"border","width"),{x:l,y:u,box:c}=fA(t,n),d=o.left+(c&&a.left),f=o.top+(c&&a.top);let{width:h,height:g}=e;return s&&(h-=o.width+a.width,g-=o.height+a.height),{x:Math.round((l-d)/h*n.width/i),y:Math.round((u-f)/g*n.height/i)}}function hA(t,e,n){let i,r;if(e===void 0||n===void 0){const s=t&&Mp(t);if(!s)e=t.clientWidth,n=t.clientHeight;else{const o=s.getBoundingClientRect(),a=hu(s),l=Ji(a,"border","width"),u=Ji(a,"padding");e=o.width-u.width-l.width,n=o.height-u.height-l.height,i=fu(a.maxWidth,s,"clientWidth"),r=fu(a.maxHeight,s,"clientHeight")}}return{width:e,height:n,maxWidth:i||au,maxHeight:r||au}}const pu=t=>Math.round(t*10)/10;function pA(t,e,n,i){const r=hu(t),s=Ji(r,"margin"),o=fu(r.maxWidth,t,"clientWidth")||au,a=fu(r.maxHeight,t,"clientHeight")||au,l=hA(t,e,n);let{width:u,height:c}=l;if(r.boxSizing==="content-box"){const f=Ji(r,"border","width"),h=Ji(r,"padding");u-=h.width+f.width,c-=h.height+f.height}return u=Math.max(0,u-s.width),c=Math.max(0,i?u/i:c-s.height),u=pu(Math.min(u,o,l.maxWidth)),c=pu(Math.min(c,a,l.maxHeight)),u&&!c&&(c=pu(u/2)),(e!==void 0||n!==void 0)&&i&&l.height&&c>l.height&&(c=l.height,u=pu(Math.floor(c*i))),{width:u,height:c}}function JS(t,e,n){const i=e||1,r=Math.floor(t.height*i),s=Math.floor(t.width*i);t.height=Math.floor(t.height),t.width=Math.floor(t.width);const o=t.canvas;return o.style&&(n||!o.style.height&&!o.style.width)&&(o.style.height=`${t.height}px`,o.style.width=`${t.width}px`),t.currentDevicePixelRatio!==i||o.height!==r||o.width!==s?(t.currentDevicePixelRatio=i,o.height=r,o.width=s,t.ctx.setTransform(i,0,0,i,0,0),!0):!1}const mA=function(){let t=!1;try{const e={get passive(){return t=!0,!1}};_p()&&(window.addEventListener("test",null,e),window.removeEventListener("test",null,e))}catch(e){}return t}();function eP(t,e){const n=uA(t,e),i=n&&n.match(/^(\d+)(\.\d+)?px$/);return i?+i[1]:void 0}const gA=function(t,e){return{x(n){return t+t+e-n},setWidth(n){e=n},textAlign(n){return n==="center"?n:n==="right"?"left":"right"},xPlus(n,i){return n-i},leftForLtr(n,i){return n-i}}},vA=function(){return{x(t){return t},setWidth(t){},textAlign(t){return t},xPlus(t,e){return t+e},leftForLtr(t,e){return t}}};function ts(t,e,n){return t?gA(e,n):vA()}function tP(t,e){let n,i;(e==="ltr"||e==="rtl")&&(n=t.canvas.style,i=[n.getPropertyValue("direction"),n.getPropertyPriority("direction")],n.setProperty("direction",e,"important"),t.prevTextDirection=i)}function nP(t,e){e!==void 0&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",e[0],e[1]))}/*! * Chart.js v4.4.5 * https://www.chartjs.org * (c) 2024 Chart.js Contributors * Released under the MIT License */class yA{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(e,n,i,r){const s=n.listeners[r],o=n.duration;s.forEach(a=>a({chart:e,initial:n.initial,numSteps:o,currentStep:Math.min(i-n.start,o)}))}_refresh(){this._request||(this._running=!0,this._request=AS.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(e=Date.now()){let n=0;this._charts.forEach((i,r)=>{if(!i.running||!i.items.length)return;const s=i.items;let o=s.length-1,a=!1,l;for(;o>=0;--o)l=s[o],l._active?(l._total>i.duration&&(i.duration=l._total),l.tick(e),a=!0):(s[o]=s[s.length-1],s.pop());a&&(r.draw(),this._notify(r,i,e,"progress")),s.length||(i.running=!1,this._notify(r,i,e,"complete"),i.initial=!1),n+=s.length}),this._lastDate=e,n===0&&(this._running=!1)}_getAnims(e){const n=this._charts;let i=n.get(e);return i||(i={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},n.set(e,i)),i}listen(e,n,i){this._getAnims(e).listeners[n].push(i)}add(e,n){!n||!n.length||this._getAnims(e).items.push(...n)}has(e){return this._getAnims(e).items.length>0}start(e){const n=this._charts.get(e);n&&(n.running=!0,n.start=Date.now(),n.duration=n.items.reduce((i,r)=>Math.max(i,r._duration),0),this._refresh())}running(e){if(!this._running)return!1;const n=this._charts.get(e);return!(!n||!n.running||!n.items.length)}stop(e){const n=this._charts.get(e);if(!n||!n.items.length)return;const i=n.items;let r=i.length-1;for(;r>=0;--r)i[r].cancel();n.items=[],this._notify(e,n,Date.now(),"complete")}remove(e){return this._charts.delete(e)}}var Dn=new yA;const iP="transparent",bA={boolean(t,e,n){return n>.5?e:t},color(t,e,n){const i=OS(t||iP),r=i.valid&&OS(e||iP);return r&&r.valid?r.mix(i,n).hexString():e},number(t,e,n){return t+(e-t)*n}};class xA{constructor(e,n,i,r){const s=n[i];r=be([e.to,r,s,e.from]);const o=be([e.from,s,r]);this._active=!0,this._fn=e.fn||bA[e.type||typeof o],this._easing=ko[e.easing]||ko.linear,this._start=Math.floor(Date.now()+(e.delay||0)),this._duration=this._total=Math.floor(e.duration),this._loop=!!e.loop,this._target=n,this._prop=i,this._from=o,this._to=r,this._promises=void 0}active(){return this._active}update(e,n,i){if(this._active){this._notify(!1);const r=this._target[this._prop],s=i-this._start,o=this._duration-s;this._start=i,this._duration=Math.floor(Math.max(o,e.duration)),this._total+=s,this._loop=!!e.loop,this._to=be([e.to,n,r,e.from]),this._from=be([e.from,r,n])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(e){const n=e-this._start,i=this._duration,r=this._prop,s=this._from,o=this._loop,a=this._to;let l;if(this._active=s!==a&&(o||n1?2-l:l,l=this._easing(Math.min(1,Math.max(0,l))),this._target[r]=this._fn(s,a,l)}wait(){const e=this._promises||(this._promises=[]);return new Promise((n,i)=>{e.push({res:n,rej:i})})}_notify(e){const n=e?"res":"rej",i=this._promises||[];for(let r=0;r{const s=e[r];if(!re(s))return;const o={};for(const a of n)o[a]=s[a];(_e(s.properties)&&s.properties||[r]).forEach(a=>{(a===r||!i.has(a))&&i.set(a,o)})})}_animateOptions(e,n){const i=n.options,r=SA(e,i);if(!r)return[];const s=this._createAnimations(r,i);return i.$shared&&wA(e.options.$animations,i).then(()=>{e.options=i},()=>{}),s}_createAnimations(e,n){const i=this._properties,r=[],s=e.$animations||(e.$animations={}),o=Object.keys(n),a=Date.now();let l;for(l=o.length-1;l>=0;--l){const u=o[l];if(u.charAt(0)==="$")continue;if(u==="options"){r.push(...this._animateOptions(e,n));continue}const c=n[u];let d=s[u];const f=i.get(u);if(d)if(f&&d.active()){d.update(f,c,a);continue}else d.cancel();if(!f||!f.duration){e[u]=c;continue}s[u]=d=new xA(f,e,u,c),r.push(d)}return r}update(e,n){if(this._properties.size===0){Object.assign(e,n);return}const i=this._createAnimations(e,n);if(i.length)return Dn.add(this._chart,i),!0}}function wA(t,e){const n=[],i=Object.keys(e);for(let r=0;r0||!n&&s<0)return r.index}return null}function uP(t,e){const{chart:n,_cachedMeta:i}=t,r=n._stacks||(n._stacks={}),{iScale:s,vScale:o,index:a}=i,l=s.axis,u=o.axis,c=TA(s,o,i),d=e.length;let f;for(let h=0;hn[i].axis===e).shift()}function _A(t,e){return Jr(t,{active:!1,dataset:void 0,datasetIndex:e,index:e,mode:"default",type:"dataset"})}function MA(t,e,n){return Jr(t,{active:!1,dataIndex:e,parsed:void 0,raw:void 0,element:n,index:e,mode:"default",type:"data"})}function Eo(t,e){const n=t.controller.index,i=t.vScale&&t.vScale.axis;if(i){e=e||t._parsed;for(const r of e){const s=r._stacks;if(!s||s[i]===void 0||s[i][n]===void 0)return;delete s[i][n],s[i]._visualValues!==void 0&&s[i]._visualValues[n]!==void 0&&delete s[i]._visualValues[n]}}}const Ap=t=>t==="reset"||t==="none",cP=(t,e)=>e?t:Object.assign({},t),DA=(t,e,n)=>t&&!e.hidden&&e._stacked&&{keys:oP(n,!0),values:null};class _o{constructor(e,n){this.chart=e,this._ctx=e.ctx,this.index=n,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){const e=this._cachedMeta;this.configure(),this.linkScales(),e._stacked=Dp(e.vScale,e),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(e){this.index!==e&&Eo(this._cachedMeta),this.index=e}linkScales(){const e=this.chart,n=this._cachedMeta,i=this.getDataset(),r=(d,f,h,g)=>d==="x"?f:d==="r"?g:h,s=n.xAxisID=oe(i.xAxisID,Lp(e,"x")),o=n.yAxisID=oe(i.yAxisID,Lp(e,"y")),a=n.rAxisID=oe(i.rAxisID,Lp(e,"r")),l=n.indexAxis,u=n.iAxisID=r(l,s,o,a),c=n.vAxisID=r(l,o,s,a);n.xScale=this.getScaleForId(s),n.yScale=this.getScaleForId(o),n.rScale=this.getScaleForId(a),n.iScale=this.getScaleForId(u),n.vScale=this.getScaleForId(c)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(e){return this.chart.scales[e]}_getOtherScale(e){const n=this._cachedMeta;return e===n.iScale?n.vScale:n.iScale}reset(){this._update("reset")}_destroy(){const e=this._cachedMeta;this._data&&DS(this._data,this),e._stacked&&Eo(e)}_dataCheck(){const e=this.getDataset(),n=e.data||(e.data=[]),i=this._data;if(re(n)){const r=this._cachedMeta;this._data=kA(n,r)}else if(i!==n){if(i){DS(i,this);const r=this._cachedMeta;Eo(r),r._parsed=[]}n&&Object.isExtensible(n)&&RL(n,this),this._syncList=[],this._data=n}}addElements(){const e=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(e.dataset=new this.datasetElementType)}buildOrUpdateElements(e){const n=this._cachedMeta,i=this.getDataset();let r=!1;this._dataCheck();const s=n._stacked;n._stacked=Dp(n.vScale,n),n.stack!==i.stack&&(r=!0,Eo(n),n.stack=i.stack),this._resyncElements(e),(r||s!==n._stacked)&&(uP(this,n._parsed),n._stacked=Dp(n.vScale,n))}configure(){const e=this.chart.config,n=e.datasetScopeKeys(this._type),i=e.getOptionScopes(this.getDataset(),n,!0);this.options=e.createResolver(i,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(e,n){const{_cachedMeta:i,_data:r}=this,{iScale:s,_stacked:o}=i,a=s.axis;let l=e===0&&n===r.length?!0:i._sorted,u=e>0&&i._parsed[e-1],c,d,f;if(this._parsing===!1)i._parsed=r,i._sorted=!0,f=r;else{_e(r[e])?f=this.parseArrayData(i,r,e,n):re(r[e])?f=this.parseObjectData(i,r,e,n):f=this.parsePrimitiveData(i,r,e,n);const h=()=>d[a]===null||u&&d[a]v||d=0;--f)if(!g()){this.updateRangeFromParsed(u,e,h,l);break}}return u}getAllParsedValues(e){const n=this._cachedMeta._parsed,i=[];let r,s,o;for(r=0,s=n.length;r=0&&ethis.getContext(i,r,n),v=u.resolveNamedOptions(f,h,g,d);return v.$shared&&(v.$shared=l,s[o]=Object.freeze(cP(v,l))),v}_resolveAnimations(e,n,i){const r=this.chart,s=this._cachedDataOpts,o=`animation-${n}`,a=s[o];if(a)return a;let l;if(r.options.animation!==!1){const c=this.chart.config,d=c.datasetAnimationScopeKeys(this._type,n),f=c.getOptionScopes(this.getDataset(),d);l=c.createResolver(f,this.getContext(e,i,n))}const u=new rP(r,l&&l.animations);return l&&l._cacheable&&(s[o]=Object.freeze(u)),u}getSharedOptions(e){if(e.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},e))}includeOptions(e,n){return!n||Ap(e)||this.chart._animationsDisabled}_getSharedOptions(e,n){const i=this.resolveDataElementOptions(e,n),r=this._sharedOptions,s=this.getSharedOptions(i),o=this.includeOptions(n,s)||s!==r;return this.updateSharedOptions(s,n,i),{sharedOptions:s,includeOptions:o}}updateElement(e,n,i,r){Ap(r)?Object.assign(e,i):this._resolveAnimations(n,r).update(e,i)}updateSharedOptions(e,n,i){e&&!Ap(n)&&this._resolveAnimations(void 0,n).update(e,i)}_setStyle(e,n,i,r){e.active=r;const s=this.getStyle(n,r);this._resolveAnimations(n,i,r).update(e,{options:!r&&this.getSharedOptions(s)||s})}removeHoverStyle(e,n,i){this._setStyle(e,i,"active",!1)}setHoverStyle(e,n,i){this._setStyle(e,i,"active",!0)}_removeDatasetHoverStyle(){const e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",!1)}_setDatasetHoverStyle(){const e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",!0)}_resyncElements(e){const n=this._data,i=this._cachedMeta.data;for(const[a,l,u]of this._syncList)this[a](l,u);this._syncList=[];const r=i.length,s=n.length,o=Math.min(s,r);o&&this.parse(0,o),s>r?this._insertElements(r,s-r,e):s{for(u.length+=n,a=u.length-1;a>=o;a--)u[a]=u[a-n]};for(l(s),a=e;ar-s))}return t._cache.$bar}function AA(t){const e=t.iScale,n=LA(e,t.type);let i=e._length,r,s,o,a;const l=()=>{o===32767||o===-32768||($o(a)&&(i=Math.min(i,Math.abs(o-a)||i)),a=o)};for(r=0,s=n.length;r0?r[t-1]:null,a=tMath.abs(a)&&(l=a,u=o),e[n.axis]=u,e._custom={barStart:l,barEnd:u,start:r,end:s,min:o,max:a}}function dP(t,e,n,i){return _e(t)?IA(t,e,n,i):e[n.axis]=n.parse(t,i),e}function fP(t,e,n,i){const r=t.iScale,s=t.vScale,o=r.getLabels(),a=r===s,l=[];let u,c,d,f;for(u=n,c=n+i;u=n?1:-1)}function OA(t){let e,n,i,r,s;return t.horizontal?(e=t.base>t.x,n="left",i="right"):(e=t.basec.controller.options.grouped),s=i.options.stacked,o=[],a=this._cachedMeta.controller.getParsed(n),l=a&&a[i.axis],u=c=>{const d=c._parsed.find(h=>h[i.axis]===l),f=d&&d[c.vScale.axis];if(ae(f)||isNaN(f))return!0};for(const c of r)if(!(n!==void 0&&u(c))&&((s===!1||o.indexOf(c.stack)===-1||s===void 0&&c.stack===void 0)&&o.push(c.stack),c.index===e))break;return o.length||o.push(void 0),o}_getStackCount(e){return this._getStacks(void 0,e).length}_getStackIndex(e,n,i){const r=this._getStacks(e,i),s=n!==void 0?r.indexOf(n):-1;return s===-1?r.length-1:s}_getRuler(){const e=this.options,n=this._cachedMeta,i=n.iScale,r=[];let s,o;for(s=0,o=n.data.length;s{l[o]&&l[o](e[n],r)&&(s.push({element:l,datasetIndex:u,index:c}),a=a||l.inRange(e.x,e.y,r))}),i&&!a?[]:s}var YA={evaluateInteractionItems:Mo,modes:{index(t,e,n,i){const r=er(e,t),s=n.axis||"x",o=n.includeInvisible||!1,a=n.intersect?Ip(t,r,s,i,o):Np(t,r,s,!1,i,o),l=[];return a.length?(t.getSortedVisibleDatasetMetas().forEach(u=>{const c=a[0].index,d=u.data[c];d&&!d.skip&&l.push({element:d,datasetIndex:u.index,index:c})}),l):[]},dataset(t,e,n,i){const r=er(e,t),s=n.axis||"xy",o=n.includeInvisible||!1;let a=n.intersect?Ip(t,r,s,i,o):Np(t,r,s,!1,i,o);if(a.length>0){const l=a[0].datasetIndex,u=t.getDatasetMeta(l).data;a=[];for(let c=0;cn.pos===e)}function vP(t,e){return t.filter(n=>gP.indexOf(n.pos)===-1&&n.box.axis===e)}function Lo(t,e){return t.sort((n,i)=>{const r=e?i:n,s=e?n:i;return r.weight===s.weight?r.index-s.index:r.weight-s.weight})}function GA(t){const e=[];let n,i,r,s,o,a;for(n=0,i=(t||[]).length;nu.box.fullSize),!0),i=Lo(Do(e,"left"),!0),r=Lo(Do(e,"right")),s=Lo(Do(e,"top"),!0),o=Lo(Do(e,"bottom")),a=vP(e,"x"),l=vP(e,"y");return{fullSize:n,leftAndTop:i.concat(s),rightAndBottom:r.concat(l).concat(o).concat(a),chartArea:Do(e,"chartArea"),vertical:i.concat(r).concat(l),horizontal:s.concat(o).concat(a)}}function yP(t,e,n,i){return Math.max(t[n],e[n])+Math.max(t[i],e[i])}function bP(t,e){t.top=Math.max(t.top,e.top),t.left=Math.max(t.left,e.left),t.bottom=Math.max(t.bottom,e.bottom),t.right=Math.max(t.right,e.right)}function ZA(t,e,n,i){const{pos:r,box:s}=n,o=t.maxPadding;if(!re(r)){n.size&&(t[r]-=n.size);const d=i[n.stack]||{size:0,count:1};d.size=Math.max(d.size,n.horizontal?s.height:s.width),n.size=d.size/d.count,t[r]+=n.size}s.getPadding&&bP(o,s.getPadding());const a=Math.max(0,e.outerWidth-yP(o,t,"left","right")),l=Math.max(0,e.outerHeight-yP(o,t,"top","bottom")),u=a!==t.w,c=l!==t.h;return t.w=a,t.h=l,n.horizontal?{same:u,other:c}:{same:c,other:u}}function JA(t){const e=t.maxPadding;function n(i){const r=Math.max(e[i]-t[i],0);return t[i]+=r,r}t.y+=n("top"),t.x+=n("left"),n("right"),n("bottom")}function e6(t,e){const n=e.maxPadding;function i(r){const s={left:0,top:0,right:0,bottom:0};return r.forEach(o=>{s[o]=Math.max(e[o],n[o])}),s}return i(t?["left","right"]:["top","bottom"])}function Ao(t,e,n,i){const r=[];let s,o,a,l,u,c;for(s=0,o=t.length,u=0;s{typeof v.beforeLayout=="function"&&v.beforeLayout()});const c=l.reduce((v,b)=>b.box.options&&b.box.options.display===!1?v:v+1,0)||1,d=Object.freeze({outerWidth:e,outerHeight:n,padding:r,availableWidth:s,availableHeight:o,vBoxMaxWidth:s/2/c,hBoxMaxHeight:o/2}),f=Object.assign({},r);bP(f,Pt(i));const h=Object.assign({maxPadding:f,w:s,h:o,x:r.left,y:r.top},r),g=QA(l.concat(u),d);Ao(a.fullSize,h,d,g),Ao(l,h,d,g),Ao(u,h,d,g)&&Ao(l,h,d,g),JA(h),xP(a.leftAndTop,h,d,g),h.x+=h.w,h.y+=h.h,xP(a.rightAndBottom,h,d,g),t.chartArea={left:h.left,top:h.top,right:h.left+h.w,bottom:h.top+h.h,height:h.h,width:h.w},le(a.chartArea,v=>{const b=v.box;Object.assign(b,t.chartArea),b.update(h.w,h.h,{left:0,top:0,right:0,bottom:0})})}};class wP{acquireContext(e,n){}releaseContext(e){return!1}addEventListener(e,n,i){}removeEventListener(e,n,i){}getDevicePixelRatio(){return 1}getMaximumSize(e,n,i,r){return n=Math.max(0,n||e.width),i=i||e.height,{width:n,height:Math.max(0,r?Math.floor(n/r):i)}}isAttached(e){return!0}updateConfig(e){}}class t6 extends wP{acquireContext(e){return e&&e.getContext&&e.getContext("2d")||null}updateConfig(e){e.options.animation=!1}}const vu="$chartjs",n6={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},SP=t=>t===null||t==="";function i6(t,e){const n=t.style,i=t.getAttribute("height"),r=t.getAttribute("width");if(t[vu]={initial:{height:i,width:r,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",n.boxSizing=n.boxSizing||"border-box",SP(r)){const s=eP(t,"width");s!==void 0&&(t.width=s)}if(SP(i))if(t.style.height==="")t.height=t.width/(e||2);else{const s=eP(t,"height");s!==void 0&&(t.height=s)}return t}const PP=mA?{passive:!0}:!1;function r6(t,e,n){t&&t.addEventListener(e,n,PP)}function s6(t,e,n){t&&t.canvas&&t.canvas.removeEventListener(e,n,PP)}function o6(t,e){const n=n6[t.type]||t.type,{x:i,y:r}=er(t,e);return{type:n,chart:e,native:t,x:i!==void 0?i:null,y:r!==void 0?r:null}}function yu(t,e){for(const n of t)if(n===e||n.contains(e))return!0}function a6(t,e,n){const i=t.canvas,r=new MutationObserver(s=>{let o=!1;for(const a of s)o=o||yu(a.addedNodes,i),o=o&&!yu(a.removedNodes,i);o&&n()});return r.observe(document,{childList:!0,subtree:!0}),r}function l6(t,e,n){const i=t.canvas,r=new MutationObserver(s=>{let o=!1;for(const a of s)o=o||yu(a.removedNodes,i),o=o&&!yu(a.addedNodes,i);o&&n()});return r.observe(document,{childList:!0,subtree:!0}),r}const Ro=new Map;let $P=0;function kP(){const t=window.devicePixelRatio;t!==$P&&($P=t,Ro.forEach((e,n)=>{n.currentDevicePixelRatio!==t&&e()}))}function u6(t,e){Ro.size||window.addEventListener("resize",kP),Ro.set(t,e)}function c6(t){Ro.delete(t),Ro.size||window.removeEventListener("resize",kP)}function d6(t,e,n){const i=t.canvas,r=i&&Mp(i);if(!r)return;const s=RS((a,l)=>{const u=r.clientWidth;n(a,l),u{const l=a[0],u=l.contentRect.width,c=l.contentRect.height;u===0&&c===0||s(u,c)});return o.observe(r),u6(t,s),o}function Op(t,e,n){n&&n.disconnect(),e==="resize"&&c6(t)}function f6(t,e,n){const i=t.canvas,r=RS(s=>{t.ctx!==null&&n(o6(s,t))},t);return r6(i,e,r),r}class h6 extends wP{acquireContext(e,n){const i=e&&e.getContext&&e.getContext("2d");return i&&i.canvas===e?(i6(e,n),i):null}releaseContext(e){const n=e.canvas;if(!n[vu])return!1;const i=n[vu].initial;["height","width"].forEach(s=>{const o=i[s];ae(o)?n.removeAttribute(s):n.setAttribute(s,o)});const r=i.style||{};return Object.keys(r).forEach(s=>{n.style[s]=r[s]}),n.width=n.width,delete n[vu],!0}addEventListener(e,n,i){this.removeEventListener(e,n);const r=e.$proxies||(e.$proxies={}),o={attach:a6,detach:l6,resize:d6}[n]||f6;r[n]=o(e,n,i)}removeEventListener(e,n){const i=e.$proxies||(e.$proxies={}),r=i[n];if(!r)return;({attach:Op,detach:Op,resize:Op}[n]||s6)(e,n,r),i[n]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(e,n,i,r){return pA(e,n,i,r)}isAttached(e){const n=e&&Mp(e);return!!(n&&n.isConnected)}}function p6(t){return!_p()||typeof OffscreenCanvas!="undefined"&&t instanceof OffscreenCanvas?t6:h6}let mi=(Fu=class{constructor(){G(this,"x");G(this,"y");G(this,"active",!1);G(this,"options");G(this,"$animations")}tooltipPosition(e){const{x:n,y:i}=this.getProps(["x","y"],e);return{x:n,y:i}}hasValue(){return uu(this.x)&&uu(this.y)}getProps(e,n){const i=this.$animations;if(!n||!i)return this;const r={};return e.forEach(s=>{r[s]=i[s]&&i[s].active()?i[s]._to:this[s]}),r}},G(Fu,"defaults",{}),G(Fu,"defaultRoutes"),Fu);function m6(t,e){const n=t.options.ticks,i=g6(t),r=Math.min(n.maxTicksLimit||i,i),s=n.major.enabled?y6(e):[],o=s.length,a=s[0],l=s[o-1],u=[];if(o>r)return b6(e,u,s,o/r),u;const c=v6(s,e,r);if(o>0){let d,f;const h=o>1?Math.round((l-a)/(o-1)):null;for(bu(e,u,c,ae(h)?0:a-h,a),d=0,f=o-1;dr)return l}return Math.max(r,1)}function y6(t){const e=[];let n,i;for(n=0,i=t.length;nt==="left"?"right":t==="right"?"left":t,TP=(t,e,n)=>e==="top"||e==="left"?t[e]+n:t[e]-n,CP=(t,e)=>Math.min(e||t,t);function EP(t,e){const n=[],i=t.length/e,r=t.length;let s=0;for(;so+a)))return l}function P6(t,e){le(t,n=>{const i=n.gc,r=i.length/2;let s;if(r>e){for(s=0;si?i:n,i=r&&n>i?n:i,{min:an(n,an(i,n)),max:an(i,an(n,i))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const e=this.chart.data;return this.options.labels||(this.isHorizontal()?e.xLabels:e.yLabels)||e.labels||[]}getLabelItems(e=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(e))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){de(this.options.beforeUpdate,[this])}update(e,n,i){const{beginAtZero:r,grace:s,ticks:o}=this.options,a=o.sampleSize;this.beforeUpdate(),this.maxWidth=e,this.maxHeight=n,this._margins=i=Object.assign({left:0,right:0,top:0,bottom:0},i),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+i.left+i.right:this.height+i.top+i.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=JL(this,s,r),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const l=a=s||i<=1||!this.isHorizontal()){this.labelRotation=r;return}const c=this._getLabelSizes(),d=c.widest.width,f=c.highest.height,h=ct(this.chart.width-d,0,this.maxWidth);a=e.offset?this.maxWidth/i:h/(i-1),d+6>a&&(a=h/(i-(e.offset?.5:1)),l=this.maxHeight-Fo(e.grid)-n.padding-_P(e.title,this.chart.options.font),u=Math.sqrt(d*d+f*f),o=_L(Math.min(Math.asin(ct((c.highest.height+6)/a,-1,1)),Math.asin(ct(l/u,-1,1))-Math.asin(ct(f/u,-1,1)))),o=Math.max(r,Math.min(s,o))),this.labelRotation=o}afterCalculateLabelRotation(){de(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){de(this.options.beforeFit,[this])}fit(){const e={width:0,height:0},{chart:n,options:{ticks:i,title:r,grid:s}}=this,o=this._isVisible(),a=this.isHorizontal();if(o){const l=_P(r,n.options.font);if(a?(e.width=this.maxWidth,e.height=Fo(s)+l):(e.height=this.maxHeight,e.width=Fo(s)+l),i.display&&this.ticks.length){const{first:u,last:c,widest:d,highest:f}=this._getLabelSizes(),h=i.padding*2,g=Gi(this.labelRotation),v=Math.cos(g),b=Math.sin(g);if(a){const p=i.mirror?0:b*d.width+v*f.height;e.height=Math.min(this.maxHeight,e.height+p+h)}else{const p=i.mirror?0:v*d.width+b*f.height;e.width=Math.min(this.maxWidth,e.width+p+h)}this._calculatePadding(u,c,b,v)}}this._handleMargins(),a?(this.width=this._length=n.width-this._margins.left-this._margins.right,this.height=e.height):(this.width=e.width,this.height=this._length=n.height-this._margins.top-this._margins.bottom)}_calculatePadding(e,n,i,r){const{ticks:{align:s,padding:o},position:a}=this.options,l=this.labelRotation!==0,u=a!=="top"&&this.axis==="x";if(this.isHorizontal()){const c=this.getPixelForTick(0)-this.left,d=this.right-this.getPixelForTick(this.ticks.length-1);let f=0,h=0;l?u?(f=r*e.width,h=i*n.height):(f=i*e.height,h=r*n.width):s==="start"?h=n.width:s==="end"?f=e.width:s!=="inner"&&(f=e.width/2,h=n.width/2),this.paddingLeft=Math.max((f-c+o)*this.width/(this.width-c),0),this.paddingRight=Math.max((h-d+o)*this.width/(this.width-d),0)}else{let c=n.height/2,d=e.height/2;s==="start"?(c=0,d=e.height):s==="end"&&(c=n.height,d=0),this.paddingTop=c+o,this.paddingBottom=d+o}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){de(this.options.afterFit,[this])}isHorizontal(){const{axis:e,position:n}=this.options;return n==="top"||n==="bottom"||e==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(e){this.beforeTickToLabelConversion(),this.generateTickLabels(e);let n,i;for(n=0,i=e.length;n({width:o[w]||0,height:a[w]||0});return{first:_(0),last:_(n-1),widest:_(C),highest:_(L),widths:o,heights:a}}getLabelForValue(e){return e}getPixelForValue(e,n){return NaN}getValueForPixel(e){}getPixelForTick(e){const n=this.ticks;return e<0||e>n.length-1?null:this.getPixelForValue(n[e].value)}getPixelForDecimal(e){this._reversePixels&&(e=1-e);const n=this._startPixel+e*this._length;return DL(this._alignToPixels?Zi(this.chart,n,0):n)}getDecimalForPixel(e){const n=(e-this._startPixel)/this._length;return this._reversePixels?1-n:n}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:e,max:n}=this;return e<0&&n<0?n:e>0&&n>0?e:0}getContext(e){const n=this.ticks||[];if(e>=0&&ea*r?a/i:l/r:l*r0}_computeGridLineItems(e){const n=this.axis,i=this.chart,r=this.options,{grid:s,position:o,border:a}=r,l=s.offset,u=this.isHorizontal(),d=this.ticks.length+(l?1:0),f=Fo(s),h=[],g=a.setContext(this.getContext()),v=g.display?g.width:0,b=v/2,p=function(E){return Zi(i,E,v)};let m,y,S,P,C,L,_,w,$,F,T,N;if(o==="top")m=p(this.bottom),L=this.bottom-f,w=m-b,F=p(e.top)+b,N=e.bottom;else if(o==="bottom")m=p(this.top),F=e.top,N=p(e.bottom)-b,L=m+b,w=this.top+f;else if(o==="left")m=p(this.right),C=this.right-f,_=m-b,$=p(e.left)+b,T=e.right;else if(o==="right")m=p(this.left),$=e.left,T=p(e.right)-b,C=m+b,_=this.left+f;else if(n==="x"){if(o==="center")m=p((e.top+e.bottom)/2+.5);else if(re(o)){const E=Object.keys(o)[0],A=o[E];m=p(this.chart.scales[E].getPixelForValue(A))}F=e.top,N=e.bottom,L=m+b,w=L+f}else if(n==="y"){if(o==="center")m=p((e.left+e.right)/2);else if(re(o)){const E=Object.keys(o)[0],A=o[E];m=p(this.chart.scales[E].getPixelForValue(A))}C=m-b,_=C-f,$=e.left,T=e.right}const M=oe(r.ticks.maxTicksLimit,d),O=Math.max(1,Math.ceil(d/M));for(y=0;y0&&(ce-=K/2);break}I={left:ce,top:J,width:K+z.width,height:Q+z.height,color:O.backdropColor}}b.push({label:S,font:w,textOffset:T,options:{rotation:v,color:A,strokeColor:R,strokeWidth:j,textAlign:H,textBaseline:N,translation:[P,C],backdrop:I}})}return b}_getXAxisLabelAlignment(){const{position:e,ticks:n}=this.options;if(-Gi(this.labelRotation))return e==="top"?"left":"right";let r="center";return n.align==="start"?r="left":n.align==="end"?r="right":n.align==="inner"&&(r="inner"),r}_getYAxisLabelAlignment(e){const{position:n,ticks:{crossAlign:i,mirror:r,padding:s}}=this.options,o=this._getLabelSizes(),a=e+s,l=o.widest.width;let u,c;return n==="left"?r?(c=this.right+s,i==="near"?u="left":i==="center"?(u="center",c+=l/2):(u="right",c+=l)):(c=this.right-a,i==="near"?u="right":i==="center"?(u="center",c-=l/2):(u="left",c=this.left)):n==="right"?r?(c=this.left+s,i==="near"?u="right":i==="center"?(u="center",c-=l/2):(u="left",c-=l)):(c=this.left+a,i==="near"?u="left":i==="center"?(u="center",c+=l/2):(u="right",c=this.right)):u="right",{textAlign:u,x:c}}_computeLabelArea(){if(this.options.ticks.mirror)return;const e=this.chart,n=this.options.position;if(n==="left"||n==="right")return{top:0,left:this.left,bottom:e.height,right:this.right};if(n==="top"||n==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:e.width}}drawBackground(){const{ctx:e,options:{backgroundColor:n},left:i,top:r,width:s,height:o}=this;n&&(e.save(),e.fillStyle=n,e.fillRect(i,r,s,o),e.restore())}getLineWidthForValue(e){const n=this.options.grid;if(!this._isVisible()||!n.display)return 0;const r=this.ticks.findIndex(s=>s.value===e);return r>=0?n.setContext(this.getContext(r)).lineWidth:0}drawGrid(e){const n=this.options.grid,i=this.ctx,r=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(e));let s,o;const a=(l,u,c)=>{!c.width||!c.color||(i.save(),i.lineWidth=c.width,i.strokeStyle=c.color,i.setLineDash(c.borderDash||[]),i.lineDashOffset=c.borderDashOffset,i.beginPath(),i.moveTo(l.x,l.y),i.lineTo(u.x,u.y),i.stroke(),i.restore())};if(n.display)for(s=0,o=r.length;s{this.draw(s)}}]:[{z:i,draw:s=>{this.drawBackground(),this.drawGrid(s),this.drawTitle()}},{z:r,draw:()=>{this.drawBorder()}},{z:n,draw:s=>{this.drawLabels(s)}}]}getMatchingVisibleMetas(e){const n=this.chart.getSortedVisibleDatasetMetas(),i=this.axis+"AxisID",r=[];let s,o;for(s=0,o=n.length;s{const i=n.split("."),r=i.pop(),s=[t].concat(i).join("."),o=e[n].split("."),a=o.pop(),l=o.join(".");ke.route(s,r,l,a)})}function M6(t){return"id"in t&&"defaults"in t}class D6{constructor(){this.controllers=new xu(_o,"datasets",!0),this.elements=new xu(mi,"elements"),this.plugins=new xu(Object,"plugins"),this.scales=new xu(ns,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...e){this._each("register",e)}remove(...e){this._each("unregister",e)}addControllers(...e){this._each("register",e,this.controllers)}addElements(...e){this._each("register",e,this.elements)}addPlugins(...e){this._each("register",e,this.plugins)}addScales(...e){this._each("register",e,this.scales)}getController(e){return this._get(e,this.controllers,"controller")}getElement(e){return this._get(e,this.elements,"element")}getPlugin(e){return this._get(e,this.plugins,"plugin")}getScale(e){return this._get(e,this.scales,"scale")}removeControllers(...e){this._each("unregister",e,this.controllers)}removeElements(...e){this._each("unregister",e,this.elements)}removePlugins(...e){this._each("unregister",e,this.plugins)}removeScales(...e){this._each("unregister",e,this.scales)}_each(e,n,i){[...n].forEach(r=>{const s=i||this._getRegistryForType(r);i||s.isForType(r)||s===this.plugins&&r.id?this._exec(e,s,r):le(r,o=>{const a=i||this._getRegistryForType(o);this._exec(e,a,o)})})}_exec(e,n,i){const r=hp(e);de(i["before"+r],[],i),n[e](i),de(i["after"+r],[],i)}_getRegistryForType(e){for(let n=0;ns.filter(a=>!o.some(l=>a.plugin.id===l.plugin.id));this._notify(r(n,i),e,"stop"),this._notify(r(i,n),e,"start")}}function A6(t){const e={},n=[],i=Object.keys(un.plugins.items);for(let s=0;s1&&MP(t[0].toLowerCase());if(i)return i}throw new Error(`Cannot determine type of '${t}' axis. Please provide 'axis' or 'position' option.`)}function DP(t,e,n){if(n[e+"AxisID"]===t)return{axis:e}}function j6(t,e){if(e.data&&e.data.datasets){const n=e.data.datasets.filter(i=>i.xAxisID===t||i.yAxisID===t);if(n.length)return DP(t,"x",n[0])||DP(t,"y",n[0])}return{}}function z6(t,e){const n=qi[t.type]||{scales:{}},i=e.scales||{},r=Vp(t.type,e),s=Object.create(null);return Object.keys(i).forEach(o=>{const a=i[o];if(!re(a))return console.error(`Invalid scale configuration for scale: ${o}`);if(a._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${o}`);const l=jp(o,a,j6(o,t),ke.scales[a.type]),u=O6(l,r),c=n.scales||{};s[o]=Po(Object.create(null),[{axis:l},a,c[l],c[u]])}),t.data.datasets.forEach(o=>{const a=o.type||t.type,l=o.indexAxis||Vp(a,e),c=(qi[a]||{}).scales||{};Object.keys(c).forEach(d=>{const f=N6(d,l),h=o[f+"AxisID"]||f;s[h]=s[h]||Object.create(null),Po(s[h],[{axis:f},i[h],c[d]])})}),Object.keys(s).forEach(o=>{const a=s[o];Po(a,[ke.scales[a.type],ke.scale])}),s}function LP(t){const e=t.options||(t.options={});e.plugins=oe(e.plugins,{}),e.scales=z6(t,e)}function AP(t){return t=t||{},t.datasets=t.datasets||[],t.labels=t.labels||[],t}function B6(t){return t=t||{},t.data=AP(t.data),LP(t),t}const RP=new Map,FP=new Set;function wu(t,e){let n=RP.get(t);return n||(n=e(),RP.set(t,n),FP.add(n)),n}const Io=(t,e,n)=>{const i=qr(e,n);i!==void 0&&t.add(i)};class K6{constructor(e){this._config=B6(e),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(e){this._config.type=e}get data(){return this._config.data}set data(e){this._config.data=AP(e)}get options(){return this._config.options}set options(e){this._config.options=e}get plugins(){return this._config.plugins}update(){const e=this._config;this.clearCache(),LP(e)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(e){return wu(e,()=>[[`datasets.${e}`,""]])}datasetAnimationScopeKeys(e,n){return wu(`${e}.transition.${n}`,()=>[[`datasets.${e}.transitions.${n}`,`transitions.${n}`],[`datasets.${e}`,""]])}datasetElementScopeKeys(e,n){return wu(`${e}-${n}`,()=>[[`datasets.${e}.elements.${n}`,`datasets.${e}`,`elements.${n}`,""]])}pluginScopeKeys(e){const n=e.id,i=this.type;return wu(`${i}-plugin-${n}`,()=>[[`plugins.${n}`,...e.additionalOptionScopes||[]]])}_cachedScopes(e,n){const i=this._scopeCache;let r=i.get(e);return(!r||n)&&(r=new Map,i.set(e,r)),r}getOptionScopes(e,n,i){const{options:r,type:s}=this,o=this._cachedScopes(e,i),a=o.get(n);if(a)return a;const l=new Set;n.forEach(c=>{e&&(l.add(e),c.forEach(d=>Io(l,e,d))),c.forEach(d=>Io(l,r,d)),c.forEach(d=>Io(l,qi[s]||{},d)),c.forEach(d=>Io(l,ke,d)),c.forEach(d=>Io(l,bp,d))});const u=Array.from(l);return u.length===0&&u.push(Object.create(null)),FP.has(n)&&o.set(n,u),u}chartOptionScopes(){const{options:e,type:n}=this;return[e,qi[n]||{},ke.datasets[n]||{},{type:n},ke,bp]}resolveNamedOptions(e,n,i,r=[""]){const s={$shared:!0},{resolver:o,subPrefixes:a}=IP(this._resolverCache,e,r);let l=o;if(W6(o,n)){s.$shared=!1,i=hi(i)?i():i;const u=this.createResolver(e,i,a);l=es(o,i,u)}for(const u of n)s[u]=l[u];return s}createResolver(e,n,i=[""],r){const{resolver:s}=IP(this._resolverCache,e,i);return re(n)?es(s,n,void 0,r):s}}function IP(t,e,n){let i=t.get(e);i||(i=new Map,t.set(e,i));const r=n.join();let s=i.get(r);return s||(s={resolver:Tp(e,n),subPrefixes:n.filter(a=>!a.toLowerCase().includes("hover"))},i.set(r,s)),s}const H6=t=>re(t)&&Object.getOwnPropertyNames(t).some(e=>hi(t[e]));function W6(t,e){const{isScriptable:n,isIndexable:i}=YS(t);for(const r of e){const s=n(r),o=i(r),a=(o||s)&&t[r];if(s&&(hi(a)||H6(a))||o&&_e(a))return!0}return!1}var U6="4.4.5";const Y6=["top","bottom","left","right","chartArea"];function NP(t,e){return t==="top"||t==="bottom"||Y6.indexOf(t)===-1&&e==="x"}function OP(t,e){return function(n,i){return n[t]===i[t]?n[e]-i[e]:n[t]-i[t]}}function VP(t){const e=t.chart,n=e.options.animation;e.notifyPlugins("afterRender"),de(n&&n.onComplete,[t],e)}function G6(t){const e=t.chart,n=e.options.animation;de(n&&n.onProgress,[t],e)}function jP(t){return _p()&&typeof t=="string"?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas),t}const Su={},zP=t=>{const e=jP(t);return Object.values(Su).filter(n=>n.canvas===e).pop()};function X6(t,e,n){const i=Object.keys(t);for(const r of i){const s=+r;if(s>=e){const o=t[r];delete t[r],(n>0||s>e)&&(t[s+n]=o)}}}function Q6(t,e,n,i){return!n||t.type==="mouseout"?null:i?e:t}function Pu(t,e,n){return t.options.clip?t[n]:e[n]}function q6(t,e){const{xScale:n,yScale:i}=t;return n&&i?{left:Pu(n,e,"left"),right:Pu(n,e,"right"),top:Pu(i,e,"top"),bottom:Pu(i,e,"bottom")}:e}let $u=(bi=class{static register(...e){un.add(...e),BP()}static unregister(...e){un.remove(...e),BP()}constructor(e,n){const i=this.config=new K6(n),r=jP(e),s=zP(r);if(s)throw new Error("Canvas is already in use. Chart with ID '"+s.id+"' must be destroyed before the canvas with ID '"+s.canvas.id+"' can be reused.");const o=i.createResolver(i.chartOptionScopes(),this.getContext());this.platform=new(i.platform||p6(r)),this.platform.updateConfig(i);const a=this.platform.acquireContext(r,o.aspectRatio),l=a&&a.canvas,u=l&&l.height,c=l&&l.width;if(this.id=yL(),this.ctx=a,this.canvas=l,this.width=c,this.height=u,this._options=o,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new L6,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=FL(d=>this.update(d),o.resizeDelay||0),this._dataChanges=[],Su[this.id]=this,!a||!l){console.error("Failed to create chart: can't acquire context from the given item");return}Dn.listen(this,"complete",VP),Dn.listen(this,"progress",G6),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:e,maintainAspectRatio:n},width:i,height:r,_aspectRatio:s}=this;return ae(e)?n&&s?s:r?i/r:null:e}get data(){return this.config.data}set data(e){this.config.data=e}get options(){return this._options}set options(e){this.config.options=e}get registry(){return un}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():JS(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return HS(this.canvas,this.ctx),this}stop(){return Dn.stop(this),this}resize(e,n){Dn.running(this)?this._resizeBeforeDraw={width:e,height:n}:this._resize(e,n)}_resize(e,n){const i=this.options,r=this.canvas,s=i.maintainAspectRatio&&this.aspectRatio,o=this.platform.getMaximumSize(r,e,n,s),a=i.devicePixelRatio||this.platform.getDevicePixelRatio(),l=this.width?"resize":"attach";this.width=o.width,this.height=o.height,this._aspectRatio=this.aspectRatio,JS(this,a,!0)&&(this.notifyPlugins("resize",{size:o}),de(i.onResize,[this,o],this),this.attached&&this._doResize(l)&&this.render())}ensureScalesHaveIDs(){const n=this.options.scales||{};le(n,(i,r)=>{i.id=r})}buildOrUpdateScales(){const e=this.options,n=e.scales,i=this.scales,r=Object.keys(i).reduce((o,a)=>(o[a]=!1,o),{});let s=[];n&&(s=s.concat(Object.keys(n).map(o=>{const a=n[o],l=jp(o,a),u=l==="r",c=l==="x";return{options:a,dposition:u?"chartArea":c?"bottom":"left",dtype:u?"radialLinear":c?"category":"linear"}}))),le(s,o=>{const a=o.options,l=a.id,u=jp(l,a),c=oe(a.type,o.dtype);(a.position===void 0||NP(a.position,u)!==NP(o.dposition))&&(a.position=o.dposition),r[l]=!0;let d=null;if(l in i&&i[l].type===c)d=i[l];else{const f=un.getScale(c);d=new f({id:l,type:c,ctx:this.ctx,chart:this}),i[d.id]=d}d.init(a,e)}),le(r,(o,a)=>{o||delete i[a]}),le(i,o=>{Vt.configure(this,o,o.options),Vt.addBox(this,o)})}_updateMetasets(){const e=this._metasets,n=this.data.datasets.length,i=e.length;if(e.sort((r,s)=>r.index-s.index),i>n){for(let r=n;rn.length&&delete this._stacks,e.forEach((i,r)=>{n.filter(s=>s===i._dataset).length===0&&this._destroyDatasetMeta(r)})}buildOrUpdateControllers(){const e=[],n=this.data.datasets;let i,r;for(this._removeUnreferencedMetasets(),i=0,r=n.length;i{this.getDatasetMeta(n).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(e){const n=this.config;n.update();const i=this._options=n.createResolver(n.chartOptionScopes(),this.getContext()),r=this._animationsDisabled=!i.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:e,cancelable:!0})===!1)return;const s=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let o=0;for(let u=0,c=this.data.datasets.length;u{u.reset()}),this._updateDatasets(e),this.notifyPlugins("afterUpdate",{mode:e}),this._layers.sort(OP("z","_idx"));const{_active:a,_lastEvent:l}=this;l?this._eventHandler(l,!0):a.length&&this._updateHoverStyles(a,a,!0),this.render()}_updateScales(){le(this.scales,e=>{Vt.removeBox(this,e)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const e=this.options,n=new Set(Object.keys(this._listeners)),i=new Set(e.events);(!$S(n,i)||!!this._responsiveListeners!==e.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:e}=this,n=this._getUniformDataChanges()||[];for(const{method:i,start:r,count:s}of n){const o=i==="_removeElements"?-s:s;X6(e,r,o)}}_getUniformDataChanges(){const e=this._dataChanges;if(!e||!e.length)return;this._dataChanges=[];const n=this.data.datasets.length,i=s=>new Set(e.filter(o=>o[0]===s).map((o,a)=>a+","+o.splice(1).join(","))),r=i(0);for(let s=1;ss.split(",")).map(s=>({method:s[1],start:+s[2],count:+s[3]}))}_updateLayout(e){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;Vt.update(this,this.width,this.height,e);const n=this.chartArea,i=n.width<=0||n.height<=0;this._layers=[],le(this.boxes,r=>{i&&r.position==="chartArea"||(r.configure&&r.configure(),this._layers.push(...r._layers()))},this),this._layers.forEach((r,s)=>{r._idx=s}),this.notifyPlugins("afterLayout")}_updateDatasets(e){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:e,cancelable:!0})!==!1){for(let n=0,i=this.data.datasets.length;n=0;--n)this._drawDataset(e[n]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(e){const n=this.ctx,i=e._clip,r=!i.disabled,s=q6(e,this.chartArea),o={meta:e,index:e.index,cancelable:!0};this.notifyPlugins("beforeDatasetDraw",o)!==!1&&(r&&Pp(n,{left:i.left===!1?0:s.left-i.left,right:i.right===!1?this.width:s.right+i.right,top:i.top===!1?0:s.top-i.top,bottom:i.bottom===!1?this.height:s.bottom+i.bottom}),e.controller.draw(),r&&$p(n),o.cancelable=!1,this.notifyPlugins("afterDatasetDraw",o))}isPointInArea(e){return Sp(e,this.chartArea,this._minPadding)}getElementsAtEventForMode(e,n,i,r){const s=YA.modes[n];return typeof s=="function"?s(this,e,i,r):[]}getDatasetMeta(e){const n=this.data.datasets[e],i=this._metasets;let r=i.filter(s=>s&&s._dataset===n).pop();return r||(r={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n&&n.order||0,index:e,_dataset:n,_parsed:[],_sorted:!1},i.push(r)),r}getContext(){return this.$context||(this.$context=Jr(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(e){const n=this.data.datasets[e];if(!n)return!1;const i=this.getDatasetMeta(e);return typeof i.hidden=="boolean"?!i.hidden:!n.hidden}setDatasetVisibility(e,n){const i=this.getDatasetMeta(e);i.hidden=!n}toggleDataVisibility(e){this._hiddenIndices[e]=!this._hiddenIndices[e]}getDataVisibility(e){return!this._hiddenIndices[e]}_updateVisibility(e,n,i){const r=i?"show":"hide",s=this.getDatasetMeta(e),o=s.controller._resolveAnimations(void 0,r);$o(n)?(s.data[n].hidden=!i,this.update()):(this.setDatasetVisibility(e,i),o.update(s,{visible:i}),this.update(a=>a.datasetIndex===e?r:void 0))}hide(e,n){this._updateVisibility(e,n,!1)}show(e,n){this._updateVisibility(e,n,!0)}_destroyDatasetMeta(e){const n=this._metasets[e];n&&n.controller&&n.controller._destroy(),delete this._metasets[e]}_stop(){let e,n;for(this.stop(),Dn.remove(this),e=0,n=this.data.datasets.length;e{n.addEventListener(this,s,o),e[s]=o},r=(s,o,a)=>{s.offsetX=o,s.offsetY=a,this._eventHandler(s)};le(this.options.events,s=>i(s,r))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const e=this._responsiveListeners,n=this.platform,i=(l,u)=>{n.addEventListener(this,l,u),e[l]=u},r=(l,u)=>{e[l]&&(n.removeEventListener(this,l,u),delete e[l])},s=(l,u)=>{this.canvas&&this.resize(l,u)};let o;const a=()=>{r("attach",a),this.attached=!0,this.resize(),i("resize",s),i("detach",o)};o=()=>{this.attached=!1,r("resize",s),this._stop(),this._resize(0,0),i("attach",a)},n.isAttached(this.canvas)?a():o()}unbindEvents(){le(this._listeners,(e,n)=>{this.platform.removeEventListener(this,n,e)}),this._listeners={},le(this._responsiveListeners,(e,n)=>{this.platform.removeEventListener(this,n,e)}),this._responsiveListeners=void 0}updateHoverStyle(e,n,i){const r=i?"set":"remove";let s,o,a,l;for(n==="dataset"&&(s=this.getDatasetMeta(e[0].datasetIndex),s.controller["_"+r+"DatasetHoverStyle"]()),a=0,l=e.length;a{const a=this.getDatasetMeta(s);if(!a)throw new Error("No dataset found at index "+s);return{datasetIndex:s,element:a.data[o],index:o}});!su(i,n)&&(this._active=i,this._lastEvent=null,this._updateHoverStyles(i,n))}notifyPlugins(e,n,i){return this._plugins.notify(this,e,n,i)}isPluginEnabled(e){return this._plugins._cache.filter(n=>n.plugin.id===e).length===1}_updateHoverStyles(e,n,i){const r=this.options.hover,s=(l,u)=>l.filter(c=>!u.some(d=>c.datasetIndex===d.datasetIndex&&c.index===d.index)),o=s(n,e),a=i?e:s(e,n);o.length&&this.updateHoverStyle(o,r.mode,!1),a.length&&r.mode&&this.updateHoverStyle(a,r.mode,!0)}_eventHandler(e,n){const i={event:e,replay:n,cancelable:!0,inChartArea:this.isPointInArea(e)},r=o=>(o.options.events||this.options.events).includes(e.native.type);if(this.notifyPlugins("beforeEvent",i,r)===!1)return;const s=this._handleEvent(e,n,i.inChartArea);return i.cancelable=!1,this.notifyPlugins("afterEvent",i,r),(s||i.changed)&&this.render(),this}_handleEvent(e,n,i){const{_active:r=[],options:s}=this,o=n,a=this._getActiveElements(e,r,i,o),l=$L(e),u=Q6(e,this._lastEvent,i,l);i&&(this._lastEvent=null,de(s.onHover,[e,a,this],this),l&&de(s.onClick,[e,a,this],this));const c=!su(a,r);return(c||n)&&(this._active=a,this._updateHoverStyles(a,r,n)),this._lastEvent=u,c}_getActiveElements(e,n,i,r){if(e.type==="mouseout")return[];if(!i)return n;const s=this.options.hover;return this.getElementsAtEventForMode(e,s.mode,s,r)}},G(bi,"defaults",ke),G(bi,"instances",Su),G(bi,"overrides",qi),G(bi,"registry",un),G(bi,"version",U6),G(bi,"getChart",zP),bi);function BP(){return le($u.instances,t=>t._plugins.invalidate())}function Z6(t,e,n){const{startAngle:i,pixelMargin:r,x:s,y:o,outerRadius:a,innerRadius:l}=e;let u=r/a;t.beginPath(),t.arc(s,o,a,i-u,n+u),l>r?(u=r/l,t.arc(s,o,l,n+u,i-u,!0)):t.arc(s,o,r,n+Be,i-Be),t.closePath(),t.clip()}function J6(t){return kp(t,["outerStart","outerEnd","innerStart","innerEnd"])}function eR(t,e,n,i){const r=J6(t.options.borderRadius),s=(n-e)/2,o=Math.min(s,i*e/2),a=l=>{const u=(n-Math.min(s,l))*i/2;return ct(l,0,Math.min(s,u))};return{outerStart:a(r.outerStart),outerEnd:a(r.outerEnd),innerStart:ct(r.innerStart,0,o),innerEnd:ct(r.innerEnd,0,o)}}function is(t,e,n,i){return{x:n+t*Math.cos(e),y:i+t*Math.sin(e)}}function ku(t,e,n,i,r,s){const{x:o,y:a,startAngle:l,pixelMargin:u,innerRadius:c}=e,d=Math.max(e.outerRadius+i+n-u,0),f=c>0?c+i+n+u:0;let h=0;const g=r-l;if(i){const O=c>0?c-i:0,E=d>0?d-i:0,A=(O+E)/2,R=A!==0?g*A/(A+i):g;h=(g-R)/2}const v=Math.max(.001,g*d-n/Ne)/d,b=(g-v)/2,p=l+b+h,m=r-b-h,{outerStart:y,outerEnd:S,innerStart:P,innerEnd:C}=eR(e,f,d,m-p),L=d-y,_=d-S,w=p+y/L,$=m-S/_,F=f+P,T=f+C,N=p+P/F,M=m-C/T;if(t.beginPath(),s){const O=(w+$)/2;if(t.arc(o,a,d,w,O),t.arc(o,a,d,O,$),S>0){const j=is(_,$,o,a);t.arc(j.x,j.y,S,$,m+Be)}const E=is(T,m,o,a);if(t.lineTo(E.x,E.y),C>0){const j=is(T,M,o,a);t.arc(j.x,j.y,C,m+Be,M+Math.PI)}const A=(m-C/f+(p+P/f))/2;if(t.arc(o,a,f,m-C/f,A,!0),t.arc(o,a,f,A,p+P/f,!0),P>0){const j=is(F,N,o,a);t.arc(j.x,j.y,P,N+Math.PI,p-Be)}const R=is(L,p,o,a);if(t.lineTo(R.x,R.y),y>0){const j=is(L,w,o,a);t.arc(j.x,j.y,y,p-Be,w)}}else{t.moveTo(o,a);const O=Math.cos(w)*d+o,E=Math.sin(w)*d+a;t.lineTo(O,E);const A=Math.cos($)*d+o,R=Math.sin($)*d+a;t.lineTo(A,R)}t.closePath()}function tR(t,e,n,i,r){const{fullCircles:s,startAngle:o,circumference:a}=e;let l=e.endAngle;if(s){ku(t,e,n,i,l,r);for(let u=0;u=tt||v,p=Qi(a,c+h,d+h);return b&&p}getCenterPoint(n){const{x:i,y:r,startAngle:s,endAngle:o,innerRadius:a,outerRadius:l}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius"],n),{offset:u,spacing:c}=this.options,d=(s+o)/2,f=(a+l+c+u)/2;return{x:i+Math.cos(d)*f,y:r+Math.sin(d)*f}}tooltipPosition(n){return this.getCenterPoint(n)}draw(n){const{options:i,circumference:r}=this,s=(i.offset||0)/4,o=(i.spacing||0)/2,a=i.circular;if(this.pixelMargin=i.borderAlign==="inner"?.33:0,this.fullCircles=r>tt?Math.floor(r/tt):0,r===0||this.innerRadius<0||this.outerRadius<0)return;n.save();const l=(this.startAngle+this.endAngle)/2;n.translate(Math.cos(l)*s,Math.sin(l)*s);const u=1-Math.sin(Math.min(Ne,r||0)),c=s*u;n.fillStyle=i.backgroundColor,n.strokeStyle=i.borderColor,tR(n,this,c,o,a),nR(n,this,c,o,a),n.restore()}}G(No,"id","arc"),G(No,"defaults",{borderAlign:"center",borderColor:"#fff",borderDash:[],borderDashOffset:0,borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0,circular:!0}),G(No,"defaultRoutes",{backgroundColor:"backgroundColor"}),G(No,"descriptors",{_scriptable:!0,_indexable:n=>n!=="borderDash"});function KP(t,e,n,i){const r=t.options,{[n]:s}=t.getProps([n],i);return Math.abs(e-s){let{boxHeight:n=e,boxWidth:i=e}=t;return t.usePointStyle&&(n=Math.min(n,e),i=t.pointStyleWidth||Math.min(i,e)),{boxWidth:i,boxHeight:n,itemHeight:Math.max(e,n)}},lR=(t,e)=>t!==null&&e!==null&&t.datasetIndex===e.datasetIndex&&t.index===e.index;class UP extends mi{constructor(e){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=e.chart,this.options=e.options,this.ctx=e.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(e,n,i){this.maxWidth=e,this.maxHeight=n,this._margins=i,this.setDimensions(),this.buildLabels(),this.fit()}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height)}buildLabels(){const e=this.options.labels||{};let n=de(e.generateLabels,[this.chart],this)||[];e.filter&&(n=n.filter(i=>e.filter(i,this.chart.data))),e.sort&&(n=n.sort((i,r)=>e.sort(i,r,this.chart.data))),this.options.reverse&&n.reverse(),this.legendItems=n}fit(){const{options:e,ctx:n}=this;if(!e.display){this.width=this.height=0;return}const i=e.labels,r=Ke(i.font),s=r.size,o=this._computeTitleHeight(),{boxWidth:a,itemHeight:l}=WP(i,s);let u,c;n.font=r.string,this.isHorizontal()?(u=this.maxWidth,c=this._fitRows(o,s,a,l)+10):(c=this.maxHeight,u=this._fitCols(o,r,a,l)+10),this.width=Math.min(u,e.maxWidth||this.maxWidth),this.height=Math.min(c,e.maxHeight||this.maxHeight)}_fitRows(e,n,i,r){const{ctx:s,maxWidth:o,options:{labels:{padding:a}}}=this,l=this.legendHitBoxes=[],u=this.lineWidths=[0],c=r+a;let d=e;s.textAlign="left",s.textBaseline="middle";let f=-1,h=-c;return this.legendItems.forEach((g,v)=>{const b=i+n/2+s.measureText(g.text).width;(v===0||u[u.length-1]+b+2*a>o)&&(d+=c,u[u.length-(v>0?0:1)]=0,h+=c,f++),l[v]={left:0,top:h,row:f,width:b,height:r},u[u.length-1]+=b+a}),d}_fitCols(e,n,i,r){const{ctx:s,maxHeight:o,options:{labels:{padding:a}}}=this,l=this.legendHitBoxes=[],u=this.columnSizes=[],c=o-e;let d=a,f=0,h=0,g=0,v=0;return this.legendItems.forEach((b,p)=>{const{itemWidth:m,itemHeight:y}=uR(i,n,s,b,r);p>0&&h+y+2*a>c&&(d+=f+a,u.push({width:f,height:h}),g+=f+a,v++,f=h=0),l[p]={left:g,top:h,col:v,width:m,height:y},f=Math.max(f,m),h+=y+a}),d+=f,u.push({width:f,height:h}),d}adjustHitBoxes(){if(!this.options.display)return;const e=this._computeTitleHeight(),{legendHitBoxes:n,options:{align:i,labels:{padding:r},rtl:s}}=this,o=ts(s,this.left,this.width);if(this.isHorizontal()){let a=0,l=Qe(i,this.left+r,this.right-this.lineWidths[a]);for(const u of n)a!==u.row&&(a=u.row,l=Qe(i,this.left+r,this.right-this.lineWidths[a])),u.top+=this.top+e+r,u.left=o.leftForLtr(o.x(l),u.width),l+=u.width+r}else{let a=0,l=Qe(i,this.top+e+r,this.bottom-this.columnSizes[a].height);for(const u of n)u.col!==a&&(a=u.col,l=Qe(i,this.top+e+r,this.bottom-this.columnSizes[a].height)),u.top=l,u.left+=this.left+r,u.left=o.leftForLtr(o.x(u.left),u.width),l+=u.height+r}}isHorizontal(){return this.options.position==="top"||this.options.position==="bottom"}draw(){if(this.options.display){const e=this.ctx;Pp(e,this),this._draw(),$p(e)}}_draw(){const{options:e,columnSizes:n,lineWidths:i,ctx:r}=this,{align:s,labels:o}=e,a=ke.color,l=ts(e.rtl,this.left,this.width),u=Ke(o.font),{padding:c}=o,d=u.size,f=d/2;let h;this.drawTitle(),r.textAlign=l.textAlign("left"),r.textBaseline="middle",r.lineWidth=.5,r.font=u.string;const{boxWidth:g,boxHeight:v,itemHeight:b}=WP(o,d),p=function(C,L,_){if(isNaN(g)||g<=0||isNaN(v)||v<0)return;r.save();const w=oe(_.lineWidth,1);if(r.fillStyle=oe(_.fillStyle,a),r.lineCap=oe(_.lineCap,"butt"),r.lineDashOffset=oe(_.lineDashOffset,0),r.lineJoin=oe(_.lineJoin,"miter"),r.lineWidth=w,r.strokeStyle=oe(_.strokeStyle,a),r.setLineDash(oe(_.lineDash,[])),o.usePointStyle){const $={radius:v*Math.SQRT2/2,pointStyle:_.pointStyle,rotation:_.rotation,borderWidth:w},F=l.xPlus(C,g/2),T=L+f;WS(r,$,F,T,o.pointStyleWidth&&g)}else{const $=L+Math.max((d-v)/2,0),F=l.leftForLtr(C,g),T=Zr(_.borderRadius);r.beginPath(),Object.values(T).some(N=>N!==0)?du(r,{x:F,y:$,w:g,h:v,radius:T}):r.rect(F,$,g,v),r.fill(),w!==0&&r.stroke()}r.restore()},m=function(C,L,_){Co(r,_.text,C,L+b/2,u,{strikethrough:_.hidden,textAlign:l.textAlign(_.textAlign)})},y=this.isHorizontal(),S=this._computeTitleHeight();y?h={x:Qe(s,this.left+c,this.right-i[0]),y:this.top+c+S,line:0}:h={x:this.left+c,y:Qe(s,this.top+S+c,this.bottom-n[0].height),line:0},tP(this.ctx,e.textDirection);const P=b+c;this.legendItems.forEach((C,L)=>{r.strokeStyle=C.fontColor,r.fillStyle=C.fontColor;const _=r.measureText(C.text).width,w=l.textAlign(C.textAlign||(C.textAlign=o.textAlign)),$=g+f+_;let F=h.x,T=h.y;l.setWidth(this.width),y?L>0&&F+$+c>this.right&&(T=h.y+=P,h.line++,F=h.x=Qe(s,this.left+c,this.right-i[h.line])):L>0&&T+P>this.bottom&&(F=h.x=F+n[h.line].width+c,h.line++,T=h.y=Qe(s,this.top+S+c,this.bottom-n[h.line].height));const N=l.x(F);if(p(N,T,C),F=IL(w,F+g+f,y?F+$:this.right,e.rtl),m(l.x(F),T,C),y)h.x+=$+c;else if(typeof C.text!="string"){const M=u.lineHeight;h.y+=YP(C,M)+c}else h.y+=P}),nP(this.ctx,e.textDirection)}drawTitle(){const e=this.options,n=e.title,i=Ke(n.font),r=Pt(n.padding);if(!n.display)return;const s=ts(e.rtl,this.left,this.width),o=this.ctx,a=n.position,l=i.size/2,u=r.top+l;let c,d=this.left,f=this.width;if(this.isHorizontal())f=Math.max(...this.lineWidths),c=this.top+u,d=Qe(e.align,d,this.right-f);else{const g=this.columnSizes.reduce((v,b)=>Math.max(v,b.height),0);c=u+Qe(e.align,this.top,this.bottom-g-e.labels.padding-this._computeTitleHeight())}const h=Qe(a,d,d+f);o.textAlign=s.textAlign(vp(a)),o.textBaseline="middle",o.strokeStyle=n.color,o.fillStyle=n.color,o.font=i.string,Co(o,n.text,h,c,i)}_computeTitleHeight(){const e=this.options.title,n=Ke(e.font),i=Pt(e.padding);return e.display?n.lineHeight+i.height:0}_getLegendItemAt(e,n){let i,r,s;if(Qi(e,this.left,this.right)&&Qi(n,this.top,this.bottom)){for(s=this.legendHitBoxes,i=0;is.length>o.length?s:o)),e+n.size/2+i.measureText(r).width}function dR(t,e,n){let i=t;return typeof e.text!="string"&&(i=YP(e,n)),i}function YP(t,e){const n=t.text?t.text.length:0;return e*n}function fR(t,e){return!!((t==="mousemove"||t==="mouseout")&&(e.onHover||e.onLeave)||e.onClick&&(t==="click"||t==="mouseup"))}var hR={id:"legend",_element:UP,start(t,e,n){const i=t.legend=new UP({ctx:t.ctx,options:n,chart:t});Vt.configure(t,i,n),Vt.addBox(t,i)},stop(t){Vt.removeBox(t,t.legend),delete t.legend},beforeUpdate(t,e,n){const i=t.legend;Vt.configure(t,i,n),i.options=n},afterUpdate(t){const e=t.legend;e.buildLabels(),e.adjustHitBoxes()},afterEvent(t,e){e.replay||t.legend.handleEvent(e.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(t,e,n){const i=e.datasetIndex,r=n.chart;r.isDatasetVisible(i)?(r.hide(i),e.hidden=!0):(r.show(i),e.hidden=!1)},onHover:null,onLeave:null,labels:{color:t=>t.chart.options.color,boxWidth:40,padding:10,generateLabels(t){const e=t.data.datasets,{labels:{usePointStyle:n,pointStyle:i,textAlign:r,color:s,useBorderRadius:o,borderRadius:a}}=t.legend.options;return t._getSortedDatasetMetas().map(l=>{const u=l.controller.getStyle(n?0:void 0),c=Pt(u.borderWidth);return{text:e[l.index].label,fillStyle:u.backgroundColor,fontColor:s,hidden:!l.visible,lineCap:u.borderCapStyle,lineDash:u.borderDash,lineDashOffset:u.borderDashOffset,lineJoin:u.borderJoinStyle,lineWidth:(c.width+c.height)/4,strokeStyle:u.borderColor,pointStyle:i||u.pointStyle,rotation:u.rotation,textAlign:r||u.textAlign,borderRadius:o&&(a||u.borderRadius),datasetIndex:l.index}},this)}},title:{color:t=>t.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:t=>!t.startsWith("on"),labels:{_scriptable:t=>!["generateLabels","filter","sort"].includes(t)}}};class GP extends mi{constructor(e){super(),this.chart=e.chart,this.options=e.options,this.ctx=e.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(e,n){const i=this.options;if(this.left=0,this.top=0,!i.display){this.width=this.height=this.right=this.bottom=0;return}this.width=this.right=e,this.height=this.bottom=n;const r=_e(i.text)?i.text.length:1;this._padding=Pt(i.padding);const s=r*Ke(i.font).lineHeight+this._padding.height;this.isHorizontal()?this.height=s:this.width=s}isHorizontal(){const e=this.options.position;return e==="top"||e==="bottom"}_drawArgs(e){const{top:n,left:i,bottom:r,right:s,options:o}=this,a=o.align;let l=0,u,c,d;return this.isHorizontal()?(c=Qe(a,i,s),d=n+e,u=s-i):(o.position==="left"?(c=i+e,d=Qe(a,r,n),l=Ne*-.5):(c=s-e,d=Qe(a,n,r),l=Ne*.5),u=r-n),{titleX:c,titleY:d,maxWidth:u,rotation:l}}draw(){const e=this.ctx,n=this.options;if(!n.display)return;const i=Ke(n.font),s=i.lineHeight/2+this._padding.top,{titleX:o,titleY:a,maxWidth:l,rotation:u}=this._drawArgs(s);Co(e,n.text,0,0,i,{color:n.color,maxWidth:l,rotation:u,textAlign:vp(n.align),textBaseline:"middle",translation:[o,a]})}}function pR(t,e){const n=new GP({ctx:t.ctx,options:e,chart:t});Vt.configure(t,n,e),Vt.addBox(t,n),t.titleBlock=n}var mR={id:"title",_element:GP,start(t,e,n){pR(t,n)},stop(t){const e=t.titleBlock;Vt.removeBox(t,e),delete t.titleBlock},beforeUpdate(t,e,n){const i=t.titleBlock;Vt.configure(t,i,n),i.options=n},defaults:{align:"center",display:!1,font:{weight:"bold"},fullSize:!0,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const Vo={average(t){if(!t.length)return!1;let e,n,i=new Set,r=0,s=0;for(e=0,n=t.length;ea+l)/i.size,y:r/s}},nearest(t,e){if(!t.length)return!1;let n=e.x,i=e.y,r=Number.POSITIVE_INFINITY,s,o,a;for(s=0,o=t.length;s-1?t.split(` `):t}function gR(t,e){const{element:n,datasetIndex:i,index:r}=e,s=t.getDatasetMeta(i).controller,{label:o,value:a}=s.getLabelAndValue(r);return{chart:t,label:o,parsed:s.getParsed(r),raw:t.data.datasets[i].data[r],formattedValue:a,dataset:s.getDataset(),dataIndex:r,datasetIndex:i,element:n}}function XP(t,e){const n=t.chart.ctx,{body:i,footer:r,title:s}=t,{boxWidth:o,boxHeight:a}=e,l=Ke(e.bodyFont),u=Ke(e.titleFont),c=Ke(e.footerFont),d=s.length,f=r.length,h=i.length,g=Pt(e.padding);let v=g.height,b=0,p=i.reduce((S,P)=>S+P.before.length+P.lines.length+P.after.length,0);if(p+=t.beforeBody.length+t.afterBody.length,d&&(v+=d*u.lineHeight+(d-1)*e.titleSpacing+e.titleMarginBottom),p){const S=e.displayColors?Math.max(a,l.lineHeight):l.lineHeight;v+=h*S+(p-h)*l.lineHeight+(p-1)*e.bodySpacing}f&&(v+=e.footerMarginTop+f*c.lineHeight+(f-1)*e.footerSpacing);let m=0;const y=function(S){b=Math.max(b,n.measureText(S).width+m)};return n.save(),n.font=u.string,le(t.title,y),n.font=l.string,le(t.beforeBody.concat(t.afterBody),y),m=e.displayColors?o+2+e.boxPadding:0,le(i,S=>{le(S.before,y),le(S.lines,y),le(S.after,y)}),m=0,n.font=c.string,le(t.footer,y),n.restore(),b+=g.width,{width:b,height:v}}function vR(t,e){const{y:n,height:i}=e;return nt.height-i/2?"bottom":"center"}function yR(t,e,n,i){const{x:r,width:s}=i,o=n.caretSize+n.caretPadding;if(t==="left"&&r+s+o>e.width||t==="right"&&r-s-o<0)return!0}function bR(t,e,n,i){const{x:r,width:s}=n,{width:o,chartArea:{left:a,right:l}}=t;let u="center";return i==="center"?u=r<=(a+l)/2?"left":"right":r<=s/2?u="left":r>=o-s/2&&(u="right"),yR(u,t,e,n)&&(u="center"),u}function QP(t,e,n){const i=n.yAlign||e.yAlign||vR(t,n);return{xAlign:n.xAlign||e.xAlign||bR(t,e,n,i),yAlign:i}}function xR(t,e){let{x:n,width:i}=t;return e==="right"?n-=i:e==="center"&&(n-=i/2),n}function wR(t,e,n){let{y:i,height:r}=t;return e==="top"?i+=n:e==="bottom"?i-=r+n:i-=r/2,i}function qP(t,e,n,i){const{caretSize:r,caretPadding:s,cornerRadius:o}=t,{xAlign:a,yAlign:l}=n,u=r+s,{topLeft:c,topRight:d,bottomLeft:f,bottomRight:h}=Zr(o);let g=xR(e,a);const v=wR(e,l,u);return l==="center"?a==="left"?g+=u:a==="right"&&(g-=u):a==="left"?g-=Math.max(c,f)+r:a==="right"&&(g+=Math.max(d,h)+r),{x:ct(g,0,i.width-e.width),y:ct(v,0,i.height-e.height)}}function Cu(t,e,n){const i=Pt(n.padding);return e==="center"?t.x+t.width/2:e==="right"?t.x+t.width-i.right:t.x+i.left}function ZP(t){return cn([],Ln(t))}function SR(t,e,n){return Jr(t,{tooltip:e,tooltipItems:n,type:"tooltip"})}function JP(t,e){const n=e&&e.dataset&&e.dataset.tooltip&&e.dataset.tooltip.callbacks;return n?t.override(n):t}const e$={beforeTitle:Mn,title(t){if(t.length>0){const e=t[0],n=e.chart.data.labels,i=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return e.dataset.label||"";if(e.label)return e.label;if(i>0&&e.dataIndex{const o={before:[],lines:[],after:[]},a=JP(i,s);cn(o.before,Ln(dt(a,"beforeLabel",this,s))),cn(o.lines,dt(a,"label",this,s)),cn(o.after,Ln(dt(a,"afterLabel",this,s))),r.push(o)}),r}getAfterBody(e,n){return ZP(dt(n.callbacks,"afterBody",this,e))}getFooter(e,n){const{callbacks:i}=n,r=dt(i,"beforeFooter",this,e),s=dt(i,"footer",this,e),o=dt(i,"afterFooter",this,e);let a=[];return a=cn(a,Ln(r)),a=cn(a,Ln(s)),a=cn(a,Ln(o)),a}_createItems(e){const n=this._active,i=this.chart.data,r=[],s=[],o=[];let a=[],l,u;for(l=0,u=n.length;le.filter(c,d,f,i))),e.itemSort&&(a=a.sort((c,d)=>e.itemSort(c,d,i))),le(a,c=>{const d=JP(e.callbacks,c);r.push(dt(d,"labelColor",this,c)),s.push(dt(d,"labelPointStyle",this,c)),o.push(dt(d,"labelTextColor",this,c))}),this.labelColors=r,this.labelPointStyles=s,this.labelTextColors=o,this.dataPoints=a,a}update(e,n){const i=this.options.setContext(this.getContext()),r=this._active;let s,o=[];if(!r.length)this.opacity!==0&&(s={opacity:0});else{const a=Vo[i.position].call(this,r,this._eventPosition);o=this._createItems(i),this.title=this.getTitle(o,i),this.beforeBody=this.getBeforeBody(o,i),this.body=this.getBody(o,i),this.afterBody=this.getAfterBody(o,i),this.footer=this.getFooter(o,i);const l=this._size=XP(this,i),u=Object.assign({},a,l),c=QP(this.chart,i,u),d=qP(i,u,c,this.chart);this.xAlign=c.xAlign,this.yAlign=c.yAlign,s={opacity:1,x:d.x,y:d.y,width:l.width,height:l.height,caretX:a.x,caretY:a.y}}this._tooltipItems=o,this.$context=void 0,s&&this._resolveAnimations().update(this,s),e&&i.external&&i.external.call(this,{chart:this.chart,tooltip:this,replay:n})}drawCaret(e,n,i,r){const s=this.getCaretPosition(e,i,r);n.lineTo(s.x1,s.y1),n.lineTo(s.x2,s.y2),n.lineTo(s.x3,s.y3)}getCaretPosition(e,n,i){const{xAlign:r,yAlign:s}=this,{caretSize:o,cornerRadius:a}=i,{topLeft:l,topRight:u,bottomLeft:c,bottomRight:d}=Zr(a),{x:f,y:h}=e,{width:g,height:v}=n;let b,p,m,y,S,P;return s==="center"?(S=h+v/2,r==="left"?(b=f,p=b-o,y=S+o,P=S-o):(b=f+g,p=b+o,y=S-o,P=S+o),m=b):(r==="left"?p=f+Math.max(l,c)+o:r==="right"?p=f+g-Math.max(u,d)-o:p=this.caretX,s==="top"?(y=h,S=y-o,b=p-o,m=p+o):(y=h+v,S=y+o,b=p+o,m=p-o),P=y),{x1:b,x2:p,x3:m,y1:y,y2:S,y3:P}}drawTitle(e,n,i){const r=this.title,s=r.length;let o,a,l;if(s){const u=ts(i.rtl,this.x,this.width);for(e.x=Cu(this,i.titleAlign,i),n.textAlign=u.textAlign(i.titleAlign),n.textBaseline="middle",o=Ke(i.titleFont),a=i.titleSpacing,n.fillStyle=i.titleColor,n.font=o.string,l=0;lm!==0)?(e.beginPath(),e.fillStyle=s.multiKeyBackground,du(e,{x:v,y:g,w:u,h:l,radius:p}),e.fill(),e.stroke(),e.fillStyle=o.backgroundColor,e.beginPath(),du(e,{x:b,y:g+1,w:u-2,h:l-2,radius:p}),e.fill()):(e.fillStyle=s.multiKeyBackground,e.fillRect(v,g,u,l),e.strokeRect(v,g,u,l),e.fillStyle=o.backgroundColor,e.fillRect(b,g+1,u-2,l-2))}e.fillStyle=this.labelTextColors[i]}drawBody(e,n,i){const{body:r}=this,{bodySpacing:s,bodyAlign:o,displayColors:a,boxHeight:l,boxWidth:u,boxPadding:c}=i,d=Ke(i.bodyFont);let f=d.lineHeight,h=0;const g=ts(i.rtl,this.x,this.width),v=function(_){n.fillText(_,g.x(e.x+h),e.y+f/2),e.y+=f+s},b=g.textAlign(o);let p,m,y,S,P,C,L;for(n.textAlign=o,n.textBaseline="middle",n.font=d.string,e.x=Cu(this,b,i),n.fillStyle=i.bodyColor,le(this.beforeBody,v),h=a&&b!=="right"?o==="center"?u/2+c:u+2+c:0,S=0,C=r.length;S0&&n.stroke()}_updateAnimationTarget(e){const n=this.chart,i=this.$animations,r=i&&i.x,s=i&&i.y;if(r||s){const o=Vo[e.position].call(this,this._active,this._eventPosition);if(!o)return;const a=this._size=XP(this,e),l=Object.assign({},o,this._size),u=QP(n,e,l),c=qP(e,l,u,n);(r._to!==c.x||s._to!==c.y)&&(this.xAlign=u.xAlign,this.yAlign=u.yAlign,this.width=a.width,this.height=a.height,this.caretX=o.x,this.caretY=o.y,this._resolveAnimations().update(this,c))}}_willRender(){return!!this.opacity}draw(e){const n=this.options.setContext(this.getContext());let i=this.opacity;if(!i)return;this._updateAnimationTarget(n);const r={width:this.width,height:this.height},s={x:this.x,y:this.y};i=Math.abs(i)<.001?0:i;const o=Pt(n.padding),a=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&a&&(e.save(),e.globalAlpha=i,this.drawBackground(s,e,r,n),tP(e,n.textDirection),s.y+=o.top,this.drawTitle(s,e,n),this.drawBody(s,e,n),this.drawFooter(s,e,n),nP(e,n.textDirection),e.restore())}getActiveElements(){return this._active||[]}setActiveElements(e,n){const i=this._active,r=e.map(({datasetIndex:a,index:l})=>{const u=this.chart.getDatasetMeta(a);if(!u)throw new Error("Cannot find a dataset at index "+a);return{datasetIndex:a,element:u.data[l],index:l}}),s=!su(i,r),o=this._positionChanged(r,n);(s||o)&&(this._active=r,this._eventPosition=n,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(e,n,i=!0){if(n&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const r=this.options,s=this._active||[],o=this._getActiveElements(e,s,n,i),a=this._positionChanged(o,e),l=n||!su(o,s)||a;return l&&(this._active=o,(r.enabled||r.external)&&(this._eventPosition={x:e.x,y:e.y},this.update(!0,n))),l}_getActiveElements(e,n,i,r){const s=this.options;if(e.type==="mouseout")return[];if(!r)return n.filter(a=>this.chart.data.datasets[a.datasetIndex]&&this.chart.getDatasetMeta(a.datasetIndex).controller.getParsed(a.index)!==void 0);const o=this.chart.getElementsAtEventForMode(e,s.mode,s,i);return s.reverse&&o.reverse(),o}_positionChanged(e,n){const{caretX:i,caretY:r,options:s}=this,o=Vo[s.position].call(this,e,n);return o!==!1&&(i!==o.x||r!==o.y)}}G(Kp,"positioners",Vo);var PR={id:"tooltip",_element:Kp,positioners:Vo,afterInit(t,e,n){n&&(t.tooltip=new Kp({chart:t,options:n}))},beforeUpdate(t,e,n){t.tooltip&&t.tooltip.initialize(n)},reset(t,e,n){t.tooltip&&t.tooltip.initialize(n)},afterDraw(t){const e=t.tooltip;if(e&&e._willRender()){const n={tooltip:e};if(t.notifyPlugins("beforeTooltipDraw",V(k({},n),{cancelable:!0}))===!1)return;e.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",n)}},afterEvent(t,e){if(t.tooltip){const n=e.replay;t.tooltip.handleEvent(e.event,n,e.inChartArea)&&(e.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,e)=>e.bodyFont.size,boxWidth:(t,e)=>e.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:e$},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:t=>t!=="filter"&&t!=="itemSort"&&t!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};const $R=(t,e,n,i)=>(typeof e=="string"?(n=t.push(e)-1,i.unshift({index:n,label:e})):isNaN(e)&&(n=null),n);function kR(t,e,n,i){const r=t.indexOf(e);if(r===-1)return $R(t,e,n,i);const s=t.lastIndexOf(e);return r!==s?n:r}const TR=(t,e)=>t===null?null:ct(Math.round(t),0,e);function t$(t){const e=this.getLabels();return t>=0&&tn.length-1?null:this.getPixelForValue(n[e].value)}getValueForPixel(e){return Math.round(this._startValue+this.getDecimalForPixel(e)*this._valueRange)}getBasePixel(){return this.bottom}}G(Hp,"id","category"),G(Hp,"defaults",{ticks:{callback:t$}});function CR(t,e){const n=[],{bounds:r,step:s,min:o,max:a,precision:l,count:u,maxTicks:c,maxDigits:d,includeBounds:f}=t,h=s||1,g=c-1,{min:v,max:b}=e,p=!ae(o),m=!ae(a),y=!ae(u),S=(b-v)/(d+1);let P=TS((b-v)/g/h)*h,C,L,_,w;if(P<1e-14&&!p&&!m)return[{value:v},{value:b}];w=Math.ceil(b/P)-Math.floor(v/P),w>g&&(P=TS(w*P/g/h)*h),ae(l)||(C=Math.pow(10,l),P=Math.ceil(P*C)/C),r==="ticks"?(L=Math.floor(v/P)*P,_=Math.ceil(b/P)*P):(L=v,_=b),p&&m&&s&&CL((a-o)/s,P/1e3)?(w=Math.round(Math.min((a-o)/P,c)),P=(a-o)/w,L=o,_=a):y?(L=p?o:L,_=m?a:_,w=u-1,P=(_-L)/w):(w=(_-L)/P,lu(w,Math.round(w),P/1e3)?w=Math.round(w):w=Math.ceil(w));const $=Math.max(CS(P),CS(L));C=Math.pow(10,ae(l)?$:l),L=Math.round(L*C)/C,_=Math.round(_*C)/C;let F=0;for(p&&(f&&L!==o?(n.push({value:o}),La)break;n.push({value:T})}return m&&f&&_!==a?n.length&&lu(n[n.length-1].value,a,n$(a,S,t))?n[n.length-1].value=a:n.push({value:a}):(!m||_===a)&&n.push({value:_}),n}function n$(t,e,{horizontal:n,minRotation:i}){const r=Gi(i),s=(n?Math.sin(r):Math.cos(r))||.001,o=.75*e*(""+t).length;return Math.min(e/s,o)}class ER extends ns{constructor(e){super(e),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(e,n){return ae(e)||(typeof e=="number"||e instanceof Number)&&!isFinite(+e)?null:+e}handleTickRangeOptions(){const{beginAtZero:e}=this.options,{minDefined:n,maxDefined:i}=this.getUserBounds();let{min:r,max:s}=this;const o=l=>r=n?r:l,a=l=>s=i?s:l;if(e){const l=pi(r),u=pi(s);l<0&&u<0?a(0):l>0&&u>0&&o(0)}if(r===s){let l=s===0?1:Math.abs(s*.05);a(s+l),e||o(r-l)}this.min=r,this.max=s}getTickLimit(){const e=this.options.ticks;let{maxTicksLimit:n,stepSize:i}=e,r;return i?(r=Math.ceil(this.max/i)-Math.floor(this.min/i)+1,r>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${i} would result generating up to ${r} ticks. Limiting to 1000.`),r=1e3)):(r=this.computeTickLimit(),n=n||11),n&&(r=Math.min(n,r)),r}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const e=this.options,n=e.ticks;let i=this.getTickLimit();i=Math.max(2,i);const r={maxTicks:i,bounds:e.bounds,min:e.min,max:e.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==!1},s=this._range||this,o=CR(r,s);return e.bounds==="ticks"&&EL(o,this,"value"),e.reverse?(o.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),o}configure(){const e=this.ticks;let n=this.min,i=this.max;if(super.configure(),this.options.offset&&e.length){const r=(i-n)/Math.max(e.length-1,1)/2;n-=r,i+=r}this._startValue=n,this._endValue=i,this._valueRange=i-n}getLabelForValue(e){return jS(e,this.chart.options.locale,this.options.ticks.format)}}class Wp extends ER{determineDataLimits(){const{min:e,max:n}=this.getMinMax(!0);this.min=Ot(e)?e:0,this.max=Ot(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const e=this.isHorizontal(),n=e?this.width:this.height,i=Gi(this.options.ticks.minRotation),r=(e?Math.sin(i):Math.cos(i))||.001,s=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,s.lineHeight/r))}getPixelForValue(e){return e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getValueForPixel(e){return this._startValue+this.getDecimalForPixel(e)*this._valueRange}}G(Wp,"id","linear"),G(Wp,"defaults",{ticks:{callback:BS.formatters.numeric}});const Eu={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},ft=Object.keys(Eu);function i$(t,e){return t-e}function r$(t,e){if(ae(e))return null;const n=t._adapter,{parser:i,round:r,isoWeekday:s}=t._parseOpts;let o=e;return typeof i=="function"&&(o=i(o)),Ot(o)||(o=typeof i=="string"?n.parse(o,i):n.parse(o)),o===null?null:(r&&(o=r==="week"&&(uu(s)||s===!0)?n.startOf(o,"isoWeek",s):n.startOf(o,r)),+o)}function s$(t,e,n,i){const r=ft.length;for(let s=ft.indexOf(t);s=ft.indexOf(n);s--){const o=ft[s];if(Eu[o].common&&t._adapter.diff(r,i,o)>=e-1)return o}return ft[n?ft.indexOf(n):0]}function MR(t){for(let e=ft.indexOf(t)+1,n=ft.length;e=e?n[i]:n[r];t[s]=!0}}function DR(t,e,n,i){const r=t._adapter,s=+r.startOf(e[0].value,i),o=e[e.length-1].value;let a,l;for(a=s;a<=o;a=+r.add(a,1,i))l=n[a],l>=0&&(e[l].major=!0);return e}function a$(t,e,n){const i=[],r={},s=e.length;let o,a;for(o=0;o+e.value))}initOffsets(e=[]){let n=0,i=0,r,s;this.options.offset&&e.length&&(r=this.getDecimalForValue(e[0]),e.length===1?n=1-r:n=(this.getDecimalForValue(e[1])-r)/2,s=this.getDecimalForValue(e[e.length-1]),e.length===1?i=s:i=(s-this.getDecimalForValue(e[e.length-2]))/2);const o=e.length<3?.5:.25;n=ct(n,0,o),i=ct(i,0,o),this._offsets={start:n,end:i,factor:1/(n+1+i)}}_generate(){const e=this._adapter,n=this.min,i=this.max,r=this.options,s=r.time,o=s.unit||s$(s.minUnit,n,i,this._getLabelCapacity(n)),a=oe(r.ticks.stepSize,1),l=o==="week"?s.isoWeekday:!1,u=uu(l)||l===!0,c={};let d=n,f,h;if(u&&(d=+e.startOf(d,"isoWeek",l)),d=+e.startOf(d,u?"day":o),e.diff(i,n,o)>1e5*a)throw new Error(n+" and "+i+" are too far apart with stepSize of "+a+" "+o);const g=r.ticks.source==="data"&&this.getDataTimestamps();for(f=d,h=0;f+v)}getLabelForValue(e){const n=this._adapter,i=this.options.time;return i.tooltipFormat?n.format(e,i.tooltipFormat):n.format(e,i.displayFormats.datetime)}format(e,n){const r=this.options.time.displayFormats,s=this._unit,o=n||r[s];return this._adapter.format(e,o)}_tickFormatFunction(e,n,i,r){const s=this.options,o=s.ticks.callback;if(o)return de(o,[e,n,i],this);const a=s.time.displayFormats,l=this._unit,u=this._majorUnit,c=l&&a[l],d=u&&a[u],f=i[n],h=u&&d&&f&&f.major;return this._adapter.format(e,r||(h?d:c))}generateTickLabels(e){let n,i,r;for(n=0,i=e.length;n0?a:1}getDataTimestamps(){let e=this._cache.data||[],n,i;if(e.length)return e;const r=this.getMatchingVisibleMetas();if(this._normalized&&r.length)return this._cache.data=r[0].controller.getAllParsedValues(this);for(n=0,i=r.length;n=t[i].pos&&e<=t[r].pos&&({lo:i,hi:r}=gp(t,"pos",e)),{pos:s,time:a}=t[i],{pos:o,time:l}=t[r]):(e>=t[i].time&&e<=t[r].time&&({lo:i,hi:r}=gp(t,"time",e)),{time:s,pos:a}=t[i],{time:o,pos:l}=t[r]);const u=o-s;return u?a+(l-a)*(e-s)/u:a}class l$ extends _u{constructor(e){super(e),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const e=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(e);this._minPos=Mu(n,this.min),this._tableRange=Mu(n,this.max)-this._minPos,super.initOffsets(e)}buildLookupTable(e){const{min:n,max:i}=this,r=[],s=[];let o,a,l,u,c;for(o=0,a=e.length;o=n&&u<=i&&r.push(u);if(r.length<2)return[{time:n,pos:0},{time:i,pos:1}];for(o=0,a=r.length;or-s)}_getTimestampsForTable(){let e=this._cache.all||[];if(e.length)return e;const n=this.getDataTimestamps(),i=this.getLabelTimestamps();return n.length&&i.length?e=this.normalize(n.concat(i)):e=n.length?n:i,e=this._cache.all=e,e}getDecimalForValue(e){return(Mu(this._table,e)-this._minPos)/this._tableRange}getValueForPixel(e){const n=this._offsets,i=this.getDecimalForPixel(e)/n.factor-n.end;return Mu(this._table,i*this._tableRange+this._minPos,!0)}}G(l$,"id","timeseries"),G(l$,"defaults",_u.defaults);const u$="label";function c$(t,e){typeof t=="function"?t(e):t&&(t.current=e)}function LR(t,e){const n=t.options;n&&e&&Object.assign(n,e)}function d$(t,e){t.labels=e}function f$(t,e){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:u$;const i=[];t.datasets=e.map(r=>{const s=t.datasets.find(o=>o[n]===r[n]);return!s||!r.data||i.includes(s)?k({},r):(i.push(s),Object.assign(s,r),s)})}function AR(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:u$;const n={labels:[],datasets:[]};return d$(n,t.labels),f$(n,t.datasets,e),n}function RR(t,e){const p=t,{height:n=150,width:i=300,redraw:r=!1,datasetIdKey:s,type:o,data:a,options:l,plugins:u=[],fallbackContent:c,updateMode:d}=p,f=ee(p,["height","width","redraw","datasetIdKey","type","data","options","plugins","fallbackContent","updateMode"]),h=x.useRef(null),g=x.useRef(),v=()=>{h.current&&(g.current=new $u(h.current,{type:o,data:AR(a,s),options:l&&k({},l),plugins:u}),c$(e,g.current))},b=()=>{c$(e,null),g.current&&(g.current.destroy(),g.current=null)};return x.useEffect(()=>{!r&&g.current&&l&&LR(g.current,l)},[r,l]),x.useEffect(()=>{!r&&g.current&&d$(g.current.config.data,a.labels)},[r,a.labels]),x.useEffect(()=>{!r&&g.current&&a.datasets&&f$(g.current.config.data,a.datasets,s)},[r,a.datasets]),x.useEffect(()=>{g.current&&(r?(b(),setTimeout(v)):g.current.update(d))},[r,l,a.labels,a.datasets,d]),x.useEffect(()=>{g.current&&(b(),setTimeout(v))},[o]),x.useEffect(()=>(v(),()=>b()),[]),W.createElement("canvas",Object.assign({ref:h,role:"img",height:n,width:i},f),c)}const FR=x.forwardRef(RR);function IR(t,e){return $u.register(e),x.forwardRef((n,i)=>W.createElement(FR,Object.assign({},n,{ref:i,type:t})))}const NR=IR("bar",mu);/*! * chartjs-plugin-datalabels v2.2.0 * https://chartjs-plugin-datalabels.netlify.app * (c) 2017-2022 chartjs-plugin-datalabels contributors * Released under the MIT license */var h$=function(){if(typeof window!="undefined"){if(window.devicePixelRatio)return window.devicePixelRatio;var t=window.screen;if(t)return(t.deviceXDPI||1)/(t.logicalXDPI||1)}return 1}(),jo={toTextLines:function(t){var e=[],n;for(t=[].concat(t);t.length;)n=t.pop(),typeof n=="string"?e.unshift.apply(e,n.split(` `)):Array.isArray(n)?t.push.apply(t,n):ae(t)||e.unshift(""+n);return e},textSize:function(t,e,n){var i=[].concat(e),r=i.length,s=t.font,o=0,a;for(t.font=n.string,a=0;an.right&&(i|=m$),en.bottom&&(i|=g$),i}function jR(t,e){for(var n=t.x0,i=t.y0,r=t.x1,s=t.y1,o=Du(n,i,e),a=Du(r,s,e),l,u,c;!(!(o|a)||o&a);)l=o||a,l&v$?(u=n+(r-n)*(e.top-i)/(s-i),c=e.top):l&g$?(u=n+(r-n)*(e.bottom-i)/(s-i),c=e.bottom):l&m$?(c=i+(s-i)*(e.right-n)/(r-n),u=e.right):l&p$&&(c=i+(s-i)*(e.left-n)/(r-n),u=e.left),l===o?(n=u,i=c,o=Du(n,i,e)):(r=u,s=c,a=Du(r,s,e));return{x0:n,x1:r,y0:i,y1:s}}function Lu(t,e){var n=e.anchor,i=t,r,s;return e.clamp&&(i=jR(i,e.area)),n==="start"?(r=i.x0,s=i.y0):n==="end"?(r=i.x1,s=i.y1):(r=(i.x0+i.x1)/2,s=(i.y0+i.y1)/2),OR(r,s,t.vx,t.vy,e.align)}var Au={arc:function(t,e){var n=(t.startAngle+t.endAngle)/2,i=Math.cos(n),r=Math.sin(n),s=t.innerRadius,o=t.outerRadius;return Lu({x0:t.x+i*s,y0:t.y+r*s,x1:t.x+i*o,y1:t.y+r*o,vx:i,vy:r},e)},point:function(t,e){var n=Up(t,e.origin),i=n.x*t.options.radius,r=n.y*t.options.radius;return Lu({x0:t.x-i,y0:t.y-r,x1:t.x+i,y1:t.y+r,vx:n.x,vy:n.y},e)},bar:function(t,e){var n=Up(t,e.origin),i=t.x,r=t.y,s=0,o=0;return t.horizontal?(i=Math.min(t.x,t.base),s=Math.abs(t.base-t.x)):(r=Math.min(t.y,t.base),o=Math.abs(t.base-t.y)),Lu({x0:i,y0:r+o,x1:i+s,y1:r,vx:n.x,vy:n.y},e)},fallback:function(t,e){var n=Up(t,e.origin);return Lu({x0:t.x,y0:t.y,x1:t.x+(t.width||0),y1:t.y+(t.height||0),vx:n.x,vy:n.y},e)}},An=jo.rasterize;function zR(t){var e=t.borderWidth||0,n=t.padding,i=t.size.height,r=t.size.width,s=-r/2,o=-i/2;return{frame:{x:s-n.left-e,y:o-n.top-e,w:r+n.width+e*2,h:i+n.height+e*2},text:{x:s,y:o,w:r,h:i}}}function BR(t,e){var n=e.chart.getDatasetMeta(e.datasetIndex).vScale;if(!n)return null;if(n.xCenter!==void 0&&n.yCenter!==void 0)return{x:n.xCenter,y:n.yCenter};var i=n.getBasePixel();return t.horizontal?{x:i,y:null}:{x:null,y:i}}function KR(t){return t instanceof No?Au.arc:t instanceof Tu?Au.point:t instanceof Oo?Au.bar:Au.fallback}function HR(t,e,n,i,r,s){var o=Math.PI/2;if(s){var a=Math.min(s,r/2,i/2),l=e+a,u=n+a,c=e+i-a,d=n+r-a;t.moveTo(e,u),li.x+i.w+n*2||t.y>i.y+i.h+n*2)},intersects:function(t){var e=this._points(),n=t._points(),i=[Ru(e[0],e[1]),Ru(e[0],e[3])],r,s,o;for(this._rotation!==t._rotation&&i.push(Ru(n[0],n[1]),Ru(n[0],n[3])),r=0;r=0;--n)for(r=t[n].$layout,i=n-1;i>=0&&r._visible;--i)s=t[i].$layout,s._visible&&r._box.intersects(s._box)&&e(r,s);return t}function ZR(t){var e,n,i,r,s,o,a;for(e=0,n=t.length;el.getProps([u],!0)[u]}),s=i.geometry(),o=w$(a,i.model(),s),r._box.update(o,s,i.rotation()));return qR(t,function(l,u){var c=l._hidable,d=u._hidable;c&&d||d?u._visible=!1:c&&(l._visible=!1)})}var Bo={prepare:function(t){var e=[],n,i,r,s,o;for(n=0,r=t.length;n=0;--n)if(i=t[n].$layout,i&&i._visible&&i._box.contains(e))return t[n];return null},draw:function(t,e){var n,i,r,s,o,a;for(n=0,i=e.length;n{const o=()=>{i(window.innerWidth)};return window.addEventListener("resize",o),()=>{window.removeEventListener("resize",o)}},[]);const r={labels:t.slice(0,4).map(o=>o.year),datasets:[{label:"Agent-related cost*",data:t.slice(0,4).map(o=>o.serviceRepCost),backgroundColor:"#F0F3FC"},{label:"Agentforce cost**",data:t.slice(0,4).map(o=>o.cost),backgroundColor:"#4864D2"},{label:"Net Savings",data:t.slice(0,4).map(o=>o.savings),backgroundColor:"#C8D4F8"}]},s={indexAxis:"y",plugins:{title:{display:!1,text:"Stacked Bar Chart"},legend:{position:"bottom",labels:{color:"#000000",font:{size:12,family:"Salesforce Sans"}}},tooltip:{enabled:!1},datalabels:{display:!(n<768),color:"#3651C0",anchor:"middle",font:{weight:"bold",size:n<1024?10:16},align:"middle",formatter:(o,a)=>a.dataset.label==="Net Savings"&&o!==0?`$${o.toLocaleString()}`:null}},elements:{bar:{borderRadius:0,barPercentage:1}},responsive:!0,maintainAspectRatio:!1,scales:{x:{stacked:!0,grid:{display:!0,drawTicks:!0,color:"#fff",tickColor:"#D9D9D9"},title:{display:!0,text:"Potential annual cost without Agentforce",color:"#333",align:"start",padding:{top:10,bottom:10},font:{size:12,family:"Salesforce Sans"}},suggestedMax:0},y:{stacked:!0,grid:{display:!1}}}};return D.jsx(NR,{data:r,options:s,"aria-label":e})}var P$=t=>typeof t=="boolean"?`${t}`:t===0?"0":t,pt=t=>!t||typeof t!="object"||Object.keys(t).length===0,aF=(t,e)=>JSON.stringify(t)===JSON.stringify(e);function $$(t,e){t.forEach(function(n){Array.isArray(n)?$$(n,e):e.push(n)})}function k$(t){let e=[];return $$(t,e),e}var T$=(...t)=>k$(t).filter(Boolean),C$=(t,e)=>{let n={},i=Object.keys(t),r=Object.keys(e);for(let s of i)if(r.includes(s)){let o=t[s],a=e[s];typeof o=="object"&&typeof a=="object"?n[s]=C$(o,a):Array.isArray(o)||Array.isArray(a)?n[s]=T$(a,o):n[s]=a+" "+o}else n[s]=t[s];for(let s of r)i.includes(s)||(n[s]=e[s]);return n},E$=t=>!t||typeof t!="string"?t:t.replace(/\s+/g," ").trim();const Gp="-",lF=t=>{const e=cF(t),{conflictingClassGroups:n,conflictingClassGroupModifiers:i}=t;return{getClassGroupId:o=>{const a=o.split(Gp);return a[0]===""&&a.length!==1&&a.shift(),_$(a,e)||uF(o)},getConflictingClassGroupIds:(o,a)=>{const l=n[o]||[];return a&&i[o]?[...l,...i[o]]:l}}},_$=(t,e)=>{var o;if(t.length===0)return e.classGroupId;const n=t[0],i=e.nextPart.get(n),r=i?_$(t.slice(1),i):void 0;if(r)return r;if(e.validators.length===0)return;const s=t.join(Gp);return(o=e.validators.find(({validator:a})=>a(s)))==null?void 0:o.classGroupId},M$=/^\[(.+)\]$/,uF=t=>{if(M$.test(t)){const e=M$.exec(t)[1],n=e==null?void 0:e.substring(0,e.indexOf(":"));if(n)return"arbitrary.."+n}},cF=t=>{const{theme:e,prefix:n}=t,i={nextPart:new Map,validators:[]};return fF(Object.entries(t.classGroups),n).forEach(([s,o])=>{Xp(o,i,s,e)}),i},Xp=(t,e,n,i)=>{t.forEach(r=>{if(typeof r=="string"){const s=r===""?e:D$(e,r);s.classGroupId=n;return}if(typeof r=="function"){if(dF(r)){Xp(r(i),e,n,i);return}e.validators.push({validator:r,classGroupId:n});return}Object.entries(r).forEach(([s,o])=>{Xp(o,D$(e,s),n,i)})})},D$=(t,e)=>{let n=t;return e.split(Gp).forEach(i=>{n.nextPart.has(i)||n.nextPart.set(i,{nextPart:new Map,validators:[]}),n=n.nextPart.get(i)}),n},dF=t=>t.isThemeGetter,fF=(t,e)=>e?t.map(([n,i])=>{const r=i.map(s=>typeof s=="string"?e+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([o,a])=>[e+o,a])):s);return[n,r]}):t,hF=t=>{if(t<1)return{get:()=>{},set:()=>{}};let e=0,n=new Map,i=new Map;const r=(s,o)=>{n.set(s,o),e++,e>t&&(e=0,i=n,n=new Map)};return{get(s){let o=n.get(s);if(o!==void 0)return o;if((o=i.get(s))!==void 0)return r(s,o),o},set(s,o){n.has(s)?n.set(s,o):r(s,o)}}},L$="!",pF=t=>{const{separator:e,experimentalParseClassName:n}=t,i=e.length===1,r=e[0],s=e.length,o=a=>{const l=[];let u=0,c=0,d;for(let b=0;bc?d-c:void 0;return{modifiers:l,hasImportantModifier:h,baseClassName:g,maybePostfixModifierPosition:v}};return n?a=>n({className:a,parseClassName:o}):o},mF=t=>{if(t.length<=1)return t;const e=[];let n=[];return t.forEach(i=>{i[0]==="["?(e.push(...n.sort(),i),n=[]):n.push(i)}),e.push(...n.sort()),e},gF=t=>k({cache:hF(t.cacheSize),parseClassName:pF(t)},lF(t)),vF=/\s+/,yF=(t,e)=>{const{parseClassName:n,getClassGroupId:i,getConflictingClassGroupIds:r}=e,s=[],o=t.trim().split(vF);let a="";for(let l=o.length-1;l>=0;l-=1){const u=o[l],{modifiers:c,hasImportantModifier:d,baseClassName:f,maybePostfixModifierPosition:h}=n(u);let g=!!h,v=i(g?f.substring(0,h):f);if(!v){if(!g){a=u+(a.length>0?" "+a:a);continue}if(v=i(f),!v){a=u+(a.length>0?" "+a:a);continue}g=!1}const b=mF(c).join(":"),p=d?b+L$:b,m=p+v;if(s.includes(m))continue;s.push(m);const y=r(v,g);for(let S=0;S0?" "+a:a)}return a};function bF(){let t=0,e,n,i="";for(;t{if(typeof t=="string")return t;let e,n="";for(let i=0;id(c),t());return n=gF(u),i=n.cache.get,r=n.cache.set,s=a,a(l)}function a(l){const u=i(l);if(u)return u;const c=yF(l,n);return r(l,c),c}return function(){return s(bF.apply(null,arguments))}}const ve=t=>{const e=n=>n[t]||[];return e.isThemeGetter=!0,e},R$=/^\[(?:([a-z-]+):)?(.+)\]$/i,xF=/^\d+\/\d+$/,wF=new Set(["px","full","screen"]),SF=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,PF=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,$F=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,kF=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,TF=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Rn=t=>rs(t)||wF.has(t)||xF.test(t),vi=t=>ss(t,"length",RF),rs=t=>!!t&&!Number.isNaN(Number(t)),qp=t=>ss(t,"number",rs),Ko=t=>!!t&&Number.isInteger(Number(t)),CF=t=>t.endsWith("%")&&rs(t.slice(0,-1)),q=t=>R$.test(t),yi=t=>SF.test(t),EF=new Set(["length","size","percentage"]),_F=t=>ss(t,EF,F$),MF=t=>ss(t,"position",F$),DF=new Set(["image","url"]),LF=t=>ss(t,DF,IF),AF=t=>ss(t,"",FF),Ho=()=>!0,ss=(t,e,n)=>{const i=R$.exec(t);return i?i[1]?typeof e=="string"?i[1]===e:e.has(i[1]):n(i[2]):!1},RF=t=>PF.test(t)&&!$F.test(t),F$=()=>!1,FF=t=>kF.test(t),IF=t=>TF.test(t),Zp=()=>{const t=ve("colors"),e=ve("spacing"),n=ve("blur"),i=ve("brightness"),r=ve("borderColor"),s=ve("borderRadius"),o=ve("borderSpacing"),a=ve("borderWidth"),l=ve("contrast"),u=ve("grayscale"),c=ve("hueRotate"),d=ve("invert"),f=ve("gap"),h=ve("gradientColorStops"),g=ve("gradientColorStopPositions"),v=ve("inset"),b=ve("margin"),p=ve("opacity"),m=ve("padding"),y=ve("saturate"),S=ve("scale"),P=ve("sepia"),C=ve("skew"),L=ve("space"),_=ve("translate"),w=()=>["auto","contain","none"],$=()=>["auto","hidden","clip","visible","scroll"],F=()=>["auto",q,e],T=()=>[q,e],N=()=>["",Rn,vi],M=()=>["auto",rs,q],O=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],E=()=>["solid","dashed","dotted","double","none"],A=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],R=()=>["start","end","center","between","around","evenly","stretch"],j=()=>["","0",q],H=()=>["auto","avoid","all","avoid-page","page","left","right","column"],I=()=>[rs,q];return{cacheSize:500,separator:":",theme:{colors:[Ho],spacing:[Rn,vi],blur:["none","",yi,q],brightness:I(),borderColor:[t],borderRadius:["none","","full",yi,q],borderSpacing:T(),borderWidth:N(),contrast:I(),grayscale:j(),hueRotate:I(),invert:j(),gap:T(),gradientColorStops:[t],gradientColorStopPositions:[CF,vi],inset:F(),margin:F(),opacity:I(),padding:T(),saturate:I(),scale:I(),sepia:j(),skew:I(),space:T(),translate:T()},classGroups:{aspect:[{aspect:["auto","square","video",q]}],container:["container"],columns:[{columns:[yi]}],"break-after":[{"break-after":H()}],"break-before":[{"break-before":H()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...O(),q]}],overflow:[{overflow:$()}],"overflow-x":[{"overflow-x":$()}],"overflow-y":[{"overflow-y":$()}],overscroll:[{overscroll:w()}],"overscroll-x":[{"overscroll-x":w()}],"overscroll-y":[{"overscroll-y":w()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[v]}],"inset-x":[{"inset-x":[v]}],"inset-y":[{"inset-y":[v]}],start:[{start:[v]}],end:[{end:[v]}],top:[{top:[v]}],right:[{right:[v]}],bottom:[{bottom:[v]}],left:[{left:[v]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Ko,q]}],basis:[{basis:F()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",q]}],grow:[{grow:j()}],shrink:[{shrink:j()}],order:[{order:["first","last","none",Ko,q]}],"grid-cols":[{"grid-cols":[Ho]}],"col-start-end":[{col:["auto",{span:["full",Ko,q]},q]}],"col-start":[{"col-start":M()}],"col-end":[{"col-end":M()}],"grid-rows":[{"grid-rows":[Ho]}],"row-start-end":[{row:["auto",{span:[Ko,q]},q]}],"row-start":[{"row-start":M()}],"row-end":[{"row-end":M()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",q]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",q]}],gap:[{gap:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"justify-content":[{justify:["normal",...R()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...R(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...R(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[m]}],px:[{px:[m]}],py:[{py:[m]}],ps:[{ps:[m]}],pe:[{pe:[m]}],pt:[{pt:[m]}],pr:[{pr:[m]}],pb:[{pb:[m]}],pl:[{pl:[m]}],m:[{m:[b]}],mx:[{mx:[b]}],my:[{my:[b]}],ms:[{ms:[b]}],me:[{me:[b]}],mt:[{mt:[b]}],mr:[{mr:[b]}],mb:[{mb:[b]}],ml:[{ml:[b]}],"space-x":[{"space-x":[L]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[L]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",q,e]}],"min-w":[{"min-w":[q,e,"min","max","fit"]}],"max-w":[{"max-w":[q,e,"none","full","min","max","fit","prose",{screen:[yi]},yi]}],h:[{h:[q,e,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[q,e,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[q,e,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[q,e,"auto","min","max","fit"]}],"font-size":[{text:["base",yi,vi]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",qp]}],"font-family":[{font:[Ho]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",q]}],"line-clamp":[{"line-clamp":["none",rs,qp]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Rn,q]}],"list-image":[{"list-image":["none",q]}],"list-style-type":[{list:["none","disc","decimal",q]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[t]}],"placeholder-opacity":[{"placeholder-opacity":[p]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[t]}],"text-opacity":[{"text-opacity":[p]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...E(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Rn,vi]}],"underline-offset":[{"underline-offset":["auto",Rn,q]}],"text-decoration-color":[{decoration:[t]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:T()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",q]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",q]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[p]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...O(),MF]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",_F]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},LF]}],"bg-color":[{bg:[t]}],"gradient-from-pos":[{from:[g]}],"gradient-via-pos":[{via:[g]}],"gradient-to-pos":[{to:[g]}],"gradient-from":[{from:[h]}],"gradient-via":[{via:[h]}],"gradient-to":[{to:[h]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[p]}],"border-style":[{border:[...E(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[p]}],"divide-style":[{divide:E()}],"border-color":[{border:[r]}],"border-color-x":[{"border-x":[r]}],"border-color-y":[{"border-y":[r]}],"border-color-s":[{"border-s":[r]}],"border-color-e":[{"border-e":[r]}],"border-color-t":[{"border-t":[r]}],"border-color-r":[{"border-r":[r]}],"border-color-b":[{"border-b":[r]}],"border-color-l":[{"border-l":[r]}],"divide-color":[{divide:[r]}],"outline-style":[{outline:["",...E()]}],"outline-offset":[{"outline-offset":[Rn,q]}],"outline-w":[{outline:[Rn,vi]}],"outline-color":[{outline:[t]}],"ring-w":[{ring:N()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[t]}],"ring-opacity":[{"ring-opacity":[p]}],"ring-offset-w":[{"ring-offset":[Rn,vi]}],"ring-offset-color":[{"ring-offset":[t]}],shadow:[{shadow:["","inner","none",yi,AF]}],"shadow-color":[{shadow:[Ho]}],opacity:[{opacity:[p]}],"mix-blend":[{"mix-blend":[...A(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":A()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[i]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",yi,q]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[c]}],invert:[{invert:[d]}],saturate:[{saturate:[y]}],sepia:[{sepia:[P]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[i]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[c]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[p]}],"backdrop-saturate":[{"backdrop-saturate":[y]}],"backdrop-sepia":[{"backdrop-sepia":[P]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[o]}],"border-spacing-x":[{"border-spacing-x":[o]}],"border-spacing-y":[{"border-spacing-y":[o]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",q]}],duration:[{duration:I()}],ease:[{ease:["linear","in","out","in-out",q]}],delay:[{delay:I()}],animate:[{animate:["none","spin","ping","pulse","bounce",q]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[S]}],"scale-x":[{"scale-x":[S]}],"scale-y":[{"scale-y":[S]}],rotate:[{rotate:[Ko,q]}],"translate-x":[{"translate-x":[_]}],"translate-y":[{"translate-y":[_]}],"skew-x":[{"skew-x":[C]}],"skew-y":[{"skew-y":[C]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",q]}],accent:[{accent:["auto",t]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",q]}],"caret-color":[{caret:[t]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":T()}],"scroll-mx":[{"scroll-mx":T()}],"scroll-my":[{"scroll-my":T()}],"scroll-ms":[{"scroll-ms":T()}],"scroll-me":[{"scroll-me":T()}],"scroll-mt":[{"scroll-mt":T()}],"scroll-mr":[{"scroll-mr":T()}],"scroll-mb":[{"scroll-mb":T()}],"scroll-ml":[{"scroll-ml":T()}],"scroll-p":[{"scroll-p":T()}],"scroll-px":[{"scroll-px":T()}],"scroll-py":[{"scroll-py":T()}],"scroll-ps":[{"scroll-ps":T()}],"scroll-pe":[{"scroll-pe":T()}],"scroll-pt":[{"scroll-pt":T()}],"scroll-pr":[{"scroll-pr":T()}],"scroll-pb":[{"scroll-pb":T()}],"scroll-pl":[{"scroll-pl":T()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",q]}],fill:[{fill:[t,"none"]}],"stroke-w":[{stroke:[Rn,vi,qp]}],stroke:[{stroke:[t,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},NF=(t,{cacheSize:e,prefix:n,separator:i,experimentalParseClassName:r,extend:s={},override:o={}})=>{Wo(t,"cacheSize",e),Wo(t,"prefix",n),Wo(t,"separator",i),Wo(t,"experimentalParseClassName",r);for(const a in o)OF(t[a],o[a]);for(const a in s)VF(t[a],s[a]);return t},Wo=(t,e,n)=>{n!==void 0&&(t[e]=n)},OF=(t,e)=>{if(e)for(const n in e)Wo(t,n,e[n])},VF=(t,e)=>{if(e)for(const n in e){const i=e[n];i!==void 0&&(t[n]=(t[n]||[]).concat(i))}},jF=(t,...e)=>typeof t=="function"?Qp(Zp,t,...e):Qp(()=>NF(Zp(),t),...e),zF=Qp(Zp);var BF={twMerge:!0,twMergeConfig:{},responsiveVariants:!1},I$=t=>t||void 0,Uo=(...t)=>I$(k$(t).filter(Boolean).join(" ")),Jp=null,Fn={},em=!1,Yo=(...t)=>e=>e.twMerge?((!Jp||em)&&(em=!1,Jp=pt(Fn)?zF:jF(V(k({},Fn),{extend:k({theme:Fn.theme,classGroups:Fn.classGroups,conflictingClassGroupModifiers:Fn.conflictingClassGroupModifiers,conflictingClassGroups:Fn.conflictingClassGroups},Fn.extend)}))),I$(Jp(Uo(t)))):Uo(t),N$=(t,e)=>{for(let n in e)t.hasOwnProperty(n)?t[n]=Uo(t[n],e[n]):t[n]=e[n];return t},KF=(t,e)=>{let{extend:n=null,slots:i={},variants:r={},compoundVariants:s=[],compoundSlots:o=[],defaultVariants:a={}}=t,l=k(k({},BF),e),u=n!=null&&n.base?Uo(n.base,t==null?void 0:t.base):t==null?void 0:t.base,c=n!=null&&n.variants&&!pt(n.variants)?C$(r,n.variants):r,d=n!=null&&n.defaultVariants&&!pt(n.defaultVariants)?k(k({},n.defaultVariants),a):a;!pt(l.twMergeConfig)&&!aF(l.twMergeConfig,Fn)&&(em=!0,Fn=l.twMergeConfig);let f=pt(n==null?void 0:n.slots),h=pt(i)?{}:k({base:Uo(t==null?void 0:t.base,f&&(n==null?void 0:n.base))},i),g=f?h:N$(k({},n==null?void 0:n.slots),pt(h)?{base:t==null?void 0:t.base}:h),v=pt(n==null?void 0:n.compoundVariants)?s:T$(n==null?void 0:n.compoundVariants,s),b=m=>{if(pt(c)&&pt(i)&&f)return Yo(u,m==null?void 0:m.class,m==null?void 0:m.className)(l);if(v&&!Array.isArray(v))throw new TypeError(`The "compoundVariants" prop must be an array. Received: ${typeof v}`);if(o&&!Array.isArray(o))throw new TypeError(`The "compoundSlots" prop must be an array. Received: ${typeof o}`);let y=(T,N,M=[],O)=>{let E=M;if(typeof N=="string")E=E.concat(E$(N).split(" ").map(A=>`${T}:${A}`));else if(Array.isArray(N))E=E.concat(N.reduce((A,R)=>A.concat(`${T}:${R}`),[]));else if(typeof N=="object"&&typeof O=="string"){for(let A in N)if(N.hasOwnProperty(A)&&A===O){let R=N[A];if(R&&typeof R=="string"){let j=E$(R);E[O]?E[O]=E[O].concat(j.split(" ").map(H=>`${T}:${H}`)):E[O]=j.split(" ").map(H=>`${T}:${H}`)}else Array.isArray(R)&&R.length>0&&(E[O]=R.reduce((j,H)=>j.concat(`${T}:${H}`),[]))}}return E},S=(T,N=c,M=null,O=null)=>{var E;let A=N[T];if(!A||pt(A))return null;let R=(E=O==null?void 0:O[T])!=null?E:m==null?void 0:m[T];if(R===null)return null;let j=P$(R),H=Array.isArray(l.responsiveVariants)&&l.responsiveVariants.length>0||l.responsiveVariants===!0,I=d==null?void 0:d[T],z=[];if(typeof j=="object"&&H)for(let[J,ce]of Object.entries(j)){let $t=A[ce];if(J==="initial"){I=ce;continue}Array.isArray(l.responsiveVariants)&&!l.responsiveVariants.includes(J)||(z=y(J,$t,z,M))}let Q=j!=null&&typeof j!="object"?j:P$(I),K=A[Q||"false"];return typeof z=="object"&&typeof M=="string"&&z[M]?N$(z,K):z.length>0?(z.push(K),z):K},P=()=>c?Object.keys(c).map(T=>S(T,c)):null,C=(T,N)=>{if(!c||typeof c!="object")return null;let M=new Array;for(let O in c){let E=S(O,c,T,N),A=T==="base"&&typeof E=="string"?E:E&&E[T];A&&(M[M.length]=A)}return M},L={};for(let T in m)m[T]!==void 0&&(L[T]=m[T]);let _=(T,N)=>{var M;let O=typeof(m==null?void 0:m[T])=="object"?{[T]:(M=m[T])==null?void 0:M.initial}:{};return k(k(k(k({},d),L),O),N)},w=(T=[],N)=>{let M=[];for(let O of T){let E=O,{class:A,className:R}=E,j=ee(E,["class","className"]);let H=!0;for(let[I,z]of Object.entries(j)){let Q=_(I,N);if(Array.isArray(z)){if(!z.includes(Q[I])){H=!1;break}}else if(Q[I]!==z){H=!1;break}}H&&(A&&M.push(A),R&&M.push(R))}return M},$=T=>{let N=w(v,T);if(!Array.isArray(N))return N;let M={};for(let O of N)if(typeof O=="string"&&(M.base=Yo(M.base,O)(l)),typeof O=="object")for(let[E,A]of Object.entries(O))M[E]=Yo(M[E],A)(l);return M},F=T=>{if(o.length<1)return null;let N={};for(let M of o){let O=M,{slots:E=[],class:A,className:R}=O,j=ee(O,["slots","class","className"]);if(!pt(j)){let H=!0;for(let I of Object.keys(j)){let z=_(I,T)[I];if(z===void 0||(Array.isArray(j[I])?!j[I].includes(z):j[I]!==z)){H=!1;break}}if(!H)continue}for(let H of E)N[H]=N[H]||[],N[H].push([A,R])}return N};if(!pt(i)||!f){let T={};if(typeof g=="object"&&!pt(g))for(let N of Object.keys(g))T[N]=M=>{var O,E;return Yo(g[N],C(N,M),((O=$(M))!=null?O:[])[N],((E=F(M))!=null?E:[])[N],M==null?void 0:M.class,M==null?void 0:M.className)(l)};return T}return Yo(u,P(),w(v),m==null?void 0:m.class,m==null?void 0:m.className)(l)},p=()=>{if(!(!c||typeof c!="object"))return Object.keys(c)};return b.variantKeys=p(),b.extend=n,b.base=u,b.slots=g,b.variants=c,b.defaultVariants=d,b.compoundSlots=o,b.compoundVariants=v,b};const HF=KF({base:"w-full px-8 py-3 min-h-[52px] rounded text-center font-sans font-bold tracking-tight flex items-center justify-center",variants:{color:{primary:"bg-sfprimary text-white hover:bg-sfnavy",secondary:"border-2 border-sfprimary bg-white text-sfprimary hover:bg-sfprimary hover:text-white"},size:{sm:"text-sm leading-none",md:"text-base leading-none",lg:"px-8 py-5 text-lg leading-none"}},compoundVariants:[{size:["sm","md"],class:""}]}),WF=(t,e)=>{const n=t.target,i=n.closest('[data-blade-name="sf/open"]'),r=i?i.getAttribute("data-blade-id"):"",s=i?i.getAttribute("data-blade-position"):"";let o=0,a=n.previousElementSibling;for(;a;)o++,a=a.previousElementSibling;const l={event:"custEv_contentClick",blade:{id:r,name:"sf/marquee/agentforce",position:s,source:"www",variant:"marquee",state:"rendered",type:"blade",module:{id:r,name:n.innerText,type:"cta",position:o+1,link:{text:n.innerText,url:n.getAttribute("href"),type:`${e} cta`,internalDriver:""}}}};window.dataLayer&&window.dataLayer.push(k({},l))},O$=({children:t,url:e,target:n,variant:i="primary",size:r="md"})=>D.jsx(D.Fragment,{children:D.jsx(s3,{onPress:s=>{WF(s,i)},href:e,target:n,className:HF({size:r,color:i==="text"?"secondary":i}),children:t})}),UF=()=>D.jsxs("div",{className:"relative mx-auto h-[200px] w-full sm:h-[300px]",children:[D.jsx("div",{className:"masked-contour absolute inset-x-0 bottom-0 z-0 mx-auto -mb-[2px] w-full",children:D.jsx("img",{src:"https://wp.sfdcdigital.com/en-us/wp-content/uploads/sites/4/2024/10/contour.svg",alt:"",className:"w-full"})}),D.jsx("div",{className:"data-dust-left absolute left-0 top-[-50px] z-10 sm:top-[-450px]",children:D.jsx("img",{src:"https://wp.sfdcdigital.com/en-us/wp-content/uploads/sites/4/2024/10/DataDust.svg",alt:"",className:"w-auto max-sm:w-[250px]"})}),D.jsx("div",{className:"data-dust-right visible absolute right-0 top-[-80px] z-10 max-lg:hidden",children:D.jsx("img",{src:"https://wp.sfdcdigital.com/en-us/wp-content/uploads/sites/4/2024/10/DataDust-2.svg",alt:""})}),D.jsx("div",{className:"astro-agentforce absolute bottom-[-20px] right-0 z-20 sm:right-[10%]",children:D.jsx("img",{src:"https://wp.sfdcdigital.com/en-us/wp-content/uploads/sites/4/2024/10/astro-bot.png",alt:"",className:"w-[200px] sm:w-[260px]"})}),D.jsx("div",{className:"einstein-agentforce absolute bottom-[-40px] left-[13%] z-20",children:D.jsx("img",{src:"https://wp.sfdcdigital.com/en-us/wp-content/uploads/sites/4/2024/10/einstein-bot.png",alt:"",className:"w-[200px] sm:w-[260px]"})}),D.jsx("div",{className:"appy-agentforce absolute bottom-[-20px] left-[3%] z-20",children:D.jsx("img",{src:"https://wp.sfdcdigital.com/en-us/wp-content/uploads/sites/4/2024/10/appy-bot.png",alt:"",className:"w-[80px] sm:w-[180px]"})})]});function YF(){const[t,e]=x.useState(20),[n,i]=x.useState(5e4),[r,s]=x.useState(20),[o,a]=x.useState(50),l=t*n,u=r*t*260,c=2,f=75*t*12,h=o,g=o-o*.3,v=g-g*.3,b=u*(v/100),p=u*(g/100),m=u*(h/100);//! Removed `* 2` from costYear1 per Vandana Gangwar const y=u*c*(v/100),S=u*c*(g/100),P=u*c*(h/100),C=y+S+P,L=l*3,_=l*(1-v/100),w=l*(1-g/100),$=l*(1-h/100),F=_+w+$,T=(l+f)*(1-v/100),N=(l+f)*(1-g/100),M=(l+f)*(1-h/100),O=T+N+M,E=l+f-T-y,A=l+f-N-S,R=l+f-M-P,j=E+A+R,H=j/L*100,I=[{year:"Year 0",serviceRepCost:Math.max(0,l),cost:0,savings:0},{year:"Year 1",serviceRepCost:Math.max(0,T),cost:Math.max(0,y),savings:Math.max(0,E)},{year:"Year 2",serviceRepCost:Math.max(0,N),cost:Math.max(0,S),savings:Math.max(0,A)},{year:"Year 3",serviceRepCost:Math.max(0,M),cost:Math.max(0,P),savings:Math.max(0,R)},{serviceRepCost:Math.max(0,O),year:"Total",cost:Math.max(0,C),savings:Math.max(0,j)}],z=`With Agentforce Service Agent handling ${Math.round(o)}% of conversations, you will save $${Math.round(j)} over 3 years total net savings.`,Q=`A bar chart showing a $${Math.round(T)} human cost, $${Math.round(y)} cost for Agentforce and $${Math.round(E)} Net Savings in Year 1. $${Math.round(N)} human cost, $${Math.round(S)} cost for Agentforce and $${Math.round(A)} Net Savings in Year 2. $${Math.round(M)} human cost, $${Math.round(P)} cost for Agentforce and $${Math.round(R)} Net Savings in Year 3.`;return D.jsxs("div",{className:"bg-agentforce-light",children:[D.jsxs("div",{className:"flex min-h-screen flex-col items-center justify-center px-4 pb-10 pt-10 md:pt-16",children:[D.jsxs("section",{className:"max-w-[1280px] text-center md:max-w-[540px] lg:max-w-[768px]",children:[D.jsxs("h1",{className:"text-5xl text-sky-950",children:[D.jsxs("span",{children:[D.jsx("span",{className:"text-indigo-700",children:ge.headerEyebrow}),D.jsx("br",{}),ge.header]}),D.jsx("br",{})]}),D.jsx("h2",{className:"mb-10 text-2xl text-sky-950 md:mb-16",children:ge.headerBottom})]}),D.jsxs("section",{className:"container z-20 mx-auto flex flex-col gap-8 p-0 md:max-w-[540px] md:flex-col lg:max-w-[768px] xl:max-w-[1280px] xl:flex-row 2xl:max-w-[1440px]",children:[D.jsxs("div",{className:"w-full self-start rounded-2xl bg-white px-6 py-8 shadow-lg xl:w-[320px]",children:[D.jsx("h3",{className:"mb-6 font-display text-2xl text-sfnavy",children:ge.formHeadline}),D.jsx("p",{className:"mb-6 font-sans text-sm font-normal leading-tight text-neutral-700",children:"(All fields are required)"}),D.jsxs("div",{className:"flex flex-col gap-6",children:[D.jsx(ap,{label:ge.formField1Label,info:ge.formField1Info,value:t,defaultValue:t,minValue:1,maxValue:1e5,formatOptions:{maximumFractionDigits:0},onChange:K=>isNaN(K)?e(1):e(Number(K)),validationBehavior:"native",errorMessage:"Customer service employees is required",isRequired:!0}),D.jsx(ap,{label:ge.formField2Label,info:ge.formField2Info,value:n,defaultValue:n,minValue:1,maxValue:1e6,formatOptions:{style:"currency",currency:ge.currency,maximumFractionDigits:0},onChange:K=>isNaN(K)?i(0):i(Number(K)),validationBehavior:"native",errorMessage:"Cost per employee is required",isRequired:!0}),D.jsx(ap,{label:ge.formField4Label,info:ge.formField4Info,value:r,defaultValue:r,formatOptions:{maximumFractionDigits:0},onChange:K=>isNaN(K)?s(1):s(Number(K)),validationBehavior:"native",errorMessage:"Conversations handled is required",isRequired:!0}),D.jsx(Y3,{label:ge.formField3Label,info:ge.formField3Info,value:o,onChange:a,maxValue:100,suffix:"%",step:5})]})]}),D.jsxs("div",{className:"relative flex w-full flex-col gap-6 self-start overflow-hidden rounded-2xl bg-white p-8 pt-12 shadow-lg sm:px-10 xl:flex-1",children:[D.jsx("div",{className:"absolute inset-0 top-0 h-2 w-full",style:{background:"linear-gradient(90deg, #02BEC7 -12.85%, #1E1D80 26.7%, #7B00E1 95.81%, #DC32EC 129.59%)"}}),D.jsxs("div",{className:"inline-flex w-full flex-col items-center justify-start",children:[D.jsxs("h2",{className:"mb-4 max-w-lg text-center font-display text-2xl leading-9 text-sfnavy sm:text-2xl sm:leading-10",children:["With Agentforce Service Agent handling"," ",D.jsxs("span",{className:"text-indigo-500",children:[o,"% "]}),"of conversations, you will save"]}),D.jsx("div",{className:"mb-4 text-center text-5xl font-semibold sm:text-[80px] sm:leading-[80px]",children:D.jsx("div",{style:{background:"linear-gradient(90deg, #02BEC7 -12.85%, #1E1D80 26.7%, #7B00E1 95.81%, #DC32EC 129.59%)",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent",WebkitTextStrokeWidth:"1",WebkitTextStrokeColor:"#8E55E4",fontFeatureSettings:'"liga" off, "clig" off',accentColor:"#8E55E4"},children:D.jsx(dl,{value:j})})}),D.jsx("div",{className:"mb-5 font-sans text-xl font-bold leading-[30px] tracking-tight text-neutral-900",children:ge.resultsDescription}),D.jsx("div",{role:"region",id:"agentforce-savings-info",className:"sr-only","aria-live":"polite","aria-atomic":"true",children:z}),D.jsxs(G3,{children:[D.jsxs(X3,{children:[D.jsx(hS,{id:"table",children:"Table"}),D.jsx(hS,{id:"chart",children:"Chart"})]}),D.jsx(pS,{id:"table",children:D.jsx("div",{className:"flex w-full flex-col",children:D.jsx(fD,{yearlyData:I})})}),D.jsx(pS,{id:"chart",children:D.jsx("div",{className:"relative flex w-full flex-col overflow-x-auto max-sm:h-[40vh] max-sm:w-[75vw]",children:D.jsx(oF,{data:I,ariaLabel:Q})})})]}),D.jsx("p",{className:"my-8 font-sans text-xs font-normal leading-[18px] tracking-tight text-black",dangerouslySetInnerHTML:{__html:ge.legalDisclaimer}}),D.jsxs("div",{className:"flex w-full flex-col gap-4 md:flex-row",children:[D.jsx(O$,{url:ge.cta1Url,target:"_blank",children:ge.cta1Label}),D.jsx(O$,{variant:"secondary",url:ge.cta2Url,children:ge.cta2Label})]})]})]})]}),new URLSearchParams(window.location.search).get("debug")==="true"&&D.jsx("div",{className:"container mx-auto flex flex-col p-0 md:flex-row md:gap-4",children:D.jsxs("div",{className:"grid w-full grid-cols-4 gap-4 rounded-xl bg-white p-4 text-center shadow-lg",children:[D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"totalHumanCost"}),D.jsx("div",{className:"text-indigo-500",children:l.toLocaleString("en-US",{style:"currency",currency:"USD",maximumFractionDigits:0})})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"totalAnnualConversations"}),D.jsx("div",{className:"text-indigo-500",children:u})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"humanCostSavingsYear1"}),D.jsx("div",{className:"text-indigo-500",children:_})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"humanCostSavingsYear2"}),D.jsx("div",{className:"text-indigo-500",children:w})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"humanCostSavingsYear3"}),D.jsx("div",{className:"text-indigo-500",children:$})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"yearOne"}),D.jsx("div",{className:"text-indigo-500",children:v})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"yearTwo"}),D.jsx("div",{className:"text-indigo-500",children:g})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"yearThree"}),D.jsx("div",{className:"text-indigo-500",children:h})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"conversationsYear1"}),D.jsx("div",{className:"text-indigo-500",children:b})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"conversationsYear2"}),D.jsx("div",{className:"text-indigo-500",children:p})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"conversationsYear3"}),D.jsx("div",{className:"text-indigo-500",children:m})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"serviceAgentCost"}),D.jsx("div",{className:"text-indigo-500",children:c.toLocaleString("en-US",{style:"currency",currency:"USD",maximumFractionDigits:0})})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"costYear1"}),D.jsx("div",{className:"text-indigo-500",children:y.toLocaleString("en-US",{style:"currency",currency:"USD",maximumFractionDigits:0})})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"costYear2"}),D.jsx("div",{className:"text-indigo-500",children:S.toLocaleString("en-US",{style:"currency",currency:"USD",maximumFractionDigits:0})})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"costYear3"}),D.jsx("div",{className:"text-indigo-500",children:P.toLocaleString("en-US",{style:"currency",currency:"USD",maximumFractionDigits:0})})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"costTotal"}),D.jsx("div",{className:"text-indigo-500",children:C.toLocaleString("en-US",{style:"currency",currency:"USD",maximumFractionDigits:0})})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"costTotalAsIs"}),D.jsx("div",{className:"text-indigo-500",children:L.toLocaleString("en-US",{style:"currency",currency:"USD",maximumFractionDigits:0})})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"totalSavingsPercentage"}),D.jsxs("div",{className:"text-indigo-500",children:[H.toFixed(2),"%"]})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"humanCostSavingsTotal"}),D.jsx("div",{className:"text-indigo-500",children:F})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"totalLicenseCost"}),D.jsx("div",{className:"text-indigo-500",children:f})]}),D.jsxs("div",{className:"p-1",children:[D.jsx("strong",{className:"text-black",children:"totalAnnualConversations"}),D.jsx("div",{className:"text-indigo-500",children:u})]})]})})]}),D.jsx(UF,{})]})}Wu.createRoot(document.getElementById("wps-agentforce-roi")).render(D.jsx(W.StrictMode,{children:D.jsx(YF,{})}))});