@sbb-esta/lyne-elements-dev 5.13.2-dev.1794463730 → 5.13.2-dev.1794477486

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/alert.pure.js CHANGED
@@ -1,11 +1,11 @@
1
- import{__esDecorate as e,__runInitializers as t}from"tslib";import{html as n,nothing as r,unsafeCSS as i}from"lit";import{property as a,state as o}from"lit/decorators.js";import{html as s,unsafeStatic as c}from"lit/static-html.js";import{SbbDarkModeController as l,SbbElement as u,SbbLanguageController as d,SbbOpenCloseBaseElement as f,SbbReadonlyMixin as p,forceType as m,i18nCloseAlert as h,isEventPrevented as g,isZeroAnimationDuration as _,screenReaderOnlyStyles as v}from"./core.js";import{SbbTransparentButtonElement as y}from"./button.pure.js";import{SbbDividerElement as b}from"./divider.pure.js";import{SbbIconNameMixin as x}from"./icon.pure.js";var S=`:host{gap:var(--sbb-alert-group-gap);flex-direction:column;display:flex}:host(:focus-visible:not(:is(:state(empty),[state--empty]))){outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) var(--sbb-focus-outline-style,solid) var(--sbb-focus-outline-width);border-radius:var(--sbb-alert-group-border-radius)}
2
- `;let C=(()=>{let n=u,l,d=[],f=[],p,h=[],_=[],y,b=[],x=[],C,w=[],T=[];return class extends n{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(n[Symbol.metadata]??null):void 0;l=[a({reflect:!0})],p=[m(),a({attribute:`accessibility-title`})],y=[a({attribute:`accessibility-title-level`})],C=[o()],e(this,null,l,{kind:`accessor`,name:`role`,static:!1,private:!1,access:{has:e=>`role`in e,get:e=>e.role,set:(e,t)=>{e.role=t}},metadata:t},d,f),e(this,null,p,{kind:`accessor`,name:`accessibilityTitle`,static:!1,private:!1,access:{has:e=>`accessibilityTitle`in e,get:e=>e.accessibilityTitle,set:(e,t)=>{e.accessibilityTitle=t}},metadata:t},h,_),e(this,null,y,{kind:`accessor`,name:`accessibilityTitleLevel`,static:!1,private:!1,access:{has:e=>`accessibilityTitleLevel`in e,get:e=>e.accessibilityTitleLevel,set:(e,t)=>{e.accessibilityTitleLevel=t}},metadata:t},b,x),e(this,null,C,{kind:`accessor`,name:`_hasAlerts`,static:!1,private:!1,access:{has:e=>`_hasAlerts`in e,get:e=>e._hasAlerts,set:(e,t)=>{e._hasAlerts=t}},metadata:t},w,T),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.elementName=`sbb-alert-group`}static{this.styles=[v,i(S)]}static{this.events={empty:`empty`}}#e=t(this,d,`status`);get role(){return this.#e}set role(e){this.#e=e}#t=(t(this,f),t(this,h,``));get accessibilityTitle(){return this.#t}set accessibilityTitle(e){this.#t=e}#n=(t(this,_),t(this,b,`2`));get accessibilityTitleLevel(){return this.#n}set accessibilityTitleLevel(e){this.#n=e}#r=(t(this,x),t(this,w,!1));get _hasAlerts(){return this.#r}set _hasAlerts(e){this.#r=e}constructor(){super(),t(this,T),this.addEventListener?.(`close`,async e=>{await g(e)||this._alertClosed(e)},{capture:!0})}_alertClosed(e){let t=e.target;document.activeElement===t&&(this.tabIndex=0,this.focus(),this.addEventListener(`blur`,()=>this.removeAttribute(`tabindex`),{once:!0}))}_slotChanged(e){let t=this._hasAlerts;this._hasAlerts=e.target.assignedElements().filter(e=>e instanceof Element&&e.localName===`sbb-alert`).length>0,!this._hasAlerts&&t&&this.dispatchEvent(new Event(`empty`,{composed:!0,bubbles:!0})),this.toggleState(`empty`,!this._hasAlerts)}render(){let e=`h${this.accessibilityTitleLevel}`;return s`
1
+ import{__esDecorate as e,__runInitializers as t}from"tslib";import{html as n,nothing as r,unsafeCSS as i}from"lit";import{property as a,state as o}from"lit/decorators.js";import{html as s,unsafeStatic as c}from"lit/static-html.js";import{SbbDarkModeController as l,SbbElement as u,SbbLanguageController as d,SbbOpenCloseBaseElement as f,SbbReadonlyMixin as p,SbbTemporaryFocusController as m,forceType as h,i18nCloseAlert as g,isEventPrevented as _,isZeroAnimationDuration as v,screenReaderOnlyStyles as y}from"./core.js";import{SbbTransparentButtonElement as b}from"./button.pure.js";import{SbbDividerElement as x}from"./divider.pure.js";import{SbbIconNameMixin as S}from"./icon.pure.js";var C=`:host{gap:var(--sbb-alert-group-gap);flex-direction:column;display:flex}:host(:focus-visible:not(:is(:state(empty),[state--empty]))){outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) var(--sbb-focus-outline-style,solid) var(--sbb-focus-outline-width);border-radius:var(--sbb-alert-group-border-radius)}
2
+ `;let w=(()=>{let n=u,l,d=[],f=[],p,g=[],v=[],b,x=[],S=[],w,T=[],E=[];return class extends n{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(n[Symbol.metadata]??null):void 0;l=[a({reflect:!0})],p=[h(),a({attribute:`accessibility-title`})],b=[a({attribute:`accessibility-title-level`})],w=[o()],e(this,null,l,{kind:`accessor`,name:`role`,static:!1,private:!1,access:{has:e=>`role`in e,get:e=>e.role,set:(e,t)=>{e.role=t}},metadata:t},d,f),e(this,null,p,{kind:`accessor`,name:`accessibilityTitle`,static:!1,private:!1,access:{has:e=>`accessibilityTitle`in e,get:e=>e.accessibilityTitle,set:(e,t)=>{e.accessibilityTitle=t}},metadata:t},g,v),e(this,null,b,{kind:`accessor`,name:`accessibilityTitleLevel`,static:!1,private:!1,access:{has:e=>`accessibilityTitleLevel`in e,get:e=>e.accessibilityTitleLevel,set:(e,t)=>{e.accessibilityTitleLevel=t}},metadata:t},x,S),e(this,null,w,{kind:`accessor`,name:`_hasAlerts`,static:!1,private:!1,access:{has:e=>`_hasAlerts`in e,get:e=>e._hasAlerts,set:(e,t)=>{e._hasAlerts=t}},metadata:t},T,E),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.elementName=`sbb-alert-group`}static{this.styles=[y,i(C)]}static{this.events={empty:`empty`}}#e=t(this,d,`status`);get role(){return this.#e}set role(e){this.#e=e}#t=(t(this,f),t(this,g,``));get accessibilityTitle(){return this.#t}set accessibilityTitle(e){this.#t=e}#n=(t(this,v),t(this,x,`2`));get accessibilityTitleLevel(){return this.#n}set accessibilityTitleLevel(e){this.#n=e}#r=(t(this,S),t(this,T,!1));get _hasAlerts(){return this.#r}set _hasAlerts(e){this.#r=e}constructor(){super(),t(this,E),this.addEventListener?.(`close`,async e=>{await _(e)||this._alertClosed(e)},{capture:!0})}_alertClosed(e){let t=e.target;document.activeElement===t&&(this.hasAttribute(`tabindex`)||this.addController(new m(this)),this.focus())}_slotChanged(e){let t=this._hasAlerts;this._hasAlerts=e.target.assignedElements().filter(e=>e instanceof Element&&e.localName===`sbb-alert`).length>0,!this._hasAlerts&&t&&this.dispatchEvent(new Event(`empty`,{composed:!0,bubbles:!0})),this.toggleState(`empty`,!this._hasAlerts)}render(){let e=`h${this.accessibilityTitleLevel}`;return s`
3
3
  ${this._hasAlerts?s`<${c(e)} class="sbb-screen-reader-only">
4
4
  <slot name="accessibility-title">${this.accessibilityTitle}</slot>
5
5
  </${c(e)}>`:r}
6
6
  <slot @slotchange=${e=>this._slotChanged(e)}></slot>
7
- `}}})();var w=`:host{--sbb-alert-animation-duration:var(--sbb-disable-animation-duration,var(--sbb-animation-duration-6x));opacity:0;border-radius:var(--sbb-alert-forced-color-border-radius);outline:var(--sbb-alert-outline);grid-template-rows:0fr;display:grid}:host(:is(:state(state-opening),[state--state-opening]):not([animation=open],[animation=all])),:host(:is(:state(state-closing),[state--state-closing]):not([animation=close],[animation=all])){--sbb-disable-animation-duration:0s}:host([size=s]){--sbb-alert-gap:var(--sbb-alert-gap-s);--sbb-alert-close-icon-margin:var(--sbb-alert-close-icon-margin-s);--sbb-alert-icon-padding-block:var(--sbb-alert-icon-padding-block-s)}:host([size=m]){--sbb-alert-gap:var(--sbb-alert-gap-m);--sbb-alert-close-icon-margin:var(--sbb-alert-close-icon-margin-m);--sbb-alert-icon-padding-block:var(--sbb-alert-icon-padding-block-m)}:host([size=l]){--sbb-alert-gap:var(--sbb-alert-gap-l);--sbb-alert-close-icon-margin:var(--sbb-alert-close-icon-margin-l);--sbb-alert-icon-padding-block:var(--sbb-alert-icon-padding-block-l);--sbb-alert-icon-size:var(--sbb-alert-icon-size-l);--sbb-alert-title-margin-block:0 var(--sbb-spacing-fixed-1x)}:host(:not(:is(:state(dark),[state--dark]))){--sbb-focus-outline-color:var(--sbb-focus-outline-color-dark)}:host(:is(:is(:state(state-opened),[state--state-opened]),:is(:state(state-closing),[state--state-closing]))){opacity:1;grid-template-rows:1fr}:host(:is(:state(state-opening),[state--state-opening])){animation-name:open,open-opacity;animation-fill-mode:forwards;animation-duration:var(--sbb-alert-animation-duration);animation-timing-function:var(--sbb-alert-timing-function);animation-delay:0s, var(--sbb-alert-animation-duration)}:host(:is(:state(state-closing),[state--state-closing])){animation-name:close-opacity,close;animation-fill-mode:forwards;animation-duration:var(--sbb-alert-animation-duration);animation-timing-function:var(--sbb-alert-timing-function);animation-delay:0s, var(--sbb-disable-animation-duration,var(--sbb-animation-duration-2x))}.sbb-alert__transition-wrapper{overflow:hidden}.sbb-alert{grid-template-columns:var(--sbb-alert-grid-template-columns);align-items:center;gap:var(--sbb-alert-gap);min-width:fit-content;padding:var(--sbb-alert-padding);color:var(--sbb-alert-color);background-color:var(--sbb-alert-background-color);border-radius:var(--sbb-alert-border-radius);font-size:var(--sbb-alert-font-size);letter-spacing:var(--sbb-letter-spacing-text);line-height:var(--sbb-typo-line-height-text);display:grid;overflow:hidden}.sbb-alert__icon{min-width:var(--sbb-alert-icon-size);padding-block:var(--sbb-alert-icon-padding-block);--sbb-icon-svg-width:var(--sbb-alert-icon-size);--sbb-icon-svg-height:var(--sbb-alert-icon-size);align-self:start;align-items:center;min-height:1lh;display:flex}@media (width>=37.5rem){:host(:is(:state(slotted-title),[state--slotted-title])) .sbb-alert__icon{padding-block:var(--sbb-spacing-fixed-1x)}}.sbb-alert__content{color-scheme:light only;order:3;grid-column:1/3}@media (width>=37.5rem){.sbb-alert__content{order:initial;grid-column-start:initial;grid-column-end:initial}}.sbb-alert__content-slot{margin:0;padding:0;display:inline}.sbb-alert__close-button-wrapper{color-scheme:light only;justify-content:flex-end;align-items:center;height:100%;display:flex}.sbb-alert__close-button{margin-block:calc(-1 * var(--sbb-spacing-fixed-8x))}@media (width>=37.5rem){.sbb-alert__close-button{margin-inline-start:var(--sbb-alert-close-icon-margin)}}.sbb-alert__close-button-divider{display:var(--sbb-alert-close-button-divider-display,none);height:calc(100% - var(--sbb-spacing-fixed-1x) * 2)}@keyframes open{0%{grid-template-rows:0fr}to{grid-template-rows:1fr}}@keyframes open-opacity{0%{opacity:0}to{opacity:1}}@keyframes close{0%{grid-template-rows:1fr}to{grid-template-rows:0fr}}@keyframes close-opacity{0%{opacity:1}to{opacity:0}}::slotted(sbb-title){margin-block:var(--sbb-alert-title-margin-block)}
8
- `;let T=(()=>{let o=x(p(f)),s,c=[],u=[],m,g=[],v=[];return class extends o{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(o[Symbol.metadata]??null):void 0;s=[a({reflect:!0})],m=[a({reflect:!0})],e(this,null,s,{kind:`accessor`,name:`size`,static:!1,private:!1,access:{has:e=>`size`in e,get:e=>e.size,set:(e,t)=>{e.size=t}},metadata:t},c,u),e(this,null,m,{kind:`accessor`,name:`animation`,static:!1,private:!1,access:{has:e=>`animation`in e,get:e=>e.animation,set:(e,t)=>{e.animation=t}},metadata:t},g,v),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.elementName=`sbb-alert`}static{this.elementDependencies=[y,b]}static{this.styles=[i(w)]}static{this.events={beforeopen:`beforeopen`,open:`open`,beforeclose:`beforeclose`,close:`close`}}#e;get size(){return this.#e}set size(e){this.#e=e}#t;get animation(){return this.#t}set animation(e){this.#t=e}constructor(){super(),this.#e=t(this,c,null),this.#t=(t(this,u),t(this,g,`all`)),this._language=(t(this,v),new d(this)),this._darkModeController=new l(this,()=>{this._syncLinks(),this._configureTitle(),this.requestUpdate()}),this.addEventListener(`animationend`,e=>this._onAnimationEnd(e))}open(){this.state=`opening`,this.dispatchBeforeOpenEvent()&&this._isZeroAnimationDuration()&&this._handleOpening()}close(){this.state===`opened`&&this.dispatchBeforeCloseEvent()&&(this.state=`closing`,this._isZeroAnimationDuration()&&this._handleClosing())}firstUpdated(e){super.firstUpdated(e),this.open()}willUpdate(e){super.willUpdate(e),e.has(`size`)&&this._configureTitle()}_isZeroAnimationDuration(){return _(this,`--sbb-alert-animation-duration`)}_onAnimationEnd(e){this.state===`opening`&&e.animationName===`open-opacity`?this._handleOpening():this.state===`closing`&&e.animationName===`close`&&this._handleClosing()}_handleOpening(){this.state=`opened`,this.dispatchOpenEvent()}_handleClosing(){this.state=`closed`,this.dispatchCloseEvent(),setTimeout(()=>this.remove())}_handleSlotchange(){this._syncLinks();let e=Array.from(this.children).find(e=>e.localName===`sbb-title`);e&&(e.slot=`title`)}_syncLinks(){Array.from(this.querySelectorAll?.(`sbb-link`)??[]).forEach(e=>{customElements.upgrade(e),e.negative=this._isLightMode()})}_configureTitle(){let e=this.querySelector?.(`sbb-title`);e&&(customElements.upgrade(e),e.negative=this._isLightMode(),e.visualLevel=this.size===`l`?`3`:`5`)}_isLightMode(){return!this._darkModeController.matches()}renderIconName(){return super.renderIconName()||`info`}render(){return n`
7
+ `}}})();var T=`:host{--sbb-alert-animation-duration:var(--sbb-disable-animation-duration,var(--sbb-animation-duration-6x));opacity:0;border-radius:var(--sbb-alert-forced-color-border-radius);outline:var(--sbb-alert-outline);grid-template-rows:0fr;display:grid}:host(:is(:state(state-opening),[state--state-opening]):not([animation=open],[animation=all])),:host(:is(:state(state-closing),[state--state-closing]):not([animation=close],[animation=all])){--sbb-disable-animation-duration:0s}:host([size=s]){--sbb-alert-gap:var(--sbb-alert-gap-s);--sbb-alert-close-icon-margin:var(--sbb-alert-close-icon-margin-s);--sbb-alert-icon-padding-block:var(--sbb-alert-icon-padding-block-s)}:host([size=m]){--sbb-alert-gap:var(--sbb-alert-gap-m);--sbb-alert-close-icon-margin:var(--sbb-alert-close-icon-margin-m);--sbb-alert-icon-padding-block:var(--sbb-alert-icon-padding-block-m)}:host([size=l]){--sbb-alert-gap:var(--sbb-alert-gap-l);--sbb-alert-close-icon-margin:var(--sbb-alert-close-icon-margin-l);--sbb-alert-icon-padding-block:var(--sbb-alert-icon-padding-block-l);--sbb-alert-icon-size:var(--sbb-alert-icon-size-l);--sbb-alert-title-margin-block:0 var(--sbb-spacing-fixed-1x)}:host(:not(:is(:state(dark),[state--dark]))){--sbb-focus-outline-color:var(--sbb-focus-outline-color-dark)}:host(:is(:is(:state(state-opened),[state--state-opened]),:is(:state(state-closing),[state--state-closing]))){opacity:1;grid-template-rows:1fr}:host(:is(:state(state-opening),[state--state-opening])){animation-name:open,open-opacity;animation-fill-mode:forwards;animation-duration:var(--sbb-alert-animation-duration);animation-timing-function:var(--sbb-alert-timing-function);animation-delay:0s, var(--sbb-alert-animation-duration)}:host(:is(:state(state-closing),[state--state-closing])){animation-name:close-opacity,close;animation-fill-mode:forwards;animation-duration:var(--sbb-alert-animation-duration);animation-timing-function:var(--sbb-alert-timing-function);animation-delay:0s, var(--sbb-disable-animation-duration,var(--sbb-animation-duration-2x))}.sbb-alert__transition-wrapper{overflow:hidden}.sbb-alert{grid-template-columns:var(--sbb-alert-grid-template-columns);align-items:center;gap:var(--sbb-alert-gap);min-width:fit-content;padding:var(--sbb-alert-padding);color:var(--sbb-alert-color);background-color:var(--sbb-alert-background-color);border-radius:var(--sbb-alert-border-radius);font-size:var(--sbb-alert-font-size);letter-spacing:var(--sbb-letter-spacing-text);line-height:var(--sbb-typo-line-height-text);display:grid;overflow:hidden}.sbb-alert__icon{min-width:var(--sbb-alert-icon-size);padding-block:var(--sbb-alert-icon-padding-block);--sbb-icon-svg-width:var(--sbb-alert-icon-size);--sbb-icon-svg-height:var(--sbb-alert-icon-size);align-self:start;align-items:center;min-height:1lh;display:flex}@media (width>=37.5rem){:host(:is(:state(slotted-title),[state--slotted-title])) .sbb-alert__icon{padding-block:var(--sbb-spacing-fixed-1x)}}.sbb-alert__content{color-scheme:light only;order:3;grid-column:1/3}@media (width>=37.5rem){.sbb-alert__content{order:initial;grid-column-start:initial;grid-column-end:initial}}.sbb-alert__content-slot{margin:0;padding:0;display:inline}.sbb-alert__close-button-wrapper{color-scheme:light only;justify-content:flex-end;align-items:center;height:100%;display:flex}.sbb-alert__close-button{margin-block:calc(-1 * var(--sbb-spacing-fixed-8x))}@media (width>=37.5rem){.sbb-alert__close-button{margin-inline-start:var(--sbb-alert-close-icon-margin)}}.sbb-alert__close-button-divider{display:var(--sbb-alert-close-button-divider-display,none);height:calc(100% - var(--sbb-spacing-fixed-1x) * 2)}@keyframes open{0%{grid-template-rows:0fr}to{grid-template-rows:1fr}}@keyframes open-opacity{0%{opacity:0}to{opacity:1}}@keyframes close{0%{grid-template-rows:1fr}to{grid-template-rows:0fr}}@keyframes close-opacity{0%{opacity:1}to{opacity:0}}::slotted(sbb-title){margin-block:var(--sbb-alert-title-margin-block)}
8
+ `;let E=(()=>{let o=S(p(f)),s,c=[],u=[],m,h=[],_=[];return class extends o{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(o[Symbol.metadata]??null):void 0;s=[a({reflect:!0})],m=[a({reflect:!0})],e(this,null,s,{kind:`accessor`,name:`size`,static:!1,private:!1,access:{has:e=>`size`in e,get:e=>e.size,set:(e,t)=>{e.size=t}},metadata:t},c,u),e(this,null,m,{kind:`accessor`,name:`animation`,static:!1,private:!1,access:{has:e=>`animation`in e,get:e=>e.animation,set:(e,t)=>{e.animation=t}},metadata:t},h,_),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.elementName=`sbb-alert`}static{this.elementDependencies=[b,x]}static{this.styles=[i(T)]}static{this.events={beforeopen:`beforeopen`,open:`open`,beforeclose:`beforeclose`,close:`close`}}#e;get size(){return this.#e}set size(e){this.#e=e}#t;get animation(){return this.#t}set animation(e){this.#t=e}constructor(){super(),this.#e=t(this,c,null),this.#t=(t(this,u),t(this,h,`all`)),this._language=(t(this,_),new d(this)),this._darkModeController=new l(this,()=>{this._syncLinks(),this._configureTitle(),this.requestUpdate()}),this.addEventListener(`animationend`,e=>this._onAnimationEnd(e))}open(){this.state=`opening`,this.dispatchBeforeOpenEvent()&&this._isZeroAnimationDuration()&&this._handleOpening()}close(){this.state===`opened`&&this.dispatchBeforeCloseEvent()&&(this.state=`closing`,this._isZeroAnimationDuration()&&this._handleClosing())}firstUpdated(e){super.firstUpdated(e),this.open()}willUpdate(e){super.willUpdate(e),e.has(`size`)&&this._configureTitle()}_isZeroAnimationDuration(){return v(this,`--sbb-alert-animation-duration`)}_onAnimationEnd(e){this.state===`opening`&&e.animationName===`open-opacity`?this._handleOpening():this.state===`closing`&&e.animationName===`close`&&this._handleClosing()}_handleOpening(){this.state=`opened`,this.dispatchOpenEvent()}_handleClosing(){this.state=`closed`,this.dispatchCloseEvent(),setTimeout(()=>this.remove())}_handleSlotchange(){this._syncLinks();let e=Array.from(this.children).find(e=>e.localName===`sbb-title`);e&&(e.slot=`title`)}_syncLinks(){Array.from(this.querySelectorAll?.(`sbb-link`)??[]).forEach(e=>{customElements.upgrade(e),e.negative=this._isLightMode()})}_configureTitle(){let e=this.querySelector?.(`sbb-title`);e&&(customElements.upgrade(e),e.negative=this._isLightMode(),e.visualLevel=this.size===`l`?`3`:`5`)}_isLightMode(){return!this._darkModeController.matches()}renderIconName(){return super.renderIconName()||`info`}render(){return n`
9
9
  <!-- wrapper needed to properly support fade in animation -->
10
10
  <div class="sbb-alert__transition-wrapper">
11
11
  <div class="sbb-alert">
@@ -27,10 +27,10 @@ import{__esDecorate as e,__runInitializers as t}from"tslib";import{html as n,not
27
27
  size=${this.size===`l`?`m`:this.size||r}
28
28
  icon-name="cross-small"
29
29
  @click=${()=>this.close()}
30
- aria-label=${h[this._language.current]}
30
+ aria-label=${g[this._language.current]}
31
31
  class="sbb-alert__close-button"
32
32
  ></sbb-transparent-button>
33
33
  </span>`}
34
34
  </div>
35
35
  </div>
36
- `}}})();export{T as SbbAlertElement,C as SbbAlertGroupElement};
36
+ `}}})();export{E as SbbAlertElement,w as SbbAlertGroupElement};
package/core.js CHANGED
@@ -40,15 +40,15 @@ let xe=0;var Se=class{constructor(){r||(document.body?this._liveElement=this._cr
40
40
  `;let Hn=(()=>{let e=V(H(P)),t,r=[],i=[],c,u=[],f=[],p,m=[],h=[];return class extends e{static{let n=typeof Symbol==`function`&&Symbol.metadata?Object.create(e[Symbol.metadata]??null):void 0;t=[l()],c=[l({attribute:`horizontal-from`,reflect:!0})],p=[l({reflect:!0})],o(this,null,t,{kind:`accessor`,name:`size`,static:!1,private:!1,access:{has:e=>`size`in e,get:e=>e.size,set:(e,t)=>{e.size=t}},metadata:n},r,i),o(this,null,c,{kind:`accessor`,name:`horizontalFrom`,static:!1,private:!1,access:{has:e=>`horizontalFrom`in e,get:e=>e.horizontalFrom,set:(e,t)=>{e.horizontalFrom=t}},metadata:n},u,f),o(this,null,p,{kind:`accessor`,name:`orientation`,static:!1,private:!1,access:{has:e=>`orientation`in e,get:e=>e.orientation,set:(e,t)=>{e.orientation=t}},metadata:n},m,h),n&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:n})}static{this.styles=[a(Vn)]}#e=s(this,r,null);get size(){return this.#e}set size(e){this.#e=e}#t=(s(this,i),s(this,u,null));get horizontalFrom(){return this.#t}set horizontalFrom(e){this.#t=e}#n=(s(this,f),s(this,m,`horizontal`));get orientation(){return this.#n}set orientation(e){this.#n=e}get selectionElements(){return Array.from(this.querySelectorAll?.(this.selectionElementSelectors)??[]).filter(e=>e.closest?.(this.localName)===this)}constructor(){super(),s(this,h),this.addController(new d(this,{config:{childList:!0,subtree:!0},callback:()=>this.toggleState(`has-panel`,!!this.querySelector?.(this.panelElementSelector))}))}onSlotChange(){}render(){return n`
41
41
  <slot @slotchange=${()=>this.onSlotChange()}></slot>
42
42
  <slot name="error"></slot>
43
- `}}})();var Un=class{get size(){return this._handlers.size}constructor(e,t){this._host=e,this._property=t,this._handlers=/* @__PURE__ */ new Set,this._hostDefinedPromise=null,r||(customElements.get(this._host.localName)?customElements.upgrade(this._host):this._hostDefinedPromise=customElements.whenDefined(this._host.localName).then(()=>{customElements.upgrade(this._host),this._hostDefinedPromise=null})),this._value=this._host[this._property]}addHandler(e){this._handlers.size||(this._host.addController?this._host.addController(this):this._hostDefinedPromise&&this._hostDefinedPromise.then(()=>this._host.addController(this))),this._handlers.add(e),this._hostDefinedPromise?this._hostDefinedPromise.then(()=>e(this._host)):e(this._host)}removeHandler(e){this._handlers.delete(e),this._handlers.size||(this._host.removeController?this._host.removeController(this):this._hostDefinedPromise&&this._hostDefinedPromise.then(()=>this._host.removeController(this)))}hostUpdate(){let e=this._host[this._property];if(this._value!==e){this._value=e;for(let e of this._handlers)e(this._host)}}};const U=/* @__PURE__ */ new WeakMap;var Wn=class{constructor(e,t,n){this._host=e,this._referenceResolver=t,this._handlers=n,this._host.addController(this)}hostConnected(){this.connect()}hostDisconnected(){this._reference!==this._referenceResolver()&&this.disconnect()}connect(){let e=this._referenceResolver();if(this._reference===e||(this.disconnect(),this._reference=e,!this._reference))return;let t=U.get(this._reference);t||(t=/* @__PURE__ */ new Map,U.set(this._reference,t)),this._watchers=t;for(let[e,t]of Object.entries(this._handlers)){let n=this._watchers.get(e);n||(n=new Un(this._reference,e),this._watchers.set(e,n)),n.addHandler(t)}}disconnect(){if(this._reference){for(let[e,t]of Object.entries(this._handlers)){let n=this._watchers?.get(e);n&&(n.removeHandler(t),n.size||(this._watchers.delete(e),!this._watchers.size&&this._reference&&U.delete(this._reference)))}this._reference=null}}};const Gn=[];r||window.addEventListener(`keydown`,e=>{e.key===`Escape`&&!e.defaultPrevented&&(e.preventDefault(),Gn.at(-1)?.escapeStrategy())});var Kn=class{constructor(e,t=Gn){this._host=e,this._overlayStack=t,this._host.addController?.(this)}hostDisconnected(){this.disconnect()}connect(){this.disconnect(),this._overlayStack.push(this._host)}disconnect(){if(this._overlayStack.length){let e=this._overlayStack.findIndex(e=>e===this._host);e!==-1&&this._overlayStack.splice(e,1)}}};const qn=/* @__PURE__ */ new WeakMap;var Jn=class{constructor(e,t,n=qn){this._host=e,this._idRef=t,this._observers=n,this._rootNode=null,this._host.addController(this)}hostConnected(){if(r)return;this._rootNode=this._host.getRootNode();let e=this._observers.get(this._rootNode);if(e)e.controllers.add(this);else{let e=/* @__PURE__ */ new Set([this]),t=new MutationObserver(t=>{let n=/* @__PURE__ */ new Set;for(let e of t)if(e.type===`attributes`)n.add(e.oldValue),n.add(e.target.id);else if(e.type===`childList`)for(let t of[...e.addedNodes,...e.removedNodes])t instanceof HTMLElement&&(n.add(t.id),t.querySelectorAll(`[id]`).forEach(e=>n.add(e.id)));for(let t of e){let e=t._host[t._idRef];e&&typeof e==`string`&&n.has(e)&&t._host.requestUpdate()}});t.observe(this._rootNode,{attributeFilter:[`id`],childList:!0,subtree:!0,attributeOldValue:!0}),this._observers.set(this._rootNode,{observer:t,controllers:e})}}hostDisconnected(){if(r||!this._rootNode)return;let e=this._observers.get(this._rootNode);e&&(e.controllers.delete(this),e.controllers.size===0&&(e.observer.disconnect(),this._observers.delete(this._rootNode))),this._rootNode=null}find(){if(r||!this._rootNode)return null;{let e=this._host[this._idRef];return typeof e==`string`?this._rootNode?.getElementById(e):null}}};const Yn=[`script`,`head`,`template`,`style`,`link`],Xn=/* @__PURE__ */ new Set,Zn=/* @__PURE__ */ new Set,Qn=/* @__PURE__ */ new Set;var $n=class{constructor(e,t=Xn,n=Qn,r=Zn){this._host=e,this._inertElements=t,this._inertOverlays=n,this._exemptedElements=r,this._host.addController?.(this)}hostConnected(){this._host.isOpen&&this.activate()}hostDisconnected(){this.isInert()&&this.deactivate()}activate(){this._inertOverlays.size&&this._removeAllInertAttributes(),this._inertOverlays.add(this._host),this._addAllInertAttributes()}deactivate(){this._currentOverlay()===this._host?(this._removeAllInertAttributes(),this._inertOverlays.delete(this._host),this._inertOverlays.size&&this._addAllInertAttributes()):this._inertOverlays.has(this._host)&&this._inertOverlays.delete(this._host)}isInert(){return this._inertOverlays.has(this._host)}exempt(e){this._inertElements.has(e)&&!this._exemptedElements.has(e)&&(this._removeInertAttributes(e),this._inertElements.delete(e),this._exemptedElements.add(e))}restoreAllExempted(){this._exemptedElements.forEach(e=>this._addInertAttributes(e)),this._exemptedElements.clear()}_currentOverlay(){return[...this._inertOverlays].pop()??null}_removeAllInertAttributes(){this._inertElements.forEach(e=>this._removeInertAttributes(e)),this._inertElements.clear()}_removeInertAttributes(e){e&&(e.hasAttribute(`data-sbb-inert`)&&(e.inert=!1,e.removeAttribute(`data-sbb-inert`)),e.hasAttribute(`data-sbb-aria-hidden`)&&(e.removeAttribute(`aria-hidden`),e.removeAttribute(`data-sbb-aria-hidden`)))}_addAllInertAttributes(){let e=this._currentOverlay(),t=e?[e]:[],n=[document.documentElement];for(;n.length>0;)for(let e of n.shift().querySelectorAll(`*`))e.matches(`sbb-toast,.sbb-overlay-outlet,.sbb-live-announcer-element,.cdk-live-announcer-element,.cdk-overlay-container`)&&t.push(e),e.shadowRoot&&n.push(e.shadowRoot);let r=[],i=e=>r.push(...e.composedPath());for(let e of t)e.addEventListener(`ɵinert`,i,{once:!0}),e.dispatchEvent(new Event(`ɵinert`,{composed:!0}));let a=new Set(r),o=/* @__PURE__ */ new Set;for(let e of a)for(let t of e.parentNode?.childNodes??[])t.nodeType===Node.ELEMENT_NODE&&!Yn.includes(t.localName)&&!a.has(t)&&o.add(t);for(let e of o)this._addInertAttributes(e)}_addInertAttributes(e){this._inertElements.add(e),e.inert||(e.inert=!0,e.toggleAttribute(`data-sbb-inert`,!0)),e.hasAttribute(`aria-hidden`)||(e.setAttribute(`aria-hidden`,`true`),e.toggleAttribute(`data-sbb-aria-hidden`,!0))}};const er=`(forced-colors: active)`,W=`(prefers-color-scheme: dark)`,tr=`(any-hover: hover)`,nr=`(pointer: coarse)`,rr=`(min-width: 0rem)`,ir=`(min-width: 37.5rem)`,ar=`(min-width: 64rem)`,or=`(min-width: 90rem)`,sr=`(max-width: 63.9375rem)`,cr=`(max-width: 89.9375rem)`,G=/* @__PURE__ */ new Map;var lr=class{constructor(e,t){this._queries=t,e.addController(this)}matches(e){return r?null:matchMedia(e).matches}hostConnected(){if(!r)for(let[e,t]of Object.entries(this._queries)){let n=G.get(e);if(n)n.handlers.add(t);else{let n=matchMedia(e),r=/* @__PURE__ */ new Set([t]),i=e=>r.forEach(t=>t(e.matches));n.addEventListener(`change`,i),G.set(e,{mediaQueryList:n,handlers:r,eventHandler:i})}}}hostDisconnected(){for(let[e,t]of Object.entries(this._queries)){let n=G.get(e);n&&(n.handlers.delete(t),n.handlers.size||G.delete(e))}}},ur=class e extends lr{static{this._currentMode=this._readLightDarkClass()}static{this._observer=r?null:new MutationObserver(t=>{if(t[0].oldValue!==document.documentElement.getAttribute(`class`)){let t=this._readLightDarkClass();this._currentMode!==t&&(e.requestUpdate(),this._currentMode=t)}})}static{this._observerConfig={attributeFilter:[`class`],attributeOldValue:!0}}constructor(e,t){let n=()=>{t(this.matches()),this._host.toggleState?.(`dark`,this.matches())};super(e,{[W]:n}),this._host=e,this._onChangeWithStateUpdater=n}static _readLightDarkClass(){if(r)return null;let e=document.documentElement.classList;return[`sbb-light-dark`,`sbb-dark`,`sbb-light`].find(t=>e.contains(t))??null}static requestUpdate(){let e=G.get(W);e&&e.handlers.forEach(t=>t(e.mediaQueryList.matches))}hostConnected(){let t=(G.get(`(prefers-color-scheme: dark)`)?.handlers.size??0)===0;super.hostConnected(),t&&e._observer.observe(document.documentElement,e._observerConfig),this._onChangeWithStateUpdater()}hostDisconnected(){super.hostDisconnected(),(G.get(`(prefers-color-scheme: dark)`)?.handlers.size??0)===0&&e._observer.disconnect()}matches(){if(r)return!1;let e=getComputedStyle(this._host).getPropertyValue(`color-scheme`),t=e.includes(`dark`),n=e.trim()===`dark`;return super.matches(`(prefers-color-scheme: dark)`)&&t||n}};const dr=!r&&CSS.supports(`anchor-name`,`--test`),fr=[`top`,`bottom`,`left`,`right`,`top span-left`,`top span-right`,`bottom span-left`,`bottom span-right`,`left span-top`,`left span-bottom`,`right span-top`,`right span-bottom`],pr=[`block-start`,`block-end`,`inline-start`,`inline-end`,`block-start span-inline-start`,`block-start span-inline-end`,`block-end span-inline-start`,`block-end span-inline-end`,`inline-start span-block-start`,`inline-start span-block-end`,`inline-end span-block-start`,`inline-end span-block-end`],mr={"block-start":`block-start`,"block-end":`block-end`,"inline-start":`inline-end`,"inline-end":`inline-start`,"block-start span-inline-start":`block-start span-inline-end`,"block-start span-inline-end":`block-start span-inline-start`,"block-end span-inline-start":`block-end span-inline-end`,"block-end span-inline-end":`block-end span-inline-start`,"inline-start span-block-start":`inline-end span-block-start`,"inline-start span-block-end":`inline-end span-block-end`,"inline-end span-block-start":`inline-start span-block-start`,"inline-end span-block-end":`inline-start span-block-end`};[...fr,...pr];let hr=0;var gr=class{get currentPosition(){return this._usePolyfill?this._lastPosition??this._positions[0]??``:(this._overlayStyles??=getComputedStyle(this._overlay),this._overlayStyles.getPropertyValue(`position-area`))}constructor(e,t=!dr){this._usePolyfill=t,this._resizeObserver=r?null:new ResizeObserver(()=>this._requestCalculatePosition()),this._anchorName=`--sbb-overlay-anchor-${++hr}`,this._positions=[],e.addController(this),this._overlay=e}hostConnected(){this._usePolyfill?this._overlay.style.setProperty(`position-area`,`initial`):this._overlay.style.setProperty(`position-anchor`,this._anchorName)}hostUpdate(){r||this._readPositionsFromCss()}connect(e){r||(this._anchor&&this.disconnect(),this._anchor=e,this._usePolyfill||this._anchor.style.setProperty(`anchor-name`,this._anchorName),this._readPositionsFromCss(),this._calculatePosition(),this._abortController?.abort(),this._abortController=new AbortController,document.addEventListener(`scroll`,()=>this._requestCalculatePosition(),{capture:!0,passive:!0,signal:this._abortController.signal}),window.addEventListener(`resize`,()=>this._requestCalculatePosition(),{passive:!0,signal:this._abortController.signal}),this._resizeObserver.observe(e,{box:`border-box`}),this._resizeObserver.observe(this._overlay,{box:`border-box`}))}disconnect(){this._anchor?.style.removeProperty(`anchor-name`),this._anchor=void 0,this._abortController?.abort(),this._resizeObserver.disconnect()}_requestCalculatePosition(){this._frame??=requestAnimationFrame(()=>{this._calculatePosition(),this._frame=void 0})}_calculatePosition(){if(this._anchor){if(this._usePolyfill){let e=this._getOptimalPosition(this._positions);this._applyOverlayPosition(e.position,e.left,e.top)}this._overlay.setAttribute(`data-position`,this.currentPosition)}}_getOptimalPosition(e){let{offsetHeight:t,offsetWidth:n}=this._overlay,{innerHeight:r,innerWidth:i}=window,{top:a,left:o,height:s,width:c}=this._anchor.getBoundingClientRect(),l=this._overlay.matches(`:dir(rtl)`),u=a,d=r-s-a,f=o,p=i-c-o,m=n-c,h=t-s,g=m/2,_=h/2;this._overlay.style.setProperty(`--sbb-overlay-controller-trigger-height`,`${s}px`),this._overlay.style.setProperty(`--sbb-overlay-controller-trigger-width`,`${c}px`);let v={left:0,top:0,position:``},y;for(let r of e){switch(l&&pr.includes(r)?mr[r]:r){default:case`bottom`:case`block-end`:v={position:r,left:o-g,top:a+s,fits:t<=d&&g<=f&&g<=p};break;case`top`:case`block-start`:v={position:r,left:o-g,top:a-t,fits:t<=u&&g<=f&&g<=p};break;case`right`:case`inline-end`:v={position:r,left:o+c,top:a-_,fits:n<=p&&_<=u&&_<=d};break;case`left`:case`inline-start`:v={position:r,left:o-n,top:a-_,fits:n<=f&&_<=u&&_<=d};break;case`top span-left`:case`block-start span-inline-start`:v={position:r,left:o-m,top:a-t,fits:t<=u&&m<=f};break;case`top span-right`:case`block-start span-inline-end`:v={position:r,left:o,top:a-t,fits:t<=u&&m<=p};break;case`bottom span-left`:case`block-end span-inline-start`:v={position:r,left:o-m,top:a+s,fits:t<=d&&m<=f};break;case`bottom span-right`:case`block-end span-inline-end`:v={position:r,left:o,top:a+s,fits:t<=d&&m<=p};break;case`left span-top`:case`inline-start span-block-start`:v={position:r,left:o-n,top:a+s-t,fits:n<=f&&h<=u};break;case`left span-bottom`:case`inline-start span-block-end`:v={position:r,left:o-n,top:a,fits:n<=f&&h<=d};break;case`right span-top`:case`inline-end span-block-start`:v={position:r,left:o+c,top:a+s-t,fits:n<=p&&h<=u};break;case`right span-bottom`:case`inline-end span-block-end`:v={position:r,left:o+c,top:a,fits:n<=p&&h<=d}}if(v.fits)return v;y??=v}return y}_applyOverlayPosition(e,t,n){this._lastPosition=e,this._overlay.style.left=`${t}px`,this._overlay.style.top=`${n}px`}_readPositionsFromCss(){if(!this._usePolyfill)return;this._overlayStyles??=getComputedStyle(this._overlay);let e=[this._overlayStyles.getPropertyValue(`--sbb-overlay-position-area`)||`block-end`,...this._overlayStyles.getPropertyValue(`--sbb-overlay-position-try-fallbacks`).split(`,`).map(e=>e.trim()).filter(e=>!!e)];this._positions=e,this._lastPosition&&!this._positions.includes(this._lastPosition)&&(this._lastPosition=void 0)}};const _r=/* @__PURE__ */ new Set;var vr=class{constructor(e,t=_r){this._host=e,this._lockers=t,this._locked=!1,this._scrollProperties={scrollPosition:0,touchStartY:0},this._touchStart=e=>{this._scrollProperties.touchStartY=e.touches[0]?.clientY??0},this._touchMove=e=>{let t=e.touches[0];if(!t)return;let n=this._findScrollableAncestor(e.composedPath());if(!n){e.preventDefault();return}let r=t.clientY-this._scrollProperties.touchStartY,i=n.scrollTop<=0,a=n.scrollTop+n.clientHeight>=n.scrollHeight;(i&&r>0||a&&r<0)&&e.preventDefault()},this._host.addController?.(this)}_isVerticallyScrollable(e){let t=getComputedStyle(e).overflowY;return(t===`auto`||t===`scroll`)&&e.scrollHeight>e.clientHeight}_findScrollableAncestor(e){for(let t of e){if(t===document.body||t===document.documentElement)break;if(t instanceof Element&&this._isVerticallyScrollable(t))return t}return null}hostDisconnected(){this.enableScroll()}disableScroll(){if(this._locked)return;this._locked=!0;let e=this._lockers.size===0;if(this._lockers.add(this._host),!e)return;this._scrollProperties.scrollPosition=window.scrollY||document.documentElement.scrollTop,this._scrollProperties.savedPosition=document.body.style.position,this._scrollProperties.savedTop=document.body.style.top,this._scrollProperties.savedInsetInline=document.body.style.insetInline,this._scrollProperties.savedOverflow=document.body.style.overflow,this._scrollProperties.savedMinHeight=document.body.style.minHeight;let t=window.innerWidth-document.documentElement.clientWidth;document.body.style.position=`fixed`,document.body.style.top=`-${this._scrollProperties.scrollPosition}px`,document.body.style.insetInline=`0 ${t}px`,document.body.style.overflow=`hidden`,document.body.style.setProperty(`--sbb-scrollbar-reserved-space`,`${t}px`),document.body.style.minHeight=`100dvh`,document.addEventListener(`touchstart`,this._touchStart,{passive:!0}),document.addEventListener(`touchmove`,this._touchMove,{passive:!1}),document.body.toggleAttribute(`data-sbb-scroll-disabled`,!0)}enableScroll(){this._locked&&(this._locked=!1,this._lockers.delete(this._host),this._lockers.size>0||(document.body.style.position=this._scrollProperties.savedPosition||``,document.body.style.top=this._scrollProperties.savedTop||``,document.body.style.insetInline=this._scrollProperties.savedInsetInline||``,document.body.style.overflow=this._scrollProperties.savedOverflow||``,document.body.style.removeProperty(`--sbb-scrollbar-reserved-space`),document.body.style.minHeight=this._scrollProperties.savedMinHeight||``,document.removeEventListener(`touchstart`,this._touchStart),document.removeEventListener(`touchmove`,this._touchMove),document.body.removeAttribute(`data-sbb-scroll-disabled`),window.scrollTo(0,this._scrollProperties.scrollPosition)))}};const yr=/(0?[1-9]|[12][0-9]|3[01])[.,\\/\-\s](0?[1-9]|1[0-2])[.,\\/\-\s]([0-9]{1,4}$)?/,br=/([0-9]{2})([0-9]{2})([0-9]{4})/,xr=/^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-3][0-9])$/,Sr=1,Cr=2,wr=3,Tr=4,Er=5,Dr=6,Or=0;var K=class{constructor(e=15){this._cutoffYearOffset=e}deserialize(e){return e==null||this.isDateInstance(e)&&this.isValid(e)?e:this.invalid()}parse(e){if(!e)return null;let t=null,n=e.match(xr);try{t=n?this.createDate(+n[1],+n[2],+n[3]):null}catch{}if(this.isValid(t))return t;let r=e.replace(/\D/g,` `).trim()?.match(yr)??e.match(br);try{t=r?this.createDate(+r[3],+r[2],+r[1]):null}catch{}if(!r||r.index!==0||r.length<=2||r.some(e=>e===void 0)||!this.isValid(t))return null;let i=+r[3];if(typeof i==`number`&&i<100&&i>=0){let e=this.getYear(this.today())-2e3+this._cutoffYearOffset;i=i<=e?2e3+i:1900+i}return this.createDate(i,+r[2],+r[1])}format(e,t){if(!this.isValid(e))return``;let n=/* @__PURE__ */ new Date(this.toIso8601(e)+`T00:00:00`),r=new Intl.DateTimeFormat(`de-CH`,{day:`2-digit`,month:`2-digit`,year:`numeric`});if(t?.weekdayStyle===`none`)return r.format(n);let i=t?.weekdayStyle??`short`,a=this.getDayOfWeekNames(i)[this.getDayOfWeek(e)];return a=a.charAt(0).toUpperCase()+a.substring(1),i===`short`&&(a=a.substring(0,2)),`${a}, ${r.format(n)}`}toIso8601(e){let t=(e,t=2)=>`${e}`.padStart(t,`0`);return`${t(this.getYear(e),4)}-${t(this.getMonth(e))}-${t(this.getDate(e))}`}getValidDateOrNull(e){return this.isDateInstance(e)&&this.isValid(e)?e:null}getFirstWeekOffset(e){let t=this.createDate(this.getYear(e),this.getMonth(e),1);return(7+this.getDayOfWeek(t)-this.getFirstDayOfWeek())%7}compareDate(e,t){return this.getYear(e)-this.getYear(t)||this.getMonth(e)-this.getMonth(t)||this.getDate(e)-this.getDate(t)}sameDate(e,t){if(e&&t){let n=this.isValid(e),r=this.isValid(t);return n&&r?!this.compareDate(e,t):n==r}return e==t}clampDate(e,t,n){return t&&this.compareDate(e,t)<0?t:n&&this.compareDate(e,n)>0?n:e}};const kr=/^\d{4}-\d{2}-\d{2}(?:T\d{2}:\d{2}:\d{2}(?:\.\d+)?(?:Z|(?:(?:\+|-)\d{2}:\d{2}))?)?$/;var Ar=class extends K{getYear(e){return e.getFullYear()}getMonth(e){return e.getMonth()+1}getDate(e){return e.getDate()}getDayOfWeek(e){return e.getDay()}getAccessibilityFormatDate(e){return new Intl.DateTimeFormat(z.current,{year:`numeric`,month:`long`,day:`numeric`}).format(new Date(e))}getMonthNames(e){let t=new Intl.DateTimeFormat(z.current,{month:e});return this._range(12,e=>t.format(new Date(2017,e,1)))}getDateNames(){let e=new Intl.DateTimeFormat(z.current,{day:`numeric`});return this._range(31,t=>e.format(new Date(2017,0,t+1)))}getDayOfWeekNames(e){let t=new Intl.DateTimeFormat(z.current,{weekday:e});return this._range(7,e=>t.format(new Date(2017,0,e+1)))}getFirstDayOfWeek(){return 1}getNumDaysInMonth(e){return this.getDate(this._createDateWithOverflow(this.getYear(e),this.getMonth(e),0))}today(){return new Date((/* @__PURE__ */ new Date()).setHours(0,0,0,0))}createDate(e,t,n){if(t<1||t>12)throw Error(`Invalid month "${t}". Month has to be between 1 and 12.`);if(n<1)throw Error(`Invalid day "${n}". Day has to be greater than 0.`);let r=this._createDateWithOverflow(e,t-1,n);if(r.getMonth()+1!==t)throw Error(`Invalid day "${n}" for month "${t}".`);return r}isDateInstance(e){return e instanceof Date}isValid(e){return!!e&&!isNaN(e.valueOf())}clone(e){return new Date(e.valueOf())}addCalendarYears(e,t){return this.addCalendarMonths(e,t*12)}addCalendarMonths(e,t){let n=e.getMonth()+t,r=new Date(e.getFullYear(),n,1,0,0,0,0),i=this.getNumDaysInMonth(r);return new Date(this.clone(e).setMonth(n,Math.min(i,e.getDate())))}addCalendarDays(e,t){let n=e.getDate()+t;return new Date(e.getFullYear(),e.getMonth(),n,0,0,0,0)}deserialize(e){if(typeof e==`string`){if(!e)return null;if(kr.test(e))return this.getValidDateOrNull(new Date(e.includes(`T`)?e:e+`T00:00:00`))}return super.deserialize(e)}invalid(){return/* @__PURE__ */ new Date(NaN)}_range(e,t){return Array.from({length:e},(e,n)=>t(n))}_createDateWithOverflow(e,t,n){let r=new Date(e,t,n);return e>=0&&e<100&&r.setFullYear(this.getYear(r)-1900),r}};const q=new Ar,jr=/^\d{4}-\d{2}-\d{2}(?:T\d{2}:\d{2}:\d{2}(?:\.\d+)?(?:Z|(?:(?:\+|-)\d{2}:\d{2}))?)?$/;var Mr=class extends K{constructor(e){if(super(e),typeof Temporal!=`object`)throw Error(`Temporal is not available in the current environment. Please make sure to include the temporal polyfill.`)}getYear(e){return e.year}getMonth(e){return e.month}getDate(e){return e.day}getDayOfWeek(e){return e.dayOfWeek%7}getAccessibilityFormatDate(e){return this.deserialize(e).toLocaleString(z.current,{year:`numeric`,month:`long`,day:`numeric`})}getMonthNames(e){let t=new Intl.DateTimeFormat(z.current,{month:e});return this._range(12,e=>t.format(Temporal.PlainDate.from({year:2017,month:e+1,day:1})))}getDateNames(){let e=new Intl.DateTimeFormat(z.current,{day:`numeric`});return this._range(31,t=>e.format(Temporal.PlainDate.from({year:2017,month:1,day:t+1})))}getDayOfWeekNames(e){let t=new Intl.DateTimeFormat(z.current,{weekday:e});return this._range(7,e=>t.format(Temporal.PlainDate.from({year:2017,month:1,day:e+1})))}getFirstDayOfWeek(){return 1}getNumDaysInMonth(e){return e.daysInMonth}today(){return Temporal.Now.plainDateISO()}createDate(e,t,n){if(t<1||t>12)throw Error(`Invalid month "${t}". Month has to be between 1 and 12.`);if(n<1)throw Error(`Invalid day "${n}". Day has to be greater than 0.`);try{return Temporal.PlainDate.from({year:e,month:t,day:n},{overflow:`reject`})}catch{throw Error(`Invalid date "${n}" for month with index "${t}".`)}}isDateInstance(e){return e instanceof Temporal.PlainDate}isValid(e){return this.isDateInstance(e)}clone(e){return Temporal.PlainDate.from(e)}addCalendarYears(e,t){return e.add({years:t})}addCalendarMonths(e,t){return e.add({months:t})}addCalendarDays(e,t){return e.add({days:t})}deserialize(e){if(typeof e==`string`){if(!e)return null;if(jr.test(e))return this.getValidDateOrNull(Temporal.PlainDate.from(e.split(`T`)[0]))}return super.deserialize(e)}invalid(){return null}toIso8601(e){return e.toJSON()}_range(e,t){return Array.from({length:e},(e,n)=>t(n))}};const Nr=e=>(t,n)=>{let{kind:r}=n;if(r===`accessor`)return{get(){let n=t.get.call(this);return e(this,n)}};throw Error(`Unsupported decorator location: ${r}`)},Pr=e=>(t,n)=>{let{kind:r}=n;if(r===`accessor`)return{set(r){let i=n.access.get(this);t.set.call(this,r);let a=n.access.get(this);a!==i&&e(this,a,i)}};throw Error(`Unsupported decorator location: ${r}`)},J=/* @__PURE__ */ new WeakMap,Y=/* @__PURE__ */ new WeakMap,Fr=()=>(e,t)=>{let{kind:n,metadata:i,name:a}=t;if(n===`accessor`){if(r)return{};let n=globalThis.litPropertyMetadata.get(i)?.get(a)?.attribute,o=typeof n==`string`?n:a;return t.addInitializer(function(){this.addController({host:this,rootNode:null,checkIdReference(e){let n=this.host.getAttribute(o)??Y.get(this.host);if(n&&typeof n==`string`&&(!e||e.has(n))){let e=this.rootNode?.getElementById?.(n)??null;t.access.get(this.host)!==e&&t.access.set(this.host,e)}},hostConnected(){this.rootNode=this.host.getRootNode(),this.checkIdReference();let e=J.get(this.rootNode);if(e)e.controllers.add(this);else{let e=/* @__PURE__ */ new Set([this]),t=new MutationObserver(t=>{let n=/* @__PURE__ */ new Set;for(let e of t)if(e.type===`attributes`)e.oldValue&&n.add(e.oldValue),e.target.id&&n.add(e.target.id);else if(e.type===`childList`)for(let t of[...e.addedNodes,...e.removedNodes])t instanceof HTMLElement&&(t.id&&n.add(t.id),t.querySelectorAll(`[id]`).forEach(e=>{e.id&&n.add(e.id)}));e.forEach(e=>e.checkIdReference(n))});t.observe(this.rootNode,{attributeFilter:[`id`],attributeOldValue:!0,childList:!0,subtree:!0}),J.set(this.rootNode,{observer:t,controllers:e})}},hostDisconnected(){if(r||!this.rootNode)return;let e=J.get(this.rootNode);e&&(e.controllers.delete(this),e.controllers.size===0&&(e.observer.disconnect(),J.delete(this.rootNode))),this.rootNode=null}})}),{set(t){if(typeof t!=`string`)Y.delete(this),t instanceof HTMLElement&&this.hasAttribute(o)&&t.id!==this.getAttribute(o)&&this.removeAttribute(o);else if(this.hasAttribute(o)&&this.getAttribute(o)!==t)return;else{let e=t?this.getRootNode?.()?.getElementById?.(t):null;e?t=e:t&&=(Y.set(this,t),null)}e.set.call(this,t)}}}throw Error(`Unsupported decorator location: ${n}`)},Ir={toAttribute(e,t){let n=R().datetime?.dateAdapter??q;return n.isValid(e)?n.toIso8601(e):null}},Lr=e=>(t,n)=>{let{kind:r}=n;if(r===`accessor`)return{set(e){let n=R().datetime?.dateAdapter??q;e=n.getValidDateOrNull(n.deserialize(e)),e=e?n.createDate(n.getYear(e),n.getMonth(e),n.getDate(e)):null,t.set.call(this,e)},get(){let n=R().datetime?.dateAdapter??q,r=t.get.call(this);return n.isValid(r)?n.clone(r):e?.fallback?.(n)}};throw Error(`Unsupported decorator location: ${r}`)};function Rr(e,t){if(r||globalThis.disableAnimation)return!0;let n=getComputedStyle(e).getPropertyValue(t);return parseFloat(n)===0}function X(e,t){let n=t;for(;n;){if(n===e)return!0;n=n instanceof ShadowRoot?n.host:n.parentNode}return!1}function zr(e,t,n){n?e.setAttribute(t,n):e.removeAttribute(t)}function Br(e){let t=()=>queueMicrotask(e);document.readyState===`loading`?document.addEventListener(`DOMContentLoaded`,t):t()}function Z(){return document.body.hasAttribute(`data-sbb-scroll-disabled`)}function Vr(e){let t=getComputedStyle(e).overflowY;return(t===`auto`||t===`scroll`)&&e.scrollHeight>e.clientHeight}function Hr(e){for(let t of e){if(t===document.body||t===document.documentElement)break;if(t instanceof Element&&Vr(t))return t}return null}var Ur=class{constructor(){this._scrollPosition=0,this._touchStartY=0,this._touchStart=e=>{this._touchStartY=e.touches[0]?.clientY??0},this._touchMove=e=>{let t=e.touches[0];if(!t)return;let n=Hr(e.composedPath());if(!n){e.preventDefault();return}let r=t.clientY-this._touchStartY,i=n.scrollTop<=0,a=n.scrollTop+n.clientHeight>=n.scrollHeight;(i&&r>0||a&&r<0)&&e.preventDefault()}}disableScroll(){if(Z())return;this._scrollPosition=window.scrollY||document.documentElement.scrollTop,this._position=document.body.style.position,this._top=document.body.style.top,this._insetInline=document.body.style.insetInline,this._overflow=document.body.style.overflow;let e=window.innerWidth-document.documentElement.clientWidth;document.body.style.position=`fixed`,document.body.style.top=`-${this._scrollPosition}px`,document.body.style.insetInline=`0 ${e}px`,document.body.style.overflow=`hidden`,document.body.style.setProperty(`--sbb-scrollbar-reserved-space`,`${e}px`),document.addEventListener(`touchstart`,this._touchStart,{passive:!0}),document.addEventListener(`touchmove`,this._touchMove,{passive:!1}),document.body.toggleAttribute(`data-sbb-scroll-disabled`,!0)}enableScroll(){Z()&&(document.body.style.position=this._position||``,document.body.style.top=this._top||``,document.body.style.insetInline=this._insetInline||``,document.body.style.overflow=this._overflow||``,document.body.style.removeProperty(`--sbb-scrollbar-reserved-space`),document.removeEventListener(`touchstart`,this._touchStart),document.removeEventListener(`touchmove`,this._touchMove),document.body.removeAttribute(`data-sbb-scroll-disabled`),window.scrollTo(0,this._scrollPosition))}};function Wr(e){e.key===` `&&e.preventDefault()}function Gr(e,t){let n=Object.getPrototypeOf(e).constructor,r=new n(e.type,e);t.dispatchEvent(r)}const Kr=e=>{class t extends e{constructor(){super(...arguments),this.isAnimating=!1,this._animationPromise=Promise.resolve()}get animationComplete(){return this._animationPromise}disconnectedCallback(){super.disconnectedCallback(),this.stopAnimation()}startAnimation(){this.isAnimating||(this._animationPromise=this._enqueueAnimation())}stopAnimation(){}async _enqueueAnimation(){this.isAnimating=!0;let e=this.stopAnimation,t=new Promise(t=>{this.stopAnimation=()=>{e(),this.isAnimating=!1,t()}});try{await this._animationPromise}catch(e){Promise.reject(e)}return t}}return t},qr=e=>(()=>{let n=V(H(L(e))),r=[],i;return class extends n{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(n[Symbol.metadata]??null):void 0;i=[l({type:Boolean,converter:{...t,fromAttribute:(e,n)=>({value:t.fromAttribute?.(e,n),attribute:!0})}})],o(this,null,i,{kind:`setter`,name:`checked`,static:!1,private:!1,access:{has:e=>`checked`in e,set:(e,t)=>{e.checked=t}},metadata:e},null,r),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.role=`checkbox`}set checked(e){let t=typeof e==`object`&&e.attribute;t&&(e=e.value),this.hasUpdated&&!t&&(this._attributeMutationBlocked=!0),this._checked=!!e,this.updateFormValue()}get checked(){return this._checked}get type(){return`checkbox`}constructor(){super(),this._attributeMutationBlocked=(s(this,r),!1),this._languageController=new z(this),this._checked=!1,this._handleKeyboardInteraction=e=>{e.key===` `&&this._handleUserInteraction()},this._handleUserInteraction=()=>{this.disabled||(this.withUserInteraction?.(),this.checked=!this.checked,this._attributeMutationBlocked=!0,this.dispatchEvent(new InputEvent(`input`,{composed:!0,bubbles:!0})),this.dispatchEvent(new Event(`change`,{bubbles:!0})))},this.addEventListener?.(`click`,this._handleUserInteraction),this.addEventListener?.(`keydown`,Wr),this.addEventListener?.(`keyup`,this._handleKeyboardInteraction)}connectedCallback(){super.connectedCallback(),this.tabIndex=0}attributeChangedCallback(e,t,n){e===`checked`&&this._attributeMutationBlocked||super.attributeChangedCallback(e,t,n)}formResetCallback(){this.checked=this.hasAttribute(`checked`),this._attributeMutationBlocked=!1}formStateRestoreCallback(e,t){e&&(this.checked=e===`true`)}updateFormValue(){this.checked?super.updateFormValue():this.internals.setFormValue(null)}formState(){return`${this.checked}`}shouldValidate(e){return super.shouldValidate(e)||e===`checked`||e===`required`}validate(){super.validate(),this.required&&!this.checked?this.setValidityFlag(`valueMissing`,fn[this._languageController.current]):this.removeValidityFlag(`valueMissing`)}}})(),Jr=e=>(()=>{let t=e,n=[],r;return class extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;r=[l({type:Boolean,attribute:`readonly`})],o(this,null,r,{kind:`setter`,name:`readOnly`,static:!1,private:!1,access:{has:e=>`readOnly`in e,set:(e,t)=>{e.readOnly=t}},metadata:e},null,n),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}set readOnly(e){this.#e=!!e,this.toggleAttribute(`readonly`,this.#e)}get readOnly(){return this.#e}#e=(s(this,n),!1)}})(),Yr=(()=>{if(r)return!1;let e=document.createElement(`div`);return e.setAttribute(`contenteditable`,`PLAINTEXT-ONLY`),e.contentEditable===`plaintext-only`})(),Xr=e=>(()=>{let t=Jr(V(H(L(e)))),i=[],a,u,d;return class extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;a=[l()],u=[l({attribute:!1})],d=[c({passive:!0})],o(this,null,a,{kind:`setter`,name:`value`,static:!1,private:!1,access:{has:e=>`value`in e,set:(e,t)=>{e.value=t}},metadata:e},null,i),o(this,null,u,{kind:`setter`,name:`placeholder`,static:!1,private:!1,access:{has:e=>`placeholder`in e,set:(e,t)=>{e.placeholder=t}},metadata:e},null,i),o(this,null,d,{kind:`method`,name:`_cleanChildren`,static:!1,private:!1,access:{has:e=>`_cleanChildren`in e,get:e=>e._cleanChildren},metadata:e},null,i),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.role=`textbox`}static{this.formFieldAssociated=!0}get type(){return`text`}set value(e){this._value=this._cleanText(e),this.hasUpdated&&this._assignValue(this._value),this.dispatchEvent(new Event(`displayvaluechange`,{bubbles:!0,composed:!0}))}get value(){return this._value??``}set placeholder(e){e?this.setAttribute(`placeholder`,e):this.removeAttribute(`placeholder`),this.internals.ariaPlaceholder=e||null}get placeholder(){return this.getAttribute(`placeholder`)??``}constructor(){super(),this._shouldEmitChange=(s(this,i),!1),this._shouldTriggerSubmit=!1,this.language=new z(this),this._value=``,this.addEventListener?.(`input`,()=>{let e=this._value;this._value=this._cleanText(this.textContent??``),this.requestUpdate(`value`,e),this.internals.states.add(`interacted`),this._shouldEmitChange=!0},{capture:!0}),this.addEventListener?.(`change`,()=>this._shouldEmitChange=!1,{capture:!0}),this.addEventListener?.(`keydown`,e=>{this._requiresEmptyPatch()&&this._assignValue(``);let t=window.getSelection(),n=t?.getRangeAt(0);if(n&&!n.collapsed&&n.startContainer===this&&n.endContainer===this.lastChild&&n.selectNodeContents(this.lastChild),(e.key===`Enter`||e.key===`
43
+ `}}})();var Un=class{get size(){return this._handlers.size}constructor(e,t){this._host=e,this._property=t,this._handlers=/* @__PURE__ */ new Set,this._hostDefinedPromise=null,r||(customElements.get(this._host.localName)?customElements.upgrade(this._host):this._hostDefinedPromise=customElements.whenDefined(this._host.localName).then(()=>{customElements.upgrade(this._host),this._hostDefinedPromise=null})),this._value=this._host[this._property]}addHandler(e){this._handlers.size||(this._host.addController?this._host.addController(this):this._hostDefinedPromise&&this._hostDefinedPromise.then(()=>this._host.addController(this))),this._handlers.add(e),this._hostDefinedPromise?this._hostDefinedPromise.then(()=>e(this._host)):e(this._host)}removeHandler(e){this._handlers.delete(e),this._handlers.size||(this._host.removeController?this._host.removeController(this):this._hostDefinedPromise&&this._hostDefinedPromise.then(()=>this._host.removeController(this)))}hostUpdate(){let e=this._host[this._property];if(this._value!==e){this._value=e;for(let e of this._handlers)e(this._host)}}};const U=/* @__PURE__ */ new WeakMap;var Wn=class{constructor(e,t,n){this._host=e,this._referenceResolver=t,this._handlers=n,this._host.addController(this)}hostConnected(){this.connect()}hostDisconnected(){this._reference!==this._referenceResolver()&&this.disconnect()}connect(){let e=this._referenceResolver();if(this._reference===e||(this.disconnect(),this._reference=e,!this._reference))return;let t=U.get(this._reference);t||(t=/* @__PURE__ */ new Map,U.set(this._reference,t)),this._watchers=t;for(let[e,t]of Object.entries(this._handlers)){let n=this._watchers.get(e);n||(n=new Un(this._reference,e),this._watchers.set(e,n)),n.addHandler(t)}}disconnect(){if(this._reference){for(let[e,t]of Object.entries(this._handlers)){let n=this._watchers?.get(e);n&&(n.removeHandler(t),n.size||(this._watchers.delete(e),!this._watchers.size&&this._reference&&U.delete(this._reference)))}this._reference=null}}};const Gn=[];r||window.addEventListener(`keydown`,e=>{e.key===`Escape`&&!e.defaultPrevented&&(e.preventDefault(),Gn.at(-1)?.escapeStrategy())});var Kn=class{constructor(e,t=Gn){this._host=e,this._overlayStack=t,this._host.addController?.(this)}hostDisconnected(){this.disconnect()}connect(){this.disconnect(),this._overlayStack.push(this._host)}disconnect(){if(this._overlayStack.length){let e=this._overlayStack.findIndex(e=>e===this._host);e!==-1&&this._overlayStack.splice(e,1)}}};const qn=/* @__PURE__ */ new WeakMap;var Jn=class{constructor(e,t,n=qn){this._host=e,this._idRef=t,this._observers=n,this._rootNode=null,this._host.addController(this)}hostConnected(){if(r)return;this._rootNode=this._host.getRootNode();let e=this._observers.get(this._rootNode);if(e)e.controllers.add(this);else{let e=/* @__PURE__ */ new Set([this]),t=new MutationObserver(t=>{let n=/* @__PURE__ */ new Set;for(let e of t)if(e.type===`attributes`)n.add(e.oldValue),n.add(e.target.id);else if(e.type===`childList`)for(let t of[...e.addedNodes,...e.removedNodes])t instanceof HTMLElement&&(n.add(t.id),t.querySelectorAll(`[id]`).forEach(e=>n.add(e.id)));for(let t of e){let e=t._host[t._idRef];e&&typeof e==`string`&&n.has(e)&&t._host.requestUpdate()}});t.observe(this._rootNode,{attributeFilter:[`id`],childList:!0,subtree:!0,attributeOldValue:!0}),this._observers.set(this._rootNode,{observer:t,controllers:e})}}hostDisconnected(){if(r||!this._rootNode)return;let e=this._observers.get(this._rootNode);e&&(e.controllers.delete(this),e.controllers.size===0&&(e.observer.disconnect(),this._observers.delete(this._rootNode))),this._rootNode=null}find(){if(r||!this._rootNode)return null;{let e=this._host[this._idRef];return typeof e==`string`?this._rootNode?.getElementById(e):null}}};const Yn=[`script`,`head`,`template`,`style`,`link`],Xn=/* @__PURE__ */ new Set,Zn=/* @__PURE__ */ new Set,Qn=/* @__PURE__ */ new Set;var $n=class{constructor(e,t=Xn,n=Qn,r=Zn){this._host=e,this._inertElements=t,this._inertOverlays=n,this._exemptedElements=r,this._host.addController?.(this)}hostConnected(){this._host.isOpen&&this.activate()}hostDisconnected(){this.isInert()&&this.deactivate()}activate(){this._inertOverlays.size&&this._removeAllInertAttributes(),this._inertOverlays.add(this._host),this._addAllInertAttributes()}deactivate(){this._currentOverlay()===this._host?(this._removeAllInertAttributes(),this._inertOverlays.delete(this._host),this._inertOverlays.size&&this._addAllInertAttributes()):this._inertOverlays.has(this._host)&&this._inertOverlays.delete(this._host)}isInert(){return this._inertOverlays.has(this._host)}exempt(e){this._inertElements.has(e)&&!this._exemptedElements.has(e)&&(this._removeInertAttributes(e),this._inertElements.delete(e),this._exemptedElements.add(e))}restoreAllExempted(){this._exemptedElements.forEach(e=>this._addInertAttributes(e)),this._exemptedElements.clear()}_currentOverlay(){return[...this._inertOverlays].pop()??null}_removeAllInertAttributes(){this._inertElements.forEach(e=>this._removeInertAttributes(e)),this._inertElements.clear()}_removeInertAttributes(e){e&&(e.hasAttribute(`data-sbb-inert`)&&(e.inert=!1,e.removeAttribute(`data-sbb-inert`)),e.hasAttribute(`data-sbb-aria-hidden`)&&(e.removeAttribute(`aria-hidden`),e.removeAttribute(`data-sbb-aria-hidden`)))}_addAllInertAttributes(){let e=this._currentOverlay(),t=e?[e]:[],n=[document.documentElement];for(;n.length>0;)for(let e of n.shift().querySelectorAll(`*`))e.matches(`sbb-toast,.sbb-overlay-outlet,.sbb-live-announcer-element,.cdk-live-announcer-element,.cdk-overlay-container`)&&t.push(e),e.shadowRoot&&n.push(e.shadowRoot);let r=[],i=e=>r.push(...e.composedPath());for(let e of t)e.addEventListener(`ɵinert`,i,{once:!0}),e.dispatchEvent(new Event(`ɵinert`,{composed:!0}));let a=new Set(r),o=/* @__PURE__ */ new Set;for(let e of a)for(let t of e.parentNode?.childNodes??[])t.nodeType===Node.ELEMENT_NODE&&!Yn.includes(t.localName)&&!a.has(t)&&o.add(t);for(let e of o)this._addInertAttributes(e)}_addInertAttributes(e){this._inertElements.add(e),e.inert||(e.inert=!0,e.toggleAttribute(`data-sbb-inert`,!0)),e.hasAttribute(`aria-hidden`)||(e.setAttribute(`aria-hidden`,`true`),e.toggleAttribute(`data-sbb-aria-hidden`,!0))}};const er=`(forced-colors: active)`,W=`(prefers-color-scheme: dark)`,tr=`(any-hover: hover)`,nr=`(pointer: coarse)`,rr=`(min-width: 0rem)`,ir=`(min-width: 37.5rem)`,ar=`(min-width: 64rem)`,or=`(min-width: 90rem)`,sr=`(max-width: 63.9375rem)`,cr=`(max-width: 89.9375rem)`,G=/* @__PURE__ */ new Map;var lr=class{constructor(e,t){this._queries=t,e.addController(this)}matches(e){return r?null:matchMedia(e).matches}hostConnected(){if(!r)for(let[e,t]of Object.entries(this._queries)){let n=G.get(e);if(n)n.handlers.add(t);else{let n=matchMedia(e),r=/* @__PURE__ */ new Set([t]),i=e=>r.forEach(t=>t(e.matches));n.addEventListener(`change`,i),G.set(e,{mediaQueryList:n,handlers:r,eventHandler:i})}}}hostDisconnected(){for(let[e,t]of Object.entries(this._queries)){let n=G.get(e);n&&(n.handlers.delete(t),n.handlers.size||G.delete(e))}}},ur=class e extends lr{static{this._currentMode=this._readLightDarkClass()}static{this._observer=r?null:new MutationObserver(t=>{if(t[0].oldValue!==document.documentElement.getAttribute(`class`)){let t=this._readLightDarkClass();this._currentMode!==t&&(e.requestUpdate(),this._currentMode=t)}})}static{this._observerConfig={attributeFilter:[`class`],attributeOldValue:!0}}constructor(e,t){let n=()=>{t(this.matches()),this._host.toggleState?.(`dark`,this.matches())};super(e,{[W]:n}),this._host=e,this._onChangeWithStateUpdater=n}static _readLightDarkClass(){if(r)return null;let e=document.documentElement.classList;return[`sbb-light-dark`,`sbb-dark`,`sbb-light`].find(t=>e.contains(t))??null}static requestUpdate(){let e=G.get(W);e&&e.handlers.forEach(t=>t(e.mediaQueryList.matches))}hostConnected(){let t=(G.get(`(prefers-color-scheme: dark)`)?.handlers.size??0)===0;super.hostConnected(),t&&e._observer.observe(document.documentElement,e._observerConfig),this._onChangeWithStateUpdater()}hostDisconnected(){super.hostDisconnected(),(G.get(`(prefers-color-scheme: dark)`)?.handlers.size??0)===0&&e._observer.disconnect()}matches(){if(r)return!1;let e=getComputedStyle(this._host).getPropertyValue(`color-scheme`),t=e.includes(`dark`),n=e.trim()===`dark`;return super.matches(`(prefers-color-scheme: dark)`)&&t||n}};const dr=!r&&CSS.supports(`anchor-name`,`--test`),fr=[`top`,`bottom`,`left`,`right`,`top span-left`,`top span-right`,`bottom span-left`,`bottom span-right`,`left span-top`,`left span-bottom`,`right span-top`,`right span-bottom`],pr=[`block-start`,`block-end`,`inline-start`,`inline-end`,`block-start span-inline-start`,`block-start span-inline-end`,`block-end span-inline-start`,`block-end span-inline-end`,`inline-start span-block-start`,`inline-start span-block-end`,`inline-end span-block-start`,`inline-end span-block-end`],mr={"block-start":`block-start`,"block-end":`block-end`,"inline-start":`inline-end`,"inline-end":`inline-start`,"block-start span-inline-start":`block-start span-inline-end`,"block-start span-inline-end":`block-start span-inline-start`,"block-end span-inline-start":`block-end span-inline-end`,"block-end span-inline-end":`block-end span-inline-start`,"inline-start span-block-start":`inline-end span-block-start`,"inline-start span-block-end":`inline-end span-block-end`,"inline-end span-block-start":`inline-start span-block-start`,"inline-end span-block-end":`inline-start span-block-end`};[...fr,...pr];let hr=0;var gr=class{get currentPosition(){return this._usePolyfill?this._lastPosition??this._positions[0]??``:(this._overlayStyles??=getComputedStyle(this._overlay),this._overlayStyles.getPropertyValue(`position-area`))}constructor(e,t=!dr){this._usePolyfill=t,this._resizeObserver=r?null:new ResizeObserver(()=>this._requestCalculatePosition()),this._anchorName=`--sbb-overlay-anchor-${++hr}`,this._positions=[],e.addController(this),this._overlay=e}hostConnected(){this._usePolyfill?this._overlay.style.setProperty(`position-area`,`initial`):this._overlay.style.setProperty(`position-anchor`,this._anchorName)}hostUpdate(){r||this._readPositionsFromCss()}connect(e){r||(this._anchor&&this.disconnect(),this._anchor=e,this._usePolyfill||this._anchor.style.setProperty(`anchor-name`,this._anchorName),this._readPositionsFromCss(),this._calculatePosition(),this._abortController?.abort(),this._abortController=new AbortController,document.addEventListener(`scroll`,()=>this._requestCalculatePosition(),{capture:!0,passive:!0,signal:this._abortController.signal}),window.addEventListener(`resize`,()=>this._requestCalculatePosition(),{passive:!0,signal:this._abortController.signal}),this._resizeObserver.observe(e,{box:`border-box`}),this._resizeObserver.observe(this._overlay,{box:`border-box`}))}disconnect(){this._anchor?.style.removeProperty(`anchor-name`),this._anchor=void 0,this._abortController?.abort(),this._resizeObserver.disconnect()}_requestCalculatePosition(){this._frame??=requestAnimationFrame(()=>{this._calculatePosition(),this._frame=void 0})}_calculatePosition(){if(this._anchor){if(this._usePolyfill){let e=this._getOptimalPosition(this._positions);this._applyOverlayPosition(e.position,e.left,e.top)}this._overlay.setAttribute(`data-position`,this.currentPosition)}}_getOptimalPosition(e){let{offsetHeight:t,offsetWidth:n}=this._overlay,{innerHeight:r,innerWidth:i}=window,{top:a,left:o,height:s,width:c}=this._anchor.getBoundingClientRect(),l=this._overlay.matches(`:dir(rtl)`),u=a,d=r-s-a,f=o,p=i-c-o,m=n-c,h=t-s,g=m/2,_=h/2;this._overlay.style.setProperty(`--sbb-overlay-controller-trigger-height`,`${s}px`),this._overlay.style.setProperty(`--sbb-overlay-controller-trigger-width`,`${c}px`);let v={left:0,top:0,position:``},y;for(let r of e){switch(l&&pr.includes(r)?mr[r]:r){default:case`bottom`:case`block-end`:v={position:r,left:o-g,top:a+s,fits:t<=d&&g<=f&&g<=p};break;case`top`:case`block-start`:v={position:r,left:o-g,top:a-t,fits:t<=u&&g<=f&&g<=p};break;case`right`:case`inline-end`:v={position:r,left:o+c,top:a-_,fits:n<=p&&_<=u&&_<=d};break;case`left`:case`inline-start`:v={position:r,left:o-n,top:a-_,fits:n<=f&&_<=u&&_<=d};break;case`top span-left`:case`block-start span-inline-start`:v={position:r,left:o-m,top:a-t,fits:t<=u&&m<=f};break;case`top span-right`:case`block-start span-inline-end`:v={position:r,left:o,top:a-t,fits:t<=u&&m<=p};break;case`bottom span-left`:case`block-end span-inline-start`:v={position:r,left:o-m,top:a+s,fits:t<=d&&m<=f};break;case`bottom span-right`:case`block-end span-inline-end`:v={position:r,left:o,top:a+s,fits:t<=d&&m<=p};break;case`left span-top`:case`inline-start span-block-start`:v={position:r,left:o-n,top:a+s-t,fits:n<=f&&h<=u};break;case`left span-bottom`:case`inline-start span-block-end`:v={position:r,left:o-n,top:a,fits:n<=f&&h<=d};break;case`right span-top`:case`inline-end span-block-start`:v={position:r,left:o+c,top:a+s-t,fits:n<=p&&h<=u};break;case`right span-bottom`:case`inline-end span-block-end`:v={position:r,left:o+c,top:a,fits:n<=p&&h<=d}}if(v.fits)return v;y??=v}return y}_applyOverlayPosition(e,t,n){this._lastPosition=e,this._overlay.style.left=`${t}px`,this._overlay.style.top=`${n}px`}_readPositionsFromCss(){if(!this._usePolyfill)return;this._overlayStyles??=getComputedStyle(this._overlay);let e=[this._overlayStyles.getPropertyValue(`--sbb-overlay-position-area`)||`block-end`,...this._overlayStyles.getPropertyValue(`--sbb-overlay-position-try-fallbacks`).split(`,`).map(e=>e.trim()).filter(e=>!!e)];this._positions=e,this._lastPosition&&!this._positions.includes(this._lastPosition)&&(this._lastPosition=void 0)}};const _r=/* @__PURE__ */ new Set;var vr=class{constructor(e,t=_r){this._host=e,this._lockers=t,this._locked=!1,this._scrollProperties={scrollPosition:0,touchStartY:0},this._touchStart=e=>{this._scrollProperties.touchStartY=e.touches[0]?.clientY??0},this._touchMove=e=>{let t=e.touches[0];if(!t)return;let n=this._findScrollableAncestor(e.composedPath());if(!n){e.preventDefault();return}let r=t.clientY-this._scrollProperties.touchStartY,i=n.scrollTop<=0,a=n.scrollTop+n.clientHeight>=n.scrollHeight;(i&&r>0||a&&r<0)&&e.preventDefault()},this._host.addController?.(this)}_isVerticallyScrollable(e){let t=getComputedStyle(e).overflowY;return(t===`auto`||t===`scroll`)&&e.scrollHeight>e.clientHeight}_findScrollableAncestor(e){for(let t of e){if(t===document.body||t===document.documentElement)break;if(t instanceof Element&&this._isVerticallyScrollable(t))return t}return null}hostDisconnected(){this.enableScroll()}disableScroll(){if(this._locked)return;this._locked=!0;let e=this._lockers.size===0;if(this._lockers.add(this._host),!e)return;this._scrollProperties.scrollPosition=window.scrollY||document.documentElement.scrollTop,this._scrollProperties.savedPosition=document.body.style.position,this._scrollProperties.savedTop=document.body.style.top,this._scrollProperties.savedInsetInline=document.body.style.insetInline,this._scrollProperties.savedOverflow=document.body.style.overflow,this._scrollProperties.savedMinHeight=document.body.style.minHeight;let t=window.innerWidth-document.documentElement.clientWidth;document.body.style.position=`fixed`,document.body.style.top=`-${this._scrollProperties.scrollPosition}px`,document.body.style.insetInline=`0 ${t}px`,document.body.style.overflow=`hidden`,document.body.style.setProperty(`--sbb-scrollbar-reserved-space`,`${t}px`),document.body.style.minHeight=`100dvh`,document.addEventListener(`touchstart`,this._touchStart,{passive:!0}),document.addEventListener(`touchmove`,this._touchMove,{passive:!1}),document.body.toggleAttribute(`data-sbb-scroll-disabled`,!0)}enableScroll(){this._locked&&(this._locked=!1,this._lockers.delete(this._host),this._lockers.size>0||(document.body.style.position=this._scrollProperties.savedPosition||``,document.body.style.top=this._scrollProperties.savedTop||``,document.body.style.insetInline=this._scrollProperties.savedInsetInline||``,document.body.style.overflow=this._scrollProperties.savedOverflow||``,document.body.style.removeProperty(`--sbb-scrollbar-reserved-space`),document.body.style.minHeight=this._scrollProperties.savedMinHeight||``,document.removeEventListener(`touchstart`,this._touchStart),document.removeEventListener(`touchmove`,this._touchMove),document.body.removeAttribute(`data-sbb-scroll-disabled`),window.scrollTo(0,this._scrollProperties.scrollPosition)))}},yr=class{constructor(e){this._abortController=new AbortController,this._host=e,e.addController(this),e.tabIndex=-1,e.addEventListener(`blur`,()=>this._purge(),{once:!0,signal:this._abortController.signal})}hostDisconnected(){this._abortController.abort(),this._purge()}_purge(){this._host.removeController(this),this._host.removeAttribute(`tabindex`)}};const br=/(0?[1-9]|[12][0-9]|3[01])[.,\\/\-\s](0?[1-9]|1[0-2])[.,\\/\-\s]([0-9]{1,4}$)?/,xr=/([0-9]{2})([0-9]{2})([0-9]{4})/,Sr=/^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-3][0-9])$/,Cr=1,wr=2,Tr=3,Er=4,Dr=5,Or=6,kr=0;var K=class{constructor(e=15){this._cutoffYearOffset=e}deserialize(e){return e==null||this.isDateInstance(e)&&this.isValid(e)?e:this.invalid()}parse(e){if(!e)return null;let t=null,n=e.match(Sr);try{t=n?this.createDate(+n[1],+n[2],+n[3]):null}catch{}if(this.isValid(t))return t;let r=e.replace(/\D/g,` `).trim()?.match(br)??e.match(xr);try{t=r?this.createDate(+r[3],+r[2],+r[1]):null}catch{}if(!r||r.index!==0||r.length<=2||r.some(e=>e===void 0)||!this.isValid(t))return null;let i=+r[3];if(typeof i==`number`&&i<100&&i>=0){let e=this.getYear(this.today())-2e3+this._cutoffYearOffset;i=i<=e?2e3+i:1900+i}return this.createDate(i,+r[2],+r[1])}format(e,t){if(!this.isValid(e))return``;let n=/* @__PURE__ */ new Date(this.toIso8601(e)+`T00:00:00`),r=new Intl.DateTimeFormat(`de-CH`,{day:`2-digit`,month:`2-digit`,year:`numeric`});if(t?.weekdayStyle===`none`)return r.format(n);let i=t?.weekdayStyle??`short`,a=this.getDayOfWeekNames(i)[this.getDayOfWeek(e)];return a=a.charAt(0).toUpperCase()+a.substring(1),i===`short`&&(a=a.substring(0,2)),`${a}, ${r.format(n)}`}toIso8601(e){let t=(e,t=2)=>`${e}`.padStart(t,`0`);return`${t(this.getYear(e),4)}-${t(this.getMonth(e))}-${t(this.getDate(e))}`}getValidDateOrNull(e){return this.isDateInstance(e)&&this.isValid(e)?e:null}getFirstWeekOffset(e){let t=this.createDate(this.getYear(e),this.getMonth(e),1);return(7+this.getDayOfWeek(t)-this.getFirstDayOfWeek())%7}compareDate(e,t){return this.getYear(e)-this.getYear(t)||this.getMonth(e)-this.getMonth(t)||this.getDate(e)-this.getDate(t)}sameDate(e,t){if(e&&t){let n=this.isValid(e),r=this.isValid(t);return n&&r?!this.compareDate(e,t):n==r}return e==t}clampDate(e,t,n){return t&&this.compareDate(e,t)<0?t:n&&this.compareDate(e,n)>0?n:e}};const Ar=/^\d{4}-\d{2}-\d{2}(?:T\d{2}:\d{2}:\d{2}(?:\.\d+)?(?:Z|(?:(?:\+|-)\d{2}:\d{2}))?)?$/;var jr=class extends K{getYear(e){return e.getFullYear()}getMonth(e){return e.getMonth()+1}getDate(e){return e.getDate()}getDayOfWeek(e){return e.getDay()}getAccessibilityFormatDate(e){return new Intl.DateTimeFormat(z.current,{year:`numeric`,month:`long`,day:`numeric`}).format(new Date(e))}getMonthNames(e){let t=new Intl.DateTimeFormat(z.current,{month:e});return this._range(12,e=>t.format(new Date(2017,e,1)))}getDateNames(){let e=new Intl.DateTimeFormat(z.current,{day:`numeric`});return this._range(31,t=>e.format(new Date(2017,0,t+1)))}getDayOfWeekNames(e){let t=new Intl.DateTimeFormat(z.current,{weekday:e});return this._range(7,e=>t.format(new Date(2017,0,e+1)))}getFirstDayOfWeek(){return 1}getNumDaysInMonth(e){return this.getDate(this._createDateWithOverflow(this.getYear(e),this.getMonth(e),0))}today(){return new Date((/* @__PURE__ */ new Date()).setHours(0,0,0,0))}createDate(e,t,n){if(t<1||t>12)throw Error(`Invalid month "${t}". Month has to be between 1 and 12.`);if(n<1)throw Error(`Invalid day "${n}". Day has to be greater than 0.`);let r=this._createDateWithOverflow(e,t-1,n);if(r.getMonth()+1!==t)throw Error(`Invalid day "${n}" for month "${t}".`);return r}isDateInstance(e){return e instanceof Date}isValid(e){return!!e&&!isNaN(e.valueOf())}clone(e){return new Date(e.valueOf())}addCalendarYears(e,t){return this.addCalendarMonths(e,t*12)}addCalendarMonths(e,t){let n=e.getMonth()+t,r=new Date(e.getFullYear(),n,1,0,0,0,0),i=this.getNumDaysInMonth(r);return new Date(this.clone(e).setMonth(n,Math.min(i,e.getDate())))}addCalendarDays(e,t){let n=e.getDate()+t;return new Date(e.getFullYear(),e.getMonth(),n,0,0,0,0)}deserialize(e){if(typeof e==`string`){if(!e)return null;if(Ar.test(e))return this.getValidDateOrNull(new Date(e.includes(`T`)?e:e+`T00:00:00`))}return super.deserialize(e)}invalid(){return/* @__PURE__ */ new Date(NaN)}_range(e,t){return Array.from({length:e},(e,n)=>t(n))}_createDateWithOverflow(e,t,n){let r=new Date(e,t,n);return e>=0&&e<100&&r.setFullYear(this.getYear(r)-1900),r}};const q=new jr,Mr=/^\d{4}-\d{2}-\d{2}(?:T\d{2}:\d{2}:\d{2}(?:\.\d+)?(?:Z|(?:(?:\+|-)\d{2}:\d{2}))?)?$/;var Nr=class extends K{constructor(e){if(super(e),typeof Temporal!=`object`)throw Error(`Temporal is not available in the current environment. Please make sure to include the temporal polyfill.`)}getYear(e){return e.year}getMonth(e){return e.month}getDate(e){return e.day}getDayOfWeek(e){return e.dayOfWeek%7}getAccessibilityFormatDate(e){return this.deserialize(e).toLocaleString(z.current,{year:`numeric`,month:`long`,day:`numeric`})}getMonthNames(e){let t=new Intl.DateTimeFormat(z.current,{month:e});return this._range(12,e=>t.format(Temporal.PlainDate.from({year:2017,month:e+1,day:1})))}getDateNames(){let e=new Intl.DateTimeFormat(z.current,{day:`numeric`});return this._range(31,t=>e.format(Temporal.PlainDate.from({year:2017,month:1,day:t+1})))}getDayOfWeekNames(e){let t=new Intl.DateTimeFormat(z.current,{weekday:e});return this._range(7,e=>t.format(Temporal.PlainDate.from({year:2017,month:1,day:e+1})))}getFirstDayOfWeek(){return 1}getNumDaysInMonth(e){return e.daysInMonth}today(){return Temporal.Now.plainDateISO()}createDate(e,t,n){if(t<1||t>12)throw Error(`Invalid month "${t}". Month has to be between 1 and 12.`);if(n<1)throw Error(`Invalid day "${n}". Day has to be greater than 0.`);try{return Temporal.PlainDate.from({year:e,month:t,day:n},{overflow:`reject`})}catch{throw Error(`Invalid date "${n}" for month with index "${t}".`)}}isDateInstance(e){return e instanceof Temporal.PlainDate}isValid(e){return this.isDateInstance(e)}clone(e){return Temporal.PlainDate.from(e)}addCalendarYears(e,t){return e.add({years:t})}addCalendarMonths(e,t){return e.add({months:t})}addCalendarDays(e,t){return e.add({days:t})}deserialize(e){if(typeof e==`string`){if(!e)return null;if(Mr.test(e))return this.getValidDateOrNull(Temporal.PlainDate.from(e.split(`T`)[0]))}return super.deserialize(e)}invalid(){return null}toIso8601(e){return e.toJSON()}_range(e,t){return Array.from({length:e},(e,n)=>t(n))}};const Pr=e=>(t,n)=>{let{kind:r}=n;if(r===`accessor`)return{get(){let n=t.get.call(this);return e(this,n)}};throw Error(`Unsupported decorator location: ${r}`)},Fr=e=>(t,n)=>{let{kind:r}=n;if(r===`accessor`)return{set(r){let i=n.access.get(this);t.set.call(this,r);let a=n.access.get(this);a!==i&&e(this,a,i)}};throw Error(`Unsupported decorator location: ${r}`)},J=/* @__PURE__ */ new WeakMap,Y=/* @__PURE__ */ new WeakMap,Ir=()=>(e,t)=>{let{kind:n,metadata:i,name:a}=t;if(n===`accessor`){if(r)return{};let n=globalThis.litPropertyMetadata.get(i)?.get(a)?.attribute,o=typeof n==`string`?n:a;return t.addInitializer(function(){this.addController({host:this,rootNode:null,checkIdReference(e){let n=this.host.getAttribute(o)??Y.get(this.host);if(n&&typeof n==`string`&&(!e||e.has(n))){let e=this.rootNode?.getElementById?.(n)??null;t.access.get(this.host)!==e&&t.access.set(this.host,e)}},hostConnected(){this.rootNode=this.host.getRootNode(),this.checkIdReference();let e=J.get(this.rootNode);if(e)e.controllers.add(this);else{let e=/* @__PURE__ */ new Set([this]),t=new MutationObserver(t=>{let n=/* @__PURE__ */ new Set;for(let e of t)if(e.type===`attributes`)e.oldValue&&n.add(e.oldValue),e.target.id&&n.add(e.target.id);else if(e.type===`childList`)for(let t of[...e.addedNodes,...e.removedNodes])t instanceof HTMLElement&&(t.id&&n.add(t.id),t.querySelectorAll(`[id]`).forEach(e=>{e.id&&n.add(e.id)}));e.forEach(e=>e.checkIdReference(n))});t.observe(this.rootNode,{attributeFilter:[`id`],attributeOldValue:!0,childList:!0,subtree:!0}),J.set(this.rootNode,{observer:t,controllers:e})}},hostDisconnected(){if(r||!this.rootNode)return;let e=J.get(this.rootNode);e&&(e.controllers.delete(this),e.controllers.size===0&&(e.observer.disconnect(),J.delete(this.rootNode))),this.rootNode=null}})}),{set(t){if(typeof t!=`string`)Y.delete(this),t instanceof HTMLElement&&this.hasAttribute(o)&&t.id!==this.getAttribute(o)&&this.removeAttribute(o);else if(this.hasAttribute(o)&&this.getAttribute(o)!==t)return;else{let e=t?this.getRootNode?.()?.getElementById?.(t):null;e?t=e:t&&=(Y.set(this,t),null)}e.set.call(this,t)}}}throw Error(`Unsupported decorator location: ${n}`)},Lr={toAttribute(e,t){let n=R().datetime?.dateAdapter??q;return n.isValid(e)?n.toIso8601(e):null}},Rr=e=>(t,n)=>{let{kind:r}=n;if(r===`accessor`)return{set(e){let n=R().datetime?.dateAdapter??q;e=n.getValidDateOrNull(n.deserialize(e)),e=e?n.createDate(n.getYear(e),n.getMonth(e),n.getDate(e)):null,t.set.call(this,e)},get(){let n=R().datetime?.dateAdapter??q,r=t.get.call(this);return n.isValid(r)?n.clone(r):e?.fallback?.(n)}};throw Error(`Unsupported decorator location: ${r}`)};function zr(e,t){if(r||globalThis.disableAnimation)return!0;let n=getComputedStyle(e).getPropertyValue(t);return parseFloat(n)===0}function X(e,t){let n=t;for(;n;){if(n===e)return!0;n=n instanceof ShadowRoot?n.host:n.parentNode}return!1}function Br(e,t,n){n?e.setAttribute(t,n):e.removeAttribute(t)}function Vr(e){let t=()=>queueMicrotask(e);document.readyState===`loading`?document.addEventListener(`DOMContentLoaded`,t):t()}function Z(){return document.body.hasAttribute(`data-sbb-scroll-disabled`)}function Hr(e){let t=getComputedStyle(e).overflowY;return(t===`auto`||t===`scroll`)&&e.scrollHeight>e.clientHeight}function Ur(e){for(let t of e){if(t===document.body||t===document.documentElement)break;if(t instanceof Element&&Hr(t))return t}return null}var Wr=class{constructor(){this._scrollPosition=0,this._touchStartY=0,this._touchStart=e=>{this._touchStartY=e.touches[0]?.clientY??0},this._touchMove=e=>{let t=e.touches[0];if(!t)return;let n=Ur(e.composedPath());if(!n){e.preventDefault();return}let r=t.clientY-this._touchStartY,i=n.scrollTop<=0,a=n.scrollTop+n.clientHeight>=n.scrollHeight;(i&&r>0||a&&r<0)&&e.preventDefault()}}disableScroll(){if(Z())return;this._scrollPosition=window.scrollY||document.documentElement.scrollTop,this._position=document.body.style.position,this._top=document.body.style.top,this._insetInline=document.body.style.insetInline,this._overflow=document.body.style.overflow;let e=window.innerWidth-document.documentElement.clientWidth;document.body.style.position=`fixed`,document.body.style.top=`-${this._scrollPosition}px`,document.body.style.insetInline=`0 ${e}px`,document.body.style.overflow=`hidden`,document.body.style.setProperty(`--sbb-scrollbar-reserved-space`,`${e}px`),document.addEventListener(`touchstart`,this._touchStart,{passive:!0}),document.addEventListener(`touchmove`,this._touchMove,{passive:!1}),document.body.toggleAttribute(`data-sbb-scroll-disabled`,!0)}enableScroll(){Z()&&(document.body.style.position=this._position||``,document.body.style.top=this._top||``,document.body.style.insetInline=this._insetInline||``,document.body.style.overflow=this._overflow||``,document.body.style.removeProperty(`--sbb-scrollbar-reserved-space`),document.removeEventListener(`touchstart`,this._touchStart),document.removeEventListener(`touchmove`,this._touchMove),document.body.removeAttribute(`data-sbb-scroll-disabled`),window.scrollTo(0,this._scrollPosition))}};function Gr(e){e.key===` `&&e.preventDefault()}function Kr(e,t){let n=Object.getPrototypeOf(e).constructor,r=new n(e.type,e);t.dispatchEvent(r)}const qr=e=>{class t extends e{constructor(){super(...arguments),this.isAnimating=!1,this._animationPromise=Promise.resolve()}get animationComplete(){return this._animationPromise}disconnectedCallback(){super.disconnectedCallback(),this.stopAnimation()}startAnimation(){this.isAnimating||(this._animationPromise=this._enqueueAnimation())}stopAnimation(){}async _enqueueAnimation(){this.isAnimating=!0;let e=this.stopAnimation,t=new Promise(t=>{this.stopAnimation=()=>{e(),this.isAnimating=!1,t()}});try{await this._animationPromise}catch(e){Promise.reject(e)}return t}}return t},Jr=e=>(()=>{let n=V(H(L(e))),r=[],i;return class extends n{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(n[Symbol.metadata]??null):void 0;i=[l({type:Boolean,converter:{...t,fromAttribute:(e,n)=>({value:t.fromAttribute?.(e,n),attribute:!0})}})],o(this,null,i,{kind:`setter`,name:`checked`,static:!1,private:!1,access:{has:e=>`checked`in e,set:(e,t)=>{e.checked=t}},metadata:e},null,r),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.role=`checkbox`}set checked(e){let t=typeof e==`object`&&e.attribute;t&&(e=e.value),this.hasUpdated&&!t&&(this._attributeMutationBlocked=!0),this._checked=!!e,this.updateFormValue()}get checked(){return this._checked}get type(){return`checkbox`}constructor(){super(),this._attributeMutationBlocked=(s(this,r),!1),this._languageController=new z(this),this._checked=!1,this._handleKeyboardInteraction=e=>{e.key===` `&&this._handleUserInteraction()},this._handleUserInteraction=()=>{this.disabled||(this.withUserInteraction?.(),this.checked=!this.checked,this._attributeMutationBlocked=!0,this.dispatchEvent(new InputEvent(`input`,{composed:!0,bubbles:!0})),this.dispatchEvent(new Event(`change`,{bubbles:!0})))},this.addEventListener?.(`click`,this._handleUserInteraction),this.addEventListener?.(`keydown`,Gr),this.addEventListener?.(`keyup`,this._handleKeyboardInteraction)}connectedCallback(){super.connectedCallback(),this.tabIndex=0}attributeChangedCallback(e,t,n){e===`checked`&&this._attributeMutationBlocked||super.attributeChangedCallback(e,t,n)}formResetCallback(){this.checked=this.hasAttribute(`checked`),this._attributeMutationBlocked=!1}formStateRestoreCallback(e,t){e&&(this.checked=e===`true`)}updateFormValue(){this.checked?super.updateFormValue():this.internals.setFormValue(null)}formState(){return`${this.checked}`}shouldValidate(e){return super.shouldValidate(e)||e===`checked`||e===`required`}validate(){super.validate(),this.required&&!this.checked?this.setValidityFlag(`valueMissing`,fn[this._languageController.current]):this.removeValidityFlag(`valueMissing`)}}})(),Yr=e=>(()=>{let t=e,n=[],r;return class extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;r=[l({type:Boolean,attribute:`readonly`})],o(this,null,r,{kind:`setter`,name:`readOnly`,static:!1,private:!1,access:{has:e=>`readOnly`in e,set:(e,t)=>{e.readOnly=t}},metadata:e},null,n),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}set readOnly(e){this.#e=!!e,this.toggleAttribute(`readonly`,this.#e)}get readOnly(){return this.#e}#e=(s(this,n),!1)}})(),Xr=(()=>{if(r)return!1;let e=document.createElement(`div`);return e.setAttribute(`contenteditable`,`PLAINTEXT-ONLY`),e.contentEditable===`plaintext-only`})(),Zr=e=>(()=>{let t=Yr(V(H(L(e)))),i=[],a,u,d;return class extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;a=[l()],u=[l({attribute:!1})],d=[c({passive:!0})],o(this,null,a,{kind:`setter`,name:`value`,static:!1,private:!1,access:{has:e=>`value`in e,set:(e,t)=>{e.value=t}},metadata:e},null,i),o(this,null,u,{kind:`setter`,name:`placeholder`,static:!1,private:!1,access:{has:e=>`placeholder`in e,set:(e,t)=>{e.placeholder=t}},metadata:e},null,i),o(this,null,d,{kind:`method`,name:`_cleanChildren`,static:!1,private:!1,access:{has:e=>`_cleanChildren`in e,get:e=>e._cleanChildren},metadata:e},null,i),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.role=`textbox`}static{this.formFieldAssociated=!0}get type(){return`text`}set value(e){this._value=this._cleanText(e),this.hasUpdated&&this._assignValue(this._value),this.dispatchEvent(new Event(`displayvaluechange`,{bubbles:!0,composed:!0}))}get value(){return this._value??``}set placeholder(e){e?this.setAttribute(`placeholder`,e):this.removeAttribute(`placeholder`),this.internals.ariaPlaceholder=e||null}get placeholder(){return this.getAttribute(`placeholder`)??``}constructor(){super(),this._shouldEmitChange=(s(this,i),!1),this._shouldTriggerSubmit=!1,this.language=new z(this),this._value=``,this.addEventListener?.(`input`,()=>{let e=this._value;this._value=this._cleanText(this.textContent??``),this.requestUpdate(`value`,e),this.internals.states.add(`interacted`),this._shouldEmitChange=!0},{capture:!0}),this.addEventListener?.(`change`,()=>this._shouldEmitChange=!1,{capture:!0}),this.addEventListener?.(`keydown`,e=>{this._requiresEmptyPatch()&&this._assignValue(``);let t=window.getSelection(),n=t?.getRangeAt(0);if(n&&!n.collapsed&&n.startContainer===this&&n.endContainer===this.lastChild&&n.selectNodeContents(this.lastChild),(e.key===`Enter`||e.key===`
44
44
  `)&&e.isTrusted)e.preventDefault(),e.stopImmediatePropagation(),this._shouldTriggerSubmit=this.dispatchEvent(new KeyboardEvent(`keydown`,e));else if(A&&this.value&&(e.key===`Backspace`||e.key===`Delete`)&&e.isTrusted){if(e.preventDefault(),e.stopImmediatePropagation(),!this.dispatchEvent(new KeyboardEvent(`keydown`,e)))return;let n=t?.getRangeAt(0);if(!n)return;n.collapsed?e.key===`Backspace`&&n.startOffset>0?(n.setStart(n.startContainer,n.startOffset-1),n.deleteContents(),this._dispatchInputEvent()):e.key===`Delete`&&n.endOffset<this.value.length&&(n.setEnd(n.endContainer,n.endOffset+1),n.deleteContents(),this._dispatchInputEvent()):(n.deleteContents(),this._dispatchInputEvent())}},{capture:!0}),this.addEventListener?.(`keyup`,e=>{e.key===`Enter`||e.key===`
45
- `?(this._emitChangeIfNecessary(),this._shouldTriggerSubmit&&(this._shouldTriggerSubmit=!1,this.form?.requestSubmit())):this._requiresEmptyPatch()&&this._setCursorAt(0)},{capture:!0}),this.addEventListener?.(`paste`,e=>{e.preventDefault(),this._requiresEmptyPatch()&&this._assignValue(``);let t=this._cleanText(e.clipboardData?.getData(`text/plain`)??``),n=window.getSelection()?.getRangeAt(0);n&&t&&(n.deleteContents(),n.insertNode(document.createTextNode(this.preparePastedText(t))),n.setStart(n.endContainer,n.endOffset),this._dispatchInputEvent())}),this.addEventListener?.(`focus`,()=>{T.mostRecentModality===`keyboard`&&window.getSelection()?.selectAllChildren(this)}),this.addEventListener?.(`touchend`,()=>{this._requiresEmptyPatch()&&(this._assignValue(`&nbsp;`),this._setCursorAt(0))}),this.addEventListener?.(`click`,()=>{this._requiresEmptyPatch()&&T.mostRecentModality===`touch`&&this._setCursorAt(0)}),this.addEventListener?.(`blur`,()=>{window.getSelection()?.removeAllRanges(),this.value===``&&this._assignValue(``),this._emitChangeIfNecessary(),this.scrollLeft=0},{capture:!0})}isDisabledExternally(){return this.formDisabled}connectedCallback(){super.connectedCallback(),this.internals.ariaMultiLine=`false`,this._updateContenteditable(),this._assignValue(this.value)}focus(e){if(super.focus(e),this._canSelect()){let e=window.getSelection();if(!e)return;let t=e.rangeCount>0?e.getRangeAt(0):null;if(t&&t.startOffset!==0)return;this._setCursorAt(this.textContent.length)}}attributeChangedCallback(e,t,n){e===`value`&&this.matches?.(`:is(:state(interacted),[state--interacted])`)||super.attributeChangedCallback(e,t,n)}formResetCallback(){this.internals.states.delete(`interacted`),this.value=this.getAttribute(`value`)??``}formStateRestoreCallback(e,t){e&&typeof e==`string`&&(this.value=e)}select(){window.getSelection()?.selectAllChildren(this)}firstUpdated(e){super.firstUpdated(e),this.value&&!this.innerHTML.length&&this._assignValue(this.value)}requestUpdate(e,t,n){super.requestUpdate(e,t,n),this.isConnected&&(e===`disabled`||e===`formDisabled`||e===`readOnly`)&&this._updateContenteditable()}shouldValidate(e){return super.shouldValidate(e)||e===`value`||e===`required`}validate(){super.validate(),this.required&&!this.value?this.setValidityFlag(`valueMissing`,hn[this.language.current]):this.removeValidityFlag(`valueMissing`)}isSelected(){if(r)return!1;let e=window.getSelection();return!!e&&e.rangeCount>0&&this.contains(e.anchorNode)}preparePastedText(e){return e}_requiresEmptyPatch(){return!r&&k&&this.value===``&&window.matchMedia(`(pointer: coarse)`).matches}_assignValue(e){this.innerHTML=e}_setCursorAt(e){let t=window.getSelection();if(!this.firstChild||!t)return;let n=document.createRange();n.setStart(this.firstChild,e),n.collapse(!0),t.removeAllRanges(),t.addRange(n)}_cleanText(e){return e===null?``:`${e}`.replace(/[\n\r]+/g,``)}_dispatchInputEvent(){this.dispatchEvent(new InputEvent(`input`,{bubbles:!0,composed:!0}))}_cleanChildren(){if(this.childElementCount)for(let e of this.children)e.remove()}_updateContenteditable(){if(!r&&this.isConnected){this.internals.ariaReadOnly=this.readOnly?`true`:null,this.internals.ariaDisabled=this.disabled?`true`:null;let e=this.disabled||this.readOnly?`false`:Yr?`plaintext-only`:`true`;this.setAttribute(`contenteditable`,e),this.readOnly?this.setAttribute(`tabindex`,`0`):this.removeAttribute(`tabindex`)}}_emitChangeIfNecessary(){this._shouldEmitChange&&(this._shouldEmitChange=!1,this.dispatchEvent(new Event(`change`,{bubbles:!0})))}_canSelect(){return!r&&!this.disabled&&!this.readOnly&&!!this.value}render(){return n`<slot @slotchange=${this._cleanChildren}></slot>`}}})(),Q=/* @__PURE__ */ new WeakMap,Zr=e=>(()=>{let t=V(H(L(e))),n=[],i,a;return class extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;i=[l({type:Boolean})],a=[l()],o(this,null,i,{kind:`setter`,name:`checked`,static:!1,private:!1,access:{has:e=>`checked`in e,set:(e,t)=>{e.checked=t}},metadata:e},null,n),o(this,null,a,{kind:`setter`,name:`name`,static:!1,private:!1,access:{has:e=>`name`in e,set:(e,t)=>{e.name=t}},metadata:e},null,n),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.role=`radio`}set checked(e){this._checked=!!e,this.toggleState(`checked`,this.checked),this.internals.ariaChecked=this.checked.toString(),this.updateFormValue(),this._synchronizeGroupState()}get checked(){return this._checked}set name(e){let t=this.name;e!==t&&(super.name=e,this._disconnectFromRegistry(t),this._connectToRegistry(),this._synchronizeGroupState())}get name(){return super.name}get type(){return`radio`}constructor(){super(),this._checked=(s(this,n),!1),this._languageController=new z(this),this.addEventListener?.(`keydown`,e=>this._handleArrowKeyDown(e))}connectedCallback(){super.connectedCallback(),this._connectToRegistry(),this._synchronizeGroupState()}disconnectedCallback(){super.disconnectedCallback(),this._disconnectFromRegistry(this.name)}formResetCallback(){this.checked=this.hasAttribute(`checked`)}formStateRestoreCallback(e,t){typeof e==`string`||e==null?this.checked=e===this.value:e instanceof FormData&&this._readFormData(e).then(e=>{this.checked=e===this.value})}async _readFormData(e){let t=e.get(this.name);return t instanceof Blob?JSON.parse(await t.text()):t}willUpdate(e){super.willUpdate(e),e.has(`disabled`)&&this.updateFocusableRadios()}firstUpdated(e){super.firstUpdated(e),this.updateFocusableRadios()}updateFormValue(){this.checked?super.updateFormValue():this.internals.setFormValue(null)}shouldValidate(e){return super.shouldValidate(e)||e===`checked`||e===`required`}validate(){if(super.validate(),!this.associatedRadioButtons)return;let e=!1,t=!1;for(let n of this.associatedRadioButtons)e||=n.required,t||=n.checked;e&&!t?this.associatedRadioButtons.forEach(e=>e.setValidityFlag(`valueMissing`,pn[this._languageController.current])):this.associatedRadioButtons.forEach(e=>e.removeValidityFlag(`valueMissing`))}updateFocusableRadios(){if(!this.hasUpdated)return;let e=this._interactableGroupedRadios(),t=e.findIndex(e=>e.checked&&!e.disabled&&!e.formDisabled),n=t===-1?e.findIndex(e=>!e.disabled&&!e.formDisabled):t;n!==-1&&(e[n].tabIndex=0,e.splice(n,1)),e.forEach(e=>e.removeAttribute(`tabindex`))}async navigateByKeyboard(e){e.checked=!0,this.emitChangeEvents(),await e.updateComplete,e.focus()}emitChangeEvents(){this.dispatchEvent(new InputEvent(`input`,{bubbles:!0,cancelable:!0,composed:!0})),this.dispatchEvent(new Event(`change`,{bubbles:!0}))}_synchronizeGroupState(){this.checked&&this._deselectGroupedRadios(),this.updateFocusableRadios()}_connectToRegistry(){if(!this.name||r)return;let e=this.form??this.getRootNode();this._radioButtonGroupsMap=Q.get(e),this._radioButtonGroupsMap||(this._radioButtonGroupsMap=/* @__PURE__ */ new Map,Q.set(e,this._radioButtonGroupsMap)),this.associatedRadioButtons=this._radioButtonGroupsMap.get(this.name),this.associatedRadioButtons||(this.associatedRadioButtons=/* @__PURE__ */ new Set,this._radioButtonGroupsMap.set(this.name,this.associatedRadioButtons));let t=Array.from(this.associatedRadioButtons);this.associatedRadioButtons.clear();let n=t.findIndex(e=>this.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_FOLLOWING);n===-1?t.push(this):t.splice(n,0,this),t.forEach(e=>this.associatedRadioButtons.add(e)),this.validate()}_disconnectFromRegistry(e){this.associatedRadioButtons?.delete(this),this.associatedRadioButtons?.size===0?this._radioButtonGroupsMap?.delete(e):this.validate(),this.associatedRadioButtons=void 0,this._radioButtonGroupsMap=void 0}_interactableGroupedRadios(){return Array.from(this.associatedRadioButtons??[]).filter(e=>M.isVisible(e))}_deselectGroupedRadios(){Array.from(this.associatedRadioButtons??[]).filter(e=>e!==this).forEach(e=>e.checked=!1)}async _handleArrowKeyDown(e){if(!p(e))return;e.preventDefault();let t=this._interactableGroupedRadios().filter(e=>!e.disabled&&!e.formDisabled),n=y(e,t.indexOf(this),t.length);await this.navigateByKeyboard(t[n])}}})();var Qr=`:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible){--sbb-scrollbar-width:var(--sbb-spacing-fixed-3x);--sbb-scrollbar-thumb-width:.125rem;--sbb-scrollbar-thumb-width-hover:.25rem;--sbb-scrollbar-width-firefox:thin;--sbb-scrollbar-color:light-dark(color-mix(in srgb, var(--sbb-color-black) 30%, transparent),color-mix(in srgb, var(--sbb-color-white) 30%, transparent));--sbb-scrollbar-color-hover:light-dark(color-mix(in srgb, var(--sbb-color-black) 60%, transparent),color-mix(in srgb, var(--sbb-color-white) 60%, transparent));--sbb-scrollbar-track-color:transparent}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar{width:var(--sbb-scrollbar-width);height:var(--sbb-scrollbar-width);background-color:var(--sbb-scrollbar-track-color,transparent)}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-corner{background-color:var(--sbb-scrollbar-track-color,transparent)}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-thumb{background-color:var(--sbb-scrollbar-color,currentcolor);border:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width))) solid transparent;border-radius:var(--sbb-border-radius-4x);background-clip:padding-box}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-thumb:hover{background-color:var(--sbb-scrollbar-color-hover,currentcolor);border-width:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width-hover)))}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-button,:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-corner{display:none}@supports not selector(::-webkit-scrollbar){:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible){scrollbar-width:var(--sbb-scrollbar-width-firefox);scrollbar-color:var(--sbb-scrollbar-color,currentcolor) var(--sbb-scrollbar-track-color,transparent)}}:is(.sbb-scrollbar-negative,.sbb-scrollbar-thick-negative,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-negative-track-visible){--sbb-scrollbar-color:color-mix(in srgb, var(--sbb-color-white) 30%, transparent);--sbb-scrollbar-color-hover:color-mix(in srgb, var(--sbb-color-white) 60%, transparent)}:is(.sbb-scrollbar-thick-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible){--sbb-scrollbar-thumb-width:.5rem;--sbb-scrollbar-thumb-width-hover:var(--sbb-scrollbar-thumb-width);--sbb-scrollbar-width-firefox:auto}:is(.sbb-scrollbar-track-visible,.sbb-scrollbar-thick-track-visible){--sbb-scrollbar-track-color:var(--sbb-background-color-4)}:is(.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-negative-track-visible){--sbb-scrollbar-track-color:var(--sbb-background-color-4-negative)}
46
- `,$r=`button{appearance:none;box-sizing:border-box;-webkit-tap-highlight-color:transparent;color:inherit;background:0 0;border:none;border-radius:0;outline:none;margin:0;padding:0}
47
- `,ei=`:host{--sbb-scrollbar-width:var(--sbb-spacing-fixed-3x);--sbb-scrollbar-thumb-width:.125rem;--sbb-scrollbar-thumb-width-hover:.25rem;--sbb-scrollbar-width-firefox:thin;--sbb-scrollbar-color:light-dark(color-mix(in srgb, var(--sbb-color-black) 30%, transparent),color-mix(in srgb, var(--sbb-color-white) 30%, transparent));--sbb-scrollbar-color-hover:light-dark(color-mix(in srgb, var(--sbb-color-black) 60%, transparent),color-mix(in srgb, var(--sbb-color-white) 60%, transparent));--sbb-scrollbar-track-color:transparent}:host::-webkit-scrollbar{width:var(--sbb-scrollbar-width);height:var(--sbb-scrollbar-width);background-color:var(--sbb-scrollbar-track-color,transparent)}:host::-webkit-scrollbar-corner{background-color:var(--sbb-scrollbar-track-color,transparent)}:host::-webkit-scrollbar-thumb{background-color:var(--sbb-scrollbar-color,currentcolor);border:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width))) solid transparent;border-radius:var(--sbb-border-radius-4x);background-clip:padding-box}:host::-webkit-scrollbar-thumb:hover{background-color:var(--sbb-scrollbar-color-hover,currentcolor);border-width:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width-hover)))}:host::-webkit-scrollbar-button,:host::-webkit-scrollbar-corner{display:none}@supports not selector(::-webkit-scrollbar){:host{scrollbar-width:var(--sbb-scrollbar-width-firefox);scrollbar-color:var(--sbb-scrollbar-color,currentcolor) var(--sbb-scrollbar-track-color,transparent)}}
48
- `,ti=`ul,ol{font-size:inherit;margin:0;padding:0;list-style:none}
49
- `,ni=`:host(:where([popover])),.sbb-popover-reset:where([popover]){width:auto;height:auto;color:inherit;pointer-events:none;background-color:#0000;border:none;margin:0;padding:0}
50
- `,ri=`.sbb-screen-reader-only{clip-path:rect(0 0 0 0);white-space:nowrap;border:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}
51
- `;const ii=a($r),ai=a(ei),oi=a(ti),si=a(ri),ci=a(ni),li=a(Qr),ui=`data-ssr-child-count`,di=e=>(()=>{let t=e,r,a=[],c=[];return class extends t{constructor(){super(...arguments),this.#e=s(this,a,[]),this._handleSlotchange=(s(this,c),()=>{let e=Array.from(this.children??[]).filter(e=>this.listChildLocalNames.includes(e.localName));e.length===this.listChildren.length&&this.listChildren.every((t,n)=>e[n]===t)||(this.listChildren.filter(t=>!e.includes(t)).forEach(e=>e.removeAttribute(`slot`)),this.listChildren=e,this.removeAttribute(ui))})}static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;r=[u()],o(this,null,r,{kind:`accessor`,name:`listChildren`,static:!1,private:!1,access:{has:e=>`listChildren`in e,get:e=>e.listChildren,set:(e,t)=>{e.listChildren=t}},metadata:e},a,c),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.elementDependencies=[]}static{this.styles=[oi,si]}#e;get listChildren(){return this.#e}set listChildren(e){this.#e=e}connectedCallback(){super.connectedCallback(),this.shadowRoot?.addEventListener(`slotchange`,this._handleSlotchange,{passive:!0})}disconnectedCallback(){super.disconnectedCallback(),this.shadowRoot?.removeEventListener(`slotchange`,this._handleSlotchange)}updated(e){super.updated(e),e.has(`listChildren`)&&this.listChildren.forEach((e,t)=>e.setAttribute(`slot`,`li-${t}`))}renderList(e={},t={}){let r=this.listSlotEntries(t);return r.length>=2?n`
45
+ `?(this._emitChangeIfNecessary(),this._shouldTriggerSubmit&&(this._shouldTriggerSubmit=!1,this.form?.requestSubmit())):this._requiresEmptyPatch()&&this._setCursorAt(0)},{capture:!0}),this.addEventListener?.(`paste`,e=>{e.preventDefault(),this._requiresEmptyPatch()&&this._assignValue(``);let t=this._cleanText(e.clipboardData?.getData(`text/plain`)??``),n=window.getSelection()?.getRangeAt(0);n&&t&&(n.deleteContents(),n.insertNode(document.createTextNode(this.preparePastedText(t))),n.setStart(n.endContainer,n.endOffset),this._dispatchInputEvent())}),this.addEventListener?.(`focus`,()=>{T.mostRecentModality===`keyboard`&&window.getSelection()?.selectAllChildren(this)}),this.addEventListener?.(`touchend`,()=>{this._requiresEmptyPatch()&&(this._assignValue(`&nbsp;`),this._setCursorAt(0))}),this.addEventListener?.(`click`,()=>{this._requiresEmptyPatch()&&T.mostRecentModality===`touch`&&this._setCursorAt(0)}),this.addEventListener?.(`blur`,()=>{window.getSelection()?.removeAllRanges(),this.value===``&&this._assignValue(``),this._emitChangeIfNecessary(),this.scrollLeft=0},{capture:!0})}isDisabledExternally(){return this.formDisabled}connectedCallback(){super.connectedCallback(),this.internals.ariaMultiLine=`false`,this._updateContenteditable(),this._assignValue(this.value)}focus(e){if(super.focus(e),this._canSelect()){let e=window.getSelection();if(!e)return;let t=e.rangeCount>0?e.getRangeAt(0):null;if(t&&t.startOffset!==0)return;this._setCursorAt(this.textContent.length)}}attributeChangedCallback(e,t,n){e===`value`&&this.matches?.(`:is(:state(interacted),[state--interacted])`)||super.attributeChangedCallback(e,t,n)}formResetCallback(){this.internals.states.delete(`interacted`),this.value=this.getAttribute(`value`)??``}formStateRestoreCallback(e,t){e&&typeof e==`string`&&(this.value=e)}select(){window.getSelection()?.selectAllChildren(this)}firstUpdated(e){super.firstUpdated(e),this.value&&!this.innerHTML.length&&this._assignValue(this.value)}requestUpdate(e,t,n){super.requestUpdate(e,t,n),this.isConnected&&(e===`disabled`||e===`formDisabled`||e===`readOnly`)&&this._updateContenteditable()}shouldValidate(e){return super.shouldValidate(e)||e===`value`||e===`required`}validate(){super.validate(),this.required&&!this.value?this.setValidityFlag(`valueMissing`,hn[this.language.current]):this.removeValidityFlag(`valueMissing`)}isSelected(){if(r)return!1;let e=window.getSelection();return!!e&&e.rangeCount>0&&this.contains(e.anchorNode)}preparePastedText(e){return e}_requiresEmptyPatch(){return!r&&k&&this.value===``&&window.matchMedia(`(pointer: coarse)`).matches}_assignValue(e){this.innerHTML=e}_setCursorAt(e){let t=window.getSelection();if(!this.firstChild||!t)return;let n=document.createRange();n.setStart(this.firstChild,e),n.collapse(!0),t.removeAllRanges(),t.addRange(n)}_cleanText(e){return e===null?``:`${e}`.replace(/[\n\r]+/g,``)}_dispatchInputEvent(){this.dispatchEvent(new InputEvent(`input`,{bubbles:!0,composed:!0}))}_cleanChildren(){if(this.childElementCount)for(let e of this.children)e.remove()}_updateContenteditable(){if(!r&&this.isConnected){this.internals.ariaReadOnly=this.readOnly?`true`:null,this.internals.ariaDisabled=this.disabled?`true`:null;let e=this.disabled||this.readOnly?`false`:Xr?`plaintext-only`:`true`;this.setAttribute(`contenteditable`,e),this.readOnly?this.setAttribute(`tabindex`,`0`):this.removeAttribute(`tabindex`)}}_emitChangeIfNecessary(){this._shouldEmitChange&&(this._shouldEmitChange=!1,this.dispatchEvent(new Event(`change`,{bubbles:!0})))}_canSelect(){return!r&&!this.disabled&&!this.readOnly&&!!this.value}render(){return n`<slot @slotchange=${this._cleanChildren}></slot>`}}})(),Q=/* @__PURE__ */ new WeakMap,Qr=e=>(()=>{let t=V(H(L(e))),n=[],i,a;return class e extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;i=[l({type:Boolean})],a=[l()],o(this,null,i,{kind:`setter`,name:`checked`,static:!1,private:!1,access:{has:e=>`checked`in e,set:(e,t)=>{e.checked=t}},metadata:e},null,n),o(this,null,a,{kind:`setter`,name:`name`,static:!1,private:!1,access:{has:e=>`name`in e,set:(e,t)=>{e.name=t}},metadata:e},null,n),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.role=`radio`}static{this._tabindexState={elements:/* @__PURE__ */ new Set,handleEvent(e){e.key===`Tab`&&Array.from(this.elements,e=>e.associatedRadioButtons).filter((e,t,n)=>!!e&&n.indexOf(e)===t).forEach(e=>e?.values().next().value?.updateFocusableRadios())},add(e){this.elements.size||window.addEventListener(`keydown`,this,{passive:!0}),this.elements.add(e)},delete(e){this.elements.delete(e),this.elements.size||window.removeEventListener(`keydown`,this)}}}set checked(e){this._checked=!!e,this.toggleState(`checked`,this.checked),this.internals.ariaChecked=this.checked.toString(),this.updateFormValue(),this._synchronizeGroupState()}get checked(){return this._checked}set name(e){let t=this.name;e!==t&&(super.name=e,this._disconnectFromRegistry(t),this._connectToRegistry(),this._synchronizeGroupState())}get name(){return super.name}get type(){return`radio`}constructor(){super(),this._checked=(s(this,n),!1),this._languageController=new z(this),this._tabindexState=e._tabindexState,this.addEventListener?.(`keydown`,e=>this._handleArrowKeyDown(e))}focus(e){this.hasAttribute(`tabindex`)||this.addController(new yr(this)),super.focus(e)}connectedCallback(){super.connectedCallback(),this._connectToRegistry(),this._synchronizeGroupState(),this.updateFocusableRadios()}disconnectedCallback(){super.disconnectedCallback(),this._disconnectFromRegistry(this.name)}formResetCallback(){this.checked=this.hasAttribute(`checked`)}formStateRestoreCallback(e,t){typeof e==`string`||e==null?this.checked=e===this.value:e instanceof FormData&&this._readFormData(e).then(e=>{this.checked=e===this.value})}requestUpdate(e,t,n){super.requestUpdate(e,t,n),(e===`disabled`||e===`formDisabled`||e===`checked`||e===`name`)&&this.updateFocusableRadios()}async _readFormData(e){let t=e.get(this.name);return t instanceof Blob?JSON.parse(await t.text()):t}updateFormValue(){this.checked?super.updateFormValue():this.internals.setFormValue(null)}shouldValidate(e){return super.shouldValidate(e)||e===`checked`||e===`required`}validate(){if(super.validate(),!this.associatedRadioButtons)return;let e=!1,t=!1;for(let n of this.associatedRadioButtons)e||=n.required,t||=n.checked;e&&!t?this.associatedRadioButtons.forEach(e=>e.setValidityFlag(`valueMissing`,pn[this._languageController.current])):this.associatedRadioButtons.forEach(e=>e.removeValidityFlag(`valueMissing`))}updateFocusableRadios(){let e=this._interactableGroupedRadios(),t=e.findIndex(e=>e.checked&&!e.disabled&&!e.formDisabled),n=t===-1?e.findIndex(e=>!e.disabled&&!e.formDisabled):t;n!==-1&&(e[n].tabIndex=0,e.splice(n,1)),e.forEach(e=>e.removeAttribute(`tabindex`))}async navigateByKeyboard(e){e.checked=!0,this.emitChangeEvents(),e.focus()}emitChangeEvents(){this.dispatchEvent(new InputEvent(`input`,{bubbles:!0,cancelable:!0,composed:!0})),this.dispatchEvent(new Event(`change`,{bubbles:!0}))}_synchronizeGroupState(){this.checked&&this._deselectGroupedRadios()}_connectToRegistry(){if(!this.name||r)return;let e=this.form??this.getRootNode();this._radioButtonGroupsMap=Q.get(e),this._radioButtonGroupsMap||(this._radioButtonGroupsMap=/* @__PURE__ */ new Map,Q.set(e,this._radioButtonGroupsMap)),this.associatedRadioButtons=this._radioButtonGroupsMap.get(this.name),this.associatedRadioButtons||(this.associatedRadioButtons=/* @__PURE__ */ new Set,this._radioButtonGroupsMap.set(this.name,this.associatedRadioButtons));let t=Array.from(this.associatedRadioButtons);this.associatedRadioButtons.clear();let n=t.findIndex(e=>this.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_FOLLOWING);n===-1?t.push(this):t.splice(n,0,this),t.forEach(e=>this.associatedRadioButtons.add(e)),this._tabindexState.add(this),this.validate()}_disconnectFromRegistry(e){this._tabindexState.delete(this),this.associatedRadioButtons?.delete(this),this.associatedRadioButtons?.size===0?this._radioButtonGroupsMap?.delete(e):this.validate(),this.associatedRadioButtons=void 0,this._radioButtonGroupsMap=void 0}_interactableGroupedRadios(){return Array.from(this.associatedRadioButtons??[]).filter(e=>M.isVisible(e))}_deselectGroupedRadios(){Array.from(this.associatedRadioButtons??[]).filter(e=>e!==this).forEach(e=>e.checked=!1)}async _handleArrowKeyDown(e){if(!p(e))return;e.preventDefault();let t=this._interactableGroupedRadios().filter(e=>!e.disabled&&!e.formDisabled),n=y(e,t.indexOf(this),t.length);await this.navigateByKeyboard(t[n])}}})();var $r=`:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible){--sbb-scrollbar-width:var(--sbb-spacing-fixed-3x);--sbb-scrollbar-thumb-width:.125rem;--sbb-scrollbar-thumb-width-hover:.25rem;--sbb-scrollbar-width-firefox:thin;--sbb-scrollbar-color:light-dark(color-mix(in srgb, var(--sbb-color-black) 30%, transparent),color-mix(in srgb, var(--sbb-color-white) 30%, transparent));--sbb-scrollbar-color-hover:light-dark(color-mix(in srgb, var(--sbb-color-black) 60%, transparent),color-mix(in srgb, var(--sbb-color-white) 60%, transparent));--sbb-scrollbar-track-color:transparent}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar{width:var(--sbb-scrollbar-width);height:var(--sbb-scrollbar-width);background-color:var(--sbb-scrollbar-track-color,transparent)}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-corner{background-color:var(--sbb-scrollbar-track-color,transparent)}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-thumb{background-color:var(--sbb-scrollbar-color,currentcolor);border:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width))) solid transparent;border-radius:var(--sbb-border-radius-4x);background-clip:padding-box}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-thumb:hover{background-color:var(--sbb-scrollbar-color-hover,currentcolor);border-width:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width-hover)))}:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-button,:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible)::-webkit-scrollbar-corner{display:none}@supports not selector(::-webkit-scrollbar){:is(.sbb-scrollbar,.sbb-scrollbar-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-negative,.sbb-scrollbar-track-visible,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible){scrollbar-width:var(--sbb-scrollbar-width-firefox);scrollbar-color:var(--sbb-scrollbar-color,currentcolor) var(--sbb-scrollbar-track-color,transparent)}}:is(.sbb-scrollbar-negative,.sbb-scrollbar-thick-negative,.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-negative-track-visible){--sbb-scrollbar-color:color-mix(in srgb, var(--sbb-color-white) 30%, transparent);--sbb-scrollbar-color-hover:color-mix(in srgb, var(--sbb-color-white) 60%, transparent)}:is(.sbb-scrollbar-thick-negative,.sbb-scrollbar-thick,.sbb-scrollbar-thick-track-visible,.sbb-scrollbar-thick-negative-track-visible){--sbb-scrollbar-thumb-width:.5rem;--sbb-scrollbar-thumb-width-hover:var(--sbb-scrollbar-thumb-width);--sbb-scrollbar-width-firefox:auto}:is(.sbb-scrollbar-track-visible,.sbb-scrollbar-thick-track-visible){--sbb-scrollbar-track-color:var(--sbb-background-color-4)}:is(.sbb-scrollbar-negative-track-visible,.sbb-scrollbar-thick-negative-track-visible){--sbb-scrollbar-track-color:var(--sbb-background-color-4-negative)}
46
+ `,ei=`button{appearance:none;box-sizing:border-box;-webkit-tap-highlight-color:transparent;color:inherit;background:0 0;border:none;border-radius:0;outline:none;margin:0;padding:0}
47
+ `,ti=`:host{--sbb-scrollbar-width:var(--sbb-spacing-fixed-3x);--sbb-scrollbar-thumb-width:.125rem;--sbb-scrollbar-thumb-width-hover:.25rem;--sbb-scrollbar-width-firefox:thin;--sbb-scrollbar-color:light-dark(color-mix(in srgb, var(--sbb-color-black) 30%, transparent),color-mix(in srgb, var(--sbb-color-white) 30%, transparent));--sbb-scrollbar-color-hover:light-dark(color-mix(in srgb, var(--sbb-color-black) 60%, transparent),color-mix(in srgb, var(--sbb-color-white) 60%, transparent));--sbb-scrollbar-track-color:transparent}:host::-webkit-scrollbar{width:var(--sbb-scrollbar-width);height:var(--sbb-scrollbar-width);background-color:var(--sbb-scrollbar-track-color,transparent)}:host::-webkit-scrollbar-corner{background-color:var(--sbb-scrollbar-track-color,transparent)}:host::-webkit-scrollbar-thumb{background-color:var(--sbb-scrollbar-color,currentcolor);border:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width))) solid transparent;border-radius:var(--sbb-border-radius-4x);background-clip:padding-box}:host::-webkit-scrollbar-thumb:hover{background-color:var(--sbb-scrollbar-color-hover,currentcolor);border-width:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width-hover)))}:host::-webkit-scrollbar-button,:host::-webkit-scrollbar-corner{display:none}@supports not selector(::-webkit-scrollbar){:host{scrollbar-width:var(--sbb-scrollbar-width-firefox);scrollbar-color:var(--sbb-scrollbar-color,currentcolor) var(--sbb-scrollbar-track-color,transparent)}}
48
+ `,ni=`ul,ol{font-size:inherit;margin:0;padding:0;list-style:none}
49
+ `,ri=`:host(:where([popover])),.sbb-popover-reset:where([popover]){width:auto;height:auto;color:inherit;pointer-events:none;background-color:#0000;border:none;margin:0;padding:0}
50
+ `,ii=`.sbb-screen-reader-only{clip-path:rect(0 0 0 0);white-space:nowrap;border:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}
51
+ `;const ai=a(ei),oi=a(ti),si=a(ni),ci=a(ii),li=a(ri),ui=a($r),di=`data-ssr-child-count`,fi=e=>(()=>{let t=e,r,a=[],c=[];return class extends t{constructor(){super(...arguments),this.#e=s(this,a,[]),this._handleSlotchange=(s(this,c),()=>{let e=Array.from(this.children??[]).filter(e=>this.listChildLocalNames.includes(e.localName));e.length===this.listChildren.length&&this.listChildren.every((t,n)=>e[n]===t)||(this.listChildren.filter(t=>!e.includes(t)).forEach(e=>e.removeAttribute(`slot`)),this.listChildren=e,this.removeAttribute(di))})}static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;r=[u()],o(this,null,r,{kind:`accessor`,name:`listChildren`,static:!1,private:!1,access:{has:e=>`listChildren`in e,get:e=>e.listChildren,set:(e,t)=>{e.listChildren=t}},metadata:e},a,c),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.elementDependencies=[]}static{this.styles=[si,ci]}#e;get listChildren(){return this.#e}set listChildren(e){this.#e=e}connectedCallback(){super.connectedCallback(),this.shadowRoot?.addEventListener(`slotchange`,this._handleSlotchange,{passive:!0})}disconnectedCallback(){super.disconnectedCallback(),this.shadowRoot?.removeEventListener(`slotchange`,this._handleSlotchange)}updated(e){super.updated(e),e.has(`listChildren`)&&this.listChildren.forEach((e,t)=>e.setAttribute(`slot`,`li-${t}`))}renderList(e={},t={}){let r=this.listSlotEntries(t);return r.length>=2?n`
52
52
  <ul
53
53
  class=${e.class||this.localName}
54
54
  aria-label=${e.ariaLabel||i}
@@ -65,5 +65,5 @@ let xe=0;var Se=class{constructor(){r||(document.body?this._liveElement=this._cr
65
65
  <span class=${e.class||this.localName}>
66
66
  <span><slot name=${r[0].name}></slot></span>
67
67
  </span>
68
- ${this.renderHiddenSlot()} `:this.renderHiddenSlot()}listSlotEntries(e){return(this.listChildren.length?this.listChildren:Array.from({length:+(this.getAttribute(ui)??0)})).map((t,n)=>({name:`li-${n}`,ariaHidden:e?.localNameVisualOnly?.includes(t.localName)??!1}))}renderHiddenSlot(){return n`<span hidden><slot></slot></span>`}}})(),fi=e=>(()=>{let t=e,n,r=[],i=[];return class extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;n=[I(),l({reflect:!0,type:Boolean})],o(this,null,n,{kind:`accessor`,name:`negative`,static:!1,private:!1,access:{has:e=>`negative`in e,get:e=>e.negative,set:(e,t)=>{e.negative=t}},metadata:e},r,i),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}#e=s(this,r,!1);get negative(){return this.#e}set negative(e){this.#e=e}constructor(){super(...arguments),s(this,i)}}})();var pi=`:host{--sbb-selection-panel-background:var(--sbb-selection-panel-inner-background,var(--sbb-selection-panel-background-default));--sbb-selection-panel-border-width:var(--sbb-selection-panel-inner-border-width,var(--sbb-selection-panel-border-width-default));--sbb-selection-panel-animation-duration:var(--sbb-disable-animation-duration,var(--sbb-animation-duration-4x));display:block;outline:none!important}:host([size=xs]){--sbb-selection-panel-checkbox-dimension:var(--sbb-checkbox-dimension-xs);--sbb-selection-panel-input-padding:var(--sbb-selection-panel-input-padding-block-xs) var(--sbb-selection-panel-input-padding-inline-xs)}:host([size=s]){--sbb-selection-panel-checkbox-dimension:var(--sbb-checkbox-dimension-s);--sbb-selection-panel-input-padding:var(--sbb-selection-panel-input-padding-block-s) var(--sbb-selection-panel-input-padding-inline-s)}:host([size=m]){--sbb-selection-panel-checkbox-dimension:var(--sbb-checkbox-dimension-m);--sbb-selection-panel-input-padding:var(--sbb-selection-panel-input-padding-block-m) var(--sbb-selection-panel-input-padding-inline-m)}:host([color=milk]){--sbb-selection-panel-background:var(--sbb-selection-panel-inner-background,var(--sbb-selection-panel-background-milk))}:host([borderless]:not(:is(:state(checked),[state--checked]))){--sbb-selection-panel-border-color:var(--sbb-selection-panel-border-color-borderless)}:host(:is(:state(checked),[state--checked]):not(:disabled,[disabled])){--sbb-selection-panel-border-color:var(--sbb-selection-panel-border-color-checked);--sbb-selection-panel-border-width:var(--sbb-selection-panel-inner-border-width,var(--sbb-selection-panel-border-width-checked))}:host(:is(:disabled,[disabled])){--sbb-selection-panel-cursor:var(--sbb-cursor-default)}.sbb-selection-panel{cursor:var(--sbb-selection-panel-cursor);border-radius:var(--sbb-selection-panel-border-radius);box-shadow:inset 0 0 0 var(--sbb-selection-panel-border-width) var(--sbb-selection-panel-border-color);padding:var(--sbb-selection-panel-input-padding);background-color:var(--sbb-selection-panel-background);height:100%;transition-duration:var(--sbb-selection-panel-animation-duration);transition-timing-function:var(--sbb-animation-easing);transition-property:box-shadow;display:block;position:relative}@media (forced-colors:active){.sbb-selection-panel:after{content:"";pointer-events:none;border:var(--sbb-selection-panel-border-width) solid var(--sbb-selection-panel-border-color);border-radius:var(--sbb-selection-panel-border-radius);display:block;position:absolute;inset:0}}:host(:focus-visible) .sbb-selection-panel{outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) var(--sbb-focus-outline-style,solid) var(--sbb-focus-outline-width)}.sbb-selection-panel__badge{user-select:none;pointer-events:none;border-radius:var(--sbb-selection-panel-border-radius);position:absolute;inset:0;overflow:hidden}slot[name=suffix]{color:var(--sbb-selection-panel-suffix-color)}slot[name=subtext]{color:var(--sbb-selection-panel-subtext-color);padding-inline-start:calc(var(--sbb-selection-panel-checkbox-dimension) + var(--sbb-spacing-fixed-2x));display:block}:host(:not(:is(:state(slotted-subtext),[state--slotted-subtext]))) slot[name=subtext]{display:none}
69
- `;const mi=e=>(()=>{let t=e,n,r=[],i=[],c,u=[],d=[],f,p=[],m=[],h,g=[],_=[];return class extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;n=[l({reflect:!0})],c=[I(),l({reflect:!0,type:Boolean})],f=[I(),l()],h=[l({reflect:!0}),Nr((e,t)=>e.group?.size??t)],o(this,null,n,{kind:`accessor`,name:`color`,static:!1,private:!1,access:{has:e=>`color`in e,get:e=>e.color,set:(e,t)=>{e.color=t}},metadata:e},r,i),o(this,null,c,{kind:`accessor`,name:`borderless`,static:!1,private:!1,access:{has:e=>`borderless`in e,get:e=>e.borderless,set:(e,t)=>{e.borderless=t}},metadata:e},u,d),o(this,null,f,{kind:`accessor`,name:`expansionState`,static:!1,private:!1,access:{has:e=>`expansionState`in e,get:e=>e.expansionState,set:(e,t)=>{e.expansionState=t}},metadata:e},p,m),o(this,null,h,{kind:`accessor`,name:`size`,static:!1,private:!1,access:{has:e=>`size`in e,get:e=>e.size,set:(e,t)=>{e.size=t}},metadata:e},g,_),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.styles=[a(pi)]}#e=s(this,r,`white`);get color(){return this.#e}set color(e){this.#e=e}#t=(s(this,i),s(this,u,!1));get borderless(){return this.#t}set borderless(e){this.#t=e}#n=(s(this,d),s(this,p,``));get expansionState(){return this.#n}set expansionState(e){this.#n=e}#r=(s(this,m),s(this,g,null));get size(){return this.#r}set size(e){this.#r=e}connectedCallback(){super.connectedCallback(),this.dispatchEvent(new Event(`panelconnected`,{bubbles:!0}))}constructor(){super(...arguments),s(this,_)}}})(),hi=e=>{class t extends e{get group(){return this.closest?.(`sbb-radio-button-group, sbb-checkbox-group`)??null}get panel(){return this.querySelector?.(`sbb-radio-button-panel, sbb-checkbox-panel`)??null}constructor(...e){super(e),this._previousSize=null,this._propertyWatcher=new Wn(this,()=>this.panel,{checked:e=>{this.toggleState(`checked`,e.checked),this.onInputStateChange?.()},disabled:e=>{this.toggleState(`disabled`,e.disabled),this.onInputStateChange?.()},size:e=>{this._previousSize&&this.internals.states.delete(`size-${this._previousSize}`),this._previousSize=e.size,this._previousSize&&this.internals.states.add(`size-${this._previousSize}`)},borderless:e=>{this.toggleState(`borderless`,e.borderless)},color:e=>{this._previousColor&&this.internals.states.delete(`color-${this._previousColor}`),this._previousColor=e.color,this._previousColor&&this.internals.states.add(`color-${this._previousColor}`)}}),this.addEventListener?.(`panelconnected`,()=>this._propertyWatcher.connect())}onInputStateChange(){}}return t},gi=e=>{class t extends e{constructor(){super(...arguments),this._updatePromise=Promise.resolve(),this._updateResolve=()=>{}}startUpdate(){this._updatePromise=new Promise(e=>this._updateResolve=e)}completeUpdate(){this._updateResolve()}async getUpdateComplete(){let e=await super.getUpdateComplete();return await this._updatePromise,e}}return t};function $(e){let t=window.getComputedStyle(e),n=t.display,r=parseInt(t.maxHeight,10).toString();if(n!==`none`&&r!==`0`)return{scrollHeight:e.scrollHeight,clientHeight:e.clientHeight,offsetHeight:e.offsetHeight,scrollWidth:e.scrollWidth,clientWidth:e.clientWidth,offsetWidth:e.offsetWidth};e.style.position=`absolute`,e.style.visibility=`hidden`,e.style.display=`block`;let i=e.scrollHeight,a=e.clientHeight,o=e.offsetHeight,s=e.scrollWidth,c=e.clientWidth,l=e.offsetWidth;return e.style.display=``,e.style.position=``,e.style.visibility=``,{scrollHeight:i,clientHeight:a,offsetHeight:o,scrollWidth:s,clientWidth:c,offsetWidth:l}}function _i(e,t){if(!e||!t)return!1;let n=e.getBoundingClientRect();return n.top<=t.clientY&&t.clientY<=n.top+n.height&&n.left<=t.clientX&&t.clientX<=n.left+n.width}function vi(e,t,n,r){let i=r?.verticalOffset||0,a=r?.horizontalOffset||0,o=r?.responsiveHeight||!1,s=t.getBoundingClientRect(),c=$(e),l=s.left,u=s.top,d=document.documentElement.clientWidth-(l+s.width),f=u-i,p=document.documentElement.clientHeight-(u+s.height+i),m=l,h=u+s.height+i,g=c.offsetWidth-s.width,_={horizontal:`start`,vertical:`below`},v=`${p-i}px`;r?.centered&&l-16+s.width/2>c.offsetWidth/2&&d-16>g/2&&(m-=g/=2,_.horizontal=`center`),d<g&&l>g&&(m-=g,_.horizontal=`end`),a&&_.horizontal!==`center`&&s.width/2<a&&(m+=a*(_.horizontal===`start`?-1:1)),(l<g&&d<g||document.documentElement.clientWidth<c.offsetWidth)&&(m=document.documentElement.clientWidth/2-c.offsetWidth/2);let y=p-i>=c.scrollHeight,b=f-i>=(o?c.clientHeight:c.scrollHeight),x=!y&&(b||f>p);!r?.forceBelow&&(r?.forceAbove||x)&&(h=f<c.scrollHeight?h-s.height-f-i:u-c.clientHeight-i,v=`${f-i}px`,_.vertical=`above`);let S=n.getBoundingClientRect();return S.left<0&&(m-=S.left),S.top<0&&(h-=S.top),{top:h,left:m,maxHeight:v,alignment:_}}function yi(e,t,n,r){let i=r?.verticalOffset||0,a=r?.horizontalOffset||0,o=t.getBoundingClientRect(),s=$(e),c=t.parentElement.shadowRoot.querySelector(r?.contentSelector??`.${e.className}`).getBoundingClientRect(),l=n.getBoundingClientRect(),u=document.documentElement.clientWidth-c.right,d=document.documentElement.clientHeight-(o.top-i),f=document.documentElement.clientHeight,p=`${f-32}px`,m={horizontal:`end`,vertical:`above`},h=s.offsetWidth+a,g=c.right,_=o.top+i;return u<h&&o.left>h&&(g=g-c.width-s.offsetWidth,m.horizontal=`start`),a&&m.horizontal!==`center`&&(g+=a*(m.horizontal===`start`?-1:1)),d<s.scrollHeight&&(_=f-s.clientHeight-16),l.left<0&&(g-=l.left),l.top<0&&(_-=l.top),{top:_,left:g,maxHeight:p,alignment:m}}function bi(e,t,n,r,i,a=`auto`){if(!e||!t)return;let o=t.getBoundingClientRect();i.style.setProperty(`--sbb-options-panel-width`,`${t.offsetWidth}px`),i.style.setProperty(`--sbb-options-panel-origin-height`,`${t.offsetHeight}px`),i.style.setProperty(`--sbb-options-panel-origin-position-x`,`${o.left}px`),i.style.setProperty(`--sbb-options-panel-origin-position-y`,`${o.top}px`);let s=vi(n,t,r,{forceBelow:a===`below`,forceAbove:a===`above`});i.style.setProperty(`--sbb-options-panel-position-x`,`${s.left}px`),i.style.setProperty(`--sbb-options-panel-position-y`,`${s.top}px`),i.style.setProperty(`--sbb-options-panel-max-height-calculated`,s.maxHeight);let c=s.alignment.vertical===`above`;i.toggleState?.(`options-panel-position-above`,c),i.toggleState?.(`options-panel-position-below`,!c),t.setAttribute(`data-options-panel-position`,s.alignment.vertical)}var xi=class{constructor(){this._overlays=/* @__PURE__ */ new Set,this._pointerDownListener=e=>{this._pointerDownEventTarget=e.composedPath()[0]},this._clickListener=e=>{let t=e.composedPath()[0],n=e.type===`click`&&this._pointerDownEventTarget?this._pointerDownEventTarget:t;this._pointerDownEventTarget=void 0;for(let e of Array.from(this._overlays).reverse()){if(X(e,t)||X(e,n))break;e.dispatchEvent(new Event(`overlayOutsidePointer`))}}}connect(e){this._overlays.size||(this._addGlobalEventListeners(),j&&(this._cursorOriginalValue=document.body.style.cursor,document.body.style.cursor=`pointer`)),this._overlays.add(e)}disconnect(e){this._overlays.delete(e),this._overlays.size||(this._abortController?.abort(),this._abortController=void 0,this._pointerDownEventTarget=void 0,j&&(document.body.style.cursor=this._cursorOriginalValue))}_addGlobalEventListeners(){let e=document.body;this._abortController=new AbortController;let t={capture:!0,passive:!0,signal:this._abortController.signal};e.addEventListener(`click`,this._clickListener,t),!ie&&!j&&(e.addEventListener(`pointerdown`,this._pointerDownListener,t),e.addEventListener(`auxclick`,this._clickListener,t),e.addEventListener(`contextmenu`,this._clickListener,t))}};const Si=new xi;function Ci(e,t,n,r){t&&(t.ariaHasPopup=n,t.ariaControlsElements=Oe(t.ariaControlsElements,e),t.ariaExpanded=`${r===`opening`||r===`opened`}`)}function wi(e){e&&(e.ariaHasPopup=null,e.ariaControlsElements=null,e.ariaExpanded=null)}function Ti(e,t,n,r=`listbox`){e&&(e.setAttribute(`autocomplete`,`off`),e.setAttribute(`role`,`combobox`),e.setAttribute(`aria-autocomplete`,`list`),e.setAttribute(`aria-haspopup`,r),e.setAttribute(`aria-controls`,t),e.setAttribute(`aria-expanded`,`${n}`))}function Ei(e){e&&(e.removeAttribute(`autocomplete`),e.removeAttribute(`role`),e.removeAttribute(`aria-autocomplete`),e.removeAttribute(`aria-haspopup`),e.removeAttribute(`aria-controls`),e.removeAttribute(`aria-expanded`))}export{K as DateAdapter,yr as FORMAT_DATE,Er as FRIDAY,xr as ISO8601_FORMAT_DATE,te as IS_FOCUSABLE_QUERY,le as InteractivityChecker,ce as IsFocusableConfig,Sr as MONDAY,Ar as NativeDateAdapter,Dr as SATURDAY,br as SEPARATORLESS_FORMAT_DATE,Or as SUNDAY,F as SbbActionBaseElement,Kr as SbbAnimationCompleteMixin,Ne as SbbButtonBaseElement,Me as SbbButtonLikeBaseElement,ur as SbbDarkModeController,zn as SbbDisabledInteractiveMixin,V as SbbDisabledMixin,Bn as SbbDisabledTabIndexActionMixin,P as SbbElement,Kn as SbbEscapableOverlayController,be as SbbFocusTrapController,ee as SbbFocusVisibleWithinController,qr as SbbFormAssociatedCheckboxMixin,Xr as SbbFormAssociatedInputMixin,L as SbbFormAssociatedMixin,Zr as SbbFormAssociatedRadioButtonMixin,Jn as SbbIdReferenceController,$n as SbbInertController,z as SbbLanguageController,Ln as SbbLinkBaseElement,Se as SbbLiveAnnouncer,lr as SbbMediaMatcherController,ar as SbbMediaQueryBreakpointLargeAndAbove,cr as SbbMediaQueryBreakpointLargeAndBelow,ir as SbbMediaQueryBreakpointSmallAndAbove,sr as SbbMediaQueryBreakpointSmallAndBelow,or as SbbMediaQueryBreakpointUltraAndAbove,rr as SbbMediaQueryBreakpointZeroAndAbove,W as SbbMediaQueryDarkMode,er as SbbMediaQueryForcedColors,tr as SbbMediaQueryHover,nr as SbbMediaQueryPointerCoarse,di as SbbNamedSlotListMixin,fi as SbbNegativeMixin,Rn as SbbOpenCloseBaseElement,xi as SbbOverlayOutsidePointerEventListener,gr as SbbOverlayPositionController,mi as SbbPanelMixin,Wn as SbbPropertyWatcherController,Jr as SbbReadonlyMixin,H as SbbRequiredMixin,vr as SbbScrollController,Ur as SbbScrollHandler,Hn as SbbSelectionGroupBaseElement,hi as SbbSelectionPanelMixin,N as SbbSlottedChangeEvent,gi as SbbUpdateSchedulerMixin,Tr as THURSDAY,Cr as TUESDAY,Mr as TemporalDateAdapter,wr as WEDNESDAY,Oe as appendAriaElements,ii as buttonResetStyles,X as containsPierceShadowDom,q as defaultDateAdapter,I as forceType,Gr as forwardEvent,vi as getElementPosition,yi as getElementPositionHorizontal,$ as getElementRectangle,S as getEventTarget,y as getNextElementIndex,Nr as getOverride,Pr as handleDistinctChange,ai as hostScrollbarStyles,Qe as i18nAdditionalWagonInformationHeading,ze as i18nAnd,Ie as i18nArrival,In as i18nAutocompleteActionsHint,Ze as i18nBlockedPassage,Yt as i18nBreadcrumbEllipsisButtonLabel,Fn as i18nButton,Nt as i18nCalendarDateSelection,Tn as i18nCalendarWeekNumber,On as i18nCarouselArrowsNavigationHint,Dn as i18nCarouselItemAriaLabel,fn as i18nCheckboxRequired,Cn as i18nChipDelete,wn as i18nChipGroupInputDescription,Be as i18nClass,Xt as i18nClearInput,yt as i18nCloseAlert,St as i18nCloseDialog,Ct as i18nCloseNavigation,bt as i18nCloseNotification,Tt as i18nClosePopover,wt as i18nCloseSidebar,Ke as i18nClosedCompartmentLabel,qt as i18nCollapsed,Ut as i18nConnectionFrom,Gt as i18nConnectionRoundtrip,Wt as i18nConnectionTo,Ye as i18nCouchetteWagonLabel,Ht as i18nDateChangedTo,gn as i18nDateInvalid,vn as i18nDateMax,_n as i18nDateMin,Vt as i18nDatePickerPlaceholder,$e as i18nDeparture,xt as i18nDialog,Fe as i18nDirection,tt as i18nDownload,it as i18nDurationDay,rt as i18nDurationHour,nt as i18nDurationMinute,Kt as i18nExpanded,$t as i18nFileSelectorButtonLabel,en as i18nFileSelectorButtonLabelMultiple,an as i18nFileSelectorCurrentlySelected,rn as i18nFileSelectorDeleteFile,tn as i18nFileSelectorSubtitleLabel,nn as i18nFileSelectorSubtitleLabelMultiple,Zt as i18nFlipCard,ft as i18nFromPlatform,Et as i18nGoBack,hn as i18nInputRequired,ln as i18nItemsPerPage,qe as i18nLocomotiveLabel,Nn as i18nLogo125Anniversary,Pn as i18nLogo125AnniversaryYears,Jt as i18nMapContainerButtonLabel,ht as i18nMeansOfTransport,mn as i18nMultipleSelectionPossible,dt as i18nNew,At as i18nNextDay,Ot as i18nNextMonth,on as i18nNextPage,kn as i18nNextSlide,It as i18nNextYear,Pt as i18nNextYearRange,et as i18nNonAccessible,mt as i18nOccupancy,cn as i18nPage,dn as i18nPaginatorOf,un as i18nPaginatorSelected,jt as i18nPreviousDay,kt as i18nPreviousMonth,sn as i18nPreviousPage,An as i18nPreviousSlide,Lt as i18nPreviousYear,Ft as i18nPreviousYearRange,ct as i18nRealTimeInfo,Mn as i18nRemainingCharacters,Xe as i18nRestaurantWagonLabel,Qt as i18nReverseCard,Le as i18nSector,Re as i18nSectorShort,Rt as i18nSelectNextDay,zt as i18nSelectPreviousDay,pn as i18nSelectionRequired,Bt as i18nShowCalendar,Je as i18nSleepingWagonLabel,jn as i18nSlide,pt as i18nSupersaver,gt as i18nTargetOpensInNewWindow,yn as i18nTimeInputChange,bn as i18nTimeInvalid,xn as i18nTimeMax,Sn as i18nTimeMaxLength,En as i18nTimetableFormSwapButtonLabel,Dt as i18nToday,Ve as i18nTrain,He as i18nTrains,lt as i18nTransferProcedure,ut as i18nTransferProcedures,st as i18nTravelhints,ot as i18nTripDuration,at as i18nTripQuayChange,We as i18nWagonLabel,Ge as i18nWagonLabelNumber,Ue as i18nWagonsLabel,_t as i18nWalkingDistanceArrival,vt as i18nWalkingDistanceDeparture,Mt as i18nYearMonthSelection,Fr as idReference,M as interactivityChecker,ie as isAndroid,g as isArrowKeyOrPageKeysPressed,p as isArrowKeyPressed,k as isBlink,oe as isChromium,D as isEdge,_i as isEventOnElement,Ae as isEventPrevented,b as isFakeMousedownFromScreenReader,x as isFakeTouchstartFromScreenReader,re as isFirefox,j as isIOS,ne as isMacOS,h as isNextArrowKeyPressed,se as isNextjs,m as isPreviousArrowKeyPressed,ae as isSafari,O as isTrident,A as isWebkit,Rr as isZeroAnimationDuration,oi as listResetStyles,Pe as mergeConfig,B as omitEmptyConverter,Z as pageScrollDisabled,Lr as plainDate,Ir as plainDateConverter,ci as popoverResetStyles,Wr as preventScrollOnSpacebarPress,Br as queueDomContentLoaded,Q as radioButtonRegistry,R as readConfig,Ei as removeAriaComboBoxAttributes,ke as removeAriaElements,wi as removeAriaOverlayTriggerProperties,T as sbbInputModalityDetector,Ce as sbbLiveAnnouncer,Si as sbbOverlayOutsidePointerEventListener,si as screenReaderOnlyStyles,li as scrollbarStyles,Ti as setAriaComboBoxAttributes,Ci as setAriaOverlayTriggerProperties,zr as setOrRemoveAttribute,bi as setOverlayPosition,De as ɵstateController};
68
+ ${this.renderHiddenSlot()} `:this.renderHiddenSlot()}listSlotEntries(e){return(this.listChildren.length?this.listChildren:Array.from({length:+(this.getAttribute(di)??0)})).map((t,n)=>({name:`li-${n}`,ariaHidden:e?.localNameVisualOnly?.includes(t.localName)??!1}))}renderHiddenSlot(){return n`<span hidden><slot></slot></span>`}}})(),pi=e=>(()=>{let t=e,n,r=[],i=[];return class extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;n=[I(),l({reflect:!0,type:Boolean})],o(this,null,n,{kind:`accessor`,name:`negative`,static:!1,private:!1,access:{has:e=>`negative`in e,get:e=>e.negative,set:(e,t)=>{e.negative=t}},metadata:e},r,i),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}#e=s(this,r,!1);get negative(){return this.#e}set negative(e){this.#e=e}constructor(){super(...arguments),s(this,i)}}})();var mi=`:host{--sbb-selection-panel-background:var(--sbb-selection-panel-inner-background,var(--sbb-selection-panel-background-default));--sbb-selection-panel-border-width:var(--sbb-selection-panel-inner-border-width,var(--sbb-selection-panel-border-width-default));--sbb-selection-panel-animation-duration:var(--sbb-disable-animation-duration,var(--sbb-animation-duration-4x));display:block;outline:none!important}:host([size=xs]){--sbb-selection-panel-checkbox-dimension:var(--sbb-checkbox-dimension-xs);--sbb-selection-panel-input-padding:var(--sbb-selection-panel-input-padding-block-xs) var(--sbb-selection-panel-input-padding-inline-xs)}:host([size=s]){--sbb-selection-panel-checkbox-dimension:var(--sbb-checkbox-dimension-s);--sbb-selection-panel-input-padding:var(--sbb-selection-panel-input-padding-block-s) var(--sbb-selection-panel-input-padding-inline-s)}:host([size=m]){--sbb-selection-panel-checkbox-dimension:var(--sbb-checkbox-dimension-m);--sbb-selection-panel-input-padding:var(--sbb-selection-panel-input-padding-block-m) var(--sbb-selection-panel-input-padding-inline-m)}:host([color=milk]){--sbb-selection-panel-background:var(--sbb-selection-panel-inner-background,var(--sbb-selection-panel-background-milk))}:host([borderless]:not(:is(:state(checked),[state--checked]))){--sbb-selection-panel-border-color:var(--sbb-selection-panel-border-color-borderless)}:host(:is(:state(checked),[state--checked]):not(:disabled,[disabled])){--sbb-selection-panel-border-color:var(--sbb-selection-panel-border-color-checked);--sbb-selection-panel-border-width:var(--sbb-selection-panel-inner-border-width,var(--sbb-selection-panel-border-width-checked))}:host(:is(:disabled,[disabled])){--sbb-selection-panel-cursor:var(--sbb-cursor-default)}.sbb-selection-panel{cursor:var(--sbb-selection-panel-cursor);border-radius:var(--sbb-selection-panel-border-radius);box-shadow:inset 0 0 0 var(--sbb-selection-panel-border-width) var(--sbb-selection-panel-border-color);padding:var(--sbb-selection-panel-input-padding);background-color:var(--sbb-selection-panel-background);height:100%;transition-duration:var(--sbb-selection-panel-animation-duration);transition-timing-function:var(--sbb-animation-easing);transition-property:box-shadow;display:block;position:relative}@media (forced-colors:active){.sbb-selection-panel:after{content:"";pointer-events:none;border:var(--sbb-selection-panel-border-width) solid var(--sbb-selection-panel-border-color);border-radius:var(--sbb-selection-panel-border-radius);display:block;position:absolute;inset:0}}:host(:focus-visible) .sbb-selection-panel{outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) var(--sbb-focus-outline-style,solid) var(--sbb-focus-outline-width)}.sbb-selection-panel__badge{user-select:none;pointer-events:none;border-radius:var(--sbb-selection-panel-border-radius);position:absolute;inset:0;overflow:hidden}slot[name=suffix]{color:var(--sbb-selection-panel-suffix-color)}slot[name=subtext]{color:var(--sbb-selection-panel-subtext-color);padding-inline-start:calc(var(--sbb-selection-panel-checkbox-dimension) + var(--sbb-spacing-fixed-2x));display:block}:host(:not(:is(:state(slotted-subtext),[state--slotted-subtext]))) slot[name=subtext]{display:none}
69
+ `;const hi=e=>(()=>{let t=e,n,r=[],i=[],c,u=[],d=[],f,p=[],m=[],h,g=[],_=[];return class extends t{static{let e=typeof Symbol==`function`&&Symbol.metadata?Object.create(t[Symbol.metadata]??null):void 0;n=[l({reflect:!0})],c=[I(),l({reflect:!0,type:Boolean})],f=[I(),l()],h=[l({reflect:!0}),Pr((e,t)=>e.group?.size??t)],o(this,null,n,{kind:`accessor`,name:`color`,static:!1,private:!1,access:{has:e=>`color`in e,get:e=>e.color,set:(e,t)=>{e.color=t}},metadata:e},r,i),o(this,null,c,{kind:`accessor`,name:`borderless`,static:!1,private:!1,access:{has:e=>`borderless`in e,get:e=>e.borderless,set:(e,t)=>{e.borderless=t}},metadata:e},u,d),o(this,null,f,{kind:`accessor`,name:`expansionState`,static:!1,private:!1,access:{has:e=>`expansionState`in e,get:e=>e.expansionState,set:(e,t)=>{e.expansionState=t}},metadata:e},p,m),o(this,null,h,{kind:`accessor`,name:`size`,static:!1,private:!1,access:{has:e=>`size`in e,get:e=>e.size,set:(e,t)=>{e.size=t}},metadata:e},g,_),e&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:e})}static{this.styles=[a(mi)]}#e=s(this,r,`white`);get color(){return this.#e}set color(e){this.#e=e}#t=(s(this,i),s(this,u,!1));get borderless(){return this.#t}set borderless(e){this.#t=e}#n=(s(this,d),s(this,p,``));get expansionState(){return this.#n}set expansionState(e){this.#n=e}#r=(s(this,m),s(this,g,null));get size(){return this.#r}set size(e){this.#r=e}connectedCallback(){super.connectedCallback(),this.dispatchEvent(new Event(`panelconnected`,{bubbles:!0}))}constructor(){super(...arguments),s(this,_)}}})(),gi=e=>{class t extends e{get group(){return this.closest?.(`sbb-radio-button-group, sbb-checkbox-group`)??null}get panel(){return this.querySelector?.(`sbb-radio-button-panel, sbb-checkbox-panel`)??null}constructor(...e){super(e),this._previousSize=null,this._propertyWatcher=new Wn(this,()=>this.panel,{checked:e=>{this.toggleState(`checked`,e.checked),this.onInputStateChange?.()},disabled:e=>{this.toggleState(`disabled`,e.disabled),this.onInputStateChange?.()},size:e=>{this._previousSize&&this.internals.states.delete(`size-${this._previousSize}`),this._previousSize=e.size,this._previousSize&&this.internals.states.add(`size-${this._previousSize}`)},borderless:e=>{this.toggleState(`borderless`,e.borderless)},color:e=>{this._previousColor&&this.internals.states.delete(`color-${this._previousColor}`),this._previousColor=e.color,this._previousColor&&this.internals.states.add(`color-${this._previousColor}`)}}),this.addEventListener?.(`panelconnected`,()=>this._propertyWatcher.connect())}onInputStateChange(){}}return t},_i=e=>{class t extends e{constructor(){super(...arguments),this._updatePromise=Promise.resolve(),this._updateResolve=()=>{}}startUpdate(){this._updatePromise=new Promise(e=>this._updateResolve=e)}completeUpdate(){this._updateResolve()}async getUpdateComplete(){let e=await super.getUpdateComplete();return await this._updatePromise,e}}return t};function $(e){let t=window.getComputedStyle(e),n=t.display,r=parseInt(t.maxHeight,10).toString();if(n!==`none`&&r!==`0`)return{scrollHeight:e.scrollHeight,clientHeight:e.clientHeight,offsetHeight:e.offsetHeight,scrollWidth:e.scrollWidth,clientWidth:e.clientWidth,offsetWidth:e.offsetWidth};e.style.position=`absolute`,e.style.visibility=`hidden`,e.style.display=`block`;let i=e.scrollHeight,a=e.clientHeight,o=e.offsetHeight,s=e.scrollWidth,c=e.clientWidth,l=e.offsetWidth;return e.style.display=``,e.style.position=``,e.style.visibility=``,{scrollHeight:i,clientHeight:a,offsetHeight:o,scrollWidth:s,clientWidth:c,offsetWidth:l}}function vi(e,t){if(!e||!t)return!1;let n=e.getBoundingClientRect();return n.top<=t.clientY&&t.clientY<=n.top+n.height&&n.left<=t.clientX&&t.clientX<=n.left+n.width}function yi(e,t,n,r){let i=r?.verticalOffset||0,a=r?.horizontalOffset||0,o=r?.responsiveHeight||!1,s=t.getBoundingClientRect(),c=$(e),l=s.left,u=s.top,d=document.documentElement.clientWidth-(l+s.width),f=u-i,p=document.documentElement.clientHeight-(u+s.height+i),m=l,h=u+s.height+i,g=c.offsetWidth-s.width,_={horizontal:`start`,vertical:`below`},v=`${p-i}px`;r?.centered&&l-16+s.width/2>c.offsetWidth/2&&d-16>g/2&&(m-=g/=2,_.horizontal=`center`),d<g&&l>g&&(m-=g,_.horizontal=`end`),a&&_.horizontal!==`center`&&s.width/2<a&&(m+=a*(_.horizontal===`start`?-1:1)),(l<g&&d<g||document.documentElement.clientWidth<c.offsetWidth)&&(m=document.documentElement.clientWidth/2-c.offsetWidth/2);let y=p-i>=c.scrollHeight,b=f-i>=(o?c.clientHeight:c.scrollHeight),x=!y&&(b||f>p);!r?.forceBelow&&(r?.forceAbove||x)&&(h=f<c.scrollHeight?h-s.height-f-i:u-c.clientHeight-i,v=`${f-i}px`,_.vertical=`above`);let S=n.getBoundingClientRect();return S.left<0&&(m-=S.left),S.top<0&&(h-=S.top),{top:h,left:m,maxHeight:v,alignment:_}}function bi(e,t,n,r){let i=r?.verticalOffset||0,a=r?.horizontalOffset||0,o=t.getBoundingClientRect(),s=$(e),c=t.parentElement.shadowRoot.querySelector(r?.contentSelector??`.${e.className}`).getBoundingClientRect(),l=n.getBoundingClientRect(),u=document.documentElement.clientWidth-c.right,d=document.documentElement.clientHeight-(o.top-i),f=document.documentElement.clientHeight,p=`${f-32}px`,m={horizontal:`end`,vertical:`above`},h=s.offsetWidth+a,g=c.right,_=o.top+i;return u<h&&o.left>h&&(g=g-c.width-s.offsetWidth,m.horizontal=`start`),a&&m.horizontal!==`center`&&(g+=a*(m.horizontal===`start`?-1:1)),d<s.scrollHeight&&(_=f-s.clientHeight-16),l.left<0&&(g-=l.left),l.top<0&&(_-=l.top),{top:_,left:g,maxHeight:p,alignment:m}}function xi(e,t,n,r,i,a=`auto`){if(!e||!t)return;let o=t.getBoundingClientRect();i.style.setProperty(`--sbb-options-panel-width`,`${t.offsetWidth}px`),i.style.setProperty(`--sbb-options-panel-origin-height`,`${t.offsetHeight}px`),i.style.setProperty(`--sbb-options-panel-origin-position-x`,`${o.left}px`),i.style.setProperty(`--sbb-options-panel-origin-position-y`,`${o.top}px`);let s=yi(n,t,r,{forceBelow:a===`below`,forceAbove:a===`above`});i.style.setProperty(`--sbb-options-panel-position-x`,`${s.left}px`),i.style.setProperty(`--sbb-options-panel-position-y`,`${s.top}px`),i.style.setProperty(`--sbb-options-panel-max-height-calculated`,s.maxHeight);let c=s.alignment.vertical===`above`;i.toggleState?.(`options-panel-position-above`,c),i.toggleState?.(`options-panel-position-below`,!c),t.setAttribute(`data-options-panel-position`,s.alignment.vertical)}var Si=class{constructor(){this._overlays=/* @__PURE__ */ new Set,this._pointerDownListener=e=>{this._pointerDownEventTarget=e.composedPath()[0]},this._clickListener=e=>{let t=e.composedPath()[0],n=e.type===`click`&&this._pointerDownEventTarget?this._pointerDownEventTarget:t;this._pointerDownEventTarget=void 0;for(let e of Array.from(this._overlays).reverse()){if(X(e,t)||X(e,n))break;e.dispatchEvent(new Event(`overlayOutsidePointer`))}}}connect(e){this._overlays.size||(this._addGlobalEventListeners(),j&&(this._cursorOriginalValue=document.body.style.cursor,document.body.style.cursor=`pointer`)),this._overlays.add(e)}disconnect(e){this._overlays.delete(e),this._overlays.size||(this._abortController?.abort(),this._abortController=void 0,this._pointerDownEventTarget=void 0,j&&(document.body.style.cursor=this._cursorOriginalValue))}_addGlobalEventListeners(){let e=document.body;this._abortController=new AbortController;let t={capture:!0,passive:!0,signal:this._abortController.signal};e.addEventListener(`click`,this._clickListener,t),!ie&&!j&&(e.addEventListener(`pointerdown`,this._pointerDownListener,t),e.addEventListener(`auxclick`,this._clickListener,t),e.addEventListener(`contextmenu`,this._clickListener,t))}};const Ci=new Si;function wi(e,t,n,r){t&&(t.ariaHasPopup=n,t.ariaControlsElements=Oe(t.ariaControlsElements,e),t.ariaExpanded=`${r===`opening`||r===`opened`}`)}function Ti(e){e&&(e.ariaHasPopup=null,e.ariaControlsElements=null,e.ariaExpanded=null)}function Ei(e,t,n,r=`listbox`){e&&(e.setAttribute(`autocomplete`,`off`),e.setAttribute(`role`,`combobox`),e.setAttribute(`aria-autocomplete`,`list`),e.setAttribute(`aria-haspopup`,r),e.setAttribute(`aria-controls`,t),e.setAttribute(`aria-expanded`,`${n}`))}function Di(e){e&&(e.removeAttribute(`autocomplete`),e.removeAttribute(`role`),e.removeAttribute(`aria-autocomplete`),e.removeAttribute(`aria-haspopup`),e.removeAttribute(`aria-controls`),e.removeAttribute(`aria-expanded`))}export{K as DateAdapter,br as FORMAT_DATE,Dr as FRIDAY,Sr as ISO8601_FORMAT_DATE,te as IS_FOCUSABLE_QUERY,le as InteractivityChecker,ce as IsFocusableConfig,Cr as MONDAY,jr as NativeDateAdapter,Or as SATURDAY,xr as SEPARATORLESS_FORMAT_DATE,kr as SUNDAY,F as SbbActionBaseElement,qr as SbbAnimationCompleteMixin,Ne as SbbButtonBaseElement,Me as SbbButtonLikeBaseElement,ur as SbbDarkModeController,zn as SbbDisabledInteractiveMixin,V as SbbDisabledMixin,Bn as SbbDisabledTabIndexActionMixin,P as SbbElement,Kn as SbbEscapableOverlayController,be as SbbFocusTrapController,ee as SbbFocusVisibleWithinController,Jr as SbbFormAssociatedCheckboxMixin,Zr as SbbFormAssociatedInputMixin,L as SbbFormAssociatedMixin,Qr as SbbFormAssociatedRadioButtonMixin,Jn as SbbIdReferenceController,$n as SbbInertController,z as SbbLanguageController,Ln as SbbLinkBaseElement,Se as SbbLiveAnnouncer,lr as SbbMediaMatcherController,ar as SbbMediaQueryBreakpointLargeAndAbove,cr as SbbMediaQueryBreakpointLargeAndBelow,ir as SbbMediaQueryBreakpointSmallAndAbove,sr as SbbMediaQueryBreakpointSmallAndBelow,or as SbbMediaQueryBreakpointUltraAndAbove,rr as SbbMediaQueryBreakpointZeroAndAbove,W as SbbMediaQueryDarkMode,er as SbbMediaQueryForcedColors,tr as SbbMediaQueryHover,nr as SbbMediaQueryPointerCoarse,fi as SbbNamedSlotListMixin,pi as SbbNegativeMixin,Rn as SbbOpenCloseBaseElement,Si as SbbOverlayOutsidePointerEventListener,gr as SbbOverlayPositionController,hi as SbbPanelMixin,Wn as SbbPropertyWatcherController,Yr as SbbReadonlyMixin,H as SbbRequiredMixin,vr as SbbScrollController,Wr as SbbScrollHandler,Hn as SbbSelectionGroupBaseElement,gi as SbbSelectionPanelMixin,N as SbbSlottedChangeEvent,yr as SbbTemporaryFocusController,_i as SbbUpdateSchedulerMixin,Er as THURSDAY,wr as TUESDAY,Nr as TemporalDateAdapter,Tr as WEDNESDAY,Oe as appendAriaElements,ai as buttonResetStyles,X as containsPierceShadowDom,q as defaultDateAdapter,I as forceType,Kr as forwardEvent,yi as getElementPosition,bi as getElementPositionHorizontal,$ as getElementRectangle,S as getEventTarget,y as getNextElementIndex,Pr as getOverride,Fr as handleDistinctChange,oi as hostScrollbarStyles,Qe as i18nAdditionalWagonInformationHeading,ze as i18nAnd,Ie as i18nArrival,In as i18nAutocompleteActionsHint,Ze as i18nBlockedPassage,Yt as i18nBreadcrumbEllipsisButtonLabel,Fn as i18nButton,Nt as i18nCalendarDateSelection,Tn as i18nCalendarWeekNumber,On as i18nCarouselArrowsNavigationHint,Dn as i18nCarouselItemAriaLabel,fn as i18nCheckboxRequired,Cn as i18nChipDelete,wn as i18nChipGroupInputDescription,Be as i18nClass,Xt as i18nClearInput,yt as i18nCloseAlert,St as i18nCloseDialog,Ct as i18nCloseNavigation,bt as i18nCloseNotification,Tt as i18nClosePopover,wt as i18nCloseSidebar,Ke as i18nClosedCompartmentLabel,qt as i18nCollapsed,Ut as i18nConnectionFrom,Gt as i18nConnectionRoundtrip,Wt as i18nConnectionTo,Ye as i18nCouchetteWagonLabel,Ht as i18nDateChangedTo,gn as i18nDateInvalid,vn as i18nDateMax,_n as i18nDateMin,Vt as i18nDatePickerPlaceholder,$e as i18nDeparture,xt as i18nDialog,Fe as i18nDirection,tt as i18nDownload,it as i18nDurationDay,rt as i18nDurationHour,nt as i18nDurationMinute,Kt as i18nExpanded,$t as i18nFileSelectorButtonLabel,en as i18nFileSelectorButtonLabelMultiple,an as i18nFileSelectorCurrentlySelected,rn as i18nFileSelectorDeleteFile,tn as i18nFileSelectorSubtitleLabel,nn as i18nFileSelectorSubtitleLabelMultiple,Zt as i18nFlipCard,ft as i18nFromPlatform,Et as i18nGoBack,hn as i18nInputRequired,ln as i18nItemsPerPage,qe as i18nLocomotiveLabel,Nn as i18nLogo125Anniversary,Pn as i18nLogo125AnniversaryYears,Jt as i18nMapContainerButtonLabel,ht as i18nMeansOfTransport,mn as i18nMultipleSelectionPossible,dt as i18nNew,At as i18nNextDay,Ot as i18nNextMonth,on as i18nNextPage,kn as i18nNextSlide,It as i18nNextYear,Pt as i18nNextYearRange,et as i18nNonAccessible,mt as i18nOccupancy,cn as i18nPage,dn as i18nPaginatorOf,un as i18nPaginatorSelected,jt as i18nPreviousDay,kt as i18nPreviousMonth,sn as i18nPreviousPage,An as i18nPreviousSlide,Lt as i18nPreviousYear,Ft as i18nPreviousYearRange,ct as i18nRealTimeInfo,Mn as i18nRemainingCharacters,Xe as i18nRestaurantWagonLabel,Qt as i18nReverseCard,Le as i18nSector,Re as i18nSectorShort,Rt as i18nSelectNextDay,zt as i18nSelectPreviousDay,pn as i18nSelectionRequired,Bt as i18nShowCalendar,Je as i18nSleepingWagonLabel,jn as i18nSlide,pt as i18nSupersaver,gt as i18nTargetOpensInNewWindow,yn as i18nTimeInputChange,bn as i18nTimeInvalid,xn as i18nTimeMax,Sn as i18nTimeMaxLength,En as i18nTimetableFormSwapButtonLabel,Dt as i18nToday,Ve as i18nTrain,He as i18nTrains,lt as i18nTransferProcedure,ut as i18nTransferProcedures,st as i18nTravelhints,ot as i18nTripDuration,at as i18nTripQuayChange,We as i18nWagonLabel,Ge as i18nWagonLabelNumber,Ue as i18nWagonsLabel,_t as i18nWalkingDistanceArrival,vt as i18nWalkingDistanceDeparture,Mt as i18nYearMonthSelection,Ir as idReference,M as interactivityChecker,ie as isAndroid,g as isArrowKeyOrPageKeysPressed,p as isArrowKeyPressed,k as isBlink,oe as isChromium,D as isEdge,vi as isEventOnElement,Ae as isEventPrevented,b as isFakeMousedownFromScreenReader,x as isFakeTouchstartFromScreenReader,re as isFirefox,j as isIOS,ne as isMacOS,h as isNextArrowKeyPressed,se as isNextjs,m as isPreviousArrowKeyPressed,ae as isSafari,O as isTrident,A as isWebkit,zr as isZeroAnimationDuration,si as listResetStyles,Pe as mergeConfig,B as omitEmptyConverter,Z as pageScrollDisabled,Rr as plainDate,Lr as plainDateConverter,li as popoverResetStyles,Gr as preventScrollOnSpacebarPress,Vr as queueDomContentLoaded,Q as radioButtonRegistry,R as readConfig,Di as removeAriaComboBoxAttributes,ke as removeAriaElements,Ti as removeAriaOverlayTriggerProperties,T as sbbInputModalityDetector,Ce as sbbLiveAnnouncer,Ci as sbbOverlayOutsidePointerEventListener,ci as screenReaderOnlyStyles,ui as scrollbarStyles,Ei as setAriaComboBoxAttributes,wi as setAriaOverlayTriggerProperties,Br as setOrRemoveAttribute,xi as setOverlayPosition,De as ɵstateController};
@@ -10060,6 +10060,72 @@
10060
10060
  }
10061
10061
  ]
10062
10062
  },
10063
+ {
10064
+ "kind": "javascript-module",
10065
+ "path": "core/controllers/temporary-focus-controller.js",
10066
+ "declarations": [
10067
+ {
10068
+ "kind": "class",
10069
+ "description": "Temporarily allows focus to be set to an element that does not have a tabindex.",
10070
+ "name": "SbbTemporaryFocusController",
10071
+ "members": [
10072
+ {
10073
+ "kind": "field",
10074
+ "name": "_abortController",
10075
+ "privacy": "private",
10076
+ "default": "new AbortController()"
10077
+ },
10078
+ {
10079
+ "kind": "field",
10080
+ "name": "_host",
10081
+ "type": {
10082
+ "text": "ReactiveControllerHost & HTMLElement"
10083
+ },
10084
+ "privacy": "private",
10085
+ "default": "host"
10086
+ },
10087
+ {
10088
+ "kind": "method",
10089
+ "name": "hostDisconnected",
10090
+ "privacy": "public",
10091
+ "return": {
10092
+ "type": {
10093
+ "text": "void"
10094
+ }
10095
+ }
10096
+ },
10097
+ {
10098
+ "kind": "method",
10099
+ "name": "_purge",
10100
+ "privacy": "private",
10101
+ "return": {
10102
+ "type": {
10103
+ "text": "void"
10104
+ }
10105
+ }
10106
+ },
10107
+ {
10108
+ "kind": "field",
10109
+ "name": "tabIndex",
10110
+ "type": {
10111
+ "text": "number"
10112
+ },
10113
+ "default": "-1"
10114
+ }
10115
+ ]
10116
+ }
10117
+ ],
10118
+ "exports": [
10119
+ {
10120
+ "kind": "js",
10121
+ "name": "SbbTemporaryFocusController",
10122
+ "declaration": {
10123
+ "name": "SbbTemporaryFocusController",
10124
+ "module": "core/controllers/temporary-focus-controller.js"
10125
+ }
10126
+ }
10127
+ ]
10128
+ },
10063
10129
  {
10064
10130
  "kind": "javascript-module",
10065
10131
  "path": "core/datetime/native-date-adapter.js",
@@ -16358,6 +16424,18 @@
16358
16424
  "readonly": true,
16359
16425
  "default": "'radio'"
16360
16426
  },
16427
+ {
16428
+ "kind": "field",
16429
+ "name": "_tabindexState",
16430
+ "type": {
16431
+ "text": "object"
16432
+ },
16433
+ "privacy": "private",
16434
+ "static": true,
16435
+ "readonly": true,
16436
+ "default": "{ elements: new Set<SbbFormAssociatedRadioButtonElement>(), handleEvent(event: KeyboardEvent): void { if (event.key === 'Tab') { Array.from(this.elements, (e) => e.associatedRadioButtons) .filter((v, i, a) => !!v && a.indexOf(v) === i) .forEach((s) => s?.values().next().value?.updateFocusableRadios()); } }, add(element: SbbFormAssociatedRadioButtonElement) { if (!this.elements.size) { window.addEventListener('keydown', this, { passive: true }); } this.elements.add(element); }, delete(element: SbbFormAssociatedRadioButtonElement) { this.elements.delete(element); if (!this.elements.size) { window.removeEventListener('keydown', this); } }, }",
16437
+ "description": "The native radio button places focus on the currently selected\nor, with no selected option, on the first visible radio button.\nAs we cannot deterministically detect when an element becomes\nvisible, we re-check visibility state of radio buttons\non Tab key press."
16438
+ },
16361
16439
  {
16362
16440
  "kind": "field",
16363
16441
  "name": "checked",
@@ -16425,6 +16503,11 @@
16425
16503
  "privacy": "private",
16426
16504
  "default": "new SbbLanguageController(this)"
16427
16505
  },
16506
+ {
16507
+ "kind": "field",
16508
+ "name": "_tabindexState",
16509
+ "privacy": "private"
16510
+ },
16428
16511
  {
16429
16512
  "kind": "method",
16430
16513
  "name": "_readFormData",
@@ -24174,6 +24257,22 @@
24174
24257
  "module": "core/base-elements/element.js"
24175
24258
  }
24176
24259
  },
24260
+ {
24261
+ "kind": "field",
24262
+ "name": "_tabindexState",
24263
+ "privacy": "private",
24264
+ "type": {
24265
+ "text": "object"
24266
+ },
24267
+ "static": true,
24268
+ "readonly": true,
24269
+ "default": "{ elements: new Set<SbbFormAssociatedRadioButtonElement>(), handleEvent(event: KeyboardEvent): void { if (event.key === 'Tab') { Array.from(this.elements, (e) => e.associatedRadioButtons) .filter((v, i, a) => !!v && a.indexOf(v) === i) .forEach((s) => s?.values().next().value?.updateFocusableRadios()); } }, add(element: SbbFormAssociatedRadioButtonElement) { if (!this.elements.size) { window.addEventListener('keydown', this, { passive: true }); } this.elements.add(element); }, delete(element: SbbFormAssociatedRadioButtonElement) { this.elements.delete(element); if (!this.elements.size) { window.removeEventListener('keydown', this); } }, }",
24270
+ "description": "The native radio button places focus on the currently selected\nor, with no selected option, on the first visible radio button.\nAs we cannot deterministically detect when an element becomes\nvisible, we re-check visibility state of radio buttons\non Tab key press.",
24271
+ "inheritedFrom": {
24272
+ "name": "SbbFormAssociatedRadioButtonMixin",
24273
+ "module": "core/mixins/form-associated-radio-button-mixin.js"
24274
+ }
24275
+ },
24177
24276
  {
24178
24277
  "kind": "field",
24179
24278
  "name": "checked",
@@ -25335,7 +25434,7 @@
25335
25434
  "privacy": "private",
25336
25435
  "return": {
25337
25436
  "type": {
25338
- "text": "Promise<void>"
25437
+ "text": "void"
25339
25438
  }
25340
25439
  },
25341
25440
  "parameters": [
@@ -25380,6 +25479,22 @@
25380
25479
  "module": "core/mixins/form-associated-radio-button-mixin.js"
25381
25480
  }
25382
25481
  },
25482
+ {
25483
+ "kind": "field",
25484
+ "name": "_tabindexState",
25485
+ "privacy": "private",
25486
+ "type": {
25487
+ "text": "object"
25488
+ },
25489
+ "static": true,
25490
+ "readonly": true,
25491
+ "default": "{ elements: new Set<SbbFormAssociatedRadioButtonElement>(), handleEvent(event: KeyboardEvent): void { if (event.key === 'Tab') { Array.from(this.elements, (e) => e.associatedRadioButtons) .filter((v, i, a) => !!v && a.indexOf(v) === i) .forEach((s) => s?.values().next().value?.updateFocusableRadios()); } }, add(element: SbbFormAssociatedRadioButtonElement) { if (!this.elements.size) { window.addEventListener('keydown', this, { passive: true }); } this.elements.add(element); }, delete(element: SbbFormAssociatedRadioButtonElement) { this.elements.delete(element); if (!this.elements.size) { window.removeEventListener('keydown', this); } }, }",
25492
+ "description": "The native radio button places focus on the currently selected\nor, with no selected option, on the first visible radio button.\nAs we cannot deterministically detect when an element becomes\nvisible, we re-check visibility state of radio buttons\non Tab key press.",
25493
+ "inheritedFrom": {
25494
+ "name": "SbbFormAssociatedRadioButtonMixin",
25495
+ "module": "core/mixins/form-associated-radio-button-mixin.js"
25496
+ }
25497
+ },
25383
25498
  {
25384
25499
  "kind": "field",
25385
25500
  "name": "checked",
@@ -26339,7 +26454,7 @@
26339
26454
  "privacy": "private",
26340
26455
  "return": {
26341
26456
  "type": {
26342
- "text": "Promise<void>"
26457
+ "text": "void"
26343
26458
  }
26344
26459
  },
26345
26460
  "parameters": [
@@ -26392,6 +26507,22 @@
26392
26507
  "module": "core/base-elements/element.js"
26393
26508
  }
26394
26509
  },
26510
+ {
26511
+ "kind": "field",
26512
+ "name": "_tabindexState",
26513
+ "privacy": "private",
26514
+ "type": {
26515
+ "text": "object"
26516
+ },
26517
+ "static": true,
26518
+ "readonly": true,
26519
+ "default": "{ elements: new Set<SbbFormAssociatedRadioButtonElement>(), handleEvent(event: KeyboardEvent): void { if (event.key === 'Tab') { Array.from(this.elements, (e) => e.associatedRadioButtons) .filter((v, i, a) => !!v && a.indexOf(v) === i) .forEach((s) => s?.values().next().value?.updateFocusableRadios()); } }, add(element: SbbFormAssociatedRadioButtonElement) { if (!this.elements.size) { window.addEventListener('keydown', this, { passive: true }); } this.elements.add(element); }, delete(element: SbbFormAssociatedRadioButtonElement) { this.elements.delete(element); if (!this.elements.size) { window.removeEventListener('keydown', this); } }, }",
26520
+ "description": "The native radio button places focus on the currently selected\nor, with no selected option, on the first visible radio button.\nAs we cannot deterministically detect when an element becomes\nvisible, we re-check visibility state of radio buttons\non Tab key press.",
26521
+ "inheritedFrom": {
26522
+ "name": "SbbFormAssociatedRadioButtonMixin",
26523
+ "module": "core/mixins/form-associated-radio-button-mixin.js"
26524
+ }
26525
+ },
26395
26526
  {
26396
26527
  "kind": "field",
26397
26528
  "name": "checked",
@@ -27722,7 +27853,7 @@
27722
27853
  "privacy": "private",
27723
27854
  "return": {
27724
27855
  "type": {
27725
- "text": "Promise<void>"
27856
+ "text": "void"
27726
27857
  }
27727
27858
  },
27728
27859
  "parameters": [
@@ -27775,6 +27906,22 @@
27775
27906
  "module": "core/base-elements/element.js"
27776
27907
  }
27777
27908
  },
27909
+ {
27910
+ "kind": "field",
27911
+ "name": "_tabindexState",
27912
+ "privacy": "private",
27913
+ "type": {
27914
+ "text": "object"
27915
+ },
27916
+ "static": true,
27917
+ "readonly": true,
27918
+ "default": "{ elements: new Set<SbbFormAssociatedRadioButtonElement>(), handleEvent(event: KeyboardEvent): void { if (event.key === 'Tab') { Array.from(this.elements, (e) => e.associatedRadioButtons) .filter((v, i, a) => !!v && a.indexOf(v) === i) .forEach((s) => s?.values().next().value?.updateFocusableRadios()); } }, add(element: SbbFormAssociatedRadioButtonElement) { if (!this.elements.size) { window.addEventListener('keydown', this, { passive: true }); } this.elements.add(element); }, delete(element: SbbFormAssociatedRadioButtonElement) { this.elements.delete(element); if (!this.elements.size) { window.removeEventListener('keydown', this); } }, }",
27919
+ "description": "The native radio button places focus on the currently selected\nor, with no selected option, on the first visible radio button.\nAs we cannot deterministically detect when an element becomes\nvisible, we re-check visibility state of radio buttons\non Tab key press.",
27920
+ "inheritedFrom": {
27921
+ "name": "SbbFormAssociatedRadioButtonMixin",
27922
+ "module": "core/mixins/form-associated-radio-button-mixin.js"
27923
+ }
27924
+ },
27778
27925
  {
27779
27926
  "kind": "field",
27780
27927
  "name": "checked",
@@ -29023,11 +29170,11 @@
29023
29170
  "kind": "field",
29024
29171
  "name": "_fallbackValue",
29025
29172
  "type": {
29026
- "text": "T | null"
29173
+ "text": "T | null | typeof emptyValue"
29027
29174
  },
29028
29175
  "privacy": "private",
29029
- "default": "null",
29030
- "description": "Used to preserve the `value` in case the radios are not yet 'loaded'"
29176
+ "default": "emptyValue",
29177
+ "description": "Used to preserve the `value` in case the radios are not yet 'loaded'."
29031
29178
  },
29032
29179
  {
29033
29180
  "kind": "field",
@@ -31092,6 +31239,14 @@
31092
31239
  "module": "core/controllers/scroll-controller.js"
31093
31240
  }
31094
31241
  },
31242
+ {
31243
+ "kind": "js",
31244
+ "name": "*",
31245
+ "declaration": {
31246
+ "name": "*",
31247
+ "module": "core/controllers/temporary-focus-controller.js"
31248
+ }
31249
+ },
31095
31250
  {
31096
31251
  "kind": "js",
31097
31252
  "name": "*",
@@ -2,7 +2,7 @@ import { __esDecorate, __runInitializers } from "tslib";
2
2
  import { html, nothing, unsafeCSS } from "lit";
3
3
  import { property, state } from "lit/decorators.js";
4
4
  import { html as html$1, unsafeStatic } from "lit/static-html.js";
5
- import { SbbDarkModeController, SbbElement, SbbLanguageController, SbbOpenCloseBaseElement, SbbReadonlyMixin, forceType, i18nCloseAlert, isEventPrevented, isZeroAnimationDuration, screenReaderOnlyStyles } from "./core.js";
5
+ import { SbbDarkModeController, SbbElement, SbbLanguageController, SbbOpenCloseBaseElement, SbbReadonlyMixin, SbbTemporaryFocusController, forceType, i18nCloseAlert, isEventPrevented, isZeroAnimationDuration, screenReaderOnlyStyles } from "./core.js";
6
6
  import { SbbTransparentButtonElement } from "./button.pure.js";
7
7
  import { SbbDividerElement } from "./divider.pure.js";
8
8
  import { SbbIconNameMixin } from "./icon.pure.js";
@@ -157,9 +157,8 @@ let SbbAlertGroupElement = (() => {
157
157
  _alertClosed(event) {
158
158
  const target = event.target;
159
159
  if (document.activeElement === target) {
160
- this.tabIndex = 0;
160
+ if (!this.hasAttribute("tabindex")) this.addController(new SbbTemporaryFocusController(this));
161
161
  this.focus();
162
- this.addEventListener("blur", () => this.removeAttribute("tabindex"), { once: true });
163
162
  }
164
163
  }
165
164
  _slotChanged(event) {
@@ -0,0 +1,11 @@
1
+ import type { ReactiveController, ReactiveControllerHost } from 'lit';
2
+ /**
3
+ * Temporarily allows focus to be set to an element that does not have a tabindex.
4
+ */
5
+ export declare class SbbTemporaryFocusController implements ReactiveController {
6
+ private _abortController;
7
+ private _host;
8
+ constructor(host: ReactiveControllerHost & HTMLElement);
9
+ hostDisconnected(): void;
10
+ private _purge;
11
+ }
@@ -22,6 +22,7 @@ export * from './core/controllers/language-controller.ts';
22
22
  export * from './core/controllers/media-matchers-controller.ts';
23
23
  export * from './core/controllers/overlay-position-controller.ts';
24
24
  export * from './core/controllers/scroll-controller.ts';
25
+ export * from './core/controllers/temporary-focus-controller.ts';
25
26
  export * from './core/datetime/date-adapter.ts';
26
27
  export * from './core/datetime/native-date-adapter.ts';
27
28
  export * from './core/datetime/temporal-date-adapter.ts';
@@ -3996,6 +3996,31 @@ var SbbScrollController = class {
3996
3996
  }
3997
3997
  };
3998
3998
 
3999
+ // src/elements/core/controllers/temporary-focus-controller.ts
4000
+ /**
4001
+ * Temporarily allows focus to be set to an element that does not have a tabindex.
4002
+ */
4003
+ var SbbTemporaryFocusController = class {
4004
+ constructor(host) {
4005
+ this._abortController = new AbortController();
4006
+ this._host = host;
4007
+ host.addController(this);
4008
+ host.tabIndex = -1;
4009
+ host.addEventListener("blur", () => this._purge(), {
4010
+ once: true,
4011
+ signal: this._abortController.signal
4012
+ });
4013
+ }
4014
+ hostDisconnected() {
4015
+ this._abortController.abort();
4016
+ this._purge();
4017
+ }
4018
+ _purge() {
4019
+ this._host.removeController(this);
4020
+ this._host.removeAttribute("tabindex");
4021
+ }
4022
+ };
4023
+
3999
4024
  // src/elements/core/datetime/date-adapter.ts
4000
4025
  const FORMAT_DATE = /(0?[1-9]|[12][0-9]|3[01])[.,\\/\-\s](0?[1-9]|1[0-2])[.,\\/\-\s]([0-9]{1,4}$)?/;
4001
4026
  const SEPARATORLESS_FORMAT_DATE = /([0-9]{2})([0-9]{2})([0-9]{4})/;
@@ -5420,6 +5445,29 @@ const SbbFormAssociatedRadioButtonMixin = (superClass) => {
5420
5445
  this.role = "radio";
5421
5446
  }
5422
5447
  /**
5448
+ * The native radio button places focus on the currently selected
5449
+ * or, with no selected option, on the first visible radio button.
5450
+ * As we cannot deterministically detect when an element becomes
5451
+ * visible, we re-check visibility state of radio buttons
5452
+ * on Tab key press.
5453
+ */
5454
+ static {
5455
+ this._tabindexState = {
5456
+ elements: /* @__PURE__ */ new Set(),
5457
+ handleEvent(event) {
5458
+ if (event.key === "Tab") Array.from(this.elements, (e) => e.associatedRadioButtons).filter((v, i, a) => !!v && a.indexOf(v) === i).forEach((s) => s?.values().next().value?.updateFocusableRadios());
5459
+ },
5460
+ add(element) {
5461
+ if (!this.elements.size) window.addEventListener("keydown", this, { passive: true });
5462
+ this.elements.add(element);
5463
+ },
5464
+ delete(element) {
5465
+ this.elements.delete(element);
5466
+ if (!this.elements.size) window.removeEventListener("keydown", this);
5467
+ }
5468
+ };
5469
+ }
5470
+ /**
5423
5471
  * Whether the radio button is checked.
5424
5472
  */
5425
5473
  set checked(value) {
@@ -5455,12 +5503,21 @@ const SbbFormAssociatedRadioButtonMixin = (superClass) => {
5455
5503
  super();
5456
5504
  this._checked = (__runInitializers(this, _instanceExtraInitializers), false);
5457
5505
  this._languageController = new SbbLanguageController(this);
5506
+ this._tabindexState = SbbFormAssociatedRadioButtonElement._tabindexState;
5458
5507
  this.addEventListener?.("keydown", (e) => this._handleArrowKeyDown(e));
5459
5508
  }
5509
+ /**
5510
+ * @internal
5511
+ */
5512
+ focus(options) {
5513
+ if (!this.hasAttribute("tabindex")) this.addController(new SbbTemporaryFocusController(this));
5514
+ super.focus(options);
5515
+ }
5460
5516
  connectedCallback() {
5461
5517
  super.connectedCallback();
5462
5518
  this._connectToRegistry();
5463
5519
  this._synchronizeGroupState();
5520
+ this.updateFocusableRadios();
5464
5521
  }
5465
5522
  disconnectedCallback() {
5466
5523
  super.disconnectedCallback();
@@ -5485,18 +5542,14 @@ const SbbFormAssociatedRadioButtonMixin = (superClass) => {
5485
5542
  this.checked = data === this.value;
5486
5543
  });
5487
5544
  }
5545
+ requestUpdate(name, oldValue, options) {
5546
+ super.requestUpdate(name, oldValue, options);
5547
+ if (name === "disabled" || name === "formDisabled" || name === "checked" || name === "name") this.updateFocusableRadios();
5548
+ }
5488
5549
  async _readFormData(formData) {
5489
5550
  const data = formData.get(this.name);
5490
5551
  return data instanceof Blob ? JSON.parse(await data.text()) : data;
5491
5552
  }
5492
- willUpdate(changedProperties) {
5493
- super.willUpdate(changedProperties);
5494
- if (changedProperties.has("disabled")) this.updateFocusableRadios();
5495
- }
5496
- firstUpdated(changedProperties) {
5497
- super.firstUpdated(changedProperties);
5498
- this.updateFocusableRadios();
5499
- }
5500
5553
  /**
5501
5554
  * Called on `value` change
5502
5555
  * If 'checked', update the value. Otherwise, do nothing.
@@ -5530,7 +5583,6 @@ const SbbFormAssociatedRadioButtonMixin = (superClass) => {
5530
5583
  * - the first non-disabled radio in DOM order;
5531
5584
  */
5532
5585
  updateFocusableRadios() {
5533
- if (!this.hasUpdated) return;
5534
5586
  const radios = this._interactableGroupedRadios();
5535
5587
  const checkedIndex = radios.findIndex((r) => r.checked && !r.disabled && !r.formDisabled);
5536
5588
  const focusableIndex = checkedIndex !== -1 ? checkedIndex : radios.findIndex((r) => !r.disabled && !r.formDisabled);
@@ -5543,7 +5595,6 @@ const SbbFormAssociatedRadioButtonMixin = (superClass) => {
5543
5595
  async navigateByKeyboard(next) {
5544
5596
  next.checked = true;
5545
5597
  this.emitChangeEvents();
5546
- await next.updateComplete;
5547
5598
  next.focus();
5548
5599
  }
5549
5600
  emitChangeEvents() {
@@ -5556,7 +5607,6 @@ const SbbFormAssociatedRadioButtonMixin = (superClass) => {
5556
5607
  }
5557
5608
  _synchronizeGroupState() {
5558
5609
  if (this.checked) this._deselectGroupedRadios();
5559
- this.updateFocusableRadios();
5560
5610
  }
5561
5611
  /**
5562
5612
  * Add `this` to the radioButton registry
@@ -5580,12 +5630,14 @@ const SbbFormAssociatedRadioButtonMixin = (superClass) => {
5580
5630
  if (index !== -1) entries.splice(index, 0, this);
5581
5631
  else entries.push(this);
5582
5632
  entries.forEach((r) => this.associatedRadioButtons.add(r));
5633
+ this._tabindexState.add(this);
5583
5634
  this.validate();
5584
5635
  }
5585
5636
  /**
5586
5637
  * Remove `this` from the radioButton registry and, if the group is empty, delete the entry from the groups Map
5587
5638
  */
5588
5639
  _disconnectFromRegistry(previousName) {
5640
+ this._tabindexState.delete(this);
5589
5641
  this.associatedRadioButtons?.delete(this);
5590
5642
  if (this.associatedRadioButtons?.size === 0) this._radioButtonGroupsMap?.delete(previousName);
5591
5643
  else this.validate();
@@ -6341,4 +6393,4 @@ function removeAriaComboBoxAttributes(trigger) {
6341
6393
  trigger.removeAttribute("aria-expanded");
6342
6394
  }
6343
6395
 
6344
- export { DateAdapter, FORMAT_DATE, FRIDAY, ISO8601_FORMAT_DATE, IS_FOCUSABLE_QUERY, InteractivityChecker, IsFocusableConfig, MONDAY, NativeDateAdapter, SATURDAY, SEPARATORLESS_FORMAT_DATE, SUNDAY, SbbActionBaseElement, SbbAnimationCompleteMixin, SbbButtonBaseElement, SbbButtonLikeBaseElement, SbbDarkModeController, SbbDisabledInteractiveMixin, SbbDisabledMixin, SbbDisabledTabIndexActionMixin, SbbElement, SbbEscapableOverlayController, SbbFocusTrapController, SbbFocusVisibleWithinController, SbbFormAssociatedCheckboxMixin, SbbFormAssociatedInputMixin, SbbFormAssociatedMixin, SbbFormAssociatedRadioButtonMixin, SbbIdReferenceController, SbbInertController, SbbLanguageController, SbbLinkBaseElement, SbbLiveAnnouncer, SbbMediaMatcherController, SbbMediaQueryBreakpointLargeAndAbove, SbbMediaQueryBreakpointLargeAndBelow, SbbMediaQueryBreakpointSmallAndAbove, SbbMediaQueryBreakpointSmallAndBelow, SbbMediaQueryBreakpointUltraAndAbove, SbbMediaQueryBreakpointZeroAndAbove, SbbMediaQueryDarkMode, SbbMediaQueryForcedColors, SbbMediaQueryHover, SbbMediaQueryPointerCoarse, SbbNamedSlotListMixin, SbbNegativeMixin, SbbOpenCloseBaseElement, SbbOverlayOutsidePointerEventListener, SbbOverlayPositionController, SbbPanelMixin, SbbPropertyWatcherController, SbbReadonlyMixin, SbbRequiredMixin, SbbScrollController, SbbScrollHandler, SbbSelectionGroupBaseElement, SbbSelectionPanelMixin, SbbSlottedChangeEvent, SbbUpdateSchedulerMixin, THURSDAY, TUESDAY, TemporalDateAdapter, WEDNESDAY, appendAriaElements, buttonResetStyles, containsPierceShadowDom, defaultDateAdapter, forceType, forwardEvent, getElementPosition, getElementPositionHorizontal, getElementRectangle, getEventTarget, getNextElementIndex, getOverride, handleDistinctChange, hostScrollbarStyles, i18nAdditionalWagonInformationHeading, i18nAnd, i18nArrival, i18nAutocompleteActionsHint, i18nBlockedPassage, i18nBreadcrumbEllipsisButtonLabel, i18nButton, i18nCalendarDateSelection, i18nCalendarWeekNumber, i18nCarouselArrowsNavigationHint, i18nCarouselItemAriaLabel, i18nCheckboxRequired, i18nChipDelete, i18nChipGroupInputDescription, i18nClass, i18nClearInput, i18nCloseAlert, i18nCloseDialog, i18nCloseNavigation, i18nCloseNotification, i18nClosePopover, i18nCloseSidebar, i18nClosedCompartmentLabel, i18nCollapsed, i18nConnectionFrom, i18nConnectionRoundtrip, i18nConnectionTo, i18nCouchetteWagonLabel, i18nDateChangedTo, i18nDateInvalid, i18nDateMax, i18nDateMin, i18nDatePickerPlaceholder, i18nDeparture, i18nDialog, i18nDirection, i18nDownload, i18nDurationDay, i18nDurationHour, i18nDurationMinute, i18nExpanded, i18nFileSelectorButtonLabel, i18nFileSelectorButtonLabelMultiple, i18nFileSelectorCurrentlySelected, i18nFileSelectorDeleteFile, i18nFileSelectorSubtitleLabel, i18nFileSelectorSubtitleLabelMultiple, i18nFlipCard, i18nFromPlatform, i18nGoBack, i18nInputRequired, i18nItemsPerPage, i18nLocomotiveLabel, i18nLogo125Anniversary, i18nLogo125AnniversaryYears, i18nMapContainerButtonLabel, i18nMeansOfTransport, i18nMultipleSelectionPossible, i18nNew, i18nNextDay, i18nNextMonth, i18nNextPage, i18nNextSlide, i18nNextYear, i18nNextYearRange, i18nNonAccessible, i18nOccupancy, i18nPage, i18nPaginatorOf, i18nPaginatorSelected, i18nPreviousDay, i18nPreviousMonth, i18nPreviousPage, i18nPreviousSlide, i18nPreviousYear, i18nPreviousYearRange, i18nRealTimeInfo, i18nRemainingCharacters, i18nRestaurantWagonLabel, i18nReverseCard, i18nSector, i18nSectorShort, i18nSelectNextDay, i18nSelectPreviousDay, i18nSelectionRequired, i18nShowCalendar, i18nSleepingWagonLabel, i18nSlide, i18nSupersaver, i18nTargetOpensInNewWindow, i18nTimeInputChange, i18nTimeInvalid, i18nTimeMax, i18nTimeMaxLength, i18nTimetableFormSwapButtonLabel, i18nToday, i18nTrain, i18nTrains, i18nTransferProcedure, i18nTransferProcedures, i18nTravelhints, i18nTripDuration, i18nTripQuayChange, i18nWagonLabel, i18nWagonLabelNumber, i18nWagonsLabel, i18nWalkingDistanceArrival, i18nWalkingDistanceDeparture, i18nYearMonthSelection, idReference, interactivityChecker, isAndroid, isArrowKeyOrPageKeysPressed, isArrowKeyPressed, isBlink, isChromium, isEdge, isEventOnElement, isEventPrevented, isFakeMousedownFromScreenReader, isFakeTouchstartFromScreenReader, isFirefox, isIOS, isMacOS, isNextArrowKeyPressed, isNextjs, isPreviousArrowKeyPressed, isSafari, isTrident, isWebkit, isZeroAnimationDuration, listResetStyles, mergeConfig, omitEmptyConverter, pageScrollDisabled, plainDate, plainDateConverter, popoverResetStyles, preventScrollOnSpacebarPress, queueDomContentLoaded, radioButtonRegistry, readConfig, removeAriaComboBoxAttributes, removeAriaElements, removeAriaOverlayTriggerProperties, sbbInputModalityDetector, sbbLiveAnnouncer, sbbOverlayOutsidePointerEventListener, screenReaderOnlyStyles, scrollbarStyles, setAriaComboBoxAttributes, setAriaOverlayTriggerProperties, setOrRemoveAttribute, setOverlayPosition, ɵstateController };
6396
+ export { DateAdapter, FORMAT_DATE, FRIDAY, ISO8601_FORMAT_DATE, IS_FOCUSABLE_QUERY, InteractivityChecker, IsFocusableConfig, MONDAY, NativeDateAdapter, SATURDAY, SEPARATORLESS_FORMAT_DATE, SUNDAY, SbbActionBaseElement, SbbAnimationCompleteMixin, SbbButtonBaseElement, SbbButtonLikeBaseElement, SbbDarkModeController, SbbDisabledInteractiveMixin, SbbDisabledMixin, SbbDisabledTabIndexActionMixin, SbbElement, SbbEscapableOverlayController, SbbFocusTrapController, SbbFocusVisibleWithinController, SbbFormAssociatedCheckboxMixin, SbbFormAssociatedInputMixin, SbbFormAssociatedMixin, SbbFormAssociatedRadioButtonMixin, SbbIdReferenceController, SbbInertController, SbbLanguageController, SbbLinkBaseElement, SbbLiveAnnouncer, SbbMediaMatcherController, SbbMediaQueryBreakpointLargeAndAbove, SbbMediaQueryBreakpointLargeAndBelow, SbbMediaQueryBreakpointSmallAndAbove, SbbMediaQueryBreakpointSmallAndBelow, SbbMediaQueryBreakpointUltraAndAbove, SbbMediaQueryBreakpointZeroAndAbove, SbbMediaQueryDarkMode, SbbMediaQueryForcedColors, SbbMediaQueryHover, SbbMediaQueryPointerCoarse, SbbNamedSlotListMixin, SbbNegativeMixin, SbbOpenCloseBaseElement, SbbOverlayOutsidePointerEventListener, SbbOverlayPositionController, SbbPanelMixin, SbbPropertyWatcherController, SbbReadonlyMixin, SbbRequiredMixin, SbbScrollController, SbbScrollHandler, SbbSelectionGroupBaseElement, SbbSelectionPanelMixin, SbbSlottedChangeEvent, SbbTemporaryFocusController, SbbUpdateSchedulerMixin, THURSDAY, TUESDAY, TemporalDateAdapter, WEDNESDAY, appendAriaElements, buttonResetStyles, containsPierceShadowDom, defaultDateAdapter, forceType, forwardEvent, getElementPosition, getElementPositionHorizontal, getElementRectangle, getEventTarget, getNextElementIndex, getOverride, handleDistinctChange, hostScrollbarStyles, i18nAdditionalWagonInformationHeading, i18nAnd, i18nArrival, i18nAutocompleteActionsHint, i18nBlockedPassage, i18nBreadcrumbEllipsisButtonLabel, i18nButton, i18nCalendarDateSelection, i18nCalendarWeekNumber, i18nCarouselArrowsNavigationHint, i18nCarouselItemAriaLabel, i18nCheckboxRequired, i18nChipDelete, i18nChipGroupInputDescription, i18nClass, i18nClearInput, i18nCloseAlert, i18nCloseDialog, i18nCloseNavigation, i18nCloseNotification, i18nClosePopover, i18nCloseSidebar, i18nClosedCompartmentLabel, i18nCollapsed, i18nConnectionFrom, i18nConnectionRoundtrip, i18nConnectionTo, i18nCouchetteWagonLabel, i18nDateChangedTo, i18nDateInvalid, i18nDateMax, i18nDateMin, i18nDatePickerPlaceholder, i18nDeparture, i18nDialog, i18nDirection, i18nDownload, i18nDurationDay, i18nDurationHour, i18nDurationMinute, i18nExpanded, i18nFileSelectorButtonLabel, i18nFileSelectorButtonLabelMultiple, i18nFileSelectorCurrentlySelected, i18nFileSelectorDeleteFile, i18nFileSelectorSubtitleLabel, i18nFileSelectorSubtitleLabelMultiple, i18nFlipCard, i18nFromPlatform, i18nGoBack, i18nInputRequired, i18nItemsPerPage, i18nLocomotiveLabel, i18nLogo125Anniversary, i18nLogo125AnniversaryYears, i18nMapContainerButtonLabel, i18nMeansOfTransport, i18nMultipleSelectionPossible, i18nNew, i18nNextDay, i18nNextMonth, i18nNextPage, i18nNextSlide, i18nNextYear, i18nNextYearRange, i18nNonAccessible, i18nOccupancy, i18nPage, i18nPaginatorOf, i18nPaginatorSelected, i18nPreviousDay, i18nPreviousMonth, i18nPreviousPage, i18nPreviousSlide, i18nPreviousYear, i18nPreviousYearRange, i18nRealTimeInfo, i18nRemainingCharacters, i18nRestaurantWagonLabel, i18nReverseCard, i18nSector, i18nSectorShort, i18nSelectNextDay, i18nSelectPreviousDay, i18nSelectionRequired, i18nShowCalendar, i18nSleepingWagonLabel, i18nSlide, i18nSupersaver, i18nTargetOpensInNewWindow, i18nTimeInputChange, i18nTimeInvalid, i18nTimeMax, i18nTimeMaxLength, i18nTimetableFormSwapButtonLabel, i18nToday, i18nTrain, i18nTrains, i18nTransferProcedure, i18nTransferProcedures, i18nTravelhints, i18nTripDuration, i18nTripQuayChange, i18nWagonLabel, i18nWagonLabelNumber, i18nWagonsLabel, i18nWalkingDistanceArrival, i18nWalkingDistanceDeparture, i18nYearMonthSelection, idReference, interactivityChecker, isAndroid, isArrowKeyOrPageKeysPressed, isArrowKeyPressed, isBlink, isChromium, isEdge, isEventOnElement, isEventPrevented, isFakeMousedownFromScreenReader, isFakeTouchstartFromScreenReader, isFirefox, isIOS, isMacOS, isNextArrowKeyPressed, isNextjs, isPreviousArrowKeyPressed, isSafari, isTrident, isWebkit, isZeroAnimationDuration, listResetStyles, mergeConfig, omitEmptyConverter, pageScrollDisabled, plainDate, plainDateConverter, popoverResetStyles, preventScrollOnSpacebarPress, queueDomContentLoaded, radioButtonRegistry, readConfig, removeAriaComboBoxAttributes, removeAriaElements, removeAriaOverlayTriggerProperties, sbbInputModalityDetector, sbbLiveAnnouncer, sbbOverlayOutsidePointerEventListener, screenReaderOnlyStyles, scrollbarStyles, setAriaComboBoxAttributes, setAriaOverlayTriggerProperties, setOrRemoveAttribute, setOverlayPosition, ɵstateController };
@@ -31,7 +31,7 @@ export declare class SbbRadioButtonGroupElement<T = string> extends SbbSelection
31
31
  set value(val: T | null);
32
32
  get value(): T | null;
33
33
  /**
34
- * Used to preserve the `value` in case the radios are not yet 'loaded'
34
+ * Used to preserve the `value` in case the radios are not yet 'loaded'.
35
35
  */
36
36
  private _fallbackValue;
37
37
  /** Name for the group. Will be propagated to the child radio buttons. Must be unique if multiple groups are used on the same page. */
@@ -3,6 +3,7 @@ import { property } from "lit/decorators.js";
3
3
  import { SbbSelectionGroupBaseElement, forceType } from "./core.js";
4
4
 
5
5
  // src/elements/radio-button-group/radio-button-group.component.ts
6
+ const emptyValue = Symbol("emptyValue");
6
7
  let nextId = 0;
7
8
  /**
8
9
  * It can be used as a container for radio button elements.
@@ -133,11 +134,11 @@ let SbbRadioButtonGroupElement = (() => {
133
134
  set value(val) {
134
135
  this._fallbackValue = val;
135
136
  if (!this.hasUpdated) return;
136
- const toCheck = val == null ? null : this.selectionElements.find((r) => this.compareWith(r.value, val));
137
+ const toCheck = this.selectionElements.find((r) => this.compareWith(r.value, val));
137
138
  this.selectionElements.forEach((r) => r.checked = r === toCheck);
138
139
  }
139
140
  get value() {
140
- return this.selectionElements.find((r) => r.checked && !r.disabled)?.value ?? this._fallbackValue;
141
+ return this.selectionElements.find((r) => r.checked && !r.disabled)?.value ?? (this._fallbackValue === emptyValue ? null : this._fallbackValue);
141
142
  }
142
143
  #name_accessor_storage;
143
144
  /** Name for the group. Will be propagated to the child radio buttons. Must be unique if multiple groups are used on the same page. */
@@ -158,9 +159,9 @@ let SbbRadioButtonGroupElement = (() => {
158
159
  this.#allowEmptySelection_accessor_storage = __runInitializers(this, _allowEmptySelection_initializers, false);
159
160
  this.#compareWith_accessor_storage = (__runInitializers(this, _allowEmptySelection_extraInitializers), __runInitializers(this, _compareWith_initializers, (v1, v2) => v1 === v2));
160
161
  /**
161
- * Used to preserve the `value` in case the radios are not yet 'loaded'
162
+ * Used to preserve the `value` in case the radios are not yet 'loaded'.
162
163
  */
163
- this._fallbackValue = (__runInitializers(this, _compareWith_extraInitializers), null);
164
+ this._fallbackValue = (__runInitializers(this, _compareWith_extraInitializers), emptyValue);
164
165
  this.#name_accessor_storage = __runInitializers(this, _name_initializers, `sbb-radio-button-group-${++nextId}`);
165
166
  __runInitializers(this, _name_extraInitializers);
166
167
  this.addEventListener?.("change", (e) => this._onRadioChange(e));
@@ -177,7 +178,7 @@ let SbbRadioButtonGroupElement = (() => {
177
178
  _onRadioChange(event) {
178
179
  const target = event.target;
179
180
  if (target.localName !== "sbb-radio-button" && target.localName !== "sbb-radio-button-panel" || target.group !== this) return;
180
- this._fallbackValue = null;
181
+ this._fallbackValue = emptyValue;
181
182
  /**
182
183
  * Deprecated. Mirrors change event for React. Will be removed once React properly supports change events.
183
184
  * @deprecated
@@ -195,7 +196,7 @@ let SbbRadioButtonGroupElement = (() => {
195
196
  * Mainly used to cover cases where the setter is called before the radios are loaded
196
197
  */
197
198
  _updateRadioState() {
198
- if (this._fallbackValue != null) this.value = this.value;
199
+ if (this._fallbackValue !== emptyValue) this.value = this.value;
199
200
  }
200
201
  onSlotChange() {
201
202
  super.onSlotChange();
@@ -105,14 +105,9 @@ const SbbRadioButtonCommonElementMixin = (superClass) => {
105
105
  isRequiredExternally() {
106
106
  return this.group?.required ?? false;
107
107
  }
108
- async _handleClick(event) {
108
+ _handleClick(event) {
109
109
  event.preventDefault();
110
110
  this.select();
111
- /**
112
- * Since only a single radio of a group is focusable at any time, it is possible that the one clicked does not have 'tabindex=0'.
113
- * To cover that, we await the next render (which will make the 'checked' radio focusable) and focus the clicked radio
114
- */
115
- await this.updateComplete;
116
111
  this.focus();
117
112
  }
118
113
  _handleKeyDown(evt) {
@@ -207,7 +202,7 @@ let SbbRadioButtonPanelElement = (() => {
207
202
  */
208
203
  updateFocusableRadios() {
209
204
  super.updateFocusableRadios();
210
- Array.from(this.associatedRadioButtons ?? []).filter((r) => !r.disabled && r._hasSelectionPanelElement).forEach((r) => r.tabIndex = 0);
205
+ Array.from(this.associatedRadioButtons ?? []).filter((r) => !r.disabled && !r.formDisabled && r._hasSelectionPanelElement).forEach((r) => r.tabIndex = 0);
211
206
  }
212
207
  /**
213
208
  * As an exception, radio-panels with a selection-panel attached are not checked automatically when navigating by keyboard
@@ -105,14 +105,9 @@ const SbbRadioButtonCommonElementMixin = (superClass) => {
105
105
  isRequiredExternally() {
106
106
  return this.group?.required ?? false;
107
107
  }
108
- async _handleClick(event) {
108
+ _handleClick(event) {
109
109
  event.preventDefault();
110
110
  this.select();
111
- /**
112
- * Since only a single radio of a group is focusable at any time, it is possible that the one clicked does not have 'tabindex=0'.
113
- * To cover that, we await the next render (which will make the 'checked' radio focusable) and focus the clicked radio
114
- */
115
- await this.updateComplete;
116
111
  this.focus();
117
112
  }
118
113
  _handleKeyDown(evt) {
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@sbb-esta/lyne-elements-dev",
3
- "version": "5.13.2-dev.1794463730",
3
+ "version": "5.13.2-dev.1794477486",
4
4
  "description": "Lyne Design System",
5
5
  "keywords": [
6
6
  "design system",
7
7
  "web components",
8
8
  "lit",
9
- "https://github.com/sbb-design-systems/lyne-components/commit/a515546e8c5f6c688fb353c48e751b7799b527a4"
9
+ "https://github.com/sbb-design-systems/lyne-components/commit/bf70096338ffadd2430117f19143a94a7bdeec6b"
10
10
  ],
11
11
  "type": "module",
12
12
  "exports": {
@@ -1 +1 @@
1
- import{__esDecorate as e,__runInitializers as t}from"tslib";import{property as n}from"lit/decorators.js";import{SbbSelectionGroupBaseElement as r,forceType as i}from"./core.js";let a=0,o=(()=>{let o=r,s=[],c,l=[],u=[],d,f=[],p=[],m,h,g=[],_=[];return class extends o{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(o[Symbol.metadata]??null):void 0;c=[i(),n({attribute:`allow-empty-selection`,type:Boolean})],d=[n({attribute:!1})],m=[n()],h=[i(),n()],e(this,null,c,{kind:`accessor`,name:`allowEmptySelection`,static:!1,private:!1,access:{has:e=>`allowEmptySelection`in e,get:e=>e.allowEmptySelection,set:(e,t)=>{e.allowEmptySelection=t}},metadata:t},l,u),e(this,null,d,{kind:`accessor`,name:`compareWith`,static:!1,private:!1,access:{has:e=>`compareWith`in e,get:e=>e.compareWith,set:(e,t)=>{e.compareWith=t}},metadata:t},f,p),e(this,null,m,{kind:`setter`,name:`value`,static:!1,private:!1,access:{has:e=>`value`in e,set:(e,t)=>{e.value=t}},metadata:t},null,s),e(this,null,h,{kind:`accessor`,name:`name`,static:!1,private:!1,access:{has:e=>`name`in e,get:e=>e.name,set:(e,t)=>{e.name=t}},metadata:t},g,_),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.elementName=`sbb-radio-button-group`}static{this.role=`radiogroup`}static{this.events={didChange:`didChange`,change:`change`,input:`input`}}#e;get allowEmptySelection(){return this.#e}set allowEmptySelection(e){this.#e=e}#t;get compareWith(){return this.#t}set compareWith(e){this.#t=e}set value(e){if(this._fallbackValue=e,!this.hasUpdated)return;let t=e==null?null:this.selectionElements.find(t=>this.compareWith(t.value,e));this.selectionElements.forEach(e=>e.checked=e===t)}get value(){return this.selectionElements.find(e=>e.checked&&!e.disabled)?.value??this._fallbackValue}#n;get name(){return this.#n}set name(e){this.#n=e}get radioButtons(){return this.selectionElements}constructor(){super(),this.selectionElementSelectors=(t(this,s),`sbb-radio-button, sbb-radio-button-panel`),this.panelElementSelector=`sbb-radio-button-panel`,this.#e=t(this,l,!1),this.#t=(t(this,u),t(this,f,(e,t)=>e===t)),this._fallbackValue=(t(this,p),null),this.#n=t(this,g,`sbb-radio-button-group-${++a}`),t(this,_),this.addEventListener?.(`change`,e=>this._onRadioChange(e)),this.addEventListener?.(`ɵradiobuttonvaluechange`,()=>this._updateRadioState())}willUpdate(e){super.willUpdate(e),e.has(`name`)&&this._updateRadiosName()}firstUpdated(e){super.firstUpdated(e),this.updateComplete.then(()=>this._updateRadioState())}_onRadioChange(e){let t=e.target;t.localName!==`sbb-radio-button`&&t.localName!==`sbb-radio-button-panel`||t.group!==this||(this._fallbackValue=null,this.dispatchEvent(new Event(`didChange`,{bubbles:!0})))}_updateRadiosName(){this.selectionElements.forEach(e=>e.name=this.name)}_updateRadioState(){this._fallbackValue!=null&&(this.value=this.value)}onSlotChange(){super.onSlotChange(),this._updateRadiosName(),this._updateRadioState()}}})();export{o as SbbRadioButtonGroupElement};
1
+ import{__esDecorate as e,__runInitializers as t}from"tslib";import{property as n}from"lit/decorators.js";import{SbbSelectionGroupBaseElement as r,forceType as i}from"./core.js";const a=Symbol(`emptyValue`);let o=0,s=(()=>{let s=r,c=[],l,u=[],d=[],f,p=[],m=[],h,g,_=[],v=[];return class extends s{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(s[Symbol.metadata]??null):void 0;l=[i(),n({attribute:`allow-empty-selection`,type:Boolean})],f=[n({attribute:!1})],h=[n()],g=[i(),n()],e(this,null,l,{kind:`accessor`,name:`allowEmptySelection`,static:!1,private:!1,access:{has:e=>`allowEmptySelection`in e,get:e=>e.allowEmptySelection,set:(e,t)=>{e.allowEmptySelection=t}},metadata:t},u,d),e(this,null,f,{kind:`accessor`,name:`compareWith`,static:!1,private:!1,access:{has:e=>`compareWith`in e,get:e=>e.compareWith,set:(e,t)=>{e.compareWith=t}},metadata:t},p,m),e(this,null,h,{kind:`setter`,name:`value`,static:!1,private:!1,access:{has:e=>`value`in e,set:(e,t)=>{e.value=t}},metadata:t},null,c),e(this,null,g,{kind:`accessor`,name:`name`,static:!1,private:!1,access:{has:e=>`name`in e,get:e=>e.name,set:(e,t)=>{e.name=t}},metadata:t},_,v),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.elementName=`sbb-radio-button-group`}static{this.role=`radiogroup`}static{this.events={didChange:`didChange`,change:`change`,input:`input`}}#e;get allowEmptySelection(){return this.#e}set allowEmptySelection(e){this.#e=e}#t;get compareWith(){return this.#t}set compareWith(e){this.#t=e}set value(e){if(this._fallbackValue=e,!this.hasUpdated)return;let t=this.selectionElements.find(t=>this.compareWith(t.value,e));this.selectionElements.forEach(e=>e.checked=e===t)}get value(){return this.selectionElements.find(e=>e.checked&&!e.disabled)?.value??(this._fallbackValue===a?null:this._fallbackValue)}#n;get name(){return this.#n}set name(e){this.#n=e}get radioButtons(){return this.selectionElements}constructor(){super(),this.selectionElementSelectors=(t(this,c),`sbb-radio-button, sbb-radio-button-panel`),this.panelElementSelector=`sbb-radio-button-panel`,this.#e=t(this,u,!1),this.#t=(t(this,d),t(this,p,(e,t)=>e===t)),this._fallbackValue=(t(this,m),a),this.#n=t(this,_,`sbb-radio-button-group-${++o}`),t(this,v),this.addEventListener?.(`change`,e=>this._onRadioChange(e)),this.addEventListener?.(`ɵradiobuttonvaluechange`,()=>this._updateRadioState())}willUpdate(e){super.willUpdate(e),e.has(`name`)&&this._updateRadiosName()}firstUpdated(e){super.firstUpdated(e),this.updateComplete.then(()=>this._updateRadioState())}_onRadioChange(e){let t=e.target;t.localName!==`sbb-radio-button`&&t.localName!==`sbb-radio-button-panel`||t.group!==this||(this._fallbackValue=a,this.dispatchEvent(new Event(`didChange`,{bubbles:!0})))}_updateRadiosName(){this.selectionElements.forEach(e=>e.name=this.name)}_updateRadioState(){this._fallbackValue!==a&&(this.value=this.value)}onSlotChange(){super.onSlotChange(),this._updateRadiosName(),this._updateRadioState()}}})();export{s as SbbRadioButtonGroupElement};
@@ -1,5 +1,5 @@
1
1
  import{__esDecorate as e,__runInitializers as t}from"tslib";import{html as n,nothing as r,unsafeCSS as i}from"lit";import{property as a}from"lit/decorators.js";import{SbbElement as o,SbbFormAssociatedRadioButtonMixin as s,SbbPanelMixin as c,SbbPropertyWatcherController as l,SbbUpdateSchedulerMixin as u,screenReaderOnlyStyles as d}from"./core.js";var f=`:host{--sbb-radio-button-background-fake-border-width:calc(var(--sbb-radio-button-dimension) / 2);--sbb-radio-button-icon-align:calc((1em * var(--sbb-typo-line-height-text) - var(--sbb-radio-button-dimension)) / 2)}:host(:is(:state(checked),[state--checked])){--sbb-radio-button-inner-circle-color:var(--sbb-radio-button-inner-circle-color-checked);--sbb-radio-button-border-color:var(--sbb-radio-button-border-color-checked);--sbb-radio-button-background-fake-border-width:calc((var(--sbb-radio-button-dimension) - var(--sbb-radio-button-inner-circle-dimension)) / 2)}:host(:disabled){--sbb-radio-button-label-color:var(--sbb-radio-button-label-color-disabled);--sbb-radio-button-background-color:var(--sbb-radio-button-background-color-disabled);--sbb-radio-button-border-style:var(--sbb-radio-button-border-style-disabled);--sbb-radio-button-border-color:var(--sbb-radio-button-border-color-disabled);--sbb-radio-button-inner-circle-color:var(--sbb-radio-button-inner-circle-color-disabled);--sbb-radio-button-cursor:var(--sbb-cursor-default)}:host(:disabled:is(:state(checked),[state--checked])){--sbb-radio-button-inner-circle-color:var(--sbb-radio-button-inner-circle-color-checked-disabled)}:host([size=xs]){--sbb-radio-button-font-size:var(--sbb-radio-button-font-size-xs);--sbb-radio-button-dimension:var(--sbb-radio-button-dimension-xs)}:host([size=s]){--sbb-radio-button-font-size:var(--sbb-radio-button-font-size-s);--sbb-radio-button-dimension:var(--sbb-radio-button-dimension-s)}:host([size=m]){--sbb-radio-button-font-size:var(--sbb-radio-button-font-size-m);--sbb-radio-button-dimension:var(--sbb-radio-button-dimension-m)}.sbb-radio-button{font-size:var(--sbb-radio-button-font-size);letter-spacing:var(--sbb-letter-spacing-text);line-height:var(--sbb-typo-line-height-text);cursor:var(--sbb-radio-button-cursor);user-select:none;color:var(--sbb-radio-button-label-color);-webkit-tap-highlight-color:transparent;display:block;position:relative}.sbb-radio-button__label-slot{min-height:calc(var(--sbb-radio-button-font-size) * var(--sbb-typo-line-height-text));align-items:flex-start;display:flex;overflow:hidden}.sbb-radio-button__label-slot:before,.sbb-radio-button__label-slot:after{content:"";width:var(--sbb-radio-button-dimension);height:var(--sbb-radio-button-dimension);transition-duration:var(--sbb-disable-animation-duration,var(--sbb-animation-duration-4x));border-radius:50%;flex-shrink:0;margin-block-start:var(--sbb-radio-button-icon-align);transition-property:background-color,border;transition-timing-function:ease}@media (forced-colors:active){.sbb-radio-button__label-slot:before,.sbb-radio-button__label-slot:after{transition:none}}.sbb-radio-button__label-slot:before{background:var(--sbb-radio-button-inner-circle-color);border:var(--sbb-radio-button-background-fake-border-width) solid var(--sbb-radio-button-background-color);margin-inline-end:var(--sbb-radio-button-label-gap)}.sbb-radio-button__label-slot:after{border:var(--sbb-radio-button-border-width) var(--sbb-radio-button-border-style) var(--sbb-radio-button-border-color);position:absolute}
2
- `;const p=n=>(()=>{let r=s(n),o=[],c;return class extends r{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(r[Symbol.metadata]??null):void 0;c=[a({attribute:`allow-empty-selection`,type:Boolean})],e(this,null,c,{kind:`setter`,name:`allowEmptySelection`,static:!1,private:!1,access:{has:e=>`allowEmptySelection`in e,set:(e,t)=>{e.allowEmptySelection=t}},metadata:t},null,o),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.styles=[i(f)]}static{this.events={change:`change`,input:`input`}}set allowEmptySelection(e){this._allowEmptySelection=!!e}get allowEmptySelection(){return this._allowEmptySelection||(this.group?.allowEmptySelection??!1)}get group(){return this._group}constructor(){super(),this._allowEmptySelection=(t(this,o),!1),this._group=null,this.addEventListener?.(`click`,e=>this._handleClick(e)),this.addEventListener?.(`keydown`,e=>this._handleKeyDown(e)),this.addController(new l(this,()=>this.closest(`sbb-radio-button-group`),[`disabled`,`required`,`size`].reduce((e,t)=>Object.assign(e,{[t]:()=>this.requestUpdate(t)}),{})))}connectedCallback(){super.connectedCallback(),this._group=this.closest(`sbb-radio-button-group`)}select(){this.disabled||this.formDisabled||(this.allowEmptySelection?(this.checked=!this.checked,this.emitChangeEvents()):this.checked||(this.checked=!0,this.emitChangeEvents()))}willUpdate(e){super.willUpdate(e),e.has(`value`)&&this.dispatchEvent(new Event(`ɵradiobuttonvaluechange`,{bubbles:!0}))}isDisabledExternally(){return this.group?.disabled??!1}isRequiredExternally(){return this.group?.required??!1}async _handleClick(e){e.preventDefault(),this.select(),await this.updateComplete,this.focus()}_handleKeyDown(e){e.code===`Space`&&(e.preventDefault(),this.select())}}})();let m=(()=>{let i=c(p(u(o))),s,l=[],f=[];return class extends i{constructor(){super(...arguments),this.#e=t(this,l,null),this._hasSelectionPanelElement=(t(this,f),!1)}static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(i[Symbol.metadata]??null):void 0;s=[a()],e(this,null,s,{kind:`accessor`,name:`value`,static:!1,private:!1,access:{has:e=>`value`in e,get:e=>e.value,set:(e,t)=>{e.value=t}},metadata:t},l,f),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.elementName=`sbb-radio-button-panel`}static{this.styles=[d]}static{this.events={change:`change`,input:`input`}}#e;get value(){return this.#e}set value(e){this.#e=e}connectedCallback(){super.connectedCallback(),this._hasSelectionPanelElement=!!this.closest?.(`sbb-selection-expansion-panel, sbb-selection-action-panel`)}willUpdate(e){super.willUpdate(e),e.has(`checked`)&&this.toggleState(`checked`,this.checked)}updateFocusableRadios(){super.updateFocusableRadios(),Array.from(this.associatedRadioButtons??[]).filter(e=>!e.disabled&&e._hasSelectionPanelElement).forEach(e=>e.tabIndex=0)}async navigateByKeyboard(e){this._hasSelectionPanelElement?e.focus():await super.navigateByKeyboard(e)}render(){return n`
2
+ `;const p=n=>(()=>{let r=s(n),o=[],c;return class extends r{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(r[Symbol.metadata]??null):void 0;c=[a({attribute:`allow-empty-selection`,type:Boolean})],e(this,null,c,{kind:`setter`,name:`allowEmptySelection`,static:!1,private:!1,access:{has:e=>`allowEmptySelection`in e,set:(e,t)=>{e.allowEmptySelection=t}},metadata:t},null,o),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.styles=[i(f)]}static{this.events={change:`change`,input:`input`}}set allowEmptySelection(e){this._allowEmptySelection=!!e}get allowEmptySelection(){return this._allowEmptySelection||(this.group?.allowEmptySelection??!1)}get group(){return this._group}constructor(){super(),this._allowEmptySelection=(t(this,o),!1),this._group=null,this.addEventListener?.(`click`,e=>this._handleClick(e)),this.addEventListener?.(`keydown`,e=>this._handleKeyDown(e)),this.addController(new l(this,()=>this.closest(`sbb-radio-button-group`),[`disabled`,`required`,`size`].reduce((e,t)=>Object.assign(e,{[t]:()=>this.requestUpdate(t)}),{})))}connectedCallback(){super.connectedCallback(),this._group=this.closest(`sbb-radio-button-group`)}select(){this.disabled||this.formDisabled||(this.allowEmptySelection?(this.checked=!this.checked,this.emitChangeEvents()):this.checked||(this.checked=!0,this.emitChangeEvents()))}willUpdate(e){super.willUpdate(e),e.has(`value`)&&this.dispatchEvent(new Event(`ɵradiobuttonvaluechange`,{bubbles:!0}))}isDisabledExternally(){return this.group?.disabled??!1}isRequiredExternally(){return this.group?.required??!1}_handleClick(e){e.preventDefault(),this.select(),this.focus()}_handleKeyDown(e){e.code===`Space`&&(e.preventDefault(),this.select())}}})();let m=(()=>{let i=c(p(u(o))),s,l=[],f=[];return class extends i{constructor(){super(...arguments),this.#e=t(this,l,null),this._hasSelectionPanelElement=(t(this,f),!1)}static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(i[Symbol.metadata]??null):void 0;s=[a()],e(this,null,s,{kind:`accessor`,name:`value`,static:!1,private:!1,access:{has:e=>`value`in e,get:e=>e.value,set:(e,t)=>{e.value=t}},metadata:t},l,f),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.elementName=`sbb-radio-button-panel`}static{this.styles=[d]}static{this.events={change:`change`,input:`input`}}#e;get value(){return this.#e}set value(e){this.#e=e}connectedCallback(){super.connectedCallback(),this._hasSelectionPanelElement=!!this.closest?.(`sbb-selection-expansion-panel, sbb-selection-action-panel`)}willUpdate(e){super.willUpdate(e),e.has(`checked`)&&this.toggleState(`checked`,this.checked)}updateFocusableRadios(){super.updateFocusableRadios(),Array.from(this.associatedRadioButtons??[]).filter(e=>!e.disabled&&!e.formDisabled&&e._hasSelectionPanelElement).forEach(e=>e.tabIndex=0)}async navigateByKeyboard(e){this._hasSelectionPanelElement?e.focus():await super.navigateByKeyboard(e)}render(){return n`
3
3
  <div class="sbb-selection-panel">
4
4
  <div class="sbb-selection-panel__badge">
5
5
  <slot name="badge"></slot>
@@ -1,5 +1,5 @@
1
1
  import{__esDecorate as e,__runInitializers as t}from"tslib";import{html as n,unsafeCSS as r}from"lit";import{property as i}from"lit/decorators.js";import{SbbElement as a,SbbFormAssociatedRadioButtonMixin as o,SbbPropertyWatcherController as s,getOverride as c}from"./core.js";var l=`:host{--sbb-radio-button-background-fake-border-width:calc(var(--sbb-radio-button-dimension) / 2);--sbb-radio-button-icon-align:calc((1em * var(--sbb-typo-line-height-text) - var(--sbb-radio-button-dimension)) / 2)}:host(:is(:state(checked),[state--checked])){--sbb-radio-button-inner-circle-color:var(--sbb-radio-button-inner-circle-color-checked);--sbb-radio-button-border-color:var(--sbb-radio-button-border-color-checked);--sbb-radio-button-background-fake-border-width:calc((var(--sbb-radio-button-dimension) - var(--sbb-radio-button-inner-circle-dimension)) / 2)}:host(:disabled){--sbb-radio-button-label-color:var(--sbb-radio-button-label-color-disabled);--sbb-radio-button-background-color:var(--sbb-radio-button-background-color-disabled);--sbb-radio-button-border-style:var(--sbb-radio-button-border-style-disabled);--sbb-radio-button-border-color:var(--sbb-radio-button-border-color-disabled);--sbb-radio-button-inner-circle-color:var(--sbb-radio-button-inner-circle-color-disabled);--sbb-radio-button-cursor:var(--sbb-cursor-default)}:host(:disabled:is(:state(checked),[state--checked])){--sbb-radio-button-inner-circle-color:var(--sbb-radio-button-inner-circle-color-checked-disabled)}:host([size=xs]){--sbb-radio-button-font-size:var(--sbb-radio-button-font-size-xs);--sbb-radio-button-dimension:var(--sbb-radio-button-dimension-xs)}:host([size=s]){--sbb-radio-button-font-size:var(--sbb-radio-button-font-size-s);--sbb-radio-button-dimension:var(--sbb-radio-button-dimension-s)}:host([size=m]){--sbb-radio-button-font-size:var(--sbb-radio-button-font-size-m);--sbb-radio-button-dimension:var(--sbb-radio-button-dimension-m)}.sbb-radio-button{font-size:var(--sbb-radio-button-font-size);letter-spacing:var(--sbb-letter-spacing-text);line-height:var(--sbb-typo-line-height-text);cursor:var(--sbb-radio-button-cursor);user-select:none;color:var(--sbb-radio-button-label-color);-webkit-tap-highlight-color:transparent;display:block;position:relative}.sbb-radio-button__label-slot{min-height:calc(var(--sbb-radio-button-font-size) * var(--sbb-typo-line-height-text));align-items:flex-start;display:flex;overflow:hidden}.sbb-radio-button__label-slot:before,.sbb-radio-button__label-slot:after{content:"";width:var(--sbb-radio-button-dimension);height:var(--sbb-radio-button-dimension);transition-duration:var(--sbb-disable-animation-duration,var(--sbb-animation-duration-4x));border-radius:50%;flex-shrink:0;margin-block-start:var(--sbb-radio-button-icon-align);transition-property:background-color,border;transition-timing-function:ease}@media (forced-colors:active){.sbb-radio-button__label-slot:before,.sbb-radio-button__label-slot:after{transition:none}}.sbb-radio-button__label-slot:before{background:var(--sbb-radio-button-inner-circle-color);border:var(--sbb-radio-button-background-fake-border-width) solid var(--sbb-radio-button-background-color);margin-inline-end:var(--sbb-radio-button-label-gap)}.sbb-radio-button__label-slot:after{border:var(--sbb-radio-button-border-width) var(--sbb-radio-button-border-style) var(--sbb-radio-button-border-color);position:absolute}
2
- `;const u=n=>(()=>{let a=o(n),c=[],u;return class extends a{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(a[Symbol.metadata]??null):void 0;u=[i({attribute:`allow-empty-selection`,type:Boolean})],e(this,null,u,{kind:`setter`,name:`allowEmptySelection`,static:!1,private:!1,access:{has:e=>`allowEmptySelection`in e,set:(e,t)=>{e.allowEmptySelection=t}},metadata:t},null,c),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.styles=[r(l)]}static{this.events={change:`change`,input:`input`}}set allowEmptySelection(e){this._allowEmptySelection=!!e}get allowEmptySelection(){return this._allowEmptySelection||(this.group?.allowEmptySelection??!1)}get group(){return this._group}constructor(){super(),this._allowEmptySelection=(t(this,c),!1),this._group=null,this.addEventListener?.(`click`,e=>this._handleClick(e)),this.addEventListener?.(`keydown`,e=>this._handleKeyDown(e)),this.addController(new s(this,()=>this.closest(`sbb-radio-button-group`),[`disabled`,`required`,`size`].reduce((e,t)=>Object.assign(e,{[t]:()=>this.requestUpdate(t)}),{})))}connectedCallback(){super.connectedCallback(),this._group=this.closest(`sbb-radio-button-group`)}select(){this.disabled||this.formDisabled||(this.allowEmptySelection?(this.checked=!this.checked,this.emitChangeEvents()):this.checked||(this.checked=!0,this.emitChangeEvents()))}willUpdate(e){super.willUpdate(e),e.has(`value`)&&this.dispatchEvent(new Event(`ɵradiobuttonvaluechange`,{bubbles:!0}))}isDisabledExternally(){return this.group?.disabled??!1}isRequiredExternally(){return this.group?.required??!1}async _handleClick(e){e.preventDefault(),this.select(),await this.updateComplete,this.focus()}_handleKeyDown(e){e.code===`Space`&&(e.preventDefault(),this.select())}}})();var d=`:host{display:block;outline:none!important}:host(:not(:is(:state(slotted),[state--slotted]),:is(:state(slotted-icon),[state--slotted-icon]),:is(:state(has-icon-name),[state--has-icon-name]))){--sbb-radio-button-label-gap:0}:host(:focus-visible) .sbb-radio-button{outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) var(--sbb-focus-outline-style,solid) var(--sbb-focus-outline-width);border-radius:calc(var(--sbb-border-radius-4x) - var(--sbb-focus-outline-offset))}
2
+ `;const u=n=>(()=>{let a=o(n),c=[],u;return class extends a{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(a[Symbol.metadata]??null):void 0;u=[i({attribute:`allow-empty-selection`,type:Boolean})],e(this,null,u,{kind:`setter`,name:`allowEmptySelection`,static:!1,private:!1,access:{has:e=>`allowEmptySelection`in e,set:(e,t)=>{e.allowEmptySelection=t}},metadata:t},null,c),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.styles=[r(l)]}static{this.events={change:`change`,input:`input`}}set allowEmptySelection(e){this._allowEmptySelection=!!e}get allowEmptySelection(){return this._allowEmptySelection||(this.group?.allowEmptySelection??!1)}get group(){return this._group}constructor(){super(),this._allowEmptySelection=(t(this,c),!1),this._group=null,this.addEventListener?.(`click`,e=>this._handleClick(e)),this.addEventListener?.(`keydown`,e=>this._handleKeyDown(e)),this.addController(new s(this,()=>this.closest(`sbb-radio-button-group`),[`disabled`,`required`,`size`].reduce((e,t)=>Object.assign(e,{[t]:()=>this.requestUpdate(t)}),{})))}connectedCallback(){super.connectedCallback(),this._group=this.closest(`sbb-radio-button-group`)}select(){this.disabled||this.formDisabled||(this.allowEmptySelection?(this.checked=!this.checked,this.emitChangeEvents()):this.checked||(this.checked=!0,this.emitChangeEvents()))}willUpdate(e){super.willUpdate(e),e.has(`value`)&&this.dispatchEvent(new Event(`ɵradiobuttonvaluechange`,{bubbles:!0}))}isDisabledExternally(){return this.group?.disabled??!1}isRequiredExternally(){return this.group?.required??!1}_handleClick(e){e.preventDefault(),this.select(),this.focus()}_handleKeyDown(e){e.code===`Space`&&(e.preventDefault(),this.select())}}})();var d=`:host{display:block;outline:none!important}:host(:not(:is(:state(slotted),[state--slotted]),:is(:state(slotted-icon),[state--slotted-icon]),:is(:state(has-icon-name),[state--has-icon-name]))){--sbb-radio-button-label-gap:0}:host(:focus-visible) .sbb-radio-button{outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) var(--sbb-focus-outline-style,solid) var(--sbb-focus-outline-width);border-radius:calc(var(--sbb-border-radius-4x) - var(--sbb-focus-outline-offset))}
3
3
  `;let f=(()=>{let o=u(a),s,l=[],f=[],p,m=[],h=[];return class extends o{static{let t=typeof Symbol==`function`&&Symbol.metadata?Object.create(o[Symbol.metadata]??null):void 0;s=[i({reflect:!0}),c((e,t)=>e.group?.size??t)],p=[i()],e(this,null,s,{kind:`accessor`,name:`size`,static:!1,private:!1,access:{has:e=>`size`in e,get:e=>e.size,set:(e,t)=>{e.size=t}},metadata:t},l,f),e(this,null,p,{kind:`accessor`,name:`value`,static:!1,private:!1,access:{has:e=>`value`in e,get:e=>e.value,set:(e,t)=>{e.value=t}},metadata:t},m,h),t&&Object.defineProperty(this,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:t})}static{this.elementName=`sbb-radio-button`}static{this.styles=[r(d)]}static{this.events={change:`change`,input:`input`}}#e=t(this,l,null);get size(){return this.#e}set size(e){this.#e=e}#t=(t(this,f),t(this,m,null));get value(){return this.#t}set value(e){this.#t=e}render(){return n`
4
4
  <div class="sbb-radio-button">
5
5
  <span class="sbb-radio-button__label-slot">