@arcgis/map-components 5.1.0-next.121 → 5.1.0-next.123

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.
Files changed (67) hide show
  1. package/dist/cdn/{ZZORY2UI.js → 2GDVOK6V.js} +1 -1
  2. package/dist/cdn/{A6P7RDWG.js → 4AQ43ENS.js} +1 -1
  3. package/dist/cdn/{BQDL5AKD.js → 6RUN7OSM.js} +1 -1
  4. package/dist/cdn/{JA7RPLTP.js → 6WV5RHUP.js} +2 -2
  5. package/dist/cdn/{QZMJWS2B.js → ADWNNODV.js} +1 -1
  6. package/dist/cdn/CNNVHQTZ.js +4 -0
  7. package/dist/cdn/CRJEQWDO.js +2 -0
  8. package/dist/cdn/HBE3W2BQ.js +2 -0
  9. package/dist/cdn/JOOGE4FT.js +2 -0
  10. package/dist/cdn/{VRLY2I2M.js → MASUN7EL.js} +1 -1
  11. package/dist/cdn/{FMTWGY6C.js → NJHOCKLL.js} +1 -1
  12. package/dist/cdn/{J4TYGEI3.js → RIRETHHL.js} +1 -1
  13. package/dist/cdn/{PO3NMPKS.js → SXWQBHG3.js} +1 -1
  14. package/dist/cdn/{7I7G7KRT.js → W4SQ3QCZ.js} +1 -1
  15. package/dist/cdn/X5UAYUNL.js +2 -0
  16. package/dist/cdn/index.js +1 -1
  17. package/dist/docs/api.json +1 -1
  18. package/dist/docs/docs.json +1 -1
  19. package/dist/docs/web-types.json +1 -1
  20. package/package.json +4 -4
  21. package/dist/cdn/E33LBHQA.js +0 -4
  22. package/dist/cdn/E6IL4F2M.js +0 -2
  23. package/dist/cdn/GCFIJLPC.js +0 -2
  24. package/dist/cdn/JUIA2RF6.js +0 -2
  25. package/dist/cdn/RZHHKFQG.js +0 -2
  26. /package/dist/cdn/{GJ5TOPT3.js → 2CZRXPMB.js} +0 -0
  27. /package/dist/cdn/{DPU3VHST.js → 2RIDZVJS.js} +0 -0
  28. /package/dist/cdn/{SUNN2JJ2.js → 3DVOY4BQ.js} +0 -0
  29. /package/dist/cdn/{NDMFLRTB.js → 3NSVHKCX.js} +0 -0
  30. /package/dist/cdn/{O6LYJEON.js → 3WCEFKJX.js} +0 -0
  31. /package/dist/cdn/{MC2YUGXZ.js → 3X2K6TOS.js} +0 -0
  32. /package/dist/cdn/{KCP3JSEI.js → 5U45EC5U.js} +0 -0
  33. /package/dist/cdn/{OKNXBCUX.js → 6TIWCGNI.js} +0 -0
  34. /package/dist/cdn/{U3TSRIEI.js → ACZBI3TS.js} +0 -0
  35. /package/dist/cdn/{L54L4XXE.js → BALE27RC.js} +0 -0
  36. /package/dist/cdn/{W52ULASU.js → CSLP3Y5Q.js} +0 -0
  37. /package/dist/cdn/{URTOVAT4.js → FVOWGP5P.js} +0 -0
  38. /package/dist/cdn/{772IZDK4.js → HHVQ6PZP.js} +0 -0
  39. /package/dist/cdn/{7LWMV5A2.js → IIQPDHOL.js} +0 -0
  40. /package/dist/cdn/{KDLK5QD5.js → KODINAEM.js} +0 -0
  41. /package/dist/cdn/{KRMRVJFP.js → KOSOMJZF.js} +0 -0
  42. /package/dist/cdn/{7IB6AI2V.js → LCL6A5WY.js} +0 -0
  43. /package/dist/cdn/{VUQCK6IF.js → M3RQA7LC.js} +0 -0
  44. /package/dist/cdn/{GNOAUTDK.js → NFC5RKO7.js} +0 -0
  45. /package/dist/cdn/{NRMPFAXY.js → NY56F774.js} +0 -0
  46. /package/dist/cdn/{IL63OQEZ.js → OKZBZTFG.js} +0 -0
  47. /package/dist/cdn/{XUZ43MBE.js → PFWDUC5T.js} +0 -0
  48. /package/dist/cdn/{KOZ67YXN.js → PS4ID2TE.js} +0 -0
  49. /package/dist/cdn/{AVFPVB7U.js → QBLPJW3F.js} +0 -0
  50. /package/dist/cdn/{UHA7OYN5.js → R6G7YQAK.js} +0 -0
  51. /package/dist/cdn/{TKKD4742.js → RT5PKDE3.js} +0 -0
  52. /package/dist/cdn/{H76ZEZDT.js → S372YWXF.js} +0 -0
  53. /package/dist/cdn/{3MSBRZSL.js → S6ARJLXF.js} +0 -0
  54. /package/dist/cdn/{GMSP2RYI.js → ST4PUEOI.js} +0 -0
  55. /package/dist/cdn/{ZRRRSIMH.js → SYVTOG2B.js} +0 -0
  56. /package/dist/cdn/{FV53P5VQ.js → U5WUAQYQ.js} +0 -0
  57. /package/dist/cdn/{F6ZBUVU3.js → UGILYDTR.js} +0 -0
  58. /package/dist/cdn/{NI4PVDRC.js → VOI7MTIP.js} +0 -0
  59. /package/dist/cdn/{QGYTLHWY.js → VZLSY2HC.js} +0 -0
  60. /package/dist/cdn/{KAJYVAAI.js → WDDHDMHF.js} +0 -0
  61. /package/dist/cdn/{HEP3BHHQ.js → XPGK3YXK.js} +0 -0
  62. /package/dist/cdn/{2KBFRAA3.js → XQ5DUVE2.js} +0 -0
  63. /package/dist/cdn/{LSPV526S.js → XVEQWFE4.js} +0 -0
  64. /package/dist/cdn/{CK5XEDZS.js → YDOV4SQ2.js} +0 -0
  65. /package/dist/cdn/{PZSA4K32.js → YGVTAUE6.js} +0 -0
  66. /package/dist/cdn/{7D5T777O.js → YSJ2NU2N.js} +0 -0
  67. /package/dist/cdn/{OWF5OCZY.js → ZHJBZYZ4.js} +0 -0
