diff --git a/cdn/build/es6/node_modules/@haxtheweb/a11y-details/a11y-details.js b/cdn/build/es6/node_modules/@haxtheweb/a11y-details/a11y-details.js index 31258b95ec..8c91268e89 100644 --- a/cdn/build/es6/node_modules/@haxtheweb/a11y-details/a11y-details.js +++ b/cdn/build/es6/node_modules/@haxtheweb/a11y-details/a11y-details.js @@ -127,4 +127,4 @@ import{LitElement as e,html as t,css as s}from"../../lit/index.js";class A11yDet
- `}static get haxProperties(){return{canScale:!0,canEditSource:!0,gizmo:{title:"Accessible Details Button",description:"Accessible progressive disclosure with detail and summary",icon:"icons:arrow-drop-down",color:"grey",tags:["Layout","Details","Summary","Button","Accessible"],handles:[{type:""}],meta:{author:"HAXTheWeb core team",owner:"The Pennsylvania State University"}},settings:{configure:[{slot:"summary",title:"Button",description:'Summary of the content that if concealed, eg. "info", "medatadata", etc. ',inputMethod:"code-editor"},{slot:"details",title:"Decription",description:"Detailed description that can be hidden or shown",inputMethod:"code-editor"},{slot:"",title:"Decription Button",description:'Default for button that shows/hides description text, eg. "info", "medatadata", etc. ',inputMethod:"code-editor"}],advanced:[{property:"openText",title:"Optional summary text when details are open",inputMethod:"textfield",required:!1},{property:"closeText",title:"Optional summary text when details are closed",inputMethod:"textfield",required:!1}]},demoSchema:[{tag:"a11y-details",properties:{openText:"Show Aenean",closeText:"Hide Aenean"},content:'
Show Aenean
\n
Aenean eget nisl volutpat, molestie purus eget, bibendum metus. Pellentesque magna velit, tincidunt quis pharetra id, gravida placerat erat. Maecenas id dui pretium risus pulvinar feugiat vel nec leo. Praesent non congue tellus. Suspendisse ac tincidunt purus. Donec eu dui a metus vehicula bibendum sed nec tortor. Nunc convallis justo sed nibh consectetur, at pharetra nulla accumsan.\n
'}]}}static get properties(){return{...super.properties,closeText:{type:String,attribute:"close-text",reflect:!0},openText:{type:String,attribute:"open-text",reflect:!0}}}static get tag(){return"a11y-details"}constructor(){super(),this.closeText="",this.openText="",this.tag=A11yDetails.tag}disconnectedCallback(){this.observer&&this.observer.disconnect&&this.observer.disconnect(),super.disconnectedCallback()}firstUpdated(){super.firstUpdated&&super.firstUpdated(),this._updateElement(),this.observer.observe(this,{childList:!0,subtree:!0})}get details(){return this&&this.shadowRoot&&this.shadowRoot.querySelector("details")?this.shadowRoot.querySelector("details"):void 0}get summaryClasses(){return[this.openText&&this.openText.trim&&""!==this.openText.trim()?"has-open-text":"",this.closeText&&this.closeText.trim&&""!==this.closeText.trim()?"has-close-text":""].join(" ")}get observer(){return new MutationObserver((e=>this._watchChildren(e)))}get detailsObserver(){return new MutationObserver((()=>this._updateElement()))}_handleClick(e){this.details&&void 0===this.details.open&&(this.toggleOpen(),e.preventDefault(),e.stopPropagation())}_handleKeyup(e){(this.details&&void 0===this.details.open&&13==e.keyCode||32==e.keyCode)&&(this.toggleOpen(),e.preventDefault(),e.stopPropagation())}toggleOpen(){this.details.hasAttribute("open")?(this.details.removeAttribute("open"),this.details.open&&(this.details.open=!1)):(this.details.setAttribute("open",""),this.details.open&&(this.details.open=!0))}_updateElement(){let e=this.querySelector("* > details"),t=e?e.querySelector("* > summary"):void 0;if(t&&this._copyToSlot("summary",t.cloneNode(!0)),e){let t=e.cloneNode(!0),s=t.querySelectorAll("* > summary");Object.keys(s||{}).forEach((e=>s[e].remove())),this._copyToSlot("details",t,"div")}}_watchChildren(e){this._hasMutations(e)?(this._updateElement(),this.detailsObserver.observe(this.querySelector("* > details"),{childList:!0,subtree:!0,characterData:!0})):this._hasMutations(e,"removedNodes")&&!this.querySelector("* > details")&&this.detailsObserver.disconnect&&this.detailsObserver.disconnect()}_hasMutations(e,t="addedNodes"){return Object.keys(e||{}).filter((s=>{let a=e[s][t];return Object.keys(a||{}).filter((e=>"DETAILS"===a[e].tagName)).length>0})).length>0}_copyToSlot(e,t,s="span"){let a=Object.keys(t.childNodes||{}).filter((e=>{let s=t.childNodes[e];return!!s.tagName||s.textContent.trim().length>0})).map((e=>t.childNodes[parseInt(e)]));1===a.length&&a[0].tagName&&(s=(t=a[0]).tagName),this._getSlot(e,s).innerHTML=t.innerHTML,t.remove()}_getSlot(e,t="span"){let s=this.querySelector(`[slot=${e}]`);return s&&s.tagName!==t&&s.remove(),s||(s=document.createElement(t),s.slot=e,this.append(s)),s}}customElements.define("a11y-details",A11yDetails);export{A11yDetails}; \ No newline at end of file + `}static get haxProperties(){return{canScale:!0,canEditSource:!0,gizmo:{title:"Accessible Details Button",description:"Accessible progressive disclosure with detail and summary",icon:"icons:arrow-drop-down",color:"grey",tags:["Layout","Details","Summary","Button","Accessible"],handles:[{type:""}],meta:{author:"HAXTheWeb core team",owner:"The Pennsylvania State University"}},settings:{configure:[{slot:"summary",title:"Button",description:'Summary of the content that if concealed, eg. "info", "medatadata", etc. ',inputMethod:"code-editor"},{slot:"details",title:"Decription",description:"Detailed description that can be hidden or shown",inputMethod:"code-editor"},{slot:"",title:"Decription Button",description:'Default for button that shows/hides description text, eg. "info", "medatadata", etc. ',inputMethod:"code-editor"}],advanced:[{property:"openText",title:"Optional summary text when details are open",inputMethod:"textfield",required:!1},{property:"closeText",title:"Optional summary text when details are closed",inputMethod:"textfield",required:!1}]},demoSchema:[{tag:"a11y-details",properties:{openText:"Show Aenean",closeText:"Hide Aenean"},content:'
Show Aenean
\n
Aenean eget nisl volutpat, molestie purus eget, bibendum metus. Pellentesque magna velit, tincidunt quis pharetra id, gravida placerat erat. Maecenas id dui pretium risus pulvinar feugiat vel nec leo. Praesent non congue tellus. Suspendisse ac tincidunt purus. Donec eu dui a metus vehicula bibendum sed nec tortor. Nunc convallis justo sed nibh consectetur, at pharetra nulla accumsan.\n
'}]}}static get properties(){return{...super.properties,closeText:{type:String,attribute:"close-text",reflect:!0},openText:{type:String,attribute:"open-text",reflect:!0}}}static get tag(){return"a11y-details"}constructor(){super(),this.closeText="",this.openText="",this.tag=A11yDetails.tag}disconnectedCallback(){this.observer&&this.observer.disconnect&&this.observer.disconnect(),super.disconnectedCallback()}firstUpdated(){super.firstUpdated&&super.firstUpdated(),this._updateElement(),this.observer.observe(this,{childList:!0,subtree:!0})}get details(){return this&&this.shadowRoot&&this.shadowRoot.querySelector("details")?this.shadowRoot.querySelector("details"):void 0}get summaryClasses(){return[this.openText&&this.openText.trim&&""!==this.openText.trim()?"has-open-text":"",this.closeText&&this.closeText.trim&&""!==this.closeText.trim()?"has-close-text":""].join(" ")}get observer(){return new MutationObserver((e=>this._watchChildren(e)))}get detailsObserver(){return new MutationObserver((()=>this._updateElement()))}_handleClick(e){this.details&&void 0===this.details.open&&(this.toggleOpen(),e.preventDefault(),e.stopPropagation())}_handleKeyup(e){(this.details&&void 0===this.details.open&&13==e.keyCode||32==e.keyCode)&&(this.toggleOpen(),e.preventDefault(),e.stopPropagation())}toggleOpen(){this.details.hasAttribute("open")?(this.details.removeAttribute("open"),this.details.open&&(this.details.open=!1)):(this.details.setAttribute("open",""),this.details.open&&(this.details.open=!0))}_updateElement(){let e=this.querySelector("* > details"),t=e?e.querySelector("* > summary"):void 0;if(t&&this._copyToSlot("summary",t.cloneNode(!0)),e){let t=e.cloneNode(!0),s=t.querySelectorAll("* > summary");Object.keys(s||{}).forEach((e=>s[e].remove())),this._copyToSlot("details",t,"div")}}_watchChildren(e){this._hasMutations(e)?(this._updateElement(),this.detailsObserver.observe(this.querySelector("* > details"),{childList:!0,subtree:!0,characterData:!0})):this._hasMutations(e,"removedNodes")&&!this.querySelector("* > details")&&this.detailsObserver.disconnect&&this.detailsObserver.disconnect()}_hasMutations(e,t="addedNodes"){return Object.keys(e||{}).filter((s=>{let a=e[s][t];return Object.keys(a||{}).filter((e=>"DETAILS"===a[e].tagName)).length>0})).length>0}_copyToSlot(e,t,s="span"){let a=Object.keys(t.childNodes||{}).filter((e=>{let s=t.childNodes[e];return!!s.tagName||s.textContent.trim().length>0})).map((e=>t.childNodes[parseInt(e)]));1===a.length&&a[0].tagName&&(s=(t=a[0]).tagName),this._getSlot(e,s).innerHTML=t.innerHTML,t.remove()}_getSlot(e,t="span"){let s=this.querySelector(`[slot=${e}]`);return s&&s.tagName!==t&&s.remove(),s||(s=globalThis.document.createElement(t),s.slot=e,this.append(s)),s}}customElements.define("a11y-details",A11yDetails);export{A11yDetails}; \ No newline at end of file diff --git a/cdn/build/es6/node_modules/@haxtheweb/a11y-gif-player/a11y-gif-player.js b/cdn/build/es6/node_modules/@haxtheweb/a11y-gif-player/a11y-gif-player.js index b6bac952fa..ce52946926 100644 --- a/cdn/build/es6/node_modules/@haxtheweb/a11y-gif-player/a11y-gif-player.js +++ b/cdn/build/es6/node_modules/@haxtheweb/a11y-gif-player/a11y-gif-player.js @@ -2,7 +2,7 @@ * Copyright 2019 The Pennsylvania State University * @license Apache-2.0, see License.md for full text. */ -import{LitElement as t,html as i,css as e}from"../../lit/index.js";import{SchemaBehaviors as o}from"../schema-behaviors/schema-behaviors.js";import{IntersectionObserverMixin as r}from"../intersection-element/lib/IntersectionObserverMixin.js";import{I18NMixin as s}from"../i18n-manager/lib/I18NMixin.js";class A11yGifPlayer extends(s(r(o(t)))){constructor(){super(),this.windowControllers=new AbortController,this.__gifLoaded=!1,this.disabled=!1,this.__playing=!1,this._updateFromSlot(),this.t={toggleAnimation:"Toggle animation"},this.registerLocalization({context:this,basePath:import.meta.url,locales:["es"]})}static get styles(){return[e` +import{LitElement as t,html as i,css as e}from"../../lit/index.js";import{SchemaBehaviors as o}from"../schema-behaviors/schema-behaviors.js";import{IntersectionObserverMixin as s}from"../intersection-element/lib/IntersectionObserverMixin.js";import{I18NMixin as r}from"../i18n-manager/lib/I18NMixin.js";class A11yGifPlayer extends(r(s(o(t)))){constructor(){super(),this.windowControllers=new AbortController,this.__gifLoaded=!1,this.disabled=!1,this.__playing=!1,this._updateFromSlot(),this.t={toggleAnimation:"Toggle animation"},this.registerLocalization({context:this,basePath:import.meta.url,locales:["es"]})}static get styles(){return[e` :host { display: block; } @@ -127,4 +127,4 @@ import{LitElement as t,html as i,css as e}from"../../lit/index.js";import{Schema
${this.longdesc}
- `:""} `}static get tag(){return"a11y-gif-player"}static get properties(){return{...super.properties,alt:{type:String},disabled:{type:Boolean},describedBy:{attribute:"described-by",type:String},longdesc:{type:String,attribute:"longdesc"},src:{type:String},srcWithoutAnimation:{type:String,attribute:"src-without-animation"},__playing:{type:Boolean},__gifLoaded:{type:Boolean}}}updated(t){super.updated(t),t.forEach(((t,i)=>{"elementVisible"===i&&this[i]&&(import("../a11y-details/a11y-details.js"),this.shadowRoot&&!this.srcWithoutAnimation&&this.src&&import("../micro-frontend-registry/micro-frontend-registry.js").then((()=>{this._automaticStill=!0,this.srcWithoutAnimation=this.generateStill(this.src)}))),this.shadowRoot&&"src"===i&&this[i]&&this.elementVisible&&this._automaticStill&&(this.srcWithoutAnimation=this.generateStill(this.src))}))}generateStill(t){const i=window.MicroFrontendRegistry.requestAvailability();return i.enableServices(["core"]),i.url("@core/imgManipulate",{quality:50,src:t})}get observer(){return new MutationObserver((()=>this._updateFromSlot()))}connectedCallback(){super.connectedCallback&&super.connectedCallback(),this.observer.observe(this,{attributes:!1,childList:!0,subtree:!0}),window.addEventListener("beforeprint",(t=>{this.shadowRoot.querySelector("#longdesc").toggleOpen()}),{signal:this.windowControllers.signal}),window.addEventListener("afterprint",(t=>{this.shadowRoot.querySelector("#longdesc").toggleOpen()}),{signal:this.windowControllers.signal})}disconnectedCallback(){this.observer.disconnect(),this.windowControllers.abort(),super.disconnectedCallback&&super.disconnectedCallback()}play(){this.__playing=!0}stop(){this.__playing=!1}toggle(){this.__playing?this.stop():this.play()}toggleAnimation(){this.__playing?this.stop():this.play()}_updateFromSlot(){let t=this.querySelector("img");if(t){let i=t.src||null,e=t.alt||null;i&&(this.srcWithoutAnimation=i),e&&(this.alt=e)}if(t=this.querySelector("simple-img"),t){let i=t.srcconverted||null,e=t.alt||null;i&&(this.srcWithoutAnimation=i),e&&(this.alt=e)}}static get haxProperties(){return new URL(`./lib/${this.tag}.haxProperties.json`,import.meta.url).href}}customElements.define(A11yGifPlayer.tag,A11yGifPlayer);export{A11yGifPlayer}; \ No newline at end of file + `:""} `}static get tag(){return"a11y-gif-player"}static get properties(){return{...super.properties,alt:{type:String},disabled:{type:Boolean},describedBy:{attribute:"described-by",type:String},longdesc:{type:String,attribute:"longdesc"},src:{type:String},srcWithoutAnimation:{type:String,attribute:"src-without-animation"},__playing:{type:Boolean},__gifLoaded:{type:Boolean}}}updated(t){super.updated(t),t.forEach(((t,i)=>{"elementVisible"===i&&this[i]&&(import("../a11y-details/a11y-details.js"),this.shadowRoot&&!this.srcWithoutAnimation&&this.src&&import("../micro-frontend-registry/micro-frontend-registry.js").then((()=>{this._automaticStill=!0,this.srcWithoutAnimation=this.generateStill(this.src)}))),this.shadowRoot&&"src"===i&&this[i]&&this.elementVisible&&this._automaticStill&&(this.srcWithoutAnimation=this.generateStill(this.src))}))}generateStill(t){const i=globalThis.MicroFrontendRegistry.requestAvailability();return i.enableServices(["core"]),i.url("@core/imgManipulate",{quality:50,src:t})}get observer(){return new MutationObserver((()=>this._updateFromSlot()))}connectedCallback(){super.connectedCallback&&super.connectedCallback(),this.observer.observe(this,{attributes:!1,childList:!0,subtree:!0}),globalThis.addEventListener("beforeprint",(t=>{this.shadowRoot.querySelector("#longdesc").toggleOpen()}),{signal:this.windowControllers.signal}),globalThis.addEventListener("afterprint",(t=>{this.shadowRoot.querySelector("#longdesc").toggleOpen()}),{signal:this.windowControllers.signal})}disconnectedCallback(){this.observer.disconnect(),this.windowControllers.abort(),super.disconnectedCallback&&super.disconnectedCallback()}play(){this.__playing=!0}stop(){this.__playing=!1}toggle(){this.__playing?this.stop():this.play()}toggleAnimation(){this.__playing?this.stop():this.play()}_updateFromSlot(){if(this.querySelector){let t=this.querySelector("img");if(t){let i=t.src||null,e=t.alt||null;i&&(this.srcWithoutAnimation=i),e&&(this.alt=e)}if(t=this.querySelector("simple-img"),t){let i=t.srcconverted||null,e=t.alt||null;i&&(this.srcWithoutAnimation=i),e&&(this.alt=e)}}}static get haxProperties(){return new URL(`./lib/${this.tag}.haxProperties.json`,import.meta.url).href}}customElements.define(A11yGifPlayer.tag,A11yGifPlayer);export{A11yGifPlayer}; \ No newline at end of file diff --git a/cdn/build/es6/node_modules/@haxtheweb/a11y-tabs/a11y-tabs.js b/cdn/build/es6/node_modules/@haxtheweb/a11y-tabs/a11y-tabs.js index b6bddfe65b..d5e04422c1 100644 --- a/cdn/build/es6/node_modules/@haxtheweb/a11y-tabs/a11y-tabs.js +++ b/cdn/build/es6/node_modules/@haxtheweb/a11y-tabs/a11y-tabs.js @@ -279,7 +279,7 @@ import{LitElement as t,html as a,css as e}from"../../lit/index.js";import{Respon
-
`}static get haxProperties(){return new URL(`./lib/${this.tag}.haxProperties.json`,import.meta.url).href}static get properties(){return{...super.properties,ariaLabel:{type:String,reflect:!0,attribute:"aria-label"},activeTab:{type:String,reflect:!0,attribute:"active-tab"},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"},disabled:{type:Boolean,reflect:!0,attribute:"disabled"},hidden:{type:Boolean,reflect:!0,attribute:"hidden"},iconBreakpoint:{type:Number,attribute:"icon-breakpoint"},id:{type:String,reflect:!0},layoutBreakpoint:{type:Number,attribute:"layout-breakpoint"},responsiveSize:{type:String,reflect:!0,attribute:"responsive-size"},sticky:{type:Boolean,reflect:!0,attribute:"sticky"},__tabs:{type:Array},__tabButtons:{type:Array},__tabFocus:{type:Number}}}static get tag(){return"a11y-tabs"}constructor(){super(),this.fullWidth=!1,this.disableResponsive=!1,this.disabled=!1,this.hidden=!1,this.__tabs=[],this.__tabFocus=0,this.addEventListener("a11y-tab-changed",(t=>this.updateTabs()))}get buttons(){return this.__tabButtons}get iconsOnly(){return this.iconBreakpoint&&(this.tabs||[]).filter((t=>!t.icon)).length<1&&this.responsiveWidththis.updateTabs()))}get tabQuery(){return"a11y-tab"}get tabs(){return Object.keys(this.__tabs||{}).map((t=>(this.__tabs[t].order=t+1,this.__tabs[t].total=this.__tabs.length,this.__tabs[t])))}get vertical(){return this.layoutBreakpoint&&this.layoutBreakpoint{this.updateTabs()}),0)}disconnectedCallback(){this.observer&&this.observer.disconnect&&this.observer.disconnect(),super.disconnectedCallback()}updated(t){t.forEach(((t,a)=>{"id"===a&&this._idChanged(this.id,t),"activeTab"===a&&this.activeTab!==t&&this._activeTabChanged(this.activeTab,t),"responsiveWidth"===a&&(this.vertical?this.setAttribute("vertical",!0):this.removeAttribute("vertical")),["iconsBreakpoint","responsiveWidth","__tabs"].includes(a)&&(this.iconsOnly?this.setAttribute("icons-only",!0):this.removeAttribute("icons-only"))}))}selectTab(t){let a=this.querySelectorAll(this.tabQuery);if(a&&a.length>0){let e=Object.keys(a||[]).filter((t=>!a[t].disabled)).map((t=>a[t].id)),s=e.filter((a=>a===t))[0]||e[0];a.forEach((t=>{t.inactive=t.id!==s})),this.activeTab=s}}updateTabs(t){this.__tabs=this.querySelectorAll(this.tabQuery),this.__tabButtons=this.shadowRoot.querySelectorAll("[role=tab]"),this.selectTab(this.activeTab)}_activeTabChanged(t,a){t!==a&&this.selectTab(t),window.dispatchEvent(new CustomEvent("a11y-tabs-active-changed",{cancelable:!0,detail:this})),this.dispatchEvent(new CustomEvent("a11y-tabs-active-changed",{detail:this}))}_generateUUID(){return"ss-s-s-s-sss".replace(/s/g,Math.floor(65536*(1+Math.random())).toString(16).substring(1))}_handleTab(t){t.disabled||(this.activeTab=t.id)}_handleKey(t,a){0===this.buttons.length&&this.updateTabs(),this.__tabFocus=t;let focus=(a=1)=>{this.__tabFocus=this.__tabFocus+a,this.__tabFocus>=this.buttons.length?this.__tabFocus=0:this.__tabFocus<0&&(this.__tabFocus=this.buttons.length-1),this.buttons[this.__tabFocus].disabled&&this.__tabFocus!==t&&focus(a)};39!==a.keyCode&&37!==a.keyCode||(this.buttons[this.__tabFocus].setAttribute("tabindex",-1),focus(39===a.keyCode?1:-1),this.buttons[this.__tabFocus].disabled||(this.buttons[this.__tabFocus].setAttribute("tabindex",0),this.buttons[this.__tabFocus].focus()),a.preventDefault(),a.stopPropagation())}_idChanged(t,a){t||(this.id="a11y-tabs"+this._generateUUID())}_tabButton(t,e){return a` + `}static get haxProperties(){return new URL(`./lib/${this.tag}.haxProperties.json`,import.meta.url).href}static get properties(){return{...super.properties,ariaLabel:{type:String,reflect:!0,attribute:"aria-label"},activeTab:{type:String,reflect:!0,attribute:"active-tab"},fullWidth:{type:Boolean,reflect:!0,attribute:"full-width"},disabled:{type:Boolean,reflect:!0,attribute:"disabled"},hidden:{type:Boolean,reflect:!0,attribute:"hidden"},iconBreakpoint:{type:Number,attribute:"icon-breakpoint"},id:{type:String,reflect:!0},layoutBreakpoint:{type:Number,attribute:"layout-breakpoint"},responsiveSize:{type:String,reflect:!0,attribute:"responsive-size"},sticky:{type:Boolean,reflect:!0,attribute:"sticky"},__tabs:{type:Array},__tabButtons:{type:Array},__tabFocus:{type:Number}}}static get tag(){return"a11y-tabs"}constructor(){super(),this.fullWidth=!1,this.disableResponsive=!1,this.disabled=!1,this.hidden=!1,this.__tabs=[],this.__tabFocus=0,this.addEventListener("a11y-tab-changed",(t=>this.updateTabs()))}get buttons(){return this.__tabButtons}get iconsOnly(){return this.iconBreakpoint&&(this.tabs||[]).filter((t=>!t.icon)).length<1&&this.responsiveWidththis.updateTabs()))}get tabQuery(){return"a11y-tab"}get tabs(){return Object.keys(this.__tabs||{}).map((t=>(this.__tabs[t].order=t+1,this.__tabs[t].total=this.__tabs.length,this.__tabs[t])))}get vertical(){return this.layoutBreakpoint&&this.layoutBreakpoint{this.updateTabs()}),0)}disconnectedCallback(){this.observer&&this.observer.disconnect&&this.observer.disconnect(),super.disconnectedCallback()}updated(t){t.forEach(((t,a)=>{"id"===a&&this._idChanged(this.id,t),"activeTab"===a&&this.activeTab!==t&&this._activeTabChanged(this.activeTab,t),"responsiveWidth"===a&&(this.vertical?this.setAttribute("vertical",!0):this.removeAttribute("vertical")),["iconsBreakpoint","responsiveWidth","__tabs"].includes(a)&&(this.iconsOnly?this.setAttribute("icons-only",!0):this.removeAttribute("icons-only"))}))}selectTab(t){let a=this.querySelectorAll(this.tabQuery);if(a&&a.length>0){let e=Object.keys(a||[]).filter((t=>!a[t].disabled)).map((t=>a[t].id)),s=e.filter((a=>a===t))[0]||e[0];a.forEach((t=>{t.inactive=t.id!==s})),this.activeTab=s}}updateTabs(t){this.__tabs=this.querySelectorAll(this.tabQuery),this.__tabButtons=this.shadowRoot.querySelectorAll("[role=tab]"),this.selectTab(this.activeTab)}_activeTabChanged(t,a){t!==a&&this.selectTab(t),globalThis.dispatchEvent(new CustomEvent("a11y-tabs-active-changed",{cancelable:!0,detail:this})),this.dispatchEvent(new CustomEvent("a11y-tabs-active-changed",{detail:this}))}_generateUUID(){return"ss-s-s-s-sss".replace(/s/g,Math.floor(65536*(1+Math.random())).toString(16).substring(1))}_handleTab(t){t.disabled||(this.activeTab=t.id)}_handleKey(t,a){0===this.buttons.length&&this.updateTabs(),this.__tabFocus=t;let focus=(a=1)=>{this.__tabFocus=this.__tabFocus+a,this.__tabFocus>=this.buttons.length?this.__tabFocus=0:this.__tabFocus<0&&(this.__tabFocus=this.buttons.length-1),this.buttons[this.__tabFocus].disabled&&this.__tabFocus!==t&&focus(a)};39!==a.keyCode&&37!==a.keyCode||(this.buttons[this.__tabFocus].setAttribute("tabindex",-1),focus(39===a.keyCode?1:-1),this.buttons[this.__tabFocus].disabled||(this.buttons[this.__tabFocus].setAttribute("tabindex",0),this.buttons[this.__tabFocus].focus()),a.preventDefault(),a.stopPropagation())}_idChanged(t,a){t||(this.id="a11y-tabs"+this._generateUUID())}_tabButton(t,e){return a`