@proximus/lavender-light 2.0.0-alpha.101 → 2.0.0-alpha.103

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.
@@ -4301,9 +4301,9 @@ if (!customElements.get("px-button-wrapper")) {
4301
4301
  const styles$2 = ':host{display:block}:host,:host *{box-sizing:border-box}.content-wrapper{margin-inline:var(--px-padding-s-mobile);max-width:var(--px-content-wrapper-max-width-desktop)}@media screen and (min-width: 77rem){.content-wrapper{margin-inline:auto}}.overlapped{margin-bottom:calc(var(--px-overlapped-mobile) * -1)}::slotted([slot="overlap"]){margin-top:var(--px-overlapped-mobile)}@media screen and (min-width: 48rem){.overlapped{margin-bottom:calc(var(--px-overlapped-desktop) * -1)}::slotted([slot="overlap"]){margin-top:var(--px-overlapped-desktop)}}@media screen and (min-width: 64.0625rem){.overlapped{margin-bottom:calc(var(--px-overlapped-desktop) * -1)}::slotted([slot="overlap"]){margin-top:var(--px-overlapped-desktop)}}';
4302
4302
  const styleSheet = new CSSStyleSheet();
4303
4303
  styleSheet.replaceSync(styles$2);
4304
- class Section extends HTMLElement {
4304
+ class Section extends WithExtraAttributes {
4305
4305
  constructor() {
4306
- super();
4306
+ super(styleSheet);
4307
4307
  this.template = () => `
4308
4308
  <px-container border-radius="none" padding-inline="none">
4309
4309
  <div class="content-wrapper">
@@ -4319,9 +4319,7 @@ class Section extends HTMLElement {
4319
4319
  <slot name="overlap"></slot>
4320
4320
  </div>
4321
4321
  `;
4322
- this.attachShadow({ mode: "open" });
4323
4322
  this.shadowRoot.innerHTML = this.template();
4324
- this.shadowRoot.adoptedStyleSheets = [styleSheet];
4325
4323
  }
4326
4324
  connectedCallback() {
4327
4325
  var _a, _b;
@@ -4341,6 +4339,7 @@ class Section extends HTMLElement {
4341
4339
  }
4342
4340
  static get observedAttributes() {
4343
4341
  return [
4342
+ ...super.observedAttributes,
4344
4343
  "background-color",
4345
4344
  "background-gradient",
4346
4345
  "background-image",
@@ -4446,6 +4445,9 @@ class Section extends HTMLElement {
4446
4445
  case "border-side--laptop":
4447
4446
  this.$container.borderSideLaptop = newValue;
4448
4447
  break;
4448
+ default:
4449
+ super.attributeChangedCallback(name, oldValue, newValue);
4450
+ break;
4449
4451
  }
4450
4452
  }
4451
4453
  }
@@ -4668,7 +4670,7 @@ class Section extends HTMLElement {
4668
4670
  if (!customElements.get("px-section")) {
4669
4671
  customElements.define("px-section", Section);
4670
4672
  }
4671
- const styles$1 = ":host{display:block}:host *{box-sizing:border-box}button,a{display:block;font-family:var(--px-font-family);font-size:var(--px-text-size-label-m-mobile);line-height:var(--px-font-line-height-l);color:var(--px-color-text-neutral-default);text-align:center;cursor:pointer;padding:32px 0;height:100%}button:after,a:after{content:attr(data-label);display:block;height:0;width:auto;visibility:hidden;overflow:hidden;-webkit-user-select:none;user-select:none;pointer-events:none;font-weight:var(--px-font-weight-title)}button:focus-visible,a:focus-visible{outline-offset:var(--px-focus-offset-mobile);outline:var(--px-focus-outline-mobile) solid var(--px-color-border-focus-outline-default)}button:hover,a:hover{font-weight:var(--px-font-weight-title);color:var(--px-color-background-container-primary-default);padding-block:30px}button{margin:0;border:0;border-bottom:2px solid rgba(0,0,0,0);outline:0;background:inherit}button[aria-expanded=true]{font-weight:var(--px-font-weight-title);color:var(--px-color-background-container-primary-default);border-bottom-color:var(--px-color-background-container-primary-default)}a{text-decoration:none}@media screen and (min-width: 48rem){button,a{font-size:var(--px-text-size-label-m-tablet)}button:focus-visible,a:focus-visible{outline-offset:var(--px-focus-offset-tablet);outline-width:var(--px-focus-outline-tablet)}}@media screen and (min-width: 64.0625rem){button,a{font-size:var(--px-text-size-label-m-laptop)}button:focus-visible,a:focus-visible{outline-offset:var(--px-focus-offset-laptop);outline-width:var(--px-focus-outline-laptop)}}@media screen and (min-width: 90.0625rem){button,a{font-size:var(--px-text-size-label-m-desktop)}button:focus-visible,a:focus-visible{outline-offset:var(--px-focus-offset-desktop);outline-width:var(--px-focus-outline-desktop)}}";
4673
+ const styles$1 = ":host{display:block}:host *{box-sizing:border-box}button,a{display:block;font-family:var(--px-font-family);font-size:var(--px-text-size-label-m-mobile);line-height:var(--px-font-line-height-l);color:var(--px-color-text-neutral-default);text-align:center;cursor:pointer;padding:32px 0;height:100%}button:after,a:after{content:attr(data-label);display:block;height:0;width:auto;visibility:hidden;overflow:hidden;-webkit-user-select:none;user-select:none;pointer-events:none;font-weight:var(--px-font-weight-title)}button:focus-visible,a:focus-visible{outline-offset:var(--px-focus-offset-mobile);outline:var(--px-focus-outline-mobile) solid var(--px-color-border-focus-outline-default)}:host([current]) button,button:hover,:host([current]) a,a:hover{font-weight:var(--px-font-weight-title);color:var(--px-color-background-container-primary-default);padding-block:30px}button{margin:0;border:0;border-bottom:2px solid rgba(0,0,0,0);outline:0;background:inherit}button[aria-expanded=true]{font-weight:var(--px-font-weight-title);color:var(--px-color-background-container-primary-default);border-bottom-color:var(--px-color-background-container-primary-default)}a{text-decoration:none}@media screen and (min-width: 48rem){button,a{font-size:var(--px-text-size-label-m-tablet)}button:focus-visible,a:focus-visible{outline-offset:var(--px-focus-offset-tablet);outline-width:var(--px-focus-outline-tablet)}}@media screen and (min-width: 64.0625rem){button,a{font-size:var(--px-text-size-label-m-laptop)}button:focus-visible,a:focus-visible{outline-offset:var(--px-focus-offset-laptop);outline-width:var(--px-focus-outline-laptop)}}@media screen and (min-width: 90.0625rem){button,a{font-size:var(--px-text-size-label-m-desktop)}button:focus-visible,a:focus-visible{outline-offset:var(--px-focus-offset-desktop);outline-width:var(--px-focus-outline-desktop)}}";
4672
4674
  const stylesheet$1 = new CSSStyleSheet();
4673
4675
  stylesheet$1.replaceSync(styles$1);
4674
4676
  class HeaderItem extends WithExtraAttributes {
@@ -4687,7 +4689,7 @@ class HeaderItem extends WithExtraAttributes {
4687
4689
  }
4688
4690
  }
4689
4691
  static get observedAttributes() {
4690
- return ["for", "href"];
4692
+ return ["for", "href", "current"];
4691
4693
  }
4692
4694
  connectedCallback() {
4693
4695
  this.setAttribute("slot", "header-entries");
@@ -4708,9 +4710,9 @@ class HeaderItem extends WithExtraAttributes {
4708
4710
  }
4709
4711
  attributeChangedCallback(name, oldValue, newValue) {
4710
4712
  super.attributeChangedCallback(name, oldValue, newValue);
4711
- if (name === "href" && this.$a && !!newValue) {
4713
+ if (name === "href" && oldValue !== newValue) {
4712
4714
  this.shadowRoot.innerHTML = this.template();
4713
- } else if (name === "for" && this.$button && !!newValue) {
4715
+ } else if (name === "for" && oldValue !== newValue && this.$button) {
4714
4716
  this.shadowRoot.innerHTML = this.template();
4715
4717
  this.setupButtonA11y();
4716
4718
  }
@@ -4745,6 +4747,16 @@ class HeaderItem extends WithExtraAttributes {
4745
4747
  this.$button.setAttribute("aria-controls", this.for);
4746
4748
  }
4747
4749
  }
4750
+ get current() {
4751
+ return this.hasAttribute("current");
4752
+ }
4753
+ set current(value) {
4754
+ if (value) {
4755
+ this.setAttribute("current", "");
4756
+ } else {
4757
+ this.removeAttribute("current");
4758
+ }
4759
+ }
4748
4760
  get $button() {
4749
4761
  return this.shadowRoot.querySelector("button");
4750
4762
  }