@@ -1,2 +1,2 @@
1
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};
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,v as y,we as z,be as A,S as B,$e as C,ye as D,a as E,g as F,De as G,K as H,ke as I,l as J,Ae as K,V as L,m as M,c as N,q as O,u as P,G as Q,J as R,E as S,x as T,Q as U,Ne as V,$ as W,U as X};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import"./E33LBHQA.js";import"./VRLY2I2M.js";import"./QZMJWS2B.js";import"./E6IL4F2M.js";import{Q as o}from"./JUIA2RF6.js";import"./GMSP2RYI.js";import"./ZZORY2UI.js";import"./3TTFCHAA.js";var t=["#2888B8","#EB7028","#48A375","#9370B1","#e55035","#3d9ccc","#DC7B04","#b87bb0","#3fa681","#EE6386"],c=t.map(r=>o(r));export{c as esriChartColorSet};
2
+ import"./CNNVHQTZ.js";import"./MASUN7EL.js";import"./ADWNNODV.js";import"./JOOGE4FT.js";import{R as o}from"./HBE3W2BQ.js";import"./ST4PUEOI.js";import"./2GDVOK6V.js";import"./3TTFCHAA.js";var t=["#2888B8","#EB7028","#48A375","#9370B1","#e55035","#3d9ccc","#DC7B04","#b87bb0","#3fa681","#EE6386"],c=t.map(r=>o(r));export{c as esriChartColorSet};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{W as i}from"./ZZORY2UI.js";import"./3TTFCHAA.js";var t=class extends i{setupDefaultRules(){super.setupDefaultRules(),this.rule("Component").setAll({interpolationDuration:600}),this.rule("Hierarchy").set("animationDuration",600),this.rule("Scrollbar").set("animationDuration",600),this.rule("Tooltip").set("animationDuration",300),this.rule("MapChart").set("animationDuration",1e3),this.rule("MapChart").set("wheelDuration",300),this.rule("Entity").setAll({stateAnimationDuration:600}),this.rule("Sprite").states.create("default",{stateAnimationDuration:600}),this.rule("Tooltip",["axis"]).setAll({animationDuration:200}),this.rule("WordCloud").set("animationDuration",500),this.rule("Polygon").set("animationDuration",600),this.rule("ArcDiagram").set("animationDuration",600)}};var n=t;export{n as default};
2
+ import{X as i}from"./2GDVOK6V.js";import"./3TTFCHAA.js";var t=class extends i{setupDefaultRules(){super.setupDefaultRules(),this.rule("Component").setAll({interpolationDuration:600}),this.rule("Hierarchy").set("animationDuration",600),this.rule("Scrollbar").set("animationDuration",600),this.rule("Tooltip").set("animationDuration",300),this.rule("MapChart").set("animationDuration",1e3),this.rule("MapChart").set("wheelDuration",300),this.rule("Entity").setAll({stateAnimationDuration:600}),this.rule("Sprite").states.create("default",{stateAnimationDuration:600}),this.rule("Tooltip",["axis"]).setAll({animationDuration:200}),this.rule("WordCloud").set("animationDuration",500),this.rule("Polygon").set("animationDuration",600),this.rule("ArcDiagram").set("animationDuration",600)}};var n=t;export{n as default};
@@ -1,3 +1,3 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as q}from"./GI5SSBWA.js";import b from"./22EHINJ6.js";import a from"./R3NYK6BO.js";import{e as D,f as O}from"./R2NTRI4S.js";import"./FAECSPBC.js";import{g as H}from"./GMFJ55C3.js";import{N as P,O as U,R as M,U as B,a as E,b as I}from"./FKJWY2PS.js";import"./3TTFCHAA.js";export default $arcgis.t(([{getColorsFromRenderer:re},{substitute:ne},{watch:se},oe,J,{renderingSanitizer:Q},,{e:C,f:j,g:V,h:G,i:K,j:W,l:L,n:F,o:k,p:R}])=>{var le=E`.container{display:flex;flex-flow:row wrap;align-items:center;margin-top:var(--calcite-spacing-xs);width:100%;min-height:150px}.container .pagination-button{display:flex;align-items:center;justify-content:center;border:none;background:transparent;cursor:pointer;padding-block:var(--calcite-spacing-xs);padding-inline:var(--calcite-spacing-xs);color:var(--calcite-color-text-3)}.container .pagination-button:hover,.container .pagination-button:focus{background-color:var(--calcite-color-foreground-3);color:var(--calcite-color-text-1);fill:var(--calcite-color-text-1)}.item-title{margin:0;font-size:var(--calcite-font-size-md);line-height:var(--calcite-font-line-height-relative-snug)}.item-caption{padding-block-start:var(--calcite-spacing-xxs);font-size:var(--calcite-font-size-sm);line-height:var(--calcite-font-line-height-relative-snug)}.item{display:flex;align-items:flex-start;justify-content:center;margin-block:var(--calcite-spacing-xs);width:100%;height:auto}.item-navigation{display:flex;flex:0 1 100%;align-items:flex-start;justify-content:space-between;margin-block-end:var(--calcite-spacing-xs)}.item-text{margin-inline-end:var(--calcite-spacing-xs)}.pagination{display:flex;flex:0 0 auto;align-items:center;overflow:hidden}.pagination:only-child{margin-inline-start:auto}.pagination-text{padding-inline:var(--calcite-spacing-xxs);color:var(--calcite-color-text-3);font-size:var(--calcite-font-size-sm);line-height:var(--calcite-font-line-height-relative-normal)}.item-container{flex:0 1 auto;width:100%}.item-container img{max-width:100%}.item-container img[src$=".SVG"],.item-container img[src$=".svg"]{width:100%}.chart{width:100%;height:155px}`;function z(S){if(!C(S))return null;let[e,t]=S.split("/").slice(1);return{layerId:e,fieldName:t}}var X=15,w="category",A="value",ce="rgba(50, 50, 50, 1)",de=250,he=500,ue=200,N=class extends U{constructor(){super(...arguments),this._direction=O(),this._prefersReducedMotion=D("(prefers-reduced-motion)"),this.activeMediaInfoIndex=0,this.chartAnimationDisabled=!1,this.headingLevel=2}static{this.properties={_refreshIntervalInfo:16,messages:0,values:0,expressionValues:0,activeMediaInfoIndex:9,chartAnimationDisabled:5,activeMediaInfo:32,formattedMediaInfos:32,description:1,fieldInfoMap:0,layer:0,mediaInfos:0,popupTemplate:0,relatedInfos:0,formattedValues:0,heading:1,graphic:0,formattedMediaInfoCount:32,headingLevel:9}}static{this.styles=le}get activeMediaInfo(){return this.formattedMediaInfos[this.activeMediaInfoIndex]||null}get formattedMediaInfos(){return this._formatMediaInfos()||[]}get formattedMediaInfoCount(){return this.formattedMediaInfos.length}next(){this._pageContentElementMedia(1)}previous(){this._pageContentElementMedia(-1)}setActiveMedia(e){this._setContentElementMedia(e)}loaded(){this.manager.onLifecycle(()=>[se(()=>[this.activeMediaInfo,this.activeMediaInfoIndex],()=>this._setupMediaRefreshTimer(),{initial:!0}),{remove:()=>this._clearMediaRefreshTimer()}])}_setContentElementMedia(e){let{formattedMediaInfoCount:t}=this,i=(e+t)%t;this.activeMediaInfoIndex=i}_pageContentElementMedia(e){let{activeMediaInfoIndex:t}=this,i=t+e;this._setContentElementMedia(i)}_formatMediaInfos(){let{mediaInfos:e,layer:t}=this,i=this.values??{},a=this.formattedValues??{},s=this.fieldInfoMap??new Map,r=this.expressionValues??{};return e?.map(o=>{let n=o?.clone();if(!n)return null;if(n.title=R({values:i,fieldInfoMap:s,globalValues:a,layer:t,text:n.title}),n.caption=R({values:i,fieldInfoMap:s,globalValues:a,layer:t,text:n.caption}),n.altText=R({values:i,fieldInfoMap:s,globalValues:a,layer:t,text:n.altText}),n.type==="image"){if(!n.value)return null;let l=n.value;return this._setImageValue({value:l,formattedValues:a,layer:t}),l.sourceURL?n:void 0}if(n.type==="pie-chart"||n.type==="line-chart"||n.type==="column-chart"||n.type==="bar-chart"){if(!n.value)return null;let l=n.value;return this._setChartValue({value:l,chartType:n.type,values:i,expressionValues:r,formattedValues:a,layer:t}),n}return null}).filter(o=>o!=null)??[]}_setImageValue(e){let t=this.fieldInfoMap??new Map,{value:i,formattedValues:a,layer:s}=e,{linkURL:r,sourceURL:o}=i;if(o){let n=k(o,s);i.sourceURL=F({formattedValues:a,template:n,fieldInfoMap:t})}if(r){let n=k(r,s);i.linkURL=F({formattedValues:a,template:n,fieldInfoMap:t})}}_setChartValue(e){let{value:t,values:i,expressionValues:a,formattedValues:s,chartType:r,layer:o}=e,{popupTemplate:n,relatedInfos:l}=this,{fields:p,normalizeField:d}=t,c=o;if(t.fields=G(p,c),d&&(t.normalizeField=V(d,c)),!p.some(u=>!!(s[u]!=null||C(u)&&l?.size)))return;let m=n?.fieldInfos??[];t.series=[],p.forEach((u,g)=>{let h=t.colors?.[g];if(C(u)){t.series=[...t.series,...this._getRelatedChartInfos({fieldInfos:m,fieldName:u,formattedValues:s,expressionValues:a,chartType:r,value:t,color:h})];return}let v=this._getChartOption({value:t,values:i,chartType:r,formattedValues:s,expressionValues:a,fieldName:u,fieldInfos:m,color:h});t.series.push(v)})}_getRelatedChartInfos(e){let{fieldInfos:t,fieldName:i,formattedValues:a,chartType:s,value:r,color:o,expressionValues:n}=e,l=[],p=z(i),d=p&&this.relatedInfos?.get(p.layerId);if(!d)return l;let{relatedFeatures:c,relation:m}=d;if(!m||!c)return l;let{cardinality:u}=m;return c.forEach(g=>{let h=g.attributes;h&&Object.keys(h).forEach(v=>{v===p.fieldName&&l.push(this._getChartOption({value:r,values:h,formattedValues:a,expressionValues:n,fieldName:i,chartType:s,relatedFieldName:v,hasMultipleRelatedFeatures:c?.length>1,fieldInfos:t,color:o}))})}),u&&(u==="one-to-many"||u==="many-to-many")?l:[l[0]]}_getTooltip({label:e,value:t,chartType:i}){return i==="pie-chart"?`${e}`:`${e}: ${t}`}_getChartOption(e){let{value:t,values:i,formattedValues:a,expressionValues:s,fieldName:r,relatedFieldName:o,fieldInfos:n,chartType:l,hasMultipleRelatedFeatures:p,color:d}=e,{layer:c,graphic:m}=this,u=this.fieldInfoMap??new Map,{normalizeField:g,tooltipField:h}=t,v=g?C(g)?i[z(g).fieldName]:i[g]:null,x=K(r)&&s?.[r]!==void 0?s[r]:o&&i[o]!==void 0?i[o]:i[r]!==void 0?i[r]:a[r],_=x===void 0?null:x&&v&&typeof x=="number"&&typeof v=="number"?x/v:x,f=W(n,r),y=V(r,c),b=(h&&a[h]!==void 0?a[h]:L({fieldInfo:f||new oe({fieldName:y}),expressionInfos:this.popupTemplate?.expressionInfos,graphic:m,layer:c}))??"",Z=a[y]??"",Y=_!=null?typeof _=="number"?_:Number(_):null;if(C(r)){let T=u.get(r.toLowerCase()),ee=h?u.get(h.toLowerCase()):null,te=T?.fieldName??r,$=p&&h?z(h).fieldName:ee?.fieldName??h,ie=(p&&$?i[$]:a[$]??(T&&L({fieldInfo:T,layer:c,graphic:m}))??T?.fieldName??o)??"",ae=(p&&o?i[o]:a[te])??"";return new J({fieldName:r,tooltip:this._getTooltip({label:ie,value:ae,chartType:l}),color:d,value:Y})}return new J({fieldName:r,tooltip:this._getTooltip({label:b,value:Z,chartType:l}),color:d,value:Y})}_getRenderer(){let e=this.layer;return this.graphic?.isAggregate&&e?.featureReduction&&"renderer"in e.featureReduction?e.featureReduction.renderer:e?.renderer}async _getSeriesColors(e){let{color:t}=await import("./FMTWGY6C.js"),i=new Map;return e.forEach(a=>{a.color&&i.set(a,t(a.color.toCss(!0)))}),i}async _getRendererColors(){let{color:e}=await import("./FMTWGY6C.js"),t=new Map,i=this._getRenderer(),a="default";if(!i)return t;let s=await re(i);return s.delete(a),Array.from(s.values()).every(r=>r?.length===1)&&Array.from(s.keys()).forEach(r=>{let o=s.get(r)?.[0]?.toCss(!0);o&&t.set(r,e(o))}),t}async _createChart(e){let{activeMediaInfo:t}=this;if(!e||!t)return;let{createRoot:i}=await import("./GCFIJLPC.js").then(m=>m.default.then(e=>({createRoot:e}))),a=await i(e);this._chartRoot=a,this._renderChart({mediaInfo:t,root:a})}_handleMediaKeyup(e){let{key:t}=e;t==="ArrowLeft"&&(e.stopPropagation(),this.previous()),t==="ArrowRight"&&(e.stopPropagation(),this.next())}_canAnimateChart(){return!this.chartAnimationDisabled&&!this._prefersReducedMotion}_getChartAnimationMS(){return this._canAnimateChart()?de:0}_getChartSeriesAnimationMS(){return this._canAnimateChart()?he:0}async _customizeChartTooltip(e,t="horizontal"){let{color:i}=await import("./FMTWGY6C.js");e.setAll({pointerOrientation:t}),e.get("background")?.setAll({stroke:i(ce)}),e.label.setAll({direction:this._direction,oversizedBehavior:"wrap",maxWidth:ue})}async _createPieChart(e,t){let[{Tooltip:i},{PieChart:a,PieSeries:s}]=await Promise.all([import("./FMTWGY6C.js"),import("./RZHHKFQG.js")]),{mediaInfo:r,root:o}=e,{title:n}=r,l=5,p=r?.altText||r?.title||"",d=o.container.children.push(a.new(o,{role:"figure",ariaLabel:p,focusable:!0,paddingBottom:l,paddingTop:l,paddingLeft:l,paddingRight:l})),c=`{category}: {valuePercentTotal.formatNumber('0.00')}%
3
- ({value})`,m=i.new(o,{labelText:c}),u=d.series.push(s.new(o,{name:n,valueField:A,categoryField:w,tooltip:m}));u.ticks.template.set("forceHidden",!0),u.labels.template.set("forceHidden",!0),u.slices.template.states.create("active",{shiftRadius:l}),this._customizeChartTooltip(m),u.slices.template.setAll({ariaLabel:c,focusable:!0,templateField:"columnSettings"}),u.data.setAll(t),u.appear(this._getChartSeriesAnimationMS()),d.appear(this._getChartAnimationMS()),d.root.dom.classList.toggle("chart-rendered",!0)}_getMinSeriesValue(e){let t=0;return e.forEach(i=>t=Math.min(i.value,t)),t}async _createColumnChart(e,t,i){let[{Tooltip:a,Scrollbar:s},{CategoryAxis:r,AxisRendererX:o,AxisRendererY:n,ValueAxis:l,ColumnSeries:p}]=await Promise.all([import("./FMTWGY6C.js"),import("./J4TYGEI3.js")]),{mediaInfo:d,root:c}=t,{value:m,title:u}=d,{_direction:g}=this;e.setAll({wheelX:"panX",wheelY:"zoomX"});let h=e.xAxes.push(r.new(c,{renderer:o.new(c,{inversed:g==="rtl"}),categoryField:w}));h.get("renderer").labels.template.setAll({forceHidden:!0});let v=e.yAxes.push(l.new(c,{renderer:n.new(c,{inside:!1}),min:this._getMinSeriesValue(m.series)}));v.get("renderer").labels.template.setAll({direction:g});let x="{categoryX}",_=a.new(c,{labelText:x}),f=e.series.push(p.new(c,{name:u,xAxis:h,yAxis:v,valueYField:A,categoryXField:w,tooltip:_}));this._customizeChartTooltip(_),f.columns.template.setAll({ariaLabel:x,focusable:!0,templateField:"columnSettings"}),m.series.length>X&&e.set("scrollbarX",s.new(c,{orientation:"horizontal"})),h.data.setAll(i),f.data.setAll(i),f.appear(this._getChartSeriesAnimationMS()),e.appear(this._getChartAnimationMS())}async _createBarChart(e,t,i){let[{Tooltip:a,Scrollbar:s},{CategoryAxis:r,AxisRendererX:o,AxisRendererY:n,ValueAxis:l,ColumnSeries:p}]=await Promise.all([import("./FMTWGY6C.js"),import("./J4TYGEI3.js")]),{mediaInfo:d,root:c}=t,{value:m,title:u}=d,{_direction:g}=this;e.setAll({wheelX:"panY",wheelY:"zoomY"});let h=e.yAxes.push(r.new(c,{renderer:n.new(c,{inversed:!0}),categoryField:w}));h.get("renderer").labels.template.setAll({forceHidden:!0});let v=e.xAxes.push(l.new(c,{renderer:o.new(c,{inside:!1,inversed:g==="rtl"}),min:this._getMinSeriesValue(m.series)}));v.get("renderer").labels.template.setAll({direction:g});let x="{categoryY}",_=a.new(c,{labelText:x}),f=e.series.push(p.new(c,{name:u,xAxis:v,yAxis:h,valueXField:A,categoryYField:w,tooltip:_}));this._customizeChartTooltip(_,"vertical"),f.columns.template.setAll({ariaLabel:x,focusable:!0,templateField:"columnSettings"}),m.series.length>X&&e.set("scrollbarY",s.new(c,{orientation:"vertical"})),h.data.setAll(i),f.data.setAll(i),f.appear(this._getChartSeriesAnimationMS()),e.appear(this._getChartAnimationMS())}async _createLineChart(e,t,i){let[{Tooltip:a,Scrollbar:s},{CategoryAxis:r,AxisRendererX:o,AxisRendererY:n,ValueAxis:l,LineSeries:p}]=await Promise.all([import("./FMTWGY6C.js"),import("./J4TYGEI3.js")]),{root:d,mediaInfo:c}=t,{value:m,title:u}=c,{_direction:g}=this;e.setAll({wheelX:"panX",wheelY:"zoomX"});let h=e.xAxes.push(r.new(d,{renderer:o.new(d,{inversed:g==="rtl"}),categoryField:w}));h.get("renderer").labels.template.setAll({forceHidden:!0});let v=e.yAxes.push(l.new(d,{renderer:n.new(d,{inside:!1}),min:this._getMinSeriesValue(m.series)}));v.get("renderer").labels.template.setAll({direction:g});let x="{categoryX}",_=i[0]?.lineSettings?.stroke,f=a.new(d,{getFillFromSprite:!_,labelText:x});_&&f.get("background")?.setAll({fill:_});let y=e.series.push(p.new(d,{name:u,xAxis:h,yAxis:v,valueYField:A,categoryXField:w,tooltip:f}));y.strokes.template.setAll({templateField:"lineSettings"}),this._customizeChartTooltip(f,"vertical"),m.series.length>X&&e.set("scrollbarX",s.new(d,{orientation:"horizontal"})),h.data.setAll(i),y.data.setAll(i),y.appear(this._getChartSeriesAnimationMS()),e.appear(this._getChartAnimationMS())}async _createXYChart(e,t){let{XYChart:i,XYCursor:a}=await import("./J4TYGEI3.js"),{root:s,mediaInfo:r}=e,{type:o}=r,n=r?.altText||r?.title||"",l=s.container.children.push(i.new(s,{role:"figure",ariaLabel:n,focusable:!0,panX:!0,panY:!0}));l.set("cursor",a.new(s,{})),o==="column-chart"&&await this._createColumnChart(l,e,t),o==="bar-chart"&&await this._createBarChart(l,e,t),o==="line-chart"&&await this._createLineChart(l,e,t),l.root.dom.classList.toggle("chart-rendered",!0)}_clearMediaRefreshTimer(){let{_refreshTimer:e}=this;e&&(clearTimeout(e),this._refreshTimer=void 0)}_updateMediaInfoTimestamp(e){let t=Date.now();this._refreshIntervalInfo={timestamp:t,sourceURL:e&&this._getImageSource(e,t)}}_setupMediaRefreshTimer(){this._clearMediaRefreshTimer();let{activeMediaInfo:e}=this;e?.type==="image"&&e.refreshInterval>0&&this._setRefreshTimeout(e)}_setRefreshTimeout(e){let{refreshInterval:t,value:i}=e,a=t*6e4;this._updateMediaInfoTimestamp(i.sourceURL);let s=window.setInterval(()=>{this._updateMediaInfoTimestamp(i.sourceURL)},a);this._refreshTimer=s}_getImageSource(e,t){let i=e.includes("?")?"&":"?",[a,s=""]=e.split("#");return`${a}${i}timestamp=${t}${s?"#":""}${s}`}_updateChartElement(e){this._chartRoot?.dispose(),this._chartRoot=void 0,e&&this._createChart(e)}render(){return I`<div class="root" @keyup=${this._handleMediaKeyup}><arcgis-feature-element-info .heading=${this.heading} .description=${this.description} .headingLevel=${this.headingLevel}></arcgis-feature-element-info>${this._renderMedia()}</div>`}_renderMedia(){let{formattedMediaInfoCount:e,activeMediaInfoIndex:t}=this,i=this._renderMediaText();return e?I`<div class="container">${this._renderMediaInfo()}<div class="item-navigation">${i}${e>1?I`<div class="pagination">${this._renderMediaPageButton("previous")}<span class="pagination-text">${ne(this.messages?.pageText??"",{index:t+1,total:e})}</span>${this._renderMediaPageButton("next")}</div>`:null}</div></div>`:null}_renderMediaText(){let{activeMediaInfo:e}=this;if(!e)return null;let t=e?.title?I`<div class="item-title" .innerHTML=${Q.sanitize(e.title)??""}></div>`:null,i=e?.caption?I`<div class="item-caption" .innerHTML=${Q.sanitize(e.caption)??""}></div>`:null;return t||i?I`<div class="item-text">${t}${i}</div>`:null}_renderImageMediaInfo(e){if(!e.value)return null;let{_refreshIntervalInfo:t}=this,{value:i,refreshInterval:a,altText:s,title:r}=e,{sourceURL:o,linkURL:n}=i,l=j(n??void 0)?"_blank":"_self",p=l==="_blank"?"noreferrer":"",d=a?t:null,c=d?d.sourceURL:o,m=I`<img alt=${(s||r)??M} src=${c??void 0??M}>`;return(n?I`<a href=${n??M} rel=${p??M} target=${l??M} title=${r??M}>${m}</a>`:null)??m}_renderChartMediaInfo(e){let{activeMediaInfoIndex:t,formattedMediaInfoCount:i}=this;return q(`media-${e.type}-${t}-${i}`,I`<div class="chart" ${P(this._updateChartElement)}></div>`)}_renderMediaInfoType(){let{activeMediaInfo:e}=this;return e?e.type==="image"?this._renderImageMediaInfo(e):e.type.includes("chart")?this._renderChartMediaInfo(e):null:null}_renderMediaInfo(){let{activeMediaInfo:e}=this;return e?I`<div class="item-container"><div class="item">${this._renderMediaInfoType()}</div></div>`:null}_renderMediaPageButton(e){if(this.formattedMediaInfoCount<2)return null;let t=e==="previous",i=t?this.messages?.previous??"":this.messages?.next??"",a=t?"chevron-left":"chevron-right",s=t?this.previous:this.next;return I`<button .ariaLabel=${i} class="pagination-button" @click=${s} tabindex=0 title=${i??M} type=button><calcite-icon flip-rtl class="pagination-icon" .icon=${a} scale=s></calcite-icon></button>`}async _renderChart(e){let{root:t,mediaInfo:i}=e,{value:a,type:s}=i,[{default:r},{default:o},{default:n},{esriChartColorSet:l},{ColorSet:p,Theme:d}]=await Promise.all([import("./BQDL5AKD.js"),import("./PO3NMPKS.js"),import("./7I7G7KRT.js"),import("./A6P7RDWG.js"),import("./FMTWGY6C.js")]),c=d.new(t);c.rule("ColorSet").set("colors",l),c.rule("ColorSet").set("reuse",!0);let m=[n.new(t),c];H(this.el)==="dark"&&m.push(o.new(t)),this._canAnimateChart()&&m.push(r.new(t)),t.setThemes(m);let u=await this._getRendererColors(),g=await this._getSeriesColors(a.series),h=p.new(t,{}),v=g.get(a.series[0]),x=v?{lineSettings:{stroke:v}}:void 0,_=a.series.map((f,y)=>{let b=g.get(f)||u.get(f.fieldName)||h.getIndex(y);return{[w]:f.tooltip,[A]:f.value,columnSettings:{fill:b,stroke:b},...x}}).filter(f=>s==="pie-chart"?f.value!=null&&f.value>0:!0);s==="pie-chart"?this._createPieChart(e,_):this._createXYChart(e,_)}};B("arcgis-feature-media",N);return N},"renderers/support/utils","intl","core/reactiveUtils","popup/FieldInfo","popup/content/support/ChartMediaInfoValueSeries","applications/Components/sanitizerUtils",a,b)
2
+ import{a as q}from"./GI5SSBWA.js";import b from"./22EHINJ6.js";import a from"./R3NYK6BO.js";import{e as D,f as O}from"./R2NTRI4S.js";import"./FAECSPBC.js";import{g as H}from"./GMFJ55C3.js";import{N as P,O as U,R as M,U as B,a as E,b as I}from"./FKJWY2PS.js";import"./3TTFCHAA.js";export default $arcgis.t(([{getColorsFromRenderer:re},{substitute:ne},{watch:se},oe,J,{renderingSanitizer:Q},,{e:C,f:j,g:V,h:G,i:K,j:W,l:L,n:F,o:k,p:R}])=>{var le=E`.container{display:flex;flex-flow:row wrap;align-items:center;margin-top:var(--calcite-spacing-xs);width:100%;min-height:150px}.container .pagination-button{display:flex;align-items:center;justify-content:center;border:none;background:transparent;cursor:pointer;padding-block:var(--calcite-spacing-xs);padding-inline:var(--calcite-spacing-xs);color:var(--calcite-color-text-3)}.container .pagination-button:hover,.container .pagination-button:focus{background-color:var(--calcite-color-foreground-3);color:var(--calcite-color-text-1);fill:var(--calcite-color-text-1)}.item-title{margin:0;font-size:var(--calcite-font-size-md);line-height:var(--calcite-font-line-height-relative-snug)}.item-caption{padding-block-start:var(--calcite-spacing-xxs);font-size:var(--calcite-font-size-sm);line-height:var(--calcite-font-line-height-relative-snug)}.item{display:flex;align-items:flex-start;justify-content:center;margin-block:var(--calcite-spacing-xs);width:100%;height:auto}.item-navigation{display:flex;flex:0 1 100%;align-items:flex-start;justify-content:space-between;margin-block-end:var(--calcite-spacing-xs)}.item-text{margin-inline-end:var(--calcite-spacing-xs)}.pagination{display:flex;flex:0 0 auto;align-items:center;overflow:hidden}.pagination:only-child{margin-inline-start:auto}.pagination-text{padding-inline:var(--calcite-spacing-xxs);color:var(--calcite-color-text-3);font-size:var(--calcite-font-size-sm);line-height:var(--calcite-font-line-height-relative-normal)}.item-container{flex:0 1 auto;width:100%}.item-container img{max-width:100%}.item-container img[src$=".SVG"],.item-container img[src$=".svg"]{width:100%}.chart{width:100%;height:155px}`;function z(S){if(!C(S))return null;let[e,t]=S.split("/").slice(1);return{layerId:e,fieldName:t}}var X=15,w="category",A="value",ce="rgba(50, 50, 50, 1)",de=250,he=500,ue=200,N=class extends U{constructor(){super(...arguments),this._direction=O(),this._prefersReducedMotion=D("(prefers-reduced-motion)"),this.activeMediaInfoIndex=0,this.chartAnimationDisabled=!1,this.headingLevel=2}static{this.properties={_refreshIntervalInfo:16,messages:0,values:0,expressionValues:0,activeMediaInfoIndex:9,chartAnimationDisabled:5,activeMediaInfo:32,formattedMediaInfos:32,description:1,fieldInfoMap:0,layer:0,mediaInfos:0,popupTemplate:0,relatedInfos:0,formattedValues:0,heading:1,graphic:0,formattedMediaInfoCount:32,headingLevel:9}}static{this.styles=le}get activeMediaInfo(){return this.formattedMediaInfos[this.activeMediaInfoIndex]||null}get formattedMediaInfos(){return this._formatMediaInfos()||[]}get formattedMediaInfoCount(){return this.formattedMediaInfos.length}next(){this._pageContentElementMedia(1)}previous(){this._pageContentElementMedia(-1)}setActiveMedia(e){this._setContentElementMedia(e)}loaded(){this.manager.onLifecycle(()=>[se(()=>[this.activeMediaInfo,this.activeMediaInfoIndex],()=>this._setupMediaRefreshTimer(),{initial:!0}),{remove:()=>this._clearMediaRefreshTimer()}])}_setContentElementMedia(e){let{formattedMediaInfoCount:t}=this,i=(e+t)%t;this.activeMediaInfoIndex=i}_pageContentElementMedia(e){let{activeMediaInfoIndex:t}=this,i=t+e;this._setContentElementMedia(i)}_formatMediaInfos(){let{mediaInfos:e,layer:t}=this,i=this.values??{},a=this.formattedValues??{},s=this.fieldInfoMap??new Map,r=this.expressionValues??{};return e?.map(o=>{let n=o?.clone();if(!n)return null;if(n.title=R({values:i,fieldInfoMap:s,globalValues:a,layer:t,text:n.title}),n.caption=R({values:i,fieldInfoMap:s,globalValues:a,layer:t,text:n.caption}),n.altText=R({values:i,fieldInfoMap:s,globalValues:a,layer:t,text:n.altText}),n.type==="image"){if(!n.value)return null;let l=n.value;return this._setImageValue({value:l,formattedValues:a,layer:t}),l.sourceURL?n:void 0}if(n.type==="pie-chart"||n.type==="line-chart"||n.type==="column-chart"||n.type==="bar-chart"){if(!n.value)return null;let l=n.value;return this._setChartValue({value:l,chartType:n.type,values:i,expressionValues:r,formattedValues:a,layer:t}),n}return null}).filter(o=>o!=null)??[]}_setImageValue(e){let t=this.fieldInfoMap??new Map,{value:i,formattedValues:a,layer:s}=e,{linkURL:r,sourceURL:o}=i;if(o){let n=k(o,s);i.sourceURL=F({formattedValues:a,template:n,fieldInfoMap:t})}if(r){let n=k(r,s);i.linkURL=F({formattedValues:a,template:n,fieldInfoMap:t})}}_setChartValue(e){let{value:t,values:i,expressionValues:a,formattedValues:s,chartType:r,layer:o}=e,{popupTemplate:n,relatedInfos:l}=this,{fields:p,normalizeField:d}=t,c=o;if(t.fields=G(p,c),d&&(t.normalizeField=V(d,c)),!p.some(u=>!!(s[u]!=null||C(u)&&l?.size)))return;let m=n?.fieldInfos??[];t.series=[],p.forEach((u,g)=>{let h=t.colors?.[g];if(C(u)){t.series=[...t.series,...this._getRelatedChartInfos({fieldInfos:m,fieldName:u,formattedValues:s,expressionValues:a,chartType:r,value:t,color:h})];return}let v=this._getChartOption({value:t,values:i,chartType:r,formattedValues:s,expressionValues:a,fieldName:u,fieldInfos:m,color:h});t.series.push(v)})}_getRelatedChartInfos(e){let{fieldInfos:t,fieldName:i,formattedValues:a,chartType:s,value:r,color:o,expressionValues:n}=e,l=[],p=z(i),d=p&&this.relatedInfos?.get(p.layerId);if(!d)return l;let{relatedFeatures:c,relation:m}=d;if(!m||!c)return l;let{cardinality:u}=m;return c.forEach(g=>{let h=g.attributes;h&&Object.keys(h).forEach(v=>{v===p.fieldName&&l.push(this._getChartOption({value:r,values:h,formattedValues:a,expressionValues:n,fieldName:i,chartType:s,relatedFieldName:v,hasMultipleRelatedFeatures:c?.length>1,fieldInfos:t,color:o}))})}),u&&(u==="one-to-many"||u==="many-to-many")?l:[l[0]]}_getTooltip({label:e,value:t,chartType:i}){return i==="pie-chart"?`${e}`:`${e}: ${t}`}_getChartOption(e){let{value:t,values:i,formattedValues:a,expressionValues:s,fieldName:r,relatedFieldName:o,fieldInfos:n,chartType:l,hasMultipleRelatedFeatures:p,color:d}=e,{layer:c,graphic:m}=this,u=this.fieldInfoMap??new Map,{normalizeField:g,tooltipField:h}=t,v=g?C(g)?i[z(g).fieldName]:i[g]:null,x=K(r)&&s?.[r]!==void 0?s[r]:o&&i[o]!==void 0?i[o]:i[r]!==void 0?i[r]:a[r],_=x===void 0?null:x&&v&&typeof x=="number"&&typeof v=="number"?x/v:x,f=W(n,r),y=V(r,c),b=(h&&a[h]!==void 0?a[h]:L({fieldInfo:f||new oe({fieldName:y}),expressionInfos:this.popupTemplate?.expressionInfos,graphic:m,layer:c}))??"",Z=a[y]??"",Y=_!=null?typeof _=="number"?_:Number(_):null;if(C(r)){let T=u.get(r.toLowerCase()),ee=h?u.get(h.toLowerCase()):null,te=T?.fieldName??r,$=p&&h?z(h).fieldName:ee?.fieldName??h,ie=(p&&$?i[$]:a[$]??(T&&L({fieldInfo:T,layer:c,graphic:m}))??T?.fieldName??o)??"",ae=(p&&o?i[o]:a[te])??"";return new J({fieldName:r,tooltip:this._getTooltip({label:ie,value:ae,chartType:l}),color:d,value:Y})}return new J({fieldName:r,tooltip:this._getTooltip({label:b,value:Z,chartType:l}),color:d,value:Y})}_getRenderer(){let e=this.layer;return this.graphic?.isAggregate&&e?.featureReduction&&"renderer"in e.featureReduction?e.featureReduction.renderer:e?.renderer}async _getSeriesColors(e){let{color:t}=await import("./NJHOCKLL.js"),i=new Map;return e.forEach(a=>{a.color&&i.set(a,t(a.color.toCss(!0)))}),i}async _getRendererColors(){let{color:e}=await import("./NJHOCKLL.js"),t=new Map,i=this._getRenderer(),a="default";if(!i)return t;let s=await re(i);return s.delete(a),Array.from(s.values()).every(r=>r?.length===1)&&Array.from(s.keys()).forEach(r=>{let o=s.get(r)?.[0]?.toCss(!0);o&&t.set(r,e(o))}),t}async _createChart(e){let{activeMediaInfo:t}=this;if(!e||!t)return;let{createRoot:i}=await import("./CRJEQWDO.js").then(m=>m.default.then(e=>({createRoot:e}))),a=await i(e);this._chartRoot=a,this._renderChart({mediaInfo:t,root:a})}_handleMediaKeyup(e){let{key:t}=e;t==="ArrowLeft"&&(e.stopPropagation(),this.previous()),t==="ArrowRight"&&(e.stopPropagation(),this.next())}_canAnimateChart(){return!this.chartAnimationDisabled&&!this._prefersReducedMotion}_getChartAnimationMS(){return this._canAnimateChart()?de:0}_getChartSeriesAnimationMS(){return this._canAnimateChart()?he:0}async _customizeChartTooltip(e,t="horizontal"){let{color:i}=await import("./NJHOCKLL.js");e.setAll({pointerOrientation:t}),e.get("background")?.setAll({stroke:i(ce)}),e.label.setAll({direction:this._direction,oversizedBehavior:"wrap",maxWidth:ue})}async _createPieChart(e,t){let[{Tooltip:i},{PieChart:a,PieSeries:s}]=await Promise.all([import("./NJHOCKLL.js"),import("./X5UAYUNL.js")]),{mediaInfo:r,root:o}=e,{title:n}=r,l=5,p=r?.altText||r?.title||"",d=o.container.children.push(a.new(o,{role:"figure",ariaLabel:p,focusable:!0,paddingBottom:l,paddingTop:l,paddingLeft:l,paddingRight:l})),c=`{category}: {valuePercentTotal.formatNumber('0.00')}%
3
+ ({value})`,m=i.new(o,{labelText:c}),u=d.series.push(s.new(o,{name:n,valueField:A,categoryField:w,tooltip:m}));u.ticks.template.set("forceHidden",!0),u.labels.template.set("forceHidden",!0),u.slices.template.states.create("active",{shiftRadius:l}),this._customizeChartTooltip(m),u.slices.template.setAll({ariaLabel:c,focusable:!0,templateField:"columnSettings"}),u.data.setAll(t),u.appear(this._getChartSeriesAnimationMS()),d.appear(this._getChartAnimationMS()),d.root.dom.classList.toggle("chart-rendered",!0)}_getMinSeriesValue(e){let t=0;return e.forEach(i=>t=Math.min(i.value,t)),t}async _createColumnChart(e,t,i){let[{Tooltip:a,Scrollbar:s},{CategoryAxis:r,AxisRendererX:o,AxisRendererY:n,ValueAxis:l,ColumnSeries:p}]=await Promise.all([import("./NJHOCKLL.js"),import("./RIRETHHL.js")]),{mediaInfo:d,root:c}=t,{value:m,title:u}=d,{_direction:g}=this;e.setAll({wheelX:"panX",wheelY:"zoomX"});let h=e.xAxes.push(r.new(c,{renderer:o.new(c,{inversed:g==="rtl"}),categoryField:w}));h.get("renderer").labels.template.setAll({forceHidden:!0});let v=e.yAxes.push(l.new(c,{renderer:n.new(c,{inside:!1}),min:this._getMinSeriesValue(m.series)}));v.get("renderer").labels.template.setAll({direction:g});let x="{categoryX}",_=a.new(c,{labelText:x}),f=e.series.push(p.new(c,{name:u,xAxis:h,yAxis:v,valueYField:A,categoryXField:w,tooltip:_}));this._customizeChartTooltip(_),f.columns.template.setAll({ariaLabel:x,focusable:!0,templateField:"columnSettings"}),m.series.length>X&&e.set("scrollbarX",s.new(c,{orientation:"horizontal"})),h.data.setAll(i),f.data.setAll(i),f.appear(this._getChartSeriesAnimationMS()),e.appear(this._getChartAnimationMS())}async _createBarChart(e,t,i){let[{Tooltip:a,Scrollbar:s},{CategoryAxis:r,AxisRendererX:o,AxisRendererY:n,ValueAxis:l,ColumnSeries:p}]=await Promise.all([import("./NJHOCKLL.js"),import("./RIRETHHL.js")]),{mediaInfo:d,root:c}=t,{value:m,title:u}=d,{_direction:g}=this;e.setAll({wheelX:"panY",wheelY:"zoomY"});let h=e.yAxes.push(r.new(c,{renderer:n.new(c,{inversed:!0}),categoryField:w}));h.get("renderer").labels.template.setAll({forceHidden:!0});let v=e.xAxes.push(l.new(c,{renderer:o.new(c,{inside:!1,inversed:g==="rtl"}),min:this._getMinSeriesValue(m.series)}));v.get("renderer").labels.template.setAll({direction:g});let x="{categoryY}",_=a.new(c,{labelText:x}),f=e.series.push(p.new(c,{name:u,xAxis:v,yAxis:h,valueXField:A,categoryYField:w,tooltip:_}));this._customizeChartTooltip(_,"vertical"),f.columns.template.setAll({ariaLabel:x,focusable:!0,templateField:"columnSettings"}),m.series.length>X&&e.set("scrollbarY",s.new(c,{orientation:"vertical"})),h.data.setAll(i),f.data.setAll(i),f.appear(this._getChartSeriesAnimationMS()),e.appear(this._getChartAnimationMS())}async _createLineChart(e,t,i){let[{Tooltip:a,Scrollbar:s},{CategoryAxis:r,AxisRendererX:o,AxisRendererY:n,ValueAxis:l,LineSeries:p}]=await Promise.all([import("./NJHOCKLL.js"),import("./RIRETHHL.js")]),{root:d,mediaInfo:c}=t,{value:m,title:u}=c,{_direction:g}=this;e.setAll({wheelX:"panX",wheelY:"zoomX"});let h=e.xAxes.push(r.new(d,{renderer:o.new(d,{inversed:g==="rtl"}),categoryField:w}));h.get("renderer").labels.template.setAll({forceHidden:!0});let v=e.yAxes.push(l.new(d,{renderer:n.new(d,{inside:!1}),min:this._getMinSeriesValue(m.series)}));v.get("renderer").labels.template.setAll({direction:g});let x="{categoryX}",_=i[0]?.lineSettings?.stroke,f=a.new(d,{getFillFromSprite:!_,labelText:x});_&&f.get("background")?.setAll({fill:_});let y=e.series.push(p.new(d,{name:u,xAxis:h,yAxis:v,valueYField:A,categoryXField:w,tooltip:f}));y.strokes.template.setAll({templateField:"lineSettings"}),this._customizeChartTooltip(f,"vertical"),m.series.length>X&&e.set("scrollbarX",s.new(d,{orientation:"horizontal"})),h.data.setAll(i),y.data.setAll(i),y.appear(this._getChartSeriesAnimationMS()),e.appear(this._getChartAnimationMS())}async _createXYChart(e,t){let{XYChart:i,XYCursor:a}=await import("./RIRETHHL.js"),{root:s,mediaInfo:r}=e,{type:o}=r,n=r?.altText||r?.title||"",l=s.container.children.push(i.new(s,{role:"figure",ariaLabel:n,focusable:!0,panX:!0,panY:!0}));l.set("cursor",a.new(s,{})),o==="column-chart"&&await this._createColumnChart(l,e,t),o==="bar-chart"&&await this._createBarChart(l,e,t),o==="line-chart"&&await this._createLineChart(l,e,t),l.root.dom.classList.toggle("chart-rendered",!0)}_clearMediaRefreshTimer(){let{_refreshTimer:e}=this;e&&(clearTimeout(e),this._refreshTimer=void 0)}_updateMediaInfoTimestamp(e){let t=Date.now();this._refreshIntervalInfo={timestamp:t,sourceURL:e&&this._getImageSource(e,t)}}_setupMediaRefreshTimer(){this._clearMediaRefreshTimer();let{activeMediaInfo:e}=this;e?.type==="image"&&e.refreshInterval>0&&this._setRefreshTimeout(e)}_setRefreshTimeout(e){let{refreshInterval:t,value:i}=e,a=t*6e4;this._updateMediaInfoTimestamp(i.sourceURL);let s=window.setInterval(()=>{this._updateMediaInfoTimestamp(i.sourceURL)},a);this._refreshTimer=s}_getImageSource(e,t){let i=e.includes("?")?"&":"?",[a,s=""]=e.split("#");return`${a}${i}timestamp=${t}${s?"#":""}${s}`}_updateChartElement(e){this._chartRoot?.dispose(),this._chartRoot=void 0,e&&this._createChart(e)}render(){return I`<div class="root" @keyup=${this._handleMediaKeyup}><arcgis-feature-element-info .heading=${this.heading} .description=${this.description} .headingLevel=${this.headingLevel}></arcgis-feature-element-info>${this._renderMedia()}</div>`}_renderMedia(){let{formattedMediaInfoCount:e,activeMediaInfoIndex:t}=this,i=this._renderMediaText();return e?I`<div class="container">${this._renderMediaInfo()}<div class="item-navigation">${i}${e>1?I`<div class="pagination">${this._renderMediaPageButton("previous")}<span class="pagination-text">${ne(this.messages?.pageText??"",{index:t+1,total:e})}</span>${this._renderMediaPageButton("next")}</div>`:null}</div></div>`:null}_renderMediaText(){let{activeMediaInfo:e}=this;if(!e)return null;let t=e?.title?I`<div class="item-title" .innerHTML=${Q.sanitize(e.title)??""}></div>`:null,i=e?.caption?I`<div class="item-caption" .innerHTML=${Q.sanitize(e.caption)??""}></div>`:null;return t||i?I`<div class="item-text">${t}${i}</div>`:null}_renderImageMediaInfo(e){if(!e.value)return null;let{_refreshIntervalInfo:t}=this,{value:i,refreshInterval:a,altText:s,title:r}=e,{sourceURL:o,linkURL:n}=i,l=j(n??void 0)?"_blank":"_self",p=l==="_blank"?"noreferrer":"",d=a?t:null,c=d?d.sourceURL:o,m=I`<img alt=${(s||r)??M} src=${c??void 0??M}>`;return(n?I`<a href=${n??M} rel=${p??M} target=${l??M} title=${r??M}>${m}</a>`:null)??m}_renderChartMediaInfo(e){let{activeMediaInfoIndex:t,formattedMediaInfoCount:i}=this;return q(`media-${e.type}-${t}-${i}`,I`<div class="chart" ${P(this._updateChartElement)}></div>`)}_renderMediaInfoType(){let{activeMediaInfo:e}=this;return e?e.type==="image"?this._renderImageMediaInfo(e):e.type.includes("chart")?this._renderChartMediaInfo(e):null:null}_renderMediaInfo(){let{activeMediaInfo:e}=this;return e?I`<div class="item-container"><div class="item">${this._renderMediaInfoType()}</div></div>`:null}_renderMediaPageButton(e){if(this.formattedMediaInfoCount<2)return null;let t=e==="previous",i=t?this.messages?.previous??"":this.messages?.next??"",a=t?"chevron-left":"chevron-right",s=t?this.previous:this.next;return I`<button .ariaLabel=${i} class="pagination-button" @click=${s} tabindex=0 title=${i??M} type=button><calcite-icon flip-rtl class="pagination-icon" .icon=${a} scale=s></calcite-icon></button>`}async _renderChart(e){let{root:t,mediaInfo:i}=e,{value:a,type:s}=i,[{default:r},{default:o},{default:n},{esriChartColorSet:l},{ColorSet:p,Theme:d}]=await Promise.all([import("./6RUN7OSM.js"),import("./SXWQBHG3.js"),import("./W4SQ3QCZ.js"),import("./4AQ43ENS.js"),import("./NJHOCKLL.js")]),c=d.new(t);c.rule("ColorSet").set("colors",l),c.rule("ColorSet").set("reuse",!0);let m=[n.new(t),c];H(this.el)==="dark"&&m.push(o.new(t)),this._canAnimateChart()&&m.push(r.new(t)),t.setThemes(m);let u=await this._getRendererColors(),g=await this._getSeriesColors(a.series),h=p.new(t,{}),v=g.get(a.series[0]),x=v?{lineSettings:{stroke:v}}:void 0,_=a.series.map((f,y)=>{let b=g.get(f)||u.get(f.fieldName)||h.getIndex(y);return{[w]:f.tooltip,[A]:f.value,columnSettings:{fill:b,stroke:b},...x}}).filter(f=>s==="pie-chart"?f.value!=null&&f.value>0:!0);s==="pie-chart"?this._createPieChart(e,_):this._createXYChart(e,_)}};B("arcgis-feature-media",N);return N},"renderers/support/utils","intl","core/reactiveUtils","popup/FieldInfo","popup/content/support/ChartMediaInfoValueSeries","applications/Components/sanitizerUtils",a,b)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{E as L,F as R,P as y,R as k,h as x}from"./E6IL4F2M.js";import{N as b,Q as V,d as $,f as C,o as G,q as D,u as w}from"./JUIA2RF6.js";import{a as B}from"./GMSP2RYI.js";import{O as E,g as m,o as M}from"./ZZORY2UI.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};
2
+ import{E as L,F as R,P as y,R as k,h as x}from"./JOOGE4FT.js";import{O as b,R as V,d as $,f as C,o as G,q as D,u as w}from"./HBE3W2BQ.js";import{a as B}from"./ST4PUEOI.js";import{P as E,g as m,o as M}from"./2GDVOK6V.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};