@lmvz-ds/components 0.13.1 → 0.13.3
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/cjs/{icons-FIfJEo6G.js → Effect-CpZhfb0D.js} +5153 -1359
- package/dist/cjs/aria-loader-BBKbBZLq.js +76 -0
- package/dist/cjs/{assets-CJzJZPzV.js → assets-BnJmIx_h.js} +2 -2
- package/dist/cjs/icons-Brr4vqiE.js +653 -0
- package/dist/cjs/{index-D3BMpL5w.js → index-9ZJx0550.js} +3 -0
- package/dist/cjs/index-QRnWYctw.js +35629 -0
- package/dist/cjs/index.cjs.js +12 -4
- package/dist/cjs/lmvz-action.cjs.entry.js +1 -1
- package/dist/cjs/lmvz-button.cjs.entry.js +6 -3
- package/dist/cjs/lmvz-card.cjs.entry.js +2 -2
- package/dist/cjs/lmvz-chip.cjs.entry.js +1 -1
- package/dist/cjs/lmvz-components.cjs.js +1 -1
- package/dist/cjs/lmvz-header.cjs.entry.js +8 -5
- package/dist/cjs/lmvz-icon.cjs.entry.js +20 -9
- package/dist/cjs/lmvz-input.cjs.entry.js +8 -5
- package/dist/cjs/lmvz-menuitem.cjs.entry.js +7 -4
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{reactive-controller-host-BMDEj1kX.js → reactive-controller-host-DWpVosFu.js} +71 -50
- package/dist/collection/components/lmvz-button/lmvz-button.js +3 -1
- package/dist/collection/components/lmvz-header/lmvz-header.js +5 -3
- package/dist/collection/components/lmvz-icon/lmvz-icon.js +14 -5
- package/dist/collection/components/lmvz-input/lmvz-input.js +5 -3
- package/dist/collection/components/lmvz-menuitem/lmvz-menuitem.js +4 -2
- package/dist/collection/index.js +1 -0
- package/dist/collection/integration/header-integration.js +1 -3
- package/dist/collection/utils/aria/aria-validation-controller.js +68 -27
- package/dist/components/index.js +1 -1
- package/dist/components/lmvz-action.js +1 -1
- package/dist/components/lmvz-button.js +1 -1
- package/dist/components/lmvz-card.js +1 -1
- package/dist/components/lmvz-chip.js +1 -1
- package/dist/components/lmvz-header.js +1 -1
- package/dist/components/lmvz-icon.js +1 -1
- package/dist/components/lmvz-input.js +1 -1
- package/dist/components/lmvz-menuitem.js +1 -1
- package/dist/components/p-BaPwpeMs.js +1 -0
- package/dist/components/p-Bz0S2cGj.js +1 -0
- package/dist/components/p-CSRpdnrt.js +1 -0
- package/dist/components/p-DK2hpvEW.js +12 -0
- package/dist/{lmvz-components/p-CVf2C8dL.js → components/p-DcMNH3fv.js} +1 -1
- package/dist/components/p-DugBvwmd.js +1 -0
- package/dist/esm/{icons-CM7lsnuO.js → Effect-DyamyJqO.js} +4951 -1357
- package/dist/esm/aria-loader-DB71Xewa.js +69 -0
- package/dist/esm/{assets-BelZNJ1W.js → assets-CvV1KMMV.js} +1 -1
- package/dist/esm/icons-C69Um2xB.js +649 -0
- package/dist/esm/index-CekEw3_K.js +35626 -0
- package/dist/esm/{index-T5ljELGS.js → index-smGPjoDX.js} +3 -1
- package/dist/esm/index.js +5 -4
- package/dist/esm/lmvz-action.entry.js +1 -1
- package/dist/esm/lmvz-button.entry.js +6 -3
- package/dist/esm/lmvz-card.entry.js +2 -2
- package/dist/esm/lmvz-chip.entry.js +1 -1
- package/dist/esm/lmvz-components.js +2 -2
- package/dist/esm/lmvz-header.entry.js +8 -5
- package/dist/esm/lmvz-icon.entry.js +20 -9
- package/dist/esm/lmvz-input.entry.js +8 -5
- package/dist/esm/lmvz-menuitem.entry.js +7 -4
- package/dist/esm/loader.js +2 -2
- package/dist/esm/{reactive-controller-host-CZ3dGAjR.js → reactive-controller-host-1nFoJEdT.js} +65 -44
- package/dist/lmvz-components/index.esm.js +1 -1
- package/dist/lmvz-components/lmvz-components.esm.js +1 -1
- package/dist/lmvz-components/{p-d9dc29a1.entry.js → p-0e5aa1a3.entry.js} +1 -1
- package/dist/lmvz-components/p-5775a56c.entry.js +1 -0
- package/dist/lmvz-components/p-814ee542.entry.js +1 -0
- package/dist/lmvz-components/{p-feda2ec5.entry.js → p-9faac8f3.entry.js} +1 -1
- package/dist/lmvz-components/p-B3j8zrhV.js +1 -0
- package/dist/lmvz-components/p-BEoSvNlI.js +1 -0
- package/dist/lmvz-components/p-BTpia82J.js +1 -0
- package/dist/{components/p-CdYWDK7m.js → lmvz-components/p-D7GrtdQF.js} +1 -1
- package/dist/lmvz-components/p-DyamyJqO.js +1 -0
- package/dist/lmvz-components/p-c61f7daa.entry.js +1 -0
- package/dist/lmvz-components/p-c6bae21b.entry.js +1 -0
- package/dist/lmvz-components/p-cM67HC0Z.js +12 -0
- package/dist/lmvz-components/{p-980688a0.entry.js → p-d4b68381.entry.js} +1 -1
- package/dist/lmvz-components/p-f1559aa1.entry.js +1 -0
- package/dist/lmvz-components/p-smGPjoDX.js +2 -0
- package/dist/manifest.json +1 -1
- package/dist/types/components/lmvz-button/lmvz-button.d.ts +1 -0
- package/dist/types/components/lmvz-header/lmvz-header.d.ts +1 -0
- package/dist/types/components/lmvz-icon/lmvz-icon.d.ts +3 -0
- package/dist/types/components/lmvz-input/lmvz-input.d.ts +2 -1
- package/dist/types/components/lmvz-menuitem/lmvz-menuitem.d.ts +3 -1
- package/dist/types/index.d.ts +1 -0
- package/dist/types/utils/aria/aria-validation-controller.d.ts +8 -2
- package/hydrate/index.js +96 -39
- package/hydrate/index.mjs +96 -39
- package/package.json +6 -8
- package/dist/components/p-BsS3QvWn.js +0 -1
- package/dist/components/p-CMteT-Yo.js +0 -1
- package/dist/components/p-vi4YzJmv.js +0 -1
- package/dist/lmvz-components/p-16878d4c.entry.js +0 -1
- package/dist/lmvz-components/p-6e3314ab.entry.js +0 -1
- package/dist/lmvz-components/p-8ea1a349.entry.js +0 -1
- package/dist/lmvz-components/p-BoR31cjC.js +0 -1
- package/dist/lmvz-components/p-CZ3dGAjR.js +0 -1
- package/dist/lmvz-components/p-T5ljELGS.js +0 -2
- package/dist/lmvz-components/p-a34542fa.entry.js +0 -1
- package/dist/lmvz-components/p-d2bf6a3f.entry.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s,h as t,H as r}from"./p-
|
|
1
|
+
import{r as s,h as t,H as r}from"./p-smGPjoDX.js";const a=class{constructor(t){s(this,t)}text;render(){return t(r,{key:"b247f41d22bcf77998bf5a49669f1aa8d7fd3a63"},this.text)}};a.style=":host{display:block}";export{a as lmvz_chip}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{g as e,r as a,h as t,H as r}from"./p-smGPjoDX.js";import{R as n,A as s}from"./p-B3j8zrhV.js";import{g as i,c as l}from"./p-B3JVFwO1.js";import"./p-BTpia82J.js";class o{host;elements=[];constructor(e){this.host=e}hostDidRender(){this.host.el.addEventListener("keydown",this.handleKeydown)}updateElements(e){this.elements=e}handleKeydown=e=>{const{key:a}=e;if(!["ArrowDown","ArrowRight","ArrowUp","ArrowLeft"].includes(a))return;const t=i(document),r=this.getNextFocusableElement(t,["ArrowDown","ArrowRight"].includes(a)?"down":"up");r&&(e.preventDefault(),r.focus?.())};getNextFocusableElement(e,a){const{elements:t}=this,r=t.indexOf(e);if(-1===r)return null;let n=null;if("down"===a?n=(r+1)%t.length:"up"===a&&(n=(r-1+t.length)%t.length),null==n)return null;const s=t[n];return l(s)?s:this.getNextFocusableElement(s,a)}}const c=class extends n{get el(){return e(this)}validationEl=this.el;primarySlot;secondarySlot;secondaryNav;keyboardNavigationController=new o(this);get primaryMenuitems(){return this.primarySlot.assignedElements({flatten:!1})}get secondaryMenuitems(){return this.secondarySlot.assignedElements({flatten:!0})}get role(){return"banner"}lmvzActiveNav;get secondarySlotName(){return`connect-nav-${this.lmvzActiveNav}`}constructor(e){super(),a(this,e),this.addController(new s(this,{reValidateOnPropChanges:!0})),this.addController(this.keyboardNavigationController)}handleActiveNavChange(){this.updateElementsActive()}componentDidLoad(){this.primarySlot.addEventListener("slotchange",this.handlePrimaryNavItemsChange.bind(this)),this.handlePrimaryNavItemsChange(),this.secondarySlot.addEventListener("slotchange",this.handleSecondaryNavItemsChange.bind(this)),super.componentDidLoad()}handlePrimaryNavItemsChange(){const e=this.primaryMenuitems;e.length?(e.forEach((e=>{e.setAttribute("aria-haspopup","true"),e.setAttribute("aria-controls","nav-secondary")})),this.updateElementsActive()):console.warn("Primary slot has no assigned elements. Please add navigation items to the primary slot.")}handleSecondaryNavItemsChange(){this.secondaryMenuitems.length&&this.updateKeyboardNavSubjects()}updateKeyboardNavSubjects(){this.keyboardNavigationController.updateElements([...this.primaryMenuitems,...this.secondaryMenuitems])}updateElementsActive(){let e;this.primaryMenuitems.forEach((a=>{const t=a.id===this.lmvzActiveNav;t&&(e=a.textContent||a.id),a.setAttribute("aria-expanded",t?"true":"false")})),this.secondaryNav.setAttribute("aria-label",`Untermenü für ${e}`)}delegateFocus(){const e=this.primaryMenuitems[0];e&&e.focus()}render(){return t(r,{key:"7c257913615a89b9be8f959b4dc43664ee474113",onFocus:this.delegateFocus.bind(this)},t("div",{key:"70f33263e629170d1b19cbfb1a00ca1adbbe91e0",class:"brand"},t("slot",{key:"d9c99c51da3210e5459684e59e66baf1622a8946",name:"brand"},t("lmvz-icon",{key:"18bd0e88032c023d319bc3fac43c2b09d5098893",id:"fallback-logo-lmvz",icon:"Logo",size:"inherit","aria-label":"Lehrmittelverlag Zürich"}))),t("nav",{key:"c56a1e63344e42b1be26fe817705f0265bdb2bcf","aria-label":"Hauptnavigation"},t("div",{key:"fbaebcb4857b0fba7b81cc35ef6092bb98ae89f8",role:"menubar",class:"primary-menubar"},t("slot",{key:"4a408eacbb41fa57d838581c18389241dce0e634",name:"nav-primary",ref:e=>this.primarySlot=e}),t("div",{key:"6229842569958c724478c6aa15adc75b07d8417e",role:"menu",id:"nav-secondary",class:"secondary-menubar",hidden:!this.lmvzActiveNav,ref:e=>this.secondaryNav=e},t("slot",{key:"4dd4278eaa77cfc984e338da6bb1aa7321c6a545",name:this.secondarySlotName,ref:e=>this.secondarySlot=e})))),t("div",{key:"98b7802b0dc2dfe3a7a38bf89ae2b68994734396",class:"actions"},t("slot",{key:"5f7682fe0ad34496b887baab7b19641a86c01acb",name:"actions"})))}static get watchers(){return{lmvzActiveNav:[{handleActiveNavChange:0}]}}};c.style=":host{display:flex;width:100vw;flex-direction:row;align-items:center;box-sizing:border-box;background-color:var(--lmvz-semantic-color-surface-primary, #ffffff);--lmvz-header-x-spacing-level-1:var(--lmvz-dimension-8-28, clamp(0.5rem, 0.2rem + 1.29vw, 1.75rem));--lmvz-header-x-spacing-level-2:var(--lmvz-component-buttongroup-wrapper-gap-x, clamp(0.25rem, 0.16rem + 0.39vw, 0.63rem));padding:var(--lmvz-dimension-8-16, clamp(0.5rem, 0.38rem + 0.52vw, 1rem)) var(--lmvz-header-x-spacing-level-1);gap:var(--lmvz-header-x-spacing-level-1);.brand{display:inline-flex;justify-content:center;align-items:center}#fallback-logo-lmvz{height:34px;width:auto}nav{flex-grow:1}.primary-menubar{display:flex;flex-direction:row;align-items:center}.secondary-menubar{display:flex;flex-direction:row;align-items:center;margin-left:var(--lmvz-header-x-spacing-level-2);padding-left:var(--lmvz-header-x-spacing-level-2);border-left:1px solid var(--lmvz-semantic-color-border-default, #e0e0e0)}}";export{c as lmvz_header}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var t={isDev:!1},n=(t=>(t.Undefined="undefined",t.Null="null",t.String="string",t.Number="number",t.SpecialNumber="number",t.Boolean="boolean",t.BigInt="bigint",t))(n||{}),e=(t=>(t.Array="array",t.Date="date",t.Map="map",t.Object="object",t.RegularExpression="regexp",t.Set="set",t.Channel="channel",t.Symbol="symbol",t))(e||{}),o="type",l="value",s="serialized:";function i(t,n,e){const o="undefined"!=typeof HTMLElement?HTMLElement.prototype:null;for(;t&&t!==o;){const o=Object.getOwnPropertyDescriptor(t,n);if(o&&(!e||o.get))return o;t=Object.getPrototypeOf(t)}}var r,c=(t,n)=>{var e;Object.entries(null!=(e=n.o.t)?e:{}).map((([e,[o]])=>{if(31&o||32&o){const o=t[e],l=i(Object.getPrototypeOf(t),e,!0)||Object.getOwnPropertyDescriptor(t,e);l&&Object.defineProperty(t,e,{get(){return l.get.call(this)},set(t){l.set.call(this,t)},configurable:!0,enumerable:!0}),n.l.has(e)?t[e]=n.l.get(e):void 0!==o&&(t[e]=o)}}))},u=t=>{if(t.__stencil__getHostRef)return t.__stencil__getHostRef()},f=(t,n)=>{n&&(t.__stencil__getHostRef=()=>n,n.i=t,512&n.o.u&&c(t,n))},a=(t,n)=>n in t,d=(t,n)=>(0,console.error)(t,n),p=new Map,$=new Map,h="s-id",v="sty-id",m="c-id",y="slot-fb{display:contents}slot-fb[hidden]{display:none}",b="http://www.w3.org/1999/xlink",g=["formAssociatedCallback","formResetCallback","formDisabledCallback","formStateRestoreCallback"],w="undefined"!=typeof window?window:{},j={u:0,p:"",jmp:t=>t(),raf:t=>requestAnimationFrame(t),ael:(t,n,e,o)=>t.addEventListener(n,e,o),rel:(t,n,e,o)=>t.removeEventListener(n,e,o),ce:(t,n)=>new CustomEvent(t,n)},S=t=>Promise.resolve(t),O=(()=>{try{return!!w.document.adoptedStyleSheets&&(new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync)}catch(t){}return!1})(),k=!!O&&(()=>!!w.document&&Object.getOwnPropertyDescriptor(w.document.adoptedStyleSheets,"length").writable)(),N=!1,C=[],x=[],E=(t,n)=>e=>{t.push(e),N||(N=!0,n&&4&j.u?R(L):j.raf(L))},M=t=>{for(let n=0;n<t.length;n++)try{t[n](performance.now())}catch(t){d(t)}t.length=0},L=()=>{M(C),M(x),(N=C.length>0)&&j.raf(L)},R=t=>S().then(t),I=E(x,!0),A=t=>{const n=new URL(t,j.p);return n.origin!==w.location.origin?n.href:n.pathname};function T(t){const n={mode:"open"};n.delegatesFocus=!!(16&t.u);const e=this.attachShadow(n);void 0===r&&(r=null),r&&(k?e.adoptedStyleSheets.push(r):e.adoptedStyleSheets=[...e.adoptedStyleSheets,r])}var D=t=>{const n=z(t,"childNodes");t.tagName&&t.tagName.includes("-")&&t["s-cr"]&&"SLOT-FB"!==t.tagName&&B(n,t.tagName).forEach((t=>{1===t.nodeType&&"SLOT-FB"===t.tagName&&(t.hidden=!!F(t,H(t),!1).length)}));let e=0;for(e=0;e<n.length;e++){const t=n[e];1===t.nodeType&&z(t,"childNodes").length&&D(t)}};function B(t,n,e){let o,l=0,s=[];for(;l<t.length;l++){if(o=t[l],o["s-sr"]&&(!n||o["s-hn"]===n)&&(void 0===e||H(o)===e)&&(s.push(o),void 0!==e))return s;s=[...s,...B(o.childNodes,n,e)]}return s}var F=(t,n,e=!0)=>{const o=[];(e&&t["s-sr"]||!t["s-sr"])&&o.push(t);let l=t;for(;l=l.nextSibling;)H(l)!==n||!e&&l["s-sr"]||o.push(l);return o},P=(t,n)=>1===t.nodeType?null===t.getAttribute("slot")&&""===n||t.getAttribute("slot")===n:t["s-sn"]===n||""===n,U=(t,n,e,o)=>{if(t["s-ol"]&&t["s-ol"].isConnected)return;const l=document.createTextNode("");if(l["s-nr"]=t,!n["s-cr"]||!n["s-cr"].parentNode)return;const s=n["s-cr"].parentNode,i=z(s,"appendChild");if(void 0!==o){l["s-oo"]=o;const t=z(s,"childNodes"),n=[l];t.forEach((t=>{t["s-nr"]&&n.push(t)})),n.sort(((t,n)=>!t["s-oo"]||t["s-oo"]<(n["s-oo"]||0)?-1:!n["s-oo"]||n["s-oo"]<t["s-oo"]?1:0)),n.forEach((t=>i.call(s,t)))}else i.call(s,l);t["s-ol"]=l,t["s-sh"]=n["s-hn"]},H=t=>"string"==typeof t["s-sn"]?t["s-sn"]:1===t.nodeType&&t.getAttribute("slot")||void 0;function V(t){if(t.assignedElements||t.assignedNodes||!t["s-sr"])return;const n=n=>function(t){const e=[],o=this["s-sn"];(null==t?void 0:t.flatten)&&console.error("\n Flattening is not supported for Stencil non-shadow slots.\n You can use `.childNodes` to nested slot fallback content.\n If you have a particular use case, please open an issue on the Stencil repo.\n ");const l=this["s-cr"].parentElement;return(l.__childNodes?l.childNodes:(t=>{const n=[];for(let e=0;e<t.length;e++){const o=t[e]["s-nr"]||void 0;o&&o.isConnected&&n.push(o)}return n})(l.childNodes)).forEach((t=>{o===H(t)&&e.push(t)})),n?e.filter((t=>1===t.nodeType)):e}.bind(t);t.assignedElements=n(!0),t.assignedNodes=n(!1)}function z(t,n){if("__"+n in t){const e=t["__"+n];return"function"!=typeof e?e:e.bind(t)}return"function"!=typeof t[n]?t[n]:t[n].bind(t)}function _(t){var n,e,o;return null!=(o=null==(e=null==(n=t.head)?void 0:n.querySelector('meta[name="csp-nonce"]'))?void 0:e.getAttribute("content"))?o:void 0}var W=new WeakMap,q=(t,n,e)=>{let o=$.get(t);O&&e?(o=o||new CSSStyleSheet,"string"==typeof o?o=n:o.replaceSync(n)):o=n,$.set(t,o)},Y=(t,n)=>{var e,o,l;const s=G(n),i=$.get(s);if(!w.document)return s;if(t=11===t.nodeType?t:w.document,i)if("string"==typeof i){let l,r=W.get(t=t.head||t);r||W.set(t,r=new Set);const c=t.querySelector(`[${v}="${s}"]`);if(c)c.textContent=i;else if(!r.has(s)){l=w.document.createElement("style"),l.textContent=i;const c=null!=(e=j.$)?e:_(w.document);if(null!=c&&l.setAttribute("nonce",c),!(1&n.u))if("HEAD"===t.nodeName){const n=t.querySelectorAll("link[rel=preconnect]"),e=n.length>0?n[n.length-1].nextSibling:t.querySelector("style");t.insertBefore(l,(null==e?void 0:e.parentNode)===t?e:null)}else if("host"in t)if(O){const n=new(null!=(o=t.defaultView)?o:t.ownerDocument.defaultView).CSSStyleSheet;n.replaceSync(i),k?t.adoptedStyleSheets.unshift(n):t.adoptedStyleSheets=[n,...t.adoptedStyleSheets]}else{const n=t.querySelector("style");n?n.textContent=i+n.textContent:t.prepend(l)}else t.append(l);1&n.u&&t.insertBefore(l,null),4&n.u&&(l.textContent+=y),r&&r.add(s)}}else{let n=W.get(t);if(n||W.set(t,n=new Set),!n.has(s)){const e=null!=(l=t.defaultView)?l:t.ownerDocument.defaultView;let o;if(i.constructor===e.CSSStyleSheet)o=i;else{o=new e.CSSStyleSheet;for(let t=0;t<i.cssRules.length;t++)o.insertRule(i.cssRules[t].cssText,t)}if(k?t.adoptedStyleSheets.push(o):t.adoptedStyleSheets=[...t.adoptedStyleSheets,o],n.add(s),"host"in t){const n=t.querySelector(`[${v}="${s}"]`);n&&I((()=>n.remove()))}}}return s},G=t=>"sc-"+t.h,J=t=>t.replace(/\/\*!@([^\/]+)\*\/[^\{]+\{/g,"$1{"),Z=t=>"object"==(t=typeof t)||"function"===t,K=(t,n,...e)=>{let o=null,l=null,s=null,i=!1,r=!1;const c=[],u=n=>{for(let e=0;e<n.length;e++)o=n[e],Array.isArray(o)?u(o):null!=o&&"boolean"!=typeof o&&((i="function"!=typeof t&&!Z(o))&&(o+=""),i&&r?c[c.length-1].v+=o:c.push(i?Q(null,o):o),r=i)};if(u(e),n){n.key&&(l=n.key),n.name&&(s=n.name);{const t=n.className||n.class;t&&(n.class="object"!=typeof t?t:Object.keys(t).filter((n=>t[n])).join(" "))}}const f=Q(t,null);return f.m=n,c.length>0&&(f.j=c),f.S=l,f.O=s,f},Q=(t,n)=>({u:0,k:t,v:null!=n?n:null,N:null,j:null,m:null,S:null,O:null}),X={},tt=(t,n,e,o,l,s,i,r=[])=>{let c,u,f,a;const d=l["s-sc"];if(1===s.nodeType){if(c=s.getAttribute(m),c&&(u=c.split("."),u[0]===i||"0"===u[0])){f=et({u:0,C:u[0],M:u[1],L:u[2],R:u[3],k:s.tagName.toLowerCase(),N:s,m:{class:s.className||""}}),n.push(f),s.removeAttribute(m),t.j||(t.j=[]),d&&u[0]===i&&(s["s-si"]=d,f.m.class+=" "+d);const l=f.N.getAttribute("s-sn");"string"==typeof l&&("slot-fb"===f.k&&(ot(l,u[2],f,s,t,n,e,o,r),d&&s.classList.add(d)),f.N["s-sn"]=l,f.N.removeAttribute("s-sn")),void 0!==f.R&&(t.j[f.R]=f),t=f,o&&"0"===f.L&&(o[f.R]=f.N)}if(s.shadowRoot)for(a=s.shadowRoot.childNodes.length-1;a>=0;a--)tt(t,n,e,o,l,s.shadowRoot.childNodes[a],i,r);const p=s.__childNodes||s.childNodes;for(a=p.length-1;a>=0;a--)tt(t,n,e,o,l,p[a],i,r)}else if(8===s.nodeType)u=s.nodeValue.split("."),(u[1]===i||"0"===u[1])&&(c=u[0],f=et({C:u[1],M:u[2],L:u[3],R:u[4]||"0",N:s,m:null,j:null,S:null,O:null,k:null,v:null}),"t"===c?(f.N=ct(s,3),f.N&&3===f.N.nodeType&&(f.v=f.N.textContent,n.push(f),s.remove(),i===f.C&&(t.j||(t.j=[]),t.j[f.R]=f),o&&"0"===f.L&&(o[f.R]=f.N))):"c"===c?(f.N=ct(s,8),f.N&&8===f.N.nodeType&&(n.push(f),s.remove())):f.C===i&&("s"===c?ot(s["s-sn"]=u[5]||"",u[2],f,s,t,n,e,o,r):"r"===c&&(o?s.remove():(l["s-cr"]=s,s["s-cn"]=!0))));else if(t&&"style"===t.k){const n=Q(null,s.textContent);n.N=s,n.R="0",t.j=[n]}return t},nt=(t,n)=>{if(1===t.nodeType){const e=t[h]||t.getAttribute(h);e&&n.set(e,t);let o=0;if(t.shadowRoot)for(;o<t.shadowRoot.childNodes.length;o++)nt(t.shadowRoot.childNodes[o],n);const l=t.__childNodes||t.childNodes;for(o=0;o<l.length;o++)nt(l[o],n)}else if(8===t.nodeType){const e=t.nodeValue.split(".");"o"===e[0]&&(n.set(e[1]+"."+e[2],t),t.nodeValue="",t["s-en"]=e[3])}},et=t=>({u:0,C:null,M:null,L:null,R:"0",N:null,m:null,j:null,S:null,O:null,k:null,v:null,...t});function ot(t,n,e,o,l,s,i,r,c){o["s-sr"]=!0,e.O=t||null,e.k="slot";const u=(null==l?void 0:l.N)?l.N["s-id"]||l.N.getAttribute("s-id"):"";if(r&&w.document){const s=e.N=w.document.createElement(e.k);e.O&&e.N.setAttribute("name",t),l.N.shadowRoot&&u&&u!==e.C?z(l.N,"insertBefore")(s,z(l.N,"children")[0]):z(z(o,"parentNode"),"insertBefore")(s,o),rt(c,n,t,o,e.C),o.remove(),"0"===e.L&&(r[e.R]=e.N)}else{const s=e.N,i=u&&u!==e.C&&l.N.shadowRoot;rt(c,n,t,o,i?u:e.C),V(o),i&&l.N.insertBefore(s,l.N.children[0])}s.push(e),i.push(e),l.j||(l.j=[]),l.j[e.R]=e}var lt,st,it,rt=(t,n,e,o,l)=>{var s,i;let r=o.nextSibling;if(t[n]=t[n]||[],r&&!(null==(s=r.nodeValue)?void 0:s.startsWith("s.")))do{!r||(r.getAttribute&&r.getAttribute("slot")||r["s-sn"])!==e&&(""!==e||r["s-sn"]||r.getAttribute&&r.getAttribute("slot")||8!==r.nodeType&&3!==r.nodeType)||(r["s-sn"]=e,t[n].push({slot:o,node:r,hostId:l})),r=null==r?void 0:r.nextSibling}while(r&&!(null==(i=r.nodeValue)?void 0:i.startsWith("s.")))},ct=(t,n)=>{let e=t;do{e=e.nextSibling}while(e&&(e.nodeType!==n||!e.nodeValue));return e},ut=class t{static fromLocalValue(n){const e=n[o],s=l in n?n[l]:void 0;switch(e){case"string":case"boolean":return s;case"bigint":return BigInt(s);case"undefined":return;case"null":return null;case"number":return"NaN"===s?NaN:"-0"===s?-0:"Infinity"===s?1/0:"-Infinity"===s?-1/0:s;case"array":return s.map((n=>t.fromLocalValue(n)));case"date":return new Date(s);case"map":const n=new Map;for(const[e,o]of s){const l="object"==typeof e&&null!==e?t.fromLocalValue(e):e,s=t.fromLocalValue(o);n.set(l,s)}return n;case"object":const o={};for(const[n,e]of s)o[n]=t.fromLocalValue(e);return o;case"regexp":const{pattern:l,flags:i}=s;return RegExp(l,i);case"set":const r=new Set;for(const n of s)r.add(t.fromLocalValue(n));return r;case"symbol":return Symbol(s);default:throw Error("Unsupported type: "+e)}}static fromLocalValueArray(n){return n.map((n=>t.fromLocalValue(n)))}static isLocalValueObject(t){if("object"!=typeof t||null===t)return!1;if(!t.hasOwnProperty(o))return!1;const s=t[o];return!!Object.values({...n,...e}).includes(s)&&("null"===s||"undefined"===s||t.hasOwnProperty(l))}},ft=(t,n,e)=>"string"==typeof t&&t.startsWith(s)?t=function(t){return"string"==typeof t&&t.startsWith(s)?ut.fromLocalValue(JSON.parse(atob(t.slice(11)))):t}(t):null==t||Z(t)?t:4&n?(e&&"string"==typeof t||"false"!==t)&&(""===t||!!t):2&n?"string"==typeof t?parseFloat(t):"number"==typeof t?t:NaN:1&n?t+"":t,at=t=>{var n;return null==(n=u(t))?void 0:n.$hostElement$},dt=(t,n)=>{const e=at(t);return{emit:t=>pt(e,n,{bubbles:!0,composed:!0,cancelable:!0,detail:t})}},pt=(t,n,e)=>{const o=j.ce(n,e);return t.dispatchEvent(o),o},$t=(t,n,e,o,l,s,i)=>{if(e===o)return;let r=a(t,n),c=n.toLowerCase();if("class"===n){const n=t.classList,l=vt(e);let s=vt(o);if((t["s-si"]||t["s-sc"])&&i){const e=t["s-sc"]||t["s-si"];s.push(e),l.forEach((t=>{t.startsWith(e)&&s.push(t)})),s=[...new Set(s)].filter((t=>t)),n.add(...s)}else n.remove(...l.filter((t=>t&&!s.includes(t)))),n.add(...s.filter((t=>t&&!l.includes(t))))}else if("style"===n){for(const n in e)o&&null!=o[n]||(n.includes("-")?t.style.removeProperty(n):t.style[n]="");for(const n in o)e&&o[n]===e[n]||(n.includes("-")?t.style.setProperty(n,o[n]):t.style[n]=o[n])}else if("key"===n);else if("ref"===n)o&&Ft(o,t);else if(r||"o"!==n[0]||"n"!==n[1]){if("a"===n[0]&&n.startsWith("attr:")){const e=n.slice(5);let l;{const n=u(t);if(n&&n.o&&n.o.t){const t=n.o.t[e];t&&t[1]&&(l=t[1])}}return l||(l=e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()),void(null==o||!1===o?!1===o&&""!==t.getAttribute(l)||t.removeAttribute(l):t.setAttribute(l,!0===o?"":o))}if("p"===n[0]&&n.startsWith("prop:")){const e=n.slice(5);try{t[e]=o}catch(t){}return}{const i=Z(o);if((r||i&&null!==o)&&!l)try{if(t.tagName.includes("-"))t[n]!==o&&(t[n]=o);else{const l=null==o?"":o;"list"===n?r=!1:null!=e&&t[n]===l||("function"==typeof t.__lookupSetter__(n)?t[n]=l:t.setAttribute(n,l))}}catch(t){}let u=!1;c!==(c=c.replace(/^xlink\:?/,""))&&(n=c,u=!0),null==o||!1===o?!1===o&&""!==t.getAttribute(n)||(u?t.removeAttributeNS(b,n):t.removeAttribute(n)):(!r||4&s||l)&&!i&&1===t.nodeType&&(o=!0===o?"":o,u?t.setAttributeNS(b,n,o):t.setAttribute(n,o))}}else if(n="-"===n[2]?n.slice(3):a(w,c)?c.slice(2):c[2]+n.slice(3),e||o){const l=n.endsWith(mt);n=n.replace(yt,""),e&&j.rel(t,n,e,l),o&&j.ael(t,n,o,l)}},ht=/\s/,vt=t=>("object"==typeof t&&t&&"baseVal"in t&&(t=t.baseVal),t&&"string"==typeof t?t.split(ht):[]),mt="Capture",yt=RegExp(mt+"$"),bt=(t,n,e,o)=>{const l=11===n.N.nodeType&&n.N.host?n.N.host:n.N,s=t&&t.m||{},i=n.m||{};for(const t of gt(Object.keys(s)))t in i||$t(l,t,s[t],void 0,e,n.u,o);for(const t of gt(Object.keys(i)))$t(l,t,s[t],i[t],e,n.u,o)};function gt(t){return t.includes("ref")?[...t.filter((t=>"ref"!==t)),"ref"]:t}var wt=!1,jt=!1,St=!1,Ot=!1,kt=[],Nt=[],Ct=(t,n,e)=>{var o;const l=n.j[e];let s,i,r,c=0;if(wt||(St=!0,"slot"===l.k&&(l.u|=l.j?2:1)),null!=l.v)s=l.N=w.document.createTextNode(l.v);else if(1&l.u)s=l.N=w.document.createTextNode(""),bt(null,l,Ot);else{if(!w.document)throw Error("You are trying to render a Stencil component in an environment that doesn't support the DOM.");if(s=l.N=w.document.createElement(!wt&&2&l.u?"slot-fb":l.k),bt(null,l,Ot),null!=lt&&void 0!==lt&&s["s-si"]!==lt&&s.classList.add(s["s-si"]=lt),l.j){const n="template"===l.k?s.content:s;for(c=0;c<l.j.length;++c)i=Ct(t,l,c),i&&n.appendChild(i)}}return s["s-hn"]=it,3&l.u&&(s["s-sr"]=!0,s["s-cr"]=st,s["s-sn"]=l.O||"",s["s-rf"]=null==(o=l.m)?void 0:o.ref,V(s),r=t&&t.j&&t.j[e],r&&r.k===l.k&&t.N&&xt(t.N),Ut(st,s,n.N,null==t?void 0:t.N)),s},xt=t=>{j.u|=1;const n=t.closest(it.toLowerCase());if(null!=n){const e=Array.from(n.__childNodes||n.childNodes).find((t=>t["s-cr"])),o=Array.from(t.__childNodes||t.childNodes);for(const t of e?o.reverse():o)null!=t["s-sh"]&&(Pt(n,t,null!=e?e:null),t["s-sh"]=void 0,St=!0)}j.u&=-2},Et=(t,n)=>{j.u|=1;const e=Array.from(t.__childNodes||t.childNodes);if(t["s-sr"]){let n=t;for(;n=n.nextSibling;)n&&n["s-sn"]===t["s-sn"]&&n["s-sh"]===it&&e.push(n)}for(let t=e.length-1;t>=0;t--){const o=e[t];o["s-hn"]!==it&&o["s-ol"]&&(Pt(It(o).parentNode,o,It(o)),o["s-ol"].remove(),o["s-ol"]=void 0,o["s-sh"]=void 0,St=!0),n&&Et(o,n)}j.u&=-2},Mt=(t,n,e,o,l,s)=>{let i,r=t["s-cr"]&&t["s-cr"].parentNode||t;for(r.shadowRoot&&r.tagName===it&&(r=r.shadowRoot),"template"===e.k&&(r=r.content);l<=s;++l)o[l]&&(i=Ct(null,e,l),i&&(o[l].N=i,Pt(r,i,It(n))))},Lt=(t,n,e)=>{for(let o=n;o<=e;++o){const n=t[o];if(n){const t=n.N;Bt(n),t&&(jt=!0,t["s-ol"]?t["s-ol"].remove():Et(t,!0),t.remove())}}},Rt=(t,n,e=!1)=>t.k===n.k&&("slot"===t.k?t.O===n.O:e?(e&&!t.S&&n.S&&(t.S=n.S),!0):t.S===n.S),It=t=>t&&t["s-ol"]||t,At=(t,n,e=!1)=>{const o=n.N=t.N,l=t.j,s=n.j,i=n.v;let r;null==i?("slot"!==n.k||wt||t.O!==n.O&&(n.N["s-sn"]=n.O||"",xt(n.N.parentElement)),bt(t,n,Ot,e),null!==l&&null!==s?((t,n,e,o,l=!1)=>{let s,i,r=0,c=0,u=0,f=0,a=n.length-1,d=n[0],p=n[a],$=o.length-1,h=o[0],v=o[$];const m="template"===e.k?t.content:t;for(;r<=a&&c<=$;)if(null==d)d=n[++r];else if(null==p)p=n[--a];else if(null==h)h=o[++c];else if(null==v)v=o[--$];else if(Rt(d,h,l))At(d,h,l),d=n[++r],h=o[++c];else if(Rt(p,v,l))At(p,v,l),p=n[--a],v=o[--$];else if(Rt(d,v,l))"slot"!==d.k&&"slot"!==v.k||Et(d.N.parentNode,!1),At(d,v,l),Pt(m,d.N,p.N.nextSibling),d=n[++r],v=o[--$];else if(Rt(p,h,l))"slot"!==d.k&&"slot"!==v.k||Et(p.N.parentNode,!1),At(p,h,l),Pt(m,p.N,d.N),p=n[--a],h=o[++c];else{for(u=-1,f=r;f<=a;++f)if(n[f]&&null!==n[f].S&&n[f].S===h.S){u=f;break}u>=0?(i=n[u],i.k!==h.k?s=Ct(n&&n[c],e,u):(At(i,h,l),n[u]=void 0,s=i.N),h=o[++c]):(s=Ct(n&&n[c],e,c),h=o[++c]),s&&Pt(It(d.N).parentNode,s,It(d.N))}r>a?Mt(t,null==o[$+1]?null:o[$+1].N,e,o,c,$):c>$&&Lt(n,r,a)})(o,l,n,s,e):null!==s?(null!==t.v&&(o.textContent=""),Mt(o,null,n,s,0,s.length-1)):e||null===l?e&&null!==l&&null===s&&(n.j=l):Lt(l,0,l.length-1)):(r=o["s-cr"])?r.parentNode.textContent=i:t.v!==i&&(o.data=i)},Tt=[],Dt=t=>{let n,e,o;const l=t.__childNodes||t.childNodes;for(const t of l){if(t["s-sr"]&&(n=t["s-cr"])&&n.parentNode){e=n.parentNode.__childNodes||n.parentNode.childNodes;const l=t["s-sn"];for(o=e.length-1;o>=0;o--)if(n=e[o],!(n["s-cn"]||n["s-nr"]||n["s-hn"]===t["s-hn"]||n["s-sh"]&&n["s-sh"]===t["s-hn"]))if(P(n,l)){let e=Tt.find((t=>t.I===n));jt=!0,n["s-sn"]=n["s-sn"]||l,e?(e.I["s-sh"]=t["s-hn"],e.A=t):(n["s-sh"]=t["s-hn"],Tt.push({A:t,I:n})),n["s-sr"]&&Tt.map((t=>{P(t.I,n["s-sn"])&&(e=Tt.find((t=>t.I===n)),e&&!t.A&&(t.A=e.A))}))}else Tt.some((t=>t.I===n))||Tt.push({I:n})}1===t.nodeType&&Dt(t)}},Bt=t=>{t.m&&t.m.ref&&kt.push((()=>t.m.ref(null))),t.j&&t.j.map(Bt)},Ft=(t,n)=>{Nt.push((()=>t(n)))},Pt=(t,n,e,o)=>{if("string"==typeof n["s-sn"]&&n["s-sr"]&&n["s-cr"])Ut(n["s-cr"],n,t,n.parentElement);else if("string"==typeof n["s-sn"]){t.insertBefore(n,e);const{slotNode:l}=function(t,n){var e;if(!(n=n||(null==(e=t["s-ol"])?void 0:e.parentElement)))return{slotNode:null,slotName:""};const o=t["s-sn"]=H(t)||"";return{slotNode:B(z(n,"childNodes"),n.tagName,o)[0],slotName:o}}(n);return l&&!o&&function(t){t.dispatchEvent(new CustomEvent("slotchange",{bubbles:!1,cancelable:!1,composed:!1}))}(l),n}return t.__insertBefore?t.__insertBefore(n,e):null==t?void 0:t.insertBefore(n,e)};function Ut(t,n,e,o){var l,s;let i;if(t&&"string"==typeof n["s-sn"]&&n["s-sr"]&&t.parentNode&&t.parentNode["s-sc"]&&(i=n["s-si"]||t.parentNode["s-sc"])){const t=n["s-sn"],r=n["s-hn"];if(null==(l=e.classList)||l.add(i+"-s"),o&&(null==(s=o.classList)?void 0:s.contains(i+"-s"))){let n=(o.__childNodes||o.childNodes)[0],e=!1;for(;n;){if(n["s-sn"]!==t&&n["s-hn"]===r&&n["s-sr"]){e=!0;break}n=n.nextSibling}e||o.classList.remove(i+"-s")}}}var Ht=(t,n)=>{if(n&&!t.T&&n["s-p"]){const e=n["s-p"].push(new Promise((o=>t.T=()=>{n["s-p"].splice(e-1,1),o()})))}},Vt=(t,n)=>{if(t.u|=16,4&t.u)return void(t.u|=512);Ht(t,t.D);const e=()=>zt(t,n);if(!n)return I(e);queueMicrotask((()=>{e()}))},zt=(t,n)=>{const e=t.$hostElement$,o=t.i;if(!o)throw Error(`Can't render component <${e.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`);let l;return n?(t.B&&(t.B=!1,Zt(o,"connectedCallback",void 0,e)),t.F.length&&t.F.forEach((t=>t(e))),l=Zt(o,"componentWillLoad",void 0,e)):l=Zt(o,"componentWillUpdate",void 0,e),l=_t(l,(()=>Zt(o,"componentWillRender",void 0,e))),_t(l,(()=>qt(t,o,n)))},_t=(t,n)=>Wt(t)?t.then(n).catch((t=>{console.error(t),n()})):n(),Wt=t=>t instanceof Promise||t&&t.then&&"function"==typeof t.then,qt=async(t,n,e)=>{var o;const l=t.$hostElement$,s=l["s-rc"];e&&(t=>{const n=t.o,e=t.$hostElement$,o=n.u,l=Y(e.shadowRoot?e.shadowRoot:e.getRootNode(),n);10&o&&(e["s-sc"]=l,e.classList.add(l+"-h"))})(t);Yt(t,n,l,e),s&&(s.map((t=>t())),l["s-rc"]=void 0);{const n=null!=(o=l["s-p"])?o:[],e=()=>Gt(t);0===n.length?e():(Promise.all(n).then(e).catch(e),t.u|=4,n.length=0)}},Yt=(t,n,e,o)=>{try{n=n.render(),t.u&=-17,t.u|=2,((t,n,e=!1)=>{var o,l,s,i,r;const c=t.$hostElement$,u=t.o,f=t.P||Q(null,null),a=(t=>t&&t.k===X)(n)?n:K(null,null,n);if(it=c.tagName,u.U&&(a.m=a.m||{},u.U.forEach((([t,n])=>{a.m[n]=c[t]}))),e&&a.m)for(const t of Object.keys(a.m))c.hasAttribute(t)&&!["key","ref","style","class"].includes(t)&&(a.m[t]=c[t]);if(a.k=null,a.u|=4,t.P=a,a.N=f.N=c.shadowRoot||c,lt=c["s-sc"],wt=!(!(1&u.u)||128&u.u),st=c["s-cr"],jt=!1,At(f,a,e),j.u|=1,St){Dt(a.N);for(const t of Tt){const n=t.I;if(!n["s-ol"]&&w.document){const t=w.document.createTextNode("");t["s-nr"]=n,Pt(n.parentNode,n["s-ol"]=t,n,e)}}for(const t of Tt){const n=t.I,r=t.A;if(1===n.nodeType&&e&&(n["s-ih"]=null!=(o=n.hidden)&&o),r){const t=r.parentNode;let o=r.nextSibling;if(o&&1===o.nodeType){let e=null==(l=n["s-ol"])?void 0:l.previousSibling;for(;e;){let l=null!=(s=e["s-nr"])?s:null;if(l&&l["s-sn"]===n["s-sn"]&&t===(l.__parentNode||l.parentNode)){for(l=l.nextSibling;l===n||(null==l?void 0:l["s-sr"]);)l=null==l?void 0:l.nextSibling;if(!l||!l["s-nr"]){o=l;break}}e=e.previousSibling}}if((!o&&t!==(n.__parentNode||n.parentNode)||(n.__nextSibling||n.nextSibling)!==o)&&n!==o){if(Pt(t,n,o,e),8===n.nodeType&&n.nodeValue.startsWith("s-nt-")){const t=w.document.createTextNode(n.nodeValue.replace(/^s-nt-/,""));t["s-hn"]=n["s-hn"],t["s-sn"]=n["s-sn"],t["s-sh"]=n["s-sh"],t["s-sr"]=n["s-sr"],t["s-ol"]=n["s-ol"],t["s-ol"]["s-nr"]=t,Pt(n.parentNode,t,n,e),n.parentNode.removeChild(n)}1===n.nodeType&&"SLOT-FB"!==n.tagName&&(n.hidden=null!=(i=n["s-ih"])&&i)}n&&"function"==typeof r["s-rf"]&&r["s-rf"](r)}else 1===n.nodeType&&(n.hidden=!0)}}if(jt&&D(a.N),j.u&=-2,Tt.length=0,!wt&&!(1&u.u)&&c["s-cr"]){const t=a.N.__childNodes||a.N.childNodes;for(const n of t)if(n["s-hn"]!==it&&!n["s-sh"])if(e&&null==n["s-ih"]&&(n["s-ih"]=null!=(r=n.hidden)&&r),1===n.nodeType)n.hidden=!0;else if(3===n.nodeType&&n.nodeValue.trim()){const t=w.document.createComment("s-nt-"+n.nodeValue);t["s-sn"]=n["s-sn"],Pt(n.parentNode,t,n,e),n.parentNode.removeChild(n)}}st=void 0,kt.forEach((t=>t())),kt.length=0,Nt.forEach((t=>t())),Nt.length=0})(t,n,o)}catch(n){d(n,t.$hostElement$)}return null},Gt=t=>{const n=t.$hostElement$,e=t.i,o=t.D;Zt(e,"componentDidRender",void 0,n),64&t.u?Zt(e,"componentDidUpdate",void 0,n):(t.u|=64,Kt(n),Zt(e,"componentDidLoad",void 0,n),t.H(n),o||Jt()),t.V(n),t.T&&(t.T(),t.T=void 0),512&t.u&&R((()=>Vt(t,!1))),t.u&=-517},Jt=()=>{var t;R((()=>pt(w,"appload",{detail:{namespace:"lmvz-components"}}))),(null==(t=j._)?void 0:t.size)&&j._.clear()},Zt=(t,n,e,o)=>{if(t&&t[n])try{return t[n](e)}catch(t){d(t,o)}},Kt=t=>t.classList.add("hydrated"),Qt=(t,n,e,o)=>{const l=u(t);if(!l)return;if(!l)throw Error(`Couldn't find host element for "${o.h}" as it is unknown to this Stencil runtime. This usually happens when integrating a 3rd party Stencil component with another Stencil component or application. Please reach out to the maintainers of the 3rd party Stencil component or report this on the Stencil Discord server (https://chat.stenciljs.com) or comment on this similar [GitHub issue](https://github.com/stenciljs/core/issues/5457).`);const s=l.$hostElement$,i=l.l.get(n),r=l.u,c=l.i;if(e=ft(e,o.t[n][0],!!(64&o.u)),!(8&r&&void 0!==i||e===i||Number.isNaN(i)&&Number.isNaN(e))){if(l.l.set(n,e),o.W){const t=o.W[n];t&&t.map((t=>{try{const[[o,s]]=Object.entries(t);(128&r||1&s)&&(c?c[o](e,i,n):l.F.push((()=>{l.i[o](e,i,n)})))}catch(t){d(t,s)}}))}if(2&r){if(c.componentShouldUpdate&&!1===c.componentShouldUpdate(e,i,n)&&!(16&r))return;16&r||Vt(l,!1)}}},Xt=(t,n,e)=>{var o,l;const s=t.prototype;64&n.u&&1&e&&g.forEach((t=>{Object.defineProperty(s,t,{value(...n){var e;const o=u(this),l=null==o?void 0:o.i;if(l){const e=l[t];"function"==typeof e&&e.call(l,...n)}else null==(e=null==o?void 0:o.q)||e.then((e=>{const o=e[t];"function"==typeof o&&o.call(e,...n)}))}})}));{t.watchers&&!n.W&&(n.W=t.watchers),t.deserializers&&!n.Y&&(n.Y=t.deserializers),t.serializers&&!n.G&&(n.G=t.serializers);const r=Object.entries(null!=(o=n.t)?o:{});if(r.map((([t,[o]])=>{if(31&o||2&e&&32&o){const{get:l,set:r}=i(s,t)||{};l&&(n.t[t][0]|=2048),r&&(n.t[t][0]|=4096),(1&e||!l)&&Object.defineProperty(s,t,{get(){{if(!(2048&n.t[t][0]))return((t,n)=>u(this).l.get(n))(0,t);const e=u(this),o=e?e.i:s;if(!o)return;return o[t]}},configurable:!0,enumerable:!0}),Object.defineProperty(s,t,{set(l){const s=u(this);if(s){if(r)return void 0===(32&o?this[t]:s.$hostElement$[t])&&s.l.get(t)&&(l=s.l.get(t)),r.call(this,ft(l,o,!!(64&n.u))),void Qt(this,t,l=32&o?this[t]:s.$hostElement$[t],n);{if(!(1&e&&4096&n.t[t][0]))return Qt(this,t,l,n),void(1&e&&!s.i&&s.F.push((()=>{4096&n.t[t][0]&&s.i[t]!==s.l.get(t)&&(s.i[t]=l)})));const i=()=>{const e=s.i[t];!s.l.get(t)&&e&&s.l.set(t,e),s.i[t]=ft(l,o,!!(64&n.u)),Qt(this,t,s.i[t],n)};s.i?i():s.F.push((()=>{i()}))}}}})}else 1&e&&64&o&&Object.defineProperty(s,t,{value(...n){var e;const o=u(this);return null==(e=null==o?void 0:o.J)?void 0:e.then((()=>{var e;return null==(e=o.i)?void 0:e[t](...n)}))}})})),1&e){const e=new Map;s.attributeChangedCallback=function(t,o,l){j.jmp((()=>{var i;const c=e.get(t),f=u(this);if(this.hasOwnProperty(c)&&(l=this[c],delete this[c]),s.hasOwnProperty(c)&&"number"==typeof this[c]&&this[c]==l)return;if(null==c){const e=null==f?void 0:f.u;if(f&&e&&!(8&e)&&l!==o){const s=f.i,r=null==(i=n.W)?void 0:i[t];null==r||r.forEach((n=>{const[[i,r]]=Object.entries(n);null!=s[i]&&(128&e||1&r)&&s[i].call(s,l,o,t)}))}return}const a=r.find((([t])=>t===c));a&&4&a[1][0]&&(l=null!==l&&"false"!==l);const d=Object.getOwnPropertyDescriptor(s,c);l==this[c]||d.get&&!d.set||(this[c]=l)}))},t.observedAttributes=Array.from(new Set([...Object.keys(null!=(l=n.W)?l:{}),...r.filter((([t,n])=>31&n[0])).map((([t,o])=>{var l;const s=o[1]||t;return e.set(s,t),512&o[0]&&(null==(l=n.U)||l.push([t,s])),s}))]))}}return t},tn=(t,n)=>{Zt(t,"connectedCallback",void 0,n)},nn=t=>{if(!(1&j.u)){const n=u(t);if(!n)return;const e=n.o,o=()=>{};if(1&n.u)(null==n?void 0:n.i)?tn(n.i,t):(null==n?void 0:n.q)&&n.q.then((()=>tn(n.i,t)));else{let o;if(n.u|=1,o=t.getAttribute(h),o){if(1&e.u){const n=Y(t.shadowRoot,e);t.classList.remove(n+"-h",n+"-s")}else if(2&e.u){const n=G(e);t["s-sc"]=n}((t,n,e,o)=>{var l,s,i,r;const c=t.shadowRoot,f=[],a=[],d=[],p=c?[]:null,$=Q(n,null);let v;$.N=t;{const n=o.o;n&&10&n.u&&t["s-sc"]?(v=t["s-sc"],t.classList.add(v+"-h")):t["s-sc"]&&delete t["s-sc"]}!w.document||j._&&j._.size||nt(w.document.body,j._=new Map),t[h]=e,t.removeAttribute(h),o.P=tt($,f,a,p,t,t,e,d);let m=0;const y=f.length;let b;for(;m<y;m++){b=f[m];const e=b.C+"."+b.M,o=j._.get(e),s=b.N;if(c){if((null==(l=b.k)?void 0:(""+l).includes("-"))&&"slot-fb"!==b.k&&!b.N.shadowRoot){const t=u(b.N);if(t){const n=G(t.o),e=w.document.querySelector(`style[sty-id="${n}"]`);e&&p.unshift(e.cloneNode(!0))}}}else s["s-hn"]=n.toUpperCase(),"slot"===b.k&&(s["s-cr"]=t["s-cr"]);"slot"===b.k&&(b.O=b.N["s-sn"]||b.N.name||null,b.j?(b.u|=2,b.N.childNodes.length||b.j.forEach((t=>{b.N.appendChild(t.N)}))):b.u|=1),o&&o.isConnected&&(o.parentElement.shadowRoot&&""===o["s-en"]&&o.parentNode.insertBefore(s,o.nextSibling),o.parentNode.removeChild(o),c||(s["s-oo"]=parseInt(b.M))),o&&!o["s-id"]&&j._.delete(e)}const g=[],S=d.length;let O,k,N,C,x=0,E=0;for(;x<S;x++)if(O=d[x],O&&O.length)for(N=O.length,k=0;k<N;k++){if(C=O[k],g[C.hostId]||(g[C.hostId]=j._.get(C.hostId)),!g[C.hostId])continue;const t=g[C.hostId];t.shadowRoot&&C.node.parentElement!==t&&t.insertBefore(C.node,null==(i=null==(s=O[k-1])?void 0:s.node)?void 0:i.nextSibling),t.shadowRoot&&c||(C.slot["s-cr"]||(C.slot["s-cr"]=t["s-cr"],C.slot["s-cr"]=!C.slot["s-cr"]&&t.shadowRoot?t:(t.__childNodes||t.childNodes)[0]),U(C.node,C.slot,0,C.node["s-oo"]||E),(null==(r=C.node.parentElement)?void 0:r.shadowRoot)&&C.node.getAttribute&&C.node.getAttribute("slot")&&C.node.removeAttribute("slot")),E=(C.node["s-oo"]||E)+1}if(v&&a.length&&a.forEach((t=>{t.N.parentElement.classList.add(v+"-s")})),c&&!c.childNodes.length){let n=0;const e=p.length;if(e){for(;n<e;n++){const t=p[n];t&&c.appendChild(t)}Array.from(t.childNodes).forEach((t=>{"string"!=typeof t["s-en"]&&"string"!=typeof t["s-sn"]&&(1===t.nodeType&&t.slot&&t.hidden?t.removeAttribute("hidden"):8!==t.nodeType||t.nodeValue||t.parentNode.removeChild(t))}))}}o.$hostElement$=t})(t,e.h,o,n)}o||12&e.u&&en(t);{let e=t;for(;e=e.parentNode||e.host;)if(1===e.nodeType&&e.hasAttribute("s-id")&&e["s-p"]||e["s-p"]){Ht(n,n.D=e);break}}e.t&&Object.entries(e.t).map((([n,[e]])=>{if(31&e&&Object.prototype.hasOwnProperty.call(t,n)){const e=t[n];delete t[n],t[n]=e}})),(async(t,n,e)=>{let o;try{if(!(32&n.u)){if(n.u|=32,e.Z){const l=((t,n)=>{const e=t.h.replace(/-/g,"_"),o=t.Z;if(!o)return;const l=p.get(o);return l?l[e]:import(`./${o}.entry.js`).then((t=>(p.set(o,t),t[e])),(t=>{d(t,n.$hostElement$)}))
|
|
2
|
+
/*!__STENCIL_STATIC_IMPORT_SWITCH__*/})(e,n);if(l&&"then"in l){const t=()=>{};o=await l,t()}else o=l;if(!o)throw Error(`Constructor for "${e.h}#${n.K}" was not found`);o.isProxied||(e.W=o.watchers,e.G=o.serializers,e.Y=o.deserializers,Xt(o,e,2),o.isProxied=!0);const s=()=>{};n.u|=8;try{new o(n)}catch(n){d(n,t)}n.u&=-9,n.u|=128,s(),4&e.u?n.B=!0:tn(n.i,t)}else o=t.constructor,customElements.whenDefined(t.localName).then((()=>n.u|=128));if(o&&o.style){let t;"string"==typeof o.style&&(t=o.style);const n=G(e);if(!$.has(n)){const o=()=>{};q(n,t,!!(1&e.u)),o()}}}const l=n.D,s=()=>Vt(n,!0);l&&l["s-rc"]?l["s-rc"].push(s):s()}catch(e){d(e,t),n.T&&(n.T(),n.T=void 0),n.H&&n.H(t)}})(t,n,e)}o()}},en=t=>{if(!w.document)return;const n=t["s-cr"]=w.document.createComment("");n["s-cn"]=!0,Pt(t,n,t.firstChild)},on=(t,n)=>{Zt(t,"disconnectedCallback",void 0,n||t)},ln=(t,n={})=>{var e;if(!w.document)return void console.warn("Stencil: No document found. Skipping bootstrapping lazy components.");const o=[],l=n.exclude||[],s=w.customElements,i=w.document.head,r=i.querySelector("meta[charset]"),c=w.document.createElement("style"),f=[];let a,d=!0;Object.assign(j,n),j.p=new URL(n.resourcesUrl||"./",w.document.baseURI).href,j.u|=2,(()=>{if(!w.document)return;const t=w.document.querySelectorAll(`[${v}]`);let n=0;for(;n<t.length;n++)q(t[n].getAttribute(v),J(t[n].innerHTML),!0)})();let p=!1;if(t.map((t=>{t[1].map((n=>{var e,i,r;const c={u:n[0],h:n[1],t:n[2],X:n[3]};4&c.u&&(p=!0),c.t=n[2],c.U=[],c.W=null!=(e=n[4])?e:{},c.G=null!=(i=n[5])?i:{},c.Y=null!=(r=n[6])?r:{};const $=c.h,h=class extends HTMLElement{"s-p";"s-rc";hasRegisteredEventListeners=!1;constructor(t){if(super(t),((t,n)=>{const e={u:0,$hostElement$:t,o:n,l:new Map,tt:new Map};e.J=new Promise((t=>e.V=t)),e.q=new Promise((t=>e.H=t)),t["s-p"]=[],t["s-rc"]=[],e.F=[];const o=e;t.__stencil__getHostRef=()=>o})(t=this,c),1&c.u)if(t.shadowRoot){if("open"!==t.shadowRoot.mode)throw Error(`Unable to re-use existing shadow root for ${c.h}! Mode is set to ${t.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else T.call(t,c)}connectedCallback(){u(this)&&(this.hasRegisteredEventListeners||(this.hasRegisteredEventListeners=!0),a&&(clearTimeout(a),a=null),d?f.push(this):j.jmp((()=>nn(this))))}disconnectedCallback(){j.jmp((()=>(async t=>{if(!(1&j.u)){const n=u(t);(null==n?void 0:n.i)?on(n.i,t):(null==n?void 0:n.q)&&n.q.then((()=>on(n.i,t)))}W.has(t)&&W.delete(t),t.shadowRoot&&W.has(t.shadowRoot)&&W.delete(t.shadowRoot)})(this))),j.raf((()=>{var t;const n=u(this);if(!n)return;const e=f.findIndex((t=>t===this));e>-1&&f.splice(e,1),(null==(t=null==n?void 0:n.P)?void 0:t.N)instanceof Node&&!n.P.N.isConnected&&delete n.P.N}))}componentOnReady(){var t;return null==(t=u(this))?void 0:t.q}};64&c.u&&(h.formAssociated=!0),c.Z=t[0],l.includes($)||s.get($)||(o.push($),s.define($,Xt(h,c,1)))}))})),o.length>0&&(p&&(c.textContent+=y),c.textContent+=o.sort()+"{visibility:hidden}.hydrated{visibility:inherit}",c.innerHTML.length)){c.setAttribute("data-styles","");const t=null!=(e=j.$)?e:_(w.document);null!=t&&c.setAttribute("nonce",t),i.insertBefore(c,r?r.nextSibling:i.firstChild)}d=!1,f.length?f.map((t=>t.connectedCallback())):j.jmp((()=>a=setTimeout(Jt,30)))},sn=t=>j.$=t;export{t as B,X as H,A as a,ln as b,dt as c,at as g,K as h,S as p,f as r,sn as s}
|
package/dist/manifest.json
CHANGED
|
@@ -6,6 +6,7 @@ import { type FormRef } from '../../utils/component';
|
|
|
6
6
|
import { ReactiveControllerHost } from '../../utils/reactive-controller-host';
|
|
7
7
|
export declare class LmvzButton extends ReactiveControllerHost implements AriaValidationHost, ElementActivationHost {
|
|
8
8
|
el: HTMLLmvzButtonElement;
|
|
9
|
+
validationEl: HTMLButtonElement;
|
|
9
10
|
private inheritedAttributes;
|
|
10
11
|
private formEl;
|
|
11
12
|
private formButtonEl;
|
|
@@ -3,6 +3,7 @@ import { type ListKeyboardNavigationHost } from '../../utils/aria/list-keyboard-
|
|
|
3
3
|
import { ReactiveControllerHost } from '../../utils/reactive-controller-host';
|
|
4
4
|
export declare class LmvzHeader extends ReactiveControllerHost implements AriaValidationHost, ListKeyboardNavigationHost {
|
|
5
5
|
readonly el: HTMLElement;
|
|
6
|
+
readonly validationEl: HTMLElement;
|
|
6
7
|
private primarySlot;
|
|
7
8
|
private secondarySlot;
|
|
8
9
|
private secondaryNav;
|
|
@@ -3,7 +3,9 @@ import { type AriaValidationHost } from '../../utils/aria/aria-validation-contro
|
|
|
3
3
|
import { ReactiveControllerHost } from '../../utils/reactive-controller-host';
|
|
4
4
|
export declare class LmvzIcon extends ReactiveControllerHost implements AriaValidationHost {
|
|
5
5
|
private intersectionObserver;
|
|
6
|
+
private readonly ariaValidationController;
|
|
6
7
|
el: HTMLElement;
|
|
8
|
+
validationEl: HTMLElement;
|
|
7
9
|
icon: Icon.IconName;
|
|
8
10
|
weight?: Icon.IconWeight;
|
|
9
11
|
size?: Icon.Size;
|
|
@@ -15,6 +17,7 @@ export declare class LmvzIcon extends ReactiveControllerHost implements AriaVali
|
|
|
15
17
|
connectedCallback(): void;
|
|
16
18
|
disconnectedCallback(): void;
|
|
17
19
|
private loadIconPathData;
|
|
20
|
+
componentDidRender(): void;
|
|
18
21
|
render(): any;
|
|
19
22
|
private waitUntilVisible;
|
|
20
23
|
}
|
|
@@ -3,7 +3,8 @@ import { Input } from '../../api';
|
|
|
3
3
|
import { type AriaValidationHost } from '../../utils/aria/aria-validation-controller';
|
|
4
4
|
import { ReactiveControllerHost } from '../../utils/reactive-controller-host';
|
|
5
5
|
export declare class LmvzInput extends ReactiveControllerHost implements AriaValidationHost {
|
|
6
|
-
el: HTMLElement;
|
|
6
|
+
readonly el: HTMLElement;
|
|
7
|
+
readonly validationEl: HTMLElement;
|
|
7
8
|
lmvzInput: EventEmitter<string>;
|
|
8
9
|
internals: ElementInternals;
|
|
9
10
|
private nativeInputElement?;
|
|
@@ -3,7 +3,9 @@ import { type AriaValidationHost } from '../../utils/aria/aria-validation-contro
|
|
|
3
3
|
import { type ElementActivationHost } from '../../utils/aria/element-activation-controller';
|
|
4
4
|
import { ReactiveControllerHost } from '../../utils/reactive-controller-host';
|
|
5
5
|
export declare class LmvzMenuItem extends ReactiveControllerHost implements AriaValidationHost, ElementActivationHost {
|
|
6
|
-
el: HTMLElement;
|
|
6
|
+
readonly el: HTMLElement;
|
|
7
|
+
validationEl: HTMLElement;
|
|
8
|
+
validationSlot: HTMLSlotElement;
|
|
7
9
|
get role(): string;
|
|
8
10
|
get ti(): number;
|
|
9
11
|
lmvzActivation: EventEmitter<void>;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import type { ReactiveController } from '../reactive-controller-host';
|
|
2
2
|
export type AriaValidationHost<T extends HTMLElement = HTMLElement> = {
|
|
3
|
-
|
|
3
|
+
validationEl: T | undefined;
|
|
4
|
+
validationSlot?: HTMLSlotElement;
|
|
4
5
|
};
|
|
5
6
|
type Config = {
|
|
6
7
|
reValidateOnPropChanges?: boolean;
|
|
7
8
|
verboseLogging?: boolean;
|
|
9
|
+
validationTiming?: 'load' | 'slot';
|
|
8
10
|
};
|
|
9
11
|
export declare class AriaValidationController implements ReactiveController {
|
|
10
12
|
private readonly host;
|
|
@@ -12,13 +14,17 @@ export declare class AriaValidationController implements ReactiveController {
|
|
|
12
14
|
private visibilityObserver?;
|
|
13
15
|
private elementQueued;
|
|
14
16
|
private elementValidated;
|
|
15
|
-
private
|
|
17
|
+
private elementLoaded;
|
|
18
|
+
private static knownValidationErrors;
|
|
16
19
|
get disabled(): boolean;
|
|
20
|
+
private get useVerboseLogging();
|
|
17
21
|
constructor(host: AriaValidationHost, config?: Config);
|
|
18
22
|
private readonly onRuntimeConfigChange;
|
|
19
23
|
hostDidLoad(): void;
|
|
20
24
|
hostDidUpdate(): void;
|
|
21
25
|
hostDisconnected(): void;
|
|
26
|
+
revalidateAria(): void;
|
|
27
|
+
private observeSlot;
|
|
22
28
|
private observeVisibilityOnce;
|
|
23
29
|
private checkLazyValidation;
|
|
24
30
|
private enqueueValidation;
|
package/hydrate/index.js
CHANGED
|
@@ -5096,6 +5096,8 @@ var registerHost = (elm, cmpMeta) => {
|
|
|
5096
5096
|
elm.__stencil__getHostRef = () => hostRef;
|
|
5097
5097
|
return hostRef;
|
|
5098
5098
|
};
|
|
5099
|
+
var Build = {
|
|
5100
|
+
isDev: false};
|
|
5099
5101
|
var styles = /* @__PURE__ */ new Map();
|
|
5100
5102
|
var setScopedSSR = (opts) => {
|
|
5101
5103
|
scopedSSR = opts.serializeShadowRoot !== false && opts.serializeShadowRoot !== "declarative-shadow-dom";
|
|
@@ -5221,7 +5223,7 @@ var classNames = /*@__PURE__*/getDefaultExportFromCjs(classnamesExports);
|
|
|
5221
5223
|
|
|
5222
5224
|
const GLOBAL_STATE_KEY = Symbol('__lmvzAriaValidationRuntimeState');
|
|
5223
5225
|
const ARIA_VALIDATION_RUNTIME_CHANGED_EVENT = 'lmvz:aria-validation-runtime-changed';
|
|
5224
|
-
|
|
5226
|
+
function getRuntimeState() {
|
|
5225
5227
|
const globalState = globalThis;
|
|
5226
5228
|
if (!globalState[GLOBAL_STATE_KEY]) {
|
|
5227
5229
|
globalState[GLOBAL_STATE_KEY] = {
|
|
@@ -5229,8 +5231,9 @@ const getRuntimeState = () => {
|
|
|
5229
5231
|
};
|
|
5230
5232
|
}
|
|
5231
5233
|
return globalState[GLOBAL_STATE_KEY];
|
|
5232
|
-
}
|
|
5234
|
+
}
|
|
5233
5235
|
const isAriaValidationEnabled = () => getRuntimeState().enabled;
|
|
5236
|
+
const useVerboseLogging = () => getRuntimeState().verboseLogging ?? false;
|
|
5234
5237
|
function queueValidation(...args) {
|
|
5235
5238
|
const state = getRuntimeState();
|
|
5236
5239
|
if (!state.enabled || !state.runtime)
|
|
@@ -5244,10 +5247,14 @@ class AriaValidationController {
|
|
|
5244
5247
|
visibilityObserver;
|
|
5245
5248
|
elementQueued = false;
|
|
5246
5249
|
elementValidated = false;
|
|
5247
|
-
|
|
5250
|
+
elementLoaded = false;
|
|
5251
|
+
static knownValidationErrors = [];
|
|
5248
5252
|
get disabled() {
|
|
5249
5253
|
return !isAriaValidationEnabled();
|
|
5250
5254
|
}
|
|
5255
|
+
get useVerboseLogging() {
|
|
5256
|
+
return this.config?.verboseLogging || Build.isDev || useVerboseLogging();
|
|
5257
|
+
}
|
|
5251
5258
|
constructor(host, config) {
|
|
5252
5259
|
this.host = host;
|
|
5253
5260
|
this.config = config;
|
|
@@ -5258,12 +5265,17 @@ class AriaValidationController {
|
|
|
5258
5265
|
this.checkLazyValidation();
|
|
5259
5266
|
};
|
|
5260
5267
|
hostDidLoad() {
|
|
5268
|
+
this.elementLoaded = true;
|
|
5261
5269
|
if (typeof window !== 'undefined') {
|
|
5262
5270
|
window.addEventListener(ARIA_VALIDATION_RUNTIME_CHANGED_EVENT, this.onRuntimeConfigChange);
|
|
5263
5271
|
}
|
|
5264
5272
|
if (this.elementQueued || this.elementValidated)
|
|
5265
5273
|
return;
|
|
5266
|
-
if (
|
|
5274
|
+
if (this.config?.validationTiming === 'slot') {
|
|
5275
|
+
this.observeSlot();
|
|
5276
|
+
return;
|
|
5277
|
+
}
|
|
5278
|
+
if (!this.host.validationEl?.checkVisibility() || this.config?.validationTiming !== 'load') {
|
|
5267
5279
|
this.observeVisibilityOnce();
|
|
5268
5280
|
return;
|
|
5269
5281
|
}
|
|
@@ -5278,26 +5290,40 @@ class AriaValidationController {
|
|
|
5278
5290
|
window.removeEventListener(ARIA_VALIDATION_RUNTIME_CHANGED_EVENT, this.onRuntimeConfigChange);
|
|
5279
5291
|
}
|
|
5280
5292
|
}
|
|
5293
|
+
revalidateAria() {
|
|
5294
|
+
this.enqueueValidation();
|
|
5295
|
+
}
|
|
5296
|
+
observeSlot() {
|
|
5297
|
+
this.host.validationSlot?.addEventListener('slotchange', this.enqueueValidation.bind(this));
|
|
5298
|
+
}
|
|
5281
5299
|
observeVisibilityOnce() {
|
|
5282
|
-
|
|
5283
|
-
|
|
5284
|
-
|
|
5285
|
-
|
|
5286
|
-
|
|
5287
|
-
|
|
5288
|
-
|
|
5289
|
-
|
|
5290
|
-
|
|
5291
|
-
|
|
5292
|
-
|
|
5293
|
-
|
|
5294
|
-
|
|
5300
|
+
window.setTimeout(() => {
|
|
5301
|
+
if (!this.host.validationEl)
|
|
5302
|
+
return;
|
|
5303
|
+
this.visibilityObserver = new IntersectionObserver((entries) => {
|
|
5304
|
+
for (const entry of entries) {
|
|
5305
|
+
if (entry.target !== this.host.validationEl)
|
|
5306
|
+
continue;
|
|
5307
|
+
if (!entry.isIntersecting)
|
|
5308
|
+
continue;
|
|
5309
|
+
this.checkLazyValidation();
|
|
5310
|
+
this.discardVisibilityObserver();
|
|
5311
|
+
}
|
|
5312
|
+
}, {
|
|
5313
|
+
root: this.host.validationEl?.parentElement,
|
|
5314
|
+
rootMargin: '0px',
|
|
5315
|
+
threshold: 0.01,
|
|
5316
|
+
});
|
|
5317
|
+
this.visibilityObserver.observe(this.host.validationEl);
|
|
5295
5318
|
});
|
|
5296
|
-
this.visibilityObserver.observe(this.host.el);
|
|
5297
5319
|
}
|
|
5298
5320
|
checkLazyValidation() {
|
|
5321
|
+
if (!this.elementLoaded)
|
|
5322
|
+
return;
|
|
5299
5323
|
if (!this.config?.reValidateOnPropChanges && (this.elementQueued || this.elementValidated))
|
|
5300
5324
|
return;
|
|
5325
|
+
if (!this.host.validationEl?.checkVisibility())
|
|
5326
|
+
return;
|
|
5301
5327
|
this.enqueueValidation();
|
|
5302
5328
|
}
|
|
5303
5329
|
enqueueValidation() {
|
|
@@ -5305,33 +5331,47 @@ class AriaValidationController {
|
|
|
5305
5331
|
return;
|
|
5306
5332
|
this.elementQueued = true;
|
|
5307
5333
|
queueValidation({
|
|
5308
|
-
context: { include: this.host.
|
|
5334
|
+
context: { include: this.host.validationEl, exclude: AriaValidationController.knownValidationErrors },
|
|
5309
5335
|
onComplete: (error, results) => {
|
|
5310
5336
|
this.elementValidated = true;
|
|
5337
|
+
const elementName = this.host.tagName || this.host.validationEl?.tagName || 'Element';
|
|
5311
5338
|
if (error) {
|
|
5312
|
-
console.error('Error running ARIA validation:', error);
|
|
5339
|
+
console.error('Error running ARIA validation:', error, elementName);
|
|
5340
|
+
if (!this.host.validationEl?.tagName) {
|
|
5341
|
+
console.dir(this.host);
|
|
5342
|
+
}
|
|
5313
5343
|
return;
|
|
5314
5344
|
}
|
|
5345
|
+
const message = [elementName];
|
|
5315
5346
|
if (!results?.violations.length) {
|
|
5316
|
-
if (this.
|
|
5317
|
-
console.log(
|
|
5347
|
+
if (this.useVerboseLogging) {
|
|
5348
|
+
console.log(...message, 'has no ARIA violations');
|
|
5349
|
+
if (!this.host.validationEl?.tagName) {
|
|
5350
|
+
console.dir(this.host);
|
|
5351
|
+
}
|
|
5318
5352
|
}
|
|
5319
5353
|
return;
|
|
5320
5354
|
}
|
|
5321
|
-
const
|
|
5322
|
-
|
|
5355
|
+
const count = results.violations.length;
|
|
5356
|
+
const label = [...message, results.violations.at(0).id, count > 1 ? `(+${count - 1} more)` : ''].filter(Boolean).join(' ');
|
|
5357
|
+
if (this.useVerboseLogging) {
|
|
5323
5358
|
console.group(label);
|
|
5324
5359
|
}
|
|
5325
5360
|
else {
|
|
5326
5361
|
console.groupCollapsed(label);
|
|
5327
5362
|
}
|
|
5328
|
-
const targets = results.violations.flatMap(violation => {
|
|
5363
|
+
const targets = results.violations.flatMap((violation) => {
|
|
5329
5364
|
console.dir(violation, { showHidden: true, compact: false });
|
|
5330
|
-
return violation.nodes.map(node => node.target);
|
|
5365
|
+
return violation.nodes.map((node) => node.target);
|
|
5331
5366
|
});
|
|
5332
|
-
|
|
5367
|
+
if (this.host.validationEl) {
|
|
5368
|
+
console.log('element:', this.host.validationEl);
|
|
5369
|
+
}
|
|
5370
|
+
else {
|
|
5371
|
+
console.dir(this.host);
|
|
5372
|
+
}
|
|
5333
5373
|
console.groupEnd();
|
|
5334
|
-
|
|
5374
|
+
AriaValidationController.knownValidationErrors.push(...targets);
|
|
5335
5375
|
},
|
|
5336
5376
|
});
|
|
5337
5377
|
}
|
|
@@ -5546,6 +5586,7 @@ const lmvzButtonCss = () => ` @layer lmvz-ds.reset, lmvz-ds.
|
|
|
5546
5586
|
|
|
5547
5587
|
class LmvzButton extends ReactiveControllerHost {
|
|
5548
5588
|
get el() { return getElement(this); }
|
|
5589
|
+
validationEl;
|
|
5549
5590
|
inheritedAttributes = {};
|
|
5550
5591
|
formEl = null;
|
|
5551
5592
|
formButtonEl = null;
|
|
@@ -5570,6 +5611,7 @@ class LmvzButton extends ReactiveControllerHost {
|
|
|
5570
5611
|
}
|
|
5571
5612
|
connectedCallback() {
|
|
5572
5613
|
this.inheritedAttributes = inheritAriaAttributes(this.el);
|
|
5614
|
+
super.connectedCallback();
|
|
5573
5615
|
}
|
|
5574
5616
|
renderHiddenButton() {
|
|
5575
5617
|
const formEl = (this.formEl = findFormByRef(this.form, this.el));
|
|
@@ -5597,7 +5639,7 @@ class LmvzButton extends ReactiveControllerHost {
|
|
|
5597
5639
|
};
|
|
5598
5640
|
render() {
|
|
5599
5641
|
this.renderHiddenButton();
|
|
5600
|
-
return (hAsync(Host, { key: '
|
|
5642
|
+
return (hAsync(Host, { key: '3f3eda78349322ce5160d7aac1290a73f0adcd4a', "aria-disabled": this.disabled ? 'true' : null }, hAsync("button", { key: 'b132404d8d5f5bf0fa7e845b562c953c5ceec36c', ref: (e) => (this.validationEl = e), disabled: this.disabled, class: classNames(this.variant, { [this.scale ?? '']: !!this.scale, disabled: this.disabled }), ...this.inheritedAttributes }, hAsync("slot", { key: 'ce63f7f1061ec9c3f10cbcfc67998ddbf3e04c3d' }))));
|
|
5601
5643
|
}
|
|
5602
5644
|
static get delegatesFocus() { return true; }
|
|
5603
5645
|
static get style() { return lmvzButtonCss(); }
|
|
@@ -5753,6 +5795,7 @@ const lmvzHeaderCss = () => `:host{display:flex;width:100vw;flex-direction:row;a
|
|
|
5753
5795
|
|
|
5754
5796
|
class LmvzHeader extends ReactiveControllerHost {
|
|
5755
5797
|
get el() { return getElement(this); }
|
|
5798
|
+
validationEl = this.el;
|
|
5756
5799
|
primarySlot;
|
|
5757
5800
|
secondarySlot;
|
|
5758
5801
|
secondaryNav;
|
|
@@ -5783,6 +5826,7 @@ class LmvzHeader extends ReactiveControllerHost {
|
|
|
5783
5826
|
this.primarySlot.addEventListener('slotchange', this.handlePrimaryNavItemsChange.bind(this));
|
|
5784
5827
|
this.handlePrimaryNavItemsChange();
|
|
5785
5828
|
this.secondarySlot.addEventListener('slotchange', this.handleSecondaryNavItemsChange.bind(this));
|
|
5829
|
+
super.componentDidLoad();
|
|
5786
5830
|
}
|
|
5787
5831
|
handlePrimaryNavItemsChange() {
|
|
5788
5832
|
const items = this.primaryMenuitems;
|
|
@@ -5790,7 +5834,7 @@ class LmvzHeader extends ReactiveControllerHost {
|
|
|
5790
5834
|
console.warn('Primary slot has no assigned elements. Please add navigation items to the primary slot.');
|
|
5791
5835
|
return;
|
|
5792
5836
|
}
|
|
5793
|
-
items.forEach(el => {
|
|
5837
|
+
items.forEach((el) => {
|
|
5794
5838
|
el.setAttribute('aria-haspopup', 'true');
|
|
5795
5839
|
el.setAttribute('aria-controls', `nav-secondary`);
|
|
5796
5840
|
});
|
|
@@ -5809,7 +5853,7 @@ class LmvzHeader extends ReactiveControllerHost {
|
|
|
5809
5853
|
updateElementsActive() {
|
|
5810
5854
|
const items = this.primaryMenuitems;
|
|
5811
5855
|
let label;
|
|
5812
|
-
items.forEach(el => {
|
|
5856
|
+
items.forEach((el) => {
|
|
5813
5857
|
const isActive = el.id === this.lmvzActiveNav;
|
|
5814
5858
|
if (isActive)
|
|
5815
5859
|
label = el.textContent || el.id;
|
|
@@ -5824,7 +5868,7 @@ class LmvzHeader extends ReactiveControllerHost {
|
|
|
5824
5868
|
}
|
|
5825
5869
|
}
|
|
5826
5870
|
render() {
|
|
5827
|
-
return (hAsync(Host, { key: '
|
|
5871
|
+
return (hAsync(Host, { key: '7c257913615a89b9be8f959b4dc43664ee474113', onFocus: this.delegateFocus.bind(this) }, hAsync("div", { key: '70f33263e629170d1b19cbfb1a00ca1adbbe91e0', class: 'brand' }, hAsync("slot", { key: 'd9c99c51da3210e5459684e59e66baf1622a8946', name: 'brand' }, hAsync("lmvz-icon", { key: '18bd0e88032c023d319bc3fac43c2b09d5098893', id: 'fallback-logo-lmvz', icon: 'Logo', size: 'inherit', "aria-label": 'Lehrmittelverlag Z\u00FCrich' }))), hAsync("nav", { key: 'c56a1e63344e42b1be26fe817705f0265bdb2bcf', "aria-label": 'Hauptnavigation' }, hAsync("div", { key: 'fbaebcb4857b0fba7b81cc35ef6092bb98ae89f8', role: 'menubar', class: 'primary-menubar' }, hAsync("slot", { key: '4a408eacbb41fa57d838581c18389241dce0e634', name: 'nav-primary', ref: (el) => (this.primarySlot = el) }), hAsync("div", { key: '6229842569958c724478c6aa15adc75b07d8417e', role: 'menu', id: 'nav-secondary', class: 'secondary-menubar', hidden: !this.lmvzActiveNav, ref: (el) => (this.secondaryNav = el) }, hAsync("slot", { key: '4dd4278eaa77cfc984e338da6bb1aa7321c6a545', name: this.secondarySlotName, ref: (el) => (this.secondarySlot = el) })))), hAsync("div", { key: '98b7802b0dc2dfe3a7a38bf89ae2b68994734396', class: 'actions' }, hAsync("slot", { key: '5f7682fe0ad34496b887baab7b19641a86c01acb', name: 'actions' }))));
|
|
5828
5872
|
}
|
|
5829
5873
|
static get watchers() { return {
|
|
5830
5874
|
"lmvzActiveNav": [{
|
|
@@ -9595,7 +9639,9 @@ const lmvzIconCss = () => `.sc-lmvz-icon-h{--lmvz-icon-color:var(--lmvz-componen
|
|
|
9595
9639
|
|
|
9596
9640
|
class LmvzIcon extends ReactiveControllerHost {
|
|
9597
9641
|
intersectionObserver;
|
|
9642
|
+
ariaValidationController = new AriaValidationController(this);
|
|
9598
9643
|
get el() { return getElement(this); }
|
|
9644
|
+
validationEl;
|
|
9599
9645
|
icon;
|
|
9600
9646
|
weight = 'medium';
|
|
9601
9647
|
size = 'md';
|
|
@@ -9608,27 +9654,34 @@ class LmvzIcon extends ReactiveControllerHost {
|
|
|
9608
9654
|
constructor(hostRef) {
|
|
9609
9655
|
super();
|
|
9610
9656
|
registerInstance(this, hostRef);
|
|
9611
|
-
this.addController(
|
|
9657
|
+
this.addController(this.ariaValidationController);
|
|
9612
9658
|
}
|
|
9613
9659
|
connectedCallback() {
|
|
9614
9660
|
this.waitUntilVisible(() => {
|
|
9615
9661
|
this.visible = true;
|
|
9616
9662
|
this.loadIconPathData();
|
|
9617
9663
|
});
|
|
9664
|
+
super.connectedCallback();
|
|
9618
9665
|
}
|
|
9619
9666
|
disconnectedCallback() {
|
|
9620
9667
|
if (this.intersectionObserver) {
|
|
9621
9668
|
this.intersectionObserver.disconnect();
|
|
9622
9669
|
this.intersectionObserver = null;
|
|
9623
9670
|
}
|
|
9671
|
+
super.disconnectedCallback();
|
|
9624
9672
|
}
|
|
9625
9673
|
async loadIconPathData() {
|
|
9626
9674
|
{
|
|
9627
9675
|
return;
|
|
9628
9676
|
}
|
|
9629
9677
|
}
|
|
9678
|
+
componentDidRender() {
|
|
9679
|
+
this.validationEl = this.el.querySelector('svg');
|
|
9680
|
+
this.ariaValidationController.revalidateAria();
|
|
9681
|
+
super.componentDidRender();
|
|
9682
|
+
}
|
|
9630
9683
|
render() {
|
|
9631
|
-
return hAsync(Host, { key: '
|
|
9684
|
+
return hAsync(Host, { key: '8b1ce550253e994650fe91de38496aff7c7eccc2', role: 'img', "aria-hidden": `${this.ariaHidden}`, innerHTML: this.iconData });
|
|
9632
9685
|
}
|
|
9633
9686
|
waitUntilVisible(callback, rootMargin = 50) {
|
|
9634
9687
|
{
|
|
@@ -9665,6 +9718,7 @@ const lmvzInputCss = () => `@layer lmvz-ds.reset, lmvz-ds.theme, lmvz-ds.compone
|
|
|
9665
9718
|
let inputIdCounter = 0;
|
|
9666
9719
|
class LmvzInput extends ReactiveControllerHost {
|
|
9667
9720
|
get el() { return getElement(this); }
|
|
9721
|
+
validationEl = this.el;
|
|
9668
9722
|
lmvzInput;
|
|
9669
9723
|
internals;
|
|
9670
9724
|
nativeInputElement;
|
|
@@ -9741,7 +9795,7 @@ class LmvzInput extends ReactiveControllerHost {
|
|
|
9741
9795
|
}
|
|
9742
9796
|
async getInputElement() {
|
|
9743
9797
|
if (!this.nativeInputElement) {
|
|
9744
|
-
await new Promise(resolve => componentOnReady(this.el, resolve));
|
|
9798
|
+
await new Promise((resolve) => componentOnReady(this.el, resolve));
|
|
9745
9799
|
}
|
|
9746
9800
|
return Promise.resolve(this.nativeInputElement);
|
|
9747
9801
|
}
|
|
@@ -9762,6 +9816,7 @@ class LmvzInput extends ReactiveControllerHost {
|
|
|
9762
9816
|
}
|
|
9763
9817
|
componentWillLoad() {
|
|
9764
9818
|
this.initialValue = this.value;
|
|
9819
|
+
super.componentWillLoad();
|
|
9765
9820
|
}
|
|
9766
9821
|
formAssociatedCallback(form) {
|
|
9767
9822
|
if (!form)
|
|
@@ -9810,9 +9865,9 @@ class LmvzInput extends ReactiveControllerHost {
|
|
|
9810
9865
|
render() {
|
|
9811
9866
|
const hasValue = Boolean(this.value);
|
|
9812
9867
|
const shouldFloatLabel = hasValue || Boolean(this.placeholder);
|
|
9813
|
-
return (hAsync("div", { key: '
|
|
9868
|
+
return (hAsync("div", { key: '79ab97e1e1d0217d5302ca1dea7087292ef19fc7', class: classNames('input-container', {
|
|
9814
9869
|
'interaction-filled': hasValue,
|
|
9815
|
-
}) }, hAsync("div", { key: '
|
|
9870
|
+
}) }, hAsync("div", { key: '9e59a33c261f610f93e1d6db3a07107f9300bbda', class: 'input-wrapper' }, hAsync("slot", { key: 'fadb3f5e49afa817014cdbd44774462b467827f4', name: 'before-input' }), hAsync("div", { key: '27d592787bb841fbd430c2e8ce0adc10f59b68ec', class: 'label-input-group' }, hAsync("label", { key: 'f83f154f356660ecafde254b5437ce6c42898b54', htmlFor: this.inputId, class: classNames({ floating: shouldFloatLabel }) }, this.label, this.required && (hAsync("span", { key: 'b51463179a2099ecd687ccd2480136379b0d0502', class: 'required-indicator', "aria-hidden": 'true' }, ' ', "*"))), hAsync("input", { key: '30d8308f286e82fba5d2ebdad972509c06294543', id: this.inputId, ref: (el) => (this.nativeInputElement = el), type: this.type, min: this.min, max: this.max, step: this.step, value: this.value, name: this.name, placeholder: this.placeholder, disabled: this.disabled, readOnly: this.readonly, required: this.required, form: this.form, autocomplete: this.autocomplete, inputmode: this.inputmode, autocorrect: this.autocorrect, autocapitalize: this.autocapitalize, spellcheck: this.spellcheck, autofocus: this.autofocus, minlength: this.minlength, maxlength: this.maxlength, pattern: this.pattern, "aria-invalid": this.error ? 'true' : 'false', "aria-required": this.required ? 'true' : 'false', "aria-describedby": this.describedBy, "aria-errormessage": this.errorId, onInput: this.handleInput, onChange: this.handleChange, onFocus: this.handleFocus, onBlur: this.handleBlur })), hAsync("slot", { key: 'a8448a0827ce24194b21b8281d2b54eb76f24652', name: 'after-input' })), hAsync("div", { key: '79413854b97380812c84f3128d1db053d4154008', id: this.helperId, role: 'status' }, this.helperText || null), hAsync("div", { key: 'd34c6b421688934b69917f6da1f9bb22c220a6f9', id: this.errorId, role: 'alert' }, (this.showErrorMessage && this.errorMessage) || null)));
|
|
9816
9871
|
}
|
|
9817
9872
|
static get formAssociated() { return true; }
|
|
9818
9873
|
static get watchers() { return {
|
|
@@ -9871,6 +9926,8 @@ const lmvzMenuitemCss = () => `@layer lmvz-ds.reset, lmvz-ds.theme, lmvz-ds.comp
|
|
|
9871
9926
|
|
|
9872
9927
|
class LmvzMenuItem extends ReactiveControllerHost {
|
|
9873
9928
|
get el() { return getElement(this); }
|
|
9929
|
+
validationEl = this.el;
|
|
9930
|
+
validationSlot;
|
|
9874
9931
|
get role() {
|
|
9875
9932
|
return 'menuitem';
|
|
9876
9933
|
}
|
|
@@ -9882,11 +9939,11 @@ class LmvzMenuItem extends ReactiveControllerHost {
|
|
|
9882
9939
|
super();
|
|
9883
9940
|
registerInstance(this, hostRef);
|
|
9884
9941
|
this.lmvzActivation = createEvent(this, "lmvzActivation");
|
|
9885
|
-
this.addController(new AriaValidationController(this));
|
|
9942
|
+
this.addController(new AriaValidationController(this, { validationTiming: 'slot' }));
|
|
9886
9943
|
this.addController(new ElementActivationController(this));
|
|
9887
9944
|
}
|
|
9888
9945
|
render() {
|
|
9889
|
-
return (hAsync(Host, { key: '
|
|
9946
|
+
return (hAsync(Host, { key: 'a022a198618ac628cb39c97b29cf0c332b522e79' }, hAsync("slot", { key: 'c8dab82b31b49db3d966cacb1cf9ef5cb1763797', ref: e => (this.validationSlot = e) })));
|
|
9890
9947
|
}
|
|
9891
9948
|
static get style() { return lmvzMenuitemCss(); }
|
|
9892
9949
|
static get cmpMeta() { return {
|