@arcgis/ai-components 5.1.0-next.76 → 5.1.0-next.78

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.
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{g as s,h as e,v as i,y as t}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";var o=s`:host{display:contents}.icon{padding:var(--calcite-spacing-sm);border-radius:var(--calcite-spacing-xl);background:var(--calcite-color-brand);color:var(--calcite-color-foreground-1)}.loading-container{display:flex;flex-direction:column;gap:var(--calcite-spacing-sm);padding:0 var(--calcite-spacing-sm)}.loading{display:flex;align-items:center;gap:var(--calcite-spacing-sm)}.text{font-style:italic;word-wrap:break-word;word-break:break-all;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:1;line-clamp:1;-webkit-box-orient:vertical}.skeleton-block{display:flex;flex-direction:column;gap:var(--calcite-spacing-sm);width:100%}.skeleton-text{display:block;height:.95em;border-radius:var(--calcite-border-radius);background:linear-gradient(90deg,color-mix(in srgb,var(--calcite-color-foreground-2) 65%,transparent),color-mix(in srgb,var(--calcite-color-foreground-3) 85%,transparent),color-mix(in srgb,var(--calcite-color-foreground-2) 65%,transparent));background-size:200% 100%;animation:assistant-message-loading-shimmer 1.2s ease-in-out infinite;width:85%}.skeleton-text:last-child{width:70%}@keyframes assistant-message-loading-shimmer{0%{background-position:-150% 0}to{background-position:150% 0}}@media(prefers-reduced-motion){.skeleton-text{animation:none}}`,a=class extends i{constructor(){super(...arguments),this.loading=!1,this.loadingMessage=""}static{this.properties={loading:5,loadingMessage:1}}static{this.styles=o}render(){return this.loading?e`<arcgis-assistant-message footer-disabled><slot name=icon slot=icon><calcite-icon class="icon" icon=effects scale=s></calcite-icon></slot><slot name=content slot=content><div class="loading-container"><div class="loading"><calcite-loader label=loading inline></calcite-loader><div class="text">${this.loadingMessage}</div></div><div class="skeleton-block"><span class="skeleton-text"></span><span class="skeleton-text"></span></div></div></slot></arcgis-assistant-message>`:null}};t("arcgis-assistant-message-loading",a);export{a as ArcgisAssistantMessageLoading};
2
+ import{g as s,h as e,v as i,y as t}from"./GW636L6T.js";import"./CFDTXKJ6.js";var o=s`:host{display:contents}.icon{padding:var(--calcite-spacing-sm);border-radius:var(--calcite-spacing-xl);background:var(--calcite-color-brand);color:var(--calcite-color-foreground-1)}.loading-container{display:flex;flex-direction:column;gap:var(--calcite-spacing-sm);padding:0 var(--calcite-spacing-sm)}.loading{display:flex;align-items:center;gap:var(--calcite-spacing-sm)}.text{font-style:italic;word-wrap:break-word;word-break:break-all;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:1;line-clamp:1;-webkit-box-orient:vertical}.skeleton-block{display:flex;flex-direction:column;gap:var(--calcite-spacing-sm);width:100%}.skeleton-text{display:block;height:.95em;border-radius:var(--calcite-border-radius);background:linear-gradient(90deg,color-mix(in srgb,var(--calcite-color-foreground-2) 65%,transparent),color-mix(in srgb,var(--calcite-color-foreground-3) 85%,transparent),color-mix(in srgb,var(--calcite-color-foreground-2) 65%,transparent));background-size:200% 100%;animation:assistant-message-loading-shimmer 1.2s ease-in-out infinite;width:85%}.skeleton-text:last-child{width:70%}@keyframes assistant-message-loading-shimmer{0%{background-position:-150% 0}to{background-position:150% 0}}@media(prefers-reduced-motion){.skeleton-text{animation:none}}`,a=class extends i{constructor(){super(...arguments),this.loading=!1,this.loadingMessage=""}static{this.properties={loading:5,loadingMessage:1}}static{this.styles=o}render(){return this.loading?e`<arcgis-assistant-message footer-disabled><slot name=icon slot=icon><calcite-icon class="icon" icon=effects scale=s></calcite-icon></slot><slot name=content slot=content><div class="loading-container"><div class="loading"><calcite-loader label=loading inline></calcite-loader><div class="text">${this.loadingMessage}</div></div><div class="skeleton-block"><span class="skeleton-text"></span><span class="skeleton-text"></span></div></div></slot></arcgis-assistant-message>`:null}};t("arcgis-assistant-message-loading",a);export{a as ArcgisAssistantMessageLoading};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{g as a,h as e,v as t,y as n}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";var i=a`:host{display:block;container-type:inline-size}.container{display:flex;flex-direction:column;align-items:flex-start;gap:var(--calcite-spacing-sm);width:100%;text-align:left}.icon{padding:var(--calcite-spacing-sm);border-radius:var(--calcite-spacing-xl);background:var(--calcite-color-brand);color:var(--calcite-color-foreground-1)}.content-container{display:flex;flex:1;flex-direction:column;width:100%;gap:var(--calcite-spacing-md)}@container (min-width: 480px){.container{max-width:80%}}`,s=class extends t{constructor(){super(...arguments),this.feedbackEnabled=!1,this.logEnabled=!1,this.copyEnabled=!1,this.readAloudEnabled=!1,this.footerDisabled=!1}static{this.properties={feedbackEnabled:5,logEnabled:5,copyEnabled:5,readAloudEnabled:5,footerDisabled:5,message:0}}static{this.styles=i}_renderContent(){return e`<arcgis-assistant-message-content .message=${this.message}></arcgis-assistant-message-content>`}_renderFooter(){return e`<arcgis-assistant-message-footer .message=${this.message} .feedbackEnabled=${this.feedbackEnabled} .logEnabled=${this.logEnabled} .copyEnabled=${this.copyEnabled} .readAloudEnabled=${this.readAloudEnabled}></arcgis-assistant-message-footer>`}render(){return e`<div class="container"><slot name=icon><calcite-icon icon=effects class="icon" scale=s></calcite-icon></slot><div class="content-container"><slot name=content>${this._renderContent()}</slot>${this.footerDisabled?null:e`<slot name=footer>${this._renderFooter()}</slot>`}</div></div>`}};n("arcgis-assistant-message",s);export{s as ArcgisAssistantMessage};
2
+ import{g as a,h as e,v as t,y as n}from"./GW636L6T.js";import"./CFDTXKJ6.js";var i=a`:host{display:block;container-type:inline-size}.container{display:flex;flex-direction:column;align-items:flex-start;gap:var(--calcite-spacing-sm);width:100%;text-align:left}.icon{padding:var(--calcite-spacing-sm);border-radius:var(--calcite-spacing-xl);background:var(--calcite-color-brand);color:var(--calcite-color-foreground-1)}.content-container{display:flex;flex:1;flex-direction:column;width:100%;gap:var(--calcite-spacing-md)}@container (min-width: 480px){.container{max-width:80%}}`,s=class extends t{constructor(){super(...arguments),this.feedbackEnabled=!1,this.logEnabled=!1,this.copyEnabled=!1,this.readAloudEnabled=!1,this.footerDisabled=!1}static{this.properties={feedbackEnabled:5,logEnabled:5,copyEnabled:5,readAloudEnabled:5,footerDisabled:5,message:0}}static{this.styles=i}_renderContent(){return e`<arcgis-assistant-message-content .message=${this.message}></arcgis-assistant-message-content>`}_renderFooter(){return e`<arcgis-assistant-message-footer .message=${this.message} .feedbackEnabled=${this.feedbackEnabled} .logEnabled=${this.logEnabled} .copyEnabled=${this.copyEnabled} .readAloudEnabled=${this.readAloudEnabled}></arcgis-assistant-message-footer>`}render(){return e`<div class="container"><slot name=icon><calcite-icon icon=effects class="icon" scale=s></calcite-icon></slot><div class="content-container"><slot name=content>${this._renderContent()}</slot>${this.footerDisabled?null:e`<slot name=footer>${this._renderFooter()}</slot>`}</div></div>`}};n("arcgis-assistant-message",s);export{s as ArcgisAssistantMessage};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as m}from"./KADK7ZYA.js";import"./YGW7TUNX.js";import{g as p,h as u,v as h,y as g}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";export default $arcgis.t(([{watch:y},f,{property:_,subclass:A}])=>{var S=p``,b=Object.defineProperty,C=Object.getOwnPropertyDescriptor,c=(e,s,i,a)=>{for(var r=a>1?void 0:a?C(s,i):s,t=e.length-1,n;t>=0;t--)(n=e[t])&&(r=(a?n(s,i,r):n(r))||r);return a&&r&&b(s,i,r),r};function l(){return typeof window>"u"?null:window}var o=class extends f{constructor(){super(...arguments),this._utterance=null,this.state="idle",this.supported=o.isSupported()}destroy(){this.stop(),super.destroy()}start(e){let s=e.trim(),i=l(),a=i?.SpeechSynthesisUtterance,r=i?.speechSynthesis;if(this._set("supported",o.isSupported(i)),!s||!a||!r)return;this.stop();let t=new a(s);t.rate=.9,t.pitch=1.1,t.volume=1,t.onend=()=>{this._utterance===t&&this._reset()},t.onerror=()=>{this._utterance===t&&this._reset()};try{r.speak(t),this._utterance=t,this._set("state","playing")}catch{t.onend=null,t.onerror=null,this._reset()}}stop(){let e=l(),s=e?.speechSynthesis;if(this._set("supported",o.isSupported(e)),s)try{(s.speaking||s.pending)&&s.cancel()}catch{}this._reset()}toggle(e){if(this.state==="playing"){this.stop();return}this.start(e)}static isSupported(e=l()){return!!e?.speechSynthesis&&typeof e.SpeechSynthesisUtterance=="function"}_reset(){this._utterance&&(this._utterance.onend=null,this._utterance.onerror=null),this._utterance=null,this._set("state","idle")}};c([_({readOnly:!0})],o.prototype,"state",2);c([_({readOnly:!0})],o.prototype,"supported",2);o=c([A("ReadAloudController")],o);var d=class extends h{constructor(){super(...arguments),this._messages=m({blocking:!0}),this._readAloudController=new o,this.readAloudEnabled=!1}static{this.properties={readAloudEnabled:5,message:0}}static{this.styles=S}loaded(){this.manager.onLifecycle(()=>[y(()=>this._readAloudController.state,()=>this.requestUpdate(),{initial:!0}),{remove:()=>{this._readAloudController.stop()}}])}_toggleReadAloud(){this._readAloudController.toggle(this.message?.content??"")}render(){return this.readAloudEnabled&&!this.message?.error&&this.message?.content?.trim()&&this._readAloudController.supported?u`<calcite-action id=action-read-aloud .icon=${this._readAloudController.state==="playing"?"sound-off":"sound"} scale=s .active=${this._readAloudController.state==="playing"} @click=${()=>this._toggleReadAloud()} text></calcite-action><calcite-tooltip reference-element=action-read-aloud overlay-positioning=fixed placement=bottom><span>${this._readAloudController.state==="playing"?this._messages.stopReadingButtonLabel:this._messages.readAloudButtonLabel}</span></calcite-tooltip>`:null}};g("arcgis-assistant-message-read-aloud",d);return d},"core/reactiveUtils","core/Accessor","core/accessorSupport/decorators")
2
+ import{a as m}from"./A2EDNDZP.js";import"./YGW7TUNX.js";import{g as p,h as u,v as h,y as g}from"./GW636L6T.js";import"./CFDTXKJ6.js";export default $arcgis.t(([{watch:y},f,{property:_,subclass:A}])=>{var S=p``,b=Object.defineProperty,C=Object.getOwnPropertyDescriptor,c=(e,s,i,a)=>{for(var r=a>1?void 0:a?C(s,i):s,t=e.length-1,n;t>=0;t--)(n=e[t])&&(r=(a?n(s,i,r):n(r))||r);return a&&r&&b(s,i,r),r};function l(){return typeof window>"u"?null:window}var o=class extends f{constructor(){super(...arguments),this._utterance=null,this.state="idle",this.supported=o.isSupported()}destroy(){this.stop(),super.destroy()}start(e){let s=e.trim(),i=l(),a=i?.SpeechSynthesisUtterance,r=i?.speechSynthesis;if(this._set("supported",o.isSupported(i)),!s||!a||!r)return;this.stop();let t=new a(s);t.rate=.9,t.pitch=1.1,t.volume=1,t.onend=()=>{this._utterance===t&&this._reset()},t.onerror=()=>{this._utterance===t&&this._reset()};try{r.speak(t),this._utterance=t,this._set("state","playing")}catch{t.onend=null,t.onerror=null,this._reset()}}stop(){let e=l(),s=e?.speechSynthesis;if(this._set("supported",o.isSupported(e)),s)try{(s.speaking||s.pending)&&s.cancel()}catch{}this._reset()}toggle(e){if(this.state==="playing"){this.stop();return}this.start(e)}static isSupported(e=l()){return!!e?.speechSynthesis&&typeof e.SpeechSynthesisUtterance=="function"}_reset(){this._utterance&&(this._utterance.onend=null,this._utterance.onerror=null),this._utterance=null,this._set("state","idle")}};c([_({readOnly:!0})],o.prototype,"state",2);c([_({readOnly:!0})],o.prototype,"supported",2);o=c([A("ReadAloudController")],o);var d=class extends h{constructor(){super(...arguments),this._messages=m({blocking:!0}),this._readAloudController=new o,this.readAloudEnabled=!1}static{this.properties={readAloudEnabled:5,message:0}}static{this.styles=S}loaded(){this.manager.onLifecycle(()=>[y(()=>this._readAloudController.state,()=>this.requestUpdate(),{initial:!0}),{remove:()=>{this._readAloudController.stop()}}])}_toggleReadAloud(){this._readAloudController.toggle(this.message?.content??"")}render(){return this.readAloudEnabled&&!this.message?.error&&this.message?.content?.trim()&&this._readAloudController.supported?u`<calcite-action id=action-read-aloud .icon=${this._readAloudController.state==="playing"?"sound-off":"sound"} scale=s .active=${this._readAloudController.state==="playing"} @click=${()=>this._toggleReadAloud()} text></calcite-action><calcite-tooltip reference-element=action-read-aloud overlay-positioning=fixed placement=bottom><span>${this._readAloudController.state==="playing"?this._messages.stopReadingButtonLabel:this._messages.readAloudButtonLabel}</span></calcite-tooltip>`:null}};g("arcgis-assistant-message-read-aloud",d);return d},"core/reactiveUtils","core/Accessor","core/accessorSupport/decorators")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import c from"./TDBJ6YZ6.js";import b from"./2E6GEUNH.js";import"./WI3JQXAS.js";import{a as r,c as e}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as a,y as s}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";export default $arcgis.t(([,{b:i}])=>{var t=class extends a{constructor(){super(...arguments),this.agent=i}static{this.properties={referenceElement:1}}#t;getContext(){if(!this.#t)throw new Error("arcgis-assistant-data-exploration-agent requires a mapView");return{mapView:this.#t}}load(){this.#t=r(this,"arcgis-assistant-data-exploration-agent"),e(this)}};s("arcgis-assistant-data-exploration-agent",t);return t},b,c)
2
+ import c from"./TDBJ6YZ6.js";import b from"./2E6GEUNH.js";import"./WI3JQXAS.js";import{a as r,c as e}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as a,y as s}from"./GW636L6T.js";import"./CFDTXKJ6.js";export default $arcgis.t(([,{b:i}])=>{var t=class extends a{constructor(){super(...arguments),this.agent=i}static{this.properties={referenceElement:1}}#t;getContext(){if(!this.#t)throw new Error("arcgis-assistant-data-exploration-agent requires a mapView");return{mapView:this.#t}}load(){this.#t=r(this,"arcgis-assistant-data-exploration-agent"),e(this)}};s("arcgis-assistant-data-exploration-agent",t);return t},b,c)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as $,c as k}from"./YGW7TUNX.js";import{a as C,b as L,c as m,d as f,e as P,f as O,k as g,m as v,o as w,z as N}from"./SGGBOB5K.js";var _=t=>(...s)=>{let o=f(),e=new t(...s),r=e.exports;m(o.at(-1));let n=e.component.manager;n.W(e,r),e.watchExports(n.W.bind(n,e)),P(e);let a=[e.component,...o].reverse();return v(a,i=>i===void 0?void 0:j(e,i,r),r)},j=(t,{host:s,key:o,isReactive:e},r)=>{let n=s,a=n[o]!==t.exports,i=n[o]!==r,c=r!==t.exports;if(a&&!i&&c&&(n[o]=t.exports),s===t.component){if(e){let l=t.component.manager;i&&l.W(t,n[o]),t.onUpdate(u=>{if(u.has(o)){let x=n[o];x!==t.exports&&l.W(t,x)}})}t.O=e?void 0:o}let d=t.component.constructor.elementProperties.get(o)?.readOnly;t.watchExports(()=>{n[o]!==t.exports&&(d?O(()=>{n[o]=t.exports}):n[o]=t.exports)})};var z="ar,bg,bs,ca,cs,da,de,el,en,es,et,fi,fr,he,hr,hu,id,it,ja,ko,lt,lv,nl,nb,no,pl,pt-BR,pt-PT,ro,ru,sk,sl,sr,sv,th,tr,uk,vi,zh-CN,zh-HK,zh-TW".split(","),M=new Set(z),h="en",U={pt:"pt-BR",nb:"no",nn:"no",zh:"zh-CN"},F=async(t,s,o="")=>{let e=`${s}/${o}`,r=`${e}${t}.json`;return b[r]??(b[r]=A(t,e)),await b[r]},b={},A=async(t,s)=>{let o=`${s}${t}.json`;try{let e=await fetch(o);if(e.ok)return await e.json()}catch(e){return g("error","intl",`An unknown error occurred while fetching localization strings at ${o}`,{detail:{error:e}}),{}}return t===h?{}:await A(h,s)},y=t=>{let s=k(t,"lang",globalThis.navigator?.language||h);return{lang:s,t9nLocale:D(s)}},D=t=>{let[s,o]=t.split("-"),e=s.toLowerCase(),r=e;return o&&(r=`${e}-${o.toUpperCase()}`),r=U[r]??r,M.has(r)?r:o?D(e):h},T=(t,s,o,e)=>{let r,n=()=>K(t,s(),e).then(a=>{(r?.lang!==a.lang||r.t9nLocale!==a.t9nLocale||r.t9nStrings!==a.t9nStrings)&&o(a),r=a}).catch(a=>{g("error","intl","Error updating component locale state",{detail:{error:a}})});return queueMicrotask(n),$(t,["lang"],n)},K=async(t,s,o=t.localName.split("-").slice(1).join("-"))=>{let{lang:e,t9nLocale:r}=y(t),n=`${s}/${o}/t9n`,i=o===null?{}:await F(r,n,"messages.");return{lang:e,t9nLocale:r,t9nStrings:i}};var W=t=>I(void 0,t);var E=class extends w{constructor(s,o){super(s);let e=this.exports;try{L(this.component);let r=o(this.component,this),n=this.exports!==e;if(C(r)){n||this.setProvisionalExports(r);let a=r.then(i=>{this.exports=i,super.catchUpLifecycle()}).catch(i=>{this.P.reject(i)});this.onLoad(async()=>await a)}else(!n||r!==void 0)&&(this.exports=r),queueMicrotask(()=>super.catchUpLifecycle())}catch(r){this.P.reject(r)}}catchUpLifecycle(){}},I=_(E);var S=t=>(s={})=>W((o,e)=>{let r=y(o.el),n={_lang:r.lang,_t9nLocale:r.t9nLocale,_loading:!0},a=o;e.onLifecycle(()=>T(o.el,()=>t("./assets"),({t9nLocale:c,t9nStrings:p,lang:d})=>{let l={...p,_lang:d,_t9nLocale:c,_loading:!1};e.exports=l;let u=p.componentLabel;typeof u=="string"&&"label"in o&&o.label==null&&(o.label??=u),i(a.messageOverrides)},s.name));let i=c=>{let p=e.exports,d=p._original??p,l=V(d,c);c&&(l._original=d),e.exports=l};return"messageOverrides"in a&&e.onUpdate(c=>{c.has("messageOverrides")&&i(a.messageOverrides)}),s.blocking?(e.setProvisionalExports(n,!1),e.ready):n}),V=(t,s)=>{if(!s)return t;let o={...t};return Object.entries(s).forEach(([e,r])=>{t[e]!==void 0&&(typeof r=="object"?o[e]=V(t[e],r):o[e]=r??t[e])}),o};var ct=S(N);export{ct as a};
2
+ import{a as $,c as k}from"./YGW7TUNX.js";import{a as C,b as L,c as m,d as f,e as P,f as O,k as g,m as v,o as w,z as N}from"./GW636L6T.js";var _=t=>(...s)=>{let o=f(),e=new t(...s),r=e.exports;m(o.at(-1));let n=e.component.manager;n.W(e,r),e.watchExports(n.W.bind(n,e)),P(e);let a=[e.component,...o].reverse();return v(a,i=>i===void 0?void 0:j(e,i,r),r)},j=(t,{host:s,key:o,isReactive:e},r)=>{let n=s,a=n[o]!==t.exports,i=n[o]!==r,c=r!==t.exports;if(a&&!i&&c&&(n[o]=t.exports),s===t.component){if(e){let l=t.component.manager;i&&l.W(t,n[o]),t.onUpdate(u=>{if(u.has(o)){let x=n[o];x!==t.exports&&l.W(t,x)}})}t.O=e?void 0:o}let d=t.component.constructor.elementProperties.get(o)?.readOnly;t.watchExports(()=>{n[o]!==t.exports&&(d?O(()=>{n[o]=t.exports}):n[o]=t.exports)})};var z="ar,bg,bs,ca,cs,da,de,el,en,es,et,fi,fr,he,hr,hu,id,it,ja,ko,lt,lv,nl,nb,no,pl,pt-BR,pt-PT,ro,ru,sk,sl,sr,sv,th,tr,uk,vi,zh-CN,zh-HK,zh-TW".split(","),M=new Set(z),h="en",U={pt:"pt-BR",nb:"no",nn:"no",zh:"zh-CN"},F=async(t,s,o="")=>{let e=`${s}/${o}`,r=`${e}${t}.json`;return b[r]??(b[r]=A(t,e)),await b[r]},b={},A=async(t,s)=>{let o=`${s}${t}.json`;try{let e=await fetch(o);if(e.ok)return await e.json()}catch(e){return g("error","intl",`An unknown error occurred while fetching localization strings at ${o}`,{detail:{error:e}}),{}}return t===h?{}:await A(h,s)},y=t=>{let s=k(t,"lang",globalThis.navigator?.language||h);return{lang:s,t9nLocale:D(s)}},D=t=>{let[s,o]=t.split("-"),e=s.toLowerCase(),r=e;return o&&(r=`${e}-${o.toUpperCase()}`),r=U[r]??r,M.has(r)?r:o?D(e):h},T=(t,s,o,e)=>{let r,n=()=>K(t,s(),e).then(a=>{(r?.lang!==a.lang||r.t9nLocale!==a.t9nLocale||r.t9nStrings!==a.t9nStrings)&&o(a),r=a}).catch(a=>{g("error","intl","Error updating component locale state",{detail:{error:a}})});return queueMicrotask(n),$(t,["lang"],n)},K=async(t,s,o=t.localName.split("-").slice(1).join("-"))=>{let{lang:e,t9nLocale:r}=y(t),n=`${s}/${o}/t9n`,i=o===null?{}:await F(r,n,"messages.");return{lang:e,t9nLocale:r,t9nStrings:i}};var W=t=>I(void 0,t);var E=class extends w{constructor(s,o){super(s);let e=this.exports;try{L(this.component);let r=o(this.component,this),n=this.exports!==e;if(C(r)){n||this.setProvisionalExports(r);let a=r.then(i=>{this.exports=i,super.catchUpLifecycle()}).catch(i=>{this.P.reject(i)});this.onLoad(async()=>await a)}else(!n||r!==void 0)&&(this.exports=r),queueMicrotask(()=>super.catchUpLifecycle())}catch(r){this.P.reject(r)}}catchUpLifecycle(){}},I=_(E);var S=t=>(s={})=>W((o,e)=>{let r=y(o.el),n={_lang:r.lang,_t9nLocale:r.t9nLocale,_loading:!0},a=o;e.onLifecycle(()=>T(o.el,()=>t("./assets"),({t9nLocale:c,t9nStrings:p,lang:d})=>{let l={...p,_lang:d,_t9nLocale:c,_loading:!1};e.exports=l;let u=p.componentLabel;typeof u=="string"&&"label"in o&&o.label==null&&(o.label??=u),i(a.messageOverrides)},s.name));let i=c=>{let p=e.exports,d=p._original??p,l=V(d,c);c&&(l._original=d),e.exports=l};return"messageOverrides"in a&&e.onUpdate(c=>{c.has("messageOverrides")&&i(a.messageOverrides)}),s.blocking?(e.setProvisionalExports(n,!1),e.ready):n}),V=(t,s)=>{if(!s)return t;let o={...t};return Object.entries(s).forEach(([e,r])=>{t[e]!==void 0&&(typeof r=="object"?o[e]=V(t[e],r):o[e]=r??t[e])}),o};var ct=S(N);export{ct as a};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as o}from"./KADK7ZYA.js";import"./YGW7TUNX.js";import{g as a,h as e,n as i,v as c,y as n}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";var r=a`.actions{display:flex;flex-direction:row;gap:var(--calcite-spacing-xs)}`,t=class extends c{constructor(){super(...arguments),this._messages=o({blocking:!0}),this.feedbackEnabled=!1,this.arcgisFeedback=i()}static{this.properties={feedbackEnabled:5,message:0}}static{this.styles=r}_handleFeedback(s){this.message&&(this.message.feedback=this.message.feedback?.positive===s?void 0:{positive:s},this.arcgisFeedback.emit(this.message),this.requestUpdate())}_getFeedback(){return this.message?.feedback?.positive}_renderThumbsUpButton(){return e`<calcite-action id=action-thumbs-up icon=thumbs-up scale=s .active=${this._getFeedback()===!0} @click=${()=>this._handleFeedback(!0)} text></calcite-action><calcite-tooltip reference-element=action-thumbs-up overlay-positioning=fixed placement=bottom><span>${this._messages.thumbsUpLabel}</span></calcite-tooltip>`}_renderThumbsDownButton(){return e`<calcite-action id=action-thumbs-down icon=thumbs-down scale=s .active=${this._getFeedback()===!1} @click=${()=>this._handleFeedback(!1)} text></calcite-action><calcite-tooltip reference-element=action-thumbs-down overlay-positioning=fixed placement=bottom><span>${this._messages.thumbsDownLabel}</span></calcite-tooltip>`}render(){return this.feedbackEnabled&&!this.message?.error?e`<div class="actions">${this._renderThumbsUpButton()}${this._renderThumbsDownButton()}</div>`:null}};n("arcgis-assistant-message-feedback",t);export{t as ArcgisAssistantMessageFeedback};
2
+ import{a as o}from"./A2EDNDZP.js";import"./YGW7TUNX.js";import{g as a,h as e,n as i,v as c,y as n}from"./GW636L6T.js";import"./CFDTXKJ6.js";var r=a`.actions{display:flex;flex-direction:row;gap:var(--calcite-spacing-xs)}`,t=class extends c{constructor(){super(...arguments),this._messages=o({blocking:!0}),this.feedbackEnabled=!1,this.arcgisFeedback=i()}static{this.properties={feedbackEnabled:5,message:0}}static{this.styles=r}_handleFeedback(s){this.message&&(this.message.feedback=this.message.feedback?.positive===s?void 0:{positive:s},this.arcgisFeedback.emit(this.message),this.requestUpdate())}_getFeedback(){return this.message?.feedback?.positive}_renderThumbsUpButton(){return e`<calcite-action id=action-thumbs-up icon=thumbs-up scale=s .active=${this._getFeedback()===!0} @click=${()=>this._handleFeedback(!0)} text></calcite-action><calcite-tooltip reference-element=action-thumbs-up overlay-positioning=fixed placement=bottom><span>${this._messages.thumbsUpLabel}</span></calcite-tooltip>`}_renderThumbsDownButton(){return e`<calcite-action id=action-thumbs-down icon=thumbs-down scale=s .active=${this._getFeedback()===!1} @click=${()=>this._handleFeedback(!1)} text></calcite-action><calcite-tooltip reference-element=action-thumbs-down overlay-positioning=fixed placement=bottom><span>${this._messages.thumbsDownLabel}</span></calcite-tooltip>`}render(){return this.feedbackEnabled&&!this.message?.error?e`<div class="actions">${this._renderThumbsUpButton()}${this._renderThumbsDownButton()}</div>`:null}};n("arcgis-assistant-message-feedback",t);export{t as ArcgisAssistantMessageFeedback};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import c from"./TDBJ6YZ6.js";import b from"./2E6GEUNH.js";import"./WI3JQXAS.js";import{a as i,c as e}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as a,y as s}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";export default $arcgis.t(([,{a:r}])=>{var t=class extends a{constructor(){super(...arguments),this.agent=r}static{this.properties={referenceElement:1}}#t;getContext(){if(!this.#t)throw new Error("arcgis-assistant-navigation-agent requires a mapView");return{mapView:this.#t}}load(){this.#t=i(this,"arcgis-assistant-navigation-agent"),e(this)}};s("arcgis-assistant-navigation-agent",t);return t},b,c)
2
+ import c from"./TDBJ6YZ6.js";import b from"./2E6GEUNH.js";import"./WI3JQXAS.js";import{a as i,c as e}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as a,y as s}from"./GW636L6T.js";import"./CFDTXKJ6.js";export default $arcgis.t(([,{a:r}])=>{var t=class extends a{constructor(){super(...arguments),this.agent=r}static{this.properties={referenceElement:1}}#t;getContext(){if(!this.#t)throw new Error("arcgis-assistant-navigation-agent requires a mapView");return{mapView:this.#t}}load(){this.#t=i(this,"arcgis-assistant-navigation-agent"),e(this)}};s("arcgis-assistant-navigation-agent",t);return t},b,c)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{g as C,h as S,n as l,v as R,w as m,y}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";export default $arcgis.t(([{when:k,watch:u},I,{property:d,subclass:f}])=>{var T=C`.button{--calcite-button-background-color: var(--calcite-color-transparent);--calcite-button-border-color: transparent;--calcite-button-icon-color: var(--calcite-color-text-3);--calcite-button-text-color: var(--calcite-color-text-3);flex:0 0 auto;position:relative}.button[data-state=disabled]{--calcite-button-icon-color: var(--calcite-color-text-3);opacity:var(--calcite-opacity-disabled)}.button[data-state=listening]{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-brand) 14%, var(--calcite-color-foreground-1) );--calcite-button-border-color: color-mix(in srgb, var(--calcite-color-brand) 24%, transparent);--calcite-button-icon-color: var(--calcite-color-brand);--calcite-button-text-color: var(--calcite-color-brand);box-shadow:var(--calcite-shadow-sm)}.button[data-state=listening]:hover{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-brand-hover, var(--calcite-color-brand)) 18%, var(--calcite-color-foreground-1) )}.button[data-state=listening]:active{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-brand) 24%, var(--calcite-color-foreground-1) )}.button[data-state=processing]{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-brand) 10%, var(--calcite-color-foreground-1) );--calcite-button-border-color: color-mix(in srgb, var(--calcite-color-brand) 20%, transparent);--calcite-button-icon-color: var(--calcite-color-brand);--calcite-button-text-color: var(--calcite-color-brand)}.button[data-state=error]{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-status-danger) 12%, var(--calcite-color-foreground-1) );--calcite-button-border-color: color-mix(in srgb, var(--calcite-color-status-danger) 24%, transparent);--calcite-button-icon-color: var(--calcite-color-status-danger);--calcite-button-text-color: var(--calcite-color-status-danger)}.button[data-state=listening]:after{content:"";position:absolute;inset:-4px;border:1px solid color-mix(in srgb,var(--calcite-color-brand) 40%,transparent);border-radius:inherit;opacity:0;pointer-events:none;transform:scale(.92);animation:assistant-speech-input-recording-pulse 1.8s ease-out infinite}@keyframes assistant-speech-input-recording-pulse{0%{opacity:.65;transform:scale(.92)}70%{opacity:0;transform:scale(1.16)}to{opacity:0;transform:scale(1.16)}}@media(prefers-reduced-motion){.button[data-state=listening]:after{animation:none}}`,x=Object.defineProperty,V=Object.getOwnPropertyDescriptor,p=(e,t,s,i)=>{for(var r=i>1?void 0:i?V(t,s):t,n=e.length-1,o;n>=0;n--)(o=e[n])&&(r=(i?o(t,s,r):o(r))||r);return i&&r&&x(t,s,r),r},a=class extends I{constructor(e){super(e),this.state="idle",this.liveTranscript="",this.transcript="",this.errorCode=void 0}static isSupported(){return!1}};p([d()],a.prototype,"language",2);p([d({readOnly:!0})],a.prototype,"state",2);p([d({readOnly:!0})],a.prototype,"liveTranscript",2);p([d({readOnly:!0})],a.prototype,"transcript",2);p([d({readOnly:!0})],a.prototype,"errorCode",2);a=p([f("SpeechController")],a);var O=["audio/webm;codecs=opus","audio/webm","audio/mp4","audio/ogg;codecs=opus","audio/ogg"];function h(e){return e.replace(/\s+/gu," ").trim()}var M=Object.defineProperty,D=Object.getOwnPropertyDescriptor,g=(e,t,s,i)=>{for(var r=i>1?void 0:i?D(t,s):t,n=e.length-1,o;n>=0;n--)(o=e[n])&&(r=(i?o(t,s,r):o(r))||r);return i&&r&&M(t,s,r),r},c=class extends a{constructor(e){super(e),this._activeSessionId=null,this._mediaRecorder=null,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._mediaStream=null,this._pendingChunkOperations=new Set,this._recordedChunks=[],this.handleRecording=null,this.chunkTimeSlice=3e3}get _mimeType(){return typeof window>"u"||typeof window.MediaRecorder?.isTypeSupported!="function"?"":O.find(e=>window.MediaRecorder.isTypeSupported(e))??""}initialize(){c.isSupported()&&this.addHandles(k(()=>!!this.errorCode,()=>{this._set("state","error")}))}destroy(){this._mediaRecorder&&(this._mediaRecorder.onstart=null,this._mediaRecorder.ondataavailable=null,this._mediaRecorder.onerror=null,this._mediaRecorder.onstop=null),this.cancel(),this._mediaRecorder=null}_queuePendingChunkOperation(e){this._pendingChunkOperations.add(e),e.finally(()=>{this._pendingChunkOperations.delete(e)})}async _awaitPendingChunkOperations(){this._pendingChunkOperations.size&&await Promise.allSettled(Array.from(this._pendingChunkOperations))}_onDataAvailable(e){let t=this._activeSessionId;t!=null&&this._queuePendingChunkOperation(this._processDataAvailable(e,t))}async _processDataAvailable(e,t){let s=e.data;if(!s.size||t!==this._activeSessionId)return;this._recordedChunks.push(s);let i=s.type||this._mediaRecorder?.mimeType||this._mimeType,r=this._mediaRecorderStopReason==="toggle"&&this._mediaRecorder?.state==="inactive";try{if(!this.handleRecording)return;let n=h(await this.handleRecording(s,i,this._mediaRecorderChunkIndex,r)??"");if(t!==this._activeSessionId)return;n&&this._set("liveTranscript",h(`${this.liveTranscript} ${n}`))}catch(n){if(t!==this._activeSessionId)return;this._failSession(n instanceof Error&&n.message==="transcription-unavailable"?"transcription-unavailable":"transcription-failed");return}!r&&t===this._activeSessionId&&(this._mediaRecorderChunkIndex+=1)}_failSession(e){let t=this._mediaRecorder;if(t){t.onstart=null,t.ondataavailable=null,t.onerror=null,t.onstop=null;try{t.state!=="inactive"&&t.stop()}catch{}}this._activeSessionId=null,this._mediaRecorder=null,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._releaseMediaStream(),this._set("liveTranscript",""),this._set("transcript",""),this._set("errorCode",e)}_onError(){this._failSession("recording-failed")}_onStart(){this._set("state","listening")}_onStop(){this._handleStop()}_releaseMediaStream(){this._mediaStream?.getTracks().forEach(e=>e.stop()),this._mediaStream=null}async _handleStop(){let e=this._mediaRecorder,t=this._activeSessionId,s=this._mediaRecorderStopReason,i=e?.mimeType||this._recordedChunks.find(n=>!!n.type)?.type||"",r=[...this._recordedChunks];if(this._mediaRecorder=null,this._mediaRecorderChunkIndex=0,this._releaseMediaStream(),s==="cancel"){this._activeSessionId===t&&(this._activeSessionId=null),this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._set("liveTranscript",""),this._set("transcript",""),this._set("state","idle"),this._set("errorCode",void 0);return}if(t==null){this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._set("state","idle"),this._set("errorCode",void 0);return}if(await this._awaitPendingChunkOperations(),t===this._activeSessionId){if(!(i?new Blob(r,{type:i}):new Blob(r)).size){this._activeSessionId===t&&(this._activeSessionId=null),this._mediaRecorderStopReason=null,this._recordedChunks=[],this._set("errorCode","recording-failed");return}this._set("state","processing"),this._set("transcript",h(`${this.transcript} ${this.liveTranscript}`)),this._set("liveTranscript",""),this._activeSessionId===t&&(this._activeSessionId=null),this._set("state","idle"),this._set("errorCode",void 0),this._mediaRecorderStopReason=null,this._recordedChunks=[]}}start(){if(!c.isSupported()){this._set("errorCode","not-supported");return}let e=Date.now();this._activeSessionId=e,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._set("liveTranscript",""),this._set("transcript",""),this._set("errorCode",void 0),navigator.mediaDevices.getUserMedia({audio:!0}).then(t=>{if(e!==this._activeSessionId){t.getTracks().forEach(r=>r.stop());return}let s=this._mimeType,i=s?new window.MediaRecorder(t,{mimeType:s}):new window.MediaRecorder(t);this._mediaStream=t,this._mediaRecorder=i,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._recordedChunks=[],i.ondataavailable=this._onDataAvailable.bind(this),i.onerror=this._onError.bind(this),i.onstart=this._onStart.bind(this),i.onstop=this._onStop.bind(this),this._mediaRecorder.start(this.chunkTimeSlice)}).catch(t=>{e===this._activeSessionId&&(this._activeSessionId=null,this._mediaRecorder=null,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._releaseMediaStream(),t instanceof DOMException&&t.name==="NotAllowedError"?this._set("errorCode","not-allowed"):this._set("errorCode","recording-failed"))})}stop(){if(this._mediaRecorder){this._mediaRecorderStopReason="toggle";try{this._mediaRecorder.state!=="inactive"?this._mediaRecorder.stop():this._handleStop()}catch{}}}cancel(){let e=this._mediaRecorder;if(this._activeSessionId=null,this._mediaRecorderStopReason="cancel",this._mediaRecorderChunkIndex=0,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._set("liveTranscript",""),this._set("transcript",""),this._set("state","idle"),this._set("errorCode",void 0),!e){this._releaseMediaStream();return}try{if(e.state!=="inactive"){e.stop();return}}catch{}this._mediaRecorder=null,this._releaseMediaStream()}static isSupported(){return typeof window<"u"&&!!(window.MediaRecorder&&navigator.mediaDevices?.getUserMedia)}};g([d()],c.prototype,"_mimeType",1);g([d()],c.prototype,"handleRecording",2);g([d()],c.prototype,"chunkTimeSlice",2);c=g([f("MediaRecorderController")],c);var $=Object.getOwnPropertyDescriptor,E=(e,t,s,i)=>{for(var r=i>1?void 0:i?$(t,s):t,n=e.length-1,o;n>=0;n--)(o=e[n])&&(r=o(r)||r);return r};function w(){if(typeof window>"u")return null;let e=window;return e.SpeechRecognition??e.webkitSpeechRecognition??null}var _=class extends a{constructor(e){super(e),this._isCancelled=!1,this._recognition=null}initialize(){let e=w();if(!e)return;let t=new e;t.continuous=!0,t.interimResults=!0,this.language&&(t.lang=this.language),t.onstart=this._onStart.bind(this),t.onresult=this._onResult.bind(this),t.onerror=this._onError.bind(this),t.onend=this._onEnd.bind(this),t.onspeechend=this._onSpeechEnd.bind(this),this._recognition=t,this.addHandles(k(()=>!!this.errorCode,()=>{this._set("state","error")}))}destroy(){this._recognition&&(this._recognition.onstart=null,this._recognition.onresult=null,this._recognition.onerror=null,this._recognition.onend=null,this._recognition.onspeechend=null,this.cancel(),this._recognition=null)}_onStart(){this._isCancelled=!1,this._set("state","listening")}_onResult(e){let{finalTranscript:t,liveTranscript:s}=Array.from(e.results).reduce((i,r)=>(r.isFinal?i.finalTranscript+=r[0].transcript:i.liveTranscript+=r[0].transcript,i),{finalTranscript:"",liveTranscript:""});this._set("transcript",h(t)),this._set("liveTranscript",h(s))}_onError(e){if(e.error==="aborted"&&this._isCancelled){this._set("state","idle");return}let t="unhandled";switch(e.error){case"no-speech":t="no-speech";break;case"service-not-allowed":case"not-allowed":t="not-allowed";break;default:t="unhandled"}this._set("errorCode",t)}_onEnd(){let e=h(`${this.transcript} ${this.liveTranscript}`);if(this._set("liveTranscript",""),this._isCancelled){this._set("transcript",""),this._set("state","idle"),this._set("errorCode",void 0);return}this.errorCode?this._set("transcript",""):(this._set("transcript",e),this._set("state","idle")),this._set("errorCode",void 0)}_onSpeechEnd(){this._set("state","processing")}_reset(e=!1){this._isCancelled=e,this._set("liveTranscript",""),this._set("transcript",""),this._set("errorCode",void 0),this._set("state","idle")}start(){if(!this._recognition){this._set("errorCode","not-supported");return}this._reset(!1);try{this._recognition.start()}catch{this._set("errorCode","unhandled")}}stop(){if(this._recognition){this._set("state","processing");try{this._recognition.stop()}catch{}}}cancel(){if(this._recognition){this._reset(!0);try{this._recognition.abort()}catch{}}}static isSupported(){return!!w()}};_=E([f("WebSpeechController")],_);function b(e){let{baseValue:t,transcript:s}=e;if(!s)return t;let i=t.trim();return i?`${i} ${s}`:s}var v=class extends R{constructor(){super(...arguments),this.#t=null,this._resolvedMode="disabled",this.awaitingResponse=!1,this.inputValue="",this.mode="web-speech",this.arcgisVoiceInputDraftChange=l(),this.arcgisVoiceInputError=l(),this.arcgisVoiceInputInterimTranscription=l(),this.arcgisVoiceInputStart=l(),this.arcgisVoiceInputStop=l(),this.arcgisVoiceInputTranscription=l(),this.arcgisVoiceInputTranscriptionStreamChunk=l()}static{this.properties={_resolvedMode:16,_state:16,_errorCode:16,_liveTranscript:16,_transcript:16,_isButtonDisabled:16,_buttonLabel:16,awaitingResponse:5,inputValue:1,language:1,mode:1}}static{this.styles=T}#t;get _state(){return this._speechController?.state??"idle"}get _errorCode(){return this._speechController?.errorCode??null}get _liveTranscript(){return this._speechController?.liveTranscript??""}get _transcript(){return this._speechController?.transcript??""}get _isButtonDisabled(){return this._resolvedMode==="disabled"||this.awaitingResponse||this._state==="processing"}get _buttonLabel(){if(this.awaitingResponse)return"Voice input unavailable while assistant is responding";if(this._resolvedMode==="disabled")return"Voice input unavailable";switch(this._state){case"error":return this._errorCode==="not-allowed"?"Microphone permission denied. Retry voice input":"Retry voice input";case"listening":return"Stop voice input";case"processing":return"Processing voice input";default:return"Start voice input"}}clearDraftSession(){this.#t=null}loaded(){this.manager.onLifecycle(()=>[u(()=>[this.mode,this.language],()=>{this._configureController()},{initial:!0}),u(()=>this.awaitingResponse,t=>{t&&this._cancelActiveSession()},{initial:!0}),u(()=>this._liveTranscript,t=>{if(t){let s=h(`${this._transcript} ${t}`);this.arcgisVoiceInputInterimTranscription.emit({transcript:s}),this._applyVoiceInputTranscript(s)}}),u(()=>this._transcript,t=>{t&&(this.arcgisVoiceInputTranscription.emit({transcript:t}),this._applyVoiceInputTranscript(t,{final:!0}))}),u(()=>this._state,t=>{t==="error"&&this._errorCode&&this.arcgisVoiceInputError.emit({errorCode:this._errorCode})})])}disconnectedCallback(){super.disconnectedCallback(),this._destroySpeechController()}_configureController(){let t=this._resolveMode();this._destroySpeechController(),this._resolvedMode=t,t!=="disabled"&&(this._speechController=t==="web-speech"?new _({language:this.language}):new c({language:this.language,handleRecording:this._handleRecording.bind(this)}))}_destroySpeechController(){this._speechController?.cancel(),this._speechController?.destroy(),this._speechController=void 0}_emitDraftChange(t,s){this.arcgisVoiceInputDraftChange.emit({focusInput:s?.focusInput,value:t})}_startVoiceInputSession(){this.#t={baseValue:this.inputValue.trim(),phase:"listening",transcript:""}}_finishVoiceInputSession(){let t=this.#t;if(!t){this._emitDraftChange(this.inputValue.trim());return}let s={...t,phase:"stopped"},i=b(s);this.#t=s,this._emitDraftChange(i)}async _applyVoiceInputTranscript(t,s){let i=this.#t;if(!t||!i)return;if(i.phase==="stopped"){let o=b(i);if(this.inputValue.trim()!==o){this.clearDraftSession();return}}let r={...i,transcript:t},n=b(r);this.#t=r,this._emitDraftChange(n,{focusInput:s?.final&&r.phase==="stopped"})}async _handleToggle(){if(!(this._isButtonDisabled||!this._speechController)){if(this._state==="listening"){this._speechController.stop(),this._finishVoiceInputSession(),this.arcgisVoiceInputStop.emit();return}this._speechController.start(),this._startVoiceInputSession(),this.arcgisVoiceInputStart.emit()}}async _handleRecording(t,s,i,r){let n;return this.arcgisVoiceInputTranscriptionStreamChunk.emit({blob:t,chunkIndex:i,isFinal:r,mimeType:s,respondWithTranscript:o=>{n=o}}),n}_resolveMode(){return this.mode==="disabled"?"disabled":this.mode==="web-speech"&&_.isSupported()?"web-speech":c.isSupported()?"media-recorder":"disabled"}async _cancelActiveSession(){this._speechController&&this._resolvedMode!=="disabled"&&this._speechController.cancel(),this.clearDraftSession()}render(){return S`<calcite-button appearance=transparent class="button" data-mode=${this._resolvedMode??m} data-state=${(this._resolvedMode==="disabled"?"disabled":this._state)??m} .disabled=${this._isButtonDisabled} icon-start=microphone kind=neutral .label=${this._buttonLabel} .loading=${this._state==="processing"} round scale=m @click=${()=>{this._handleToggle()}}></calcite-button>`}};y("arcgis-assistant-speech-input",v);return v},"core/reactiveUtils","core/Accessor","core/accessorSupport/decorators")
2
+ import{g as C,h as S,n as l,v as R,w as m,y}from"./GW636L6T.js";import"./CFDTXKJ6.js";export default $arcgis.t(([{when:k,watch:u},I,{property:d,subclass:f}])=>{var T=C`.button{--calcite-button-background-color: var(--calcite-color-transparent);--calcite-button-border-color: transparent;--calcite-button-icon-color: var(--calcite-color-text-3);--calcite-button-text-color: var(--calcite-color-text-3);flex:0 0 auto;position:relative}.button[data-state=disabled]{--calcite-button-icon-color: var(--calcite-color-text-3);opacity:var(--calcite-opacity-disabled)}.button[data-state=listening]{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-brand) 14%, var(--calcite-color-foreground-1) );--calcite-button-border-color: color-mix(in srgb, var(--calcite-color-brand) 24%, transparent);--calcite-button-icon-color: var(--calcite-color-brand);--calcite-button-text-color: var(--calcite-color-brand);box-shadow:var(--calcite-shadow-sm)}.button[data-state=listening]:hover{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-brand-hover, var(--calcite-color-brand)) 18%, var(--calcite-color-foreground-1) )}.button[data-state=listening]:active{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-brand) 24%, var(--calcite-color-foreground-1) )}.button[data-state=processing]{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-brand) 10%, var(--calcite-color-foreground-1) );--calcite-button-border-color: color-mix(in srgb, var(--calcite-color-brand) 20%, transparent);--calcite-button-icon-color: var(--calcite-color-brand);--calcite-button-text-color: var(--calcite-color-brand)}.button[data-state=error]{--calcite-button-background-color: color-mix( in srgb, var(--calcite-color-status-danger) 12%, var(--calcite-color-foreground-1) );--calcite-button-border-color: color-mix(in srgb, var(--calcite-color-status-danger) 24%, transparent);--calcite-button-icon-color: var(--calcite-color-status-danger);--calcite-button-text-color: var(--calcite-color-status-danger)}.button[data-state=listening]:after{content:"";position:absolute;inset:-4px;border:1px solid color-mix(in srgb,var(--calcite-color-brand) 40%,transparent);border-radius:inherit;opacity:0;pointer-events:none;transform:scale(.92);animation:assistant-speech-input-recording-pulse 1.8s ease-out infinite}@keyframes assistant-speech-input-recording-pulse{0%{opacity:.65;transform:scale(.92)}70%{opacity:0;transform:scale(1.16)}to{opacity:0;transform:scale(1.16)}}@media(prefers-reduced-motion){.button[data-state=listening]:after{animation:none}}`,x=Object.defineProperty,V=Object.getOwnPropertyDescriptor,p=(e,t,s,i)=>{for(var r=i>1?void 0:i?V(t,s):t,n=e.length-1,o;n>=0;n--)(o=e[n])&&(r=(i?o(t,s,r):o(r))||r);return i&&r&&x(t,s,r),r},a=class extends I{constructor(e){super(e),this.state="idle",this.liveTranscript="",this.transcript="",this.errorCode=void 0}static isSupported(){return!1}};p([d()],a.prototype,"language",2);p([d({readOnly:!0})],a.prototype,"state",2);p([d({readOnly:!0})],a.prototype,"liveTranscript",2);p([d({readOnly:!0})],a.prototype,"transcript",2);p([d({readOnly:!0})],a.prototype,"errorCode",2);a=p([f("SpeechController")],a);var O=["audio/webm;codecs=opus","audio/webm","audio/mp4","audio/ogg;codecs=opus","audio/ogg"];function h(e){return e.replace(/\s+/gu," ").trim()}var M=Object.defineProperty,D=Object.getOwnPropertyDescriptor,g=(e,t,s,i)=>{for(var r=i>1?void 0:i?D(t,s):t,n=e.length-1,o;n>=0;n--)(o=e[n])&&(r=(i?o(t,s,r):o(r))||r);return i&&r&&M(t,s,r),r},c=class extends a{constructor(e){super(e),this._activeSessionId=null,this._mediaRecorder=null,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._mediaStream=null,this._pendingChunkOperations=new Set,this._recordedChunks=[],this.handleRecording=null,this.chunkTimeSlice=3e3}get _mimeType(){return typeof window>"u"||typeof window.MediaRecorder?.isTypeSupported!="function"?"":O.find(e=>window.MediaRecorder.isTypeSupported(e))??""}initialize(){c.isSupported()&&this.addHandles(k(()=>!!this.errorCode,()=>{this._set("state","error")}))}destroy(){this._mediaRecorder&&(this._mediaRecorder.onstart=null,this._mediaRecorder.ondataavailable=null,this._mediaRecorder.onerror=null,this._mediaRecorder.onstop=null),this.cancel(),this._mediaRecorder=null}_queuePendingChunkOperation(e){this._pendingChunkOperations.add(e),e.finally(()=>{this._pendingChunkOperations.delete(e)})}async _awaitPendingChunkOperations(){this._pendingChunkOperations.size&&await Promise.allSettled(Array.from(this._pendingChunkOperations))}_onDataAvailable(e){let t=this._activeSessionId;t!=null&&this._queuePendingChunkOperation(this._processDataAvailable(e,t))}async _processDataAvailable(e,t){let s=e.data;if(!s.size||t!==this._activeSessionId)return;this._recordedChunks.push(s);let i=s.type||this._mediaRecorder?.mimeType||this._mimeType,r=this._mediaRecorderStopReason==="toggle"&&this._mediaRecorder?.state==="inactive";try{if(!this.handleRecording)return;let n=h(await this.handleRecording(s,i,this._mediaRecorderChunkIndex,r)??"");if(t!==this._activeSessionId)return;n&&this._set("liveTranscript",h(`${this.liveTranscript} ${n}`))}catch(n){if(t!==this._activeSessionId)return;this._failSession(n instanceof Error&&n.message==="transcription-unavailable"?"transcription-unavailable":"transcription-failed");return}!r&&t===this._activeSessionId&&(this._mediaRecorderChunkIndex+=1)}_failSession(e){let t=this._mediaRecorder;if(t){t.onstart=null,t.ondataavailable=null,t.onerror=null,t.onstop=null;try{t.state!=="inactive"&&t.stop()}catch{}}this._activeSessionId=null,this._mediaRecorder=null,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._releaseMediaStream(),this._set("liveTranscript",""),this._set("transcript",""),this._set("errorCode",e)}_onError(){this._failSession("recording-failed")}_onStart(){this._set("state","listening")}_onStop(){this._handleStop()}_releaseMediaStream(){this._mediaStream?.getTracks().forEach(e=>e.stop()),this._mediaStream=null}async _handleStop(){let e=this._mediaRecorder,t=this._activeSessionId,s=this._mediaRecorderStopReason,i=e?.mimeType||this._recordedChunks.find(n=>!!n.type)?.type||"",r=[...this._recordedChunks];if(this._mediaRecorder=null,this._mediaRecorderChunkIndex=0,this._releaseMediaStream(),s==="cancel"){this._activeSessionId===t&&(this._activeSessionId=null),this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._set("liveTranscript",""),this._set("transcript",""),this._set("state","idle"),this._set("errorCode",void 0);return}if(t==null){this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._set("state","idle"),this._set("errorCode",void 0);return}if(await this._awaitPendingChunkOperations(),t===this._activeSessionId){if(!(i?new Blob(r,{type:i}):new Blob(r)).size){this._activeSessionId===t&&(this._activeSessionId=null),this._mediaRecorderStopReason=null,this._recordedChunks=[],this._set("errorCode","recording-failed");return}this._set("state","processing"),this._set("transcript",h(`${this.transcript} ${this.liveTranscript}`)),this._set("liveTranscript",""),this._activeSessionId===t&&(this._activeSessionId=null),this._set("state","idle"),this._set("errorCode",void 0),this._mediaRecorderStopReason=null,this._recordedChunks=[]}}start(){if(!c.isSupported()){this._set("errorCode","not-supported");return}let e=Date.now();this._activeSessionId=e,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._set("liveTranscript",""),this._set("transcript",""),this._set("errorCode",void 0),navigator.mediaDevices.getUserMedia({audio:!0}).then(t=>{if(e!==this._activeSessionId){t.getTracks().forEach(r=>r.stop());return}let s=this._mimeType,i=s?new window.MediaRecorder(t,{mimeType:s}):new window.MediaRecorder(t);this._mediaStream=t,this._mediaRecorder=i,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._recordedChunks=[],i.ondataavailable=this._onDataAvailable.bind(this),i.onerror=this._onError.bind(this),i.onstart=this._onStart.bind(this),i.onstop=this._onStop.bind(this),this._mediaRecorder.start(this.chunkTimeSlice)}).catch(t=>{e===this._activeSessionId&&(this._activeSessionId=null,this._mediaRecorder=null,this._mediaRecorderChunkIndex=0,this._mediaRecorderStopReason=null,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._releaseMediaStream(),t instanceof DOMException&&t.name==="NotAllowedError"?this._set("errorCode","not-allowed"):this._set("errorCode","recording-failed"))})}stop(){if(this._mediaRecorder){this._mediaRecorderStopReason="toggle";try{this._mediaRecorder.state!=="inactive"?this._mediaRecorder.stop():this._handleStop()}catch{}}}cancel(){let e=this._mediaRecorder;if(this._activeSessionId=null,this._mediaRecorderStopReason="cancel",this._mediaRecorderChunkIndex=0,this._pendingChunkOperations.clear(),this._recordedChunks=[],this._set("liveTranscript",""),this._set("transcript",""),this._set("state","idle"),this._set("errorCode",void 0),!e){this._releaseMediaStream();return}try{if(e.state!=="inactive"){e.stop();return}}catch{}this._mediaRecorder=null,this._releaseMediaStream()}static isSupported(){return typeof window<"u"&&!!(window.MediaRecorder&&navigator.mediaDevices?.getUserMedia)}};g([d()],c.prototype,"_mimeType",1);g([d()],c.prototype,"handleRecording",2);g([d()],c.prototype,"chunkTimeSlice",2);c=g([f("MediaRecorderController")],c);var $=Object.getOwnPropertyDescriptor,E=(e,t,s,i)=>{for(var r=i>1?void 0:i?$(t,s):t,n=e.length-1,o;n>=0;n--)(o=e[n])&&(r=o(r)||r);return r};function w(){if(typeof window>"u")return null;let e=window;return e.SpeechRecognition??e.webkitSpeechRecognition??null}var _=class extends a{constructor(e){super(e),this._isCancelled=!1,this._recognition=null}initialize(){let e=w();if(!e)return;let t=new e;t.continuous=!0,t.interimResults=!0,this.language&&(t.lang=this.language),t.onstart=this._onStart.bind(this),t.onresult=this._onResult.bind(this),t.onerror=this._onError.bind(this),t.onend=this._onEnd.bind(this),t.onspeechend=this._onSpeechEnd.bind(this),this._recognition=t,this.addHandles(k(()=>!!this.errorCode,()=>{this._set("state","error")}))}destroy(){this._recognition&&(this._recognition.onstart=null,this._recognition.onresult=null,this._recognition.onerror=null,this._recognition.onend=null,this._recognition.onspeechend=null,this.cancel(),this._recognition=null)}_onStart(){this._isCancelled=!1,this._set("state","listening")}_onResult(e){let{finalTranscript:t,liveTranscript:s}=Array.from(e.results).reduce((i,r)=>(r.isFinal?i.finalTranscript+=r[0].transcript:i.liveTranscript+=r[0].transcript,i),{finalTranscript:"",liveTranscript:""});this._set("transcript",h(t)),this._set("liveTranscript",h(s))}_onError(e){if(e.error==="aborted"&&this._isCancelled){this._set("state","idle");return}let t="unhandled";switch(e.error){case"no-speech":t="no-speech";break;case"service-not-allowed":case"not-allowed":t="not-allowed";break;default:t="unhandled"}this._set("errorCode",t)}_onEnd(){let e=h(`${this.transcript} ${this.liveTranscript}`);if(this._set("liveTranscript",""),this._isCancelled){this._set("transcript",""),this._set("state","idle"),this._set("errorCode",void 0);return}this.errorCode?this._set("transcript",""):(this._set("transcript",e),this._set("state","idle")),this._set("errorCode",void 0)}_onSpeechEnd(){this._set("state","processing")}_reset(e=!1){this._isCancelled=e,this._set("liveTranscript",""),this._set("transcript",""),this._set("errorCode",void 0),this._set("state","idle")}start(){if(!this._recognition){this._set("errorCode","not-supported");return}this._reset(!1);try{this._recognition.start()}catch{this._set("errorCode","unhandled")}}stop(){if(this._recognition){this._set("state","processing");try{this._recognition.stop()}catch{}}}cancel(){if(this._recognition){this._reset(!0);try{this._recognition.abort()}catch{}}}static isSupported(){return!!w()}};_=E([f("WebSpeechController")],_);function b(e){let{baseValue:t,transcript:s}=e;if(!s)return t;let i=t.trim();return i?`${i} ${s}`:s}var v=class extends R{constructor(){super(...arguments),this.#t=null,this._resolvedMode="disabled",this.awaitingResponse=!1,this.inputValue="",this.mode="web-speech",this.arcgisVoiceInputDraftChange=l(),this.arcgisVoiceInputError=l(),this.arcgisVoiceInputInterimTranscription=l(),this.arcgisVoiceInputStart=l(),this.arcgisVoiceInputStop=l(),this.arcgisVoiceInputTranscription=l(),this.arcgisVoiceInputTranscriptionStreamChunk=l()}static{this.properties={_resolvedMode:16,_state:16,_errorCode:16,_liveTranscript:16,_transcript:16,_isButtonDisabled:16,_buttonLabel:16,awaitingResponse:5,inputValue:1,language:1,mode:1}}static{this.styles=T}#t;get _state(){return this._speechController?.state??"idle"}get _errorCode(){return this._speechController?.errorCode??null}get _liveTranscript(){return this._speechController?.liveTranscript??""}get _transcript(){return this._speechController?.transcript??""}get _isButtonDisabled(){return this._resolvedMode==="disabled"||this.awaitingResponse||this._state==="processing"}get _buttonLabel(){if(this.awaitingResponse)return"Voice input unavailable while assistant is responding";if(this._resolvedMode==="disabled")return"Voice input unavailable";switch(this._state){case"error":return this._errorCode==="not-allowed"?"Microphone permission denied. Retry voice input":"Retry voice input";case"listening":return"Stop voice input";case"processing":return"Processing voice input";default:return"Start voice input"}}clearDraftSession(){this.#t=null}loaded(){this.manager.onLifecycle(()=>[u(()=>[this.mode,this.language],()=>{this._configureController()},{initial:!0}),u(()=>this.awaitingResponse,t=>{t&&this._cancelActiveSession()},{initial:!0}),u(()=>this._liveTranscript,t=>{if(t){let s=h(`${this._transcript} ${t}`);this.arcgisVoiceInputInterimTranscription.emit({transcript:s}),this._applyVoiceInputTranscript(s)}}),u(()=>this._transcript,t=>{t&&(this.arcgisVoiceInputTranscription.emit({transcript:t}),this._applyVoiceInputTranscript(t,{final:!0}))}),u(()=>this._state,t=>{t==="error"&&this._errorCode&&this.arcgisVoiceInputError.emit({errorCode:this._errorCode})})])}disconnectedCallback(){super.disconnectedCallback(),this._destroySpeechController()}_configureController(){let t=this._resolveMode();this._destroySpeechController(),this._resolvedMode=t,t!=="disabled"&&(this._speechController=t==="web-speech"?new _({language:this.language}):new c({language:this.language,handleRecording:this._handleRecording.bind(this)}))}_destroySpeechController(){this._speechController?.cancel(),this._speechController?.destroy(),this._speechController=void 0}_emitDraftChange(t,s){this.arcgisVoiceInputDraftChange.emit({focusInput:s?.focusInput,value:t})}_startVoiceInputSession(){this.#t={baseValue:this.inputValue.trim(),phase:"listening",transcript:""}}_finishVoiceInputSession(){let t=this.#t;if(!t){this._emitDraftChange(this.inputValue.trim());return}let s={...t,phase:"stopped"},i=b(s);this.#t=s,this._emitDraftChange(i)}async _applyVoiceInputTranscript(t,s){let i=this.#t;if(!t||!i)return;if(i.phase==="stopped"){let o=b(i);if(this.inputValue.trim()!==o){this.clearDraftSession();return}}let r={...i,transcript:t},n=b(r);this.#t=r,this._emitDraftChange(n,{focusInput:s?.final&&r.phase==="stopped"})}async _handleToggle(){if(!(this._isButtonDisabled||!this._speechController)){if(this._state==="listening"){this._speechController.stop(),this._finishVoiceInputSession(),this.arcgisVoiceInputStop.emit();return}this._speechController.start(),this._startVoiceInputSession(),this.arcgisVoiceInputStart.emit()}}async _handleRecording(t,s,i,r){let n;return this.arcgisVoiceInputTranscriptionStreamChunk.emit({blob:t,chunkIndex:i,isFinal:r,mimeType:s,respondWithTranscript:o=>{n=o}}),n}_resolveMode(){return this.mode==="disabled"?"disabled":this.mode==="web-speech"&&_.isSupported()?"web-speech":c.isSupported()?"media-recorder":"disabled"}async _cancelActiveSession(){this._speechController&&this._resolvedMode!=="disabled"&&this._speechController.cancel(),this.clearDraftSession()}render(){return S`<calcite-button appearance=transparent class="button" data-mode=${this._resolvedMode??m} data-state=${(this._resolvedMode==="disabled"?"disabled":this._state)??m} .disabled=${this._isButtonDisabled} icon-start=microphone kind=neutral .label=${this._buttonLabel} .loading=${this._state==="processing"} round scale=m @click=${()=>{this._handleToggle()}}></calcite-button>`}};y("arcgis-assistant-speech-input",v);return v},"core/reactiveUtils","core/Accessor","core/accessorSupport/decorators")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import c from"./TDBJ6YZ6.js";import b from"./2E6GEUNH.js";import"./WI3JQXAS.js";import{a as e,c as a}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as s,y as r}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";export default $arcgis.t(([,{c:i}])=>{var t=class extends s{constructor(){super(...arguments),this.agent=i}static{this.properties={referenceElement:1}}#t;getContext(){if(!this.#t)throw new Error("arcgis-assistant-layer-styling-agent requires a mapView");return{mapView:this.#t}}load(){this.#t=e(this,"arcgis-assistant-layer-styling-agent"),a(this)}};r("arcgis-assistant-layer-styling-agent",t);return t},b,c)
2
+ import c from"./TDBJ6YZ6.js";import b from"./2E6GEUNH.js";import"./WI3JQXAS.js";import{a as e,c as a}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as s,y as r}from"./GW636L6T.js";import"./CFDTXKJ6.js";export default $arcgis.t(([,{c:i}])=>{var t=class extends s{constructor(){super(...arguments),this.agent=i}static{this.properties={referenceElement:1}}#t;getContext(){if(!this.#t)throw new Error("arcgis-assistant-layer-styling-agent requires a mapView");return{mapView:this.#t}}load(){this.#t=e(this,"arcgis-assistant-layer-styling-agent"),a(this)}};r("arcgis-assistant-layer-styling-agent",t);return t},b,c)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as c}from"./KADK7ZYA.js";import"./YGW7TUNX.js";import{g as i,h as s,n as r,v as a,y as p}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";var l=i`:host{display:block;max-width:100%}.group{max-width:100%}.prompt{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-style:normal;cursor:pointer}calcite-chip{max-width:100%}`,e=class extends a{constructor(){super(...arguments),this._messages=c({blocking:!0}),this.prompts=[],this.arcgisPromptSelect=r()}static{this.properties={label:1,prompts:0}}static{this.styles=l}_emitPromptSelect(t){this.arcgisPromptSelect.emit({prompt:t})}render(){return this.prompts.length?s`<calcite-chip-group class="group" .label=${this.label??this._messages.suggestedPromptsLabel}>${this.prompts.map(t=>s`<calcite-chip .value=${t} .label=${t} appearance=outline-fill kind=brand @calciteChipSelect=${()=>this._emitPromptSelect(t)}><div class="prompt">${t}</div></calcite-chip>`)}</calcite-chip-group>`:null}};p("arcgis-assistant-suggested-prompts",e);export{e as ArcgisAssistantSuggestedPrompts};
2
+ import{a as c}from"./A2EDNDZP.js";import"./YGW7TUNX.js";import{g as i,h as s,n as r,v as a,y as p}from"./GW636L6T.js";import"./CFDTXKJ6.js";var l=i`:host{display:block;max-width:100%}.group{max-width:100%}.prompt{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-style:normal;cursor:pointer}calcite-chip{max-width:100%}`,e=class extends a{constructor(){super(...arguments),this._messages=c({blocking:!0}),this.prompts=[],this.arcgisPromptSelect=r()}static{this.properties={label:1,prompts:0}}static{this.styles=l}_emitPromptSelect(t){this.arcgisPromptSelect.emit({prompt:t})}render(){return this.prompts.length?s`<calcite-chip-group class="group" .label=${this.label??this._messages.suggestedPromptsLabel}>${this.prompts.map(t=>s`<calcite-chip .value=${t} .label=${t} appearance=outline-fill kind=brand @calciteChipSelect=${()=>this._emitPromptSelect(t)}><div class="prompt">${t}</div></calcite-chip>`)}</calcite-chip-group>`:null}};p("arcgis-assistant-suggested-prompts",e);export{e as ArcgisAssistantSuggestedPrompts};
@@ -0,0 +1,4 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
+ var Y=globalThis,Z=Y.ShadowRoot&&(Y.ShadyCSS===void 0||Y.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,gt=Symbol(),Mt=new WeakMap,M=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==gt)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o,e=this.t;if(Z&&t===void 0){let s=e!==void 0&&e.length===1;s&&(t=Mt.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&Mt.set(e,t))}return t}toString(){return this.cssText}},kt=o=>new M(typeof o=="string"?o:o+"",void 0,gt),$e=(o,...t)=>{let e=o.length===1?o[0]:t.reduce((s,r,n)=>s+(i=>{if(i._$cssResult$===!0)return i.cssText;if(typeof i=="number")return i;throw Error("Value passed to 'css' function must be a 'css' function result: "+i+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(r)+o[n+1],o[0]);return new M(e,o,gt)},jt=(o,t)=>{if(Z)o.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(let e of t){let s=document.createElement("style"),r=Y.litNonce;r!==void 0&&s.setAttribute("nonce",r),s.textContent=e.cssText,o.appendChild(s)}},vt=Z?o=>o:o=>o instanceof CSSStyleSheet?(t=>{let e="";for(let s of t.cssRules)e+=s.cssText;return kt(e)})(o):o;var{is:be,defineProperty:Ae,getOwnPropertyDescriptor:_e,getOwnPropertyNames:Ce,getOwnPropertySymbols:we,getPrototypeOf:Oe}=Object,tt=globalThis,Ht=tt.trustedTypes,Te=Ht?Ht.emptyScript:"",Se=tt.reactiveElementPolyfillSupport,k=(o,t)=>o,X={toAttribute(o,t){switch(t){case Boolean:o=o?Te:null;break;case Object:case Array:o=o==null?o:JSON.stringify(o)}return o},fromAttribute(o,t){let e=o;switch(t){case Boolean:e=o!==null;break;case Number:e=o===null?null:Number(o);break;case Object:case Array:try{e=JSON.parse(o)}catch{e=null}}return e}},j=(o,t)=>!be(o,t),zt={attribute:!0,type:String,converter:X,reflect:!1,useDefault:!1,hasChanged:j};Symbol.metadata??=Symbol("metadata"),tt.litPropertyMetadata??=new WeakMap;var A=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=zt){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){let s=Symbol(),r=this.getPropertyDescriptor(t,s,e);r!==void 0&&Ae(this.prototype,t,r)}}static getPropertyDescriptor(t,e,s){let{get:r,set:n}=_e(this.prototype,t)??{get(){return this[e]},set(i){this[e]=i}};return{get:r,set(i){let a=r?.call(this);n?.call(this,i),this.requestUpdate(t,a,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??zt}static _$Ei(){if(this.hasOwnProperty(k("elementProperties")))return;let t=Oe(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(k("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(k("properties"))){let e=this.properties,s=[...Ce(e),...we(e)];for(let r of s)this.createProperty(r,e[r])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[s,r]of e)this.elementProperties.set(s,r)}this._$Eh=new Map;for(let[e,s]of this.elementProperties){let r=this._$Eu(e,s);r!==void 0&&this._$Eh.set(r,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let s=new Set(t.flat(1/0).reverse());for(let r of s)e.unshift(vt(r))}else t!==void 0&&e.push(vt(t));return e}static _$Eu(t,e){let s=e.attribute;return s===!1?void 0:typeof s=="string"?s:typeof t=="string"?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(t=>t(this))}addController(t){(this._$EO??=new Set).add(t),this.renderRoot!==void 0&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){let t=new Map,e=this.constructor.elementProperties;for(let s of e.keys())this.hasOwnProperty(s)&&(t.set(s,this[s]),delete this[s]);t.size>0&&(this._$Ep=t)}createRenderRoot(){let t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return jt(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,e,s){this._$AK(t,s)}_$ET(t,e){let s=this.constructor.elementProperties.get(t),r=this.constructor._$Eu(t,s);if(r!==void 0&&s.reflect===!0){let n=(s.converter?.toAttribute!==void 0?s.converter:X).toAttribute(e,s.type);this._$Em=t,n==null?this.removeAttribute(r):this.setAttribute(r,n),this._$Em=null}}_$AK(t,e){let s=this.constructor,r=s._$Eh.get(t);if(r!==void 0&&this._$Em!==r){let n=s.getPropertyOptions(r),i=typeof n.converter=="function"?{fromAttribute:n.converter}:n.converter?.fromAttribute!==void 0?n.converter:X;this._$Em=r;let a=i.fromAttribute(e,n.type);this[r]=a??this._$Ej?.get(r)??a,this._$Em=null}}requestUpdate(t,e,s,r=!1,n){if(t!==void 0){let i=this.constructor;if(r===!1&&(n=this[t]),s??=i.getPropertyOptions(t),!((s.hasChanged??j)(n,e)||s.useDefault&&s.reflect&&n===this._$Ej?.get(t)&&!this.hasAttribute(i._$Eu(t,s))))return;this.C(t,e,s)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(t,e,{useDefault:s,reflect:r,wrapped:n},i){s&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,i??e??this[t]),n!==!0||i!==void 0)||(this._$AL.has(t)||(this.hasUpdated||s||(e=void 0),this._$AL.set(t,e)),r===!0&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(let[r,n]of this._$Ep)this[r]=n;this._$Ep=void 0}let s=this.constructor.elementProperties;if(s.size>0)for(let[r,n]of s){let{wrapped:i}=n,a=this[r];i!==!0||this._$AL.has(r)||a===void 0||this.C(r,void 0,n,a)}}let t=!1,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(s=>s.hostUpdate?.()),this.update(e)):this._$EM()}catch(s){throw t=!1,this._$EM(),s}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach(e=>e.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&=this._$Eq.forEach(e=>this._$ET(e,this[e])),this._$EM()}updated(t){}firstUpdated(t){}};A.elementStyles=[],A.shadowRootOptions={mode:"open"},A[k("elementProperties")]=new Map,A[k("finalized")]=new Map,Se?.({ReactiveElement:A}),(tt.reactiveElementVersions??=[]).push("2.1.2");var $t=globalThis,Vt=o=>o,et=$t.trustedTypes,Bt=et?et.createPolicy("lit-html",{createHTML:o=>o}):void 0,bt="$lit$",_=`lit$${Math.random().toFixed(9).slice(2)}$`,At="?"+_,Pe=`<${At}>`,T=document,z=()=>T.createComment(""),V=o=>o===null||typeof o!="object"&&typeof o!="function",_t=Array.isArray,Qt=o=>_t(o)||typeof o?.[Symbol.iterator]=="function",Et=`[
3
+ \f\r]`,H=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Wt=/-->/g,Ft=/>/g,w=RegExp(`>|${Et}(?:([^\\s"'>=/]+)(${Et}*=${Et}*(?:[^
4
+ \f\r"'\`<>=]|("|')|))|$)`,"g"),qt=/'/g,Gt=/"/g,Jt=/^(?:script|style|textarea|title)$/i,Ct=o=>(t,...e)=>({_$litType$:o,strings:t,values:e}),ps=Ct(1),us=Ct(2),fs=Ct(3),f=Symbol.for("lit-noChange"),d=Symbol.for("lit-nothing"),Kt=new WeakMap,O=T.createTreeWalker(T,129);function Yt(o,t){if(!_t(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return Bt!==void 0?Bt.createHTML(t):t}var Zt=(o,t)=>{let e=o.length-1,s=[],r,n=t===2?"<svg>":t===3?"<math>":"",i=H;for(let a=0;a<e;a++){let c=o[a],h,u,l=-1,m=0;for(;m<c.length&&(i.lastIndex=m,u=i.exec(c),u!==null);)m=i.lastIndex,i===H?u[1]==="!--"?i=Wt:u[1]!==void 0?i=Ft:u[2]!==void 0?(Jt.test(u[2])&&(r=RegExp("</"+u[2],"g")),i=w):u[3]!==void 0&&(i=w):i===w?u[0]===">"?(i=r??H,l=-1):u[1]===void 0?l=-2:(l=i.lastIndex-u[2].length,h=u[1],i=u[3]===void 0?w:u[3]==='"'?Gt:qt):i===Gt||i===qt?i=w:i===Wt||i===Ft?i=H:(i=w,r=void 0);let v=i===w&&o[a+1].startsWith("/>")?" ":"";n+=i===H?c+Pe:l>=0?(s.push(h),c.slice(0,l)+bt+c.slice(l)+_+v):c+_+(l===-2?a:v)}return[Yt(o,n+(o[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),s]},B=class o{constructor({strings:t,_$litType$:e},s){let r;this.parts=[];let n=0,i=0,a=t.length-1,c=this.parts,[h,u]=Zt(t,e);if(this.el=o.createElement(h,s),O.currentNode=this.el.content,e===2||e===3){let l=this.el.content.firstChild;l.replaceWith(...l.childNodes)}for(;(r=O.nextNode())!==null&&c.length<a;){if(r.nodeType===1){if(r.hasAttributes())for(let l of r.getAttributeNames())if(l.endsWith(bt)){let m=u[i++],v=r.getAttribute(l).split(_),C=/([.?@])?(.*)/.exec(m);c.push({type:1,index:n,name:C[2],strings:v,ctor:C[1]==="."?ot:C[1]==="?"?rt:C[1]==="@"?nt:P}),r.removeAttribute(l)}else l.startsWith(_)&&(c.push({type:6,index:n}),r.removeAttribute(l));if(Jt.test(r.tagName)){let l=r.textContent.split(_),m=l.length-1;if(m>0){r.textContent=et?et.emptyScript:"";for(let v=0;v<m;v++)r.append(l[v],z()),O.nextNode(),c.push({type:2,index:++n});r.append(l[m],z())}}}else if(r.nodeType===8)if(r.data===At)c.push({type:2,index:n});else{let l=-1;for(;(l=r.data.indexOf(_,l+1))!==-1;)c.push({type:7,index:n}),l+=_.length-1}n++}}static createElement(t,e){let s=T.createElement("template");return s.innerHTML=t,s}};function S(o,t,e=o,s){if(t===f)return t;let r=s!==void 0?e._$Co?.[s]:e._$Cl,n=V(t)?void 0:t._$litDirective$;return r?.constructor!==n&&(r?._$AO?.(!1),n===void 0?r=void 0:(r=new n(o),r._$AT(o,e,s)),s!==void 0?(e._$Co??=[])[s]=r:e._$Cl=r),r!==void 0&&(t=S(o,r._$AS(o,t.values),r,s)),t}var st=class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){let{el:{content:e},parts:s}=this._$AD,r=(t?.creationScope??T).importNode(e,!0);O.currentNode=r;let n=O.nextNode(),i=0,a=0,c=s[0];for(;c!==void 0;){if(i===c.index){let h;c.type===2?h=new L(n,n.nextSibling,this,t):c.type===1?h=new c.ctor(n,c.name,c.strings,this,t):c.type===6&&(h=new it(n,this,t)),this._$AV.push(h),c=s[++a]}i!==c?.index&&(n=O.nextNode(),i++)}return O.currentNode=T,r}p(t){let e=0;for(let s of this._$AV)s!==void 0&&(s.strings!==void 0?(s._$AI(t,s,e),e+=s.strings.length-2):s._$AI(t[e])),e++}},L=class o{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,s,r){this.type=2,this._$AH=d,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=r,this._$Cv=r?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&t?.nodeType===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=S(this,t,e),V(t)?t===d||t==null||t===""?(this._$AH!==d&&this._$AR(),this._$AH=d):t!==this._$AH&&t!==f&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Qt(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==d&&V(this._$AH)?this._$AA.nextSibling.data=t:this.T(T.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:s}=t,r=typeof s=="number"?this._$AC(t):(s.el===void 0&&(s.el=B.createElement(Yt(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===r)this._$AH.p(e);else{let n=new st(r,this),i=n.u(this.options);n.p(e),this.T(i),this._$AH=n}}_$AC(t){let e=Kt.get(t.strings);return e===void 0&&Kt.set(t.strings,e=new B(t)),e}k(t){_t(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,s,r=0;for(let n of t)r===e.length?e.push(s=new o(this.O(z()),this.O(z()),this,this.options)):s=e[r],s._$AI(n),r++;r<e.length&&(this._$AR(s&&s._$AB.nextSibling,r),e.length=r)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){let s=Vt(t).nextSibling;Vt(t).remove(),t=s}}setConnected(t){this._$AM===void 0&&(this._$Cv=t,this._$AP?.(t))}},P=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,s,r,n){this.type=1,this._$AH=d,this._$AN=void 0,this.element=t,this.name=e,this._$AM=r,this.options=n,s.length>2||s[0]!==""||s[1]!==""?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=d}_$AI(t,e=this,s,r){let n=this.strings,i=!1;if(n===void 0)t=S(this,t,e,0),i=!V(t)||t!==this._$AH&&t!==f,i&&(this._$AH=t);else{let a=t,c,h;for(t=n[0],c=0;c<n.length-1;c++)h=S(this,a[s+c],e,c),h===f&&(h=this._$AH[c]),i||=!V(h)||h!==this._$AH[c],h===d?t=d:t!==d&&(t+=(h??"")+n[c+1]),this._$AH[c]=h}i&&!r&&this.j(t)}j(t){t===d?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},ot=class extends P{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===d?void 0:t}},rt=class extends P{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==d)}},nt=class extends P{constructor(t,e,s,r,n){super(t,e,s,r,n),this.type=5}_$AI(t,e=this){if((t=S(this,t,e,0)??d)===f)return;let s=this._$AH,r=t===d&&s!==d||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,n=t!==d&&(s===d||r);r&&this.element.removeEventListener(this.name,this,s),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},it=class{constructor(t,e,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){S(this,t)}},Xt={M:bt,P:_,A:At,C:1,L:Zt,R:st,D:Qt,V:S,I:L,H:P,N:rt,U:nt,B:ot,F:it},Ne=$t.litHtmlPolyfillSupport;Ne?.(B,L),($t.litHtmlVersions??=[]).push("3.3.2");var wt=(o,t,e)=>{let s=e?.renderBefore??t,r=s._$litPart$;if(r===void 0){let n=e?.renderBefore??null;s._$litPart$=r=new L(t.insertBefore(z(),n),n,void 0,e??{})}return r._$AI(o),r};var Ot=globalThis,E=class extends A{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){let t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=wt(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return f}};E._$litElement$=!0,E.finalized=!0,Ot.litElementHydrateSupport?.({LitElement:E});var De=Ot.litElementPolyfillSupport;De?.({LitElement:E});(Ot.litElementVersions??=[]).push("4.2.2");var te=new Set,ee;var se=o=>typeof o=="string"?o:"el"in o?o.el.localName:"localName"in o?o.localName:o.declaredClass,Ts=(o,t,e,s)=>{let r=se(t);if(s?.once){let i=`${o}${r}${e}`;if(te.has(i))return;te.add(i)}let n;if(s?.detail){n={};for(let[i,a]of Object.entries(s.detail))if((typeof a=="object"||typeof a=="function")&&a!==null){let c=new WeakRef(a);Object.defineProperty(n,i,{get(){return c.deref()}})}else n[i]=a;ee?.log.interceptors?.forEach(i=>i(o,r,e,n)),console[o](`[${r}]: ${e}`,n)}else ee?.log.interceptors?.forEach(i=>i(o,r,e)),console[o](`[${r}]: ${e}`)},oe=o=>{let t=`[${se(o)}] `;return e=>{let s=e instanceof Error&&e.message?e:new Error(String(e));s.message=`${t}${s.message}`,setTimeout(()=>{throw e})}};var p=(o,t,...e)=>{try{return o?.call(t,...e)}catch(s){console.error(s,o)}},W=async(o,t,...e)=>{try{return await o?.call(t,...e)}catch(s){console.error(s,o)}};var q=Symbol.for("controller"),xe=o=>typeof o=="object"&&o!==null&&(q in o||"hostConnected"in o||"hostDisconnected"in o||"hostUpdate"in o||"hostUpdated"in o),Ns=o=>typeof o?.then=="function";var F,D=o=>{F!==o&&(F=o,queueMicrotask(()=>F===o?F=void 0:0))},G=o=>F,N=[],re=o=>{if(o===void 0){N=[];return}let t=N.indexOf(o);N=t===-1?[...N,o]:N.slice(0,t+1),queueMicrotask(()=>N=[])},ne=()=>N,U,Ds=o=>{U!==o&&(U=o,queueMicrotask(()=>U===o?U=void 0:0))},Le=()=>{let o=U;return U=void 0,o},ie=async(o,t)=>{let e=ct(o);if(e===void 0)return o;if(await e.ready,typeof t=="function"){let s=e.watchExports(r=>t(r,s))}return e.exports},ae=async o=>{let t=ct(o);return await t.ready,t},ct=o=>{let e=G().manager.X(o);if(e!==void 0)return e;if(xe(o))return o;let s=Le();if(s!==void 0)return s},at=!1,xs=o=>{at=!0;try{return o()}finally{at=!1}};var b=class{constructor(){this.promise=new Promise((t,e)=>{this.resolve=t,this.reject=e})}};var ce=(o,t)=>{let e=t>Ue?Re:t/Ie,s=0,r=setInterval(()=>{s+=e,s>=t&&(clearInterval(r),o())},e);return r},Ue=4e3,Re=2e3,Ie=4;var Me=(o,t,e)=>{let s=Object.keys(o),r=s.length;R===void 0&&queueMicrotask(I),R??=new Map;let n=R.get(o);return n===void 0&&(n={callbacks:[],keyCount:r},R.set(o,n)),n.keyCount!==r&&(n.callbacks.forEach(i=>i(s)),n.callbacks=[],n.keyCount=r),n.callbacks.push(i=>{let a=h=>p(t,null,h),c=i[r];c===void 0?a(void 0):o[c]===e?a(c):a(void 0)}),e},R,I=()=>{R?.forEach(({callbacks:o},t)=>{let e=Object.keys(t);o.forEach(s=>s(e))}),R=void 0},ke=(o,t,e)=>{let s=o.manager;return s.V!==d&&s.V!==e&&s.S(void 0,void 0),s.T.length===0&&queueMicrotask(()=>s.S(void 0,void 0)),s.V=e,s.T.push((r,n)=>p(t,void 0,e===n?r:void 0)),e},je=(o=[G(),...ne()],t,e)=>{let s=Array.isArray(o)?o:[o],r=s.length+1,n=i=>{r-=1,i!==void 0&&(r=Math.min(r,0)),r===0&&t(i)};s.forEach(i=>Me(i,a=>n(a===void 0?void 0:{key:a,host:i,isReactive:!1}),e));for(let i of s)if("manager"in i&&i.manager.component===i){ke(i,a=>n(a===void 0?void 0:{key:a,host:i,isReactive:!0}),e);break}return e},He=(o="",t={},e=G())=>{let s={emit:r=>{o===""&&I();let n=new CustomEvent(o,{detail:r,cancelable:!0,bubbles:!0,composed:!0,...t});return e.el.dispatchEvent(n),n}};return o===""&&je(void 0,r=>o=r.key,s),s},ze=He.bind(null,""),de;de=q;var Tt=class{constructor(t){this.#t=[],this.#e=[],this.#s=[],this.#r=[],this.#n=[],this.#c=[],this.#l=[],this.#d=[],this.#i=[],this.#p=!1,this.P=new b,this.connectedCalled=!1,this.loadedCalled=!1,this[de]=!0,this.#h=[];let e=this,s=t??G(new.target.name);e.#o=s,e.ready=e.P.promise,e.#a=he(e),e.component=s,e.#o.addController(e),e.#o.manager===void 0||(re(e),queueMicrotask(()=>e.catchUpLifecycle()))}#t;#e;#s;#r;#n;#c;#l;#d;#i;#p;#o;catchUpLifecycle(){let{manager:t}=this.#o;t.connectedCalled&&!this.connectedCalled&&this.triggerConnected(),t.#p&&this.triggerLoad().then(()=>t.loadedCalled&&this.triggerLoaded()).catch(oe(this.#o))}#a;get exports(){return this.#a}set exports(t){let e=this.#a;e!==t&&(this.#a=t,this.#h.forEach(p),this.connectedCalled&&this.O!==!1&&this.#o.requestUpdate(this.O,e)),this.P.resolve(t)}setProvisionalExports(t,e=!0){this.#a=e?he(t):t,this.#h.forEach(p)}#h;watchExports(t){let e=()=>t(this.#a);return this.#h.push(e),()=>{this.#h.splice(this.#h.indexOf(e),1)}}get use(){return D(this.#o),ie}get useRef(){return D(this.#o),ae}get useRefSync(){return D(this.#o),ct}controllerRemoved(){this.#o.el.isConnected&&this.triggerDisconnected(),this.triggerDestroy()}onConnected(t){this.#t.push(t)}onDisconnected(t){this.#e.push(t)}onLoad(t){this.#s.push(t)}onLoaded(t){this.#r.push(t)}onUpdate(t){this.#n.push(t)}onUpdated(t){this.#c.push(t)}onDestroy(t){this.#l.push(t)}onLifecycle(t){this.#d.push(t),this.connectedCalled&&this.#o.el.isConnected&&this.#u(t)}triggerConnected(){let t=this;t.hostConnected&&p(t.hostConnected,t),t.#t.forEach(p),t.triggerLifecycle(),t.connectedCalled=!0}triggerDisconnected(){let t=this;t.hostDisconnected&&p(t.hostDisconnected,t),t.#e.forEach(p),t.#i.forEach(p),t.#i=[]}async triggerLoad(){if(this.#p)return;this.#p=!0;let t=this;t.hostLoad&&await W(t.hostLoad,t),this.#s.length>0&&await Promise.allSettled(this.#s.map(W)),this.P.resolve(this.#a)}triggerLoaded(){this.loadedCalled||(this.hostLoaded&&p(this.hostLoaded,this),this.#r.forEach(p),this.loadedCalled=!0)}triggerUpdate(t){this.hostUpdate&&p(this.hostUpdate,this,t),this.#n.forEach(le,t)}triggerUpdated(t){this.hostUpdated&&p(this.hostUpdated,this,t),this.#c.forEach(le,t)}triggerDestroy(){this.hostDestroy&&p(this.hostDestroy,this),this.#l.forEach(p)}triggerLifecycle(){this.hostLifecycle&&this.#u(()=>this.hostLifecycle()),this.#d.forEach(this.#u,this)}#u(t){D(this.#o);let e=p(t);(Array.isArray(e)?e:[e]).forEach(r=>{typeof r=="function"?this.#i.push(r):typeof r=="object"&&typeof r.remove=="function"&&this.#i.push(r.remove)})}};function le(o){p(o,void 0,this)}var pe=Tt,he=o=>{if(typeof o!="object"&&typeof o!="function"||o===null)return o;let t={get(s,r,n){if(!((r==="exports"||r==="_exports")&&r in s&&s[r]===e)&&(r in s||r in Promise.prototype||typeof r=="symbol"))return typeof s=="function"?s[r]:Reflect.get(s,r,n)}},e=new Proxy(o,t);return e};var{I:Bs}=Xt;var lt=o=>o.strings===void 0;var Ve={},ue=(o,t=Ve)=>o._$AH=t;var y={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},$=o=>(...t)=>({_$litDirective$:o,values:t}),g=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,s){this._$Ct=t,this._$AM=e,this._$Ci=s}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};var K=(o,t)=>{let e=o._$AN;if(e===void 0)return!1;for(let s of e)s._$AO?.(t,!1),K(s,t);return!0},ht=o=>{let t,e;do{if((t=o._$AM)===void 0)break;e=t._$AN,e.delete(o),o=t}while(e?.size===0)},fe=o=>{for(let t;t=o._$AM;o=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(o))break;e.add(o),Fe(t)}};function Be(o){this._$AN!==void 0?(ht(this),this._$AM=o,fe(this)):this._$AM=o}function We(o,t=!1,e=0){let s=this._$AH,r=this._$AN;if(r!==void 0&&r.size!==0)if(t)if(Array.isArray(s))for(let n=e;n<s.length;n++)K(s[n],!1),ht(s[n]);else s!=null&&(K(s,!1),ht(s));else K(this,o)}var Fe=o=>{o.type==y.CHILD&&(o._$AP??=We,o._$AQ??=Be)},dt=class extends g{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,s){super._$AT(t,e,s),fe(this),this.isConnected=t._$AU}_$AO(t,e=!0){t!==this.isConnected&&(this.isConnected=t,t?this.reconnected?.():this.disconnected?.()),e&&(K(this,t),ht(this))}setValue(t){if(lt(this._$Ct))this._$Ct._$AI(t,this);else{let e=[...this._$Ct._$AH];e[this._$Ci]=t,this._$Ct._$AI(e,this,0)}}disconnected(){}reconnected(){}};var Xs=()=>new Pt,Pt=class{},St=new WeakMap,Nt=$(class extends dt{render(o){return d}update(o,[t]){let e=t!==this.G;return e&&this.G!==void 0&&this.rt(void 0),(e||this.lt!==this.ct)&&(this.G=t,this.ht=o.options?.host,this.rt(this.ct=o.element)),d}rt(o){if(this.isConnected||(o=void 0),typeof this.G=="function"){let t=this.ht??globalThis,e=St.get(t);e===void 0&&(e=new WeakMap,St.set(t,e)),e.get(this.G)!==void 0&&this.G.call(this.ht,void 0),e.set(this.G,o),o!==void 0&&this.G.call(this.ht,o)}else this.G.value=o}get lt(){return typeof this.G=="function"?St.get(this.ht??globalThis)?.get(this.G):this.G?.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}});var pt=o=>o.replace(Ge,(t,e)=>`${e===0?"":"-"}${t.toLowerCase()}`),Ge=/[A-Z]+(?![a-z])|[A-Z]/gu;var uo="randomUUID"in crypto;var xt=o=>{let t=o;for(;t=t.parentNode??t.host;)if(t?.constructor?.lumina){let e=t;return e.manager?.loadedCalled||(e.J??e._offspring).push(o),(e.I??e._postLoad).promise}return!1},Lt={};function Ut(){}function Rt(o){for(let t of["Associated","Disabled","Reset","StateRestore"]){let e=`orm${t}Callback`;o.prototype["f"+e]=async function(...s){await this.componentOnReady(),(this.el??this).dispatchEvent(new CustomEvent(`luminaF${e}`,{detail:s}))}}}var Ke=(o,t)=>function(s,r){if(!globalThis.customElements)return;let i=(r??s??{}).resourcesUrl;i&&o.setAssetPath(i);for(let[a,[c,h="",u=0]]of Object.entries(t)){if(customElements.get(a))continue;let[l,m,v]=h.split(";"),C=l?l?.split(",").map(Qe):void 0,yt=C?.map(([x])=>x),J=class extends Dt{static{this.formAssociated=u===1}static{this.observedAttributes=C?.map(([,x])=>x).filter(x=>x!=="")}static{this.C=yt}static{this.E=m?m?.split(","):void 0}static{this.D=v?.split(",")}static{this.L=a}static{this.K=o}constructor(){!J.B&&(J.B=c(),J.F()),super()}};customElements.define(a,J)}},ut=Object.defineProperty,Qe=o=>{let t=o.split(":");return t.length===1?[t[0],pt(t[0])]:t},Je=globalThis.HTMLElement??Ut,Dt=class extends Je{constructor(){super(),this.#e={},this.#s=[],this.I=new b,this.H=new b,this.J=[];let t=this,e=t.constructor;t._offspring=t.J,t._postLoad=t.I,e.C?.forEach(s=>{Object.hasOwn(t,s)&&(t.#e[s]=t[s],delete t[s])}),e.A?t.#r({a:e.A}):e.B.then(async s=>{await e.K.p,t.#r(await(s.default?.then(r=>typeof r=="function"?{a:r}:r)??s))}).catch(s=>{t.H.reject(s),setTimeout(()=>{throw s})})}static{this.lumina=!0}static F(){for(let t of this.C??[])ut(this.prototype,t,{configurable:!0,enumerable:!0,get(){return this.#e[t]},set(e){this.#e[t]=e}});for(let t of this.E??[])ut(this.prototype,t,{async value(...e){return this.#t||await this.H.promise,await this.#t[t](...e)},configurable:!0});for(let t of this.D??[])ut(this.prototype,t,{value(...e){return this.#t[t](...e)},configurable:!0})}static{Rt(this)}#t;#e;#s;get manager(){return this.#t?.manager}attributeChangedCallback(t,e,s){this.#t?.attributeChangedCallback(t,e,s),this.#t||this.#s.push(t)}connectedCallback(){this.#t?this.#t.connectedCallback?.():queueMicrotask(()=>this.G=xt(this))}disconnectedCallback(){this.#t?.disconnectedCallback?.()}async componentOnReady(){return await this.H.promise,this}#r(t){let e=this.constructor,s=e.L,r=this.#e,n=Object.values(t).find(l=>l.L===s),i=`${s}--lazy`,a=n;for(;a&&!Object.hasOwn(a,"lumina");)a=Object.getPrototypeOf(a);Ze(a),!e.A&&(e.A=n,customElements.define(i,n)),n.N=this;let h=document.createElement(i);n.N=void 0,this.#t=h,this.#e=h,this.#s.forEach(l=>h.attributeChangedCallback(l,null,this.getAttribute(l))),Object.entries(r).forEach(Ye,h);let u=this.isConnected;(u||this.G)&&(h.connectedCallback?.(),u||h.disconnectedCallback())}addController(){}requestUpdate(){this.#t?.requestUpdate()}};function Ye([o,t]){this[o]=t}var Ze=o=>{let t=o.prototype,e=Element.prototype;Object.hasOwn(t,"isConnected")||(t.setAttribute=function(r,n){e.setAttribute.call(this.el,r,n)},t.removeAttribute=function(r){e.removeAttribute.call(this.el,r)},t.hasAttribute=function(r){return e.hasAttribute.call(this.el,r)},ut(t,"isConnected",{get(){return Reflect.get(e,"isConnected",this.el)}}))};var ft=class extends pe{constructor(t){super(t),this.destroyed=!1,this.R=!1,this.V=d,this.T=[],this.#s=new WeakMap,this.#e=t,this.exports=void 0,this.hasDestroy=mt in t&&typeof t.destroy=="function",E.prototype.addController.call(t,{hostConnected:()=>{if(this.destroyed){let e=t.el.localName;throw t.el.remove(),new Error(`The ${e} component has already been destroyed. It cannot be used again. If you meant to disconnect and reconnect a component without automatic destroy, set the ${mt} prop.`)}this.#t!==void 0&&clearTimeout(this.#t),I();for(let e of t.M)"triggerConnected"in e?e.triggerConnected():p(e.hostConnected,e)},hostDisconnected:()=>{for(let e of t.M)"triggerDisconnected"in e?e.triggerDisconnected():p(e.hostDisconnected,e);this.hasDestroy&&!this.destroyed&&this.U()},hostUpdate:()=>{for(let e of t.M)"triggerUpdate"in e?e.triggerUpdate(this.Q):p(e.hostUpdate,e,this.Q)},hostUpdated:()=>{for(let e of t.M)"triggerUpdated"in e?e.triggerUpdated(this.Q):p(e.hostUpdated,e,this.Q);this.Q=void 0}}),queueMicrotask(()=>this.R=!0),D(t)}#t;#e;async destroy(){if(!this.destroyed){this.#e.el.isConnected&&(this.hasDestroy=!1,this.#e.el.remove()),this.#t=void 0,this.destroyed=!0;for(let t of this.#e.M)"triggerDestroy"in t?t.triggerDestroy():p(t.hostDestroy,t);this.#e.M.splice(0)}}U(){if(this.#t!==void 0&&clearTimeout(this.#t),!this.#e.el.isConnected&&!this.#e.autoDestroyDisabled){let t=()=>{this.#e.destroy()};this.#t=ce(t,Xe)}}S(t,e){let s=this.T;this.V=d,this.T=[],s.forEach(r=>r(t,e))}#s;W(t,e){(typeof e=="object"&&e!==null||typeof e=="function")&&this.#s.set(e,t)}X(t){if(typeof t=="object"&&t!==null||typeof t=="function")return this.#s.get(t)}},Xe=1e3,mt="autoDestroyDisabled";var ts=$(class extends g{constructor(o){if(super(o),o.type!==y.ATTRIBUTE||o.name!=="class"||o.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(o){return" "+Object.keys(o).filter(t=>o[t]).join(" ")+" "}update(o,[t]){if(this.st===void 0){this.st=new Set,o.strings!==void 0&&(this.nt=new Set(o.strings.join(" ").split(/\s/).filter(s=>s!=="")));for(let s in t)t[s]&&!this.nt?.has(s)&&this.st.add(s);return this.render(t)}let e=o.element.classList;for(let s of this.st)s in t||(e.remove(s),this.st.delete(s));for(let s in t){let r=!!t[s];r===this.st.has(s)||this.nt?.has(s)||(r?(e.add(s),this.st.add(s)):(e.remove(s),this.st.delete(s)))}return f}});var ye="important",es=" !"+ye,ss=$(class extends g{constructor(o){if(super(o),o.type!==y.ATTRIBUTE||o.name!=="style"||o.strings?.length>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}render(o){return Object.keys(o).reduce((t,e)=>{let s=o[e];return s==null?t:t+`${e=e.includes("-")?e:e.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${s};`},"")}update(o,[t]){let{style:e}=o.element;if(this.ft===void 0)return this.ft=new Set(Object.keys(t)),this.render(t);for(let s of this.ft)t[s]==null&&(this.ft.delete(s),s.includes("-")?e.removeProperty(s):e[s]=null);for(let s in t){let r=t[s];if(r!=null){this.ft.add(s);let n=typeof r=="string"&&r.endsWith(es);s.includes("-")||n?e.setProperty(s,n?r.slice(0,-11):r,n?ye:""):e[s]=r}}return f}});var os=$(class extends g{constructor(o){if(super(o),o.type!==y.PROPERTY&&o.type!==y.ATTRIBUTE&&o.type!==y.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!lt(o))throw Error("`live` bindings can only contain a single expression")}render(o){return o}update(o,[t]){if(t===f||t===d)return t;let e=o.element,s=o.name;if(o.type===y.PROPERTY){if(t===e[s])return f}else if(o.type===y.BOOLEAN_ATTRIBUTE){if(!!t===e.hasAttribute(s))return f}else if(o.type===y.ATTRIBUTE&&e.getAttribute(s)===t+"")return f;return ue(o),t}});var ge=class o extends E{constructor(){super(),this.M=[],this.manager=new ft(this);let t=this,e=t.constructor,s=e.N,r=e.K.o,n=o.prototype.shouldUpdate;t.#r=s?.H??new b,t.I=s?.I??new b,t.J=s?.J??[],t._offspring=t.J,t._postLoad=t.I,t.el=s??t,t.#s=t.enableUpdating,t.enableUpdating=Ut,t.shouldUpdate!==n&&(t.#e=t.shouldUpdate,t.shouldUpdate=n),r&&(t.#t=new Map,e.elementProperties.forEach((i,a)=>t.#t.set(a,r()))),!1}static finalizeStyles(t){let e=super.finalizeStyles(t),s=this.shadowRootOptions===Lt;return this.K?.commonStyles===void 0||s?e:[this.K.commonStyles,...e]}static createProperty(t,e){let s=typeof e=="number"?e:Array.isArray(e)?e[0]:0,r=Array.isArray(e)?e[1]:void 0,n=r?.hasChanged??j,i={attribute:s&1&&typeof t=="string"?pt(t):!1,reflect:!!(s&2),type:s&4?Boolean:s&8?Number:void 0,state:!!(s&16),readOnly:!!(s&32),noAccessor:!!(s&64),useDefault:!!(s&128),c:!1,...r,hasChanged(a,c){let h=n(a,c);return i.c=h,h}};super.createProperty(t,i)}static getPropertyDescriptor(t,e,s){let r=this.K,n=super.getPropertyDescriptor(t,e,s);return s.d=n,{...n,get(){return r.t?.(this.#t.get(t)),n.get?.call(this)},set(i){let a=this.manager;if(s.readOnly&&!at&&(a.R||a.connectedCalled))throw Error(`Cannot assign to read-only property "${t}" of ${this.el.localName}. Trying to assign "${i}"`);n.set.call(this,i??void 0),s.c&&this.#t?.get(t)?.notify(),a.T.length>0&&(I(),a?.S(t,i))}}}static{this.lumina=!0}static{Rt(this)}#t;#e;#s;#r;#n;#c;get elementInternals(){return this.#c??=this.el.attachInternals(),this.#c}connectedCallback(){this.hasAttribute("defer-hydration")||this.#l(!0)}#l(t){let e=this.constructor.K.c?.(()=>this.requestUpdate());this.#n=e;let s=!this.manager.connectedCalled;t&&super.connectedCallback(),s?queueMicrotask(()=>this.#i().catch(r=>{this.#r.reject(r),setTimeout(()=>{throw r})})):e&&this.requestUpdate()}#d(t){try{this.#n.clear(),this.constructor.K.r(this.#n,()=>super.update(t))}catch(e){throw this.#n.clear(),e}}disconnectedCallback(){super.disconnectedCallback(),this.#n?.destroy(),this.#n=void 0}createRenderRoot(){let t=this.el.shadowRoot,e=this.constructor,s=e.shadowRootOptions,n=t??(s===Lt?this.el:this.el.attachShadow(s));if(t)return this.manager.connectedCalled||this.#l(!1),E.prototype.createRenderRoot.call(this),t;if(this.isConnected){let i=n.getRootNode();i.adoptedStyleSheets=[...i.adoptedStyleSheets,...e.elementStyles.map(a=>"styleSheet"in a?a.styleSheet:a)]}return n}async#i(){let t=this.el.G??xt(this.el);t&&await t;let e=[];for(let r of this.M)"triggerLoad"in r?e.push(r.triggerLoad()):e.push(W(r.hostLoad,r));await Promise.all(e),await this.load?.(),this.manager.hasDestroy&&this.manager.onUpdate(r=>r.has(mt)&&this.manager.U()),this.#s(!0),this.performUpdate(),this.I.resolve(),await 0;let s=this.J.filter(r=>!r.manager?.loadedCalled);s.length&&await Promise.allSettled(s.map(async r=>await r.componentOnReady())),this.J.length=0,this.el.setAttribute(this.constructor.K.hydratedAttribute,"");for(let r of this.M)"triggerLoaded"in r?r.triggerLoaded():p(r.hostLoaded,r);this.loaded?.(),this.#r.resolve()}shouldUpdate(t){return this.manager.Q=t,this.#e?.(t)??!0}update(t){this.#n?this.#d(t):super.update(t)}listen(t,e,s){let r=e?.bind(this)??e;this.manager.onLifecycle(()=>(this.el.addEventListener(t,r,s),()=>this.el.removeEventListener(t,r,s)))}listenOn(t,e,s,r){let n=s?.bind(this)??s;this.manager.onLifecycle(()=>(t.addEventListener(e,n,r),()=>t.removeEventListener(e,n,r)))}async componentOnReady(){return await this.#r.promise,this}addController(t){this.M.push(t),!(q in t)&&this.renderRoot&&this.el.isConnected&&t.hostConnected?.()}removeController(t){this.M.splice(this.M.indexOf(t),1),t.controllerRemoved?.()}};var Ee=o=>{let t,e=r=>{t=new URL(r,globalThis.location?.href||void 0).href},s={...o,getAssetPath(r){let n=new URL(r,t);return n.origin!==globalThis.location?.origin?n.href:n.pathname},setAssetPath:e,customElement(r,n){n.K=s,n.L=r,customElements.get(r)||customElements.define(r,n)}};return e(o.defaultAssetPath),s};var It=class extends g{#t;#e;constructor(t){super(t);let e=this;this.#e=function(r){return e.#t.call(this,r)}}render(t){return typeof t=="function"?(this.#t=t,Nt(this.#e)):Nt(t)}},_r=$(It);var Cr=d;var Q=Ee({defaultAssetPath:"https://jsdev.arcgis.com/5.1.0-next/ai-components/",hydratedAttribute:"hydrated"}),{customElement:Pr,getAssetPath:Nr,setAssetPath:Dr}=Q;Q.t=void 0;Q.o=void 0;Q.c=void 0;Q.r=void 0;export{Ns as a,D as b,re as c,ne as d,Ds as e,xs as f,$e as g,ps as h,f as i,d as j,Ts as k,oe as l,je as m,ze as n,Tt as o,Ke as p,y as q,$ as r,g as s,Xs as t,Nt as u,ge as v,Cr as w,Q as x,Pr as y,Nr as z};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import c from"./2E6GEUNH.js";import{a as $}from"./KADK7ZYA.js";import"./WI3JQXAS.js";import{a as S}from"./KVH3PDVW.js";import"./YGW7TUNX.js";import{g as _,h as a,l as f,n as o,t as y,u as b,v as w,y as E}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";export default $arcgis.t(([P,{whenOnce:L,watch:x,when:R},O,M,{property:d,subclass:A},{d:k}])=>{var V=_`:host{display:block;width:var(--arcgis-internal-panel-width, 100%);height:var(--arcgis-internal-expand-max-height, 100%)}.footer-container{display:flex;flex-direction:column;flex:1 1 0;gap:var(--calcite-spacing-md)}.content-container{display:flex;flex-direction:column;flex:1 1 0;min-height:0;position:relative;overflow:auto}.suggested-prompts-container{display:flex;justify-content:center;width:100%}.suggested-prompts{display:block;padding:var(--calcite-spacing-md);max-width:100%;box-sizing:border-box}`,z=Object.defineProperty,j=Object.getOwnPropertyDescriptor,h=(g,t,e,i)=>{for(var s=i>1?void 0:i?j(t,e):t,r=g.length-1,n;r>=0;r--)(n=g[r])&&(s=(i?n(t,e,s):n(s))||s);return i&&s&&z(t,e,s),s},l=class extends M{constructor(g){super(g),this.view=null,this.loading=!1,this.processing=!1,this.processingStep=""}async load(){this._set("loading",!0);try{await this._initialize()}finally{this._set("loading",!1)}}destroy(){this.orchestrator?.dispose(),super.destroy()}async _initialize(){this.removeHandles(),await Promise.all([this.portal.load(),this.view?.when()]),this.view&&await L(()=>!this.view.updating),this._set("orchestrator",await k.init({agents:[...this.agents],view:this.view??void 0})),this.addHandles([x(()=>[this.view,this.agents],()=>{this._initialize()})])}clearChatHistory(){this.orchestrator?.newConversation()}async*ask(g,t){if(!this.orchestrator)throw new Error("Orchestrator not initialized yet.");this._set("processing",!0),this._set("processingStep","");let e=[],i;try{let s=this.orchestrator.ask(g);for await(let r of s){let n=r.runId;if(t?.aborted){yield{type:"cancelled",runId:n};break}switch(r.type){case"trace":{this._set("processingStep",r.data.text),e.push(r.data.text);break}case"completed":{let c=r.result,p=!!c.content.length,m=!!i?.length;if(!p&&!m){yield{type:"completed",error:"Could not process the request.",log:e,runId:n};return}let u=c.content;this._set("processingStep",""),yield{type:"completed",response:u,blocks:i,log:e,runId:n};return}case"ux-suggestion":{let c=r.suggestion;i=i?[...i,c]:[c];break}case"interrupt":{let{kind:c,message:p,metadata:m}=r.interrupt,u=Array.isArray(m)?m.filter(I=>typeof I=="string"):[],C=(()=>{switch(c){case"booleanChoice":return{type:"boolean-choice",message:p,options:u};case"singleSelection":return{type:"single-select",message:p,options:u};case"multipleSelection":return{type:"multi-select",message:p,options:u};case"textInput":return{type:"text-input",message:p};default:return{type:c,message:p,options:u}}})();this._set("processingStep","Waiting for user input..."),yield{type:"interrupt",payload:C,runId:n};break}case"cancelled":{yield{type:"cancelled",runId:n};return}case"error":{yield{type:"completed",error:r.error.message,log:e,runId:n};return}default:{console.warn("Unknown event type:",r);break}}}}catch(s){console.warn("Error during message processing:",s),yield{type:"completed",error:"An error occurred during message processing.",log:e,runId:"error"};return}finally{this._set("processing",!1)}}};h([d({readOnly:!0})],l.prototype,"orchestrator",2);h([d()],l.prototype,"agents",2);h([d()],l.prototype,"portal",2);h([d()],l.prototype,"view",2);h([d({readOnly:!0})],l.prototype,"loading",2);h([d({readOnly:!0})],l.prototype,"processing",2);h([d({readOnly:!0})],l.prototype,"processingStep",2);l=h([A("OrchestratorController")],l);var H="Embeddings resource 'embeddings-v01.json' not found in the webmap portal item.",F="Embeddings not found for this web map.",N="https://developers.arcgis.com/javascript/latest/agentic-apps/ai-webmap-setup/#embeddings",v=class extends w{constructor(){super(...arguments),this._messages=$({blocking:!0}),this.#t=y(),this.#n=y(),this.#e=y(),this.#s=null,this.#o=new Map,this.#r=O.getDefault(),this.#i=t=>{t.stopPropagation(),this.cancelInterrupt()},this.#a=t=>{t.stopPropagation();let e=t.detail;this.submitInterrupt(e)},this.#l=t=>{t.stopPropagation(),this.keepSuggestedPrompts||(this.suggestedPrompts=[]);let e=t.detail;this._inputValue="",this.arcgisSubmit.emit(e),this.submitMessage(e)},this.#c=t=>{if(t.stopPropagation(),this.arcgisCancel.emit(),this._interrupt){this.orchestrator?.cancelInterrupt(),this._interrupt=null;return}this.#s?.abort()},this.#h=t=>{t.stopPropagation();let e=t.detail;this.arcgisFeedback.emit(e)},this.#g=t=>{t.stopPropagation();let e=t.detail;this._inputValue=e.prompt,this.arcgisPromptSelect.emit(e)},this._orchestratorController=null,this._interrupt=null,this._error=null,this._inputValue="",this.messages=new P([]),this.referenceElement=null,this.suggestedPrompts=[],this.feedbackEnabled=!1,this.keepSuggestedPrompts=!1,this.logEnabled=!1,this.copyEnabled=!1,this.voiceInputEnabled=!1,this.readAloudEnabled=!1,this.arcgisCancel=o(),this.arcgisError=o(),this.arcgisFeedback=o(),this.arcgisInterrupt=o(),this.arcgisInterruptCancel=o(),this.arcgisInterruptSubmit=o(),this.arcgisPromptSelect=o(),this.arcgisReady=o(),this.arcgisSubmit=o()}static{this.properties={_orchestratorController:16,_interrupt:16,_error:16,_inputValue:16,_user:16,awaitingResponse:32,awaitingResponseStep:32,interrupt:32,messages:0,orchestrator:32,entryMessage:1,heading:1,description:1,referenceElement:1,suggestedPrompts:0,feedbackEnabled:5,keepSuggestedPrompts:5,logEnabled:5,copyEnabled:5,voiceInputEnabled:5,readAloudEnabled:5}}static{this.styles=V}#t;#n;#e;#s;#o;#r;#i;#a;#l;#c;#h;#g;async#p(){try{let t=S(this.el,this.referenceElement);await t?.componentOnReady();let e=[...this.#o.values()];return e.length?(this._orchestratorController=new l({agents:e,portal:this.#r,view:t?.view}),await this._orchestratorController.load(),!0):(this._error="No agents found.",!1)}catch(t){return this._error=t?.message??"Error initializing orchestrator.",f(this)(t),!1}}get _user(){return this.#r?.user?.fullName||this.#r?.user?.username}get awaitingResponse(){return this._orchestratorController?.processing??!1}get awaitingResponseStep(){return this._orchestratorController?.processingStep??""}get interrupt(){return this._interrupt}get orchestrator(){return this._orchestratorController?.orchestrator}async clearChatHistory(){this._reset(),this._orchestratorController?.clearChatHistory()}cancelInterrupt(){this.arcgisInterruptCancel.emit(),this.orchestrator?.cancelInterrupt(),this._interrupt=null}register(t){this.#o.set(t.agent.id,t)}async submitMessage(t){let e=t.trim();if(!e||(this.messages.push({id:Date.now().toString(),role:"user",content:e}),!this._orchestratorController))return;let i=this._orchestratorController.ask(e,this.#s?.signal);for await(let s of i){let r=s.runId;switch(s.type){case"completed":this.messages.push({role:"assistant",content:s.response,blocks:s.blocks,log:s.log,error:s.error,id:r});break;case"interrupt":this._interrupt={...s.payload,id:r},this.arcgisInterrupt.emit(this._interrupt);break;case"cancelled":this.messages.push({role:"assistant",error:"Request cancelled.",id:r});break}}}submitInterrupt(t){this.arcgisInterruptSubmit.emit(t),this.orchestrator?.resumeInterrupt(t),this._interrupt=null}load(){this.manager.onLifecycle(this._reset.bind(this))}loaded(){this.manager.onLifecycle(()=>{this.#t.value?.addEventListener("arcgisPromptSelect",this.#g),this.#t.value?.addEventListener("arcgisSubmit",this.#l),this.#t.value?.addEventListener("arcgisCancel",this.#c),this.#t.value?.addEventListener("arcgisFeedback",this.#h);let t=R(()=>!!this._interrupt&&!!this.#e.value,()=>{let e=this.#e.value;e.removeEventListener("arcgisSubmit",this.#a),e.removeEventListener("arcgisCancel",this.#i),e.addEventListener("arcgisSubmit",this.#a,{once:!0}),e.addEventListener("arcgisCancel",this.#i,{once:!0})});return queueMicrotask(()=>{this.#p().then(e=>{e?this.arcgisReady.emit():this._error&&this.arcgisError.emit(new Error(this._error))})}),()=>{t.remove(),this.#t.value?.removeEventListener("arcgisPromptSelect",this.#g),this.#e.value?.removeEventListener("arcgisSubmit",this.#a),this.#e.value?.removeEventListener("arcgisCancel",this.#i),this.#t.value?.removeEventListener("arcgisSubmit",this.#l),this.#t.value?.removeEventListener("arcgisCancel",this.#c),this.#t.value?.removeEventListener("arcgisFeedback",this.#h),this._orchestratorController?.destroy(),this._orchestratorController=null}})}_reset(){this.#s?.abort(),this._interrupt=null,this.messages.removeAll(),this._error=null,this._inputValue=""}_renderEntryMessage(){return this._interrupt?a`<slot name=interrupt><arcgis-assistant-interrupt .type=${this._interrupt.type} .message=${this._interrupt.message} .options=${this._interrupt.options} ${b(this.#e)}></arcgis-assistant-interrupt></slot>`:this._error?this._renderErrorNotice():this.entryMessage?this.messages.length>0?null:a`<calcite-notice open kind=info closable icon width=full><div slot=message>${this.entryMessage}</div></calcite-notice>`:a`<slot name=entry-message></slot>`}_renderErrorNotice(){return this._error?a`<calcite-notice closable slot=entry-message open kind=danger icon width=full>${this._error===H?a`<div slot=message>${F}</div><calcite-link slot=link .href=${N} target=_blank title="Learn about web map embeddings">Read more</calcite-link>`:a`<div slot=message>${this._error}</div>`}</calcite-notice>`:null}_renderSuggestedPrompts(){return this.suggestedPrompts?.length?a`<div class="suggested-prompts-container"><arcgis-assistant-suggested-prompts class="suggested-prompts" .prompts=${this.suggestedPrompts}></arcgis-assistant-suggested-prompts></div>`:null}render(){return a`<calcite-panel .loading=${!this._orchestratorController&&!this._error||this._orchestratorController?.loading} .heading=${this.heading??this._messages.assistantLabel} .description=${this.description} ${b(this.#t)}><slot name=header-actions-start slot=header-actions-start></slot><slot name=header-actions-end slot=header-actions-end></slot><div class="content-container"><arcgis-assistant-chat .loading=${this.awaitingResponse} .messages=${this.messages}><slot name=message-starter slot=message-starter></slot><slot name=messages slot=messages>${this.messages.map(t=>t.role==="assistant"?a`<arcgis-assistant-message .message=${t} .feedbackEnabled=${this.feedbackEnabled} .logEnabled=${this.logEnabled} .copyEnabled=${this.copyEnabled} .readAloudEnabled=${this.readAloudEnabled}></arcgis-assistant-message>`:a`<arcgis-assistant-user-message .message=${t} .user=${this._user}></arcgis-assistant-user-message>`)}</slot><slot name=message-loading slot=message-loading><arcgis-assistant-message-loading .loading=${this.awaitingResponse} .loadingMessage=${this.awaitingResponseStep}></arcgis-assistant-message-loading></slot></arcgis-assistant-chat></div>${this._renderSuggestedPrompts()}<div class="footer-container" slot=footer>${this._renderEntryMessage()}<slot name=chat-entry><arcgis-assistant-chat-entry .awaitingResponse=${this.awaitingResponse} .arcgisSubmit=${this.arcgisSubmit} .arcgisCancel=${this.arcgisCancel} .inputValue=${this._inputValue} .messages=${this.messages} .voiceInputEnabled=${this.voiceInputEnabled} ${b(this.#n)}><slot name=entry-actions-start slot=entry-actions-start></slot><slot name=entry-actions-end slot=entry-actions-end><calcite-button .iconStart=${this.awaitingResponse?"circle-stop":"send"} @click=${()=>{this.#n.value?.submitMessage()}} round>${this.awaitingResponse?this._messages.stopButtonLabel:this._messages.askButtonLabel}</calcite-button></slot></arcgis-assistant-chat-entry></slot><slot name=footer-content></slot></div></calcite-panel>`}};E("arcgis-assistant",v);return v},"core/Collection","core/reactiveUtils","portal/Portal","core/Accessor","core/accessorSupport/decorators",c)
2
+ import c from"./2E6GEUNH.js";import{a as $}from"./A2EDNDZP.js";import"./WI3JQXAS.js";import{a as S}from"./KVH3PDVW.js";import"./YGW7TUNX.js";import{g as _,h as a,l as f,n as o,t as y,u as b,v as w,y as E}from"./GW636L6T.js";import"./CFDTXKJ6.js";export default $arcgis.t(([P,{whenOnce:L,watch:x,when:R},O,M,{property:d,subclass:A},{d:k}])=>{var V=_`:host{display:block;width:var(--arcgis-internal-panel-width, 100%);height:var(--arcgis-internal-expand-max-height, 100%)}.footer-container{display:flex;flex-direction:column;flex:1 1 0;gap:var(--calcite-spacing-md)}.content-container{display:flex;flex-direction:column;flex:1 1 0;min-height:0;position:relative;overflow:auto}.suggested-prompts-container{display:flex;justify-content:center;width:100%}.suggested-prompts{display:block;padding:var(--calcite-spacing-md);max-width:100%;box-sizing:border-box}`,z=Object.defineProperty,j=Object.getOwnPropertyDescriptor,h=(g,t,e,i)=>{for(var s=i>1?void 0:i?j(t,e):t,r=g.length-1,n;r>=0;r--)(n=g[r])&&(s=(i?n(t,e,s):n(s))||s);return i&&s&&z(t,e,s),s},l=class extends M{constructor(g){super(g),this.view=null,this.loading=!1,this.processing=!1,this.processingStep=""}async load(){this._set("loading",!0);try{await this._initialize()}finally{this._set("loading",!1)}}destroy(){this.orchestrator?.dispose(),super.destroy()}async _initialize(){this.removeHandles(),await Promise.all([this.portal.load(),this.view?.when()]),this.view&&await L(()=>!this.view.updating),this._set("orchestrator",await k.init({agents:[...this.agents],view:this.view??void 0})),this.addHandles([x(()=>[this.view,this.agents],()=>{this._initialize()})])}clearChatHistory(){this.orchestrator?.newConversation()}async*ask(g,t){if(!this.orchestrator)throw new Error("Orchestrator not initialized yet.");this._set("processing",!0),this._set("processingStep","");let e=[],i;try{let s=this.orchestrator.ask(g);for await(let r of s){let n=r.runId;if(t?.aborted){yield{type:"cancelled",runId:n};break}switch(r.type){case"trace":{this._set("processingStep",r.data.text),e.push(r.data.text);break}case"completed":{let c=r.result,p=!!c.content.length,m=!!i?.length;if(!p&&!m){yield{type:"completed",error:"Could not process the request.",log:e,runId:n};return}let u=c.content;this._set("processingStep",""),yield{type:"completed",response:u,blocks:i,log:e,runId:n};return}case"ux-suggestion":{let c=r.suggestion;i=i?[...i,c]:[c];break}case"interrupt":{let{kind:c,message:p,metadata:m}=r.interrupt,u=Array.isArray(m)?m.filter(I=>typeof I=="string"):[],C=(()=>{switch(c){case"booleanChoice":return{type:"boolean-choice",message:p,options:u};case"singleSelection":return{type:"single-select",message:p,options:u};case"multipleSelection":return{type:"multi-select",message:p,options:u};case"textInput":return{type:"text-input",message:p};default:return{type:c,message:p,options:u}}})();this._set("processingStep","Waiting for user input..."),yield{type:"interrupt",payload:C,runId:n};break}case"cancelled":{yield{type:"cancelled",runId:n};return}case"error":{yield{type:"completed",error:r.error.message,log:e,runId:n};return}default:{console.warn("Unknown event type:",r);break}}}}catch(s){console.warn("Error during message processing:",s),yield{type:"completed",error:"An error occurred during message processing.",log:e,runId:"error"};return}finally{this._set("processing",!1)}}};h([d({readOnly:!0})],l.prototype,"orchestrator",2);h([d()],l.prototype,"agents",2);h([d()],l.prototype,"portal",2);h([d()],l.prototype,"view",2);h([d({readOnly:!0})],l.prototype,"loading",2);h([d({readOnly:!0})],l.prototype,"processing",2);h([d({readOnly:!0})],l.prototype,"processingStep",2);l=h([A("OrchestratorController")],l);var H="Embeddings resource 'embeddings-v01.json' not found in the webmap portal item.",F="Embeddings not found for this web map.",N="https://developers.arcgis.com/javascript/latest/agentic-apps/ai-webmap-setup/#embeddings",v=class extends w{constructor(){super(...arguments),this._messages=$({blocking:!0}),this.#t=y(),this.#n=y(),this.#e=y(),this.#s=null,this.#o=new Map,this.#r=O.getDefault(),this.#i=t=>{t.stopPropagation(),this.cancelInterrupt()},this.#a=t=>{t.stopPropagation();let e=t.detail;this.submitInterrupt(e)},this.#l=t=>{t.stopPropagation(),this.keepSuggestedPrompts||(this.suggestedPrompts=[]);let e=t.detail;this._inputValue="",this.arcgisSubmit.emit(e),this.submitMessage(e)},this.#c=t=>{if(t.stopPropagation(),this.arcgisCancel.emit(),this._interrupt){this.orchestrator?.cancelInterrupt(),this._interrupt=null;return}this.#s?.abort()},this.#h=t=>{t.stopPropagation();let e=t.detail;this.arcgisFeedback.emit(e)},this.#g=t=>{t.stopPropagation();let e=t.detail;this._inputValue=e.prompt,this.arcgisPromptSelect.emit(e)},this._orchestratorController=null,this._interrupt=null,this._error=null,this._inputValue="",this.messages=new P([]),this.referenceElement=null,this.suggestedPrompts=[],this.feedbackEnabled=!1,this.keepSuggestedPrompts=!1,this.logEnabled=!1,this.copyEnabled=!1,this.voiceInputEnabled=!1,this.readAloudEnabled=!1,this.arcgisCancel=o(),this.arcgisError=o(),this.arcgisFeedback=o(),this.arcgisInterrupt=o(),this.arcgisInterruptCancel=o(),this.arcgisInterruptSubmit=o(),this.arcgisPromptSelect=o(),this.arcgisReady=o(),this.arcgisSubmit=o()}static{this.properties={_orchestratorController:16,_interrupt:16,_error:16,_inputValue:16,_user:16,awaitingResponse:32,awaitingResponseStep:32,interrupt:32,messages:0,orchestrator:32,entryMessage:1,heading:1,description:1,referenceElement:1,suggestedPrompts:0,feedbackEnabled:5,keepSuggestedPrompts:5,logEnabled:5,copyEnabled:5,voiceInputEnabled:5,readAloudEnabled:5}}static{this.styles=V}#t;#n;#e;#s;#o;#r;#i;#a;#l;#c;#h;#g;async#p(){try{let t=S(this.el,this.referenceElement);await t?.componentOnReady();let e=[...this.#o.values()];return e.length?(this._orchestratorController=new l({agents:e,portal:this.#r,view:t?.view}),await this._orchestratorController.load(),!0):(this._error="No agents found.",!1)}catch(t){return this._error=t?.message??"Error initializing orchestrator.",f(this)(t),!1}}get _user(){return this.#r?.user?.fullName||this.#r?.user?.username}get awaitingResponse(){return this._orchestratorController?.processing??!1}get awaitingResponseStep(){return this._orchestratorController?.processingStep??""}get interrupt(){return this._interrupt}get orchestrator(){return this._orchestratorController?.orchestrator}async clearChatHistory(){this._reset(),this._orchestratorController?.clearChatHistory()}cancelInterrupt(){this.arcgisInterruptCancel.emit(),this.orchestrator?.cancelInterrupt(),this._interrupt=null}register(t){this.#o.set(t.agent.id,t)}async submitMessage(t){let e=t.trim();if(!e||(this.messages.push({id:Date.now().toString(),role:"user",content:e}),!this._orchestratorController))return;let i=this._orchestratorController.ask(e,this.#s?.signal);for await(let s of i){let r=s.runId;switch(s.type){case"completed":this.messages.push({role:"assistant",content:s.response,blocks:s.blocks,log:s.log,error:s.error,id:r});break;case"interrupt":this._interrupt={...s.payload,id:r},this.arcgisInterrupt.emit(this._interrupt);break;case"cancelled":this.messages.push({role:"assistant",error:"Request cancelled.",id:r});break}}}submitInterrupt(t){this.arcgisInterruptSubmit.emit(t),this.orchestrator?.resumeInterrupt(t),this._interrupt=null}load(){this.manager.onLifecycle(this._reset.bind(this))}loaded(){this.manager.onLifecycle(()=>{this.#t.value?.addEventListener("arcgisPromptSelect",this.#g),this.#t.value?.addEventListener("arcgisSubmit",this.#l),this.#t.value?.addEventListener("arcgisCancel",this.#c),this.#t.value?.addEventListener("arcgisFeedback",this.#h);let t=R(()=>!!this._interrupt&&!!this.#e.value,()=>{let e=this.#e.value;e.removeEventListener("arcgisSubmit",this.#a),e.removeEventListener("arcgisCancel",this.#i),e.addEventListener("arcgisSubmit",this.#a,{once:!0}),e.addEventListener("arcgisCancel",this.#i,{once:!0})});return queueMicrotask(()=>{this.#p().then(e=>{e?this.arcgisReady.emit():this._error&&this.arcgisError.emit(new Error(this._error))})}),()=>{t.remove(),this.#t.value?.removeEventListener("arcgisPromptSelect",this.#g),this.#e.value?.removeEventListener("arcgisSubmit",this.#a),this.#e.value?.removeEventListener("arcgisCancel",this.#i),this.#t.value?.removeEventListener("arcgisSubmit",this.#l),this.#t.value?.removeEventListener("arcgisCancel",this.#c),this.#t.value?.removeEventListener("arcgisFeedback",this.#h),this._orchestratorController?.destroy(),this._orchestratorController=null}})}_reset(){this.#s?.abort(),this._interrupt=null,this.messages.removeAll(),this._error=null,this._inputValue=""}_renderEntryMessage(){return this._interrupt?a`<slot name=interrupt><arcgis-assistant-interrupt .type=${this._interrupt.type} .message=${this._interrupt.message} .options=${this._interrupt.options} ${b(this.#e)}></arcgis-assistant-interrupt></slot>`:this._error?this._renderErrorNotice():this.entryMessage?this.messages.length>0?null:a`<calcite-notice open kind=info closable icon width=full><div slot=message>${this.entryMessage}</div></calcite-notice>`:a`<slot name=entry-message></slot>`}_renderErrorNotice(){return this._error?a`<calcite-notice closable slot=entry-message open kind=danger icon width=full>${this._error===H?a`<div slot=message>${F}</div><calcite-link slot=link .href=${N} target=_blank title="Learn about web map embeddings">Read more</calcite-link>`:a`<div slot=message>${this._error}</div>`}</calcite-notice>`:null}_renderSuggestedPrompts(){return this.suggestedPrompts?.length?a`<div class="suggested-prompts-container"><arcgis-assistant-suggested-prompts class="suggested-prompts" .prompts=${this.suggestedPrompts}></arcgis-assistant-suggested-prompts></div>`:null}render(){return a`<calcite-panel .loading=${!this._orchestratorController&&!this._error||this._orchestratorController?.loading} .heading=${this.heading??this._messages.assistantLabel} .description=${this.description} ${b(this.#t)}><slot name=header-actions-start slot=header-actions-start></slot><slot name=header-actions-end slot=header-actions-end></slot><div class="content-container"><arcgis-assistant-chat .loading=${this.awaitingResponse} .messages=${this.messages}><slot name=message-starter slot=message-starter></slot><slot name=messages slot=messages>${this.messages.map(t=>t.role==="assistant"?a`<arcgis-assistant-message .message=${t} .feedbackEnabled=${this.feedbackEnabled} .logEnabled=${this.logEnabled} .copyEnabled=${this.copyEnabled} .readAloudEnabled=${this.readAloudEnabled}></arcgis-assistant-message>`:a`<arcgis-assistant-user-message .message=${t} .user=${this._user}></arcgis-assistant-user-message>`)}</slot><slot name=message-loading slot=message-loading><arcgis-assistant-message-loading .loading=${this.awaitingResponse} .loadingMessage=${this.awaitingResponseStep}></arcgis-assistant-message-loading></slot></arcgis-assistant-chat></div>${this._renderSuggestedPrompts()}<div class="footer-container" slot=footer>${this._renderEntryMessage()}<slot name=chat-entry><arcgis-assistant-chat-entry .awaitingResponse=${this.awaitingResponse} .arcgisSubmit=${this.arcgisSubmit} .arcgisCancel=${this.arcgisCancel} .inputValue=${this._inputValue} .messages=${this.messages} .voiceInputEnabled=${this.voiceInputEnabled} ${b(this.#n)}><slot name=entry-actions-start slot=entry-actions-start></slot><slot name=entry-actions-end slot=entry-actions-end><calcite-button .iconStart=${this.awaitingResponse?"circle-stop":"send"} @click=${()=>{this.#n.value?.submitMessage()}} round>${this.awaitingResponse?this._messages.stopButtonLabel:this._messages.askButtonLabel}</calcite-button></slot></arcgis-assistant-chat-entry></slot><slot name=footer-content></slot></div></calcite-panel>`}};E("arcgis-assistant",v);return v},"core/Collection","core/reactiveUtils","portal/Portal","core/Accessor","core/accessorSupport/decorators",c)
@@ -1,5 +1,5 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{i as Se,j as le,q as Te,r as Re,s as $e}from"./SGGBOB5K.js";var V=class extends $e{constructor(t){if(super(t),this.it=le,t.type!==Te.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===le||t==null)return this._t=void 0,this.it=t;if(t===Se)return t;if(typeof t!="string")throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this._t;this.it=t;let r=[t];return r.raw=r,this._t={_$litType$:this.constructor.resultType,strings:r,values:[]}}};V.directiveName="unsafeHTML",V.resultType=1;var Ur=Re(V);var J=function(){return J=Object.assign||function(t){for(var r,s=1,n=arguments.length;s<n;s++){r=arguments[s];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i])}return t},J.apply(this,arguments)},oe={exports:{}},x={},ce={exports:{}},z={};function Ce(){var e={};return e["align-content"]=!1,e["align-items"]=!1,e["align-self"]=!1,e["alignment-adjust"]=!1,e["alignment-baseline"]=!1,e.all=!1,e["anchor-point"]=!1,e.animation=!1,e["animation-delay"]=!1,e["animation-direction"]=!1,e["animation-duration"]=!1,e["animation-fill-mode"]=!1,e["animation-iteration-count"]=!1,e["animation-name"]=!1,e["animation-play-state"]=!1,e["animation-timing-function"]=!1,e.azimuth=!1,e["backface-visibility"]=!1,e.background=!0,e["background-attachment"]=!0,e["background-clip"]=!0,e["background-color"]=!0,e["background-image"]=!0,e["background-origin"]=!0,e["background-position"]=!0,e["background-repeat"]=!0,e["background-size"]=!0,e["baseline-shift"]=!1,e.binding=!1,e.bleed=!1,e["bookmark-label"]=!1,e["bookmark-level"]=!1,e["bookmark-state"]=!1,e.border=!0,e["border-bottom"]=!0,e["border-bottom-color"]=!0,e["border-bottom-left-radius"]=!0,e["border-bottom-right-radius"]=!0,e["border-bottom-style"]=!0,e["border-bottom-width"]=!0,e["border-collapse"]=!0,e["border-color"]=!0,e["border-image"]=!0,e["border-image-outset"]=!0,e["border-image-repeat"]=!0,e["border-image-slice"]=!0,e["border-image-source"]=!0,e["border-image-width"]=!0,e["border-left"]=!0,e["border-left-color"]=!0,e["border-left-style"]=!0,e["border-left-width"]=!0,e["border-radius"]=!0,e["border-right"]=!0,e["border-right-color"]=!0,e["border-right-style"]=!0,e["border-right-width"]=!0,e["border-spacing"]=!0,e["border-style"]=!0,e["border-top"]=!0,e["border-top-color"]=!0,e["border-top-left-radius"]=!0,e["border-top-right-radius"]=!0,e["border-top-style"]=!0,e["border-top-width"]=!0,e["border-width"]=!0,e.bottom=!1,e["box-decoration-break"]=!0,e["box-shadow"]=!0,e["box-sizing"]=!0,e["box-snap"]=!0,e["box-suppress"]=!0,e["break-after"]=!0,e["break-before"]=!0,e["break-inside"]=!0,e["caption-side"]=!1,e.chains=!1,e.clear=!0,e.clip=!1,e["clip-path"]=!1,e["clip-rule"]=!1,e.color=!0,e["color-interpolation-filters"]=!0,e["column-count"]=!1,e["column-fill"]=!1,e["column-gap"]=!1,e["column-rule"]=!1,e["column-rule-color"]=!1,e["column-rule-style"]=!1,e["column-rule-width"]=!1,e["column-span"]=!1,e["column-width"]=!1,e.columns=!1,e.contain=!1,e.content=!1,e["counter-increment"]=!1,e["counter-reset"]=!1,e["counter-set"]=!1,e.crop=!1,e.cue=!1,e["cue-after"]=!1,e["cue-before"]=!1,e.cursor=!1,e.direction=!1,e.display=!0,e["display-inside"]=!0,e["display-list"]=!0,e["display-outside"]=!0,e["dominant-baseline"]=!1,e.elevation=!1,e["empty-cells"]=!1,e.filter=!1,e.flex=!1,e["flex-basis"]=!1,e["flex-direction"]=!1,e["flex-flow"]=!1,e["flex-grow"]=!1,e["flex-shrink"]=!1,e["flex-wrap"]=!1,e.float=!1,e["float-offset"]=!1,e["flood-color"]=!1,e["flood-opacity"]=!1,e["flow-from"]=!1,e["flow-into"]=!1,e.font=!0,e["font-family"]=!0,e["font-feature-settings"]=!0,e["font-kerning"]=!0,e["font-language-override"]=!0,e["font-size"]=!0,e["font-size-adjust"]=!0,e["font-stretch"]=!0,e["font-style"]=!0,e["font-synthesis"]=!0,e["font-variant"]=!0,e["font-variant-alternates"]=!0,e["font-variant-caps"]=!0,e["font-variant-east-asian"]=!0,e["font-variant-ligatures"]=!0,e["font-variant-numeric"]=!0,e["font-variant-position"]=!0,e["font-weight"]=!0,e.grid=!1,e["grid-area"]=!1,e["grid-auto-columns"]=!1,e["grid-auto-flow"]=!1,e["grid-auto-rows"]=!1,e["grid-column"]=!1,e["grid-column-end"]=!1,e["grid-column-start"]=!1,e["grid-row"]=!1,e["grid-row-end"]=!1,e["grid-row-start"]=!1,e["grid-template"]=!1,e["grid-template-areas"]=!1,e["grid-template-columns"]=!1,e["grid-template-rows"]=!1,e["hanging-punctuation"]=!1,e.height=!0,e.hyphens=!1,e.icon=!1,e["image-orientation"]=!1,e["image-resolution"]=!1,e["ime-mode"]=!1,e["initial-letters"]=!1,e["inline-box-align"]=!1,e["justify-content"]=!1,e["justify-items"]=!1,e["justify-self"]=!1,e.left=!1,e["letter-spacing"]=!0,e["lighting-color"]=!0,e["line-box-contain"]=!1,e["line-break"]=!1,e["line-grid"]=!1,e["line-height"]=!1,e["line-snap"]=!1,e["line-stacking"]=!1,e["line-stacking-ruby"]=!1,e["line-stacking-shift"]=!1,e["line-stacking-strategy"]=!1,e["list-style"]=!0,e["list-style-image"]=!0,e["list-style-position"]=!0,e["list-style-type"]=!0,e.margin=!0,e["margin-bottom"]=!0,e["margin-left"]=!0,e["margin-right"]=!0,e["margin-top"]=!0,e["marker-offset"]=!1,e["marker-side"]=!1,e.marks=!1,e.mask=!1,e["mask-box"]=!1,e["mask-box-outset"]=!1,e["mask-box-repeat"]=!1,e["mask-box-slice"]=!1,e["mask-box-source"]=!1,e["mask-box-width"]=!1,e["mask-clip"]=!1,e["mask-image"]=!1,e["mask-origin"]=!1,e["mask-position"]=!1,e["mask-repeat"]=!1,e["mask-size"]=!1,e["mask-source-type"]=!1,e["mask-type"]=!1,e["max-height"]=!0,e["max-lines"]=!1,e["max-width"]=!0,e["min-height"]=!0,e["min-width"]=!0,e["move-to"]=!1,e["nav-down"]=!1,e["nav-index"]=!1,e["nav-left"]=!1,e["nav-right"]=!1,e["nav-up"]=!1,e["object-fit"]=!1,e["object-position"]=!1,e.opacity=!1,e.order=!1,e.orphans=!1,e.outline=!1,e["outline-color"]=!1,e["outline-offset"]=!1,e["outline-style"]=!1,e["outline-width"]=!1,e.overflow=!1,e["overflow-wrap"]=!1,e["overflow-x"]=!1,e["overflow-y"]=!1,e.padding=!0,e["padding-bottom"]=!0,e["padding-left"]=!0,e["padding-right"]=!0,e["padding-top"]=!0,e.page=!1,e["page-break-after"]=!1,e["page-break-before"]=!1,e["page-break-inside"]=!1,e["page-policy"]=!1,e.pause=!1,e["pause-after"]=!1,e["pause-before"]=!1,e.perspective=!1,e["perspective-origin"]=!1,e.pitch=!1,e["pitch-range"]=!1,e["play-during"]=!1,e.position=!1,e["presentation-level"]=!1,e.quotes=!1,e["region-fragment"]=!1,e.resize=!1,e.rest=!1,e["rest-after"]=!1,e["rest-before"]=!1,e.richness=!1,e.right=!1,e.rotation=!1,e["rotation-point"]=!1,e["ruby-align"]=!1,e["ruby-merge"]=!1,e["ruby-position"]=!1,e["shape-image-threshold"]=!1,e["shape-outside"]=!1,e["shape-margin"]=!1,e.size=!1,e.speak=!1,e["speak-as"]=!1,e["speak-header"]=!1,e["speak-numeral"]=!1,e["speak-punctuation"]=!1,e["speech-rate"]=!1,e.stress=!1,e["string-set"]=!1,e["tab-size"]=!1,e["table-layout"]=!1,e["text-align"]=!0,e["text-align-last"]=!0,e["text-combine-upright"]=!0,e["text-decoration"]=!0,e["text-decoration-color"]=!0,e["text-decoration-line"]=!0,e["text-decoration-skip"]=!0,e["text-decoration-style"]=!0,e["text-emphasis"]=!0,e["text-emphasis-color"]=!0,e["text-emphasis-position"]=!0,e["text-emphasis-style"]=!0,e["text-height"]=!0,e["text-indent"]=!0,e["text-justify"]=!0,e["text-orientation"]=!0,e["text-overflow"]=!0,e["text-shadow"]=!0,e["text-space-collapse"]=!0,e["text-transform"]=!0,e["text-underline-position"]=!0,e["text-wrap"]=!0,e.top=!1,e.transform=!1,e["transform-origin"]=!1,e["transform-style"]=!1,e.transition=!1,e["transition-delay"]=!1,e["transition-duration"]=!1,e["transition-property"]=!1,e["transition-timing-function"]=!1,e["unicode-bidi"]=!1,e["vertical-align"]=!1,e.visibility=!1,e["voice-balance"]=!1,e["voice-duration"]=!1,e["voice-family"]=!1,e["voice-pitch"]=!1,e["voice-range"]=!1,e["voice-rate"]=!1,e["voice-stress"]=!1,e["voice-volume"]=!1,e.volume=!1,e["white-space"]=!1,e.widows=!1,e.width=!0,e["will-change"]=!1,e["word-break"]=!0,e["word-spacing"]=!0,e["word-wrap"]=!0,e["wrap-flow"]=!1,e["wrap-through"]=!1,e["writing-mode"]=!1,e["z-index"]=!1,e}function pt(e,t,r){}function ft(e,t,r){}var ht=/javascript\s*\:/img;function gt(e,t){return ht.test(t)?"":t}z.whiteList=Ce();z.getDefaultWhiteList=Ce;z.onAttr=pt;z.onIgnoreAttr=ft;z.safeAttrValue=gt;var dt={indexOf:function(e,t){var r,s;if(Array.prototype.indexOf)return e.indexOf(t);for(r=0,s=e.length;r<s;r++)if(e[r]===t)return r;return-1},forEach:function(e,t,r){var s,n;if(Array.prototype.forEach)return e.forEach(t,r);for(s=0,n=e.length;s<n;s++)t.call(r,e[s],s,e)},trim:function(e){return String.prototype.trim?e.trim():e.replace(/(^\s*)|(\s*$)/g,"")},trimRight:function(e){return String.prototype.trimRight?e.trimRight():e.replace(/(\s*$)/g,"")}},M=dt;function kt(e,t){e=M.trimRight(e),e[e.length-1]!==";"&&(e+=";");var r=e.length,s=!1,n=0,i=0,a="";function o(){if(!s){var c=M.trim(e.slice(n,i)),p=c.indexOf(":");if(p!==-1){var f=M.trim(c.slice(0,p)),h=M.trim(c.slice(p+1));if(f){var g=t(n,a.length,f,h,c);g&&(a+=g+"; ")}}}n=i+1}for(;i<r;i++){var l=e[i];if(l==="/"&&e[i+1]==="*"){var u=e.indexOf("*/",i+2);if(u===-1)break;i=u+1,n=i+1,s=!1}else l==="("?s=!0:l===")"?s=!1:l===";"?s||o():l===`
2
+ import{i as Se,j as le,q as Te,r as Re,s as $e}from"./GW636L6T.js";var V=class extends $e{constructor(t){if(super(t),this.it=le,t.type!==Te.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===le||t==null)return this._t=void 0,this.it=t;if(t===Se)return t;if(typeof t!="string")throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this._t;this.it=t;let r=[t];return r.raw=r,this._t={_$litType$:this.constructor.resultType,strings:r,values:[]}}};V.directiveName="unsafeHTML",V.resultType=1;var Ur=Re(V);var J=function(){return J=Object.assign||function(t){for(var r,s=1,n=arguments.length;s<n;s++){r=arguments[s];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i])}return t},J.apply(this,arguments)},oe={exports:{}},x={},ce={exports:{}},z={};function Ce(){var e={};return e["align-content"]=!1,e["align-items"]=!1,e["align-self"]=!1,e["alignment-adjust"]=!1,e["alignment-baseline"]=!1,e.all=!1,e["anchor-point"]=!1,e.animation=!1,e["animation-delay"]=!1,e["animation-direction"]=!1,e["animation-duration"]=!1,e["animation-fill-mode"]=!1,e["animation-iteration-count"]=!1,e["animation-name"]=!1,e["animation-play-state"]=!1,e["animation-timing-function"]=!1,e.azimuth=!1,e["backface-visibility"]=!1,e.background=!0,e["background-attachment"]=!0,e["background-clip"]=!0,e["background-color"]=!0,e["background-image"]=!0,e["background-origin"]=!0,e["background-position"]=!0,e["background-repeat"]=!0,e["background-size"]=!0,e["baseline-shift"]=!1,e.binding=!1,e.bleed=!1,e["bookmark-label"]=!1,e["bookmark-level"]=!1,e["bookmark-state"]=!1,e.border=!0,e["border-bottom"]=!0,e["border-bottom-color"]=!0,e["border-bottom-left-radius"]=!0,e["border-bottom-right-radius"]=!0,e["border-bottom-style"]=!0,e["border-bottom-width"]=!0,e["border-collapse"]=!0,e["border-color"]=!0,e["border-image"]=!0,e["border-image-outset"]=!0,e["border-image-repeat"]=!0,e["border-image-slice"]=!0,e["border-image-source"]=!0,e["border-image-width"]=!0,e["border-left"]=!0,e["border-left-color"]=!0,e["border-left-style"]=!0,e["border-left-width"]=!0,e["border-radius"]=!0,e["border-right"]=!0,e["border-right-color"]=!0,e["border-right-style"]=!0,e["border-right-width"]=!0,e["border-spacing"]=!0,e["border-style"]=!0,e["border-top"]=!0,e["border-top-color"]=!0,e["border-top-left-radius"]=!0,e["border-top-right-radius"]=!0,e["border-top-style"]=!0,e["border-top-width"]=!0,e["border-width"]=!0,e.bottom=!1,e["box-decoration-break"]=!0,e["box-shadow"]=!0,e["box-sizing"]=!0,e["box-snap"]=!0,e["box-suppress"]=!0,e["break-after"]=!0,e["break-before"]=!0,e["break-inside"]=!0,e["caption-side"]=!1,e.chains=!1,e.clear=!0,e.clip=!1,e["clip-path"]=!1,e["clip-rule"]=!1,e.color=!0,e["color-interpolation-filters"]=!0,e["column-count"]=!1,e["column-fill"]=!1,e["column-gap"]=!1,e["column-rule"]=!1,e["column-rule-color"]=!1,e["column-rule-style"]=!1,e["column-rule-width"]=!1,e["column-span"]=!1,e["column-width"]=!1,e.columns=!1,e.contain=!1,e.content=!1,e["counter-increment"]=!1,e["counter-reset"]=!1,e["counter-set"]=!1,e.crop=!1,e.cue=!1,e["cue-after"]=!1,e["cue-before"]=!1,e.cursor=!1,e.direction=!1,e.display=!0,e["display-inside"]=!0,e["display-list"]=!0,e["display-outside"]=!0,e["dominant-baseline"]=!1,e.elevation=!1,e["empty-cells"]=!1,e.filter=!1,e.flex=!1,e["flex-basis"]=!1,e["flex-direction"]=!1,e["flex-flow"]=!1,e["flex-grow"]=!1,e["flex-shrink"]=!1,e["flex-wrap"]=!1,e.float=!1,e["float-offset"]=!1,e["flood-color"]=!1,e["flood-opacity"]=!1,e["flow-from"]=!1,e["flow-into"]=!1,e.font=!0,e["font-family"]=!0,e["font-feature-settings"]=!0,e["font-kerning"]=!0,e["font-language-override"]=!0,e["font-size"]=!0,e["font-size-adjust"]=!0,e["font-stretch"]=!0,e["font-style"]=!0,e["font-synthesis"]=!0,e["font-variant"]=!0,e["font-variant-alternates"]=!0,e["font-variant-caps"]=!0,e["font-variant-east-asian"]=!0,e["font-variant-ligatures"]=!0,e["font-variant-numeric"]=!0,e["font-variant-position"]=!0,e["font-weight"]=!0,e.grid=!1,e["grid-area"]=!1,e["grid-auto-columns"]=!1,e["grid-auto-flow"]=!1,e["grid-auto-rows"]=!1,e["grid-column"]=!1,e["grid-column-end"]=!1,e["grid-column-start"]=!1,e["grid-row"]=!1,e["grid-row-end"]=!1,e["grid-row-start"]=!1,e["grid-template"]=!1,e["grid-template-areas"]=!1,e["grid-template-columns"]=!1,e["grid-template-rows"]=!1,e["hanging-punctuation"]=!1,e.height=!0,e.hyphens=!1,e.icon=!1,e["image-orientation"]=!1,e["image-resolution"]=!1,e["ime-mode"]=!1,e["initial-letters"]=!1,e["inline-box-align"]=!1,e["justify-content"]=!1,e["justify-items"]=!1,e["justify-self"]=!1,e.left=!1,e["letter-spacing"]=!0,e["lighting-color"]=!0,e["line-box-contain"]=!1,e["line-break"]=!1,e["line-grid"]=!1,e["line-height"]=!1,e["line-snap"]=!1,e["line-stacking"]=!1,e["line-stacking-ruby"]=!1,e["line-stacking-shift"]=!1,e["line-stacking-strategy"]=!1,e["list-style"]=!0,e["list-style-image"]=!0,e["list-style-position"]=!0,e["list-style-type"]=!0,e.margin=!0,e["margin-bottom"]=!0,e["margin-left"]=!0,e["margin-right"]=!0,e["margin-top"]=!0,e["marker-offset"]=!1,e["marker-side"]=!1,e.marks=!1,e.mask=!1,e["mask-box"]=!1,e["mask-box-outset"]=!1,e["mask-box-repeat"]=!1,e["mask-box-slice"]=!1,e["mask-box-source"]=!1,e["mask-box-width"]=!1,e["mask-clip"]=!1,e["mask-image"]=!1,e["mask-origin"]=!1,e["mask-position"]=!1,e["mask-repeat"]=!1,e["mask-size"]=!1,e["mask-source-type"]=!1,e["mask-type"]=!1,e["max-height"]=!0,e["max-lines"]=!1,e["max-width"]=!0,e["min-height"]=!0,e["min-width"]=!0,e["move-to"]=!1,e["nav-down"]=!1,e["nav-index"]=!1,e["nav-left"]=!1,e["nav-right"]=!1,e["nav-up"]=!1,e["object-fit"]=!1,e["object-position"]=!1,e.opacity=!1,e.order=!1,e.orphans=!1,e.outline=!1,e["outline-color"]=!1,e["outline-offset"]=!1,e["outline-style"]=!1,e["outline-width"]=!1,e.overflow=!1,e["overflow-wrap"]=!1,e["overflow-x"]=!1,e["overflow-y"]=!1,e.padding=!0,e["padding-bottom"]=!0,e["padding-left"]=!0,e["padding-right"]=!0,e["padding-top"]=!0,e.page=!1,e["page-break-after"]=!1,e["page-break-before"]=!1,e["page-break-inside"]=!1,e["page-policy"]=!1,e.pause=!1,e["pause-after"]=!1,e["pause-before"]=!1,e.perspective=!1,e["perspective-origin"]=!1,e.pitch=!1,e["pitch-range"]=!1,e["play-during"]=!1,e.position=!1,e["presentation-level"]=!1,e.quotes=!1,e["region-fragment"]=!1,e.resize=!1,e.rest=!1,e["rest-after"]=!1,e["rest-before"]=!1,e.richness=!1,e.right=!1,e.rotation=!1,e["rotation-point"]=!1,e["ruby-align"]=!1,e["ruby-merge"]=!1,e["ruby-position"]=!1,e["shape-image-threshold"]=!1,e["shape-outside"]=!1,e["shape-margin"]=!1,e.size=!1,e.speak=!1,e["speak-as"]=!1,e["speak-header"]=!1,e["speak-numeral"]=!1,e["speak-punctuation"]=!1,e["speech-rate"]=!1,e.stress=!1,e["string-set"]=!1,e["tab-size"]=!1,e["table-layout"]=!1,e["text-align"]=!0,e["text-align-last"]=!0,e["text-combine-upright"]=!0,e["text-decoration"]=!0,e["text-decoration-color"]=!0,e["text-decoration-line"]=!0,e["text-decoration-skip"]=!0,e["text-decoration-style"]=!0,e["text-emphasis"]=!0,e["text-emphasis-color"]=!0,e["text-emphasis-position"]=!0,e["text-emphasis-style"]=!0,e["text-height"]=!0,e["text-indent"]=!0,e["text-justify"]=!0,e["text-orientation"]=!0,e["text-overflow"]=!0,e["text-shadow"]=!0,e["text-space-collapse"]=!0,e["text-transform"]=!0,e["text-underline-position"]=!0,e["text-wrap"]=!0,e.top=!1,e.transform=!1,e["transform-origin"]=!1,e["transform-style"]=!1,e.transition=!1,e["transition-delay"]=!1,e["transition-duration"]=!1,e["transition-property"]=!1,e["transition-timing-function"]=!1,e["unicode-bidi"]=!1,e["vertical-align"]=!1,e.visibility=!1,e["voice-balance"]=!1,e["voice-duration"]=!1,e["voice-family"]=!1,e["voice-pitch"]=!1,e["voice-range"]=!1,e["voice-rate"]=!1,e["voice-stress"]=!1,e["voice-volume"]=!1,e.volume=!1,e["white-space"]=!1,e.widows=!1,e.width=!0,e["will-change"]=!1,e["word-break"]=!0,e["word-spacing"]=!0,e["word-wrap"]=!0,e["wrap-flow"]=!1,e["wrap-through"]=!1,e["writing-mode"]=!1,e["z-index"]=!1,e}function pt(e,t,r){}function ft(e,t,r){}var ht=/javascript\s*\:/img;function gt(e,t){return ht.test(t)?"":t}z.whiteList=Ce();z.getDefaultWhiteList=Ce;z.onAttr=pt;z.onIgnoreAttr=ft;z.safeAttrValue=gt;var dt={indexOf:function(e,t){var r,s;if(Array.prototype.indexOf)return e.indexOf(t);for(r=0,s=e.length;r<s;r++)if(e[r]===t)return r;return-1},forEach:function(e,t,r){var s,n;if(Array.prototype.forEach)return e.forEach(t,r);for(s=0,n=e.length;s<n;s++)t.call(r,e[s],s,e)},trim:function(e){return String.prototype.trim?e.trim():e.replace(/(^\s*)|(\s*$)/g,"")},trimRight:function(e){return String.prototype.trimRight?e.trimRight():e.replace(/(\s*$)/g,"")}},M=dt;function kt(e,t){e=M.trimRight(e),e[e.length-1]!==";"&&(e+=";");var r=e.length,s=!1,n=0,i=0,a="";function o(){if(!s){var c=M.trim(e.slice(n,i)),p=c.indexOf(":");if(p!==-1){var f=M.trim(c.slice(0,p)),h=M.trim(c.slice(p+1));if(f){var g=t(n,a.length,f,h,c);g&&(a+=g+"; ")}}}n=i+1}for(;i<r;i++){var l=e[i];if(l==="/"&&e[i+1]==="*"){var u=e.indexOf("*/",i+2);if(u===-1)break;i=u+1,n=i+1,s=!1}else l==="("?s=!0:l===")"?s=!1:l===";"?s||o():l===`
3
3
  `&&o()}return M.trim(a)}var bt=kt,Z=z,xt=bt;function Le(e){return e==null}function mt(e){var t={};for(var r in e)t[r]=e[r];return t}function Ie(e){e=mt(e||{}),e.whiteList=e.whiteList||Z.whiteList,e.onAttr=e.onAttr||Z.onAttr,e.onIgnoreAttr=e.onIgnoreAttr||Z.onIgnoreAttr,e.safeAttrValue=e.safeAttrValue||Z.safeAttrValue,this.options=e}Ie.prototype.process=function(e){if(e=e||"",e=e.toString(),!e)return"";var t=this,r=t.options,s=r.whiteList,n=r.onAttr,i=r.onIgnoreAttr,a=r.safeAttrValue,o=xt(e,function(l,u,c,p,f){var h=s[c],g=!1;if(h===!0?g=h:typeof h=="function"?g=h(p):h instanceof RegExp&&(g=h.test(p)),g!==!0&&(g=!1),p=a(c,p),!!p){var b={position:u,sourcePosition:l,source:f,isWhite:g};if(g){var m=n(c,p,b);return Le(m)?c+":"+p:m}else{var m=i(c,p,b);if(!Le(m))return m}}});return o};var wt=Ie;(function(e,t){var r=z,s=wt;function n(a,o){var l=new s(o);return l.process(a)}t=e.exports=n,t.FilterCSS=s;for(var i in r)t[i]=r[i]})(ce,ce.exports);var ue=ce.exports,pe={indexOf:function(e,t){var r,s;if(Array.prototype.indexOf)return e.indexOf(t);for(r=0,s=e.length;r<s;r++)if(e[r]===t)return r;return-1},forEach:function(e,t,r){var s,n;if(Array.prototype.forEach)return e.forEach(t,r);for(s=0,n=e.length;s<n;s++)t.call(r,e[s],s,e)},trim:function(e){return String.prototype.trim?e.trim():e.replace(/(^\s*)|(\s*$)/g,"")},spaceIndex:function(e){var t=/\s|\n|\t/,r=t.exec(e);return r?r.index:-1}},yt=ue.FilterCSS,vt=ue.getDefaultWhiteList,K=pe;function Pe(){return{a:["target","href","title"],abbr:["title"],address:[],area:["shape","coords","href","alt"],article:[],aside:[],audio:["autoplay","controls","crossorigin","loop","muted","preload","src"],b:[],bdi:["dir"],bdo:["dir"],big:[],blockquote:["cite"],br:[],caption:[],center:[],cite:[],code:[],col:["align","valign","span","width"],colgroup:["align","valign","span","width"],dd:[],del:["datetime"],details:["open"],div:[],dl:[],dt:[],em:[],figcaption:[],figure:[],font:["color","size","face"],footer:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],header:[],hr:[],i:[],img:["src","alt","title","width","height"],ins:["datetime"],li:[],mark:[],nav:[],ol:[],p:[],pre:[],s:[],section:[],small:[],span:[],sub:[],summary:[],sup:[],strong:[],strike:[],table:["width","border","align","valign"],tbody:["align","valign"],td:["width","rowspan","colspan","align","valign"],tfoot:["align","valign"],th:["width","rowspan","colspan","align","valign"],thead:["align","valign"],tr:["rowspan","align","valign"],tt:[],u:[],ul:[],video:["autoplay","controls","crossorigin","loop","muted","playsinline","poster","preload","src","height","width"]}}var Oe=new yt;function At(e,t,r){}function St(e,t,r){}function Tt(e,t,r){}function Rt(e,t,r){}function qe(e){return e.replace(Lt,"&lt;").replace(_t,"&gt;")}function $t(e,t,r,s){if(r=Me(r),t==="href"||t==="src"){if(r=K.trim(r),r==="#")return"#";if(!(r.substr(0,7)==="http://"||r.substr(0,8)==="https://"||r.substr(0,7)==="mailto:"||r.substr(0,4)==="tel:"||r.substr(0,11)==="data:image/"||r.substr(0,6)==="ftp://"||r.substr(0,2)==="./"||r.substr(0,3)==="../"||r[0]==="#"||r[0]==="/"))return""}else if(t==="background"){if(X.lastIndex=0,X.test(r))return""}else if(t==="style"){if(_e.lastIndex=0,_e.test(r)||(Ee.lastIndex=0,Ee.test(r)&&(X.lastIndex=0,X.test(r))))return"";s!==!1&&(s=s||Oe,r=s.process(r))}return r=He(r),r}var Lt=/</g,_t=/>/g,Et=/"/g,zt=/&quot;/g,Ct=/&#([a-zA-Z0-9]*);?/gim,It=/&colon;?/gim,Pt=/&newline;?/gim,X=/((j\s*a\s*v\s*a|v\s*b|l\s*i\s*v\s*e)\s*s\s*c\s*r\s*i\s*p\s*t\s*|m\s*o\s*c\s*h\s*a):/gi,_e=/e\s*x\s*p\s*r\s*e\s*s\s*s\s*i\s*o\s*n\s*\(.*/gi,Ee=/u\s*r\s*l\s*\(.*/gi;function Be(e){return e.replace(Et,"&quot;")}function De(e){return e.replace(zt,'"')}function Fe(e){return e.replace(Ct,function(r,s){return s[0]==="x"||s[0]==="X"?String.fromCharCode(parseInt(s.substr(1),16)):String.fromCharCode(parseInt(s,10))})}function Ne(e){return e.replace(It,":").replace(Pt," ")}function Ve(e){for(var t="",r=0,s=e.length;r<s;r++)t+=e.charCodeAt(r)<32?" ":e.charAt(r);return K.trim(t)}function Me(e){return e=De(e),e=Fe(e),e=Ne(e),e=Ve(e),e}function He(e){return e=Be(e),e=qe(e),e}function Ot(){return""}function qt(e,t){typeof t!="function"&&(t=function(){});var r=!Array.isArray(e);function s(a){return r?!0:K.indexOf(e,a)!==-1}var n=[],i=!1;return{onIgnoreTag:function(a,o,l){if(s(a))if(l.isClosing){var u="[/removed]",c=l.position+u.length;return n.push([i!==!1?i:l.position,c]),i=!1,u}else return i||(i=l.position),"[removed]";else return t(a,o,l)},remove:function(a){var o="",l=0;return K.forEach(n,function(u){o+=a.slice(l,u[0]),l=u[1]}),o+=a.slice(l),o}}}function Bt(e){for(var t="",r=0;r<e.length;){var s=e.indexOf("<!--",r);if(s===-1){t+=e.slice(r);break}t+=e.slice(r,s);var n=e.indexOf("-->",s);if(n===-1)break;r=n+3}return t}function Dt(e){var t=e.split("");return t=t.filter(function(r){var s=r.charCodeAt(0);return s===127?!1:s<=31?s===10||s===13:!0}),t.join("")}x.whiteList=Pe();x.getDefaultWhiteList=Pe;x.onTag=At;x.onIgnoreTag=St;x.onTagAttr=Tt;x.onIgnoreTagAttr=Rt;x.safeAttrValue=$t;x.escapeHtml=qe;x.escapeQuote=Be;x.unescapeQuote=De;x.escapeHtmlEntities=Fe;x.escapeDangerHtml5Entities=Ne;x.clearNonPrintableCharacter=Ve;x.friendlyAttrValue=Me;x.escapeAttrValue=He;x.onIgnoreTagStripAll=Ot;x.StripTagBody=qt;x.stripCommentTag=Bt;x.stripBlankChar=Dt;x.cssFilter=Oe;x.getDefaultCSSWhiteList=vt;var Y={},R=pe;function Ft(e){var t=R.spaceIndex(e),r;return t===-1?r=e.slice(1,-1):r=e.slice(1,t+1),r=R.trim(r).toLowerCase(),r.slice(0,1)==="/"&&(r=r.slice(1)),r.slice(-1)==="/"&&(r=r.slice(0,-1)),r}function Nt(e){return e.slice(0,2)==="</"}function Vt(e,t,r){var s="",n=0,i=!1,a=!1,o=0,l=e.length,u="",c="";e:for(o=0;o<l;o++){var p=e.charAt(o);if(i===!1){if(p==="<"){i=o;continue}}else if(a===!1){if(p==="<"){s+=r(e.slice(n,o)),i=o,n=o;continue}if(p===">"){s+=r(e.slice(n,i)),c=e.slice(i,o+1),u=Ft(c),s+=t(i,s.length,u,c,Nt(c)),n=o+1,i=!1;continue}if(p==='"'||p==="'")for(var f=1,h=e.charAt(o-f);h.trim()===""||h==="=";){if(h==="="){a=p;continue e}h=e.charAt(o-++f)}}else if(p===a){a=!1;continue}}return n<e.length&&(s+=r(e.substr(n))),s}var Mt=/[^a-zA-Z0-9\\_:.-]/gim;function Ht(e,t){var r=0,s=0,n=[],i=!1,a=e.length;function o(f,h){if(f=R.trim(f),f=f.replace(Mt,"").toLowerCase(),!(f.length<1)){var g=t(f,h||"");g&&n.push(g)}}for(var l=0;l<a;l++){var u=e.charAt(l),c,p;if(i===!1&&u==="="){i=e.slice(r,l),r=l+1,s=e.charAt(r)==='"'||e.charAt(r)==="'"?r:jt(e,l+1);continue}if(i!==!1&&l===s){if(p=e.indexOf(u,l+1),p===-1)break;c=R.trim(e.slice(s+1,p)),o(i,c),i=!1,l=p,r=l+1;continue}if(/\s|\n|\t/.test(u))if(e=e.replace(/\s|\n|\t/g," "),i===!1)if(p=Wt(e,l),p===-1){c=R.trim(e.slice(r,l)),o(c),i=!1,r=l+1;continue}else{l=p-1;continue}else if(p=Gt(e,l-1),p===-1){c=R.trim(e.slice(r,l)),c=ze(c),o(i,c),i=!1,r=l+1;continue}else continue}return r<e.length&&(i===!1?o(e.slice(r)):o(i,ze(R.trim(e.slice(r))))),R.trim(n.join(" "))}function Wt(e,t){for(;t<e.length;t++){var r=e[t];if(r!==" ")return r==="="?t:-1}}function jt(e,t){for(;t<e.length;t++){var r=e[t];if(r!==" ")return r==="'"||r==='"'?t:-1}}function Gt(e,t){for(;t>0;t--){var r=e[t];if(r!==" ")return r==="="?t:-1}}function Zt(e){return e[0]==='"'&&e[e.length-1]==='"'||e[0]==="'"&&e[e.length-1]==="'"}function ze(e){return Zt(e)?e.substr(1,e.length-2):e}Y.parseTag=Vt;Y.parseAttr=Ht;var Xt=ue.FilterCSS,y=x,We=Y,Qt=We.parseTag,Ut=We.parseAttr,U=pe;function Q(e){return e==null}function Jt(e){var t=U.spaceIndex(e);if(t===-1)return{html:"",closing:e[e.length-2]==="/"};e=U.trim(e.slice(t+1,-1));var r=e[e.length-1]==="/";return r&&(e=U.trim(e.slice(0,-1))),{html:e,closing:r}}function Kt(e){var t={};for(var r in e)t[r]=e[r];return t}function Yt(e){var t={};for(var r in e)Array.isArray(e[r])?t[r.toLowerCase()]=e[r].map(function(s){return s.toLowerCase()}):t[r.toLowerCase()]=e[r];return t}function je(e){e=Kt(e||{}),e.stripIgnoreTag&&(e.onIgnoreTag&&console.error('Notes: cannot use these two options "stripIgnoreTag" and "onIgnoreTag" at the same time'),e.onIgnoreTag=y.onIgnoreTagStripAll),e.whiteList||e.allowList?e.whiteList=Yt(e.whiteList||e.allowList):e.whiteList=y.whiteList,e.onTag=e.onTag||y.onTag,e.onTagAttr=e.onTagAttr||y.onTagAttr,e.onIgnoreTag=e.onIgnoreTag||y.onIgnoreTag,e.onIgnoreTagAttr=e.onIgnoreTagAttr||y.onIgnoreTagAttr,e.safeAttrValue=e.safeAttrValue||y.safeAttrValue,e.escapeHtml=e.escapeHtml||y.escapeHtml,this.options=e,e.css===!1?this.cssFilter=!1:(e.css=e.css||{},this.cssFilter=new Xt(e.css))}je.prototype.process=function(e){if(e=e||"",e=e.toString(),!e)return"";var t=this,r=t.options,s=r.whiteList,n=r.onTag,i=r.onIgnoreTag,a=r.onTagAttr,o=r.onIgnoreTagAttr,l=r.safeAttrValue,u=r.escapeHtml,c=t.cssFilter;r.stripBlankChar&&(e=y.stripBlankChar(e)),r.allowCommentTag||(e=y.stripCommentTag(e));var p=!1;r.stripIgnoreTagBody&&(p=y.StripTagBody(r.stripIgnoreTagBody,i),i=p.onIgnoreTag);var f=Qt(e,function(h,g,b,m,L){var _={sourcePosition:h,position:g,isClosing:L,isWhite:Object.prototype.hasOwnProperty.call(s,b)},E=n(b,m,_);if(!Q(E))return E;if(_.isWhite){if(_.isClosing)return"</"+b+">";var G=Jt(m),F=s[b],T=Ut(G.html,function(O,q){var ae=U.indexOf(F,O)!==-1,N=a(b,O,q,ae);return Q(N)?ae?(q=l(b,O,q,c),q?O+'="'+q+'"':O):(N=o(b,O,q,ae),Q(N)?void 0:N):N});return m="<"+b,T&&(m+=" "+T),G.closing&&(m+=" /"),m+=">",m}else return E=i(b,m,_),Q(E)?u(m):E},u);return p&&(f=p.remove(f)),f};var er=je;(function(e,t){var r=x,s=Y,n=er;function i(o,l){var u=new n(l);return u.process(o)}t=e.exports=i,t.filterXSS=i,t.FilterXSS=n,(function(){for(var o in r)t[o]=r[o];for(var l in s)t[l]=s[l]})();function a(){return typeof self<"u"&&typeof DedicatedWorkerGlobalScope<"u"&&self instanceof DedicatedWorkerGlobalScope}a()&&(self.filterXSS=e.exports)})(oe,oe.exports);var B=oe.exports,tr=function(e){if(typeof e!="object"||e===null||Object.prototype.toString.call(e)!=="[object Object]")return!1;var t=Object.getPrototypeOf(e);if(t===null)return!0;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t},Ge=(function(){function e(t,r){var s=this;this.arcgisWhiteList={a:["href","style","target"],abbr:["title"],article:["style"],aside:["style"],audio:["autoplay","controls","loop","muted","preload"],b:[],blockquote:["style"],br:[],code:["style"],dd:["style"],del:["style"],details:["open","style"],div:["align","aria-hidden","aria-label","style"],dl:["style"],dt:["style"],em:[],figcaption:["style"],figure:["style"],font:["color","face","size","style"],footer:["style"],h1:["style"],h2:["style"],h3:["style"],h4:["style"],h5:["style"],h6:["style"],header:["style"],hr:[],i:[],img:["alt","border","height","src","style","width"],li:[],main:["style"],mark:["style"],nav:["style"],ol:[],p:["style"],pre:["style"],section:["style"],source:["media","src","type"],span:["aria-hidden","aria-label","style"],strong:[],sub:["style"],summary:["style"],sup:["style"],table:["border","cellpadding","cellspacing","height","style","width"],tbody:[],tr:["align","height","style","valign"],td:["align","colspan","height","nowrap","rowspan","style","valign","width"],th:["align","colspan","height","nowrap","rowspan","style","valign","width"],time:["style"],u:[],ul:[],video:["autoplay","controls","height","loop","muted","poster","preload","width"]},this.arcgisCSSWhiteList=J(J({},B.getDefaultCSSWhiteList()),{"align-items":!0,"align-self":!0,flex:!0,"flex-basis":!0,"flex-direction":!0,"flex-flow":!0,"flex-grow":!0,"flex-shrink":!0,"flex-wrap":!0,float:!0,gap:!0,grid:!0,"grid-area":!0,"grid-auto-columns":!0,"grid-auto-flow":!0,"grid-auto-rows":!0,"grid-column":!0,"grid-column-end":!0,"grid-column-start":!0,"grid-row":!0,"grid-row-end":!0,"grid-row-start":!0,"grid-template":!0,"grid-template-areas":!0,"grid-template-columns":!0,"grid-template-rows":!0,"justify-content":!0,"justify-items":!0,"justify-self":!0,"line-height":!0,overflow:!0}),this.allowedProtocols=["http","https","mailto","iform","tel","flow","lfmobile","arcgis-navigator","arcgis-appstudio-player","arcgis-survey123","arcgis-collector","arcgis-workforce","arcgis-explorer","arcgis-trek2there","arcgis-quickcapture","mspbi","comgooglemaps","pdfefile","pdfehttp","pdfehttps","boxapp","boxemm","awb","awbs","gropen","radarscope"],this.arcgisFilterOptions={allowCommentTag:!0,safeAttrValue:function(i,a,o,l){return i==="a"&&a==="href"||(i==="img"||i==="source")&&a==="src"?s.sanitizeUrl(o):B.safeAttrValue(i,a,o,l)}},this._entityMap={"&":"&#x38;","<":"&#x3C;",">":"&#x3E;",'"':"&#x22;","'":"&#x27;","/":"&#x2F;"};var n;t&&!r?n=t:t&&r?(n=Object.create(this.arcgisFilterOptions),n.css={whiteList:this.arcgisCSSWhiteList},Object.keys(t).forEach(function(i){if(i==="whiteList")n.whiteList=s._extendObjectOfArrays([s.arcgisWhiteList,t.whiteList||{}]);else if(i==="css"){var a=t.css.whiteList;a!=null&&t.css instanceof Object&&Object.keys(a).forEach(function(o){return n.css.whiteList[o]=a[o]})}else n[i]=t[i]})):(n=Object.create(this.arcgisFilterOptions),n.whiteList=this.arcgisWhiteList,n.css={whiteList:this.arcgisCSSWhiteList}),this.xssFilterOptions=n,this._xssFilter=new B.FilterXSS(n)}return e.prototype.sanitize=function(t,r){switch(r===void 0&&(r={}),typeof t){case"number":return isNaN(t)||!isFinite(t)?null:t;case"boolean":return t;case"string":return this._xssFilter.process(t);case"object":return this._iterateOverObject(t,r);default:return r.allowUndefined&&typeof t>"u"?void 0:null}},e.prototype.sanitizeUrl=function(t,r){var s=(r??{}).isProtocolRequired,n=s===void 0?!0:s,i=this._trim(t.substring(0,t.indexOf(":"))),a=t==="/",o=/^#/.test(t),l=i&&this.allowedProtocols.indexOf(i.toLowerCase())>-1;return a||o||l?B.escapeAttrValue(t):!i&&!n?B.escapeAttrValue("https://".concat(t)):""},e.prototype.sanitizeHTMLAttribute=function(t,r,s,n){return typeof this.xssFilterOptions.safeAttrValue=="function"?this.xssFilterOptions.safeAttrValue(t,r,s,n):B.safeAttrValue(t,r,s,n)},e.prototype.validate=function(t,r){r===void 0&&(r={});var s=this.sanitize(t,r);return{isValid:t===s,sanitized:s}},e.prototype.encodeHTML=function(t){var r=this;return String(t).replace(/[&<>"'\/]/g,function(s){return r._entityMap[s]})},e.prototype.encodeAttrValue=function(t){var r=/^[a-zA-Z0-9]$/;return String(t).replace(/[\x00-\xFF]/g,function(s,n){return r.test(s)?s:"&#x".concat(Number(t.charCodeAt(n)).toString(16),";")})},e.prototype._extendObjectOfArrays=function(t){var r={};return t.forEach(function(s){Object.keys(s).forEach(function(n){Array.isArray(s[n])&&Array.isArray(r[n])?r[n]=r[n].concat(s[n]):r[n]=s[n]})}),r},e.prototype._iterateOverObject=function(t,r){var s=this;r===void 0&&(r={});try{var n=!1,i=void 0;if(Array.isArray(t))i=t.reduce(function(o,l){var u=s.validate(l,r);return u.isValid?o.concat([l]):(n=!0,o.concat([u.sanitized]))},[]);else if(tr(t)){var a=Object.keys(t);i=a.reduce(function(o,l){var u=t[l],c=s.validate(u,r);return c.isValid?o[l]=u:(n=!0,o[l]=c.sanitized),o},{})}else return r.allowUndefined&&typeof t>"u"?void 0:null;return n?i:t}catch{return null}},e.prototype._trim=function(t){return String.prototype.trim?t.trim():t.replace(/(^\s*)|(\s*$)/g,"")},e})();function de(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var P=de();function et(e){P=e}var C={exec:()=>null};function d(e,t=""){let r=typeof e=="string"?e:e.source,s={replace:(n,i)=>{let a=typeof i=="string"?i:i.source;return a=a.replace(w.caret,"$1"),r=r.replace(n,a),s},getRegex:()=>new RegExp(r,t)};return s}var rr=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),w={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i"),blockquoteBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}>`)},nr=/^(?:[ \t]*(?:\n|$))+/,sr=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,ir=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,j=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,ar=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,ke=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,tt=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,rt=d(tt).replace(/bull/g,ke).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),lr=d(tt).replace(/bull/g,ke).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),be=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,or=/^[^\n]+/,xe=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,cr=d(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",xe).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),ur=d(/^(bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,ke).getRegex(),se="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",me=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,pr=d("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",me).replace("tag",se).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),nt=d(be).replace("hr",j).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",se).getRegex(),fr=d(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",nt).getRegex(),we={blockquote:fr,code:sr,def:cr,fences:ir,heading:ar,hr:j,html:pr,lheading:rt,list:ur,newline:nr,paragraph:nt,table:C,text:or},Ze=d("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",j).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",se).getRegex(),hr={...we,lheading:lr,table:Ze,paragraph:d(be).replace("hr",j).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",Ze).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",se).getRegex()},gr={...we,html:d(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",me).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:C,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:d(be).replace("hr",j).replace("heading",` *#{1,6} *[^
4
4
  ]`).replace("lheading",rt).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},dr=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,kr=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,st=/^( {2,}|\\)\n(?!\s*$)/,br=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,D=/[\p{P}\p{S}]/u,ie=/[\s\p{P}\p{S}]/u,ye=/[^\s\p{P}\p{S}]/u,xr=d(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,ie).getRegex(),it=/(?!~)[\p{P}\p{S}]/u,mr=/(?!~)[\s\p{P}\p{S}]/u,wr=/(?:[^\s\p{P}\p{S}]|~)/u,yr=d(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",rr?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),at=/^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/,vr=d(at,"u").replace(/punct/g,D).getRegex(),Ar=d(at,"u").replace(/punct/g,it).getRegex(),lt="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",Sr=d(lt,"gu").replace(/notPunctSpace/g,ye).replace(/punctSpace/g,ie).replace(/punct/g,D).getRegex(),Tr=d(lt,"gu").replace(/notPunctSpace/g,wr).replace(/punctSpace/g,mr).replace(/punct/g,it).getRegex(),Rr=d("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,ye).replace(/punctSpace/g,ie).replace(/punct/g,D).getRegex(),$r=d(/^~~?(?:((?!~)punct)|[^\s~])/,"u").replace(/punct/g,D).getRegex(),Lr="^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)",_r=d(Lr,"gu").replace(/notPunctSpace/g,ye).replace(/punctSpace/g,ie).replace(/punct/g,D).getRegex(),Er=d(/\\(punct)/,"gu").replace(/punct/g,D).getRegex(),zr=d(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),Cr=d(me).replace("(?:-->|$)","-->").getRegex(),Ir=d("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",Cr).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),te=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/,Pr=d(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace("label",te).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),ot=d(/^!?\[(label)\]\[(ref)\]/).replace("label",te).replace("ref",xe).getRegex(),ct=d(/^!?\[(ref)\](?:\[\])?/).replace("ref",xe).getRegex(),Or=d("reflink|nolink(?!\\()","g").replace("reflink",ot).replace("nolink",ct).getRegex(),Xe=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,ve={_backpedal:C,anyPunctuation:Er,autolink:zr,blockSkip:yr,br:st,code:kr,del:C,delLDelim:C,delRDelim:C,emStrongLDelim:vr,emStrongRDelimAst:Sr,emStrongRDelimUnd:Rr,escape:dr,link:Pr,nolink:ct,punctuation:xr,reflink:ot,reflinkSearch:Or,tag:Ir,text:br,url:C},qr={...ve,link:d(/^!?\[(label)\]\((.*?)\)/).replace("label",te).getRegex(),reflink:d(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",te).getRegex()},fe={...ve,emStrongRDelimAst:Tr,emStrongLDelim:Ar,delLDelim:$r,delRDelim:_r,url:d(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",Xe).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:d(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",Xe).getRegex()},Br={...fe,br:d(st).replace("{2,}","*").getRegex(),text:d(fe.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},ee={normal:we,gfm:hr,pedantic:gr},H={normal:ve,gfm:fe,breaks:Br,pedantic:qr},Dr={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},Qe=e=>Dr[e];function S(e,t){if(t){if(w.escapeTest.test(e))return e.replace(w.escapeReplace,Qe)}else if(w.escapeTestNoEncode.test(e))return e.replace(w.escapeReplaceNoEncode,Qe);return e}function Ue(e){try{e=encodeURI(e).replace(w.percentDecode,"%")}catch{return null}return e}function Je(e,t){let r=e.replace(w.findPipe,(i,a,o)=>{let l=!1,u=a;for(;--u>=0&&o[u]==="\\";)l=!l;return l?"|":" |"}),s=r.split(w.splitPipe),n=0;if(s[0].trim()||s.shift(),s.length>0&&!s.at(-1)?.trim()&&s.pop(),t)if(s.length>t)s.splice(t);else for(;s.length<t;)s.push("");for(;n<s.length;n++)s[n]=s[n].trim().replace(w.slashPipe,"|");return s}function $(e,t,r){let s=e.length;if(s===0)return"";let n=0;for(;n<s;){let i=e.charAt(s-n-1);if(i===t&&!r)n++;else if(i!==t&&r)n++;else break}return e.slice(0,s-n)}function Ke(e){let t=e.split(`
5
5
  `),r=t.length-1;for(;r>=0&&!t[r].trim();)r--;return t.length-r<=2?e:t.slice(0,r+1).join(`
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{b as e,c as i}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as s,y as a}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";var t=class extends s{static{this.properties={agent:0,context:0}}async getContext(){return e(this.context)?await this.context():this.context}load(){i(this)}};a("arcgis-assistant-agent",t);export{t as ArcgisAssistantAgent};
2
+ import{b as e,c as i}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as s,y as a}from"./GW636L6T.js";import"./CFDTXKJ6.js";var t=class extends s{static{this.properties={agent:0,context:0}}async getContext(){return e(this.context)?await this.context():this.context}load(){i(this)}};a("arcgis-assistant-agent",t);export{t as ArcgisAssistantAgent};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as n}from"./KADK7ZYA.js";import"./YGW7TUNX.js";import{g as a,h as e,n as s,v as c,y as l}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";var o=a``,i=class extends c{constructor(){super(...arguments),this.#t=[],this._messages=n({blocking:!0}),this.arcgisCancel=s(),this.arcgisSubmit=s()}static{this.properties={type:1,message:1,options:0}}static{this.styles=o}#t;_renderInterruptOptions(){switch(this.type){case"single-select":return e`<calcite-list selection-mode=single-persist .label=${this._messages.optionsLabel} @calciteListChange=${t=>this.#t=t.target.selectedItems[0]?.value}>${this.options?.map(t=>e`<calcite-list-item .label=${t} .value=${t}></calcite-list-item>`)}</calcite-list>`;case"multi-select":return e`<calcite-list selection-mode=multiple .label=${this._messages.optionsLabel} @calciteListChange=${t=>this.#t=t.target.selectedItems.map(r=>r.value)}>${this.options?.map(t=>e`<calcite-list-item .label=${t} .value=${t}></calcite-list-item>`)}</calcite-list>`;case"boolean-choice":return null;case"text-input":return e`<calcite-input .label=${this._messages.enterTextLabel} @calciteInputInput=${t=>this.#t=t.target.value}></calcite-input>`}}render(){return e`<calcite-panel .description=${this.message}>${this._renderInterruptOptions()}<calcite-button slot=footer-end appearance=outline @click=${()=>this.arcgisCancel.emit()}>${this._messages.cancelButtonLabel}</calcite-button><calcite-button slot=footer-end appearance=solid @click=${()=>this.arcgisSubmit.emit(this.type==="boolean-choice"?!0:this.#t)}>${this._messages.submitButtonLabel}</calcite-button></calcite-panel>`}};l("arcgis-assistant-interrupt",i);export{i as ArcgisAssistantInterrupt};
2
+ import{a as n}from"./A2EDNDZP.js";import"./YGW7TUNX.js";import{g as a,h as e,n as s,v as c,y as l}from"./GW636L6T.js";import"./CFDTXKJ6.js";var o=a``,i=class extends c{constructor(){super(...arguments),this.#t=[],this._messages=n({blocking:!0}),this.arcgisCancel=s(),this.arcgisSubmit=s()}static{this.properties={type:1,message:1,options:0}}static{this.styles=o}#t;_renderInterruptOptions(){switch(this.type){case"single-select":return e`<calcite-list selection-mode=single-persist .label=${this._messages.optionsLabel} @calciteListChange=${t=>this.#t=t.target.selectedItems[0]?.value}>${this.options?.map(t=>e`<calcite-list-item .label=${t} .value=${t}></calcite-list-item>`)}</calcite-list>`;case"multi-select":return e`<calcite-list selection-mode=multiple .label=${this._messages.optionsLabel} @calciteListChange=${t=>this.#t=t.target.selectedItems.map(r=>r.value)}>${this.options?.map(t=>e`<calcite-list-item .label=${t} .value=${t}></calcite-list-item>`)}</calcite-list>`;case"boolean-choice":return null;case"text-input":return e`<calcite-input .label=${this._messages.enterTextLabel} @calciteInputInput=${t=>this.#t=t.target.value}></calcite-input>`}}render(){return e`<calcite-panel .description=${this.message}>${this._renderInterruptOptions()}<calcite-button slot=footer-end appearance=outline @click=${()=>this.arcgisCancel.emit()}>${this._messages.cancelButtonLabel}</calcite-button><calcite-button slot=footer-end appearance=solid @click=${()=>this.arcgisSubmit.emit(this.type==="boolean-choice"?!0:this.#t)}>${this._messages.submitButtonLabel}</calcite-button></calcite-panel>`}};l("arcgis-assistant-interrupt",i);export{i as ArcgisAssistantInterrupt};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as l}from"./KADK7ZYA.js";import"./YGW7TUNX.js";import{g as a,h as e,k as o,t as i,u as n,v as r,y as c}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";export default $arcgis.t(([{watch:d}])=>{var g=a`.container{display:flex;align-items:center;width:100%;justify-content:space-between;gap:var(--calcite-spacing-xs)}.start,.end{display:flex;align-items:center;gap:var(--calcite-spacing-xs)}`,t=class extends r{constructor(){super(...arguments),this._messages=l({blocking:!0}),this._endRef=i(),this._showLog=!1,this.feedbackEnabled=!1,this.logEnabled=!1,this.copyEnabled=!1,this.readAloudEnabled=!1}static{this.properties={_showLog:16,feedbackEnabled:5,logEnabled:5,copyEnabled:5,readAloudEnabled:5,message:0}}static{this.styles=g}loaded(){this.manager.onLifecycle(()=>[d(()=>this._showLog,()=>this._scrollToEnd())])}_scrollToEnd(){requestAnimationFrame(()=>{this._endRef.value?.scrollIntoView({behavior:"smooth",block:"end"})})}_renderCopyButton(){return!this.message?.error&&this.copyEnabled?e`<calcite-action id=action-copy icon=copy-to-clipboard scale=s @click=${async()=>{try{let s=this.message?.content?.trim();s&&await navigator.clipboard.writeText(s)}catch(s){o("warn","assistant-message-footer","Failed to copy text to clipboard",{once:!0,detail:{error:s}})}}} text></calcite-action><calcite-tooltip reference-element=action-copy overlay-positioning=fixed placement=bottom><span>${this._messages.copyButtonLabel}</span></calcite-tooltip>`:null}_renderLogButton(){return this.message?.log?.length&&this.logEnabled?e`<calcite-action id=action-log icon=access-string-results scale=s @click=${()=>this._showLog=!this._showLog} .text=${this._messages.logButtonLabel} .active=${this._showLog}></calcite-action><calcite-tooltip reference-element=action-log overlay-positioning=fixed placement=bottom><span>${this._messages.logButtonLabel}</span></calcite-tooltip>`:null}_renderReadAloudButton(){return e`<arcgis-assistant-message-read-aloud .message=${this.message} .readAloudEnabled=${this.readAloudEnabled}></arcgis-assistant-message-read-aloud>`}_renderLog(){return e`<arcgis-assistant-message-log .log=${this.message?.log} .showLog=${this._showLog} .logEnabled=${this.logEnabled}></arcgis-assistant-message-log>`}_renderFeedback(){return e`<arcgis-assistant-message-feedback .message=${this.message} .feedbackEnabled=${this.feedbackEnabled}></arcgis-assistant-message-feedback>`}render(){return e`${this._renderLog()}<div class="container"><div class="start">${this._renderCopyButton()}${this._renderLogButton()}${this._renderReadAloudButton()}<slot name=footer-actions-start></slot></div><div class="end"><slot name=footer-actions-end></slot>${this._renderFeedback()}</div></div><div ${n(this._endRef)}></div>`}};c("arcgis-assistant-message-footer",t);return t},"core/reactiveUtils")
2
+ import{a as l}from"./A2EDNDZP.js";import"./YGW7TUNX.js";import{g as a,h as e,k as o,t as i,u as n,v as r,y as c}from"./GW636L6T.js";import"./CFDTXKJ6.js";export default $arcgis.t(([{watch:d}])=>{var g=a`.container{display:flex;align-items:center;width:100%;justify-content:space-between;gap:var(--calcite-spacing-xs)}.start,.end{display:flex;align-items:center;gap:var(--calcite-spacing-xs)}`,t=class extends r{constructor(){super(...arguments),this._messages=l({blocking:!0}),this._endRef=i(),this._showLog=!1,this.feedbackEnabled=!1,this.logEnabled=!1,this.copyEnabled=!1,this.readAloudEnabled=!1}static{this.properties={_showLog:16,feedbackEnabled:5,logEnabled:5,copyEnabled:5,readAloudEnabled:5,message:0}}static{this.styles=g}loaded(){this.manager.onLifecycle(()=>[d(()=>this._showLog,()=>this._scrollToEnd())])}_scrollToEnd(){requestAnimationFrame(()=>{this._endRef.value?.scrollIntoView({behavior:"smooth",block:"end"})})}_renderCopyButton(){return!this.message?.error&&this.copyEnabled?e`<calcite-action id=action-copy icon=copy-to-clipboard scale=s @click=${async()=>{try{let s=this.message?.content?.trim();s&&await navigator.clipboard.writeText(s)}catch(s){o("warn","assistant-message-footer","Failed to copy text to clipboard",{once:!0,detail:{error:s}})}}} text></calcite-action><calcite-tooltip reference-element=action-copy overlay-positioning=fixed placement=bottom><span>${this._messages.copyButtonLabel}</span></calcite-tooltip>`:null}_renderLogButton(){return this.message?.log?.length&&this.logEnabled?e`<calcite-action id=action-log icon=access-string-results scale=s @click=${()=>this._showLog=!this._showLog} .text=${this._messages.logButtonLabel} .active=${this._showLog}></calcite-action><calcite-tooltip reference-element=action-log overlay-positioning=fixed placement=bottom><span>${this._messages.logButtonLabel}</span></calcite-tooltip>`:null}_renderReadAloudButton(){return e`<arcgis-assistant-message-read-aloud .message=${this.message} .readAloudEnabled=${this.readAloudEnabled}></arcgis-assistant-message-read-aloud>`}_renderLog(){return e`<arcgis-assistant-message-log .log=${this.message?.log} .showLog=${this._showLog} .logEnabled=${this.logEnabled}></arcgis-assistant-message-log>`}_renderFeedback(){return e`<arcgis-assistant-message-feedback .message=${this.message} .feedbackEnabled=${this.feedbackEnabled}></arcgis-assistant-message-feedback>`}render(){return e`${this._renderLog()}<div class="container"><div class="start">${this._renderCopyButton()}${this._renderLogButton()}${this._renderReadAloudButton()}<slot name=footer-actions-start></slot></div><div class="end"><slot name=footer-actions-end></slot>${this._renderFeedback()}</div></div><div ${n(this._endRef)}></div>`}};c("arcgis-assistant-message-footer",t);return t},"core/reactiveUtils")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import c from"./TDBJ6YZ6.js";import b from"./2E6GEUNH.js";import"./WI3JQXAS.js";import{a as r,c as a}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as s,y as e}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";export default $arcgis.t(([,{d:i}])=>{var t=class extends s{constructor(){super(...arguments),this.agent=i}static{this.properties={referenceElement:1}}#t;getContext(){if(!this.#t)throw new Error("arcgis-assistant-help-agent requires a mapView");return{mapView:this.#t}}load(){this.#t=r(this,"arcgis-assistant-help-agent"),a(this)}};e("arcgis-assistant-help-agent",t);return t},b,c)
2
+ import c from"./TDBJ6YZ6.js";import b from"./2E6GEUNH.js";import"./WI3JQXAS.js";import{a as r,c as a}from"./B4DEC7PH.js";import"./KVH3PDVW.js";import"./YGW7TUNX.js";import{v as s,y as e}from"./GW636L6T.js";import"./CFDTXKJ6.js";export default $arcgis.t(([,{d:i}])=>{var t=class extends s{constructor(){super(...arguments),this.agent=i}static{this.properties={referenceElement:1}}#t;getContext(){if(!this.#t)throw new Error("arcgis-assistant-help-agent requires a mapView");return{mapView:this.#t}}load(){this.#t=r(this,"arcgis-assistant-help-agent"),a(this)}};e("arcgis-assistant-help-agent",t);return t},b,c)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{g as o,h as i,v as p,y as a}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";var n=o`:host{display:block}`,t=class extends p{static{this.properties={block:0}}static{this.styles=n}_renderSuggestedPrompts(s){if(s.type!=="suggested-prompts")return null;let r=s.data?.prompts,e=Array.isArray(r)?r.filter(l=>typeof l=="string"):[];return e.length?i`<arcgis-assistant-suggested-prompts .prompts=${e}></arcgis-assistant-suggested-prompts>`:null}_renderBlock(s){return s.type==="suggested-prompts"?this._renderSuggestedPrompts(s):null}render(){return this.block?this._renderBlock(this.block):null}};a("arcgis-assistant-message-block",t);export{t as ArcgisAssistantMessageBlock};
2
+ import{g as o,h as i,v as p,y as a}from"./GW636L6T.js";import"./CFDTXKJ6.js";var n=o`:host{display:block}`,t=class extends p{static{this.properties={block:0}}static{this.styles=n}_renderSuggestedPrompts(s){if(s.type!=="suggested-prompts")return null;let r=s.data?.prompts,e=Array.isArray(r)?r.filter(l=>typeof l=="string"):[];return e.length?i`<arcgis-assistant-suggested-prompts .prompts=${e}></arcgis-assistant-suggested-prompts>`:null}_renderBlock(s){return s.type==="suggested-prompts"?this._renderSuggestedPrompts(s):null}render(){return this.block?this._renderBlock(this.block):null}};a("arcgis-assistant-message-block",t);export{t as ArcgisAssistantMessageBlock};
@@ -1,3 +1,3 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as e,b as n}from"./C5BYUKXO.js";import{g as r,h as i,v as s,y as c}from"./SGGBOB5K.js";import"./CFDTXKJ6.js";var l=r`.container{border-radius:var(--calcite-border-radius);margin-bottom:var(--calcite-spacing-md)}.block{margin:0;background-color:var(--calcite-color-foreground-1);width:100%;max-height:300px;overflow:auto}.entry{margin-left:var(--calcite-spacing-sm);padding:var(--calcite-spacing-xxs) var(--calcite-spacing-lg);border-left:1px solid var(--calcite-color-border-1)}`,o=class extends s{constructor(){super(...arguments),this.logEnabled=!1,this.showLog=!1}static{this.properties={logEnabled:5,showLog:5,log:0}}static{this.styles=l}render(){return this.log?.length&&this.showLog&&this.logEnabled?i`<div class="container"><div class="block"><calcite-accordion appearance=transparent icon-position=start icon-type=chevron scale=s>${this.log.map(a=>{let t=a.includes(`
2
+ import{a as e,b as n}from"./IWK6YKIU.js";import{g as r,h as i,v as s,y as c}from"./GW636L6T.js";import"./CFDTXKJ6.js";var l=r`.container{border-radius:var(--calcite-border-radius);margin-bottom:var(--calcite-spacing-md)}.block{margin:0;background-color:var(--calcite-color-foreground-1);width:100%;max-height:300px;overflow:auto}.entry{margin-left:var(--calcite-spacing-sm);padding:var(--calcite-spacing-xxs) var(--calcite-spacing-lg);border-left:1px solid var(--calcite-color-border-1)}`,o=class extends s{constructor(){super(...arguments),this.logEnabled=!1,this.showLog=!1}static{this.properties={logEnabled:5,showLog:5,log:0}}static{this.styles=l}render(){return this.log?.length&&this.showLog&&this.logEnabled?i`<div class="container"><div class="block"><calcite-accordion appearance=transparent icon-position=start icon-type=chevron scale=s>${this.log.map(a=>{let t=a.includes(`
3
3
  `)||a.length>70;return i`<calcite-accordion-item .heading=${t?`${a.substring(0,70)}...`:a} .expanded=${t}><div class="entry">${t?e(n(a)):null}</div></calcite-accordion-item>`})}</calcite-accordion></div></div>`:null}};c("arcgis-assistant-message-log",o);export{o as ArcgisAssistantMessageLog};