@codeforamerica/marcomms-design-system 1.16.0 → 1.17.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,16 +1,66 @@
1
1
  /*! For license information please see index.js.LICENSE.txt */
2
- (()=>{"use strict";const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,i=Symbol(),o=new WeakMap;class a{constructor(t,e,o){if(this._$cssResult$=!0,o!==i)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const i=this.t;if(e&&void 0===t){const e=void 0!==i&&1===i.length;e&&(t=o.get(i)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&o.set(i,t))}return t}toString(){return this.cssText}}const s=(t,...e)=>{const o=1===t.length?t[0]:e.reduce((e,i,o)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+t[o+1],t[0]);return new a(o,t,i)},r=(i,o)=>{if(e)i.adoptedStyleSheets=o.map(t=>t instanceof CSSStyleSheet?t:t.styleSheet);else for(const e of o){const o=document.createElement("style"),a=t.litNonce;void 0!==a&&o.setAttribute("nonce",a),o.textContent=e.cssText,i.appendChild(o)}},n=e?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return(t=>new a("string"==typeof t?t:t+"",void 0,i))(e)})(t):t,{is:l,defineProperty:c,getOwnPropertyDescriptor:h,getOwnPropertyNames:d,getOwnPropertySymbols:p,getPrototypeOf:u}=Object,g=globalThis,v=g.trustedTypes,m=v?v.emptyScript:"",f=g.reactiveElementPolyfillSupport,b=(t,e)=>t,w={toAttribute(t,e){switch(e){case Boolean:t=t?m:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},y=(t,e)=>!l(t,e),x={attribute:!0,type:String,converter:w,reflect:!1,useDefault:!1,hasChanged:y};Symbol.metadata??=Symbol("metadata"),g.litPropertyMetadata??=new WeakMap;class k extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=x){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const i=Symbol(),o=this.getPropertyDescriptor(t,i,e);void 0!==o&&c(this.prototype,t,o)}}static getPropertyDescriptor(t,e,i){const{get:o,set:a}=h(this.prototype,t)??{get(){return this[e]},set(t){this[e]=t}};return{get:o,set(e){const s=o?.call(this);a?.call(this,e),this.requestUpdate(t,s,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??x}static _$Ei(){if(this.hasOwnProperty(b("elementProperties")))return;const t=u(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(b("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(b("properties"))){const t=this.properties,e=[...d(t),...p(t)];for(const i of e)this.createProperty(i,t[i])}const t=this[Symbol.metadata];if(null!==t){const e=litPropertyMetadata.get(t);if(void 0!==e)for(const[t,i]of e)this.elementProperties.set(t,i)}this._$Eh=new Map;for(const[t,e]of this.elementProperties){const i=this._$Eu(t,e);void 0!==i&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(n(t))}else void 0!==t&&e.push(n(t));return e}static _$Eu(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(t=>t(this))}addController(t){(this._$EO??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){const t=new Map,e=this.constructor.elementProperties;for(const i of e.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return r(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$ET(t,e){const i=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,i);if(void 0!==o&&!0===i.reflect){const a=(void 0!==i.converter?.toAttribute?i.converter:w).toAttribute(e,i.type);this._$Em=t,null==a?this.removeAttribute(o):this.setAttribute(o,a),this._$Em=null}}_$AK(t,e){const i=this.constructor,o=i._$Eh.get(t);if(void 0!==o&&this._$Em!==o){const t=i.getPropertyOptions(o),a="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:w;this._$Em=o;const s=a.fromAttribute(e,t.type);this[o]=s??this._$Ej?.get(o)??s,this._$Em=null}}requestUpdate(t,e,i,o=!1,a){if(void 0!==t){const s=this.constructor;if(!1===o&&(a=this[t]),i??=s.getPropertyOptions(t),!((i.hasChanged??y)(a,e)||i.useDefault&&i.reflect&&a===this._$Ej?.get(t)&&!this.hasAttribute(s._$Eu(t,i))))return;this.C(t,e,i)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(t,e,{useDefault:i,reflect:o,wrapped:a},s){i&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,s??e??this[t]),!0!==a||void 0!==s)||(this._$AL.has(t)||(this.hasUpdated||i||(e=void 0),this._$AL.set(t,e)),!0===o&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,e]of this._$Ep)this[t]=e;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[e,i]of t){const{wrapped:t}=i,o=this[e];!0!==t||this._$AL.has(e)||void 0===o||this.C(e,void 0,i,o)}}let t=!1;const e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(t=>t.hostUpdate?.()),this.update(e)):this._$EM()}catch(e){throw t=!1,this._$EM(),e}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach(t=>t.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&=this._$Eq.forEach(t=>this._$ET(t,this[t])),this._$EM()}updated(t){}firstUpdated(t){}}k.elementStyles=[],k.shadowRootOptions={mode:"open"},k[b("elementProperties")]=new Map,k[b("finalized")]=new Map,f?.({ReactiveElement:k}),(g.reactiveElementVersions??=[]).push("2.1.2");const $=globalThis,_=t=>t,E=$.trustedTypes,A=E?E.createPolicy("lit-html",{createHTML:t=>t}):void 0,z="$lit$",P=`lit$${Math.random().toFixed(9).slice(2)}$`,S="?"+P,T=`<${S}>`,C=document,L=()=>C.createComment(""),U=t=>null===t||"object"!=typeof t&&"function"!=typeof t,M=Array.isArray,I="[ \t\n\f\r]",R=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,H=/-->/g,N=/>/g,O=RegExp(`>|${I}(?:([^\\s"'>=/]+)(${I}*=${I}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),V=/'/g,q=/"/g,B=/^(?:script|style|textarea|title)$/i,F=t=>(e,...i)=>({_$litType$:t,strings:e,values:i}),D=F(1),j=F(2),W=(F(3),Symbol.for("lit-noChange")),K=Symbol.for("lit-nothing"),X=new WeakMap,Z=C.createTreeWalker(C,129);function G(t,e){if(!M(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==A?A.createHTML(e):e}const Y=(t,e)=>{const i=t.length-1,o=[];let a,s=2===e?"<svg>":3===e?"<math>":"",r=R;for(let e=0;e<i;e++){const i=t[e];let n,l,c=-1,h=0;for(;h<i.length&&(r.lastIndex=h,l=r.exec(i),null!==l);)h=r.lastIndex,r===R?"!--"===l[1]?r=H:void 0!==l[1]?r=N:void 0!==l[2]?(B.test(l[2])&&(a=RegExp("</"+l[2],"g")),r=O):void 0!==l[3]&&(r=O):r===O?">"===l[0]?(r=a??R,c=-1):void 0===l[1]?c=-2:(c=r.lastIndex-l[2].length,n=l[1],r=void 0===l[3]?O:'"'===l[3]?q:V):r===q||r===V?r=O:r===H||r===N?r=R:(r=O,a=void 0);const d=r===O&&t[e+1].startsWith("/>")?" ":"";s+=r===R?i+T:c>=0?(o.push(n),i.slice(0,c)+z+i.slice(c)+P+d):i+P+(-2===c?e:d)}return[G(t,s+(t[i]||"<?>")+(2===e?"</svg>":3===e?"</math>":"")),o]};class J{constructor({strings:t,_$litType$:e},i){let o;this.parts=[];let a=0,s=0;const r=t.length-1,n=this.parts,[l,c]=Y(t,e);if(this.el=J.createElement(l,i),Z.currentNode=this.el.content,2===e||3===e){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(o=Z.nextNode())&&n.length<r;){if(1===o.nodeType){if(o.hasAttributes())for(const t of o.getAttributeNames())if(t.endsWith(z)){const e=c[s++],i=o.getAttribute(t).split(P),r=/([.?@])?(.*)/.exec(e);n.push({type:1,index:a,name:r[2],strings:i,ctor:"."===r[1]?ot:"?"===r[1]?at:"@"===r[1]?st:it}),o.removeAttribute(t)}else t.startsWith(P)&&(n.push({type:6,index:a}),o.removeAttribute(t));if(B.test(o.tagName)){const t=o.textContent.split(P),e=t.length-1;if(e>0){o.textContent=E?E.emptyScript:"";for(let i=0;i<e;i++)o.append(t[i],L()),Z.nextNode(),n.push({type:2,index:++a});o.append(t[e],L())}}}else if(8===o.nodeType)if(o.data===S)n.push({type:2,index:a});else{let t=-1;for(;-1!==(t=o.data.indexOf(P,t+1));)n.push({type:7,index:a}),t+=P.length-1}a++}}static createElement(t,e){const i=C.createElement("template");return i.innerHTML=t,i}}function Q(t,e,i=t,o){if(e===W)return e;let a=void 0!==o?i._$Co?.[o]:i._$Cl;const s=U(e)?void 0:e._$litDirective$;return a?.constructor!==s&&(a?._$AO?.(!1),void 0===s?a=void 0:(a=new s(t),a._$AT(t,i,o)),void 0!==o?(i._$Co??=[])[o]=a:i._$Cl=a),void 0!==a&&(e=Q(t,a._$AS(t,e.values),a,o)),e}class tt{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:i}=this._$AD,o=(t?.creationScope??C).importNode(e,!0);Z.currentNode=o;let a=Z.nextNode(),s=0,r=0,n=i[0];for(;void 0!==n;){if(s===n.index){let e;2===n.type?e=new et(a,a.nextSibling,this,t):1===n.type?e=new n.ctor(a,n.name,n.strings,this,t):6===n.type&&(e=new rt(a,this,t)),this._$AV.push(e),n=i[++r]}s!==n?.index&&(a=Z.nextNode(),s++)}return Z.currentNode=C,o}p(t){let e=0;for(const i of this._$AV)void 0!==i&&(void 0!==i.strings?(i._$AI(t,i,e),e+=i.strings.length-2):i._$AI(t[e])),e++}}class et{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,i,o){this.type=2,this._$AH=K,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=o,this._$Cv=o?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t?.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=Q(this,t,e),U(t)?t===K||null==t||""===t?(this._$AH!==K&&this._$AR(),this._$AH=K):t!==this._$AH&&t!==W&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):(t=>M(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==K&&U(this._$AH)?this._$AA.nextSibling.data=t:this.T(C.createTextNode(t)),this._$AH=t}$(t){const{values:e,_$litType$:i}=t,o="number"==typeof i?this._$AC(t):(void 0===i.el&&(i.el=J.createElement(G(i.h,i.h[0]),this.options)),i);if(this._$AH?._$AD===o)this._$AH.p(e);else{const t=new tt(o,this),i=t.u(this.options);t.p(e),this.T(i),this._$AH=t}}_$AC(t){let e=X.get(t.strings);return void 0===e&&X.set(t.strings,e=new J(t)),e}k(t){M(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,o=0;for(const a of t)o===e.length?e.push(i=new et(this.O(L()),this.O(L()),this,this.options)):i=e[o],i._$AI(a),o++;o<e.length&&(this._$AR(i&&i._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){const e=_(t).nextSibling;_(t).remove(),t=e}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}}class it{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,i,o,a){this.type=1,this._$AH=K,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=a,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=K}_$AI(t,e=this,i,o){const a=this.strings;let s=!1;if(void 0===a)t=Q(this,t,e,0),s=!U(t)||t!==this._$AH&&t!==W,s&&(this._$AH=t);else{const o=t;let r,n;for(t=a[0],r=0;r<a.length-1;r++)n=Q(this,o[i+r],e,r),n===W&&(n=this._$AH[r]),s||=!U(n)||n!==this._$AH[r],n===K?t=K:t!==K&&(t+=(n??"")+a[r+1]),this._$AH[r]=n}s&&!o&&this.j(t)}j(t){t===K?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class ot extends it{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===K?void 0:t}}class at extends it{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==K)}}class st extends it{constructor(t,e,i,o,a){super(t,e,i,o,a),this.type=5}_$AI(t,e=this){if((t=Q(this,t,e,0)??K)===W)return;const i=this._$AH,o=t===K&&i!==K||t.capture!==i.capture||t.once!==i.once||t.passive!==i.passive,a=t!==K&&(i===K||o);o&&this.element.removeEventListener(this.name,this,i),a&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}}class rt{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){Q(this,t)}}const nt=$.litHtmlPolyfillSupport;nt?.(J,et),($.litHtmlVersions??=[]).push("3.3.2");const lt=globalThis;class ct extends k{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){const t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,e,i)=>{const o=i?.renderBefore??e;let a=o._$litPart$;if(void 0===a){const t=i?.renderBefore??null;o._$litPart$=a=new et(e.insertBefore(L(),t),t,void 0,i??{})}return a._$AI(t),a})(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return W}}ct._$litElement$=!0,ct.finalized=!0,lt.litElementHydrateSupport?.({LitElement:ct});const ht=lt.litElementPolyfillSupport;ht?.({LitElement:ct}),(lt.litElementVersions??=[]).push("4.2.2");const dt=s`
3
- *,
4
- *::before,
5
- *::after {
6
- box-sizing: border-box;
7
- }
8
-
2
+ (()=>{"use strict";const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,i=Symbol(),a=new WeakMap;class o{constructor(t,e,a){if(this._$cssResult$=!0,a!==i)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const i=this.t;if(e&&void 0===t){const e=void 0!==i&&1===i.length;e&&(t=a.get(i)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&a.set(i,t))}return t}toString(){return this.cssText}}const s=(t,...e)=>{const a=1===t.length?t[0]:e.reduce((e,i,a)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+t[a+1],t[0]);return new o(a,t,i)},r=(i,a)=>{if(e)i.adoptedStyleSheets=a.map(t=>t instanceof CSSStyleSheet?t:t.styleSheet);else for(const e of a){const a=document.createElement("style"),o=t.litNonce;void 0!==o&&a.setAttribute("nonce",o),a.textContent=e.cssText,i.appendChild(a)}},n=e?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return(t=>new o("string"==typeof t?t:t+"",void 0,i))(e)})(t):t,{is:l,defineProperty:c,getOwnPropertyDescriptor:h,getOwnPropertyNames:d,getOwnPropertySymbols:p,getPrototypeOf:g}=Object,u=globalThis,v=u.trustedTypes,m=v?v.emptyScript:"",f=u.reactiveElementPolyfillSupport,b=(t,e)=>t,w={toAttribute(t,e){switch(e){case Boolean:t=t?m:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},y=(t,e)=>!l(t,e),x={attribute:!0,type:String,converter:w,reflect:!1,useDefault:!1,hasChanged:y};Symbol.metadata??=Symbol("metadata"),u.litPropertyMetadata??=new WeakMap;class k extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=x){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const i=Symbol(),a=this.getPropertyDescriptor(t,i,e);void 0!==a&&c(this.prototype,t,a)}}static getPropertyDescriptor(t,e,i){const{get:a,set:o}=h(this.prototype,t)??{get(){return this[e]},set(t){this[e]=t}};return{get:a,set(e){const s=a?.call(this);o?.call(this,e),this.requestUpdate(t,s,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??x}static _$Ei(){if(this.hasOwnProperty(b("elementProperties")))return;const t=g(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(b("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(b("properties"))){const t=this.properties,e=[...d(t),...p(t)];for(const i of e)this.createProperty(i,t[i])}const t=this[Symbol.metadata];if(null!==t){const e=litPropertyMetadata.get(t);if(void 0!==e)for(const[t,i]of e)this.elementProperties.set(t,i)}this._$Eh=new Map;for(const[t,e]of this.elementProperties){const i=this._$Eu(t,e);void 0!==i&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(n(t))}else void 0!==t&&e.push(n(t));return e}static _$Eu(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(t=>t(this))}addController(t){(this._$EO??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){const t=new Map,e=this.constructor.elementProperties;for(const i of e.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return r(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$ET(t,e){const i=this.constructor.elementProperties.get(t),a=this.constructor._$Eu(t,i);if(void 0!==a&&!0===i.reflect){const o=(void 0!==i.converter?.toAttribute?i.converter:w).toAttribute(e,i.type);this._$Em=t,null==o?this.removeAttribute(a):this.setAttribute(a,o),this._$Em=null}}_$AK(t,e){const i=this.constructor,a=i._$Eh.get(t);if(void 0!==a&&this._$Em!==a){const t=i.getPropertyOptions(a),o="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:w;this._$Em=a;const s=o.fromAttribute(e,t.type);this[a]=s??this._$Ej?.get(a)??s,this._$Em=null}}requestUpdate(t,e,i,a=!1,o){if(void 0!==t){const s=this.constructor;if(!1===a&&(o=this[t]),i??=s.getPropertyOptions(t),!((i.hasChanged??y)(o,e)||i.useDefault&&i.reflect&&o===this._$Ej?.get(t)&&!this.hasAttribute(s._$Eu(t,i))))return;this.C(t,e,i)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(t,e,{useDefault:i,reflect:a,wrapped:o},s){i&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,s??e??this[t]),!0!==o||void 0!==s)||(this._$AL.has(t)||(this.hasUpdated||i||(e=void 0),this._$AL.set(t,e)),!0===a&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,e]of this._$Ep)this[t]=e;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[e,i]of t){const{wrapped:t}=i,a=this[e];!0!==t||this._$AL.has(e)||void 0===a||this.C(e,void 0,i,a)}}let t=!1;const e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(t=>t.hostUpdate?.()),this.update(e)):this._$EM()}catch(e){throw t=!1,this._$EM(),e}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach(t=>t.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&=this._$Eq.forEach(t=>this._$ET(t,this[t])),this._$EM()}updated(t){}firstUpdated(t){}}k.elementStyles=[],k.shadowRootOptions={mode:"open"},k[b("elementProperties")]=new Map,k[b("finalized")]=new Map,f?.({ReactiveElement:k}),(u.reactiveElementVersions??=[]).push("2.1.2");const $=globalThis,_=t=>t,E=$.trustedTypes,A=E?E.createPolicy("lit-html",{createHTML:t=>t}):void 0,z="$lit$",P=`lit$${Math.random().toFixed(9).slice(2)}$`,S="?"+P,T=`<${S}>`,C=document,L=()=>C.createComment(""),U=t=>null===t||"object"!=typeof t&&"function"!=typeof t,M=Array.isArray,I="[ \t\n\f\r]",R=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,H=/-->/g,N=/>/g,O=RegExp(`>|${I}(?:([^\\s"'>=/]+)(${I}*=${I}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),V=/'/g,q=/"/g,B=/^(?:script|style|textarea|title)$/i,F=t=>(e,...i)=>({_$litType$:t,strings:e,values:i}),D=F(1),j=F(2),W=(F(3),Symbol.for("lit-noChange")),K=Symbol.for("lit-nothing"),X=new WeakMap,Z=C.createTreeWalker(C,129);function G(t,e){if(!M(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==A?A.createHTML(e):e}const Y=(t,e)=>{const i=t.length-1,a=[];let o,s=2===e?"<svg>":3===e?"<math>":"",r=R;for(let e=0;e<i;e++){const i=t[e];let n,l,c=-1,h=0;for(;h<i.length&&(r.lastIndex=h,l=r.exec(i),null!==l);)h=r.lastIndex,r===R?"!--"===l[1]?r=H:void 0!==l[1]?r=N:void 0!==l[2]?(B.test(l[2])&&(o=RegExp("</"+l[2],"g")),r=O):void 0!==l[3]&&(r=O):r===O?">"===l[0]?(r=o??R,c=-1):void 0===l[1]?c=-2:(c=r.lastIndex-l[2].length,n=l[1],r=void 0===l[3]?O:'"'===l[3]?q:V):r===q||r===V?r=O:r===H||r===N?r=R:(r=O,o=void 0);const d=r===O&&t[e+1].startsWith("/>")?" ":"";s+=r===R?i+T:c>=0?(a.push(n),i.slice(0,c)+z+i.slice(c)+P+d):i+P+(-2===c?e:d)}return[G(t,s+(t[i]||"<?>")+(2===e?"</svg>":3===e?"</math>":"")),a]};class J{constructor({strings:t,_$litType$:e},i){let a;this.parts=[];let o=0,s=0;const r=t.length-1,n=this.parts,[l,c]=Y(t,e);if(this.el=J.createElement(l,i),Z.currentNode=this.el.content,2===e||3===e){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(a=Z.nextNode())&&n.length<r;){if(1===a.nodeType){if(a.hasAttributes())for(const t of a.getAttributeNames())if(t.endsWith(z)){const e=c[s++],i=a.getAttribute(t).split(P),r=/([.?@])?(.*)/.exec(e);n.push({type:1,index:o,name:r[2],strings:i,ctor:"."===r[1]?at:"?"===r[1]?ot:"@"===r[1]?st:it}),a.removeAttribute(t)}else t.startsWith(P)&&(n.push({type:6,index:o}),a.removeAttribute(t));if(B.test(a.tagName)){const t=a.textContent.split(P),e=t.length-1;if(e>0){a.textContent=E?E.emptyScript:"";for(let i=0;i<e;i++)a.append(t[i],L()),Z.nextNode(),n.push({type:2,index:++o});a.append(t[e],L())}}}else if(8===a.nodeType)if(a.data===S)n.push({type:2,index:o});else{let t=-1;for(;-1!==(t=a.data.indexOf(P,t+1));)n.push({type:7,index:o}),t+=P.length-1}o++}}static createElement(t,e){const i=C.createElement("template");return i.innerHTML=t,i}}function Q(t,e,i=t,a){if(e===W)return e;let o=void 0!==a?i._$Co?.[a]:i._$Cl;const s=U(e)?void 0:e._$litDirective$;return o?.constructor!==s&&(o?._$AO?.(!1),void 0===s?o=void 0:(o=new s(t),o._$AT(t,i,a)),void 0!==a?(i._$Co??=[])[a]=o:i._$Cl=o),void 0!==o&&(e=Q(t,o._$AS(t,e.values),o,a)),e}class tt{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:i}=this._$AD,a=(t?.creationScope??C).importNode(e,!0);Z.currentNode=a;let o=Z.nextNode(),s=0,r=0,n=i[0];for(;void 0!==n;){if(s===n.index){let e;2===n.type?e=new et(o,o.nextSibling,this,t):1===n.type?e=new n.ctor(o,n.name,n.strings,this,t):6===n.type&&(e=new rt(o,this,t)),this._$AV.push(e),n=i[++r]}s!==n?.index&&(o=Z.nextNode(),s++)}return Z.currentNode=C,a}p(t){let e=0;for(const i of this._$AV)void 0!==i&&(void 0!==i.strings?(i._$AI(t,i,e),e+=i.strings.length-2):i._$AI(t[e])),e++}}class et{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,i,a){this.type=2,this._$AH=K,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=a,this._$Cv=a?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t?.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=Q(this,t,e),U(t)?t===K||null==t||""===t?(this._$AH!==K&&this._$AR(),this._$AH=K):t!==this._$AH&&t!==W&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):(t=>M(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==K&&U(this._$AH)?this._$AA.nextSibling.data=t:this.T(C.createTextNode(t)),this._$AH=t}$(t){const{values:e,_$litType$:i}=t,a="number"==typeof i?this._$AC(t):(void 0===i.el&&(i.el=J.createElement(G(i.h,i.h[0]),this.options)),i);if(this._$AH?._$AD===a)this._$AH.p(e);else{const t=new tt(a,this),i=t.u(this.options);t.p(e),this.T(i),this._$AH=t}}_$AC(t){let e=X.get(t.strings);return void 0===e&&X.set(t.strings,e=new J(t)),e}k(t){M(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,a=0;for(const o of t)a===e.length?e.push(i=new et(this.O(L()),this.O(L()),this,this.options)):i=e[a],i._$AI(o),a++;a<e.length&&(this._$AR(i&&i._$AB.nextSibling,a),e.length=a)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){const e=_(t).nextSibling;_(t).remove(),t=e}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}}class it{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,i,a,o){this.type=1,this._$AH=K,this._$AN=void 0,this.element=t,this.name=e,this._$AM=a,this.options=o,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=K}_$AI(t,e=this,i,a){const o=this.strings;let s=!1;if(void 0===o)t=Q(this,t,e,0),s=!U(t)||t!==this._$AH&&t!==W,s&&(this._$AH=t);else{const a=t;let r,n;for(t=o[0],r=0;r<o.length-1;r++)n=Q(this,a[i+r],e,r),n===W&&(n=this._$AH[r]),s||=!U(n)||n!==this._$AH[r],n===K?t=K:t!==K&&(t+=(n??"")+o[r+1]),this._$AH[r]=n}s&&!a&&this.j(t)}j(t){t===K?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class at extends it{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===K?void 0:t}}class ot extends it{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==K)}}class st extends it{constructor(t,e,i,a,o){super(t,e,i,a,o),this.type=5}_$AI(t,e=this){if((t=Q(this,t,e,0)??K)===W)return;const i=this._$AH,a=t===K&&i!==K||t.capture!==i.capture||t.once!==i.once||t.passive!==i.passive,o=t!==K&&(i===K||a);a&&this.element.removeEventListener(this.name,this,i),o&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}}class rt{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){Q(this,t)}}const nt=$.litHtmlPolyfillSupport;nt?.(J,et),($.litHtmlVersions??=[]).push("3.3.2");const lt=globalThis;class ct extends k{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){const t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,e,i)=>{const a=i?.renderBefore??e;let o=a._$litPart$;if(void 0===o){const t=i?.renderBefore??null;a._$litPart$=o=new et(e.insertBefore(L(),t),t,void 0,i??{})}return o._$AI(t),o})(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return W}}ct._$litElement$=!0,ct.finalized=!0,lt.litElementHydrateSupport?.({LitElement:ct});const ht=lt.litElementPolyfillSupport;ht?.({LitElement:ct}),(lt.litElementVersions??=[]).push("4.2.2");const dt=s`
9
3
  *:focus-visible,
10
4
  *:target {
11
5
  outline: var(--focus-outline);
12
6
  position: relative;
13
7
  }
8
+
9
+ // RESET
10
+
11
+ // Use a more-intuitive box-sizing model.
12
+ *, *::before, *::after {
13
+ box-sizing: border-box;
14
+ }
15
+
16
+ // Remove default margin
17
+ * {
18
+ margin: 0;
19
+ }
20
+
21
+ // Set default text-wrap of 'pretty'
22
+ * {
23
+ text-wrap: pretty;
24
+ }
25
+
26
+ // Wrap overly long words
27
+ * {
28
+ overflow-wrap: break-word;
29
+ text-overflow: ellipsis;
30
+ word-break: break-word;
31
+ }
32
+
33
+ // Fix Safari antialiasing for variable fonts
34
+ * {
35
+ font-synthesis: none !important;
36
+ }
37
+
38
+ // Improve text rendering
39
+ body {
40
+ -webkit-font-smoothing: antialiased;
41
+ }
42
+
43
+ // Reasonable media defaults
44
+ img, picture, video, canvas, svg {
45
+ display: block;
46
+ height: auto;
47
+ max-width: 100%;
48
+ }
49
+
50
+ // Remove built-in form typography styles
51
+ input, button, textarea, select {
52
+ font: inherit;
53
+ }
54
+
55
+ // Avoid text overflows
56
+ p, h1, h2, h3, h4, h5, h6 {
57
+ overflow-wrap: break-word;
58
+ }
59
+
60
+ // Create a root stacking context
61
+ #root, #__next {
62
+ isolation: isolate;
63
+ }
14
64
  `;class pt extends ct{static properties={imageUrl:{},altText:{},size:{}};static styles=(()=>[dt,s`
15
65
  :host {
16
66
  --bg-color: var(--blue-20);
@@ -50,7 +100,7 @@
50
100
  />
51
101
  `:K}
52
102
  </picture>
53
- `}}customElements.get("cfa-avatar")||customElements.define("cfa-avatar",pt);class ut extends ct{static properties={color:{},shape:{},styles:{}};static styles=(()=>[dt,s`
103
+ `}}customElements.get("cfa-avatar")||customElements.define("cfa-avatar",pt);class gt extends ct{static properties={color:{},shape:{},styles:{}};static styles=(()=>[dt,s`
54
104
  :host {
55
105
  --color: var(--blue-20);
56
106
 
@@ -119,7 +169,7 @@
119
169
  >
120
170
  ${this.blobTemplate()}
121
171
  </div>
122
- `}}customElements.get("cfa-blob")||customElements.define("cfa-blob",ut);const gt=s`
172
+ `}}customElements.get("cfa-blob")||customElements.define("cfa-blob",gt);const ut=s`
123
173
  .cfa-button,
124
174
  a.cfa-button,
125
175
  .cfa-button > a,
@@ -304,76 +354,134 @@
304
354
  <slot></slot>
305
355
  </span>
306
356
  `}}customElements.get("cfa-icon")||customElements.define("cfa-icon",vt);const mt=s`
307
- .serif {
308
- font-family: var(--font-family-serif) !important;
309
- }
357
+ // =====
310
358
 
311
- .sans-serif {
312
- font-family: var(--font-family-sans-serif) !important;
359
+ // Typography spacing
360
+
361
+ // Add a single space around paragraphs, blockquotes, and lists
362
+ p, ul, ol, blockquote {
363
+ & + * {
364
+ margin-block-start: var(--spacing, var(--spacing-layout-1, 1.5rem));
365
+ }
366
+ * + & {
367
+ margin-block-start: var(--spacing, var(--spacing-layout-1, 1.5rem));
368
+ }
313
369
  }
314
370
 
315
- .normal {
316
- font-weight: normal !important;
371
+ h1, h2, h3, h4, .h1, .h2, .h3, .h4, .display-1, .display-2 {
372
+ // Add a single line space after headings
373
+ & + * {
374
+ margin-block-start: var(--spacing, var(--spacing-layout-1, 1.5rem));
375
+ }
376
+
377
+ // Add two line spaces before headings
378
+ * + & {
379
+ --spacing: var(--spacing-layout-2);
380
+
381
+ margin-block-start: --spacing;
382
+ }
383
+
384
+ // Only add a single space between headings and other headings
385
+ & + & {
386
+ --spacing: var(--spacing-layout-1);
387
+ }
388
+
389
+ // Reduce space after breadcrumbs and eyebrows
390
+ cfa-breadcrumbs + & {
391
+ margin-block-start: var(--spacing-layout-half) !important;
392
+ }
393
+
394
+ .eyebrow + & {
395
+ margin-block-start: 0 !important;
396
+ }
317
397
  }
318
398
 
319
- .strong {
320
- font-weight: bold !important;
399
+ h1, .h1, .display-1, .display-2 {
400
+ text-wrap: balance;
321
401
  }
322
402
 
323
- italic {
324
- font-style: italic !important;
403
+ // =====
404
+
405
+ // Font styles
406
+
407
+ .regular {
408
+ font-family: var(--font-family-base);
409
+ font-size: var(--font-size-base);
410
+ line-height: var(--line-height-base);
325
411
  }
326
412
 
327
- .display 1 {
328
- font-family: var(--font-family-display-1);
413
+ .display-1 {
414
+ font-family: var(--font-family-heading);
329
415
  font-size: var(--font-size-display-1);
330
- font-weight: var(--font-weight-display-1);
331
- letter-spacing: var(--letter-spacing-display-1);
416
+ font-weight: bold;
332
417
  line-height: var(--line-height-display-1);
418
+ letter-spacing: var(--letter-spacing-display-1);
333
419
  }
334
420
 
335
421
  .display-2 {
336
- font-family: var(--font-family-display-2);
422
+ font-family: var(--font-family-heading);
337
423
  font-size: var(--font-size-display-2);
338
- font-weight: var(--font-weight-display-2);
339
- letter-spacing: var(--letter-spacing-display-2);
424
+ font-weight: bold;
340
425
  line-height: var(--line-height-display-2);
426
+ letter-spacing: var(--letter-spacing-display-2);
341
427
  }
342
428
 
429
+ h1,
343
430
  .h1 {
344
- font-family: var(--font-family-h1);
431
+ font-family: var(--font-family-heading);
345
432
  font-size: var(--font-size-h1);
346
- font-weight: var(--font-weight-h1);
347
- letter-spacing: var(--letter-spacing-h1);
433
+ font-weight: bold;
348
434
  line-height: var(--line-height-h1);
435
+ letter-spacing: var(--letter-spacing-h1);
349
436
  }
350
437
 
438
+ h2,
351
439
  .h2 {
352
- font-family: var(--font-family-h2);
440
+ font-family: var(--font-family-heading);
353
441
  font-size: var(--font-size-h2);
354
- font-weight: var(--font-weight-h2);
355
- letter-spacing: var(--letter-spacing-h2);
442
+ font-weight: bold;
356
443
  line-height: var(--line-height-h2);
444
+ letter-spacing: var(--letter-spacing-h2);
357
445
  }
358
446
 
447
+ h3,
359
448
  .h3 {
360
- font-family: var(--font-family-h3);
449
+ font-family: var(--font-family-heading);
361
450
  font-size: var(--font-size-h3);
362
- font-weight: var(--font-weight-h3);
363
- letter-spacing: var(--letter-spacing-h3);
451
+ font-weight: bold;
364
452
  line-height: var(--line-height-h3);
453
+ letter-spacing: var(--letter-spacing-h3);
365
454
  }
366
455
 
456
+ h4,
367
457
  .h4 {
368
- font-family: var(--font-family-h4);
458
+ font-family: var(--font-family-heading);
369
459
  font-size: var(--font-size-h4);
370
- font-weight: var(--font-weight-h4);
371
- letter-spacing: var(--letter-spacing-h4);
460
+ font-weight: bold;
372
461
  line-height: var(--line-height-h4);
462
+ letter-spacing: var(--letter-spacing-h4);
463
+ }
464
+
465
+ .extra-large {
466
+ font-size: var(--font-size-extra-large);
467
+ line-height: var(--line-height-extra-large);
468
+ letter-spacing: var(--letter-spacing-extra-large);
469
+ }
470
+
471
+ .large {
472
+ font-size: var(--font-size-large);
473
+ line-height: var(--line-height-large);
474
+ letter-spacing: var(--letter-spacing-large);
475
+ }
476
+
477
+ .small {
478
+ font-size: var(--font-size-small);
479
+ line-height: var(--line-height-small);
480
+ letter-spacing: var(--letter-spacing-small);
373
481
  }
374
482
 
375
483
  .eyebrow {
376
- font-family: var(--font-family-eyebrow);
484
+ font-family: var(--font-family-sans-serif);
377
485
  font-size: var(--font-size-eyebrow);
378
486
  font-weight: var(--font-weight-eyebrow);
379
487
  letter-spacing: var(--letter-spacing-eyebrow);
@@ -393,23 +501,251 @@
393
501
  margin-block-end: var(--spacing-layout-half);
394
502
  position: relative;
395
503
  text-transform: uppercase;
504
+
505
+ &::after {
506
+ border-block-end: var(--hairline) solid currentColor;
507
+ content: "";
508
+ flex-grow: 1;
509
+ margin-left: var(--spacing-component-3);
510
+ }
511
+ }
512
+
513
+ .subtle {
514
+ opacity: 0.6;
515
+ }
516
+
517
+ .serif {
518
+ font-family: var(--font-family-serif);
519
+ }
520
+
521
+ .sans-serif {
522
+ font-family: var(--font-family-sans-serif);
523
+ }
524
+
525
+ i,
526
+ em,
527
+ .italic {
528
+ font-style: italic;
529
+ }
530
+
531
+ b,
532
+ strong,
533
+ .strong {
534
+ font-weight: bold;
535
+ }
536
+
537
+ .normal {
538
+ font-weight: normal;
539
+ }
540
+
541
+ .prominent-link,
542
+ a.prominent-link {
543
+ --accent-color: var(--purple-60);
544
+
545
+ font-weight: bold;
546
+ text-decoration: underline;
547
+ text-decoration-color: var(--accent-color);
548
+ text-decoration-thickness: var(--medium);
549
+ text-underline-offset: 0.4em;
550
+ transition: color 0.2s ease-in-out, border-color 0.2s ease-in-out;
551
+
552
+ &:hover {
553
+ --accent-color: var(--red-60);
554
+ }
555
+
556
+ &:not(:has(cfa-icon))::after {
557
+ @include icon.icon;
558
+
559
+ content: "arrow_right_alt";
560
+ display: inline-block;
561
+ padding-inline-start: 0.1em;
562
+ text-decoration: none;
563
+ transition: padding 0.2s ease-in-out;
564
+ width: 1em;
565
+ }
566
+
567
+ &:not(:has(cfa-icon)):hover::after {
568
+ padding-inline-start: 0.3em;
569
+ }
570
+
571
+ cfa-icon {
572
+ text-decoration: none;
573
+ }
574
+ }
575
+
576
+ .white-text,
577
+ .text-light /* fallback */ {
578
+ -moz-osx-font-smoothing: grayscale; // Sharper antialising for white text on a dark background
579
+ -webkit-font-smoothing: antialiased; // Sharper antialising for white text on a dark background
580
+ color: var(--white);
581
+ --link-color: var(--white);
582
+ --link-hover-color: var(--white);
583
+ }
584
+
585
+ // =====
586
+
587
+ // Highlights
588
+
589
+ .highlight {
590
+ --highlight-offset: 0.2em;
591
+
592
+ box-decoration-break: clone;
593
+ display: inline;
594
+ background: linear-gradient(to top, transparent 0%, transparent var(--highlight-offset), var(--highlight-color) var(--highlight-offset), var(--highlight-color) calc(var(--highlight-offset) + var(--highlight-thickness)), transparent calc(var(--highlight-offset) + var(--highlight-thickness)), transparent 100%);
595
+ padding-inline: 0.1em;
596
+ -webkit-box-decoration-break: clone;
597
+ margin-inline-start: -0.1em;
598
+ margin-inline-end: -0.1em;
599
+ word-wrap: break-word;
396
600
  }
397
601
 
398
- .eyebrow-with-line::after {
399
- border-block-end: var(--hairline) solid var(--text-color);
602
+ // ======
603
+
604
+ // Lists
605
+
606
+ .ul {
607
+ list-style-type: disc;
608
+ padding-left: var(--spacing-layout-1);
609
+ }
610
+
611
+ .ul > li {
612
+ margin-inline-start: 0;
613
+ padding-left: var(--spacing-component-2);
614
+ }
615
+
616
+ .ul > li + li {
617
+ margin-block-start: var(--spacing-layout-half);
618
+ }
619
+
620
+ .ul > li > ul {
621
+ margin-block-start: var(--spacing-layout-half);
622
+ }
623
+
624
+ .ol {
625
+ list-style-type: decimal;
626
+ padding-left: var(--spacing-layout-1);
627
+ }
628
+
629
+ .ol > li {
630
+ margin-inline-start: 0;
631
+ padding-inline-start: var(--spacing-component-2);
632
+ }
633
+
634
+ .ol > li + li {
635
+ margin-block-start: var(--spacing-layout-half);
636
+ }
637
+
638
+ .ol > li > ul {
639
+ margin-block-start: var(--spacing-layout-half);
640
+ }
641
+
642
+ .ul--unstyled {
643
+ list-style: none;
644
+ padding: 0;
645
+ }
646
+
647
+ .ul--unstyled > li {
648
+ margin-inline: 0;
649
+ padding: 0;
650
+ }
651
+
652
+ .ul--line-separators > li + li::before {
653
+ border-block-start: 1px solid var(--gray-20);
400
654
  content: "";
401
- flex-grow: 1;
402
- margin-left: var(--spacing-component-3);
655
+ display: block;
656
+ margin-block: var(--spacing-layout-half);
657
+ width: 100%;
403
658
  }
404
659
 
405
- .small {
406
- font-size: var(--font-size-small);
407
- letter-spacing: var(--letter-spacing-small);
408
- line-height: var(--line-height-small);
660
+ .ul--inline,
661
+ .ul--inline-with-separators,
662
+ .ul--inline-with-line-separators {
663
+ display: inline;
664
+ list-style: none;
665
+ padding-inline: 0 !important;
666
+ padding-left: 0 !important;
409
667
  }
410
668
 
411
- .subtle {
412
- color: var(--text-color-subtle);
669
+ .ul--inline > li,
670
+ .ul--inline-with-separators > li,
671
+ .ul--inline-with-line-separators > li {
672
+ display: inline-block;
673
+ margin-inline-end: var(--spacing-component-3);
674
+ padding: 0 !important;
675
+ }
676
+
677
+ .ul--inline li:last-child,
678
+ .ul--inline-with-separators li:last-child,
679
+ .ul--inline-with-line-separators li:last-child {
680
+ margin-inline-end: 0;
681
+ }
682
+
683
+ .ul--inline > li + li,
684
+ .ul--inline-with-separators > li + li,
685
+ .ul--inline-with-line-separators > li + li {
686
+ margin-block-start: 0;
687
+ }
688
+
689
+ .ul--inline-with-separators li,
690
+ .ul--inline-with-line-separators li {
691
+ margin-inline-end: 0;
692
+ }
693
+
694
+ .ul--inline-with-separators > li::after {
695
+ content: "•";
696
+ margin-inline: var(--spacing-component-2);
697
+ opacity: 0.5;
698
+ }
699
+
700
+ .ul--inline-with-separators > li:last-child::after {
701
+ content: "";
702
+ }
703
+
704
+ .ul--inline-with-line-separators > li::after {
705
+ content: "|";
706
+ margin-inline: var(--spacing-component-2);
707
+ opacity: 0.5;
708
+ }
709
+
710
+ .ul--inline-with-line-separators > li:last-child::after {
711
+ content: "";
712
+ }
713
+
714
+ // ===
715
+
716
+ // Horizontal rule
717
+
718
+ hr {
719
+ --color: currentColor;
720
+
721
+ background-color: var(--color);
722
+ border: 0;
723
+ color: var(--color);
724
+ display: block;
725
+ font-size: 0;
726
+ height: var(--hairline);
727
+ margin-block: var(--spacing-layout-1);
728
+ opacity: 0.4;
729
+ }
730
+
731
+ // ===
732
+
733
+ // Icons
734
+
735
+ .icon {
736
+ -webkit-font-feature-settings: 'liga';
737
+ direction: ltr;
738
+ display: inline-block;
739
+ font-family: 'Material Symbols Rounded';
740
+ font-feature-settings: 'liga';
741
+ font-size: 1.4em;
742
+ font-style: normal;
743
+ font-weight: normal;
744
+ letter-spacing: normal;
745
+ text-transform: none;
746
+ vertical-align: middle;
747
+ white-space: nowrap;
748
+ word-wrap: normal;
413
749
  }
414
750
  `;class ft extends ct{static properties={color:""};static styles=(()=>[dt,mt,s`
415
751
  .label {
@@ -1251,99 +1587,6 @@
1251
1587
  .logo img {
1252
1588
  object-fit: contain;
1253
1589
  }
1254
-
1255
- /* --- */
1256
-
1257
- /* Theme: Compact Card */
1258
-
1259
- .card--compact {
1260
- --padding: var(--spacing-component-3);
1261
- }
1262
-
1263
- .card--compact .title {
1264
- font-size: var(--font-size-h4);
1265
- line-height: var(--line-height-h4);
1266
- }
1267
-
1268
- .card--compact .action-label {
1269
- padding-block-start: 0;
1270
- }
1271
-
1272
- /* --- */
1273
-
1274
- /* Theme: Horizontal Card */
1275
-
1276
- @media (min-width: 768px) {
1277
- .card--horizontal,
1278
- a.card--horizontal {
1279
- align-items: stretch;
1280
- flex-direction: row;
1281
- }
1282
-
1283
- .card--horizontal .visual {
1284
- aspect-ratio: initial;
1285
- height: auto;
1286
- flex: 0 0 50%;
1287
- }
1288
-
1289
- .card--horizontal .logo {
1290
- border-block-end: 0;
1291
- border-inline-end: 1px solid var(--gray-20);
1292
- }
1293
- }
1294
-
1295
- /* --- */
1296
-
1297
- /* Theme: Horizontal Compact Card */
1298
-
1299
- @media (min-width: 768px) {
1300
- .card--horizontal-compact,
1301
- a.card--horizontal-compact {
1302
- align-items: stretch;
1303
- flex-direction: row;
1304
- }
1305
-
1306
- .card--horizontal-compact .visual {
1307
- aspect-ratio: initial;
1308
- flex: 0 0 34%;
1309
- height: auto;
1310
- position: relative;
1311
- }
1312
-
1313
- .card--horizontal-compact .image picture {
1314
- position: absolute;
1315
- height: 100%;
1316
- width: 100%;
1317
- }
1318
-
1319
- .card--horizontal-compact .logo {
1320
- border-block-end: 0;
1321
- border-right: 1px solid var(--gray-20);
1322
- padding: var(--spacing-component-4);
1323
- }
1324
- }
1325
-
1326
- .card--horizontal-compact,
1327
- a.card--horizontal-compact {
1328
- --padding: var(--spacing-component-3);
1329
- }
1330
-
1331
- .card--horizontal-compact .body {
1332
- gap: var(--spacing-component-2);
1333
- }
1334
-
1335
- .card--horizontal-compact .header {
1336
- margin-block-end: var(--spacing-component-2);
1337
- }
1338
-
1339
- .card--horizontal-compact .title {
1340
- font-size: var(--font-size-h4);
1341
- line-height: var(--line-height-h4);
1342
- }
1343
-
1344
- .card--horizontal-compact .action-label {
1345
- padding-block-start: var(--spacing-component-2);
1346
- }
1347
1590
  `])();visualTemplate(){let t;return"image"===this.visualType?t=D`
1348
1591
  <div class="visual image">
1349
1592
  <div class="fallback-image">
@@ -1407,11 +1650,11 @@
1407
1650
  `:K}
1408
1651
  </div>
1409
1652
  <div class="body">
1410
- ${this.text?D` <div class="small" .innerHTML="${this.text}"></div> `:K}
1653
+ ${this.text?D` <div class="small" .innerHTML=${this.text}></div> `:K}
1411
1654
  ${this.metaText?D`
1412
1655
  <div
1413
1656
  class="meta-text small"
1414
- .innerHTML="${this.metaText}"
1657
+ .innerHTML=${this.metaText}
1415
1658
  ></div>
1416
1659
  `:K}
1417
1660
  ${this.actionLabel?D` <div class="action-label">${this.actionLabel}</div> `:K}
@@ -1755,14 +1998,14 @@
1755
1998
  background-color: var(--blue-40);
1756
1999
  }
