@arcgis/map-components 5.1.0-next.37 → 5.1.0-next.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cdn/5C33IP7B.js +2 -0
- package/dist/cdn/ANRWXBWL.js +2 -0
- package/dist/cdn/BE4GRNQV.js +2 -0
- package/dist/cdn/GPGC63RW.js +2 -0
- package/dist/cdn/{5RTPMSZH.js → HIQZMFIH.js} +2 -2
- package/dist/cdn/{HHJN3Q6G.js → HKNVYHER.js} +1 -1
- package/dist/cdn/IPIYZVAJ.js +2 -0
- package/dist/cdn/IULGMTSK.js +2 -0
- package/dist/cdn/{YC5JACID.js → JJTM5KZ2.js} +1 -1
- package/dist/cdn/JWJHIBYW.js +2 -0
- package/dist/cdn/{4JCY4NHX.js → NBBZRGXH.js} +1 -1
- package/dist/cdn/OGE4JCW6.js +2 -0
- package/dist/cdn/PILEMW25.js +2 -0
- package/dist/cdn/QEDQOBD7.js +4 -0
- package/dist/cdn/{D27YXH3W.js → T34SPRV3.js} +1 -1
- package/dist/cdn/WG4E5DBM.js +2 -0
- package/dist/cdn/index.js +1 -1
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/package.json +5 -5
- package/dist/cdn/2AYGSNEO.js +0 -2
- package/dist/cdn/63N5ERFL.js +0 -2
- package/dist/cdn/6RKD6GFP.js +0 -2
- package/dist/cdn/CCKYOWZO.js +0 -2
- package/dist/cdn/HEAH7MYD.js +0 -2
- package/dist/cdn/PZC5TBXA.js +0 -2
- package/dist/cdn/R7BJHEHH.js +0 -2
- package/dist/cdn/S4NUCPRQ.js +0 -4
- package/dist/cdn/XW72RT5D.js +0 -2
- package/dist/cdn/Y6IN6NEC.js +0 -2
- package/dist/cdn/ZJ36DBTH.js +0 -2
- /package/dist/cdn/{JPDYVHUZ.js → 2HJ7EGEB.js} +0 -0
- /package/dist/cdn/{D3X7R3GD.js → 3LKCMCHN.js} +0 -0
- /package/dist/cdn/{FHSXSYA6.js → 4S2JKX63.js} +0 -0
- /package/dist/cdn/{LEC4CIVO.js → 5VWD7SPW.js} +0 -0
- /package/dist/cdn/{WL4J6REN.js → 6PWTVRJ6.js} +0 -0
- /package/dist/cdn/{DZG4EA6U.js → 6TB2XH3T.js} +0 -0
- /package/dist/cdn/{NCTWDKYG.js → 6W3OENEK.js} +0 -0
- /package/dist/cdn/{4NBXFFTY.js → 6ZCH5OTT.js} +0 -0
- /package/dist/cdn/{WG5RPCHL.js → 7C22TPME.js} +0 -0
- /package/dist/cdn/{6QPD32WT.js → BEDLAEXK.js} +0 -0
- /package/dist/cdn/{ELF2SE5K.js → BILSW27K.js} +0 -0
- /package/dist/cdn/{FYVM32GJ.js → BLSJEYOH.js} +0 -0
- /package/dist/cdn/{BFHBS4MR.js → BUILQQ6S.js} +0 -0
- /package/dist/cdn/{V2D4QTRR.js → BVFH7ZG4.js} +0 -0
- /package/dist/cdn/{GVW4OIR5.js → E6GYGJ2B.js} +0 -0
- /package/dist/cdn/{KNFAPO3C.js → EG3W3ADI.js} +0 -0
- /package/dist/cdn/{SPXZXKMH.js → FVTX4GNH.js} +0 -0
- /package/dist/cdn/{YGJ7NPDT.js → FWV2SQE2.js} +0 -0
- /package/dist/cdn/{HEBLEJCT.js → GPESYF4D.js} +0 -0
- /package/dist/cdn/{47T624VO.js → GT5SWKXT.js} +0 -0
- /package/dist/cdn/{JMZA4GQB.js → H4WIQKA4.js} +0 -0
- /package/dist/cdn/{5IPPKC3M.js → HX6XVMJE.js} +0 -0
- /package/dist/cdn/{RJTABGPK.js → MR5AEEII.js} +0 -0
- /package/dist/cdn/{6JUTQDKC.js → O5S54F3U.js} +0 -0
- /package/dist/cdn/{J3F5FPMC.js → OIJPQ63Z.js} +0 -0
- /package/dist/cdn/{43UMYTXQ.js → PWPTFBHS.js} +0 -0
- /package/dist/cdn/{7LEGS7EX.js → QSOU6NQA.js} +0 -0
- /package/dist/cdn/{PDCUZMSB.js → QY7A4VMP.js} +0 -0
- /package/dist/cdn/{3NF4UU3S.js → SPSJMCAO.js} +0 -0
- /package/dist/cdn/{DYC6OHKG.js → T3ZFKRCS.js} +0 -0
- /package/dist/cdn/{IDITPQDC.js → TKVE7ETK.js} +0 -0
- /package/dist/cdn/{B3I4OKDQ.js → ULYGZ4D2.js} +0 -0
- /package/dist/cdn/{WBZEEY5N.js → UX5YG5TO.js} +0 -0
- /package/dist/cdn/{AQG5RIV3.js → VIEEGP7G.js} +0 -0
- /package/dist/cdn/{2SQUOXWG.js → WRS3F55Q.js} +0 -0
- /package/dist/cdn/{UYDFCELQ.js → WTUUS552.js} +0 -0
- /package/dist/cdn/{XJQRAKJ6.js → YGVSJT3E.js} +0 -0
- /package/dist/cdn/{TRPYDMNK.js → YJPCWIX2.js} +0 -0
- /package/dist/cdn/{FRWY77LH.js → ZLOQIB7A.js} +0 -0
- /package/dist/cdn/{3GVHNIXM.js → ZX5YTFYB.js} +0 -0
- /package/dist/cdn/{H6LWU2FC.js → ZYZA5VUV.js} +0 -0
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
+
import{a as y}from"./3TTFCHAA.js";var w={};y(w,{PLACEHOLDER:()=>te,PLACEHOLDER2:()=>se,assert:()=>W,getType:()=>T,isArray:()=>ee,isDate:()=>N,isNaN:()=>k,isNumber:()=>d,isObject:()=>A,isString:()=>F,numberToString:()=>Z,repeat:()=>D,toDate:()=>X,toNumber:()=>R});function k(s){return Number(s)!==s}function T(s){return{}.toString.call(s)}function W(s,e="Assertion failed"){if(!s)throw new Error(e)}function R(s){if(s!=null&&!d(s)){let e=Number(s);if(k(e)&&F(s)&&s!=""&&s.match(/[0-9]+/)){let t=s.replace(/[^0-9.\-]+/g,"");return s===t?e:R(t)}return e}return s}function X(s){if(N(s))return new Date(s);if(d(s))return new Date(s);{let e=Number(s);return d(e)?new Date(e):new Date(s)}}function Z(s){if(k(s))return"NaN";if(s===1/0)return"Infinity";if(s===-1/0)return"-Infinity";if(s===0&&1/s===-1/0)return"-0";let e=s<0;s=Math.abs(s);let t=/^([0-9]+)(?:\.([0-9]+))?(?:e[\+\-]([0-9]+))?$/.exec(""+s),i=t[1],n=t[2]||"",r;if(t[3]===void 0)r=n===""?i:i+"."+n;else{let o=+t[3];if(s<1){let h=o-1;r="0."+D("0",h)+i+n}else{let h=o-n.length;h===0?r=i+n:h<0?r=i+n.slice(0,h)+"."+n.slice(h):r=i+n+D("0",h)}}return e?"-"+r:r}function D(s,e){return new Array(e+1).join(s)}function N(s){return T(s)==="[object Date]"}function F(s){return typeof s=="string"}function d(s){return typeof s=="number"&&Number(s)==s}function A(s){return typeof s=="object"&&s!==null}function ee(s){return Array.isArray(s)}var te="__\xA7\xA7\xA7__",se="__\xA7\xA7\xA7\xA7__";var a={};y(a,{add:()=>ue,any:()=>O,copy:()=>me,each:()=>p,eachContinue:()=>re,eachReverse:()=>ne,find:()=>we,findIndex:()=>v,findIndexReverse:()=>H,findMap:()=>ve,findReverse:()=>be,first:()=>pe,getFirstSortedIndex:()=>$e,getSortedIndex:()=>S,has:()=>ge,indexOf:()=>L,insert:()=>M,insertIndex:()=>B,keepIf:()=>ye,last:()=>he,map:()=>ie,move:()=>de,pushAll:()=>ce,pushOne:()=>fe,remove:()=>b,removeFirst:()=>_,removeIndex:()=>z,replace:()=>ae,setIndex:()=>le,shiftLeft:()=>oe,shuffle:()=>Ee,slice:()=>xe,toArray:()=>_e});function L(s,e){let t=s.length;for(let i=0;i<t;++i)if(s[i]===e)return i;return-1}function O(s,e){let t=s.length;for(let i=0;i<t;++i)if(e(s[i]))return!0;return!1}function ie(s,e){let t=s.length,i=new Array(t);for(let n=0;n<t;++n)i[n]=e(s[n],n);return i}function p(s,e){let t=s.length;for(let i=0;i<t;++i)e(s[i],i)}function ne(s,e){let t=s.length;for(;t>0;)--t,e(s[t],t)}function re(s,e){let t=s.length;for(let i=0;i<t&&e(s[i],i);++i);}function oe(s,e){let t=s.length;for(let i=e;i<t;++i)s[i-e]=s[i];s.length=t-e}function he(s){let e=s.length;return e?s[e-1]:void 0}function pe(s){return s[0]}function M(s,e,t){t=Math.max(0,Math.min(t,s.length)),s.splice(t,0,e)}function le(s,e,t){b(s,e),M(s,e,t)}function ce(s,e){let t=e.length;for(let i=0;i<t;++i)s.push(e[i])}function b(s,e){let t=!1,i=0;for(;;){if(i=s.indexOf(e,i),i===-1)return t;t=!0,s.splice(i,1)}}function _(s,e){let t=s.indexOf(e);return t!==-1?(s.splice(t,1),!0):!1}function de(s,e,t){let i=L(s,e);i!==-1&&z(s,i),t==null?s.push(e):B(s,t,e)}function ue(s,e,t){d(t)?t===0?s.unshift(e):s.splice(t,0,e):s.push(e)}function fe(s,e){s.indexOf(e)===-1&&s.push(e)}function ae(s,e,t){let i=s.indexOf(e);i!==-1&&s.splice(i,1),d(t)?s.splice(t,0,e):s.push(e)}function _e(s){return Array.isArray(s)?s:[s]}function ge(s,e){return L(s,e)!==-1}function me(s){let e=s.length,t=new Array(e);for(let i=0;i<e;++i)t[i]=s[i];return t}function xe(s,e,t=s.length){let i=new Array(t-e);for(let n=e;n<t;++n)i[n-e]=s[n];return i}function B(s,e,t){s.splice(e,0,t)}function z(s,e){s.splice(e,1)}function v(s,e){let t=s.length;for(let i=0;i<t;++i)if(e(s[i],i))return i;return-1}function H(s,e){let t=s.length;for(;t>0;)if(--t,e(s[t],t))return t;return-1}function we(s,e){let t=v(s,e);if(t!==-1)return s[t]}function be(s,e){let t=H(s,e);if(t!==-1)return s[t]}function ve(s,e){let t=s.length;for(let i=0;i<t;++i){let n=e(s[i],i);if(n!==void 0)return n}}function Ee(s){let e=s.length,t,i;for(;e!==0;)i=Math.floor(Math.random()*e),e-=1,t=s[e],s[e]=s[i],s[i]=t}function S(s,e){let t=0,i=s.length,n=!1;for(;t<i;){let r=t+i>>1,o=e(s[r]);if(o<0)t=r+1;else if(o===0){for(n=!0,t=r+1;t<i&&e(s[t])===0;t++);t--;break}else i=r}return{found:n,index:t}}function $e(s,e){let t=0,i=s.length,n=!1;for(;t<i;){let r=t+i>>1,o=e(s[r]);o<0?t=r+1:(o===0&&(n=!0),i=r)}return{found:n,index:t}}function ye(s,e){let t=s.length;for(;t>0;)--t,e(s[t])||s.splice(t,1)}var V={};y(V,{copy:()=>ke,each:()=>l,eachContinue:()=>Ae,eachOrdered:()=>Le,entries:()=>De,hasKey:()=>Y,keys:()=>g,keysOrdered:()=>K,softCopyProperties:()=>Oe});function g(s){return Object.keys(s)}function De(s){return Object.entries(s)}function K(s,e){return g(s).sort(e)}function ke(s){return Object.assign({},s)}function l(s,e){g(s).forEach(t=>{e(t,s[t])})}function Ae(s,e){for(let t in s)if(Y(s,t)&&!e(t,s[t]))break}function Le(s,e,t){p(K(s,t),i=>{e(i,s[i])})}function Y(s,e){return{}.hasOwnProperty.call(s,e)}function Oe(s,e){return l(s,(t,i)=>{i!=null&&e[t]==null&&(e[t]=i)}),e}var m=class{constructor(){this._disposed=!1}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._dispose())}},c=class{constructor(e){this._disposed=!1,this._dispose=e}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._dispose())}},q=class extends m{constructor(){super(...arguments),this._disposers=[]}_dispose(){p(this._disposers,e=>{e.dispose()})}},u=class extends m{constructor(e){super(),this._disposers=e}_dispose(){p(this._disposers,e=>{e.dispose()})}get disposers(){return this._disposers}},G=class extends m{_dispose(){this._disposer!=null&&(this._disposer.dispose(),this._disposer=void 0)}get(){return this._value}set(e,t){this._disposer!=null&&this._disposer.dispose(),this._disposer=t,this._value=e}reset(){this.set(void 0,void 0)}},J=class extends c{constructor(){super(...arguments),this._counter=0}increment(){return++this._counter,new c(()=>{--this._counter,this._counter===0&&this.dispose()})}};var E=class{constructor(){this._listeners=[],this._killed=[],this._disabled={},this._iterating=0,this._enabled=!0,this._disposed=!1}isDisposed(){return this._disposed}dispose(){if(!this._disposed){this._disposed=!0;let e=this._listeners;this._iterating=1,this._listeners=null,this._disabled=null;try{p(e,t=>{t.disposer.dispose()})}finally{this._killed=null,this._iterating=null}}}hasListeners(){return this._listeners.length!==0}hasListenersByType(e){return O(this._listeners,t=>(t.type===null||t.type===e)&&!t.killed)}enable(){this._enabled=!0}disable(){this._enabled=!1}enableType(e){delete this._disabled[e]}disableType(e,t=1/0){this._disabled[e]=t}_removeListener(e){if(this._iterating===0){let t=this._listeners.indexOf(e);if(t===-1)throw new Error("Invalid state: could not remove listener");this._listeners.splice(t,1)}else this._killed.push(e)}_removeExistingListener(e,t,i,n){if(this._disposed)throw new Error("EventDispatcher is disposed");this._eachListener(r=>{r.once===e&&r.type===t&&(i===void 0||r.callback===i)&&r.context===n&&r.disposer.dispose()})}isEnabled(e){if(this._disposed)throw new Error("EventDispatcher is disposed");return this._enabled&&this._listeners.length>0&&this.hasListenersByType(e)&&this._disabled[e]===void 0}removeType(e){if(this._disposed)throw new Error("EventDispatcher is disposed");this._eachListener(t=>{t.type===e&&t.disposer.dispose()})}has(e,t,i){return v(this._listeners,r=>r.once!==!0&&r.type===e&&(t===void 0||r.callback===t)&&r.context===i)!==-1}_shouldDispatch(e){if(this._disposed)throw new Error("EventDispatcher is disposed");let t=this._disabled[e];return d(t)?(t<=1?delete this._disabled[e]:--this._disabled[e],!1):this._enabled}_eachListener(e){++this._iterating;try{p(this._listeners,e)}finally{--this._iterating,this._iterating===0&&this._killed.length!==0&&(p(this._killed,t=>{this._removeListener(t)}),this._killed.length=0)}}dispatch(e,t){this._shouldDispatch(e)&&this._eachListener(i=>{!i.killed&&(i.type===null||i.type===e)&&(i._debounceDelay?(i._debounceTimeout&&window.clearTimeout(i._debounceTimeout),i._debounceTimeout=window.setTimeout(()=>{i._debounceTimeout=void 0,i.killed||i.dispatch(e,t)},i._debounceDelay)):i.dispatch(e,t))})}_on(e,t,i,n,r,o,h){if(this._disposed)throw new Error("EventDispatcher is disposed");this._removeExistingListener(e,t,i,n);let f={type:t,callback:i,context:n,shouldClone:r,dispatch:o,killed:!1,once:e,disposer:new c(()=>{f.killed=!0,f._debounceTimeout&&window.clearTimeout(f._debounceTimeout),this._removeListener(f)}),_debounceDelay:h};return this._listeners.push(f),f}onAll(e,t,i=!0){return this._on(!1,null,e,t,i,(n,r)=>e.call(t,r)).disposer}on(e,t,i,n=!0){return this._on(!1,e,t,i,n,(r,o)=>t.call(i,o)).disposer}onDebounced(e,t,i,n,r=!0){return this._on(!1,e,t,n,r,(o,h)=>t.call(n,h),i).disposer}once(e,t,i,n=!0){let r=this._on(!0,e,t,i,n,(o,h)=>{r.disposer.dispose(),t.call(i,h)});return r.disposer}off(e,t,i){this._removeExistingListener(!1,e,t,i)}copyFrom(e){if(this._disposed)throw new Error("EventDispatcher is disposed");if(e===this)throw new Error("Cannot copyFrom the same TargetedEventDispatcher");let t=[];return p(e._listeners,i=>{!i.killed&&i.shouldClone&&(i.type===null?t.push(this.onAll(i.callback,i.context)):i.once?t.push(this.once(i.type,i.callback,i.context)):t.push(this.on(i.type,i.callback,i.context)))}),new u(t)}};function I(s){l(s,(e,t)=>{A(t)&&typeof t.dispose=="function"&&(t.enableDispose=!0,t.dispose())})}var j=class{constructor(e,t,i){this._name=e,this._template=t,this._settings=i}_dispose(){I(this._settings)}get(e,t){let i=this._settings[e];return i!==void 0?i:t}set(e,t){this._settings[e]=t,this._template._stateChanged(this._name)}remove(e){delete this._settings[e],this._template._stateChanged(this._name)}setAll(e){g(e).forEach(t=>{this._settings[t]=e[t]}),this._template._stateChanged(this._name)}_apply(e,t){l(this._settings,(i,n)=>{!t[i]&&!e._userSettings[i]&&(t[i]=!0,e.setRaw(i,n))})}},C=class{constructor(e){this._states={},this._template=e}_dispose(){l(this._states,(e,t)=>{t._dispose()})}lookup(e){return this._states[e]}create(e,t){let i=this._states[e];if(i)return i.setAll(t),i;{let n=new j(e,this._template,t);return this._states[e]=n,this._template._stateChanged(e),n}}remove(e){delete this._states[e],this._template._stateChanged(e)}_apply(e,t){l(this._states,(i,n)=>{let r=t.states[i];r==null&&(r=t.states[i]={});let o=e.states.create(i,{});n._apply(o,r)})}},P=class{constructor(){this._callbacks={}}add(e,t){let i=this._callbacks[e];return i===void 0&&(i=this._callbacks[e]=[]),i.push(t),new c(()=>{_(i,t),i.length===0&&delete this._callbacks[e]})}remove(e){this._callbacks[e]!==void 0&&delete this._callbacks[e]}_apply(e){let t=[];return l(this._callbacks,(i,n)=>{p(n,r=>{t.push(e.adapters.add(i,r))})}),new u(t)}},$=class s{constructor(e,t){if(this._disposed=!1,this._privateSettings={},this._settingEvents={},this._privateSettingEvents={},this._entities=[],this.states=new C(this),this.adapters=new P,this.events=new E,!t)throw new Error("You cannot use `new Class()`, instead use `Class.new()`");this._settings=e}static new(e){return new s(e,!0)}_dispose(){I(this._settings),I(this._privateSettings)}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._dispose())}_checkDisposed(){if(this._disposed)throw new Error("Template is disposed")}get entities(){return this._entities}get(e,t){this._checkDisposed();let i=this._settings[e];return i!==void 0?i:t}setRaw(e,t){this._checkDisposed(),this._settings[e]=t}set(e,t){this._checkDisposed(),this._settings[e]!==t&&(this.setRaw(e,t),this._entities.forEach(i=>{i._setTemplateProperty(this,e,t)}))}remove(e){this._checkDisposed(),e in this._settings&&(delete this._settings[e],this._entities.forEach(t=>{t._removeTemplateProperty(e)}))}removeAll(){this._checkDisposed(),l(this._settings,(e,t)=>{this.remove(e)})}getPrivate(e,t){this._checkDisposed();let i=this._privateSettings[e];return i!==void 0?i:t}setPrivateRaw(e,t){return this._checkDisposed(),this._privateSettings[e]=t,t}setPrivate(e,t){return this._checkDisposed(),this._privateSettings[e]!==t&&(this.setPrivateRaw(e,t),this._entities.forEach(i=>{i._setTemplatePrivateProperty(this,e,t)})),t}removePrivate(e){this._checkDisposed(),e in this._privateSettings&&(delete this._privateSettings[e],this._entities.forEach(t=>{t._removeTemplatePrivateProperty(e)}))}setAll(e){this._checkDisposed(),l(e,(t,i)=>{this.set(t,i)})}on(e,t){this._checkDisposed();let i=this._settingEvents[e];return i===void 0&&(i=this._settingEvents[e]=[]),i.push(t),new c(()=>{_(i,t),i.length===0&&delete this._settingEvents[e]})}onPrivate(e,t){this._checkDisposed();let i=this._privateSettingEvents[e];return i===void 0&&(i=this._privateSettingEvents[e]=[]),i.push(t),new c(()=>{_(i,t),i.length===0&&delete this._privateSettingEvents[e]})}_apply(e,t){this._checkDisposed();let i=[];return l(this._settingEvents,(n,r)=>{p(r,o=>{i.push(e.on(n,o))})}),l(this._privateSettingEvents,(n,r)=>{p(r,o=>{i.push(e.onPrivate(n,o))})}),this.states._apply(e,t),i.push(this.adapters._apply(e)),i.push(e.events.copyFrom(this.events)),new u(i)}_setObjectTemplate(e){this._checkDisposed(),this._entities.push(e)}_removeObjectTemplate(e){b(this._entities,e)}_stateChanged(e){this._checkDisposed(),this._entities.forEach(t=>{t._applyStateByKey(e)})}};function x(s,e){return s===e?0:s<e?-1:1}function Q(s,e,t){let i=s.length,n=e.length,r=Math.min(i,n);for(let o=0;o<r;++o){let h=t(s[o],e[o]);if(h!==0)return h}return x(i,n)}function Ne(s,e){return s===e?0:s<e?-1:1}var U=class{constructor(e,t){if(this._rules={},this._root=e,!t)throw new Error("You cannot use `new Class()`, instead use `Class.new()`")}static new(e){let t=new this(e,!0);return t.setupDefaultRules(),t}setupDefaultRules(){}_lookupRules(e){return this._rules[e]}ruleRaw(e,t=[]){let i=this._rules[e];i||(i=this._rules[e]=[]),t.sort(x);let{index:n,found:r}=S(i,o=>{let h=x(o.tags.length,t.length);return h===0?Q(o.tags,t,x):h});if(r)return i[n].template;{let o=$.new({});return i.splice(n,0,{tags:t,template:o}),o}}rule(e,t=[]){return this.ruleRaw(e,t)}};export{k as a,R as b,X as c,Z as d,N as e,F as f,d as g,A as h,ee as i,te as j,se as k,w as l,L as m,ie as n,p as o,ne as p,re as q,b as r,_ as s,de as t,fe as u,me as v,B as w,z as x,we as y,be as z,S as A,$e as B,ye as C,a as D,g as E,De as F,K as G,ke as H,l as I,Ae as J,V as K,m as L,c as M,q as N,u as O,G as P,J as Q,E as R,x as S,Q as T,Ne as U,$ as V,U as W};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
+
import{a as kt,b as Lt,c as pi,d as Ge}from"./WG4E5DBM.js";import{a as We}from"./5C33IP7B.js";import{A as V,C as li,E as B,F as wt,H as ci,I as di,J as ui,K as J,L as ys,M as C,N as fi,O as rt,Q as xs,c as yt,da as Ie,e as jt,h as j,i as xt,k as bt,l as fs,m as ps,o as Se,r as ms,s as gs,u as Pt,y as P,z as Ye}from"./IPIYZVAJ.js";import{A as Ut,B as ri,C as ai,D as ns,E as oi,F as ni,G as hs,H as ls,I as cs,J as Te,K as Ce,L as ds,N as U,Q as K,R as L,V as hi,c as ts,d as $,e as Fe,f as ct,h as Re,i as es,j as Oe,l as ke,m as is,n as si,o as ss,p as $t,q as _t,r as rs,s as I,t as as,u as Bt,v as os,w as O,x as He}from"./JWJHIBYW.js";import{a as q,b as pt,d as N,e as St,f as ei}from"./GPGC63RW.js";import{C as Wt,E as ve,F as Vt,H as Ki,I as W,J as Ji,L as Qi,M as ht,N as ii,O as lt,Q as we,R as us,S as _s,V as vt,b as X,d as Ui,f as mt,g as M,h as Dt,i as _e,j as gt,k as Mt,m as ji,n as Zi,o as v,q as ye,r as Et,s as xe,t as qi,u as be,v as Gt}from"./PILEMW25.js";import{a as Ps}from"./3TTFCHAA.js";var mi=class{constructor(){this._targets=[],this._observer=new ResizeObserver(t=>{v(t,e=>{v(this._targets,i=>{i.target===e.target&&i.callback()})})})}addTarget(t,e){this._observer.observe(t,{box:"border-box"}),this._targets.push({target:t,callback:e})}removeTarget(t){this._observer.unobserve(t),Wt(this._targets,e=>e.target!==t)}},Xe=class g{constructor(){this._timer=null,this._targets=[]}addTarget(t,e){if(this._timer===null){let s=null,r=()=>{let a=Date.now();(s===null||a>s+g.delay)&&(s=a,v(this._targets,o=>{let n=o.target.getBoundingClientRect();(n.width!==o.size.width||n.height!==o.size.height)&&(o.size=n,o.callback())})),this._targets.length===0?this._timer=null:this._timer=requestAnimationFrame(r)};this._timer=requestAnimationFrame(r)}let i={width:0,height:0,left:0,right:0,top:0,bottom:0,x:0,y:0};this._targets.push({target:t,callback:e,size:i})}removeTarget(t){Wt(this._targets,e=>e.target!==t),this._targets.length===0&&this._timer!==null&&(cancelAnimationFrame(this._timer),this._timer=null)}};Xe.delay=200;var Ve=null;function Ls(){return Ve===null&&(typeof ResizeObserver<"u"?Ve=new mi:Ve=new Xe),Ve}var Ue=class{constructor(t,e){this._disposed=!1,this._sensor=Ls(),this._element=t,this._listener=Fe(e),this._sensor.addTarget(t,e)}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._sensor.removeTarget(this._element),this._listener.dispose())}get sensor(){return this._sensor}};var At=class extends P{};At.className="InterfaceColors";At.classNames=P.classNames.concat([At.className]);var dt=class extends B{_beforeChanged(){super._beforeChanged(),(this.isDirty("pointerBaseWidth")||this.isDirty("cornerRadius")||this.isDirty("pointerLength")||this.isDirty("pointerX")||this.isDirty("pointerY")||this.isDirty("width")||this.isDirty("height"))&&(this._clear=!0)}_changed(){if(super._changed(),this._clear){this.markDirtyBounds();let t=this.width(),e=this.height();if(t>0&&e>0){let i=this.get("cornerRadius",8);i=j(i,0,Math.min(t/2,e/2));let s=this.get("pointerX",0),r=this.get("pointerY",0),a=this.get("pointerBaseWidth",15)/2,o=0,n=0,d=t,m=0,l=t,c=e,h=0,p=e,_=(s-o)*(c-n)-(r-n)*(l-o),u=(s-h)*(m-p)-(r-p)*(d-h),f=this._display;if(f.moveTo(i,0),_>0&&u>0){let b=Math.round(j(s,i+a,t-a-i));r=j(r,-1/0,0),f.lineTo(b-a,0),f.lineTo(s,r),f.lineTo(b+a,0)}if(f.lineTo(t-i,0),f.arcTo(t,0,t,i,i),_>0&&u<0){let b=Math.round(j(r,i+a,e-a-i));s=j(s,t,1/0),f.lineTo(t,i),f.lineTo(t,Math.max(b-a,i)),f.lineTo(s,r),f.lineTo(t,b+a)}if(f.lineTo(t,e-i),f.arcTo(t,e,t-i,e,i),_<0&&u<0){let b=Math.round(j(s,i+a,t-a-i));r=j(r,e,1/0),f.lineTo(t-i,e),f.lineTo(b+a,e),f.lineTo(s,r),f.lineTo(b-a,e)}if(f.lineTo(i,e),f.arcTo(0,e,0,e-i,i),_<0&&u>0){let b=Math.round(j(r,i+a,e-i-a));s=j(s,-1/0,0),f.lineTo(0,e-i),f.lineTo(0,b+a),f.lineTo(s,r),f.lineTo(0,Math.max(b-a,i))}f.lineTo(0,i),f.arcTo(0,0,i,0,i),f.closePath()}}}};dt.className="PointedRectangle";dt.classNames=B.classNames.concat([dt.className]);var at=class extends C{constructor(t,e,i,s=[]){super(t,e,i,s),this._fx=0,this._fy=0,this._w=0,this._h=0,this._htmlContentHovered=!1}_afterNew(){this._settings.themeTags=U(this._settings.themeTags,["tooltip"]),super._afterNew(),this._setDefaultFn("background",()=>dt.new(this._root,{})).set("themeTags",["tooltip","background"]),this._label=this.children.push(rt.new(this._root,{})),this._disposers.push(this._label.events.on("boundschanged",()=>{this._updateBackground()})),this._disposers.push(this.on("bounds",()=>{this._updateBackground()})),this._updateTextColor(),this._root.tooltipContainer.children.push(this),this.hide(0),this._disposers.push(this.label.onPrivate("htmlElement",e=>{e&&(this._disposers.push($(e,"pointerover",i=>{this._htmlContentHovered=!0})),this._disposers.push($(e,"pointerout",i=>{this._htmlContentHovered=!1})))})),this.on("visible",e=>{this._handleReaderAnnouncement()}),this.label.events.on("dataitemchanged",e=>{this._handleReaderAnnouncement()}),this._root._tooltips.push(this)}_handleReaderAnnouncement(){this.get("readerAnnounce")&&this.isVisibleDeep()&&this._root.readerAlert(this.label.getAccessibleText())}get label(){return this._label}_dispose(){super._dispose(),Et(this._root._tooltips,this)}_updateChildren(){super._updateChildren(),(this.isDirty("pointerOrientation")||this.isPrivateDirty("minWidth")||this.isPrivateDirty("minHeight"))&&this.get("background")._markDirtyKey("width"),this.get("labelText")!=null&&this.label.set("text",this.get("labelText")),this.get("labelHTML")!=null&&this.label.set("html",this.get("labelHTML")),this.get("labelAriaLabel")!=null&&this.label.set("ariaLabel",this.get("labelAriaLabel"))}_changed(){if(super._changed(),(this.isDirty("pointTo")||this.isDirty("pointerOrientation"))&&this._updateBackground(),this.isDirty("tooltipTarget")&&this.updateBackgroundColor(),this.isDirty("keepTargetHover"))if(this.get("keepTargetHover")){let e=this.get("background");this._keepHoverDp=new lt([e.events.on("pointerover",i=>{let s=this.get("tooltipTarget");s&&(s.parent&&s.parent.getPrivate("tooltipTarget")==s&&(s=s.parent),s.hover())}),e.events.on("pointerout",i=>{let s=this.get("tooltipTarget");s&&(s.parent&&s.parent.getPrivate("tooltipTarget")==s&&(s=s.parent),this._htmlContentHovered||s.unhover())})]),this.label.onPrivate("htmlElement",i=>{this._keepHoverDp&&i&&this._keepHoverDp.disposers.push($(i,"pointerleave",s=>{let r=this.root._renderer.getEvent(s);e.events.dispatch("pointerout",{type:"pointerout",originalEvent:r.event,point:r.point,simulated:!1,target:e})}))})}else this._keepHoverDp&&(this._keepHoverDp.dispose(),this._keepHoverDp=void 0)}_onShow(){super._onShow(),this.updateBackgroundColor()}updateBackgroundColor(){let t=this.get("tooltipTarget"),e=this.get("background"),i,s;if(t&&e){if(i=t.get("fill"),s=t.get("stroke"),i==null&&(i=s),this.get("getFillFromSprite")&&(this._fillDp&&this._fillDp.dispose(),i!=null&&e.set("fill",i),this._fillDp=t.on("fill",r=>{r!=null&&(e.set("fill",r),this._updateTextColor(r))}),this._disposers.push(this._fillDp)),this.get("getFillGradientFromSprite")){this._fillGrDp&&this._fillGrDp.dispose();let r=t.get("fillGradient");r!=null&&e.set("fillGradient",r),this._fillGrDp=t.on("fillGradient",a=>{a!=null&&e.set("fillGradient",a)}),this._disposers.push(this._fillGrDp)}this.get("getStrokeFromSprite")&&(this._strokeDp&&this._strokeDp.dispose(),i!=null&&e.set("stroke",i),this._strokeDp=t.on("fill",r=>{r!=null&&e.set("stroke",r)}),this._disposers.push(this._strokeDp)),this.get("getLabelFillFromSprite")&&(this._labelDp&&this._labelDp.dispose(),i!=null&&this.label.set("fill",i),this._labelDp=t.on("fill",r=>{r!=null&&this.label.set("fill",r)}),this._disposers.push(this._labelDp))}this._updateTextColor(i)}_updateTextColor(t){this.get("autoTextColor")&&(t==null&&(t=this.get("background").get("fill")),t==null&&(t=this._root.interfaceColors.get("background")),t instanceof L&&this.label.set("fill",L.alternative(t,this._root.interfaceColors.get("alternativeText"),this._root.interfaceColors.get("text"))))}_setDataItem(t){super._setDataItem(t),this.label._setDataItem(t)}_updateBackground(){super.updateBackground();let t=this._root.container;if(t){let e=.5,i=.5,s=this.get("centerX");s instanceof q&&(e=s.value);let r=this.get("centerY");r instanceof q&&(i=r.value);let a=t.width(),o=t.height(),n=this.parent,d=0,m=0;if(n){d=n.x(),m=n.y();let S=n.get("layerMargin");S&&(d+=S.left||0,m+=S.top||0,a+=(S.left||0)+(S.right||0),o+=(S.top||0)+(S.bottom||0))}let l=this.get("bounds",{left:-d,top:-m,right:a-d,bottom:o-m});this._updateBounds();let c=this.width(),h=this.height();c===0&&(c=this._w),h===0&&(h=this._h);let p=this.get("pointTo",{x:a/2,y:o/2}),_=p.x,u=p.y,f=this.get("pointerOrientation"),b=this.get("background"),x=0,y=0,w=0;b instanceof dt&&(x=b.get("pointerLength",0),y=b.get("strokeWidth",0)/2,w=y,b.set("width",c),b.set("height",h));let T=0,k=0,E=l.right-l.left,R=l.bottom-l.top;f=="horizontal"||f=="left"||f=="right"?(y=0,f=="horizontal"?_>l.left+E/2?(_-=c*(1-e)+x,w*=-1):_+=c*e+x:f=="left"?_+=c*(1-e)+x:(_-=c*e+x,w*=-1)):(w=0,f=="vertical"?u>l.top+h/2+x?u-=h*(1-i)+x:(u+=h*i+x,y*=-1):f=="down"?u-=h*(1-i)+x:(u+=h*i+x,y*=-1)),_=j(_,l.left+c*e,l.left+E-c*(1-e))+w,u=j(u,l.top+h*i,l.top+R-h*(1-i))-y,T=p.x-_+c*e+w,k=p.y-u+h*i-y,this._fx=_,this._fy=u;let D=this.get("animationDuration",0);if(D>0&&this.get("visible")&&this.get("opacity")>.1){let S=this.get("animationEasing");this.animate({key:"x",to:_,duration:D,easing:S}),this.animate({key:"y",to:u,duration:D,easing:S})}else this.set("x",_),this.set("y",u);b instanceof dt&&(b.set("pointerX",T),b.set("pointerY",k)),c>0&&(this._w=c),h>0&&(this._h=h)}}};at.className="Tooltip";at.classNames=C.classNames.concat([at.className]);var De=class extends P{_setDefaults(){this._setDefault("negativeBase",0),this._setDefault("numberFormat","#,###.#####"),this._setDefault("smallNumberThreshold",1);let t="_big_number_suffix_",e="_small_number_suffix_",i="_byte_suffix_";this._setDefault("bigNumberPrefixes",[{number:1e3,suffix:this._t(t+"3")},{number:1e6,suffix:this._t(t+"6")},{number:1e9,suffix:this._t(t+"9")},{number:1e12,suffix:this._t(t+"12")},{number:1e15,suffix:this._t(t+"15")},{number:1e18,suffix:this._t(t+"18")},{number:1e21,suffix:this._t(t+"21")},{number:1e24,suffix:this._t(t+"24")}]),this._setDefault("smallNumberPrefixes",[{number:1e-24,suffix:this._t(e+"24")},{number:1e-21,suffix:this._t(e+"21")},{number:1e-18,suffix:this._t(e+"18")},{number:1e-15,suffix:this._t(e+"15")},{number:1e-12,suffix:this._t(e+"12")},{number:1e-9,suffix:this._t(e+"9")},{number:1e-6,suffix:this._t(e+"6")},{number:.001,suffix:this._t(e+"3")}]),this._setDefault("bytePrefixes",[{number:1,suffix:this._t(i+"B")},{number:1024,suffix:this._t(i+"KB")},{number:1048576,suffix:this._t(i+"MB")},{number:1073741824,suffix:this._t(i+"GB")},{number:1099511627776,suffix:this._t(i+"TB")},{number:0x4000000000000,suffix:this._t(i+"PB")}]),super._setDefaults()}_beforeChanged(){super._beforeChanged()}format(t,e,i){(e==null||mt(e)&&e.toLowerCase()==="number")&&(e=this.get("numberFormat",""));let s,r=Number(t);if(Dt(e))try{return this.get("intlLocales")?new Intl.NumberFormat(this.get("intlLocales"),e).format(r):new Intl.NumberFormat(void 0,e).format(r)}catch{return"Invalid"}else{e=Ut(e);let a=this.parseFormat(e,this._root.language),o;r>this.get("negativeBase")?o=a.positive:r<this.get("negativeBase")?o=a.negative:o=a.zero,i!=null&&!o.mod&&(o=Ki(o),o.decimals.active=r==0?0:i),s=o.template.split(gt).join(this.applyFormat(r,o))}return this.get("forceLTR")===!0&&(s="\u200E"+s),s}parseFormat(t,e){let i=e.translateEmpty("_thousandSeparator"),s=e.translateEmpty("_decimalSeparator"),r={positive:{thousands:{active:-1,passive:-1,interval:-1,separator:i},decimals:{active:-1,passive:-1,separator:s},template:"",source:"",parsed:!1},negative:{thousands:{active:-1,passive:-1,interval:-1,separator:i},decimals:{active:-1,passive:-1,separator:s},template:"",source:"",parsed:!1},zero:{thousands:{active:-1,passive:-1,interval:-1,separator:i},decimals:{active:-1,passive:-1,separator:s},template:"",source:"",parsed:!1}};t=t.replace("||",Mt);let a=t.split("|");return r.positive.source=a[0],typeof a[2]>"u"?r.zero=r.positive:r.zero.source=a[2],typeof a[1]>"u"?r.negative=r.positive:r.negative.source=a[1],W(r,(o,n)=>{if(n.parsed)return;let d=n.source;d.toLowerCase()==="number"&&(d=this.get("numberFormat","#,###.#####"));let m=J.chunk(d,!0);for(let l=0;l<m.length;l++){let c=m[l];if(c.text=c.text.replace(Mt,"|"),c.type==="value"){let h=c.text.match(/[#0.,]+[ ]?[abespABESP%!]?[abespABESP‰!]?/);if(h)if(h===null||h[0]==="")n.template+=c.text;else{let p=h[0].match(/[abespABESP%‰!]{2}|[abespABESP%‰]{1}$/);p&&(n.mod=p[0].toLowerCase(),n.modSpacing=!!h[0].match(/[ ]{1}[abespABESP%‰!]{1}$/));let _=h[0].split(".");if(_[0]!==""){n.thousands.active=(_[0].match(/0/g)||[]).length,n.thousands.passive=(_[0].match(/\#/g)||[]).length+n.thousands.active;let u=_[0].split(",");u.length===1||(n.thousands.interval=(u.pop()||"").length,n.thousands.interval===0&&(n.thousands.interval=-1))}typeof _[1]>"u"||(n.decimals.active=(_[1].match(/0/g)||[]).length,n.decimals.passive=(_[1].match(/\#/g)||[]).length+n.decimals.active),n.template+=c.text.split(h[0]).join(gt)}}else n.template+=c.text}n.parsed=!0}),r}applyFormat(t,e){let i=t<0;t=Math.abs(t);let s="",r="",a=e.mod?e.mod.split(""):[];if(a.indexOf("b")!==-1){let l=this.applyPrefix(t,this.get("bytePrefixes"),a.indexOf("!")!==-1);t=l[0],s=l[1],r=l[2],e.modSpacing&&(r=" "+r)}else if(a.indexOf("a")!==-1){let l=this.applyPrefix(t,t<this.get("smallNumberThreshold")?this.get("smallNumberPrefixes"):this.get("bigNumberPrefixes"),a.indexOf("!")!==-1);t=l[0],s=l[1],r=l[2],e.modSpacing&&(r=" "+r)}else if(a.indexOf("p")!==-1){let l=Math.min(t.toString().length+2,21);t=parseFloat(t.toPrecision(l)),s=this._root.language.translate("_percentPrefix"),r=this._root.language.translate("_percentSuffix"),s==""&&r==""&&(r="%")}else if(a.indexOf("%")!==-1){let l=Math.min(t.toString().length+2,21);t*=100,t=parseFloat(t.toPrecision(l)),r="%"}else if(a.indexOf("\u2030")!==-1){let l=Math.min(t.toString().length+3,21);t*=1e3,t=parseFloat(t.toPrecision(l)),r="\u2030"}if(a.indexOf("e")!==-1){let l;e.decimals.passive>=0?l=t.toExponential(e.decimals.passive).split("e"):l=t.toExponential().split("e"),t=Number(l[0]),r="e"+l[1],e.modSpacing&&(r=" "+r)}else if(e.decimals.passive===0)t=Math.round(t);else if(e.decimals.passive>0){let l=os(t);if(l>0){let c=Math.pow(10,e.decimals.passive);t=Math.round(parseFloat((t*c).toFixed(l)))/c}}let o="",n=Ui(t).split("."),d=n[0];if(d.length<e.thousands.active&&(d=Array(e.thousands.active-d.length+1).join("0")+d),e.thousands.interval>0){let l=[],c=d.split("").reverse().join("");for(let h=0,p=d.length;h<=p;h+=e.thousands.interval){let _=c.substr(h,e.thousands.interval).split("").reverse().join("");_!==""&&l.unshift(_)}d=l.join(e.thousands.separator)}o+=d,n.length===1&&n.push("");let m=n[1];return m.length<e.decimals.active&&(m+=Array(e.decimals.active-m.length+1).join("0")),m!==""&&(o+=e.decimals.separator+m),o===""&&(o="0"),t!==0&&i&&a.indexOf("s")===-1&&(o="-"+o),s&&(o=s+o),r&&(o+=r),o}applyPrefix(t,e,i=!1){let s=t,r="",a="",o=!1,n=1;for(let d=0,m=e.length;d<m;d++)e[d].number<=t&&(e[d].number===0?s=0:(s=t/e[d].number,n=e[d].number),r=e[d].prefix,a=e[d].suffix,o=!0);return!o&&i&&e.length&&t!=0&&(s=t/e[0].number,r=e[0].prefix,a=e[0].suffix,o=!0),o&&(s=parseFloat(s.toPrecision(Math.min(n.toString().length+Math.floor(s).toString().replace(/[^0-9]*/g,"").length,21)))),[s,r,a]}escape(t){return t.replace("||",Mt)}unescape(t){return t.replace(Mt,"|")}};function vs(g,t){let e=0,i=0,s=1,r=0,a=0,o=0,n=0,d=0;return g.formatToParts(t).forEach(m=>{switch(m.type){case"year":e=+m.value;break;case"month":i=+m.value-1;break;case"day":s=+m.value;break;case"hour":r=+m.value;break;case"minute":a=+m.value;break;case"second":o=+m.value;break;case"fractionalSecond":n=+m.value;break;case"weekday":switch(m.value){case"Sun":d=0;break;case"Mon":d=1;break;case"Tue":d=2;break;case"Wed":d=3;break;case"Thu":d=4;break;case"Fri":d=5;break;case"Sat":d=6;break}}}),r===24&&(r=0),{year:e,month:i,day:s,hour:r,minute:a,second:o,millisecond:n,weekday:d}}function bs(g,t){let{year:e,month:i,day:s,hour:r,minute:a,second:o,millisecond:n}=vs(g,t);return Date.UTC(e,i,s,r,a,o,n)}var Me=class{constructor(t,e){if(!e)throw new Error("You cannot use `new Class()`, instead use `Class.new()`");this.name=t,this._utc=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:"UTC",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",weekday:"short",fractionalSecondDigits:3}),this._dtf=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",weekday:"short",fractionalSecondDigits:3})}static new(t){return new this(t,!0)}convertLocal(t){let e=this.offsetUTC(t),i=t.getTimezoneOffset(),s=new Date(t);s.setUTCMinutes(s.getUTCMinutes()-(e-i));let r=s.getTimezoneOffset();return i!=r&&s.setUTCMinutes(s.getUTCMinutes()+r-i),s}offsetUTC(t){let e=bs(this._utc,t),i=bs(this._dtf,t);return(e-i)/6e4}parseDate(t){return vs(this._dtf,t)}};var Ee=class extends P{_setDefaults(){this._setDefault("capitalize",!0),this._setDefault("dateFormat","yyyy-MM-dd"),super._setDefaults()}_beforeChanged(){super._beforeChanged()}format(t,e,i=!1){(typeof e>"u"||e==="")&&(e=this.get("dateFormat","yyyy-MM-dd"));let s,r=t;if(Dt(e))try{let d=this.get("intlLocales");return d?new Intl.DateTimeFormat(d,e).format(r):new Intl.DateTimeFormat(void 0,e).format(r)}catch{return"Invalid"}let a=this.parseFormat(e),o=this._root.timezone,n=r;return o&&!this._root.utc&&!i&&(r=o.convertLocal(r)),M(r.getTime())?(s=this.applyFormat(r,a,i,n),this.get("capitalize")&&(s=s.replace(/^.{1}/,s.substr(0,1).toUpperCase())),s):"Invalid date"}applyFormat(t,e,i=!1,s){let r=e.template,a,o,n,d,m,l,c,h,p=t.getTime();this._root.utc&&!i?(a=t.getUTCFullYear(),o=t.getUTCMonth(),n=t.getUTCDay(),d=t.getUTCDate(),m=t.getUTCHours(),l=t.getUTCMinutes(),c=t.getUTCSeconds(),h=t.getUTCMilliseconds()):(a=t.getFullYear(),o=t.getMonth(),n=t.getDay(),d=t.getDate(),m=t.getHours(),l=t.getMinutes(),c=t.getSeconds(),h=t.getMilliseconds());for(let _=0,u=e.parts.length;_<u;_++){let f="";switch(e.parts[_]){case"G":f=this._t(a<0?"_era_bc":"_era_ad");break;case"yyyy":f=Math.abs(a).toString(),a<0&&(f+=this._t("_era_bc"));break;case"yyy":case"yy":case"y":f=Math.abs(a).toString().substr(-e.parts[_].length),a<0&&(f+=this._t("_era_bc"));break;case"YYYY":case"YYY":case"YY":case"Y":let b=hs(t,this._root.utc);e.parts[_]=="YYYY"?f=Math.abs(b).toString():f=Math.abs(b).toString().substr(-e.parts[_].length),b<0&&(f+=this._t("_era_bc"));break;case"u":break;case"q":f=""+Math.ceil((t.getMonth()+1)/3);break;case"MMMMM":f=this._t(this._getMonth(o)).substr(0,1);break;case"MMMM":f=this._t(this._getMonth(o));break;case"MMM":f=this._t(this._getShortMonth(o));break;case"MM":f=O(o+1,2,"0");break;case"M":f=(o+1).toString();break;case"ww":f=O(ni(t,this._root.utc),2,"0");break;case"w":f=ni(t,this._root.utc).toString();break;case"W":f=ls(t,this._root.utc).toString();break;case"dd":f=O(d,2,"0");break;case"d":f=d.toString();break;case"DD":case"DDD":f=O(oi(t,this._root.utc).toString(),e.parts[_].length,"0");break;case"D":f=oi(t,this._root.utc).toString();break;case"F":break;case"g":break;case"t":f=this._root.language.translateFunc("_dateOrd").call(this,d);break;case"E":f=(n||7).toString();break;case"EE":f=O((n||7).toString(),2,"0");break;case"EEE":case"eee":f=this._t(this._getShortWeekday(n));break;case"EEEE":case"eeee":f=this._t(this._getWeekday(n));break;case"EEEEE":case"eeeee":f=this._t(this._getShortWeekday(n)).substr(0,1);break;case"e":case"ee":f=(n-(this._root.locale.firstDayOfWeek||1)+1).toString(),e.parts[_]=="ee"&&(f=O(f,2,"0"));break;case"a":m>=12?f=this._t("PM"):f=this._t("AM");break;case"aa":m>=12?f=this._t("P.M."):f=this._t("A.M.");break;case"aaa":m>=12?f=this._t("P"):f=this._t("A");break;case"h":f=Te(m).toString();break;case"hh":f=O(Te(m),2,"0");break;case"H":f=m.toString();break;case"HH":f=O(m,2,"0");break;case"K":f=Te(m,0).toString();break;case"KK":f=O(Te(m,0),2,"0");break;case"k":f=(m+1).toString();break;case"kk":f=O(m+1,2,"0");break;case"m":f=l.toString();break;case"mm":f=O(l,2,"0");break;case"s":f=c.toString();break;case"ss":f=O(c,2,"0");break;case"S":case"SS":case"SSS":f=Math.round(h/1e3*Math.pow(10,e.parts[_].length)).toString();break;case"x":f=p.toString();break;case"n":case"nn":case"nnn":f=O(h,e.parts[_].length,"0");break;case"z":f=Ce(s||t,!1,!1,this._root.utc,this._root.timezone?this._root.timezone.name:void 0).replace(/[+-]+[0-9]+$/,"");break;case"zz":f=Ce(s||t,!0,!1,this._root.utc,this._root.timezone?this._root.timezone.name:void 0);break;case"zzz":f=Ce(s||t,!1,!0,this._root.utc,this._root.timezone?this._root.timezone.name:void 0).replace(/[+-]+[0-9]+$/,"");break;case"zzzz":f=Ce(s||t,!0,!0,this._root.utc,this._root.timezone?this._root.timezone.name:void 0);break;case"Z":case"ZZ":let x=this._root.utc?"UTC":this._root.timezone;x instanceof Me&&(x=x.name);let y=x?ds(x,s||t):t.getTimezoneOffset(),w=Math.abs(y)/60,T=Math.floor(w),k=w*60-T*60;this._root.utc&&(T=0,k=0),e.parts[_]=="Z"?(f="GMT",f+=y>0?"-":"+",f+=O(T,2)+":"+O(k,2)):(f=y>0?"-":"+",f+=O(T,2)+O(k,2));break;case"i":f=t.toISOString();break;case"I":f=t.toUTCString();break}r=r.replace(gt,f)}return r}parseFormat(t){let e={template:"",parts:[]},i=J.chunk(t,!0);for(let s=0;s<i.length;s++){let r=i[s];if(r.type==="value"){if(r.text.match(/^date$/i)){let o=this.get("dateFormat","yyyy-MM-dd");mt(o)||(o="yyyy-MM-dd"),r.text=o}let a=r.text.match(/G|yyyy|yyy|yy|y|YYYY|YYY|YY|Y|u|q|MMMMM|MMMM|MMM|MM|M|ww|w|W|dd|d|DDD|DD|D|F|g|EEEEE|EEEE|EEE|EE|E|eeeee|eeee|eee|ee|e|aaa|aa|a|hh|h|HH|H|KK|K|kk|k|mm|m|ss|s|SSS|SS|S|A|zzzz|zzz|zz|z|ZZ|Z|t|x|nnn|nn|n|i|I/g);if(a)for(let o=0;o<a.length;o++)e.parts.push(a[o]),r.text=r.text.replace(a[o],gt)}e.template+=r.text}return e}_months(){return["January","February","March","April","May","June","July","August","September","October","November","December"]}_getMonth(t){return this._months()[t]}_shortMonths(){return["Jan","Feb","Mar","Apr","May(short)","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}_getShortMonth(t){return this._shortMonths()[t]}_weekdays(){return["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]}_getWeekday(t){return this._weekdays()[t]}_shortWeekdays(){return["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]}_getShortWeekday(t){return this._shortWeekdays()[t]}parse(t,e,i){if(typeof i>"u"&&(i=this._root.utc),t instanceof Date)return t;if(M(t))return new Date(t);if(e=="x")return new Date(parseInt(t));mt(t)||(t=t.toString());let s,r="";e=Ut(e),e=e.substr(0,t.length);let a=this.parseFormat(e),o={year:-1,year3:-1,year2:-1,year1:-1,month:-1,monthShort:-1,monthLong:-1,weekdayShort:-1,weekdayLong:-1,day:-1,yearDay:-1,week:-1,hourBase0:-1,hour12Base0:-1,hourBase1:-1,hour12Base1:-1,minute:-1,second:-1,millisecond:-1,millisecondDigits:-1,am:-1,zone:-1,timestamp:-1,iso:-1},n={year:1970,month:0,day:1,hour:0,minute:0,second:0,millisecond:0,timestamp:null,offset:0,utc:i},d=0,m=0;for(let h=0;h<a.parts.length;h++){switch(m=h+d+1,a.parts[h]){case"yyyy":case"YYYY":r+="([0-9]{4})",o.year=m;break;case"yyy":case"YYY":r+="([0-9]{3})",o.year3=m;break;case"yy":case"YY":r+="([0-9]{2})",o.year2=m;break;case"y":case"Y":r+="([0-9]{1})",o.year1=m;break;case"MMMM":r+="("+this.getStringList(this._months()).join("|")+")",o.monthLong=m;break;case"MMM":r+="("+this.getStringList(this._shortMonths()).join("|")+")",o.monthShort=m;break;case"MM":case"M":r+="([0-9]{2}|[0-9]{1})",o.month=m;break;case"ww":case"w":r+="([0-9]{2}|[0-9]{1})",o.week=m;break;case"dd":case"d":r+="([0-9]{2}|[0-9]{1})",o.day=m;break;case"DDD":case"DD":case"D":r+="([0-9]{3}|[0-9]{2}|[0-9]{1})",o.yearDay=m;break;case"dddd":r+="("+this.getStringList(this._weekdays()).join("|")+")",o.weekdayLong=m;break;case"ddd":r+="("+this.getStringList(this._shortWeekdays()).join("|")+")",o.weekdayShort=m;break;case"aaa":case"aa":case"a":r+="("+this.getStringList(["AM","PM","A.M.","P.M.","A","P"]).join("|")+")",o.am=m;break;case"hh":case"h":r+="([0-9]{2}|[0-9]{1})",o.hour12Base1=m;break;case"HH":case"H":r+="([0-9]{2}|[0-9]{1})",o.hourBase0=m;break;case"KK":case"K":r+="([0-9]{2}|[0-9]{1})",o.hour12Base0=m;break;case"kk":case"k":r+="([0-9]{2}|[0-9]{1})",o.hourBase1=m;break;case"mm":case"m":r+="([0-9]{2}|[0-9]{1})",o.minute=m;break;case"ss":case"s":r+="([0-9]{2}|[0-9]{1})",o.second=m;break;case"SSS":case"SS":case"S":r+="([0-9]{3}|[0-9]{2}|[0-9]{1})",o.millisecond=m,o.millisecondDigits=a.parts[h].length;break;case"nnn":case"nn":case"n":r+="([0-9]{3}|[0-9]{2}|[0-9]{1})",o.millisecond=m;break;case"x":r+="([0-9]{1,})",o.timestamp=m;break;case"Z":r+="GMT([-+]+[0-9]{2}:[0-9]{2})",o.zone=m;break;case"ZZ":r+="([\\-+]+[0-9]{2}[0-9]{2})",o.zone=m;break;case"i":r+="([0-9]{4})-?([0-9]{2})-?([0-9]{2})T?([0-9]{2}):?([0-9]{2}):?([0-9]{2})\\.?([0-9]{0,3})([zZ]|[+\\-][0-9]{2}:?[0-9]{2}|$)",o.iso=m,d+=7;break;case"G":case"YYYY":case"YYY":case"YY":case"Y":case"MMMMM":case"W":case"EEEEE":case"EEEE":case"EEE":case"EE":case"E":case"eeeee":case"eeee":case"eee":case"ee":case"e":case"zzzz":case"zzz":case"zz":case"z":case"t":d--;break}r+="[^0-9]*"}let l=new RegExp(r),c=t.match(l);if(c){if(o.year>-1&&(n.year=parseInt(c[o.year])),o.year3>-1){let h=parseInt(c[o.year3]);h+=1e3,n.year=h}if(o.year2>-1){let h=parseInt(c[o.year2]);h>50?h+=1e3:h+=2e3,n.year=h}if(o.year1>-1){let h=parseInt(c[o.year1]);h=Math.floor(new Date().getFullYear()/10)*10+h,n.year=h}if(o.monthLong>-1&&(n.month=this.resolveMonth(c[o.monthLong])),o.monthShort>-1&&(n.month=this.resolveShortMonth(c[o.monthShort])),o.month>-1&&(n.month=parseInt(c[o.month])-1),o.week>-1&&o.day===-1&&(n.month=0,n.day=cs(parseInt(c[o.week]),n.year,1,i)),o.day>-1&&(n.day=parseInt(c[o.day])),o.yearDay>-1&&(n.month=0,n.day=parseInt(c[o.yearDay])),o.hourBase0>-1&&(n.hour=parseInt(c[o.hourBase0])),o.hourBase1>-1&&(n.hour=parseInt(c[o.hourBase1])-1),o.hour12Base0>-1){let h=parseInt(c[o.hour12Base0]);h==11&&(h=0),o.am>-1&&!this.isAm(c[o.am])&&(h+=12),n.hour=h}if(o.hour12Base1>-1){let h=parseInt(c[o.hour12Base1]);h==12&&(h=0),o.am>-1&&!this.isAm(c[o.am])&&(h+=12),n.hour=h}if(o.minute>-1&&(n.minute=parseInt(c[o.minute])),o.second>-1&&(n.second=parseInt(c[o.second])),o.millisecond>-1){let h=parseInt(c[o.millisecond]);o.millisecondDigits==2?h*=10:o.millisecondDigits==1&&(h*=100),n.millisecond=h}if(o.timestamp>-1){n.timestamp=parseInt(c[o.timestamp]);let h=new Date(n.timestamp);n.year=h.getUTCFullYear(),n.month=h.getUTCMonth(),n.day=h.getUTCDate(),n.hour=h.getUTCHours(),n.minute=h.getUTCMinutes(),n.second=h.getUTCSeconds(),n.millisecond=h.getUTCMilliseconds()}o.zone>-1&&(n.offset=this.resolveTimezoneOffset(new Date(n.year,n.month,n.day),c[o.zone])),o.iso>-1&&(n.year=X(c[o.iso+0]),n.month=X(c[o.iso+1])-1,n.day=X(c[o.iso+2]),n.hour=X(c[o.iso+3]),n.minute=X(c[o.iso+4]),n.second=X(c[o.iso+5]),n.millisecond=X(c[o.iso+6]),c[o.iso+7]=="Z"||c[o.iso+7]=="z"?n.utc=!0:c[o.iso+7]!=""&&(n.offset=this.resolveTimezoneOffset(new Date(n.year,n.month,n.day),c[o.iso+7]))),n.utc?s=new Date(Date.UTC(n.year,n.month,n.day,n.hour,n.minute,n.second,n.millisecond)):s=new Date(n.year,n.month,n.day,n.hour,n.minute+n.offset,n.second,n.millisecond)}else s=new Date(t);return s}resolveTimezoneOffset(t,e){if(e.match(/([+\-]?)([0-9]{2}):?([0-9]{2})/)){let s=e.match(/([+\-]?)([0-9]{2}):?([0-9]{2})/),r=s[1],a=s[2],o=s[3],n=parseInt(a)*60+parseInt(o);r=="+"&&(n*=-1);let d=(t||new Date).getTimezoneOffset();return n-d}return 0}resolveMonth(t){let e=this._months().indexOf(t);return e>-1||!this._root.language.isDefault()&&(e=this._root.language.translateAll(this._months()).indexOf(t),e>-1)?e:0}resolveShortMonth(t){let e=this._shortMonths().indexOf(t);return e>-1||(e=this._months().indexOf(t),e>-1)||this._root.language&&!this._root.language.isDefault()&&(e=this._root.language.translateAll(this._shortMonths()).indexOf(t),e>-1)?e:0}isAm(t){return this.getStringList(["AM","A.M.","A"]).indexOf(t.toUpperCase())>-1}getStringList(t){let e=[];for(let i=0;i<t.length;i++)this._root.language?e.push(ai(this._t(t[i]))):e.push(ai(t[i]));return e}};var $e=class extends P{constructor(){super(...arguments),this._unitAliases={Y:"y",D:"d",H:"h",K:"h",k:"h",n:"S"}}_setDefaults(){let t="_duration_millisecond",e="_duration_second",i="_duration_minute",s="_duration_hour",r="_duration_day",a="_duration_week",o="_duration_month",n="_duration_year",d="_second",m="_minute",l="_hour",c="_day",h="_week",p="_week",_="_year";this._setDefault("negativeBase",0),this._setDefault("baseUnit","second"),this._setDefault("durationFormats",{millisecond:{millisecond:this._t(t),second:this._t(t+d),minute:this._t(t+m),hour:this._t(t+l),day:this._t(t+c),week:this._t(t+h),month:this._t(t+p),year:this._t(t+_)},second:{second:this._t(e),minute:this._t(e+m),hour:this._t(e+l),day:this._t(e+c),week:this._t(e+h),month:this._t(e+p),year:this._t(e+_)},minute:{minute:this._t(i),hour:this._t(i+l),day:this._t(i+c),week:this._t(i+h),month:this._t(i+p),year:this._t(i+_)},hour:{hour:this._t(s),day:this._t(s+c),week:this._t(s+h),month:this._t(s+p),year:this._t(s+_)},day:{day:this._t(r),week:this._t(r+h),month:this._t(r+p),year:this._t(r+_)},week:{week:this._t(a),month:this._t(a+p),year:this._t(a+_)},month:{month:this._t(o),year:this._t(o+_)},year:{year:this._t(n)}}),super._setDefaults()}_beforeChanged(){super._beforeChanged()}format(t,e,i){let s=i||this.get("baseUnit");(typeof e>"u"||e==="")&&(this.get("durationFormat")!=null?e=this.get("durationFormat"):e=this.getFormat(X(t),void 0,s)),e=Ut(e);let r=this.parseFormat(e,s),a=Number(t),o;a>this.get("negativeBase")?o=r.positive:a<this.get("negativeBase")?o=r.negative:o=r.zero;let n=this.applyFormat(a,o);return o.color!==""&&(n="["+o.color+"]"+n+"[/]"),n}parseFormat(t,e){let i=e||this.get("baseUnit"),s={positive:{color:"",template:"",parts:[],source:"",baseUnit:i,parsed:!1,absolute:!1},negative:{color:"",template:"",parts:[],source:"",baseUnit:i,parsed:!1,absolute:!1},zero:{color:"",template:"",parts:[],source:"",baseUnit:i,parsed:!1,absolute:!1}};t=t.replace("||",Mt);let r=t.split("|");return s.positive.source=r[0],typeof r[2]>"u"?s.zero=s.positive:s.zero.source=r[2],typeof r[1]>"u"?s.negative=s.positive:s.negative.source=r[1],W(s,(a,o)=>{if(o.parsed)return;let n=o.source,d=[];d=o.source.match(/^\[([^\]]*)\]/),d&&d.length&&d[0]!==""&&(n=o.source.substr(d[0].length),o.color=d[1]);let m=J.chunk(n,!0);for(let l=0;l<m.length;l++){let c=m[l];if(c.text=c.text.replace(Mt,"|"),c.type==="value"){c.text.match(/[yYMdDwhHKkmsSn]+a/)&&(o.absolute=!0,c.text=c.text.replace(/([yYMdDwhHKkmsSn]+)a/,"$1"));let h=c.text.match(/y+|Y+|M+|d+|D+|w+|h+|H+|K+|k+|m+|s+|S+|n+/g);if(h)for(let p=0;p<h.length;p++)h[p]==null&&(h[p]=this._unitAliases[h[p]]),o.parts.push(h[p]),c.text=c.text.replace(h[p],gt)}o.template+=c.text}o.parsed=!0}),s}applyFormat(t,e){let i=!e.absolute&&t<this.get("negativeBase");t=Math.abs(t);let s=this.toTimeStamp(t,e.baseUnit),r=e.template,a={millisecond:0,second:0,minute:0,hour:0,day:0,week:0,month:0,year:0};for(let o=0,n=e.parts.length;o<n;o++){let d=e.parts[o],m=this._toTimeUnit(d.substr(0,1)),l,c=this._getUnitValue(m);o<n-1?l=Math.floor(s/c):l=Math.round(s/c),a[m]+=l,s-=l*c}W(a,(o,n)=>{o=="millisecond"&&n==1e3?(a.second++,a.millisecond=0):o=="second"&&n==60?(a.minute++,a.second=0):o=="minute"&&n==60?(a.hour++,a.minute=0):o=="hour"&&n==24?(a.day++,a.hour=0):o=="day"&&n==7&&e.parts.indexOf("w")!==-1?(a.week++,a.day=0):o=="day"&&n==30?(a.month++,a.day=0):o=="month"&&n==12&&(a.year++,a.month=0)});for(let o=0,n=e.parts.length;o<n;o++){let d=e.parts[o],m=this._toTimeUnit(d.substr(0,1)),l=d.length;r=r.replace(gt,O(a[m],l,"0"))}return i&&(r="-"+r),r}toTimeStamp(t,e){return t*this._getUnitValue(e)}_toTimeUnit(t){switch(t){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year"}}getFormat(t,e,i){if(this.get("durationFormat")!=null)return this.get("durationFormat");if(i||(i=this.get("baseUnit")),e!=null&&t!=e){t=Math.abs(t),e=Math.abs(e);let s=this.getValueUnit(Math.max(t,e),i);return this.get("durationFormats")[i][s]}else{let s=this.getValueUnit(t,i);return this.get("durationFormats")[i][s]}}getValueUnit(t,e){e||(e=this.get("baseUnit"));let i,s=this.getMilliseconds(t,e);return Ji(this._getUnitValues(),(r,a)=>{if(r==e||i){if(s/a<=1)return i||(i=r),!1;i=r}return!0}),i}getMilliseconds(t,e){return e||(e=this.get("baseUnit")),t*this._getUnitValue(e)}_getUnitValue(t){return this._getUnitValues()[t]}_getUnitValues(){return{millisecond:1,second:1e3,minute:6e4,hour:36e5,day:864e5,week:6048e5,month:2592e6,year:31536e6}}};var je={firstDayOfWeek:1,_decimalSeparator:".",_thousandSeparator:",",_percentPrefix:null,_percentSuffix:"%",_big_number_suffix_3:"k",_big_number_suffix_6:"M",_big_number_suffix_9:"G",_big_number_suffix_12:"T",_big_number_suffix_15:"P",_big_number_suffix_18:"E",_big_number_suffix_21:"Z",_big_number_suffix_24:"Y",_small_number_suffix_3:"m",_small_number_suffix_6:"\u03BC",_small_number_suffix_9:"n",_small_number_suffix_12:"p",_small_number_suffix_15:"f",_small_number_suffix_18:"a",_small_number_suffix_21:"z",_small_number_suffix_24:"y",_byte_suffix_B:"B",_byte_suffix_KB:"KB",_byte_suffix_MB:"MB",_byte_suffix_GB:"GB",_byte_suffix_TB:"TB",_byte_suffix_PB:"PB",_date:"yyyy-MM-dd",_date_millisecond:"mm:ss SSS",_date_millisecond_full:"HH:mm:ss SSS",_date_second:"HH:mm:ss",_date_second_full:"HH:mm:ss",_date_minute:"HH:mm",_date_minute_full:"HH:mm - MMM dd, yyyy",_date_hour:"HH:mm",_date_hour_short:"HH",_date_hour_full:"HH:mm - MMM dd, yyyy",_date_day:"MMM dd",_date_day_full:"MMM dd, yyyy",_date_week:"ww",_date_week_full:"MMM dd, yyyy",_date_month:"MMM",_date_month_full:"MMM, yyyy",_date_year:"yyyy",_duration_millisecond:"SSS",_duration_millisecond_second:"ss.SSS",_duration_millisecond_minute:"mm:ss SSS",_duration_millisecond_hour:"hh:mm:ss SSS",_duration_millisecond_day:"d'd' mm:ss SSS",_duration_millisecond_week:"d'd' mm:ss SSS",_duration_millisecond_month:"M'm' dd'd' mm:ss SSS",_duration_millisecond_year:"y'y' MM'm' dd'd' mm:ss SSS",_duration_second:"ss",_duration_second_minute:"mm:ss",_duration_second_hour:"hh:mm:ss",_duration_second_day:"d'd' hh:mm:ss",_duration_second_week:"d'd' hh:mm:ss",_duration_second_month:"M'm' dd'd' hh:mm:ss",_duration_second_year:"y'y' MM'm' dd'd' hh:mm:ss",_duration_minute:"mm",_duration_minute_hour:"hh:mm",_duration_minute_day:"d'd' hh:mm",_duration_minute_week:"d'd' hh:mm",_duration_minute_month:"M'm' dd'd' hh:mm",_duration_minute_year:"y'y' MM'm' dd'd' hh:mm",_duration_hour:"hh'h'",_duration_hour_day:"d'd' hh'h'",_duration_hour_week:"d'd' hh'h'",_duration_hour_month:"M'm' dd'd' hh'h'",_duration_hour_year:"y'y' MM'm' dd'd' hh'h'",_duration_day:"d'd'",_duration_day_week:"d'd'",_duration_day_month:"M'm' dd'd'",_duration_day_year:"y'y' MM'm' dd'd'",_duration_week:"w'w'",_duration_week_month:"w'w'",_duration_week_year:"w'w'",_duration_month:"M'm'",_duration_month_year:"y'y' MM'm'",_duration_year:"y'y'",_era_ad:"AD",_era_bc:"BC",A:"",P:"",AM:"",PM:"","A.M.":"","P.M.":"",January:"",February:"",March:"",April:"",May:"",June:"",July:"",August:"",September:"",October:"",November:"",December:"",Jan:"",Feb:"",Mar:"",Apr:"","May(short)":"May",Jun:"",Jul:"",Aug:"",Sep:"",Oct:"",Nov:"",Dec:"",Sunday:"",Monday:"",Tuesday:"",Wednesday:"",Thursday:"",Friday:"",Saturday:"",Sun:"",Mon:"",Tue:"",Wed:"",Thu:"",Fri:"",Sat:"",_dateOrd:function(g){let t="th";if(g<11||g>13)switch(g%10){case 1:t="st";break;case 2:t="nd";break;case 3:t="rd";break}return t},"Zoom Out":"",Play:"",Stop:"",Legend:"","Press ENTER to toggle":"",Loading:"",Home:"",Chart:"","Serial chart":"","X/Y chart":"","Pie chart":"","Gauge chart":"","Radar chart":"","Sankey diagram":"","Flow diagram":"","Chord diagram":"","TreeMap chart":"","Force directed tree":"","Sliced chart":"",Series:"","Candlestick Series":"","OHLC Series":"","Column Series":"","Line Series":"","Pie Slice Series":"","Funnel Series":"","Pyramid Series":"","X/Y Series":"",Map:"","Press ENTER to zoom in":"","Press ENTER to zoom out":"","Use arrow keys to zoom in and out":"","Use plus and minus keys on your keyboard to zoom in and out":"",Export:"",Image:"",Data:"",Print:"","Press ENTER or use arrow keys to navigate":"","Press ENTER to open":"","Press ENTER to print.":"","Press ENTER to export as %1.":"","(Press ESC to close this message)":"","Image Export Complete":"","Export operation took longer than expected. Something might have gone wrong.":"","Saved from":"",PNG:"",JPG:"",GIF:"",SVG:"",PDF:"",JSON:"",CSV:"",XLSX:"",HTML:"","Use TAB to select grip buttons or left and right arrows to change selection":"","Use left and right arrows to move selection":"","Use left and right arrows to move left selection":"","Use left and right arrows to move right selection":"","Use TAB select grip buttons or up and down arrows to change selection":"","Use up and down arrows to move selection":"","Use up and down arrows to move lower selection":"","Use up and down arrows to move upper selection":"","From %1 to %2":"","From %1":"","To %1":"","No parser available for file: %1":"","Error parsing file: %1":"","Unable to load file: %1":"","Invalid date":"",Close:"",Minimize:"",Confirm:""};var Ze=class extends P{_setDefaults(){this.setPrivate("defaultLocale",je),super._setDefaults()}translate(t,e,...i){e||(e=this._root.locale||this.getPrivate("defaultLocale"));let s=t,r=e[t];if(r===null)s="";else if(r!=null)r&&(s=r);else if(e!==this.getPrivate("defaultLocale"))return this.translate(t,this.getPrivate("defaultLocale"),...i);if(i.length)for(let a=i.length,o=0;o<a;++o)s=s.split("%"+(o+1)).join(i[o]);return s}translateAny(t,e,...i){return this.translate(t,e,...i)}setTranslationAny(t,e,i){let s=i||this._root.locale;s[t]=e}setTranslationsAny(t,e){W(t,(i,s)=>{this.setTranslationAny(i,s,e)})}translateEmpty(t,e,...i){let s=this.translate(t,e,...i);return s==t?"":s}translateFunc(t,e){return this._root.locale[t]?this._root.locale[t]:e!==this.getPrivate("defaultLocale")?this.translateFunc(t,this.getPrivate("defaultLocale")):()=>""}translateAll(t,e){return this.isDefault()?t:Zi(t,i=>this.translate(i,e))}isDefault(){return this.getPrivate("defaultLocale")===this._root.locale}};var Zt=class{constructor(t=1,e=0,i=0,s=1,r=0,a=0){this.a=t,this.b=e,this.c=i,this.d=s,this.tx=r,this.ty=a}setTransform(t,e,i,s,r,a=1){this.a=Math.cos(r)*a,this.b=Math.sin(r)*a,this.c=-Math.sin(r)*a,this.d=Math.cos(r)*a,this.tx=t-(i*this.a+s*this.c),this.ty=e-(i*this.b+s*this.d)}apply(t){return{x:this.a*t.x+this.c*t.y+this.tx,y:this.b*t.x+this.d*t.y+this.ty}}applyInverse(t){let e=1/(this.a*this.d+this.c*-this.b);return{x:this.d*e*t.x+-this.c*e*t.y+(this.ty*this.c-this.tx*this.d)*e,y:this.a*e*t.y+-this.b*e*t.x+(-this.ty*this.a+this.tx*this.b)*e}}append(t){let e=this.a,i=this.b,s=this.c,r=this.d;this.a=t.a*e+t.b*s,this.b=t.a*i+t.b*r,this.c=t.c*e+t.d*s,this.d=t.c*i+t.d*r,this.tx=t.tx*e+t.ty*s+this.tx,this.ty=t.tx*i+t.ty*r+this.ty}prepend(t){let e=this.tx;if(t.a!==1||t.b!==0||t.c!==0||t.d!==1){let i=this.a,s=this.c;this.a=i*t.a+this.b*t.c,this.b=i*t.b+this.b*t.d,this.c=s*t.a+this.d*t.c,this.d=s*t.b+this.d*t.d}this.tx=e*t.a+this.ty*t.c+t.tx,this.ty=e*t.b+this.ty*t.d+t.ty}copyFrom(t){this.a=t.a,this.b=t.b,this.c=t.c,this.d=t.d,this.tx=t.tx,this.ty=t.ty}};var As=(function(){function g(t,e){var i=[],s=!0,r=!1,a=void 0;try{for(var o=t[Symbol.iterator](),n;!(s=(n=o.next()).done)&&(i.push(n.value),!(e&&i.length===e));s=!0);}catch(d){r=!0,a=d}finally{try{!s&&o.return&&o.return()}finally{if(r)throw a}}return i}return function(t,e){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return g(t,e);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),Be=Math.PI*2,gi=function(t,e,i,s,r,a,o){var n=t.x,d=t.y;n*=e,d*=i;var m=s*n-r*d,l=r*n+s*d;return{x:m+a,y:l+o}},Ns=function(t,e){var i=e===1.5707963267948966?.551915024494:e===-1.5707963267948966?-.551915024494:1.3333333333333333*Math.tan(e/4),s=Math.cos(t),r=Math.sin(t),a=Math.cos(t+e),o=Math.sin(t+e);return[{x:s-r*i,y:r+s*i},{x:a+o*i,y:o-a*i},{x:a,y:o}]},ws=function(t,e,i,s){var r=t*s-e*i<0?-1:1,a=t*i+e*s;return a>1&&(a=1),a<-1&&(a=-1),r*Math.acos(a)},zs=function(t,e,i,s,r,a,o,n,d,m,l,c){var h=Math.pow(r,2),p=Math.pow(a,2),_=Math.pow(l,2),u=Math.pow(c,2),f=h*p-h*u-p*_;f<0&&(f=0),f/=h*u+p*_,f=Math.sqrt(f)*(o===n?-1:1);var b=f*r/a*c,x=f*-a/r*l,y=m*b-d*x+(t+i)/2,w=d*b+m*x+(e+s)/2,T=(l-b)/r,k=(c-x)/a,E=(-l-b)/r,R=(-c-x)/a,D=ws(1,0,T,k),S=ws(T,k,E,R);return n===0&&S>0&&(S-=Be),n===1&&S<0&&(S+=Be),[y,w,D,S]},Fs=function(t){var e=t.px,i=t.py,s=t.cx,r=t.cy,a=t.rx,o=t.ry,n=t.xAxisRotation,d=n===void 0?0:n,m=t.largeArcFlag,l=m===void 0?0:m,c=t.sweepFlag,h=c===void 0?0:c,p=[];if(a===0||o===0)return[];var _=Math.sin(d*Be/360),u=Math.cos(d*Be/360),f=u*(e-s)/2+_*(i-r)/2,b=-_*(e-s)/2+u*(i-r)/2;if(f===0&&b===0)return[];a=Math.abs(a),o=Math.abs(o);var x=Math.pow(f,2)/Math.pow(a,2)+Math.pow(b,2)/Math.pow(o,2);x>1&&(a*=Math.sqrt(x),o*=Math.sqrt(x));var y=zs(e,i,s,r,a,o,l,h,_,u,f,b),w=As(y,4),T=w[0],k=w[1],E=w[2],R=w[3],D=Math.abs(R)/(Be/4);Math.abs(1-D)<1e-7&&(D=1);var S=Math.max(Math.ceil(D),1);R/=S;for(var Y=0;Y<S;Y++)p.push(Ns(E,R)),E+=R;return p.map(function(H){var Xt=gi(H[0],a,o,u,_,T,k),G=Xt.x,ti=Xt.y,A=gi(H[1],a,o,u,_,T,k),et=A.x,ot=A.y,ft=gi(H[2],a,o,u,_,T,k),ge=ft.x,nt=ft.y;return{x1:G,y1:ti,x2:et,y2:ot,x:ge,y:nt}})},ks=Fs;function Rs(g,t,e){if(t!==e)throw new Error("Required "+e+" arguments for "+g+" but got "+t)}function Pe(g,t,e){if(t<e)throw new Error("Required at least "+e+" arguments for "+g+" but got "+t)}function tt(g,t,e){if(Pe(g,t,e),t%e!==0)throw new Error("Arguments for "+g+" must be in pairs of "+e)}function Os(g){for(let t=0;t<g.length;t+=7){let e=t+3,i=g[e];if(i.length>1){let s=/^([01])([01])(.*)$/.exec(i);s!==null&&(g.splice(e,0,s[1]),++e,g.splice(e,0,s[2]),++e,s[3].length>0?g[e]=s[3]:g.splice(e,1))}if(++e,i=g[e],i.length>1){let s=/^([01])(.+)$/.exec(i);s!==null&&(g.splice(e,0,s[1]),++e,g[e]=s[2])}}}function Ts(g){if(g===0||g===1)return g;throw new Error("Flag must be 0 or 1")}function Hs(g){let t=[0,0,0];for(let e=0;e<24;e++)t[e%3]<<=1,t[e%3]|=g&1,g>>=1;return(t[0]|0)+(t[1]<<8)+(t[2]<<16)}function qe(g,t){for(;!(g.interactive&&!t(g));)if(g._parent)g=g._parent;else break}function Ys(g,t,e){return $(g,Oe(t),i=>{let s=si(i),r=i.touches;r?(r.length==0&&(r=i.changedTouches),e(Gt(r),s)):e([i],s)})}function Cs(g){let t=document.createElement("canvas");t.width=1,t.height=1;let e=t.getContext("2d",{willReadFrequently:!0});e.drawImage(g,0,0,1,1);try{return e.getImageData(0,0,1,1),!1}catch{return console.warn('Image "'+g.src+'" is loaded from different host and is not covered by CORS policy. For more information about the implications read here: https://www.amcharts.com/docs/v5/concepts/cors'),!0}}function Le(g){g.width=0,g.height=0,g.style.width="0px",g.style.height="0px"}function Ss(g){return Math.floor(g)+.5}var _i=class{constructor(){this._x=0,this._y=0}get x(){return this._x}get y(){return this._y}set x(t){this._x=t}set y(t){this._y=t}},qt=class extends Qi{constructor(t){super(),this.mask=null,this.visible=!0,this.exportable=!0,this.interactive=!1,this.inactive=null,this.wheelable=!1,this.cancelTouch=!1,this.isMeasured=!1,this.buttonMode=!1,this.alpha=1,this.compoundAlpha=1,this.angle=0,this.scale=1,this.x=0,this.y=0,this.crisp=!1,this.pivot=new _i,this._localMatrix=new Zt,this._matrix=new Zt,this._uMatrix=new Zt,this._renderer=t}subStatus(t){return{inactive:this.inactive==null?t.inactive:this.inactive,layer:this._layer||t.layer}}_dispose(){this._renderer._removeObject(this),this.getLayer().dirty=!0}getCanvas(){return this.getLayer().view}getLayer(){let t=this;for(;;){if(t._layer)return t._layer;if(t._parent)t=t._parent;else return this._renderer.defaultLayer}}setLayer(t,e){t==null?this._layer=void 0:(this._layer=this._renderer.getLayer(t,!0),this._layer.visible=!0,this._layer.margin=e,e&&$t(this._layer.view,!1),this._renderer._ghostLayer.setMargin(this._renderer.layers),this._parent&&this._parent.registerChildLayer(this._layer),this._layer.dirty=!0,this._renderer.resizeLayer(this._layer),this._renderer.resizeGhost())}markDirtyLayer(){this.getLayer().dirty=!0}clear(){this.invalidateBounds()}invalidateBounds(){this._localBounds=void 0}_addBounds(t){}_getColorId(){return this._colorId===void 0&&(this._colorId=this._renderer.paintId(this)),this._colorId}_isInteractive(t){return!t.inactive&&(this.interactive||this._renderer._forceInteractive>0)}_isInteractiveMask(t){return this._isInteractive(t)}contains(t){for(;;){if(t===this)return!0;if(t._parent)t=t._parent;else return!1}}toGlobal(t){return this._matrix.apply(t)}toLocal(t){return this._matrix.applyInverse(t)}getLocalMatrix(){return this._uMatrix.setTransform(0,0,this.pivot.x,this.pivot.y,this.angle*Math.PI/180,this.scale),this._uMatrix}getLocalBounds(){return this._localBounds||(this._localBounds={left:1e7,top:1e7,right:-1e7,bottom:-1e7},this._addBounds(this._localBounds)),this._localBounds}getAdjustedBounds(t){this._setMatrix();let e=this.getLocalMatrix(),i=e.apply({x:t.left,y:t.top}),s=e.apply({x:t.right,y:t.top}),r=e.apply({x:t.right,y:t.bottom}),a=e.apply({x:t.left,y:t.bottom});return{left:Math.min(i.x,s.x,r.x,a.x),top:Math.min(i.y,s.y,r.y,a.y),right:Math.max(i.x,s.x,r.x,a.x),bottom:Math.max(i.y,s.y,r.y,a.y)}}on(t,e,i){return this.interactive?this._renderer._addEvent(this,t,e,i):new ht(()=>{})}_setMatrix(){this._localMatrix.setTransform(this.x,this.y,this.pivot.x,this.pivot.y,this.angle*Math.PI/180,this.scale),this._matrix.copyFrom(this._localMatrix),this._parent&&this._matrix.prepend(this._parent._matrix)}_transform(t,e){let i=this._matrix,s=i.tx*e,r=i.ty*e;this.crisp&&(s=Ss(s),r=Ss(r)),t.setTransform(i.a*e,i.b*e,i.c*e,i.d*e,s,r)}_transformMargin(t,e,i){let s=this._matrix;t.setTransform(s.a*e,s.b*e,s.c*e,s.d*e,(s.tx+i.left)*e,(s.ty+i.top)*e)}_transformLayer(t,e,i){i.margin?this._transformMargin(t,i.scale||e,i.margin):this._transform(t,i.scale||e)}render(t,e=0){if(this.visible&&(this.exportable!==!1||!this._renderer._omitTainted)){this._setMatrix();let i=this.subStatus(t),s=this._renderer.resolution,r=this._renderer.layers,a=this._renderer._ghostLayer,o=a.context,n=this.mask;n&&n._setMatrix(),v(r,d=>{if(d){let m=d.context;m.save(),n&&(n._transformLayer(m,s,d),n._runPath(m),m.clip()),m.globalAlpha=this.compoundAlpha*this.alpha,this._transformLayer(m,s,d),this.filter&&(m.filter=this.filter)}}),o.save(),n&&this._isInteractiveMask(i)&&(n._transformMargin(o,s,a.margin),n._runPath(o),o.clip()),this._transformMargin(o,s,a.margin),i.layer.order>0&&!e&&qi(this._renderer._deferredGhostLayers,i.layer.order),this._render(i,e),o.restore(),v(r,d=>{d&&d.context.restore()})}}_render(t,e=0){this.exportable===!1&&(t.layer.tainted=!0)}_ghostOnly(t=0){return t>0}_drawGhost(t,e=0){let i=this._isInteractive(t),s=t.layer.order||0;return!!(i&&(s==0&&!this._ghostOnly(e)||s==e))}hovering(){return this._renderer._hovering.has(this)}dragging(){return this._renderer._dragging.some(t=>t.value===this)}shouldCancelTouch(){let t=this._renderer;return t.tapToActivate&&!t._touchActive?!1:this.cancelTouch?!0:this._parent?this._parent.shouldCancelTouch():!1}},yi=class extends qt{constructor(){super(...arguments),this.interactiveChildren=!0,this._children=[]}_isInteractiveMask(t){return this.interactiveChildren||super._isInteractiveMask(t)}addChild(t){t._parent=this,this._children.push(t),t._layer&&this.registerChildLayer(t._layer)}addChildAt(t,e){t._parent=this,this._children.splice(e,0,t),t._layer&&this.registerChildLayer(t._layer)}removeChild(t){t._parent=void 0,xe(this._children,t)}_render(t,e){super._render(t);let i=this._renderer;this.interactive&&this.interactiveChildren&&++i._forceInteractive,v(this._children,s=>{s.compoundAlpha=this.compoundAlpha*this.alpha,s.render(t,e)}),this.interactive&&this.interactiveChildren&&--i._forceInteractive}registerChildLayer(t){this._childLayers||(this._childLayers=[]),be(this._childLayers,t),this._parent&&this._parent.registerChildLayer(t)}markDirtyLayer(t=!1){super.markDirtyLayer(),t&&this._childLayers&&v(this._childLayers,e=>e.dirty=!0)}_dispose(){super._dispose(),this._childLayers&&v(this._childLayers,t=>{t.dirty=!0})}};function z(g,t){g.left=Math.min(g.left,t.x),g.top=Math.min(g.top,t.y),g.right=Math.max(g.right,t.x),g.bottom=Math.max(g.bottom,t.y)}var F=class{colorize(t,e){}colorizeGhost(t,e){this.colorize(t,e)}path(t){}pathGhost(t){this.path(t)}addBounds(t){}},xi=class extends F{colorize(t,e){t.beginPath()}},Ae=class extends F{constructor(t){super(),this.color=t}colorize(t,e){e!==void 0?t.fillStyle=e:t.fillStyle=this.color}},bi=class extends F{constructor(t){super(),this.clearShadow=t}colorize(t,e){t.fill(),this.clearShadow&&(t.shadowColor="",t.shadowBlur=0,t.shadowOffsetX=0,t.shadowOffsetY=0)}},vi=class extends F{colorize(t,e){t.stroke()}},Ne=class extends F{constructor(t,e,i,s){super(),this.width=t,this.color=e,this.lineJoin=i,this.lineCap=s}colorize(t,e){e!==void 0?t.strokeStyle=e:t.strokeStyle=this.color,t.lineWidth=this.width,this.lineJoin&&(t.lineJoin=this.lineJoin),this.lineCap&&(t.lineCap=this.lineCap)}},wi=class extends F{constructor(t){super(),this.dash=t}colorize(t,e){t.setLineDash(this.dash)}},ki=class extends F{constructor(t){super(),this.dashOffset=t}colorize(t,e){t.lineDashOffset=this.dashOffset}},Ti=class extends F{constructor(t,e,i,s){super(),this.x=t,this.y=e,this.width=i,this.height=s}path(t){t.rect(this.x,this.y,this.width,this.height)}addBounds(t){let e=this.x,i=this.y,s=e+this.width,r=i+this.height;z(t,{x:e,y:i}),z(t,{x:s,y:i}),z(t,{x:e,y:r}),z(t,{x:s,y:r})}},Ci=class extends F{constructor(t,e,i){super(),this.x=t,this.y=e,this.radius=i}path(t){t.moveTo(this.x+this.radius,this.y),t.arc(this.x,this.y,this.radius,0,2*Math.PI)}addBounds(t){z(t,{x:this.x-this.radius,y:this.y-this.radius}),z(t,{x:this.x+this.radius,y:this.y+this.radius})}},Si=class extends F{constructor(t,e,i,s){super(),this.x=t,this.y=e,this.radiusX=i,this.radiusY=s}path(t){t.ellipse(0,0,this.radiusX,this.radiusY,0,0,Math.PI*2)}addBounds(t){z(t,{x:this.x-this.radiusX,y:this.y-this.radiusY}),z(t,{x:this.x+this.radiusX,y:this.y+this.radiusY})}},Di=class extends F{constructor(t,e,i,s,r,a){super(),this.cx=t,this.cy=e,this.radius=i,this.startAngle=s,this.endAngle=r,this.anticlockwise=a}path(t){this.radius>0&&t.arc(this.cx,this.cy,this.radius,this.startAngle,this.endAngle,this.anticlockwise)}addBounds(t){let e=ps(this.cx,this.cy,this.startAngle*jt,this.endAngle*jt,this.radius);z(t,{x:e.left,y:e.top}),z(t,{x:e.right,y:e.bottom})}},Mi=class extends F{constructor(t,e,i,s,r){super(),this.x1=t,this.y1=e,this.x2=i,this.y2=s,this.radius=r}path(t){this.radius>0&&t.arcTo(this.x1,this.y1,this.x2,this.y2,this.radius)}addBounds(t){}},Ei=class extends F{constructor(t,e){super(),this.x=t,this.y=e}path(t){t.lineTo(this.x,this.y)}addBounds(t){z(t,{x:this.x,y:this.y})}},$i=class extends F{constructor(t,e){super(),this.x=t,this.y=e}path(t){t.moveTo(this.x,this.y)}addBounds(t){z(t,{x:this.x,y:this.y})}},Bi=class extends F{path(t){t.closePath()}},Pi=class extends F{constructor(t,e,i,s,r,a){super(),this.cpX=t,this.cpY=e,this.cpX2=i,this.cpY2=s,this.toX=r,this.toY=a}path(t){t.bezierCurveTo(this.cpX,this.cpY,this.cpX2,this.cpY2,this.toX,this.toY)}addBounds(t){z(t,{x:this.cpX,y:this.cpY}),z(t,{x:this.cpX2,y:this.cpY2}),z(t,{x:this.toX,y:this.toY})}},Li=class extends F{constructor(t,e,i,s){super(),this.cpX=t,this.cpY=e,this.toX=i,this.toY=s}path(t){t.quadraticCurveTo(this.cpX,this.cpY,this.toX,this.toY)}addBounds(t){z(t,{x:this.cpX,y:this.cpY}),z(t,{x:this.toX,y:this.toY})}},Ai=class extends F{constructor(t,e,i,s,r){super(),this.color=t,this.blur=e,this.offsetX=i,this.offsetY=s,this.opacity=r}colorize(t,e){this.opacity&&(t.fillStyle=this.color),t.shadowColor=this.color,t.shadowBlur=this.blur,t.shadowOffsetX=this.offsetX,t.shadowOffsetY=this.offsetY}colorizeGhost(t,e){}},Ni=class extends F{constructor(t,e,i,s,r){super(),this.image=t,this.width=e,this.height=i,this.x=s,this.y=r}path(t){t.drawImage(this.image,this.x,this.y,this.width,this.height)}addBounds(t){z(t,{x:this.x,y:this.y}),z(t,{x:this.width,y:this.height})}},zi=class extends qt{constructor(){super(...arguments),this._operations=[],this.blendMode=li.NORMAL,this._hasShadows=!1}clear(){super.clear(),this._operations.length=0}_pushOp(t){this._operations.push(t)}beginFill(t,e=1){this._fillAlpha=e,t?t instanceof L?this._pushOp(new Ae(t.toCSS(e))):(this.isMeasured=!0,this._pushOp(new Ae(t))):this._pushOp(new Ae("rgba(0, 0, 0, "+e+")"))}endFill(){this._pushOp(new bi(this._hasShadows))}endStroke(){this._pushOp(new vi)}beginPath(){this._pushOp(new xi)}lineStyle(t=0,e,i=1,s,r){this._strokeAlpha=i,e?e instanceof L?this._pushOp(new Ne(t,e.toCSS(i),s,r)):this._pushOp(new Ne(t,e,s,r)):this._pushOp(new Ne(t,"rgba(0, 0, 0, "+i+")",s,r))}setLineDash(t){this._pushOp(new wi(t||[]))}setLineDashOffset(t=0){this._pushOp(new ki(t))}drawRect(t,e,i,s){this._pushOp(new Ti(t,e,i,s))}drawCircle(t,e,i){this._pushOp(new Ci(t,e,i))}drawEllipse(t,e,i,s){this._pushOp(new Si(t,e,i,s))}arc(t,e,i,s,r,a=!1){this._pushOp(new Di(t,e,i,s,r,a))}arcTo(t,e,i,s,r){this._pushOp(new Mi(t,e,i,s,r))}lineTo(t,e){this._pushOp(new Ei(t,e))}moveTo(t,e){this._pushOp(new $i(t,e))}bezierCurveTo(t,e,i,s,r,a){this._pushOp(new Pi(t,e,i,s,r,a))}quadraticCurveTo(t,e,i,s){this._pushOp(new Li(t,e,i,s))}closePath(){this._pushOp(new Bi)}shadow(t,e=0,i=0,s=0,r){this._hasShadows=!0,this._pushOp(new Ai(r?t.toCSS(r):t.toCSS(this._fillAlpha||this._strokeAlpha),e,i,s))}image(t,e,i,s,r){this._pushOp(new Ni(t,e,i,s,r))}svgPath(t){let e=0,i=0,s=null,r=null,a=null,o=null,n=/([MmZzLlHhVvCcSsQqTtAa])([^MmZzLlHhVvCcSsQqTtAa]*)/g,d=/[\u0009\u0020\u000A\u000C\u000D]*([\+\-]?[0-9]*\.?[0-9]+(?:[eE][\+\-]?[0-9]+)?)[\u0009\u0020\u000A\u000C\u000D]*,?/g,m=this._operations.length;try{let l;for(;(l=n.exec(t))!==null;){let c=l[1],h=l[2],p=[];for(;(l=d.exec(h))!==null;)p.push(l[1]);switch(c!=="S"&&c!=="s"&&c!=="C"&&c!=="c"&&(s=null,r=null),c!=="Q"&&c!=="q"&&c!=="T"&&c!=="t"&&(a=null,o=null),c){case"M":tt(c,p.length,2),e=+p[0],i=+p[1],this.moveTo(e,i);for(let u=2;u<p.length;u+=2)e=+p[u],i=+p[u+1],this.lineTo(e,i);break;case"m":tt(c,p.length,2),e+=+p[0],i+=+p[1],this.moveTo(e,i);for(let u=2;u<p.length;u+=2)e+=+p[u],i+=+p[u+1],this.lineTo(e,i);break;case"L":tt(c,p.length,2);for(let u=0;u<p.length;u+=2)e=+p[u],i=+p[u+1],this.lineTo(e,i);break;case"l":tt(c,p.length,2);for(let u=0;u<p.length;u+=2)e+=+p[u],i+=+p[u+1],this.lineTo(e,i);break;case"H":Pe(c,p.length,1);for(let u=0;u<p.length;++u)e=+p[u],this.lineTo(e,i);break;case"h":Pe(c,p.length,1);for(let u=0;u<p.length;++u)e+=+p[u],this.lineTo(e,i);break;case"V":Pe(c,p.length,1);for(let u=0;u<p.length;++u)i=+p[u],this.lineTo(e,i);break;case"v":Pe(c,p.length,1);for(let u=0;u<p.length;++u)i+=+p[u],this.lineTo(e,i);break;case"C":tt(c,p.length,6);for(let u=0;u<p.length;u+=6){let f=+p[u],b=+p[u+1];s=+p[u+2],r=+p[u+3],e=+p[u+4],i=+p[u+5],this.bezierCurveTo(f,b,s,r,e,i)}break;case"c":tt(c,p.length,6);for(let u=0;u<p.length;u+=6){let f=+p[u]+e,b=+p[u+1]+i;s=+p[u+2]+e,r=+p[u+3]+i,e+=+p[u+4],i+=+p[u+5],this.bezierCurveTo(f,b,s,r,e,i)}break;case"S":tt(c,p.length,4),(s===null||r===null)&&(s=e,r=i);for(let u=0;u<p.length;u+=4){let f=2*e-s,b=2*i-r;s=+p[u],r=+p[u+1],e=+p[u+2],i=+p[u+3],this.bezierCurveTo(f,b,s,r,e,i)}break;case"s":tt(c,p.length,4),(s===null||r===null)&&(s=e,r=i);for(let u=0;u<p.length;u+=4){let f=2*e-s,b=2*i-r;s=+p[u]+e,r=+p[u+1]+i,e+=+p[u+2],i+=+p[u+3],this.bezierCurveTo(f,b,s,r,e,i)}break;case"Q":tt(c,p.length,4);for(let u=0;u<p.length;u+=4)a=+p[u],o=+p[u+1],e=+p[u+2],i=+p[u+3],this.quadraticCurveTo(a,o,e,i);break;case"q":tt(c,p.length,4);for(let u=0;u<p.length;u+=4)a=+p[u]+e,o=+p[u+1]+i,e+=+p[u+2],i+=+p[u+3],this.quadraticCurveTo(a,o,e,i);break;case"T":tt(c,p.length,2),(a===null||o===null)&&(a=e,o=i);for(let u=0;u<p.length;u+=2)a=2*e-a,o=2*i-o,e=+p[u],i=+p[u+1],this.quadraticCurveTo(a,o,e,i);break;case"t":tt(c,p.length,2),(a===null||o===null)&&(a=e,o=i);for(let u=0;u<p.length;u+=2)a=2*e-a,o=2*i-o,e+=+p[u],i+=+p[u+1],this.quadraticCurveTo(a,o,e,i);break;case"A":case"a":let _=c==="a";Os(p),tt(c,p.length,7);for(let u=0;u<p.length;u+=7){let f=+p[u+5],b=+p[u+6];_&&(f+=e,b+=i);let x=ks({px:e,py:i,rx:+p[u],ry:+p[u+1],xAxisRotation:+p[u+2],largeArcFlag:Ts(+p[u+3]),sweepFlag:Ts(+p[u+4]),cx:f,cy:b});v(x,y=>{this.bezierCurveTo(y.x1,y.y1,y.x2,y.y2,y.x,y.y),e=y.x,i=y.y})}break;case"Z":case"z":Rs(c,p.length,0),this.closePath();break}}}catch(l){this._operations.length=m,console.warn(`Error when parsing svgPath:
|
|
3
|
+
`+l.message+`
|
|
4
|
+
`+t)}}_runPath(t){t.beginPath(),v(this._operations,e=>{e.path(t)})}_render(t,e=0){super._render(t);let i=t.layer.dirty,s=this._isInteractive(t),r=this._ghostOnly(e),a=this._drawGhost(t,e);if(i||s||r){let o=t.layer.context,n=this._renderer._ghostLayer.context;i&&!r&&(o.globalCompositeOperation=this.blendMode,o.beginPath());let d;a&&(n.beginPath(),d=this._getColorId()),v(this._operations,m=>{i&&!r&&(m.path(o),m.colorize(o,void 0)),a&&(m.pathGhost(n),m.colorizeGhost(n,d))})}}renderDetached(t){if(this.visible){this._setMatrix(),t.save();let e=this.mask;e&&(e._setMatrix(),e._transform(t,1),e._runPath(t),t.clip()),t.globalAlpha=this.compoundAlpha*this.alpha,this._transform(t,1),this.filter&&(t.filter=this.filter),t.globalCompositeOperation=this.blendMode,t.beginPath(),v(this._operations,i=>{i.path(t),i.colorize(t,void 0)}),t.restore()}}_addBounds(t){this.visible&&this.isMeasured&&v(this._operations,e=>{e.addBounds(t)})}},Ke=class extends qt{constructor(t,e,i){super(t),this.resolution=1,this.textVisible=!0,this._originalScale=1,this.text=e,this.style=i}invalidateBounds(){super.invalidateBounds(),this._textInfo=void 0}invalidateVisibility(){this.textVisible=!0,this.scale=this._originalScale||1}_shared(t){this.style.textAlign&&(t.textAlign=this.style.textAlign),this.style.direction&&(t.direction=this.style.direction),this.style.textBaseline&&(t.textBaseline=this.style.textBaseline)}_prerender(t,e=!1,i=!1){super._render(t);let s=t.layer.context,r=this._renderer._ghostLayer.context,a=this.style,o=this._getFontStyle(void 0,i);s.font=o,this._isInteractive(t)&&!e&&(r.font=o),a.fill&&(a.fill instanceof L?s.fillStyle=a.fill.toCSS(a.fillOpacity!=null?a.fillOpacity:1):s.fillStyle=a.fill),a.shadowColor&&(t.layer.context.shadowColor=a.shadowColor.toCSS(a.shadowOpacity||1)),a.shadowBlur&&(t.layer.context.shadowBlur=a.shadowBlur),a.shadowOffsetX&&(t.layer.context.shadowOffsetX=a.shadowOffsetX),a.shadowOffsetY&&(t.layer.context.shadowOffsetY=a.shadowOffsetY),this._shared(s),this._isInteractive(t)&&!e&&(r.fillStyle=this._getColorId(),this._shared(r))}_getFontStyle(t,e=!1){let i=this.style,s=[];return t&&t.fontVariant?s.push(t.fontVariant):i.fontVariant&&s.push(i.fontVariant),e||(t&&t.fontWeight?s.push(t.fontWeight):i.fontWeight&&s.push(i.fontWeight)),t&&t.fontStyle?s.push(t.fontStyle):i.fontStyle&&s.push(i.fontStyle),t&&t.fontSize?(M(t.fontSize)&&(t.fontSize=t.fontSize+"px"),s.push(t.fontSize)):i.fontSize&&(M(i.fontSize)&&(i.fontSize=i.fontSize+"px"),s.push(i.fontSize)),t&&t.fontFamily?s.push(t.fontFamily):i.fontFamily?s.push(i.fontFamily):s.length&&s.push("Arial"),s.join(" ")}_render(t,e=0){if(this._textInfo||this._measure(t),this.textVisible){let i=this._isInteractive(t),s=t.layer.context,r=t.layer.dirty,a=this._renderer._ghostLayer.context,o=this._ghostOnly(e),n=this._drawGhost(t,e);s.save(),a.save(),this._prerender(t),v(this._textInfo,(d,m)=>{v(d.textChunks,(l,c)=>{if(l.style&&(s.save(),a.save(),o||(s.font=l.style),this._isInteractive(t)&&(a.font=l.style)),l.fill&&(s.save(),o||(s.fillStyle=l.fill.toCSS())),r&&!o&&s.fillText(l.text,l.offsetX,d.offsetY+l.offsetY),l.textDecoration=="underline"||l.textDecoration=="line-through"){let h=1,p=1,_=l.height,u=this.style.oversizedBehavior||"";if(["truncate","wrap","wrap-no-break"].indexOf(u)>-1){let x=this._measureText(l.text,s);l.width=x.actualBoundingBoxLeft+x.actualBoundingBoxRight}let f=l.offsetX;switch(this.style.textAlign){case"right":case"end":f-=l.width;break;case"center":f-=l.width/2;break}if(l.style)switch(J.getTextStyle(l.style).fontWeight){case"bolder":case"bold":case"700":case"800":case"900":h=2;break}_&&(p=_/20);let b;l.textDecoration=="line-through"?b=h+d.offsetY+l.offsetY-l.height/2:b=h+p*1.5+d.offsetY+l.offsetY,o||(s.save(),s.beginPath(),l.fill?s.strokeStyle=l.fill.toCSS():this.style.fill&&this.style.fill instanceof L&&(s.strokeStyle=this.style.fill.toCSS()),s.lineWidth=h*p,s.moveTo(f,b),s.lineTo(f+l.width,b),s.stroke(),s.restore())}i&&this.interactive&&n&&a.fillText(l.text,l.offsetX,d.offsetY+l.offsetY),l.fill&&s.restore(),l.style&&(s.restore(),a.restore())})}),s.restore(),a.restore()}}_addBounds(t){if(this.visible&&this.isMeasured){let e=this._measure({inactive:this.inactive,layer:this.getLayer()});z(t,{x:e.left,y:e.top}),z(t,{x:e.right,y:e.bottom})}}_ignoreFontWeight(){return/apple/i.test(navigator.vendor)}_measure(t){let e=t.layer.context,i=this._renderer._ghostLayer.context,s=this.style.direction=="rtl";this._textInfo=[];let r=this.style.oversizedBehavior,a=this.style.maxWidth,o=M(a)&&r=="truncate",n=M(a)&&(r=="wrap"||r=="wrap-no-break");e.save(),i.save(),this._prerender(t,!0,this._ignoreFontWeight());let d="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 ",m=this.text.toString().replace(/\r/g,"").split(/\n/),l=!0,c=0,h=0,p=0,_;v(m,(f,b)=>{let x;for(f==""?x=[{type:"value",text:""}]:x=J.chunk(f,!1,this.style.ignoreFormatting);x.length>0;){let y={offsetY:p,ascent:0,width:0,height:0,left:0,right:0,textChunks:[]},w=this._measureText(d,e),T=w.actualBoundingBoxAscent+w.actualBoundingBoxDescent;y.height=T,y.ascent=w.actualBoundingBoxAscent;let k,E=this.style.textDecoration,R,D,S=!1,Y=!0,H=[],Xt;ye(x,(G,ti)=>{if(G.type=="format")if(G.text=="[/]")l||(e.restore(),i.restore(),l=!0),R=void 0,_=void 0,D=void 0,E=this.style.textDecoration,Xt=void 0,k=G.text;else{l||(e.restore(),i.restore());let A=J.getTextStyle(G.text),et=this._getFontStyle(A);e.save(),i.save(),e.font=et,_=et,k=G.text,A.textDecoration&&(E=A.textDecoration),A.fill&&(R=A.fill),A.width&&(D=X(A.width)),A.verticalAlign&&(Xt=A.verticalAlign),l=!1;let ot=this._measureText(d,e),ft=ot.actualBoundingBoxAscent+ot.actualBoundingBoxDescent;ft>y.height&&(y.height=ft),ot.actualBoundingBoxAscent>y.ascent&&(y.ascent=ot.actualBoundingBoxAscent)}else if(G.type=="value"&&!S){let A=this._measureText(G.text,e),et=A.actualBoundingBoxLeft+A.actualBoundingBoxRight;if(o){this.truncated=void 0;let nt=Y||this.style.breakWords||!1,It=this.style.ellipsis||"",Xi=this._measureText(It,e),$s=Xi.actualBoundingBoxLeft+Xi.actualBoundingBoxRight;if(y.width+et>a){let Bs=a-y.width-$s;G.text=this._truncateText(e,G.text,Bs,nt),G.text+=It,S=!0,this.truncated=!0}}else if(n&&y.width+et>a){let nt=a-y.width,It=this._truncateText(e,G.text,nt,!1,Y&&this.style.oversizedBehavior!="wrap-no-break");if(It=="")return this.textVisible=!0,!1;H=x.slice(ti+1),He(It)!=He(G.text)&&(H.unshift({type:"value",text:G.text.substr(It.length)}),k&&H.unshift({type:"format",text:k})),G.text=He(It),x=[],S=!0}let ot=1,ft=1;if(_&&D&&D>et){let nt=et/D;switch(this.style.textAlign){case"right":case"end":ot=nt;break;case"center":ot=nt,ft=nt;break;default:ft=nt}et=D}let ge=A.actualBoundingBoxAscent+A.actualBoundingBoxDescent;ge>y.height&&(y.height=ge),A.actualBoundingBoxAscent>y.ascent&&(y.ascent=A.actualBoundingBoxAscent),y.width+=et,y.left+=A.actualBoundingBoxLeft/ot,y.right+=A.actualBoundingBoxRight/ft,y.textChunks.push({style:_,fill:R,text:G.text,width:et,height:ge,left:A.actualBoundingBoxLeft,right:A.actualBoundingBoxRight,ascent:A.actualBoundingBoxAscent,offsetX:0,offsetY:0,textDecoration:E,verticalAlign:Xt}),Y=!1}return!0}),this.style.lineHeight instanceof q?(y.height*=this.style.lineHeight.value,y.ascent*=this.style.lineHeight.value):(y.height*=this.style.lineHeight||1.2,y.ascent*=this.style.lineHeight||1.2),c<y.left&&(c=y.left),h<y.right&&(h=y.right),this._textInfo.push(y),p+=y.height,x=H||[]}}),l||(e.restore(),i.restore()),v(this._textInfo,(f,b)=>{let x=0;v(f.textChunks,y=>{if(y.offsetX=x+y.left-f.left,y.offsetY+=f.height-f.height*(this.style.baselineRatio||.19),x+=y.width*(s?-1:1),y.verticalAlign)switch(y.verticalAlign){case"super":y.offsetY-=f.height/2-y.height/2;break;case"sub":y.offsetY+=y.height/2;break}})});let u={left:s?-h:-c,top:0,right:s?c:h,bottom:p};if(r!=="none"){let f=this._fitRatio(u);if(f<1)if(r=="fit")M(this.style.minScale)&&f<this.style.minScale?(this.textVisible=!1,u.left=0,u.top=0,u.right=0,u.bottom=0):(this._originalScale||(this._originalScale=this.scale),this.scale=f,this.textVisible=!0);else if(r=="hide")this.textVisible=!1,u.left=0,u.top=0,u.right=0,u.bottom=0;else{switch(this.style.textAlign){case"right":case"end":u.left=s?a:-a,u.right=0;break;case"center":u.left=-a/2,u.right=a/2;break;default:u.left=0,u.right=s?-a:a}this.scale=this._originalScale||1,this._originalScale=void 0,this.textVisible=!0}else this.scale=this._originalScale||1,this._originalScale=void 0,this.textVisible=!0}return e.restore(),i.restore(),u}_fitRatio(t){let e=this.style.maxWidth,i=this.style.maxHeight;if(!M(e)&&!M(i))return 1;let s=t.right-t.left,r=t.bottom-t.top;return Math.min(e/s||1,i/r||1)}_truncateText(t,e,i,s=!1,r=!0){let a;do{if(s)e=e.slice(0,-1);else{let n=e.replace(/[^,;:!?\\\/\s]+[,;:!?\\\/\s]*$/g,"");if((n==""||n===e)&&r)s=!0;else{if(n=="")return e;e=n}}let o=this._measureText(e,t);a=o.actualBoundingBoxLeft+o.actualBoundingBoxRight}while(a>i&&e!="");return e}_measureText(t,e){let i=e.measureText(t),s={};if(i.actualBoundingBoxAscent==null){let a=document.createElement("div");a.innerText=t,a.style.visibility="hidden",a.style.position="absolute",a.style.top="-1000000px;",a.style.fontFamily=this.style.fontFamily||"",a.style.fontSize=this.style.fontSize+"",document.body.appendChild(a);let o=a.getBoundingClientRect();document.body.removeChild(a);let n=o.height,d=i.width;s={actualBoundingBoxAscent:n,actualBoundingBoxDescent:0,actualBoundingBoxLeft:0,actualBoundingBoxRight:d,fontBoundingBoxAscent:n,fontBoundingBoxDescent:0,width:d}}else s={actualBoundingBoxAscent:i.actualBoundingBoxAscent,actualBoundingBoxDescent:i.actualBoundingBoxDescent,actualBoundingBoxLeft:i.actualBoundingBoxLeft,actualBoundingBoxRight:i.actualBoundingBoxRight,fontBoundingBoxAscent:i.actualBoundingBoxAscent,fontBoundingBoxDescent:i.actualBoundingBoxDescent,width:i.width};let r=i.width;switch(this.style.textAlign){case"right":case"end":s.actualBoundingBoxLeft=r,s.actualBoundingBoxRight=0;break;case"center":s.actualBoundingBoxLeft=r/2,s.actualBoundingBoxRight=r/2;break;default:s.actualBoundingBoxLeft=0,s.actualBoundingBoxRight=r}return s}},Fi=class{constructor(){this.lineHeight=pt(120),this.baselineRatio=.19,this.oversizedBehavior="none",this.breakWords=!1,this.ellipsis="\u2026",this.ignoreFormatting=!1}},Ri=class extends Ke{constructor(){super(...arguments),this.textType="circular",this.inside=!1,this.orientation="auto",this.kerning=0,this._textReversed=!1}_render(t,e=0){switch(this.textType){case"circular":this._renderCircular(t,e);break;default:super._render(t,e);break}}_renderCircular(t,e=0){if(this.textVisible){this._prerender(t);let i=this._isInteractive(t),s=t.layer.context,r=t.layer.dirty,a=this._renderer._ghostLayer.context;s.save(),i&&a.save(),this._textInfo||this._measure(t);let o=this.radius||0,n=this.startAngle||0,d=0,m=this.orientation,l=m=="auto"?"auto":m=="inward",c=this.inside,h=this.style.textAlign||"left",p=this.kerning||0,_=h=="left"?1:-1,u=!this._textReversed,f=this._ghostOnly(e),b=this._drawGhost(t,e);if(l=="auto"){let x=0,y=0;v(this._textInfo,(w,T)=>{let k=n+w.width/(o-w.height)/2*-_;k>x&&(x=k)}),h=="left"?y=(x+d/2)*jt:h=="right"?y=(x-d/2)*jt:y=n*jt,y=fs(y),l=y>=270||y<=90}l==!0&&u&&(this._textInfo.reverse(),this._textReversed=!0),v(this._textInfo,(x,y)=>{let w=x.height;c||(o+=w),(_==-1&&l||_==1&&!l)&&u&&x.textChunks.reverse();let T=n;d=0,h=="center"&&(T+=x.width/(o-w)/2*-_,d=T-n),T+=Math.PI*(l?0:1),s.save(),i&&a.save(),f||s.rotate(T),i&&a.rotate(T);let k=0;v(x.textChunks,(E,R)=>{let D=E.text,S=E.width;k=S/2/(o-w)*_,f||s.rotate(k),i&&a.rotate(k),E.style&&(s.save(),a.save(),f||(s.font=E.style),i&&(a.font=E.style)),E.fill&&(s.save(),f||(s.fillStyle=E.fill.toCSS())),f||(s.textBaseline="middle",s.textAlign="center"),i&&(a.textBaseline="middle",a.textAlign="center"),r&&!f&&s.fillText(D,0,(l?1:-1)*(0-o+w/2)),i&&b&&a.fillText(D,0,(l?1:-1)*(0-o+w/2)),E.fill&&s.restore(),E.style&&(s.restore(),a.restore()),k=(S/2+p)/(o-w)*_,f||s.rotate(k),i&&a.rotate(k)}),s.restore(),i&&a.restore(),c&&(o-=w)}),s.restore(),i&&a.restore()}}_measure(t){switch(this.textType){case"circular":return this._measureCircular(t);default:return super._measure(t)}}_measureCircular(t){let e=t.layer.context,i=this._renderer._ghostLayer.context,s=this.style.direction=="rtl",r=this.style.oversizedBehavior,a=this.style.maxWidth,o=M(a)&&r=="truncate",n=this.style.ellipsis||"",d;this.textVisible=!0,this._textInfo=[],this._textReversed=!1,e.save(),i.save(),this._prerender(t,!0);let m=this.text.toString().replace(/\r/g,"").split(/\n/),l=!0,c=0,h=0;return v(m,(p,_)=>{let u=J.chunk(p,!1,this.style.ignoreFormatting),f={offsetY:h,ascent:0,width:0,height:0,left:0,right:0,textChunks:[]},b,x,y;v(u,(w,T)=>{if(w.type=="format"){if(w.text=="[/]")l||(e.restore(),i.restore(),l=!0),x=void 0,b=void 0,y=void 0;else{let k=J.getTextStyle(w.text),E=this._getFontStyle(k);e.save(),i.save(),e.font=E,b=E,k.fill&&(x=k.fill),k.width&&(y=X(k.width)),l=!1}o&&(d=this._measureText(n,e))}else if(w.type=="value"){let k=w.text.match(/./ug)||[];s&&(k=ns(w.text),k.reverse());for(let E=0;E<k.length;E++){let R=k[E],D=this._measureText(R,e),S=D.width;b&&y&&y>S&&(S=y);let Y=D.actualBoundingBoxAscent+D.actualBoundingBoxDescent;if(Y>f.height&&(f.height=Y),D.actualBoundingBoxAscent>f.ascent&&(f.ascent=D.actualBoundingBoxAscent),c+=S,o){d||(d=this._measureText(n,e));let H=d.actualBoundingBoxLeft+d.actualBoundingBoxRight;if(c+H>a){f.textChunks.length==1?this.textVisible=!1:(f.width+=H,f.left+=d.actualBoundingBoxLeft,f.right+=d.actualBoundingBoxRight,f.textChunks.push({style:b,fill:x,text:n,width:H,height:Y+d.actualBoundingBoxDescent,left:d.actualBoundingBoxLeft,right:d.actualBoundingBoxRight,ascent:d.actualBoundingBoxAscent,offsetX:0,offsetY:Y,textDecoration:void 0}));break}}f.width+=S,f.left+=D.actualBoundingBoxLeft,f.right+=D.actualBoundingBoxRight,f.textChunks.push({style:b,fill:x,text:R,width:S,height:Y+D.actualBoundingBoxDescent,left:D.actualBoundingBoxLeft,right:D.actualBoundingBoxRight,ascent:D.actualBoundingBoxAscent,offsetX:0,offsetY:Y,textDecoration:void 0})}}}),this.style.lineHeight instanceof q?f.height*=this.style.lineHeight.value:f.height*=this.style.lineHeight||1.2,this._textInfo.push(f),h+=f.height}),l||(e.restore(),i.restore()),r=="hide"&&c>a&&(this.textVisible=!1),v(this._textInfo,p=>{v(p.textChunks,_=>{_.offsetY+=Math.round((p.height-_.height+(p.ascent-_.ascent))/2)})}),e.restore(),i.restore(),{left:0,top:0,right:0,bottom:0}}},Oi=class extends qt{constructor(t,e){super(t),this.image=e}_dispose(){super._dispose(),this._imageMask&&Le(this._imageMask)}getLocalBounds(){if(!this._localBounds){let t=0,e=0;this.width&&(t=this.width),this.height&&(e=this.height),this._localBounds={left:0,top:0,right:t,bottom:e},this._addBounds(this._localBounds)}return this._localBounds}_render(t,e=0){if(super._render(t),this.image){if(this.tainted===void 0&&(this.tainted=Cs(this.image),t.layer.tainted=!0),this.tainted&&this._renderer._omitTainted)return;let i=this._ghostOnly(e),s=this._drawGhost(t,e);if(t.layer.dirty&&!i){this.shadowColor&&(t.layer.context.shadowColor=this.shadowColor.toCSS(this.shadowOpacity||1)),this.shadowBlur&&(t.layer.context.shadowBlur=this.shadowBlur),this.shadowOffsetX&&(t.layer.context.shadowOffsetX=this.shadowOffsetX),this.shadowOffsetY&&(t.layer.context.shadowOffsetY=this.shadowOffsetY);let r=this.width||this.image.naturalWidth,a=this.height||this.image.naturalHeight;t.layer.context.drawImage(this.image,0,0,r,a)}if(this.interactive&&this._isInteractive(t)&&s){let r=this._getMask(this.image);this._renderer._ghostLayer.context.drawImage(r,0,0)}}}clear(){super.clear(),this.image=void 0,this._imageMask=void 0}_getMask(t){if(this._imageMask===void 0){let e=this.width||t.naturalWidth,i=this.height||t.naturalHeight,s=document.createElement("canvas");s.width=e,s.height=i;let r=s.getContext("2d");r.imageSmoothingEnabled=!1,r.fillStyle=this._getColorId(),r.fillRect(0,0,e,i),Cs(t)||(r.globalCompositeOperation="destination-in",r.drawImage(t,0,0,e,i)),this._imageMask=s}return this._imageMask}},Hi=class{constructor(t,e,i,s){this.event=t,this.originalPoint=e,this.point=i,this.bbox=s,this.simulated=!1,this.native=!0,ct("touchevents")&&t instanceof Touch?this.id=t.identifier:this.id=null}},ze=class extends ii{constructor(t){if(super(),this.view=document.createElement("div"),this._layerDom=document.createElement("div"),this.layers=[],this._dirtyLayers=[],this.defaultLayer=this.getLayer(0),this._ghostLayer=new Yi,this._deferredGhostLayers=[],this._patternCanvas=document.createElement("canvas"),this._patternContext=this._patternCanvas.getContext("2d"),this._realWidth=0,this._realHeight=0,this._calculatedWidth=0,this._calculatedHeight=0,this.interactionsEnabled=!0,this._listeners={},this._events={},this._colorId=0,this._colorMap={},this._forceInteractive=0,this._omitTainted=!1,this._hovering=new Set,this._dragging=[],this._mousedown=[],this.tapToActivate=!1,this.tapToActivateTimeout=3e3,this._touchActive=!1,t==null?this.resolution=window.devicePixelRatio:this.resolution=t,this.view.style.position="absolute",this.view.setAttribute("aria-hidden","true"),this.view.appendChild(this._layerDom),this._disposers.push(new ht(()=>{W(this._events,(e,i)=>{i.disposer.dispose()}),v(this.layers,e=>{Le(e.view),e.exportableView&&Le(e.exportableView)}),Le(this._ghostLayer.view),Le(this._patternCanvas)})),this._disposers.push(Fe(()=>{t==null&&(this.resolution=window.devicePixelRatio)})),ct("touchevents")){let e=i=>{this._dragging.length!==0&&ye(this._dragging,s=>s.value.shouldCancelTouch()?(i.preventDefault(),!1):!0),this._touchActiveTimeout&&this._delayTouchDeactivate()};this._disposers.push($(window,"touchstart",e,{passive:!1})),this._disposers.push($(this.view,"touchstart",e,{passive:!1})),this._disposers.push($(this.view,"touchmove",()=>{this._touchActiveTimeout&&this._delayTouchDeactivate()},{passive:!0})),this._disposers.push($(window,"click",i=>{this._touchActive=!1},{passive:!0})),this._disposers.push($(this.view,"click",i=>{window.setTimeout(()=>{this._touchActive=!0,this._delayTouchDeactivate()},100)},{passive:!0}))}ct("wheelevents")&&this._disposers.push($(this.view,"wheel",e=>{let i=!1;this._hovering.forEach(s=>{if(s.wheelable)return i=!0,!1}),i&&e.preventDefault()},{passive:!1}))}resetImageArray(){this._ghostLayer.imageArray=void 0}_delayTouchDeactivate(){this._touchActiveTimeout&&clearTimeout(this._touchActiveTimeout),this.tapToActivateTimeout>0&&(this._touchActiveTimeout=window.setTimeout(()=>{this._touchActive=!1},this.tapToActivateTimeout))}get debugGhostView(){return!!this._ghostLayer.view.parentNode}set debugGhostView(t){t?this._ghostLayer.view.parentNode||this.view.appendChild(this._ghostLayer.view):this._ghostLayer.view.parentNode&&this._ghostLayer.view.parentNode.removeChild(this._ghostLayer.view)}createLinearGradient(t,e,i,s){return this.defaultLayer.context.createLinearGradient(t,e,i,s)}createRadialGradient(t,e,i,s,r,a){return this.defaultLayer.context.createRadialGradient(t,e,i,s,r,a)}createPattern(t,e,i,s,r){return this._patternCanvas.width=s,this._patternCanvas.height=r,this._patternContext.clearRect(0,0,s,r),e.renderDetached(this._patternContext),t.renderDetached(this._patternContext),this._patternContext.createPattern(this._patternCanvas,i)}makeContainer(){return new yi(this)}makeGraphics(){return new zi(this)}makeText(t,e){return new Ke(this,t,e)}makeTextStyle(){return new Fi}makeRadialText(t,e){return new Ri(this,t,e)}makePicture(t){return new Oi(this,t)}resizeLayer(t){t.resize(this._calculatedWidth,this._calculatedHeight,this._calculatedWidth,this._calculatedHeight,this.resolution)}resizeGhost(){this._ghostLayer.resize(this._calculatedWidth,this._calculatedHeight,this._calculatedWidth,this._calculatedHeight,this.resolution)}resize(t,e,i,s){this._realWidth=t,this._realHeight=e,this._calculatedWidth=i,this._calculatedHeight=s,v(this.layers,r=>{r&&(r.dirty=!0,this.resizeLayer(r))}),this.resizeGhost(),this.view.style.width=i+"px",this.view.style.height=s+"px"}createDetachedLayer(t=!1){let e=document.createElement("canvas"),i=e.getContext("2d",{willReadFrequently:t}),s=new Je(e,i);return e.style.position="absolute",e.style.top="0px",e.style.left="0px",s}getLayerByOrder(t){let e=this.layers,i=e.length;for(let s=0;s<i;s++){let r=e[s];if(r.order==t)return r}}getLayer(t,e=!0){let i=this.getLayerByOrder(t);if(i)return i;let s=this.createDetachedLayer(t==99);s.order=t,s.visible=e,s.view.className="am5-layer-"+t,s.visible&&this.resizeLayer(s);let r=this.layers;r.push(s),r.sort((d,m)=>d.order>m.order?1:d.order<m.order?-1:0);let a=r.length,o=ji(r,s),n;for(let d=o+1;d<a;d++)if(r[d].visible){n=r[d];break}return s.visible&&(n===void 0?this._layerDom.appendChild(s.view):this._layerDom.insertBefore(s.view,n.view)),s}render(t){this._dirtyLayers.length=0,this._deferredGhostLayers=[],v(this.layers,i=>{i&&i.dirty&&i.visible&&(this._dirtyLayers.push(i),i.clear())}),this._ghostLayer.clear(),t.render({inactive:null,layer:this.defaultLayer});let e=this._deferredGhostLayers;if(e.length&&(e.sort((i,s)=>i-s),v(e,i=>{t.render({inactive:null,layer:this.defaultLayer},i)})),this._ghostLayer.context.restore(),v(this.layers,i=>{if(i){let s=i.context;s.beginPath(),s.moveTo(0,0),s.stroke()}}),v(this._dirtyLayers,i=>{i.context.restore(),i.dirty=!1}),this._hovering.size&&this._lastPointerMoveEvent){let{events:i,target:s,native:r}=this._lastPointerMoveEvent;v(i,a=>{this._dispatchGlobalMousemove(a,s,r)})}}paintId(t){let e=Hs(++this._colorId),i=L.fromHex(e).toCSS();return this._colorMap[i]=t,i}_removeObject(t){t._colorId!==void 0&&delete this._colorMap[t._colorId]}_adjustBoundingBox(t){let e=this._ghostLayer.margin;return new DOMRect(-e.left,-e.top,t.width+e.left+e.right,t.height+e.top+e.bottom)}getEvent(t,e=!0){let i=this.view.getBoundingClientRect(),s=t.clientX||0,r=t.clientY||0,a=this._calculatedWidth/this._realWidth,o=this._calculatedHeight/this._realHeight,n={x:s-i.left,y:r-i.top},d={x:(s-(e?i.left:0))*a,y:(r-(e?i.top:0))*o};return new Hi(t,n,d,this._adjustBoundingBox(i))}_getHitTarget(t,e,i){if(e.width===0||e.height===0||t.x<e.left||t.x>e.right||t.y<e.top||t.y>e.bottom||!i||!this._layerDom.contains(i))return;let s=this._ghostLayer.getImageData(t,e);if(s.data[0]===0&&s.data[1]===0&&s.data[2]===0)return!1;let r=L.fromRGB(s.data[0],s.data[1],s.data[2]).toCSS();return this._colorMap[r]}getObjectAtPoint(t){let e=this._ghostLayer.getImageArray(t);if(e[0]===0&&e[1]===0&&e[2]===0)return;let i=L.fromRGB(e[0],e[1],e[2]).toCSS();return this._colorMap[i]}_withEvents(t,e){let i=this._events[t];if(i!==void 0){i.dispatching=!0;try{e(i)}finally{i.dispatching=!1,i.cleanup&&(i.cleanup=!1,Wt(i.callbacks,s=>!s.disposed),i.callbacks.length===0&&(i.disposer.dispose(),delete this._events[t]))}}}_dispatchEventAll(t,e){this.interactionsEnabled&&this._withEvents(t,i=>{v(i.callbacks,s=>{s.disposed||s.callback.call(s.context,e)})})}_dispatchEvent(t,e,i){if(!this.interactionsEnabled)return!1;let s=!1;return this._withEvents(t,r=>{v(r.callbacks,a=>{!a.disposed&&a.object===e&&(a.callback.call(a.context,i),s=!0)})}),s}_dispatchMousedown(t,e){let i=t.button;if(i!=0&&i!=2&&i!=1&&i!==void 0)return;let s=this.getEvent(t),r=this._getHitTarget(s.originalPoint,s.bbox,e);if(r){let a=s.id,o=!1;qe(r,n=>{let d={id:a,value:n};return this._mousedown.push(d),!o&&this._dispatchEvent("pointerdown",n,s)&&(o=!0,this._dragging.some(l=>l.value===n&&l.id===a)||this._dragging.push(d)),!0})}}_dispatchGlobalMousemove(t,e,i){let s=this.getEvent(t),r=this._getHitTarget(s.originalPoint,s.bbox,e);s.native=i,r?(this._hovering.forEach(a=>{a.contains(r)||(this._hovering.delete(a),a.cursorOverStyle&&ke(document.body,"cursor",a._replacedCursorStyle),this._dispatchEvent("pointerout",a,s))}),s.native&&qe(r,a=>(this._hovering.has(a)||(this._hovering.add(a),a.cursorOverStyle&&(a._replacedCursorStyle=is(document.body,"cursor"),ke(document.body,"cursor",a.cursorOverStyle)),this._dispatchEvent("pointerover",a,s)),!0))):(this._hovering.forEach(a=>{a.cursorOverStyle&&ke(document.body,"cursor",a._replacedCursorStyle),this._dispatchEvent("pointerout",a,s)}),this._hovering.clear()),this._dispatchEventAll("globalpointermove",s)}removeHovering(t){this._hovering.delete(t),t.cursorOverStyle&&ke(document.body,"cursor",t._replacedCursorStyle)}_dispatchGlobalMouseup(t,e){let i=this.getEvent(t);i.native=e,this._dispatchEventAll("globalpointerup",i)}_dispatchDragMove(t){if(this._dragging.length!==0){let e=this.getEvent(t),i=e.id;this._dragging.forEach(s=>{s.id===i&&this._dispatchEvent("pointermove",s.value,e)})}}_dispatchDragEnd(t,e){let i=t.button,s;if(i==0||i===void 0)s="click";else if(i==2)s="rightclick";else if(i==1)s="middleclick";else return;let r=this.getEvent(t),a=r.id;if(this._mousedown.length!==0){let o=this._getHitTarget(r.originalPoint,r.bbox,e);o&&this._mousedown.forEach(n=>{n.id===a&&n.value.contains(o)&&this._dispatchEvent(s,n.value,r)}),this._mousedown.length=0}this._dragging.length!==0&&(this._dragging.forEach(o=>{o.id===a&&this._dispatchEvent("pointerup",o.value,r)}),this._dragging.length=0)}_dispatchDoubleClick(t,e){let i=this.getEvent(t),s=this._getHitTarget(i.originalPoint,i.bbox,e);s&&qe(s,r=>!this._dispatchEvent("dblclick",r,i))}_dispatchWheel(t,e){let i=this.getEvent(t),s=this._getHitTarget(i.originalPoint,i.bbox,e);s&&qe(s,r=>!this._dispatchEvent("wheel",r,i))}_makeSharedEvent(t,e){if(this._listeners[t]===void 0){let i=e();this._listeners[t]=new we(()=>{delete this._listeners[t],i.dispose()})}return this._listeners[t].increment()}_onPointerEvent(t,e){let i=!1,s=null;function r(){s=null,i=!1}return new lt([new ht(()=>{s!==null&&clearTimeout(s),r()}),$(this.view,Oe(t),a=>{i=!0,s!==null&&clearTimeout(s),s=window.setTimeout(r,0)}),Ys(window,t,(a,o)=>{s!==null&&(clearTimeout(s),s=null),e(a,o,i),i=!1})])}_initEvent(t){switch(t){case"globalpointermove":case"pointerover":case"pointerout":return this._makeSharedEvent("pointermove",()=>{let e=(i,s,r)=>{this._lastPointerMoveEvent={events:i,target:s,native:r},v(i,a=>{this._dispatchGlobalMousemove(a,s,r)})};return new lt([this._onPointerEvent("pointerdown",e),this._onPointerEvent("pointermove",e)])});case"globalpointerup":return this._makeSharedEvent("pointerup",()=>{let e=this._onPointerEvent("pointerup",(s,r,a)=>{v(s,o=>{this._dispatchGlobalMouseup(o,a)}),this._lastPointerMoveEvent={events:s,target:r,native:a}}),i=this._onPointerEvent("pointercancel",(s,r,a)=>{v(s,o=>{this._dispatchGlobalMouseup(o,a)}),this._lastPointerMoveEvent={events:s,target:r,native:a}});return new ht(()=>{e.dispose(),i.dispose()})});case"click":case"rightclick":case"middleclick":case"pointerdown":case"pointermove":case"pointerup":return this._makeSharedEvent("pointerdown",()=>{let e=this._onPointerEvent("pointerdown",(a,o)=>{v(a,n=>{this._dispatchMousedown(n,o)})}),i=this._onPointerEvent("pointermove",a=>{v(a,o=>{this._dispatchDragMove(o)})}),s=this._onPointerEvent("pointerup",(a,o)=>{v(a,n=>{this._dispatchDragEnd(n,o)})}),r=this._onPointerEvent("pointercancel",(a,o)=>{v(a,n=>{this._dispatchDragEnd(n,o)})});return new ht(()=>{e.dispose(),i.dispose(),s.dispose(),r.dispose()})});case"dblclick":return this._makeSharedEvent("dblclick",()=>this._onPointerEvent("dblclick",(e,i)=>{v(e,s=>{this._dispatchDoubleClick(s,i)})}));case"wheel":return this._makeSharedEvent("wheel",()=>$(this.view,Oe("wheel"),e=>{this._dispatchWheel(e,si(e))},{passive:!1}))}}_addEvent(t,e,i,s){let r=this._events[e];r===void 0&&(r=this._events[e]={disposer:this._initEvent(e),callbacks:[],dispatching:!1,cleanup:!1});let a={object:t,context:s,callback:i,disposed:!1};return r.callbacks.push(a),new ht(()=>{a.disposed=!0,r.dispatching?r.cleanup=!0:(xe(r.callbacks,a),r.callbacks.length===0&&(r.disposer.dispose(),delete this._events[e]))})}getCanvas(t,e){this.render(t),e||(e={});let i=this.resolution,s=Math.floor(this._calculatedWidth*this.resolution),r=Math.floor(this._calculatedHeight*this.resolution);if(e.minWidth&&e.minWidth>s){let h=e.minWidth/s;h>i&&(i=h*this.resolution)}if(e.minHeight&&e.minHeight>r){let h=e.minHeight/r;h>i&&(i=h*this.resolution)}if(e.maxWidth&&e.maxWidth<s){let h=e.maxWidth/s;h<i&&(i=h*this.resolution)}if(e.maxHeight&&e.maxHeight>r){let h=e.maxHeight/r;h<i&&(i=h*this.resolution)}e.maintainPixelRatio&&(i/=this.resolution);let a=[],o=!1,n=document.createElement("canvas");i!=this.resolution&&(o=!0,s=s*i/this.resolution,r=r*i/this.resolution),n.width=s,n.height=r,n.style.position="fixed",n.style.top="-10000px",this.view.appendChild(n),a.push(n);let d=n.getContext("2d"),m=0,l=0,c=!1;return v(this.layers,h=>{if(h&&h.visible&&(h.tainted||o)){c=!0,h.exportableView=h.view,h.exportableContext=h.context,h.view=document.createElement("canvas"),h.view.style.position="fixed",h.view.style.top="-10000px",this.view.appendChild(h.view),a.push(h.view);let p=0,_=0;h.margin&&(p+=h.margin.left||0+h.margin.right||0,_+=h.margin.top||0+h.margin.bottom||0),h.view.width=s+p,h.view.height=r+_,h.context=h.view.getContext("2d"),h.dirty=!0,h.scale=i}}),c&&(this._omitTainted=!0,this.render(t),this._omitTainted=!1),v(this.layers,h=>{if(h&&h.visible){let p=0,_=0;h.margin&&(p=-(h.margin.left||0)*this.resolution,_=-(h.margin.top||0)*this.resolution),d.drawImage(h.view,p,_),h.exportableView&&(h.view=h.exportableView,h.exportableView=void 0),h.exportableContext&&(h.context=h.exportableContext,h.exportableContext=void 0),m<h.view.clientWidth&&(m=h.view.clientWidth),l<h.view.clientHeight&&(l=h.view.clientHeight),h.scale=void 0}}),n.style.width=m+"px",n.style.height=l+"px",v(a,h=>{h.style.position="",h.style.top="",this.view.removeChild(h)}),n}},Yi=class{constructor(){this.margin={left:0,right:0,top:0,bottom:0},this._resolution=1,this._width=0,this._height=0,this.view=document.createElement("canvas"),this.context=this.view.getContext("2d",{alpha:!1,willReadFrequently:!0}),this.context.imageSmoothingEnabled=!1,this.view.style.position="absolute",this.view.style.top="0px",this.view.style.left="0px"}resize(t,e,i,s,r){this._resolution=r,t+=this.margin.left+this.margin.right,e+=this.margin.top+this.margin.bottom,i+=this.margin.left+this.margin.right,s+=this.margin.top+this.margin.bottom,this.view.style.left=-this.margin.left+"px",this.view.style.top=-this.margin.top+"px",this._width=Math.floor(t*r),this._height=Math.floor(e*r),this.view.width=this._width,this.view.style.width=i+"px",this.view.height=this._height,this.view.style.height=s+"px"}getImageData(t,e){return this.context.getImageData(Math.round((t.x-e.left)/e.width*this._width),Math.round((t.y-e.top)/e.height*this._height),1,1)}getImageArray(t){this.imageArray||(this.imageArray=this.context.getImageData(0,0,this._width,this._height).data);let e=this.imageArray,i=Math.round(t.x*this._resolution),r=(Math.round(t.y*this._resolution)*this._width+i)*4;return[e[r],e[r+1],e[r+2],e[r+3]]}setMargin(t){this.margin.left=0,this.margin.right=0,this.margin.top=0,this.margin.bottom=0,v(t,e=>{e.margin&&(this.margin.left=Math.max(this.margin.left,e.margin.left),this.margin.right=Math.max(this.margin.right,e.margin.right),this.margin.top=Math.max(this.margin.top,e.margin.top),this.margin.bottom=Math.max(this.margin.bottom,e.margin.bottom))})}clear(){this.context.save(),this.context.fillStyle="#000",this.context.fillRect(0,0,this._width,this._height)}},Je=class{constructor(t,e){this.tainted=!0,this.order=0,this.visible=!0,this.dirty=!0,this._width=0,this._height=0,this.view=t,this.context=e}resize(t,e,i,s,r){this.width!=null&&(t=this.width,i=this.width),this.height!=null&&(e=this.height,s=this.height),this.margin?(t+=this.margin.left+this.margin.right,e+=this.margin.top+this.margin.bottom,i+=this.margin.left+this.margin.right,s+=this.margin.top+this.margin.bottom,this.view.style.left=-this.margin.left+"px",this.view.style.top=-this.margin.top+"px"):(this.view.style.left="0px",this.view.style.top="0px"),this._width=Math.floor(t*r),this._height=Math.floor(e*r),this.view.width=this._width,this.view.style.width=i+"px",this.view.height=this._height,this.view.style.height=s+"px"}clear(){this.context.save(),this.context.clearRect(0,0,this._width,this._height)}};function Ds(g,t){g==null?requestAnimationFrame(t):setTimeout(()=>{requestAnimationFrame(t)},1e3/g)}var Ii=class g{constructor(t,e={},i){if(this._isDirty=!1,this._isDirtyParents=!1,this._isDirtyAnimation=!1,this._dirty={},this._dirtyParents={},this._dirtyBounds={},this._dirtyPositions={},this._ticker=null,this._tickers=[],this._updateTick=!0,this.skipRenderFrame=!1,this.events=new us,this.animationTime=null,this._animations=[],this.language=Ze.new(this,{}),this.locale=je,this.utc=!1,this.numberFormatter=De.new(this,{}),this.dateFormatter=Ee.new(this,{}),this.durationFormatter=$e.new(this,{}),this.tabindex=0,this._tabindexes=[],this._a11yD=!1,this._focusElementDirty=!1,this._skipNextGroupJump=!0,this.verticalLayout=di.new(this,{}),this.horizontalLayout=ci.new(this,{}),this.gridLayout=ui.new(this,{}),this._paused=!1,this.autoResize=!0,this._fontHash=[],this._isDisposed=!1,this._disposers=[],this._tooltips=[],this._htmlEnabledContainers=[],this.entitiesById={},!i)throw new Error("You cannot use `new Class()`, instead use `Class.new()`");this._settings=e,e.accessible==!1&&(this._a11yD=!0),e.useSafeResolution==null&&(e.useSafeResolution=!0);let s;e.useSafeResolution&&(s=as()),this._renderer=new ze(s);let r;if(t instanceof HTMLElement?r=t:r=document.getElementById(t),v(Pt.rootElements,n=>{if(n.dom===r)if(Pt.autoDispose)n.dispose();else throw new Error("You cannot have multiple Roots on the same DOM node")}),this.interfaceColors=At.new(this,{}),r===null)throw new Error("Could not find HTML element with id `"+t+"`");this.dom=r;let a=document.createElement("div");a.style.position="relative",a.style.width="100%",a.style.height="100%",r.appendChild(a);let o=e.tooltipContainerBounds;o&&(this._tooltipContainerSettings=o),this._inner=a,this._updateComputedStyles(),Pt.rootElements.push(this)}static new(t,e){let i=new g(t,e,!0);return i._init(),i}moveDOM(t){let e;if(t instanceof HTMLElement?e=t:e=document.getElementById(t),e){for(;this.dom.childNodes.length>0;)e.appendChild(this.dom.childNodes[0]);this.dom=e,this._initResizeSensor(),this.resize()}}_handleLogo(){if(this._logo){let t=this.dom.offsetWidth,e=this.dom.offsetHeight;t<=150||e<=60?this._logo.hide():this._logo.show()}}_showBranding(){if(!this._logo){let t=this.tooltipContainer.children.push(C.new(this,{interactive:!0,interactiveChildren:!1,position:"absolute",setStateOnChildren:!0,paddingTop:9,paddingRight:9,paddingBottom:9,paddingLeft:9,scale:.6,y:pt(100),centerY:N,tooltipY:10,tooltipText:"Created using amCharts 5",tooltipX:N,cursorOverStyle:"pointer",background:wt.new(this,{fill:K(4671320),fillOpacity:0,tooltipY:5})}));t.set("tooltip",this.systemTooltip),t.events.on("click",()=>{window.open("https://www.amcharts.com/","_blank")}),t.states.create("hover",{});let e=t.children.push(B.new(this,{stroke:K(13421772),strokeWidth:3,svgPath:"M5 25 L13 25h13.6c3.4 0 6 0 10.3-4.3s5.2-12 8.6-12c3.4 0 4.3 8.6 7.7 8.6M83.4 25H79.8c-3.4 0-6 0-10.3-4.3s-5.2-12-8.6-12-4.3 8.6-7.7 8.6",dx:-50,strokeOpacity:0}));e.states.create("hover",{stroke:K(3976191)});let i=t.children.push(B.new(this,{stroke:K(8947848),strokeWidth:3,svgPath:"M83.4 25h-31C37 25 39.5 4.4 28.4 4.4S18.9 24.2 4.3 25H0",dx:50,strokeOpacity:0})),s=gs(ms),r=1500;t.setTimeout(()=>{i.animate({key:"strokeOpacity",to:1,duration:r,easing:s}),i.animate({key:"dx",to:0,duration:r,easing:s}),e.animate({key:"dx",to:0,duration:r,easing:s}),e.animate({key:"strokeOpacity",to:1,duration:r,easing:s})},3e3),i.states.create("hover",{stroke:K(4671320)}),this._logo=t,this._handleLogo()}}_getRealSize(){return this.dom.getBoundingClientRect()}_getCalculatedSize(t){return this._settings.calculateSize?this._settings.calculateSize(t):{width:t.width,height:t.height}}_init(){let t=this._settings;t.accessible!==!1&&(t.focusable&&(this._inner.setAttribute("focusable","true"),this._inner.setAttribute("tabindex",this.tabindex+"")),t.ariaLabel&&this._inner.setAttribute("aria-label",t.ariaLabel),t.role&&this._inner.setAttribute("role",t.role));let e=this._renderer,i=this._getRealSize(),s=this._getCalculatedSize(i),r=Math.floor(s.width),a=Math.floor(s.height),o=Math.floor(i.width),n=Math.floor(i.height),d=C.new(this,{visible:!0,width:r,height:a});this._rootContainer=d,this._rootContainer._defaultThemes.push(xs.new(this));let m=d.children.push(C.new(this,{visible:!0,width:N,height:N}));this.container=m,e.resize(o,n,r,a),this._inner.appendChild(e.view),this._initResizeSensor();let l=document.createElement("div");if(this._htmlElementContainer=l,l.className="am5-html-container",l.style.position="absolute",l.style.pointerEvents="none",this._tooltipContainerSettings||(l.style.overflow="hidden"),this._inner.appendChild(l),this._a11yD!==!0){let c=document.createElement("div");c.className="am5-reader-container",c.setAttribute("role","alert"),c.style.position="absolute",c.style.width="1px",c.style.height="1px",c.style.overflow="hidden",c.style.clip="rect(1px, 1px, 1px, 1px)",this._readerAlertElement=c,this._inner.appendChild(this._readerAlertElement);let h=document.createElement("div");h.className="am5-focus-container",h.style.position="absolute",h.style.pointerEvents="none",h.style.top="0px",h.style.left="0px",h.style.overflow="hidden",h.style.width=r+"px",h.style.height=a+"px",h.setAttribute("role","graphics-document"),$t(h,!1),this._focusElementContainer=h,this._inner.appendChild(this._focusElementContainer);let p=document.createElement("div");this._tooltipElementContainer=p,p.className="am5-tooltip-container",this._inner.appendChild(p),ct("keyboardevents")&&(this._disposers.push($(window,"keydown",_=>{let u=_t(_);u=="Shift"?this._isShift=!0:u=="Tab"&&(this._isShift=_.shiftKey)})),this._disposers.push($(window,"keyup",_=>{_t(_)=="Shift"&&(this._isShift=!1)})),this._disposers.push($(h,"click",()=>{let _=this._focusedSprite;if(_){let u=_.get("clickAnnounceText","");u!==""&&this.readerAlert(u);let f=e.getEvent(new MouseEvent("click"));_.events.dispatch("click",{type:"click",originalEvent:f.event,point:f.point,simulated:!0,target:_})}})),this._disposers.push($(h,"keydown",_=>{let u=this._focusedSprite;if(u){_.key=="Escape"&&(Re(),this._focusedSprite=void 0);let f=0,b=0,x=_t(_);switch(x){case"Enter":case" ":let y=u.get("clickAnnounceText","");if(y!==""&&this.readerAlert(y),x==" "&&u.get("role")!="checkbox")return;_.preventDefault();let w=e.getEvent(new MouseEvent("mouse"));u.events.dispatch("click",{type:"click",originalEvent:w.event,point:w.point,simulated:!0,target:u});return;case"ArrowLeft":f=-6;break;case"ArrowRight":f=6;break;case"ArrowUp":b=-6;break;case"ArrowDown":b=6;break;default:return}if(f!=0||b!=0){if(_.preventDefault(),!u.isDragging()){this._keyboardDragPoint={x:0,y:0};let T=e.getEvent(new MouseEvent("mousedown",{clientX:0,clientY:0}));T.point={x:0,y:0},u.events.isEnabled("pointerdown")&&u.events.dispatch("pointerdown",{type:"pointerdown",originalEvent:T.event,point:T.point,simulated:!0,target:u})}let y=this._keyboardDragPoint;y.x+=f,y.y+=b;let w=e.getEvent(new MouseEvent("mousemove",{clientX:y.x,clientY:y.y}),!1);u.events.isEnabled("globalpointermove")&&u.events.dispatch("globalpointermove",{type:"globalpointermove",originalEvent:w.event,point:w.point,simulated:!0,target:u})}}})),this._disposers.push($(h,"keyup",_=>{if(this._focusedSprite){let u=this._focusedSprite,f=_t(_);switch(f){case"ArrowLeft":case"ArrowRight":case"ArrowUp":case"ArrowDown":if(u.isDragging()){let x=this._keyboardDragPoint,y=e.getEvent(new MouseEvent("mouseup",{clientX:x.x,clientY:x.y}));u.events.isEnabled("globalpointerup")&&u.events.dispatch("globalpointerup",{type:"globalpointerup",originalEvent:y.event,point:y.point,simulated:!0,target:u}),this._keyboardDragPoint=void 0;return}else if(u.get("focusableGroup")){let x=u.get("focusableGroup"),y=this._tabindexes.filter(k=>!!(k.get("focusableGroup")==x&&k.getPrivate("focusable")!==!1&&k.isVisibleDeep())),w=y.indexOf(u),T=y.length-1;w+=f=="ArrowRight"||f=="ArrowDown"?1:-1,w<0?w=T:w>T&&(w=0),es(y[w].getPrivate("focusElement").dom)}break;case"Tab":let b=u.get("focusableGroup");if(b&&this._isShift){this._skipNextGroupJump||(this._focusNext(u.getPrivate("focusElement").dom,-1,b),this._skipNextGroupJump=!0);return}break}}})))}this._startTicker(),this.setThemes([]),this._addTooltip(),this._hasLicense()||this._showBranding()}get systemTooltip(){if(!this._systemTooltip){let t=at.new(this,{themeTags:["system"]});this._systemTooltip=t}return this._systemTooltip}_initResizeSensor(){this._resizeSensorDisposer&&this._resizeSensorDisposer.dispose(),this._resizeSensorDisposer=new Ue(this.dom,()=>{this.autoResize&&this.resize()}),this._disposers.push(this._resizeSensorDisposer)}resize(){let t=this._getRealSize(),e=this._getCalculatedSize(t),i=Math.floor(e.width),s=Math.floor(e.height);if(i>0&&s>0){let r=Math.floor(t.width),a=Math.floor(t.height),o=this._htmlElementContainer;if(o.style.width=i+"px",o.style.height=s+"px",this._a11yD!==!0){let d=this._focusElementContainer;d.style.width=i+"px",d.style.height=s+"px"}this._renderer.resize(r,a,i,s);let n=this._rootContainer;n.setPrivate("width",i),n.setPrivate("height",s),this._render(),this._handleLogo()}}_render(){if(this.skipRenderFrame){this.skipRenderFrame=!1;return}this._renderer.render(this._rootContainer._display),this._focusElementDirty&&(this._updateCurrentFocus(),this._focusElementDirty=!1)}_runTickers(t){v(this._tickers,e=>{e(t)})}_runAnimations(t){let e=0;return Wt(this._animations,i=>{let s=i._runAnimation(t);return s===hi.Stopped?!1:(s===hi.Playing&&++e,!0)}),this._isDirtyAnimation=!1,e===0}_runDirties(){let t={};for(;this._isDirtyParents;)this._isDirtyParents=!1,Vt(this._dirtyParents).forEach(([a,o])=>{delete this._dirtyParents[a],o.isDisposed()||(t[o.uid]=o,o._prepareChildren())});Vt(t).forEach(([a,o])=>{o._updateChildren()});let e=[];Vt(this._dirty).forEach(([a,o])=>{o.isDisposed()?delete this._dirty[a]:(e.push(o),o._beforeChanged())}),e.forEach(a=>{a._changed(),delete this._dirty[a.uid],a._clearDirty()}),this._isDirty=!1;let i={},s=[];Vt(this._dirtyBounds).forEach(([a,o])=>{delete this._dirtyBounds[a],o.isDisposed()||(i[o.uid]=o.depth(),s.push(o))}),this._positionHTMLElements(),s.sort((a,o)=>_s(i[o.uid],i[a.uid])),s.forEach(a=>{a._updateBounds()});let r=this._dirtyPositions;Vt(r).forEach(([a,o])=>{delete r[a],o.isDisposed()||o._updatePosition()}),e.forEach(a=>{a._afterChanged()}),Vt(t).forEach(([a,o])=>{o._childrenPrep=!1,o._childrenUpdt=!1})}_renderFrame(t){if(this._updateTick){this.events.isEnabled("framestarted")&&this.events.dispatch("framestarted",{type:"framestarted",target:this,timestamp:t}),this._checkComputedStyles(),this._runTickers(t);let e=this._runAnimations(t);return this._runDirties(),this._render(),this._renderer.resetImageArray(),this._positionHTMLElements(),this.events.isEnabled("frameended")&&this.events.dispatch("frameended",{type:"frameended",target:this,timestamp:t}),this._tickers.length===0&&e&&!this._isDirtyAnimation&&!this._isDirty}else return!0}_runTicker(t,e){this.isDisposed()||(this.animationTime=t,this._renderFrame(t)?(this._ticker=null,this.animationTime=null):this._paused||(e?this._ticker:Ds(this.fps,this._ticker)))}_runTickerNow(t=1e4){if(!this.isDisposed()){let e=performance.now()+t;for(;;){let i=performance.now();if(i>=e){this.animationTime=null;break}if(this.animationTime=i,this._renderFrame(i)){this.animationTime=null;break}}}}_startTicker(){this._ticker===null&&(this.animationTime=null,this._ticker=t=>{this._runTicker(t)},Ds(this.fps,this._ticker))}get updateTick(){return this._updateTick}set updateTick(t){this._updateTick=t,t&&this._startTicker()}_addDirtyEntity(t){this._isDirty=!0,this._dirty[t.uid]===void 0&&(this._dirty[t.uid]=t),this._startTicker()}_addDirtyParent(t){this._isDirty=!0,this._isDirtyParents=!0,this._dirtyParents[t.uid]===void 0&&(this._dirtyParents[t.uid]=t),this._startTicker()}_addDirtyBounds(t){this._isDirty=!0,this._dirtyBounds[t.uid]===void 0&&(this._dirtyBounds[t.uid]=t),this._startTicker()}_addDirtyPosition(t){this._isDirty=!0,this._dirtyPositions[t.uid]===void 0&&(this._dirtyPositions[t.uid]=t),this._startTicker()}_addAnimation(t){this._isDirtyAnimation=!0,this._animations.indexOf(t)===-1&&this._animations.push(t),this._startTicker()}_markDirty(){this._isDirty=!0}_markDirtyRedraw(){this.events.once("frameended",()=>{this._isDirty=!0,this._startTicker()})}eachFrame(t){return this._tickers.push(t),this._startTicker(),new ht(()=>{xe(this._tickers,t)})}markDirtyGlobal(t){t||(t=this.container),t.walkChildren(e=>{e instanceof C&&this.markDirtyGlobal(e),e.markDirty(),e.markDirtyBounds()})}width(){return Math.floor(this._getCalculatedSize(this._getRealSize()).width)}height(){return Math.floor(this._getCalculatedSize(this._getRealSize()).height)}dispose(){this._isDisposed||(this._isDisposed=!0,this._rootContainer.dispose(),this._renderer.dispose(),this.horizontalLayout.dispose(),this.verticalLayout.dispose(),this.interfaceColors.dispose(),v(this._disposers,t=>{t.dispose()}),this._inner&&ts(this._inner),Et(Pt.rootElements,this))}isDisposed(){return this._isDisposed}readerAlert(t){if(this._a11yD!==!0){let e=this._readerAlertElement;t=ri(t),e.innerHTML==t&&(e.innerHTML=""),e.innerHTML=t}}setThemes(t){this._rootContainer.set("themes",t);let e=this.tooltipContainer;e&&e._applyThemes();let i=this.interfaceColors;i&&i._applyThemes()}_addTooltip(){if(!this.tooltipContainer){let t=this._tooltipContainerSettings,e=this._rootContainer.children.push(C.new(this,{position:"absolute",isMeasured:!1,width:N,height:N,layer:t?35:30,layerMargin:t||void 0}));this.tooltipContainer=e;let i=at.new(this,{});this.container.set("tooltip",i),i.hide(0),this._tooltip=i}}_registerTabindexOrder(t){this._a11yD!=!0&&(t.get("focusable")?be(this._tabindexes,t):Et(this._tabindexes,t),this._invalidateTabindexes())}_unregisterTabindexOrder(t){this._a11yD!=!0&&(Et(this._tabindexes,t),this._invalidateTabindexes())}_invalidateTabindexes(){if(this._a11yD==!0)return;this._tabindexes.sort((e,i)=>{let s=e.get("tabindexOrder",0),r=i.get("tabindexOrder",0);return s==r?0:s>r?1:-1});let t=[];v(this._tabindexes,(e,i)=>{e.getPrivate("focusElement")?this._moveFocusElement(i,e):this._makeFocusElement(i,e);let s=e.get("focusableGroup");s&&e.getPrivate("focusable")!==!1&&(t.indexOf(s)!==-1?e.getPrivate("focusElement").dom.setAttribute("tabindex","-1"):t.push(s))})}_updateCurrentFocus(){this._a11yD!=!0&&this._focusedSprite&&(this._decorateFocusElement(this._focusedSprite),this._positionFocusElement(this._focusedSprite))}_decorateFocusElement(t,e){if(this._a11yD==!0||(e||(e=t.getPrivate("focusElement").dom),!e))return;let i=t.get("role");i?e.setAttribute("role",i):e.removeAttribute("role");let s=t.get("ariaLabel");if(s){let _=ys(t,s);e.setAttribute("aria-label",_)}else e.removeAttribute("aria-label");let r=t.get("ariaLive");r?e.setAttribute("aria-live",r):e.removeAttribute("aria-live");let a=t.get("ariaChecked");a!=null&&i&&["checkbox","option","radio","menuitemcheckbox","menuitemradio","treeitem"].indexOf(i)!==-1?e.setAttribute("aria-checked",a?"true":"false"):e.removeAttribute("aria-checked");let o=t.get("ariaCurrent");o!=null?e.setAttribute("aria-current",o):e.removeAttribute("aria-current");let n=t.get("ariaSelected");n!=null&&i&&["gridcell","option","row","tab","columnheader","rowheader","treeitem"].indexOf(i)!==-1?e.setAttribute("aria-selected",n?"true":"false"):e.removeAttribute("aria-selected"),t.get("ariaHidden")?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden");let d=t.get("ariaOrientation");d?e.setAttribute("aria-orientation",d):e.removeAttribute("aria-orientation");let m=t.get("ariaValueNow");m?e.setAttribute("aria-valuenow",m):e.removeAttribute("aria-valuenow");let l=t.get("ariaValueMin");l?e.setAttribute("aria-valuemin",l):e.removeAttribute("aria-valuemin");let c=t.get("ariaValueMax");c?e.setAttribute("aria-valuemax",c):e.removeAttribute("aria-valuemax");let h=t.get("ariaValueText");h?e.setAttribute("aria-valuetext",h):e.removeAttribute("aria-valuetext");let p=t.get("ariaControls");p?e.setAttribute("aria-controls",p):e.removeAttribute("aria-controls"),t.get("visible")&&t.get("opacity")!==0&&t.get("role")!="tooltip"&&!t.isHidden()&&t.getPrivate("focusable")!==!1&&(t.height()||t.width())?(e.getAttribute("tabindex")!="-1"&&e.setAttribute("tabindex",""+this.tabindex),e.removeAttribute("aria-hidden")):(e.removeAttribute("tabindex"),e.setAttribute("aria-hidden","true"))}_makeFocusElement(t,e){if(e.getPrivate("focusElement")||this._a11yD==!0)return;let i=document.createElement("div");e.get("role")!="tooltip"&&(i.tabIndex=this.tabindex),i.style.position="absolute",$t(i,!1);let s=[];e.setPrivate("focusElement",{dom:i,disposers:s}),this._decorateFocusElement(e),s.push($(i,"focus",r=>{this._handleFocus(r)})),s.push($(i,"blur",r=>{this._handleBlur(r)})),this._moveFocusElement(t,e)}_removeFocusElement(t){if(this._a11yD==!0)return;Et(this._tabindexes,t);let e=t.getPrivate("focusElement");e&&(this._focusElementContainer.removeChild(e.dom),v(e.disposers,s=>{s.dispose()}))}_hideFocusElement(t){if(this._a11yD==!0)return;let e=t.getPrivate("focusElement");e.dom.style.display="none"}_moveFocusElement(t,e){if(this._a11yD==!0)return;let i=this._focusElementContainer,s=e.getPrivate("focusElement").dom;if(s===this._focusElementContainer.children[t])return;let r=this._focusElementContainer.children[t+1];r?i.insertBefore(s,r):i.append(s)}_positionFocusElement(t){if(this._a11yD==!0||t==null)return;this._focusElementContainer.scrollTop=0;let e=t.globalBounds(),i=e.right==e.left?t.width():e.right-e.left,s=e.top==e.bottom?t.height():e.bottom-e.top,r=this._settings.focusPadding!==void 0?this._settings.focusPadding:2,a=e.left-r,o=e.top-r;i<0&&(a+=i,i=Math.abs(i)),s<0&&(o+=s,s=Math.abs(s));let n=t.getPrivate("focusElement").dom;n.style.top=o+"px",n.style.left=a+"px",n.style.width=i+r*2+"px",n.style.height=s+r*2+"px"}_getSpriteByFocusElement(t){let e;return ye(this._tabindexes,(i,s)=>i.getPrivate("focusElement").dom===t?(e=i,!1):!0),e}_handleFocus(t){if(this._a11yD==!0)return;let e=this._getSpriteByFocusElement(t.target);if(e){if(!e.isVisibleDeep()){this._focusNext(t.target,this._isShift?-1:1);return}this._positionFocusElement(e),this._focusedSprite=e,e.events.isEnabled("focus")&&e.events.dispatch("focus",{type:"focus",originalEvent:t,target:e}),e.getPrivate("focusElement").dom.tabIndex==-1&&(this._skipNextGroupJump=!1)}}_focusNext(t,e,i){if(this._a11yD==!0)return;let s=Array.from(document.querySelectorAll(["a[href]","area[href]","button:not([disabled])","details","input:not([disabled])","iframe:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[contentEditable=""]','[contentEditable="true"]','[contentEditable="TRUE"]','[tabindex]:not([tabindex^="-"])'].join(","))),r=s.indexOf(t)+e;r<0?r=s.length-1:r>=s.length&&(r=0);let a=s[r];if(i&&e==-1){let o=this._getSpriteByFocusElement(a);if(o&&o.get("focusableGroup")==i){this._focusNext(a,e);return}}a.focus()}_handleBlur(t){if(this._a11yD==!0)return;let e=this._focusedSprite;e&&!e.isDisposed()&&e.events.isEnabled("blur")&&e.events.dispatch("blur",{type:"blur",originalEvent:t,target:e}),this._focusedSprite=void 0}updateTooltip(t){if(this._a11yD==!0)return;let e=ri(t._getText()),i=t.getPrivate("tooltipElement");t.get("role")=="tooltip"&&e!=""?(i||(i=this._makeTooltipElement(t)),i.innerHTML!=e&&(i.innerHTML=e),i.setAttribute("aria-hidden",t.isVisibleDeep()?"false":"true")):i&&(i.remove(),t.removePrivate("tooltipElement"))}_makeTooltipElement(t){let e=this._tooltipElementContainer,i=document.createElement("div");return i.style.position="absolute",i.style.width="1px",i.style.height="1px",i.style.overflow="hidden",i.style.clip="rect(1px, 1px, 1px, 1px)",$t(i,!1),this._decorateFocusElement(t,i),e.append(i),t.setPrivate("tooltipElement",i),i}_removeTooltipElement(t){if(this._a11yD==!0)return;let e=t.getPrivate("tooltipElement");if(e){let i=e.parentElement;i&&i.removeChild(e)}}_invalidateAccessibility(t){if(this._a11yD==!0)return;this._focusElementDirty=!0;let e=t.getPrivate("focusElement");t.get("focusable")?e&&(this._decorateFocusElement(t),this._positionFocusElement(t)):e&&this._removeFocusElement(t)}focused(t){return this._focusedSprite===t}documentPointToRoot(t){let e=this._getRealSize(),i=this._getCalculatedSize(e),s=i.width/e.width,r=i.height/e.height;return{x:(t.x-e.left)*s,y:(t.y-e.top)*r}}rootPointToDocument(t){let e=this._getRealSize(),i=this._getCalculatedSize(e),s=i.width/e.width,r=i.height/e.height;return{x:t.x/s+e.left,y:t.y/r+e.top}}addDisposer(t){return this._disposers.push(t),t}_updateComputedStyles(){let t=window.getComputedStyle(this.dom),e=this._fontHash,i=ve(t).flatMap(s=>{var r;return typeof s=="string"&&s.startsWith("font")?[(r=t[s])===null||r===void 0?void 0:r.toString()]:[]});if(e.length!==i.length)return this._fontHash=i,!0;for(let s=0;s<e.length;s++)if(e[s]!==i[s])return this._fontHash=i,!0;return!1}_checkComputedStyles(){this._updateComputedStyles()&&this._invalidateLabelBounds(this.container)}_invalidateLabelBounds(t){t instanceof C?t.children.each(e=>{this._invalidateLabelBounds(e)}):t instanceof fi&&t.markDirtyBounds()}_hasLicense(){for(let t=0;t<Pt.licenses.length;t++)if(Pt.licenses[t].match(/^AM5C.{5,}/i))return!0;return!1}_licenseApplied(){this._logo&&this._logo.set("forceHidden",!0)}get debugGhostView(){return this._renderer.debugGhostView}set debugGhostView(t){this._renderer.debugGhostView=t}set tapToActivate(t){this._renderer.tapToActivate=t}get tapToActivate(){return this._renderer.tapToActivate}set tapToActivateTimeout(t){this._renderer.tapToActivateTimeout=t}get tapToActivateTimeout(){return this._renderer.tapToActivateTimeout}_makeHTMLElement(t){let e=this._htmlElementContainer,i=document.createElement("div");t.setPrivate("htmlElement",i);let s=!1,r;t._walkParents(o=>{if(o.get("verticalScrollbar"))return s=!0,r=o,!1});let a;return s&&(a=document.createElement("div"),t.setPrivate("htmlElementWrapper",a),t.setPrivate("wrapperContainer",r),a.style.position="absolute",a.style.overflow="hidden",a.style.boxSizing="border-box",a.style.top="0px",a.style.left="0px",a.style.width="100%",a.style.height="100%",r.events.on("boundschanged",()=>{this._positionHTMLElement(t)})),i.style.position="absolute",i.style.overflow="auto",i.style.boxSizing="border-box",$t(i,t.get("interactive",!1)),t.events.isEnabled("click")&&($t(i,!0),this._disposers.push($(i,"click",o=>{let n=this._renderer.getEvent(o);t.events.dispatch("click",{type:"click",originalEvent:n.event,point:n.point,simulated:!1,target:t})}))),this._positionHTMLElement(t),s?(a.append(i),e.append(a)):e.append(i),be(this._htmlEnabledContainers,t),i}_positionHTMLElements(){v(this._htmlEnabledContainers,t=>{this._positionHTMLElement(t)})}_positionHTMLElement(t){let e=t.getPrivate("htmlElementWrapper");if(e){let s=t.getPrivate("wrapperContainer");if(s){let r=s.globalBounds();e.style.clipPath="rect("+r.top+"px "+r.right+"px "+r.bottom+"px "+r.left+"px)"}}let i=t.getPrivate("htmlElement");if(i){v(["paddingTop","paddingRight","paddingBottom","paddingLeft","minWidth","minHeight","maxWidth","maxHeight"],x=>{let y=t.get(x);y?i.style[x]=y+"px":i.style[x]=""}),v(["fontFamily","fontSize","fontStyle","fontWeight","fontStyle","fontVariant","textDecoration"],x=>{let y=t.get(x);y?x=="fontSize"&&!mt(y)?i.style[x]=y+"px":i.style[x]=y+"":i.style[x]=""});let a=t.compositeScale()||1,o=t.compositeRotation()||0;i.style.transform="",i.style.transformOrigin="";let n=t.compositeOpacity();setTimeout(()=>{i.style.opacity=n+""},10);let d=t.isVisibleDeep();d&&(i.style.display="block");let m={x:t.x()+t.get("dx",0),y:t.y()+t.get("dy",0)};t.parent&&(m=t.parent.toGlobal(m)),i.style.top=m.y+"px",i.style.left=m.x+"px";let l=t.get("width"),c=t.get("height"),h=0,p=0;if(l&&(h=t.width()),c&&(p=t.height()),!l||!c){i.style.position="fixed",i.style.width="",i.style.height="";let x=i.getBoundingClientRect();i.style.position="absolute",l||(h=x.width),c||(p=x.height);let y=h/a,w=p/a,T=t.get("centerX",0),k=t.get("centerY",0),E=0,R=0,D=0,S=0;T instanceof q?(E=-T.value*y,R=(1-T.value)*y):(E=-T,R=y-T),k instanceof q?(D=-k.value*w,S=(1-k.value)*w):(D=-k,S=w-k),t._localBounds={left:E,right:R,top:D,bottom:S};let Y=t._adjustedLocalBounds,H=t._display.getAdjustedBounds(t._localBounds);t._adjustedLocalBounds=H,(Y.left!==H.left||Y.right!==H.right||Y.top!==H.top||Y.bottom!==H.bottom)&&t.markDirtyBounds()}h>0&&(i.style.minWidth=h+"px"),p>0&&(i.style.minHeight=p+"px"),(!d||n==0)&&(i.style.display="none");let _=t.get("centerX",0),u=ei(_)?_.percent+"%":_+"px",f=t.get("centerY",0),b=ei(f)?f.percent+"%":f+"px";(_||f)&&(i.style.transform="translate(-"+u+", -"+b+")"+i.style.transform),a!=1&&(i.style.transform+="scale("+a+")"),o!=0&&(i.style.transform+=" rotate("+o+"deg)"),i.style.transform!=""&&(i.style.transformOrigin=u+" "+b)}}_setHTMLContent(t,e){let i=t.getPrivate("htmlElement");i||(i=this._makeHTMLElement(t),this.autoResize||this.resize()),i.innerHTML!=e&&(i.innerHTML=e)}_removeHTMLContent(t){let e=t.getPrivate("htmlElementWrapper"),i=t.getPrivate("htmlElement");e?(this._htmlElementContainer.removeChild(e),t.removePrivate("htmlElement"),t.removePrivate("htmlElementWrapper"),t.removePrivate("wrapperContainer")):i&&(this._htmlElementContainer.removeChild(i),t.removePrivate("htmlElement"),t.removePrivate("wrapperContainer")),Et(this._htmlEnabledContainers,t)}};var Qe;function Gs(g,t,e){let i=t.interfaceColors,s=i.get("secondaryButton").toCSS(),r=i.get("text").toCSS(),a=i.get("alternativeBackground").toCSS(.45);if(!Qe){let o=new lt([new I(g,".am5-modal",{width:"100%",height:"100%",position:"absolute","z-index":"100000",top:"0",left:"0"},t.nonce),new I(g,".am5-modal-curtain",{top:"0",left:"0",width:"100%",height:"100%",position:"absolute",background:i.get("background").toCSS(.5),"z-index":"100"},t.nonce),new I(g,".am5-modal-wrapper",{top:"0",left:"0",width:"100%",height:"100%",position:"absolute","text-align":"center","white-space":"nowrap",background:i.get("background").toCSS(.5),"z-index":"101"},t.nonce),new I(g,".am5-modal-wrapper:before",{content:"''",display:"inline-block",height:"100%","vertical-align":"middle","margin-right":"-0.25em"},t.nonce),new I(g,".am5-modal-content",{display:"inline-block",padding:"1.2em","vertical-align":"middle","text-align":"start","white-space":"normal",background:i.get("background").toCSS(),"border-radius":"4px","-webkit-box-shadow":"0px 0px 36px 0px "+a,"box-shadow":"0px 0px 36px 0px "+a,color:r},t.nonce),new I(g,".am5-modal-content h1",{"font-size":"1em",margin:"0 0 0.5em 0"},t.nonce),new I(g,".am5-modal-table",{display:"table",margin:"1em 0"},t.nonce),new I(g,".am5-modal-table-row",{display:"table-row"},t.nonce),new I(g,".am5-modal-table-heading",{display:"table-heading",padding:"3px 10px 3px 0"},t.nonce),new I(g,".am5-modal-table-cell",{display:"table-cell",padding:"3px 0 3px 0"},t.nonce),new I(g,".am5-modal-table-cell > *",{"vertical-align":"middle"},t.nonce),new I(g,".am5-modal-content input[type=text], .am5-modal-content input[type=number], .am5-modal-content select",{border:"1px solid "+s,"border-radius":"4px",padding:"3px 5px",margin:"2px"},t.nonce),new I(g,".am5-modal-input-narrow",{width:"50px"},t.nonce),new I(g,".am5-modal-button",{"font-weight":"400",color:i.get("secondaryButtonText").toCSS(),"line-height":"1.5","text-align":"center","text-decoration":"none","vertical-align":"middle",cursor:"pointer",padding:"0.2em 0.8em","font-size":"1em","border-radius":"0.25em",margin:"0 0.25em 0 0",border:"1px solid "+i.get("secondaryButtonStroke").toCSS(),background:i.get("secondaryButton").toCSS()},t.nonce),new I(g,".am5-modal-button:hover",{background:i.get("secondaryButtonHover").toCSS()},t.nonce),new I(g,".am5-modal-button.am5-modal-primary",{color:i.get("primaryButtonText").toCSS(),border:"1px solid "+i.get("primaryButtonStroke").toCSS(),background:i.get("primaryButton").toCSS()},t.nonce),new I(g,".am5-modal-button.am5-modal-primary:hover",{background:i.get("primaryButtonHover").toCSS()},t.nonce)]);Qe=new we(()=>{Qe=void 0,o.dispose()})}return Qe.increment()}var Kt=class extends P{_afterNew(){super._afterNewApplyThemes(),this._setRawDefault("deactivateRoot",!0),Gs(rs(this._root.dom),this._root);let t=document.createElement("div");t.className="am5-modal",t.style.display="none",this.root._inner.appendChild(t),this.setPrivate("container",t);let e=document.createElement("div");e.className="am5-modal-curtain",t.appendChild(e),this.setPrivate("curtain",e),this._disposers.push($(e,"click",()=>{this.cancel()}));let i=document.createElement("div");i.className="am5-modal-wrapper",t.appendChild(i),this.setPrivate("wrapper",i);let s=document.createElement("div");s.className="am5-modal-content",i.appendChild(s),this.setPrivate("content",s);let r=this.get("content");r&&(s.innerHTML=r),ct("keyboardevents")&&this._disposers.push($(document,"keydown",a=>{this.isOpen()&&_t(a)=="Escape"&&this.cancel()}))}_beforeChanged(){super._beforeChanged(),this.isDirty("content")&&(this.getPrivate("content").innerHTML=this.get("content",""))}isOpen(){return this.getPrivate("container").style.display!="none"}open(){this.getPrivate("container").style.display="block",this.get("deactivateRoot")&&this.setTimeout(()=>{this._root._renderer.interactionsEnabled=!1},10),this.events.dispatch("opened",{type:"opened",target:this})}close(){this.getPrivate("container").style.display="none",this.get("deactivateRoot")&&(this._root._renderer.interactionsEnabled=!0),this.events.dispatch("closed",{type:"closed",target:this})}cancel(){this.getPrivate("container").style.display="none",this.get("deactivateRoot")&&(this._root._renderer.interactionsEnabled=!0),this.events.dispatch("cancelled",{type:"cancelled",target:this})}_dispose(){super._dispose();let t=this.getPrivate("container");t.parentElement&&t.parentElement.removeChild(t)}};Kt.className="Modal";Kt.classNames=P.classNames.concat([Kt.className]);var Jt=class extends P{_afterNew(){super._afterNewApplyThemes()}_beforeChanged(){if(super._beforeChanged(),this.isDirty("sprite")){let t=this.get("sprite");t&&(t.setAll({position:"absolute",role:"figure"}),this._disposers.push(t))}(this.isDirty("locationX")||this.isDirty("locationY"))&&this.series&&this.series._positionBullet(this)}};Jt.className="Bullet";Jt.classNames=P.classNames.concat([Jt.className]);var Qt=class extends Lt{_afterNew(){super._afterNew(),this.addTag("confirm"),ct("keyboardevents")&&this._disposers.push($(document,"keydown",t=>{let e=_t(t);this.get("active")&&e=="Escape"&&this._cancel()})),this._disposers.push($(document,"click",()=>{this._ignoreClick||this._cancel(),this._ignoreClick=!1})),this.events.on("click",()=>{this.get("active")||(this._ignoreClick=!0),this._confirm()})}_cancel(){this.get("active")&&(this.events.dispatch("cancelled",{type:"cancelled",target:this}),this.set("active",!1))}_confirm(){this.get("active")&&(this.events.dispatch("confirmed",{type:"confirmed",target:this}),this.set("active",!1),this.isFocus()&&this.setTimeout(()=>{this.set("active",!1),Re()},10))}_prepareChildren(){super._prepareChildren()}};Qt.className="ConfirmButton";Qt.classNames=Lt.classNames.concat([Qt.className]);var zt=class extends B{_afterNew(){super._afterNew(),this._display.isMeasured=!0,this.setPrivateRaw("trustBounds",!0)}_beforeChanged(){super._beforeChanged(),this.isDirty("radius")&&(this._clear=!0)}_changed(){super._changed(),this._clear&&this._display.drawCircle(0,0,Math.abs(this.get("radius",10)))}};zt.className="Circle";zt.classNames=B.classNames.concat([zt.className]);var te=class extends B{_beforeChanged(){if(super._beforeChanged(),this.isDirty("coordinates")){let t=[],e=this.get("coordinates");e&&v(e,i=>{t.push({x:i[0],y:i[1]})}),this.set("points",t)}if(this.isPrivateDirty("points")&&(this._clear=!0),this.isDirty("points")){this._clear=!0;let t=this.get("points"),e=this._prevSettings.points;if(e){if(t){let o=Gt(t),n=Gt(e),d=o.length,m=n.length;if(d>m){let l=Gt(o);for(let c=0;c<d;c++){let h=Math.floor(c/d*m);l[c]={x:n[h].x,y:n[h].y}}n=l}else if(m>d){let l=Gt(n);for(let c=0;c<m;c++){let h=Math.floor(c/m*d);l[c]={x:o[h].x,y:o[h].y}}o=l}this.setPrivateRaw("previousPoints",n),this.setPrivateRaw("points",o),this.morphAnimation=this.animatePrivate({key:"morphProgress",from:0,to:1,duration:this.get("animationDuration",0),easing:this.get("animationEasing")}),this._root.events.once("frameended",()=>{this._markDirtyPrivateKey("morphProgress")})}}else this.setPrivateRaw("previousPoints",t),this.setPrivateRaw("points",t);let i=1/0,s=-1/0,r=1/0,a=-1/0;if(t)for(let o=1,n=t.length;o<n;o++){let d=t[o];i=Math.min(i,d.x),s=Math.max(s,d.x),r=Math.min(r,d.y),a=Math.max(a,d.y)}this.setPrivate("minX",i),this.setPrivate("maxX",s),this.setPrivate("minY",r),this.setPrivate("maxY",r)}this.isPrivateDirty("morphProgress")&&(this._clear=!0)}_changed(){super._changed(),this._clear&&this._draw()}_draw(){let t=this.getPrivate("previousPoints"),e=this.getPrivate("points"),i=this.getPrivate("morphProgress",1);if(e&&t){let s=e[0],r=t[0];s&&this._display.moveTo(r.x+(s.x-r.x)*i,r.y+(s.y-r.y)*i);for(let a=1,o=e.length;a<o;a++){let n=e[a],d=t[a];this._display.lineTo(d.x+(n.x-d.x)*i,d.y+(n.y-d.y)*i)}this._display.closePath()}}_updateSize(){this.markDirty(),this._clear=!0}};te.className="Polygon";te.classNames=B.classNames.concat([te.className]);var ee=class extends B{_beforeChanged(){super._beforeChanged(),(this.isDirty("radiusX")||this.isDirty("radiusY")||this.isDirty("rotation"))&&(this._clear=!0)}_changed(){super._changed(),this._clear&&this._display.drawEllipse(0,0,Math.abs(this.get("radiusX")),Math.abs(this.get("radiusY")))}};ee.className="Ellipse";ee.classNames=B.classNames.concat([ee.className]);var ie=class extends B{_beforeChanged(){super._beforeChanged(),(this.isDirty("radius")||this.isDirty("innerRadius")||this.isDirty("spikes"))&&(this._clear=!0)}_changed(){if(super._changed(),this._clear){let t=this._display,e=this.get("radius",0),i=Bt(this.get("innerRadius",0),e),s=this.get("spikes",0),r=Math.PI/s,a=Math.PI/2*3;t.moveTo(0,-e);for(let o=0;o<s;o++)t.lineTo(Math.cos(a)*e,Math.sin(a)*e),a+=r,t.lineTo(Math.cos(a)*i,Math.sin(a)*i),a+=r;t.lineTo(0,-e),t.closePath()}}};ie.className="Star";ie.classNames=B.classNames.concat([ie.className]);var Ft=class extends C{constructor(){super(...arguments),this._movePoints={},this._downScale=1,this._downX=0,this._downY=0,this.contents=this.children.push(C.new(this._root,{width:N,height:N,x:0,y:0,draggable:!0,background:wt.new(this._root,{fill:K(16777215),fillOpacity:0})}))}_afterNew(){super._afterNew();let t=this.contents.events;this._disposers.push(t.on("pointerdown",s=>{this._handleThisDown(s)})),this._disposers.push(t.on("globalpointerup",s=>{this._handleThisUp(s)})),this._disposers.push(t.on("globalpointermove",s=>{this._handleThisMove(s)}));let e=this.contents.get("background");e&&(e.adapters.add("width",s=>Number(s)*20),e.adapters.add("height",s=>Number(s)*20),e.adapters.add("x",s=>Number(s)-e.width()/2),e.adapters.add("y",s=>Number(s)-e.height()/2));let i=this.contents;i.adapters.add("x",s=>{let r=i.get("scale",1);if(M(s)&&r>=1){let a=this.get("maxPanOut",.4),o=i.width();s=Math.min(o*a,s),s=Math.max(this.width()-o*r*(1+a),s)}return s}),i.adapters.add("y",s=>{let r=i.get("scale",1);if(M(s)&&r>=1){let a=this.get("maxPanOut",.4),o=i.height();s=Math.min(o*a,s),s=Math.max(this.height()-o*r*(1+a),s)}return s})}_prepareChildren(){super._prepareChildren(),this.isDirty("wheelable")&&this._handleSetWheel(),this.contents._display.cancelTouch=this.get("pinchZoom",!1)}_handleSetWheel(){this.get("wheelable")?(this._wheelDp&&this._wheelDp.dispose(),this._wheelDp=this.events.on("wheel",t=>{let e=t.originalEvent;if(ss(e,this))e.preventDefault();else return;let i=this.toLocal(t.point);this._handleWheelZoom(e.deltaY,i)}),this._disposers.push(this._wheelDp)):this._wheelDp&&this._wheelDp.dispose()}_handleWheelZoom(t,e){let i=this.get("zoomStep",2),s=this.contents.get("scale",1),r=s;t>0?r=s/i:t<0&&(r=s*i),r!=s&&this.zoomToPoint(e,r)}zoomToPoint(t,e){e&&(e=j(e,this.get("minZoomLevel",1),this.get("maxZoomLevel",32)));let i=this.contents.get("scale",1),s=t.x,r=t.y,a=s,o=r,n=this.contents,d=n.x(),m=n.y(),l=a-(s-d)/i*e,c=o-(r-m)/i*e;return this._animateTo(l,c,e),this._za}zoomIn(){return this.zoomToPoint({x:this.width()/2,y:this.height()/2},this.contents.get("scale",1)*this.get("zoomStep",2))}zoomOut(){return this.zoomToPoint({x:this.width()/2,y:this.height()/2},this.contents.get("scale",1)/this.get("zoomStep",2))}goHome(){return this._animateTo(0,0,1)}_animateTo(t,e,i){let s=this.get("animationDuration",0),r=this.get("animationEasing"),a=this.contents;this._txa=a.animate({key:"x",to:t,duration:s,easing:r}),this._tya=a.animate({key:"y",to:e,duration:s,easing:r}),this._za=a.animate({key:"scale",to:i,duration:s,easing:r})}_handleThisUp(t){this._downPoints={}}_handleThisDown(t){let e=this.contents;this._downScale=e.get("scale",1);let i=e._downPoints,s=ve(i).length;if(s==1){let r=i[1];r||(r=i[0]),r&&r.x==t.point.x&&r.y==t.point.y&&(s=0)}if(s>0){this._downX=e.x(),this._downY=e.y();let r=e._getDownPointId();if(r){let a=this._movePoints[r];a&&(e._downPoints[r]=a)}}}_handleThisMove(t){let i=t.originalEvent.pointerId;if(this.get("pinchZoom")&&i&&(this._movePoints[i]=t.point,ve(this.contents._downPoints).length>1)){this._handlePinch();return}}_handlePinch(){let t=0,e=[],i=[];if(W(this.contents._downPoints,(s,r)=>{e[t]=r;let a=this._movePoints[s];a&&(i[t]=a),t++}),e.length>1&&i.length>1){this.contents._isDragging=!1;let s=e[0],r=e[1],a=i[0],o=i[1];if(s&&r&&a&&o){s=this.toLocal(s),r=this.toLocal(r),a=this.toLocal(a),o=this.toLocal(o);let n=Math.hypot(r.x-s.x,r.y-s.y),m=Math.hypot(o.x-a.x,o.y-a.y)/n*this._downScale,l={x:a.x+(o.x-a.x)/2,y:a.y+(o.y-a.y)/2},c={x:s.x+(r.x-s.x)/2,y:s.y+(r.y-s.y)/2},h=this._downX||0,p=this._downY||0,_=this._downScale,u=l.x-(-h+c.x)/_*m,f=l.y-(-p+c.y)/_*m;this.contents.setAll({x:u,y:f,scale:m})}}}};Ft.className="ZoomableContainer";Ft.classNames=C.classNames.concat([Ft.className]);var it=class extends P{_afterNew(){super._afterNewApplyThemes()}getFill(t){return{addColorStop:(e,i)=>{}}}_changed(){super._changed()}getBounds(t){let e=this.get("target");if(e){let i=e.globalBounds(),s=t.toLocal({x:i.left,y:i.top}),r=t.toLocal({x:i.right,y:i.top}),a=t.toLocal({x:i.right,y:i.bottom}),o=t.toLocal({x:i.left,y:i.bottom});return{left:Math.min(s.x,r.x,a.x,o.x),top:Math.min(s.y,r.y,a.y,o.y),right:Math.max(s.x,r.x,a.x,o.x),bottom:Math.max(s.y,r.y,a.y,o.y)}}return t._display.getLocalBounds()}};it.className="Gradient";it.classNames=P.classNames.concat([it.className]);var Rt=class extends it{getFill(t){let e=this.get("rotation",0),i=this.getBounds(t),s=i.left||0,r=i.right||0,a=i.top||0,o=i.bottom||0,n=bt(e),d=xt(e),m=n*(r-s),l=d*(o-a);m==0&&(m=1),l==0&&(l=1);let c=Math.max(m,l),h=this._root._renderer.createLinearGradient(s,a,s+c*n,a+c*d),p=this.get("stops");if(p){let _=0;v(p,u=>{let f=u.offset;M(f)||(f=_/(p.length-1));let b=u.opacity;M(b)||(b=1);let x=u.color;if(x){let y=u.lighten;y&&(x=L.lighten(x,y));let w=u.brighten;w&&(x=L.brighten(x,w)),h.addColorStop(f,"rgba("+x.r+","+x.g+","+x.b+","+b+")")}_++})}return h}};Rt.className="LinearGradient";Rt.classNames=it.classNames.concat([Rt.className]);var se=class extends C{constructor(){super(...arguments),this.labelContainer=this.children.push(C.new(this._root,{})),this.markerContainer=this.children.push(C.new(this._root,{})),this.startLabel=this.labelContainer.children.push(rt.new(this._root,{themeTags:["start"]})),this.endLabel=this.labelContainer.children.push(rt.new(this._root,{themeTags:["end"]})),this.markers=this.addDisposer(new yt(vt.new({}),()=>kt._new(this._root,{themeTags:U(this.markers.template.get("themeTags",[]),[this.get("orientation"),"heatlegend","marker"])},[this.markers.template])))}_afterNew(){this._settings.themeTags=U(this._settings.themeTags,["heatlegend",this._settings.orientation]),super._afterNew(),this.set("tooltip",at.new(this._root,{themeTags:["heatlegend"]}))}makeMarker(){let t=this.markers.make();return t.states.create("disabled",{}),t}showValue(t,e,i){let s=this.getTooltip();if(s&&M(t)){let r=this.get("startValue",0),a=this.get("endValue",1),o=(t-r)/(a-r);(o==1/0||o==-1/0||isNaN(o))&&(o=.5);let n=this.get("startColor"),d=this.get("endColor");e||(e=this.getNumberFormatter().format(t)),i||(i=L.interpolate(o,n,d)),s.label.set("text",e);let m;this.get("orientation")=="vertical"?m=this.markerContainer.toGlobal({x:0,y:this.innerHeight()*(1-o)}):m=this.markerContainer.toGlobal({x:this.innerWidth()*o,y:0});let l=s.get("background");l&&l.set("fill",i),s.set("pointTo",m),s.show()}}_prepareChildren(){super._prepareChildren();let t=this.labelContainer,e=this.get("orientation"),i=this.startLabel,s=this.endLabel,r=this.getTooltip();if(this.isDirty("orientation")&&(e=="vertical"?(this.markerContainer.setAll({layout:this._root.verticalLayout,height:N}),this.set("layout",this._root.horizontalLayout),i.setAll({y:N,x:void 0,centerY:N,centerX:N}),s.setAll({y:0,x:void 0,centerY:0,centerX:N}),t.setAll({height:N,width:void 0}),r&&r.set("pointerOrientation","horizontal")):(this.markerContainer.setAll({layout:this._root.horizontalLayout,width:N}),this.set("layout",this._root.verticalLayout),i.setAll({x:0,y:void 0,centerX:0,centerY:0}),s.setAll({x:N,y:void 0,centerX:N,centerY:0}),t.setAll({width:N,height:void 0}),r&&r.set("pointerOrientation","vertical"))),this.isDirty("stepCount")){let a=this.get("stepCount",1),o=this.get("startColor"),n=this.get("endColor"),d=this.get("startOpacity",1),m=this.get("endOpacity",1);if(this.markerContainer.children.clear(),a>1)for(let l=0;l<a;l++){let c=this.makeMarker();e=="vertical"?this.markerContainer.children.moveValue(c,0):this.markerContainer.children.push(c),o&&n&&c.setAll({fill:L.interpolate(l/a,o,n),fillOpacity:pt(l/a*100).interpolate(d,m)})}else if(a==1){let l=this.makeMarker();this.markerContainer.children.push(l);let c=Rt.new(this._root,{stops:[{color:o,opacity:d},{color:n,opacity:m}]});if(e=="vertical"){c.set("rotation",90);let h=c.get("stops");h&&h.reverse()}else c.set("rotation",0);o&&n&&l.set("fillGradient",c)}}(this.isDirty("startText")||this.isDirty("startValue"))&&i.set("text",this.get("startText",this.getNumberFormatter().format(this.get("startValue",0)))),(this.isDirty("endText")||this.isDirty("endValue"))&&s.set("text",this.get("endText",this.getNumberFormatter().format(this.get("endValue",1))))}};se.className="HeatLegend";se.classNames=C.classNames.concat([se.className]);var re=class extends Ie{constructor(){super(...arguments),this.itemContainers=this.addDisposer(new yt(vt.new({}),()=>C._new(this._root,{themeTags:U(this.itemContainers.template.get("themeTags",[]),["legend","item"]),themeTagsSelf:U(this.itemContainers.template.get("themeTagsSelf",[]),["itemcontainer"]),background:kt.new(this._root,{themeTags:U(this.itemContainers.template.get("themeTags",[]),["legend","item","background"]),themeTagsSelf:U(this.itemContainers.template.get("themeTagsSelf",[]),["itemcontainer"])})},[this.itemContainers.template]))),this.markers=this.addDisposer(new yt(vt.new({}),()=>C._new(this._root,{themeTags:U(this.markers.template.get("themeTags",[]),["legend","marker"])},[this.markers.template]))),this.labels=this.addDisposer(new yt(vt.new({}),()=>rt._new(this._root,{themeTags:U(this.labels.template.get("themeTags",[]),["legend","label"])},[this.labels.template]))),this.valueLabels=this.addDisposer(new yt(vt.new({}),()=>rt._new(this._root,{themeTags:U(this.valueLabels.template.get("themeTags",[]),["legend","label","value"])},[this.valueLabels.template]))),this.markerRectangles=this.addDisposer(new yt(vt.new({}),()=>kt._new(this._root,{themeTags:U(this.markerRectangles.template.get("themeTags",[]),["legend","marker","rectangle"])},[this.markerRectangles.template])))}_afterNew(){this._settings.themeTags=U(this._settings.themeTags,["legend"]),this.fields.push("name","stroke","fill"),super._afterNew()}makeItemContainer(t){let e=this.children.push(this.itemContainers.make());return e._setDataItem(t),this.itemContainers.push(e),e.states.create("disabled",{}),e}makeMarker(){let t=this.markers.make();return this.markers.push(t),t.states.create("disabled",{}),t}makeLabel(){let t=this.labels.make();return t.states.create("disabled",{}),t}makeValueLabel(){let t=this.valueLabels.make();return t.states.create("disabled",{}),t}makeMarkerRectangle(){let t=this.markerRectangles.make();return t.states.create("disabled",{}),t}processDataItem(t){super.processDataItem(t);let e=this.makeItemContainer(t),i=this.get("nameField"),s=this.get("fillField"),r=this.get("strokeField");if(e){let a=this.get("clickTarget","itemContainer"),o=t.dataContext;o&&o.set&&o.set("legendDataItem",t),e._setDataItem(t),t.set("itemContainer",e);let n=this.makeMarker();if(n){e.children.push(n),n._setDataItem(t),t.set("marker",n);let l=this.get("useDefaultMarker"),c=n.children.push(this.makeMarkerRectangle()),h=t.get("fill"),p=t.get("stroke");t.set("markerRectangle",c),o&&o.get&&(h=o.get(s,h),p=o.get(r,p)),p||(p=h),l?o.on&&(o.on(s,()=>{c.set("fill",o.get(s))}),o.on(r,()=>{c.set("stroke",o.get(r))})):o&&o.createLegendMarker&&o.createLegendMarker(),c.setAll({fill:h,stroke:p});let _=o.component;_&&_.updateLegendMarker&&_.updateLegendMarker(o)}let d=this.makeLabel();if(d){e.children.push(d),d._setDataItem(t),t.set("label",d),d.text.on("text",()=>{e.setRaw("ariaLabel",d.text._getText()+(this.get("clickTarget")!=="none"?"; "+this._t("Press ENTER to toggle"):"")),e.markDirtyAccessibility()}),o&&o.get&&t.set("name",o.get(i));let l=t.get("name");l&&d.set("text",l)}let m=this.makeValueLabel();if(m&&(e.children.push(m),m._setDataItem(t),t.set("valueLabel",m)),o&&o.show&&(o.on("visible",l=>{e.set("disabled",!l)}),o.get("visible")||e.set("disabled",!0),a!="none")){let l=e;a=="marker"&&(l=n),this._addClickEvents(l,o,t)}this.children.values.sort((l,c)=>{let h=l.dataItem.dataContext,p=c.dataItem.dataContext;if(h&&p){let _=this.data.indexOf(h),u=this.data.indexOf(p);if(_>u)return 1;if(_<u)return-1}return 0}),o&&o.updateLegendValue&&o.updateLegendValue()}}_addClickEvents(t,e,i){t.set("cursorOverStyle","pointer"),t.events.on("pointerover",()=>{let s=e.component;s&&s.hoverDataItem&&s.hoverDataItem(e)}),t.events.on("pointerout",()=>{let s=e.component;s&&s.hoverDataItem&&s.unhoverDataItem(e)}),t.events.on("click",()=>{let s=i.get("label").text._getText();e.show&&e.isHidden&&(e.isHidden()||e.get("visible")===!1)?(e.show(),t.set("disabled",!1),this._root.readerAlert(this._t("%1 shown",this._root.locale,s))):e.hide&&(e.hide(),t.set("disabled",!0),this._root.readerAlert(this._t("%1 hidden",this._root.locale,s)))})}disposeDataItem(t){super.disposeDataItem(t);let e=t.dataContext;e&&e.get&&e.get("legendDataItem")==t&&e.set("legendDataItem",void 0);let i=t.get("itemContainer");i&&(this.itemContainers.removeValue(i),i.dispose());let s=t.get("marker");s&&(this.markers.removeValue(s),s.dispose());let r=t.get("markerRectangle");r&&(this.markerRectangles.removeValue(r),r.dispose());let a=t.get("label");a&&(this.labels.removeValue(a),a.dispose());let o=t.get("valueLabel");o&&(this.valueLabels.removeValue(o),o.dispose())}};re.className="Legend";re.classNames=Ie.classNames.concat([re.className]);var st=class extends B{_beforeChanged(){super._beforeChanged(),(this.isDirty("width")||this.isDirty("height")||this.isPrivateDirty("width")||this.isPrivateDirty("height"))&&(this._clear=!0)}_changed(){super._changed(),this._clear&&!this.get("draw")&&this._draw()}_draw(){let t=this.width(),e=this.height(),i=this._display;i.moveTo(-t/2,e/2),i.lineTo(0,-e/2),i.lineTo(t/2,e/2),i.lineTo(-t/2,e/2),i.closePath()}_updateSize(){this.markDirty(),this._clear=!0}};st.className="Triangle";st.classNames=B.classNames.concat([st.className]);var ut=class g extends B{_beforeChanged(){super._beforeChanged(),this.isDirty("points")&&(this._clear=!0)}static makeOrthogonal(t){if(t.length>1){let e=[];for(let i=0;i<t.length-1;i++){let s=t[i],r=t[i+1];e.push(s),s.x!==r.x&&s.y!==r.y&&e.push({x:r.x,y:s.y})}e.push(t[t.length-1]),t=e}return t}_changed(){if(super._changed(),this._clear){let t=this._display,e=this.get("points",[]);if(e.length===0)return;e=g.makeOrthogonal(e),t.moveTo(e[0].x,e[0].y);for(let i=1;i<e.length;i++){let s=this.get("cornerRadius",0),r=e[i-1],a=e[i],o=e[i+1],n=a.y===r.y&&a.x!==r.x,d=a.x===r.x&&a.y!==r.y,m=o&&(n&&o.y!==a.y||d&&o.x!==a.x);if(s>0&&o&&m){if(d){s=Math.min(s,Math.abs(a.x-o.x)/2,Math.abs(a.y-r.y)/2);let l=Math.sign(a.y-r.y);t.lineTo(a.x,a.y-s*l);let c=o.x<a.x?-1:1;t.arcTo(a.x,a.y,a.x+s*c,a.y,s)}else if(n){s=Math.min(s,Math.abs(a.y-o.y)/2,Math.abs(a.x-r.x)/2);let l=Math.sign(a.x-r.x);t.lineTo(a.x-s*l,a.y);let c=o.y<a.y?-1:1;t.arcTo(a.x,a.y,a.x,a.y+s*c,s)}}else t.lineTo(a.x,a.y)}}}};ut.className="OrthogonalLine";ut.classNames=B.classNames.concat([ut.className]);var ae=class extends C{constructor(){super(...arguments),this.line=this.children.push(ut.new(this._root,{themeTags:["line"]})),this.hitLine=this.children.push(ut.new(this._root,{themeTags:["hit"]})),this.startArrow=this.children.push(st.new(this._root,{themeTags:["start","arrow"]})),this.endArrow=this.children.push(st.new(this._root,{themeTags:["end","arrow"]}))}_afterNew(){this.addTag("link"),super._afterNew()}_updateChildren(){if(super._updateChildren(),this.isDirty("points")){let t=ut.makeOrthogonal(this.get("points",[]));this.line.set("points",t),this.hitLine.set("points",t);let e=this.startArrow,i=this.endArrow,s=t.length;if(s>1){let[r,a]=t;e.setAll({x:r.x,y:r.y,rotation:Se(r,a)-90});let o=t[s-1],n=t[s-2];i.setAll({x:o.x,y:o.y,rotation:Se(n,o)+90})}else if(s===1){let[r]=t;e.setAll({x:r.x,y:r.y,rotation:0}),i.setAll({x:r.x,y:r.y,rotation:0})}}}};ae.className="Link";ae.classNames=C.classNames.concat([ae.className]);var oe=class extends Ye{constructor(){super(...arguments),this._display=this._root._renderer.makePicture(void 0)}_changed(){if(super._changed(),this.isDirty("width")){let t=this.get("width");this._display.width=M(t)?t:void 0}if(this.isDirty("height")){let t=this.get("height");this._display.height=M(t)?t:void 0}if(this.isDirty("shadowColor")){this._display.clear();let t=this.get("shadowColor");this._display.shadowColor=t??void 0}this.isDirty("shadowBlur")&&(this._display.clear(),this._display.shadowBlur=this.get("shadowBlur")),this.isDirty("shadowOffsetX")&&(this._display.clear(),this._display.shadowOffsetX=this.get("shadowOffsetX")),this.isDirty("shadowOffsetY")&&(this._display.clear(),this._display.shadowOffsetY=this.get("shadowOffsetY")),this.isDirty("shadowOpacity")&&(this._display.clear(),this._display.shadowOpacity=this.get("shadowOpacity")),(this.isDirty("src")||this.isDirty("cors"))&&(this._display.clear(),this._load())}_load(){let t=this.get("src");if(t){let e=new Image;e.crossOrigin=this.get("cors","anonymous"),e.src=t;let i=this.events;e.decode().then(()=>{this._display.image=e,this._updateSize(),!i.isDisposed()&&i.isEnabled("loaded")&&i.dispatch("loaded",{type:"loaded",target:this})}).catch(s=>{!i.isDisposed()&&i.isEnabled("loaderror")&&i.dispatch("loaderror",{type:"loaderror",target:this})})}}_updateSize(){super._updateSize();let t=this._display.image;if(t){let e=this.getPrivate("width",this.get("width")),i=this.getPrivate("height",this.get("height")),s=t.width&&t.height?t.width/t.height:0;M(e)&&M(i)?(this._display.width=e,this._display.height=i):M(e)&&s?i=e/s:M(i)&&s?e=i*s:(e=t.width,i=t.height),M(e)&&(this._display.width=e),M(i)&&(this._display.height=i),this.markDirtyBounds(),this.markDirty()}}};oe.className="Picture";oe.classNames=Ye.classNames.concat([oe.className]);var ne=class extends Ge{_afterNew(){this._addOrientationClass(),super._afterNew(),this.endGrip.setPrivate("visible",!1),this.thumb.setPrivate("visible",!1)}updateGrips(){super.updateGrips();let t=this.startGrip;this.endGrip.setAll({x:t.x(),y:t.y()}),this.setRaw("end",this.get("start"))}};ne.className="Slider";ne.classNames=Ge.classNames.concat([ne.className]);var he=class extends C{constructor(){super(...arguments),this.homeButton=this.children.push(Lt.new(this._root,{width:35,height:35,themeTags:["home"]})),this.plusButton=this.children.push(Lt.new(this._root,{width:35,height:35,themeTags:["plus"]})),this.minusButton=this.children.push(Lt.new(this._root,{width:35,height:35,themeTags:["minus"]}))}_afterNew(){super._afterNew(),this.set("position","absolute"),this.set("layout",this._root.verticalLayout),this.addTag("zoomtools"),this.plusButton.setAll({icon:B.new(this._root,{themeTags:["icon"]}),layout:void 0}),this.minusButton.setAll({icon:B.new(this._root,{themeTags:["icon"]}),layout:void 0}),this.homeButton.setAll({icon:B.new(this._root,{themeTags:["icon"]}),layout:void 0})}_prepareChildren(){if(super._prepareChildren(),this.isDirty("target")){let t=this.get("target"),e=this._prevSettings.target;t&&(t instanceof Ft&&(this._targetDisposer=this.addDisposer(t.contents.on("scale",i=>{i==t.get("minZoomLevel")?this.minusButton.set("disabled",!0):this.minusButton.set("disabled",!1),i==t.get("maxZoomLevel")?this.plusButton.set("disabled",!0):this.plusButton.set("disabled",!1)})),this.root.events.once("frameended",()=>{t.get("scale")==t.get("minZoomLevel")&&this.minusButton.set("disabled",!0)})),this._disposer=new lt([this.plusButton.events.on("click",()=>{t.zoomIn()}),this.minusButton.events.on("click",()=>{t.zoomOut()}),this.homeButton.events.on("click",()=>{t.goHome()})])),e&&(this._disposer&&this._disposer.dispose(),this._targetDisposer&&this._targetDisposer.dispose())}}};he.className="ZoomTools";he.classNames=C.classNames.concat([he.className]);var le=class extends V{constructor(){super(...arguments),this.canvas=document.createElement("canvas"),this.context=this.canvas.getContext("2d"),this._clearGrain=!1}_beforeChanged(){this.canvas.width=this.get("width",200),this.canvas.height=this.get("height",200),(this.isDirty("size")||this.isDirty("density")||this.isDirty("minOpacity")||this.isDirty("maxOpacity")||this.isDirty("colors")||this.isDirty("horizontalGap")||this.isDirty("verticalGap"))&&(this._clearGrain=!0),super._beforeChanged()}_changed(){if(super._changed(),this._clearGrain){let t=this.get("width",200),e=this.get("height",200),i=this.context.getImageData(0,0,t,e),s=Math.max(1,this.get("size",1)),r=this.get("minOpacity",0),a=this.get("maxOpacity",.3),o=this.get("colors",[this.get("color",L.fromHex(0))]),n=t/s,d=e/s,m=this.get("density",1),l=this.get("horizontalGap",0)+1,c=this.get("verticalGap",0)+1;for(let h=0;h<d;h++)if(!(c>0&&h/c!=Math.round(h/c)))for(let p=0;p<n;p++){let _=o[Math.floor(Math.random()*o.length)],u=(r+Math.random()*(a-r))*255,f=Math.random();l>0&&p/l!=Math.round(p/l)||f<m&&this._setRectData(p,h,s,t,i.data,_.r,_.g,_.b,u)}this.context.putImageData(i,0,0),this._pattern=this.context.createPattern(this.canvas,"repeat")}this._clearGrain=!1}_checkDirtyFill(){return!1}_setRectData(t,e,i,s,r,a,o,n,d){for(var m=t*i;m<t*i+i;m++)for(var l=e*i;l<e*i+i;l++){var c=(l*s+m)*4;r[c]=a,r[c+1]=o,r[c+2]=n,r[c+3]=d}}};le.className="GrainPattern";le.classNames=V.classNames.concat([le.className]);var ce=class extends it{getFill(t){let e=this.getBounds(t),i=0,s=0,r=e.left||0,a=e.right||0,o=e.top||0,n=e.bottom||0,d=a-r,m=n-o,l=t.get("radius");M(l)?(i=0,s=0):(l=Math.min(d,m)/2,i=d/2,s=m/2);let c=this.get("x"),h=this.get("y");c!=null&&(i=Bt(c,d)),h!=null&&(s=Bt(h,m));let p=this._root._renderer.createRadialGradient(i,s,0,i,s,l),_=this.get("stops");if(_){let u=0;v(_,f=>{let b=f.offset;M(b)||(b=u/(_.length-1));let x=f.opacity;M(x)||(x=1);let y=f.color;if(y){let w=f.lighten;w&&(y=L.lighten(y,w));let T=f.brighten;T&&(y=L.brighten(y,T)),p.addColorStop(b,"rgba("+y.r+","+y.g+","+y.b+","+x+")")}u++})}return p}};ce.className="RadialGradient";ce.classNames=it.classNames.concat([ce.className]);var Ot=class extends V{_beforeChanged(){super._beforeChanged(),this.isDirty("gap")&&(this._clear=!0)}_draw(){super._draw();let t=this.get("checkered",!1),e=this.get("centered",!0),i=this.get("gap",0),s=this.get("rotation",0),r=this.get("width",100),a=this.get("height",100),o=this.get("radius",3),n=o*2+i,d=o*2+i,m=Math.round(r/n),l=Math.round(a/d);n=r/m,d=a/l,s!=0&&(this._display.x=n*bt(s),this._display.y=d*xt(s));let c=this.get("color"),h=this.get("colorOpacity");(c||h)&&this._display.beginFill(c,h);for(let p=s==0?0:-l*2;p<l*2;p++)for(let _=s==0?0:-m*2;_<m*2;_++)if(!t||(p&1)!=1&&(_&1)!=1||(p&1)==1&&(_&1)==1){let u=_*n,f=p*d;e&&(u+=n+i/2,f+=d+i/2),this._display.drawCircle(u-o,f-o,o)}t?(r=r/2-i*2,a=a/2-i*2):(r-=i,a-=i),(c||h)&&this._display.endFill()}};Ot.className="CirclePattern";Ot.classNames=V.classNames.concat([Ot.className]);var Ht=class extends V{_beforeChanged(){super._beforeChanged(),this.isDirty("gap")&&(this._clear=!0)}_draw(){super._draw();let t=this.get("width",100),e=this.get("height",100),i=this.get("gap",0),s=this.get("strokeWidth",1);if(!i)this._display.moveTo(0,0),this._display.lineTo(t,0);else{let o=i+s,n=e/o,d=this.get("angle",0)*Math.PI/180;if(d===0)for(let m=-n;m<n*2;m++){let l=Math.round(m*o-o/2)+.5;this._display.moveTo(-t,l),this._display.lineTo(t*2,l)}else{let m=Math.cos(d),l=Math.sin(d),c=Math.sqrt(t*t+e*e)*2,h=o/Math.max(Math.abs(m),Math.abs(l)),p=Math.ceil(c/h)*2;for(let _=-p;_<p;_++){let u=_*o,f=u*l-c*m,b=u*m+c*l,x=u*l+c*m,y=u*m-c*l;this._display.moveTo(f,b),this._display.lineTo(x,y)}}}this._display.lineStyle(s,this.get("color"),this.get("colorOpacity"));let r=this.get("strokeDasharray");M(r)&&(r<.5?r=[0]:r=[r]),this._display.setLineDash(r);let a=this.get("strokeDashoffset");a&&this._display.setLineDashOffset(a),this._display.endStroke()}};Ht.className="LinePattern";Ht.classNames=V.classNames.concat([Ht.className]);var Yt=class extends V{_beforeChanged(){super._beforeChanged(),this.isDirty("gap")&&(this._clear=!0)}_draw(){super._draw();let t=this.get("checkered",!1),e=this.get("centered",!0),i=this.get("gap",0),s=this.get("rotation",0),r=this.get("width",100),a=this.get("height",100),o=this.get("maxWidth",5),n=this.get("maxHeight",5),d=this._display,m=o+i,l=n+i,c=Math.round(r/m),h=Math.round(a/l);m=r/c,l=a/h,s!=0&&(d.x=m/2*bt(s),d.y=-l/2*xt(s));for(let u=s==0?0:-h*2;u<h*2;u++)for(let f=s==0?0:-c*2;f<c*2;f++)if(!t||(u&1)!=1&&(f&1)!=1||(u&1)==1&&(f&1)==1){let b=f*m,x=u*l;e&&(b+=(m-o)/2,x+=(l-n)/2),d.drawRect(b,x,o,n)}t?(r=r/2-i*2,a=a/2-i*2):(r-=i,a-=i);let p=this.get("color"),_=this.get("colorOpacity");(p||_)&&(d.beginFill(p,_),d.endFill())}};Yt.className="RectanglePattern";Yt.classNames=V.classNames.concat([Yt.className]);var de=class extends V{_beforeChanged(){super._beforeChanged(),this.isDirty("svgPath")&&(this._clear=!0)}_draw(){super._draw();let t=this.get("svgPath");t!=null&&this._display.svgPath(t);let e=this.get("color"),i=this.get("colorOpacity");(e||i)&&(this._display.beginFill(e,i),this._display.endFill())}};de.className="PathPattern";de.classNames=V.classNames.concat([de.className]);var ue=class extends P{_afterNew(){if(super._afterNewApplyThemes(),this.get("patterns",[]).length===0){let t=this.get("color",this.root.interfaceColors.get("stroke"));this.set("patterns",[this.getLinePattern({width:1e3,height:1e3,rotation:45,strokeWidth:1,color:t}),this.getRectanglePattern({width:10,height:10,rotation:0,maxWidth:4,maxHeight:4,color:t}),this.getLinePattern({width:1e3,height:1e3,rotation:-45,strokeWidth:1,gap:6,color:t}),this.getCirclePattern({width:11,height:11,radius:2,color:t}),this.getLinePattern({width:6,height:6,rotation:90,strokeWidth:1,color:t}),this.getRectanglePattern({width:14,height:14,rotation:45,gap:4,maxWidth:6,maxHeight:6,checkered:!0,color:t}),this.getLinePattern({width:6,height:6,rotation:0,strokeWidth:1,color:t}),this.getRectanglePattern({width:15,height:15,rotation:0,gap:5,maxWidth:5,maxHeight:5,checkered:!0,color:t}),this.getLinePattern({width:1e3,height:1e3,rotation:45,strokeWidth:2,gap:3,strokeDasharray:[4,2],color:t}),this.getCirclePattern({width:20,height:20,radius:3,gap:4,checkered:!0,color:t}),this.getLinePattern({width:1e3,height:1e3,rotation:-45,strokeWidth:2,gap:3,strokeDasharray:[4,2],color:t}),this.getRectanglePattern({width:10,height:10,rotation:0,gap:1,maxWidth:9,maxHeight:9,color:t}),this.getLinePattern({width:1e3,height:1e3,rotation:-45,strokeWidth:2,gap:1,color:t}),this.getLinePattern({width:1e3,height:1e3,rotation:45,strokeWidth:2,gap:1,color:t}),this.getLinePattern({width:1e3,height:1e3,rotation:0,strokeWidth:3,gap:1,color:t}),this.getLinePattern({width:1e3,height:1e3,rotation:90,strokeWidth:3,gap:1,color:t})])}this._dirty.patterns=!1}_beforeChanged(){this.isDirty("patterns")&&this.reset()}getIndex(t){let e=this.get("patterns",[]);if(t<e.length&&e[t]!==null)return e[t];if(t>e.length-1){let i=t-Math.floor(t*(t/e.length));return e[i]}return e[t]}next(){let t=this.getPrivate("currentStep",this.get("startIndex",0));return this.setPrivate("currentStep",t+this.get("step",1)),this.getIndex(t)}reset(){this.setPrivate("currentStep",this.get("startIndex",0))}getLinePattern(t){return Ht.new(this.root,t)}getRectanglePattern(t){return Yt.new(this.root,t)}getCirclePattern(t){return Ot.new(this.root,t)}};ue.className="PatternSet";ue.classNames=P.classNames.concat([ue.className]);var Gi=class{static parse(t,e){e=this._applyDefaults(e);try{if(mt(t)){let i=JSON.parse(t);return e.reverse&&_e(i)&&i.reverse(),i}else{if(_e(t)||Dt(t))return t;throw"Unable to parse JSON data"}}catch{return}}static _applyDefaults(t){let e={},i={reverse:!1};return t||(t={}),W(i,(s,r)=>{e[s]=t[s]||r}),e}},Wi=class{static parse(t,e){e=this._applyDefaults(e);let i=this.CSVToArray(t,e.delimiter),s=[],r=[],a,o;for(o=0;o<e.skipRows;o++)i.shift();if(e.useColumnNames){r=i.shift();for(let d=0;d<r.length;d++)a=r[d]!=null?r[d].replace(/^\s+|\s+$/gm,""):"",a===""&&(a="col"+d),r[d]=a}let n;for(;n=e.reverse?i.pop():i.shift(),!!n;){if(e.skipEmpty&&n.length===1&&n[0]==="")continue;let d={};for(o=0;o<n.length;o++)a=r[o]===void 0?"col"+o:r[o],d[a]=n[o];s.push(d)}return s}static CSVToArray(t,e){e=e||",";let i=new RegExp("(\\"+e+'|\\r?\\n|\\r|^)(?:"([^"]*(?:""[^"]*)*)"|([^"\\'+e+"\\r\\n]*))","gi"),s=[[]],r=null;for(;r=i.exec(t),!!r;){let a=r[1];a.length&&a!==e&&s.push([]);let o;r[2]?o=r[2].replace(new RegExp('""',"g"),'"'):o=r[3],s[s.length-1].push(o)}return s}static _applyDefaults(t){let e={},i={delimiter:",",reverse:!1,skipRows:0,skipEmpty:!0,useColumnNames:!1};return t||(t={}),W(i,(s,r)=>{e[s]=t[s]||r}),e}};var Vi=class extends P{constructor(){super(...arguments),this._checkDates=!1,this._checkNumbers=!1,this._checkColors=!1,this._checkEmpty=!1,this._checkDeep=!1}_afterNew(){super._afterNew(),this._checkFeatures(),this.on("dateFields",()=>this._checkFeatures()),this.on("dateFormat",()=>this._checkFeatures()),this.on("numericFields",()=>this._checkFeatures()),this.on("colorFields",()=>this._checkFeatures()),this.on("emptyAs",()=>this._checkFeatures())}_checkFeatures(){(this.isDirty("dateFields")||this.isDirty("dateFormat"))&&(this._checkDates=this.get("dateFields")&&this.get("dateFields").length>0),this.isDirty("numericFields")&&(this._checkNumbers=this.get("numericFields")&&this.get("numericFields").length>0),this.isDirty("colorFields")&&(this._checkColors=this.get("colorFields")&&this.get("colorFields").length>0),this.isDirty("emptyAs")&&(this._checkEmpty=this.get("emptyAs")!=null),this._checkDeepFeatures()}_checkDeepFeatures(){let t=[];v(["dateFields","numericFields","colorFields"],e=>{v(this.get(e,[]),i=>{let s=i.split(".");for(s.pop();s.length>0;)t.push(s.join(".")),s.pop()})}),this._checkDeep=t.length>0,this.setPrivate("deepFields",t)}processMany(t){_e(t)&&(this._checkDates||this._checkNumbers||this._checkColors||this._checkEmpty)&&v(t,e=>{this.processRow(e)})}processRow(t,e=""){W(t,(i,s)=>{let r=e+i;this._checkEmpty&&(t[i]=this._maybeToEmpty(t[i])),this._checkNumbers&&(t[i]=this._maybeToNumber(r,t[i])),this._checkDates&&(t[i]=this._maybeToDate(r,t[i])),this._checkColors&&(t[i]=this._maybeToColor(r,t[i])),this._checkDeep&&this.getPrivate("deepFields",[]).indexOf(r)!==-1&&Dt(t[i])&&this.processRow(t[i],r+".")})}_maybeToNumber(t,e){return this.get("numericFields").indexOf(t)!==-1?X(e):e}_maybeToDate(t,e){return this.get("dateFields").indexOf(t)!==-1?this._root.dateFormatter.parse(e,this.get("dateFormat","")).getTime():e}_maybeToEmpty(t){return(t==null||t=="")&&this.get("emptyAs")!=null?this.get("emptyAs"):t}_maybeToColor(t,e){return this.get("colorFields").indexOf(t)!==-1?L.fromAny(e):e}};var fe=class extends C{constructor(){super(...arguments),this.rectangle=this.children.push(wt.new(this._root,{themeTags:["rectangle"],fillOpacity:0,fill:K(16777215)})),this.gripL=this._createGrip("left"),this.gripR=this._createGrip("right"),this.gripT=this._createGrip("top"),this.gripB=this._createGrip("bottom"),this._is=1,this._ix=0,this._iw=0,this._isHover=!1}_afterNew(){super._afterNew(),this.addTag("resizer"),this.set("visible",!1),this.gripL.events.on("dragged",t=>{this._resize(t.target,-1)}),this.gripR.events.on("dragged",t=>{this._resize(t.target,1)}),this.gripL.events.on("dragstart",t=>{this._resizeStart(t.target)}),this.gripR.events.on("dragstart",t=>{this._resizeStart(t.target)}),this.gripT.events.on("dragged",t=>{this._rotate(t,90)}),this.gripB.events.on("dragged",t=>{this._rotate(t,-90)}),this.gripT.events.on("dragstart",t=>{this._resizeStart(t.target)}),this.gripB.events.on("dragstart",t=>{this._resizeStart(t.target)})}_resizeStart(t){let e=this.get("sprite");e&&(this._is=e.get("scale",1),this._ix=t.x(),this._iw=this.width()/2)}_resize(t,e){let i=this.get("sprite"),s=this.get("spriteTemplate");if(i){let r=Math.max(.01,this._is*(1+e*(t.x()-this._ix)/this._iw));s?s.set("scale",r):i.set("scale",r),i.states.lookup("default").set("scale",r),this._updatePositions()}}_rotate(t,e){let i=this.get("sprite"),s=this.get("spriteTemplate");if(i){let r=this.parent;if(r){let a=this.get("rotationStep",10),o=Math.round((Se({x:this.x(),y:this.y()},r.toLocal(t.point))+e)/a)*a;s?s.set("rotation",o):i.set("rotation",o),i.states.lookup("default").set("rotation",o),this._updatePositions()}}}_createGrip(t){let e=this.children.push(C.new(this._root,{themeTags:["grip",t],setStateOnChildren:!0,draggable:!0}));return e.children.push(kt.new(this._root,{themeTags:["outline"],centerX:St,centerY:St})),e.children.push(kt.new(this._root,{centerX:St,centerY:St})),e}_updateChildren(){if(super._updateChildren(),this.isDirty("sprite")){let t=this.get("sprite");if(t){this.show(0),this.setPrivate("visible",!0),this._updatePositions();let e=t.parent;e&&e.children.moveValue(this,0),this._positionDP=t.events.on("positionchanged",()=>{this._updatePositions()}),this._positionDP=t.events.on("boundschanged",()=>{this._updatePositions()})}else this.hide(0),this.setPrivate("visible",!1),this._positionDP&&this._positionDP.dispose()}(this.isDirty("width")||this.isDirty("height")||this.isDirty("rotation"))&&this._updatePositions()}_updatePositions(){let t=this.get("sprite");if(t){let e=t.localBounds(),i=t.get("scale",1),s=20,r=(e.right-e.left)*i+s,a=(e.bottom-e.top)*i+s,o=t.get("rotation",0),n=this.rectangle,d=t.get("centerX",St),m=t.get("centerY",St),l=0;d instanceof q&&(l=d.value);let c=0;m instanceof q&&(c=m.value),n.setAll({centerX:d,centerY:m,width:r,height:a}),this.setAll({x:t.x()+s*(l-.5)*bt(o)-s*(c-.5)*xt(o),y:t.y()+s*(c-.5)*bt(o)+s*(l-.5)*xt(o),width:r,height:a,rotation:o}),this.gripT.setAll({x:(.5-l)*r,y:-c*a}),this.gripB.setAll({x:(.5-l)*r,y:(1-c)*a}),this.gripL.setAll({x:-l*r,y:(.5-c)*a}),this.gripR.setAll({x:(1-l)*r,y:(.5-c)*a}),this.rectangle.setAll({width:r,height:a})}}};fe.className="SpriteResizer";fe.classNames=C.classNames.concat([fe.className]);var pe=class extends C{constructor(){super(...arguments),this.label=this.children.push(pi.new(this._root,{})),this.buttonsContainer=this.children.push(C.new(this._root,{themeTags:["buttons"]})),this.upButton=this.buttonsContainer.children.push(st.new(this._root,{themeTags:["upbutton"]})),this.downButton=this.buttonsContainer.children.push(st.new(this._root,{themeTags:["downbutton"]}))}_afterNew(){this.addTag("numericstepper"),this.set("layout",this._root.horizontalLayout),this.label.adapters.add("text",t=>(t&&t.replace(/\D/g,""),t===""&&(t="0"),t)),this.set("background",wt.new(this._root,{fillOpacity:0,fill:K(16777215)})),this.buttonsContainer.states.create("hidden",{opacity:0,visible:!0}),this.events.on("pointerover",()=>{this.buttonsContainer.set("active",!0)}),this.events.on("pointerout",()=>{this.buttonsContainer.set("active",!1)}),this.label.on("text",t=>{if(t){let e=parseFloat(t);isNaN(e)||this.set("value",e)}}),this.upButton.events.on("click",()=>{this.set("value",this.get("value",0)+1)}),this.downButton.events.on("click",()=>{this.set("value",Math.max(0,this.get("value",0)-1))}),super._afterNew()}_updateChildren(){super._updateChildren();let t=this.get("value",0),e=this.label;if(this.isDirty("value")&&e.set("text",t.toString()),this.isDirty("disabled")){let i=this.get("disabled",!1);this.set("interactive",!i),this.upButton.set("interactive",!i),this.downButton.set("interactive",!i),i?(this.label.set("editOn","none"),this.buttonsContainer.hide(0)):(this.label.set("editOn","click"),this.buttonsContainer.show(0))}}};pe.className="NumericStepper";pe.classNames=C.classNames.concat([pe.className]);var me=class extends C{constructor(){super(...arguments),this.circle=this.children.push(zt.new(this._root,{themeTags:["background"]})),this.label=this.children.push(rt.new(this._root,{})),this.slice=this.children.push(We.new(this._root,{isMeasured:!1})),this.backgroundSlice=this.children.push(We.new(this._root,{themeTags:["background"]}))}_afterNew(){this.addTag("progresspie"),super._afterNew()}_updateChildren(){if(super._updateChildren(),this.isDirty("width")||this.isDirty("height")||this.isDirty("radius")||this.isDirty("innerRadius")){let t=this.innerWidth(),e=this.innerHeight(),i=Bt(this.get("radius",N),Math.min(t,e)/2),s=Bt(this.get("innerRadius",pt(80)),i);this.slice.setAll({radius:i,innerRadius:s}),this.backgroundSlice.setAll({radius:i,innerRadius:s}),this.circle.set("radius",i)}if(this.isDirty("value")){let t=this.get("value",0);this.slice.set("arc",t*360),this.backgroundSlice.set("arc",360),this.label.setAll({text:this.getNumberFormatter().format(t*100,this.get("numberFormat","#'"))}),this.root.events.once("frameended",()=>{this.label.markDirtyKey("text")})}}};me.className="ProgressPie";me.classNames=C.classNames.concat([me.className]);var Es={};Ps(Es,{load:()=>Ws,readBlob:()=>Ms});function Ws(g,t,e){return new Promise((i,s)=>{let r=e!=null&&e.responseType=="blob",a=new XMLHttpRequest;if(a.onload=()=>{if(a.status===200){let o,n;if(r){n=a.response,Ms(n).then(m=>{let l={xhr:a,error:!1,response:m,blob:n,type:a.getResponseHeader("Content-Type"),target:t};i(l)});return}else o=a.responseText||a.response;let d={xhr:a,error:!1,response:o,blob:n,type:a.getResponseHeader("Content-Type"),target:t};i(d)}else s({xhr:a,error:!0,type:a.getResponseHeader("Content-Type"),target:t})},a.onerror=()=>{s({xhr:a,error:!0,type:a.getResponseHeader("Content-Type"),target:t})},a.open("GET",g,!0),e&&e.withCredentials&&(a.withCredentials=!0),e!=null){if(e.requestHeaders!=null)for(let o=0;o<e.requestHeaders.length;o++){let n=e.requestHeaders[o];a.setRequestHeader(n.key,n.value)}e.responseType!=null&&(a.responseType=e.responseType)}a.send()})}function Ms(g){return new Promise((t,e)=>{let i=new FileReader;i.onload=s=>{t(i.result)},i.onerror=s=>{e(s)},i.readAsText(g)})}export{At as a,dt as b,at as c,De as d,Me as e,Ee as f,$e as g,ze as h,Je as i,Ii as j,Kt as k,Jt as l,Qt as m,zt as n,te as o,ee as p,ie as q,Ft as r,it as s,Rt as t,se as u,re as v,st as w,ut as x,ae as y,oe as z,ne as A,he as B,le as C,ce as D,Ot as E,Ht as F,Yt as G,de as H,ue as I,Gi as J,Wi as K,Vi as L,fe as M,pe as N,me as O,Es as P};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
-
import{A as Aa,B as Fa,C as Ga,D as Ha,E as Ia,F as Ja,G as Ka,H as La,I as Ma,J as Oa,K as Pa,L as Qa,M as Ra,N as Sa,O as Ta,P as Ua,a as N,b as P,c as Q,d as R,e as S,f as T,g as U,h as W,i as X,j as Y,k as Z,l as _,m as ba,n as ca,o as da,p as ea,q as fa,r as ka,s as la,t as ma,u as na,v as ra,w as ta,x as ua,y as va,z as wa}from"./
|
|
2
|
+
import{A as Aa,B as Fa,C as Ga,D as Ha,E as Ia,F as Ja,G as Ka,H as La,I as Ma,J as Oa,K as Pa,L as Qa,M as Ra,N as Sa,O as Ta,P as Ua,a as N,b as P,c as Q,d as R,e as S,f as T,g as U,h as W,i as X,j as Y,k as Z,l as _,m as ba,n as ca,o as da,p as ea,q as fa,r as ka,s as la,t as ma,u as na,v as ra,w as ta,x as ua,y as va,z as wa}from"./QEDQOBD7.js";import{a as $,b as aa,c as oa,d as za}from"./WG4E5DBM.js";import{a as Ba}from"./5C33IP7B.js";import{A as B,B as C,C as D,E,F,G,H,I,J,K,M as L,N as M,O,R as ga,S as ha,T as ia,U as ja,c as r,ca as pa,da as qa,ea as sa,fa as xa,ga as ya,ma as Ca,na as Da,oa as Ea,pa as Na,q as s,t,u,v,w,x,y,z as A}from"./IPIYZVAJ.js";import{P as o,Q as p,R as q,b as n}from"./JWJHIBYW.js";import{a,b,c,d,e}from"./GPGC63RW.js";import{D as g,K as h,M as i,N as j,O as k,P as l,Q as m,V as z,W as V,l as f}from"./PILEMW25.js";import"./3TTFCHAA.js";export{j as ArrayDisposer,D as BlendMode,_ as Bullet,aa as Button,Pa as CSVParser,X as CanvasLayer,W as CanvasRenderer,Ca as Chart,ca as Circle,Ia as CirclePattern,q as Color,Na as ColorSet,ja as Component,ba as ConfirmButton,L as Container,m as CounterDisposer,ia as DataItem,Qa as DataProcessor,T as DateFormatter,i as Disposer,U as DurationFormatter,oa as EditableLabel,ea as Ellipse,y as Entity,la as Gradient,Ga as GrainPattern,E as Graphics,J as GridLayout,na as HeatLegend,H as HorizontalLayout,N as InterfaceColors,Oa as JSONParser,ha as JsonData,O as Label,G as Layout,ra as Legend,sa as Line,Ja as LinePattern,ma as LinearGradient,va as Link,ga as ListData,r as ListTemplate,Z as Modal,k as MultiDisposer,l as MutableValueDisposer,R as NumberFormatter,Sa as NumericStepper,ua as OrthogonalLine,La as PathPattern,B as Pattern,Ma as PatternSet,a as Percent,wa as Picture,C as PicturePattern,P as PointedRectangle,da as Polygon,Ta as ProgressPie,Ha as RadialGradient,ya as RadialLabel,xa as RadialText,F as Rectangle,Ka as RectanglePattern,Y as Root,$ as RoundedRectangle,za as Scrollbar,Da as SerialChart,qa as Series,Ba as Slice,Aa as Slider,A as Sprite,Ra as SpriteResizer,fa as Star,z as Template,M as Text,K as TextFormatter,V as Theme,Ea as Tick,S as Timezone,Q as Tooltip,ta as Triangle,I as VerticalLayout,Fa as ZoomTools,ka as ZoomableContainer,v as addLicense,g as array,p as color,w as disposeAllRootElements,t as ease,x as getRootById,s as math,Ua as net,h as object,c as p0,d as p100,e as p50,b as percent,n as ready,u as registry,pa as time,f as type,o as utils};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
+
import{E as L,F as R,M as y,O as k,h as x}from"./IPIYZVAJ.js";import{N as b,Q as V,d as $,f as C,o as G,q as D,u as w}from"./JWJHIBYW.js";import{a as B}from"./GPGC63RW.js";import{O as E,g as m,o as M}from"./PILEMW25.js";var c=class extends R{_beforeChanged(){super._beforeChanged(),(this.isDirty("cornerRadiusTL")||this.isDirty("cornerRadiusTR")||this.isDirty("cornerRadiusBR")||this.isDirty("cornerRadiusBL"))&&(this._clear=!0)}_draw(){let e=this.width(),t=this.height(),s=e/Math.abs(e),r=t/Math.abs(t),i=0,a=0,l=this.get("strokeWidth",0);this.get("containStroke",!1)&&(e-=s*l,t-=r*l,i+=s*l/2,a+=r*l/2);let n=e,h=t;if(m(n)&&m(h)){let o=Math.min(n,h)/2,u=w(this.get("cornerRadiusTL",8),o),d=w(this.get("cornerRadiusTR",8),o),g=w(this.get("cornerRadiusBR",8),o),f=w(this.get("cornerRadiusBL",8),o),_=Math.min(Math.abs(n/2),Math.abs(h/2));u=x(u,0,_),d=x(d,0,_),g=x(g,0,_),f=x(f,0,_);let p=this._display;p.moveTo(i+u*s,a),p.lineTo(i+n-d*s,a),d>0&&p.arcTo(i+n,a,i+n,a+d*r,d),p.lineTo(i+n,a+h-g*r),g>0&&p.arcTo(i+n,a+h,i+n-g*s,a+h,g),p.lineTo(i+f*s,a+h),f>0&&p.arcTo(i,a+h,i,a+h-f*r,f),p.lineTo(i,a+u*r),u>0&&p.arcTo(i,a,i+u*s,a,u),p.closePath()}}};c.className="RoundedRectangle";c.classNames=R.classNames.concat([c.className]);var v=class extends y{_afterNew(){this._settings.themeTags=b(this._settings.themeTags,["button"]),super._afterNew(),this._settings.background||this.set("background",c.new(this._root,{themeTags:b(this._settings.themeTags,["background"])})),this.setPrivate("trustBounds",!0)}_prepareChildren(){if(super._prepareChildren(),this.isDirty("icon")){let e=this._prevSettings.icon,t=this.get("icon");t!==e&&(this._disposeProperty("icon"),e&&e.dispose(),t&&this.children.push(t),this._prevSettings.icon=t)}if(this.isDirty("label")){let e=this._prevSettings.label,t=this.get("label");t!==e&&(this._disposeProperty("label"),e&&e.dispose(),t&&this.children.push(t),this._prevSettings.label=t)}}};v.className="Button";v.classNames=y.classNames.concat([v.className]);var T=class extends k{_afterNew(){super._afterNew();let e=this.children.push(y.new(this._root,{html:'<textarea class="am5-editable-label"></textarea>',isMeasured:!1}));e.hide(),this.setPrivate("input",e);let t=this.get("background");t?t.set("themeTags",["editablelabel","background"]):t=this.set("background",c.new(this._root,{themeTags:["editablelabel","background"]}))}_beforeChanged(){if(super._beforeChanged(),this.isDirty("editOn")){this._editOnEvents&&this._editOnEvents.dispose();let e=this.get("editOn","click");e!="none"&&(this._editOnEvents=new E([this.getPrivate("input").events.on(e,t=>{}),this.events.on(e,t=>{this.set("active",!0)})]))}}_prepareChildren(){super._prepareChildren(),this._maybeInitTextarea()}_updateChildren(){if(super._updateChildren(),this.isDirty("active")){let e=this.get("active",!1);e?this._startEditing():this._stopEditing();let t=this.get("background");t&&t.set("active",e)}this._syncText(),this._syncStyle()}_maybeInitTextarea(){if(!this._isInited()){let e=this.getPrivate("input");if(e&&e.getPrivate("htmlElement")){let s=e.getPrivate("htmlElement").querySelector(".am5-editable-label");s&&(this.setPrivate("textarea",s),s.addEventListener("input",r=>{this.get("multiLine")===!1&&(s.value=s.value.replace(/\n/g," ")),this.set("text",s.value),this._syncStyle()}),s.addEventListener("blur",r=>this.set("active",!1)),C("keyboardevents")&&this._disposers.push($(document,"keydown",r=>{D(r)=="Escape"&&this.set("active",!1)})),this._disposers.push($(document,"keydown",r=>{D(r)=="Enter"&&this.get("multiLine")===!1&&(r.preventDefault(),this.set("active",!1))})),this.events.dispatch("inited",{type:"inited",target:this}))}}}_isInited(){return!!this.getPrivate("textarea")}_startEditing(){if(!this._isInited()){this.events.once("inited",()=>{this._startEditing()});return}this._text.set("opacity",0);let e=this.getPrivate("input"),t=this.getPrivate("textarea");t&&(this.get("text","")==""&&this.set("text"," "),e.show(0),this.setTimeout(()=>{this._syncStyle(),t.focus()},100))}_stopEditing(){if(!this._isInited()){this.events.once("inited",()=>{this._stopEditing()});return}let e=this.getPrivate("input"),t=this.getPrivate("textarea");t&&(this.set("text",t.value),e.hide(0),this._text.set("opacity",1))}_syncStyle(){let e=this.getPrivate("input"),t=this.getPrivate("textarea"),s=e.getPrivate("htmlElement");if(t&&s){let r=window.getComputedStyle(t);M(r,d=>{t.style[d]="initial"}),t.style.color=this.get("fill",V(0)).toCSS(this.get("fillOpacity",1)),t.style.backgroundColor="rgba(0, 0, 0, 0)",t.style.border="none",t.style.outline="none",t.style.padding="0",t.wrap="off",t.style.resize="none",t.style.overflow="hidden";let i=this.get("maxWidth",0)-this.get("paddingLeft",0)-this.get("paddingRight",0);i>0?t.style.maxWidth=i+"px":t.style.minWidth="",t.style.height="auto",t.style.minHeight=t.scrollHeight+"px",this.get("width")&&(t.style.width=this.width()-this.get("paddingLeft",0)-this.get("paddingRight",0)+"px",t.style.minWidth="");let a=this.get("lineHeight");a?a instanceof B?t.style.lineHeight=a.value+"":m(a)&&(t.style.lineHeight=a+""):t.style.lineHeight="1.2";let l=this.get("fontFamily");l||(l=getComputedStyle(s,"font-family").getPropertyValue("font-family")),t.style.fontFamily=l;let n=this.get("fontSize");n?m(n)?n=n+"px":n=n:n=getComputedStyle(s,"font-size").getPropertyValue("font-size"),t.style.fontSize=n;let h=this.get("fontWeight");h?h=h:h=getComputedStyle(s,"font-weight").getPropertyValue("font-weight"),t.style.fontWeight=h;let o=this.get("fontStyle");o?o=o:o=getComputedStyle(s,"font-style").getPropertyValue("font-style"),t.style.fontStyle=o,this.get("oversizedBehavior")=="wrap"?t.style.whiteSpace="pre-wrap":t.style.whiteSpace="nowrap",this._root.events.on("frameended",()=>{t.style.minWidth==""&&(t.style.minWidth=t.scrollWidth+20+"px");let d=this.get("textAlign","start");d=="center"?(t.style.textAlign="center",!s.style.transform.match(/translateX/)&&!this.get("width")&&(s.style.transform+=" translateX(-50%)")):d=="end"?(t.style.textAlign="right",!s.style.transform.match(/translateX/)&&!this.get("width")&&(s.style.transform+=" translateX(-100%)")):t.style.textAlign=d})}}_syncText(){let e=this.getPrivate("textarea"),t=this.get("text","");t==" "&&(t=""),e&&(e.value=t)}};T.className="EditableLabel";T.classNames=k.classNames.concat([T.className]);var N=class extends y{constructor(){super(...arguments),this.thumb=this._makeThumb(),this.startGrip=this._makeButton(),this.endGrip=this._makeButton(),this._thumbBusy=!1,this._startDown=!1,this._endDown=!1,this._thumbDown=!1}_addOrientationClass(){this._settings.themeTags=b(this._settings.themeTags,["scrollbar",this._settings.orientation]),this._settings.background||(this._settings.background=c.new(this._root,{themeTags:b(this._settings.themeTags,["main","background"])}))}_makeButton(){return this.children.push(v.new(this._root,{themeTags:["resize","button",this.get("orientation")],icon:L.new(this._root,{themeTags:["icon"]})}))}_makeThumb(){return this.children.push(c.new(this._root,{themeTags:["thumb",this.get("orientation")]}))}_handleAnimation(e){e&&this._disposers.push(e.events.on("stopped",()=>{this.setPrivateRaw("isBusy",!1),this._thumbBusy=!1}))}_afterNew(){this._addOrientationClass(),super._afterNew();let e=this.startGrip,t=this.endGrip,s=this.thumb,r=this.get("background");r&&this._disposers.push(r.events.on("click",i=>{this.setPrivateRaw("isBusy",!0);let a=this._display.toLocal(i.point),l=this.width(),n=this.height(),h=this.get("orientation"),o;h=="vertical"?o=(a.y-s.height()/2)/n:o=(a.x-s.width()/2)/l;let u,d;h=="vertical"?(u=o*n,d="y"):(u=o*l,d="x");let g=this.get("animationDuration",0);g>0?(this._thumbBusy=!0,this._handleAnimation(this.thumb.animate({key:d,to:u,duration:g,easing:this.get("animationEasing")}))):(this.thumb.set(d,u),this._root.events.once("frameended",()=>{this.setPrivateRaw("isBusy",!1)}))})),this._disposers.push(s.events.on("dblclick",i=>{if(!G(i.originalEvent,this))return;let a=this.get("animationDuration",0),l=this.get("animationEasing");this.animate({key:"start",to:0,duration:a,easing:l}),this.animate({key:"end",to:1,duration:a,easing:l})})),this._disposers.push(e.events.on("pointerdown",()=>{this.setPrivateRaw("isBusy",!0),this._startDown=!0,this._gripDown="start"})),this._disposers.push(t.events.on("pointerdown",()=>{this.setPrivateRaw("isBusy",!0),this._endDown=!0,this._gripDown="end"})),this._disposers.push(s.events.on("pointerdown",()=>{this.setPrivateRaw("isBusy",!0),this._thumbDown=!0,this._gripDown=void 0})),this._disposers.push(e.events.on("globalpointerup",()=>{this._startDown&&(this.setPrivateRaw("isBusy",!1),this._released()),this._startDown=!1})),this._disposers.push(t.events.on("globalpointerup",()=>{this._endDown&&(this.setPrivateRaw("isBusy",!1),this._released()),this._endDown=!1})),this._disposers.push(s.events.on("globalpointerup",()=>{this._thumbDown&&(this.setPrivateRaw("isBusy",!1),this._released()),this._thumbDown=!1})),this._disposers.push(e.on("x",()=>{this._updateThumb()})),this._disposers.push(t.on("x",()=>{this._updateThumb()})),this._disposers.push(e.on("y",()=>{this._updateThumb()})),this._disposers.push(t.on("y",()=>{this._updateThumb()})),this._disposers.push(s.events.on("positionchanged",()=>{this._updateGripsByThumb()})),this.get("orientation")=="vertical"?(e.set("x",0),t.set("x",0),this._disposers.push(s.adapters.add("y",i=>Math.max(Math.min(Number(i),this.height()-s.height()),0))),this._disposers.push(s.adapters.add("x",i=>this.width()/2)),this._disposers.push(e.adapters.add("x",i=>this.width()/2)),this._disposers.push(t.adapters.add("x",i=>this.width()/2)),this._disposers.push(e.adapters.add("y",i=>Math.max(Math.min(Number(i),this.height()),0))),this._disposers.push(t.adapters.add("y",i=>Math.max(Math.min(Number(i),this.height()),0)))):(e.set("y",0),t.set("y",0),this._disposers.push(s.adapters.add("x",i=>Math.max(Math.min(Number(i),this.width()-s.width()),0))),this._disposers.push(s.adapters.add("y",i=>this.height()/2)),this._disposers.push(e.adapters.add("y",i=>this.height()/2)),this._disposers.push(t.adapters.add("y",i=>this.height()/2)),this._disposers.push(e.adapters.add("x",i=>Math.max(Math.min(Number(i),this.width()),0))),this._disposers.push(t.adapters.add("x",i=>Math.max(Math.min(Number(i),this.width()),0))))}_updateChildren(){super._updateChildren(),(this.isDirty("end")||this.isDirty("start")||this._sizeDirty)&&this.updateGrips()}_changed(){if(super._changed(),this.isDirty("start")||this.isDirty("end")){let e="rangechanged";this.events.isEnabled(e)&&this.events.dispatch(e,{type:e,target:this,start:this.get("start",0),end:this.get("end",1),grip:this._gripDown})}}_released(){let e="released";this.events.isEnabled(e)&&this.events.dispatch(e,{type:e,target:this})}updateGrips(){let e=this.startGrip,t=this.endGrip,s=this.get("orientation"),r=this.height(),i=this.width();s=="vertical"?(e.set("y",r*this.get("start",0)),t.set("y",r*this.get("end",1))):(e.set("x",i*this.get("start",0)),t.set("x",i*this.get("end",1)));let a=this.getPrivate("positionTextFunction"),l=Math.round(this.get("start",0)*100),n=Math.round(this.get("end",0)*100),h,o;a?(h=a.call(this,this.get("start",0)),o=a.call(this,this.get("end",0))):(h=l+"%",o=n+"%"),e.set("ariaLabel",this._t("From %1",void 0,h)),e.set("ariaValueNow",""+l),e.set("ariaValueText",l+"%"),e.set("ariaValueMin","0"),e.set("ariaValueMax","100"),t.set("ariaLabel",this._t("To %1",void 0,o)),t.set("ariaValueNow",""+n),t.set("ariaValueText",n+"%"),t.set("ariaValueMin","0"),t.set("ariaValueMax","100")}_updateThumb(){let e=this.thumb,t=this.startGrip,s=this.endGrip,r=this.height(),i=this.width(),a=t.x(),l=s.x(),n=t.y(),h=s.y(),o=0,u=1;this.get("orientation")=="vertical"?m(n)&&m(h)&&(!this._thumbBusy&&!e.isDragging()&&(e.set("height",h-n),e.set("y",n)),o=n/r,u=h/r):m(a)&&m(l)&&(!this._thumbBusy&&!e.isDragging()&&(e.set("width",l-a),e.set("x",a)),o=a/i,u=l/i),this.getPrivate("isBusy")&&(this.get("start")!=o||this.get("end")!=u)&&(this.set("start",o),this.set("end",u));let d=this.getPrivate("positionTextFunction"),g=Math.round(this.get("start",0)*100),f=Math.round(this.get("end",0)*100),_,p;d?(_=d.call(this,this.get("start",0)),p=d.call(this,this.get("end",0))):(_=g+"%",p=f+"%"),e.set("ariaLabel",this._t("From %1 to %2",void 0,_,p)),e.set("ariaValueNow",""+g),e.set("ariaValueText",g+"%")}_updateGripsByThumb(){let e=this.thumb,t=this.startGrip,s=this.endGrip;if(this.get("orientation")=="vertical"){let r=e.height();t.set("y",e.y()),s.set("y",e.y()+r)}else{let r=e.width();t.set("x",e.x()),s.set("x",e.x()+r)}}};N.className="Scrollbar";N.classNames=y.classNames.concat([N.className]);export{c as a,v as b,T as c,N as d};
|