@esri/calcite-components 5.0.0-next.5 → 5.0.0-next.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/calcite/{AUIOWPFN.js → 2IIGKMQ6.js} +2 -2
- package/dist/calcite/{7ZNR3GNI.js → 2XFESLAQ.js} +2 -2
- package/dist/calcite/{6VPACZP5.js → 3COSYM4H.js} +2 -2
- package/dist/calcite/{XZTRPLLK.js → 3ISWQGU4.js} +2 -2
- package/dist/calcite/{APIFFM3O.js → 3M2X4DMO.js} +2 -2
- package/dist/calcite/{U3KRKTQY.js → 3W422TPV.js} +2 -2
- package/dist/calcite/{F6EDNLSI.js → 43KOILAW.js} +2 -2
- package/dist/calcite/{ZLR2B6GQ.js → 44XNJNTA.js} +1 -1
- package/dist/calcite/{4JZMONLD.js → 4FSJL2OC.js} +2 -2
- package/dist/calcite/{JJWGSKGI.js → 4M5YCJ4Q.js} +2 -2
- package/dist/calcite/{3HXEF55M.js → 4YTONN4P.js} +2 -2
- package/dist/calcite/{NQJMDHT5.js → 53JXVKUS.js} +2 -2
- package/dist/calcite/{YSBWKH76.js → 56HP62NE.js} +1 -1
- package/dist/calcite/{K3AHNZL7.js → 57TYRZR3.js} +2 -2
- package/dist/calcite/{V4NPQ4WA.js → 5BQ76NQW.js} +2 -2
- package/dist/calcite/{C2X6VADY.js → 5HV6X5DX.js} +2 -2
- package/dist/calcite/{6VQ5IL36.js → 5T7WLABP.js} +2 -2
- package/dist/calcite/{BHBYSC5H.js → 62XLJEVX.js} +2 -2
- package/dist/calcite/{GUT2GKDG.js → 65HZ2HOS.js} +2 -2
- package/dist/calcite/{UOZDXXIF.js → 6EEMG3AJ.js} +2 -2
- package/dist/calcite/{X374PRV7.js → 6EKZQPKT.js} +2 -2
- package/dist/calcite/{OMKDUGKV.js → 6FCYAKPP.js} +2 -2
- package/dist/calcite/{BHU252WA.js → 6GKHPG2T.js} +2 -2
- package/dist/calcite/{W72YZH73.js → 6OLYWF6Z.js} +2 -2
- package/dist/calcite/{B5JXPZDV.js → 6PMY6MUE.js} +2 -2
- package/dist/calcite/{KRHM7ACI.js → 6YVXONLB.js} +2 -2
- package/dist/calcite/{HT5KXL4J.js → 76DFVIQ3.js} +2 -2
- package/dist/calcite/{DZWPXJWV.js → 7AG2R6XN.js} +2 -2
- package/dist/calcite/{5IPJANUU.js → 7DQ4G2FS.js} +2 -2
- package/dist/calcite/{RND3V33U.js → 7EIPWPP6.js} +1 -1
- package/dist/calcite/{4ARTWEEZ.js → 7GYHOBTA.js} +2 -2
- package/dist/calcite/{NULQJBCW.js → 7XEO6UJ3.js} +2 -2
- package/dist/calcite/{VIWDW2WZ.js → A6DNGYP7.js} +2 -2
- package/dist/calcite/{I53JH7YD.js → A6ZYDDPX.js} +2 -2
- package/dist/calcite/{YSP6WWQB.js → A7OBU3ZB.js} +1 -1
- package/dist/calcite/{BEUZYBM5.js → AANSYYFF.js} +2 -2
- package/dist/calcite/{Y442PVMQ.js → ABFHGJOG.js} +2 -2
- package/dist/calcite/{H2FWQITV.js → ABRDCSJF.js} +1 -1
- package/dist/calcite/{PFKUB7JD.js → AHOADFZ7.js} +2 -2
- package/dist/calcite/{PSNA5FAF.js → AIANT2RL.js} +2 -2
- package/dist/calcite/{BNKVQYLQ.js → B36ZLEKI.js} +2 -2
- package/dist/calcite/{PFDLGOVS.js → B53J7Q5J.js} +2 -2
- package/dist/calcite/{SXB76NOR.js → BKNGM5YO.js} +2 -2
- package/dist/calcite/{LYDOM6VQ.js → BMB7PJZB.js} +2 -2
- package/dist/calcite/{ZV7YL7QG.js → BOFKO4PD.js} +2 -2
- package/dist/calcite/{AQ4DKRX6.js → BTK24FM2.js} +2 -2
- package/dist/calcite/{LH7245HX.js → CFWXX2ZT.js} +2 -2
- package/dist/calcite/{IKDSO2OB.js → CYUZWU4F.js} +2 -2
- package/dist/calcite/{ALDDSDTX.js → CZF6KYOX.js} +1 -1
- package/dist/calcite/{HVF3RXXI.js → DATE73WS.js} +2 -2
- package/dist/calcite/{VBRBI7IU.js → DEJFI4YA.js} +2 -2
- package/dist/calcite/{2VKJIYLT.js → DN6V2M24.js} +1 -1
- package/dist/calcite/{C4S2BOWK.js → DUM3R2CL.js} +2 -2
- package/dist/calcite/{7PFVW4JF.js → E5NO42AW.js} +1 -1
- package/dist/calcite/{2YBCAJSV.js → EFDQMGZP.js} +2 -2
- package/dist/calcite/{MVLJJOH2.js → EHZXDIG5.js} +2 -2
- package/dist/calcite/{HU4SHWE7.js → EOWCTVN7.js} +2 -2
- package/dist/calcite/{VMWAAH5B.js → FHRBYILV.js} +2 -2
- package/dist/calcite/{LJI5SYGA.js → FMB23RBB.js} +1 -1
- package/dist/calcite/{6J5W2PAJ.js → FQKP2XIR.js} +2 -2
- package/dist/calcite/{ROWPIQLT.js → FSNEMWMV.js} +2 -2
- package/dist/calcite/{2KH3AUCG.js → FWMD4ANX.js} +2 -2
- package/dist/calcite/{R73QB7MJ.js → GLUJXIHJ.js} +2 -2
- package/dist/calcite/{RFALVOKT.js → GS2BRYGH.js} +2 -2
- package/dist/calcite/{PJOGMC7F.js → GSSIFYMO.js} +2 -2
- package/dist/calcite/{3NOZ7M75.js → GWC7UZVN.js} +2 -2
- package/dist/calcite/{K5GJLIBR.js → GWYUQTSG.js} +2 -2
- package/dist/calcite/{7NUC3WBG.js → H2NP25UI.js} +1 -1
- package/dist/calcite/{CIU4VM7X.js → H3GTITDX.js} +2 -2
- package/dist/calcite/{IHEW664E.js → HBSTMWBE.js} +2 -2
- package/dist/calcite/{5AL5GWRD.js → HM4RW4PL.js} +2 -2
- package/dist/calcite/{C3BQ4W7K.js → HURJRVCG.js} +2 -2
- package/dist/calcite/{ZSMNT5VS.js → HZJQA7EQ.js} +2 -2
- package/dist/calcite/{UGI3YWJM.js → IAOITTID.js} +2 -2
- package/dist/calcite/{XNLWKJLM.js → ID4WJFNU.js} +2 -2
- package/dist/calcite/{H5ANNFJC.js → IFQNEPTP.js} +2 -2
- package/dist/calcite/{5LAPR75M.js → IJDY7EKO.js} +2 -2
- package/dist/calcite/{7DTG5KDL.js → IODUDIBK.js} +2 -2
- package/dist/calcite/{7QP5BUGE.js → JD35MQMV.js} +2 -2
- package/dist/calcite/{LROCCBRV.js → JD5Y5FIJ.js} +2 -2
- package/dist/calcite/{HBHSBTMM.js → JJP2FEER.js} +1 -1
- package/dist/calcite/{WBGRGCXR.js → JNCHO6X5.js} +2 -2
- package/dist/calcite/{LRKWQ3C3.js → JSS6WCPJ.js} +2 -2
- package/dist/calcite/{NLYYOFNV.js → JTAYXV5Y.js} +1 -1
- package/dist/calcite/{RI3NRBMI.js → JVYKUU2B.js} +2 -2
- package/dist/calcite/{DOH3ZW2R.js → K2RWUB5W.js} +2 -2
- package/dist/calcite/{XRSYDXWZ.js → KDHLLH5G.js} +1 -1
- package/dist/calcite/{BE5OB2TH.js → KLLDUBU7.js} +2 -2
- package/dist/calcite/{5K2Z2TMW.js → KR5QX3PG.js} +2 -2
- package/dist/calcite/{DONAES6Q.js → L63HBU2O.js} +2 -2
- package/dist/calcite/{GE7SQF7S.js → LDFECFWX.js} +2 -2
- package/dist/calcite/{2IWOXJH7.js → LFSTWFMB.js} +2 -2
- package/dist/calcite/{VQMSSO2U.js → LFYXGVGK.js} +2 -2
- package/dist/calcite/{Q23OEAP2.js → LNKZ4ULL.js} +2 -2
- package/dist/calcite/{DJVVGNTK.js → LX3J3Q7Q.js} +1 -1
- package/dist/calcite/{DDW4WTS2.js → LX7GBILP.js} +2 -2
- package/dist/calcite/{KT4EQWT6.js → MEWZXHJ6.js} +2 -2
- package/dist/calcite/{W5OJOVZY.js → MPYXWS5E.js} +1 -1
- package/dist/calcite/{UN7GLLXI.js → MTRDCPVY.js} +2 -2
- package/dist/calcite/{2HKRJLBG.js → MYWUD5PR.js} +2 -2
- package/dist/calcite/{7XJU5OTS.js → N3QXJKKO.js} +2 -2
- package/dist/calcite/{Q2GRCTSJ.js → NHRWRXH2.js} +2 -2
- package/dist/calcite/{AUF6YLAM.js → NKMBE4R4.js} +2 -2
- package/dist/calcite/{KH3UKQ2D.js → NKYR42W6.js} +2 -2
- package/dist/calcite/{VYFT5EAY.js → NOOPM2CL.js} +1 -1
- package/dist/calcite/{DDXY7TRY.js → NQF73COG.js} +2 -2
- package/dist/calcite/{YV7DKMEQ.js → NSIT4HJE.js} +2 -2
- package/dist/calcite/{ZVWKN3G7.js → O72KETNZ.js} +2 -2
- package/dist/calcite/{Y3HXK6MO.js → OBY2JHHI.js} +2 -2
- package/dist/calcite/{MP3OWQ2A.js → OD7IPBKO.js} +2 -2
- package/dist/calcite/{HXGFAPCM.js → OFHMIOCW.js} +2 -2
- package/dist/calcite/{S5CLKCGJ.js → OFO7DXMT.js} +1 -1
- package/dist/calcite/{2GG4AF5T.js → OXZ2Y5YM.js} +1 -1
- package/dist/calcite/{PVL2DQVP.js → OYVYZ6ZO.js} +2 -2
- package/dist/calcite/{WWJXVV6U.js → P6BUUDOL.js} +2 -2
- package/dist/calcite/{OCT7LR2O.js → PBO64SRK.js} +1 -1
- package/dist/calcite/{3YZG7MA3.js → PCGNN5RO.js} +2 -2
- package/dist/calcite/{PU5TGCQG.js → PMWGEAYN.js} +2 -2
- package/dist/calcite/{V3ZR6RFK.js → POOA337X.js} +1 -1
- package/dist/calcite/{ZAQTILTS.js → PPV5DY5L.js} +2 -2
- package/dist/calcite/{4GHB4NY4.js → PQDB6CTL.js} +2 -2
- package/dist/calcite/{A4CO6B7Z.js → PRLHDLWI.js} +2 -2
- package/dist/calcite/{QF6F6CY3.js → Q4IQBOWU.js} +2 -2
- package/dist/calcite/{CUL3VHSD.js → QCGVJHJ6.js} +2 -2
- package/dist/calcite/{IEL7YV5C.js → QYN6LQ5J.js} +2 -2
- package/dist/calcite/{N5MSFOLW.js → REY2OA4D.js} +2 -2
- package/dist/calcite/{62OUMNJ6.js → RLF4GWLJ.js} +2 -2
- package/dist/calcite/{OFZACK2Y.js → RW5EELAZ.js} +2 -2
- package/dist/calcite/{MEFMO7UB.js → SHFV6LYT.js} +2 -2
- package/dist/calcite/{PLD7OLLJ.js → SL3VKZG5.js} +2 -2
- package/dist/calcite/{ZZGPQLEW.js → SLWHNU7X.js} +2 -2
- package/dist/calcite/{W6EWFSR3.js → SSLEHUOY.js} +2 -2
- package/dist/calcite/{WOTQIMPZ.js → SXK4ATVN.js} +2 -2
- package/dist/calcite/{CTLGVBKW.js → SXMKRRD6.js} +2 -2
- package/dist/calcite/{RRP2E2T3.js → SXOKB2BX.js} +2 -2
- package/dist/calcite/{ZTOBC3PN.js → SZXBPZ7S.js} +2 -2
- package/dist/calcite/{73LRFHS4.js → T3QJCLEX.js} +2 -2
- package/dist/calcite/{3266GV6Z.js → TBM5T67T.js} +2 -2
- package/dist/calcite/{CQMVTE7J.js → TOSB6ECB.js} +2 -2
- package/dist/calcite/{BFINWHLX.js → TTLR3A5P.js} +2 -2
- package/dist/calcite/{DSEMLW7Z.js → TUAQEJC4.js} +2 -2
- package/dist/calcite/{7IYAKB7Q.js → TWGPU2HX.js} +2 -2
- package/dist/calcite/{WTY55PPZ.js → TYPQP3Q3.js} +2 -2
- package/dist/calcite/{YCLOS6NX.js → U74QHS5H.js} +2 -2
- package/dist/calcite/{UNJRBV2R.js → UCG3QU7A.js} +2 -2
- package/dist/calcite/{7IHVHMIY.js → UKQ6KSXO.js} +2 -2
- package/dist/calcite/{LQ3URZCB.js → ULXDFGLX.js} +2 -2
- package/dist/calcite/{NSBK36H4.js → UQ4HIO7J.js} +2 -2
- package/dist/calcite/{N7OO7R2S.js → UROEAN4Q.js} +2 -2
- package/dist/calcite/{QFT74HW3.js → VCXMHEPN.js} +2 -2
- package/dist/calcite/{NID6WJOW.js → VMEYQQVI.js} +2 -2
- package/dist/calcite/{NU57UAAO.js → VS3YLYMZ.js} +1 -1
- package/dist/calcite/{H5DKF7F3.js → VUYRIPVA.js} +2 -2
- package/dist/calcite/{BYZPKQRD.js → VYLJCYTD.js} +2 -2
- package/dist/calcite/{Q3MUDXRY.js → WBXWOFF6.js} +2 -2
- package/dist/calcite/{SMRCCHJE.js → WC4TGTDM.js} +2 -2
- package/dist/calcite/WXESTAXY.js +4 -0
- package/dist/calcite/{VKRWRFEJ.js → WYLLIW2W.js} +2 -2
- package/dist/calcite/{3KUVOQAL.js → X46HC2YH.js} +2 -2
- package/dist/calcite/{WPTOKN7K.js → XIXFKVFZ.js} +1 -1
- package/dist/calcite/{FZIUTVKD.js → XJ4SR7WO.js} +1 -1
- package/dist/calcite/{SGJU36YV.js → XQAX6FNF.js} +2 -2
- package/dist/calcite/{CF6DTFNX.js → XTDUXEIX.js} +2 -2
- package/dist/calcite/{45F6XOYY.js → XTYQVPDC.js} +2 -2
- package/dist/calcite/{AHOXXRX5.js → YG5VYPTQ.js} +2 -2
- package/dist/calcite/{SZWYWOXZ.js → YQQN42G5.js} +2 -2
- package/dist/calcite/{PSCEW76J.js → ZAD5LV3P.js} +2 -2
- package/dist/calcite/{67HVFNHP.js → ZEMRH6DW.js} +2 -2
- package/dist/calcite/{XNFJXDQ6.js → ZJD56MA6.js} +2 -2
- package/dist/calcite/{CVLFEMH2.js → ZOBQ5UTK.js} +2 -2
- package/dist/calcite/{CJWGQETT.js → ZOINAXKM.js} +2 -2
- package/dist/calcite/{PZL4QWV5.js → ZPU3MCWK.js} +2 -2
- package/dist/calcite/calcite.esm.js +2 -2
- package/dist/chunks/runtime.js +3 -3
- package/dist/components/calcite-stepper/customElement.d.ts +0 -6
- package/dist/components/calcite-stepper/customElement.js +0 -2
- package/dist/docs/api.json +1 -10
- package/dist/docs/docs.json +1 -16
- package/dist/docs/vscode.html-custom-data.json +1 -1
- package/dist/docs/web-types.json +2 -12
- package/dist/index.d.ts +0 -1
- package/dist/types/lumina.d.ts +0 -1
- package/dist/types/preact.d.ts +0 -1
- package/dist/types/preact10.d.ts +0 -1
- package/dist/types/react.d.ts +0 -1
- package/dist/types/stencil.d.ts +0 -1
- package/package.json +2 -2
- package/dist/calcite/T6Y6ZTWW.js +0 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*! All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
|
3
|
-
v5.0.0-next.
|
|
3
|
+
v5.0.0-next.6 */
|
|
4
4
|
var Q=globalThis,Y=Q.ShadowRoot&&(Q.ShadyCSS===void 0||Q.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,ut=Symbol(),It=new WeakMap,I=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==ut)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(Y&&t===void 0){let s=e!==void 0&&e.length===1;s&&(t=It.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&It.set(e,t))}return t}toString(){return this.cssText}},kt=o=>new I(typeof o=="string"?o:o+"",void 0,ut),$e=(o,...t)=>{let e=o.length===1?o[0]:t.reduce(((s,i,n)=>s+(r=>{if(r._$cssResult$===!0)return r.cssText;if(typeof r=="number")return r;throw Error("Value passed to 'css' function must be a 'css' function result: "+r+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+o[n+1]),o[0]);return new I(e,o,ut)},jt=(o,t)=>{if(Y)o.adoptedStyleSheets=t.map((e=>e instanceof CSSStyleSheet?e:e.styleSheet));else for(let e of t){let s=document.createElement("style"),i=Q.litNonce;i!==void 0&&s.setAttribute("nonce",i),s.textContent=e.cssText,o.appendChild(s)}},ft=Y?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:_e,getOwnPropertyDescriptor:Ae,getOwnPropertyNames:Ce,getOwnPropertySymbols:we,getPrototypeOf:Oe}=Object,X=globalThis,Ht=X.trustedTypes,Se=Ht?Ht.emptyScript:"",Te=X.reactiveElementPolyfillSupport,k=(o,t)=>o,Z={toAttribute(o,t){switch(t){case Boolean:o=o?Se: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:Z,reflect:!1,useDefault:!1,hasChanged:j};Symbol.metadata??=Symbol("metadata"),X.litPropertyMetadata??=new WeakMap;var b=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(),i=this.getPropertyDescriptor(t,s,e);i!==void 0&&_e(this.prototype,t,i)}}static getPropertyDescriptor(t,e,s){let{get:i,set:n}=Ae(this.prototype,t)??{get(){return this[e]},set(r){this[e]=r}};return{get:i,set(r){let a=i?.call(this);n?.call(this,r),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 i of s)this.createProperty(i,e[i])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[s,i]of e)this.elementProperties.set(s,i)}this._$Eh=new Map;for(let[e,s]of this.elementProperties){let i=this._$Eu(e,s);i!==void 0&&this._$Eh.set(i,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 i of s)e.unshift(ft(i))}else t!==void 0&&e.push(ft(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),i=this.constructor._$Eu(t,s);if(i!==void 0&&s.reflect===!0){let n=(s.converter?.toAttribute!==void 0?s.converter:Z).toAttribute(e,s.type);this._$Em=t,n==null?this.removeAttribute(i):this.setAttribute(i,n),this._$Em=null}}_$AK(t,e){let s=this.constructor,i=s._$Eh.get(t);if(i!==void 0&&this._$Em!==i){let n=s.getPropertyOptions(i),r=typeof n.converter=="function"?{fromAttribute:n.converter}:n.converter?.fromAttribute!==void 0?n.converter:Z;this._$Em=i;let a=r.fromAttribute(e,n.type);this[i]=a??this._$Ej?.get(i)??a,this._$Em=null}}requestUpdate(t,e,s){if(t!==void 0){let i=this.constructor,n=this[t];if(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:i,wrapped:n},r){s&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,r??e??this[t]),n!==!0||r!==void 0)||(this._$AL.has(t)||(this.hasUpdated||s||(e=void 0),this._$AL.set(t,e)),i===!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[i,n]of this._$Ep)this[i]=n;this._$Ep=void 0}let s=this.constructor.elementProperties;if(s.size>0)for(let[i,n]of s){let{wrapped:r}=n,a=this[i];r!==!0||this._$AL.has(i)||a===void 0||this.C(i,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){}};b.elementStyles=[],b.shadowRootOptions={mode:"open"},b[k("elementProperties")]=new Map,b[k("finalized")]=new Map,Te?.({ReactiveElement:b}),(X.reactiveElementVersions??=[]).push("2.1.1");var yt=globalThis,tt=yt.trustedTypes,Vt=tt?tt.createPolicy("lit-html",{createHTML:o=>o}):void 0,gt="$lit$",_=`lit$${Math.random().toFixed(9).slice(2)}$`,vt="?"+_,Pe=`<${vt}>`,S=document,z=()=>S.createComment(""),V=o=>o===null||typeof o!="object"&&typeof o!="function",Et=Array.isArray,Kt=o=>Et(o)||typeof o?.[Symbol.iterator]=="function",mt=`[
|
|
5
5
|
\f\r]`,H=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Bt=/-->/g,Wt=/>/g,w=RegExp(`>|${mt}(?:([^\\s"'>=/]+)(${mt}*=${mt}*(?:[^
|
|
6
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),Ft=/'/g,qt=/"/g,Jt=/^(?:script|style|textarea|title)$/i,$t=o=>(t,...e)=>({_$litType$:o,strings:t,values:e}),Cs=$t(1),ws=$t(2),Os=$t(3),f=Symbol.for("lit-noChange"),d=Symbol.for("lit-nothing"),Gt=new WeakMap,O=S.createTreeWalker(S,129);function Qt(o,t){if(!Et(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return Vt!==void 0?Vt.createHTML(t):t}var Yt=(o,t)=>{let e=o.length-1,s=[],i,n=t===2?"<svg>":t===3?"<math>":"",r=H;for(let a=0;a<e;a++){let c=o[a],l,u,h=-1,y=0;for(;y<c.length&&(r.lastIndex=y,u=r.exec(c),u!==null);)y=r.lastIndex,r===H?u[1]==="!--"?r=Bt:u[1]!==void 0?r=Wt:u[2]!==void 0?(Jt.test(u[2])&&(i=RegExp("</"+u[2],"g")),r=w):u[3]!==void 0&&(r=w):r===w?u[0]===">"?(r=i??H,h=-1):u[1]===void 0?h=-2:(h=r.lastIndex-u[2].length,l=u[1],r=u[3]===void 0?w:u[3]==='"'?qt:Ft):r===qt||r===Ft?r=w:r===Bt||r===Wt?r=H:(r=w,i=void 0);let g=r===w&&o[a+1].startsWith("/>")?" ":"";n+=r===H?c+Pe:h>=0?(s.push(l),c.slice(0,h)+gt+c.slice(h)+_+g):c+_+(h===-2?a:g)}return[Qt(o,n+(o[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),s]},B=class o{constructor({strings:t,_$litType$:e},s){let i;this.parts=[];let n=0,r=0,a=t.length-1,c=this.parts,[l,u]=Yt(t,e);if(this.el=o.createElement(l,s),O.currentNode=this.el.content,e===2||e===3){let h=this.el.content.firstChild;h.replaceWith(...h.childNodes)}for(;(i=O.nextNode())!==null&&c.length<a;){if(i.nodeType===1){if(i.hasAttributes())for(let h of i.getAttributeNames())if(h.endsWith(gt)){let y=u[r++],g=i.getAttribute(h).split(_),C=/([.?@])?(.*)/.exec(y);c.push({type:1,index:n,name:C[2],strings:g,ctor:C[1]==="."?st:C[1]==="?"?ot:C[1]==="@"?it:P}),i.removeAttribute(h)}else h.startsWith(_)&&(c.push({type:6,index:n}),i.removeAttribute(h));if(Jt.test(i.tagName)){let h=i.textContent.split(_),y=h.length-1;if(y>0){i.textContent=tt?tt.emptyScript:"";for(let g=0;g<y;g++)i.append(h[g],z()),O.nextNode(),c.push({type:2,index:++n});i.append(h[y],z())}}}else if(i.nodeType===8)if(i.data===vt)c.push({type:2,index:n});else{let h=-1;for(;(h=i.data.indexOf(_,h+1))!==-1;)c.push({type:7,index:n}),h+=_.length-1}n++}}static createElement(t,e){let s=S.createElement("template");return s.innerHTML=t,s}};function T(o,t,e=o,s){if(t===f)return t;let i=s!==void 0?e._$Co?.[s]:e._$Cl,n=V(t)?void 0:t._$litDirective$;return i?.constructor!==n&&(i?._$AO?.(!1),n===void 0?i=void 0:(i=new n(o),i._$AT(o,e,s)),s!==void 0?(e._$Co??=[])[s]=i:e._$Cl=i),i!==void 0&&(t=T(o,i._$AS(o,t.values),i,s)),t}var et=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,i=(t?.creationScope??S).importNode(e,!0);O.currentNode=i;let n=O.nextNode(),r=0,a=0,c=s[0];for(;c!==void 0;){if(r===c.index){let l;c.type===2?l=new U(n,n.nextSibling,this,t):c.type===1?l=new c.ctor(n,c.name,c.strings,this,t):c.type===6&&(l=new nt(n,this,t)),this._$AV.push(l),c=s[++a]}r!==c?.index&&(n=O.nextNode(),r++)}return O.currentNode=S,i}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++}},U=class o{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,s,i){this.type=2,this._$AH=d,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=i,this._$Cv=i?.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=T(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):Kt(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(S.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:s}=t,i=typeof s=="number"?this._$AC(t):(s.el===void 0&&(s.el=B.createElement(Qt(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===i)this._$AH.p(e);else{let n=new et(i,this),r=n.u(this.options);n.p(e),this.T(r),this._$AH=n}}_$AC(t){let e=Gt.get(t.strings);return e===void 0&&Gt.set(t.strings,e=new B(t)),e}k(t){Et(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,s,i=0;for(let n of t)i===e.length?e.push(s=new o(this.O(z()),this.O(z()),this,this.options)):s=e[i],s._$AI(n),i++;i<e.length&&(this._$AR(s&&s._$AB.nextSibling,i),e.length=i)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){let s=t.nextSibling;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,i,n){this.type=1,this._$AH=d,this._$AN=void 0,this.element=t,this.name=e,this._$AM=i,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,i){let n=this.strings,r=!1;if(n===void 0)t=T(this,t,e,0),r=!V(t)||t!==this._$AH&&t!==f,r&&(this._$AH=t);else{let a=t,c,l;for(t=n[0],c=0;c<n.length-1;c++)l=T(this,a[s+c],e,c),l===f&&(l=this._$AH[c]),r||=!V(l)||l!==this._$AH[c],l===d?t=d:t!==d&&(t+=(l??"")+n[c+1]),this._$AH[c]=l}r&&!i&&this.j(t)}j(t){t===d?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},st=class extends P{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===d?void 0:t}},ot=class extends P{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==d)}},it=class extends P{constructor(t,e,s,i,n){super(t,e,s,i,n),this.type=5}_$AI(t,e=this){if((t=T(this,t,e,0)??d)===f)return;let s=this._$AH,i=t===d&&s!==d||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,n=t!==d&&(s===d||i);i&&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)}},nt=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){T(this,t)}},Zt={M:gt,P:_,A:vt,C:1,L:Yt,R:et,D:Kt,V:T,I:U,H:P,N:ot,U:it,B:st,F:nt},Ne=yt.litHtmlPolyfillSupport;Ne?.(B,U),(yt.litHtmlVersions??=[]).push("3.3.1");var bt=(o,t,e)=>{let s=e?.renderBefore??t,i=s._$litPart$;if(i===void 0){let n=e?.renderBefore??null;s._$litPart$=i=new U(t.insertBefore(z(),n),n,void 0,e??{})}return i._$AI(o),i};var _t=globalThis,A=class extends b{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=bt(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return f}};A._$litElement$=!0,A.finalized=!0,_t.litElementHydrateSupport?.({LitElement:A});var De=_t.litElementPolyfillSupport;De?.({LitElement:A});(_t.litElementVersions??=[]).push("4.2.1");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),Hs=o=>typeof o?.then=="function";var F,D=o=>{F!==o&&(F=o,queueMicrotask(()=>F===o?F=void 0:0))},G=o=>F,N=[],Xt=o=>{if(o===void 0){N=[];return}let t=N.indexOf(o);N=t===-1?[...N,o]:N.slice(0,t+1),queueMicrotask(()=>N=[])},te=()=>N,R,zs=o=>{R!==o&&(R=o,queueMicrotask(()=>R===o?R=void 0:0))},Le=()=>{let o=R;return R=void 0,o},ee=async(o,t)=>{let e=at(o);if(e===void 0)return o;if(await e.ready,typeof t=="function"){let s=e.watchExports(i=>t(i,s))}return e.exports},se=async o=>{let t=at(o);return await t.ready,t},at=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},rt=!1,Vs=o=>{rt=!0;try{return o()}finally{rt=!1}};var $=class{constructor(){this.promise=new Promise((t,e)=>{this.resolve=t,this.reject=e})}},oe=(o,t)=>{let e=t>Ue?Re:t/Me,s=0,i=setInterval(()=>{s+=e,s>=t&&(clearInterval(i),o())},e);return i},Ue=4e3,Re=2e3,Me=4;var Ie=(o,t,e)=>{let s=Object.keys(o),i=s.length;M===void 0&&queueMicrotask(K),M??=new Map;let n=M.get(o);return n===void 0&&(n={callbacks:[],keyCount:i},M.set(o,n)),n.keyCount!==i&&(n.callbacks.forEach(r=>r(s)),n.callbacks=[],n.keyCount=i),n.callbacks.push(r=>{let a=l=>p(t,null,l),c=r[i];c===void 0?a(void 0):o[c]===e?a(c):a(void 0)}),e},M,K=()=>{M?.forEach(({callbacks:o},t)=>{let e=Object.keys(t);o.forEach(s=>s(e))}),M=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((i,n)=>p(t,void 0,e===n?i:void 0)),e},je=(o=[G(),...te()],t,e)=>{let s=Array.isArray(o)?o:[o],i=s.length+1,n=r=>{i-=1,r!==void 0&&(i=Math.min(i,0)),i===0&&t(r)};s.forEach(r=>Ie(r,a=>n(a===void 0?void 0:{key:a,host:r,isReactive:!1}),e));for(let r of s)if("manager"in r&&r.manager.component===r){ke(r,a=>n(a===void 0?void 0:{key:a,host:r,isReactive:!0}),e);break}return e},He=(o="",t={},e=G())=>{let s={emit:i=>{o===""&&K();let n=new CustomEvent(o,{detail:i,cancelable:!0,bubbles:!0,composed:!0,...t});return e.el.dispatchEvent(n),n}};return o===""&&je(void 0,i=>o=i.key,s),s},ze=He.bind(null,""),re;re=q;var At=class{constructor(t){this.#t=[],this.#e=[],this.#s=[],this.#o=[],this.#i=[],this.#c=[],this.#l=[],this.#p=[],this.#h=[],this.#d=!1,this.P=new $,this.connectedCalled=!1,this.loadedCalled=!1,this[re]=!0,this.#a=[];let e=this,s=t??G(new.target.name);e.#n=s,e.ready=e.P.promise,e.#r=ne(e),e.component=s,e.#n.addController(e),e.#n.manager===void 0||(Xt(e),queueMicrotask(()=>e.catchUpLifecycle()))}#t;#e;#s;#o;#i;#c;#l;#p;#h;#d;#n;catchUpLifecycle(){let{manager:t}=this.#n;t.connectedCalled&&!this.connectedCalled&&this.triggerConnected(),t.#d&&this.triggerLoad().then(()=>t.loadedCalled&&this.triggerLoaded()).catch(console.error)}#r;get exports(){return this.#r}set exports(t){let e=this.#r;e!==t&&(this.#r=t,this.#a.forEach(p),this.connectedCalled&&this.O!==!1&&this.#n.requestUpdate(this.O,e)),this.P.resolve(t)}setProvisionalExports(t,e=!0){this.#r=e?ne(t):t,this.#a.forEach(p)}#a;watchExports(t){let e=()=>t(this.#r);return this.#a.push(e),()=>void this.#a.splice(this.#a.indexOf(e),1)}get use(){return D(this.#n),ee}get useRef(){return D(this.#n),se}get useRefSync(){return D(this.#n),at}controllerRemoved(){this.#n.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.#o.push(t)}onUpdate(t){this.#i.push(t)}onUpdated(t){this.#c.push(t)}onDestroy(t){this.#l.push(t)}onLifecycle(t){this.#p.push(t),this.connectedCalled&&this.#n.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.#h.forEach(p),t.#h=[]}async triggerLoad(){if(this.#d)return;this.#d=!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.#r)}triggerLoaded(){this.loadedCalled||(this.hostLoaded&&p(this.hostLoaded,this),this.#o.forEach(p),this.loadedCalled=!0)}triggerUpdate(t){this.hostUpdate&&p(this.hostUpdate,this,t),this.#i.forEach(ie,t)}triggerUpdated(t){this.hostUpdated&&p(this.hostUpdated,this,t),this.#c.forEach(ie,t)}triggerDestroy(){this.hostDestroy&&p(this.hostDestroy,this),this.#l.forEach(p)}triggerLifecycle(){this.hostLifecycle&&this.#u(()=>this.hostLifecycle()),this.#p.forEach(this.#u,this)}#u(t){D(this.#n);let e=p(t);(Array.isArray(e)?e:[e]).forEach(i=>{typeof i=="function"?this.#h.push(i):typeof i=="object"&&typeof i.remove=="function"&&this.#h.push(i.remove)})}};function ie(o){p(o,void 0,this)}var ae=At,ne=o=>{if(typeof o!="object"&&typeof o!="function"||o===null)return o;let t={get(s,i,n){if(!((i==="exports"||i==="_exports")&&i in s&&s[i]===e)&&(i in s||i in Promise.prototype||typeof i=="symbol"))return typeof s=="function"?s[i]:Reflect.get(s,i,n)}},e=new Proxy(o,t);return e};var m={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},E=o=>(...t)=>({_$litDirective$:o,values:t}),v=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{I:Ve}=Zt;var ct=o=>o.strings===void 0,ce=()=>document.createComment(""),Xs=(o,t,e)=>{let s=o._$AA.parentNode,i=t===void 0?o._$AB:t._$AA;if(e===void 0){let n=s.insertBefore(ce(),i),r=s.insertBefore(ce(),i);e=new Ve(n,r,o,o.options)}else{let n=e._$AB.nextSibling,r=e._$AM,a=r!==o;if(a){let c;e._$AQ?.(o),e._$AM=o,e._$AP!==void 0&&(c=o._$AU)!==r._$AU&&e._$AP(c)}if(n!==i||a){let c=e._$AA;for(;c!==n;){let l=c.nextSibling;s.insertBefore(c,i),c=l}}}return e},to=(o,t,e=o)=>(o._$AI(t,e),o),Be={},le=(o,t=Be)=>o._$AH=t,eo=o=>o._$AH,so=o=>{o._$AR(),o._$AA.remove()};var We=E(class extends v{constructor(o){if(super(o),o.type!==m.PROPERTY&&o.type!==m.ATTRIBUTE&&o.type!==m.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!ct(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===m.PROPERTY){if(t===e[s])return f}else if(o.type===m.BOOLEAN_ATTRIBUTE){if(!!t===e.hasAttribute(s))return f}else if(o.type===m.ATTRIBUTE&&e.getAttribute(s)===t+"")return f;return le(o),t}});var J=(o,t)=>{let e=o._$AN;if(e===void 0)return!1;for(let s of e)s._$AO?.(t,!1),J(s,t);return!0},lt=o=>{let t,e;do{if((t=o._$AM)===void 0)break;e=t._$AN,e.delete(o),o=t}while(e?.size===0)},he=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),Ge(t)}};function Fe(o){this._$AN!==void 0?(lt(this),this._$AM=o,he(this)):this._$AM=o}function qe(o,t=!1,e=0){let s=this._$AH,i=this._$AN;if(i!==void 0&&i.size!==0)if(t)if(Array.isArray(s))for(let n=e;n<s.length;n++)J(s[n],!1),lt(s[n]);else s!=null&&(J(s,!1),lt(s));else J(this,o)}var Ge=o=>{o.type==m.CHILD&&(o._$AP??=qe,o._$AQ??=Fe)},ht=class extends v{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,s){super._$AT(t,e,s),he(this),this.isConnected=t._$AU}_$AO(t,e=!0){t!==this.isConnected&&(this.isConnected=t,t?this.reconnected?.():this.disconnected?.()),e&&(J(this,t),lt(this))}setValue(t){if(ct(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 Eo=()=>new wt,wt=class{},Ct=new WeakMap,Ot=E(class extends ht{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=Ct.get(t);e===void 0&&(e=new WeakMap,Ct.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"?Ct.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 dt=o=>o.replace(Je,(t,e)=>`${e===0?"":"-"}${t.toLowerCase()}`),Je=/[A-Z]+(?![a-z])|[A-Z]/gu;var xo="randomUUID"in crypto;var Pt=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},Nt={};function Dt(){}var Ze=(o,t)=>function(s,i){if(!globalThis.customElements)return;let r=(i??s??{}).resourcesUrl;r&&o.setAssetPath(r);for(let[a,[c,l=""]]of Object.entries(t)){if(customElements.get(a))continue;let[u,h,y]=l.split(";"),g=u?u?.split(",").map(Xe):void 0,C=g?.map(([L])=>L),x=class extends Tt{static{this.observedAttributes=g?.map(([,L])=>L).filter(L=>L!=="")}static{this.C=C}static{this.E=h?h?.split(","):void 0}static{this.D=y?.split(",")}static{this.L=a}static{this.K=o}constructor(){!x.B&&(x.B=c(),x.F()),super()}};customElements.define(a,x)}},pt=Object.defineProperty,Xe=o=>{let t=o.split(":");return t.length===1?[t[0],dt(t[0])]:t},ts=globalThis.HTMLElement??Dt,Tt=class extends ts{constructor(){super(),this.#e={},this.#s=[],this.I=new $,this.H=new $,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.#o({a:e.A}):e.B.then(async s=>{await e.K.p,t.#o(await(s.default?.then(i=>typeof i=="function"?{a:i}:i)??s))}).catch(s=>{t.H.reject(s),setTimeout(()=>{throw s})})}static{this.lumina=!0}static F(){for(let t of this.C??[])pt(this.prototype,t,{configurable:!0,enumerable:!0,get(){return this.#e[t]},set(e){this.#e[t]=e}});for(let t of this.E??[])pt(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??[])pt(this.prototype,t,{value(...e){return this.#t[t](...e)},configurable:!0})}#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=Pt(this))}disconnectedCallback(){this.#t?.disconnectedCallback?.()}async componentOnReady(){return await this.H.promise,this}#o(t){let e=this.constructor,s=e.L,i=this.#e,n=Object.values(t).find(h=>h.L===s),r=`${s}--lazy`,a=n;for(;a&&!Object.hasOwn(a,"lumina");)a=Object.getPrototypeOf(a);ss(a),!e.A&&(e.A=n,customElements.define(r,n)),n.N=this;let l=document.createElement(r);n.N=void 0,this.#t=l,this.#e=l,this.#s.forEach(h=>l.attributeChangedCallback(h,null,this.getAttribute(h))),Object.entries(i).forEach(es,l);let u=this.isConnected;(u||this.G)&&(l.connectedCallback?.(),u||l.disconnectedCallback())}addController(){}requestUpdate(){this.#t?.requestUpdate()}};function es([o,t]){this[o]=t}var ss=o=>{let t=o.prototype,e=Element.prototype;Object.hasOwn(t,"isConnected")||(t.setAttribute=function(i,n){e.setAttribute.call(this.el,i,n)},t.removeAttribute=function(i){e.removeAttribute.call(this.el,i)},pt(t,"isConnected",{get(){return Reflect.get(e,"isConnected",this.el)}}))};var de=E(class extends v{constructor(o){if(super(o),o.type!==m.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 i=!!t[s];i===this.st.has(s)||this.nt?.has(s)||(i?(e.add(s),this.st.add(s)):(e.remove(s),this.st.delete(s)))}return f}});var pe="important",os=" !"+pe,ue=E(class extends v{constructor(o){if(super(o),o.type!==m.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 i=t[s];if(i!=null){this.ft.add(s);let n=typeof i=="string"&&i.endsWith(os);s.includes("-")||n?e.setProperty(s,n?i.slice(0,-11):i,n?pe:""):e[s]=i}}return f}});var xt=class extends ae{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=Lt in t&&typeof t.destroy=="function",A.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 ${Lt} prop.`)}this.#t!==void 0&&clearTimeout(this.#t),K();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=()=>void this.#e.destroy();this.#t=oe(t,ds)}}S(t,e){let s=this.T;this.V=d,this.T=[],s.forEach(i=>i(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)}},ds=1e3,Lt="autoDestroyDisabled",fe=class o extends A{constructor(){super(),this.M=[],this.manager=new xt(this);let t=this,e=t.constructor,s=e.N,i=e.K.o,n=o.prototype.shouldUpdate;t.#o=s?.H??new $,t.I=s?.I??new $,t.J=s?.J??[],t._offspring=t.J,t._postLoad=t.I,t.el=s??t,t.#s=t.enableUpdating,t.enableUpdating=Dt,t.shouldUpdate!==n&&(t.#e=t.shouldUpdate,t.shouldUpdate=n),i&&(t.#t=new Map,e.elementProperties.forEach((r,a)=>t.#t.set(a,i()))),!1}static finalizeStyles(t){let e=super.finalizeStyles(t),s=this.shadowRootOptions===Nt;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,i=Array.isArray(e)?e[1]:void 0,n=i?.hasChanged??j,r={attribute:s&1&&typeof t=="string"?dt(t):!1,reflect:!!(s&2),type:s&4?Boolean:s&8?Number:void 0,state:!!(s&16),readOnly:!!(s&32),noAccessor:!!(s&64),c:!1,...i,hasChanged(a,c){let l=n(a,c);return r.c=l,l}};super.createProperty(t,r)}static getPropertyDescriptor(t,e,s){let i=this.K,n=super.getPropertyDescriptor(t,e,s);return s.d=n,{...n,get(){return i.t?.(this.#t.get(t)),n.get?.call(this)},set(r){let a=this.manager;if(s.readOnly&&!rt&&(a.R||a.connectedCalled))throw Error(`Cannot assign to read-only property "${t}" of ${this.el.localName}. Trying to assign "${r}"`);n.set.call(this,r??void 0),s.c&&this.#t?.get(t)?.notify(),a.T.length>0&&(K(),a?.S(t,r))}}}static{this.lumina=!0}#t;#e;#s;#o;#i;connectedCallback(){if(this.el.hasAttribute("defer-hydration"))return;let t=this.constructor.K.c?.(()=>this.requestUpdate());this.#i=t;let e=!this.manager.connectedCalled;super.connectedCallback(),e?queueMicrotask(()=>this.#l().catch(s=>{this.#o.reject(s),setTimeout(()=>{throw s})})):t&&this.requestUpdate()}#c(t){try{this.#i.clear(),this.constructor.K.r(this.#i,()=>super.update(t))}catch(e){throw this.#i.clear(),e}}disconnectedCallback(){super.disconnectedCallback(),this.#i?.destroy(),this.#i=void 0}createRenderRoot(){let t=this.el.shadowRoot,e=this.constructor,s=e.shadowRootOptions,n=t??(s===Nt?this.el:this.el.attachShadow(s));if(this.isConnected){let r=n.getRootNode();r.adoptedStyleSheets=[...r.adoptedStyleSheets,...e.elementStyles.map(a=>"styleSheet"in a?a.styleSheet:a)]}return n}async#l(){let t=this.el.G??Pt(this.el);t&&await t;let e=[];for(let i of this.M)"triggerLoad"in i?e.push(i.triggerLoad()):e.push(W(i.hostLoad,i));await Promise.all(e),await this.load?.(),this.manager.hasDestroy&&this.manager.onUpdate(i=>i.has(Lt)&&this.manager.U()),this.#s(!0),this.performUpdate(),this.I.resolve(),await Promise.resolve();let s=this.J.filter(i=>!i.manager?.loadedCalled);s.length&&await Promise.allSettled(s.map(async i=>await i.componentOnReady())),this.J.length=0,this.el.setAttribute(this.constructor.K.hydratedAttribute,"");for(let i of this.M)"triggerLoaded"in i?i.triggerLoaded():p(i.hostLoaded,i);this.loaded?.(),this.#o.resolve()}shouldUpdate(t){return this.manager.Q=t,this.#e?.(t)??!0}update(t){this.#i?this.#c(t):super.update(t)}listen(t,e,s){let i=e?.bind(this)??e;this.manager.onLifecycle(()=>(this.el.addEventListener(t,i,s),()=>this.el.removeEventListener(t,i,s)))}listenOn(t,e,s,i){let n=s?.bind(this)??s;this.manager.onLifecycle(()=>(t.addEventListener(e,n,i),()=>t.removeEventListener(e,n,i)))}async componentOnReady(){return await this.#o.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 me=o=>{let t,e=i=>{t=new URL(i,globalThis.location?.href||void 0).href},s={...o,getAssetPath(i){let n=new URL(i,t);return n.origin!==globalThis.location?.origin?n.href:n.pathname},setAssetPath:e,customElement(i,n){n.K=s,n.L=i,customElements.get(i)||customElements.define(i,n)}};return e(o.defaultAssetPath),s};var $i=o=>typeof o=="object"&&o!=null?de(o):o,bi=o=>typeof o=="object"&&o!=null?ue(o):o;var Ut=class extends v{#t;#e;constructor(t){super(t);let e=this;this.#e=function(i){return e.#t.call(this,i)}}render(t){return typeof t=="function"?(this.#t=t,Ot(this.#e)):Ot(t)}},_i=E(Ut);var Ai=d;function Ci(o,t,e){e==null?o.removeAttribute(t):o.setAttribute(t,e)}var wi={toAttribute:o=>o===!0?"":o===!1?null:o};var ve="calcite-mode-auto",Ee="calcite-mode-dark",ps="calcite-mode-light",Ni={autoMode:ve,darkMode:Ee,lightMode:ps,rtl:"calcite--rtl",calciteAnimate:"calcite-animate",calciteAnimateInUp:"calcite-animate__in-up",calciteAnimateInDown:"calcite-animate__in-down",calciteAnimateInRight:"calcite-animate__in-right",calciteAnimateInLeft:"calcite-animate__in-left"},Di={filter:250,nextTick:0,resize:150,reposition:100},xi=10,Li=25;function ye(){let{classList:o}=document.body,t=window.matchMedia("(prefers-color-scheme: dark)").matches,e=()=>o.contains(Ee)||o.contains(ve)&&t?"dark":"light",s=r=>document.body.dispatchEvent(new CustomEvent("calciteModeChange",{bubbles:!0,detail:{mode:r}})),i=r=>{n!==r&&s(r),n=r},n=e();s(n),window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change",r=>i(r.matches?"dark":"light")),new MutationObserver(()=>i(e())).observe(document.body,{attributes:!0,attributeFilter:["class"]})}var Mt,us={focusTrapStack:[],logLevel:"info"};function fs(){return{...us,...globalThis.calciteConfig??{}}}function ms(){return Mt||(Mt=fs()),Mt}var ge="5.0.0-next.5",ys="2025-11-19",gs="aea808500";function vs(){let o=ms();o&&o.version||(console.info(`Using Calcite Components ${ge} [Date: ${ys}, Revision: ${gs}]`),Object.defineProperty(o,"version",{value:ge,writable:!1}),globalThis.calciteConfig=o)}document.readyState==="interactive"?ye():document.addEventListener("DOMContentLoaded",ye,{once:!0});queueMicrotask(vs);var Es=me({defaultAssetPath:"https://cdn.jsdelivr.net/npm/@esri/calcite-components@5.0.0-next.5/dist/calcite/",hydratedAttribute:"calcite-hydrated"}),{customElement:Ui,getAssetPath:Ri,setAssetPath:Mi}=Es;export{Hs as a,D as b,Xt as c,te as d,zs as e,Vs as f,$e as g,Cs as h,ws as i,Os as j,f as k,d as l,bt as m,je as n,ze as o,At as p,ae as q,Ze as r,m as s,E as t,v as u,Xs as v,to as w,le as x,eo as y,so as z,We as A,Eo as B,Ot as C,fe as D,$i as E,bi as F,Ai as G,Ci as H,wi as I,Ni as J,Di as K,xi as L,Li as M,ms as N,Es as O,Ui as P,Ri as Q};
|
|
6
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),Ft=/'/g,qt=/"/g,Jt=/^(?:script|style|textarea|title)$/i,$t=o=>(t,...e)=>({_$litType$:o,strings:t,values:e}),Cs=$t(1),ws=$t(2),Os=$t(3),f=Symbol.for("lit-noChange"),d=Symbol.for("lit-nothing"),Gt=new WeakMap,O=S.createTreeWalker(S,129);function Qt(o,t){if(!Et(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return Vt!==void 0?Vt.createHTML(t):t}var Yt=(o,t)=>{let e=o.length-1,s=[],i,n=t===2?"<svg>":t===3?"<math>":"",r=H;for(let a=0;a<e;a++){let c=o[a],l,u,h=-1,y=0;for(;y<c.length&&(r.lastIndex=y,u=r.exec(c),u!==null);)y=r.lastIndex,r===H?u[1]==="!--"?r=Bt:u[1]!==void 0?r=Wt:u[2]!==void 0?(Jt.test(u[2])&&(i=RegExp("</"+u[2],"g")),r=w):u[3]!==void 0&&(r=w):r===w?u[0]===">"?(r=i??H,h=-1):u[1]===void 0?h=-2:(h=r.lastIndex-u[2].length,l=u[1],r=u[3]===void 0?w:u[3]==='"'?qt:Ft):r===qt||r===Ft?r=w:r===Bt||r===Wt?r=H:(r=w,i=void 0);let g=r===w&&o[a+1].startsWith("/>")?" ":"";n+=r===H?c+Pe:h>=0?(s.push(l),c.slice(0,h)+gt+c.slice(h)+_+g):c+_+(h===-2?a:g)}return[Qt(o,n+(o[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),s]},B=class o{constructor({strings:t,_$litType$:e},s){let i;this.parts=[];let n=0,r=0,a=t.length-1,c=this.parts,[l,u]=Yt(t,e);if(this.el=o.createElement(l,s),O.currentNode=this.el.content,e===2||e===3){let h=this.el.content.firstChild;h.replaceWith(...h.childNodes)}for(;(i=O.nextNode())!==null&&c.length<a;){if(i.nodeType===1){if(i.hasAttributes())for(let h of i.getAttributeNames())if(h.endsWith(gt)){let y=u[r++],g=i.getAttribute(h).split(_),C=/([.?@])?(.*)/.exec(y);c.push({type:1,index:n,name:C[2],strings:g,ctor:C[1]==="."?st:C[1]==="?"?ot:C[1]==="@"?it:P}),i.removeAttribute(h)}else h.startsWith(_)&&(c.push({type:6,index:n}),i.removeAttribute(h));if(Jt.test(i.tagName)){let h=i.textContent.split(_),y=h.length-1;if(y>0){i.textContent=tt?tt.emptyScript:"";for(let g=0;g<y;g++)i.append(h[g],z()),O.nextNode(),c.push({type:2,index:++n});i.append(h[y],z())}}}else if(i.nodeType===8)if(i.data===vt)c.push({type:2,index:n});else{let h=-1;for(;(h=i.data.indexOf(_,h+1))!==-1;)c.push({type:7,index:n}),h+=_.length-1}n++}}static createElement(t,e){let s=S.createElement("template");return s.innerHTML=t,s}};function T(o,t,e=o,s){if(t===f)return t;let i=s!==void 0?e._$Co?.[s]:e._$Cl,n=V(t)?void 0:t._$litDirective$;return i?.constructor!==n&&(i?._$AO?.(!1),n===void 0?i=void 0:(i=new n(o),i._$AT(o,e,s)),s!==void 0?(e._$Co??=[])[s]=i:e._$Cl=i),i!==void 0&&(t=T(o,i._$AS(o,t.values),i,s)),t}var et=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,i=(t?.creationScope??S).importNode(e,!0);O.currentNode=i;let n=O.nextNode(),r=0,a=0,c=s[0];for(;c!==void 0;){if(r===c.index){let l;c.type===2?l=new U(n,n.nextSibling,this,t):c.type===1?l=new c.ctor(n,c.name,c.strings,this,t):c.type===6&&(l=new nt(n,this,t)),this._$AV.push(l),c=s[++a]}r!==c?.index&&(n=O.nextNode(),r++)}return O.currentNode=S,i}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++}},U=class o{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,s,i){this.type=2,this._$AH=d,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=i,this._$Cv=i?.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=T(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):Kt(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(S.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:s}=t,i=typeof s=="number"?this._$AC(t):(s.el===void 0&&(s.el=B.createElement(Qt(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===i)this._$AH.p(e);else{let n=new et(i,this),r=n.u(this.options);n.p(e),this.T(r),this._$AH=n}}_$AC(t){let e=Gt.get(t.strings);return e===void 0&&Gt.set(t.strings,e=new B(t)),e}k(t){Et(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,s,i=0;for(let n of t)i===e.length?e.push(s=new o(this.O(z()),this.O(z()),this,this.options)):s=e[i],s._$AI(n),i++;i<e.length&&(this._$AR(s&&s._$AB.nextSibling,i),e.length=i)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){let s=t.nextSibling;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,i,n){this.type=1,this._$AH=d,this._$AN=void 0,this.element=t,this.name=e,this._$AM=i,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,i){let n=this.strings,r=!1;if(n===void 0)t=T(this,t,e,0),r=!V(t)||t!==this._$AH&&t!==f,r&&(this._$AH=t);else{let a=t,c,l;for(t=n[0],c=0;c<n.length-1;c++)l=T(this,a[s+c],e,c),l===f&&(l=this._$AH[c]),r||=!V(l)||l!==this._$AH[c],l===d?t=d:t!==d&&(t+=(l??"")+n[c+1]),this._$AH[c]=l}r&&!i&&this.j(t)}j(t){t===d?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},st=class extends P{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===d?void 0:t}},ot=class extends P{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==d)}},it=class extends P{constructor(t,e,s,i,n){super(t,e,s,i,n),this.type=5}_$AI(t,e=this){if((t=T(this,t,e,0)??d)===f)return;let s=this._$AH,i=t===d&&s!==d||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,n=t!==d&&(s===d||i);i&&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)}},nt=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){T(this,t)}},Zt={M:gt,P:_,A:vt,C:1,L:Yt,R:et,D:Kt,V:T,I:U,H:P,N:ot,U:it,B:st,F:nt},Ne=yt.litHtmlPolyfillSupport;Ne?.(B,U),(yt.litHtmlVersions??=[]).push("3.3.1");var bt=(o,t,e)=>{let s=e?.renderBefore??t,i=s._$litPart$;if(i===void 0){let n=e?.renderBefore??null;s._$litPart$=i=new U(t.insertBefore(z(),n),n,void 0,e??{})}return i._$AI(o),i};var _t=globalThis,A=class extends b{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=bt(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return f}};A._$litElement$=!0,A.finalized=!0,_t.litElementHydrateSupport?.({LitElement:A});var De=_t.litElementPolyfillSupport;De?.({LitElement:A});(_t.litElementVersions??=[]).push("4.2.1");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),Hs=o=>typeof o?.then=="function";var F,D=o=>{F!==o&&(F=o,queueMicrotask(()=>F===o?F=void 0:0))},G=o=>F,N=[],Xt=o=>{if(o===void 0){N=[];return}let t=N.indexOf(o);N=t===-1?[...N,o]:N.slice(0,t+1),queueMicrotask(()=>N=[])},te=()=>N,R,zs=o=>{R!==o&&(R=o,queueMicrotask(()=>R===o?R=void 0:0))},Le=()=>{let o=R;return R=void 0,o},ee=async(o,t)=>{let e=at(o);if(e===void 0)return o;if(await e.ready,typeof t=="function"){let s=e.watchExports(i=>t(i,s))}return e.exports},se=async o=>{let t=at(o);return await t.ready,t},at=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},rt=!1,Vs=o=>{rt=!0;try{return o()}finally{rt=!1}};var $=class{constructor(){this.promise=new Promise((t,e)=>{this.resolve=t,this.reject=e})}},oe=(o,t)=>{let e=t>Ue?Re:t/Me,s=0,i=setInterval(()=>{s+=e,s>=t&&(clearInterval(i),o())},e);return i},Ue=4e3,Re=2e3,Me=4;var Ie=(o,t,e)=>{let s=Object.keys(o),i=s.length;M===void 0&&queueMicrotask(K),M??=new Map;let n=M.get(o);return n===void 0&&(n={callbacks:[],keyCount:i},M.set(o,n)),n.keyCount!==i&&(n.callbacks.forEach(r=>r(s)),n.callbacks=[],n.keyCount=i),n.callbacks.push(r=>{let a=l=>p(t,null,l),c=r[i];c===void 0?a(void 0):o[c]===e?a(c):a(void 0)}),e},M,K=()=>{M?.forEach(({callbacks:o},t)=>{let e=Object.keys(t);o.forEach(s=>s(e))}),M=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((i,n)=>p(t,void 0,e===n?i:void 0)),e},je=(o=[G(),...te()],t,e)=>{let s=Array.isArray(o)?o:[o],i=s.length+1,n=r=>{i-=1,r!==void 0&&(i=Math.min(i,0)),i===0&&t(r)};s.forEach(r=>Ie(r,a=>n(a===void 0?void 0:{key:a,host:r,isReactive:!1}),e));for(let r of s)if("manager"in r&&r.manager.component===r){ke(r,a=>n(a===void 0?void 0:{key:a,host:r,isReactive:!0}),e);break}return e},He=(o="",t={},e=G())=>{let s={emit:i=>{o===""&&K();let n=new CustomEvent(o,{detail:i,cancelable:!0,bubbles:!0,composed:!0,...t});return e.el.dispatchEvent(n),n}};return o===""&&je(void 0,i=>o=i.key,s),s},ze=He.bind(null,""),re;re=q;var At=class{constructor(t){this.#t=[],this.#e=[],this.#s=[],this.#o=[],this.#i=[],this.#c=[],this.#l=[],this.#p=[],this.#h=[],this.#d=!1,this.P=new $,this.connectedCalled=!1,this.loadedCalled=!1,this[re]=!0,this.#a=[];let e=this,s=t??G(new.target.name);e.#n=s,e.ready=e.P.promise,e.#r=ne(e),e.component=s,e.#n.addController(e),e.#n.manager===void 0||(Xt(e),queueMicrotask(()=>e.catchUpLifecycle()))}#t;#e;#s;#o;#i;#c;#l;#p;#h;#d;#n;catchUpLifecycle(){let{manager:t}=this.#n;t.connectedCalled&&!this.connectedCalled&&this.triggerConnected(),t.#d&&this.triggerLoad().then(()=>t.loadedCalled&&this.triggerLoaded()).catch(console.error)}#r;get exports(){return this.#r}set exports(t){let e=this.#r;e!==t&&(this.#r=t,this.#a.forEach(p),this.connectedCalled&&this.O!==!1&&this.#n.requestUpdate(this.O,e)),this.P.resolve(t)}setProvisionalExports(t,e=!0){this.#r=e?ne(t):t,this.#a.forEach(p)}#a;watchExports(t){let e=()=>t(this.#r);return this.#a.push(e),()=>void this.#a.splice(this.#a.indexOf(e),1)}get use(){return D(this.#n),ee}get useRef(){return D(this.#n),se}get useRefSync(){return D(this.#n),at}controllerRemoved(){this.#n.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.#o.push(t)}onUpdate(t){this.#i.push(t)}onUpdated(t){this.#c.push(t)}onDestroy(t){this.#l.push(t)}onLifecycle(t){this.#p.push(t),this.connectedCalled&&this.#n.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.#h.forEach(p),t.#h=[]}async triggerLoad(){if(this.#d)return;this.#d=!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.#r)}triggerLoaded(){this.loadedCalled||(this.hostLoaded&&p(this.hostLoaded,this),this.#o.forEach(p),this.loadedCalled=!0)}triggerUpdate(t){this.hostUpdate&&p(this.hostUpdate,this,t),this.#i.forEach(ie,t)}triggerUpdated(t){this.hostUpdated&&p(this.hostUpdated,this,t),this.#c.forEach(ie,t)}triggerDestroy(){this.hostDestroy&&p(this.hostDestroy,this),this.#l.forEach(p)}triggerLifecycle(){this.hostLifecycle&&this.#u(()=>this.hostLifecycle()),this.#p.forEach(this.#u,this)}#u(t){D(this.#n);let e=p(t);(Array.isArray(e)?e:[e]).forEach(i=>{typeof i=="function"?this.#h.push(i):typeof i=="object"&&typeof i.remove=="function"&&this.#h.push(i.remove)})}};function ie(o){p(o,void 0,this)}var ae=At,ne=o=>{if(typeof o!="object"&&typeof o!="function"||o===null)return o;let t={get(s,i,n){if(!((i==="exports"||i==="_exports")&&i in s&&s[i]===e)&&(i in s||i in Promise.prototype||typeof i=="symbol"))return typeof s=="function"?s[i]:Reflect.get(s,i,n)}},e=new Proxy(o,t);return e};var m={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},E=o=>(...t)=>({_$litDirective$:o,values:t}),v=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{I:Ve}=Zt;var ct=o=>o.strings===void 0,ce=()=>document.createComment(""),Xs=(o,t,e)=>{let s=o._$AA.parentNode,i=t===void 0?o._$AB:t._$AA;if(e===void 0){let n=s.insertBefore(ce(),i),r=s.insertBefore(ce(),i);e=new Ve(n,r,o,o.options)}else{let n=e._$AB.nextSibling,r=e._$AM,a=r!==o;if(a){let c;e._$AQ?.(o),e._$AM=o,e._$AP!==void 0&&(c=o._$AU)!==r._$AU&&e._$AP(c)}if(n!==i||a){let c=e._$AA;for(;c!==n;){let l=c.nextSibling;s.insertBefore(c,i),c=l}}}return e},to=(o,t,e=o)=>(o._$AI(t,e),o),Be={},le=(o,t=Be)=>o._$AH=t,eo=o=>o._$AH,so=o=>{o._$AR(),o._$AA.remove()};var We=E(class extends v{constructor(o){if(super(o),o.type!==m.PROPERTY&&o.type!==m.ATTRIBUTE&&o.type!==m.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!ct(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===m.PROPERTY){if(t===e[s])return f}else if(o.type===m.BOOLEAN_ATTRIBUTE){if(!!t===e.hasAttribute(s))return f}else if(o.type===m.ATTRIBUTE&&e.getAttribute(s)===t+"")return f;return le(o),t}});var J=(o,t)=>{let e=o._$AN;if(e===void 0)return!1;for(let s of e)s._$AO?.(t,!1),J(s,t);return!0},lt=o=>{let t,e;do{if((t=o._$AM)===void 0)break;e=t._$AN,e.delete(o),o=t}while(e?.size===0)},he=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),Ge(t)}};function Fe(o){this._$AN!==void 0?(lt(this),this._$AM=o,he(this)):this._$AM=o}function qe(o,t=!1,e=0){let s=this._$AH,i=this._$AN;if(i!==void 0&&i.size!==0)if(t)if(Array.isArray(s))for(let n=e;n<s.length;n++)J(s[n],!1),lt(s[n]);else s!=null&&(J(s,!1),lt(s));else J(this,o)}var Ge=o=>{o.type==m.CHILD&&(o._$AP??=qe,o._$AQ??=Fe)},ht=class extends v{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,s){super._$AT(t,e,s),he(this),this.isConnected=t._$AU}_$AO(t,e=!0){t!==this.isConnected&&(this.isConnected=t,t?this.reconnected?.():this.disconnected?.()),e&&(J(this,t),lt(this))}setValue(t){if(ct(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 Eo=()=>new wt,wt=class{},Ct=new WeakMap,Ot=E(class extends ht{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=Ct.get(t);e===void 0&&(e=new WeakMap,Ct.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"?Ct.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 dt=o=>o.replace(Je,(t,e)=>`${e===0?"":"-"}${t.toLowerCase()}`),Je=/[A-Z]+(?![a-z])|[A-Z]/gu;var xo="randomUUID"in crypto;var Pt=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},Nt={};function Dt(){}var Ze=(o,t)=>function(s,i){if(!globalThis.customElements)return;let r=(i??s??{}).resourcesUrl;r&&o.setAssetPath(r);for(let[a,[c,l=""]]of Object.entries(t)){if(customElements.get(a))continue;let[u,h,y]=l.split(";"),g=u?u?.split(",").map(Xe):void 0,C=g?.map(([L])=>L),x=class extends Tt{static{this.observedAttributes=g?.map(([,L])=>L).filter(L=>L!=="")}static{this.C=C}static{this.E=h?h?.split(","):void 0}static{this.D=y?.split(",")}static{this.L=a}static{this.K=o}constructor(){!x.B&&(x.B=c(),x.F()),super()}};customElements.define(a,x)}},pt=Object.defineProperty,Xe=o=>{let t=o.split(":");return t.length===1?[t[0],dt(t[0])]:t},ts=globalThis.HTMLElement??Dt,Tt=class extends ts{constructor(){super(),this.#e={},this.#s=[],this.I=new $,this.H=new $,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.#o({a:e.A}):e.B.then(async s=>{await e.K.p,t.#o(await(s.default?.then(i=>typeof i=="function"?{a:i}:i)??s))}).catch(s=>{t.H.reject(s),setTimeout(()=>{throw s})})}static{this.lumina=!0}static F(){for(let t of this.C??[])pt(this.prototype,t,{configurable:!0,enumerable:!0,get(){return this.#e[t]},set(e){this.#e[t]=e}});for(let t of this.E??[])pt(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??[])pt(this.prototype,t,{value(...e){return this.#t[t](...e)},configurable:!0})}#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=Pt(this))}disconnectedCallback(){this.#t?.disconnectedCallback?.()}async componentOnReady(){return await this.H.promise,this}#o(t){let e=this.constructor,s=e.L,i=this.#e,n=Object.values(t).find(h=>h.L===s),r=`${s}--lazy`,a=n;for(;a&&!Object.hasOwn(a,"lumina");)a=Object.getPrototypeOf(a);ss(a),!e.A&&(e.A=n,customElements.define(r,n)),n.N=this;let l=document.createElement(r);n.N=void 0,this.#t=l,this.#e=l,this.#s.forEach(h=>l.attributeChangedCallback(h,null,this.getAttribute(h))),Object.entries(i).forEach(es,l);let u=this.isConnected;(u||this.G)&&(l.connectedCallback?.(),u||l.disconnectedCallback())}addController(){}requestUpdate(){this.#t?.requestUpdate()}};function es([o,t]){this[o]=t}var ss=o=>{let t=o.prototype,e=Element.prototype;Object.hasOwn(t,"isConnected")||(t.setAttribute=function(i,n){e.setAttribute.call(this.el,i,n)},t.removeAttribute=function(i){e.removeAttribute.call(this.el,i)},pt(t,"isConnected",{get(){return Reflect.get(e,"isConnected",this.el)}}))};var de=E(class extends v{constructor(o){if(super(o),o.type!==m.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 i=!!t[s];i===this.st.has(s)||this.nt?.has(s)||(i?(e.add(s),this.st.add(s)):(e.remove(s),this.st.delete(s)))}return f}});var pe="important",os=" !"+pe,ue=E(class extends v{constructor(o){if(super(o),o.type!==m.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 i=t[s];if(i!=null){this.ft.add(s);let n=typeof i=="string"&&i.endsWith(os);s.includes("-")||n?e.setProperty(s,n?i.slice(0,-11):i,n?pe:""):e[s]=i}}return f}});var xt=class extends ae{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=Lt in t&&typeof t.destroy=="function",A.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 ${Lt} prop.`)}this.#t!==void 0&&clearTimeout(this.#t),K();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=()=>void this.#e.destroy();this.#t=oe(t,ds)}}S(t,e){let s=this.T;this.V=d,this.T=[],s.forEach(i=>i(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)}},ds=1e3,Lt="autoDestroyDisabled",fe=class o extends A{constructor(){super(),this.M=[],this.manager=new xt(this);let t=this,e=t.constructor,s=e.N,i=e.K.o,n=o.prototype.shouldUpdate;t.#o=s?.H??new $,t.I=s?.I??new $,t.J=s?.J??[],t._offspring=t.J,t._postLoad=t.I,t.el=s??t,t.#s=t.enableUpdating,t.enableUpdating=Dt,t.shouldUpdate!==n&&(t.#e=t.shouldUpdate,t.shouldUpdate=n),i&&(t.#t=new Map,e.elementProperties.forEach((r,a)=>t.#t.set(a,i()))),!1}static finalizeStyles(t){let e=super.finalizeStyles(t),s=this.shadowRootOptions===Nt;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,i=Array.isArray(e)?e[1]:void 0,n=i?.hasChanged??j,r={attribute:s&1&&typeof t=="string"?dt(t):!1,reflect:!!(s&2),type:s&4?Boolean:s&8?Number:void 0,state:!!(s&16),readOnly:!!(s&32),noAccessor:!!(s&64),c:!1,...i,hasChanged(a,c){let l=n(a,c);return r.c=l,l}};super.createProperty(t,r)}static getPropertyDescriptor(t,e,s){let i=this.K,n=super.getPropertyDescriptor(t,e,s);return s.d=n,{...n,get(){return i.t?.(this.#t.get(t)),n.get?.call(this)},set(r){let a=this.manager;if(s.readOnly&&!rt&&(a.R||a.connectedCalled))throw Error(`Cannot assign to read-only property "${t}" of ${this.el.localName}. Trying to assign "${r}"`);n.set.call(this,r??void 0),s.c&&this.#t?.get(t)?.notify(),a.T.length>0&&(K(),a?.S(t,r))}}}static{this.lumina=!0}#t;#e;#s;#o;#i;connectedCallback(){if(this.el.hasAttribute("defer-hydration"))return;let t=this.constructor.K.c?.(()=>this.requestUpdate());this.#i=t;let e=!this.manager.connectedCalled;super.connectedCallback(),e?queueMicrotask(()=>this.#l().catch(s=>{this.#o.reject(s),setTimeout(()=>{throw s})})):t&&this.requestUpdate()}#c(t){try{this.#i.clear(),this.constructor.K.r(this.#i,()=>super.update(t))}catch(e){throw this.#i.clear(),e}}disconnectedCallback(){super.disconnectedCallback(),this.#i?.destroy(),this.#i=void 0}createRenderRoot(){let t=this.el.shadowRoot,e=this.constructor,s=e.shadowRootOptions,n=t??(s===Nt?this.el:this.el.attachShadow(s));if(this.isConnected){let r=n.getRootNode();r.adoptedStyleSheets=[...r.adoptedStyleSheets,...e.elementStyles.map(a=>"styleSheet"in a?a.styleSheet:a)]}return n}async#l(){let t=this.el.G??Pt(this.el);t&&await t;let e=[];for(let i of this.M)"triggerLoad"in i?e.push(i.triggerLoad()):e.push(W(i.hostLoad,i));await Promise.all(e),await this.load?.(),this.manager.hasDestroy&&this.manager.onUpdate(i=>i.has(Lt)&&this.manager.U()),this.#s(!0),this.performUpdate(),this.I.resolve(),await Promise.resolve();let s=this.J.filter(i=>!i.manager?.loadedCalled);s.length&&await Promise.allSettled(s.map(async i=>await i.componentOnReady())),this.J.length=0,this.el.setAttribute(this.constructor.K.hydratedAttribute,"");for(let i of this.M)"triggerLoaded"in i?i.triggerLoaded():p(i.hostLoaded,i);this.loaded?.(),this.#o.resolve()}shouldUpdate(t){return this.manager.Q=t,this.#e?.(t)??!0}update(t){this.#i?this.#c(t):super.update(t)}listen(t,e,s){let i=e?.bind(this)??e;this.manager.onLifecycle(()=>(this.el.addEventListener(t,i,s),()=>this.el.removeEventListener(t,i,s)))}listenOn(t,e,s,i){let n=s?.bind(this)??s;this.manager.onLifecycle(()=>(t.addEventListener(e,n,i),()=>t.removeEventListener(e,n,i)))}async componentOnReady(){return await this.#o.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 me=o=>{let t,e=i=>{t=new URL(i,globalThis.location?.href||void 0).href},s={...o,getAssetPath(i){let n=new URL(i,t);return n.origin!==globalThis.location?.origin?n.href:n.pathname},setAssetPath:e,customElement(i,n){n.K=s,n.L=i,customElements.get(i)||customElements.define(i,n)}};return e(o.defaultAssetPath),s};var $i=o=>typeof o=="object"&&o!=null?de(o):o,bi=o=>typeof o=="object"&&o!=null?ue(o):o;var Ut=class extends v{#t;#e;constructor(t){super(t);let e=this;this.#e=function(i){return e.#t.call(this,i)}}render(t){return typeof t=="function"?(this.#t=t,Ot(this.#e)):Ot(t)}},_i=E(Ut);var Ai=d;function Ci(o,t,e){e==null?o.removeAttribute(t):o.setAttribute(t,e)}var wi={toAttribute:o=>o===!0?"":o===!1?null:o};var ve="calcite-mode-auto",Ee="calcite-mode-dark",ps="calcite-mode-light",Ni={autoMode:ve,darkMode:Ee,lightMode:ps,rtl:"calcite--rtl",calciteAnimate:"calcite-animate",calciteAnimateInUp:"calcite-animate__in-up",calciteAnimateInDown:"calcite-animate__in-down",calciteAnimateInRight:"calcite-animate__in-right",calciteAnimateInLeft:"calcite-animate__in-left"},Di={filter:250,nextTick:0,resize:150,reposition:100},xi=10,Li=25;function ye(){let{classList:o}=document.body,t=window.matchMedia("(prefers-color-scheme: dark)").matches,e=()=>o.contains(Ee)||o.contains(ve)&&t?"dark":"light",s=r=>document.body.dispatchEvent(new CustomEvent("calciteModeChange",{bubbles:!0,detail:{mode:r}})),i=r=>{n!==r&&s(r),n=r},n=e();s(n),window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change",r=>i(r.matches?"dark":"light")),new MutationObserver(()=>i(e())).observe(document.body,{attributes:!0,attributeFilter:["class"]})}var Mt,us={focusTrapStack:[],logLevel:"info"};function fs(){return{...us,...globalThis.calciteConfig??{}}}function ms(){return Mt||(Mt=fs()),Mt}var ge="5.0.0-next.6",ys="2025-11-19",gs="d2782c138";function vs(){let o=ms();o&&o.version||(console.info(`Using Calcite Components ${ge} [Date: ${ys}, Revision: ${gs}]`),Object.defineProperty(o,"version",{value:ge,writable:!1}),globalThis.calciteConfig=o)}document.readyState==="interactive"?ye():document.addEventListener("DOMContentLoaded",ye,{once:!0});queueMicrotask(vs);var Es=me({defaultAssetPath:"https://cdn.jsdelivr.net/npm/@esri/calcite-components@5.0.0-next.6/dist/calcite/",hydratedAttribute:"calcite-hydrated"}),{customElement:Ui,getAssetPath:Ri,setAssetPath:Mi}=Es;export{Hs as a,D as b,Xt as c,te as d,zs as e,Vs as f,$e as g,Cs as h,ws as i,Os as j,f as k,d as l,bt as m,je as n,ze as o,At as p,ae as q,Ze as r,m as s,E as t,v as u,Xs as v,to as w,le as x,eo as y,so as z,We as A,Eo as B,Ot as C,fe as D,$i as E,bi as F,Ai as G,Ci as H,wi as I,Ni as J,Di as K,xi as L,Li as M,ms as N,Es as O,Ui as P,Ri as Q};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*! All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
|
3
|
-
v5.0.0-next.
|
|
4
|
-
import{a as w,b as C}from"./NSBK36H4.js";import{a as y}from"./WOTQIMPZ.js";import"./B5JXPZDV.js";import"./3YZG7MA3.js";import"./CIU4VM7X.js";import{t as z}from"./5IPJANUU.js";import"./ZLR2B6GQ.js";import{C as g,D as m,E as i,G as x,P as k,g as b,h as n,o as h}from"./AUIOWPFN.js";var t={container:"container",contentContainer:"content-container",contentContainerHasContent:"content-container--has-content",contentContainerHasOnlyContentTopAndBottom:"content-container--has-only-content-top-and-bottom",textContentContainer:"text-content-container",description:"description",heading:"heading",icon:"icon",interactive:"interactive",largeVisualDeprecated:"large-visual-deprecated",row:"row",selected:"selected",selectionIcon:"selection-icon",textContent:"text-content"},s={selectedMultiple:"check-square-f",selectedSingle:"circle-f",unselectedMultiple:"square",unselectedSingle:"circle"},$={contentBottom:"content-bottom",contentTop:"content-top"},A=b`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host([disabled]){cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{box-shadow:var(--calcite-tile-shadow, var(--calcite-shadow-none));box-sizing:border-box;display:inline-block}calcite-link{--calcite-link-text-color: var(--calcite-tile-link-text-color)}.container{background-color:var(--calcite-tile-background-color, var(--calcite-color-foreground-1));block-size:var(--calcite-container-size-content-fluid);border-radius:var(--calcite-tile-corner-radius, var(--calcite-corner-radius));box-sizing:border-box;color:var(--calcite-tile-text-color, var(--calcite-color-text-3));inline-size:var(--calcite-container-size-content-fluid);outline:var(--calcite-border-width-sm, 1px) solid var(--calcite-tile-border-color, var(--calcite-color-border-2));padding:var(--calcite-internal-tile-spacing);position:relative;-webkit-user-select:none;user-select:none}.container .selection-icon{color:var(--calcite-tile-text-color, var(--calcite-color-text-3))}.container.interactive{cursor:pointer}.container.interactive:hover,.container.interactive:focus,.container.interactive.selected{outline-color:var(--calcite-tile-accent-color-press, var(--calcite-color-brand));z-index:var(--calcite-z-index)}.container.interactive:hover .selection-icon,.container.interactive:focus .selection-icon,.container.interactive.selected .selection-icon{color:var(--calcite-tile-accent-color-press, var(--calcite-color-brand))}.container.interactive:focus{box-shadow:inset 0 0 0 1px var(--calcite-tile-accent-color-press, var(--calcite-color-brand));z-index:calc(var(--calcite-z-index) + 1)}.content-container,.row{align-items:flex-start;display:flex}.content-container{flex-direction:column;word-wrap:break-word;word-break:break-word;inline-size:var(--calcite-container-size-content-fluid)}.text-content-container{inline-size:100%;outline-color:transparent;padding:0}.text-content{display:flex;flex-direction:column}.heading{color:var(--calcite-tile-heading-text-color, var(--calcite-color-text-2));font-weight:var(--calcite-font-weight-medium);line-height:1.20313rem;overflow-wrap:break-word}.description{font-weight:var(--calcite-font-weight-regular);overflow-wrap:break-word}.large-visual-deprecated{align-items:center;justify-content:center;min-block-size:12rem;text-align:center}.large-visual-deprecated .icon{align-self:center;block-size:64px;inline-size:64px}.large-visual-deprecated .selection-icon{position:absolute;inset-inline-start:var(--calcite-internal-tile-spacing);inset-block-start:var(--calcite-internal-tile-spacing);z-index:var(--calcite-z-index)}.large-visual-deprecated .text-content-container{justify-content:center}:host([alignment=center]) .icon{align-self:center}:host([alignment=center]) .text-content-container{justify-content:center}:host([alignment=center]) .text-content{text-align:center}:host([alignment=center]) slot[name=content-bottom]::slotted(*),:host([alignment=center]) slot[name=content-top]::slotted(*){align-self:center}:host([scale=s]){--calcite-internal-tile-spacing: var(--calcite-spacing-sm);max-inline-size:400px;min-inline-size:100px}:host([scale=s]) .heading{font-size:var(--calcite-font-size--2);line-height:1.03125rem}:host([scale=s]) .description{font-size:var(--calcite-font-size--3);line-height:.85938rem}:host([scale=m]){--calcite-internal-tile-spacing: var(--calcite-spacing-md);max-inline-size:460px;min-inline-size:140px}:host([scale=m]) .heading{font-size:var(--calcite-font-size--1);line-height:1.20313rem}:host([scale=m]) .description{font-size:var(--calcite-font-size--2);line-height:1.03125rem}:host([scale=l]){--calcite-internal-tile-spacing: var(--calcite-spacing-lg);max-inline-size:520px;min-inline-size:160px}:host([scale=l]) .heading{font-size:var(--calcite-font-size-0);line-height:1.375rem}:host([scale=l]) .description{font-size:var(--calcite-font-size--1);line-height:1.20313rem}.content-container--has-content,.row{gap:var(--calcite-internal-tile-spacing)}.content-container--has-only-content-top-and-bottom slot[name=content-top]::slotted(*){margin-block-end:var(--calcite-internal-tile-spacing)}:host([selection-appearance=border][layout=horizontal]) .container.selected:focus:before,:host([selection-appearance=border][layout=vertical]) .container.selected:focus:before{block-size:100%;box-shadow:inset 0 0 0 1px var(--calcite-tile-accent-color-press, var(--calcite-color-brand));content:"";display:block;inline-size:100%;inset-block-start:0;inset-inline-start:0;position:absolute}:host([selection-appearance=border][layout=horizontal]) .container.selected{box-shadow:inset 0 -4px 0 0 var(--calcite-tile-accent-color-press, var(--calcite-color-brand))}:host([selection-appearance=border][layout=vertical]) .container.selected{box-shadow:inset 4px 0 0 0 var(--calcite-tile-accent-color-press, var(--calcite-color-brand))}:host(:hover:not([disabled])) .heading,:host([active]:not([disabled])) .heading{color:var(--calcite-tile-heading-text-color, var(--calcite-color-text-1))}:host(:hover:not([disabled])) .description,:host([active]:not([disabled])) .description{color:var(--calcite-tile-text-color, var(--calcite-color-text-2))}:host([href]:focus:not([disabled])) .container,:host([href]:hover:not([disabled])) .container{outline-color:var(--calcite-tile-link-color, var(--calcite-color-text-link));z-index:var(--calcite-z-index)}:host([href]:focus:not([disabled])) .icon,:host([href]:hover:not([disabled])) .icon{color:var(--calcite-tile-link-color, var(--calcite-color-text-link))}:host([href]:focus:not([disabled])) .heading,:host([href]:hover:not([disabled])) .heading{color:var(--calcite-tile-link-color, var(--calcite-color-text-link))}:host([href]:active:not([disabled])) .container{box-shadow:inset 0 0 0 1px var(--calcite-tile-link-color, var(--calcite-color-text-link));outline-color:var(--calcite-tile-link-color, var(--calcite-color-text-link))}:host([embed]) .container{padding:0}:host([selection-mode=none]) .container:hover,:host([selection-mode=none]) .container.selected{outline-color:var(--calcite-tile-border-color, var(--calcite-color-border-2))}:host([selection-mode=none]) .container:focus{outline-color:var(--calcite-tile-accent-color-press, var(--calcite-color-brand))}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}:host([hidden]){display:none}[hidden]{display:none}::slotted(*){max-inline-size:100%}`,p=class extends m{constructor(){super(),this.focusSetter=y()(this),this.hasContentBottom=!1,this.hasContentTop=!1,this.active=!1,this.alignment="start",this.disabled=!1,this.embed=!1,this.iconFlipRtl=!1,this.interactive=!1,this.layout="horizontal",this.scale="m",this.selected=!1,this.selectionAppearance="icon",this.selectionMode="none",this.calciteInternalTileKeyEvent=h({cancelable:!1}),this.calciteTileSelect=h(),this.listen("keydown",this.keyDownHandler)}static{this.properties={hasContentBottom:[16,{},{state:!0}],hasContentTop:[16,{},{state:!0}],active:[7,{},{reflect:!0,type:Boolean}],alignment:[3,{},{reflect:!0}],description:[3,{},{reflect:!0}],disabled:[7,{},{reflect:!0,type:Boolean}],embed:[7,{},{reflect:!0,type:Boolean}],heading:[3,{},{reflect:!0}],href:[3,{},{reflect:!0}],icon:[3,{type:String},{reflect:!0}],iconFlipRtl:[7,{},{reflect:!0,type:Boolean}],interactive:[5,{},{type:Boolean}],label:1,layout:[3,{},{reflect:!0}],scale:[3,{},{reflect:!0}],selected:[7,{},{reflect:!0,type:Boolean}],selectionAppearance:[3,{},{reflect:!0}],selectionMode:[3,{},{reflect:!0}]}}static{this.styles=A}async setFocus(e){return this.focusSetter(()=>this.interactive?this.containerEl:void 0,e)}updated(){w(this)}clickHandler(){this.interactive&&(this.setFocus(),this.handleSelectEvent())}handleSelectEvent(){this.disabled||!this.interactive||this.selectionMode==="single-persist"&&this.selected===!0||this.calciteTileSelect.emit()}handleSlotChange(e){let c=e.target.dataset.name;this[`has${c}`]=z(e)}setContainerEl(e){this.containerEl=e}keyDownHandler(e){if(e.target===this.el)switch(e.key){case" ":case"Enter":this.handleSelectEvent(),e.preventDefault();break;case"ArrowDown":case"ArrowLeft":case"ArrowRight":case"ArrowUp":case"Home":case"End":this.calciteInternalTileKeyEvent.emit(e),e.preventDefault();break}}renderSelectionIcon(){let{selected:e,selectionAppearance:c,selectionMode:a}=this;if(c==="icon"&&a!=="none")return n`<calcite-icon class=${i(t.selectionIcon)} .icon=${e?a==="multiple"?s.selectedMultiple:s.selectedSingle:a==="multiple"?s.unselectedMultiple:s.unselectedSingle} scale=s></calcite-icon>`}renderTile(){let{description:e,disabled:c,hasContentBottom:a,hasContentTop:S,heading:l,icon:r,iconFlipRtl:B,interactive:o,selectionMode:d}=this,E=l&&r&&!e,v=!!this.href||!o,u=d==="multiple"&&o?"checkbox":d!=="none"&&o?"radio":o?"button":void 0,f=!!(e||l||r),T=!f&&S&&a;return n`<div .ariaChecked=${d!=="none"&&o?this.selected:void 0} .ariaDisabled=${v?c:void 0} .ariaLabel=${u&&this.label} class=${i({[t.container]:!0,[t.interactive]:o,[t.largeVisualDeprecated]:E,[t.row]:!0,[t.selected]:this.selected})} @click=${this.clickHandler} .role=${u} tabindex=${(v?void 0:0)??x} ${g(this.setContainerEl)}>${this.renderSelectionIcon()}<div class=${i({[t.contentContainer]:!0,[t.contentContainerHasContent]:f,[t.contentContainerHasOnlyContentTopAndBottom]:T})}><slot name=${$.contentTop} @slotchange=${this.handleSlotChange}></slot>${r&&n`<calcite-icon class=${i(t.icon)} .flipRtl=${B} .icon=${r} scale=l></calcite-icon>`||""}<div class=${i({[t.textContentContainer]:!0,[t.row]:!0})}><div class=${i(t.textContent)}>${l&&n`<div class=${i(t.heading)}>${l}</div>`||""}${e&&n`<div class=${i(t.description)}>${e}</div>`||""}</div></div><slot name=${$.contentBottom} @slotchange=${this.handleSlotChange}></slot></div></div>`}render(){let{disabled:e}=this;return C({disabled:e,children:this.href?n`<calcite-link .disabled=${e} .href=${this.href}>${this.renderTile()}</calcite-link>`:this.renderTile()})}};k("calcite-tile",p);export{p as Tile};
|
|
3
|
+
v5.0.0-next.6 */
|
|
4
|
+
import{a as w,b as C}from"./UQ4HIO7J.js";import{a as y}from"./SXK4ATVN.js";import"./6PMY6MUE.js";import"./PCGNN5RO.js";import"./H3GTITDX.js";import{t as z}from"./7DQ4G2FS.js";import"./44XNJNTA.js";import{C as g,D as m,E as i,G as x,P as k,g as b,h as n,o as h}from"./2IIGKMQ6.js";var t={container:"container",contentContainer:"content-container",contentContainerHasContent:"content-container--has-content",contentContainerHasOnlyContentTopAndBottom:"content-container--has-only-content-top-and-bottom",textContentContainer:"text-content-container",description:"description",heading:"heading",icon:"icon",interactive:"interactive",largeVisualDeprecated:"large-visual-deprecated",row:"row",selected:"selected",selectionIcon:"selection-icon",textContent:"text-content"},s={selectedMultiple:"check-square-f",selectedSingle:"circle-f",unselectedMultiple:"square",unselectedSingle:"circle"},$={contentBottom:"content-bottom",contentTop:"content-top"},A=b`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host([disabled]){cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{box-shadow:var(--calcite-tile-shadow, var(--calcite-shadow-none));box-sizing:border-box;display:inline-block}calcite-link{--calcite-link-text-color: var(--calcite-tile-link-text-color)}.container{background-color:var(--calcite-tile-background-color, var(--calcite-color-foreground-1));block-size:var(--calcite-container-size-content-fluid);border-radius:var(--calcite-tile-corner-radius, var(--calcite-corner-radius));box-sizing:border-box;color:var(--calcite-tile-text-color, var(--calcite-color-text-3));inline-size:var(--calcite-container-size-content-fluid);outline:var(--calcite-border-width-sm, 1px) solid var(--calcite-tile-border-color, var(--calcite-color-border-2));padding:var(--calcite-internal-tile-spacing);position:relative;-webkit-user-select:none;user-select:none}.container .selection-icon{color:var(--calcite-tile-text-color, var(--calcite-color-text-3))}.container.interactive{cursor:pointer}.container.interactive:hover,.container.interactive:focus,.container.interactive.selected{outline-color:var(--calcite-tile-accent-color-press, var(--calcite-color-brand));z-index:var(--calcite-z-index)}.container.interactive:hover .selection-icon,.container.interactive:focus .selection-icon,.container.interactive.selected .selection-icon{color:var(--calcite-tile-accent-color-press, var(--calcite-color-brand))}.container.interactive:focus{box-shadow:inset 0 0 0 1px var(--calcite-tile-accent-color-press, var(--calcite-color-brand));z-index:calc(var(--calcite-z-index) + 1)}.content-container,.row{align-items:flex-start;display:flex}.content-container{flex-direction:column;word-wrap:break-word;word-break:break-word;inline-size:var(--calcite-container-size-content-fluid)}.text-content-container{inline-size:100%;outline-color:transparent;padding:0}.text-content{display:flex;flex-direction:column}.heading{color:var(--calcite-tile-heading-text-color, var(--calcite-color-text-2));font-weight:var(--calcite-font-weight-medium);line-height:1.20313rem;overflow-wrap:break-word}.description{font-weight:var(--calcite-font-weight-regular);overflow-wrap:break-word}.large-visual-deprecated{align-items:center;justify-content:center;min-block-size:12rem;text-align:center}.large-visual-deprecated .icon{align-self:center;block-size:64px;inline-size:64px}.large-visual-deprecated .selection-icon{position:absolute;inset-inline-start:var(--calcite-internal-tile-spacing);inset-block-start:var(--calcite-internal-tile-spacing);z-index:var(--calcite-z-index)}.large-visual-deprecated .text-content-container{justify-content:center}:host([alignment=center]) .icon{align-self:center}:host([alignment=center]) .text-content-container{justify-content:center}:host([alignment=center]) .text-content{text-align:center}:host([alignment=center]) slot[name=content-bottom]::slotted(*),:host([alignment=center]) slot[name=content-top]::slotted(*){align-self:center}:host([scale=s]){--calcite-internal-tile-spacing: var(--calcite-spacing-sm);max-inline-size:400px;min-inline-size:100px}:host([scale=s]) .heading{font-size:var(--calcite-font-size--2);line-height:1.03125rem}:host([scale=s]) .description{font-size:var(--calcite-font-size--3);line-height:.85938rem}:host([scale=m]){--calcite-internal-tile-spacing: var(--calcite-spacing-md);max-inline-size:460px;min-inline-size:140px}:host([scale=m]) .heading{font-size:var(--calcite-font-size--1);line-height:1.20313rem}:host([scale=m]) .description{font-size:var(--calcite-font-size--2);line-height:1.03125rem}:host([scale=l]){--calcite-internal-tile-spacing: var(--calcite-spacing-lg);max-inline-size:520px;min-inline-size:160px}:host([scale=l]) .heading{font-size:var(--calcite-font-size-0);line-height:1.375rem}:host([scale=l]) .description{font-size:var(--calcite-font-size--1);line-height:1.20313rem}.content-container--has-content,.row{gap:var(--calcite-internal-tile-spacing)}.content-container--has-only-content-top-and-bottom slot[name=content-top]::slotted(*){margin-block-end:var(--calcite-internal-tile-spacing)}:host([selection-appearance=border][layout=horizontal]) .container.selected:focus:before,:host([selection-appearance=border][layout=vertical]) .container.selected:focus:before{block-size:100%;box-shadow:inset 0 0 0 1px var(--calcite-tile-accent-color-press, var(--calcite-color-brand));content:"";display:block;inline-size:100%;inset-block-start:0;inset-inline-start:0;position:absolute}:host([selection-appearance=border][layout=horizontal]) .container.selected{box-shadow:inset 0 -4px 0 0 var(--calcite-tile-accent-color-press, var(--calcite-color-brand))}:host([selection-appearance=border][layout=vertical]) .container.selected{box-shadow:inset 4px 0 0 0 var(--calcite-tile-accent-color-press, var(--calcite-color-brand))}:host(:hover:not([disabled])) .heading,:host([active]:not([disabled])) .heading{color:var(--calcite-tile-heading-text-color, var(--calcite-color-text-1))}:host(:hover:not([disabled])) .description,:host([active]:not([disabled])) .description{color:var(--calcite-tile-text-color, var(--calcite-color-text-2))}:host([href]:focus:not([disabled])) .container,:host([href]:hover:not([disabled])) .container{outline-color:var(--calcite-tile-link-color, var(--calcite-color-text-link));z-index:var(--calcite-z-index)}:host([href]:focus:not([disabled])) .icon,:host([href]:hover:not([disabled])) .icon{color:var(--calcite-tile-link-color, var(--calcite-color-text-link))}:host([href]:focus:not([disabled])) .heading,:host([href]:hover:not([disabled])) .heading{color:var(--calcite-tile-link-color, var(--calcite-color-text-link))}:host([href]:active:not([disabled])) .container{box-shadow:inset 0 0 0 1px var(--calcite-tile-link-color, var(--calcite-color-text-link));outline-color:var(--calcite-tile-link-color, var(--calcite-color-text-link))}:host([embed]) .container{padding:0}:host([selection-mode=none]) .container:hover,:host([selection-mode=none]) .container.selected{outline-color:var(--calcite-tile-border-color, var(--calcite-color-border-2))}:host([selection-mode=none]) .container:focus{outline-color:var(--calcite-tile-accent-color-press, var(--calcite-color-brand))}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}:host([hidden]){display:none}[hidden]{display:none}::slotted(*){max-inline-size:100%}`,p=class extends m{constructor(){super(),this.focusSetter=y()(this),this.hasContentBottom=!1,this.hasContentTop=!1,this.active=!1,this.alignment="start",this.disabled=!1,this.embed=!1,this.iconFlipRtl=!1,this.interactive=!1,this.layout="horizontal",this.scale="m",this.selected=!1,this.selectionAppearance="icon",this.selectionMode="none",this.calciteInternalTileKeyEvent=h({cancelable:!1}),this.calciteTileSelect=h(),this.listen("keydown",this.keyDownHandler)}static{this.properties={hasContentBottom:[16,{},{state:!0}],hasContentTop:[16,{},{state:!0}],active:[7,{},{reflect:!0,type:Boolean}],alignment:[3,{},{reflect:!0}],description:[3,{},{reflect:!0}],disabled:[7,{},{reflect:!0,type:Boolean}],embed:[7,{},{reflect:!0,type:Boolean}],heading:[3,{},{reflect:!0}],href:[3,{},{reflect:!0}],icon:[3,{type:String},{reflect:!0}],iconFlipRtl:[7,{},{reflect:!0,type:Boolean}],interactive:[5,{},{type:Boolean}],label:1,layout:[3,{},{reflect:!0}],scale:[3,{},{reflect:!0}],selected:[7,{},{reflect:!0,type:Boolean}],selectionAppearance:[3,{},{reflect:!0}],selectionMode:[3,{},{reflect:!0}]}}static{this.styles=A}async setFocus(e){return this.focusSetter(()=>this.interactive?this.containerEl:void 0,e)}updated(){w(this)}clickHandler(){this.interactive&&(this.setFocus(),this.handleSelectEvent())}handleSelectEvent(){this.disabled||!this.interactive||this.selectionMode==="single-persist"&&this.selected===!0||this.calciteTileSelect.emit()}handleSlotChange(e){let c=e.target.dataset.name;this[`has${c}`]=z(e)}setContainerEl(e){this.containerEl=e}keyDownHandler(e){if(e.target===this.el)switch(e.key){case" ":case"Enter":this.handleSelectEvent(),e.preventDefault();break;case"ArrowDown":case"ArrowLeft":case"ArrowRight":case"ArrowUp":case"Home":case"End":this.calciteInternalTileKeyEvent.emit(e),e.preventDefault();break}}renderSelectionIcon(){let{selected:e,selectionAppearance:c,selectionMode:a}=this;if(c==="icon"&&a!=="none")return n`<calcite-icon class=${i(t.selectionIcon)} .icon=${e?a==="multiple"?s.selectedMultiple:s.selectedSingle:a==="multiple"?s.unselectedMultiple:s.unselectedSingle} scale=s></calcite-icon>`}renderTile(){let{description:e,disabled:c,hasContentBottom:a,hasContentTop:S,heading:l,icon:r,iconFlipRtl:B,interactive:o,selectionMode:d}=this,E=l&&r&&!e,v=!!this.href||!o,u=d==="multiple"&&o?"checkbox":d!=="none"&&o?"radio":o?"button":void 0,f=!!(e||l||r),T=!f&&S&&a;return n`<div .ariaChecked=${d!=="none"&&o?this.selected:void 0} .ariaDisabled=${v?c:void 0} .ariaLabel=${u&&this.label} class=${i({[t.container]:!0,[t.interactive]:o,[t.largeVisualDeprecated]:E,[t.row]:!0,[t.selected]:this.selected})} @click=${this.clickHandler} .role=${u} tabindex=${(v?void 0:0)??x} ${g(this.setContainerEl)}>${this.renderSelectionIcon()}<div class=${i({[t.contentContainer]:!0,[t.contentContainerHasContent]:f,[t.contentContainerHasOnlyContentTopAndBottom]:T})}><slot name=${$.contentTop} @slotchange=${this.handleSlotChange}></slot>${r&&n`<calcite-icon class=${i(t.icon)} .flipRtl=${B} .icon=${r} scale=l></calcite-icon>`||""}<div class=${i({[t.textContentContainer]:!0,[t.row]:!0})}><div class=${i(t.textContent)}>${l&&n`<div class=${i(t.heading)}>${l}</div>`||""}${e&&n`<div class=${i(t.description)}>${e}</div>`||""}</div></div><slot name=${$.contentBottom} @slotchange=${this.handleSlotChange}></slot></div></div>`}render(){let{disabled:e}=this;return C({disabled:e,children:this.href?n`<calcite-link .disabled=${e} .href=${this.href}>${this.renderTile()}</calcite-link>`:this.renderTile()})}};k("calcite-tile",p);export{p as Tile};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*! All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
|
3
|
-
v5.0.0-next.
|
|
4
|
-
import{a as A}from"./XNFJXDQ6.js";import{a as z}from"./2GG4AF5T.js";import{d as r}from"./VYFT5EAY.js";import{a as M}from"./BEUZYBM5.js";import{a as R}from"./XRSYDXWZ.js";import{a as B}from"./VQMSSO2U.js";import{a as E}from"./NULQJBCW.js";import{a as C}from"./ALDDSDTX.js";import{a as P}from"./LH7245HX.js";import{a as O}from"./WOTQIMPZ.js";import"./B5JXPZDV.js";import"./3YZG7MA3.js";import"./CIU4VM7X.js";import{D as m}from"./5IPJANUU.js";import"./ZLR2B6GQ.js";import{B as k,C as w,D,E as b,M as l,P as T,g as S,h as y,o as f}from"./AUIOWPFN.js";var g={dialog:"dialog",panel:"panel",scrim:"scrim",container:"container",containerOpen:"container--open",containerEmbedded:"container--embedded",assistiveText:"assistive-text",openingActive:"dialog--opening-active"},c={actionBar:"action-bar",alerts:"alerts",customContent:"custom-content",contentTop:"content-top",contentBottom:"content-bottom",headerActionsStart:"header-actions-start",headerActionsEnd:"header-actions-end",headerMenuActions:"header-menu-actions",headerContent:"header-content",fab:"fab",footer:"footer",footerStart:"footer-start",footerEnd:"footer-end"},I={x:null,y:null},L={top:null,right:null,bottom:null,left:null},F=S`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host{--calcite-dialog-scrim-background-color: rgba(0, 0, 0, .85);pointer-events:none;inset:0;display:flex;--calcite-internal-dialog-animation-offset: 20px}:host([embedded]){z-index:var(--calcite-z-index-overlay)}:host([embedded][modal]){position:absolute}.container{pointer-events:auto;position:fixed;inset:0;display:flex;block-size:100%;inline-size:100%;align-items:center;justify-content:center;overflow:hidden;color:var(--calcite-color-text-2);opacity:0;visibility:hidden;transition:visibility 0ms linear var(--calcite-internal-animation-timing-slow),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88)}:host([placement=top]) .container{align-items:flex-start;justify-content:center}:host([placement=top-start]) .container{align-items:flex-start;justify-content:flex-start}:host([placement=top-end]) .container{align-items:flex-start;justify-content:flex-end}:host([placement=bottom]) .container{align-items:flex-end;justify-content:center}:host([placement=bottom-start]) .container{align-items:flex-end;justify-content:flex-start}:host([placement=bottom-end]) .container{align-items:flex-end;justify-content:flex-end}:host(:not([modal])) .container{pointer-events:none}:host([scale=s]){--calcite-internal-dialog-content-padding: var(--calcite-dialog-content-space, var(--calcite-spacing-sm));--calcite-internal-dialog-min-size-x: 198px;--calcite-internal-dialog-min-size-y: 140px}:host([scale=m]){--calcite-internal-dialog-content-padding: var(--calcite-dialog-content-space, var(--calcite-spacing-md));--calcite-internal-dialog-min-size-x: 288px;--calcite-internal-dialog-min-size-y: 180px}:host([scale=l]){--calcite-internal-dialog-content-padding: var(--calcite-dialog-content-space, var(--calcite-spacing-md-plus));--calcite-internal-dialog-min-size-x: 388px;--calcite-internal-dialog-min-size-y: 220px}.scrim{--calcite-scrim-background: var(--calcite-dialog-scrim-background-color, var(--calcite-color-transparent-scrim));--calcite-scrim-background-color: var( --calcite-dialog-scrim-background-color, var(--calcite-color-transparent-scrim) );position:fixed;inset:0;z-index:calc(var(--calcite-z-index) * -1);display:flex;overflow-y:hidden}calcite-panel{--calcite-panel-content-space: var(--calcite-dialog-content-space, var(--calcite-internal-dialog-content-padding));--calcite-panel-footer-space: var(--calcite-dialog-footer-space);--calcite-panel-border-color: var(--calcite-dialog-border-color);--calcite-panel-background-color: var(--calcite-dialog-background-color, var(--calcite-color-foreground-1));--calcite-panel-icon-color: var(--calcite-dialog-icon-color);--calcite-panel-heading-text-color: var(--calcite-dialog-heading-text-color);--calcite-panel-description-text-color: var(--calcite-dialog-description-text-color);--calcite-panel-header-background-color: var(--calcite-dialog-header-background-color);--calcite-panel-header-action-background-color: var(--calcite-dialog-header-action-background-color);--calcite-panel-header-action-background-color-hover: var(--calcite-dialog-header-action-background-color-hover);--calcite-panel-header-action-background-color-press: var(--calcite-dialog-header-action-background-color-press);--calcite-panel-header-action-text-color: var(--calcite-dialog-header-action-text-color);--calcite-panel-header-action-text-color-press: var(--calcite-dialog-header-action-text-color-press);--calcite-panel-footer-background-color: var(--calcite-dialog-footer-background-color);--calcite-panel-space: var(--calcite-dialog-space, var(--calcite-internal-dialog-content-padding));--calcite-panel-header-content-space: var(--calcite-dialog-header-content-space, var(--calcite-dialog-content-space));--calcite-popover-border-color: var(--calcite-dialog-action-menu-border-color, var(--calcite-color-border-1));--calcite-panel-corner-radius: var(--calcite-dialog-corner-radius)}:host([kind=brand]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-brand))}:host([kind=danger]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-status-danger))}:host([kind=info]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-status-info))}:host([kind=success]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-status-success))}:host([kind=warning]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-status-warning))}::slotted(*){--calcite-panel-background-color: initial}[popover]{padding:0;border:none;background-color:transparent;position:fixed;display:flex}[popover]:popover-open{display:flex}.dialog{pointer-events:none;position:relative;margin:1.5rem;box-sizing:border-box;display:flex;inline-size:100%;flex-direction:column;opacity:0;--tw-shadow: 0 2px 12px -4px rgba(0, 0, 0, .2), 0 2px 4px -2px rgba(0, 0, 0, .16);--tw-shadow-colored: 0 2px 12px -4px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);-webkit-overflow-scrolling:touch;visibility:hidden;transition:inset-block var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88);border-radius:var(--calcite-dialog-corner-radius, var(--calcite-corner-radius-sm));min-inline-size:var(--calcite-dialog-min-size-x, var(--calcite-internal-dialog-min-size-x));max-inline-size:var(--calcite-dialog-max-size-x, 100%);min-block-size:var(--calcite-dialog-min-size-y, var(--calcite-internal-dialog-min-size-y));max-block-size:var(--calcite-dialog-max-size-y, 100%);--calcite-internal-dialog-hidden-position: calc( var(--calcite-dialog-offset-y, 0px) + var(--calcite-internal-dialog-animation-offset) );--calcite-internal-dialog-shown-position: var(--calcite-dialog-offset-y, 0);inset-inline-start:var(--calcite-dialog-offset-x, 0);inset-block-start:var(--calcite-internal-dialog-hidden-position)}.dialog--opening-active{inset-block-start:var(--calcite-internal-dialog-shown-position)}:host([embedded]) .dialog{z-index:var(--calcite-z-index-modal)}:host([menu-open]) .dialog{transition:visibility 0ms linear var(--calcite-internal-animation-timing-slow),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88)}.panel{visibility:hidden;opacity:0;border-radius:var(--calcite-dialog-corner-radius, var(--calcite-corner-radius-sm));transition:visibility 0ms linear var(--calcite-internal-animation-timing-slow),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88)}.container--open .panel{visibility:visible;opacity:1;transition:visibility 0ms linear,opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88)}.container--open{opacity:1;visibility:visible;transition-delay:0ms}.container--open .dialog{pointer-events:auto;visibility:visible;opacity:1;transition:inset-block var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88);transition-delay:0ms}.width-s{inline-size:auto;inline-size:var(--calcite-dialog-size-x, 32rem);block-size:var(--calcite-dialog-size-y, auto)}@media screen and (max-width:35rem){.width-s{margin:0;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%;inset-inline-start:0;inset-block-start:var(--calcite-internal-dialog-animation-offset)}.width-s.dialog--opening-active{inset-block-start:0}}.width-m{inline-size:var(--calcite-dialog-size-x, 48rem);block-size:var(--calcite-dialog-size-y, auto)}@media screen and (max-width:51rem){.width-m{margin:0;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%;inset-inline-start:0;inset-block-start:var(--calcite-internal-dialog-animation-offset)}.width-m.dialog--opening-active{inset-block-start:0}}.width-l{inline-size:var(--calcite-dialog-size-x, 94rem);block-size:var(--calcite-dialog-size-y, auto)}@media screen and (max-width:97rem){.width-l{margin:0;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%;inset-inline-start:0;inset-block-start:var(--calcite-internal-dialog-animation-offset)}.width-l.dialog--opening-active{inset-block-start:0}}:host([placement=cover]) .dialog{margin:0;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%;border-radius:0}:host([placement=cover]) .panel{border-radius:0}:host([kind]) .panel{border-start-start-radius:0px;border-start-end-radius:0px}:host([kind]) .dialog{overflow:hidden}:host([kind=brand]) .dialog{border-color:var(--calcite-color-brand)}:host([kind=danger]) .dialog{border-color:var(--calcite-dialog-accent-color, var(--calcite-color-status-danger))}:host([kind=info]) .dialog{border-color:var(--calcite-dialog-accent-color, var(--calcite-color-status-info))}:host([kind=success]) .dialog{border-color:var(--calcite-dialog-accent-color, var(--calcite-color-status-success))}:host([kind=warning]) .dialog{border-color:var(--calcite-dialog-accent-color, var(--calcite-color-status-warning))}:host([kind=brand][open]) .dialog,:host([kind=danger][open]) .dialog,:host([kind=info][open]) .dialog,:host([kind=success][open]) .dialog,:host([kind=warning][open]) .dialog{border-width:0px;border-block-start-width:4px;border-style:solid}.container--embedded{z-index:var(--calcite-z-index-overlay);position:absolute;pointer-events:auto}.container--embedded calcite-scrim{position:absolute}.assistive-text{position:absolute;inline-size:1px;block-size:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}:host([hidden]){display:none}[hidden]{display:none}`,$=class extends D{constructor(){super(...arguments),this.dragPosition={...I},this.focusTrap=M({triggerProp:"open",focusTrapOptions:{clickOutsideDeactivates:()=>!this.modal||this.embedded,escapeDeactivates:e=>(!e.defaultPrevented&&!this.escapeDisabled&&(this.open=!1,e.preventDefault()),!1)}})(this),this.usePreventDocumentScroll=A()(this),this.mutationObserver=C("mutation",()=>this.handleMutationObserver()),this._open=!1,this.openProp="opened",this.transitionProp="opacity",this.panelRef=k(),this.popoverRef=k(),this.resizePosition={...L},this.messages=P(),this.focusSetter=O()(this),this.assistiveText=null,this.hasContentBottom=!1,this.hasContentTop=!1,this.hasFooter=!0,this.opened=!1,this.closeDisabled=!1,this.dragEnabled=!1,this.embedded=!1,this.escapeDisabled=!1,this.iconFlipRtl=!1,this.loading=!1,this.menuOpen=!1,this.modal=!1,this.focusTrapDisabled=!1,this.outsideCloseDisabled=!1,this.overlayPositioning="absolute",this.placement="center",this.resizable=!1,this.scale="m",this.widthScale="m",this.calciteDialogBeforeClose=f({cancelable:!1}),this.calciteDialogBeforeOpen=f({cancelable:!1}),this.calciteDialogClose=f({cancelable:!1}),this.calciteDialogOpen=f({cancelable:!1}),this.calciteDialogScroll=f({cancelable:!1})}static{this.properties={assistiveText:[16,{},{state:!0}],hasContentBottom:[16,{},{state:!0}],hasContentTop:[16,{},{state:!0}],hasFooter:[16,{},{state:!0}],opened:[16,{},{state:!0}],beforeClose:[0,{},{attribute:!1}],closeDisabled:[7,{},{reflect:!0,type:Boolean}],description:1,dragEnabled:[7,{},{reflect:!0,type:Boolean}],embedded:[7,{},{reflect:!0,type:Boolean}],escapeDisabled:[7,{},{reflect:!0,type:Boolean}],focusTrapOptions:[0,{},{attribute:!1}],heading:1,headingLevel:[11,{},{type:Number,reflect:!0}],kind:[3,{},{reflect:!0}],icon:[3,{type:String},{reflect:!0}],iconFlipRtl:[7,{},{reflect:!0,type:Boolean}],loading:[7,{},{reflect:!0,type:Boolean}],menuOpen:[7,{},{reflect:!0,type:Boolean}],messageOverrides:[0,{},{attribute:!1}],modal:[7,{},{reflect:!0,type:Boolean}],focusTrapDisabled:[7,{},{reflect:!0,type:Boolean}],open:[7,{},{reflect:!0,type:Boolean}],outsideCloseDisabled:[7,{},{reflect:!0,type:Boolean}],overlayPositioning:[3,{},{reflect:!0}],placement:[3,{},{reflect:!0}],resizable:[7,{},{reflect:!0,type:Boolean}],scale:[3,{},{reflect:!0}],widthScale:[3,{},{reflect:!0}],width:[3,{},{reflect:!0}]}}static{this.styles=F}get preventDocumentScroll(){return!this.embedded&&this.modal}get open(){return this._open}set open(e){let t=this._open;e!==t&&this.setOpenState(e)}async scrollContentTo(e){await this.panelRef.value?.scrollContentTo(e)}async setFocus(e){return this.focusSetter(()=>this.panelRef.value??this.el,e)}async updateFocusTrapElements(e){this.focusTrap.setExtraContainers(e),this.focusTrap.updateContainerElements()}connectedCallback(){super.connectedCallback(),this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0}),this.setupInteractions()}willUpdate(e){(e.has("open")&&(this.hasUpdated||this.open!==!1)||e.has("placement")&&(this.hasUpdated||this.placement!=="center")||e.has("resizable")&&(this.hasUpdated||this.resizable!==!1)||e.has("dragEnabled")&&(this.hasUpdated||this.dragEnabled!==!1))&&this.setupInteractions(),(e.has("messages")||e.has("dragEnabled")&&(this.hasUpdated||this.dragEnabled!==!1)||e.has("resizable")&&(this.hasUpdated||this.resizable!==!1))&&this.updateAssistiveText(),e.has("opened")&&(this.hasUpdated||this.opened!==!1)&&this.handleOpenedChange(this.opened)}disconnectedCallback(){super.disconnectedCallback(),this.mutationObserver?.disconnect(),this.embedded=!1,this.cleanupInteractions()}focusTrapDisabledOverride(){return!this.modal&&this.focusTrapDisabled}updateAssistiveText(){let{messages:e}=this;this.assistiveText=e&&(this.dragEnabled||this.resizable)?`${this.dragEnabled?e.dragEnabled:""} ${this.resizable?e.resizeEnabled:""}`:null}onBeforeOpen(){this.calciteDialogBeforeOpen.emit()}onOpen(){this.focusTrapDisabled&&this.setFocus(),this.focusTrap.activate(),this.calciteDialogOpen.emit()}onBeforeClose(){this.calciteDialogBeforeClose.emit()}onClose(){this.focusTrap.deactivate(),this.calciteDialogClose.emit()}async setOpenState(e){if(this.beforeClose&&!e)try{await this.beforeClose?.()}catch{return}this._open=e,e&&await this.componentOnReady(),this.opened=e}async handlePopover(){await this.componentOnReady(),!(this.embedded||!this.popoverRef.value)&&(this.open?this.popoverRef.value.showPopover():this.popoverRef.value.hidePopover())}handleOpenedChange(e){let{transitionEl:t}=this;t&&(t.classList.toggle(g.openingActive,e),B(this),this.handlePopover())}async triggerInteractModifiers(){let{interaction:e}=this;e&&(await e.reflow({name:"drag"}),await e.reflow({name:"resize"}))}getTransitionElDOMRect(){return this.transitionEl.getBoundingClientRect()}handleKeyDown(e){let{key:t,shiftKey:i,defaultPrevented:n}=e,{dragEnabled:a,resizable:o,resizePosition:d,dragPosition:s,transitionEl:h}=this;if(!(n||!["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"].includes(t)))switch(t){case"ArrowUp":if(i&&o&&h){let{minBlockSize:u}=window.getComputedStyle(h),p=m(u),v=this.getTransitionElDOMRect().height;if(v<=p)return;this.updateSize({size:v-l,type:"blockSize"}),d.bottom-=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault()}else a&&(s.y-=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault());break;case"ArrowDown":i&&o&&h?(this.updateSize({size:this.getTransitionElDOMRect().height+l,type:"blockSize"}),d.bottom+=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault()):a&&(s.y+=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault());break;case"ArrowLeft":if(i&&o&&h){let{minInlineSize:u}=window.getComputedStyle(h),p=m(u),v=this.getTransitionElDOMRect().width;if(v<=p)return;this.updateSize({size:v-l,type:"inlineSize"}),d.right-=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault()}else a&&(s.x-=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault());break;case"ArrowRight":i&&o&&h?(this.updateSize({size:this.getTransitionElDOMRect().width+l,type:"inlineSize"}),d.right+=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault()):a&&(s.x+=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault());break}}updateTransform(){let{dragPosition:{x:e,y:t},resizePosition:i,transitionEl:n,dragEnabled:a,resizable:o}=this;if(!n)return;if(!a&&!o){n.style.transform=null;return}let{top:d,right:s,bottom:h,left:x}=this.getAdjustedResizePosition(i),u=Math.round(e+x+s),p=Math.round(t+d+h);n.style.transform=u||p?`translate(${u}px, ${p}px)`:null}updateSize({type:e,size:t}){let{transitionEl:i}=this;i&&(i.style[e]=t!==null?`${Math.round(t)}px`:null)}cleanupInteractions(){this.interaction?.unset(),this.updateSize({size:null,type:"inlineSize"}),this.updateSize({size:null,type:"blockSize"}),this.dragPosition={...I},this.resizePosition={...L},this.updateTransform()}async setupInteractions(){this.cleanupInteractions();let{el:e,transitionEl:t,resizable:i,dragEnabled:n,resizePosition:a,dragPosition:o}=this;if(!(!t||!this.open)){if((i||n)&&(this.interaction=z(t,{context:e.ownerDocument})),i){await this.el.componentOnReady();let{minInlineSize:d,minBlockSize:s,maxInlineSize:h,maxBlockSize:x}=window.getComputedStyle(t);this.interaction.resizable({edges:{top:!0,right:!0,bottom:!0,left:!0},modifiers:[z.modifiers.restrictSize({min:{width:m(d),height:m(s)},max:{width:m(h)||window.innerWidth,height:m(x)||window.innerHeight}}),z.modifiers.restrict({restriction:"parent"})],listeners:{move:({rect:u,deltaRect:p})=>{p&&(a.top+=p.top,a.right+=p.right,a.bottom+=p.bottom,a.left+=p.left),this.updateSize({size:u.width,type:"inlineSize"}),this.updateSize({size:u.height,type:"blockSize"}),this.updateTransform()}}})}n&&this.interaction.draggable({modifiers:[z.modifiers.restrictRect({restriction:"parent"})],listeners:{move:({dx:d,dy:s})=>{o.x+=d,o.y+=s,this.updateTransform()}}})}}getAdjustedResizePosition({top:e,right:t,bottom:i,left:n}){let a=e/2,o=t/2,d=i/2,s=n/2;switch(this.placement){case"top":return{top:e,right:o,bottom:0,left:s};case"top-start":return{top:e,right:0,bottom:0,left:n};case"top-end":return{top:e,right:t,bottom:0,left:0};case"bottom":return{top:0,right:o,bottom:i,left:s};case"bottom-start":return{top:0,right:0,bottom:i,left:n};case"bottom-end":return{top:0,right:t,bottom:i,left:0};case"cover":case"center":default:return{top:a,right:o,bottom:d,left:s}}}setTransitionEl(e){e&&(this.transitionEl=e,this.setupInteractions(),this.handlePopover())}handleInternalPanelScroll(e){e.target===this.panelRef.value&&(e.stopPropagation(),this.calciteDialogScroll.emit())}handleInternalPanelCloseClick(e){e.target===this.panelRef.value&&(e.preventDefault(),e.stopPropagation(),this.open=!1)}handlePanelKeyDown(e){this.escapeDisabled&&e.key==="Escape"&&!e.defaultPrevented&&e.preventDefault()}handleOutsideClose(){this.outsideCloseDisabled||(this.open=!1)}handleMutationObserver(){this.focusTrap.updateContainerElements()}render(){let{assistiveText:e,description:t,heading:i,opened:n,icon:a,iconFlipRtl:o}=this;return y`<div .ariaDescription=${t} .ariaLabel=${i} .ariaModal=${this.modal} class=${b({[g.container]:!0,[g.containerOpen]:n,[g.containerEmbedded]:this.embedded})} .popover=${this.embedded?null:"manual"} role=dialog ${w(this.popoverRef)}>${this.modal?y`<calcite-scrim class=${b(g.scrim)} @click=${this.handleOutsideClose}></calcite-scrim>`:null}<div class=${b({[g.dialog]:!0,[R("width",this.width,this.widthScale)]:!!(this.width||this.widthScale)})} @keydown=${this.handleKeyDown} ${w(this.setTransitionEl)}>${e?E("assistive-text",y`<div aria-live=polite class=${b(g.assistiveText)}>${e}</div>`):null}<slot name=${c.customContent}><calcite-panel class=${b(g.panel)} .closable=${!this.closeDisabled} .description=${t} .heading=${i} .headingLevel=${this.headingLevel} .hidden=${!this.opened} .icon=${a} .iconFlipRtl=${o} .loading=${this.loading} .menuOpen=${this.menuOpen} .messageOverrides=${this.messageOverrides} @keydown=${this.handlePanelKeyDown} @calcitePanelClose=${this.handleInternalPanelCloseClick} @calcitePanelScroll=${this.handleInternalPanelScroll} .overlayPositioning=${this.overlayPositioning} .scale=${this.scale} ${w(this.panelRef)}><slot name=${c.actionBar} slot=${r.actionBar}></slot><slot name=${c.alerts} slot=${r.alerts}></slot><slot name=${c.headerActionsStart} slot=${r.headerActionsStart}></slot><slot name=${c.headerActionsEnd} slot=${r.headerActionsEnd}></slot><slot name=${c.headerContent} slot=${r.headerContent}></slot><slot name=${c.headerMenuActions} slot=${r.headerMenuActions}></slot><slot name=${c.fab} slot=${r.fab}></slot><slot name=${c.contentTop} slot=${r.contentTop}></slot><slot name=${c.contentBottom} slot=${r.contentBottom}></slot><slot name=${c.footerStart} slot=${r.footerStart}></slot><slot name=${c.footer} slot=${r.footer}></slot><slot name=${c.footerEnd} slot=${r.footerEnd}></slot><slot></slot></calcite-panel></slot></div></div>`}};T("calcite-dialog",$);export{$ as Dialog};
|
|
3
|
+
v5.0.0-next.6 */
|
|
4
|
+
import{a as A}from"./ZJD56MA6.js";import{a as z}from"./OXZ2Y5YM.js";import{d as r}from"./NOOPM2CL.js";import{a as M}from"./AANSYYFF.js";import{a as R}from"./KDHLLH5G.js";import{a as B}from"./LFYXGVGK.js";import{a as E}from"./7XEO6UJ3.js";import{a as C}from"./CZF6KYOX.js";import{a as P}from"./CFWXX2ZT.js";import{a as O}from"./SXK4ATVN.js";import"./6PMY6MUE.js";import"./PCGNN5RO.js";import"./H3GTITDX.js";import{D as m}from"./7DQ4G2FS.js";import"./44XNJNTA.js";import{B as k,C as w,D,E as b,M as l,P as T,g as S,h as y,o as f}from"./2IIGKMQ6.js";var g={dialog:"dialog",panel:"panel",scrim:"scrim",container:"container",containerOpen:"container--open",containerEmbedded:"container--embedded",assistiveText:"assistive-text",openingActive:"dialog--opening-active"},c={actionBar:"action-bar",alerts:"alerts",customContent:"custom-content",contentTop:"content-top",contentBottom:"content-bottom",headerActionsStart:"header-actions-start",headerActionsEnd:"header-actions-end",headerMenuActions:"header-menu-actions",headerContent:"header-content",fab:"fab",footer:"footer",footerStart:"footer-start",footerEnd:"footer-end"},I={x:null,y:null},L={top:null,right:null,bottom:null,left:null},F=S`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host{--calcite-dialog-scrim-background-color: rgba(0, 0, 0, .85);pointer-events:none;inset:0;display:flex;--calcite-internal-dialog-animation-offset: 20px}:host([embedded]){z-index:var(--calcite-z-index-overlay)}:host([embedded][modal]){position:absolute}.container{pointer-events:auto;position:fixed;inset:0;display:flex;block-size:100%;inline-size:100%;align-items:center;justify-content:center;overflow:hidden;color:var(--calcite-color-text-2);opacity:0;visibility:hidden;transition:visibility 0ms linear var(--calcite-internal-animation-timing-slow),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88)}:host([placement=top]) .container{align-items:flex-start;justify-content:center}:host([placement=top-start]) .container{align-items:flex-start;justify-content:flex-start}:host([placement=top-end]) .container{align-items:flex-start;justify-content:flex-end}:host([placement=bottom]) .container{align-items:flex-end;justify-content:center}:host([placement=bottom-start]) .container{align-items:flex-end;justify-content:flex-start}:host([placement=bottom-end]) .container{align-items:flex-end;justify-content:flex-end}:host(:not([modal])) .container{pointer-events:none}:host([scale=s]){--calcite-internal-dialog-content-padding: var(--calcite-dialog-content-space, var(--calcite-spacing-sm));--calcite-internal-dialog-min-size-x: 198px;--calcite-internal-dialog-min-size-y: 140px}:host([scale=m]){--calcite-internal-dialog-content-padding: var(--calcite-dialog-content-space, var(--calcite-spacing-md));--calcite-internal-dialog-min-size-x: 288px;--calcite-internal-dialog-min-size-y: 180px}:host([scale=l]){--calcite-internal-dialog-content-padding: var(--calcite-dialog-content-space, var(--calcite-spacing-md-plus));--calcite-internal-dialog-min-size-x: 388px;--calcite-internal-dialog-min-size-y: 220px}.scrim{--calcite-scrim-background: var(--calcite-dialog-scrim-background-color, var(--calcite-color-transparent-scrim));--calcite-scrim-background-color: var( --calcite-dialog-scrim-background-color, var(--calcite-color-transparent-scrim) );position:fixed;inset:0;z-index:calc(var(--calcite-z-index) * -1);display:flex;overflow-y:hidden}calcite-panel{--calcite-panel-content-space: var(--calcite-dialog-content-space, var(--calcite-internal-dialog-content-padding));--calcite-panel-footer-space: var(--calcite-dialog-footer-space);--calcite-panel-border-color: var(--calcite-dialog-border-color);--calcite-panel-background-color: var(--calcite-dialog-background-color, var(--calcite-color-foreground-1));--calcite-panel-icon-color: var(--calcite-dialog-icon-color);--calcite-panel-heading-text-color: var(--calcite-dialog-heading-text-color);--calcite-panel-description-text-color: var(--calcite-dialog-description-text-color);--calcite-panel-header-background-color: var(--calcite-dialog-header-background-color);--calcite-panel-header-action-background-color: var(--calcite-dialog-header-action-background-color);--calcite-panel-header-action-background-color-hover: var(--calcite-dialog-header-action-background-color-hover);--calcite-panel-header-action-background-color-press: var(--calcite-dialog-header-action-background-color-press);--calcite-panel-header-action-text-color: var(--calcite-dialog-header-action-text-color);--calcite-panel-header-action-text-color-press: var(--calcite-dialog-header-action-text-color-press);--calcite-panel-footer-background-color: var(--calcite-dialog-footer-background-color);--calcite-panel-space: var(--calcite-dialog-space, var(--calcite-internal-dialog-content-padding));--calcite-panel-header-content-space: var(--calcite-dialog-header-content-space, var(--calcite-dialog-content-space));--calcite-popover-border-color: var(--calcite-dialog-action-menu-border-color, var(--calcite-color-border-1));--calcite-panel-corner-radius: var(--calcite-dialog-corner-radius)}:host([kind=brand]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-brand))}:host([kind=danger]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-status-danger))}:host([kind=info]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-status-info))}:host([kind=success]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-status-success))}:host([kind=warning]) calcite-panel{--calcite-panel-icon-color: var(--calcite-dialog-icon-color, var(--calcite-color-status-warning))}::slotted(*){--calcite-panel-background-color: initial}[popover]{padding:0;border:none;background-color:transparent;position:fixed;display:flex}[popover]:popover-open{display:flex}.dialog{pointer-events:none;position:relative;margin:1.5rem;box-sizing:border-box;display:flex;inline-size:100%;flex-direction:column;opacity:0;--tw-shadow: 0 2px 12px -4px rgba(0, 0, 0, .2), 0 2px 4px -2px rgba(0, 0, 0, .16);--tw-shadow-colored: 0 2px 12px -4px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);-webkit-overflow-scrolling:touch;visibility:hidden;transition:inset-block var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88);border-radius:var(--calcite-dialog-corner-radius, var(--calcite-corner-radius-sm));min-inline-size:var(--calcite-dialog-min-size-x, var(--calcite-internal-dialog-min-size-x));max-inline-size:var(--calcite-dialog-max-size-x, 100%);min-block-size:var(--calcite-dialog-min-size-y, var(--calcite-internal-dialog-min-size-y));max-block-size:var(--calcite-dialog-max-size-y, 100%);--calcite-internal-dialog-hidden-position: calc( var(--calcite-dialog-offset-y, 0px) + var(--calcite-internal-dialog-animation-offset) );--calcite-internal-dialog-shown-position: var(--calcite-dialog-offset-y, 0);inset-inline-start:var(--calcite-dialog-offset-x, 0);inset-block-start:var(--calcite-internal-dialog-hidden-position)}.dialog--opening-active{inset-block-start:var(--calcite-internal-dialog-shown-position)}:host([embedded]) .dialog{z-index:var(--calcite-z-index-modal)}:host([menu-open]) .dialog{transition:visibility 0ms linear var(--calcite-internal-animation-timing-slow),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88)}.panel{visibility:hidden;opacity:0;border-radius:var(--calcite-dialog-corner-radius, var(--calcite-corner-radius-sm));transition:visibility 0ms linear var(--calcite-internal-animation-timing-slow),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88)}.container--open .panel{visibility:visible;opacity:1;transition:visibility 0ms linear,opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88)}.container--open{opacity:1;visibility:visible;transition-delay:0ms}.container--open .dialog{pointer-events:auto;visibility:visible;opacity:1;transition:inset-block var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88),opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(.215,.44,.42,.88);transition-delay:0ms}.width-s{inline-size:auto;inline-size:var(--calcite-dialog-size-x, 32rem);block-size:var(--calcite-dialog-size-y, auto)}@media screen and (max-width:35rem){.width-s{margin:0;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%;inset-inline-start:0;inset-block-start:var(--calcite-internal-dialog-animation-offset)}.width-s.dialog--opening-active{inset-block-start:0}}.width-m{inline-size:var(--calcite-dialog-size-x, 48rem);block-size:var(--calcite-dialog-size-y, auto)}@media screen and (max-width:51rem){.width-m{margin:0;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%;inset-inline-start:0;inset-block-start:var(--calcite-internal-dialog-animation-offset)}.width-m.dialog--opening-active{inset-block-start:0}}.width-l{inline-size:var(--calcite-dialog-size-x, 94rem);block-size:var(--calcite-dialog-size-y, auto)}@media screen and (max-width:97rem){.width-l{margin:0;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%;inset-inline-start:0;inset-block-start:var(--calcite-internal-dialog-animation-offset)}.width-l.dialog--opening-active{inset-block-start:0}}:host([placement=cover]) .dialog{margin:0;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%;border-radius:0}:host([placement=cover]) .panel{border-radius:0}:host([kind]) .panel{border-start-start-radius:0px;border-start-end-radius:0px}:host([kind]) .dialog{overflow:hidden}:host([kind=brand]) .dialog{border-color:var(--calcite-color-brand)}:host([kind=danger]) .dialog{border-color:var(--calcite-dialog-accent-color, var(--calcite-color-status-danger))}:host([kind=info]) .dialog{border-color:var(--calcite-dialog-accent-color, var(--calcite-color-status-info))}:host([kind=success]) .dialog{border-color:var(--calcite-dialog-accent-color, var(--calcite-color-status-success))}:host([kind=warning]) .dialog{border-color:var(--calcite-dialog-accent-color, var(--calcite-color-status-warning))}:host([kind=brand][open]) .dialog,:host([kind=danger][open]) .dialog,:host([kind=info][open]) .dialog,:host([kind=success][open]) .dialog,:host([kind=warning][open]) .dialog{border-width:0px;border-block-start-width:4px;border-style:solid}.container--embedded{z-index:var(--calcite-z-index-overlay);position:absolute;pointer-events:auto}.container--embedded calcite-scrim{position:absolute}.assistive-text{position:absolute;inline-size:1px;block-size:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}:host([hidden]){display:none}[hidden]{display:none}`,$=class extends D{constructor(){super(...arguments),this.dragPosition={...I},this.focusTrap=M({triggerProp:"open",focusTrapOptions:{clickOutsideDeactivates:()=>!this.modal||this.embedded,escapeDeactivates:e=>(!e.defaultPrevented&&!this.escapeDisabled&&(this.open=!1,e.preventDefault()),!1)}})(this),this.usePreventDocumentScroll=A()(this),this.mutationObserver=C("mutation",()=>this.handleMutationObserver()),this._open=!1,this.openProp="opened",this.transitionProp="opacity",this.panelRef=k(),this.popoverRef=k(),this.resizePosition={...L},this.messages=P(),this.focusSetter=O()(this),this.assistiveText=null,this.hasContentBottom=!1,this.hasContentTop=!1,this.hasFooter=!0,this.opened=!1,this.closeDisabled=!1,this.dragEnabled=!1,this.embedded=!1,this.escapeDisabled=!1,this.iconFlipRtl=!1,this.loading=!1,this.menuOpen=!1,this.modal=!1,this.focusTrapDisabled=!1,this.outsideCloseDisabled=!1,this.overlayPositioning="absolute",this.placement="center",this.resizable=!1,this.scale="m",this.widthScale="m",this.calciteDialogBeforeClose=f({cancelable:!1}),this.calciteDialogBeforeOpen=f({cancelable:!1}),this.calciteDialogClose=f({cancelable:!1}),this.calciteDialogOpen=f({cancelable:!1}),this.calciteDialogScroll=f({cancelable:!1})}static{this.properties={assistiveText:[16,{},{state:!0}],hasContentBottom:[16,{},{state:!0}],hasContentTop:[16,{},{state:!0}],hasFooter:[16,{},{state:!0}],opened:[16,{},{state:!0}],beforeClose:[0,{},{attribute:!1}],closeDisabled:[7,{},{reflect:!0,type:Boolean}],description:1,dragEnabled:[7,{},{reflect:!0,type:Boolean}],embedded:[7,{},{reflect:!0,type:Boolean}],escapeDisabled:[7,{},{reflect:!0,type:Boolean}],focusTrapOptions:[0,{},{attribute:!1}],heading:1,headingLevel:[11,{},{type:Number,reflect:!0}],kind:[3,{},{reflect:!0}],icon:[3,{type:String},{reflect:!0}],iconFlipRtl:[7,{},{reflect:!0,type:Boolean}],loading:[7,{},{reflect:!0,type:Boolean}],menuOpen:[7,{},{reflect:!0,type:Boolean}],messageOverrides:[0,{},{attribute:!1}],modal:[7,{},{reflect:!0,type:Boolean}],focusTrapDisabled:[7,{},{reflect:!0,type:Boolean}],open:[7,{},{reflect:!0,type:Boolean}],outsideCloseDisabled:[7,{},{reflect:!0,type:Boolean}],overlayPositioning:[3,{},{reflect:!0}],placement:[3,{},{reflect:!0}],resizable:[7,{},{reflect:!0,type:Boolean}],scale:[3,{},{reflect:!0}],widthScale:[3,{},{reflect:!0}],width:[3,{},{reflect:!0}]}}static{this.styles=F}get preventDocumentScroll(){return!this.embedded&&this.modal}get open(){return this._open}set open(e){let t=this._open;e!==t&&this.setOpenState(e)}async scrollContentTo(e){await this.panelRef.value?.scrollContentTo(e)}async setFocus(e){return this.focusSetter(()=>this.panelRef.value??this.el,e)}async updateFocusTrapElements(e){this.focusTrap.setExtraContainers(e),this.focusTrap.updateContainerElements()}connectedCallback(){super.connectedCallback(),this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0}),this.setupInteractions()}willUpdate(e){(e.has("open")&&(this.hasUpdated||this.open!==!1)||e.has("placement")&&(this.hasUpdated||this.placement!=="center")||e.has("resizable")&&(this.hasUpdated||this.resizable!==!1)||e.has("dragEnabled")&&(this.hasUpdated||this.dragEnabled!==!1))&&this.setupInteractions(),(e.has("messages")||e.has("dragEnabled")&&(this.hasUpdated||this.dragEnabled!==!1)||e.has("resizable")&&(this.hasUpdated||this.resizable!==!1))&&this.updateAssistiveText(),e.has("opened")&&(this.hasUpdated||this.opened!==!1)&&this.handleOpenedChange(this.opened)}disconnectedCallback(){super.disconnectedCallback(),this.mutationObserver?.disconnect(),this.embedded=!1,this.cleanupInteractions()}focusTrapDisabledOverride(){return!this.modal&&this.focusTrapDisabled}updateAssistiveText(){let{messages:e}=this;this.assistiveText=e&&(this.dragEnabled||this.resizable)?`${this.dragEnabled?e.dragEnabled:""} ${this.resizable?e.resizeEnabled:""}`:null}onBeforeOpen(){this.calciteDialogBeforeOpen.emit()}onOpen(){this.focusTrapDisabled&&this.setFocus(),this.focusTrap.activate(),this.calciteDialogOpen.emit()}onBeforeClose(){this.calciteDialogBeforeClose.emit()}onClose(){this.focusTrap.deactivate(),this.calciteDialogClose.emit()}async setOpenState(e){if(this.beforeClose&&!e)try{await this.beforeClose?.()}catch{return}this._open=e,e&&await this.componentOnReady(),this.opened=e}async handlePopover(){await this.componentOnReady(),!(this.embedded||!this.popoverRef.value)&&(this.open?this.popoverRef.value.showPopover():this.popoverRef.value.hidePopover())}handleOpenedChange(e){let{transitionEl:t}=this;t&&(t.classList.toggle(g.openingActive,e),B(this),this.handlePopover())}async triggerInteractModifiers(){let{interaction:e}=this;e&&(await e.reflow({name:"drag"}),await e.reflow({name:"resize"}))}getTransitionElDOMRect(){return this.transitionEl.getBoundingClientRect()}handleKeyDown(e){let{key:t,shiftKey:i,defaultPrevented:n}=e,{dragEnabled:a,resizable:o,resizePosition:d,dragPosition:s,transitionEl:h}=this;if(!(n||!["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"].includes(t)))switch(t){case"ArrowUp":if(i&&o&&h){let{minBlockSize:u}=window.getComputedStyle(h),p=m(u),v=this.getTransitionElDOMRect().height;if(v<=p)return;this.updateSize({size:v-l,type:"blockSize"}),d.bottom-=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault()}else a&&(s.y-=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault());break;case"ArrowDown":i&&o&&h?(this.updateSize({size:this.getTransitionElDOMRect().height+l,type:"blockSize"}),d.bottom+=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault()):a&&(s.y+=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault());break;case"ArrowLeft":if(i&&o&&h){let{minInlineSize:u}=window.getComputedStyle(h),p=m(u),v=this.getTransitionElDOMRect().width;if(v<=p)return;this.updateSize({size:v-l,type:"inlineSize"}),d.right-=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault()}else a&&(s.x-=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault());break;case"ArrowRight":i&&o&&h?(this.updateSize({size:this.getTransitionElDOMRect().width+l,type:"inlineSize"}),d.right+=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault()):a&&(s.x+=l,this.updateTransform(),this.triggerInteractModifiers(),e.preventDefault());break}}updateTransform(){let{dragPosition:{x:e,y:t},resizePosition:i,transitionEl:n,dragEnabled:a,resizable:o}=this;if(!n)return;if(!a&&!o){n.style.transform=null;return}let{top:d,right:s,bottom:h,left:x}=this.getAdjustedResizePosition(i),u=Math.round(e+x+s),p=Math.round(t+d+h);n.style.transform=u||p?`translate(${u}px, ${p}px)`:null}updateSize({type:e,size:t}){let{transitionEl:i}=this;i&&(i.style[e]=t!==null?`${Math.round(t)}px`:null)}cleanupInteractions(){this.interaction?.unset(),this.updateSize({size:null,type:"inlineSize"}),this.updateSize({size:null,type:"blockSize"}),this.dragPosition={...I},this.resizePosition={...L},this.updateTransform()}async setupInteractions(){this.cleanupInteractions();let{el:e,transitionEl:t,resizable:i,dragEnabled:n,resizePosition:a,dragPosition:o}=this;if(!(!t||!this.open)){if((i||n)&&(this.interaction=z(t,{context:e.ownerDocument})),i){await this.el.componentOnReady();let{minInlineSize:d,minBlockSize:s,maxInlineSize:h,maxBlockSize:x}=window.getComputedStyle(t);this.interaction.resizable({edges:{top:!0,right:!0,bottom:!0,left:!0},modifiers:[z.modifiers.restrictSize({min:{width:m(d),height:m(s)},max:{width:m(h)||window.innerWidth,height:m(x)||window.innerHeight}}),z.modifiers.restrict({restriction:"parent"})],listeners:{move:({rect:u,deltaRect:p})=>{p&&(a.top+=p.top,a.right+=p.right,a.bottom+=p.bottom,a.left+=p.left),this.updateSize({size:u.width,type:"inlineSize"}),this.updateSize({size:u.height,type:"blockSize"}),this.updateTransform()}}})}n&&this.interaction.draggable({modifiers:[z.modifiers.restrictRect({restriction:"parent"})],listeners:{move:({dx:d,dy:s})=>{o.x+=d,o.y+=s,this.updateTransform()}}})}}getAdjustedResizePosition({top:e,right:t,bottom:i,left:n}){let a=e/2,o=t/2,d=i/2,s=n/2;switch(this.placement){case"top":return{top:e,right:o,bottom:0,left:s};case"top-start":return{top:e,right:0,bottom:0,left:n};case"top-end":return{top:e,right:t,bottom:0,left:0};case"bottom":return{top:0,right:o,bottom:i,left:s};case"bottom-start":return{top:0,right:0,bottom:i,left:n};case"bottom-end":return{top:0,right:t,bottom:i,left:0};case"cover":case"center":default:return{top:a,right:o,bottom:d,left:s}}}setTransitionEl(e){e&&(this.transitionEl=e,this.setupInteractions(),this.handlePopover())}handleInternalPanelScroll(e){e.target===this.panelRef.value&&(e.stopPropagation(),this.calciteDialogScroll.emit())}handleInternalPanelCloseClick(e){e.target===this.panelRef.value&&(e.preventDefault(),e.stopPropagation(),this.open=!1)}handlePanelKeyDown(e){this.escapeDisabled&&e.key==="Escape"&&!e.defaultPrevented&&e.preventDefault()}handleOutsideClose(){this.outsideCloseDisabled||(this.open=!1)}handleMutationObserver(){this.focusTrap.updateContainerElements()}render(){let{assistiveText:e,description:t,heading:i,opened:n,icon:a,iconFlipRtl:o}=this;return y`<div .ariaDescription=${t} .ariaLabel=${i} .ariaModal=${this.modal} class=${b({[g.container]:!0,[g.containerOpen]:n,[g.containerEmbedded]:this.embedded})} .popover=${this.embedded?null:"manual"} role=dialog ${w(this.popoverRef)}>${this.modal?y`<calcite-scrim class=${b(g.scrim)} @click=${this.handleOutsideClose}></calcite-scrim>`:null}<div class=${b({[g.dialog]:!0,[R("width",this.width,this.widthScale)]:!!(this.width||this.widthScale)})} @keydown=${this.handleKeyDown} ${w(this.setTransitionEl)}>${e?E("assistive-text",y`<div aria-live=polite class=${b(g.assistiveText)}>${e}</div>`):null}<slot name=${c.customContent}><calcite-panel class=${b(g.panel)} .closable=${!this.closeDisabled} .description=${t} .heading=${i} .headingLevel=${this.headingLevel} .hidden=${!this.opened} .icon=${a} .iconFlipRtl=${o} .loading=${this.loading} .menuOpen=${this.menuOpen} .messageOverrides=${this.messageOverrides} @keydown=${this.handlePanelKeyDown} @calcitePanelClose=${this.handleInternalPanelCloseClick} @calcitePanelScroll=${this.handleInternalPanelScroll} .overlayPositioning=${this.overlayPositioning} .scale=${this.scale} ${w(this.panelRef)}><slot name=${c.actionBar} slot=${r.actionBar}></slot><slot name=${c.alerts} slot=${r.alerts}></slot><slot name=${c.headerActionsStart} slot=${r.headerActionsStart}></slot><slot name=${c.headerActionsEnd} slot=${r.headerActionsEnd}></slot><slot name=${c.headerContent} slot=${r.headerContent}></slot><slot name=${c.headerMenuActions} slot=${r.headerMenuActions}></slot><slot name=${c.fab} slot=${r.fab}></slot><slot name=${c.contentTop} slot=${r.contentTop}></slot><slot name=${c.contentBottom} slot=${r.contentBottom}></slot><slot name=${c.footerStart} slot=${r.footerStart}></slot><slot name=${c.footer} slot=${r.footer}></slot><slot name=${c.footerEnd} slot=${r.footerEnd}></slot><slot></slot></calcite-panel></slot></div></div>`}};T("calcite-dialog",$);export{$ as Dialog};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*! All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
|
3
|
-
v5.0.0-next.
|
|
4
|
-
import{a as s}from"./
|
|
3
|
+
v5.0.0-next.6 */
|
|
4
|
+
import{a as s}from"./CZF6KYOX.js";import{D as o,E as n,P as r,g as c,h as i,o as a}from"./2IIGKMQ6.js";var l={accordion:"accordion",transparent:"accordion--transparent"},d=c`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host{position:relative;display:block;max-inline-size:100%;line-height:1.5rem}.accordion{border-width:1px;border-block-end-width:0px;border-style:solid;border-color:var(--calcite-accordion-border-color, var(--calcite-color-border-2));background-color:var(--calcite-accordion-background-color, var(--calcite-color-foreground-1))}.accordion--transparent{--calcite-accordion-border-color: transparent;border-color:var(--calcite-color-transparent);background-color:var(--calcite-color-transparent)}:host([scale=s]){--calcite-internal-accordion-item-spacing-unit: .25rem;--calcite-internal-accordion-icon-margin: .5rem;--calcite-internal-accordion-item-padding: var(--calcite-internal-accordion-item-spacing-unit) .5rem;font-size:var(--calcite-font-size--2);line-height:1rem}:host([scale=m]){--calcite-internal-accordion-item-spacing-unit: .5rem;--calcite-internal-accordion-icon-margin: .75rem;--calcite-internal-accordion-item-padding: var(--calcite-internal-accordion-item-spacing-unit) .75rem;font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]){--calcite-internal-accordion-item-spacing-unit: .75rem;--calcite-internal-accordion-icon-margin: 1rem;--calcite-internal-accordion-item-padding: var(--calcite-internal-accordion-item-spacing-unit) 1rem;font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([hidden]){display:none}[hidden]{display:none}`,t=class extends o{constructor(){super(),this.mutationObserver=s("mutation",()=>this.updateAccordionItems()),this.appearance="solid",this.iconPosition="end",this.iconType="chevron",this.scale="m",this.selectionMode="multiple",this.calciteInternalAccordionChange=a({cancelable:!1}),this.listen("calciteInternalAccordionItemSelect",this.updateActiveItemOnChange)}static{this.properties={appearance:[3,{},{reflect:!0}],iconPosition:[3,{},{reflect:!0}],iconType:[3,{},{reflect:!0}],scale:[3,{},{reflect:!0}],selectionMode:[3,{},{reflect:!0}]}}static{this.styles=d}connectedCallback(){super.connectedCallback(),this.mutationObserver?.observe(this.el,{childList:!0}),this.updateAccordionItems()}willUpdate(e){(e.has("appearance")&&(this.hasUpdated||this.appearance!=="solid")||e.has("iconPosition")&&(this.hasUpdated||this.iconPosition!=="end")||e.has("iconType")&&(this.hasUpdated||this.iconType!=="chevron")||e.has("scale")&&(this.hasUpdated||this.scale!=="m")||e.has("selectionMode")&&(this.hasUpdated||this.selectionMode!=="multiple"))&&this.updateAccordionItems()}disconnectedCallback(){super.disconnectedCallback(),this.mutationObserver?.disconnect()}updateActiveItemOnChange(e){this.calciteInternalAccordionChange.emit({requestedAccordionItem:e.detail.requestedAccordionItem}),e.stopPropagation()}updateAccordionItems(){this.el.querySelectorAll("calcite-accordion-item").forEach(e=>{e.appearance=this.appearance,e.iconPosition=this.iconPosition,e.iconType=this.iconType,e.scale=this.scale}),document.dispatchEvent(new CustomEvent("calciteInternalAccordionItemsSync"))}render(){let e=this.appearance==="transparent";return i`<div class=${n({[l.transparent]:e,[l.accordion]:!e})}><slot></slot></div>`}};r("calcite-accordion",t);export{t as Accordion};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*! All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
|
3
|
-
v5.0.0-next.
|
|
4
|
-
import{a as F}from"./KRHM7ACI.js";import{c as z,d as C,e as A}from"./ZVWKN3G7.js";import{c as w,e as I,h as R}from"./Y3HXK6MO.js";import{a as y,b as B}from"./NSBK36H4.js";import{a as d}from"./NU57UAAO.js";import{a as x}from"./WOTQIMPZ.js";import"./B5JXPZDV.js";import"./3YZG7MA3.js";import"./CIU4VM7X.js";import{e as k}from"./5IPJANUU.js";import"./ZLR2B6GQ.js";import{B as p,C as m,D as v,E as l,P as g,g as u,h as b,l as f,o as c}from"./AUIOWPFN.js";var L={container:"container",radio:"radio"},T=u`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host([disabled]){cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{display:block;cursor:pointer}:host .container{position:relative;outline:2px solid transparent;outline-offset:2px;display:flex}:host .radio{cursor:pointer;transition-property:background-color,block-size,border-color,box-shadow,color,inset-block-end,inset-block-start,inset-inline-end,inset-inline-start,inset-size,opacity,outline-color,transform;transition-duration:var(--calcite-animation-timing);transition-timing-function:ease-in-out;outline-color:transparent;border-radius:var(--calcite-radio-button-corner-radius, var(--calcite-corner-radius-pill));background-color:var(--calcite-radio-button-background-color, var(--calcite-color-foreground-1));box-shadow:inset 0 0 0 var(--calcite-border-width-sm) var(--calcite-radio-button-border-color, var(--calcite-color-border-input))}:host([hovered]) .radio,:host(:not([checked])[focused]:not([disabled])) .radio{box-shadow:inset 0 0 0 var(--calcite-border-width-md) var(--calcite-radio-button-border-color, var(--calcite-color-brand-hover))}:host([hovered]) .radio:active,:host(:not([checked])[focused]:not([disabled])) .radio:active{box-shadow:inset 0 0 0 var(--calcite-border-width-md) var(--calcite-color-brand-press)}:host([focused]) .radio{outline:var(--calcite-border-width-md) solid var(--calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)));outline:var(--calcite-border-width-md) solid var(--calcite-internal-color-focus);outline-offset:calc(var(--calcite-spacing-base) * calc(1 - (2*clamp(0,var(--calcite-offset-invert-focus),1))))}:host([disabled]) .radio{cursor:default;opacity:var(--calcite-opacity-disabled)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}:host([hovered][disabled]) .radio{box-shadow:inset 0 0 0 var(--calcite-border-width-sm) var(--calcite-radio-button-border-color, var(--calcite-color-border-input))}:host([scale=s]){--calcite-internal-radio-size: var( --calcite-radio-button-size, var(--calcite-radio-size, var(--calcite-size-fixed-md)) )}:host([scale=m]){--calcite-internal-radio-size: var( --calcite-radio-button-size, var(--calcite-radio-size, var(--calcite-size-fixed-md-plus)) )}:host([scale=l]){--calcite-internal-radio-size: var( --calcite-radio-button-size, var(--calcite-radio-size, var(--calcite-size-fixed-lg)) )}.radio{block-size:var(--calcite-internal-radio-size);inline-size:var(--calcite-internal-radio-size);size:var(--calcite-internal-radio-size)}:host([scale=s][checked]) .radio,:host([hovered][scale=s][checked][disabled]) .radio{box-shadow:inset 0 0 0 var(--calcite-border-width-lg) var(--calcite-radio-button-border-color, var(--calcite-color-brand))}:host([scale=s][focused][checked]:not([disabled])) .radio{box-shadow:inset 0 0 0 var(--calcite-border-width-lg) var(--calcite-radio-button-border-color, var(--calcite-color-brand)),0 0 0 2px var(--calcite-radio-button-background-color, var(--calcite-color-foreground-1))}:host([scale=m][checked]) .radio,:host([hovered][scale=m][checked][disabled]) .radio{box-shadow:inset 0 0 0 5px var(--calcite-radio-button-border-color, var(--calcite-color-brand))}:host([scale=m][focused][checked]:not([disabled])) .radio{box-shadow:inset 0 0 0 5px var(--calcite-radio-button-border-color, var(--calcite-color-brand)),0 0 0 2px var(--calcite-radio-button-background-color, var(--calcite-color-foreground-1))}:host([scale=l][checked]) .radio,:host([hovered][scale=l][checked][disabled]) .radio{box-shadow:inset 0 0 0 6px var(--calcite-radio-button-border-color, var(--calcite-color-brand))}:host([scale=l][focused][checked]:not([disabled])) .radio{box-shadow:inset 0 0 0 6px var(--calcite-radio-button-border-color, var(--calcite-color-brand)),0 0 0 2px var(--calcite-radio-button-background-color, var(--calcite-color-foreground-1))}@media(forced-colors:active){:host([checked]) .radio:after,:host([checked][disabled]) .radio:after{content:"";inline-size:var(--calcite-internal-radio-size);block-size:var(--calcite-internal-radio-size);background-color:CanvasText;display:block}}.internal-label-alignment--center{align-items:center}.internal-label-alignment--end{align-items:end}.internal-label--container{display:flex;justify-content:space-between;color:var(--calcite-color-text-1)}.internal-label-required--indicator{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-color-status-danger);padding-inline:var(--calcite-spacing-base)}.internal-label-required--indicator:hover{cursor:help}.internal-label--text{line-height:1}:host([scale=s]) .internal-label-spacing--bottom{margin-block-end:var(--calcite-spacing-xxs)}:host([scale=s]) .internal-label-spacing-inline--end{margin-inline-end:var(--calcite-spacing-sm)}:host([scale=s]) .internal-label-spacing-inline--start{margin-inline-start:var(--calcite-spacing-sm)}:host([scale=s]) .internal-label--text{font-size:var(--calcite-font-size--2)}:host([scale=m]) .internal-label-spacing--bottom{margin-block-end:var(--calcite-spacing-sm)}:host([scale=m]) .internal-label-spacing-inline--end{margin-inline-end:var(--calcite-spacing-sm)}:host([scale=m]) .internal-label-spacing-inline--start{margin-inline-start:var(--calcite-spacing-sm)}:host([scale=m]) .internal-label--text{font-size:var(--calcite-font-size--1)}:host([scale=l]) .internal-label-spacing--bottom{margin-block-end:var(--calcite-spacing-sm)}:host([scale=l]) .internal-label-spacing-inline--end{margin-inline-end:var(--calcite-spacing-md)}:host([scale=l]) .internal-label-spacing-inline--start{margin-inline-start:var(--calcite-spacing-md)}:host([scale=l]) .internal-label--text{font-size:var(--calcite-font-size-0)}::slotted(input[slot=hidden-form-input]){margin:0!important;opacity:0!important;outline:none!important;padding:0!important;position:absolute!important;inset:0!important;transform:none!important;-webkit-appearance:none!important;z-index:-1!important}:host([hidden]){display:none}[hidden]{display:none}`,h=class extends v{constructor(){super(),this.containerRef=p(),this.focusSetter=x()(this),this.checked=!1,this.disabled=!1,this.focused=!1,this.hovered=!1,this.required=!1,this.scale="m",this.calciteInternalRadioButtonBlur=c({cancelable:!1}),this.calciteInternalRadioButtonCheckedChange=c({cancelable:!1}),this.calciteInternalRadioButtonFocus=c({cancelable:!1}),this.calciteRadioButtonChange=c({cancelable:!1}),this.listen("pointerenter",this.pointerEnterHandler),this.listen("pointerleave",this.pointerLeaveHandler),this.listen("click",this.clickHandler),this.listen("keydown",this.handleKeyDown)}static{this.properties={checked:[7,{},{reflect:!0,type:Boolean}],disabled:[7,{},{reflect:!0,type:Boolean}],focused:[7,{},{reflect:!0,type:Boolean}],form:[3,{},{reflect:!0}],hovered:[7,{},{reflect:!0,type:Boolean}],label:1,labelText:1,name:[3,{},{reflect:!0}],required:[7,{},{reflect:!0,type:Boolean}],scale:[3,{},{reflect:!0}],value:1}}static{this.styles=T}async emitCheckedChange(){this.calciteInternalRadioButtonCheckedChange.emit()}async setFocus(e){return this.focusSetter(()=>this.containerRef.value,e)}connectedCallback(){this.rootNode=this.el.getRootNode(),this.name&&this.checkLastRadioButton(),z(this),w(this),this.updateTabIndexOfOtherRadioButtonsInGroup(),super.connectedCallback()}willUpdate(e){this.hasUpdated&&e.has("checked")&&this.checkedChanged(this.checked),e.has("disabled")&&(this.hasUpdated||this.disabled!==!1)&&this.updateTabIndexOfOtherRadioButtonsInGroup(),e.has("name")&&this.checkLastRadioButton()}updated(){y(this)}loaded(){this.focused&&!this.disabled&&this.setFocus()}disconnectedCallback(){super.disconnectedCallback(),C(this),I(this),this.updateTabIndexOfOtherRadioButtonsInGroup()}checkedChanged(e){e&&this.uncheckOtherRadioButtonsInGroup(),this.calciteInternalRadioButtonCheckedChange.emit()}syncHiddenFormInput(e){e.type="radio"}selectItem(e,i){e[i].click()}queryButtons(){return Array.from(this.rootNode.querySelectorAll("calcite-radio-button:not([hidden])")).filter(e=>e.name===this.name)}isFocusable(){let e=this.queryButtons(),i=e.find(a=>!a.disabled),t=e.find(a=>a.checked);return i===this.el&&!t}check(){this.disabled||(this.focused=!0,this.setFocus(),!this.checked&&(this.uncheckAllRadioButtonsInGroup(),this.checked=!0,this.calciteRadioButtonChange.emit()))}clickHandler(){this.disabled||this.check()}onLabelClick(e){if(this.disabled||this.el.hidden)return;let i=e.currentTarget,t=i.for?this.rootNode.querySelector(`calcite-radio-button[id="${i.for}"]`):i.querySelector(`calcite-radio-button[name="${this.name}"]`);t&&(t.focused=!0,this.setFocus(),!t.checked&&(this.uncheckOtherRadioButtonsInGroup(),t.checked=!0,this.calciteRadioButtonChange.emit()))}checkLastRadioButton(){let i=this.queryButtons().filter(t=>t.checked);if(i?.length>1){let t=i[i.length-1];i.filter(a=>a!==t).forEach(a=>{a.checked=!1,a.emitCheckedChange()})}}uncheckAllRadioButtonsInGroup(){this.queryButtons().forEach(i=>{i.checked&&(i.checked=!1,i.focused=!1)})}uncheckOtherRadioButtonsInGroup(){this.queryButtons().filter(t=>t!==this.el).forEach(t=>{t.checked&&(t.checked=!1,t.focused=!1)})}updateTabIndexOfOtherRadioButtonsInGroup(){this.queryButtons().filter(t=>t!==this.el&&!t.disabled).forEach(t=>{t.manager?.component.requestUpdate()})}getTabIndex(){if(!this.disabled)return this.checked||this.isFocusable()?0:-1}pointerEnterHandler(){this.disabled||(this.hovered=!0)}pointerLeaveHandler(){this.disabled||(this.hovered=!1)}handleKeyDown(e){let i=["ArrowLeft","ArrowUp","ArrowRight","ArrowDown"," "],{key:t}=e,{el:a}=this;if(i.indexOf(t)===-1)return;if(t===" "){this.check(),e.preventDefault();return}let r=t;k(a)==="rtl"&&(t==="ArrowRight"&&(r="ArrowLeft"),t==="ArrowLeft"&&(r="ArrowRight"));let o=Array.from(this.rootNode.querySelectorAll("calcite-radio-button:not([hidden])")).filter(s=>s.name===this.name),n=0;switch(o.some((s,q)=>{if(s.checked)return n=q,!0}),r){case"ArrowLeft":case"ArrowUp":e.preventDefault(),this.selectItem(o,this.getNextNonDisabledIndex(o,n,"left"));return;case"ArrowRight":case"ArrowDown":e.preventDefault(),this.selectItem(o,this.getNextNonDisabledIndex(o,n,"right"));return;default:return}}getNextNonDisabledIndex(e,i,t){let a=e.length,r=t==="left"?-1:1,o=d(i+r,a);for(;e[o].disabled;)o=d(o+r,a);return o}onContainerBlur(){this.focused=!1,this.calciteInternalRadioButtonBlur.emit()}onContainerFocus(){this.disabled||(this.focused=!0,this.calciteInternalRadioButtonFocus.emit())}render(){let e=this.getTabIndex();return B({disabled:this.disabled,children:b`<div .ariaChecked=${this.checked} .ariaLabel=${A(this)} class=${l(L.container)} @blur=${this.onContainerBlur} @focus=${this.onContainerFocus} role=radio tabindex=${e??f} ${m(this.containerRef)}><div class=${l(L.radio)}></div>${this.labelText&&F({labelText:this.labelText,spacingInlineStart:!0})||""}</div>${R({component:this})}`})}};g("calcite-radio-button",h);export{h as RadioButton};
|
|
3
|
+
v5.0.0-next.6 */
|
|
4
|
+
import{a as F}from"./6YVXONLB.js";import{c as z,d as C,e as A}from"./O72KETNZ.js";import{c as w,e as I,h as R}from"./OBY2JHHI.js";import{a as y,b as B}from"./UQ4HIO7J.js";import{a as d}from"./VS3YLYMZ.js";import{a as x}from"./SXK4ATVN.js";import"./6PMY6MUE.js";import"./PCGNN5RO.js";import"./H3GTITDX.js";import{e as k}from"./7DQ4G2FS.js";import"./44XNJNTA.js";import{B as p,C as m,D as v,E as l,P as g,g as u,h as b,l as f,o as c}from"./2IIGKMQ6.js";var L={container:"container",radio:"radio"},T=u`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host([disabled]){cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{display:block;cursor:pointer}:host .container{position:relative;outline:2px solid transparent;outline-offset:2px;display:flex}:host .radio{cursor:pointer;transition-property:background-color,block-size,border-color,box-shadow,color,inset-block-end,inset-block-start,inset-inline-end,inset-inline-start,inset-size,opacity,outline-color,transform;transition-duration:var(--calcite-animation-timing);transition-timing-function:ease-in-out;outline-color:transparent;border-radius:var(--calcite-radio-button-corner-radius, var(--calcite-corner-radius-pill));background-color:var(--calcite-radio-button-background-color, var(--calcite-color-foreground-1));box-shadow:inset 0 0 0 var(--calcite-border-width-sm) var(--calcite-radio-button-border-color, var(--calcite-color-border-input))}:host([hovered]) .radio,:host(:not([checked])[focused]:not([disabled])) .radio{box-shadow:inset 0 0 0 var(--calcite-border-width-md) var(--calcite-radio-button-border-color, var(--calcite-color-brand-hover))}:host([hovered]) .radio:active,:host(:not([checked])[focused]:not([disabled])) .radio:active{box-shadow:inset 0 0 0 var(--calcite-border-width-md) var(--calcite-color-brand-press)}:host([focused]) .radio{outline:var(--calcite-border-width-md) solid var(--calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)));outline:var(--calcite-border-width-md) solid var(--calcite-internal-color-focus);outline-offset:calc(var(--calcite-spacing-base) * calc(1 - (2*clamp(0,var(--calcite-offset-invert-focus),1))))}:host([disabled]) .radio{cursor:default;opacity:var(--calcite-opacity-disabled)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}:host([hovered][disabled]) .radio{box-shadow:inset 0 0 0 var(--calcite-border-width-sm) var(--calcite-radio-button-border-color, var(--calcite-color-border-input))}:host([scale=s]){--calcite-internal-radio-size: var( --calcite-radio-button-size, var(--calcite-radio-size, var(--calcite-size-fixed-md)) )}:host([scale=m]){--calcite-internal-radio-size: var( --calcite-radio-button-size, var(--calcite-radio-size, var(--calcite-size-fixed-md-plus)) )}:host([scale=l]){--calcite-internal-radio-size: var( --calcite-radio-button-size, var(--calcite-radio-size, var(--calcite-size-fixed-lg)) )}.radio{block-size:var(--calcite-internal-radio-size);inline-size:var(--calcite-internal-radio-size);size:var(--calcite-internal-radio-size)}:host([scale=s][checked]) .radio,:host([hovered][scale=s][checked][disabled]) .radio{box-shadow:inset 0 0 0 var(--calcite-border-width-lg) var(--calcite-radio-button-border-color, var(--calcite-color-brand))}:host([scale=s][focused][checked]:not([disabled])) .radio{box-shadow:inset 0 0 0 var(--calcite-border-width-lg) var(--calcite-radio-button-border-color, var(--calcite-color-brand)),0 0 0 2px var(--calcite-radio-button-background-color, var(--calcite-color-foreground-1))}:host([scale=m][checked]) .radio,:host([hovered][scale=m][checked][disabled]) .radio{box-shadow:inset 0 0 0 5px var(--calcite-radio-button-border-color, var(--calcite-color-brand))}:host([scale=m][focused][checked]:not([disabled])) .radio{box-shadow:inset 0 0 0 5px var(--calcite-radio-button-border-color, var(--calcite-color-brand)),0 0 0 2px var(--calcite-radio-button-background-color, var(--calcite-color-foreground-1))}:host([scale=l][checked]) .radio,:host([hovered][scale=l][checked][disabled]) .radio{box-shadow:inset 0 0 0 6px var(--calcite-radio-button-border-color, var(--calcite-color-brand))}:host([scale=l][focused][checked]:not([disabled])) .radio{box-shadow:inset 0 0 0 6px var(--calcite-radio-button-border-color, var(--calcite-color-brand)),0 0 0 2px var(--calcite-radio-button-background-color, var(--calcite-color-foreground-1))}@media(forced-colors:active){:host([checked]) .radio:after,:host([checked][disabled]) .radio:after{content:"";inline-size:var(--calcite-internal-radio-size);block-size:var(--calcite-internal-radio-size);background-color:CanvasText;display:block}}.internal-label-alignment--center{align-items:center}.internal-label-alignment--end{align-items:end}.internal-label--container{display:flex;justify-content:space-between;color:var(--calcite-color-text-1)}.internal-label-required--indicator{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-color-status-danger);padding-inline:var(--calcite-spacing-base)}.internal-label-required--indicator:hover{cursor:help}.internal-label--text{line-height:1}:host([scale=s]) .internal-label-spacing--bottom{margin-block-end:var(--calcite-spacing-xxs)}:host([scale=s]) .internal-label-spacing-inline--end{margin-inline-end:var(--calcite-spacing-sm)}:host([scale=s]) .internal-label-spacing-inline--start{margin-inline-start:var(--calcite-spacing-sm)}:host([scale=s]) .internal-label--text{font-size:var(--calcite-font-size--2)}:host([scale=m]) .internal-label-spacing--bottom{margin-block-end:var(--calcite-spacing-sm)}:host([scale=m]) .internal-label-spacing-inline--end{margin-inline-end:var(--calcite-spacing-sm)}:host([scale=m]) .internal-label-spacing-inline--start{margin-inline-start:var(--calcite-spacing-sm)}:host([scale=m]) .internal-label--text{font-size:var(--calcite-font-size--1)}:host([scale=l]) .internal-label-spacing--bottom{margin-block-end:var(--calcite-spacing-sm)}:host([scale=l]) .internal-label-spacing-inline--end{margin-inline-end:var(--calcite-spacing-md)}:host([scale=l]) .internal-label-spacing-inline--start{margin-inline-start:var(--calcite-spacing-md)}:host([scale=l]) .internal-label--text{font-size:var(--calcite-font-size-0)}::slotted(input[slot=hidden-form-input]){margin:0!important;opacity:0!important;outline:none!important;padding:0!important;position:absolute!important;inset:0!important;transform:none!important;-webkit-appearance:none!important;z-index:-1!important}:host([hidden]){display:none}[hidden]{display:none}`,h=class extends v{constructor(){super(),this.containerRef=p(),this.focusSetter=x()(this),this.checked=!1,this.disabled=!1,this.focused=!1,this.hovered=!1,this.required=!1,this.scale="m",this.calciteInternalRadioButtonBlur=c({cancelable:!1}),this.calciteInternalRadioButtonCheckedChange=c({cancelable:!1}),this.calciteInternalRadioButtonFocus=c({cancelable:!1}),this.calciteRadioButtonChange=c({cancelable:!1}),this.listen("pointerenter",this.pointerEnterHandler),this.listen("pointerleave",this.pointerLeaveHandler),this.listen("click",this.clickHandler),this.listen("keydown",this.handleKeyDown)}static{this.properties={checked:[7,{},{reflect:!0,type:Boolean}],disabled:[7,{},{reflect:!0,type:Boolean}],focused:[7,{},{reflect:!0,type:Boolean}],form:[3,{},{reflect:!0}],hovered:[7,{},{reflect:!0,type:Boolean}],label:1,labelText:1,name:[3,{},{reflect:!0}],required:[7,{},{reflect:!0,type:Boolean}],scale:[3,{},{reflect:!0}],value:1}}static{this.styles=T}async emitCheckedChange(){this.calciteInternalRadioButtonCheckedChange.emit()}async setFocus(e){return this.focusSetter(()=>this.containerRef.value,e)}connectedCallback(){this.rootNode=this.el.getRootNode(),this.name&&this.checkLastRadioButton(),z(this),w(this),this.updateTabIndexOfOtherRadioButtonsInGroup(),super.connectedCallback()}willUpdate(e){this.hasUpdated&&e.has("checked")&&this.checkedChanged(this.checked),e.has("disabled")&&(this.hasUpdated||this.disabled!==!1)&&this.updateTabIndexOfOtherRadioButtonsInGroup(),e.has("name")&&this.checkLastRadioButton()}updated(){y(this)}loaded(){this.focused&&!this.disabled&&this.setFocus()}disconnectedCallback(){super.disconnectedCallback(),C(this),I(this),this.updateTabIndexOfOtherRadioButtonsInGroup()}checkedChanged(e){e&&this.uncheckOtherRadioButtonsInGroup(),this.calciteInternalRadioButtonCheckedChange.emit()}syncHiddenFormInput(e){e.type="radio"}selectItem(e,i){e[i].click()}queryButtons(){return Array.from(this.rootNode.querySelectorAll("calcite-radio-button:not([hidden])")).filter(e=>e.name===this.name)}isFocusable(){let e=this.queryButtons(),i=e.find(a=>!a.disabled),t=e.find(a=>a.checked);return i===this.el&&!t}check(){this.disabled||(this.focused=!0,this.setFocus(),!this.checked&&(this.uncheckAllRadioButtonsInGroup(),this.checked=!0,this.calciteRadioButtonChange.emit()))}clickHandler(){this.disabled||this.check()}onLabelClick(e){if(this.disabled||this.el.hidden)return;let i=e.currentTarget,t=i.for?this.rootNode.querySelector(`calcite-radio-button[id="${i.for}"]`):i.querySelector(`calcite-radio-button[name="${this.name}"]`);t&&(t.focused=!0,this.setFocus(),!t.checked&&(this.uncheckOtherRadioButtonsInGroup(),t.checked=!0,this.calciteRadioButtonChange.emit()))}checkLastRadioButton(){let i=this.queryButtons().filter(t=>t.checked);if(i?.length>1){let t=i[i.length-1];i.filter(a=>a!==t).forEach(a=>{a.checked=!1,a.emitCheckedChange()})}}uncheckAllRadioButtonsInGroup(){this.queryButtons().forEach(i=>{i.checked&&(i.checked=!1,i.focused=!1)})}uncheckOtherRadioButtonsInGroup(){this.queryButtons().filter(t=>t!==this.el).forEach(t=>{t.checked&&(t.checked=!1,t.focused=!1)})}updateTabIndexOfOtherRadioButtonsInGroup(){this.queryButtons().filter(t=>t!==this.el&&!t.disabled).forEach(t=>{t.manager?.component.requestUpdate()})}getTabIndex(){if(!this.disabled)return this.checked||this.isFocusable()?0:-1}pointerEnterHandler(){this.disabled||(this.hovered=!0)}pointerLeaveHandler(){this.disabled||(this.hovered=!1)}handleKeyDown(e){let i=["ArrowLeft","ArrowUp","ArrowRight","ArrowDown"," "],{key:t}=e,{el:a}=this;if(i.indexOf(t)===-1)return;if(t===" "){this.check(),e.preventDefault();return}let r=t;k(a)==="rtl"&&(t==="ArrowRight"&&(r="ArrowLeft"),t==="ArrowLeft"&&(r="ArrowRight"));let o=Array.from(this.rootNode.querySelectorAll("calcite-radio-button:not([hidden])")).filter(s=>s.name===this.name),n=0;switch(o.some((s,q)=>{if(s.checked)return n=q,!0}),r){case"ArrowLeft":case"ArrowUp":e.preventDefault(),this.selectItem(o,this.getNextNonDisabledIndex(o,n,"left"));return;case"ArrowRight":case"ArrowDown":e.preventDefault(),this.selectItem(o,this.getNextNonDisabledIndex(o,n,"right"));return;default:return}}getNextNonDisabledIndex(e,i,t){let a=e.length,r=t==="left"?-1:1,o=d(i+r,a);for(;e[o].disabled;)o=d(o+r,a);return o}onContainerBlur(){this.focused=!1,this.calciteInternalRadioButtonBlur.emit()}onContainerFocus(){this.disabled||(this.focused=!0,this.calciteInternalRadioButtonFocus.emit())}render(){let e=this.getTabIndex();return B({disabled:this.disabled,children:b`<div .ariaChecked=${this.checked} .ariaLabel=${A(this)} class=${l(L.container)} @blur=${this.onContainerBlur} @focus=${this.onContainerFocus} role=radio tabindex=${e??f} ${m(this.containerRef)}><div class=${l(L.radio)}></div>${this.labelText&&F({labelText:this.labelText,spacingInlineStart:!0})||""}</div>${R({component:this})}`})}};g("calcite-radio-button",h);export{h as RadioButton};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*! All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
|
3
|
-
v5.0.0-next.
|
|
4
|
-
import{c as p}from"./
|
|
3
|
+
v5.0.0-next.6 */
|
|
4
|
+
import{c as p}from"./7DQ4G2FS.js";import{a as h}from"./44XNJNTA.js";import{D as d,E as c,H as i,P as b,g as o,h as r}from"./2IIGKMQ6.js";var l={container:"container",content:"content",scale:t=>`scale-${t}`},u={tabTitleId:t=>`calcite-tab-title-${t}`},f=o`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host{display:none}:host,.container,.content{block-size:100%;inline-size:100%}:host([selected]),:host([selected]) .container{display:flex;flex-direction:column}.content{box-sizing:border-box;padding-block:var(--calcite-tab-content-space-y, var(--calcite-tab-content-block-padding, var(--calcite-internal-tab-content-space-y)))}.scale-s{--calcite-internal-tab-content-space-y: .25rem;font-size:var(--calcite-font-size-sm);line-height:1rem}.scale-m{--calcite-internal-tab-content-space-y: .5rem;font-size:var(--calcite-font-size);line-height:1rem}.scale-l{--calcite-internal-tab-content-space-y: .625rem;font-size:var(--calcite-font-size-md);line-height:1.25rem}.container{display:none;block-size:100%;inline-size:100%;overflow:auto;outline-color:transparent}.container:focus{outline:var(--calcite-border-width-md) solid var(--calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)));outline:var(--calcite-border-width-md) solid var(--calcite-internal-color-focus);outline-offset:calc(calc(-1 * var(--calcite-spacing-base)) * calc(1 - (2*clamp(0,var(--calcite-offset-invert-focus),1))))}:host([hidden]){display:none}[hidden]{display:none}`,n=class extends d{constructor(){super(),this.guid=u.tabTitleId(h()),this.scale="m",this.selected=!1,this.listenOn(document.body,"calciteInternalTabChange",this.internalTabChangeHandler)}static{this.properties={labeledBy:[16,{},{state:!0}],scale:1,selected:[7,{},{reflect:!0,type:Boolean}],tab:[3,{},{reflect:!0}]}}static{this.styles=f}async getTabIndex(){return Array.prototype.indexOf.call(p(this.el.parentElement.children).filter(e=>e.matches("calcite-tab")),this.el)}_updateAriaInfo(e=[],s=[]){this.labeledBy=s[e.indexOf(this.el.id)]||null}connectedCallback(){super.connectedCallback(),this.parentTabsEl=this.el.closest("calcite-tabs")}disconnectedCallback(){super.disconnectedCallback(),document.body?.dispatchEvent(new CustomEvent("calciteTabUnregister",{detail:this.el}))}internalTabChangeHandler(e){e.composedPath().find(a=>a.tagName==="CALCITE-TABS")===this.parentTabsEl&&(this.tab?this.selected=this.tab===e.detail.tab:this.getTabIndex().then(a=>{this.selected=a===e.detail.tab}),e.stopPropagation())}render(){let e=this.el.id||this.guid;return i(this.el,"aria-labelledby",this.labeledBy),i(this.el,"id",e),r`<div class=${c({[l.container]:!0,[l.scale(this.scale)]:!0})} role=tabpanel .tabIndex=${this.selected?0:-1}><section class=${c(l.content)}><slot></slot></section></div>`}};b("calcite-tab",n);export{n as Tab};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*! All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
|
3
|
-
v5.0.0-next.
|
|
4
|
-
import{a as T}from"./XRSYDXWZ.js";import{a as E,c as I,d as B,e as q,f as R,g as p,h as U}from"./5LAPR75M.js";import{a as z}from"./VQMSSO2U.js";import{a as F,b as A}from"./NSBK36H4.js";import"./W5OJOVZY.js";import{a as H}from"./S5CLKCGJ.js";import{a as b,b as v}from"./ALDDSDTX.js";import{a as $}from"./WOTQIMPZ.js";import"./B5JXPZDV.js";import"./3YZG7MA3.js";import"./CIU4VM7X.js";import{C as D,l as y,y as d}from"./5IPJANUU.js";import{a as P}from"./ZLR2B6GQ.js";import{C as f,D as O,E as u,P as C,g as S,h as k,l as c,o as n}from"./AUIOWPFN.js";var l=(r,e,t)=>(t.configurable=!0,t.enumerable=!0,Reflect.decorate&&typeof e!="object"&&Object.defineProperty(r,e,t),t);function L(r){return(e,t)=>{let{slot:i,selector:s}=r??{},o="slot"+(i?`[name=${i}]`:":not([name])");return l(e,t,{get(){let a=this.renderRoot?.querySelector(o),h=a?.assignedElements(r)??[];return s===void 0?h:h.filter((w=>w.matches(s)))}})}}var j={trigger:"trigger"},x={content:"content",wrapper:"wrapper",triggerContainer:"trigger-container"},G="calcite-dropdown",m={menuButton:r=>`${G}-${r}-menubutton`,menu:r=>`${G}-${r}-menu`},K=S`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host([disabled]){cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{display:inline-block}.wrapper{inline-size:max-content;display:none;max-inline-size:100vw;max-block-size:100vh;inset-block-start:0;left:0}@starting-style{.wrapper{opacity:0;inset-block-start:0;left:0}}.wrapper[popover]{padding:0;margin:0;border:none;background-color:transparent;overflow:visible;display:none}.wrapper:popover-open{display:block}.wrapper .calcite-floating-ui-anim{position:relative;transition-duration:var(--calcite-floating-ui-transition);transition-property:inset-block-start,left,opacity,display;transition-behavior:allow-discrete;opacity:0;box-shadow:0 0 16px #00000029;z-index:var(--calcite-z-index);border-radius:.25rem}.wrapper[data-placement^=bottom] .calcite-floating-ui-anim{inset-block-start:-5px}.wrapper[data-placement^=top] .calcite-floating-ui-anim{inset-block-start:5px}.wrapper[data-placement^=left] .calcite-floating-ui-anim{left:5px}.wrapper[data-placement^=right] .calcite-floating-ui-anim{left:-5px}.wrapper[data-placement] .calcite-floating-ui-anim--active{opacity:1;inset-block-start:0;left:0}@starting-style{.wrapper[data-placement] .calcite-floating-ui-anim--active{opacity:0}}.content{max-height:45vh;width:auto;overflow-y:auto;overflow-x:hidden;inline-size:var(--calcite-dropdown-width, var(--calcite-internal-dropdown-width));background-color:var(--calcite-dropdown-background-color, var(--calcite-color-foreground-1))}.trigger-container{position:relative;display:flex;height:100%;flex:1 1 auto;word-wrap:break-word;word-break:break-word}.width-s{--calcite-internal-dropdown-width: 12rem}.width-m{--calcite-internal-dropdown-width: 14rem}.width-l{--calcite-internal-dropdown-width: 16rem}@media(forced-colors:active){:host([open]) .wrapper{border:var(--calcite-border-width-sm) solid canvasText}}:host([hidden]){display:none}[hidden]{display:none}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}`,M=Object.defineProperty,N=(r,e,t,i)=>{for(var s=void 0,o=r.length-1,a;o>=0;o--)(a=r[o])&&(s=a(e,t,s)||s);return s&&M(e,t,s),s},g=class extends O{constructor(){super(),this.focusLastDropdownItem=!1,this.groups=[],this.guid=P(),this.items=[],this.mutationObserver=b("mutation",()=>this.updateItems()),this.transitionProp="opacity",this.resizeObserver=b("resize",e=>this.resizeObserverCallback(e)),this.focusSetter=$()(this),this.closeOnSelectDisabled=!1,this.disabled=!1,this.maxItems=0,this.offsetDistance=0,this.offsetSkidding=0,this.open=!1,this.overlayPositioning="absolute",this.placement=E,this.scale="m",this.selectedItems=[],this.type="click",this.calciteDropdownBeforeClose=n({cancelable:!1}),this.calciteDropdownBeforeOpen=n({cancelable:!1}),this.calciteDropdownClose=n({cancelable:!1}),this.calciteDropdownOpen=n({cancelable:!1}),this.calciteDropdownSelect=n({cancelable:!1}),this.listenOn(window,"click",this.closeCalciteDropdownOnClick),this.listen("calciteInternalDropdownCloseRequest",this.closeCalciteDropdownOnEvent),this.listenOn(window,"calciteDropdownOpen",this.closeCalciteDropdownOnOpenEvent),this.listen("pointerenter",this.pointerEnterHandler),this.listen("pointerleave",this.pointerLeaveHandler),this.listen("calciteInternalDropdownItemKeyEvent",this.calciteInternalDropdownItemKeyEvent),this.listen("calciteInternalDropdownItemSelect",this.handleItemSelect)}static{this.properties={closeOnSelectDisabled:[7,{},{reflect:!0,type:Boolean}],disabled:[7,{},{reflect:!0,type:Boolean}],flipPlacements:[0,{},{attribute:!1}],maxItems:[11,{},{reflect:!0,type:Number}],offsetDistance:[11,{},{type:Number,reflect:!0}],offsetSkidding:[11,{},{reflect:!0,type:Number}],open:[7,{},{reflect:!0,type:Boolean}],overlayPositioning:[3,{},{reflect:!0}],placement:[3,{},{reflect:!0}],scale:[3,{},{reflect:!0}],selectedItems:[0,{},{attribute:!1}],type:[3,{},{reflect:!0}],widthScale:[3,{},{reflect:!0}],width:[3,{},{reflect:!0}]}}static{this.shadowRootOptions={mode:"open",delegatesFocus:!0}}static{this.styles=K}async reposition(e=!1){let{filteredFlipPlacements:t,floatingEl:i,offsetDistance:s,offsetSkidding:o,overlayPositioning:a,placement:h,referenceEl:w}=this;return q(this,{floatingEl:i,referenceEl:w,offsetDistance:s,offsetSkidding:o,overlayPositioning:a,placement:h,flipPlacements:t,type:"menu"},e)}async setFocus(e){return this.focusSetter(()=>this.referenceEl,e)}connectedCallback(){super.connectedCallback(),this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0}),this.setFilteredPlacements(),this.updateItems(),p(this)}willUpdate(e){e.has("open")&&(this.hasUpdated||this.open!==!1)&&this.openHandler(),e.has("disabled")&&(this.hasUpdated||this.disabled!==!1)&&this.handleDisabledChange(this.disabled),e.has("flipPlacements")&&this.flipPlacementsHandler(),e.has("maxItems")&&this.hasUpdated&&this.setMaxScrollerHeight(),this.hasUpdated&&(e.has("offsetDistance")&&this.offsetDistance!==0||e.has("offsetSkidding")&&this.offsetSkidding!==0||e.has("overlayPositioning")&&this.overlayPositioning!=="absolute"||e.has("placement")&&this.placement!==E)&&this.reposition(!0),e.has("scale")&&(this.hasUpdated||this.scale!=="m")&&this.handlePropsChange()}updated(){F(this)}loaded(){this.updateSelectedItems(),p(this)}disconnectedCallback(){super.disconnectedCallback(),this.mutationObserver?.disconnect(),this.resizeObserver?.disconnect(),U(this)}async handlePopover(){await this.componentOnReady(),this.floatingEl&&(this.open?this.floatingEl.showPopover():this.floatingEl.hidePopover())}openHandler(){z(this),!this.disabled&&(this.reposition(!0),this.handlePopover())}handleDisabledChange(e){e||(this.open=!1)}flipPlacementsHandler(){this.setFilteredPlacements(),this.reposition(!0)}handlePropsChange(){this.updateItems(),this.updateGroupProps()}closeCalciteDropdownOnClick(e){this.disabled||!this.open||e.composedPath().includes(this.el)||this.closeCalciteDropdown(!1)}closeCalciteDropdownOnEvent(e){this.closeCalciteDropdown(),e.stopPropagation()}closeCalciteDropdownOnOpenEvent(e){e.composedPath().includes(this.el)||(this.open=!1)}pointerEnterHandler(){this.disabled||this.type!=="hover"||this.toggleDropdown()}pointerLeaveHandler(){this.disabled||this.type!=="hover"||this.closeCalciteDropdown()}getTraversableItems(){return this.items.filter(e=>!e.disabled&&!e.hidden)}calciteInternalDropdownItemKeyEvent(e){let{keyboardEvent:t}=e.detail,i=t.target,s=this.getTraversableItems();switch(t.key){case"Tab":this.open=!1,this.updateTabIndexOfItems(i);break;case"ArrowDown":d(s,i,"next");break;case"ArrowUp":d(s,i,"previous");break;case"Home":d(s,i,"first");break;case"End":d(s,i,"last");break}e.stopPropagation()}handleItemSelect(e){this.updateSelectedItems(),e.stopPropagation(),this.calciteDropdownSelect.emit(),this.closeOnSelectDisabled||this.closeCalciteDropdown()}setFilteredPlacements(){let{el:e,flipPlacements:t}=this;this.filteredFlipPlacements=t?B(t,e):null}updateItems(){this.items=this.groups.map(e=>Array.from(e?.querySelectorAll("calcite-dropdown-item"))).reduce((e,t)=>[...e,...t],[]),this.updateSelectedItems(),this.reposition(!0),this.items.forEach(e=>e.scale=this.scale)}updateGroups(e){let t=e.target.assignedElements({flatten:!0}).filter(i=>i?.matches("calcite-dropdown-group"));this.groups=t,this.updateItems(),this.updateGroupProps()}updateGroupProps(){this.groups.forEach((e,t)=>{e.scale=this.scale,e.position=t})}resizeObserverCallback(e){e.forEach(({target:t})=>{t===this.referenceEl?this.setDropdownWidth():t===this.scrollerEl&&this.setMaxScrollerHeight()})}setDropdownWidth(){let{referenceEl:e,scrollerEl:t}=this;!t||!e||(t.style.minWidth=`${e.clientWidth}px`)}setMaxScrollerHeight(){let{maxItems:e,items:t,scrollerEl:i}=this;if(!i)return;let s=t.length>=e&&e>0?this.getYDistanceFromScroller(t.at(e-1)):0;i.style.maxBlockSize=s>0?`${s}px`:"",this.reposition(!0)}setScrollerAndTransitionEl(e){v(this.resizeObserver,this.scrollerEl,e),this.scrollerEl=e,this.transitionEl=e}onBeforeOpen(){this.focusOnFirstActiveOrDefaultItem(),this.calciteDropdownBeforeOpen.emit()}onOpen(){this.calciteDropdownOpen.emit()}onBeforeClose(){this.calciteDropdownBeforeClose.emit()}onClose(){this.calciteDropdownClose.emit(),R(this)}setReferenceEl(e){v(this.resizeObserver,this.referenceEl,e),this.referenceEl=e,p(this)}setFloatingEl(e){this.floatingEl=e,p(this),this.handlePopover()}keyDownHandler(e){if(!e.composedPath().includes(this.referenceEl))return;let{defaultPrevented:t,key:i}=e;if(!t){if(i==="Escape"){this.closeCalciteDropdown(),e.preventDefault();return}if(this.open&&e.shiftKey&&i==="Tab"){this.closeCalciteDropdown(),e.preventDefault();return}H(i)?(this.toggleDropdown(),e.preventDefault()):(i==="ArrowDown"||i==="ArrowUp")&&(e.preventDefault(),this.focusLastDropdownItem=i==="ArrowUp",this.open=!0)}}updateSelectedItems(){this.selectedItems=this.items.filter(e=>e.selected)}getYDistanceFromScroller(e){let t=e.getBoundingClientRect();return e.offsetTop+t.height}closeCalciteDropdown(e=!0){this.open=!1,e&&y(this.triggerEls[0])}async focusOnFirstActiveOrDefaultItem(){let t=this.getTraversableItems().find(i=>i.selected)||(this.focusLastDropdownItem?this.items.at(-1):this.items[0]);this.focusLastDropdownItem=!1,t&&(await this.updateComplete,await D(),await D(),await y(t),t.scrollIntoView({block:"nearest"}))}toggleDropdown(){this.open=!this.open}updateTabIndexOfItems(e){this.items.forEach(t=>{t.tabIndex=e!==t?-1:0})}render(){let{open:e,guid:t}=this;return A({disabled:this.disabled,children:k`<div class=${u(x.triggerContainer)} id=${m.menuButton(t)??c} @click=${this.toggleDropdown} @keydown=${this.keyDownHandler} ${f(this.setReferenceEl)}><slot aria-controls=${m.menu(t)??c} .ariaExpanded=${e} aria-haspopup=menu name=${j.trigger}></slot></div><div .ariaHidden=${!e} class=${u({[x.wrapper]:!0,[T("width",this.width,this.widthScale)]:!!(this.width||this.widthScale)})} popover=manual ${f(this.setFloatingEl)}><div aria-labelledby=${m.menuButton(t)??c} class=${u({[x.content]:!0,[I.animation]:!0,[I.animationActive]:e})} id=${m.menu(t)??c} role=menu ${f(this.setScrollerAndTransitionEl)}><slot @slotchange=${this.updateGroups}></slot></div></div>`})}};N([L({slot:j.trigger})],g.prototype,"triggerEls");C("calcite-dropdown",g);export{g as Dropdown};
|
|
3
|
+
v5.0.0-next.6 */
|
|
4
|
+
import{a as T}from"./KDHLLH5G.js";import{a as E,c as I,d as B,e as q,f as R,g as p,h as U}from"./IJDY7EKO.js";import{a as z}from"./LFYXGVGK.js";import{a as F,b as A}from"./UQ4HIO7J.js";import"./MPYXWS5E.js";import{a as H}from"./OFO7DXMT.js";import{a as b,b as v}from"./CZF6KYOX.js";import{a as $}from"./SXK4ATVN.js";import"./6PMY6MUE.js";import"./PCGNN5RO.js";import"./H3GTITDX.js";import{C as D,l as y,y as d}from"./7DQ4G2FS.js";import{a as P}from"./44XNJNTA.js";import{C as f,D as O,E as u,P as C,g as S,h as k,l as c,o as n}from"./2IIGKMQ6.js";var l=(r,e,t)=>(t.configurable=!0,t.enumerable=!0,Reflect.decorate&&typeof e!="object"&&Object.defineProperty(r,e,t),t);function L(r){return(e,t)=>{let{slot:i,selector:s}=r??{},o="slot"+(i?`[name=${i}]`:":not([name])");return l(e,t,{get(){let a=this.renderRoot?.querySelector(o),h=a?.assignedElements(r)??[];return s===void 0?h:h.filter((w=>w.matches(s)))}})}}var j={trigger:"trigger"},x={content:"content",wrapper:"wrapper",triggerContainer:"trigger-container"},G="calcite-dropdown",m={menuButton:r=>`${G}-${r}-menubutton`,menu:r=>`${G}-${r}-menu`},K=S`:host{--calcite-internal-color-focus: var( --calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)) )}:host([disabled]){cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{display:inline-block}.wrapper{inline-size:max-content;display:none;max-inline-size:100vw;max-block-size:100vh;inset-block-start:0;left:0}@starting-style{.wrapper{opacity:0;inset-block-start:0;left:0}}.wrapper[popover]{padding:0;margin:0;border:none;background-color:transparent;overflow:visible;display:none}.wrapper:popover-open{display:block}.wrapper .calcite-floating-ui-anim{position:relative;transition-duration:var(--calcite-floating-ui-transition);transition-property:inset-block-start,left,opacity,display;transition-behavior:allow-discrete;opacity:0;box-shadow:0 0 16px #00000029;z-index:var(--calcite-z-index);border-radius:.25rem}.wrapper[data-placement^=bottom] .calcite-floating-ui-anim{inset-block-start:-5px}.wrapper[data-placement^=top] .calcite-floating-ui-anim{inset-block-start:5px}.wrapper[data-placement^=left] .calcite-floating-ui-anim{left:5px}.wrapper[data-placement^=right] .calcite-floating-ui-anim{left:-5px}.wrapper[data-placement] .calcite-floating-ui-anim--active{opacity:1;inset-block-start:0;left:0}@starting-style{.wrapper[data-placement] .calcite-floating-ui-anim--active{opacity:0}}.content{max-height:45vh;width:auto;overflow-y:auto;overflow-x:hidden;inline-size:var(--calcite-dropdown-width, var(--calcite-internal-dropdown-width));background-color:var(--calcite-dropdown-background-color, var(--calcite-color-foreground-1))}.trigger-container{position:relative;display:flex;height:100%;flex:1 1 auto;word-wrap:break-word;word-break:break-word}.width-s{--calcite-internal-dropdown-width: 12rem}.width-m{--calcite-internal-dropdown-width: 14rem}.width-l{--calcite-internal-dropdown-width: 16rem}@media(forced-colors:active){:host([open]) .wrapper{border:var(--calcite-border-width-sm) solid canvasText}}:host([hidden]){display:none}[hidden]{display:none}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}`,M=Object.defineProperty,N=(r,e,t,i)=>{for(var s=void 0,o=r.length-1,a;o>=0;o--)(a=r[o])&&(s=a(e,t,s)||s);return s&&M(e,t,s),s},g=class extends O{constructor(){super(),this.focusLastDropdownItem=!1,this.groups=[],this.guid=P(),this.items=[],this.mutationObserver=b("mutation",()=>this.updateItems()),this.transitionProp="opacity",this.resizeObserver=b("resize",e=>this.resizeObserverCallback(e)),this.focusSetter=$()(this),this.closeOnSelectDisabled=!1,this.disabled=!1,this.maxItems=0,this.offsetDistance=0,this.offsetSkidding=0,this.open=!1,this.overlayPositioning="absolute",this.placement=E,this.scale="m",this.selectedItems=[],this.type="click",this.calciteDropdownBeforeClose=n({cancelable:!1}),this.calciteDropdownBeforeOpen=n({cancelable:!1}),this.calciteDropdownClose=n({cancelable:!1}),this.calciteDropdownOpen=n({cancelable:!1}),this.calciteDropdownSelect=n({cancelable:!1}),this.listenOn(window,"click",this.closeCalciteDropdownOnClick),this.listen("calciteInternalDropdownCloseRequest",this.closeCalciteDropdownOnEvent),this.listenOn(window,"calciteDropdownOpen",this.closeCalciteDropdownOnOpenEvent),this.listen("pointerenter",this.pointerEnterHandler),this.listen("pointerleave",this.pointerLeaveHandler),this.listen("calciteInternalDropdownItemKeyEvent",this.calciteInternalDropdownItemKeyEvent),this.listen("calciteInternalDropdownItemSelect",this.handleItemSelect)}static{this.properties={closeOnSelectDisabled:[7,{},{reflect:!0,type:Boolean}],disabled:[7,{},{reflect:!0,type:Boolean}],flipPlacements:[0,{},{attribute:!1}],maxItems:[11,{},{reflect:!0,type:Number}],offsetDistance:[11,{},{type:Number,reflect:!0}],offsetSkidding:[11,{},{reflect:!0,type:Number}],open:[7,{},{reflect:!0,type:Boolean}],overlayPositioning:[3,{},{reflect:!0}],placement:[3,{},{reflect:!0}],scale:[3,{},{reflect:!0}],selectedItems:[0,{},{attribute:!1}],type:[3,{},{reflect:!0}],widthScale:[3,{},{reflect:!0}],width:[3,{},{reflect:!0}]}}static{this.shadowRootOptions={mode:"open",delegatesFocus:!0}}static{this.styles=K}async reposition(e=!1){let{filteredFlipPlacements:t,floatingEl:i,offsetDistance:s,offsetSkidding:o,overlayPositioning:a,placement:h,referenceEl:w}=this;return q(this,{floatingEl:i,referenceEl:w,offsetDistance:s,offsetSkidding:o,overlayPositioning:a,placement:h,flipPlacements:t,type:"menu"},e)}async setFocus(e){return this.focusSetter(()=>this.referenceEl,e)}connectedCallback(){super.connectedCallback(),this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0}),this.setFilteredPlacements(),this.updateItems(),p(this)}willUpdate(e){e.has("open")&&(this.hasUpdated||this.open!==!1)&&this.openHandler(),e.has("disabled")&&(this.hasUpdated||this.disabled!==!1)&&this.handleDisabledChange(this.disabled),e.has("flipPlacements")&&this.flipPlacementsHandler(),e.has("maxItems")&&this.hasUpdated&&this.setMaxScrollerHeight(),this.hasUpdated&&(e.has("offsetDistance")&&this.offsetDistance!==0||e.has("offsetSkidding")&&this.offsetSkidding!==0||e.has("overlayPositioning")&&this.overlayPositioning!=="absolute"||e.has("placement")&&this.placement!==E)&&this.reposition(!0),e.has("scale")&&(this.hasUpdated||this.scale!=="m")&&this.handlePropsChange()}updated(){F(this)}loaded(){this.updateSelectedItems(),p(this)}disconnectedCallback(){super.disconnectedCallback(),this.mutationObserver?.disconnect(),this.resizeObserver?.disconnect(),U(this)}async handlePopover(){await this.componentOnReady(),this.floatingEl&&(this.open?this.floatingEl.showPopover():this.floatingEl.hidePopover())}openHandler(){z(this),!this.disabled&&(this.reposition(!0),this.handlePopover())}handleDisabledChange(e){e||(this.open=!1)}flipPlacementsHandler(){this.setFilteredPlacements(),this.reposition(!0)}handlePropsChange(){this.updateItems(),this.updateGroupProps()}closeCalciteDropdownOnClick(e){this.disabled||!this.open||e.composedPath().includes(this.el)||this.closeCalciteDropdown(!1)}closeCalciteDropdownOnEvent(e){this.closeCalciteDropdown(),e.stopPropagation()}closeCalciteDropdownOnOpenEvent(e){e.composedPath().includes(this.el)||(this.open=!1)}pointerEnterHandler(){this.disabled||this.type!=="hover"||this.toggleDropdown()}pointerLeaveHandler(){this.disabled||this.type!=="hover"||this.closeCalciteDropdown()}getTraversableItems(){return this.items.filter(e=>!e.disabled&&!e.hidden)}calciteInternalDropdownItemKeyEvent(e){let{keyboardEvent:t}=e.detail,i=t.target,s=this.getTraversableItems();switch(t.key){case"Tab":this.open=!1,this.updateTabIndexOfItems(i);break;case"ArrowDown":d(s,i,"next");break;case"ArrowUp":d(s,i,"previous");break;case"Home":d(s,i,"first");break;case"End":d(s,i,"last");break}e.stopPropagation()}handleItemSelect(e){this.updateSelectedItems(),e.stopPropagation(),this.calciteDropdownSelect.emit(),this.closeOnSelectDisabled||this.closeCalciteDropdown()}setFilteredPlacements(){let{el:e,flipPlacements:t}=this;this.filteredFlipPlacements=t?B(t,e):null}updateItems(){this.items=this.groups.map(e=>Array.from(e?.querySelectorAll("calcite-dropdown-item"))).reduce((e,t)=>[...e,...t],[]),this.updateSelectedItems(),this.reposition(!0),this.items.forEach(e=>e.scale=this.scale)}updateGroups(e){let t=e.target.assignedElements({flatten:!0}).filter(i=>i?.matches("calcite-dropdown-group"));this.groups=t,this.updateItems(),this.updateGroupProps()}updateGroupProps(){this.groups.forEach((e,t)=>{e.scale=this.scale,e.position=t})}resizeObserverCallback(e){e.forEach(({target:t})=>{t===this.referenceEl?this.setDropdownWidth():t===this.scrollerEl&&this.setMaxScrollerHeight()})}setDropdownWidth(){let{referenceEl:e,scrollerEl:t}=this;!t||!e||(t.style.minWidth=`${e.clientWidth}px`)}setMaxScrollerHeight(){let{maxItems:e,items:t,scrollerEl:i}=this;if(!i)return;let s=t.length>=e&&e>0?this.getYDistanceFromScroller(t.at(e-1)):0;i.style.maxBlockSize=s>0?`${s}px`:"",this.reposition(!0)}setScrollerAndTransitionEl(e){v(this.resizeObserver,this.scrollerEl,e),this.scrollerEl=e,this.transitionEl=e}onBeforeOpen(){this.focusOnFirstActiveOrDefaultItem(),this.calciteDropdownBeforeOpen.emit()}onOpen(){this.calciteDropdownOpen.emit()}onBeforeClose(){this.calciteDropdownBeforeClose.emit()}onClose(){this.calciteDropdownClose.emit(),R(this)}setReferenceEl(e){v(this.resizeObserver,this.referenceEl,e),this.referenceEl=e,p(this)}setFloatingEl(e){this.floatingEl=e,p(this),this.handlePopover()}keyDownHandler(e){if(!e.composedPath().includes(this.referenceEl))return;let{defaultPrevented:t,key:i}=e;if(!t){if(i==="Escape"){this.closeCalciteDropdown(),e.preventDefault();return}if(this.open&&e.shiftKey&&i==="Tab"){this.closeCalciteDropdown(),e.preventDefault();return}H(i)?(this.toggleDropdown(),e.preventDefault()):(i==="ArrowDown"||i==="ArrowUp")&&(e.preventDefault(),this.focusLastDropdownItem=i==="ArrowUp",this.open=!0)}}updateSelectedItems(){this.selectedItems=this.items.filter(e=>e.selected)}getYDistanceFromScroller(e){let t=e.getBoundingClientRect();return e.offsetTop+t.height}closeCalciteDropdown(e=!0){this.open=!1,e&&y(this.triggerEls[0])}async focusOnFirstActiveOrDefaultItem(){let t=this.getTraversableItems().find(i=>i.selected)||(this.focusLastDropdownItem?this.items.at(-1):this.items[0]);this.focusLastDropdownItem=!1,t&&(await this.updateComplete,await D(),await D(),await y(t),t.scrollIntoView({block:"nearest"}))}toggleDropdown(){this.open=!this.open}updateTabIndexOfItems(e){this.items.forEach(t=>{t.tabIndex=e!==t?-1:0})}render(){let{open:e,guid:t}=this;return A({disabled:this.disabled,children:k`<div class=${u(x.triggerContainer)} id=${m.menuButton(t)??c} @click=${this.toggleDropdown} @keydown=${this.keyDownHandler} ${f(this.setReferenceEl)}><slot aria-controls=${m.menu(t)??c} .ariaExpanded=${e} aria-haspopup=menu name=${j.trigger}></slot></div><div .ariaHidden=${!e} class=${u({[x.wrapper]:!0,[T("width",this.width,this.widthScale)]:!!(this.width||this.widthScale)})} popover=manual ${f(this.setFloatingEl)}><div aria-labelledby=${m.menuButton(t)??c} class=${u({[x.content]:!0,[I.animation]:!0,[I.animationActive]:e})} id=${m.menu(t)??c} role=menu ${f(this.setScrollerAndTransitionEl)}><slot @slotchange=${this.updateGroups}></slot></div></div>`})}};N([L({slot:j.trigger})],g.prototype,"triggerEls");C("calcite-dropdown",g);export{g as Dropdown};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*! All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
|
3
|
-
v5.0.0-next.
|
|
3
|
+
v5.0.0-next.6 */
|
|
4
4
|
function e(r){return r.map(o=>{let t="";for(let n=0;n<o;n++)t+=((1+Math.random())*65536|0).toString(16).substring(1);return t}).join("-")}var i=()=>e([2,1,1,1,3]);export{i as a};
|