1757
2000
  }
1758
- `])();handleSlotchange(t){const e=t.target.assignedNodes({flatten:!0}),i=this.shadowRoot.querySelector("ul"),o=[];e.forEach(t=>{"UL"===t.tagName&&t.querySelectorAll("li").forEach(t=>{i.appendChild(t.cloneNode(!0));const e=t.querySelector("a")?.getAttribute("href");e&&e.startsWith("#")&&o.push(e.substring(1))})}),window.addEventListener("scroll",()=>this.updateActiveNav(o))}updateActiveNav(t){const e=window.scrollY;let i=null;if(t.forEach(t=>{const o=document.getElementById(t);o&&o.offsetTop<=e+256&&(i=t)}),this.shadowRoot.querySelectorAll("li a").forEach(t=>{t.classList.remove("is-active")}),i){const t=this.shadowRoot.querySelector(`li a[href*="#${i}"]`);t&&t.classList.add("is-active")}}render(){return D`
2001
+ `])();handleSlotchange(t){const e=t.target.assignedNodes({flatten:!0}),i=this.shadowRoot.querySelector("ul"),a=[];e.forEach(t=>{"UL"===t.tagName&&t.querySelectorAll("li").forEach(t=>{i.appendChild(t.cloneNode(!0));const e=t.querySelector("a")?.getAttribute("href");e&&e.startsWith("#")&&a.push(e.substring(1))})}),window.addEventListener("scroll",()=>this.updateActiveNav(a))}updateActiveNav(t){const e=window.scrollY;let i=null;if(t.forEach(t=>{const a=document.getElementById(t);a&&a.offsetTop<=e+256&&(i=t)}),this.shadowRoot.querySelectorAll("li a").forEach(t=>{t.classList.remove("is-active")}),i){const t=this.shadowRoot.querySelector(`li a[href*="#${i}"]`);t&&t.classList.add("is-active")}}render(){return D`
1759
2002
  <slot @slotchange=${this.handleSlotchange}></slot>
