scb-wc-test 0.1.21 → 0.1.23
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/all.js +2 -2
- package/index.d.ts +1 -1
- package/index.js +1 -1
- package/mvc/components/all.js +1 -1
- package/mvc/components/scb-chip/scb-chip.js +48 -0
- package/mvc/components/scb-dialog/scb-dialog.js +2 -2
- package/mvc/components/scb-header/scb-header.js +9 -14
- package/mvc/components/scb-list/scb-list-item.js +7 -4
- package/mvc/components/scb-list/scb-list.js +11 -4
- package/package.json +6 -10
- package/{scb-chips → scb-chip}/scb-chip.d.ts +2 -0
- package/{scb-chips → scb-chip}/scb-chip.js +34 -24
- package/scb-dialog/scb-dialog.js +1 -1
- package/scb-header/scb-header.js +5 -10
- package/scb-list/scb-list-item.d.ts +1 -0
- package/scb-list/scb-list-item.js +9 -3
- package/scb-list/scb-list.d.ts +6 -0
- package/scb-list/scb-list.js +48 -38
- package/scb-wc-test.bundle.js +163 -156
- package/mvc/components/scb-chips/scb-chip.js +0 -46
package/scb-wc-test.bundle.js
CHANGED
|
@@ -6,11 +6,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
6
6
|
* @license
|
|
7
7
|
* Copyright 2019 Google LLC
|
|
8
8
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
9
|
-
*/const ar=globalThis,hi=ar.ShadowRoot&&(ar.ShadyCSS===void 0||ar.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,pi=Symbol(),
|
|
9
|
+
*/const ar=globalThis,hi=ar.ShadowRoot&&(ar.ShadyCSS===void 0||ar.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,pi=Symbol(),Po=new WeakMap;let Lo=class{constructor(e,t,r){if(this._$cssResult$=!0,r!==pi)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=e,this.t=t}get styleSheet(){let e=this.o;const t=this.t;if(hi&&e===void 0){const r=t!==void 0&&t.length===1;r&&(e=Po.get(t)),e===void 0&&((this.o=e=new CSSStyleSheet).replaceSync(this.cssText),r&&Po.set(t,e))}return e}toString(){return this.cssText}};const ws=o=>new Lo(typeof o=="string"?o:o+"",void 0,pi),f=(o,...e)=>{const t=o.length===1?o[0]:e.reduce((r,i,s)=>r+(n=>{if(n._$cssResult$===!0)return n.cssText;if(typeof n=="number")return n;throw Error("Value passed to 'css' function must be a 'css' function result: "+n+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+o[s+1],o[0]);return new Lo(t,o,pi)},Ss=(o,e)=>{if(hi)o.adoptedStyleSheets=e.map(t=>t instanceof CSSStyleSheet?t:t.styleSheet);else for(const t of e){const r=document.createElement("style"),i=ar.litNonce;i!==void 0&&r.setAttribute("nonce",i),r.textContent=t.cssText,o.appendChild(r)}},Do=hi?o=>o:o=>o instanceof CSSStyleSheet?(e=>{let t="";for(const r of e.cssRules)t+=r.cssText;return ws(t)})(o):o;/**
|
|
10
10
|
* @license
|
|
11
11
|
* Copyright 2017 Google LLC
|
|
12
12
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
13
|
-
*/const{is:ks,defineProperty:$s,getOwnPropertyDescriptor:Cs,getOwnPropertyNames:Es,getOwnPropertySymbols:As,getPrototypeOf:Is}=Object,
|
|
13
|
+
*/const{is:ks,defineProperty:$s,getOwnPropertyDescriptor:Cs,getOwnPropertyNames:Es,getOwnPropertySymbols:As,getPrototypeOf:Is}=Object,De=globalThis,Ro=De.trustedTypes,Ts=Ro?Ro.emptyScript:"",ui=De.reactiveElementPolyfillSupport,It=(o,e)=>o,sr={toAttribute(o,e){switch(e){case Boolean:o=o?Ts:null;break;case Object:case Array:o=o==null?o:JSON.stringify(o)}return o},fromAttribute(o,e){let t=o;switch(e){case Boolean:t=o!==null;break;case Number:t=o===null?null:Number(o);break;case Object:case Array:try{t=JSON.parse(o)}catch{t=null}}return t}},vi=(o,e)=>!ks(o,e),Bo={attribute:!0,type:String,converter:sr,reflect:!1,useDefault:!1,hasChanged:vi};Symbol.metadata??(Symbol.metadata=Symbol("metadata")),De.litPropertyMetadata??(De.litPropertyMetadata=new WeakMap);let ht=class extends HTMLElement{static addInitializer(e){this._$Ei(),(this.l??(this.l=[])).push(e)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(e,t=Bo){if(t.state&&(t.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(e)&&((t=Object.create(t)).wrapped=!0),this.elementProperties.set(e,t),!t.noAccessor){const r=Symbol(),i=this.getPropertyDescriptor(e,r,t);i!==void 0&&$s(this.prototype,e,i)}}static getPropertyDescriptor(e,t,r){const{get:i,set:s}=Cs(this.prototype,e)??{get(){return this[t]},set(n){this[t]=n}};return{get:i,set(n){const h=i==null?void 0:i.call(this);s==null||s.call(this,n),this.requestUpdate(e,h,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){return this.elementProperties.get(e)??Bo}static _$Ei(){if(this.hasOwnProperty(It("elementProperties")))return;const e=Is(this);e.finalize(),e.l!==void 0&&(this.l=[...e.l]),this.elementProperties=new Map(e.elementProperties)}static finalize(){if(this.hasOwnProperty(It("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(It("properties"))){const t=this.properties,r=[...Es(t),...As(t)];for(const i of r)this.createProperty(i,t[i])}const e=this[Symbol.metadata];if(e!==null){const t=litPropertyMetadata.get(e);if(t!==void 0)for(const[r,i]of t)this.elementProperties.set(r,i)}this._$Eh=new Map;for(const[t,r]of this.elementProperties){const i=this._$Eu(t,r);i!==void 0&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(e){const t=[];if(Array.isArray(e)){const r=new Set(e.flat(1/0).reverse());for(const i of r)t.unshift(Do(i))}else e!==void 0&&t.push(Do(e));return t}static _$Eu(e,t){const r=t.attribute;return r===!1?void 0:typeof r=="string"?r:typeof e=="string"?e.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var e;this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),(e=this.constructor.l)==null||e.forEach(t=>t(this))}addController(e){var t;(this._$EO??(this._$EO=new Set)).add(e),this.renderRoot!==void 0&&this.isConnected&&((t=e.hostConnected)==null||t.call(e))}removeController(e){var t;(t=this._$EO)==null||t.delete(e)}_$E_(){const e=new Map,t=this.constructor.elementProperties;for(const r of t.keys())this.hasOwnProperty(r)&&(e.set(r,this[r]),delete this[r]);e.size>0&&(this._$Ep=e)}createRenderRoot(){const e=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return Ss(e,this.constructor.elementStyles),e}connectedCallback(){var e;this.renderRoot??(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(e=this._$EO)==null||e.forEach(t=>{var r;return(r=t.hostConnected)==null?void 0:r.call(t)})}enableUpdating(e){}disconnectedCallback(){var e;(e=this._$EO)==null||e.forEach(t=>{var r;return(r=t.hostDisconnected)==null?void 0:r.call(t)})}attributeChangedCallback(e,t,r){this._$AK(e,r)}_$ET(e,t){var s;const r=this.constructor.elementProperties.get(e),i=this.constructor._$Eu(e,r);if(i!==void 0&&r.reflect===!0){const n=(((s=r.converter)==null?void 0:s.toAttribute)!==void 0?r.converter:sr).toAttribute(t,r.type);this._$Em=e,n==null?this.removeAttribute(i):this.setAttribute(i,n),this._$Em=null}}_$AK(e,t){var s,n;const r=this.constructor,i=r._$Eh.get(e);if(i!==void 0&&this._$Em!==i){const h=r.getPropertyOptions(i),u=typeof h.converter=="function"?{fromAttribute:h.converter}:((s=h.converter)==null?void 0:s.fromAttribute)!==void 0?h.converter:sr;this._$Em=i;const m=u.fromAttribute(t,h.type);this[i]=m??((n=this._$Ej)==null?void 0:n.get(i))??m,this._$Em=null}}requestUpdate(e,t,r){var i;if(e!==void 0){const s=this.constructor,n=this[e];if(r??(r=s.getPropertyOptions(e)),!((r.hasChanged??vi)(n,t)||r.useDefault&&r.reflect&&n===((i=this._$Ej)==null?void 0:i.get(e))&&!this.hasAttribute(s._$Eu(e,r))))return;this.C(e,t,r)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(e,t,{useDefault:r,reflect:i,wrapped:s},n){r&&!(this._$Ej??(this._$Ej=new Map)).has(e)&&(this._$Ej.set(e,n??t??this[e]),s!==!0||n!==void 0)||(this._$AL.has(e)||(this.hasUpdated||r||(t=void 0),this._$AL.set(e,t)),i===!0&&this._$Em!==e&&(this._$Eq??(this._$Eq=new Set)).add(e))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}const e=this.scheduleUpdate();return e!=null&&await e,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var r;if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??(this.renderRoot=this.createRenderRoot()),this._$Ep){for(const[s,n]of this._$Ep)this[s]=n;this._$Ep=void 0}const i=this.constructor.elementProperties;if(i.size>0)for(const[s,n]of i){const{wrapped:h}=n,u=this[s];h!==!0||this._$AL.has(s)||u===void 0||this.C(s,void 0,n,u)}}let e=!1;const t=this._$AL;try{e=this.shouldUpdate(t),e?(this.willUpdate(t),(r=this._$EO)==null||r.forEach(i=>{var s;return(s=i.hostUpdate)==null?void 0:s.call(i)}),this.update(t)):this._$EM()}catch(i){throw e=!1,this._$EM(),i}e&&this._$AE(t)}willUpdate(e){}_$AE(e){var t;(t=this._$EO)==null||t.forEach(r=>{var i;return(i=r.hostUpdated)==null?void 0:i.call(r)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(e){return!0}update(e){this._$Eq&&(this._$Eq=this._$Eq.forEach(t=>this._$ET(t,this[t]))),this._$EM()}updated(e){}firstUpdated(e){}};ht.elementStyles=[],ht.shadowRootOptions={mode:"open"},ht[It("elementProperties")]=new Map,ht[It("finalized")]=new Map,ui==null||ui({ReactiveElement:ht}),(De.reactiveElementVersions??(De.reactiveElementVersions=[])).push("2.1.1");/**
|
|
14
14
|
* @license
|
|
15
15
|
* Copyright 2017 Google LLC
|
|
16
16
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -34,7 +34,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
34
34
|
* @license
|
|
35
35
|
* Copyright 2017 Google LLC
|
|
36
36
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
37
|
-
*/function
|
|
37
|
+
*/function Mo(o){return(e,t)=>Tt(e,t,{async get(){var r;return await this.updateComplete,((r=this.renderRoot)==null?void 0:r.querySelector(o))??null}})}/**
|
|
38
38
|
* @license
|
|
39
39
|
* Copyright 2021 Google LLC
|
|
40
40
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -46,9 +46,9 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
46
46
|
* @license
|
|
47
47
|
* Copyright 2017 Google LLC
|
|
48
48
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
49
|
-
*/const zt=globalThis,nr=zt.trustedTypes,
|
|
50
|
-
\f\r]`,Lt=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,
|
|
51
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),
|
|
49
|
+
*/const zt=globalThis,nr=zt.trustedTypes,Fo=nr?nr.createPolicy("lit-html",{createHTML:o=>o}):void 0,Ho="$lit$",Re=`lit$${Math.random().toFixed(9).slice(2)}$`,No="?"+Re,Ds=`<${No}>`,Xe=document,Ot=()=>Xe.createComment(""),Pt=o=>o===null||typeof o!="object"&&typeof o!="function",mi=Array.isArray,Rs=o=>mi(o)||typeof(o==null?void 0:o[Symbol.iterator])=="function",bi=`[
|
|
50
|
+
\f\r]`,Lt=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,qo=/-->/g,Vo=/>/g,Ze=RegExp(`>|${bi}(?:([^\\s"'>=/]+)(${bi}*=${bi}*(?:[^
|
|
51
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),Uo=/'/g,jo=/"/g,Wo=/^(?:script|style|textarea|title)$/i,Bs=o=>(e,...t)=>({_$litType$:o,strings:e,values:t}),c=Bs(1),oe=Symbol.for("lit-noChange"),p=Symbol.for("lit-nothing"),Go=new WeakMap,Je=Xe.createTreeWalker(Xe,129);function Ko(o,e){if(!mi(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return Fo!==void 0?Fo.createHTML(e):e}const Ms=(o,e)=>{const t=o.length-1,r=[];let i,s=e===2?"<svg>":e===3?"<math>":"",n=Lt;for(let h=0;h<t;h++){const u=o[h];let m,y,v=-1,x=0;for(;x<u.length&&(n.lastIndex=x,y=n.exec(u),y!==null);)x=n.lastIndex,n===Lt?y[1]==="!--"?n=qo:y[1]!==void 0?n=Vo:y[2]!==void 0?(Wo.test(y[2])&&(i=RegExp("</"+y[2],"g")),n=Ze):y[3]!==void 0&&(n=Ze):n===Ze?y[0]===">"?(n=i??Lt,v=-1):y[1]===void 0?v=-2:(v=n.lastIndex-y[2].length,m=y[1],n=y[3]===void 0?Ze:y[3]==='"'?jo:Uo):n===jo||n===Uo?n=Ze:n===qo||n===Vo?n=Lt:(n=Ze,i=void 0);const _=n===Ze&&o[h+1].startsWith("/>")?" ":"";s+=n===Lt?u+Ds:v>=0?(r.push(m),u.slice(0,v)+Ho+u.slice(v)+Re+_):u+Re+(v===-2?h:_)}return[Ko(o,s+(o[t]||"<?>")+(e===2?"</svg>":e===3?"</math>":"")),r]};class Dt{constructor({strings:e,_$litType$:t},r){let i;this.parts=[];let s=0,n=0;const h=e.length-1,u=this.parts,[m,y]=Ms(e,t);if(this.el=Dt.createElement(m,r),Je.currentNode=this.el.content,t===2||t===3){const v=this.el.content.firstChild;v.replaceWith(...v.childNodes)}for(;(i=Je.nextNode())!==null&&u.length<h;){if(i.nodeType===1){if(i.hasAttributes())for(const v of i.getAttributeNames())if(v.endsWith(Ho)){const x=y[n++],_=i.getAttribute(v).split(Re),S=/([.?@])?(.*)/.exec(x);u.push({type:1,index:s,name:S[2],strings:_,ctor:S[1]==="."?Hs:S[1]==="?"?Ns:S[1]==="@"?qs:lr}),i.removeAttribute(v)}else v.startsWith(Re)&&(u.push({type:6,index:s}),i.removeAttribute(v));if(Wo.test(i.tagName)){const v=i.textContent.split(Re),x=v.length-1;if(x>0){i.textContent=nr?nr.emptyScript:"";for(let _=0;_<x;_++)i.append(v[_],Ot()),Je.nextNode(),u.push({type:2,index:++s});i.append(v[x],Ot())}}}else if(i.nodeType===8)if(i.data===No)u.push({type:2,index:s});else{let v=-1;for(;(v=i.data.indexOf(Re,v+1))!==-1;)u.push({type:7,index:s}),v+=Re.length-1}s++}}static createElement(e,t){const r=Xe.createElement("template");return r.innerHTML=e,r}}function pt(o,e,t=o,r){var n,h;if(e===oe)return e;let i=r!==void 0?(n=t._$Co)==null?void 0:n[r]:t._$Cl;const s=Pt(e)?void 0:e._$litDirective$;return(i==null?void 0:i.constructor)!==s&&((h=i==null?void 0:i._$AO)==null||h.call(i,!1),s===void 0?i=void 0:(i=new s(o),i._$AT(o,t,r)),r!==void 0?(t._$Co??(t._$Co=[]))[r]=i:t._$Cl=i),i!==void 0&&(e=pt(o,i._$AS(o,e.values),i,r)),e}class Fs{constructor(e,t){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=t}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){const{el:{content:t},parts:r}=this._$AD,i=((e==null?void 0:e.creationScope)??Xe).importNode(t,!0);Je.currentNode=i;let s=Je.nextNode(),n=0,h=0,u=r[0];for(;u!==void 0;){if(n===u.index){let m;u.type===2?m=new Rt(s,s.nextSibling,this,e):u.type===1?m=new u.ctor(s,u.name,u.strings,this,e):u.type===6&&(m=new Vs(s,this,e)),this._$AV.push(m),u=r[++h]}n!==(u==null?void 0:u.index)&&(s=Je.nextNode(),n++)}return Je.currentNode=Xe,i}p(e){let t=0;for(const r of this._$AV)r!==void 0&&(r.strings!==void 0?(r._$AI(e,r,t),t+=r.strings.length-2):r._$AI(e[t])),t++}}class Rt{get _$AU(){var e;return((e=this._$AM)==null?void 0:e._$AU)??this._$Cv}constructor(e,t,r,i){this.type=2,this._$AH=p,this._$AN=void 0,this._$AA=e,this._$AB=t,this._$AM=r,this.options=i,this._$Cv=(i==null?void 0:i.isConnected)??!0}get parentNode(){let e=this._$AA.parentNode;const t=this._$AM;return t!==void 0&&(e==null?void 0:e.nodeType)===11&&(e=t.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,t=this){e=pt(this,e,t),Pt(e)?e===p||e==null||e===""?(this._$AH!==p&&this._$AR(),this._$AH=p):e!==this._$AH&&e!==oe&&this._(e):e._$litType$!==void 0?this.$(e):e.nodeType!==void 0?this.T(e):Rs(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==p&&Pt(this._$AH)?this._$AA.nextSibling.data=e:this.T(Xe.createTextNode(e)),this._$AH=e}$(e){var s;const{values:t,_$litType$:r}=e,i=typeof r=="number"?this._$AC(e):(r.el===void 0&&(r.el=Dt.createElement(Ko(r.h,r.h[0]),this.options)),r);if(((s=this._$AH)==null?void 0:s._$AD)===i)this._$AH.p(t);else{const n=new Fs(i,this),h=n.u(this.options);n.p(t),this.T(h),this._$AH=n}}_$AC(e){let t=Go.get(e.strings);return t===void 0&&Go.set(e.strings,t=new Dt(e)),t}k(e){mi(this._$AH)||(this._$AH=[],this._$AR());const t=this._$AH;let r,i=0;for(const s of e)i===t.length?t.push(r=new Rt(this.O(Ot()),this.O(Ot()),this,this.options)):r=t[i],r._$AI(s),i++;i<t.length&&(this._$AR(r&&r._$AB.nextSibling,i),t.length=i)}_$AR(e=this._$AA.nextSibling,t){var r;for((r=this._$AP)==null?void 0:r.call(this,!1,!0,t);e!==this._$AB;){const i=e.nextSibling;e.remove(),e=i}}setConnected(e){var t;this._$AM===void 0&&(this._$Cv=e,(t=this._$AP)==null||t.call(this,e))}}class lr{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,t,r,i,s){this.type=1,this._$AH=p,this._$AN=void 0,this.element=e,this.name=t,this._$AM=i,this.options=s,r.length>2||r[0]!==""||r[1]!==""?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=p}_$AI(e,t=this,r,i){const s=this.strings;let n=!1;if(s===void 0)e=pt(this,e,t,0),n=!Pt(e)||e!==this._$AH&&e!==oe,n&&(this._$AH=e);else{const h=e;let u,m;for(e=s[0],u=0;u<s.length-1;u++)m=pt(this,h[r+u],t,u),m===oe&&(m=this._$AH[u]),n||(n=!Pt(m)||m!==this._$AH[u]),m===p?e=p:e!==p&&(e+=(m??"")+s[u+1]),this._$AH[u]=m}n&&!i&&this.j(e)}j(e){e===p?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,e??"")}}class Hs extends lr{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===p?void 0:e}}class Ns extends lr{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==p)}}class qs extends lr{constructor(e,t,r,i,s){super(e,t,r,i,s),this.type=5}_$AI(e,t=this){if((e=pt(this,e,t,0)??p)===oe)return;const r=this._$AH,i=e===p&&r!==p||e.capture!==r.capture||e.once!==r.once||e.passive!==r.passive,s=e!==p&&(r===p||i);i&&this.element.removeEventListener(this.name,this,r),s&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){var t;typeof this._$AH=="function"?this._$AH.call(((t=this.options)==null?void 0:t.host)??this.element,e):this._$AH.handleEvent(e)}}class Vs{constructor(e,t,r){this.element=e,this.type=6,this._$AN=void 0,this._$AM=t,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(e){pt(this,e)}}const gi=zt.litHtmlPolyfillSupport;gi==null||gi(Dt,Rt),(zt.litHtmlVersions??(zt.litHtmlVersions=[])).push("3.3.1");const yi=(o,e,t)=>{const r=(t==null?void 0:t.renderBefore)??e;let i=r._$litPart$;if(i===void 0){const s=(t==null?void 0:t.renderBefore)??null;r._$litPart$=i=new Rt(e.insertBefore(Ot(),s),s,void 0,t??{})}return i._$AI(o),i};/**
|
|
52
52
|
* @license
|
|
53
53
|
* Copyright 2017 Google LLC
|
|
54
54
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -69,11 +69,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
69
69
|
* @license
|
|
70
70
|
* Copyright 2023 Google LLC
|
|
71
71
|
* SPDX-License-Identifier: Apache-2.0
|
|
72
|
-
*/const
|
|
72
|
+
*/const Yo=Symbol("attachableController");let cr;cr=new MutationObserver(o=>{var e;for(const t of o)(e=t.target[Yo])==null||e.hostConnected()});class Xo{get htmlFor(){return this.host.getAttribute("for")}set htmlFor(e){e===null?this.host.removeAttribute("for"):this.host.setAttribute("for",e)}get control(){return this.host.hasAttribute("for")?!this.htmlFor||!this.host.isConnected?null:this.host.getRootNode().querySelector(`#${this.htmlFor}`):this.currentControl||this.host.parentElement}set control(e){e?this.attach(e):this.detach()}constructor(e,t){this.host=e,this.onControlChange=t,this.currentControl=null,e.addController(this),e[Yo]=this,cr==null||cr.observe(e,{attributeFilter:["for"]})}attach(e){e!==this.currentControl&&(this.setCurrentControl(e),this.host.removeAttribute("for"))}detach(){this.setCurrentControl(null),this.host.setAttribute("for","")}hostConnected(){this.setCurrentControl(this.control)}hostDisconnected(){this.setCurrentControl(null)}setCurrentControl(e){this.onControlChange(this.currentControl,e),this.currentControl=e}}/**
|
|
73
73
|
* @license
|
|
74
74
|
* Copyright 2021 Google LLC
|
|
75
75
|
* SPDX-License-Identifier: Apache-2.0
|
|
76
|
-
*/const Ws=["focusin","focusout","pointerdown"];class wi extends g{constructor(){super(...arguments),this.visible=!1,this.inward=!1,this.attachableController=new
|
|
76
|
+
*/const Ws=["focusin","focusout","pointerdown"];class wi extends g{constructor(){super(...arguments),this.visible=!1,this.inward=!1,this.attachableController=new Xo(this,this.onControlChange.bind(this))}get htmlFor(){return this.attachableController.htmlFor}set htmlFor(e){this.attachableController.htmlFor=e}get control(){return this.attachableController.control}set control(e){this.attachableController.control=e}attach(e){this.attachableController.attach(e)}detach(){this.attachableController.detach()}connectedCallback(){super.connectedCallback(),this.setAttribute("aria-hidden","true")}handleEvent(e){var t;if(!e[Zo]){switch(e.type){default:return;case"focusin":this.visible=((t=this.control)==null?void 0:t.matches(":focus-visible"))??!1;break;case"focusout":case"pointerdown":this.visible=!1;break}e[Zo]=!0}}onControlChange(e,t){for(const r of Ws)e==null||e.removeEventListener(r,this),t==null||t.addEventListener(r,this)}update(e){e.has("visible")&&this.dispatchEvent(new Event("visibility-changed")),super.update(e)}}d([l({type:Boolean,reflect:!0})],wi.prototype,"visible",void 0),d([l({type:Boolean,reflect:!0})],wi.prototype,"inward",void 0);const Zo=Symbol("handledByFocusRing");/**
|
|
77
77
|
* @license
|
|
78
78
|
* Copyright 2024 Google LLC
|
|
79
79
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -86,11 +86,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
86
86
|
* @license
|
|
87
87
|
* Copyright 2017 Google LLC
|
|
88
88
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
89
|
-
*/const
|
|
89
|
+
*/const Be={ATTRIBUTE:1,PROPERTY:3,BOOLEAN_ATTRIBUTE:4},Si=o=>(...e)=>({_$litDirective$:o,values:e});let ki=class{constructor(e){}get _$AU(){return this._$AM._$AU}_$AT(e,t,r){this._$Ct=e,this._$AM=t,this._$Ci=r}_$AS(e,t){return this.update(e,t)}update(e,t){return this.render(...t)}};/**
|
|
90
90
|
* @license
|
|
91
91
|
* Copyright 2018 Google LLC
|
|
92
92
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
93
|
-
*/const P=Si(class extends ki{constructor(o){var e;if(super(o),o.type!==
|
|
93
|
+
*/const P=Si(class extends ki{constructor(o){var e;if(super(o),o.type!==Be.ATTRIBUTE||o.name!=="class"||((e=o.strings)==null?void 0:e.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(e=>o[e]).join(" ")+" "}update(o,[e]){var r,i;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(const s in e)e[s]&&!((r=this.nt)!=null&&r.has(s))&&this.st.add(s);return this.render(e)}const t=o.element.classList;for(const s of this.st)s in e||(t.remove(s),this.st.delete(s));for(const s in e){const n=!!e[s];n===this.st.has(s)||(i=this.nt)!=null&&i.has(s)||(n?(t.add(s),this.st.add(s)):(t.remove(s),this.st.delete(s)))}return oe}});/**
|
|
94
94
|
* @license
|
|
95
95
|
* Copyright 2021 Google LLC
|
|
96
96
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -98,7 +98,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
98
98
|
* @license
|
|
99
99
|
* Copyright 2022 Google LLC
|
|
100
100
|
* SPDX-License-Identifier: Apache-2.0
|
|
101
|
-
*/const Xs=450,
|
|
101
|
+
*/const Xs=450,Jo=225,Zs=.2,Js=10,Qs=75,en=.35,tn="::after",rn="forwards";var G;(function(o){o[o.INACTIVE=0]="INACTIVE",o[o.TOUCH_DELAY=1]="TOUCH_DELAY",o[o.HOLDING=2]="HOLDING",o[o.WAITING_FOR_CLICK=3]="WAITING_FOR_CLICK"})(G||(G={}));const on=["click","contextmenu","pointercancel","pointerdown","pointerenter","pointerleave","pointerup"],an=150,$i=window.matchMedia("(forced-colors: active)");class Bt extends g{constructor(){super(...arguments),this.disabled=!1,this.hovered=!1,this.pressed=!1,this.rippleSize="",this.rippleScale="",this.initialSize=0,this.state=G.INACTIVE,this.checkBoundsAfterContextMenu=!1,this.attachableController=new Xo(this,this.onControlChange.bind(this))}get htmlFor(){return this.attachableController.htmlFor}set htmlFor(e){this.attachableController.htmlFor=e}get control(){return this.attachableController.control}set control(e){this.attachableController.control=e}attach(e){this.attachableController.attach(e)}detach(){this.attachableController.detach()}connectedCallback(){super.connectedCallback(),this.setAttribute("aria-hidden","true")}render(){const e={hovered:this.hovered,pressed:this.pressed};return c`<div class="surface ${P(e)}"></div>`}update(e){e.has("disabled")&&this.disabled&&(this.hovered=!1,this.pressed=!1),super.update(e)}handlePointerenter(e){this.shouldReactToEvent(e)&&(this.hovered=!0)}handlePointerleave(e){this.shouldReactToEvent(e)&&(this.hovered=!1,this.state!==G.INACTIVE&&this.endPressAnimation())}handlePointerup(e){if(this.shouldReactToEvent(e)){if(this.state===G.HOLDING){this.state=G.WAITING_FOR_CLICK;return}if(this.state===G.TOUCH_DELAY){this.state=G.WAITING_FOR_CLICK,this.startPressAnimation(this.rippleStartEvent);return}}}async handlePointerdown(e){if(this.shouldReactToEvent(e)){if(this.rippleStartEvent=e,!this.isTouch(e)){this.state=G.WAITING_FOR_CLICK,this.startPressAnimation(e);return}this.checkBoundsAfterContextMenu&&!this.inBounds(e)||(this.checkBoundsAfterContextMenu=!1,this.state=G.TOUCH_DELAY,await new Promise(t=>{setTimeout(t,an)}),this.state===G.TOUCH_DELAY&&(this.state=G.HOLDING,this.startPressAnimation(e)))}}handleClick(){if(!this.disabled){if(this.state===G.WAITING_FOR_CLICK){this.endPressAnimation();return}this.state===G.INACTIVE&&(this.startPressAnimation(),this.endPressAnimation())}}handlePointercancel(e){this.shouldReactToEvent(e)&&this.endPressAnimation()}handleContextmenu(){this.disabled||(this.checkBoundsAfterContextMenu=!0,this.endPressAnimation())}determineRippleSize(){const{height:e,width:t}=this.getBoundingClientRect(),r=Math.max(e,t),i=Math.max(en*r,Qs),s=Math.floor(r*Zs),h=Math.sqrt(t**2+e**2)+Js;this.initialSize=s,this.rippleScale=`${(h+i)/s}`,this.rippleSize=`${s}px`}getNormalizedPointerEventCoords(e){const{scrollX:t,scrollY:r}=window,{left:i,top:s}=this.getBoundingClientRect(),n=t+i,h=r+s,{pageX:u,pageY:m}=e;return{x:u-n,y:m-h}}getTranslationCoordinates(e){const{height:t,width:r}=this.getBoundingClientRect(),i={x:(r-this.initialSize)/2,y:(t-this.initialSize)/2};let s;return e instanceof PointerEvent?s=this.getNormalizedPointerEventCoords(e):s={x:r/2,y:t/2},s={x:s.x-this.initialSize/2,y:s.y-this.initialSize/2},{startPoint:s,endPoint:i}}startPressAnimation(e){var n;if(!this.mdRoot)return;this.pressed=!0,(n=this.growAnimation)==null||n.cancel(),this.determineRippleSize();const{startPoint:t,endPoint:r}=this.getTranslationCoordinates(e),i=`${t.x}px, ${t.y}px`,s=`${r.x}px, ${r.y}px`;this.growAnimation=this.mdRoot.animate({top:[0,0],left:[0,0],height:[this.rippleSize,this.rippleSize],width:[this.rippleSize,this.rippleSize],transform:[`translate(${i}) scale(1)`,`translate(${s}) scale(${this.rippleScale})`]},{pseudoElement:tn,duration:Xs,easing:de.STANDARD,fill:rn})}async endPressAnimation(){this.rippleStartEvent=void 0,this.state=G.INACTIVE;const e=this.growAnimation;let t=1/0;if(typeof(e==null?void 0:e.currentTime)=="number"?t=e.currentTime:e!=null&&e.currentTime&&(t=e.currentTime.to("ms").value),t>=Jo){this.pressed=!1;return}await new Promise(r=>{setTimeout(r,Jo-t)}),this.growAnimation===e&&(this.pressed=!1)}shouldReactToEvent(e){if(this.disabled||!e.isPrimary||this.rippleStartEvent&&this.rippleStartEvent.pointerId!==e.pointerId)return!1;if(e.type==="pointerenter"||e.type==="pointerleave")return!this.isTouch(e);const t=e.buttons===1;return this.isTouch(e)||t}inBounds({x:e,y:t}){const{top:r,left:i,bottom:s,right:n}=this.getBoundingClientRect();return e>=i&&e<=n&&t>=r&&t<=s}isTouch({pointerType:e}){return e==="touch"}async handleEvent(e){if(!($i!=null&&$i.matches))switch(e.type){case"click":this.handleClick();break;case"contextmenu":this.handleContextmenu();break;case"pointercancel":this.handlePointercancel(e);break;case"pointerdown":await this.handlePointerdown(e);break;case"pointerenter":this.handlePointerenter(e);break;case"pointerleave":this.handlePointerleave(e);break;case"pointerup":this.handlePointerup(e);break}}onControlChange(e,t){for(const r of on)e==null||e.removeEventListener(r,this),t==null||t.addEventListener(r,this)}}d([l({type:Boolean,reflect:!0})],Bt.prototype,"disabled",void 0),d([w()],Bt.prototype,"hovered",void 0),d([w()],Bt.prototype,"pressed",void 0),d([k(".surface")],Bt.prototype,"mdRoot",void 0);/**
|
|
102
102
|
* @license
|
|
103
103
|
* Copyright 2024 Google LLC
|
|
104
104
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -111,19 +111,19 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
111
111
|
* @license
|
|
112
112
|
* Copyright 2023 Google LLC
|
|
113
113
|
* SPDX-License-Identifier: Apache-2.0
|
|
114
|
-
*/const
|
|
114
|
+
*/const Qo=["role","ariaAtomic","ariaAutoComplete","ariaBusy","ariaChecked","ariaColCount","ariaColIndex","ariaColSpan","ariaCurrent","ariaDisabled","ariaExpanded","ariaHasPopup","ariaHidden","ariaInvalid","ariaKeyShortcuts","ariaLabel","ariaLevel","ariaLive","ariaModal","ariaMultiLine","ariaMultiSelectable","ariaOrientation","ariaPlaceholder","ariaPosInSet","ariaPressed","ariaReadOnly","ariaRequired","ariaRoleDescription","ariaRowCount","ariaRowIndex","ariaRowSpan","ariaSelected","ariaSetSize","ariaSort","ariaValueMax","ariaValueMin","ariaValueNow","ariaValueText"];Qo.map(ea);function ea(o){return o.replace("aria","aria-").replace(/Elements?/g,"").toLowerCase()}/**
|
|
115
115
|
* @license
|
|
116
116
|
* Copyright 2023 Google LLC
|
|
117
117
|
* SPDX-License-Identifier: Apache-2.0
|
|
118
|
-
*/function Y(o){for(const e of
|
|
118
|
+
*/function Y(o){for(const e of Qo)o.createProperty(e,{attribute:ea(e),reflect:!0});o.addInitializer(e=>{const t={hostConnected(){e.setAttribute("role","presentation")}};e.addController(t)})}/**
|
|
119
119
|
* @license
|
|
120
120
|
* Copyright 2023 Google LLC
|
|
121
121
|
* SPDX-License-Identifier: Apache-2.0
|
|
122
|
-
*/const V=Symbol("internals"),Ci=Symbol("privateInternals");function
|
|
122
|
+
*/const V=Symbol("internals"),Ci=Symbol("privateInternals");function Me(o){class e extends o{get[V](){return this[Ci]||(this[Ci]=this.attachInternals()),this[Ci]}}return e}/**
|
|
123
123
|
* @license
|
|
124
124
|
* Copyright 2023 Google LLC
|
|
125
125
|
* SPDX-License-Identifier: Apache-2.0
|
|
126
|
-
*/function
|
|
126
|
+
*/function ta(o){o.addInitializer(e=>{const t=e;t.addEventListener("click",async r=>{const{type:i,[V]:s}=t,{form:n}=s;if(!(!n||i==="button")&&(await new Promise(h=>{setTimeout(h)}),!r.defaultPrevented)){if(i==="reset"){n.reset();return}n.addEventListener("submit",h=>{Object.defineProperty(h,"submitter",{configurable:!0,enumerable:!0,get:()=>t})},{capture:!0,once:!0}),s.setFormValue(t.value),n.requestSubmit()}})})}/**
|
|
127
127
|
* @license
|
|
128
128
|
* Copyright 2021 Google LLC
|
|
129
129
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -131,7 +131,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
131
131
|
* @license
|
|
132
132
|
* Copyright 2019 Google LLC
|
|
133
133
|
* SPDX-License-Identifier: Apache-2.0
|
|
134
|
-
*/const cn=
|
|
134
|
+
*/const cn=Me(g);class F extends cn{get name(){return this.getAttribute("name")??""}set name(e){this.setAttribute("name",e)}get form(){return this[V].form}constructor(){super(),this.disabled=!1,this.href="",this.target="",this.trailingIcon=!1,this.hasIcon=!1,this.type="submit",this.value="",this.handleActivationClick=e=>{!Mt(e)||!this.buttonElement||(this.focus(),ur(this.buttonElement))},this.addEventListener("click",this.handleActivationClick)}focus(){var e;(e=this.buttonElement)==null||e.focus()}blur(){var e;(e=this.buttonElement)==null||e.blur()}render(){var i;const e=this.disabled&&!this.href,t=this.href?this.renderLink():this.renderButton(),r=this.href?"link":"button";return c`
|
|
135
135
|
${(i=this.renderElevationOrOutline)==null?void 0:i.call(this)}
|
|
136
136
|
<div class="background"></div>
|
|
137
137
|
<md-focus-ring part="focus-ring" for=${r}></md-focus-ring>
|
|
@@ -164,7 +164,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
164
164
|
${this.trailingIcon?p:e}
|
|
165
165
|
<span class="label"><slot></slot></span>
|
|
166
166
|
${this.trailingIcon?e:p}
|
|
167
|
-
`}handleSlotChange(){this.hasIcon=this.assignedIcons.length>0}}Y(F),
|
|
167
|
+
`}handleSlotChange(){this.hasIcon=this.assignedIcons.length>0}}Y(F),ta(F),F.formAssociated=!0,F.shadowRootOptions={mode:"open",delegatesFocus:!0},d([l({type:Boolean,reflect:!0})],F.prototype,"disabled",void 0),d([l()],F.prototype,"href",void 0),d([l()],F.prototype,"target",void 0),d([l({type:Boolean,attribute:"trailing-icon",reflect:!0})],F.prototype,"trailingIcon",void 0),d([l({type:Boolean,attribute:"has-icon",reflect:!0})],F.prototype,"hasIcon",void 0),d([l()],F.prototype,"type",void 0),d([l({reflect:!0})],F.prototype,"value",void 0),d([k(".button")],F.prototype,"buttonElement",void 0),d([W({slot:"icon",flatten:!0})],F.prototype,"assignedIcons",void 0);/**
|
|
168
168
|
* @license
|
|
169
169
|
* Copyright 2021 Google LLC
|
|
170
170
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -243,15 +243,15 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
243
243
|
* @license
|
|
244
244
|
* Copyright 2021 Google LLC
|
|
245
245
|
* SPDX-License-Identifier: Apache-2.0
|
|
246
|
-
*/function
|
|
246
|
+
*/function Fe(o,e){e.bubbles&&(!o.shadowRoot||e.composed)&&e.stopPropagation();const t=Reflect.construct(e.constructor,[e.type,e]),r=o.dispatchEvent(t);return r||e.preventDefault(),r}/**
|
|
247
247
|
* @license
|
|
248
248
|
* Copyright 2023 Google LLC
|
|
249
249
|
* SPDX-License-Identifier: Apache-2.0
|
|
250
|
-
*/const et=Symbol("createValidator"),tt=Symbol("getValidityAnchor"),Ti=Symbol("privateValidator"),
|
|
250
|
+
*/const et=Symbol("createValidator"),tt=Symbol("getValidityAnchor"),Ti=Symbol("privateValidator"),ke=Symbol("privateSyncValidity"),gr=Symbol("privateCustomValidationMessage");function Ht(o){var e;class t extends o{constructor(){super(...arguments),this[e]=""}get validity(){return this[ke](),this[V].validity}get validationMessage(){return this[ke](),this[V].validationMessage}get willValidate(){return this[ke](),this[V].willValidate}checkValidity(){return this[ke](),this[V].checkValidity()}reportValidity(){return this[ke](),this[V].reportValidity()}setCustomValidity(i){this[gr]=i,this[ke]()}requestUpdate(i,s,n){super.requestUpdate(i,s,n),this[ke]()}firstUpdated(i){super.firstUpdated(i),this[ke]()}[(e=gr,ke)](){this[Ti]||(this[Ti]=this[et]());const{validity:i,validationMessage:s}=this[Ti].getValidity(),n=!!this[gr],h=this[gr]||s;this[V].setValidity({...i,customError:n},h,this[tt]()??void 0)}[et](){throw new Error("Implement [createValidator]")}[tt](){throw new Error("Implement [getValidityAnchor]")}}return t}/**
|
|
251
251
|
* @license
|
|
252
252
|
* Copyright 2023 Google LLC
|
|
253
253
|
* SPDX-License-Identifier: Apache-2.0
|
|
254
|
-
*/const
|
|
254
|
+
*/const $e=Symbol("getFormValue"),Nt=Symbol("getFormState");function ut(o){class e extends o{get form(){return this[V].form}get labels(){return this[V].labels}get name(){return this.getAttribute("name")??""}set name(r){this.setAttribute("name",r)}get disabled(){return this.hasAttribute("disabled")}set disabled(r){this.toggleAttribute("disabled",r)}attributeChangedCallback(r,i,s){if(r==="name"||r==="disabled"){const n=r==="disabled"?i!==null:i;this.requestUpdate(r,n);return}super.attributeChangedCallback(r,i,s)}requestUpdate(r,i,s){super.requestUpdate(r,i,s),this[V].setFormValue(this[$e](),this[Nt]())}[$e](){throw new Error("Implement [getFormValue]")}[Nt](){return this[$e]()}formDisabledCallback(r){this.disabled=r}}return e.formAssociated=!0,d([l({noAccessor:!0})],e.prototype,"name",null),d([l({type:Boolean,noAccessor:!0})],e.prototype,"disabled",null),e}/**
|
|
255
255
|
* @license
|
|
256
256
|
* Copyright 2023 Google LLC
|
|
257
257
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -259,11 +259,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
259
259
|
* @license
|
|
260
260
|
* Copyright 2023 Google LLC
|
|
261
261
|
* SPDX-License-Identifier: Apache-2.0
|
|
262
|
-
*/class
|
|
262
|
+
*/class ra extends yr{computeValidity(e){return this.checkboxControl||(this.checkboxControl=document.createElement("input"),this.checkboxControl.type="checkbox"),this.checkboxControl.checked=e.checked,this.checkboxControl.required=e.required,{validity:this.checkboxControl.validity,validationMessage:this.checkboxControl.validationMessage}}equals(e,t){return e.checked===t.checked&&e.required===t.required}copy({checked:e,required:t}){return{checked:e,required:t}}}/**
|
|
263
263
|
* @license
|
|
264
264
|
* Copyright 2019 Google LLC
|
|
265
265
|
* SPDX-License-Identifier: Apache-2.0
|
|
266
|
-
*/const kn=Ht(ut(
|
|
266
|
+
*/const kn=Ht(ut(Me(g)));class he extends kn{constructor(){super(),this.checked=!1,this.indeterminate=!1,this.required=!1,this.value="on",this.prevChecked=!1,this.prevDisabled=!1,this.prevIndeterminate=!1,this.addEventListener("click",e=>{!Mt(e)||!this.input||(this.focus(),ur(this.input))})}update(e){(e.has("checked")||e.has("disabled")||e.has("indeterminate"))&&(this.prevChecked=e.get("checked")??this.checked,this.prevDisabled=e.get("disabled")??this.disabled,this.prevIndeterminate=e.get("indeterminate")??this.indeterminate),super.update(e)}render(){const e=!this.prevChecked&&!this.prevIndeterminate,t=this.prevChecked&&!this.prevIndeterminate,r=this.prevIndeterminate,i=this.checked&&!this.indeterminate,s=this.indeterminate,n=P({disabled:this.disabled,selected:i||s,unselected:!i&&!s,checked:i,indeterminate:s,"prev-unselected":e,"prev-checked":t,"prev-indeterminate":r,"prev-disabled":this.prevDisabled}),{ariaLabel:h,ariaInvalid:u}=this;return c`
|
|
267
267
|
<div class="container ${n}">
|
|
268
268
|
<input
|
|
269
269
|
type="checkbox"
|
|
@@ -287,7 +287,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
287
287
|
<rect class="mark long" />
|
|
288
288
|
</svg>
|
|
289
289
|
</div>
|
|
290
|
-
`}handleInput(e){const t=e.target;this.checked=t.checked,this.indeterminate=t.indeterminate}handleChange(e){
|
|
290
|
+
`}handleInput(e){const t=e.target;this.checked=t.checked,this.indeterminate=t.indeterminate}handleChange(e){Fe(this,e)}[$e](){return!this.checked||this.indeterminate?null:this.value}[Nt](){return String(this.checked)}formResetCallback(){this.checked=this.hasAttribute("checked")}formStateRestoreCallback(e){this.checked=e==="true"}[et](){return new ra(()=>this)}[tt](){return this.input}}Y(he),he.shadowRootOptions={...g.shadowRootOptions,delegatesFocus:!0},d([l({type:Boolean})],he.prototype,"checked",void 0),d([l({type:Boolean})],he.prototype,"indeterminate",void 0),d([l({type:Boolean})],he.prototype,"required",void 0),d([l()],he.prototype,"value",void 0),d([w()],he.prototype,"prevChecked",void 0),d([w()],he.prototype,"prevDisabled",void 0),d([w()],he.prototype,"prevIndeterminate",void 0),d([k("input")],he.prototype,"input",void 0);/**
|
|
291
291
|
* @license
|
|
292
292
|
* Copyright 2024 Google LLC
|
|
293
293
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -300,7 +300,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
300
300
|
* @license
|
|
301
301
|
* Copyright 2023 Google LLC
|
|
302
302
|
* SPDX-License-Identifier: Apache-2.0
|
|
303
|
-
*/class
|
|
303
|
+
*/class Ce extends g{constructor(){super(...arguments),this.disabled=!1,this.alwaysFocusable=!1,this.label="",this.hasIcon=!1}get rippleDisabled(){return this.disabled}focus(e){this.disabled&&!this.alwaysFocusable||super.focus(e)}render(){return c`
|
|
304
304
|
<div class="container ${P(this.getContainerClasses())}">
|
|
305
305
|
${this.renderContainerContent()}
|
|
306
306
|
</div>
|
|
@@ -317,11 +317,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
317
317
|
</span>
|
|
318
318
|
<span class="label">${this.label}</span>
|
|
319
319
|
<span class="touch"></span>
|
|
320
|
-
`}handleIconChange(e){const t=e.target;this.hasIcon=t.assignedElements({flatten:!0}).length>0}}Y(
|
|
320
|
+
`}handleIconChange(e){const t=e.target;this.hasIcon=t.assignedElements({flatten:!0}).length>0}}Y(Ce),Ce.shadowRootOptions={...g.shadowRootOptions,delegatesFocus:!0},d([l({type:Boolean,reflect:!0})],Ce.prototype,"disabled",void 0),d([l({type:Boolean,attribute:"always-focusable"})],Ce.prototype,"alwaysFocusable",void 0),d([l()],Ce.prototype,"label",void 0),d([l({type:Boolean,reflect:!0,attribute:"has-icon"})],Ce.prototype,"hasIcon",void 0);/**
|
|
321
321
|
* @license
|
|
322
322
|
* Copyright 2023 Google LLC
|
|
323
323
|
* SPDX-License-Identifier: Apache-2.0
|
|
324
|
-
*/class qt extends
|
|
324
|
+
*/class qt extends Ce{constructor(){super(...arguments),this.elevated=!1,this.href="",this.target=""}get primaryId(){return this.href?"link":"button"}get rippleDisabled(){return!this.href&&this.disabled}getContainerClasses(){return{...super.getContainerClasses(),disabled:!this.href&&this.disabled,elevated:this.elevated,link:!!this.href}}renderPrimaryAction(e){const{ariaLabel:t}=this;return this.href?c`
|
|
325
325
|
<a
|
|
326
326
|
class="primary action"
|
|
327
327
|
id="link"
|
|
@@ -362,7 +362,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
362
362
|
* @license
|
|
363
363
|
* Copyright 2023 Google LLC
|
|
364
364
|
* SPDX-License-Identifier: Apache-2.0
|
|
365
|
-
*/class
|
|
365
|
+
*/class ia extends g{get chips(){return this.childElements.filter(e=>e instanceof Ce)}constructor(){super(),this.internals=this.attachInternals(),this.addEventListener("focusin",this.updateTabIndices.bind(this)),this.addEventListener("update-focus",this.updateTabIndices.bind(this)),this.addEventListener("keydown",this.handleKeyDown.bind(this)),this.internals.role="toolbar"}render(){return c`<slot @slotchange=${this.updateTabIndices}></slot>`}handleKeyDown(e){const t=e.key==="ArrowLeft",r=e.key==="ArrowRight",i=e.key==="Home",s=e.key==="End";if(!t&&!r&&!i&&!s)return;const{chips:n}=this;if(n.length<2)return;if(e.preventDefault(),i||s){const x=i?0:n.length-1;n[x].focus({trailing:s}),this.updateTabIndices();return}const u=getComputedStyle(this).direction==="rtl"?t:r,m=n.find(x=>x.matches(":focus-within"));if(!m){(u?n[0]:n[n.length-1]).focus({trailing:!u}),this.updateTabIndices();return}const y=n.indexOf(m);let v=u?y+1:y-1;for(;v!==y;){v>=n.length?v=0:v<0&&(v=n.length-1);const x=n[v];if(x.disabled&&!x.alwaysFocusable){u?v++:v--;continue}x.focus({trailing:!u}),this.updateTabIndices();break}}updateTabIndices(){const{chips:e}=this;let t;for(const r of e){const i=r.alwaysFocusable||!r.disabled;if(r.matches(":focus-within")&&i){t=r;continue}i&&!t&&(t=r),r.tabIndex=-1}t&&(t.tabIndex=0)}}d([W()],ia.prototype,"childElements",void 0);/**
|
|
366
366
|
* @license
|
|
367
367
|
* Copyright 2024 Google LLC
|
|
368
368
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -371,18 +371,18 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
371
371
|
* @license
|
|
372
372
|
* Copyright 2023 Google LLC
|
|
373
373
|
* SPDX-License-Identifier: Apache-2.0
|
|
374
|
-
*/let wr=class extends
|
|
374
|
+
*/let wr=class extends ia{};wr.styles=[An],wr=d([b("md-chip-set")],wr);const In=Object.freeze(Object.defineProperty({__proto__:null,get MdChipSet(){return wr}},Symbol.toStringTag,{value:"Module"}));/**
|
|
375
375
|
* @license
|
|
376
376
|
* Copyright 2023 Google LLC
|
|
377
377
|
* SPDX-License-Identifier: Apache-2.0
|
|
378
|
-
*/const Sr="aria-label-remove";class
|
|
378
|
+
*/const Sr="aria-label-remove";class oa extends Ce{get ariaLabelRemove(){if(this.hasAttribute(Sr))return this.getAttribute(Sr);const{ariaLabel:e}=this;return`Remove ${e||this.label}`}set ariaLabelRemove(e){const t=this.ariaLabelRemove;e!==t&&(e===null?this.removeAttribute(Sr):this.setAttribute(Sr,e),this.requestUpdate())}constructor(){super(),this.handleTrailingActionFocus=this.handleTrailingActionFocus.bind(this),this.addEventListener("keydown",this.handleKeyDown.bind(this))}focus(e){if((this.alwaysFocusable||!this.disabled)&&(e!=null&&e.trailing)&&this.trailingAction){this.trailingAction.focus(e);return}super.focus(e)}renderContainerContent(){return c`
|
|
379
379
|
${super.renderContainerContent()}
|
|
380
380
|
${this.renderTrailingAction(this.handleTrailingActionFocus)}
|
|
381
381
|
`}handleKeyDown(e){var m,y;const t=e.key==="ArrowLeft",r=e.key==="ArrowRight";if(!t&&!r||!this.primaryAction||!this.trailingAction)return;const s=getComputedStyle(this).direction==="rtl"?t:r,n=(m=this.primaryAction)==null?void 0:m.matches(":focus-within"),h=(y=this.trailingAction)==null?void 0:y.matches(":focus-within");if(s&&h||!s&&n)return;e.preventDefault(),e.stopPropagation(),(s?this.trailingAction:this.primaryAction).focus()}handleTrailingActionFocus(){const{primaryAction:e,trailingAction:t}=this;!e||!t||(e.tabIndex=-1,t.addEventListener("focusout",()=>{e.tabIndex=0},{once:!0}))}}/**
|
|
382
382
|
* @license
|
|
383
383
|
* Copyright 2023 Google LLC
|
|
384
384
|
* SPDX-License-Identifier: Apache-2.0
|
|
385
|
-
*/function
|
|
385
|
+
*/function aa({ariaLabel:o,disabled:e,focusListener:t,tabbable:r=!1}){return c`
|
|
386
386
|
<button
|
|
387
387
|
class="trailing action"
|
|
388
388
|
aria-label=${o}
|
|
@@ -405,7 +405,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
405
405
|
* @license
|
|
406
406
|
* Copyright 2023 Google LLC
|
|
407
407
|
* SPDX-License-Identifier: Apache-2.0
|
|
408
|
-
*/class rt extends
|
|
408
|
+
*/class rt extends oa{constructor(){super(...arguments),this.elevated=!1,this.removable=!1,this.selected=!1,this.hasSelectedIcon=!1}get primaryId(){return"button"}getContainerClasses(){return{...super.getContainerClasses(),elevated:this.elevated,selected:this.selected,"has-trailing":this.removable,"has-icon":this.hasIcon||this.selected}}renderPrimaryAction(e){const{ariaLabel:t}=this;return c`
|
|
409
409
|
<button
|
|
410
410
|
class="primary action"
|
|
411
411
|
id="button"
|
|
@@ -422,7 +422,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
422
422
|
d="M6.75012 12.1274L3.62262 8.99988L2.55762 10.0574L6.75012 14.2499L15.7501 5.24988L14.6926 4.19238L6.75012 12.1274Z" />
|
|
423
423
|
</svg>
|
|
424
424
|
</slot>
|
|
425
|
-
`:super.renderLeadingIcon()}renderTrailingAction(e){return this.removable?
|
|
425
|
+
`:super.renderLeadingIcon()}renderTrailingAction(e){return this.removable?aa({focusListener:e,ariaLabel:this.ariaLabelRemove,disabled:this.disabled}):p}renderOutline(){return this.elevated?c`<md-elevation part="elevation"></md-elevation>`:super.renderOutline()}handleClick(e){if(this.disabled)return;const t=this.selected;if(this.selected=!this.selected,!Fe(this,e)){this.selected=t;return}}}d([l({type:Boolean})],rt.prototype,"elevated",void 0),d([l({type:Boolean})],rt.prototype,"removable",void 0),d([l({type:Boolean,reflect:!0})],rt.prototype,"selected",void 0),d([l({type:Boolean,reflect:!0,attribute:"has-selected-icon"})],rt.prototype,"hasSelectedIcon",void 0),d([k(".primary.action")],rt.prototype,"primaryAction",void 0),d([k(".trailing.action")],rt.prototype,"trailingAction",void 0);/**
|
|
426
426
|
* @license
|
|
427
427
|
* Copyright 2024 Google LLC
|
|
428
428
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -431,21 +431,21 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
431
431
|
* @license
|
|
432
432
|
* Copyright 2024 Google LLC
|
|
433
433
|
* SPDX-License-Identifier: Apache-2.0
|
|
434
|
-
*/const
|
|
434
|
+
*/const sa=f`.selected{--md-ripple-hover-color: var(--_selected-hover-state-layer-color);--md-ripple-hover-opacity: var(--_selected-hover-state-layer-opacity);--md-ripple-pressed-color: var(--_selected-pressed-state-layer-color);--md-ripple-pressed-opacity: var(--_selected-pressed-state-layer-opacity)}:where(.selected)::before{background:var(--_selected-container-color)}:where(.selected) .outline{border-width:var(--_selected-outline-width)}:where(.selected.disabled)::before{background:var(--_disabled-selected-container-color);opacity:var(--_disabled-selected-container-opacity)}:where(.selected) .label{color:var(--_selected-label-text-color)}:where(.selected:hover) .label{color:var(--_selected-hover-label-text-color)}:where(.selected:focus) .label{color:var(--_selected-focus-label-text-color)}:where(.selected:active) .label{color:var(--_selected-pressed-label-text-color)}:where(.selected) .leading.icon{color:var(--_selected-leading-icon-color)}:where(.selected:hover) .leading.icon{color:var(--_selected-hover-leading-icon-color)}:where(.selected:focus) .leading.icon{color:var(--_selected-focus-leading-icon-color)}:where(.selected:active) .leading.icon{color:var(--_selected-pressed-leading-icon-color)}@media(forced-colors: active){:where(.selected:not(.elevated))::before{border:1px solid CanvasText}:where(.selected) .outline{border-width:1px}}
|
|
435
435
|
`;/**
|
|
436
436
|
* @license
|
|
437
437
|
* Copyright 2024 Google LLC
|
|
438
438
|
* SPDX-License-Identifier: Apache-2.0
|
|
439
|
-
*/const
|
|
439
|
+
*/const na=f`.trailing.action{align-items:center;justify-content:center;padding-inline-start:var(--_icon-label-space);padding-inline-end:var(--_with-trailing-icon-trailing-space)}.trailing.action :is(md-ripple,md-focus-ring){border-radius:50%;height:calc(1.3333333333*var(--_icon-size));width:calc(1.3333333333*var(--_icon-size))}.trailing.action md-focus-ring{inset:unset}.has-trailing .primary.action{padding-inline-end:0}.trailing.icon{color:var(--_trailing-icon-color);height:var(--_icon-size);width:var(--_icon-size)}:where(:hover) .trailing.icon{color:var(--_hover-trailing-icon-color)}:where(:focus) .trailing.icon{color:var(--_focus-trailing-icon-color)}:where(:active) .trailing.icon{color:var(--_pressed-trailing-icon-color)}:where(.disabled) .trailing.icon{color:var(--_disabled-trailing-icon-color);opacity:var(--_disabled-trailing-icon-opacity)}:where(.selected) .trailing.icon{color:var(--_selected-trailing-icon-color)}:where(.selected:hover) .trailing.icon{color:var(--_selected-hover-trailing-icon-color)}:where(.selected:focus) .trailing.icon{color:var(--_selected-focus-trailing-icon-color)}:where(.selected:active) .trailing.icon{color:var(--_selected-pressed-trailing-icon-color)}@media(forced-colors: active){.trailing.icon{color:ButtonText}:where(.disabled) .trailing.icon{color:GrayText;opacity:1}}
|
|
440
440
|
`;/**
|
|
441
441
|
* @license
|
|
442
442
|
* Copyright 2023 Google LLC
|
|
443
443
|
* SPDX-License-Identifier: Apache-2.0
|
|
444
|
-
*/let kr=class extends rt{};kr.styles=[xr,Oi,sa,
|
|
444
|
+
*/let kr=class extends rt{};kr.styles=[xr,Oi,na,sa,zn],kr=d([b("md-filter-chip")],kr);const On=Object.freeze(Object.defineProperty({__proto__:null,get MdFilterChip(){return kr}},Symbol.toStringTag,{value:"Module"}));/**
|
|
445
445
|
* @license
|
|
446
446
|
* Copyright 2023 Google LLC
|
|
447
447
|
* SPDX-License-Identifier: Apache-2.0
|
|
448
|
-
*/class it extends
|
|
448
|
+
*/class it extends oa{constructor(){super(...arguments),this.avatar=!1,this.href="",this.target="",this.removeOnly=!1,this.selected=!1}get primaryId(){return this.href?"link":this.removeOnly?"":"button"}get rippleDisabled(){return!this.href&&this.disabled}get primaryAction(){return this.removeOnly?null:this.renderRoot.querySelector(".primary.action")}getContainerClasses(){return{...super.getContainerClasses(),avatar:this.avatar,disabled:!this.href&&this.disabled,link:!!this.href,selected:this.selected,"has-trailing":!0}}renderPrimaryAction(e){const{ariaLabel:t}=this;return this.href?c`
|
|
449
449
|
<a
|
|
450
450
|
class="primary action"
|
|
451
451
|
id="link"
|
|
@@ -467,7 +467,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
467
467
|
type="button"
|
|
468
468
|
>${e}</button
|
|
469
469
|
>
|
|
470
|
-
`}renderTrailingAction(e){return
|
|
470
|
+
`}renderTrailingAction(e){return aa({focusListener:e,ariaLabel:this.ariaLabelRemove,disabled:!this.href&&this.disabled,tabbable:this.removeOnly})}}d([l({type:Boolean})],it.prototype,"avatar",void 0),d([l()],it.prototype,"href",void 0),d([l()],it.prototype,"target",void 0),d([l({type:Boolean,attribute:"remove-only"})],it.prototype,"removeOnly",void 0),d([l({type:Boolean,reflect:!0})],it.prototype,"selected",void 0),d([k(".trailing.action")],it.prototype,"trailingAction",void 0);/**
|
|
471
471
|
* @license
|
|
472
472
|
* Copyright 2024 Google LLC
|
|
473
473
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -476,7 +476,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
476
476
|
* @license
|
|
477
477
|
* Copyright 2023 Google LLC
|
|
478
478
|
* SPDX-License-Identifier: Apache-2.0
|
|
479
|
-
*/let Pi=class extends it{};Pi.styles=[xr,sa,
|
|
479
|
+
*/let Pi=class extends it{};Pi.styles=[xr,na,sa,Pn],Pi=d([b("md-input-chip")],Pi);/**
|
|
480
480
|
* @license
|
|
481
481
|
* Copyright 2023 Google LLC
|
|
482
482
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -484,12 +484,12 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
484
484
|
* @license
|
|
485
485
|
* Copyright 2024 Google LLC
|
|
486
486
|
* SPDX-License-Identifier: Apache-2.0
|
|
487
|
-
*/const
|
|
487
|
+
*/const Dn=f`:host{--_container-height: var(--md-suggestion-chip-container-height, 32px);--_disabled-label-text-color: var(--md-suggestion-chip-disabled-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-label-text-opacity: var(--md-suggestion-chip-disabled-label-text-opacity, 0.38);--_elevated-container-color: var(--md-suggestion-chip-elevated-container-color, var(--md-sys-color-surface-container-low, #f7f2fa));--_elevated-container-elevation: var(--md-suggestion-chip-elevated-container-elevation, 1);--_elevated-container-shadow-color: var(--md-suggestion-chip-elevated-container-shadow-color, var(--md-sys-color-shadow, #000));--_elevated-disabled-container-color: var(--md-suggestion-chip-elevated-disabled-container-color, var(--md-sys-color-on-surface, #1d1b20));--_elevated-disabled-container-elevation: var(--md-suggestion-chip-elevated-disabled-container-elevation, 0);--_elevated-disabled-container-opacity: var(--md-suggestion-chip-elevated-disabled-container-opacity, 0.12);--_elevated-focus-container-elevation: var(--md-suggestion-chip-elevated-focus-container-elevation, 1);--_elevated-hover-container-elevation: var(--md-suggestion-chip-elevated-hover-container-elevation, 2);--_elevated-pressed-container-elevation: var(--md-suggestion-chip-elevated-pressed-container-elevation, 1);--_focus-label-text-color: var(--md-suggestion-chip-focus-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-label-text-color: var(--md-suggestion-chip-hover-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-state-layer-color: var(--md-suggestion-chip-hover-state-layer-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-state-layer-opacity: var(--md-suggestion-chip-hover-state-layer-opacity, 0.08);--_label-text-color: var(--md-suggestion-chip-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_label-text-font: var(--md-suggestion-chip-label-text-font, var(--md-sys-typescale-label-large-font, var(--md-ref-typeface-plain, Roboto)));--_label-text-line-height: var(--md-suggestion-chip-label-text-line-height, var(--md-sys-typescale-label-large-line-height, 1.25rem));--_label-text-size: var(--md-suggestion-chip-label-text-size, var(--md-sys-typescale-label-large-size, 0.875rem));--_label-text-weight: var(--md-suggestion-chip-label-text-weight, var(--md-sys-typescale-label-large-weight, var(--md-ref-typeface-weight-medium, 500)));--_pressed-label-text-color: var(--md-suggestion-chip-pressed-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_pressed-state-layer-color: var(--md-suggestion-chip-pressed-state-layer-color, var(--md-sys-color-on-surface-variant, #49454f));--_pressed-state-layer-opacity: var(--md-suggestion-chip-pressed-state-layer-opacity, 0.12);--_disabled-outline-color: var(--md-suggestion-chip-disabled-outline-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-outline-opacity: var(--md-suggestion-chip-disabled-outline-opacity, 0.12);--_focus-outline-color: var(--md-suggestion-chip-focus-outline-color, var(--md-sys-color-on-surface-variant, #49454f));--_outline-color: var(--md-suggestion-chip-outline-color, var(--md-sys-color-outline, #79747e));--_outline-width: var(--md-suggestion-chip-outline-width, 1px);--_disabled-leading-icon-color: var(--md-suggestion-chip-disabled-leading-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-leading-icon-opacity: var(--md-suggestion-chip-disabled-leading-icon-opacity, 0.38);--_focus-leading-icon-color: var(--md-suggestion-chip-focus-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_hover-leading-icon-color: var(--md-suggestion-chip-hover-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_leading-icon-color: var(--md-suggestion-chip-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_pressed-leading-icon-color: var(--md-suggestion-chip-pressed-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_icon-size: var(--md-suggestion-chip-icon-size, 18px);--_container-shape-start-start: var(--md-suggestion-chip-container-shape-start-start, var(--md-suggestion-chip-container-shape, var(--md-sys-shape-corner-small, 8px)));--_container-shape-start-end: var(--md-suggestion-chip-container-shape-start-end, var(--md-suggestion-chip-container-shape, var(--md-sys-shape-corner-small, 8px)));--_container-shape-end-end: var(--md-suggestion-chip-container-shape-end-end, var(--md-suggestion-chip-container-shape, var(--md-sys-shape-corner-small, 8px)));--_container-shape-end-start: var(--md-suggestion-chip-container-shape-end-start, var(--md-suggestion-chip-container-shape, var(--md-sys-shape-corner-small, 8px)));--_leading-space: var(--md-suggestion-chip-leading-space, 16px);--_trailing-space: var(--md-suggestion-chip-trailing-space, 16px);--_icon-label-space: var(--md-suggestion-chip-icon-label-space, 8px);--_with-leading-icon-leading-space: var(--md-suggestion-chip-with-leading-icon-leading-space, 8px)}@media(forced-colors: active){.link .outline{border-color:ActiveText}}
|
|
488
488
|
`;/**
|
|
489
489
|
* @license
|
|
490
490
|
* Copyright 2023 Google LLC
|
|
491
491
|
* SPDX-License-Identifier: Apache-2.0
|
|
492
|
-
*/let Li=class extends Ln{};Li.styles=[xr,Oi,
|
|
492
|
+
*/let Li=class extends Ln{};Li.styles=[xr,Oi,Dn],Li=d([b("md-suggestion-chip")],Li);/**
|
|
493
493
|
* @license
|
|
494
494
|
* Copyright 2023 Google LLC
|
|
495
495
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -497,12 +497,12 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
497
497
|
* @license
|
|
498
498
|
* Copyright 2024 Google LLC
|
|
499
499
|
* SPDX-License-Identifier: Apache-2.0
|
|
500
|
-
*/const
|
|
500
|
+
*/const Rn=f`:host{box-sizing:border-box;color:var(--md-divider-color, var(--md-sys-color-outline-variant, #cac4d0));display:flex;height:var(--md-divider-thickness, 1px);width:100%}:host([inset]),:host([inset-start]){padding-inline-start:16px}:host([inset]),:host([inset-end]){padding-inline-end:16px}:host::before{background:currentColor;content:"";height:100%;width:100%}@media(forced-colors: active){:host::before{background:CanvasText}}
|
|
501
501
|
`;/**
|
|
502
502
|
* @license
|
|
503
503
|
* Copyright 2023 Google LLC
|
|
504
504
|
* SPDX-License-Identifier: Apache-2.0
|
|
505
|
-
*/let
|
|
505
|
+
*/let Di=class extends $r{};Di.styles=[Rn],Di=d([b("md-divider")],Di);/**
|
|
506
506
|
* @license
|
|
507
507
|
* Copyright 2023 Google LLC
|
|
508
508
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -510,7 +510,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
510
510
|
* @license
|
|
511
511
|
* Copyright 2023 Google LLC
|
|
512
512
|
* SPDX-License-Identifier: Apache-2.0
|
|
513
|
-
*/class
|
|
513
|
+
*/class D extends g{get open(){return this.isOpen}set open(e){e!==this.isOpen&&(this.isOpen=e,e?(this.setAttribute("open",""),this.show()):(this.removeAttribute("open"),this.close()))}constructor(){super(),this.quick=!1,this.returnValue="",this.noFocusTrap=!1,this.getOpenAnimation=()=>Bn,this.getCloseAnimation=()=>Mn,this.isOpen=!1,this.isOpening=!1,this.isConnectedPromise=this.getIsConnectedPromise(),this.isAtScrollTop=!1,this.isAtScrollBottom=!1,this.nextClickIsFromContent=!1,this.hasHeadline=!1,this.hasActions=!1,this.hasIcon=!1,this.escapePressedWithoutCancel=!1,this.treewalker=document.createTreeWalker(this,NodeFilter.SHOW_ELEMENT),this.addEventListener("submit",this.handleSubmit)}async show(){var r;this.isOpening=!0,await this.isConnectedPromise,await this.updateComplete;const e=this.dialog;if(e.open||!this.isOpening){this.isOpening=!1;return}if(!this.dispatchEvent(new Event("open",{cancelable:!0}))){this.open=!1,this.isOpening=!1;return}e.showModal(),this.open=!0,this.scroller&&(this.scroller.scrollTop=0),(r=this.querySelector("[autofocus]"))==null||r.focus(),await this.animateDialog(this.getOpenAnimation()),this.dispatchEvent(new Event("opened")),this.isOpening=!1}async close(e=this.returnValue){if(this.isOpening=!1,!this.isConnected){this.open=!1;return}await this.updateComplete;const t=this.dialog;if(!t.open||this.isOpening){this.open=!1;return}const r=this.returnValue;if(this.returnValue=e,!this.dispatchEvent(new Event("close",{cancelable:!0}))){this.returnValue=r;return}await this.animateDialog(this.getCloseAnimation()),t.close(e),this.open=!1,this.dispatchEvent(new Event("closed"))}connectedCallback(){super.connectedCallback(),this.isConnectedPromiseResolve()}disconnectedCallback(){super.disconnectedCallback(),this.isConnectedPromise=this.getIsConnectedPromise()}render(){const e=this.open&&!(this.isAtScrollTop&&this.isAtScrollBottom),t={"has-headline":this.hasHeadline,"has-actions":this.hasActions,"has-icon":this.hasIcon,scrollable:e,"show-top-divider":e&&!this.isAtScrollTop,"show-bottom-divider":e&&!this.isAtScrollBottom},r=this.open&&!this.noFocusTrap,i=c`
|
|
514
514
|
<div
|
|
515
515
|
class="focus-trap"
|
|
516
516
|
tabindex="0"
|
|
@@ -555,7 +555,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
555
555
|
</div>
|
|
556
556
|
${r?i:p}
|
|
557
557
|
</dialog>
|
|
558
|
-
`}firstUpdated(){this.intersectionObserver=new IntersectionObserver(e=>{for(const t of e)this.handleAnchorIntersection(t)},{root:this.scroller}),this.intersectionObserver.observe(this.topAnchor),this.intersectionObserver.observe(this.bottomAnchor)}handleDialogClick(){if(this.nextClickIsFromContent){this.nextClickIsFromContent=!1;return}this.dispatchEvent(new Event("cancel",{cancelable:!0}))&&this.close()}handleContentClick(){this.nextClickIsFromContent=!0}handleSubmit(e){const t=e.target,{submitter:r}=e;t.method!=="dialog"||!r||this.close(r.getAttribute("value")??this.returnValue)}handleCancel(e){if(e.target!==this.dialog)return;this.escapePressedWithoutCancel=!1;const t=!
|
|
558
|
+
`}firstUpdated(){this.intersectionObserver=new IntersectionObserver(e=>{for(const t of e)this.handleAnchorIntersection(t)},{root:this.scroller}),this.intersectionObserver.observe(this.topAnchor),this.intersectionObserver.observe(this.bottomAnchor)}handleDialogClick(){if(this.nextClickIsFromContent){this.nextClickIsFromContent=!1;return}this.dispatchEvent(new Event("cancel",{cancelable:!0}))&&this.close()}handleContentClick(){this.nextClickIsFromContent=!0}handleSubmit(e){const t=e.target,{submitter:r}=e;t.method!=="dialog"||!r||this.close(r.getAttribute("value")??this.returnValue)}handleCancel(e){if(e.target!==this.dialog)return;this.escapePressedWithoutCancel=!1;const t=!Fe(this,e);e.preventDefault(),!t&&this.close()}handleClose(){var e;this.escapePressedWithoutCancel&&(this.escapePressedWithoutCancel=!1,(e=this.dialog)==null||e.dispatchEvent(new Event("cancel",{cancelable:!0})))}handleKeydown(e){e.key==="Escape"&&(this.escapePressedWithoutCancel=!0,setTimeout(()=>{this.escapePressedWithoutCancel=!1}))}async animateDialog(e){var A;if((A=this.cancelAnimations)==null||A.abort(),this.cancelAnimations=new AbortController,this.quick)return;const{dialog:t,scrim:r,container:i,headline:s,content:n,actions:h}=this;if(!t||!r||!i||!s||!n||!h)return;const{container:u,dialog:m,scrim:y,headline:v,content:x,actions:_}=e,S=[[t,m??[]],[r,y??[]],[i,u??[]],[s,v??[]],[n,x??[]],[h,_??[]]],C=[];for(const[I,z]of S)for(const ie of z){const j=I.animate(...ie);this.cancelAnimations.signal.addEventListener("abort",()=>{j.cancel()}),C.push(j)}await Promise.all(C.map(I=>I.finished.catch(()=>{})))}handleHeadlineChange(e){const t=e.target;this.hasHeadline=t.assignedElements().length>0}handleActionsChange(e){const t=e.target;this.hasActions=t.assignedElements().length>0}handleIconChange(e){const t=e.target;this.hasIcon=t.assignedElements().length>0}handleAnchorIntersection(e){const{target:t,isIntersecting:r}=e;t===this.topAnchor&&(this.isAtScrollTop=r),t===this.bottomAnchor&&(this.isAtScrollBottom=r)}getIsConnectedPromise(){return new Promise(e=>{this.isConnectedPromiseResolve=e})}handleFocusTrapFocus(e){var v;const[t,r]=this.getFirstAndLastFocusableChildren();if(!t||!r){(v=this.dialog)==null||v.focus();return}const i=e.target===this.firstFocusTrap,s=!i,n=e.relatedTarget===t,h=e.relatedTarget===r,u=!n&&!h;if(s&&h||i&&u){t.focus();return}if(i&&n||s&&u){r.focus();return}}getFirstAndLastFocusableChildren(){let e=null,t=null;for(this.treewalker.currentNode=this.treewalker.root;this.treewalker.nextNode();){const r=this.treewalker.currentNode;Fn(r)&&(e||(e=r),t=r)}return[e,t]}}Y(D),d([l({type:Boolean})],D.prototype,"open",null),d([l({type:Boolean})],D.prototype,"quick",void 0),d([l({attribute:!1})],D.prototype,"returnValue",void 0),d([l()],D.prototype,"type",void 0),d([l({type:Boolean,attribute:"no-focus-trap"})],D.prototype,"noFocusTrap",void 0),d([k("dialog")],D.prototype,"dialog",void 0),d([k(".scrim")],D.prototype,"scrim",void 0),d([k(".container")],D.prototype,"container",void 0),d([k(".headline")],D.prototype,"headline",void 0),d([k(".content")],D.prototype,"content",void 0),d([k(".actions")],D.prototype,"actions",void 0),d([w()],D.prototype,"isAtScrollTop",void 0),d([w()],D.prototype,"isAtScrollBottom",void 0),d([k(".scroller")],D.prototype,"scroller",void 0),d([k(".top.anchor")],D.prototype,"topAnchor",void 0),d([k(".bottom.anchor")],D.prototype,"bottomAnchor",void 0),d([k(".focus-trap")],D.prototype,"firstFocusTrap",void 0),d([w()],D.prototype,"hasHeadline",void 0),d([w()],D.prototype,"hasActions",void 0),d([w()],D.prototype,"hasIcon",void 0);function Fn(o){var s;const e=":is(button,input,select,textarea,object,:is(a,area)[href],[tabindex],[contenteditable=true])",t=":not(:disabled,[disabled])";return o.matches(e+t+':not([tabindex^="-"])')?!0:!o.localName.includes("-")||!o.matches(t)?!1:((s=o.shadowRoot)==null?void 0:s.delegatesFocus)??!1}/**
|
|
559
559
|
* @license
|
|
560
560
|
* Copyright 2024 Google LLC
|
|
561
561
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -564,7 +564,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
564
564
|
* @license
|
|
565
565
|
* Copyright 2023 Google LLC
|
|
566
566
|
* SPDX-License-Identifier: Apache-2.0
|
|
567
|
-
*/let
|
|
567
|
+
*/let Ri=class extends D{};Ri.styles=[Hn],Ri=d([b("md-dialog")],Ri);/**
|
|
568
568
|
* @license
|
|
569
569
|
* Copyright 2023 Google LLC
|
|
570
570
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -596,17 +596,17 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
596
596
|
* @license
|
|
597
597
|
* Copyright 2024 Google LLC
|
|
598
598
|
* SPDX-License-Identifier: Apache-2.0
|
|
599
|
-
*/const
|
|
599
|
+
*/const la=f`@media(forced-colors: active){.fab{border:1px solid ButtonText}.fab.extended{padding-inline-start:15px;padding-inline-end:19px}md-focus-ring{--md-focus-ring-outward-offset: 3px}}
|
|
600
600
|
`;/**
|
|
601
601
|
* @license
|
|
602
602
|
* Copyright 2024 Google LLC
|
|
603
603
|
* SPDX-License-Identifier: Apache-2.0
|
|
604
|
-
*/const
|
|
604
|
+
*/const ca=f`:host{--md-ripple-hover-opacity: var(--_hover-state-layer-opacity);--md-ripple-pressed-opacity: var(--_pressed-state-layer-opacity);display:inline-flex;-webkit-tap-highlight-color:rgba(0,0,0,0)}:host([size=medium][touch-target=wrapper]){margin:max(0px,48px - var(--_container-height))}:host([size=large][touch-target=wrapper]){margin:max(0px,48px - var(--_large-container-height))}.fab,.icon,.icon ::slotted(*){display:flex}.fab{align-items:center;justify-content:center;vertical-align:middle;padding:0;position:relative;height:var(--_container-height);transition-property:background-color;border-width:0px;outline:none;z-index:0;text-transform:inherit;--md-elevation-level: var(--_container-elevation);--md-elevation-shadow-color: var(--_container-shadow-color);background-color:var(--_container-color);--md-ripple-hover-color: var(--_hover-state-layer-color);--md-ripple-pressed-color: var(--_pressed-state-layer-color)}.fab.extended{width:inherit;box-sizing:border-box;padding-inline-start:16px;padding-inline-end:20px}.fab:not(.extended){width:var(--_container-width)}.fab.large{width:var(--_large-container-width);height:var(--_large-container-height)}.fab.large .icon ::slotted(*){width:var(--_large-icon-size);height:var(--_large-icon-size);font-size:var(--_large-icon-size)}.fab.large,.fab.large .ripple{border-start-start-radius:var(--_large-container-shape-start-start);border-start-end-radius:var(--_large-container-shape-start-end);border-end-start-radius:var(--_large-container-shape-end-start);border-end-end-radius:var(--_large-container-shape-end-end)}.fab.large md-focus-ring{--md-focus-ring-shape-start-start: var(--_large-container-shape-start-start);--md-focus-ring-shape-start-end: var(--_large-container-shape-start-end);--md-focus-ring-shape-end-end: var(--_large-container-shape-end-end);--md-focus-ring-shape-end-start: var(--_large-container-shape-end-start)}.fab:focus{--md-elevation-level: var(--_focus-container-elevation)}.fab:hover{--md-elevation-level: var(--_hover-container-elevation)}.fab:active{--md-elevation-level: var(--_pressed-container-elevation)}.fab.lowered{background-color:var(--_lowered-container-color);--md-elevation-level: var(--_lowered-container-elevation)}.fab.lowered:focus{--md-elevation-level: var(--_lowered-focus-container-elevation)}.fab.lowered:hover{--md-elevation-level: var(--_lowered-hover-container-elevation)}.fab.lowered:active{--md-elevation-level: var(--_lowered-pressed-container-elevation)}.fab .label{color:var(--_label-text-color)}.fab:hover .fab .label{color:var(--_hover-label-text-color)}.fab:focus .fab .label{color:var(--_focus-label-text-color)}.fab:active .fab .label{color:var(--_pressed-label-text-color)}.label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:var(--_label-text-font);font-size:var(--_label-text-size);line-height:var(--_label-text-line-height);font-weight:var(--_label-text-weight)}.fab.extended .icon ::slotted(*){margin-inline-end:12px}.ripple{overflow:hidden}.ripple,md-elevation{z-index:-1}.touch-target{position:absolute;top:50%;height:48px;left:50%;width:48px;transform:translate(-50%, -50%)}:host([touch-target=none]) .touch-target{display:none}md-elevation,.fab{transition-duration:280ms;transition-timing-function:cubic-bezier(0.2, 0, 0, 1)}.fab,.ripple{border-start-start-radius:var(--_container-shape-start-start);border-start-end-radius:var(--_container-shape-start-end);border-end-start-radius:var(--_container-shape-end-start);border-end-end-radius:var(--_container-shape-end-end)}md-focus-ring{--md-focus-ring-shape-start-start: var(--_container-shape-start-start);--md-focus-ring-shape-start-end: var(--_container-shape-start-end);--md-focus-ring-shape-end-end: var(--_container-shape-end-end);--md-focus-ring-shape-end-start: var(--_container-shape-end-start)}.icon ::slotted(*){width:var(--_icon-size);height:var(--_icon-size);font-size:var(--_icon-size)}
|
|
605
605
|
`;/**
|
|
606
606
|
* @license
|
|
607
607
|
* Copyright 2023 Google LLC
|
|
608
608
|
* SPDX-License-Identifier: Apache-2.0
|
|
609
|
-
*/let Mi=class extends Bi{getRenderClasses(){return{...super.getRenderClasses(),primary:!1,secondary:!1,tertiary:!1,small:!1}}};Mi.styles=[
|
|
609
|
+
*/let Mi=class extends Bi{getRenderClasses(){return{...super.getRenderClasses(),primary:!1,secondary:!1,tertiary:!1,small:!1}}};Mi.styles=[ca,Nn,la],Mi=d([b("md-branded-fab")],Mi);/**
|
|
610
610
|
* @license
|
|
611
611
|
* Copyright 2024 Google LLC
|
|
612
612
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -615,7 +615,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
615
615
|
* @license
|
|
616
616
|
* Copyright 2022 Google LLC
|
|
617
617
|
* SPDX-License-Identifier: Apache-2.0
|
|
618
|
-
*/let Fi=class extends Bi{};Fi.styles=[
|
|
618
|
+
*/let Fi=class extends Bi{};Fi.styles=[ca,qn,la],Fi=d([b("md-fab")],Fi);/**
|
|
619
619
|
* @license
|
|
620
620
|
* Copyright 2021 Google LLC
|
|
621
621
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -667,12 +667,12 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
667
667
|
* @license
|
|
668
668
|
* Copyright 2024 Google LLC
|
|
669
669
|
* SPDX-License-Identifier: Apache-2.0
|
|
670
|
-
*/const
|
|
670
|
+
*/const da=f`:host{display:inline-flex;resize:both}.field{display:flex;flex:1;flex-direction:column;writing-mode:horizontal-tb;max-width:100%}.container-overflow{border-start-start-radius:var(--_container-shape-start-start);border-start-end-radius:var(--_container-shape-start-end);border-end-end-radius:var(--_container-shape-end-end);border-end-start-radius:var(--_container-shape-end-start);display:flex;height:100%;position:relative}.container{align-items:center;border-radius:inherit;display:flex;flex:1;max-height:100%;min-height:100%;min-width:min-content;position:relative}.field,.container-overflow{resize:inherit}.resizable:not(.disabled) .container{resize:inherit;overflow:hidden}.disabled{pointer-events:none}@layer styles{.start,.middle,.end{display:flex;box-sizing:border-box;height:100%;position:relative}.start{color:var(--_leading-content-color)}.end{color:var(--_trailing-content-color)}.start,.end{align-items:center;justify-content:center}.with-start .start,.with-end .end{min-width:48px}.with-start .start{margin-inline-end:4px}.with-end .end{margin-inline-start:4px}.middle{align-items:stretch;align-self:baseline;flex:1}.content{color:var(--_content-color);display:flex;flex:1;opacity:0;transition:opacity 83ms cubic-bezier(0.2, 0, 0, 1)}.no-label .content,.focused .content,.populated .content{opacity:1;transition-delay:67ms}:is(.disabled,.disable-transitions) .content{transition:none}.content ::slotted(*){all:unset;color:currentColor;font-family:var(--_content-font);font-size:var(--_content-size);line-height:var(--_content-line-height);font-weight:var(--_content-weight);width:100%;overflow-wrap:revert;white-space:revert}.content ::slotted(:not(textarea)){padding-top:var(--_top-space);padding-bottom:var(--_bottom-space)}.content ::slotted(textarea){margin-top:var(--_top-space);margin-bottom:var(--_bottom-space)}:hover .content{color:var(--_hover-content-color)}:hover .start{color:var(--_hover-leading-content-color)}:hover .end{color:var(--_hover-trailing-content-color)}.focused .content{color:var(--_focus-content-color)}.focused .start{color:var(--_focus-leading-content-color)}.focused .end{color:var(--_focus-trailing-content-color)}.disabled .content{color:var(--_disabled-content-color)}.disabled.no-label .content,.disabled.focused .content,.disabled.populated .content{opacity:var(--_disabled-content-opacity)}.disabled .start{color:var(--_disabled-leading-content-color);opacity:var(--_disabled-leading-content-opacity)}.disabled .end{color:var(--_disabled-trailing-content-color);opacity:var(--_disabled-trailing-content-opacity)}.error .content{color:var(--_error-content-color)}.error .start{color:var(--_error-leading-content-color)}.error .end{color:var(--_error-trailing-content-color)}.error:hover .content{color:var(--_error-hover-content-color)}.error:hover .start{color:var(--_error-hover-leading-content-color)}.error:hover .end{color:var(--_error-hover-trailing-content-color)}.error.focused .content{color:var(--_error-focus-content-color)}.error.focused .start{color:var(--_error-focus-leading-content-color)}.error.focused .end{color:var(--_error-focus-trailing-content-color)}}@layer hcm{@media(forced-colors: active){.disabled :is(.start,.content,.end){color:GrayText;opacity:1}}}@layer styles{.label{box-sizing:border-box;color:var(--_label-text-color);overflow:hidden;max-width:100%;text-overflow:ellipsis;white-space:nowrap;z-index:1;font-family:var(--_label-text-font);font-size:var(--_label-text-size);line-height:var(--_label-text-line-height);font-weight:var(--_label-text-weight);width:min-content}.label-wrapper{inset:0;pointer-events:none;position:absolute}.label.resting{position:absolute;top:var(--_top-space)}.label.floating{font-size:var(--_label-text-populated-size);line-height:var(--_label-text-populated-line-height);transform-origin:top left}.label.hidden{opacity:0}.no-label .label{display:none}.label-wrapper{inset:0;position:absolute;text-align:initial}:hover .label{color:var(--_hover-label-text-color)}.focused .label{color:var(--_focus-label-text-color)}.disabled .label{color:var(--_disabled-label-text-color)}.disabled .label:not(.hidden){opacity:var(--_disabled-label-text-opacity)}.error .label{color:var(--_error-label-text-color)}.error:hover .label{color:var(--_error-hover-label-text-color)}.error.focused .label{color:var(--_error-focus-label-text-color)}}@layer hcm{@media(forced-colors: active){.disabled .label:not(.hidden){color:GrayText;opacity:1}}}@layer styles{.supporting-text{color:var(--_supporting-text-color);display:flex;font-family:var(--_supporting-text-font);font-size:var(--_supporting-text-size);line-height:var(--_supporting-text-line-height);font-weight:var(--_supporting-text-weight);gap:16px;justify-content:space-between;padding-inline-start:var(--_supporting-text-leading-space);padding-inline-end:var(--_supporting-text-trailing-space);padding-top:var(--_supporting-text-top-space)}.supporting-text :nth-child(2){flex-shrink:0}:hover .supporting-text{color:var(--_hover-supporting-text-color)}.focus .supporting-text{color:var(--_focus-supporting-text-color)}.disabled .supporting-text{color:var(--_disabled-supporting-text-color);opacity:var(--_disabled-supporting-text-opacity)}.error .supporting-text{color:var(--_error-supporting-text-color)}.error:hover .supporting-text{color:var(--_error-hover-supporting-text-color)}.error.focus .supporting-text{color:var(--_error-focus-supporting-text-color)}}@layer hcm{@media(forced-colors: active){.disabled .supporting-text{color:GrayText;opacity:1}}}
|
|
671
671
|
`;/**
|
|
672
672
|
* @license
|
|
673
673
|
* Copyright 2021 Google LLC
|
|
674
674
|
* SPDX-License-Identifier: Apache-2.0
|
|
675
|
-
*/let Hi=class extends Vn{};Hi.styles=[
|
|
675
|
+
*/let Hi=class extends Vn{};Hi.styles=[da,Un],Hi=d([b("md-filled-field")],Hi);/**
|
|
676
676
|
* @license
|
|
677
677
|
* Copyright 2021 Google LLC
|
|
678
678
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -695,7 +695,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
695
695
|
* @license
|
|
696
696
|
* Copyright 2021 Google LLC
|
|
697
697
|
* SPDX-License-Identifier: Apache-2.0
|
|
698
|
-
*/let Ni=class extends jn{};Ni.styles=[
|
|
698
|
+
*/let Ni=class extends jn{};Ni.styles=[da,Wn],Ni=d([b("md-outlined-field")],Ni);/**
|
|
699
699
|
* @license
|
|
700
700
|
* Copyright 2022 Google LLC
|
|
701
701
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -717,16 +717,16 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
717
717
|
* @license
|
|
718
718
|
* Copyright 2020 Google LLC
|
|
719
719
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
720
|
-
*/const
|
|
721
|
-
take care to ensure page security.`)})(r)+o[i+1],o[0]),r:
|
|
720
|
+
*/const ha=Symbol.for(""),Xn=o=>{if((o==null?void 0:o.r)===ha)return o==null?void 0:o._$litStatic$},Z=(o,...e)=>({_$litStatic$:e.reduce((t,r,i)=>t+(s=>{if(s._$litStatic$!==void 0)return s._$litStatic$;throw Error(`Value passed to 'literal' function must be a 'literal' result: ${s}. Use 'unsafeStatic' to pass non-literal values, but
|
|
721
|
+
take care to ensure page security.`)})(r)+o[i+1],o[0]),r:ha}),pa=new Map,Zn=o=>(e,...t)=>{const r=t.length;let i,s;const n=[],h=[];let u,m=0,y=!1;for(;m<r;){for(u=e[m];m<r&&(s=t[m],(i=Xn(s))!==void 0);)u+=i+e[++m],y=!0;m!==r&&h.push(s),n.push(u),m++}if(m===r&&n.push(e[r]),y){const v=n.join("$$lit$$");(e=pa.get(v))===void 0&&(n.raw=n,pa.set(v,e=n)),t=h}return o(e,...t)},Vt=Zn(c);/**
|
|
722
722
|
* @license
|
|
723
723
|
* Copyright 2022 Google LLC
|
|
724
724
|
* SPDX-License-Identifier: Apache-2.0
|
|
725
|
-
*/function
|
|
725
|
+
*/function ua(o,e=!0){return e&&getComputedStyle(o).getPropertyValue("direction").trim()==="rtl"}/**
|
|
726
726
|
* @license
|
|
727
727
|
* Copyright 2018 Google LLC
|
|
728
728
|
* SPDX-License-Identifier: Apache-2.0
|
|
729
|
-
*/const Jn=
|
|
729
|
+
*/const Jn=Me(g);class H extends Jn{constructor(){super(...arguments),this.disabled=!1,this.flipIconInRtl=!1,this.href="",this.target="",this.ariaLabelSelected="",this.toggle=!1,this.selected=!1,this.type="submit",this.value="",this.flipIcon=ua(this,this.flipIconInRtl)}get name(){return this.getAttribute("name")??""}set name(e){this.setAttribute("name",e)}get form(){return this[V].form}get labels(){return this[V].labels}willUpdate(){this.href&&(this.disabled=!1)}render(){const e=this.href?Z`div`:Z`button`,{ariaLabel:t,ariaHasPopup:r,ariaExpanded:i}=this,s=t&&this.ariaLabelSelected,n=this.toggle?this.selected:p;let h=p;return this.href||(h=s&&this.selected?this.ariaLabelSelected:t),Vt`<${e}
|
|
730
730
|
class="icon-button ${P(this.getRenderClasses())}"
|
|
731
731
|
id="button"
|
|
732
732
|
aria-label="${h||p}"
|
|
@@ -754,7 +754,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
754
754
|
part="focus-ring"
|
|
755
755
|
for=${this.href?"link":"button"}></md-focus-ring>`}renderRipple(){return c`<md-ripple
|
|
756
756
|
for=${this.href?"link":p}
|
|
757
|
-
?disabled="${!this.href&&this.disabled}"></md-ripple>`}connectedCallback(){this.flipIcon=
|
|
757
|
+
?disabled="${!this.href&&this.disabled}"></md-ripple>`}connectedCallback(){this.flipIcon=ua(this,this.flipIconInRtl),super.connectedCallback()}async handleClick(e){await 0,!(!this.toggle||this.disabled||e.defaultPrevented)&&(this.selected=!this.selected,this.dispatchEvent(new InputEvent("input",{bubbles:!0,composed:!0})),this.dispatchEvent(new Event("change",{bubbles:!0})))}}Y(H),ta(H),H.formAssociated=!0,H.shadowRootOptions={mode:"open",delegatesFocus:!0},d([l({type:Boolean,reflect:!0})],H.prototype,"disabled",void 0),d([l({type:Boolean,attribute:"flip-icon-in-rtl"})],H.prototype,"flipIconInRtl",void 0),d([l()],H.prototype,"href",void 0),d([l()],H.prototype,"target",void 0),d([l({attribute:"aria-label-selected"})],H.prototype,"ariaLabelSelected",void 0),d([l({type:Boolean})],H.prototype,"toggle",void 0),d([l({type:Boolean,reflect:!0})],H.prototype,"selected",void 0),d([l()],H.prototype,"type",void 0),d([l({reflect:!0})],H.prototype,"value",void 0),d([w()],H.prototype,"flipIcon",void 0);/**
|
|
758
758
|
* @license
|
|
759
759
|
* Copyright 2024 Google LLC
|
|
760
760
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -794,21 +794,21 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
794
794
|
* @license
|
|
795
795
|
* Copyright 2023 Google LLC
|
|
796
796
|
* SPDX-License-Identifier: Apache-2.0
|
|
797
|
-
*/function
|
|
797
|
+
*/function va(o,e=be){const t=Or(o,e);return t&&(t.tabIndex=0,t.focus()),t}function fa(o,e=be){const t=ma(o,e);return t&&(t.tabIndex=0,t.focus()),t}function sl(o,e=be){const t=ft(o,e);return t&&(t.item.tabIndex=-1),t}function ft(o,e=be){for(let t=0;t<o.length;t++){const r=o[t];if(r.tabIndex===0&&e(r))return{item:r,index:t}}return null}function Or(o,e=be){for(const t of o)if(e(t))return t;return null}function ma(o,e=be){for(let t=o.length-1;t>=0;t--){const r=o[t];if(e(r))return r}return null}function nl(o,e,t=be,r=!0){for(let i=1;i<o.length;i++){const s=(i+e)%o.length;if(s<e&&!r)return null;const n=o[s];if(t(n))return n}return o[e]?o[e]:null}function ll(o,e,t=be,r=!0){for(let i=1;i<o.length;i++){const s=(e-i+o.length)%o.length;if(s>e&&!r)return null;const n=o[s];if(t(n))return n}return o[e]?o[e]:null}function ba(o,e,t=be,r=!0){if(e){const i=nl(o,e.index,t,r);return i&&(i.tabIndex=0,i.focus()),i}else return va(o,t)}function ga(o,e,t=be,r=!0){if(e){const i=ll(o,e.index,t,r);return i&&(i.tabIndex=0,i.focus()),i}else return fa(o,t)}function Pr(){return new Event("deactivate-items",{bubbles:!0,composed:!0})}function ya(){return new Event("request-activation",{bubbles:!0,composed:!0})}function be(o){return!o.disabled}/**
|
|
798
798
|
* @license
|
|
799
799
|
* Copyright 2023 Google LLC
|
|
800
800
|
* SPDX-License-Identifier: Apache-2.0
|
|
801
|
-
*/const U={ArrowDown:"ArrowDown",ArrowLeft:"ArrowLeft",ArrowUp:"ArrowUp",ArrowRight:"ArrowRight",Home:"Home",End:"End"};class
|
|
801
|
+
*/const U={ArrowDown:"ArrowDown",ArrowLeft:"ArrowLeft",ArrowUp:"ArrowUp",ArrowRight:"ArrowRight",Home:"Home",End:"End"};class xa{constructor(e){this.handleKeydown=y=>{const v=y.key;if(y.defaultPrevented||!this.isNavigableKey(v))return;const x=this.items;if(!x.length)return;const _=ft(x,this.isActivatable);y.preventDefault();const S=this.isRtl(),C=S?U.ArrowRight:U.ArrowLeft,A=S?U.ArrowLeft:U.ArrowRight;let I=null;switch(v){case U.ArrowDown:case A:I=ba(x,_,this.isActivatable,this.wrapNavigation());break;case U.ArrowUp:case C:I=ga(x,_,this.isActivatable,this.wrapNavigation());break;case U.Home:I=va(x,this.isActivatable);break;case U.End:I=fa(x,this.isActivatable);break}I&&_&&_.item!==I&&(_.item.tabIndex=-1)},this.onDeactivateItems=()=>{const y=this.items;for(const v of y)this.deactivateItem(v)},this.onRequestActivation=y=>{this.onDeactivateItems();const v=y.target;this.activateItem(v),v.focus()},this.onSlotchange=()=>{const y=this.items;let v=!1;for(const _ of y){if(!_.disabled&&_.tabIndex>-1&&!v){v=!0,_.tabIndex=0;continue}_.tabIndex=-1}if(v)return;const x=Or(y,this.isActivatable);x&&(x.tabIndex=0)};const{isItem:t,getPossibleItems:r,isRtl:i,deactivateItem:s,activateItem:n,isNavigableKey:h,isActivatable:u,wrapNavigation:m}=e;this.isItem=t,this.getPossibleItems=r,this.isRtl=i,this.deactivateItem=s,this.activateItem=n,this.isNavigableKey=h,this.isActivatable=u,this.wrapNavigation=m??(()=>!0)}get items(){const e=this.getPossibleItems(),t=[];for(const r of e){if(this.isItem(r)){t.push(r);continue}const s=r.item;s&&this.isItem(s)&&t.push(s)}return t}activateNextItem(){const e=this.items,t=ft(e,this.isActivatable);return t&&(t.item.tabIndex=-1),ba(e,t,this.isActivatable,this.wrapNavigation())}activatePreviousItem(){const e=this.items,t=ft(e,this.isActivatable);return t&&(t.item.tabIndex=-1),ga(e,t,this.isActivatable,this.wrapNavigation())}}/**
|
|
802
802
|
* @license
|
|
803
803
|
* Copyright 2021 Google LLC
|
|
804
804
|
* SPDX-License-Identifier: Apache-2.0
|
|
805
|
-
*/const cl=new Set(Object.values(U));class
|
|
805
|
+
*/const cl=new Set(Object.values(U));class _a extends g{get items(){return this.listController.items}constructor(){super(),this.listController=new xa({isItem:e=>e.hasAttribute("md-list-item"),getPossibleItems:()=>this.slotItems,isRtl:()=>getComputedStyle(this).direction==="rtl",deactivateItem:e=>{e.tabIndex=-1},activateItem:e=>{e.tabIndex=0},isNavigableKey:e=>cl.has(e),isActivatable:e=>!e.disabled&&e.type!=="text"}),this.internals=this.attachInternals(),this.internals.role="list",this.addEventListener("keydown",this.listController.handleKeydown)}render(){return c`
|
|
806
806
|
<slot
|
|
807
807
|
@deactivate-items=${this.listController.onDeactivateItems}
|
|
808
808
|
@request-activation=${this.listController.onRequestActivation}
|
|
809
809
|
@slotchange=${this.listController.onSlotchange}>
|
|
810
810
|
</slot>
|
|
811
|
-
`}activateNextItem(){return this.listController.activateNextItem()}activatePreviousItem(){return this.listController.activatePreviousItem()}}d([W({flatten:!0})],
|
|
811
|
+
`}activateNextItem(){return this.listController.activateNextItem()}activatePreviousItem(){return this.listController.activatePreviousItem()}}d([W({flatten:!0})],_a.prototype,"slotItems",void 0);/**
|
|
812
812
|
* @license
|
|
813
813
|
* Copyright 2024 Google LLC
|
|
814
814
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -817,7 +817,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
817
817
|
* @license
|
|
818
818
|
* Copyright 2021 Google LLC
|
|
819
819
|
* SPDX-License-Identifier: Apache-2.0
|
|
820
|
-
*/let Lr=class extends
|
|
820
|
+
*/let Lr=class extends _a{};Lr.styles=[dl],Lr=d([b("md-list")],Lr);const hl=Object.freeze(Object.defineProperty({__proto__:null,get MdList(){return Lr}},Symbol.toStringTag,{value:"Module"}));/**
|
|
821
821
|
* @license
|
|
822
822
|
* Copyright 2023 Google LLC
|
|
823
823
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -849,7 +849,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
849
849
|
* @license
|
|
850
850
|
* Copyright 2022 Google LLC
|
|
851
851
|
* SPDX-License-Identifier: Apache-2.0
|
|
852
|
-
*/class
|
|
852
|
+
*/class Ee extends g{constructor(){super(...arguments),this.disabled=!1,this.type="text",this.isListItem=!0,this.href="",this.target=""}get isDisabled(){return this.disabled&&this.type!=="link"}willUpdate(e){this.href&&(this.type="link"),super.willUpdate(e)}render(){return this.renderListItem(c`
|
|
853
853
|
<md-item>
|
|
854
854
|
<div slot="container">
|
|
855
855
|
${this.renderRipple()} ${this.renderFocusRing()}
|
|
@@ -888,7 +888,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
888
888
|
<slot
|
|
889
889
|
name="trailing-supporting-text"
|
|
890
890
|
slot="trailing-supporting-text"></slot>
|
|
891
|
-
`}onFocus(){this.tabIndex===-1&&this.dispatchEvent(
|
|
891
|
+
`}onFocus(){this.tabIndex===-1&&this.dispatchEvent(ya())}focus(){var e;(e=this.listItemRoot)==null||e.focus()}}Y(Ee),Ee.shadowRootOptions={...g.shadowRootOptions,delegatesFocus:!0},d([l({type:Boolean,reflect:!0})],Ee.prototype,"disabled",void 0),d([l({reflect:!0})],Ee.prototype,"type",void 0),d([l({type:Boolean,attribute:"md-list-item",reflect:!0})],Ee.prototype,"isListItem",void 0),d([l()],Ee.prototype,"href",void 0),d([l()],Ee.prototype,"target",void 0),d([k(".list-item")],Ee.prototype,"listItemRoot",void 0);/**
|
|
892
892
|
* @license
|
|
893
893
|
* Copyright 2024 Google LLC
|
|
894
894
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -897,19 +897,19 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
897
897
|
* @license
|
|
898
898
|
* Copyright 2022 Google LLC
|
|
899
899
|
* SPDX-License-Identifier: Apache-2.0
|
|
900
|
-
*/let Ui=class extends
|
|
900
|
+
*/let Ui=class extends Ee{};Ui.styles=[vl],Ui=d([b("md-list-item")],Ui);/**
|
|
901
901
|
* @license
|
|
902
902
|
* Copyright 2018 Google LLC
|
|
903
903
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
904
|
-
*/const
|
|
904
|
+
*/const wa="important",fl=" !"+wa,ot=Si(class extends ki{constructor(o){var e;if(super(o),o.type!==Be.ATTRIBUTE||o.name!=="style"||((e=o.strings)==null?void 0:e.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((e,t)=>{const r=o[t];return r==null?e:e+`${t=t.includes("-")?t:t.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${r};`},"")}update(o,[e]){const{style:t}=o.element;if(this.ft===void 0)return this.ft=new Set(Object.keys(e)),this.render(e);for(const r of this.ft)e[r]==null&&(this.ft.delete(r),r.includes("-")?t.removeProperty(r):t[r]=null);for(const r in e){const i=e[r];if(i!=null){this.ft.add(r);const s=typeof i=="string"&&i.endsWith(fl);r.includes("-")||s?t.setProperty(r,s?i.slice(0,-11):i,s?wa:""):t[r]=i}}return oe}});/**
|
|
905
905
|
* @license
|
|
906
906
|
* Copyright 2023 Google LLC
|
|
907
907
|
* SPDX-License-Identifier: Apache-2.0
|
|
908
|
-
*/function ml(o,e){return new CustomEvent("close-menu",{bubbles:!0,composed:!0,detail:{initiator:o,reason:e,itemPath:[o]}})}const
|
|
908
|
+
*/function ml(o,e){return new CustomEvent("close-menu",{bubbles:!0,composed:!0,detail:{initiator:o,reason:e,itemPath:[o]}})}const Sa=ml;function bl(){return new Event("deactivate-typeahead",{bubbles:!0,composed:!0})}function ji(){return new Event("activate-typeahead",{bubbles:!0,composed:!0})}const He={RIGHT:"ArrowRight",LEFT:"ArrowLeft"},mt={SPACE:"Space",ENTER:"Enter"},Wi={CLICK_SELECTION:"click-selection",KEYDOWN:"keydown"},Gi={ESCAPE:"Escape",SPACE:mt.SPACE,ENTER:mt.ENTER};function ka(o){return Object.values(Gi).some(e=>e===o)}function gl(o){return Object.values(mt).some(e=>e===o)}function Ki(o,e){const t=new Event("md-contains",{bubbles:!0,composed:!0});let r=[];const i=n=>{r=n.composedPath()};return e.addEventListener("md-contains",i),o.dispatchEvent(t),e.removeEventListener("md-contains",i),r.length>0}const pe={NONE:"none",LIST_ROOT:"list-root",FIRST_ITEM:"first-item",LAST_ITEM:"last-item"};/**
|
|
909
909
|
* @license
|
|
910
910
|
* Copyright 2023 Google LLC
|
|
911
911
|
* SPDX-License-Identifier: Apache-2.0
|
|
912
|
-
*/const
|
|
912
|
+
*/const Dr={END_START:"end-start",START_START:"start-start",START_END:"start-end"};class yl{constructor(e,t){this.host=e,this.getProperties=t,this.surfaceStylesInternal={display:"none"},this.lastValues={isOpen:!1},this.host.addController(this)}get surfaceStyles(){return this.surfaceStylesInternal}async position(){const{surfaceEl:e,anchorEl:t,anchorCorner:r,surfaceCorner:i,positioning:s,xOffset:n,yOffset:h,repositionStrategy:u}=this.getProperties(),m=r.toLowerCase().trim(),y=i.toLowerCase().trim();if(!e||!t)return;const v=window.innerWidth,x=window.innerHeight,_=document.createElement("div");_.style.opacity="0",_.style.position="fixed",_.style.display="block",_.style.inset="0",document.body.appendChild(_);const S=_.getBoundingClientRect();_.remove();const C=window.innerHeight-S.bottom,A=window.innerWidth-S.right;this.surfaceStylesInternal={display:"block",opacity:"0"},this.host.requestUpdate(),await this.host.updateComplete,e.popover&&e.isConnected&&e.showPopover();const I=e.getSurfacePositionClientRect?e.getSurfacePositionClientRect():e.getBoundingClientRect(),z=t.getSurfacePositionClientRect?t.getSurfacePositionClientRect():t.getBoundingClientRect(),[ie,j]=y.split("-"),[M,We]=m.split("-"),Ge=getComputedStyle(e).direction==="ltr";let{blockInset:Pe,blockOutOfBoundsCorrection:Ke,surfaceBlockProperty:di}=this.calculateBlock({surfaceRect:I,anchorRect:z,anchorBlock:M,surfaceBlock:ie,yOffset:h,positioning:s,windowInnerHeight:x,blockScrollbarHeight:C});if(Ke){const zo=ie==="start"?"end":"start",Oo=M==="start"?"end":"start",Le=this.calculateBlock({surfaceRect:I,anchorRect:z,anchorBlock:Oo,surfaceBlock:zo,yOffset:h,positioning:s,windowInnerHeight:x,blockScrollbarHeight:C});Ke>Le.blockOutOfBoundsCorrection&&(Pe=Le.blockInset,Ke=Le.blockOutOfBoundsCorrection,di=Le.surfaceBlockProperty)}let{inlineInset:Ye,inlineOutOfBoundsCorrection:At,surfaceInlineProperty:_s}=this.calculateInline({surfaceRect:I,anchorRect:z,anchorInline:We,surfaceInline:j,xOffset:n,positioning:s,isLTR:Ge,windowInnerWidth:v,inlineScrollbarWidth:A});if(At){const zo=j==="start"?"end":"start",Oo=We==="start"?"end":"start",Le=this.calculateInline({surfaceRect:I,anchorRect:z,anchorInline:Oo,surfaceInline:zo,xOffset:n,positioning:s,isLTR:Ge,windowInnerWidth:v,inlineScrollbarWidth:A});Math.abs(At)>Math.abs(Le.inlineOutOfBoundsCorrection)&&(Ye=Le.inlineInset,At=Le.inlineOutOfBoundsCorrection,_s=Le.surfaceInlineProperty)}u==="move"&&(Pe=Pe-Ke,Ye=Ye-At),this.surfaceStylesInternal={display:"block",opacity:"1",[di]:`${Pe}px`,[_s]:`${Ye}px`},u==="resize"&&(Ke&&(this.surfaceStylesInternal.height=`${I.height-Ke}px`),At&&(this.surfaceStylesInternal.width=`${I.width-At}px`)),this.host.requestUpdate()}calculateBlock(e){const{surfaceRect:t,anchorRect:r,anchorBlock:i,surfaceBlock:s,yOffset:n,positioning:h,windowInnerHeight:u,blockScrollbarHeight:m}=e,y=h==="fixed"||h==="document"?1:0,v=h==="document"?1:0,x=s==="start"?1:0,_=s==="end"?1:0,C=(i!==s?1:0)*r.height+n,A=x*r.top+_*(u-r.bottom-m),I=x*window.scrollY-_*window.scrollY,z=Math.abs(Math.min(0,u-A-C-t.height));return{blockInset:y*A+v*I+C,blockOutOfBoundsCorrection:z,surfaceBlockProperty:s==="start"?"inset-block-start":"inset-block-end"}}calculateInline(e){const{isLTR:t,surfaceInline:r,anchorInline:i,anchorRect:s,surfaceRect:n,xOffset:h,positioning:u,windowInnerWidth:m,inlineScrollbarWidth:y}=e,v=u==="fixed"||u==="document"?1:0,x=u==="document"?1:0,_=t?1:0,S=t?0:1,C=r==="start"?1:0,A=r==="end"?1:0,z=(i!==r?1:0)*s.width+h,ie=C*s.left+A*(m-s.right-y),j=C*(m-s.right-y)+A*s.left,M=_*ie+S*j,We=C*window.scrollX-A*window.scrollX,Ge=A*window.scrollX-C*window.scrollX,Pe=_*We+S*Ge,Ke=Math.abs(Math.min(0,m-M-z-n.width)),di=v*M+z+x*Pe;let Ye=r==="start"?"inset-inline-start":"inset-inline-end";return(u==="document"||u==="fixed")&&(r==="start"&&t||r==="end"&&!t?Ye="left":Ye="right"),{inlineInset:di,inlineOutOfBoundsCorrection:Ke,surfaceInlineProperty:Ye}}hostUpdate(){this.onUpdate()}hostUpdated(){this.onUpdate()}async onUpdate(){const e=this.getProperties();let t=!1;for(const[n,h]of Object.entries(e))if(t=t||h!==this.lastValues[n],t)break;const r=this.lastValues.isOpen!==e.isOpen,i=!!e.anchorEl,s=!!e.surfaceEl;t&&i&&s&&(this.lastValues.isOpen=e.isOpen,e.isOpen?(this.lastValues=e,await this.position(),e.onOpen()):r&&(await e.beforeClose(),this.close(),e.onClose()))}close(){this.surfaceStylesInternal={display:"none"},this.host.requestUpdate();const e=this.getProperties().surfaceEl;e!=null&&e.popover&&(e!=null&&e.isConnected)&&e.hidePopover()}}/**
|
|
913
913
|
* @license
|
|
914
914
|
* Copyright 2023 Google LLC
|
|
915
915
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -917,7 +917,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
917
917
|
* @license
|
|
918
918
|
* Copyright 2023 Google LLC
|
|
919
919
|
* SPDX-License-Identifier: Apache-2.0
|
|
920
|
-
*/const
|
|
920
|
+
*/const $a=200,Ca=new Set([U.ArrowDown,U.ArrowUp,U.Home,U.End]),_l=new Set([U.ArrowLeft,U.ArrowRight,...Ca]);function wl(o=document){var t;let e=o.activeElement;for(;e&&((t=e==null?void 0:e.shadowRoot)!=null&&t.activeElement);)e=e.shadowRoot.activeElement;return e}class B extends g{get openDirection(){return this.menuCorner.split("-")[0]==="start"?"DOWN":"UP"}get anchorElement(){return this.anchor?this.getRootNode().querySelector(`#${this.anchor}`):this.currentAnchorElement}set anchorElement(e){this.currentAnchorElement=e,this.requestUpdate("anchorElement")}constructor(){super(),this.anchor="",this.positioning="absolute",this.quick=!1,this.hasOverflow=!1,this.open=!1,this.xOffset=0,this.yOffset=0,this.typeaheadDelay=$a,this.anchorCorner=Dr.END_START,this.menuCorner=Dr.START_START,this.stayOpenOnOutsideClick=!1,this.stayOpenOnFocusout=!1,this.skipRestoreFocus=!1,this.defaultFocus=pe.FIRST_ITEM,this.noNavigationWrap=!1,this.typeaheadActive=!0,this.isSubmenu=!1,this.pointerPath=[],this.isRepositioning=!1,this.openCloseAnimationSignal=Ys(),this.listController=new xa({isItem:e=>e.hasAttribute("md-menu-item"),getPossibleItems:()=>this.slotItems,isRtl:()=>getComputedStyle(this).direction==="rtl",deactivateItem:e=>{e.selected=!1,e.tabIndex=-1},activateItem:e=>{e.selected=!0,e.tabIndex=0},isNavigableKey:e=>{if(!this.isSubmenu)return _l.has(e);const r=getComputedStyle(this).direction==="rtl"?U.ArrowLeft:U.ArrowRight;return e===r?!0:Ca.has(e)},wrapNavigation:()=>!this.noNavigationWrap}),this.lastFocusedElement=null,this.typeaheadController=new xl(()=>({getItems:()=>this.items,typeaheadBufferTime:this.typeaheadDelay,active:this.typeaheadActive})),this.currentAnchorElement=null,this.internals=this.attachInternals(),this.menuPositionController=new yl(this,()=>({anchorCorner:this.anchorCorner,surfaceCorner:this.menuCorner,surfaceEl:this.surfaceEl,anchorEl:this.anchorElement,positioning:this.positioning==="popover"?"document":this.positioning,isOpen:this.open,xOffset:this.xOffset,yOffset:this.yOffset,onOpen:this.onOpened,beforeClose:this.beforeClose,onClose:this.onClosed,repositionStrategy:this.hasOverflow&&this.positioning!=="popover"?"move":"resize"})),this.onWindowResize=()=>{this.isRepositioning||this.positioning!=="document"&&this.positioning!=="fixed"&&this.positioning!=="popover"||(this.isRepositioning=!0,this.reposition(),this.isRepositioning=!1)},this.handleFocusout=async e=>{const t=this.anchorElement;if(this.stayOpenOnFocusout||!this.open||this.pointerPath.includes(t))return;if(e.relatedTarget){if(Ki(e.relatedTarget,this)||this.pointerPath.length!==0&&Ki(e.relatedTarget,t))return}else if(this.pointerPath.includes(this))return;const r=this.skipRestoreFocus;this.skipRestoreFocus=!0,this.close(),await this.updateComplete,this.skipRestoreFocus=r},this.onOpened=async()=>{this.lastFocusedElement=wl();const e=this.items,t=ft(e);t&&this.defaultFocus!==pe.NONE&&(t.item.tabIndex=-1);let r=!this.quick;switch(this.quick?this.dispatchEvent(new Event("opening")):r=!!await this.animateOpen(),this.defaultFocus){case pe.FIRST_ITEM:const i=Or(e);i&&(i.tabIndex=0,i.focus(),await i.updateComplete);break;case pe.LAST_ITEM:const s=ma(e);s&&(s.tabIndex=0,s.focus(),await s.updateComplete);break;case pe.LIST_ROOT:this.focus();break;default:case pe.NONE:break}r||this.dispatchEvent(new Event("opened"))},this.beforeClose=async()=>{var e,t;this.open=!1,this.skipRestoreFocus||(t=(e=this.lastFocusedElement)==null?void 0:e.focus)==null||t.call(e),this.quick||await this.animateClose()},this.onClosed=()=>{this.quick&&(this.dispatchEvent(new Event("closing")),this.dispatchEvent(new Event("closed")))},this.onWindowPointerdown=e=>{this.pointerPath=e.composedPath()},this.onDocumentClick=e=>{if(!this.open)return;const t=e.composedPath();!this.stayOpenOnOutsideClick&&!t.includes(this)&&!t.includes(this.anchorElement)&&(this.open=!1)},this.internals.role="menu",this.addEventListener("keydown",this.handleKeydown),this.addEventListener("keydown",this.captureKeydown,{capture:!0}),this.addEventListener("focusout",this.handleFocusout)}get items(){return this.listController.items}willUpdate(e){if(e.has("open")){if(this.open){this.removeAttribute("aria-hidden");return}this.setAttribute("aria-hidden","true")}}update(e){e.has("open")&&(this.open?this.setUpGlobalEventListeners():this.cleanUpGlobalEventListeners()),e.has("positioning")&&this.positioning==="popover"&&!this.showPopover&&(this.positioning="fixed"),super.update(e)}connectedCallback(){super.connectedCallback(),this.open&&this.setUpGlobalEventListeners()}disconnectedCallback(){super.disconnectedCallback(),this.cleanUpGlobalEventListeners()}getBoundingClientRect(){return this.surfaceEl?this.surfaceEl.getBoundingClientRect():super.getBoundingClientRect()}getClientRects(){return this.surfaceEl?this.surfaceEl.getClientRects():super.getClientRects()}render(){return this.renderSurface()}renderSurface(){return c`
|
|
921
921
|
<div
|
|
922
922
|
class="menu ${P(this.getSurfaceClasses())}"
|
|
923
923
|
style=${ot(this.menuPositionController.surfaceStyles)}
|
|
@@ -935,7 +935,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
935
935
|
@activate-typeahead=${this.handleActivateTypeahead}
|
|
936
936
|
@stay-open-on-focusout=${this.handleStayOpenOnFocusout}
|
|
937
937
|
@close-on-focusout=${this.handleCloseOnFocusout}
|
|
938
|
-
@slotchange=${this.listController.onSlotchange}></slot>`}renderElevation(){return c`<md-elevation part="elevation"></md-elevation>`}getSurfaceClasses(){return{open:this.open,fixed:this.positioning==="fixed","has-overflow":this.hasOverflow}}captureKeydown(e){e.target===this&&!e.defaultPrevented&&
|
|
938
|
+
@slotchange=${this.listController.onSlotchange}></slot>`}renderElevation(){return c`<md-elevation part="elevation"></md-elevation>`}getSurfaceClasses(){return{open:this.open,fixed:this.positioning==="fixed","has-overflow":this.hasOverflow}}captureKeydown(e){e.target===this&&!e.defaultPrevented&&ka(e.code)&&(e.preventDefault(),this.close()),this.typeaheadController.onKeydown(e)}async animateOpen(){const e=this.surfaceEl,t=this.slotEl;if(!e||!t)return!0;const r=this.openDirection;this.dispatchEvent(new Event("opening")),e.classList.toggle("animating",!0);const i=this.openCloseAnimationSignal.start(),s=e.offsetHeight,n=r==="UP",h=this.items,u=500,m=50,y=250,v=(u-y)/h.length,x=e.animate([{height:"0px"},{height:`${s}px`}],{duration:u,easing:de.EMPHASIZED}),_=t.animate([{transform:n?`translateY(-${s}px)`:""},{transform:""}],{duration:u,easing:de.EMPHASIZED}),S=e.animate([{opacity:0},{opacity:1}],m),C=[];for(let z=0;z<h.length;z++){const ie=n?h.length-1-z:z,j=h[ie],M=j.animate([{opacity:0},{opacity:1}],{duration:y,delay:v*z});j.classList.toggle("md-menu-hidden",!0),M.addEventListener("finish",()=>{j.classList.toggle("md-menu-hidden",!1)}),C.push([j,M])}let A=z=>{};const I=new Promise(z=>{A=z});return i.addEventListener("abort",()=>{x.cancel(),_.cancel(),S.cancel(),C.forEach(([z,ie])=>{z.classList.toggle("md-menu-hidden",!1),ie.cancel()}),A(!0)}),x.addEventListener("finish",()=>{e.classList.toggle("animating",!1),this.openCloseAnimationSignal.finish(),A(!1)}),await I}animateClose(){let e;const t=new Promise(M=>{e=M}),r=this.surfaceEl,i=this.slotEl;if(!r||!i)return e(!1),t;const n=this.openDirection==="UP";this.dispatchEvent(new Event("closing")),r.classList.toggle("animating",!0);const h=this.openCloseAnimationSignal.start(),u=r.offsetHeight,m=this.items,y=150,v=50,x=y-v,_=50,S=50,C=.35,A=(y-S-_)/m.length,I=r.animate([{height:`${u}px`},{height:`${u*C}px`}],{duration:y,easing:de.EMPHASIZED_ACCELERATE}),z=i.animate([{transform:""},{transform:n?`translateY(-${u*(1-C)}px)`:""}],{duration:y,easing:de.EMPHASIZED_ACCELERATE}),ie=r.animate([{opacity:1},{opacity:0}],{duration:v,delay:x}),j=[];for(let M=0;M<m.length;M++){const We=n?M:m.length-1-M,Ge=m[We],Pe=Ge.animate([{opacity:1},{opacity:0}],{duration:_,delay:S+A*M});Pe.addEventListener("finish",()=>{Ge.classList.toggle("md-menu-hidden",!0)}),j.push([Ge,Pe])}return h.addEventListener("abort",()=>{I.cancel(),z.cancel(),ie.cancel(),j.forEach(([M,We])=>{We.cancel(),M.classList.toggle("md-menu-hidden",!1)}),e(!1)}),I.addEventListener("finish",()=>{r.classList.toggle("animating",!1),j.forEach(([M])=>{M.classList.toggle("md-menu-hidden",!1)}),this.openCloseAnimationSignal.finish(),this.dispatchEvent(new Event("closed")),e(!0)}),t}handleKeydown(e){this.pointerPath=[],this.listController.handleKeydown(e)}setUpGlobalEventListeners(){document.addEventListener("click",this.onDocumentClick,{capture:!0}),window.addEventListener("pointerdown",this.onWindowPointerdown),document.addEventListener("resize",this.onWindowResize,{passive:!0}),window.addEventListener("resize",this.onWindowResize,{passive:!0})}cleanUpGlobalEventListeners(){document.removeEventListener("click",this.onDocumentClick,{capture:!0}),window.removeEventListener("pointerdown",this.onWindowPointerdown),document.removeEventListener("resize",this.onWindowResize),window.removeEventListener("resize",this.onWindowResize)}onCloseMenu(){this.close()}onDeactivateItems(e){e.stopPropagation(),this.listController.onDeactivateItems()}onRequestActivation(e){e.stopPropagation(),this.listController.onRequestActivation(e)}handleDeactivateTypeahead(e){e.stopPropagation(),this.typeaheadActive=!1}handleActivateTypeahead(e){e.stopPropagation(),this.typeaheadActive=!0}handleStayOpenOnFocusout(e){e.stopPropagation(),this.stayOpenOnFocusout=!0}handleCloseOnFocusout(e){e.stopPropagation(),this.stayOpenOnFocusout=!1}close(){this.open=!1,this.slotItems.forEach(t=>{var r;(r=t.close)==null||r.call(t)})}show(){this.open=!0}activateNextItem(){return this.listController.activateNextItem()??null}activatePreviousItem(){return this.listController.activatePreviousItem()??null}reposition(){this.open&&this.menuPositionController.position()}}d([k(".menu")],B.prototype,"surfaceEl",void 0),d([k("slot")],B.prototype,"slotEl",void 0),d([l()],B.prototype,"anchor",void 0),d([l()],B.prototype,"positioning",void 0),d([l({type:Boolean})],B.prototype,"quick",void 0),d([l({type:Boolean,attribute:"has-overflow"})],B.prototype,"hasOverflow",void 0),d([l({type:Boolean,reflect:!0})],B.prototype,"open",void 0),d([l({type:Number,attribute:"x-offset"})],B.prototype,"xOffset",void 0),d([l({type:Number,attribute:"y-offset"})],B.prototype,"yOffset",void 0),d([l({type:Number,attribute:"typeahead-delay"})],B.prototype,"typeaheadDelay",void 0),d([l({attribute:"anchor-corner"})],B.prototype,"anchorCorner",void 0),d([l({attribute:"menu-corner"})],B.prototype,"menuCorner",void 0),d([l({type:Boolean,attribute:"stay-open-on-outside-click"})],B.prototype,"stayOpenOnOutsideClick",void 0),d([l({type:Boolean,attribute:"stay-open-on-focusout"})],B.prototype,"stayOpenOnFocusout",void 0),d([l({type:Boolean,attribute:"skip-restore-focus"})],B.prototype,"skipRestoreFocus",void 0),d([l({attribute:"default-focus"})],B.prototype,"defaultFocus",void 0),d([l({type:Boolean,attribute:"no-navigation-wrap"})],B.prototype,"noNavigationWrap",void 0),d([W({flatten:!0})],B.prototype,"slotItems",void 0),d([w()],B.prototype,"typeaheadActive",void 0);/**
|
|
939
939
|
* @license
|
|
940
940
|
* Copyright 2024 Google LLC
|
|
941
941
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -948,11 +948,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
948
948
|
* @license
|
|
949
949
|
* Copyright 2023 Google LLC
|
|
950
950
|
* SPDX-License-Identifier: Apache-2.0
|
|
951
|
-
*/class
|
|
951
|
+
*/class Ea{constructor(e,t){this.host=e,this.internalTypeaheadText=null,this.onClick=()=>{this.host.keepOpen||this.host.dispatchEvent(Sa(this.host,{kind:Wi.CLICK_SELECTION}))},this.onKeydown=r=>{if(this.host.href&&r.code==="Enter"){const s=this.getInteractiveElement();s instanceof HTMLAnchorElement&&s.click()}if(r.defaultPrevented)return;const i=r.code;this.host.keepOpen&&i!=="Escape"||ka(i)&&(r.preventDefault(),this.host.dispatchEvent(Sa(this.host,{kind:Wi.KEYDOWN,key:i})))},this.getHeadlineElements=t.getHeadlineElements,this.getSupportingTextElements=t.getSupportingTextElements,this.getDefaultElements=t.getDefaultElements,this.getInteractiveElement=t.getInteractiveElement,this.host.addController(this)}get typeaheadText(){if(this.internalTypeaheadText!==null)return this.internalTypeaheadText;const e=this.getHeadlineElements(),t=[];return e.forEach(r=>{r.textContent&&r.textContent.trim()&&t.push(r.textContent.trim())}),t.length===0&&this.getDefaultElements().forEach(r=>{r.textContent&&r.textContent.trim()&&t.push(r.textContent.trim())}),t.length===0&&this.getSupportingTextElements().forEach(r=>{r.textContent&&r.textContent.trim()&&t.push(r.textContent.trim())}),t.join(" ")}get tagName(){switch(this.host.type){case"link":return"a";case"button":return"button";default:case"menuitem":case"option":return"li"}}get role(){return this.host.type==="option"?"option":"menuitem"}hostConnected(){this.host.toggleAttribute("md-menu-item",!0)}hostUpdate(){this.host.href&&(this.host.type="link")}setTypeaheadText(e){this.internalTypeaheadText=e}}/**
|
|
952
952
|
* @license
|
|
953
953
|
* Copyright 2022 Google LLC
|
|
954
954
|
* SPDX-License-Identifier: Apache-2.0
|
|
955
|
-
*/class J extends g{constructor(){super(...arguments),this.disabled=!1,this.type="menuitem",this.href="",this.target="",this.keepOpen=!1,this.selected=!1,this.menuItemController=new
|
|
955
|
+
*/class J extends g{constructor(){super(...arguments),this.disabled=!1,this.type="menuitem",this.href="",this.target="",this.keepOpen=!1,this.selected=!1,this.menuItemController=new Ea(this,{getHeadlineElements:()=>this.headlineElements,getSupportingTextElements:()=>this.supportingTextElements,getDefaultElements:()=>this.defaultElements,getInteractiveElement:()=>this.listItemRoot})}get typeaheadText(){return this.menuItemController.typeaheadText}set typeaheadText(e){this.menuItemController.setTypeaheadText(e)}render(){return this.renderListItem(c`
|
|
956
956
|
<md-item>
|
|
957
957
|
<div slot="container">
|
|
958
958
|
${this.renderRipple()} ${this.renderFocusRing()}
|
|
@@ -995,16 +995,16 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
995
995
|
* @license
|
|
996
996
|
* Copyright 2024 Google LLC
|
|
997
997
|
* SPDX-License-Identifier: Apache-2.0
|
|
998
|
-
*/const
|
|
998
|
+
*/const Aa=f`:host{display:flex;--md-ripple-hover-color: var(--md-menu-item-hover-state-layer-color, var(--md-sys-color-on-surface, #1d1b20));--md-ripple-hover-opacity: var(--md-menu-item-hover-state-layer-opacity, 0.08);--md-ripple-pressed-color: var(--md-menu-item-pressed-state-layer-color, var(--md-sys-color-on-surface, #1d1b20));--md-ripple-pressed-opacity: var(--md-menu-item-pressed-state-layer-opacity, 0.12)}:host([disabled]){opacity:var(--md-menu-item-disabled-opacity, 0.3);pointer-events:none}md-focus-ring{z-index:1;--md-focus-ring-shape: 8px}a,button,li{background:none;border:none;padding:0;margin:0;text-align:unset;text-decoration:none}.list-item{border-radius:inherit;display:flex;flex:1;max-width:inherit;min-width:inherit;outline:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}.list-item:not(.disabled){cursor:pointer}[slot=container]{pointer-events:none}md-ripple{border-radius:inherit}md-item{border-radius:inherit;flex:1;color:var(--md-menu-item-label-text-color, var(--md-sys-color-on-surface, #1d1b20));font-family:var(--md-menu-item-label-text-font, var(--md-sys-typescale-body-large-font, var(--md-ref-typeface-plain, Roboto)));font-size:var(--md-menu-item-label-text-size, var(--md-sys-typescale-body-large-size, 1rem));line-height:var(--md-menu-item-label-text-line-height, var(--md-sys-typescale-body-large-line-height, 1.5rem));font-weight:var(--md-menu-item-label-text-weight, var(--md-sys-typescale-body-large-weight, var(--md-ref-typeface-weight-regular, 400)));min-height:var(--md-menu-item-one-line-container-height, 56px);padding-top:var(--md-menu-item-top-space, 12px);padding-bottom:var(--md-menu-item-bottom-space, 12px);padding-inline-start:var(--md-menu-item-leading-space, 16px);padding-inline-end:var(--md-menu-item-trailing-space, 16px)}md-item[multiline]{min-height:var(--md-menu-item-two-line-container-height, 72px)}[slot=supporting-text]{color:var(--md-menu-item-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));font-family:var(--md-menu-item-supporting-text-font, var(--md-sys-typescale-body-medium-font, var(--md-ref-typeface-plain, Roboto)));font-size:var(--md-menu-item-supporting-text-size, var(--md-sys-typescale-body-medium-size, 0.875rem));line-height:var(--md-menu-item-supporting-text-line-height, var(--md-sys-typescale-body-medium-line-height, 1.25rem));font-weight:var(--md-menu-item-supporting-text-weight, var(--md-sys-typescale-body-medium-weight, var(--md-ref-typeface-weight-regular, 400)))}[slot=trailing-supporting-text]{color:var(--md-menu-item-trailing-supporting-text-color, var(--md-sys-color-on-surface-variant, #49454f));font-family:var(--md-menu-item-trailing-supporting-text-font, var(--md-sys-typescale-label-small-font, var(--md-ref-typeface-plain, Roboto)));font-size:var(--md-menu-item-trailing-supporting-text-size, var(--md-sys-typescale-label-small-size, 0.6875rem));line-height:var(--md-menu-item-trailing-supporting-text-line-height, var(--md-sys-typescale-label-small-line-height, 1rem));font-weight:var(--md-menu-item-trailing-supporting-text-weight, var(--md-sys-typescale-label-small-weight, var(--md-ref-typeface-weight-medium, 500)))}:is([slot=start],[slot=end])::slotted(*){fill:currentColor}[slot=start]{color:var(--md-menu-item-leading-icon-color, var(--md-sys-color-on-surface-variant, #49454f))}[slot=end]{color:var(--md-menu-item-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f))}.list-item{background-color:var(--md-menu-item-container-color, transparent)}.list-item.selected{background-color:var(--md-menu-item-selected-container-color, var(--md-sys-color-secondary-container, #e8def8))}.selected:not(.disabled) ::slotted(*){color:var(--md-menu-item-selected-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b))}@media(forced-colors: active){:host([disabled]),:host([disabled]) slot{color:GrayText;opacity:1}.list-item{position:relative}.list-item.selected::before{content:"";position:absolute;inset:0;box-sizing:border-box;border-radius:inherit;pointer-events:none;border:3px double CanvasText}}
|
|
999
999
|
`;/**
|
|
1000
1000
|
* @license
|
|
1001
1001
|
* Copyright 2022 Google LLC
|
|
1002
1002
|
* SPDX-License-Identifier: Apache-2.0
|
|
1003
|
-
*/let Xi=class extends J{};Xi.styles=[
|
|
1003
|
+
*/let Xi=class extends J{};Xi.styles=[Aa],Xi=d([b("md-menu-item")],Xi);/**
|
|
1004
1004
|
* @license
|
|
1005
1005
|
* Copyright 2023 Google LLC
|
|
1006
1006
|
* SPDX-License-Identifier: Apache-2.0
|
|
1007
|
-
*/class
|
|
1007
|
+
*/class Ne extends g{get item(){return this.items[0]??null}get menu(){return this.menus[0]??null}constructor(){super(),this.anchorCorner=Dr.START_END,this.menuCorner=Dr.START_START,this.hoverOpenDelay=400,this.hoverCloseDelay=400,this.isSubMenu=!0,this.previousOpenTimeout=0,this.previousCloseTimeout=0,this.onMouseenter=()=>{var e;clearTimeout(this.previousOpenTimeout),clearTimeout(this.previousCloseTimeout),!((e=this.menu)!=null&&e.open)&&(this.hoverOpenDelay?this.previousOpenTimeout=setTimeout(()=>{this.show()},this.hoverOpenDelay):this.show())},this.onMouseleave=()=>{clearTimeout(this.previousCloseTimeout),clearTimeout(this.previousOpenTimeout),this.hoverCloseDelay?this.previousCloseTimeout=setTimeout(()=>{this.close()},this.hoverCloseDelay):this.close()},this.addEventListener("mouseenter",this.onMouseenter),this.addEventListener("mouseleave",this.onMouseleave)}render(){return c`
|
|
1008
1008
|
<slot
|
|
1009
1009
|
name="item"
|
|
1010
1010
|
@click=${this.onClick}
|
|
@@ -1017,7 +1017,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1017
1017
|
@close-menu=${this.onCloseSubmenu}
|
|
1018
1018
|
@slotchange=${this.onSlotchange}>
|
|
1019
1019
|
</slot>
|
|
1020
|
-
`}firstUpdated(){this.onSlotchange()}async show(){const e=this.menu;if(!e||e.open)return;e.addEventListener("closed",()=>{this.item.ariaExpanded="false",this.dispatchEvent(ji()),this.dispatchEvent(Pr()),e.ariaHidden="true"},{once:!0}),e.positioning==="document"&&(e.positioning="absolute"),e.quick=!0,e.hasOverflow=!0,e.anchorCorner=this.anchorCorner,e.menuCorner=this.menuCorner,e.anchorElement=this.item,e.defaultFocus="first-item",e.removeAttribute("aria-hidden"),e.skipRestoreFocus=!1;const t=e.open;if(e.show(),this.item.ariaExpanded="true",this.item.ariaHasPopup="menu",e.id&&this.item.setAttribute("aria-controls",e.id),this.dispatchEvent(Pr()),this.dispatchEvent(bl()),this.item.selected=!0,!t){let r=s=>{};const i=new Promise(s=>{r=s});e.addEventListener("opened",r,{once:!0}),await i}}async close(){const e=this.menu;if(!e||!e.open)return;this.dispatchEvent(ji()),e.quick=!0,e.close(),this.dispatchEvent(Pr());let t=i=>{};const r=new Promise(i=>{t=i});e.addEventListener("closed",t,{once:!0}),await r}onSlotchange(){var t;if(!this.item)return;this.item.ariaExpanded="false",this.item.ariaHasPopup="menu",(t=this.menu)!=null&&t.id&&this.item.setAttribute("aria-controls",this.menu.id),this.item.keepOpen=!0;const e=this.menu;e&&(e.isSubmenu=!0,e.ariaHidden="true")}onClick(){this.show()}async onKeydown(e){const t=this.isSubmenuOpenKey(e.code);if(e.defaultPrevented)return;const r=t&&(
|
|
1020
|
+
`}firstUpdated(){this.onSlotchange()}async show(){const e=this.menu;if(!e||e.open)return;e.addEventListener("closed",()=>{this.item.ariaExpanded="false",this.dispatchEvent(ji()),this.dispatchEvent(Pr()),e.ariaHidden="true"},{once:!0}),e.positioning==="document"&&(e.positioning="absolute"),e.quick=!0,e.hasOverflow=!0,e.anchorCorner=this.anchorCorner,e.menuCorner=this.menuCorner,e.anchorElement=this.item,e.defaultFocus="first-item",e.removeAttribute("aria-hidden"),e.skipRestoreFocus=!1;const t=e.open;if(e.show(),this.item.ariaExpanded="true",this.item.ariaHasPopup="menu",e.id&&this.item.setAttribute("aria-controls",e.id),this.dispatchEvent(Pr()),this.dispatchEvent(bl()),this.item.selected=!0,!t){let r=s=>{};const i=new Promise(s=>{r=s});e.addEventListener("opened",r,{once:!0}),await i}}async close(){const e=this.menu;if(!e||!e.open)return;this.dispatchEvent(ji()),e.quick=!0,e.close(),this.dispatchEvent(Pr());let t=i=>{};const r=new Promise(i=>{t=i});e.addEventListener("closed",t,{once:!0}),await r}onSlotchange(){var t;if(!this.item)return;this.item.ariaExpanded="false",this.item.ariaHasPopup="menu",(t=this.menu)!=null&&t.id&&this.item.setAttribute("aria-controls",this.menu.id),this.item.keepOpen=!0;const e=this.menu;e&&(e.isSubmenu=!0,e.ariaHidden="true")}onClick(){this.show()}async onKeydown(e){const t=this.isSubmenuOpenKey(e.code);if(e.defaultPrevented)return;const r=t&&(He.LEFT===e.code||He.RIGHT===e.code);if((e.code===mt.SPACE||r)&&(e.preventDefault(),r&&e.stopPropagation()),!t)return;const i=this.menu;if(!i)return;const s=i.items,n=Or(s);if(n){await this.show(),n.tabIndex=0,n.focus();return}}onCloseSubmenu(e){const{itemPath:t,reason:r}=e.detail;if(t.push(this.item),this.dispatchEvent(ji()),r.kind===Wi.KEYDOWN&&r.key===Gi.ESCAPE){e.stopPropagation(),this.item.dispatchEvent(ya());return}this.dispatchEvent(Pr())}async onSubMenuKeydown(e){var i;if(e.defaultPrevented)return;const{close:t,keyCode:r}=this.isSubmenuCloseKey(e.code);t&&(e.preventDefault(),(r===He.LEFT||r===He.RIGHT)&&e.stopPropagation(),await this.close(),sl(this.menu.items),(i=this.item)==null||i.focus(),this.item.tabIndex=0,this.item.focus())}isSubmenuOpenKey(e){const r=getComputedStyle(this).direction==="rtl"?He.LEFT:He.RIGHT;switch(e){case r:case mt.SPACE:case mt.ENTER:return!0;default:return!1}}isSubmenuCloseKey(e){const r=getComputedStyle(this).direction==="rtl"?He.RIGHT:He.LEFT;switch(e){case r:case Gi.ESCAPE:return{close:!0,keyCode:e};default:return{close:!1}}}}d([l({attribute:"anchor-corner"})],Ne.prototype,"anchorCorner",void 0),d([l({attribute:"menu-corner"})],Ne.prototype,"menuCorner",void 0),d([l({type:Number,attribute:"hover-open-delay"})],Ne.prototype,"hoverOpenDelay",void 0),d([l({type:Number,attribute:"hover-close-delay"})],Ne.prototype,"hoverCloseDelay",void 0),d([l({type:Boolean,reflect:!0,attribute:"md-sub-menu"})],Ne.prototype,"isSubMenu",void 0),d([W({slot:"item",flatten:!0})],Ne.prototype,"items",void 0),d([W({slot:"menu",flatten:!0})],Ne.prototype,"menus",void 0);/**
|
|
1021
1021
|
* @license
|
|
1022
1022
|
* Copyright 2024 Google LLC
|
|
1023
1023
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1026,7 +1026,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1026
1026
|
* @license
|
|
1027
1027
|
* Copyright 2023 Google LLC
|
|
1028
1028
|
* SPDX-License-Identifier: Apache-2.0
|
|
1029
|
-
*/let Zi=class extends
|
|
1029
|
+
*/let Zi=class extends Ne{};Zi.styles=[kl],Zi=d([b("md-sub-menu")],Zi);/**
|
|
1030
1030
|
* @license
|
|
1031
1031
|
* Copyright 2023 Google LLC
|
|
1032
1032
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1072,7 +1072,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1072
1072
|
* @license
|
|
1073
1073
|
* Copyright 2023 Google LLC
|
|
1074
1074
|
* SPDX-License-Identifier: Apache-2.0
|
|
1075
|
-
*/class
|
|
1075
|
+
*/class Ia extends at{constructor(){super(...arguments),this.buffer=0}renderIndicator(){const e={transform:`scaleX(${(this.indeterminate?1:this.value/this.max)*100}%)`},t=this.buffer??0,r=t>0,s={transform:`scaleX(${(this.indeterminate||!r?1:t/this.max)*100}%)`},n=this.indeterminate||!r||t>=this.max||this.value>=this.max;return c`
|
|
1076
1076
|
<div class="dots" ?hidden=${n}></div>
|
|
1077
1077
|
<div class="inactive-track" style=${ot(s)}></div>
|
|
1078
1078
|
<div class="bar primary-bar" style=${ot(e)}>
|
|
@@ -1081,7 +1081,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1081
1081
|
<div class="bar secondary-bar">
|
|
1082
1082
|
<div class="bar-inner"></div>
|
|
1083
1083
|
</div>
|
|
1084
|
-
`}}d([l({type:Number})],
|
|
1084
|
+
`}}d([l({type:Number})],Ia.prototype,"buffer",void 0);/**
|
|
1085
1085
|
* @license
|
|
1086
1086
|
* Copyright 2024 Google LLC
|
|
1087
1087
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1090,11 +1090,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1090
1090
|
* @license
|
|
1091
1091
|
* Copyright 2023 Google LLC
|
|
1092
1092
|
* SPDX-License-Identifier: Apache-2.0
|
|
1093
|
-
*/let Qi=class extends
|
|
1093
|
+
*/let Qi=class extends Ia{};Qi.styles=[El],Qi=d([b("md-linear-progress")],Qi);/**
|
|
1094
1094
|
* @license
|
|
1095
1095
|
* Copyright 2023 Google LLC
|
|
1096
1096
|
* SPDX-License-Identifier: Apache-2.0
|
|
1097
|
-
*/const
|
|
1097
|
+
*/const Rr=Symbol("isFocusable"),eo=Symbol("privateIsFocusable"),Br=Symbol("externalTabIndex"),Mr=Symbol("isUpdatingTabIndex"),Fr=Symbol("updateTabIndex");function Ta(o){var e,t,r;class i extends o{constructor(){super(...arguments),this[e]=!0,this[t]=null,this[r]=!1}get[Rr](){return this[eo]}set[Rr](n){this[Rr]!==n&&(this[eo]=n,this[Fr]())}connectedCallback(){super.connectedCallback(),this[Fr]()}attributeChangedCallback(n,h,u){if(n!=="tabindex"){super.attributeChangedCallback(n,h,u);return}if(this.requestUpdate("tabIndex",Number(h??-1)),!this[Mr]){if(!this.hasAttribute("tabindex")){this[Br]=null,this[Fr]();return}this[Br]=this.tabIndex}}[(e=eo,t=Br,r=Mr,Fr)](){const n=this[Rr]?0:-1,h=this[Br]??n;this[Mr]=!0,this.tabIndex=h,this[Mr]=!1}}return d([l({noAccessor:!0})],i.prototype,"tabIndex",void 0),i}/**
|
|
1098
1098
|
* @license
|
|
1099
1099
|
* Copyright 2023 Google LLC
|
|
1100
1100
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1106,7 +1106,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1106
1106
|
* @license
|
|
1107
1107
|
* Copyright 2018 Google LLC
|
|
1108
1108
|
* SPDX-License-Identifier: Apache-2.0
|
|
1109
|
-
*/var
|
|
1109
|
+
*/var za;const to=Symbol("checked");let Tl=0;const zl=Ht(ut(Me(Ta(g))));class Ut extends zl{get checked(){return this[to]}set checked(e){const t=this.checked;t!==e&&(this[to]=e,this.requestUpdate("checked",t),this.selectionController.handleCheckedChange())}constructor(){super(),this.maskId=`cutout${++Tl}`,this[za]=!1,this.required=!1,this.value="on",this.selectionController=new Il(this),this.addController(this.selectionController),this[V].role="radio",this.addEventListener("click",this.handleClick.bind(this)),this.addEventListener("keydown",this.handleKeydown.bind(this))}render(){const e={checked:this.checked};return c`
|
|
1110
1110
|
<div class="container ${P(e)}" aria-hidden="true">
|
|
1111
1111
|
<md-ripple
|
|
1112
1112
|
part="ripple"
|
|
@@ -1135,7 +1135,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1135
1135
|
.value=${this.value}
|
|
1136
1136
|
?disabled=${this.disabled} />
|
|
1137
1137
|
</div>
|
|
1138
|
-
`}updated(){this[V].ariaChecked=String(this.checked)}async handleClick(e){this.disabled||(await 0,!e.defaultPrevented&&(Mt(e)&&this.focus(),this.checked=!0,this.dispatchEvent(new Event("change",{bubbles:!0})),this.dispatchEvent(new InputEvent("input",{bubbles:!0,composed:!0}))))}async handleKeydown(e){await 0,!(e.key!==" "||e.defaultPrevented)&&this.click()}[(
|
|
1138
|
+
`}updated(){this[V].ariaChecked=String(this.checked)}async handleClick(e){this.disabled||(await 0,!e.defaultPrevented&&(Mt(e)&&this.focus(),this.checked=!0,this.dispatchEvent(new Event("change",{bubbles:!0})),this.dispatchEvent(new InputEvent("input",{bubbles:!0,composed:!0}))))}async handleKeydown(e){await 0,!(e.key!==" "||e.defaultPrevented)&&this.click()}[(za=to,$e)](){return this.checked?this.value:null}[Nt](){return String(this.checked)}formResetCallback(){this.checked=this.hasAttribute("checked")}formStateRestoreCallback(e){this.checked=e==="true"}[et](){return new Al(()=>this.selectionController?this.selectionController.controls:[this])}[tt](){return this.container}}d([l({type:Boolean})],Ut.prototype,"checked",null),d([l({type:Boolean})],Ut.prototype,"required",void 0),d([l()],Ut.prototype,"value",void 0),d([k(".container")],Ut.prototype,"container",void 0);/**
|
|
1139
1139
|
* @license
|
|
1140
1140
|
* Copyright 2024 Google LLC
|
|
1141
1141
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1148,11 +1148,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1148
1148
|
* @license
|
|
1149
1149
|
* Copyright 2023 Google LLC
|
|
1150
1150
|
* SPDX-License-Identifier: Apache-2.0
|
|
1151
|
-
*/const Hr=Symbol("onReportValidity"),Nr=Symbol("privateCleanupFormListeners"),qr=Symbol("privateDoNotReportInvalid"),Vr=Symbol("privateIsSelfReportingValidity"),Ur=Symbol("privateCallOnReportValidity");function
|
|
1151
|
+
*/const Hr=Symbol("onReportValidity"),Nr=Symbol("privateCleanupFormListeners"),qr=Symbol("privateDoNotReportInvalid"),Vr=Symbol("privateIsSelfReportingValidity"),Ur=Symbol("privateCallOnReportValidity");function Oa(o){var e,t,r;class i extends o{constructor(...n){super(...n),this[e]=new AbortController,this[t]=!1,this[r]=!1,this.addEventListener("invalid",h=>{this[qr]||!h.isTrusted||this.addEventListener("invalid",()=>{this[Ur](h)},{once:!0})},{capture:!0})}checkValidity(){this[qr]=!0;const n=super.checkValidity();return this[qr]=!1,n}reportValidity(){this[Vr]=!0;const n=super.reportValidity();return n&&this[Ur](null),this[Vr]=!1,n}[(e=Nr,t=qr,r=Vr,Ur)](n){const h=n==null?void 0:n.defaultPrevented;h||(this[Hr](n),!(!h&&(n==null?void 0:n.defaultPrevented)))||(this[Vr]||Dl(this[V].form,this))&&this.focus()}[Hr](n){throw new Error("Implement [onReportValidity]")}formAssociatedCallback(n){super.formAssociatedCallback&&super.formAssociatedCallback(n),this[Nr].abort(),n&&(this[Nr]=new AbortController,Pl(this,n,()=>{this[Ur](null)},this[Nr].signal))}}return i}function Pl(o,e,t,r){const i=Ll(e);let s=!1,n,h=!1;i.addEventListener("before",()=>{h=!0,n=new AbortController,s=!1,o.addEventListener("invalid",()=>{s=!0},{signal:n.signal})},{signal:r}),i.addEventListener("after",()=>{h=!1,n==null||n.abort(),!s&&t()},{signal:r}),e.addEventListener("submit",()=>{h||t()},{signal:r})}const io=new WeakMap;function Ll(o){if(!io.has(o)){const e=new EventTarget;io.set(o,e);for(const t of["reportValidity","requestSubmit"]){const r=o[t];o[t]=function(){e.dispatchEvent(new Event("before"));const i=Reflect.apply(r,this,arguments);return e.dispatchEvent(new Event("after")),i}}}return io.get(o)}function Dl(o,e){if(!o)return!0;let t;for(const r of o.elements)if(r.matches(":invalid")){t=r;break}return t===e}/**
|
|
1152
1152
|
* @license
|
|
1153
1153
|
* Copyright 2023 Google LLC
|
|
1154
1154
|
* SPDX-License-Identifier: Apache-2.0
|
|
1155
|
-
*/class
|
|
1155
|
+
*/class Rl extends yr{computeValidity(e){return this.selectControl||(this.selectControl=document.createElement("select")),yi(c`<option value=${e.value}></option>`,this.selectControl),this.selectControl.value=e.value,this.selectControl.required=e.required,{validity:this.selectControl.validity,validationMessage:this.selectControl.validationMessage}}equals(e,t){return e.value===t.value&&e.required===t.required}copy({value:e,required:t}){return{value:e,required:t}}}/**
|
|
1156
1156
|
* @license
|
|
1157
1157
|
* Copyright 2023 Google LLC
|
|
1158
1158
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1160,7 +1160,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1160
1160
|
* @license
|
|
1161
1161
|
* Copyright 2023 Google LLC
|
|
1162
1162
|
* SPDX-License-Identifier: Apache-2.0
|
|
1163
|
-
*/var
|
|
1163
|
+
*/var Pa;const jr=Symbol("value"),Ml=Oa(Ht(ut(Me(g))));class O extends Ml{get value(){return this[jr]}set value(e){this.lastUserSetValue=e,this.select(e)}get options(){var e;return((e=this.menu)==null?void 0:e.items)??[]}get selectedIndex(){const[e,t]=(this.getSelectedOptions()??[])[0]??[];return t??-1}set selectedIndex(e){this.lastUserSetSelectedIndex=e,this.selectIndex(e)}get selectedOptions(){return(this.getSelectedOptions()??[]).map(([e])=>e)}get hasError(){return this.error||this.nativeError}constructor(){super(),this.quick=!1,this.required=!1,this.errorText="",this.label="",this.noAsterisk=!1,this.supportingText="",this.error=!1,this.menuPositioning="popover",this.clampMenuWidth=!1,this.typeaheadDelay=$a,this.hasLeadingIcon=!1,this.displayText="",this.menuAlign="start",this[Pa]="",this.lastUserSetValue=null,this.lastUserSetSelectedIndex=null,this.lastSelectedOption=null,this.lastSelectedOptionRecords=[],this.nativeError=!1,this.nativeErrorText="",this.focused=!1,this.open=!1,this.defaultFocus=pe.NONE,this.prevOpen=this.open,this.selectWidth=0,this.addEventListener("focus",this.handleFocus.bind(this)),this.addEventListener("blur",this.handleBlur.bind(this))}select(e){const t=this.options.find(r=>r.value===e);t&&this.selectItem(t)}selectIndex(e){const t=this.options[e];t&&this.selectItem(t)}reset(){for(const e of this.options)e.selected=e.hasAttribute("selected");this.updateValueAndDisplayText(),this.nativeError=!1,this.nativeErrorText=""}[(Pa=jr,Hr)](e){var r;e==null||e.preventDefault();const t=this.getErrorText();this.nativeError=!!e,this.nativeErrorText=this.validationMessage,t===this.getErrorText()&&((r=this.field)==null||r.reannounceError())}update(e){if(this.hasUpdated||this.initUserSelection(),this.prevOpen!==this.open&&this.open){const t=this.getBoundingClientRect();this.selectWidth=t.width}this.prevOpen=this.open,super.update(e)}render(){return c`
|
|
1164
1164
|
<span
|
|
1165
1165
|
class="select ${P(this.getRenderClasses())}"
|
|
1166
1166
|
@focusout=${this.handleFocusout}>
|
|
@@ -1242,7 +1242,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1242
1242
|
@request-deselection=${this.handleRequestDeselection}>
|
|
1243
1243
|
${this.renderMenuContent()}
|
|
1244
1244
|
</md-menu>
|
|
1245
|
-
</div>`}renderMenuContent(){return c`<slot></slot>`}handleKeydown(e){var s,n;if(this.open||this.disabled||!this.menu)return;const t=this.menu.typeaheadController,r=e.code==="Space"||e.code==="ArrowDown"||e.code==="ArrowUp"||e.code==="End"||e.code==="Home"||e.code==="Enter";if(!t.isTypingAhead&&r){switch(e.preventDefault(),this.open=!0,e.code){case"Space":case"ArrowDown":case"Enter":this.defaultFocus=pe.NONE;break;case"End":this.defaultFocus=pe.LAST_ITEM;break;case"ArrowUp":case"Home":this.defaultFocus=pe.FIRST_ITEM;break}return}if(e.key.length===1){t.onKeydown(e),e.preventDefault();const{lastActiveRecord:h}=t;if(!h)return;(n=(s=this.labelEl)==null?void 0:s.setAttribute)==null||n.call(s,"aria-live","polite"),this.selectItem(h[ae.ITEM])&&this.dispatchInteractionEvents()}}handleClick(){this.open=!this.open}handleFocus(){this.focused=!0}handleBlur(){this.focused=!1}handleFocusout(e){e.relatedTarget&&Ki(e.relatedTarget,this)||(this.open=!1)}getSelectedOptions(){if(!this.menu)return this.lastSelectedOptionRecords=[],null;const e=this.menu.items;return this.lastSelectedOptionRecords=Bl(e),this.lastSelectedOptionRecords}async getUpdateComplete(){var e;return await((e=this.menu)==null?void 0:e.updateComplete),super.getUpdateComplete()}updateValueAndDisplayText(){const e=this.getSelectedOptions()??[];let t=!1;if(e.length){const[r]=e[0];t=this.lastSelectedOption!==r,this.lastSelectedOption=r,this[jr]=r.value,this.displayText=r.displayText}else t=this.lastSelectedOption!==null,this.lastSelectedOption=null,this[jr]="",this.displayText="";return t}async handleOpening(e){var s,n,h;if((n=(s=this.labelEl)==null?void 0:s.removeAttribute)==null||n.call(s,"aria-live"),this.redispatchEvent(e),this.defaultFocus!==pe.NONE)return;const t=this.menu.items,r=(h=ft(t))==null?void 0:h.item;let[i]=this.lastSelectedOptionRecords[0]??[null];r&&r!==i&&(r.tabIndex=-1),i=i??t[0],i&&(i.tabIndex=0,i.focus())}redispatchEvent(e){
|
|
1245
|
+
</div>`}renderMenuContent(){return c`<slot></slot>`}handleKeydown(e){var s,n;if(this.open||this.disabled||!this.menu)return;const t=this.menu.typeaheadController,r=e.code==="Space"||e.code==="ArrowDown"||e.code==="ArrowUp"||e.code==="End"||e.code==="Home"||e.code==="Enter";if(!t.isTypingAhead&&r){switch(e.preventDefault(),this.open=!0,e.code){case"Space":case"ArrowDown":case"Enter":this.defaultFocus=pe.NONE;break;case"End":this.defaultFocus=pe.LAST_ITEM;break;case"ArrowUp":case"Home":this.defaultFocus=pe.FIRST_ITEM;break}return}if(e.key.length===1){t.onKeydown(e),e.preventDefault();const{lastActiveRecord:h}=t;if(!h)return;(n=(s=this.labelEl)==null?void 0:s.setAttribute)==null||n.call(s,"aria-live","polite"),this.selectItem(h[ae.ITEM])&&this.dispatchInteractionEvents()}}handleClick(){this.open=!this.open}handleFocus(){this.focused=!0}handleBlur(){this.focused=!1}handleFocusout(e){e.relatedTarget&&Ki(e.relatedTarget,this)||(this.open=!1)}getSelectedOptions(){if(!this.menu)return this.lastSelectedOptionRecords=[],null;const e=this.menu.items;return this.lastSelectedOptionRecords=Bl(e),this.lastSelectedOptionRecords}async getUpdateComplete(){var e;return await((e=this.menu)==null?void 0:e.updateComplete),super.getUpdateComplete()}updateValueAndDisplayText(){const e=this.getSelectedOptions()??[];let t=!1;if(e.length){const[r]=e[0];t=this.lastSelectedOption!==r,this.lastSelectedOption=r,this[jr]=r.value,this.displayText=r.displayText}else t=this.lastSelectedOption!==null,this.lastSelectedOption=null,this[jr]="",this.displayText="";return t}async handleOpening(e){var s,n,h;if((n=(s=this.labelEl)==null?void 0:s.removeAttribute)==null||n.call(s,"aria-live"),this.redispatchEvent(e),this.defaultFocus!==pe.NONE)return;const t=this.menu.items,r=(h=ft(t))==null?void 0:h.item;let[i]=this.lastSelectedOptionRecords[0]??[null];r&&r!==i&&(r.tabIndex=-1),i=i??t[0],i&&(i.tabIndex=0,i.focus())}redispatchEvent(e){Fe(this,e)}handleClosed(e){this.open=!1,this.redispatchEvent(e)}handleCloseMenu(e){const t=e.detail.reason,r=e.detail.itemPath[0];this.open=!1;let i=!1;t.kind==="click-selection"?i=this.selectItem(r):t.kind==="keydown"&&gl(t.key)?i=this.selectItem(r):(r.tabIndex=-1,r.blur()),i&&this.dispatchInteractionEvents()}selectItem(e){return(this.getSelectedOptions()??[]).forEach(([r])=>{e!==r&&(r.selected=!1)}),e.selected=!0,this.updateValueAndDisplayText()}handleRequestSelection(e){const t=e.target;this.lastSelectedOptionRecords.some(([r])=>r===t)||this.selectItem(t)}handleRequestDeselection(e){const t=e.target;this.lastSelectedOptionRecords.some(([r])=>r===t)&&this.updateValueAndDisplayText()}initUserSelection(){this.lastUserSetValue&&!this.lastSelectedOptionRecords.length?this.select(this.lastUserSetValue):this.lastUserSetSelectedIndex!==null&&!this.lastSelectedOptionRecords.length?this.selectIndex(this.lastUserSetSelectedIndex):this.updateValueAndDisplayText()}handleIconChange(){this.hasLeadingIcon=this.leadingIcons.length>0}dispatchInteractionEvents(){this.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),this.dispatchEvent(new Event("change",{bubbles:!0}))}getErrorText(){return this.error?this.errorText:this.nativeErrorText}[$e](){return this.value}formResetCallback(){this.reset()}formStateRestoreCallback(e){this.value=e}click(){var e;(e=this.field)==null||e.click()}[et](){return new Rl(()=>this)}[tt](){return this.field}}Y(O),O.shadowRootOptions={...g.shadowRootOptions,delegatesFocus:!0},d([l({type:Boolean})],O.prototype,"quick",void 0),d([l({type:Boolean})],O.prototype,"required",void 0),d([l({type:String,attribute:"error-text"})],O.prototype,"errorText",void 0),d([l()],O.prototype,"label",void 0),d([l({type:Boolean,attribute:"no-asterisk"})],O.prototype,"noAsterisk",void 0),d([l({type:String,attribute:"supporting-text"})],O.prototype,"supportingText",void 0),d([l({type:Boolean,reflect:!0})],O.prototype,"error",void 0),d([l({attribute:"menu-positioning"})],O.prototype,"menuPositioning",void 0),d([l({type:Boolean,attribute:"clamp-menu-width"})],O.prototype,"clampMenuWidth",void 0),d([l({type:Number,attribute:"typeahead-delay"})],O.prototype,"typeaheadDelay",void 0),d([l({type:Boolean,attribute:"has-leading-icon"})],O.prototype,"hasLeadingIcon",void 0),d([l({attribute:"display-text"})],O.prototype,"displayText",void 0),d([l({attribute:"menu-align"})],O.prototype,"menuAlign",void 0),d([l()],O.prototype,"value",null),d([l({type:Number,attribute:"selected-index"})],O.prototype,"selectedIndex",null),d([w()],O.prototype,"nativeError",void 0),d([w()],O.prototype,"nativeErrorText",void 0),d([w()],O.prototype,"focused",void 0),d([w()],O.prototype,"open",void 0),d([w()],O.prototype,"defaultFocus",void 0),d([k(".field")],O.prototype,"field",void 0),d([k("md-menu")],O.prototype,"menu",void 0),d([k("#label")],O.prototype,"labelEl",void 0),d([W({slot:"leading-icon",flatten:!0})],O.prototype,"leadingIcons",void 0);/**
|
|
1246
1246
|
* @license
|
|
1247
1247
|
* Copyright 2023 Google LLC
|
|
1248
1248
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1255,12 +1255,12 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1255
1255
|
* @license
|
|
1256
1256
|
* Copyright 2024 Google LLC
|
|
1257
1257
|
* SPDX-License-Identifier: Apache-2.0
|
|
1258
|
-
*/const
|
|
1258
|
+
*/const La=f`:host{color:unset;min-width:210px;display:flex}.field{cursor:default;outline:none}.select{position:relative;flex-direction:column}.icon.trailing svg,.icon ::slotted(*){fill:currentColor}.icon ::slotted(*){width:inherit;height:inherit;font-size:inherit}.icon slot{display:flex;height:100%;width:100%;align-items:center;justify-content:center}.icon.trailing :is(.up,.down){opacity:0;transition:opacity 75ms linear 75ms}.select:not(.open) .down,.select.open .up{opacity:1}.field,.select,md-menu{min-width:inherit;width:inherit;max-width:inherit;display:flex}md-menu{min-width:var(--__menu-min-width);max-width:var(--__menu-max-width, inherit)}.menu-wrapper{width:0px;height:0px;max-width:inherit}md-menu ::slotted(:not[disabled]){cursor:pointer}.field,.select{width:100%}:host{display:inline-flex}:host([disabled]){pointer-events:none}
|
|
1259
1259
|
`;/**
|
|
1260
1260
|
* @license
|
|
1261
1261
|
* Copyright 2023 Google LLC
|
|
1262
1262
|
* SPDX-License-Identifier: Apache-2.0
|
|
1263
|
-
*/let oo=class extends Fl{};oo.styles=[
|
|
1263
|
+
*/let oo=class extends Fl{};oo.styles=[La,Hl],oo=d([b("md-filled-select")],oo);/**
|
|
1264
1264
|
* @license
|
|
1265
1265
|
* Copyright 2023 Google LLC
|
|
1266
1266
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1273,11 +1273,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1273
1273
|
* @license
|
|
1274
1274
|
* Copyright 2023 Google LLC
|
|
1275
1275
|
* SPDX-License-Identifier: Apache-2.0
|
|
1276
|
-
*/let ao=class extends Nl{};ao.styles=[
|
|
1276
|
+
*/let ao=class extends Nl{};ao.styles=[La,ql],ao=d([b("md-outlined-select")],ao);/**
|
|
1277
1277
|
* @license
|
|
1278
1278
|
* Copyright 2023 Google LLC
|
|
1279
1279
|
* SPDX-License-Identifier: Apache-2.0
|
|
1280
|
-
*/function Vl(){return new Event("request-selection",{bubbles:!0,composed:!0})}function Ul(){return new Event("request-deselection",{bubbles:!0,composed:!0})}class jl{get role(){return this.menuItemController.role}get typeaheadText(){return this.menuItemController.typeaheadText}setTypeaheadText(e){this.menuItemController.setTypeaheadText(e)}get displayText(){return this.internalDisplayText!==null?this.internalDisplayText:this.menuItemController.typeaheadText}setDisplayText(e){this.internalDisplayText=e}constructor(e,t){this.host=e,this.internalDisplayText=null,this.lastSelected=this.host.selected,this.firstUpdate=!0,this.onClick=()=>{this.menuItemController.onClick()},this.onKeydown=r=>{this.menuItemController.onKeydown(r)},this.menuItemController=new
|
|
1280
|
+
*/function Vl(){return new Event("request-selection",{bubbles:!0,composed:!0})}function Ul(){return new Event("request-deselection",{bubbles:!0,composed:!0})}class jl{get role(){return this.menuItemController.role}get typeaheadText(){return this.menuItemController.typeaheadText}setTypeaheadText(e){this.menuItemController.setTypeaheadText(e)}get displayText(){return this.internalDisplayText!==null?this.internalDisplayText:this.menuItemController.typeaheadText}setDisplayText(e){this.internalDisplayText=e}constructor(e,t){this.host=e,this.internalDisplayText=null,this.lastSelected=this.host.selected,this.firstUpdate=!0,this.onClick=()=>{this.menuItemController.onClick()},this.onKeydown=r=>{this.menuItemController.onKeydown(r)},this.menuItemController=new Ea(e,t),e.addController(this)}hostUpdate(){this.lastSelected!==this.host.selected&&(this.host.ariaSelected=this.host.selected?"true":"false")}hostUpdated(){this.lastSelected!==this.host.selected&&!this.firstUpdate&&(this.host.selected?this.host.dispatchEvent(Vl()):this.host.dispatchEvent(Ul())),this.lastSelected=this.host.selected,this.firstUpdate=!1}}/**
|
|
1281
1281
|
* @license
|
|
1282
1282
|
* Copyright 2023 Google LLC
|
|
1283
1283
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1323,7 +1323,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1323
1323
|
* @license
|
|
1324
1324
|
* Copyright 2023 Google LLC
|
|
1325
1325
|
* SPDX-License-Identifier: Apache-2.0
|
|
1326
|
-
*/let so=class extends Q{};so.styles=[
|
|
1326
|
+
*/let so=class extends Q{};so.styles=[Aa],so=d([b("md-select-option")],so);/**
|
|
1327
1327
|
* @license
|
|
1328
1328
|
* Copyright 2024 Google LLC
|
|
1329
1329
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1336,7 +1336,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1336
1336
|
* @license
|
|
1337
1337
|
* Copyright 2023 Google LLC
|
|
1338
1338
|
* SPDX-License-Identifier: Apache-2.0
|
|
1339
|
-
*/const Gl=ut(
|
|
1339
|
+
*/const Gl=ut(Me(g));class E extends Gl{get nameStart(){return this.getAttribute("name-start")??this.name}set nameStart(e){this.setAttribute("name-start",e)}get nameEnd(){return this.getAttribute("name-end")??this.nameStart}set nameEnd(e){this.setAttribute("name-end",e)}get renderAriaLabelStart(){const{ariaLabel:e}=this;return this.ariaLabelStart||e&&`${e} start`||this.valueLabelStart||String(this.valueStart)}get renderAriaValueTextStart(){return this.ariaValueTextStart||this.valueLabelStart||String(this.valueStart)}get renderAriaLabelEnd(){const{ariaLabel:e}=this;return this.range?this.ariaLabelEnd||e&&`${e} end`||this.valueLabelEnd||String(this.valueEnd):e||this.valueLabel||String(this.value)}get renderAriaValueTextEnd(){if(this.range)return this.ariaValueTextEnd||this.valueLabelEnd||String(this.valueEnd);const{ariaValueText:e}=this;return e||this.valueLabel||String(this.value)}constructor(){super(),this.min=0,this.max=100,this.valueLabel="",this.valueLabelStart="",this.valueLabelEnd="",this.ariaLabelStart="",this.ariaValueTextStart="",this.ariaLabelEnd="",this.ariaValueTextEnd="",this.step=1,this.ticks=!1,this.labeled=!1,this.range=!1,this.handleStartHover=!1,this.handleEndHover=!1,this.startOnTop=!1,this.handlesOverlapping=!1,this.ripplePointerId=1,this.isRedispatchingEvent=!1,this.addEventListener("click",e=>{!Mt(e)||!this.inputEnd||(this.focus(),ur(this.inputEnd))})}focus(){var e;(e=this.inputEnd)==null||e.focus()}willUpdate(e){var r,i;this.renderValueStart=e.has("valueStart")?this.valueStart:(r=this.inputStart)==null?void 0:r.valueAsNumber;const t=e.has("valueEnd")&&this.range||e.has("value");this.renderValueEnd=t?this.range?this.valueEnd:this.value:(i=this.inputEnd)==null?void 0:i.valueAsNumber,e.get("handleStartHover")!==void 0?this.toggleRippleHover(this.rippleStart,this.handleStartHover):e.get("handleEndHover")!==void 0&&this.toggleRippleHover(this.rippleEnd,this.handleEndHover)}updated(e){var t,r;if(this.range&&(this.renderValueStart=this.inputStart.valueAsNumber),this.renderValueEnd=this.inputEnd.valueAsNumber,this.range){const i=(this.max-this.min)/3;if(this.valueStart===void 0){this.inputStart.valueAsNumber=this.min+i;const s=this.inputStart.valueAsNumber;this.valueStart=this.renderValueStart=s}if(this.valueEnd===void 0){this.inputEnd.valueAsNumber=this.min+2*i;const s=this.inputEnd.valueAsNumber;this.valueEnd=this.renderValueEnd=s}}else this.value??(this.value=this.renderValueEnd);if(e.has("range")||e.has("renderValueStart")||e.has("renderValueEnd")||this.isUpdatePending){const i=(t=this.handleStart)==null?void 0:t.querySelector(".handleNub"),s=(r=this.handleEnd)==null?void 0:r.querySelector(".handleNub");this.handlesOverlapping=Kl(i,s)}this.performUpdate()}render(){const e=this.step===0?1:this.step,t=Math.max(this.max-this.min,e),r=this.range?((this.renderValueStart??this.min)-this.min)/t:0,i=((this.renderValueEnd??this.min)-this.min)/t,s={"--_start-fraction":String(r),"--_end-fraction":String(i),"--_tick-count":String(t/e)},n={ranged:this.range},h=this.valueLabelStart||String(this.renderValueStart),u=(this.range?this.valueLabelEnd:this.valueLabel)||String(this.renderValueEnd),m={start:!0,value:this.renderValueStart,ariaLabel:this.renderAriaLabelStart,ariaValueText:this.renderAriaValueTextStart,ariaMin:this.min,ariaMax:this.valueEnd??this.max},y={start:!1,value:this.renderValueEnd,ariaLabel:this.renderAriaLabelEnd,ariaValueText:this.renderAriaValueTextEnd,ariaMin:this.range?this.valueStart??this.min:this.min,ariaMax:this.max},v={start:!0,hover:this.handleStartHover,label:h},x={start:!1,hover:this.handleEndHover,label:u},_={hover:this.handleStartHover||this.handleEndHover};return c` <div
|
|
1340
1340
|
class="container ${P(n)}"
|
|
1341
1341
|
style=${ot(s)}>
|
|
1342
1342
|
${no(this.range,()=>this.renderInput(m))}
|
|
@@ -1388,7 +1388,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1388
1388
|
.value=${String(t)}
|
|
1389
1389
|
.tabIndex=${e?1:0}
|
|
1390
1390
|
aria-label=${r||p}
|
|
1391
|
-
aria-valuetext=${i} />`}async toggleRippleHover(e,t){const r=await e;r&&(t?r.handlePointerenter(new PointerEvent("pointerenter",{isPrimary:!0,pointerId:this.ripplePointerId})):r.handlePointerleave(new PointerEvent("pointerleave",{isPrimary:!0,pointerId:this.ripplePointerId})))}handleFocus(e){this.updateOnTop(e.target)}startAction(e){const t=e.target,r=t===this.inputStart?this.inputEnd:this.inputStart;this.action={canFlip:e.type==="pointerdown",flipped:!1,target:t,fixed:r,values:new Map([[t,t.valueAsNumber],[r,r==null?void 0:r.valueAsNumber]])}}finishAction(e){this.action=void 0}handleKeydown(e){this.startAction(e)}handleKeyup(e){this.finishAction(e)}handleDown(e){this.startAction(e),this.ripplePointerId=e.pointerId;const t=e.target===this.inputStart;this.handleStartHover=!this.disabled&&t&&!!this.handleStart,this.handleEndHover=!this.disabled&&!t&&!!this.handleEnd}async handleUp(e){if(!this.action)return;const{target:t,values:r,flipped:i}=this.action;await new Promise(requestAnimationFrame),t!==void 0&&(t.focus(),i&&t.valueAsNumber!==r.get(t)&&t.dispatchEvent(new Event("change",{bubbles:!0}))),this.finishAction(e)}handleMove(e){this.handleStartHover=!this.disabled&&
|
|
1391
|
+
aria-valuetext=${i} />`}async toggleRippleHover(e,t){const r=await e;r&&(t?r.handlePointerenter(new PointerEvent("pointerenter",{isPrimary:!0,pointerId:this.ripplePointerId})):r.handlePointerleave(new PointerEvent("pointerleave",{isPrimary:!0,pointerId:this.ripplePointerId})))}handleFocus(e){this.updateOnTop(e.target)}startAction(e){const t=e.target,r=t===this.inputStart?this.inputEnd:this.inputStart;this.action={canFlip:e.type==="pointerdown",flipped:!1,target:t,fixed:r,values:new Map([[t,t.valueAsNumber],[r,r==null?void 0:r.valueAsNumber]])}}finishAction(e){this.action=void 0}handleKeydown(e){this.startAction(e)}handleKeyup(e){this.finishAction(e)}handleDown(e){this.startAction(e),this.ripplePointerId=e.pointerId;const t=e.target===this.inputStart;this.handleStartHover=!this.disabled&&t&&!!this.handleStart,this.handleEndHover=!this.disabled&&!t&&!!this.handleEnd}async handleUp(e){if(!this.action)return;const{target:t,values:r,flipped:i}=this.action;await new Promise(requestAnimationFrame),t!==void 0&&(t.focus(),i&&t.valueAsNumber!==r.get(t)&&t.dispatchEvent(new Event("change",{bubbles:!0}))),this.finishAction(e)}handleMove(e){this.handleStartHover=!this.disabled&&Da(e,this.handleStart),this.handleEndHover=!this.disabled&&Da(e,this.handleEnd)}handleEnter(e){this.handleMove(e)}handleLeave(){this.handleStartHover=!1,this.handleEndHover=!1}updateOnTop(e){this.startOnTop=e.classList.contains("start")}needsClamping(){if(!this.action)return!1;const{target:e,fixed:t}=this.action;return e===this.inputStart?e.valueAsNumber>t.valueAsNumber:e.valueAsNumber<t.valueAsNumber}isActionFlipped(){const{action:e}=this;if(!e)return!1;const{target:t,fixed:r,values:i}=e;return e.canFlip&&i.get(t)===i.get(r)&&this.needsClamping()&&(e.canFlip=!1,e.flipped=!0,e.target=r,e.fixed=t),e.flipped}flipAction(){if(!this.action)return!1;const{target:e,fixed:t,values:r}=this.action,i=e.valueAsNumber!==t.valueAsNumber;return e.valueAsNumber=t.valueAsNumber,t.valueAsNumber=r.get(t),i}clampAction(){if(!this.needsClamping()||!this.action)return!1;const{target:e,fixed:t}=this.action;return e.valueAsNumber=t.valueAsNumber,!0}handleInput(e){if(this.isRedispatchingEvent)return;let t=!1,r=!1;this.range&&(this.isActionFlipped()&&(t=!0,r=this.flipAction()),this.clampAction()&&(t=!0,r=!1));const i=e.target;this.updateOnTop(i),this.range?(this.valueStart=this.inputStart.valueAsNumber,this.valueEnd=this.inputEnd.valueAsNumber):this.value=this.inputEnd.valueAsNumber,t&&e.stopPropagation(),r&&(this.isRedispatchingEvent=!0,Fe(i,e),this.isRedispatchingEvent=!1)}handleChange(e){const t=e.target,{target:r,values:i}=this.action??{};r&&r.valueAsNumber===i.get(t)||Fe(this,e),this.finishAction(e)}[$e](){if(this.range){const e=new FormData;return e.append(this.nameStart,String(this.valueStart)),e.append(this.nameEnd,String(this.valueEnd)),e}return String(this.value)}formResetCallback(){if(this.range){const t=this.getAttribute("value-start");this.valueStart=t!==null?Number(t):void 0;const r=this.getAttribute("value-end");this.valueEnd=r!==null?Number(r):void 0;return}const e=this.getAttribute("value");this.value=e!==null?Number(e):void 0}formStateRestoreCallback(e){if(Array.isArray(e)){const[[,t],[,r]]=e;this.valueStart=Number(t),this.valueEnd=Number(r),this.range=!0;return}this.value=Number(e),this.range=!1}}Y(E),E.shadowRootOptions={...g.shadowRootOptions,delegatesFocus:!0},d([l({type:Number})],E.prototype,"min",void 0),d([l({type:Number})],E.prototype,"max",void 0),d([l({type:Number})],E.prototype,"value",void 0),d([l({type:Number,attribute:"value-start"})],E.prototype,"valueStart",void 0),d([l({type:Number,attribute:"value-end"})],E.prototype,"valueEnd",void 0),d([l({attribute:"value-label"})],E.prototype,"valueLabel",void 0),d([l({attribute:"value-label-start"})],E.prototype,"valueLabelStart",void 0),d([l({attribute:"value-label-end"})],E.prototype,"valueLabelEnd",void 0),d([l({attribute:"aria-label-start"})],E.prototype,"ariaLabelStart",void 0),d([l({attribute:"aria-valuetext-start"})],E.prototype,"ariaValueTextStart",void 0),d([l({attribute:"aria-label-end"})],E.prototype,"ariaLabelEnd",void 0),d([l({attribute:"aria-valuetext-end"})],E.prototype,"ariaValueTextEnd",void 0),d([l({type:Number})],E.prototype,"step",void 0),d([l({type:Boolean})],E.prototype,"ticks",void 0),d([l({type:Boolean})],E.prototype,"labeled",void 0),d([l({type:Boolean})],E.prototype,"range",void 0),d([k("input.start")],E.prototype,"inputStart",void 0),d([k(".handle.start")],E.prototype,"handleStart",void 0),d([Mo("md-ripple.start")],E.prototype,"rippleStart",void 0),d([k("input.end")],E.prototype,"inputEnd",void 0),d([k(".handle.end")],E.prototype,"handleEnd",void 0),d([Mo("md-ripple.end")],E.prototype,"rippleEnd",void 0),d([w()],E.prototype,"handleStartHover",void 0),d([w()],E.prototype,"handleEndHover",void 0),d([w()],E.prototype,"startOnTop",void 0),d([w()],E.prototype,"handlesOverlapping",void 0),d([w()],E.prototype,"renderValueStart",void 0),d([w()],E.prototype,"renderValueEnd",void 0);function Da({x:o,y:e},t){if(!t)return!1;const{top:r,left:i,bottom:s,right:n}=t.getBoundingClientRect();return o>=i&&o<=n&&e>=r&&e<=s}function Kl(o,e){if(!(o&&e))return!1;const t=o.getBoundingClientRect(),r=e.getBoundingClientRect();return!(t.top>r.bottom||t.right<r.left||t.bottom<r.top||t.left>r.right)}/**
|
|
1392
1392
|
* @license
|
|
1393
1393
|
* Copyright 2024 Google LLC
|
|
1394
1394
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1401,11 +1401,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1401
1401
|
* @license
|
|
1402
1402
|
* Copyright 2023 Google LLC
|
|
1403
1403
|
* SPDX-License-Identifier: Apache-2.0
|
|
1404
|
-
*/const Ra=Symbol("dispatchHooks");function Xl(o,e){const t=o[Ra];if(!t)throw new Error(`'${o.type}' event needs setupDispatchHooks().`);t.addEventListener("after",e)}const
|
|
1404
|
+
*/const Ra=Symbol("dispatchHooks");function Xl(o,e){const t=o[Ra];if(!t)throw new Error(`'${o.type}' event needs setupDispatchHooks().`);t.addEventListener("after",e)}const Ba=new WeakMap;function Zl(o,...e){let t=Ba.get(o);t||(t=new Set,Ba.set(o,t));for(const r of e){if(t.has(r))continue;let i=!1;o.addEventListener(r,s=>{if(i)return;s.stopImmediatePropagation();const n=Reflect.construct(s.constructor,[s.type,s]),h=new EventTarget;n[Ra]=h,i=!0;const u=o.dispatchEvent(n);i=!1,u||s.preventDefault(),h.dispatchEvent(new Event("after"))},{capture:!0}),t.add(r)}}/**
|
|
1405
1405
|
* @license
|
|
1406
1406
|
* Copyright 2021 Google LLC
|
|
1407
1407
|
* SPDX-License-Identifier: Apache-2.0
|
|
1408
|
-
*/const Jl=Ht(ut(
|
|
1408
|
+
*/const Jl=Ht(ut(Me(g)));class Ae extends Jl{constructor(){super(),this.selected=!1,this.icons=!1,this.showOnlySelectedIcon=!1,this.required=!1,this.value="on",this.addEventListener("click",e=>{!Mt(e)||!this.input||(this.focus(),ur(this.input))}),Zl(this,"keydown"),this.addEventListener("keydown",e=>{Xl(e,()=>{e.defaultPrevented||e.key!=="Enter"||this.disabled||!this.input||this.input.click()})})}render(){return c`
|
|
1409
1409
|
<div class="switch ${P(this.getRenderClasses())}">
|
|
1410
1410
|
<input
|
|
1411
1411
|
id="switch"
|
|
@@ -1449,7 +1449,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1449
1449
|
d="M6.4 19.2 4.8 17.6 10.4 12 4.8 6.4 6.4 4.8 12 10.4 17.6 4.8 19.2 6.4 13.6 12 19.2 17.6 17.6 19.2 12 13.6Z" />
|
|
1450
1450
|
</svg>
|
|
1451
1451
|
</slot>
|
|
1452
|
-
`}renderTouchTarget(){return c`<span class="touch"></span>`}shouldShowIcons(){return this.icons||this.showOnlySelectedIcon}handleInput(e){const t=e.target;this.selected=t.checked}handleChange(e){
|
|
1452
|
+
`}renderTouchTarget(){return c`<span class="touch"></span>`}shouldShowIcons(){return this.icons||this.showOnlySelectedIcon}handleInput(e){const t=e.target;this.selected=t.checked}handleChange(e){Fe(this,e)}[$e](){return this.selected?this.value:null}[Nt](){return String(this.selected)}formResetCallback(){this.selected=this.hasAttribute("selected")}formStateRestoreCallback(e){this.selected=e==="true"}[et](){return new ra(()=>({checked:this.selected,required:this.required}))}[tt](){return this.input}}Y(Ae),Ae.shadowRootOptions={mode:"open",delegatesFocus:!0},d([l({type:Boolean})],Ae.prototype,"selected",void 0),d([l({type:Boolean})],Ae.prototype,"icons",void 0),d([l({type:Boolean,attribute:"show-only-selected-icon"})],Ae.prototype,"showOnlySelectedIcon",void 0),d([l({type:Boolean})],Ae.prototype,"required",void 0),d([l()],Ae.prototype,"value",void 0),d([k("input")],Ae.prototype,"input",void 0);/**
|
|
1453
1453
|
* @license
|
|
1454
1454
|
* Copyright 2024 Google LLC
|
|
1455
1455
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1458,11 +1458,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1458
1458
|
* @license
|
|
1459
1459
|
* Copyright 2021 Google LLC
|
|
1460
1460
|
* SPDX-License-Identifier: Apache-2.0
|
|
1461
|
-
*/let Wr=class extends
|
|
1461
|
+
*/let Wr=class extends Ae{};Wr.styles=[Ql],Wr=d([b("md-switch")],Wr);const ec=Object.freeze(Object.defineProperty({__proto__:null,get MdSwitch(){return Wr}},Symbol.toStringTag,{value:"Module"}));/**
|
|
1462
1462
|
* @license
|
|
1463
1463
|
* Copyright 2023 Google LLC
|
|
1464
1464
|
* SPDX-License-Identifier: Apache-2.0
|
|
1465
|
-
*/var
|
|
1465
|
+
*/var Ma;const bt=Symbol("indicator"),Fa=Symbol("animateIndicator"),tc=Ta(g);class ue extends tc{get selected(){return this.active}set selected(e){this.active=e}constructor(){super(),this.isTab=!0,this.active=!1,this.hasIcon=!1,this.iconOnly=!1,this.fullWidthIndicator=!1,this.internals=this.attachInternals(),this.internals.role="tab",this.addEventListener("keydown",this.handleKeydown.bind(this))}render(){const e=c`<div class="indicator"></div>`;return c`<div
|
|
1466
1466
|
class="button"
|
|
1467
1467
|
role="presentation"
|
|
1468
1468
|
@click=${this.handleContentClick}>
|
|
@@ -1477,11 +1477,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1477
1477
|
${this.fullWidthIndicator?p:e}
|
|
1478
1478
|
</div>
|
|
1479
1479
|
${this.fullWidthIndicator?e:p}
|
|
1480
|
-
</div>`}getContentClasses(){return{"has-icon":this.hasIcon,"has-label":!this.iconOnly}}updated(){this.internals.ariaSelected=String(this.active)}async handleKeydown(e){await 0,!e.defaultPrevented&&(e.key==="Enter"||e.key===" ")&&(e.preventDefault(),this.click())}handleContentClick(e){e.stopPropagation(),this.click()}[(
|
|
1480
|
+
</div>`}getContentClasses(){return{"has-icon":this.hasIcon,"has-label":!this.iconOnly}}updated(){this.internals.ariaSelected=String(this.active)}async handleKeydown(e){await 0,!e.defaultPrevented&&(e.key==="Enter"||e.key===" ")&&(e.preventDefault(),this.click())}handleContentClick(e){e.stopPropagation(),this.click()}[(Ma=bt,Fa)](e){if(!this[bt])return;this[bt].getAnimations().forEach(r=>{r.cancel()});const t=this.getKeyframes(e);t!==null&&this[bt].animate(t,{duration:250,easing:de.EMPHASIZED})}getKeyframes(e){var v;const t=rc();if(!this.active)return t?[{opacity:1},{transform:"none"}]:null;const r={},i=((v=e[bt])==null?void 0:v.getBoundingClientRect())??{},s=i.left,n=i.width,h=this[bt].getBoundingClientRect(),u=h.left,m=h.width,y=n/m;return!t&&s!==void 0&&u!==void 0&&!isNaN(y)?r.transform=`translateX(${(s-u).toFixed(4)}px) scaleX(${y.toFixed(4)})`:r.opacity=0,[r,{transform:"none"}]}handleSlotChange(){this.iconOnly=!1;for(const e of this.assignedDefaultNodes){const t=e.nodeType===Node.TEXT_NODE&&!!e.wholeText.match(/\S/);if(e.nodeType===Node.ELEMENT_NODE||t)return}this.iconOnly=!0}handleIconSlotChange(){this.hasIcon=this.assignedIcons.length>0}}d([l({type:Boolean,reflect:!0,attribute:"md-tab"})],ue.prototype,"isTab",void 0),d([l({type:Boolean,reflect:!0})],ue.prototype,"active",void 0),d([l({type:Boolean})],ue.prototype,"selected",null),d([l({type:Boolean,attribute:"has-icon"})],ue.prototype,"hasIcon",void 0),d([l({type:Boolean,attribute:"icon-only"})],ue.prototype,"iconOnly",void 0),d([k(".indicator")],ue.prototype,Ma,void 0),d([w()],ue.prototype,"fullWidthIndicator",void 0),d([fi({flatten:!0})],ue.prototype,"assignedDefaultNodes",void 0),d([W({slot:"icon",flatten:!0})],ue.prototype,"assignedIcons",void 0);function rc(){return window.matchMedia("(prefers-reduced-motion: reduce)").matches}/**
|
|
1481
1481
|
* @license
|
|
1482
1482
|
* Copyright 2023 Google LLC
|
|
1483
1483
|
* SPDX-License-Identifier: Apache-2.0
|
|
1484
|
-
*/class
|
|
1484
|
+
*/class Ha extends ue{constructor(){super(...arguments),this.inlineIcon=!1}getContentClasses(){return{...super.getContentClasses(),stacked:!this.inlineIcon}}}d([l({type:Boolean,attribute:"inline-icon"})],Ha.prototype,"inlineIcon",void 0);/**
|
|
1485
1485
|
* @license
|
|
1486
1486
|
* Copyright 2024 Google LLC
|
|
1487
1487
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1490,12 +1490,12 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1490
1490
|
* @license
|
|
1491
1491
|
* Copyright 2024 Google LLC
|
|
1492
1492
|
* SPDX-License-Identifier: Apache-2.0
|
|
1493
|
-
*/const
|
|
1493
|
+
*/const Na=f`:host{display:inline-flex;align-items:center;justify-content:center;outline:none;padding:0 16px;position:relative;-webkit-tap-highlight-color:rgba(0,0,0,0);vertical-align:middle;user-select:none;font-family:var(--_label-text-font);font-size:var(--_label-text-size);line-height:var(--_label-text-line-height);font-weight:var(--_label-text-weight);color:var(--_label-text-color);z-index:0;--md-ripple-hover-color: var(--_hover-state-layer-color);--md-ripple-hover-opacity: var(--_hover-state-layer-opacity);--md-ripple-pressed-color: var(--_pressed-state-layer-color);--md-ripple-pressed-opacity: var(--_pressed-state-layer-opacity);--md-elevation-level: var(--_container-elevation)}md-focus-ring{--md-focus-ring-shape: 8px}:host([active]) md-focus-ring{margin-bottom:calc(var(--_active-indicator-height) + 1px)}.button::before{background:var(--_container-color);content:"";inset:0;position:absolute;z-index:-1}.button::before,md-ripple,md-elevation{border-start-start-radius:var(--_container-shape-start-start);border-start-end-radius:var(--_container-shape-start-end);border-end-end-radius:var(--_container-shape-end-end);border-end-start-radius:var(--_container-shape-end-start)}.content{position:relative;box-sizing:border-box;display:inline-flex;flex-direction:row;align-items:center;justify-content:center;height:var(--_container-height);gap:8px}.indicator{position:absolute;box-sizing:border-box;z-index:-1;transform-origin:bottom left;background:var(--_active-indicator-color);border-radius:var(--_active-indicator-shape);height:var(--_active-indicator-height);inset:auto 0 0 0;opacity:0}::slotted([slot=icon]){display:inline-flex;position:relative;writing-mode:horizontal-tb;fill:currentColor;color:var(--_icon-color);font-size:var(--_icon-size);width:var(--_icon-size);height:var(--_icon-size)}:host(:hover){color:var(--_hover-label-text-color);cursor:pointer}:host(:hover) ::slotted([slot=icon]){color:var(--_hover-icon-color)}:host(:focus){color:var(--_focus-label-text-color)}:host(:focus) ::slotted([slot=icon]){color:var(--_focus-icon-color)}:host(:active){color:var(--_pressed-label-text-color)}:host(:active) ::slotted([slot=icon]){color:var(--_pressed-icon-color)}:host([active]) .indicator{opacity:1}:host([active]){color:var(--_active-label-text-color);--md-ripple-hover-color: var(--_active-hover-state-layer-color);--md-ripple-hover-opacity: var(--_active-hover-state-layer-opacity);--md-ripple-pressed-color: var(--_active-pressed-state-layer-color);--md-ripple-pressed-opacity: var(--_active-pressed-state-layer-opacity)}:host([active]) ::slotted([slot=icon]){color:var(--_active-icon-color)}:host([active]:hover){color:var(--_active-hover-label-text-color)}:host([active]:hover) ::slotted([slot=icon]){color:var(--_active-hover-icon-color)}:host([active]:focus){color:var(--_active-focus-label-text-color)}:host([active]:focus) ::slotted([slot=icon]){color:var(--_active-focus-icon-color)}:host([active]:active){color:var(--_active-pressed-label-text-color)}:host([active]:active) ::slotted([slot=icon]){color:var(--_active-pressed-icon-color)}:host,::slotted(*){white-space:nowrap}@media(forced-colors: active){.indicator{background:CanvasText}}
|
|
1494
1494
|
`;/**
|
|
1495
1495
|
* @license
|
|
1496
1496
|
* Copyright 2023 Google LLC
|
|
1497
1497
|
* SPDX-License-Identifier: Apache-2.0
|
|
1498
|
-
*/let jt=class extends
|
|
1498
|
+
*/let jt=class extends Ha{};jt.styles=[Na,ic],jt=d([b("md-primary-tab")],jt);/**
|
|
1499
1499
|
* @license
|
|
1500
1500
|
* Copyright 2023 Google LLC
|
|
1501
1501
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1508,7 +1508,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1508
1508
|
* @license
|
|
1509
1509
|
* Copyright 2023 Google LLC
|
|
1510
1510
|
* SPDX-License-Identifier: Apache-2.0
|
|
1511
|
-
*/let Wt=class extends oc{};Wt.styles=[
|
|
1511
|
+
*/let Wt=class extends oc{};Wt.styles=[Na,ac],Wt=d([b("md-secondary-tab")],Wt);/**
|
|
1512
1512
|
* @license
|
|
1513
1513
|
* Copyright 2023 Google LLC
|
|
1514
1514
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1519,7 +1519,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1519
1519
|
@click=${this.handleTabClick}></slot>
|
|
1520
1520
|
</div>
|
|
1521
1521
|
<md-divider part="divider"></md-divider>
|
|
1522
|
-
`}async handleTabClick(e){const t=e.target;await 0,!(e.defaultPrevented||!sc(t)||t.active)&&this.activateTab(t)}activateTab(e){const{tabs:t}=this,r=this.activeTab;if(!(!t.includes(e)||r===e)){for(const i of t)i.active=i===e;if(r){if(!this.dispatchEvent(new Event("change",{bubbles:!0,cancelable:!0}))){for(const s of t)s.active=s===r;return}e[
|
|
1522
|
+
`}async handleTabClick(e){const t=e.target;await 0,!(e.defaultPrevented||!sc(t)||t.active)&&this.activateTab(t)}activateTab(e){const{tabs:t}=this,r=this.activeTab;if(!(!t.includes(e)||r===e)){for(const i of t)i.active=i===e;if(r){if(!this.dispatchEvent(new Event("change",{bubbles:!0,cancelable:!0}))){for(const s of t)s.active=s===r;return}e[Fa](r)}this.updateFocusableTab(e),this.scrollToTab(e)}}updateFocusableTab(e){for(const t of this.tabs)t.tabIndex=t===e?0:-1}async handleKeydown(e){await 0;const t=e.key==="ArrowLeft",r=e.key==="ArrowRight",i=e.key==="Home",s=e.key==="End";if(e.defaultPrevented||!t&&!r&&!i&&!s)return;const{tabs:n}=this;if(n.length<2)return;e.preventDefault();let h;if(i||s)h=i?0:n.length-1;else{const y=getComputedStyle(this).direction==="rtl"?t:r,{focusedTab:v}=this;if(!v)h=y?0:n.length-1;else{const x=this.tabs.indexOf(v);h=y?x+1:x-1,h>=n.length?h=0:h<0&&(h=n.length-1)}}const u=n[h];u.focus(),this.autoActivate?this.activateTab(u):this.updateFocusableTab(u)}handleKeyup(){this.scrollToTab(this.focusedTab??this.activeTab)}handleFocusout(){if(this.matches(":focus-within"))return;const{activeTab:e}=this;e&&this.updateFocusableTab(e)}handleSlotChange(){const e=this.tabs[0];!this.activeTab&&e&&this.activateTab(e),this.scrollToTab(this.activeTab)}}d([W({flatten:!0,selector:"[md-tab]"})],gt.prototype,"tabs",void 0),d([l({type:Number,attribute:"active-tab-index"})],gt.prototype,"activeTabIndex",null),d([l({type:Boolean,attribute:"auto-activate"})],gt.prototype,"autoActivate",void 0),d([k(".tabs")],gt.prototype,"tabsScrollerElement",void 0),d([k("slot")],gt.prototype,"slotElement",void 0);function sc(o){return o instanceof HTMLElement&&o.hasAttribute("md-tab")}/**
|
|
1523
1523
|
* @license
|
|
1524
1524
|
* Copyright 2024 Google LLC
|
|
1525
1525
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1541,7 +1541,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1541
1541
|
* @license
|
|
1542
1542
|
* Copyright 2020 Google LLC
|
|
1543
1543
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
1544
|
-
*/const
|
|
1544
|
+
*/const qa=Si(class extends ki{constructor(o){if(super(o),o.type!==Be.PROPERTY&&o.type!==Be.ATTRIBUTE&&o.type!==Be.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!cc(o))throw Error("`live` bindings can only contain a single expression")}render(o){return o}update(o,[e]){if(e===oe||e===p)return e;const t=o.element,r=o.name;if(o.type===Be.PROPERTY){if(e===t[r])return oe}else if(o.type===Be.BOOLEAN_ATTRIBUTE){if(!!e===t.hasAttribute(r))return oe}else if(o.type===Be.ATTRIBUTE&&t.getAttribute(r)===e+"")return oe;return hc(o),e}});/**
|
|
1545
1545
|
* @license
|
|
1546
1546
|
* Copyright 2022 Google LLC
|
|
1547
1547
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1553,7 +1553,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1553
1553
|
* @license
|
|
1554
1554
|
* Copyright 2021 Google LLC
|
|
1555
1555
|
* SPDX-License-Identifier: Apache-2.0
|
|
1556
|
-
*/const vc=
|
|
1556
|
+
*/const vc=Oa(Ht(ut(Me(g))));class $ extends vc{constructor(){super(...arguments),this.error=!1,this.errorText="",this.label="",this.noAsterisk=!1,this.required=!1,this.value="",this.prefixText="",this.suffixText="",this.hasLeadingIcon=!1,this.hasTrailingIcon=!1,this.supportingText="",this.textDirection="",this.rows=2,this.cols=20,this.inputMode="",this.max="",this.maxLength=-1,this.min="",this.minLength=-1,this.noSpinner=!1,this.pattern="",this.placeholder="",this.readOnly=!1,this.multiple=!1,this.step="",this.type="text",this.autocomplete="",this.dirty=!1,this.focused=!1,this.nativeError=!1,this.nativeErrorText=""}get selectionDirection(){return this.getInputOrTextarea().selectionDirection}set selectionDirection(e){this.getInputOrTextarea().selectionDirection=e}get selectionEnd(){return this.getInputOrTextarea().selectionEnd}set selectionEnd(e){this.getInputOrTextarea().selectionEnd=e}get selectionStart(){return this.getInputOrTextarea().selectionStart}set selectionStart(e){this.getInputOrTextarea().selectionStart=e}get valueAsNumber(){const e=this.getInput();return e?e.valueAsNumber:NaN}set valueAsNumber(e){const t=this.getInput();t&&(t.valueAsNumber=e,this.value=t.value)}get valueAsDate(){const e=this.getInput();return e?e.valueAsDate:null}set valueAsDate(e){const t=this.getInput();t&&(t.valueAsDate=e,this.value=t.value)}get hasError(){return this.error||this.nativeError}select(){this.getInputOrTextarea().select()}setRangeText(...e){this.getInputOrTextarea().setRangeText(...e),this.value=this.getInputOrTextarea().value}setSelectionRange(e,t,r){this.getInputOrTextarea().setSelectionRange(e,t,r)}stepDown(e){const t=this.getInput();t&&(t.stepDown(e),this.value=t.value)}stepUp(e){const t=this.getInput();t&&(t.stepUp(e),this.value=t.value)}reset(){this.dirty=!1,this.value=this.getAttribute("value")??"",this.nativeError=!1,this.nativeErrorText=""}attributeChangedCallback(e,t,r){e==="value"&&this.dirty||super.attributeChangedCallback(e,t,r)}render(){const e={disabled:this.disabled,error:!this.disabled&&this.hasError,textarea:this.type==="textarea","no-spinner":this.noSpinner};return c`
|
|
1557
1557
|
<span class="text-field ${P(e)}">
|
|
1558
1558
|
${this.renderField()}
|
|
1559
1559
|
</span>
|
|
@@ -1603,7 +1603,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1603
1603
|
?required=${this.required}
|
|
1604
1604
|
rows=${this.rows}
|
|
1605
1605
|
cols=${this.cols}
|
|
1606
|
-
.value=${
|
|
1606
|
+
.value=${qa(this.value)}
|
|
1607
1607
|
@change=${this.redispatchEvent}
|
|
1608
1608
|
@focus=${this.handleFocusChange}
|
|
1609
1609
|
@blur=${this.handleFocusChange}
|
|
@@ -1633,7 +1633,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1633
1633
|
?multiple=${this.multiple}
|
|
1634
1634
|
step=${this.step||p}
|
|
1635
1635
|
type=${this.type}
|
|
1636
|
-
.value=${
|
|
1636
|
+
.value=${qa(this.value)}
|
|
1637
1637
|
@change=${this.redispatchEvent}
|
|
1638
1638
|
@focus=${this.handleFocusChange}
|
|
1639
1639
|
@blur=${this.handleFocusChange}
|
|
@@ -1641,7 +1641,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1641
1641
|
@select=${this.redispatchEvent} />
|
|
1642
1642
|
${h}
|
|
1643
1643
|
</div>
|
|
1644
|
-
`}renderPrefix(){return this.renderAffix(this.prefixText,!1)}renderSuffix(){return this.renderAffix(this.suffixText,!0)}renderAffix(e,t){return e?c`<span class="${P({suffix:t,prefix:!t})}">${e}</span>`:p}getErrorText(){return this.error?this.errorText:this.nativeErrorText}handleFocusChange(){var e;this.focused=((e=this.inputOrTextarea)==null?void 0:e.matches(":focus"))??!1}handleInput(e){this.dirty=!0,this.value=e.target.value}redispatchEvent(e){
|
|
1644
|
+
`}renderPrefix(){return this.renderAffix(this.prefixText,!1)}renderSuffix(){return this.renderAffix(this.suffixText,!0)}renderAffix(e,t){return e?c`<span class="${P({suffix:t,prefix:!t})}">${e}</span>`:p}getErrorText(){return this.error?this.errorText:this.nativeErrorText}handleFocusChange(){var e;this.focused=((e=this.inputOrTextarea)==null?void 0:e.matches(":focus"))??!1}handleInput(e){this.dirty=!0,this.value=e.target.value}redispatchEvent(e){Fe(this,e)}getInputOrTextarea(){return this.inputOrTextarea||(this.connectedCallback(),this.scheduleUpdate()),this.isUpdatePending&&this.scheduleUpdate(),this.inputOrTextarea}getInput(){return this.type==="textarea"?null:this.getInputOrTextarea()}handleIconChange(){this.hasLeadingIcon=this.leadingIcons.length>0,this.hasTrailingIcon=this.trailingIcons.length>0}[$e](){return this.value}formResetCallback(){this.reset()}formStateRestoreCallback(e){this.value=e}focus(){this.getInputOrTextarea().focus()}[et](){return new uc(()=>({state:this,renderedControl:this.inputOrTextarea}))}[tt](){return this.inputOrTextarea}[Hr](e){var r;e==null||e.preventDefault();const t=this.getErrorText();this.nativeError=!!e,this.nativeErrorText=this.validationMessage,t===this.getErrorText()&&((r=this.field)==null||r.reannounceError())}}Y($),$.shadowRootOptions={...g.shadowRootOptions,delegatesFocus:!0},d([l({type:Boolean,reflect:!0})],$.prototype,"error",void 0),d([l({attribute:"error-text"})],$.prototype,"errorText",void 0),d([l()],$.prototype,"label",void 0),d([l({type:Boolean,attribute:"no-asterisk"})],$.prototype,"noAsterisk",void 0),d([l({type:Boolean,reflect:!0})],$.prototype,"required",void 0),d([l()],$.prototype,"value",void 0),d([l({attribute:"prefix-text"})],$.prototype,"prefixText",void 0),d([l({attribute:"suffix-text"})],$.prototype,"suffixText",void 0),d([l({type:Boolean,attribute:"has-leading-icon"})],$.prototype,"hasLeadingIcon",void 0),d([l({type:Boolean,attribute:"has-trailing-icon"})],$.prototype,"hasTrailingIcon",void 0),d([l({attribute:"supporting-text"})],$.prototype,"supportingText",void 0),d([l({attribute:"text-direction"})],$.prototype,"textDirection",void 0),d([l({type:Number})],$.prototype,"rows",void 0),d([l({type:Number})],$.prototype,"cols",void 0),d([l({reflect:!0})],$.prototype,"inputMode",void 0),d([l()],$.prototype,"max",void 0),d([l({type:Number})],$.prototype,"maxLength",void 0),d([l()],$.prototype,"min",void 0),d([l({type:Number})],$.prototype,"minLength",void 0),d([l({type:Boolean,attribute:"no-spinner"})],$.prototype,"noSpinner",void 0),d([l()],$.prototype,"pattern",void 0),d([l({reflect:!0,converter:pc})],$.prototype,"placeholder",void 0),d([l({type:Boolean,reflect:!0})],$.prototype,"readOnly",void 0),d([l({type:Boolean,reflect:!0})],$.prototype,"multiple",void 0),d([l()],$.prototype,"step",void 0),d([l({reflect:!0})],$.prototype,"type",void 0),d([l({reflect:!0})],$.prototype,"autocomplete",void 0),d([w()],$.prototype,"dirty",void 0),d([w()],$.prototype,"focused",void 0),d([w()],$.prototype,"nativeError",void 0),d([w()],$.prototype,"nativeErrorText",void 0),d([k(".input")],$.prototype,"inputOrTextarea",void 0),d([k(".field")],$.prototype,"field",void 0),d([W({slot:"leading-icon"})],$.prototype,"leadingIcons",void 0),d([W({slot:"trailing-icon"})],$.prototype,"trailingIcons",void 0);/**
|
|
1645
1645
|
* @license
|
|
1646
1646
|
* Copyright 2021 Google LLC
|
|
1647
1647
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1649,12 +1649,12 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1649
1649
|
* @license
|
|
1650
1650
|
* Copyright 2024 Google LLC
|
|
1651
1651
|
* SPDX-License-Identifier: Apache-2.0
|
|
1652
|
-
*/const
|
|
1652
|
+
*/const Va=f`:host{display:inline-flex;outline:none;resize:both;text-align:start;-webkit-tap-highlight-color:rgba(0,0,0,0)}.text-field,.field{width:100%}.text-field{display:inline-flex}.field{cursor:text}.disabled .field{cursor:default}.text-field,.textarea .field{resize:inherit}.icon{color:currentColor;display:flex;fill:currentColor}.icon ::slotted(*){display:flex}[hasstart] .icon.leading{font-size:var(--_leading-icon-size);height:var(--_leading-icon-size);width:var(--_leading-icon-size)}[hasend] .icon.trailing{font-size:var(--_trailing-icon-size);height:var(--_trailing-icon-size);width:var(--_trailing-icon-size)}.input-wrapper{display:flex}.input-wrapper>*{all:inherit;padding:0}.input{caret-color:var(--_caret-color);overflow-x:hidden;text-align:inherit}.input::placeholder{color:currentColor;opacity:1}.input::-webkit-calendar-picker-indicator{display:none}.input::-webkit-search-decoration,.input::-webkit-search-cancel-button{display:none}@media(forced-colors: active){.input{background:none}}.no-spinner .input::-webkit-inner-spin-button,.no-spinner .input::-webkit-outer-spin-button{display:none}.no-spinner .input[type=number]{-moz-appearance:textfield}:focus-within .input{caret-color:var(--_focus-caret-color)}.error:focus-within .input{caret-color:var(--_error-focus-caret-color)}.text-field:not(.disabled) .prefix{color:var(--_input-text-prefix-color)}.text-field:not(.disabled) .suffix{color:var(--_input-text-suffix-color)}.text-field:not(.disabled) .input::placeholder{color:var(--_input-text-placeholder-color)}.prefix,.suffix{text-wrap:nowrap;width:min-content}.prefix{padding-inline-end:var(--_input-text-prefix-trailing-space)}.suffix{padding-inline-start:var(--_input-text-suffix-leading-space)}
|
|
1653
1653
|
`;/**
|
|
1654
1654
|
* @license
|
|
1655
1655
|
* Copyright 2021 Google LLC
|
|
1656
1656
|
* SPDX-License-Identifier: Apache-2.0
|
|
1657
|
-
*/let co=class extends fc{constructor(){super(...arguments),this.fieldTag=Z`md-filled-field`}};co.styles=[
|
|
1657
|
+
*/let co=class extends fc{constructor(){super(...arguments),this.fieldTag=Z`md-filled-field`}};co.styles=[Va,lc],co=d([b("md-filled-text-field")],co);/**
|
|
1658
1658
|
* @license
|
|
1659
1659
|
* Copyright 2024 Google LLC
|
|
1660
1660
|
* SPDX-License-Identifier: Apache-2.0
|
|
@@ -1667,7 +1667,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1667
1667
|
* @license
|
|
1668
1668
|
* Copyright 2021 Google LLC
|
|
1669
1669
|
* SPDX-License-Identifier: Apache-2.0
|
|
1670
|
-
*/let ho=class extends bc{constructor(){super(...arguments),this.fieldTag=Z`md-outlined-field`}};ho.styles=[
|
|
1670
|
+
*/let ho=class extends bc{constructor(){super(...arguments),this.fieldTag=Z`md-outlined-field`}};ho.styles=[Va,mc],ho=d([b("md-outlined-text-field")],ho);var gc=Object.defineProperty,yc=Object.getOwnPropertyDescriptor,K=(o,e,t,r)=>{for(var i=r>1?void 0:r?yc(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&gc(e,t,i),i};a.ScbAccordionItem=class extends g{constructor(){super(...arguments),this.expanded=!1,this.label="",this.content="",this.overline="",this.supportingText="",this.leading=!1,this.leadingVariant="",this.leadingIcon="",this.imgHrefImage="",this.avatarLabel="",this.avatarAlt="",this.avatarVariant="icon",this.avatarSrc="",this.density=0,this._unique=a.ScbAccordionItem._uid(),this.toggleAccordion=()=>{const e=this.closest("scb-accordion");e!=null&&e.hasAttribute("detached")||e.querySelectorAll("scb-accordion-item").forEach(r=>{r!==this&&(r.expanded=!1,r._applyInert())}),this.expanded=!this.expanded,this._applyInert()}}static _uid(){var e,t;return((t=(e=globalThis.crypto)==null?void 0:e.randomUUID)==null?void 0:t.call(e))??`${a.ScbAccordionItem._uidPrefix}-${++a.ScbAccordionItem._uidSeq}`}async firstUpdated(){a.ScbAccordionItem._mdIconLoaded||(await Promise.resolve().then(()=>X),a.ScbAccordionItem._mdIconLoaded=!0),a.ScbAccordionItem._mdRippleLoaded||(await Promise.resolve().then(()=>pr),a.ScbAccordionItem._mdRippleLoaded=!0),this._applyInert()}disconnectedCallback(){super.disconnectedCallback()}_onKeyDown(e){const t=this.closest("scb-accordion"),i=Array.from((t==null?void 0:t.querySelectorAll("scb-accordion-item"))||[]).map(h=>h.renderRoot.querySelector(".scb-accordion-top")).filter(h=>!!h),s=e.currentTarget,n=i.indexOf(s);switch(e.key){case"Enter":case" ":e.preventDefault(),this.toggleAccordion();break;case"ArrowDown":e.preventDefault(),n<i.length-1&&i[n+1].focus();break;case"ArrowUp":e.preventDefault(),n>0&&i[n-1].focus();break;case"Home":e.preventDefault(),i.length&&i[0].focus();break;case"End":e.preventDefault(),i.length&&i[i.length-1].focus();break}}_renderLeading(){if(!this.leading)return p;switch(this.leadingVariant){case"icon":return c`<md-icon>${this.leadingIcon}</md-icon>`;case"avatar":return c`
|
|
1671
1671
|
<scb-avatar
|
|
1672
1672
|
label=${this.avatarLabel}
|
|
1673
1673
|
alt=${this.avatarAlt}
|
|
@@ -1834,11 +1834,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
1834
1834
|
overflow: hidden;
|
|
1835
1835
|
}
|
|
1836
1836
|
@media (prefers-reduced-motion: reduce) { md-ripple { display: none; } }
|
|
1837
|
-
`],K([l({type:Boolean})],a.ScbAccordionItem.prototype,"expanded",2),K([l({type:String,reflect:!0})],a.ScbAccordionItem.prototype,"label",2),K([l({type:String})],a.ScbAccordionItem.prototype,"content",2),K([l({type:String,attribute:"overline"})],a.ScbAccordionItem.prototype,"overline",2),K([l({type:String,attribute:"supporting-text"})],a.ScbAccordionItem.prototype,"supportingText",2),K([l({type:Boolean})],a.ScbAccordionItem.prototype,"leading",2),K([l({type:String,attribute:"leading-variant",reflect:!0})],a.ScbAccordionItem.prototype,"leadingVariant",2),K([l({type:String,attribute:"leading-icon"})],a.ScbAccordionItem.prototype,"leadingIcon",2),K([l({type:String,attribute:"img-href-image",reflect:!0})],a.ScbAccordionItem.prototype,"imgHrefImage",2),K([l({type:String,attribute:"avatar-label"})],a.ScbAccordionItem.prototype,"avatarLabel",2),K([l({type:String,attribute:"avatar-alt"})],a.ScbAccordionItem.prototype,"avatarAlt",2),K([l({type:String,attribute:"avatar-variant"})],a.ScbAccordionItem.prototype,"avatarVariant",2),K([l({type:String,attribute:"avatar-src"})],a.ScbAccordionItem.prototype,"avatarSrc",2),K([l({type:Number,reflect:!0})],a.ScbAccordionItem.prototype,"density",2),a.ScbAccordionItem=K([b("scb-accordion-item")],a.ScbAccordionItem);var xc=Object.defineProperty,_c=Object.getOwnPropertyDescriptor,
|
|
1837
|
+
`],K([l({type:Boolean})],a.ScbAccordionItem.prototype,"expanded",2),K([l({type:String,reflect:!0})],a.ScbAccordionItem.prototype,"label",2),K([l({type:String})],a.ScbAccordionItem.prototype,"content",2),K([l({type:String,attribute:"overline"})],a.ScbAccordionItem.prototype,"overline",2),K([l({type:String,attribute:"supporting-text"})],a.ScbAccordionItem.prototype,"supportingText",2),K([l({type:Boolean})],a.ScbAccordionItem.prototype,"leading",2),K([l({type:String,attribute:"leading-variant",reflect:!0})],a.ScbAccordionItem.prototype,"leadingVariant",2),K([l({type:String,attribute:"leading-icon"})],a.ScbAccordionItem.prototype,"leadingIcon",2),K([l({type:String,attribute:"img-href-image",reflect:!0})],a.ScbAccordionItem.prototype,"imgHrefImage",2),K([l({type:String,attribute:"avatar-label"})],a.ScbAccordionItem.prototype,"avatarLabel",2),K([l({type:String,attribute:"avatar-alt"})],a.ScbAccordionItem.prototype,"avatarAlt",2),K([l({type:String,attribute:"avatar-variant"})],a.ScbAccordionItem.prototype,"avatarVariant",2),K([l({type:String,attribute:"avatar-src"})],a.ScbAccordionItem.prototype,"avatarSrc",2),K([l({type:Number,reflect:!0})],a.ScbAccordionItem.prototype,"density",2),a.ScbAccordionItem=K([b("scb-accordion-item")],a.ScbAccordionItem);var xc=Object.defineProperty,_c=Object.getOwnPropertyDescriptor,Ua=(o,e,t,r)=>{for(var i=r>1?void 0:r?_c(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&xc(e,t,i),i};a.ScbAccordion=class extends g{constructor(){super(...arguments),this.detached=!1}render(){return c`
|
|
1838
1838
|
<div class="scb-accordion" ?detached=${this.detached}>
|
|
1839
1839
|
<slot></slot>
|
|
1840
1840
|
</div>
|
|
1841
|
-
`}},
|
|
1841
|
+
`}},Ua([l({type:Boolean,reflect:!0})],a.ScbAccordion.prototype,"detached",2),a.ScbAccordion=Ua([b("scb-accordion")],a.ScbAccordion);var wc=Object.defineProperty,Sc=Object.getOwnPropertyDescriptor,ge=(o,e,t,r)=>{for(var i=r>1?void 0:r?Sc(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&wc(e,t,i),i};a.ScbButton=class extends g{constructor(){super(...arguments),this.variant="filled",this.type="button",this.label="Button",this.trailingIcon=!1,this.icon="",this.disabled=!1,this.href="",this.target="",this.rel="",this.__loadedButtons=new Set,this.__iconLoaded=!1}async __ensureDepsLoaded(){if(!this.__loadedButtons.has(this.variant)){switch(this.variant){case"filled":await Promise.resolve().then(()=>vn);break;case"outlined":await Promise.resolve().then(()=>xn);break;case"filled-tonal":await Promise.resolve().then(()=>bn);break;case"text":await Promise.resolve().then(()=>Sn);break}this.__loadedButtons.add(this.variant)}this.icon&&!this.__iconLoaded&&(await Promise.resolve().then(()=>X),this.__iconLoaded=!0)}__getMdHost(){return this.renderRoot.querySelector("md-filled-button, md-outlined-button, md-filled-tonal-button, md-text-button")}__getInnerNativeButton(e){var t;return((t=e==null?void 0:e.shadowRoot)==null?void 0:t.querySelector("button"))??null}__syncAriaToInner(){var m;const e=this.__getMdHost(),t=this.__getInnerNativeButton(e);if(!e||!t)return;const r=(this.getAttribute("aria-label")||"").trim(),i=(e.getAttribute("aria-label")||"").trim(),s=this.label.trim()===""?(this.icon||"").trim():"",n=r||i||s;n?t.setAttribute("aria-label",n):t.removeAttribute("aria-label");const h=this.getAttribute("aria-controls");h!==null?t.setAttribute("aria-controls",h):t.removeAttribute("aria-controls");const u=this.getAttribute("aria-expanded");u!==null?t.setAttribute("aria-expanded",u):t.removeAttribute("aria-expanded"),e.removeAttribute("aria-label"),e.removeAttribute("aria-controls"),e.removeAttribute("aria-expanded"),this.removeAttribute("aria-expanded"),(m=this.__ariaObserver)==null||m.disconnect(),this.__ariaObserver=new MutationObserver(y=>{const v=this.__getMdHost(),x=this.__getInnerNativeButton(v);if(!(!v||!x)){for(const _ of y){if(_.type!=="attributes"||!_.attributeName)continue;const S=_.attributeName,C=this.getAttribute(S);if(S==="aria-label"){const A=(v.getAttribute("aria-label")||"").trim(),I=(C||A||(this.label.trim()===""?(this.icon||"").trim():"")).trim();I?x.setAttribute("aria-label",I):x.removeAttribute("aria-label"),v.removeAttribute("aria-label")}else(S==="aria-controls"||S==="aria-expanded")&&(C===null?x.removeAttribute(S):x.setAttribute(S,C),S==="aria-expanded"&&this.removeAttribute("aria-expanded"))}v.removeAttribute("aria-label"),v.removeAttribute("aria-controls"),v.removeAttribute("aria-expanded")}}),this.__ariaObserver.observe(this,{attributes:!0,attributeFilter:["aria-label","aria-controls","aria-expanded"]})}firstUpdated(){(this.type==="submit"||this.type==="reset")&&this.addEventListener("click",()=>{if(!this.disabled){const e=this.closest("form");e&&(this.type==="submit"&&e.requestSubmit(),this.type==="reset"&&e.reset())}}),this.__ensureDepsLoaded(),this.__syncAriaToInner()}updated(e){(e.has("variant")||e.has("icon")&&this.icon)&&this.__ensureDepsLoaded(),e.has("variant")&&this.__syncAriaToInner()}disconnectedCallback(){var e;(e=this.__ariaObserver)==null||e.disconnect(),super.disconnectedCallback()}static get styles(){return f`
|
|
1842
1842
|
/* Gör hosten stretchbar i t.ex. flex/grid */
|
|
1843
1843
|
:host {
|
|
1844
1844
|
display: inline-flex;
|
|
@@ -2230,7 +2230,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
2230
2230
|
>
|
|
2231
2231
|
${this.__renderMd(!0)}
|
|
2232
2232
|
</scb-tooltip>
|
|
2233
|
-
`:this.__renderMd(!1)}},a.ScbIconButton.styles=f``,xe([l({type:String,attribute:"aria-label"})],a.ScbIconButton.prototype,"ariaLabel",2),xe([l({type:String})],a.ScbIconButton.prototype,"tooltip",2),xe([l({type:String})],a.ScbIconButton.prototype,"variant",2),xe([l({type:String})],a.ScbIconButton.prototype,"icon",2),xe([l({type:Boolean,reflect:!0})],a.ScbIconButton.prototype,"toggle",2),xe([l({type:Boolean,reflect:!0})],a.ScbIconButton.prototype,"selected",2),xe([l({type:String})],a.ScbIconButton.prototype,"toggleofficon",2),xe([l({type:String})],a.ScbIconButton.prototype,"toggleonicon",2),xe([l({type:Boolean,reflect:!0})],a.ScbIconButton.prototype,"disabled",2),a.ScbIconButton=xe([b("scb-icon-button")],a.ScbIconButton);const
|
|
2233
|
+
`:this.__renderMd(!1)}},a.ScbIconButton.styles=f``,xe([l({type:String,attribute:"aria-label"})],a.ScbIconButton.prototype,"ariaLabel",2),xe([l({type:String})],a.ScbIconButton.prototype,"tooltip",2),xe([l({type:String})],a.ScbIconButton.prototype,"variant",2),xe([l({type:String})],a.ScbIconButton.prototype,"icon",2),xe([l({type:Boolean,reflect:!0})],a.ScbIconButton.prototype,"toggle",2),xe([l({type:Boolean,reflect:!0})],a.ScbIconButton.prototype,"selected",2),xe([l({type:String})],a.ScbIconButton.prototype,"toggleofficon",2),xe([l({type:String})],a.ScbIconButton.prototype,"toggleonicon",2),xe([l({type:Boolean,reflect:!0})],a.ScbIconButton.prototype,"disabled",2),a.ScbIconButton=xe([b("scb-icon-button")],a.ScbIconButton);const ja=Object.freeze(Object.defineProperty({__proto__:null,get ScbIconButton(){return a.ScbIconButton}},Symbol.toStringTag,{value:"Module"}));var Ic=Object.defineProperty,Tc=Object.getOwnPropertyDescriptor,Wa=o=>{throw TypeError(o)},R=(o,e,t,r)=>{for(var i=r>1?void 0:r?Tc(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Ic(e,t,i),i},po=(o,e,t)=>e.has(o)||Wa("Cannot "+t),Gr=(o,e,t)=>(po(o,e,"read from private field"),t?t.call(o):e.get(o)),Yt=(o,e,t)=>e.has(o)?Wa("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),uo=(o,e,t,r)=>(po(o,e,"write to private field"),e.set(o,t),t),Ga=(o,e,t)=>(po(o,e,"access private method"),t),Kr,Yr,Xr,Zr,vo,fo;a.ScbListItem=class extends g{constructor(){super(...arguments),Yt(this,Zr),this.type="text",this.href="",this.itemHref="",this.target="",this.disabled=!1,this.label="",this.supportingText="",this.overline="",this.leading=!1,this.leadingVariant="",this.leadingIcon="",this.avatarLabel="",this.avatarAlt="",this.avatarVariant="icon",this.avatarSrc="",this.imgHrefImage="",this.trailing=!1,this.trailingVariant="",this.trailingIcon="",this.density=0,this.noDivider=!1,Yt(this,Kr,!1),Yt(this,Yr,!1),Yt(this,Xr,!1),this.onRowClick=()=>{var r,i;if(this.type==="link"&&(this.href||this.itemHref))return;const e=(r=this.shadowRoot)==null?void 0:r.querySelector("scb-checkbox"),t=(i=this.shadowRoot)==null?void 0:i.querySelector("scb-switch");e&&(e.checked=!e.checked),t&&(t.selected=!t.selected)},Yt(this,fo,e=>{var t;if(!e.defaultPrevented&&(e.key==="Enter"||e.key===" ")){if(this.type==="link"){const r=(t=this.shadowRoot)==null?void 0:t.querySelector("a[href]");if(r){e.preventDefault(),r.click();return}}e.preventDefault(),this.onRowClick()}})}static get styles(){return f`
|
|
2234
2234
|
:host {
|
|
2235
2235
|
border-bottom: var(--stroke-border, 1px) solid var(--md-sys-color-outline-variant);
|
|
2236
2236
|
margin-bottom: calc(var(--stroke-border, 1px) * -1);
|
|
@@ -2240,6 +2240,9 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
2240
2240
|
font-family: var(--brand-font);
|
|
2241
2241
|
}
|
|
2242
2242
|
|
|
2243
|
+
/* Per-item: ingen divider när attributet är satt */
|
|
2244
|
+
:host([no-divider]) { --stroke-border: 0px; }
|
|
2245
|
+
|
|
2243
2246
|
md-focus-ring {
|
|
2244
2247
|
position: absolute;
|
|
2245
2248
|
inset: 0;
|
|
@@ -2324,15 +2327,15 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
2324
2327
|
|
|
2325
2328
|
:host([trailing-variant="checkbox"]) .row,
|
|
2326
2329
|
:host([trailing-variant="switch"]) .row {
|
|
2327
|
-
|
|
2330
|
+
cursor: pointer;
|
|
2328
2331
|
}
|
|
2329
2332
|
|
|
2330
2333
|
:host([disabled]) .row {
|
|
2331
|
-
|
|
2334
|
+
cursor: default;
|
|
2332
2335
|
}
|
|
2333
2336
|
|
|
2334
2337
|
.link { text-decoration: none; color: inherit; display: contents; }
|
|
2335
|
-
`}async firstUpdated(){await
|
|
2338
|
+
`}async firstUpdated(){await Ga(this,Zr,vo).call(this),this.addEventListener("keydown",Gr(this,fo))}updated(e){super.updated(e),(e.has("leading")||e.has("leadingVariant")||e.has("trailing")||e.has("trailingVariant")||e.has("type")||e.has("target"))&&Ga(this,Zr,vo).call(this)}render(){const e=this.leading?(()=>{switch(this.leadingVariant){case"icon":return this.leadingIcon?c`<div class="leading"><md-icon>${this.leadingIcon}</md-icon></div>`:p;case"avatar":return c`
|
|
2336
2339
|
<div class="leading">
|
|
2337
2340
|
<scb-avatar
|
|
2338
2341
|
label=${this.avatarLabel}
|
|
@@ -2358,7 +2361,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
2358
2361
|
</div>
|
|
2359
2362
|
|
|
2360
2363
|
<md-focus-ring></md-focus-ring>
|
|
2361
|
-
`}},Kr=new WeakMap,Yr=new WeakMap,Xr=new WeakMap,Zr=new WeakSet,vo=async function(){const o=this.type==="link"&&(!this.trailing||this.trailingVariant==="icon");(this.leading&&this.leadingVariant==="icon"||this.trailing&&this.trailingVariant==="icon"||o)&&!Gr(this,Kr)&&(await Promise.resolve().then(()=>X),uo(this,Kr,!0)),this.trailing&&this.trailingVariant==="checkbox"&&!Gr(this,Yr)&&(await Promise.resolve().then(()=>Qa),uo(this,Yr,!0)),this.trailing&&this.trailingVariant==="switch"&&!Gr(this,Xr)&&(await Promise.resolve().then(()=>ys),uo(this,Xr,!0))},fo=new WeakMap,
|
|
2364
|
+
`}},Kr=new WeakMap,Yr=new WeakMap,Xr=new WeakMap,Zr=new WeakSet,vo=async function(){const o=this.type==="link"&&(!this.trailing||this.trailingVariant==="icon");(this.leading&&this.leadingVariant==="icon"||this.trailing&&this.trailingVariant==="icon"||o)&&!Gr(this,Kr)&&(await Promise.resolve().then(()=>X),uo(this,Kr,!0)),this.trailing&&this.trailingVariant==="checkbox"&&!Gr(this,Yr)&&(await Promise.resolve().then(()=>Qa),uo(this,Yr,!0)),this.trailing&&this.trailingVariant==="switch"&&!Gr(this,Xr)&&(await Promise.resolve().then(()=>ys),uo(this,Xr,!0))},fo=new WeakMap,R([l({type:String,reflect:!0,attribute:"type"})],a.ScbListItem.prototype,"type",2),R([l({type:String})],a.ScbListItem.prototype,"href",2),R([l({type:String,attribute:"item-href"})],a.ScbListItem.prototype,"itemHref",2),R([l({type:String,attribute:"target"})],a.ScbListItem.prototype,"target",2),R([l({type:Boolean,attribute:"disabled"})],a.ScbListItem.prototype,"disabled",2),R([l({type:String,reflect:!0})],a.ScbListItem.prototype,"label",2),R([l({type:String,attribute:"supporting-text"})],a.ScbListItem.prototype,"supportingText",2),R([l({type:String,attribute:"overline"})],a.ScbListItem.prototype,"overline",2),R([l({type:Boolean})],a.ScbListItem.prototype,"leading",2),R([l({type:String,attribute:"leading-variant",reflect:!0})],a.ScbListItem.prototype,"leadingVariant",2),R([l({type:String,attribute:"leading-icon"})],a.ScbListItem.prototype,"leadingIcon",2),R([l({type:String,attribute:"avatar-label"})],a.ScbListItem.prototype,"avatarLabel",2),R([l({type:String,attribute:"avatar-alt"})],a.ScbListItem.prototype,"avatarAlt",2),R([l({type:String,attribute:"avatar-variant"})],a.ScbListItem.prototype,"avatarVariant",2),R([l({type:String,attribute:"avatar-src"})],a.ScbListItem.prototype,"avatarSrc",2),R([l({type:String,reflect:!0,attribute:"img-href-image"})],a.ScbListItem.prototype,"imgHrefImage",2),R([l({type:Boolean})],a.ScbListItem.prototype,"trailing",2),R([l({type:String,attribute:"trailing-variant",reflect:!0})],a.ScbListItem.prototype,"trailingVariant",2),R([l({type:String,attribute:"trailing-icon"})],a.ScbListItem.prototype,"trailingIcon",2),R([l({type:Number,reflect:!0})],a.ScbListItem.prototype,"density",2),R([l({type:Boolean,attribute:"no-divider",reflect:!0})],a.ScbListItem.prototype,"noDivider",2),a.ScbListItem=R([b("scb-list-item")],a.ScbListItem);var zc=Object.defineProperty,Oc=Object.getOwnPropertyDescriptor,Ka=o=>{throw TypeError(o)},mo=(o,e,t,r)=>{for(var i=r>1?void 0:r?Oc(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&zc(e,t,i),i},Ya=(o,e,t)=>e.has(o)||Ka("Cannot "+t),Pc=(o,e,t)=>(Ya(o,e,"read from private field"),e.get(o)),Lc=(o,e,t)=>e.has(o)?Ka("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),Dc=(o,e,t,r)=>(Ya(o,e,"write to private field"),e.set(o,t),t),Jr;a.ScbList=class extends g{constructor(){super(...arguments),Lc(this,Jr,!1),this.noDivider=!1,this._onSlotChange=()=>this._setupItems()}async firstUpdated(){Pc(this,Jr)||(await Promise.resolve().then(()=>hl),Dc(this,Jr,!0)),this._setupItems()}_getItems(){var t;return(((t=this._slotEl)==null?void 0:t.assignedElements({flatten:!0}))??[]).filter(r=>r instanceof HTMLElement)}_setupItems(){var r;this._getItems().forEach((i,s)=>{i.hasAttribute("role")||i.setAttribute("role","listitem"),i.setAttribute("tabindex",s===0?"0":"-1")});const t=(r=this.renderRoot)==null?void 0:r.querySelector("md-list");t&&!t.hasAttribute("data-kbd")&&(t.setAttribute("data-kbd","true"),t.addEventListener("keydown",i=>this._onKeyDown(i)))}_onKeyDown(e){const t=this._getItems();if(!t.length)return;const r=t.findIndex(s=>s.getAttribute("tabindex")==="0"),i=s=>{const n=(s%t.length+t.length)%t.length;t.forEach(u=>u.setAttribute("tabindex","-1"));const h=t[n];h.setAttribute("tabindex","0"),h.focus()};switch(e.key){case"ArrowDown":case"ArrowRight":e.preventDefault(),i(r<0?0:r+1);break;case"ArrowUp":case"ArrowLeft":e.preventDefault(),i(r<0?0:r-1);break;case"Home":e.preventDefault(),i(0);break;case"End":e.preventDefault(),i(t.length-1);break}}render(){return c`
|
|
2362
2365
|
<md-list role="list" @slotchange=${this._onSlotChange}>
|
|
2363
2366
|
<slot></slot>
|
|
2364
2367
|
</md-list>
|
|
@@ -2372,10 +2375,17 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
2372
2375
|
background: var(--scb-list-bg);
|
|
2373
2376
|
}
|
|
2374
2377
|
|
|
2375
|
-
|
|
2378
|
+
/* Visa top-border på första raden endast när listan saknar no-divider
|
|
2379
|
+
och endast om första item inte själv är markerad med no-divider. */
|
|
2380
|
+
:host(:not([no-divider])) ::slotted(scb-list-item:first-of-type:not([no-divider])) {
|
|
2376
2381
|
border-top: 1px solid var(--md-sys-color-outline-variant);
|
|
2377
2382
|
}
|
|
2378
|
-
|
|
2383
|
+
|
|
2384
|
+
/* När listan har no-divider, tryck ned variabeln till alla barn */
|
|
2385
|
+
:host([no-divider]) ::slotted(scb-list-item) {
|
|
2386
|
+
--stroke-border: 0px;
|
|
2387
|
+
}
|
|
2388
|
+
`],mo([l({type:Boolean,attribute:"no-divider",reflect:!0})],a.ScbList.prototype,"noDivider",2),mo([k("slot")],a.ScbList.prototype,"_slotEl",2),a.ScbList=mo([b("scb-list")],a.ScbList);var Rc=Object.defineProperty,Bc=Object.getOwnPropertyDescriptor,yt=(o,e,t,r)=>{for(var i=r>1?void 0:r?Bc(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Rc(e,t,i),i};let Mc=0;a.ScbSearch=class extends g{constructor(){super(...arguments),this.supportingText="Hinted search text",this.value="",this.size="default",this.fullScreen=!1,this._inputFocused=!1,this._visibleSuggestions=0,this._activeIndex=-1,this._listboxId=`scb-search-listbox-${++Mc}`,this._kbMode=!1,this._kbShouldShowRing=!1,this._onGlobalKeydown=e=>{e.key==="Tab"&&(this._kbShouldShowRing=!0,this._inputFocused&&this._updateInputRingVisibility())},this._onGlobalPointerDown=()=>{this._kbShouldShowRing=!1,this._inputFocused&&this._updateInputRingVisibility()},this._listScrollHandler=()=>{const e=this._getActiveItem();this._kbMode&&e&&this._positionOptionRing(e)}}connectedCallback(){super.connectedCallback(),this._onWindowResize=this._onWindowResize.bind(this),window.addEventListener("resize",this._onWindowResize,{passive:!0}),window.addEventListener("keydown",this._onGlobalKeydown,!0),window.addEventListener("pointerdown",this._onGlobalPointerDown,!0)}disconnectedCallback(){const e=this._inputEl();e&&this._boundNativeKeydown&&e.removeEventListener("keydown",this._boundNativeKeydown,!0),this._detachListScrollListener(),window.removeEventListener("resize",this._onWindowResize),window.removeEventListener("keydown",this._onGlobalKeydown,!0),window.removeEventListener("pointerdown",this._onGlobalPointerDown,!0),super.disconnectedCallback()}firstUpdated(){this._ensureListboxA11y(),this._updateComboboxA11y();const e=this._inputEl();e&&(this._boundNativeKeydown=t=>this._handleKey(t),e.addEventListener("keydown",this._boundNativeKeydown,!0))}updated(){this._ensureListboxA11y(),this._updateComboboxA11y(),this._attachListScrollListener()}render(){const e=(this.value??"").trim().length>0,t=this._inputFocused&&e&&this._hasSuggestions;return c`
|
|
2379
2389
|
<div class="ripple-wrapper">
|
|
2380
2390
|
<md-icon class="leading">${e?"arrow_back":"search"}</md-icon>
|
|
2381
2391
|
|
|
@@ -2840,7 +2850,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
2840
2850
|
* @license
|
|
2841
2851
|
* Copyright 2018 Google LLC
|
|
2842
2852
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
2843
|
-
*/const Zt=o=>o??p;var Vc=Object.defineProperty,Uc=Object.getOwnPropertyDescriptor,Xa=o=>{throw TypeError(o)},st=(o,e,t,r)=>{for(var i=r>1?void 0:r?Uc(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Vc(e,t,i),i},jc=(o,e,t)=>e.has(o)||Xa("Cannot "+t),Wc=(o,e,t)=>(jc(o,e,"read from private field"),t?t.call(o):e.get(o)),Gc=(o,e,t)=>e.has(o)?Xa("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),
|
|
2853
|
+
*/const Zt=o=>o??p;var Vc=Object.defineProperty,Uc=Object.getOwnPropertyDescriptor,Xa=o=>{throw TypeError(o)},st=(o,e,t,r)=>{for(var i=r>1?void 0:r?Uc(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Vc(e,t,i),i},jc=(o,e,t)=>e.has(o)||Xa("Cannot "+t),Wc=(o,e,t)=>(jc(o,e,"read from private field"),t?t.call(o):e.get(o)),Gc=(o,e,t)=>e.has(o)?Xa("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),bo;a.ScbLink=class extends g{constructor(){super(...arguments),this.href="",this.disabled=!1,this.ariaLabel="",Gc(this,bo,e=>{this.disabled&&(e.preventDefault(),e.stopPropagation())})}render(){const e=this.target==="_blank"&&!this.rel?"noopener noreferrer":this.rel;return c`
|
|
2844
2854
|
<a
|
|
2845
2855
|
part="anchor"
|
|
2846
2856
|
href=${Zt(this.disabled?void 0:this.href||void 0)}
|
|
@@ -2849,11 +2859,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
2849
2859
|
download=${Zt(this.download)}
|
|
2850
2860
|
aria-disabled=${this.disabled?"true":"false"}
|
|
2851
2861
|
aria-label=${Zt(this.ariaLabel||void 0)}
|
|
2852
|
-
@click=${Wc(this,
|
|
2862
|
+
@click=${Wc(this,bo)}
|
|
2853
2863
|
><slot></slot></a>
|
|
2854
2864
|
|
|
2855
2865
|
<md-focus-ring></md-focus-ring>
|
|
2856
|
-
`}},
|
|
2866
|
+
`}},bo=new WeakMap,a.ScbLink.styles=f`
|
|
2857
2867
|
:host {
|
|
2858
2868
|
display: inline-block;
|
|
2859
2869
|
position: relative;
|
|
@@ -3458,11 +3468,11 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
3458
3468
|
.scb-card.filled .content.list ::slotted(scb-list) {
|
|
3459
3469
|
--scb-list-bg: var(--md-sys-color-surface-dim);
|
|
3460
3470
|
}
|
|
3461
|
-
`,N([l({type:String})],a.ScbCard.prototype,"type",2),N([l({type:String})],a.ScbCard.prototype,"variant",2),N([l({type:String})],a.ScbCard.prototype,"direction",2),N([l({type:String,attribute:"media-type"})],a.ScbCard.prototype,"mediaType",2),N([l({type:String,attribute:"media-href"})],a.ScbCard.prototype,"mediaHref",2),N([l({type:String,attribute:"card-href"})],a.ScbCard.prototype,"cardHref",2),N([l({type:String})],a.ScbCard.prototype,"label",2),N([l({type:String,attribute:"sub-label"})],a.ScbCard.prototype,"subLabel",2),N([l({type:String,attribute:"supporting-text"})],a.ScbCard.prototype,"supportingText",2),N([l({type:Date,reflect:!0})],a.ScbCard.prototype,"date",2),N([l({type:String,attribute:"social-comments-text"})],a.ScbCard.prototype,"commentsText",2),N([l({type:Number,attribute:"social-comments",reflect:!0})],a.ScbCard.prototype,"comments",2),N([l({type:String,attribute:"social-likes-text"})],a.ScbCard.prototype,"likesText",2),N([l({type:Number,attribute:"social-likes",reflect:!0})],a.ScbCard.prototype,"likes",2),N([l({type:Boolean,reflect:!0,attribute:"full-height"})],a.ScbCard.prototype,"fullHeight",2),N([l({type:Boolean,reflect:!0,attribute:"full-width"})],a.ScbCard.prototype,"fullWidth",2),N([l({type:Boolean,reflect:!0})],a.ScbCard.prototype,"stretch",2),a.ScbCard=N([b("scb-card")],a.ScbCard);var rd=Object.defineProperty,id=Object.getOwnPropertyDescriptor,Ja=o=>{throw TypeError(o)},ei=(o,e,t,r)=>{for(var i=r>1?void 0:r?id(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&rd(e,t,i),i},od=(o,e,t)=>e.has(o)||Ja("Cannot "+t),
|
|
3471
|
+
`,N([l({type:String})],a.ScbCard.prototype,"type",2),N([l({type:String})],a.ScbCard.prototype,"variant",2),N([l({type:String})],a.ScbCard.prototype,"direction",2),N([l({type:String,attribute:"media-type"})],a.ScbCard.prototype,"mediaType",2),N([l({type:String,attribute:"media-href"})],a.ScbCard.prototype,"mediaHref",2),N([l({type:String,attribute:"card-href"})],a.ScbCard.prototype,"cardHref",2),N([l({type:String})],a.ScbCard.prototype,"label",2),N([l({type:String,attribute:"sub-label"})],a.ScbCard.prototype,"subLabel",2),N([l({type:String,attribute:"supporting-text"})],a.ScbCard.prototype,"supportingText",2),N([l({type:Date,reflect:!0})],a.ScbCard.prototype,"date",2),N([l({type:String,attribute:"social-comments-text"})],a.ScbCard.prototype,"commentsText",2),N([l({type:Number,attribute:"social-comments",reflect:!0})],a.ScbCard.prototype,"comments",2),N([l({type:String,attribute:"social-likes-text"})],a.ScbCard.prototype,"likesText",2),N([l({type:Number,attribute:"social-likes",reflect:!0})],a.ScbCard.prototype,"likes",2),N([l({type:Boolean,reflect:!0,attribute:"full-height"})],a.ScbCard.prototype,"fullHeight",2),N([l({type:Boolean,reflect:!0,attribute:"full-width"})],a.ScbCard.prototype,"fullWidth",2),N([l({type:Boolean,reflect:!0})],a.ScbCard.prototype,"stretch",2),a.ScbCard=N([b("scb-card")],a.ScbCard);var rd=Object.defineProperty,id=Object.getOwnPropertyDescriptor,Ja=o=>{throw TypeError(o)},ei=(o,e,t,r)=>{for(var i=r>1?void 0:r?id(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&rd(e,t,i),i},od=(o,e,t)=>e.has(o)||Ja("Cannot "+t),go=(o,e,t)=>(od(o,e,"read from private field"),t?t.call(o):e.get(o)),ad=(o,e,t)=>e.has(o)?Ja("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),Jt;a.ScbCheckboxGroup=class extends g{constructor(){super(...arguments),this.orientation="vertical",this.disabled=!1,this.spacing="group",ad(this,Jt,()=>{var r;const e=(r=this.shadowRoot)==null?void 0:r.querySelector("slot");if(!e)return;const t=e.assignedElements({flatten:!0}).filter(i=>i.tagName.toLowerCase()==="scb-checkbox");for(const i of t)this.disabled?i.setAttribute("disabled",""):i.removeAttribute("disabled"),this.orientation==="horizontal"?i.setAttribute("orientation","horizontal"):i.removeAttribute("orientation"),this.spacing==="group"?i.style.setProperty("--scb-checkbox-gap","0"):i.style.removeProperty("--scb-checkbox-gap")})}render(){const e=this.orientation==="horizontal"?"row":"column";return c`
|
|
3462
3472
|
<div class="g" role="group" aria-disabled=${String(this.disabled)} style=${`--_dir:${e}`}>
|
|
3463
|
-
<slot @slotchange=${
|
|
3473
|
+
<slot @slotchange=${go(this,Jt)}></slot>
|
|
3464
3474
|
</div>
|
|
3465
|
-
`}firstUpdated(){
|
|
3475
|
+
`}firstUpdated(){go(this,Jt).call(this)}updated(e){(e.has("disabled")||e.has("orientation")||e.has("spacing"))&&go(this,Jt).call(this)}},Jt=new WeakMap,a.ScbCheckboxGroup.styles=f`
|
|
3466
3476
|
:host {
|
|
3467
3477
|
display: block;
|
|
3468
3478
|
--scb-checkbox-gap: var(--spacing-4, 12px);
|
|
@@ -3559,22 +3569,24 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
3559
3569
|
.lbl { color: var(--md-sys-color-on-surface); }
|
|
3560
3570
|
.supporting-text { color: var(--md-sys-color-on-surface-variant); }
|
|
3561
3571
|
}
|
|
3562
|
-
`,xt([l({type:Boolean,reflect:!0})],a.ScbCheckbox.prototype,"disabled",2),xt([l({type:Boolean,reflect:!0})],a.ScbCheckbox.prototype,"indeterminate",2),xt([l({type:Boolean,reflect:!0})],a.ScbCheckbox.prototype,"checked",2),xt([l({type:String})],a.ScbCheckbox.prototype,"label",2),xt([l({type:String,attribute:"supporting-text"})],a.ScbCheckbox.prototype,"supportingText",2),a.ScbCheckbox=xt([b("scb-checkbox")],a.ScbCheckbox);const Qa=Object.freeze(Object.defineProperty({__proto__:null,get ScbCheckbox(){return a.ScbCheckbox}},Symbol.toStringTag,{value:"Module"}));var ld=Object.defineProperty,cd=Object.getOwnPropertyDescriptor,
|
|
3572
|
+
`,xt([l({type:Boolean,reflect:!0})],a.ScbCheckbox.prototype,"disabled",2),xt([l({type:Boolean,reflect:!0})],a.ScbCheckbox.prototype,"indeterminate",2),xt([l({type:Boolean,reflect:!0})],a.ScbCheckbox.prototype,"checked",2),xt([l({type:String})],a.ScbCheckbox.prototype,"label",2),xt([l({type:String,attribute:"supporting-text"})],a.ScbCheckbox.prototype,"supportingText",2),a.ScbCheckbox=xt([b("scb-checkbox")],a.ScbCheckbox);const Qa=Object.freeze(Object.defineProperty({__proto__:null,get ScbCheckbox(){return a.ScbCheckbox}},Symbol.toStringTag,{value:"Module"}));var ld=Object.defineProperty,cd=Object.getOwnPropertyDescriptor,we=(o,e,t,r)=>{for(var i=r>1?void 0:r?cd(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&ld(e,t,i),i};a.ScbChip=class extends g{constructor(){super(...arguments),this.variant="assist",this.label="",this.icon="",this.disabled=!1,this.elevated=!1,this.removable=!1,this.selected=!1,this.href="",this.target="",this.__loadedVariants=new Set,this.__chipSetLoaded=!1,this.__iconLoaded=!1}updated(e){super.updated(e),(e.has("variant")||e.has("icon"))&&this.__ensureDepsLoaded()}firstUpdated(){this.__ensureDepsLoaded()}async __ensureDepsLoaded(){if(!this.__loadedVariants.has(this.variant)){switch(this.variant){case"assist":await Promise.resolve().then(()=>En);break;case"filter":await Promise.resolve().then(()=>On);break}this.__loadedVariants.add(this.variant)}!this._insideChipSet&&!this.__chipSetLoaded&&(await Promise.resolve().then(()=>In),this.__chipSetLoaded=!0),this.icon&&!this.__iconLoaded&&(await Promise.resolve().then(()=>X),this.__iconLoaded=!0)}get _insideChipSet(){return!!this.closest("md-chip-set")}render(){const e=this._renderChip();return this._insideChipSet?e:c`<md-chip-set>${e}</md-chip-set>`}_renderChip(){const e=this.icon?c`<md-icon slot="icon">${this.icon}</md-icon>`:null;switch(this.variant){case"assist":{const t=this.target==="_blank"?"noopener noreferrer":void 0;return c`
|
|
3563
3573
|
<md-assist-chip
|
|
3564
3574
|
label=${this.label}
|
|
3565
3575
|
?disabled=${this.disabled}
|
|
3566
3576
|
?elevated=${this.elevated}
|
|
3577
|
+
href=${this.href||void 0}
|
|
3578
|
+
target=${this.href&&this.target||void 0}
|
|
3579
|
+
rel=${t}
|
|
3567
3580
|
@update-focus=${this._forward}
|
|
3568
3581
|
>
|
|
3569
3582
|
${e}
|
|
3570
3583
|
</md-assist-chip>
|
|
3571
|
-
|
|
3584
|
+
`}case"filter":return c`
|
|
3572
3585
|
<md-filter-chip
|
|
3573
3586
|
label=${this.label}
|
|
3574
3587
|
?disabled=${this.disabled}
|
|
3575
3588
|
?removable=${this.removable}
|
|
3576
3589
|
?selected=${this.selected}
|
|
3577
|
-
|
|
3578
3590
|
@remove=${this._onRemove}
|
|
3579
3591
|
@update-focus=${this._forward}
|
|
3580
3592
|
@click=${()=>this._toggleSelected()}
|
|
@@ -3603,7 +3615,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
3603
3615
|
color: var(--md-sys-color-on-surface);
|
|
3604
3616
|
}
|
|
3605
3617
|
}
|
|
3606
|
-
`,
|
|
3618
|
+
`,we([l({type:String,reflect:!0})],a.ScbChip.prototype,"variant",2),we([l({type:String})],a.ScbChip.prototype,"label",2),we([l({type:String})],a.ScbChip.prototype,"icon",2),we([l({type:Boolean,reflect:!0})],a.ScbChip.prototype,"disabled",2),we([l({type:Boolean,reflect:!0})],a.ScbChip.prototype,"elevated",2),we([l({type:Boolean,reflect:!0})],a.ScbChip.prototype,"removable",2),we([l({type:Boolean,reflect:!0})],a.ScbChip.prototype,"selected",2),we([l({type:String})],a.ScbChip.prototype,"href",2),we([l({type:String})],a.ScbChip.prototype,"target",2),a.ScbChip=we([b("scb-chip")],a.ScbChip);const dd=Object.freeze(Object.defineProperty({__proto__:null,get ScbChip(){return a.ScbChip}},Symbol.toStringTag,{value:"Module"}));var hd=Object.defineProperty,pd=Object.getOwnPropertyDescriptor,q=(o,e,t,r)=>{for(var i=r>1?void 0:r?pd(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&hd(e,t,i),i};a.ScbDialog=class extends g{constructor(){super(...arguments),this.open=!1,this.inSb=!1,this.scrimClose=!0,this.variant="basic",this.label="",this.icon="",this.supportingText="",this.okButton="OK",this.cancelButton="Avbryt",this.deleteButton="Delete",this.confirmButton="Ta bort",this.denyButton="Avbryt",this.resetButton="Återställ",this.submitButton="Spara",this.formId="",this.formAction="",this.formMethod="",this.__lastTriggerEl=null,this.__slotDeps={"SCB-TEXTFIELD":()=>Promise.resolve().then(()=>Rh),"SCB-CHECKBOX":()=>Promise.resolve().then(()=>Qa),"SCB-RADIO-BUTTON":()=>Promise.resolve().then(()=>_h),"SCB-SWITCH":()=>Promise.resolve().then(()=>ys),"SCB-CHIP":()=>Promise.resolve().then(()=>dd)},this.__onDocumentClick=e=>{this.__getActionFromEvent(e)==="toggle"&&(this.__setOpen(!this.open),e.stopPropagation())},this.__onDocumentKeydown=e=>{this.open&&e.key==="Escape"&&(this.__fire("esc"),this.__setOpen(!1))},this.__onScrimClick=()=>{this.scrimClose&&(this.__fire("scrim"),this.__setOpen(!1))},this.__onOk=()=>{this.__fire("ok"),this.__setOpen(!1)},this.__onCancel=()=>{this.__fire("cancel"),this.__setOpen(!1)},this.__onConfirm=()=>{this.__fire("confirm"),this.__setOpen(!1)},this.__onDeny=()=>{this.__fire("deny"),this.__setOpen(!1)},this.__onReset=()=>{var t,r,i,s;(r=(t=this.shadowRoot)==null?void 0:t.querySelector("form"))==null||r.reset(),(((s=(i=this.shadowRoot)==null?void 0:i.querySelector("slot"))==null?void 0:s.assignedElements({flatten:!0}))??[]).forEach(n=>{const h=n.tagName;h==="SCB-TEXTFIELD"&&(n.value=""),h==="SCB-CHECKBOX"&&(n.checked=!1),h==="SCB-RADIO-BUTTON"&&(n.checked=!1),h==="SCB-SWITCH"&&(n.selected=!1),h==="SCB-CHIP"&&(n.selected=!1)}),this.__fire("reset")},this.__onSubmit=()=>{var e,t;(t=(e=this.shadowRoot)==null?void 0:e.querySelector("form"))==null||t.requestSubmit(),this.__fire("submit"),this.__setOpen(!1)},this.__onKeydownTrap=e=>{if(!this.open||e.key!=="Tab")return;const t=Array.from(this.shadowRoot.querySelectorAll('button,[href],input,select,textarea,[tabindex]:not([tabindex="-1"])')).filter(s=>!s.hasAttribute("disabled"));if(!t.length)return;const r=t[0],i=t[t.length-1];e.shiftKey&&document.activeElement===r?(i.focus(),e.preventDefault()):!e.shiftKey&&document.activeElement===i&&(r.focus(),e.preventDefault())}}async firstUpdated(){await Promise.resolve().then(()=>kc),await Promise.resolve().then(()=>ja),this.icon&&await Promise.resolve().then(()=>X),await this.__ensureSlottedDeps()}async __ensureSlottedDeps(){var r;const e=(r=this.shadowRoot)==null?void 0:r.querySelector("slot");if(!e)return;const t=async i=>{const s=new Set(i.map(n=>n.tagName));for(const n of s){const h=this.__slotDeps[n];h&&await h()}};await t(e.assignedElements({flatten:!0})),e.addEventListener("slotchange",async()=>t(e.assignedElements({flatten:!0})))}__getActionFromEvent(e){if(!this.id)return null;for(const t of e.composedPath())if(t instanceof Element){if(t.getAttribute("data-dialog-toggle")===this.id)return this.__lastTriggerEl=t,"toggle";if(t.getAttribute("aria-controls")===this.id)return this.__lastTriggerEl=t,"toggle"}return null}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.__onDocumentClick,!1),document.addEventListener("keydown",this.__onDocumentKeydown,!0),this.addEventListener("keydown",this.__onKeydownTrap)}disconnectedCallback(){document.removeEventListener("click",this.__onDocumentClick,!1),document.removeEventListener("keydown",this.__onDocumentKeydown,!0),this.removeEventListener("keydown",this.__onKeydownTrap),super.disconnectedCallback()}updated(e){var t,r;if(e.has("open")){const i=e.get("open");this.__updateTriggersExpanded(),this.open&&!i?this.updateComplete.then(()=>{var s,n,h;(h=(n=(s=this.shadowRoot)==null?void 0:s.querySelector('button,[href],input,select,textarea,[tabindex]:not([tabindex="-1"])'))==null?void 0:n.focus)==null||h.call(n)}):!this.open&&i&&((r=(t=this.__lastTriggerEl)==null?void 0:t.focus)==null||r.call(t)),this.__toggleScrollLock(this.open)}e.has("icon")&&this.icon&&Promise.resolve().then(()=>X)}__updateTriggersExpanded(){this.id&&document.querySelectorAll(`[aria-controls="${this.id}"], [data-dialog-toggle="${this.id}"]`).forEach(e=>{e.hasAttribute("aria-controls")&&e.setAttribute("aria-expanded",String(this.open))})}__toggleScrollLock(e){if(this.inSb)return;const t=document.documentElement;t.style.overflow=e?"hidden":""}__setOpen(e){this.open=e,this.__fire(e?"open":"close")}__fire(e,t){this.dispatchEvent(new CustomEvent(e,{detail:t,bubbles:!0,composed:!0}))}__slotIsEmpty(){var t;const e=(t=this.shadowRoot)==null?void 0:t.querySelector("slot");return e?e.assignedElements({flatten:!0}).length===0:!0}renderHeader(e){const t=this.variant==="form"||this.variant==="floating";return c`
|
|
3607
3619
|
<div class="header">
|
|
3608
3620
|
<div class="title">
|
|
3609
3621
|
${this.icon?c`<md-icon class="dialog-icon">${this.icon}</md-icon>`:p}
|
|
@@ -3801,7 +3813,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
3801
3813
|
}
|
|
3802
3814
|
:host([overlay][direction="vertical"][anchor="end"]) { right: calc(var(--scb-divider-gap) / -2); }
|
|
3803
3815
|
:host([overlay][direction="vertical"][anchor="start"]){ left: calc(var(--scb-divider-gap) / -2); }
|
|
3804
|
-
`,_t([l({type:String,reflect:!0})],a.ScbDivider.prototype,"variant",2),_t([l({type:String,reflect:!0})],a.ScbDivider.prototype,"direction",2),_t([l({type:String,reflect:!0})],a.ScbDivider.prototype,"inset",2),_t([l({type:Boolean,reflect:!0})],a.ScbDivider.prototype,"overlay",2),_t([l({type:String,reflect:!0})],a.ScbDivider.prototype,"anchor",2),a.ScbDivider=_t([b("scb-divider")],a.ScbDivider);var fd=Object.defineProperty,md=Object.getOwnPropertyDescriptor,nt=(o,e,t,r)=>{for(var i=r>1?void 0:r?md(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&fd(e,t,i),i};a.ScbDrawerItem=class extends g{constructor(){super(...arguments),this.label="",this.selected=!1,this.leadingIcon="",this.itemHref="",this.hasSlotContent=!1,this.expanded=!1,this.__submenuId=`sub-${Math.random().toString(36).slice(2)}`,this.__focusId=`f-${Math.random().toString(36).slice(2)}`,this._toggleExpand=e=>{e&&e.stopPropagation(),this.hasSlotContent&&this.__setExpanded(!this.expanded)},this._onButtonClick=e=>{e.stopPropagation(),this._dispatchSelect(),this._toggleExpand()},this._onLinkClick=()=>{this._dispatchSelect()},this._onKeyDown=e=>{var i,s,n,h,u,m,y,v,x;const t=Array.from(((i=this.parentElement)==null?void 0:i.querySelectorAll("scb-drawer-item"))||[]),r=t.indexOf(this);switch(e.key){case"ArrowDown":{e.preventDefault(),(n=(s=(t[r+1]||t[0]).shadowRoot)==null?void 0:s.querySelector(".scb-drawer-label-text"))==null||n.focus();break}case"ArrowUp":{e.preventDefault(),(u=(h=(t[r-1]||t[t.length-1]).shadowRoot)==null?void 0:h.querySelector(".scb-drawer-label-text"))==null||u.focus();break}case"Home":{e.preventDefault(),(y=(m=t[0].shadowRoot)==null?void 0:m.querySelector(".scb-drawer-label-text"))==null||y.focus();break}case"End":{e.preventDefault(),(x=(v=t[t.length-1].shadowRoot)==null?void 0:v.querySelector(".scb-drawer-label-text"))==null||x.focus();break}}}}get __submenuEl(){return this.renderRoot.querySelector(`#${this.__submenuId}`)}async __ensureDepsLoaded(){a.ScbDrawerItem.__rippleLoaded||(await Promise.resolve().then(()=>pr),a.ScbDrawerItem.__rippleLoaded=!0),a.ScbDrawerItem.__focusRingLoaded||(await Promise.resolve().then(()=>Ks),a.ScbDrawerItem.__focusRingLoaded=!0),this.leadingIcon&&!a.ScbDrawerItem.__iconLoaded&&(await Promise.resolve().then(()=>X),a.ScbDrawerItem.__iconLoaded=!0),this.hasSlotContent&&!a.ScbDrawerItem.__iconButtonLoaded&&(await Promise.resolve().then(()=>
|
|
3816
|
+
`,_t([l({type:String,reflect:!0})],a.ScbDivider.prototype,"variant",2),_t([l({type:String,reflect:!0})],a.ScbDivider.prototype,"direction",2),_t([l({type:String,reflect:!0})],a.ScbDivider.prototype,"inset",2),_t([l({type:Boolean,reflect:!0})],a.ScbDivider.prototype,"overlay",2),_t([l({type:String,reflect:!0})],a.ScbDivider.prototype,"anchor",2),a.ScbDivider=_t([b("scb-divider")],a.ScbDivider);var fd=Object.defineProperty,md=Object.getOwnPropertyDescriptor,nt=(o,e,t,r)=>{for(var i=r>1?void 0:r?md(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&fd(e,t,i),i};a.ScbDrawerItem=class extends g{constructor(){super(...arguments),this.label="",this.selected=!1,this.leadingIcon="",this.itemHref="",this.hasSlotContent=!1,this.expanded=!1,this.__submenuId=`sub-${Math.random().toString(36).slice(2)}`,this.__focusId=`f-${Math.random().toString(36).slice(2)}`,this._toggleExpand=e=>{e&&e.stopPropagation(),this.hasSlotContent&&this.__setExpanded(!this.expanded)},this._onButtonClick=e=>{e.stopPropagation(),this._dispatchSelect(),this._toggleExpand()},this._onLinkClick=()=>{this._dispatchSelect()},this._onKeyDown=e=>{var i,s,n,h,u,m,y,v,x;const t=Array.from(((i=this.parentElement)==null?void 0:i.querySelectorAll("scb-drawer-item"))||[]),r=t.indexOf(this);switch(e.key){case"ArrowDown":{e.preventDefault(),(n=(s=(t[r+1]||t[0]).shadowRoot)==null?void 0:s.querySelector(".scb-drawer-label-text"))==null||n.focus();break}case"ArrowUp":{e.preventDefault(),(u=(h=(t[r-1]||t[t.length-1]).shadowRoot)==null?void 0:h.querySelector(".scb-drawer-label-text"))==null||u.focus();break}case"Home":{e.preventDefault(),(y=(m=t[0].shadowRoot)==null?void 0:m.querySelector(".scb-drawer-label-text"))==null||y.focus();break}case"End":{e.preventDefault(),(x=(v=t[t.length-1].shadowRoot)==null?void 0:v.querySelector(".scb-drawer-label-text"))==null||x.focus();break}}}}get __submenuEl(){return this.renderRoot.querySelector(`#${this.__submenuId}`)}async __ensureDepsLoaded(){a.ScbDrawerItem.__rippleLoaded||(await Promise.resolve().then(()=>pr),a.ScbDrawerItem.__rippleLoaded=!0),a.ScbDrawerItem.__focusRingLoaded||(await Promise.resolve().then(()=>Ks),a.ScbDrawerItem.__focusRingLoaded=!0),this.leadingIcon&&!a.ScbDrawerItem.__iconLoaded&&(await Promise.resolve().then(()=>X),a.ScbDrawerItem.__iconLoaded=!0),this.hasSlotContent&&!a.ScbDrawerItem.__iconButtonLoaded&&(await Promise.resolve().then(()=>ja),a.ScbDrawerItem.__iconButtonLoaded=!0)}_onSlotChange(e){const r=e.target.assignedElements({flatten:!0});this.hasSlotContent=r.length>0&&r.every(i=>i.tagName==="SCB-SUB-DRAWER")}__setExpanded(e){this.hasSlotContent&&(this.expanded=e,this.dispatchEvent(new CustomEvent("scb-drawer-expand",{bubbles:!0,composed:!0,detail:{item:this,expanded:e}})))}_dispatchSelect(){this.dispatchEvent(new CustomEvent("scb-drawer-select",{bubbles:!0,composed:!0,detail:{item:this}}))}async firstUpdated(){const e=this.renderRoot.querySelector("slot");if(e){const t=e.assignedElements({flatten:!0});this.hasSlotContent=t.length>0&&t.every(r=>r.tagName==="SCB-SUB-DRAWER")}await this.__ensureDepsLoaded()}updated(e){e.has("leadingIcon")&&this.leadingIcon&&this.__ensureDepsLoaded(),e.has("hasSlotContent")&&this.hasSlotContent&&this.__ensureDepsLoaded(),e.has("expanded")&&this.__applyInert()}__applyInert(){const e=this.__submenuEl;e&&(this.expanded?(e.removeAttribute("inert"),e.setAttribute("aria-hidden","false")):(e.setAttribute("inert",""),e.setAttribute("aria-hidden","true")))}render(){const e=!!this.leadingIcon,t=!!this.itemHref,r=this.hasSlotContent;return c`
|
|
3805
3817
|
<div class="scb-drawer-item">
|
|
3806
3818
|
<div class="scb-drawer-item-label" ?selected=${this.selected}>
|
|
3807
3819
|
${t?c`
|
|
@@ -4232,7 +4244,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4232
4244
|
}
|
|
4233
4245
|
`,fe([l({type:String})],a.ScbFactCard.prototype,"variant",2),fe([l({type:String})],a.ScbFactCard.prototype,"label",2),fe([l({type:String,attribute:"sub-label"})],a.ScbFactCard.prototype,"subLabel",2),fe([l({type:String,attribute:"supporting-text"})],a.ScbFactCard.prototype,"supportingText",2),fe([l({type:String})],a.ScbFactCard.prototype,"icon",2),fe([l({type:Boolean,attribute:"show-close-button"})],a.ScbFactCard.prototype,"showCloseButton",2),fe([l({type:Boolean,reflect:!0})],a.ScbFactCard.prototype,"open",2),fe([l({type:Boolean,reflect:!0,attribute:"full-height"})],a.ScbFactCard.prototype,"fullHeight",2),fe([l({type:Boolean,reflect:!0,attribute:"full-width"})],a.ScbFactCard.prototype,"fullWidth",2),fe([l({type:Boolean,reflect:!0})],a.ScbFactCard.prototype,"stretch",2),a.ScbFactCard=fe([b("scb-fact-card")],a.ScbFactCard);var Ed=Object.defineProperty,Ad=Object.getOwnPropertyDescriptor,rs=(o,e,t,r)=>{for(var i=r>1?void 0:r?Ad(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Ed(e,t,i),i};a.ScbFooterSection=class extends g{constructor(){super(...arguments),this.title=""}render(){return c`<slot></slot>`}},a.ScbFooterSection.styles=f`
|
|
4234
4246
|
:host { display: none; }
|
|
4235
|
-
`,rs([l({type:String,reflect:!0})],a.ScbFooterSection.prototype,"title",2),a.ScbFooterSection=rs([b("scb-footer-section")],a.ScbFooterSection);var Id=Object.defineProperty,Td=Object.getOwnPropertyDescriptor,is=o=>{throw TypeError(o)},ee=(o,e,t,r)=>{for(var i=r>1?void 0:r?Td(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Id(e,t,i),i},zd=(o,e,t)=>e.has(o)||is("Cannot "+t),Od=(o,e,t)=>e.has(o)?is("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),wt=(o,e,t)=>(zd(o,e,"access private method"),t),qe,
|
|
4247
|
+
`,rs([l({type:String,reflect:!0})],a.ScbFooterSection.prototype,"title",2),a.ScbFooterSection=rs([b("scb-footer-section")],a.ScbFooterSection);var Id=Object.defineProperty,Td=Object.getOwnPropertyDescriptor,is=o=>{throw TypeError(o)},ee=(o,e,t,r)=>{for(var i=r>1?void 0:r?Td(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Id(e,t,i),i},zd=(o,e,t)=>e.has(o)||is("Cannot "+t),Od=(o,e,t)=>e.has(o)?is("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),wt=(o,e,t)=>(zd(o,e,"access private method"),t),qe,yo,Qt;a.ScbGrid=class extends g{constructor(){super(...arguments),Od(this,qe),this.colsCompact=4,this.colsMedium=8,this.colsExpanded=12,this.gap="",this.rowGap="",this.columnGap="",this.alignItems="stretch",this.justifyItems="stretch",this.paddingInline="",this.paddingBlock="",this.maxWidth="",this.autoRows=""}firstUpdated(){wt(this,qe,yo).call(this)}updated(){wt(this,qe,yo).call(this)}mapSpacingToken(e){if(!e)return;const t=String(e).trim();return/^\d+$/.test(t)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(t,10)))})`:t}parseGapShorthand(e){if(!e)return{};const t=e.trim().split(/\s+/);if(t.length===1){const r=this.mapSpacingToken(t[0]);return{row:r,col:r}}return{row:this.mapSpacingToken(t[0]),col:this.mapSpacingToken(t[1])}}render(){return c`<div class="grid"><slot></slot></div>`}},qe=new WeakSet,yo=function(){this.style.setProperty("--scb-grid-cols-compact",String(this.colsCompact)),this.style.setProperty("--scb-grid-cols-medium",String(this.colsMedium)),this.style.setProperty("--scb-grid-cols-expanded",String(this.colsExpanded));const o="var(--spacing-7, 24px)",e=this.parseGapShorthand(this.gap),t=this.mapSpacingToken(this.rowGap)??e.row??o,r=this.mapSpacingToken(this.columnGap)??e.col??o;this.style.setProperty("--scb-grid-row-gap",t),this.style.setProperty("--scb-grid-column-gap",r),this.style.setProperty("--scb-grid-gap",`${t} ${r}`),this.style.setProperty("--scb-grid-align-items",this.alignItems),this.style.setProperty("--scb-grid-justify-items",this.justifyItems);const i=this.mapSpacingToken(this.paddingInline),s=this.mapSpacingToken(this.paddingBlock);wt(this,qe,Qt).call(this,"--scb-grid-max-width",this.maxWidth),wt(this,qe,Qt).call(this,"--scb-grid-padding-inline",i??""),wt(this,qe,Qt).call(this,"--scb-grid-padding-block",s??""),wt(this,qe,Qt).call(this,"--scb-grid-auto-rows",this.autoRows)},Qt=function(o,e){e?this.style.setProperty(o,e):this.style.removeProperty(o)},a.ScbGrid.styles=f`
|
|
4236
4248
|
:host {
|
|
4237
4249
|
box-sizing: border-box;
|
|
4238
4250
|
display: block;
|
|
@@ -4329,7 +4341,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4329
4341
|
}
|
|
4330
4342
|
}
|
|
4331
4343
|
}
|
|
4332
|
-
`,ee([l({type:Number,attribute:"cols-compact",reflect:!0})],a.ScbGrid.prototype,"colsCompact",2),ee([l({type:Number,attribute:"cols-medium",reflect:!0})],a.ScbGrid.prototype,"colsMedium",2),ee([l({type:Number,attribute:"cols-expanded",reflect:!0})],a.ScbGrid.prototype,"colsExpanded",2),ee([l({type:String,reflect:!0})],a.ScbGrid.prototype,"gap",2),ee([l({type:String,attribute:"row-gap",reflect:!0})],a.ScbGrid.prototype,"rowGap",2),ee([l({type:String,attribute:"column-gap",reflect:!0})],a.ScbGrid.prototype,"columnGap",2),ee([l({type:String,attribute:"align-items",reflect:!0})],a.ScbGrid.prototype,"alignItems",2),ee([l({type:String,attribute:"justify-items",reflect:!0})],a.ScbGrid.prototype,"justifyItems",2),ee([l({type:String,attribute:"padding-inline",reflect:!0})],a.ScbGrid.prototype,"paddingInline",2),ee([l({type:String,attribute:"padding-block",reflect:!0})],a.ScbGrid.prototype,"paddingBlock",2),ee([l({type:String,attribute:"max-width",reflect:!0})],a.ScbGrid.prototype,"maxWidth",2),ee([l({type:String,attribute:"auto-rows",reflect:!0})],a.ScbGrid.prototype,"autoRows",2),a.ScbGrid=ee([b("scb-grid")],a.ScbGrid);var Pd=Object.defineProperty,Ld=Object.getOwnPropertyDescriptor,os=o=>{throw TypeError(o)},ne=(o,e,t,r)=>{for(var i=r>1?void 0:r?Ld(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Pd(e,t,i),i},
|
|
4344
|
+
`,ee([l({type:Number,attribute:"cols-compact",reflect:!0})],a.ScbGrid.prototype,"colsCompact",2),ee([l({type:Number,attribute:"cols-medium",reflect:!0})],a.ScbGrid.prototype,"colsMedium",2),ee([l({type:Number,attribute:"cols-expanded",reflect:!0})],a.ScbGrid.prototype,"colsExpanded",2),ee([l({type:String,reflect:!0})],a.ScbGrid.prototype,"gap",2),ee([l({type:String,attribute:"row-gap",reflect:!0})],a.ScbGrid.prototype,"rowGap",2),ee([l({type:String,attribute:"column-gap",reflect:!0})],a.ScbGrid.prototype,"columnGap",2),ee([l({type:String,attribute:"align-items",reflect:!0})],a.ScbGrid.prototype,"alignItems",2),ee([l({type:String,attribute:"justify-items",reflect:!0})],a.ScbGrid.prototype,"justifyItems",2),ee([l({type:String,attribute:"padding-inline",reflect:!0})],a.ScbGrid.prototype,"paddingInline",2),ee([l({type:String,attribute:"padding-block",reflect:!0})],a.ScbGrid.prototype,"paddingBlock",2),ee([l({type:String,attribute:"max-width",reflect:!0})],a.ScbGrid.prototype,"maxWidth",2),ee([l({type:String,attribute:"auto-rows",reflect:!0})],a.ScbGrid.prototype,"autoRows",2),a.ScbGrid=ee([b("scb-grid")],a.ScbGrid);var Pd=Object.defineProperty,Ld=Object.getOwnPropertyDescriptor,os=o=>{throw TypeError(o)},ne=(o,e,t,r)=>{for(var i=r>1?void 0:r?Ld(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Pd(e,t,i),i},Dd=(o,e,t)=>e.has(o)||os("Cannot "+t),Rd=(o,e,t)=>e.has(o)?os("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),Se=(o,e,t)=>(Dd(o,e,"access private method"),t),le,xo,Ie;a.ScbGridItem=class extends g{constructor(){super(...arguments),Rd(this,le),this.fit=!1}firstUpdated(){Se(this,le,xo).call(this)}updated(){Se(this,le,xo).call(this)}render(){return c`<slot></slot>`}},le=new WeakSet,xo=function(){Se(this,le,Ie).call(this,"--col-span",this.hasAttribute("col-span")?String(this.colSpan):null),Se(this,le,Ie).call(this,"--col-span-compact",this.hasAttribute("col-span-compact")?String(this.colSpanCompact):null),Se(this,le,Ie).call(this,"--col-span-medium",this.hasAttribute("col-span-medium")?String(this.colSpanMedium):null),Se(this,le,Ie).call(this,"--col-span-expanded",this.hasAttribute("col-span-expanded")?String(this.colSpanExpanded):null),Se(this,le,Ie).call(this,"--row-rule",this.hasAttribute("row-span")?`span ${this.rowSpan}`:null),Se(this,le,Ie).call(this,"--row-rule-compact",this.hasAttribute("row-span-compact")?`span ${this.rowSpanCompact}`:null),Se(this,le,Ie).call(this,"--row-rule-medium",this.hasAttribute("row-span-medium")?`span ${this.rowSpanMedium}`:null),Se(this,le,Ie).call(this,"--row-rule-expanded",this.hasAttribute("row-span-expanded")?`span ${this.rowSpanExpanded}`:null),this.align?(this.style.setProperty("--scb-grid-item-align",this.align),this.style.setProperty("align-self",this.align)):(this.style.removeProperty("--scb-grid-item-align"),this.style.removeProperty("align-self")),this.justify?(this.style.setProperty("--scb-grid-item-justify",this.justify),this.style.setProperty("justify-self",this.justify)):(this.style.removeProperty("--scb-grid-item-justify"),this.style.removeProperty("justify-self"))},Ie=function(o,e){e===null||e===""?this.style.removeProperty(o):this.style.setProperty(o,e)},a.ScbGridItem.styles=f`
|
|
4333
4345
|
:host {
|
|
4334
4346
|
box-sizing: border-box;
|
|
4335
4347
|
display: block;
|
|
@@ -4339,7 +4351,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4339
4351
|
}
|
|
4340
4352
|
:host([fit]) { block-size: 100%; }
|
|
4341
4353
|
:host([fit]) ::slotted(*) { block-size: 100%; }
|
|
4342
|
-
`,ne([l({type:Number,attribute:"col-span",reflect:!0})],a.ScbGridItem.prototype,"colSpan",2),ne([l({type:Number,attribute:"col-span-compact",reflect:!0})],a.ScbGridItem.prototype,"colSpanCompact",2),ne([l({type:Number,attribute:"col-span-medium",reflect:!0})],a.ScbGridItem.prototype,"colSpanMedium",2),ne([l({type:Number,attribute:"col-span-expanded",reflect:!0})],a.ScbGridItem.prototype,"colSpanExpanded",2),ne([l({type:Number,attribute:"row-span",reflect:!0})],a.ScbGridItem.prototype,"rowSpan",2),ne([l({type:Number,attribute:"row-span-compact",reflect:!0})],a.ScbGridItem.prototype,"rowSpanCompact",2),ne([l({type:Number,attribute:"row-span-medium",reflect:!0})],a.ScbGridItem.prototype,"rowSpanMedium",2),ne([l({type:Number,attribute:"row-span-expanded",reflect:!0})],a.ScbGridItem.prototype,"rowSpanExpanded",2),ne([l({type:String,reflect:!0})],a.ScbGridItem.prototype,"align",2),ne([l({type:String,reflect:!0})],a.ScbGridItem.prototype,"justify",2),ne([l({type:Boolean,reflect:!0})],a.ScbGridItem.prototype,"fit",2),a.ScbGridItem=ne([b("scb-grid-item")],a.ScbGridItem);var Bd=Object.defineProperty,Md=Object.getOwnPropertyDescriptor,as=o=>{throw TypeError(o)},ri=(o,e,t,r)=>{for(var i=r>1?void 0:r?Md(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Bd(e,t,i),i},
|
|
4354
|
+
`,ne([l({type:Number,attribute:"col-span",reflect:!0})],a.ScbGridItem.prototype,"colSpan",2),ne([l({type:Number,attribute:"col-span-compact",reflect:!0})],a.ScbGridItem.prototype,"colSpanCompact",2),ne([l({type:Number,attribute:"col-span-medium",reflect:!0})],a.ScbGridItem.prototype,"colSpanMedium",2),ne([l({type:Number,attribute:"col-span-expanded",reflect:!0})],a.ScbGridItem.prototype,"colSpanExpanded",2),ne([l({type:Number,attribute:"row-span",reflect:!0})],a.ScbGridItem.prototype,"rowSpan",2),ne([l({type:Number,attribute:"row-span-compact",reflect:!0})],a.ScbGridItem.prototype,"rowSpanCompact",2),ne([l({type:Number,attribute:"row-span-medium",reflect:!0})],a.ScbGridItem.prototype,"rowSpanMedium",2),ne([l({type:Number,attribute:"row-span-expanded",reflect:!0})],a.ScbGridItem.prototype,"rowSpanExpanded",2),ne([l({type:String,reflect:!0})],a.ScbGridItem.prototype,"align",2),ne([l({type:String,reflect:!0})],a.ScbGridItem.prototype,"justify",2),ne([l({type:Boolean,reflect:!0})],a.ScbGridItem.prototype,"fit",2),a.ScbGridItem=ne([b("scb-grid-item")],a.ScbGridItem);var Bd=Object.defineProperty,Md=Object.getOwnPropertyDescriptor,as=o=>{throw TypeError(o)},ri=(o,e,t,r)=>{for(var i=r>1?void 0:r?Md(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Bd(e,t,i),i},_o=(o,e,t)=>e.has(o)||as("Cannot "+t),Te=(o,e,t)=>(_o(o,e,"read from private field"),t?t.call(o):e.get(o)),St=(o,e,t)=>e.has(o)?as("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),lt=(o,e,t,r)=>(_o(o,e,"write to private field"),e.set(o,t),t),ze=(o,e,t)=>(_o(o,e,"access private method"),t),kt,er,$t,tr,ce,ss,wo,ns,So,ko,ls,cs,$o;a.ScbFooter=class extends g{constructor(){super(...arguments),St(this,ce),this.maxWidth="1440px",this.sections=[],this.description="Statistikmyndigheten SCB förser samhället med statistik för beslutsfattande, debatt och forskning.",St(this,kt,null),St(this,er,""),St(this,$t),St(this,tr,!1),St(this,ko,8)}connectedCallback(){super.connectedCallback(),ze(this,ce,So).call(this,!0),ze(this,ce,ss).call(this)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=Te(this,$t))==null||e.disconnect()}render(){const e=Te(this,ce,ns);return c`
|
|
4343
4355
|
<footer class="outer" role="contentinfo" style=${`--scb-footer-max-width:${this.maxWidth}`}>
|
|
4344
4356
|
<nav aria-label="Sidfot med länkar">
|
|
4345
4357
|
<scb-grid
|
|
@@ -4349,7 +4361,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4349
4361
|
padding-block="0"
|
|
4350
4362
|
.maxWidth=${this.maxWidth}
|
|
4351
4363
|
>
|
|
4352
|
-
${
|
|
4364
|
+
${ze(this,ce,ls).call(this,e)}
|
|
4353
4365
|
</scb-grid>
|
|
4354
4366
|
</nav>
|
|
4355
4367
|
|
|
@@ -4368,25 +4380,25 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4368
4380
|
</div>
|
|
4369
4381
|
</div>
|
|
4370
4382
|
</footer>
|
|
4371
|
-
`}},kt=new WeakMap,er=new WeakMap,$t=new WeakMap,tr=new WeakMap,ce=new WeakSet,ss=function(){var o;(o=
|
|
4383
|
+
`}},kt=new WeakMap,er=new WeakMap,$t=new WeakMap,tr=new WeakMap,ce=new WeakSet,ss=function(){var o;(o=Te(this,$t))==null||o.disconnect(),lt(this,$t,new MutationObserver(e=>{for(const t of e){if(t.type==="childList"){const r=[...t.addedNodes].some(s=>s.tagName==="SCB-FOOTER-SECTION"||s.tagName==="SCB-LINK"),i=[...t.removedNodes].some(s=>s.tagName==="SCB-FOOTER-SECTION"||s.tagName==="SCB-LINK");if(r||i){ze(this,ce,wo).call(this);return}}if(t.type==="attributes"&&(t.target.tagName==="SCB-FOOTER-SECTION"||t.target.tagName==="SCB-LINK")){ze(this,ce,wo).call(this);return}}})),Te(this,$t).observe(this,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["title","href","target"]})},wo=function(){Te(this,tr)||(lt(this,tr,!0),queueMicrotask(()=>{lt(this,tr,!1),ze(this,ce,So).call(this,!1)}))},ns=function(){return Te(this,kt)??this.sections??[]},So=function(o=!1){const e=Array.from(this.querySelectorAll("scb-footer-section"));if(!e.length){Te(this,kt)!==null&&(lt(this,kt,null),lt(this,er,""),o||this.requestUpdate());return}const t=e.map(i=>{const s=(i.getAttribute("title")||"").trim(),n=Array.from(i.querySelectorAll("scb-link")).map(h=>{const u=(h.getAttribute("href")||"").trim(),m=h.getAttribute("target"),v={label:(h.textContent||"").trim(),href:u};return m&&(v.target=m),v});return{title:s,links:n}}),r=JSON.stringify(t);r!==Te(this,er)&&(lt(this,er,r),lt(this,kt,t),o||this.requestUpdate())},ko=new WeakMap,ls=function(o){const e=[],r=o.length;if(r>0&&r<4)return e.push(c`
|
|
4372
4384
|
<scb-grid-item
|
|
4373
4385
|
col-span-compact="4"
|
|
4374
4386
|
col-span-medium="8"
|
|
4375
|
-
col-span-expanded="${
|
|
4387
|
+
col-span-expanded="${Te(this,ko)}"
|
|
4376
4388
|
>
|
|
4377
4389
|
<div class="center-row">
|
|
4378
|
-
${o.map((i,s)=>
|
|
4390
|
+
${o.map((i,s)=>ze(this,ce,$o).call(this,i,s,!0))}
|
|
4379
4391
|
</div>
|
|
4380
4392
|
</scb-grid-item>
|
|
4381
|
-
`),e;for(let i=0;i<r;i++)e.push(
|
|
4393
|
+
`),e;for(let i=0;i<r;i++)e.push(ze(this,ce,cs).call(this,o[i],i));return e},cs=function(o,e){return c`
|
|
4382
4394
|
<scb-grid-item
|
|
4383
4395
|
col-span-compact="4"
|
|
4384
4396
|
col-span-medium="4"
|
|
4385
4397
|
col-span-expanded="2"
|
|
4386
4398
|
>
|
|
4387
|
-
${
|
|
4399
|
+
${ze(this,ce,$o).call(this,o,e,!1)}
|
|
4388
4400
|
</scb-grid-item>
|
|
4389
|
-
`}
|
|
4401
|
+
`},$o=function(o,e,t){return c`
|
|
4390
4402
|
<section class="group ${t?"group--centered":""}" aria-labelledby=${`scb-footer-sec-${e}`}>
|
|
4391
4403
|
<h3 id=${`scb-footer-sec-${e}`} class="title">${o.title}</h3>
|
|
4392
4404
|
<ul>
|
|
@@ -4543,7 +4555,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4543
4555
|
|
|
4544
4556
|
.spacer { display: none; }
|
|
4545
4557
|
@media (min-width: 840px) { .spacer { display: block; } }
|
|
4546
|
-
`,ri([l({type:String,attribute:"max-width",reflect:!0,converter:{fromAttribute:o=>{if(o==null)return"1440px";const e=o.trim();return e===""?"1440px":/^\d+$/.test(e)?`${e}px`:e}}})],a.ScbFooter.prototype,"maxWidth",2),ri([l({type:Array})],a.ScbFooter.prototype,"sections",2),ri([l({type:String})],a.ScbFooter.prototype,"description",2),a.ScbFooter=ri([b("scb-footer")],a.ScbFooter);var Fd=Object.defineProperty,Hd=Object.getOwnPropertyDescriptor,ds=o=>{throw TypeError(o)},
|
|
4558
|
+
`,ri([l({type:String,attribute:"max-width",reflect:!0,converter:{fromAttribute:o=>{if(o==null)return"1440px";const e=o.trim();return e===""?"1440px":/^\d+$/.test(e)?`${e}px`:e}}})],a.ScbFooter.prototype,"maxWidth",2),ri([l({type:Array})],a.ScbFooter.prototype,"sections",2),ri([l({type:String})],a.ScbFooter.prototype,"description",2),a.ScbFooter=ri([b("scb-footer")],a.ScbFooter);var Fd=Object.defineProperty,Hd=Object.getOwnPropertyDescriptor,ds=o=>{throw TypeError(o)},Oe=(o,e,t,r)=>{for(var i=r>1?void 0:r?Hd(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Fd(e,t,i),i},Nd=(o,e,t)=>e.has(o)||ds("Cannot "+t),qd=(o,e,t)=>e.has(o)?ds("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(o):e.set(o,t),hs=(o,e,t)=>(Nd(o,e,"access private method"),t),ii,Co;a.ScbStack=class extends g{constructor(){super(...arguments),qd(this,ii),this.direction="column",this.gap="",this.rowGap="",this.columnGap="",this.align="stretch",this.justify="start",this.wrap=!1,this.inline=!1}firstUpdated(){hs(this,ii,Co).call(this)}updated(){hs(this,ii,Co).call(this)}mapSpacingToken(e){if(!e)return;const t=String(e).trim();return/^\d+$/.test(t)?`var(--spacing-${Math.max(0,Math.min(14,parseInt(t,10)))})`:t}parseGapShorthand(e){if(!e)return{};const t=e.trim().split(/\s+/);if(t.length===1){const r=this.mapSpacingToken(t[0]);return{row:r,col:r}}return{row:this.mapSpacingToken(t[0]),col:this.mapSpacingToken(t[1])}}render(){return c`<slot></slot>`}},ii=new WeakSet,Co=function(){this.style.setProperty("--scb-stack-direction",this.direction);const o="var(--spacing-5, 16px)",e=this.parseGapShorthand(this.gap),t=this.mapSpacingToken(this.rowGap)??e.row??o,r=this.mapSpacingToken(this.columnGap)??e.col??o;this.style.setProperty("--scb-stack-gap",`${t}`),this.style.setProperty("--scb-stack-row-gap",t),this.style.setProperty("--scb-stack-column-gap",r);const i={start:"flex-start",center:"center",end:"flex-end",stretch:"stretch",baseline:"baseline"},s={start:"flex-start",center:"center",end:"flex-end",between:"space-between",around:"space-around",evenly:"space-evenly"};this.style.setProperty("--scb-stack-align",i[this.align]??"stretch"),this.style.setProperty("--scb-stack-justify",s[this.justify]??"flex-start"),this.style.setProperty("--scb-stack-wrap",this.wrap?"wrap":"nowrap")},a.ScbStack.styles=f`
|
|
4547
4559
|
:host {
|
|
4548
4560
|
box-sizing: border-box;
|
|
4549
4561
|
display: var(--scb-stack-display, flex);
|
|
@@ -4562,17 +4574,17 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4562
4574
|
min-inline-size: 0;
|
|
4563
4575
|
}
|
|
4564
4576
|
:host([inline]) { --scb-stack-display: inline-flex; }
|
|
4565
|
-
`,
|
|
4577
|
+
`,Oe([l({type:String,reflect:!0})],a.ScbStack.prototype,"direction",2),Oe([l({type:String,reflect:!0})],a.ScbStack.prototype,"gap",2),Oe([l({type:String,attribute:"row-gap",reflect:!0})],a.ScbStack.prototype,"rowGap",2),Oe([l({type:String,attribute:"column-gap",reflect:!0})],a.ScbStack.prototype,"columnGap",2),Oe([l({type:String,reflect:!0})],a.ScbStack.prototype,"align",2),Oe([l({type:String,reflect:!0})],a.ScbStack.prototype,"justify",2),Oe([l({type:Boolean,reflect:!0})],a.ScbStack.prototype,"wrap",2),Oe([l({type:Boolean,reflect:!0})],a.ScbStack.prototype,"inline",2),a.ScbStack=Oe([b("scb-stack")],a.ScbStack);var Vd=Object.defineProperty,Ud=Object.getOwnPropertyDescriptor,Eo=(o,e,t,r)=>{for(var i=r>1?void 0:r?Ud(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Vd(e,t,i),i};a.ScbHeaderDrawerGroup=class extends g{constructor(){super(...arguments),this.label=""}render(){return c`<slot></slot>`}},a.ScbHeaderDrawerGroup.styles=f`:host{display:none !important}`,Eo([l({type:String})],a.ScbHeaderDrawerGroup.prototype,"label",2),Eo([l({type:String})],a.ScbHeaderDrawerGroup.prototype,"icon",2),a.ScbHeaderDrawerGroup=Eo([b("scb-header-drawer-group")],a.ScbHeaderDrawerGroup);var jd=Object.defineProperty,Wd=Object.getOwnPropertyDescriptor,oi=(o,e,t,r)=>{for(var i=r>1?void 0:r?Wd(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&jd(e,t,i),i};a.ScbHeaderDrawerItem=class extends g{constructor(){super(...arguments),this.label="",this.href="#"}render(){return c`<slot></slot>`}},a.ScbHeaderDrawerItem.styles=f`:host{display:none !important}`,oi([l({type:String})],a.ScbHeaderDrawerItem.prototype,"label",2),oi([l({type:String})],a.ScbHeaderDrawerItem.prototype,"href",2),oi([l({type:String})],a.ScbHeaderDrawerItem.prototype,"icon",2),a.ScbHeaderDrawerItem=oi([b("scb-header-drawer-item")],a.ScbHeaderDrawerItem);var Gd=Object.defineProperty,Kd=Object.getOwnPropertyDescriptor,Ao=(o,e,t,r)=>{for(var i=r>1?void 0:r?Kd(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Gd(e,t,i),i};a.ScbHeaderTab=class extends g{constructor(){super(...arguments),this.label="",this.href="#"}render(){return c`<slot></slot>`}},a.ScbHeaderTab.styles=f`:host{display:none !important}`,Ao([l({type:String})],a.ScbHeaderTab.prototype,"label",2),Ao([l({type:String})],a.ScbHeaderTab.prototype,"href",2),a.ScbHeaderTab=Ao([b("scb-header-tab")],a.ScbHeaderTab);var Yd=Object.defineProperty,Xd=Object.getOwnPropertyDescriptor,ai=(o,e,t,r)=>{for(var i=r>1?void 0:r?Xd(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Yd(e,t,i),i};a.ScbHeaderUtility=class extends g{constructor(){super(...arguments),this.label="",this.href="#"}render(){return c`<slot></slot>`}},a.ScbHeaderUtility.styles=f`:host{display:none !important}`,ai([l({type:String})],a.ScbHeaderUtility.prototype,"label",2),ai([l({type:String})],a.ScbHeaderUtility.prototype,"href",2),ai([l({type:String})],a.ScbHeaderUtility.prototype,"target",2),a.ScbHeaderUtility=ai([b("scb-header-utility")],a.ScbHeaderUtility);var Zd=Object.defineProperty,Jd=Object.getOwnPropertyDescriptor,si=(o,e,t,r)=>{for(var i=r>1?void 0:r?Jd(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Zd(e,t,i),i};a.ScbPrimaryTab=class extends jt{constructor(){super(...arguments),this.iconOnly=!1,this.inlineIcon=!1,this._onActivate=()=>{var t;const e=((t=this.textContent)==null?void 0:t.trim())??"";this.dispatchEvent(new CustomEvent("activate",{detail:{label:e},bubbles:!0,composed:!0}))}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","tab")}get icon(){return this._icon}set icon(e){const t=this._icon;t!==e&&(this._icon=e,this.requestUpdate("icon",t),this.updateIconSlot())}firstUpdated(e){super.firstUpdated(e),this.addEventListener("click",this._onActivate),this._icon&&this.updateIconSlot()}updated(){var e;if(super.updated(),this.setAttribute("aria-selected",this.active?"true":"false"),this.iconOnly&&!this.hasAttribute("aria-label")){const t=((e=this.textContent)==null?void 0:e.trim())??"";t&&this.setAttribute("aria-label",t)}}async ensureMdIconLoaded(){const e=globalThis;e.__mdIconLoaded||(await Promise.resolve().then(()=>X),e.__mdIconLoaded=!0)}async updateIconSlot(){const e=this.querySelector('md-icon[slot="icon"]');if(!this._icon){e==null||e.remove();return}if(await this.ensureMdIconLoaded(),e)e.textContent=this._icon;else{const t=document.createElement("md-icon");t.setAttribute("slot","icon"),t.textContent=this._icon,this.appendChild(t)}}},a.ScbPrimaryTab.styles=[...jt.styles,f`
|
|
4566
4578
|
/* Icon-only: dölj textslot */
|
|
4567
4579
|
:host([icon-only]) slot:not([name='icon']) {
|
|
4568
4580
|
display: none;
|
|
4569
4581
|
}
|
|
4570
|
-
`],si([l({type:String})],a.ScbPrimaryTab.prototype,"icon",1),si([l({type:Boolean,reflect:!0,attribute:"icon-only"})],a.ScbPrimaryTab.prototype,"iconOnly",2),si([l({type:Boolean,reflect:!0,attribute:"inline-icon"})],a.ScbPrimaryTab.prototype,"inlineIcon",2),a.ScbPrimaryTab=si([b("scb-primary-tab")],a.ScbPrimaryTab);var Qd=Object.defineProperty,eh=Object.getOwnPropertyDescriptor,
|
|
4582
|
+
`],si([l({type:String})],a.ScbPrimaryTab.prototype,"icon",1),si([l({type:Boolean,reflect:!0,attribute:"icon-only"})],a.ScbPrimaryTab.prototype,"iconOnly",2),si([l({type:Boolean,reflect:!0,attribute:"inline-icon"})],a.ScbPrimaryTab.prototype,"inlineIcon",2),a.ScbPrimaryTab=si([b("scb-primary-tab")],a.ScbPrimaryTab);var Qd=Object.defineProperty,eh=Object.getOwnPropertyDescriptor,Io=(o,e,t,r)=>{for(var i=r>1?void 0:r?eh(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Qd(e,t,i),i};a.ScbSecondaryTab=class extends Wt{constructor(){super(...arguments),this.iconOnly=!1,this._onActivate=()=>{var t;const e=((t=this.textContent)==null?void 0:t.trim())??"";this.dispatchEvent(new CustomEvent("activate",{detail:{label:e},bubbles:!0,composed:!0}))}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","tab")}get icon(){return this._icon}set icon(e){const t=this._icon;t!==e&&(this._icon=e,this.requestUpdate("icon",t),this.updateIconSlot())}firstUpdated(e){var t;if(super.firstUpdated(e),this.iconOnly&&!this.hasAttribute("aria-label")){const r=((t=this.textContent)==null?void 0:t.trim())??"";r&&this.setAttribute("aria-label",r)}this.addEventListener("click",this._onActivate),this._icon&&this.updateIconSlot()}updated(){var e;if(super.updated(),this.iconOnly&&!this.hasAttribute("aria-label")){const t=((e=this.textContent)==null?void 0:e.trim())??"";t&&this.setAttribute("aria-label",t)}}async ensureMdIconLoaded(){const e=globalThis;e.__mdIconLoaded||(await Promise.resolve().then(()=>X),e.__mdIconLoaded=!0)}async updateIconSlot(){const e=this.querySelector('md-icon[slot="icon"]');if(!this._icon){e==null||e.remove();return}if(await this.ensureMdIconLoaded(),e)e.textContent=this._icon;else{const t=document.createElement("md-icon");t.setAttribute("slot","icon"),t.textContent=this._icon,this.appendChild(t)}}},a.ScbSecondaryTab.styles=[...Wt.styles,f`
|
|
4571
4583
|
/* Icon-only: göm all text utom slot="icon" */
|
|
4572
4584
|
:host([icon-only]) slot:not([name='icon']) {
|
|
4573
4585
|
display: none;
|
|
4574
4586
|
}
|
|
4575
|
-
`],
|
|
4587
|
+
`],Io([l({type:String})],a.ScbSecondaryTab.prototype,"icon",1),Io([l({type:Boolean,reflect:!0,attribute:"icon-only"})],a.ScbSecondaryTab.prototype,"iconOnly",2),a.ScbSecondaryTab=Io([b("scb-secondary-tab")],a.ScbSecondaryTab);var th=Object.defineProperty,rh=Object.getOwnPropertyDescriptor,ps=(o,e,t,r)=>{for(var i=r>1?void 0:r?rh(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&th(e,t,i),i};a.ScbTabs=class extends Gt{constructor(){super(...arguments),this.ariaLabel="",this._isDispatching=!1,this._onChange=e=>{if(!e.composed&&!this._isDispatching){e.stopPropagation(),this._isDispatching=!0;const t=e.target.activeTabIndex;this.dispatchEvent(new CustomEvent("change",{detail:{activeTabIndex:t},bubbles:!0,composed:!0})),this._isDispatching=!1}}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","tablist")}firstUpdated(e){super.firstUpdated(e),this.addEventListener("change",this._onChange)}},a.ScbTabs.styles=[...Gt.styles,f`
|
|
4576
4588
|
:host {
|
|
4577
4589
|
/*Containerfärg */
|
|
4578
4590
|
--md-primary-tab-container-color: var(--md-sys-color-surface);
|
|
@@ -4594,7 +4606,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4594
4606
|
--md-secondary-tab-hover-state-layer-color: var(--md-sys-color-on-surface);
|
|
4595
4607
|
}
|
|
4596
4608
|
|
|
4597
|
-
`],ps([l({type:String,reflect:!0,attribute:"aria-label"})],a.ScbTabs.prototype,"ariaLabel",2),a.ScbTabs=ps([b("scb-tabs")],a.ScbTabs);var ih=Object.defineProperty,oh=Object.getOwnPropertyDescriptor,T=(o,e,t,r)=>{for(var i=r>1?void 0:r?oh(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&ih(e,t,i),i};const
|
|
4609
|
+
`],ps([l({type:String,reflect:!0,attribute:"aria-label"})],a.ScbTabs.prototype,"ariaLabel",2),a.ScbTabs=ps([b("scb-tabs")],a.ScbTabs);var ih=Object.defineProperty,oh=Object.getOwnPropertyDescriptor,T=(o,e,t,r)=>{for(var i=r>1?void 0:r?oh(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&ih(e,t,i),i};const To={fromAttribute:o=>o==null?!0:!/^(false|0|off|no)$/i.test(o),toAttribute:o=>String(!!o)};a.ScbHeader=class extends g{constructor(){super(...arguments),this.maxWidth="1440px",this.logoText="Statistikmyndigheten",this.logoHref="/",this.banner=!1,this.tabs=[],this.activeTab=0,this.utilityItems=[],this.showDrawer=!0,this.showSearch=!0,this.includeUtilityInDrawer=!1,this._drawerId="main-drawer",this._drawerMounted=!1,this._drawerExpanded=!1,this._searchId="header-search",this._slotTabs=[],this._slotUtils=[],this._slotMenu=[],this._measureScheduled=!1,this._scheduleMeasure=()=>{this._measureScheduled||(this._measureScheduled=!0,requestAnimationFrame(()=>{this._measureScheduled=!1,this._measure()}))},this._onWindowResize=()=>{this._scheduleMeasure()},this._onDrawerSelect=e=>{this.dispatchEvent(new CustomEvent("drawer-select",{detail:e.detail,bubbles:!0,composed:!0})),this._closeDrawerNow()},this._collapsed=!1,this._unlockAtWidth=0,this._hideLogoText=!1,this._logoTextUnlockAt=0,this._harvestPending=!1,this._harvest=()=>{const e=this._slotEl;if(!e)return;const t=e.assignedElements({flatten:!0}),r=[],i=[],s=[],n=h=>({label:h.getAttribute("label")??"",href:h.getAttribute("href")??void 0,icon:h.getAttribute("icon")??void 0});for(const h of t){const u=h.tagName.toLowerCase();if(u==="scb-header-tab"){r.push({label:h.getAttribute("label")??"",href:h.getAttribute("href")??"#"});continue}if(u==="scb-header-utility"){i.push({label:h.getAttribute("label")??"",href:h.getAttribute("href")??"#",target:h.getAttribute("target")??void 0});continue}if(u==="scb-header-drawer-group"){const m={label:h.getAttribute("label")??"",icon:h.getAttribute("icon")??void 0,children:[]};h.querySelectorAll("scb-header-drawer-item").forEach(v=>m.children.push(n(v))),s.push(m);continue}u==="scb-header-drawer-item"&&s.push(n(h))}this._slotTabs=r,this._slotUtils=i,this._slotMenu=s,queueMicrotask(()=>{this.updateComplete.then(()=>{this._applyActiveToTabs(),this._scheduleMeasure()})})},this._measure=()=>{var v,x,_;const e=this._top,t=this._logoGroup;if(!e||!t)return;const r=window.innerWidth,i=e.clientWidth,s=this._overflows(this._util),n=this._overflows(this._tabsEl),h=r<this.BP_MD||s||n;this._collapsed?!h&&i>=this._unlockAtWidth&&this._setCollapsed(!1):h&&(this._unlockAtWidth=i+this._HYST,this._setCollapsed(!0));let u=!1;if(this.showSearch&&r>=this.BP_SM&&r<this.BP_MD&&this._searchWrap){const S=getComputedStyle(this._searchWrap),C=Math.max(this._num(S.minWidth,this._tokenPx("--scb-header-search-min",320)),this._tokenPx("--scb-header-search-min",320)),A=this._num(getComputedStyle(e).gap,this._tokenPx("--spacing-7",24)),I=this.showDrawer&&(r<this.BP_MD||this._collapsed)?((v=this._menuBtn)==null?void 0:v.getBoundingClientRect().width)||this._tokenPx("--icon-size-large",48):0;u=t.getBoundingClientRect().width+A+C+A+I+8>i+.5}this._setHideSearch(u);let m=!1;if(this.showDrawer&&(r<this.BP_MD||this._collapsed)&&!this._visible(this._util)&&!this._visible(this._searchWrap)){const S=this._num(getComputedStyle(e).gap,this._tokenPx("--spacing-7",24)),C=((x=this._menuBtn)==null?void 0:x.getBoundingClientRect().width)||this._tokenPx("--icon-size-large",48),A=(((_=this._logoGroup)==null?void 0:_.getBoundingClientRect().width)||0)+S+C;this._hideLogoText?m=!(i>=this._logoTextUnlockAt):A>i+.5&&(m=!0,this._logoTextUnlockAt=i+this._HYST)}else m=!1,this._logoTextUnlockAt=0;this._setHideLogoText(m)},this._onMenuClick=async e=>{e.preventDefault(),e.stopPropagation(),this.showDrawer&&(this.dispatchEvent(new CustomEvent("menu-click",{bubbles:!0,composed:!0})),await this._ensureDrawerMounted(),await a.ScbHeader._nextFrame(),await a.ScbHeader._nextFrame(),this._openDrawerNow())},this._onSearchClick=e=>{var i;const t=this._searchEl;if(t!=null&&t.submit&&typeof t.submit=="function"){t.submit();return}const r=(t==null?void 0:t.value)??void 0;this.dispatchEvent(new CustomEvent("search-click",{detail:{value:r},bubbles:!0,composed:!0})),(i=t==null?void 0:t.focus)==null||i.call(t)},this._onTabsChange=e=>{var n,h,u;const t=e,r=((n=t==null?void 0:t.detail)==null?void 0:n.activeTabIndex)??((h=e.target)==null?void 0:h.activeTabIndex)??0;this.activeTab=r;const s=((u=(this._slotTabs.length?this._slotTabs:this.tabs)[r])==null?void 0:u.href)??"";this.dispatchEvent(new CustomEvent("tab-change",{detail:{index:r,href:s},bubbles:!0,composed:!0}))}}get _HYST(){return this._tokenPx("--spacing-11",64)}get BP_SM(){return this._tokenPx("--bp-sm",a.ScbHeader.BP_SM_DEFAULT)}get BP_MD(){return this._tokenPx("--bp-md",a.ScbHeader.BP_MD_DEFAULT)}_scheduleHarvest(){this._harvestPending||(this._harvestPending=!0,queueMicrotask(()=>{this._harvestPending=!1,this._harvest()}))}get _slotEl(){var e;return((e=this.shadowRoot)==null?void 0:e.querySelector("slot#data-slot"))??null}get _top(){return this.renderRoot.querySelector(".top-row")}get _util(){return this.renderRoot.querySelector(".utility")}get _tabsEl(){return this.renderRoot.querySelector("scb-tabs")}get _logoGroup(){return this.renderRoot.querySelector(".logo-wrap")||this.renderRoot.querySelector(".logo-group")}get _searchWrap(){return this.renderRoot.querySelector(".search")}get _menuBtn(){return this.renderRoot.querySelector(".menu-trigger")}get _searchEl(){return this.renderRoot.querySelector(`#${this._searchId}`)}_attachSlotObservers(){var t;(t=this._slotMo)==null||t.disconnect();const e=new MutationObserver(r=>{this._scheduleHarvest()});this._slotMo=e,e.observe(this,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["label","href","icon","target"]})}_setCollapsed(e){this._collapsed!==e&&(this._collapsed=e,e?this.setAttribute("data-collapsed",""):this.removeAttribute("data-collapsed"))}_setHideSearch(e){e?this.setAttribute("data-hide-search",""):this.removeAttribute("data-hide-search")}_setHideLogoText(e){this._hideLogoText!==e&&(this._hideLogoText=e,e?this.setAttribute("data-hide-logo-text",""):this.removeAttribute("data-hide-logo-text"))}_num(e,t){const r=Number.parseFloat(String(e??"").trim());return Number.isFinite(r)?r:t}_tokenPx(e,t){const r=getComputedStyle(this);return this._num(r.getPropertyValue(e),t)}_visible(e){return e?getComputedStyle(e).display!=="none":!1}_overflows(e){return!e||!this._visible(e)?!1:e.scrollWidth>e.clientWidth+1}firstUpdated(){this.updateComplete.then(()=>{this._harvest(),this._attachSlotObservers()});const e=this._top;e&&(this._ro=new ResizeObserver(()=>this._scheduleMeasure()),this._ro.observe(e)),window.addEventListener("resize",this._onWindowResize,{passive:!0});const t=this._menuBtn,r=()=>this._ensureDrawerMounted();t==null||t.addEventListener("pointerenter",r,{once:!0}),t==null||t.addEventListener("focusin",r,{once:!0}),t==null||t.addEventListener("touchstart",r,{once:!0,passive:!0})}updated(e){e.has("searchMax")&&this.style.setProperty("--scb-header-search-max",this.searchMax??"480px"),e.has("searchMin")&&this.style.setProperty("--scb-header-search-min",this.searchMin??"320px"),e.has("searchHeight")&&(this.searchHeight&&this.searchHeight.trim()?this.style.setProperty("--scb-search-height",this.searchHeight.trim()):this.style.removeProperty("--scb-search-height")),(e.has("utilityItems")||e.has("tabs")||e.has("logoText")||e.has("activeTab")||e.has("_slotTabs")||e.has("_slotUtils")||e.has("_slotMenu")||e.has("showDrawer")||e.has("showSearch")||e.has("searchMax")||e.has("searchMin"))&&this.updateComplete.then(()=>{this._scheduleMeasure(),this._applyActiveToTabs()})}disconnectedCallback(){var e,t;(e=this._ro)==null||e.disconnect(),(t=this._slotMo)==null||t.disconnect(),window.removeEventListener("resize",this._onWindowResize),super.disconnectedCallback()}async _ensureDrawerMounted(){this._drawerMounted||(this._drawerMounted=!0,await this.updateComplete)}_openDrawerNow(){var t,r;const e=this.renderRoot.querySelector(`#${this._drawerId}`);e&&(e.open=!0,e.setAttribute("open",""),(t=e.show)==null||t.call(e),(r=e.openDrawer)==null||r.call(e),this._drawerExpanded=!0,this._syncMenuBtnAria(),this.dispatchEvent(new CustomEvent("drawer-open",{bubbles:!0,composed:!0})))}_closeDrawerNow(){const e=this.renderRoot.querySelector(`#${this._drawerId}`);e&&(e.open=!1),this._drawerExpanded=!1,this._syncMenuBtnAria(),this.dispatchEvent(new CustomEvent("drawer-close",{bubbles:!0,composed:!0}))}_syncMenuBtnAria(){const e=this.renderRoot.querySelector(".menu-trigger");e&&e.setAttribute("aria-expanded",String(this._drawerExpanded))}_applyActiveToTabs(){const e=this._tabsEl;if(!e)return;e.activeTabIndex=this.activeTab,e.querySelectorAll("scb-secondary-tab").forEach((r,i)=>{r.selected=i===this.activeTab})}_renderDrawerNodes(e){return!e||e.length===0?c``:c`${e.map(t=>{const r=Array.isArray(t.children)&&t.children.length>0;return c`
|
|
4598
4610
|
<scb-drawer-item
|
|
4599
4611
|
label=${t.label}
|
|
4600
4612
|
?selected=${!1}
|
|
@@ -4769,12 +4781,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4769
4781
|
line-height: var(--md-sys-typescale-body-medium-line-height);
|
|
4770
4782
|
font-weight: var(--md-sys-typescale-body-medium-weight);
|
|
4771
4783
|
letter-spacing: var(--md-sys-typescale-body-medium-tracking);
|
|
4772
|
-
|
|
4773
4784
|
--scb-link-color: var(--md-sys-color-primary);
|
|
4774
|
-
--scb-link-decoration: underline;
|
|
4775
|
-
--scb-link-underline-offset: 3px;
|
|
4776
|
-
--scb-link-underline-thickness: 1px;
|
|
4777
|
-
--scb-link-hover-thickness: 2px;
|
|
4778
4785
|
--scb-link-white-space: nowrap;
|
|
4779
4786
|
}
|
|
4780
4787
|
@media (min-width:840px){ .utility{ display:flex; } }
|
|
@@ -4861,7 +4868,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
4861
4868
|
:host([data-hide-logo-text]) .logo-text {
|
|
4862
4869
|
display: none;
|
|
4863
4870
|
}
|
|
4864
|
-
`,a.ScbHeader._nextFrame=()=>new Promise(o=>requestAnimationFrame(()=>o())),T([l({type:String,attribute:"max-width"})],a.ScbHeader.prototype,"maxWidth",2),T([l({type:String,attribute:"logo-text"})],a.ScbHeader.prototype,"logoText",2),T([l({type:String,attribute:"logo-href"})],a.ScbHeader.prototype,"logoHref",2),T([l({type:Boolean,reflect:!0})],a.ScbHeader.prototype,"banner",2),T([l({type:String,attribute:"banner-label"})],a.ScbHeader.prototype,"bannerLabel",2),T([l({attribute:"tabs",converter:a.ScbHeader._JSON_ARRAY})],a.ScbHeader.prototype,"tabs",2),T([l({type:Number,attribute:"active-tab"})],a.ScbHeader.prototype,"activeTab",2),T([l({attribute:"utility-items",converter:a.ScbHeader._JSON_ARRAY})],a.ScbHeader.prototype,"utilityItems",2),T([l({type:String,attribute:"search-placeholder"})],a.ScbHeader.prototype,"searchPlaceholder",2),T([l({type:String,attribute:"drawer-label"})],a.ScbHeader.prototype,"drawerLabel",2),T([l({type:String,attribute:"drawer-sub-label"})],a.ScbHeader.prototype,"drawerSubLabel",2),T([l({type:String,attribute:"drawer-section-label"})],a.ScbHeader.prototype,"drawerSectionLabel",2),T([l({type:String,attribute:"drawer-search-placeholder"})],a.ScbHeader.prototype,"drawerSearchPlaceholder",2),T([l({attribute:"menu-data",converter:a.ScbHeader._JSON_ARRAY})],a.ScbHeader.prototype,"menuData",2),T([l({attribute:"show-drawer",reflect:!0,converter:
|
|
4871
|
+
`,a.ScbHeader._nextFrame=()=>new Promise(o=>requestAnimationFrame(()=>o())),T([l({type:String,attribute:"max-width"})],a.ScbHeader.prototype,"maxWidth",2),T([l({type:String,attribute:"logo-text"})],a.ScbHeader.prototype,"logoText",2),T([l({type:String,attribute:"logo-href"})],a.ScbHeader.prototype,"logoHref",2),T([l({type:Boolean,reflect:!0})],a.ScbHeader.prototype,"banner",2),T([l({type:String,attribute:"banner-label"})],a.ScbHeader.prototype,"bannerLabel",2),T([l({attribute:"tabs",converter:a.ScbHeader._JSON_ARRAY})],a.ScbHeader.prototype,"tabs",2),T([l({type:Number,attribute:"active-tab"})],a.ScbHeader.prototype,"activeTab",2),T([l({attribute:"utility-items",converter:a.ScbHeader._JSON_ARRAY})],a.ScbHeader.prototype,"utilityItems",2),T([l({type:String,attribute:"search-placeholder"})],a.ScbHeader.prototype,"searchPlaceholder",2),T([l({type:String,attribute:"drawer-label"})],a.ScbHeader.prototype,"drawerLabel",2),T([l({type:String,attribute:"drawer-sub-label"})],a.ScbHeader.prototype,"drawerSubLabel",2),T([l({type:String,attribute:"drawer-section-label"})],a.ScbHeader.prototype,"drawerSectionLabel",2),T([l({type:String,attribute:"drawer-search-placeholder"})],a.ScbHeader.prototype,"drawerSearchPlaceholder",2),T([l({attribute:"menu-data",converter:a.ScbHeader._JSON_ARRAY})],a.ScbHeader.prototype,"menuData",2),T([l({attribute:"show-drawer",reflect:!0,converter:To})],a.ScbHeader.prototype,"showDrawer",2),T([l({attribute:"show-search",reflect:!0,converter:To})],a.ScbHeader.prototype,"showSearch",2),T([l({attribute:"include-utility-in-drawer",reflect:!0,converter:To})],a.ScbHeader.prototype,"includeUtilityInDrawer",2),T([l({type:String,attribute:"search-max"})],a.ScbHeader.prototype,"searchMax",2),T([l({type:String,attribute:"search-min"})],a.ScbHeader.prototype,"searchMin",2),T([l({type:String,attribute:"search-height"})],a.ScbHeader.prototype,"searchHeight",2),T([w()],a.ScbHeader.prototype,"_drawerId",2),T([w()],a.ScbHeader.prototype,"_drawerMounted",2),T([w()],a.ScbHeader.prototype,"_drawerExpanded",2),T([w()],a.ScbHeader.prototype,"_searchId",2),T([w()],a.ScbHeader.prototype,"_slotTabs",2),T([w()],a.ScbHeader.prototype,"_slotUtils",2),T([w()],a.ScbHeader.prototype,"_slotMenu",2),T([w()],a.ScbHeader.prototype,"_collapsed",2),T([w()],a.ScbHeader.prototype,"_hideLogoText",2),a.ScbHeader=T([b("scb-header")],a.ScbHeader);var ah=Object.defineProperty,sh=Object.getOwnPropertyDescriptor,me=(o,e,t,r)=>{for(var i=r>1?void 0:r?sh(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&ah(e,t,i),i};a.ScbKeyFigureCard=class extends g{constructor(){super(...arguments),this.keyfigure=0,this.subLabel="",this.supportingText="",this.cardHref="",this.icon="",this.size="standard",this.unit="",this.fullHeight=!1,this.fullWidth=!1,this.stretch=!1}formatNumber(e){if(typeof e=="number")return e.toLocaleString("sv-SE").replace(/\u00A0/g," ");const t=Number(e);return Number.isNaN(t)?String(e):t.toLocaleString("sv-SE").replace(/\u00A0/g," ")}render(){const e=!!this.cardHref,t=this.formatNumber(this.keyfigure);return c`
|
|
4865
4872
|
<div
|
|
4866
4873
|
class="scb-keyfigure-card ${e?"clickable":""} ${this.size}"
|
|
4867
4874
|
role=${e?"link":"group"}
|
|
@@ -5708,7 +5715,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
5708
5715
|
/* Ärver färg från container */
|
|
5709
5716
|
color: var(--scb-switch-label-color, inherit);
|
|
5710
5717
|
}
|
|
5711
|
-
`,dt([l({type:String})],a.ScbSwitch.prototype,"label",2),dt([l({type:String,reflect:!0,attribute:"aria-label"})],a.ScbSwitch.prototype,"ariaLabel",2),dt([l({type:Boolean,reflect:!0})],a.ScbSwitch.prototype,"icons",2),dt([l({type:Boolean,reflect:!0})],a.ScbSwitch.prototype,"selected",2),dt([l({type:Boolean,reflect:!0})],a.ScbSwitch.prototype,"disabled",2),dt([l({type:Boolean,reflect:!0,attribute:"full-width"})],a.ScbSwitch.prototype,"fullWidth",2),a.ScbSwitch=dt([b("scb-switch")],a.ScbSwitch);const ys=Object.freeze(Object.defineProperty({__proto__:null,get ScbSwitch(){return a.ScbSwitch}},Symbol.toStringTag,{value:"Module"}));var Lh=Object.defineProperty,
|
|
5718
|
+
`,dt([l({type:String})],a.ScbSwitch.prototype,"label",2),dt([l({type:String,reflect:!0,attribute:"aria-label"})],a.ScbSwitch.prototype,"ariaLabel",2),dt([l({type:Boolean,reflect:!0})],a.ScbSwitch.prototype,"icons",2),dt([l({type:Boolean,reflect:!0})],a.ScbSwitch.prototype,"selected",2),dt([l({type:Boolean,reflect:!0})],a.ScbSwitch.prototype,"disabled",2),dt([l({type:Boolean,reflect:!0,attribute:"full-width"})],a.ScbSwitch.prototype,"fullWidth",2),a.ScbSwitch=dt([b("scb-switch")],a.ScbSwitch);const ys=Object.freeze(Object.defineProperty({__proto__:null,get ScbSwitch(){return a.ScbSwitch}},Symbol.toStringTag,{value:"Module"}));var Lh=Object.defineProperty,Dh=Object.getOwnPropertyDescriptor,re=(o,e,t,r)=>{for(var i=r>1?void 0:r?Dh(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Lh(e,t,i),i};a.ScbTextField2=class extends g{constructor(){super(...arguments),this.type="text",this.label="",this.supportingText="",this.errorText="",this.leadingIcon="",this.name="",this.pattern="",this.value="",this.underLabel="",this.error=!1,this.disabled=!1,this.required=!1,this._form=null,this._formSubmitHandler=null,this._formResetHandler=null,this._initialValue="",this._inputId=""}render(){const e=this.leadingIcon?c`<md-icon class="scb-textfield-icon">${this.leadingIcon}</md-icon>`:null,t=this.error?c`<md-icon class="scb-textfield-error-icon" aria-hidden="true">error</md-icon>`:null;this.underLabel=this.error?this.errorText||"Ogiltig inmatning.":this.supportingText,this.value=this.value||"";const r=this.underLabel?`${this._inputId}-supporting-text`:void 0;return this.type==="textarea"?c`
|
|
5712
5719
|
<label class="scb-textfield-label" for="${this._inputId}">${this.label}</label>
|
|
5713
5720
|
<span
|
|
5714
5721
|
class="scb-textfield-supporting-text"
|
|
@@ -5878,7 +5885,7 @@ var ScbWcTest=function(a){"use strict";var xs;function d(o,e,t,r){var i=argument
|
|
|
5878
5885
|
.scb-textfield.has-error-icon {
|
|
5879
5886
|
padding-right: 44px; /* Adjust as needed for icon size and spacing */
|
|
5880
5887
|
}
|
|
5881
|
-
`],re([l({type:String,reflect:!0})],a.ScbTextField2.prototype,"type",2),re([l({type:String})],a.ScbTextField2.prototype,"label",2),re([l({type:String,attribute:"supporting-text"})],a.ScbTextField2.prototype,"supportingText",2),re([l({type:String,attribute:"error-text"})],a.ScbTextField2.prototype,"errorText",2),re([l({type:String,attribute:"leading-icon"})],a.ScbTextField2.prototype,"leadingIcon",2),re([l({type:String})],a.ScbTextField2.prototype,"name",2),re([l({type:String})],a.ScbTextField2.prototype,"pattern",2),re([l({type:String,attribute:"value"})],a.ScbTextField2.prototype,"value",2),re([l({type:String})],a.ScbTextField2.prototype,"underLabel",2),re([l({type:Boolean,reflect:!0})],a.ScbTextField2.prototype,"error",2),re([l({type:Boolean,reflect:!0})],a.ScbTextField2.prototype,"disabled",2),re([l({type:Boolean,reflect:!0})],a.ScbTextField2.prototype,"required",2),a.ScbTextField2=re([b("scb-textfield")],a.ScbTextField2);const
|
|
5888
|
+
`],re([l({type:String,reflect:!0})],a.ScbTextField2.prototype,"type",2),re([l({type:String})],a.ScbTextField2.prototype,"label",2),re([l({type:String,attribute:"supporting-text"})],a.ScbTextField2.prototype,"supportingText",2),re([l({type:String,attribute:"error-text"})],a.ScbTextField2.prototype,"errorText",2),re([l({type:String,attribute:"leading-icon"})],a.ScbTextField2.prototype,"leadingIcon",2),re([l({type:String})],a.ScbTextField2.prototype,"name",2),re([l({type:String})],a.ScbTextField2.prototype,"pattern",2),re([l({type:String,attribute:"value"})],a.ScbTextField2.prototype,"value",2),re([l({type:String})],a.ScbTextField2.prototype,"underLabel",2),re([l({type:Boolean,reflect:!0})],a.ScbTextField2.prototype,"error",2),re([l({type:Boolean,reflect:!0})],a.ScbTextField2.prototype,"disabled",2),re([l({type:Boolean,reflect:!0})],a.ScbTextField2.prototype,"required",2),a.ScbTextField2=re([b("scb-textfield")],a.ScbTextField2);const Rh=Object.freeze(Object.defineProperty({__proto__:null,get ScbTextField2(){return a.ScbTextField2}},Symbol.toStringTag,{value:"Module"}));var Bh=Object.defineProperty,Mh=Object.getOwnPropertyDescriptor,Et=(o,e,t,r)=>{for(var i=r>1?void 0:r?Mh(e,t):e,s=o.length-1,n;s>=0;s--)(n=o[s])&&(i=(r?n(e,t,i):n(i))||i);return r&&i&&Bh(e,t,i),i};a.ScbTocItem=class extends g{constructor(){super(...arguments),this.expanded=!1,this.label="",this.supportingText="",this.itemHref="#",this.divider=!0,this._unique=crypto.randomUUID(),this._slotHasContent=!1,this._onSlotChange=()=>{const e=this.renderRoot.querySelector("slot");this._slotHasContent=!!e&&e.assignedNodes().length>0,this.requestUpdate(),this._updateTabbable()},this.toggleAccordion=()=>{const e=this.closest("scb-toc");e!=null&&e.hasAttribute("detached")||e.querySelectorAll("scb-toc-item").forEach(i=>{i!==this&&i.expanded&&(i.expanded=!1,this.toggleBottom(i),i.dispatchEvent(new CustomEvent("expanded-changed",{detail:{expanded:!1},bubbles:!0,composed:!0})))});const t=this.expanded;this.expanded=!this.expanded,this.toggleBottom(this),t!==this.expanded&&this.dispatchEvent(new CustomEvent("expanded-changed",{detail:{expanded:this.expanded},bubbles:!0,composed:!0}))}}connectedCallback(){super.connectedCallback(),this.addEventListener("slotchange",this._onSlotChange)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("slotchange",this._onSlotChange)}updated(e){e.has("expanded")&&this._updateTabbable()}_updateTabbable(){if(typeof window>"u")return;const e=this.renderRoot.querySelector("slot");if(!e)return;e.assignedElements({flatten:!0}).forEach(r=>{var i;r.matches("a,button,input,select,textarea,[tabindex]")&&(this.expanded?r.removeAttribute("tabindex"):r.setAttribute("tabindex","-1")),(i=r.querySelectorAll)==null||i.call(r,"a,button,input,select,textarea,[tabindex]").forEach(s=>{const n=s;this.expanded?n.removeAttribute("tabindex"):n.setAttribute("tabindex","-1")})})}toggleBottom(e){const t=e.renderRoot.querySelector(".scb-toc-item-bottom");t&&(e.expanded?(t.style.maxHeight=`${t.scrollHeight}px`,setTimeout(()=>t.style.maxHeight="unset",160)):(t.style.maxHeight=`${t.scrollHeight}px`,requestAnimationFrame(()=>t.style.maxHeight="0")))}_onKeyDown(e){const t=this.closest("scb-toc"),i=Array.from((t==null?void 0:t.querySelectorAll("scb-toc-item"))||[]).map(h=>h.renderRoot.querySelector(".scb-toc-item")).filter(h=>!!h),s=e.currentTarget,n=i.indexOf(s);switch(e.key){case"Enter":case" ":e.preventDefault(),this.toggleAccordion();break;case"ArrowDown":e.preventDefault(),n<i.length-1&&i[n+1].focus();break;case"ArrowUp":e.preventDefault(),n>0&&i[n-1].focus();break;case"Home":e.preventDefault(),i.length&&i[0].focus();break;case"End":e.preventDefault(),i.length&&i[i.length-1].focus();break}}render(){const e=`bottom-${this._unique}`;return c`
|
|
5882
5889
|
<div
|
|
5883
5890
|
class="scb-toc-item"
|
|
5884
5891
|
role="listitem"
|