1760
2003
  <nav>
1761
2004
  <ul>
1762
2005
  <li><strong>On this page: &ensp;</strong></li>
1763
2006
  </ul>
1764
2007
  </nav>
1765
- `}}customElements.get("cfa-page-nav")||customElements.define("cfa-page-nav",Ut);class Mt extends ct{static properties={previousTitle:{},previousUrl:{},nextTitle:{},nextUrl:{}};static styles=(()=>[dt,mt,gt,s`
2008
+ `}}customElements.get("cfa-page-nav")||customElements.define("cfa-page-nav",Ut);class Mt extends ct{static properties={previousTitle:{},previousUrl:{},nextTitle:{},nextUrl:{}};static styles=(()=>[dt,mt,ut,s`
1766
2009
  :host {
1767
2010
  display: block;
1768
2011
  }
@@ -1827,7 +2070,7 @@
1827
2070
  `:""}
1828
2071
  </div>
1829
2072
  </nav>
1830
- `}}customElements.get("cfa-pager")||customElements.define("cfa-pager",Mt);class It extends ct{static properties=(()=>({page:{type:Number},totalPages:{type:Number},previousLabel:{},nextLabel:{}}))();static styles=(()=>[dt,gt,s`
2073
+ `}}customElements.get("cfa-pager")||customElements.define("cfa-pager",Mt);class It extends ct{static properties=(()=>({page:{type:Number},totalPages:{type:Number},previousLabel:{},nextLabel:{}}))();static styles=(()=>[dt,ut,s`
1831
2074
  :host {
1832
2075
  display: block;
1833
2076
  }
@@ -2295,7 +2538,7 @@
2295
2538
  color: var(--black);
2296
2539
  font-weight: bold;
2297
2540
  }
2298
- `])();constructor(){super(),this.active=!1,this.panelId=""}firstUpdated(){this.addEventListener("keydown",this._onKeyDown)}_onKeyDown(t){const e=Array.from(this.parentElement.querySelectorAll("cfa-tab")),i=e.indexOf(this);let o;switch(t.key){case"ArrowLeft":o=(i-1+e.length)%e.length,e[o].shadowRoot.querySelector("button").focus();break;case"ArrowRight":o=(i+1)%e.length,e[o].shadowRoot.querySelector("button").focus();break;case"Home":e[0].shadowRoot.querySelector("button").focus();break;case"End":e[e.length-1].shadowRoot.querySelector("button").focus()}}render(){return D`
2541
+ `])();constructor(){super(),this.active=!1,this.panelId=""}firstUpdated(){this.addEventListener("keydown",this._onKeyDown)}_onKeyDown(t){const e=Array.from(this.parentElement.querySelectorAll("cfa-tab")),i=e.indexOf(this);let a;switch(t.key){case"ArrowLeft":a=(i-1+e.length)%e.length,e[a].shadowRoot.querySelector("button").focus();break;case"ArrowRight":a=(i+1)%e.length,e[a].shadowRoot.querySelector("button").focus();break;case"Home":e[0].shadowRoot.querySelector("button").focus();break;case"End":e[e.length-1].shadowRoot.querySelector("button").focus()}}render(){return D`
2299
2542
  <button
2300
2543
  role="tab"
2301
2544
  aria-selected="${this.active?"true":"false"}"
@@ -2305,7 +2548,7 @@
2305
2548
  >
2306
2549
  <slot></slot>
2307
2550
  </button>
2308
- `}}customElements.get("cfa-tab")||customElements.define("cfa-tab",Vt);class qt extends ct{static properties={};static styles=(()=>[dt,gt,s`
2551
+ `}}customElements.get("cfa-tab")||customElements.define("cfa-tab",Vt);class qt extends ct{static properties={};static styles=(()=>[dt,ut,s`
2309
2552
  :host {
2310
2553
  display: block;
2311
2554
  width: calc(100% + var(--outer-margin));
@@ -2627,7 +2870,7 @@
2627
2870
  min-width: calc(var(--carousel-dot-size) * 0.8);
2628
2871
  }
2629
2872
  }
2630
- `])();constructor(){super(),this.currentPage=0,this.totalSlides=0,this.progressPercentage=0,this.isPaused=!0,this.prefersReducedMotion=window.matchMedia("(prefers-reduced-motion: reduce)").matches,this.itemsPerView=Dt.ITEMS_PER_VIEW_DESKTOP,this.autoPlay=!0,this.autoPlayDuration=Math.max(100,Dt.AUTOPLAY_DURATION),this.autoPlayTimer=null,this.autoPlayTimeout=null,this.touchStartX=null,this.touchEndX=null,this._initialized=!1,this._resizeTimerId=null,this._mouseEnterListener=null,this._mouseLeaveListener=null}connectedCallback(){super.connectedCallback();const t=this.getAttribute("items-per-view");if(null!==t){const e=parseInt(t,10);isNaN(e)||(this.itemsPerView=e)}this.style.setProperty("--items-per-view",this.itemsPerView),this.addEventListener("keydown",t=>this._handleKeydown(t)),this.addEventListener("touchstart",t=>this._handleTouchStart(t),!1),this.addEventListener("touchend",t=>this._handleTouchEnd(t),!1),this._resizeListener=()=>{this._resizeTimerId&&clearTimeout(this._resizeTimerId),this._resizeTimerId=setTimeout(()=>{this.updateItemsPerView(),this.updateCarouselHeight()},150)},window.addEventListener("resize",this._resizeListener)}disconnectedCallback(){super.disconnectedCallback(),this.stopAutoPlay(),this._resizeListener&&window.removeEventListener("resize",this._resizeListener),this._resizeTimerId&&clearTimeout(this._resizeTimerId);const t=this.shadowRoot?.querySelector(".carousel-slides");t&&this._mouseEnterListener&&this._mouseLeaveListener&&(t.removeEventListener("mouseenter",this._mouseEnterListener),t.removeEventListener("mouseleave",this._mouseLeaveListener))}updated(t){t.has("itemsPerView")&&this.style.setProperty("--items-per-view",this.itemsPerView),t.has("currentPage")&&this.updateItemVisibility()}firstUpdated(){const t=this.shadowRoot.querySelector("slot"),e=this.shadowRoot.querySelector(".carousel-slides");t&&!this._slotChangeSetup&&(this._slotChangeSetup=!0,t.addEventListener("slotchange",()=>{this._slotChangeTimeout&&clearTimeout(this._slotChangeTimeout),this._slotChangeTimeout=setTimeout(()=>{this._initialized||this._initializeCarousel()},50)})),e&&!this._mouseEnterListener&&(this._mouseEnterListener=()=>{this.stopAutoPlay()},this._mouseLeaveListener=()=>{this.isPaused||this._scheduleNextPage()},e.addEventListener("mouseenter",this._mouseEnterListener),e.addEventListener("mouseleave",this._mouseLeaveListener))}_initializeCarousel(){if(this._initialized)return;const t=this.shadowRoot.querySelector("slot");if(!t)return;const e=t.assignedElements();0!==e.length&&(this._initialized=!0,this.totalSlides=e.length,this.updateItemsPerView(),this.updateItemVisibility(),this.startAutoPlay(),this._waitForImages(e,5e3).then(()=>{this.updateCarouselHeight()}))}_waitForImages(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3e3;return Promise.race([Promise.all(Array.from(t).map(t=>Promise.all(Array.from(t.querySelectorAll("img")).map(t=>t.complete?Promise.resolve():new Promise(e=>{t.addEventListener("load",e,{once:!0}),t.addEventListener("error",e,{once:!0})}))))),new Promise((t,i)=>setTimeout(()=>i(new Error("Image load timeout")),e))]).catch(()=>Promise.resolve())}get totalPages(){return Math.ceil(this.totalSlides/this.itemsPerView)}updateItemsPerView(){if(this.hasAttribute("items-per-view"))return;const t=window.innerWidth>=Dt.DESKTOP_BREAKPOINT?Dt.ITEMS_PER_VIEW_DESKTOP:Dt.ITEMS_PER_VIEW_MOBILE;t!==this.itemsPerView&&(this.itemsPerView=t,this.style.setProperty("--items-per-view",this.itemsPerView),this.currentPage>=this.totalPages&&(this.currentPage=0),this.requestUpdate())}updateItemVisibility(){const t=this.shadowRoot.querySelector("slot");if(!t)return;const e=t.assignedElements();if(0===e.length)return;const i=this.currentPage*this.itemsPerView,o=i+this.itemsPerView;e.forEach((t,e)=>{e>=i&&e<o?t.setAttribute("data-slide-active",""):t.removeAttribute("data-slide-active")}),this.updateCarouselHeight()}updateCarouselHeight(){const t=this.shadowRoot.querySelector("slot"),e=this.shadowRoot.querySelector(".carousel-slides");if(!t||!e)return;const i=t.assignedElements();if(0===i.length)return;const o=this.currentPage*this.itemsPerView,a=o+this.itemsPerView;requestAnimationFrame(()=>{requestAnimationFrame(()=>{setTimeout(()=>{let t=0;for(let e=o;e<a&&e<i.length;e++){const o=i[e].offsetHeight;t=Math.max(t,o)}const s=Math.max(t,Dt.SHADOW_SPACE);e.style.height=s+"px"},0)})})}startAutoPlay(){this.autoPlay&&!this.prefersReducedMotion&&0!==this.totalSlides?(this.isPaused=!1,this.progressPercentage=0,this._scheduleNextPage()):this.isPaused=!0}play(){this.prefersReducedMotion||this.startAutoPlay()}pause(){this.isPaused=!0,this.stopAutoPlay()}stopAutoPlay(){this.autoPlayTimer&&(clearInterval(this.autoPlayTimer),this.autoPlayTimer=null),this.autoPlayTimeout&&(clearTimeout(this.autoPlayTimeout),this.autoPlayTimeout=null)}_scheduleNextPage(){this.stopAutoPlay();const t=100/(this.autoPlayDuration/Dt.PROGRESS_UPDATE_INTERVAL);this.autoPlayTimer=setInterval(()=>{this.progressPercentage=Math.min(100,this.progressPercentage+t)},Dt.PROGRESS_UPDATE_INTERVAL),this.autoPlayTimeout=setTimeout(()=>{this.isPaused||(this.nextPage(),this.startAutoPlay())},this.autoPlayDuration)}nextPage(){this.currentPage=(this.currentPage+1)%this.totalPages,this.progressPercentage=0,this.stopAutoPlay(),this.requestUpdate(),this.play()}previousPage(){this.currentPage=(this.currentPage-1+this.totalPages)%this.totalPages,this.progressPercentage=0,this.stopAutoPlay(),this.requestUpdate(),this.play()}goToPage(t){t>=0&&t<this.totalPages&&t!==this.currentPage&&(this.currentPage=t,this.progressPercentage=0,this.stopAutoPlay(),this.requestUpdate(),this.play())}_handleKeydown(t){"ArrowRight"===t.key?(t.preventDefault(),this.nextPage(),this.pause()):"ArrowLeft"===t.key&&(t.preventDefault(),this.previousPage(),this.pause())}_handleTouchStart(t){t.changedTouches&&t.changedTouches.length>0&&(this.touchStartX=t.changedTouches[0].screenX)}_handleTouchEnd(t){t.changedTouches&&t.changedTouches.length>0&&(this.touchEndX=t.changedTouches[0].screenX,this._handleSwipe())}_handleSwipe(){if(null===this.touchStartX||null===this.touchEndX)return;const t=this.touchStartX-this.touchEndX;Math.abs(t)>Dt.SWIPE_THRESHOLD&&(t>0?(this.nextPage(),this.pause()):(this.previousPage(),this.pause()))}render(){return D`
2873
+ `])();constructor(){super(),this.currentPage=0,this.totalSlides=0,this.progressPercentage=0,this.isPaused=!0,this.prefersReducedMotion=window.matchMedia("(prefers-reduced-motion: reduce)").matches,this.itemsPerView=Dt.ITEMS_PER_VIEW_DESKTOP,this.autoPlay=!0,this.autoPlayDuration=Math.max(100,Dt.AUTOPLAY_DURATION),this.autoPlayTimer=null,this.autoPlayTimeout=null,this.touchStartX=null,this.touchEndX=null,this._initialized=!1,this._resizeTimerId=null,this._mouseEnterListener=null,this._mouseLeaveListener=null}connectedCallback(){super.connectedCallback();const t=this.getAttribute("items-per-view");if(null!==t){const e=parseInt(t,10);isNaN(e)||(this.itemsPerView=e)}this.style.setProperty("--items-per-view",this.itemsPerView),this.addEventListener("keydown",t=>this._handleKeydown(t)),this.addEventListener("touchstart",t=>this._handleTouchStart(t),!1),this.addEventListener("touchend",t=>this._handleTouchEnd(t),!1),this._resizeListener=()=>{this._resizeTimerId&&clearTimeout(this._resizeTimerId),this._resizeTimerId=setTimeout(()=>{this.updateItemsPerView(),this.updateCarouselHeight()},150)},window.addEventListener("resize",this._resizeListener)}disconnectedCallback(){super.disconnectedCallback(),this.stopAutoPlay(),this._resizeListener&&window.removeEventListener("resize",this._resizeListener),this._resizeTimerId&&clearTimeout(this._resizeTimerId);const t=this.shadowRoot?.querySelector(".carousel-slides");t&&this._mouseEnterListener&&this._mouseLeaveListener&&(t.removeEventListener("mouseenter",this._mouseEnterListener),t.removeEventListener("mouseleave",this._mouseLeaveListener))}updated(t){t.has("itemsPerView")&&this.style.setProperty("--items-per-view",this.itemsPerView),t.has("currentPage")&&this.updateItemVisibility()}firstUpdated(){const t=this.shadowRoot.querySelector("slot"),e=this.shadowRoot.querySelector(".carousel-slides");t&&!this._slotChangeSetup&&(this._slotChangeSetup=!0,t.addEventListener("slotchange",()=>{this._slotChangeTimeout&&clearTimeout(this._slotChangeTimeout),this._slotChangeTimeout=setTimeout(()=>{this._initialized||this._initializeCarousel()},50)})),e&&!this._mouseEnterListener&&(this._mouseEnterListener=()=>{this.stopAutoPlay()},this._mouseLeaveListener=()=>{this.isPaused||this._scheduleNextPage()},e.addEventListener("mouseenter",this._mouseEnterListener),e.addEventListener("mouseleave",this._mouseLeaveListener))}_initializeCarousel(){if(this._initialized)return;const t=this.shadowRoot.querySelector("slot");if(!t)return;const e=t.assignedElements();0!==e.length&&(this._initialized=!0,this.totalSlides=e.length,this.updateItemsPerView(),this.updateItemVisibility(),this.startAutoPlay(),this._waitForImages(e,5e3).then(()=>{this.updateCarouselHeight()}))}_waitForImages(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3e3;return Promise.race([Promise.all(Array.from(t).map(t=>Promise.all(Array.from(t.querySelectorAll("img")).map(t=>t.complete?Promise.resolve():new Promise(e=>{t.addEventListener("load",e,{once:!0}),t.addEventListener("error",e,{once:!0})}))))),new Promise((t,i)=>setTimeout(()=>i(new Error("Image load timeout")),e))]).catch(()=>Promise.resolve())}get totalPages(){return Math.ceil(this.totalSlides/this.itemsPerView)}updateItemsPerView(){if(this.hasAttribute("items-per-view"))return;const t=window.innerWidth>=Dt.DESKTOP_BREAKPOINT?Dt.ITEMS_PER_VIEW_DESKTOP:Dt.ITEMS_PER_VIEW_MOBILE;t!==this.itemsPerView&&(this.itemsPerView=t,this.style.setProperty("--items-per-view",this.itemsPerView),this.currentPage>=this.totalPages&&(this.currentPage=0),this.requestUpdate())}updateItemVisibility(){const t=this.shadowRoot.querySelector("slot");if(!t)return;const e=t.assignedElements();if(0===e.length)return;const i=this.currentPage*this.itemsPerView,a=i+this.itemsPerView;e.forEach((t,e)=>{e>=i&&e<a?t.setAttribute("data-slide-active",""):t.removeAttribute("data-slide-active")}),this.updateCarouselHeight()}updateCarouselHeight(){const t=this.shadowRoot.querySelector("slot"),e=this.shadowRoot.querySelector(".carousel-slides");if(!t||!e)return;const i=t.assignedElements();if(0===i.length)return;const a=this.currentPage*this.itemsPerView,o=a+this.itemsPerView;requestAnimationFrame(()=>{requestAnimationFrame(()=>{setTimeout(()=>{let t=0;for(let e=a;e<o&&e<i.length;e++){const a=i[e].offsetHeight;t=Math.max(t,a)}const s=Math.max(t,Dt.SHADOW_SPACE);e.style.height=s+"px"},0)})})}startAutoPlay(){this.autoPlay&&!this.prefersReducedMotion&&0!==this.totalSlides?(this.isPaused=!1,this.progressPercentage=0,this._scheduleNextPage()):this.isPaused=!0}play(){this.prefersReducedMotion||this.startAutoPlay()}pause(){this.isPaused=!0,this.stopAutoPlay()}stopAutoPlay(){this.autoPlayTimer&&(clearInterval(this.autoPlayTimer),this.autoPlayTimer=null),this.autoPlayTimeout&&(clearTimeout(this.autoPlayTimeout),this.autoPlayTimeout=null)}_scheduleNextPage(){this.stopAutoPlay();const t=100/(this.autoPlayDuration/Dt.PROGRESS_UPDATE_INTERVAL);this.autoPlayTimer=setInterval(()=>{this.progressPercentage=Math.min(100,this.progressPercentage+t)},Dt.PROGRESS_UPDATE_INTERVAL),this.autoPlayTimeout=setTimeout(()=>{this.isPaused||(this.nextPage(),this.startAutoPlay())},this.autoPlayDuration)}nextPage(){this.currentPage=(this.currentPage+1)%this.totalPages,this.progressPercentage=0,this.stopAutoPlay(),this.requestUpdate(),this.play()}previousPage(){this.currentPage=(this.currentPage-1+this.totalPages)%this.totalPages,this.progressPercentage=0,this.stopAutoPlay(),this.requestUpdate(),this.play()}goToPage(t){t>=0&&t<this.totalPages&&t!==this.currentPage&&(this.currentPage=t,this.progressPercentage=0,this.stopAutoPlay(),this.requestUpdate(),this.play())}_handleKeydown(t){"ArrowRight"===t.key?(t.preventDefault(),this.nextPage(),this.pause()):"ArrowLeft"===t.key&&(t.preventDefault(),this.previousPage(),this.pause())}_handleTouchStart(t){t.changedTouches&&t.changedTouches.length>0&&(this.touchStartX=t.changedTouches[0].screenX)}_handleTouchEnd(t){t.changedTouches&&t.changedTouches.length>0&&(this.touchEndX=t.changedTouches[0].screenX,this._handleSwipe())}_handleSwipe(){if(null===this.touchStartX||null===this.touchEndX)return;const t=this.touchStartX-this.touchEndX;Math.abs(t)>Dt.SWIPE_THRESHOLD&&(t>0?(this.nextPage(),this.pause()):(this.previousPage(),this.pause()))}render(){return D`
2631
2874
  <div
2632
2875
  class="carousel-container"
2633
2876
  role="region"