@proximus/lavender 1.4.1-alpha.8 → 1.4.1-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -84,6 +84,7 @@ class WithExtraAttributes extends HTMLElement {
84
84
  ];
85
85
  }
86
86
  attributeChangedCallback(name, oldValue, newValue) {
87
+ var _a;
87
88
  if (WithExtraAttributes.observedAttributes.indexOf(name) === -1) {
88
89
  return;
89
90
  }
@@ -114,7 +115,7 @@ class WithExtraAttributes extends HTMLElement {
114
115
  name,
115
116
  oldValue,
116
117
  newValue,
117
- this.isGrid ? cssGridAlignSelfValues : flexboxAlignSelfValues
118
+ ((_a = this.parentElement) == null ? void 0 : _a.localName) === "px-grid" ? cssGridAlignSelfValues : flexboxAlignSelfValues
118
119
  );
119
120
  break;
120
121
  case "justify-self":
@@ -193,11 +194,19 @@ class WithExtraAttributes extends HTMLElement {
193
194
  var _a;
194
195
  return (_a = this.parentElement) == null ? void 0 : _a.tagName.toLowerCase();
195
196
  }
196
- get isGrid() {
197
- return this.$parentElementName === "px-grid";
198
- }
199
- get isStack() {
200
- return this.$parentElementName === "px-stack";
197
+ get isInsideGridOrStack() {
198
+ let parent = this.parentElement;
199
+ while (parent) {
200
+ if (parent.localName === "px-grid" || parent.localName === "px-stack" && (parent == null ? void 0 : parent.getAttribute("direction")) === "row") {
201
+ return true;
202
+ }
203
+ if (window.getComputedStyle(parent).display === "contents") {
204
+ parent = parent.parentElement;
205
+ continue;
206
+ }
207
+ break;
208
+ }
209
+ return false;
201
210
  }
202
211
  get grow() {
203
212
  return this.getAttribute("grow");
@@ -456,7 +465,6 @@ class PxElement extends WithExtraAttributes {
456
465
  }
457
466
  }
458
467
  connectedCallback() {
459
- var _a;
460
468
  for (const name of getSupportedPropertyNames(this.nativeName)) {
461
469
  if (name === "constructor" || this.accessorExclusions.includes(name)) {
462
470
  continue;
@@ -476,12 +484,9 @@ class PxElement extends WithExtraAttributes {
476
484
  console.warn(`Could not create property ${name} for`, this.$el, e);
477
485
  }
478
486
  }
479
- if (this.isGrid || this.isStack) {
480
- const parentDirection = (_a = this.parentElement) == null ? void 0 : _a.getAttribute("direction");
487
+ if (this.isInsideGridOrStack) {
481
488
  this.$el.style.display = "block";
482
- if (this.isGrid || this.isStack && parentDirection === "row") {
483
- this.$el.style.height = "100%";
484
- }
489
+ this.$el.style.height = "100%";
485
490
  }
486
491
  }
487
492
  get $el() {
@@ -1980,8 +1985,10 @@ class Icon extends WithExtraAttributes {
1980
1985
  }
1981
1986
  if (newValue) {
1982
1987
  __privateGet(this, _internals).ariaHidden = "false";
1988
+ this.ariaHidden = "false";
1983
1989
  } else {
1984
1990
  __privateGet(this, _internals).ariaHidden = "true";
1991
+ this.ariaHidden = "true";
1985
1992
  }
1986
1993
  break;
1987
1994
  }
@@ -2007,6 +2014,7 @@ class Icon extends WithExtraAttributes {
2007
2014
  }
2008
2015
  if (!this.ariaLabel && __privateGet(this, _internals)) {
2009
2016
  __privateGet(this, _internals).ariaHidden = "true";
2017
+ this.ariaHidden = "true";
2010
2018
  }
2011
2019
  }
2012
2020
  updateAttribute(attrName, oldValue, newValue, attrValues) {
@@ -3011,7 +3019,20 @@ const agGridTableThButtonCss = `:host{display:inline-flex;overflow:hidden;word-b
3011
3019
  const agGridTableThButtonStyles = new CSSStyleSheet();
3012
3020
  agGridTableThButtonStyles.replaceSync(agGridTableThButtonCss);
3013
3021
  const sortingValues = ["none", "ascending", "descending"];
3022
+ const CLICK_EVENT$1 = "px.lavender.ag-grid-table-th-button.click";
3014
3023
  const _AgGridTableThButton = class _AgGridTableThButton extends PxElement {
3024
+ constructor() {
3025
+ super(agGridTableThButtonStyles);
3026
+ this.clickHandler = (event) => {
3027
+ this.handleSortingCycle(event);
3028
+ };
3029
+ this.keypressHandler = (event) => {
3030
+ if (event.code === "Enter") {
3031
+ this.handleSortingCycle();
3032
+ }
3033
+ };
3034
+ this.shadowRoot.innerHTML = this.template();
3035
+ }
3015
3036
  template() {
3016
3037
  return `
3017
3038
  <button class="ag-grid-table-th-button">
@@ -3020,15 +3041,6 @@ const _AgGridTableThButton = class _AgGridTableThButton extends PxElement {
3020
3041
  </button>
3021
3042
  `;
3022
3043
  }
3023
- constructor() {
3024
- var _a;
3025
- super(agGridTableThButtonStyles);
3026
- this.shadowRoot.innerHTML = this.template();
3027
- this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
3028
- if (this.internals) {
3029
- this.internals.ariaHidden = "true";
3030
- }
3031
- }
3032
3044
  connectedCallback() {
3033
3045
  var _a, _b, _c;
3034
3046
  super.connectedCallback();
@@ -3040,14 +3052,8 @@ const _AgGridTableThButton = class _AgGridTableThButton extends PxElement {
3040
3052
  "aria-label",
3041
3053
  "Sortable column header, press ctrl + enter to sort"
3042
3054
  );
3043
- this.addEventListener(
3044
- "click",
3045
- (event) => this.cycleToNextSortingValue(event)
3046
- );
3047
- (_c = this.$columnHeader) == null ? void 0 : _c.addEventListener(
3048
- "keypress",
3049
- (event) => this.setKeypressEvent(event)
3050
- );
3055
+ this.addEventListener("click", this.clickHandler);
3056
+ (_c = this.$columnHeader) == null ? void 0 : _c.addEventListener("keypress", this.keypressHandler);
3051
3057
  }
3052
3058
  static get observedAttributes() {
3053
3059
  return [
@@ -3079,8 +3085,8 @@ const _AgGridTableThButton = class _AgGridTableThButton extends PxElement {
3079
3085
  }
3080
3086
  disconnectedCallback() {
3081
3087
  var _a;
3082
- this.removeEventListener("click", this.cycleToNextSortingValue);
3083
- (_a = this.$columnHeader) == null ? void 0 : _a.removeEventListener("keypress", this.setKeypressEvent);
3088
+ this.removeEventListener("click", this.clickHandler);
3089
+ (_a = this.$columnHeader) == null ? void 0 : _a.removeEventListener("keypress", this.keypressHandler);
3084
3090
  }
3085
3091
  updateSorting(oldValue, newValue, attrValue) {
3086
3092
  var _a, _b;
@@ -3106,21 +3112,25 @@ const _AgGridTableThButton = class _AgGridTableThButton extends PxElement {
3106
3112
  (_b = this.$columnHeader) == null ? void 0 : _b.setAttribute("aria-label", newValue);
3107
3113
  }
3108
3114
  }
3109
- setKeypressEvent(event) {
3110
- event.stopPropagation();
3111
- event.preventDefault();
3112
- switch (event.code) {
3113
- case "Enter":
3114
- this.cycleToNextSortingValue();
3115
- break;
3116
- }
3115
+ clickAgGridTableThButton(value) {
3116
+ this.dispatchEvent(
3117
+ new CustomEvent(CLICK_EVENT$1, {
3118
+ bubbles: true,
3119
+ composed: true,
3120
+ detail: { value }
3121
+ })
3122
+ );
3117
3123
  }
3118
3124
  cycleToNextSortingValue(event) {
3125
+ event == null ? void 0 : event.stopPropagation();
3126
+ event == null ? void 0 : event.preventDefault();
3119
3127
  const currentSorting = sortingValues.indexOf(this.sorting);
3120
3128
  const nextSorting = (currentSorting + 1) % sortingValues.length;
3121
3129
  this.sorting = sortingValues[nextSorting];
3122
- event == null ? void 0 : event.stopPropagation();
3123
- event == null ? void 0 : event.preventDefault();
3130
+ }
3131
+ handleSortingCycle(event) {
3132
+ this.cycleToNextSortingValue(event);
3133
+ this.clickAgGridTableThButton(this.sorting);
3124
3134
  }
3125
3135
  get $slottedThContent() {
3126
3136
  return this.querySelector("px-ag-grid-table-th-content");
@@ -5989,10 +5999,12 @@ class CellCheckbox extends WithExtraAttributes {
5989
5999
  this.shadowRoot.innerHTML = this.template();
5990
6000
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
5991
6001
  this.tabIndex = 0;
6002
+ this.role = "checkbox";
5992
6003
  if (this.internals) {
5993
6004
  this.internals.role = "checkbox";
5994
6005
  this.internals.ariaChecked = `${this.checked}`;
5995
6006
  }
6007
+ this.ariaChecked = `${this.checked}`;
5996
6008
  }
5997
6009
  connectedCallback() {
5998
6010
  if (this.$slotVisual) {
@@ -6109,6 +6121,7 @@ class CellCheckbox extends WithExtraAttributes {
6109
6121
  if (this.internals) {
6110
6122
  this.internals.ariaDisabled = "true";
6111
6123
  }
6124
+ this.ariaDisabled = "true";
6112
6125
  this.$cell.disabled = true;
6113
6126
  this.$checkbox.setAttribute("disabled", "");
6114
6127
  this.$children.forEach((child) => {
@@ -6121,6 +6134,7 @@ class CellCheckbox extends WithExtraAttributes {
6121
6134
  if (this.internals) {
6122
6135
  this.internals.ariaDisabled = "false";
6123
6136
  }
6137
+ this.ariaDisabled = "false";
6124
6138
  this.$cell.disabled = false;
6125
6139
  this.$checkbox.removeAttribute("disabled");
6126
6140
  this.$children.forEach((child) => {
@@ -6137,6 +6151,7 @@ class CellCheckbox extends WithExtraAttributes {
6137
6151
  if (this.internals) {
6138
6152
  this.internals.ariaChecked = "false";
6139
6153
  }
6154
+ this.ariaChecked = "false";
6140
6155
  this.checked = false;
6141
6156
  if (this.$checkbox) {
6142
6157
  this.$checkbox.removeAttribute("checked");
@@ -6145,6 +6160,7 @@ class CellCheckbox extends WithExtraAttributes {
6145
6160
  if (this.internals) {
6146
6161
  this.internals.ariaChecked = "true";
6147
6162
  }
6163
+ this.ariaChecked = "true";
6148
6164
  this.checked = true;
6149
6165
  if (this.$checkbox) {
6150
6166
  this.$checkbox.setAttribute("checked", "");
@@ -6392,10 +6408,12 @@ class CellSwitch extends WithExtraAttributes {
6392
6408
  this.shadowRoot.innerHTML = this.template();
6393
6409
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
6394
6410
  this.tabIndex = 0;
6411
+ this.role = "checkbox";
6395
6412
  if (this.internals) {
6396
6413
  this.internals.role = "checkbox";
6397
6414
  this.internals.ariaChecked = `${this.checked}`;
6398
6415
  }
6416
+ this.ariaChecked = `${this.checked}`;
6399
6417
  }
6400
6418
  connectedCallback() {
6401
6419
  if (this.$slotVisual) {
@@ -6497,6 +6515,7 @@ class CellSwitch extends WithExtraAttributes {
6497
6515
  if (this.internals) {
6498
6516
  this.internals.ariaDisabled = "true";
6499
6517
  }
6518
+ this.ariaDisabled = "true";
6500
6519
  this.$cell.disabled = true;
6501
6520
  this.$switch.setAttribute("disabled", "");
6502
6521
  this.$children.forEach((child) => {
@@ -6509,6 +6528,7 @@ class CellSwitch extends WithExtraAttributes {
6509
6528
  if (this.internals) {
6510
6529
  this.internals.ariaDisabled = "false";
6511
6530
  }
6531
+ this.ariaDisabled = "false";
6512
6532
  this.$cell.disabled = false;
6513
6533
  this.$switch.removeAttribute("disabled");
6514
6534
  this.$children.forEach((child) => {
@@ -6525,6 +6545,7 @@ class CellSwitch extends WithExtraAttributes {
6525
6545
  if (this.internals) {
6526
6546
  this.internals.ariaChecked = "false";
6527
6547
  }
6548
+ this.ariaChecked = "false";
6528
6549
  this.checked = false;
6529
6550
  if (this.$switch) {
6530
6551
  this.$switch.removeAttribute("checked");
@@ -6533,6 +6554,7 @@ class CellSwitch extends WithExtraAttributes {
6533
6554
  if (this.internals) {
6534
6555
  this.internals.ariaChecked = "true";
6535
6556
  }
6557
+ this.ariaChecked = "true";
6536
6558
  this.checked = true;
6537
6559
  if (this.$switch) {
6538
6560
  this.$switch.setAttribute("checked", "");
@@ -6795,10 +6817,12 @@ class Radio extends RadioBase {
6795
6817
  super();
6796
6818
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
6797
6819
  this.tabIndex = ((_b = this.parentElement) == null ? void 0 : _b.querySelector("px-radio")) === this ? 0 : -1;
6820
+ this.role = "radio";
6798
6821
  if (this.internals) {
6799
6822
  this.internals.role = "radio";
6800
6823
  this.internals.ariaChecked = `${this.checked}`;
6801
6824
  }
6825
+ this.ariaChecked = `${this.checked}`;
6802
6826
  }
6803
6827
  static get observedAttributes() {
6804
6828
  return [...super.observedAttributes, "state", "variant", "inverted"];
@@ -6896,11 +6920,13 @@ class Radio extends RadioBase {
6896
6920
  if (this.internals) {
6897
6921
  this.internals.ariaChecked = "true";
6898
6922
  }
6923
+ this.ariaChecked = "true";
6899
6924
  } else {
6900
6925
  this.tabIndex = -1;
6901
6926
  if (this.internals) {
6902
6927
  this.internals.ariaChecked = "false";
6903
6928
  }
6929
+ this.ariaChecked = "false";
6904
6930
  }
6905
6931
  if (checked) {
6906
6932
  this.dispatchEvent(
@@ -7281,10 +7307,12 @@ class CellRadio extends WithExtraAttributes {
7281
7307
  super(commonStyleSheet$6);
7282
7308
  this.shadowRoot.innerHTML = this.template();
7283
7309
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
7310
+ this.role = "radio";
7284
7311
  if (this.internals) {
7285
7312
  this.internals.role = "radio";
7286
7313
  this.internals.ariaChecked = `${this.checked}`;
7287
7314
  }
7315
+ this.ariaChecked = `${this.checked}`;
7288
7316
  }
7289
7317
  connectedCallback() {
7290
7318
  var _a;
@@ -7405,6 +7433,7 @@ class CellRadio extends WithExtraAttributes {
7405
7433
  if (this.internals) {
7406
7434
  this.internals.ariaDisabled = "true";
7407
7435
  }
7436
+ this.ariaDisabled = "true";
7408
7437
  this.$cell.disabled = true;
7409
7438
  this.$radio.setAttribute("disabled", "");
7410
7439
  this.$children.forEach((child) => {
@@ -7417,6 +7446,7 @@ class CellRadio extends WithExtraAttributes {
7417
7446
  if (this.internals) {
7418
7447
  this.internals.ariaDisabled = "false";
7419
7448
  }
7449
+ this.ariaDisabled = "false";
7420
7450
  this.$cell.disabled = false;
7421
7451
  this.$radio.removeAttribute("disabled");
7422
7452
  this.$children.forEach((child) => {
@@ -7433,6 +7463,7 @@ class CellRadio extends WithExtraAttributes {
7433
7463
  if (this.internals) {
7434
7464
  this.internals.ariaChecked = "false";
7435
7465
  }
7466
+ this.ariaChecked = "false";
7436
7467
  this.tabIndex = -1;
7437
7468
  this.checked = false;
7438
7469
  if (this.$radio) {
@@ -7442,6 +7473,7 @@ class CellRadio extends WithExtraAttributes {
7442
7473
  if (this.internals) {
7443
7474
  this.internals.ariaChecked = "true";
7444
7475
  }
7476
+ this.ariaChecked = "true";
7445
7477
  this.tabIndex = 0;
7446
7478
  this.checked = true;
7447
7479
  if (this.$radio) {
@@ -7864,32 +7896,39 @@ if (!customElements.get("px-color-option-link")) {
7864
7896
  customElements.define("px-color-option-link", ColorOptionLink);
7865
7897
  }
7866
7898
  const contentHeaderCss = ":host{--min-height--mobile: 15.625em;--min-height--tablet: 17.5em;--min-height--laptop: 17.5em;--min-height--desktop: 17.5em}:host,:host>*{display:block;box-sizing:border-box}.content-header{position:relative;z-index:0}[min-height] .content-header-content{min-height:calc(var(--min-height--mobile) - (var(--px-spacing-l-mobile) * 2))}.content-header-content{display:flex;flex-direction:column;gap:var(--px-spacing-l-mobile);z-index:2;position:relative;box-sizing:border-box}.contrast-helper{position:absolute;top:0;right:0;bottom:0;left:0;z-index:1;pointer-events:none;display:none}[contrast-helper-gradient] .contrast-helper{display:block;background-image:linear-gradient(90deg,#fff 23.43%,#fff0 81.69%)}[inverted] :is([contrast-helper-gradient] .contrast-helper){background-image:linear-gradient(90deg,#000 23.43%,#0000 81.69%)}[contrast-helper-overlay] .contrast-helper{display:block;background-color:#ffffffb3}[inverted] :is([contrast-helper-overlay] .contrast-helper){background-color:#0006}@media only screen and (min-width: 48em){.content-header-content{gap:var(--px-spacing-l-desktop)}[min-height] .content-header-content{min-height:calc(var(--min-height--tablet) - (var(--px-spacing-l-tablet) * 2))}}@media only screen and (min-width: 64.0625em){.content-header-content{gap:var(--px-spacing-l-laptop)}[min-height] .content-header-content{min-height:calc(var(--min-height--laptop) - (var(--px-spacing-l-laptop) * 2))}}";
7867
- const contentHeaderStyles = new CSSStyleSheet();
7868
- contentHeaderStyles.replaceSync(contentHeaderCss);
7869
- const _ContentHeader = class _ContentHeader extends PxElement {
7899
+ const styles$w = ':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 only screen and (min-width: 77em){.content-wrapper{margin-inline:auto}}.overlapped{margin-bottom:calc(var(--px-overlapped-mobile) * -1)}::slotted([slot="overlap"]){margin-top:var(--px-overlapped-mobile)}@media only screen and (min-width: 48em){.overlapped{margin-bottom:calc(var(--px-overlapped-desktop) * -1)}::slotted([slot="overlap"]){margin-top:var(--px-overlapped-desktop)}}@media only screen and (min-width: 64.0625em){.overlapped{margin-bottom:calc(var(--px-overlapped-desktop) * -1)}::slotted([slot="overlap"]){margin-top:var(--px-overlapped-desktop)}}';
7900
+ const styleSheet$q = new CSSStyleSheet();
7901
+ styleSheet$q.replaceSync(styles$w);
7902
+ class Section extends HTMLElement {
7870
7903
  constructor() {
7871
- super(contentHeaderStyles);
7872
- this.template = () => `<div class="content-header">
7873
- <div class="contrast-helper"></div>
7874
- <px-section padding-block="l">
7875
- <px-grid gap="none">
7876
- <px-container padding="none" border-radius="none" background-color="none" >
7877
- <div class="content-header-content">
7878
- <px-vstack gap="heading-to-subtitle">
7879
- <px-h1 variant="title-3xl"><slot></slot></px-h1>
7880
- <slot name="subtitle"></slot>
7881
- </px-vstack>
7882
- ${this.$patchDescriptionSlot ? `<px-stack gap="s" direction="row" direction--mobile="column">
7883
- <slot name="patch" shrink></slot>
7884
- <slot name="patch-description"></slot>
7885
- </px-stack>` : ""}
7886
- </div>
7887
- </px-container>
7888
- </px-grid>
7889
- ${this.$overlapSlot ? `<slot name="overlap" slot="overlap"></slot>` : ""}
7890
- </px-section>
7891
- </div>`;
7904
+ super();
7905
+ this.template = () => `
7906
+ <px-container border-radius="none" padding-inline="none" background-color="${this.backgroundColor}">
7907
+ <div class="content-wrapper ${this.$slotOverlap ? "overlapped" : ""}">
7908
+ <px-vstack gap="heading-to-content">
7909
+ <slot name="heading"></slot>
7910
+ <px-vstack gap="none">
7911
+ <slot></slot>
7912
+ </px-vstack>
7913
+ </px-vstack>
7914
+ </div>
7915
+ </px-container>
7916
+ <div class="content-wrapper">
7917
+ <slot name="overlap"></slot>
7918
+ </div>
7919
+ `;
7920
+ this.attachShadow({ mode: "open" });
7892
7921
  this.shadowRoot.innerHTML = this.template();
7922
+ this.shadowRoot.adoptedStyleSheets = [styleSheet$q];
7923
+ }
7924
+ connectedCallback() {
7925
+ const headingSlot = this.querySelector('[slot="heading"]');
7926
+ if (!this.paddingBlock && !this.paddingTop && !this.paddingBottom && !this.paddingBlockMobile && !this.paddingTopMobile && !this.paddingBottomMobile && !this.paddingBlockTablet && !this.paddingTopTablet && !this.paddingBottomTablet && !this.paddingBlockLaptop && !this.paddingTopLaptop && !this.paddingBottomLaptop) {
7927
+ this.$container.paddingBlock = "none";
7928
+ }
7929
+ if (!headingSlot) {
7930
+ this.shadowRoot.querySelector("px-vstack").setAttribute("gap", "none");
7931
+ }
7893
7932
  }
7894
7933
  static get observedAttributes() {
7895
7934
  return [
@@ -7901,137 +7940,114 @@ const _ContentHeader = class _ContentHeader extends PxElement {
7901
7940
  "background-image--laptop",
7902
7941
  "background-size",
7903
7942
  "background-position",
7904
- "contrast-helper-gradient",
7905
- "contrast-helper-overlay",
7906
- "min-height",
7907
- "has-gridding",
7908
- "has-gridding--mobile",
7909
- "has-gridding--tablet",
7910
- "has-gridding--laptop",
7911
- "inverted"
7943
+ "padding-block",
7944
+ "padding-top",
7945
+ "padding-bottom",
7946
+ "padding-block--mobile",
7947
+ "padding-top--mobile",
7948
+ "padding-bottom--mobile",
7949
+ "padding-block--tablet",
7950
+ "padding-top--tablet",
7951
+ "padding-bottom--tablet",
7952
+ "padding-block--laptop",
7953
+ "padding-top--laptop",
7954
+ "padding-bottom--laptop",
7955
+ "border",
7956
+ "border-side",
7957
+ "border-side--mobile",
7958
+ "border-side--tablet",
7959
+ "border-side--laptop"
7912
7960
  ];
7913
7961
  }
7914
- connectedCallback() {
7915
- var _a;
7916
- (_a = super.connectedCallback) == null ? void 0 : _a.call(this);
7917
- if (this.$subtitleSlot) {
7918
- this.$subtitleSlot.setAttribute("variant", "subtitle");
7919
- }
7920
- if (this.$patchDescriptionSlot) {
7921
- if (this.$patchDescriptionSlot.localName === "px-p") {
7922
- this.$patchDescriptionSlot.setAttribute("variant", "default");
7923
- }
7924
- if (this.$patchDescriptionSlot.localName === "px-p" || this.$patchDescriptionSlot.localName === "px-span") {
7925
- this.$patchDescriptionSlot.setAttribute("font-size", "body-l");
7926
- this.$patchDescriptionSlot.removeAttribute("font-weight");
7927
- this.$patchDescriptionSlot.removeAttribute("color");
7928
- }
7929
- if (this.$patchDescriptionSlot.localName === "px-price") {
7930
- this.$patchDescriptionSlot.setAttribute("size", "m");
7931
- }
7932
- }
7933
- this.createGridding();
7962
+ get $container() {
7963
+ return this.shadowRoot.querySelector("px-container");
7934
7964
  }
7935
- attributeChangedCallback(attrName, oldValue, newValue) {
7965
+ attributeChangedCallback(name, oldValue, newValue) {
7936
7966
  if (oldValue !== newValue) {
7937
- switch (attrName) {
7967
+ switch (name) {
7938
7968
  case "background-color":
7939
- this.$section.backgroundColor = backgroundColorValues.indexOf(newValue) > 0 ? newValue : "none";
7969
+ this.$container.backgroundColor = backgroundColorValues.indexOf(newValue) > 0 ? newValue : "none";
7940
7970
  break;
7941
7971
  case "background-gradient":
7942
- this.$section.gradient = gradientValues.indexOf(newValue) > 0 ? newValue : "none";
7972
+ this.$container.gradient = this.gradient;
7943
7973
  break;
7944
7974
  case "background-image":
7945
- this.$section.backgroundImage = newValue;
7975
+ this.$container.backgroundImage = newValue;
7946
7976
  break;
7947
7977
  case "background-image--mobile":
7948
- this.$section.backgroundImageMobile = newValue;
7978
+ this.$container.backgroundImageMobile = newValue;
7949
7979
  break;
7950
7980
  case "background-image--tablet":
7951
- this.$section.backgroundImageTablet = newValue;
7981
+ this.$container.backgroundImageTablet = newValue;
7952
7982
  break;
7953
7983
  case "background-image--laptop":
7954
- this.$section.backgroundImageLaptop = newValue;
7984
+ this.$container.backgroundImageLaptop = newValue;
7955
7985
  break;
7956
7986
  case "background-size":
7957
- this.$section.backgroundSize = backgroundSizeValues.indexOf(newValue) > 0 ? newValue : "";
7987
+ this.$container.backgroundSize = newValue;
7958
7988
  break;
7959
7989
  case "background-position":
7960
- this.$section.backgroundPosition = newValue;
7990
+ this.$container.backgroundPosition = newValue;
7961
7991
  break;
7962
- case "has-gridding":
7963
- case "has-gridding--mobile":
7964
- case "has-gridding--tablet":
7965
- case "has-gridding--laptop":
7966
- this.createGridding();
7992
+ case "padding-block":
7993
+ this.$container.paddingBlock = newValue;
7967
7994
  break;
7968
- case "inverted":
7969
- for (let i = 0; i < this.$children.length; i++) {
7970
- if (!this.$children[i].hasAttribute("inverted")) {
7971
- this.$children[i].toggleAttribute("inverted");
7972
- }
7973
- }
7974
- this.$h1.toggleAttribute("inverted", newValue !== null);
7975
- this.$el.toggleAttribute("inverted", newValue !== null);
7995
+ case "padding-top":
7996
+ this.$container.paddingTop = newValue;
7976
7997
  break;
7977
- default:
7978
- super.attributeChangedCallback(attrName, oldValue, newValue);
7998
+ case "padding-bottom":
7999
+ this.$container.paddingBottom = newValue;
8000
+ break;
8001
+ case "padding-block--mobile":
8002
+ this.$container.paddingBlockMobile = newValue;
8003
+ break;
8004
+ case "padding-top--mobile":
8005
+ this.$container.paddingTopMobile = newValue;
8006
+ break;
8007
+ case "padding-bottom--mobile":
8008
+ this.$container.paddingBottomMobile = newValue;
8009
+ break;
8010
+ case "padding-block--tablet":
8011
+ this.$container.paddingBlockTablet = newValue;
8012
+ break;
8013
+ case "padding-top--tablet":
8014
+ this.$container.paddingTopTablet = newValue;
8015
+ break;
8016
+ case "padding-bottom--tablet":
8017
+ this.$container.paddingBottomTablet = newValue;
8018
+ break;
8019
+ case "padding-block--laptop":
8020
+ this.$container.paddingBlockLaptop = newValue;
8021
+ break;
8022
+ case "padding-top--laptop":
8023
+ this.$container.paddingTopLaptop = newValue;
8024
+ break;
8025
+ case "padding-bottom--laptop":
8026
+ this.$container.paddingBottomLaptop = newValue;
8027
+ break;
8028
+ case "border":
8029
+ this.$container.border = newValue;
8030
+ break;
8031
+ case "border-side":
8032
+ this.$container.borderSide = newValue;
8033
+ break;
8034
+ case "border-side--mobile":
8035
+ this.$container.borderSideMobile = newValue;
8036
+ break;
8037
+ case "border-side--tablet":
8038
+ this.$container.borderSideTablet = newValue;
8039
+ break;
8040
+ case "border-side--laptop":
8041
+ this.$container.borderSideLaptop = newValue;
7979
8042
  break;
7980
8043
  }
7981
8044
  }
7982
8045
  }
7983
- createGridding() {
7984
- const breakpoints = [
7985
- { prop: "hasGridding", gridProp: "gridCols", attr: "col-span" },
7986
- {
7987
- prop: "hasGriddingMobile",
7988
- gridProp: "gridColsMobile",
7989
- attr: "col-span--mobile"
7990
- },
7991
- {
7992
- prop: "hasGriddingTablet",
7993
- gridProp: "gridColsTablet",
7994
- attr: "col-span--tablet"
7995
- },
7996
- {
7997
- prop: "hasGriddingLaptop",
7998
- gridProp: "gridColsLaptop",
7999
- attr: "col-span--laptop"
8000
- }
8001
- ];
8002
- const spanElement = this.shadowRoot.querySelector(
8003
- "px-grid > px-container"
8004
- );
8005
- breakpoints.forEach(({ prop, gridProp, attr }) => {
8006
- if (this[prop]) {
8007
- this.$grid[gridProp] = "3";
8008
- spanElement.setAttribute(attr, "2");
8009
- }
8010
- });
8011
- }
8012
- get $grid() {
8013
- return this.shadowRoot.querySelector("px-grid");
8014
- }
8015
- get $section() {
8016
- return this.shadowRoot.querySelector("px-section");
8017
- }
8018
- get $h1() {
8019
- return this.shadowRoot.querySelector("px-h1");
8020
- }
8021
- get $subtitleSlot() {
8022
- return this.querySelector('[slot="subtitle"]');
8023
- }
8024
- get $patchDescriptionSlot() {
8025
- return this.querySelector('[slot="patch-description"]');
8026
- }
8027
- get $overlapSlot() {
8028
- return this.querySelector('[slot="overlap"]');
8029
- }
8030
- get $children() {
8031
- return this.querySelectorAll("px-content-header > *");
8046
+ get $slotOverlap() {
8047
+ return this.querySelector('[slot="overlap"]');
8032
8048
  }
8033
8049
  get backgroundColor() {
8034
- return this.getAttribute("background-color");
8050
+ return this.getAttribute("background-color") || "none";
8035
8051
  }
8036
8052
  set backgroundColor(value) {
8037
8053
  this.setAttribute("background-color", value);
@@ -8078,331 +8094,221 @@ const _ContentHeader = class _ContentHeader extends PxElement {
8078
8094
  set backgroundPosition(value) {
8079
8095
  this.setAttribute("background-position", value);
8080
8096
  }
8081
- get gradientContrastHelper() {
8082
- return this.hasAttribute("contrast-helper-gradient");
8097
+ get paddingBlock() {
8098
+ return this.getAttribute("padding-block");
8083
8099
  }
8084
- set gradientContrastHelper(value) {
8085
- if (value) {
8086
- this.setAttribute("contrast-helper-gradient", "");
8087
- } else {
8088
- this.removeAttribute("contrast-helper-gradient");
8089
- }
8100
+ set paddingBlock(value) {
8101
+ this.setAttribute("padding-block", value);
8090
8102
  }
8091
- get overlayContrastHelper() {
8092
- return this.hasAttribute("contrast-helper-overlay");
8103
+ get paddingTop() {
8104
+ return this.getAttribute("padding-top");
8093
8105
  }
8094
- set overlayContrastHelper(value) {
8095
- if (value) {
8096
- this.setAttribute("contrast-helper-overlay", "");
8097
- } else {
8098
- this.removeAttribute("contrast-helper-overlay");
8099
- }
8106
+ set paddingTop(value) {
8107
+ this.setAttribute("padding-top", value);
8100
8108
  }
8101
- get hasGridding() {
8102
- return this.hasAttribute("has-gridding");
8109
+ get paddingBottom() {
8110
+ return this.getAttribute("padding-bottom");
8103
8111
  }
8104
- set hasGridding(value) {
8105
- if (value) {
8106
- this.setAttribute("has-gridding", "");
8107
- } else {
8108
- this.removeAttribute("has-gridding");
8109
- }
8112
+ set paddingBottom(value) {
8113
+ this.setAttribute("padding-bottom", value);
8110
8114
  }
8111
- get hasGriddingMobile() {
8112
- return this.hasAttribute("has-gridding--mobile");
8115
+ get paddingBlockMobile() {
8116
+ return this.getAttribute("padding-block--mobile");
8113
8117
  }
8114
- set hasGriddingMobile(value) {
8115
- if (value) {
8116
- this.setAttribute("has-gridding--mobile", "");
8117
- } else {
8118
- this.removeAttribute("has-gridding--mobile");
8119
- }
8118
+ set paddingBlockMobile(value) {
8119
+ this.setAttribute("padding-block--mobile", value);
8120
8120
  }
8121
- get hasGriddingTablet() {
8122
- return this.hasAttribute("has-gridding--tablet");
8121
+ get paddingTopMobile() {
8122
+ return this.getAttribute("padding-top--mobile");
8123
8123
  }
8124
- set hasGriddingTablet(value) {
8125
- if (value) {
8126
- this.setAttribute("has-gridding--tablet", "");
8127
- } else {
8128
- this.removeAttribute("has-gridding--tablet");
8129
- }
8124
+ set paddingTopMobile(value) {
8125
+ this.setAttribute("padding-top--mobile", value);
8130
8126
  }
8131
- get hasGriddingLaptop() {
8132
- return this.hasAttribute("has-gridding--laptop");
8127
+ get paddingBottomMobile() {
8128
+ return this.getAttribute("padding-bottom--mobile");
8133
8129
  }
8134
- set hasGriddingLaptop(value) {
8135
- if (value) {
8136
- this.setAttribute("has-gridding--laptop", "");
8137
- } else {
8138
- this.removeAttribute("has-gridding--laptop");
8139
- }
8130
+ set paddingBottomMobile(value) {
8131
+ this.setAttribute("padding-bottom--mobile", value);
8140
8132
  }
8141
- get inverted() {
8142
- return this.hasAttribute("inverted");
8133
+ get paddingBlockTablet() {
8134
+ return this.getAttribute("padding-block--tablet");
8143
8135
  }
8144
- set inverted(value) {
8145
- if (value) {
8146
- this.setAttribute("inverted", "");
8147
- } else {
8148
- this.removeAttribute("inverted");
8149
- }
8136
+ set paddingBlockTablet(value) {
8137
+ this.setAttribute("padding-block--tablet", value);
8150
8138
  }
8151
- get minHeight() {
8152
- return this.hasAttribute("min-height");
8139
+ get paddingTopTablet() {
8140
+ return this.getAttribute("padding-top--tablet");
8153
8141
  }
8154
- set minHeight(value) {
8155
- if (value) {
8156
- this.setAttribute("min-height", "");
8157
- } else {
8158
- this.removeAttribute("min-height");
8159
- }
8142
+ set paddingTopTablet(value) {
8143
+ this.setAttribute("padding-top--tablet", value);
8160
8144
  }
8161
- };
8162
- _ContentHeader.nativeName = "div";
8163
- let ContentHeader = _ContentHeader;
8164
- if (!customElements.get("px-content-header")) {
8165
- customElements.define("px-content-header", ContentHeader);
8166
- }
8167
- const styles$w = ".separator{--separator-size: var(--px-size-border-m);--separator-direction--mobile-border-width: var(--separator-size) 0 0;--separator-direction--mobile-width: initial;--separator-direction--mobile-height: initial;clear:both;margin:0;border-style:solid;border-color:var( --separator-color-default, var(--px-color-border-main-default) );border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-horizontal--mobile{border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-vertical--mobile{width:var(--separator-size);height:100%;border-width:0 var(--separator-size) 0 0}:host([inverted]) .separator{border-color:var( --separator-color-inverted, var(--px-color-border-main-inverted) )}@media only screen and (min-width: 768px){.separator-direction-horizontal--tablet{border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-vertical--tablet{width:var(--separator-size);height:100%;border-width:0 var(--separator-size) 0 0}}@media only screen and (min-width: 1025px){.separator-direction-horizontal--laptop{border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-vertical--laptop{width:var(--separator-size);height:100%;border-width:0 var(--separator-size) 0 0}}@media only screen and (min-width: 1441px){.separator-direction-horizontal--desktop{border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-vertical--desktop{width:var(--separator-size);height:100%;border-width:0 var(--separator-size) 0 0}}";
8168
- const styleSheet$q = new CSSStyleSheet();
8169
- styleSheet$q.replaceSync(styles$w);
8170
- const separatorDirectionValues = [
8171
- "",
8172
- "default",
8173
- "horizontal",
8174
- "vertical"
8175
- ];
8176
- const separatorSizeValues = ["", "default", "none", "s", "m", "l"];
8177
- const separatorColorValues = [
8178
- "",
8179
- "main",
8180
- "brand",
8181
- "none",
8182
- "neutral",
8183
- "purpose-success",
8184
- "purpose-warning",
8185
- "purpose-error",
8186
- "purpose-unlimited",
8187
- "state-hover",
8188
- "state-active"
8189
- ];
8190
- const _Separator = class _Separator extends PxElement {
8191
- constructor() {
8192
- var _a;
8193
- super(styleSheet$q);
8194
- const $root = document.createElement(this.nativeName);
8195
- $root.classList.add("separator");
8196
- this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
8197
- this.shadowRoot.appendChild($root);
8145
+ get paddingBottomTablet() {
8146
+ return this.getAttribute("padding-bottom--tablet");
8198
8147
  }
8199
- static get observedAttributes() {
8200
- return [
8201
- ...super.observedAttributes,
8202
- "direction",
8203
- "direction--mobile",
8204
- "direction--tablet",
8205
- "direction--laptop",
8206
- "direction--desktop",
8207
- "size",
8208
- "color",
8209
- "inverted"
8210
- ];
8148
+ set paddingBottomTablet(value) {
8149
+ this.setAttribute("padding-bottom--tablet", value);
8211
8150
  }
8212
- attributeChangedCallback(attrName, oldValue, newValue) {
8213
- if (oldValue !== newValue) {
8214
- switch (attrName) {
8215
- case "direction":
8216
- case "direction--mobile":
8217
- case "direction--tablet":
8218
- case "direction--laptop":
8219
- case "direction--desktop":
8220
- this.updateDirection(
8221
- attrName,
8222
- oldValue,
8223
- newValue,
8224
- separatorDirectionValues
8225
- );
8226
- break;
8227
- case "size":
8228
- this.updateSize(attrName, oldValue, newValue, separatorSizeValues);
8229
- break;
8230
- case "color":
8231
- this.updateColor(attrName, oldValue, newValue, separatorColorValues);
8232
- break;
8233
- default:
8234
- super.attributeChangedCallback(attrName, oldValue, newValue);
8235
- break;
8236
- }
8237
- }
8151
+ get paddingBlockLaptop() {
8152
+ return this.getAttribute("padding-block--laptop");
8238
8153
  }
8239
- updateSize(attrName, oldValue, newValue, attrValue) {
8240
- const updateSizeStyle = (value) => {
8241
- if (value !== null && value !== "" && value !== "default") {
8242
- this.$el.style.setProperty(
8243
- "--separator-size",
8244
- `var(--px-size-border-${value})`
8245
- );
8246
- }
8247
- };
8248
- if (!this.checkName(attrValue, newValue)) {
8249
- console.error(`${newValue} is not a valid value for ${attrName}`);
8250
- } else {
8251
- updateSizeStyle(oldValue);
8252
- updateSizeStyle(newValue);
8253
- }
8154
+ set paddingBlockLaptop(value) {
8155
+ this.setAttribute("padding-block--laptop", value);
8254
8156
  }
8255
- updateColor(attrName, oldValue, newValue, attrValue) {
8256
- const updateColorStyle = (value) => {
8257
- if (value !== null && value !== "" && value !== "default") {
8258
- this.$el.style.setProperty(
8259
- `--separator-color-default`,
8260
- `var(--px-color-border-${value}-default)`
8261
- );
8262
- this.$el.style.setProperty(
8263
- `--separator-color-inverted`,
8264
- `var(--px-color-border-${value}-inverted)`
8265
- );
8266
- }
8267
- };
8268
- if (!this.checkName(attrValue, newValue)) {
8269
- console.error(`${newValue} is not a valid value for ${attrName}`);
8270
- } else {
8271
- updateColorStyle(oldValue);
8272
- updateColorStyle(newValue);
8273
- }
8157
+ get paddingTopLaptop() {
8158
+ return this.getAttribute("padding-top--laptop");
8274
8159
  }
8275
- updateDirection(attrName, oldValue, newValue, attrValue) {
8276
- const updateDirectionClass = (breakpoint, value) => {
8277
- if (value !== null && value !== "" && value !== "default") {
8278
- this.$el.classList.add(`separator-direction-${value}--${breakpoint}`);
8279
- }
8280
- };
8281
- if (!this.checkName(attrValue, newValue)) {
8282
- console.error(`${newValue} is not a valid value for ${attrName}`);
8283
- } else {
8284
- if (attrName === "direction") {
8285
- ["mobile", "tablet", "laptop", "desktop"].forEach((breakpoint) => {
8286
- const existingClass = Array.from(this.$el.classList).find(
8287
- (className) => className.startsWith(`separator-direction-`) && className.endsWith(`--${breakpoint}`)
8288
- );
8289
- if (!existingClass) {
8290
- updateDirectionClass(breakpoint, newValue);
8291
- }
8292
- });
8293
- } else {
8294
- const breakpoint = attrName.split("--")[1];
8295
- const existingClass = Array.from(this.$el.classList).find(
8296
- (className) => className.startsWith(`separator-direction-`) && className.endsWith(`--${breakpoint}`)
8297
- );
8298
- if (existingClass) {
8299
- this.$el.classList.replace(
8300
- existingClass,
8301
- `separator-direction-${newValue}--${breakpoint}`
8302
- );
8303
- } else {
8304
- updateDirectionClass(breakpoint, newValue);
8305
- }
8306
- }
8307
- }
8308
- }
8309
- get direction() {
8310
- return this.getAttribute("direction");
8311
- }
8312
- set direction(value) {
8313
- this.setAttribute("direction", value);
8314
- }
8315
- get directionMobile() {
8316
- return this.getAttribute("direction--mobile");
8317
- }
8318
- set directionMobile(value) {
8319
- this.setAttribute("direction--mobile", value);
8160
+ set paddingTopLaptop(value) {
8161
+ this.setAttribute("padding-top--laptop", value);
8320
8162
  }
8321
- get directionTablet() {
8322
- return this.getAttribute("direction--tablet");
8163
+ get paddingBottomLaptop() {
8164
+ return this.getAttribute("padding-bottom--laptop");
8323
8165
  }
8324
- set directionTablet(value) {
8325
- this.setAttribute("direction--tablet", value);
8166
+ set paddingBottomLaptop(value) {
8167
+ this.setAttribute("padding-bottom--laptop", value);
8326
8168
  }
8327
- get directionLaptop() {
8328
- return this.getAttribute("direction--laptop");
8169
+ get border() {
8170
+ return this.getAttribute("border");
8329
8171
  }
8330
- set directionLaptop(value) {
8331
- this.setAttribute("direction--laptop", value);
8172
+ set border(value) {
8173
+ this.setAttribute("border", value);
8332
8174
  }
8333
- get directionDesktop() {
8334
- return this.getAttribute("direction--desktop");
8175
+ get borderSide() {
8176
+ return this.getAttribute("border-side");
8335
8177
  }
8336
- set directionDesktop(value) {
8337
- this.setAttribute("direction--desktop", value);
8178
+ set borderSide(value) {
8179
+ this.setAttribute("border-side", value);
8338
8180
  }
8339
- get size() {
8340
- return this.getAttribute("size");
8181
+ get borderSideMobile() {
8182
+ return this.getAttribute("border-side--mobile");
8341
8183
  }
8342
- set size(value) {
8343
- this.setAttribute("size", value);
8184
+ set borderSideMobile(value) {
8185
+ this.setAttribute("border-side--mobile", value);
8344
8186
  }
8345
- get color() {
8346
- return this.getAttribute("color");
8187
+ get borderSideTablet() {
8188
+ return this.getAttribute("border-side--tablet");
8347
8189
  }
8348
- set color(value) {
8349
- this.setAttribute("color", value);
8190
+ set borderSideTablet(value) {
8191
+ this.setAttribute("border-side--tablet", value);
8350
8192
  }
8351
- get inverted() {
8352
- return this.getAttribute("inverted");
8193
+ get borderSideLaptop() {
8194
+ return this.getAttribute("border-side--laptop");
8353
8195
  }
8354
- set inverted(value) {
8355
- this.setAttribute("inverted", value);
8196
+ set borderSideLaptop(value) {
8197
+ this.setAttribute("border-side--laptop", value);
8356
8198
  }
8357
- };
8358
- _Separator.nativeName = "hr";
8359
- let Separator = _Separator;
8360
- if (!customElements.get("px-separator")) {
8361
- customElements.define("px-separator", Separator);
8362
8199
  }
8363
- const headingCss = "h1,.style-title-4xl,::slotted(h1),h2,.style-title-3xl,::slotted(h2),h3,.style-title-2xl,::slotted(h3),h4,.style-title-xl,::slotted(h4),h5,.style-title-l,::slotted(h5),h6,.style-title-m,::slotted(h6),.style-title-s,.style-subtitle{margin:0;font-family:var(--px-font-family);color:var(--heading-color-default, var(--px-color-text-brand-default));text-align:var(--heading-text-align--mobile, left);font-size:var(--px-text-size-heading-s-mobile);line-height:var(--px-line-height-ratio-l);font-weight:var(--px-font-weight-title)}:host([inverted]) h1,:host([inverted]) .style-title-4xl,:host([inverted]) ::slotted(h1),:host([inverted]) h2,:host([inverted]) .style-title-3xl,:host([inverted]) ::slotted(h2),:host([inverted]) h3,:host([inverted]) .style-title-2xl,:host([inverted]) ::slotted(h3),:host([inverted]) h4,:host([inverted]) .style-title-xl,:host([inverted]) ::slotted(h4),:host([inverted]) h5,:host([inverted]) .style-title-l,:host([inverted]) ::slotted(h5),:host([inverted]) h6,:host([inverted]) .style-title-m,:host([inverted]) ::slotted(h6),:host([inverted]) .style-title-s,:host([inverted]) .style-subtitle{color:var(--heading-color-inverted, var(--px-color-text-brand-inverted))}h1,.style-title-4xl,::slotted(h1){font-size:var(--px-text-size-heading-3xl-mobile);line-height:var(--px-line-height-ratio-s);font-weight:var(--px-font-weight-title-large)}h2,.style-title-3xl,::slotted(h2){font-size:var(--px-text-size-heading-2xl-mobile);line-height:var(--px-line-height-ratio-s);font-weight:var(--px-font-weight-title-large)}h3,.style-title-2xl,::slotted(h3){font-size:var(--px-text-size-heading-xl-mobile);line-height:var(--px-line-height-ratio-s)}h4,.style-title-xl,::slotted(h4){font-size:var(--px-text-size-heading-l-mobile)}h5,.style-title-l,::slotted(h5){font-size:var(--px-text-size-heading-m-mobile)}h6,.style-title-m,::slotted(h6){font-size:var(--px-text-size-heading-base-mobile)}.style-subtitle{font-size:var(--px-text-size-heading-l-mobile);font-weight:var(--px-font-weight-subtitle)}.style-title-s{font-size:var(--px-text-size-heading-s-mobile)}@media only screen and (min-width: 768px){h1,.style-title-4xl,::slotted(h1),h2,.style-title-3xl,::slotted(h2),h3,.style-title-2xl,::slotted(h3),h4,.style-title-xl,::slotted(h4),h5,.style-title-l,::slotted(h5),h6,.style-title-m,::slotted(h6),.style-title-s,.style-subtitle{text-align:var(--heading-text-align--tablet, left)}h1,.style-title-4xl,::slotted(h1){font-size:var(--px-text-size-heading-5xl-desktop)}h2,.style-title-3xl,::slotted(h2){font-size:var(--px-text-size-heading-4xl-desktop)}h3,.style-title-2xl,::slotted(h3){font-size:var(--px-text-size-heading-2xl-desktop)}h4,.style-title-xl,::slotted(h4){font-size:var(--px-text-size-heading-xl-desktop)}h5,.style-title-l,::slotted(h5){font-size:var(--px-text-size-heading-l-desktop)}h6,.style-title-m,::slotted(h6){font-size:var(--px-text-size-heading-m-desktop)}.style-title-s{font-size:var(--px-text-size-heading-base-desktop)}.style-subtitle{font-size:var(--px-text-size-heading-xl-desktop)}}@media only screen and (min-width: 1025px){h1,.style-title-4xl,::slotted(h1),h2,.style-title-3xl,::slotted(h2),h3,.style-title-2xl,::slotted(h3),h4,.style-title-xl,::slotted(h4),h5,.style-title-l,::slotted(h5),h6,.style-title-m,::slotted(h6),.style-title-s,.style-subtitle{text-align:var(--heading-text-align--laptop, left)}h1,.style-title-4xl,::slotted(h1){font-size:var(--px-text-size-heading-5xl-desktop)}h2,.style-title-3xl,::slotted(h2){font-size:var(--px-text-size-heading-4xl-desktop)}h3,.style-title-2xl,::slotted(h3){font-size:var(--px-text-size-heading-2xl-desktop)}h4,.style-title-xl,::slotted(h4){font-size:var(--px-text-size-heading-xl-desktop)}h5,.style-title-l,::slotted(h5){font-size:var(--px-text-size-heading-l-desktop)}h6,.style-title-m,::slotted(h6){font-size:var(--px-text-size-heading-m-desktop)}.style-title-s{font-size:var(--px-text-size-heading-base-desktop)}.style-subtitle{font-size:var(--px-text-size-heading-xl-desktop)}}@media screen and (min-width: 1441px){h1,.style-title-4xl,::slotted(h1),h2,.style-title-3xl,::slotted(h2),h3,.style-title-2xl,::slotted(h3),h4,.style-title-xl,::slotted(h4),h5,.style-title-l,::slotted(h5),h6,.style-title-m,::slotted(h6),.style-title-s,.style-subtitle{text-align:var(--heading-text-align--desktop, left)}}";
8364
- const headingStyles$2 = new CSSStyleSheet();
8365
- headingStyles$2.replaceSync(headingCss);
8366
- const typographyStyles$4 = new CSSStyleSheet();
8367
- typographyStyles$4.replaceSync(typographyCss$1);
8368
- class AbstractHeading extends PxElement {
8369
- template() {
8370
- return `<slot></slot>`;
8371
- }
8372
- constructor(tagName) {
8373
- super(headingStyles$2, typographyStyles$4);
8374
- const $root = document.createElement(tagName);
8375
- $root.innerHTML = this.template();
8376
- this.shadowRoot.appendChild($root);
8200
+ if (!customElements.get("px-section")) {
8201
+ customElements.define("px-section", Section);
8202
+ }
8203
+ const contentHeaderStyles = new CSSStyleSheet();
8204
+ contentHeaderStyles.replaceSync(contentHeaderCss);
8205
+ const _ContentHeader = class _ContentHeader extends PxElement {
8206
+ constructor() {
8207
+ super(contentHeaderStyles);
8208
+ this.template = () => `<div class="content-header">
8209
+ <div class="contrast-helper"></div>
8210
+ <px-section padding-block="l">
8211
+ <px-grid gap="none">
8212
+ <px-container padding="none" border-radius="none" background-color="none" >
8213
+ <div class="content-header-content">
8214
+ <px-vstack gap="heading-to-subtitle">
8215
+ <px-h1 variant="title-3xl"><slot></slot></px-h1>
8216
+ <slot name="subtitle"></slot>
8217
+ </px-vstack>
8218
+ ${this.$patchDescriptionSlot ? `<px-stack gap="s" direction="row" direction--mobile="column">
8219
+ <slot name="patch" shrink></slot>
8220
+ <slot name="patch-description"></slot>
8221
+ </px-stack>` : ""}
8222
+ </div>
8223
+ </px-container>
8224
+ </px-grid>
8225
+ ${this.$overlapSlot ? `<slot name="overlap" slot="overlap"></slot>` : ""}
8226
+ </px-section>
8227
+ </div>`;
8228
+ this.shadowRoot.innerHTML = this.template();
8377
8229
  }
8378
8230
  static get observedAttributes() {
8379
8231
  return [
8380
- ...super.observedAttributes,
8381
- "variant",
8382
- "color",
8383
- "text-align",
8384
- "text-align--mobile",
8385
- "text-align--tablet",
8386
- "text-align--laptop",
8387
- "text-align--desktop",
8232
+ "background-color",
8233
+ "background-gradient",
8234
+ "background-image",
8235
+ "background-image--mobile",
8236
+ "background-image--tablet",
8237
+ "background-image--laptop",
8238
+ "background-size",
8239
+ "background-position",
8240
+ "contrast-helper-gradient",
8241
+ "contrast-helper-overlay",
8242
+ "min-height",
8243
+ "has-gridding",
8244
+ "has-gridding--mobile",
8245
+ "has-gridding--tablet",
8246
+ "has-gridding--laptop",
8388
8247
  "inverted"
8389
8248
  ];
8390
8249
  }
8250
+ connectedCallback() {
8251
+ var _a;
8252
+ (_a = super.connectedCallback) == null ? void 0 : _a.call(this);
8253
+ if (this.$subtitleSlot) {
8254
+ this.$subtitleSlot.setAttribute("variant", "subtitle");
8255
+ }
8256
+ if (this.$patchDescriptionSlot) {
8257
+ if (this.$patchDescriptionSlot.localName === "px-p") {
8258
+ this.$patchDescriptionSlot.setAttribute("variant", "default");
8259
+ }
8260
+ if (this.$patchDescriptionSlot.localName === "px-p" || this.$patchDescriptionSlot.localName === "px-span") {
8261
+ this.$patchDescriptionSlot.setAttribute("font-size", "body-l");
8262
+ this.$patchDescriptionSlot.removeAttribute("font-weight");
8263
+ this.$patchDescriptionSlot.removeAttribute("color");
8264
+ }
8265
+ if (this.$patchDescriptionSlot.localName === "px-price") {
8266
+ this.$patchDescriptionSlot.setAttribute("size", "m");
8267
+ }
8268
+ }
8269
+ this.createGridding();
8270
+ }
8391
8271
  attributeChangedCallback(attrName, oldValue, newValue) {
8392
8272
  if (oldValue !== newValue) {
8393
8273
  switch (attrName) {
8394
- case "variant":
8395
- this.updateAttribute(attrName, oldValue, newValue, headingValues);
8274
+ case "background-color":
8275
+ this.$section.backgroundColor = backgroundColorValues.indexOf(newValue) > 0 ? newValue : "none";
8396
8276
  break;
8397
- case "color":
8398
- this.updateColor(oldValue, newValue, colorValues);
8277
+ case "background-gradient":
8278
+ this.$section.gradient = gradientValues.indexOf(newValue) > 0 ? newValue : "none";
8399
8279
  break;
8400
- case "text-align":
8401
- case "text-align--mobile":
8402
- case "text-align--tablet":
8403
- case "text-align--laptop":
8404
- case "text-align--desktop":
8405
- this.updateTextAlign(attrName, oldValue, newValue, textalignValues);
8280
+ case "background-image":
8281
+ this.$section.backgroundImage = newValue;
8282
+ break;
8283
+ case "background-image--mobile":
8284
+ this.$section.backgroundImageMobile = newValue;
8285
+ break;
8286
+ case "background-image--tablet":
8287
+ this.$section.backgroundImageTablet = newValue;
8288
+ break;
8289
+ case "background-image--laptop":
8290
+ this.$section.backgroundImageLaptop = newValue;
8291
+ break;
8292
+ case "background-size":
8293
+ this.$section.backgroundSize = backgroundSizeValues.indexOf(newValue) > 0 ? newValue : "";
8294
+ break;
8295
+ case "background-position":
8296
+ this.$section.backgroundPosition = newValue;
8297
+ break;
8298
+ case "has-gridding":
8299
+ case "has-gridding--mobile":
8300
+ case "has-gridding--tablet":
8301
+ case "has-gridding--laptop":
8302
+ this.createGridding();
8303
+ break;
8304
+ case "inverted":
8305
+ for (let i = 0; i < this.$children.length; i++) {
8306
+ if (!this.$children[i].hasAttribute("inverted")) {
8307
+ this.$children[i].toggleAttribute("inverted");
8308
+ }
8309
+ }
8310
+ this.$h1.toggleAttribute("inverted", newValue !== null);
8311
+ this.$el.toggleAttribute("inverted", newValue !== null);
8406
8312
  break;
8407
8313
  default:
8408
8314
  super.attributeChangedCallback(attrName, oldValue, newValue);
@@ -8410,22 +8316,452 @@ class AbstractHeading extends PxElement {
8410
8316
  }
8411
8317
  }
8412
8318
  }
8413
- toggleClass(oldValue, newValue) {
8414
- if (oldValue !== null && oldValue !== "" && oldValue !== "default") {
8415
- this.$el.classList.toggle(`style-${oldValue}`);
8416
- }
8417
- if (newValue !== null && newValue !== "" && newValue !== "default") {
8418
- this.$el.classList.toggle(`style-${newValue}`);
8419
- }
8319
+ createGridding() {
8320
+ const breakpoints = [
8321
+ { prop: "hasGridding", gridProp: "gridCols", attr: "col-span" },
8322
+ {
8323
+ prop: "hasGriddingMobile",
8324
+ gridProp: "gridColsMobile",
8325
+ attr: "col-span--mobile"
8326
+ },
8327
+ {
8328
+ prop: "hasGriddingTablet",
8329
+ gridProp: "gridColsTablet",
8330
+ attr: "col-span--tablet"
8331
+ },
8332
+ {
8333
+ prop: "hasGriddingLaptop",
8334
+ gridProp: "gridColsLaptop",
8335
+ attr: "col-span--laptop"
8336
+ }
8337
+ ];
8338
+ const spanElement = this.shadowRoot.querySelector(
8339
+ "px-grid > px-container"
8340
+ );
8341
+ breakpoints.forEach(({ prop, gridProp, attr }) => {
8342
+ if (this[prop]) {
8343
+ this.$grid[gridProp] = "3";
8344
+ spanElement.setAttribute(attr, "2");
8345
+ }
8346
+ });
8420
8347
  }
8421
- updateAttribute(attrName, oldValue, newValue, attrValue) {
8422
- if (!this.checkName(attrValue, newValue)) {
8423
- console.error(`${newValue} is not an allowed "${attrName}" value`);
8424
- } else {
8425
- this.toggleClass(oldValue, newValue);
8426
- }
8348
+ get $grid() {
8349
+ return this.shadowRoot.querySelector("px-grid");
8427
8350
  }
8428
- updateColor(oldValue, newValue, attrValue) {
8351
+ get $section() {
8352
+ return this.shadowRoot.querySelector("px-section");
8353
+ }
8354
+ get $h1() {
8355
+ return this.shadowRoot.querySelector("px-h1");
8356
+ }
8357
+ get $subtitleSlot() {
8358
+ return this.querySelector('[slot="subtitle"]');
8359
+ }
8360
+ get $patchDescriptionSlot() {
8361
+ return this.querySelector('[slot="patch-description"]');
8362
+ }
8363
+ get $overlapSlot() {
8364
+ return this.querySelector('[slot="overlap"]');
8365
+ }
8366
+ get $children() {
8367
+ return this.querySelectorAll("px-content-header > *");
8368
+ }
8369
+ get backgroundColor() {
8370
+ return this.getAttribute("background-color");
8371
+ }
8372
+ set backgroundColor(value) {
8373
+ this.setAttribute("background-color", value);
8374
+ }
8375
+ get gradient() {
8376
+ return this.getAttribute("background-gradient");
8377
+ }
8378
+ set gradient(value) {
8379
+ this.setAttribute("background-gradient", value);
8380
+ }
8381
+ get backgroundImage() {
8382
+ return this.getAttribute("background-image");
8383
+ }
8384
+ set backgroundImage(value) {
8385
+ this.setAttribute("background-image", value);
8386
+ }
8387
+ get backgroundImageMobile() {
8388
+ return this.getAttribute("background-image--mobile");
8389
+ }
8390
+ set backgroundImageMobile(value) {
8391
+ this.setAttribute("background-image--mobile", value);
8392
+ }
8393
+ get backgroundImageTablet() {
8394
+ return this.getAttribute("background-image--tablet");
8395
+ }
8396
+ set backgroundImageTablet(value) {
8397
+ this.setAttribute("background-image--tablet", value);
8398
+ }
8399
+ get backgroundImageLaptop() {
8400
+ return this.getAttribute("background-image--laptop");
8401
+ }
8402
+ set backgroundImageLaptop(value) {
8403
+ this.setAttribute("background-image--laptop", value);
8404
+ }
8405
+ get backgroundSize() {
8406
+ return this.getAttribute("background-size");
8407
+ }
8408
+ set backgroundSize(value) {
8409
+ this.setAttribute("background-size", value);
8410
+ }
8411
+ get backgroundPosition() {
8412
+ return this.getAttribute("background-position");
8413
+ }
8414
+ set backgroundPosition(value) {
8415
+ this.setAttribute("background-position", value);
8416
+ }
8417
+ get gradientContrastHelper() {
8418
+ return this.hasAttribute("contrast-helper-gradient");
8419
+ }
8420
+ set gradientContrastHelper(value) {
8421
+ if (value) {
8422
+ this.setAttribute("contrast-helper-gradient", "");
8423
+ } else {
8424
+ this.removeAttribute("contrast-helper-gradient");
8425
+ }
8426
+ }
8427
+ get overlayContrastHelper() {
8428
+ return this.hasAttribute("contrast-helper-overlay");
8429
+ }
8430
+ set overlayContrastHelper(value) {
8431
+ if (value) {
8432
+ this.setAttribute("contrast-helper-overlay", "");
8433
+ } else {
8434
+ this.removeAttribute("contrast-helper-overlay");
8435
+ }
8436
+ }
8437
+ get hasGridding() {
8438
+ return this.hasAttribute("has-gridding");
8439
+ }
8440
+ set hasGridding(value) {
8441
+ if (value) {
8442
+ this.setAttribute("has-gridding", "");
8443
+ } else {
8444
+ this.removeAttribute("has-gridding");
8445
+ }
8446
+ }
8447
+ get hasGriddingMobile() {
8448
+ return this.hasAttribute("has-gridding--mobile");
8449
+ }
8450
+ set hasGriddingMobile(value) {
8451
+ if (value) {
8452
+ this.setAttribute("has-gridding--mobile", "");
8453
+ } else {
8454
+ this.removeAttribute("has-gridding--mobile");
8455
+ }
8456
+ }
8457
+ get hasGriddingTablet() {
8458
+ return this.hasAttribute("has-gridding--tablet");
8459
+ }
8460
+ set hasGriddingTablet(value) {
8461
+ if (value) {
8462
+ this.setAttribute("has-gridding--tablet", "");
8463
+ } else {
8464
+ this.removeAttribute("has-gridding--tablet");
8465
+ }
8466
+ }
8467
+ get hasGriddingLaptop() {
8468
+ return this.hasAttribute("has-gridding--laptop");
8469
+ }
8470
+ set hasGriddingLaptop(value) {
8471
+ if (value) {
8472
+ this.setAttribute("has-gridding--laptop", "");
8473
+ } else {
8474
+ this.removeAttribute("has-gridding--laptop");
8475
+ }
8476
+ }
8477
+ get inverted() {
8478
+ return this.hasAttribute("inverted");
8479
+ }
8480
+ set inverted(value) {
8481
+ if (value) {
8482
+ this.setAttribute("inverted", "");
8483
+ } else {
8484
+ this.removeAttribute("inverted");
8485
+ }
8486
+ }
8487
+ get minHeight() {
8488
+ return this.hasAttribute("min-height");
8489
+ }
8490
+ set minHeight(value) {
8491
+ if (value) {
8492
+ this.setAttribute("min-height", "");
8493
+ } else {
8494
+ this.removeAttribute("min-height");
8495
+ }
8496
+ }
8497
+ };
8498
+ _ContentHeader.nativeName = "div";
8499
+ let ContentHeader = _ContentHeader;
8500
+ if (!customElements.get("px-content-header")) {
8501
+ customElements.define("px-content-header", ContentHeader);
8502
+ }
8503
+ const styles$v = ".separator{--separator-size: var(--px-size-border-m);--separator-direction--mobile-border-width: var(--separator-size) 0 0;--separator-direction--mobile-width: initial;--separator-direction--mobile-height: initial;clear:both;margin:0;border-style:solid;border-color:var( --separator-color-default, var(--px-color-border-main-default) );border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-horizontal--mobile{border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-vertical--mobile{width:var(--separator-size);height:100%;border-width:0 var(--separator-size) 0 0}:host([inverted]) .separator{border-color:var( --separator-color-inverted, var(--px-color-border-main-inverted) )}@media only screen and (min-width: 768px){.separator-direction-horizontal--tablet{border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-vertical--tablet{width:var(--separator-size);height:100%;border-width:0 var(--separator-size) 0 0}}@media only screen and (min-width: 1025px){.separator-direction-horizontal--laptop{border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-vertical--laptop{width:var(--separator-size);height:100%;border-width:0 var(--separator-size) 0 0}}@media only screen and (min-width: 1441px){.separator-direction-horizontal--desktop{border-width:var(--separator-size) 0 0;width:initial;height:initial}.separator-direction-vertical--desktop{width:var(--separator-size);height:100%;border-width:0 var(--separator-size) 0 0}}";
8504
+ const styleSheet$p = new CSSStyleSheet();
8505
+ styleSheet$p.replaceSync(styles$v);
8506
+ const separatorDirectionValues = [
8507
+ "",
8508
+ "default",
8509
+ "horizontal",
8510
+ "vertical"
8511
+ ];
8512
+ const separatorSizeValues = ["", "default", "none", "s", "m", "l"];
8513
+ const separatorColorValues = [
8514
+ "",
8515
+ "main",
8516
+ "brand",
8517
+ "none",
8518
+ "neutral",
8519
+ "purpose-success",
8520
+ "purpose-warning",
8521
+ "purpose-error",
8522
+ "purpose-unlimited",
8523
+ "state-hover",
8524
+ "state-active"
8525
+ ];
8526
+ const _Separator = class _Separator extends PxElement {
8527
+ constructor() {
8528
+ var _a;
8529
+ super(styleSheet$p);
8530
+ const $root = document.createElement(this.nativeName);
8531
+ $root.classList.add("separator");
8532
+ this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
8533
+ this.shadowRoot.appendChild($root);
8534
+ }
8535
+ static get observedAttributes() {
8536
+ return [
8537
+ ...super.observedAttributes,
8538
+ "direction",
8539
+ "direction--mobile",
8540
+ "direction--tablet",
8541
+ "direction--laptop",
8542
+ "direction--desktop",
8543
+ "size",
8544
+ "color",
8545
+ "inverted"
8546
+ ];
8547
+ }
8548
+ attributeChangedCallback(attrName, oldValue, newValue) {
8549
+ if (oldValue !== newValue) {
8550
+ switch (attrName) {
8551
+ case "direction":
8552
+ case "direction--mobile":
8553
+ case "direction--tablet":
8554
+ case "direction--laptop":
8555
+ case "direction--desktop":
8556
+ this.updateDirection(
8557
+ attrName,
8558
+ oldValue,
8559
+ newValue,
8560
+ separatorDirectionValues
8561
+ );
8562
+ break;
8563
+ case "size":
8564
+ this.updateSize(attrName, oldValue, newValue, separatorSizeValues);
8565
+ break;
8566
+ case "color":
8567
+ this.updateColor(attrName, oldValue, newValue, separatorColorValues);
8568
+ break;
8569
+ default:
8570
+ super.attributeChangedCallback(attrName, oldValue, newValue);
8571
+ break;
8572
+ }
8573
+ }
8574
+ }
8575
+ updateSize(attrName, oldValue, newValue, attrValue) {
8576
+ const updateSizeStyle = (value) => {
8577
+ if (value !== null && value !== "" && value !== "default") {
8578
+ this.$el.style.setProperty(
8579
+ "--separator-size",
8580
+ `var(--px-size-border-${value})`
8581
+ );
8582
+ }
8583
+ };
8584
+ if (!this.checkName(attrValue, newValue)) {
8585
+ console.error(`${newValue} is not a valid value for ${attrName}`);
8586
+ } else {
8587
+ updateSizeStyle(oldValue);
8588
+ updateSizeStyle(newValue);
8589
+ }
8590
+ }
8591
+ updateColor(attrName, oldValue, newValue, attrValue) {
8592
+ const updateColorStyle = (value) => {
8593
+ if (value !== null && value !== "" && value !== "default") {
8594
+ this.$el.style.setProperty(
8595
+ `--separator-color-default`,
8596
+ `var(--px-color-border-${value}-default)`
8597
+ );
8598
+ this.$el.style.setProperty(
8599
+ `--separator-color-inverted`,
8600
+ `var(--px-color-border-${value}-inverted)`
8601
+ );
8602
+ }
8603
+ };
8604
+ if (!this.checkName(attrValue, newValue)) {
8605
+ console.error(`${newValue} is not a valid value for ${attrName}`);
8606
+ } else {
8607
+ updateColorStyle(oldValue);
8608
+ updateColorStyle(newValue);
8609
+ }
8610
+ }
8611
+ updateDirection(attrName, oldValue, newValue, attrValue) {
8612
+ const updateDirectionClass = (breakpoint, value) => {
8613
+ if (value !== null && value !== "" && value !== "default") {
8614
+ this.$el.classList.add(`separator-direction-${value}--${breakpoint}`);
8615
+ }
8616
+ };
8617
+ if (!this.checkName(attrValue, newValue)) {
8618
+ console.error(`${newValue} is not a valid value for ${attrName}`);
8619
+ } else {
8620
+ if (attrName === "direction") {
8621
+ ["mobile", "tablet", "laptop", "desktop"].forEach((breakpoint) => {
8622
+ const existingClass = Array.from(this.$el.classList).find(
8623
+ (className) => className.startsWith(`separator-direction-`) && className.endsWith(`--${breakpoint}`)
8624
+ );
8625
+ if (!existingClass) {
8626
+ updateDirectionClass(breakpoint, newValue);
8627
+ }
8628
+ });
8629
+ } else {
8630
+ const breakpoint = attrName.split("--")[1];
8631
+ const existingClass = Array.from(this.$el.classList).find(
8632
+ (className) => className.startsWith(`separator-direction-`) && className.endsWith(`--${breakpoint}`)
8633
+ );
8634
+ if (existingClass) {
8635
+ this.$el.classList.replace(
8636
+ existingClass,
8637
+ `separator-direction-${newValue}--${breakpoint}`
8638
+ );
8639
+ } else {
8640
+ updateDirectionClass(breakpoint, newValue);
8641
+ }
8642
+ }
8643
+ }
8644
+ }
8645
+ get direction() {
8646
+ return this.getAttribute("direction");
8647
+ }
8648
+ set direction(value) {
8649
+ this.setAttribute("direction", value);
8650
+ }
8651
+ get directionMobile() {
8652
+ return this.getAttribute("direction--mobile");
8653
+ }
8654
+ set directionMobile(value) {
8655
+ this.setAttribute("direction--mobile", value);
8656
+ }
8657
+ get directionTablet() {
8658
+ return this.getAttribute("direction--tablet");
8659
+ }
8660
+ set directionTablet(value) {
8661
+ this.setAttribute("direction--tablet", value);
8662
+ }
8663
+ get directionLaptop() {
8664
+ return this.getAttribute("direction--laptop");
8665
+ }
8666
+ set directionLaptop(value) {
8667
+ this.setAttribute("direction--laptop", value);
8668
+ }
8669
+ get directionDesktop() {
8670
+ return this.getAttribute("direction--desktop");
8671
+ }
8672
+ set directionDesktop(value) {
8673
+ this.setAttribute("direction--desktop", value);
8674
+ }
8675
+ get size() {
8676
+ return this.getAttribute("size");
8677
+ }
8678
+ set size(value) {
8679
+ this.setAttribute("size", value);
8680
+ }
8681
+ get color() {
8682
+ return this.getAttribute("color");
8683
+ }
8684
+ set color(value) {
8685
+ this.setAttribute("color", value);
8686
+ }
8687
+ get inverted() {
8688
+ return this.getAttribute("inverted");
8689
+ }
8690
+ set inverted(value) {
8691
+ this.setAttribute("inverted", value);
8692
+ }
8693
+ };
8694
+ _Separator.nativeName = "hr";
8695
+ let Separator = _Separator;
8696
+ if (!customElements.get("px-separator")) {
8697
+ customElements.define("px-separator", Separator);
8698
+ }
8699
+ const headingCss = "h1,.style-title-4xl,::slotted(h1),h2,.style-title-3xl,::slotted(h2),h3,.style-title-2xl,::slotted(h3),h4,.style-title-xl,::slotted(h4),h5,.style-title-l,::slotted(h5),h6,.style-title-m,::slotted(h6),.style-title-s,.style-subtitle{margin:0;font-family:var(--px-font-family);color:var(--heading-color-default, var(--px-color-text-brand-default));text-align:var(--heading-text-align--mobile, left);font-size:var(--px-text-size-heading-s-mobile);line-height:var(--px-line-height-ratio-l);font-weight:var(--px-font-weight-title)}::slotted(h1),::slotted(h2),::slotted(h3),::slotted(h4),::slotted(h5),::slotted(h6){margin-bottom:var(--px-spacing-heading-to-content-mobile)}:host([inverted]) h1,:host([inverted]) .style-title-4xl,:host([inverted]) ::slotted(h1),:host([inverted]) h2,:host([inverted]) .style-title-3xl,:host([inverted]) ::slotted(h2),:host([inverted]) h3,:host([inverted]) .style-title-2xl,:host([inverted]) ::slotted(h3),:host([inverted]) h4,:host([inverted]) .style-title-xl,:host([inverted]) ::slotted(h4),:host([inverted]) h5,:host([inverted]) .style-title-l,:host([inverted]) ::slotted(h5),:host([inverted]) h6,:host([inverted]) .style-title-m,:host([inverted]) ::slotted(h6),:host([inverted]) .style-title-s,:host([inverted]) .style-subtitle{color:var(--heading-color-inverted, var(--px-color-text-brand-inverted))}h1,.style-title-4xl,::slotted(h1){font-size:var(--px-text-size-heading-3xl-mobile);line-height:var(--px-line-height-ratio-s);font-weight:var(--px-font-weight-title-large)}h2,.style-title-3xl,::slotted(h2){font-size:var(--px-text-size-heading-2xl-mobile);line-height:var(--px-line-height-ratio-s);font-weight:var(--px-font-weight-title-large)}h3,.style-title-2xl,::slotted(h3){font-size:var(--px-text-size-heading-xl-mobile);line-height:var(--px-line-height-ratio-s)}h4,.style-title-xl,::slotted(h4){font-size:var(--px-text-size-heading-l-mobile)}h5,.style-title-l,::slotted(h5){font-size:var(--px-text-size-heading-m-mobile)}h6,.style-title-m,::slotted(h6){font-size:var(--px-text-size-heading-base-mobile)}.style-subtitle{font-size:var(--px-text-size-heading-l-mobile);font-weight:var(--px-font-weight-subtitle)}.style-title-s{font-size:var(--px-text-size-heading-s-mobile)}@media only screen and (min-width: 768px){::slotted(h1),::slotted(h2),::slotted(h3),::slotted(h4),::slotted(h5),::slotted(h6){margin-bottom:var(--px-spacing-heading-to-content-tablet)}h1,.style-title-4xl,::slotted(h1),h2,.style-title-3xl,::slotted(h2),h3,.style-title-2xl,::slotted(h3),h4,.style-title-xl,::slotted(h4),h5,.style-title-l,::slotted(h5),h6,.style-title-m,::slotted(h6),.style-title-s,.style-subtitle{text-align:var(--heading-text-align--tablet, left)}h1,.style-title-4xl,::slotted(h1){font-size:var(--px-text-size-heading-5xl-desktop)}h2,.style-title-3xl,::slotted(h2){font-size:var(--px-text-size-heading-4xl-desktop)}h3,.style-title-2xl,::slotted(h3){font-size:var(--px-text-size-heading-2xl-desktop)}h4,.style-title-xl,::slotted(h4){font-size:var(--px-text-size-heading-xl-desktop)}h5,.style-title-l,::slotted(h5){font-size:var(--px-text-size-heading-l-desktop)}h6,.style-title-m,::slotted(h6){font-size:var(--px-text-size-heading-m-desktop)}.style-title-s{font-size:var(--px-text-size-heading-base-desktop)}.style-subtitle{font-size:var(--px-text-size-heading-xl-desktop)}}@media only screen and (min-width: 1025px){::slotted(h1),::slotted(h2),::slotted(h3),::slotted(h4),::slotted(h5),::slotted(h6){margin-bottom:var(--px-spacing-heading-to-content-laptop)}h1,.style-title-4xl,::slotted(h1),h2,.style-title-3xl,::slotted(h2),h3,.style-title-2xl,::slotted(h3),h4,.style-title-xl,::slotted(h4),h5,.style-title-l,::slotted(h5),h6,.style-title-m,::slotted(h6),.style-title-s,.style-subtitle{text-align:var(--heading-text-align--laptop, left)}h1,.style-title-4xl,::slotted(h1){font-size:var(--px-text-size-heading-5xl-desktop)}h2,.style-title-3xl,::slotted(h2){font-size:var(--px-text-size-heading-4xl-desktop)}h3,.style-title-2xl,::slotted(h3){font-size:var(--px-text-size-heading-2xl-desktop)}h4,.style-title-xl,::slotted(h4){font-size:var(--px-text-size-heading-xl-desktop)}h5,.style-title-l,::slotted(h5){font-size:var(--px-text-size-heading-l-desktop)}h6,.style-title-m,::slotted(h6){font-size:var(--px-text-size-heading-m-desktop)}.style-title-s{font-size:var(--px-text-size-heading-base-desktop)}.style-subtitle{font-size:var(--px-text-size-heading-xl-desktop)}}@media screen and (min-width: 1441px){::slotted(h1),::slotted(h2),::slotted(h3),::slotted(h4),::slotted(h5),::slotted(h6){margin-bottom:var(--px-spacing-heading-to-content-desktop)}h1,.style-title-4xl,::slotted(h1),h2,.style-title-3xl,::slotted(h2),h3,.style-title-2xl,::slotted(h3),h4,.style-title-xl,::slotted(h4),h5,.style-title-l,::slotted(h5),h6,.style-title-m,::slotted(h6),.style-title-s,.style-subtitle{text-align:var(--heading-text-align--desktop, left)}}";
8700
+ const headingStyles$2 = new CSSStyleSheet();
8701
+ headingStyles$2.replaceSync(headingCss);
8702
+ const typographyStyles$4 = new CSSStyleSheet();
8703
+ typographyStyles$4.replaceSync(typographyCss$1);
8704
+ class AbstractHeading extends PxElement {
8705
+ template() {
8706
+ return `<slot></slot>`;
8707
+ }
8708
+ constructor(tagName) {
8709
+ super(headingStyles$2, typographyStyles$4);
8710
+ const $root = document.createElement(tagName);
8711
+ $root.innerHTML = this.template();
8712
+ this.shadowRoot.appendChild($root);
8713
+ }
8714
+ static get observedAttributes() {
8715
+ return [
8716
+ ...super.observedAttributes,
8717
+ "variant",
8718
+ "color",
8719
+ "text-align",
8720
+ "text-align--mobile",
8721
+ "text-align--tablet",
8722
+ "text-align--laptop",
8723
+ "text-align--desktop",
8724
+ "inverted"
8725
+ ];
8726
+ }
8727
+ attributeChangedCallback(attrName, oldValue, newValue) {
8728
+ if (oldValue !== newValue) {
8729
+ switch (attrName) {
8730
+ case "variant":
8731
+ this.updateAttribute(attrName, oldValue, newValue, headingValues);
8732
+ break;
8733
+ case "color":
8734
+ this.updateColor(oldValue, newValue, colorValues);
8735
+ break;
8736
+ case "text-align":
8737
+ case "text-align--mobile":
8738
+ case "text-align--tablet":
8739
+ case "text-align--laptop":
8740
+ case "text-align--desktop":
8741
+ this.updateTextAlign(attrName, oldValue, newValue, textalignValues);
8742
+ break;
8743
+ default:
8744
+ super.attributeChangedCallback(attrName, oldValue, newValue);
8745
+ break;
8746
+ }
8747
+ }
8748
+ }
8749
+ toggleClass(oldValue, newValue) {
8750
+ if (oldValue !== null && oldValue !== "" && oldValue !== "default") {
8751
+ this.$el.classList.toggle(`style-${oldValue}`);
8752
+ }
8753
+ if (newValue !== null && newValue !== "" && newValue !== "default") {
8754
+ this.$el.classList.toggle(`style-${newValue}`);
8755
+ }
8756
+ }
8757
+ updateAttribute(attrName, oldValue, newValue, attrValue) {
8758
+ if (!this.checkName(attrValue, newValue)) {
8759
+ console.error(`${newValue} is not an allowed "${attrName}" value`);
8760
+ } else {
8761
+ this.toggleClass(oldValue, newValue);
8762
+ }
8763
+ }
8764
+ updateColor(oldValue, newValue, attrValue) {
8429
8765
  if (!this.checkName(attrValue, newValue)) {
8430
8766
  console.error(`${newValue} is not a valid color value`);
8431
8767
  return;
@@ -8578,9 +8914,9 @@ let H6 = _H6;
8578
8914
  if (!customElements.get("px-h6")) {
8579
8915
  customElements.define("px-h6", H6);
8580
8916
  }
8581
- const styles$v = '#container{border:0;border-radius:var(--px-radius-main);background-color:var(--px-color-background-surface-default);box-sizing:border-box}:host([showfrom="bottom"]) #container{height:auto;margin-bottom:0;width:100%}px-button-icon{position:absolute;top:var(--px-padding-l-desktop);right:var(--px-padding-l-desktop)}dialog{background:transparent;border-radius:0;box-shadow:none;padding:0;border:0;box-sizing:border-box;width:75%}::backdrop{background:#0000004d;-webkit-backdrop-filter:saturate(180%) blur(15px);backdrop-filter:saturate(180%) blur(15px)}#content{overflow:auto}@media screen and (min-width: 1080px){#container{height:100%;padding:var(--px-padding-l-desktop)}:host([showfrom="right"]) px-button-icon{right:10.625em}:host([showfrom="right"]) #container{padding-right:10.625em;border-radius:var(--px-radius-main) 0 0 var(--px-radius-main)}:host([showfrom="left"]) px-button-icon{right:var(--px-padding-l-desktop)}:host([showfrom="left"]) #container{padding-left:10.625em;border-radius:0 var(--px-radius-main) var(--px-radius-main) 0}:host([showfrom="bottom"]) #container{box-sizing:border-box}:host([showfrom="left"])>dialog{margin-left:0;animation:dialog-fade-in-left .3s;height:100%}:host([showfrom="bottom"])>dialog{margin-bottom:0;margin-inline:0;width:100%;animation:dialog-fade-in-bottom .3s}:host([showfrom="right"])>dialog{margin-right:0;animation:dialog-fade-in-right .3s;height:100%}#content{max-height:calc(100dvh - 22.625em)}}@media only screen and (max-width: 67.563em){dialog{width:100%}:host([showfrom="left"])>dialog,:host([showfrom="right"])>dialog,:host([showfrom="bottom"])>dialog{margin-bottom:0;margin-inline:0;height:revert;animation:dialog-fade-in-bottom .3s}#container{width:100%;box-sizing:border-box;padding:var(--px-padding-m-mobile);border-radius:var(--px-radius-main) var(--px-radius-main) 0 0}px-button-icon{top:var(--px-padding-m-mobile);right:var(--px-padding-m-mobile)}#content{min-height:2.813em;max-height:50dvh}}@keyframes dialog-fade-in-right{0%{margin-right:-67.5em}to{margin-right:0}}@keyframes dialog-fade-in-left{0%{margin-left:-67.5em}to{margin-left:0}}@keyframes dialog-fade-in-bottom{0%{margin-bottom:-12.5em}to{margin-bottom:0}}';
8582
- const styleSheet$p = new CSSStyleSheet();
8583
- styleSheet$p.replaceSync(styles$v);
8917
+ const styles$u = '#container{border:0;border-radius:var(--px-radius-main);background-color:var(--px-color-background-surface-default);box-sizing:border-box}:host([showfrom="bottom"]) #container{height:auto;margin-bottom:0;width:100%}px-button-icon{position:absolute;top:var(--px-padding-l-desktop);right:var(--px-padding-l-desktop)}dialog{background:transparent;border-radius:0;box-shadow:none;padding:0;border:0;box-sizing:border-box;width:75%}::backdrop{background:#0000004d;-webkit-backdrop-filter:saturate(180%) blur(15px);backdrop-filter:saturate(180%) blur(15px)}#content{overflow:auto}@media screen and (min-width: 1080px){#container{height:100%;padding:var(--px-padding-l-desktop)}:host([showfrom="right"]) px-button-icon{right:10.625em}:host([showfrom="right"]) #container{padding-right:10.625em;border-radius:var(--px-radius-main) 0 0 var(--px-radius-main)}:host([showfrom="left"]) px-button-icon{right:var(--px-padding-l-desktop)}:host([showfrom="left"]) #container{padding-left:10.625em;border-radius:0 var(--px-radius-main) var(--px-radius-main) 0}:host([showfrom="bottom"]) #container{box-sizing:border-box}:host([showfrom="left"])>dialog{margin-left:0;animation:dialog-fade-in-left .3s;height:100%}:host([showfrom="bottom"])>dialog{margin-bottom:0;margin-inline:0;width:100%;animation:dialog-fade-in-bottom .3s}:host([showfrom="right"])>dialog{margin-right:0;animation:dialog-fade-in-right .3s;height:100%}#content{max-height:calc(100dvh - 22.625em)}}@media only screen and (max-width: 67.563em){dialog{width:100%}:host([showfrom="left"])>dialog,:host([showfrom="right"])>dialog,:host([showfrom="bottom"])>dialog{margin-bottom:0;margin-inline:0;height:revert;animation:dialog-fade-in-bottom .3s}#container{width:100%;box-sizing:border-box;padding:var(--px-padding-m-mobile);border-radius:var(--px-radius-main) var(--px-radius-main) 0 0}px-button-icon{top:var(--px-padding-m-mobile);right:var(--px-padding-m-mobile)}#content{min-height:2.813em;max-height:50dvh}}@keyframes dialog-fade-in-right{0%{margin-right:-67.5em}to{margin-right:0}}@keyframes dialog-fade-in-left{0%{margin-left:-67.5em}to{margin-left:0}}@keyframes dialog-fade-in-bottom{0%{margin-bottom:-12.5em}to{margin-bottom:0}}';
8918
+ const styleSheet$o = new CSSStyleSheet();
8919
+ styleSheet$o.replaceSync(styles$u);
8584
8920
  const HIDE_EVENT = "px.lavender.drawer.hide";
8585
8921
  class Drawer extends HTMLElement {
8586
8922
  constructor() {
@@ -8618,7 +8954,7 @@ class Drawer extends HTMLElement {
8618
8954
  </dialog>`;
8619
8955
  this.attachShadow({ mode: "open" });
8620
8956
  this.shadowRoot.innerHTML = this.template;
8621
- this.shadowRoot.adoptedStyleSheets = [styleSheet$p];
8957
+ this.shadowRoot.adoptedStyleSheets = [styleSheet$o];
8622
8958
  if (!this.hasAttribute("showfrom")) {
8623
8959
  this.setAttribute("showfrom", "bottom");
8624
8960
  }
@@ -8716,7 +9052,7 @@ class Drawer extends HTMLElement {
8716
9052
  if (!customElements.get("px-drawer")) {
8717
9053
  customElements.define("px-drawer", Drawer);
8718
9054
  }
8719
- const styles$u = ':host{position:relative}::slotted([slot="popover"]){position:absolute;border-radius:var(--px-radius-main, 8px);background:var(--px-color-background-container-light-default, #fff);box-shadow:0 20px 25px -5px #25252514;margin:0;padding:var(--px-padding-xs-mobile) 0;border:0;right:0;width:auto}:host([grow]) ::slotted([slot="trigger"]):after{right:0;padding-right:var(--px-padding-xs-mobile)}:host([anchoralignment="top-left"]) ::slotted([slot="popover"]){top:auto}:host([anchoralignment="top-right"]) ::slotted([slot="popover"]){top:auto}:host([anchoralignment="bottom-right"]) ::slotted([slot="popover"]){left:auto}@media screen and (max-width: 767px){::slotted([slot="trigger"]){display:block;width:100%}:host([anchoralignment="top-left"]) ::slotted([slot="popover"]){left:var(--px-padding-s-mobile)}:host([anchoralignment="top-right"]) ::slotted([slot="popover"]){left:var(--px-padding-s-mobile)}}@media screen and (min-width: 768px){::slotted([slot="popover"]){padding-block:var(--px-padding-s-desktop);right:auto;width:auto}}';
9055
+ const styles$t = ':host{position:relative}::slotted([slot="popover"]){position:absolute;border-radius:var(--px-radius-main, 8px);background:var(--px-color-background-container-light-default, #fff);box-shadow:0 20px 25px -5px #25252514;margin:0;padding:var(--px-padding-xs-mobile) 0;border:0;right:0;width:auto}:host([grow]) ::slotted([slot="trigger"]):after{right:0;padding-right:var(--px-padding-xs-mobile)}:host([anchoralignment="top-left"]) ::slotted([slot="popover"]){top:auto}:host([anchoralignment="top-right"]) ::slotted([slot="popover"]){top:auto}:host([anchoralignment="bottom-right"]) ::slotted([slot="popover"]){left:auto}@media screen and (max-width: 767px){::slotted([slot="trigger"]){display:block;width:100%}:host([anchoralignment="top-left"]) ::slotted([slot="popover"]){left:var(--px-padding-s-mobile)}:host([anchoralignment="top-right"]) ::slotted([slot="popover"]){left:var(--px-padding-s-mobile)}}@media screen and (min-width: 768px){::slotted([slot="popover"]){padding-block:var(--px-padding-s-desktop);right:auto;width:auto}}';
8720
9056
  const anchorAlignmentValues = [
8721
9057
  "top-left",
8722
9058
  "top-right",
@@ -8758,7 +9094,7 @@ function anchorPolyfill($trigger, $popoverElement, anchorAlignment = "bottom-lef
8758
9094
  });
8759
9095
  }
8760
9096
  const stylesheet$8 = new CSSStyleSheet();
8761
- stylesheet$8.replaceSync(styles$u);
9097
+ stylesheet$8.replaceSync(styles$t);
8762
9098
  const defaultAnchorAlignment = "bottom-left";
8763
9099
  class Dropdown extends WithExtraAttributes {
8764
9100
  constructor() {
@@ -9616,248 +9952,40 @@ const _Link = class _Link extends PxElement {
9616
9952
  this.$el.setAttribute(attrName, newValue);
9617
9953
  }
9618
9954
  }
9619
- updateTypography(attrName, oldValue, newValue, attrValue) {
9620
- if (oldValue !== null && oldValue !== "" && oldValue !== "default") {
9621
- this.$el.classList.toggle(`${attrName}-${oldValue}`);
9622
- }
9623
- if (newValue !== null && newValue !== "" && newValue !== "default") {
9624
- this.$el.classList.toggle(`${attrName}-${newValue}`);
9625
- }
9626
- if (!this.checkName(attrValue, newValue)) {
9627
- console.error(`Bad ${attrName} value: ${newValue}`);
9628
- }
9629
- }
9630
- updateExtended(attributeName, newValue) {
9631
- if (newValue === null) {
9632
- this.$el.style.setProperty(`--button-${attributeName}`, "");
9633
- } else {
9634
- this.$el.style.setProperty(`--button-${attributeName}`, "100%");
9635
- }
9636
- }
9637
- get $before() {
9638
- return this.querySelector('[slot="before"]');
9639
- }
9640
- get $after() {
9641
- return this.querySelector('[slot="after"]');
9642
- }
9643
- get $iconNotBeforeAfter() {
9644
- return this.querySelector(
9645
- 'px-icon:not([slot="before"], [slot="after"])'
9646
- );
9647
- }
9648
- get disabled() {
9649
- return this.getAttribute("disabled");
9650
- }
9651
- set disabled(value) {
9652
- this.setAttribute("disabled", value);
9653
- }
9654
- get variant() {
9655
- return this.getAttribute("variant");
9656
- }
9657
- set variant(value) {
9658
- this.setAttribute("variant", value);
9659
- }
9660
- get shape() {
9661
- return this.getAttribute("shape");
9662
- }
9663
- set shape(value) {
9664
- this.setAttribute("shape", value);
9665
- }
9666
- get shapeMobile() {
9667
- return this.getAttribute("shape--mobile");
9668
- }
9669
- set shapeMobile(value) {
9670
- this.setAttribute("shape--mobile", value);
9671
- }
9672
- get shapeTablet() {
9673
- return this.getAttribute("shape--tablet");
9674
- }
9675
- set shapeTablet(value) {
9676
- this.setAttribute("shape--tablet", value);
9677
- }
9678
- get shapeLaptop() {
9679
- return this.getAttribute("shape--laptop");
9680
- }
9681
- set shapeLaptop(value) {
9682
- this.setAttribute("shape--laptop", value);
9683
- }
9684
- get shapeDesktop() {
9685
- return this.getAttribute("shape--desktop");
9686
- }
9687
- set shapeDesktop(value) {
9688
- this.setAttribute("shape--desktop", value);
9689
- }
9690
- get extended() {
9691
- return this.getAttribute("extended");
9692
- }
9693
- set extended(value) {
9694
- this.setAttribute("extended", value);
9695
- }
9696
- get extendedMobile() {
9697
- return this.getAttribute("extended--mobile");
9698
- }
9699
- set extendedMobile(value) {
9700
- this.setAttribute("extended--mobile", value);
9701
- }
9702
- get extendedTablet() {
9703
- return this.getAttribute("extended--tablet");
9704
- }
9705
- set extendedTablet(value) {
9706
- this.setAttribute("extended--tablet", value);
9707
- }
9708
- get extendedLaptop() {
9709
- return this.getAttribute("extended--laptop");
9710
- }
9711
- set extendedLaptop(value) {
9712
- this.setAttribute("extended--laptop", value);
9713
- }
9714
- get extendedDesktop() {
9715
- return this.getAttribute("extended--desktop");
9716
- }
9717
- set extendedDesktop(value) {
9718
- this.setAttribute("extended--desktop", value);
9719
- }
9720
- get inverted() {
9721
- return this.getAttribute("inverted");
9722
- }
9723
- set inverted(value) {
9724
- this.setAttribute("inverted", value);
9725
- }
9726
- get fontsize() {
9727
- return this.getAttribute("font-size");
9728
- }
9729
- set fontsize(value) {
9730
- this.setAttribute("font-size", value);
9731
- }
9732
- get color() {
9733
- return this.getAttribute("color");
9734
- }
9735
- set color(value) {
9736
- this.setAttribute("color", value);
9737
- }
9738
- get fontweight() {
9739
- return this.getAttribute("font-weight");
9740
- }
9741
- set fontweight(value) {
9742
- this.setAttribute("font-weight", value);
9743
- }
9744
- get title() {
9745
- return this.getAttribute("title");
9746
- }
9747
- set title(value) {
9748
- if (value) {
9749
- this.setAttribute("title", value);
9750
- } else {
9751
- this.removeAttribute("title");
9752
- }
9753
- }
9754
- };
9755
- _Link.nativeName = "a";
9756
- let Link = _Link;
9757
- if (!customElements.get("px-a")) {
9758
- customElements.define("px-a", Link);
9759
- }
9760
- const paragraphCss = "p,::slotted(p){font-family:var(--px-font-family);color:var(--px-color-text-neutral-default);font-size:var(--px-text-size-body-m-mobile);font-weight:var(--px-font-weight-body);line-height:var(--px-line-height-ratio-l);margin:0}.text-align-left{text-align:left}.text-align-center{text-align:center}.text-align-right{text-align:right}:host([inverted]) p,:host([inverted]) ::slotted(p){color:var(--px-color-text-neutral-inverted)}@media only screen and (max-width: 768px){.text-align-left--mobile{text-align:left}.text-align-center--mobile{text-align:center}.text-align-right--mobile{text-align:right}}@media only screen and (min-width: 768px){p,::slotted(p){font-size:var(--px-text-size-body-m-desktop)}.text-align-left--tablet{text-align:left}.text-align-center--tablet{text-align:center}.text-align-right--tablet{text-align:right}}@media only screen and (min-width: 1025px){p,::slotted(p){font-size:var(--px-text-size-body-m-desktop)}.text-align-left--laptop{text-align:left}.text-align-center--laptop{text-align:center}.text-align-right--laptop{text-align:right}}";
9761
- const paragraphStyles$1 = new CSSStyleSheet();
9762
- const typographyStyles$2 = new CSSStyleSheet();
9763
- const headingStyles$1 = new CSSStyleSheet();
9764
- paragraphStyles$1.replaceSync(paragraphCss);
9765
- typographyStyles$2.replaceSync(typographyCss$1);
9766
- headingStyles$1.replaceSync(headingCss);
9767
- const _Paragraph = class _Paragraph extends PxElement {
9768
- constructor() {
9769
- super(typographyStyles$2, headingStyles$1, paragraphStyles$1);
9770
- this.template = () => `<p><slot></slot></p>`;
9771
- this.shadowRoot.innerHTML = this.template();
9772
- }
9773
- static get observedAttributes() {
9774
- return [
9775
- ...super.observedAttributes,
9776
- "variant",
9777
- "color",
9778
- "font-size",
9779
- "font-weight",
9780
- "text-align",
9781
- "text-align--mobile",
9782
- "text-align--tablet",
9783
- "text-align--laptop",
9784
- "inverted",
9785
- "disabled"
9786
- ];
9787
- }
9788
- attributeChangedCallback(attrName, oldValue, newValue) {
9789
- if (oldValue !== newValue) {
9790
- switch (attrName) {
9791
- case "variant":
9792
- this.updateVariant(attrName, oldValue, newValue, headingValues);
9793
- break;
9794
- case "color":
9795
- this.updateTypography(attrName, oldValue, newValue, colorValues);
9796
- break;
9797
- case "font-size":
9798
- this.updateTypography(attrName, oldValue, newValue, fontsizeValues);
9799
- break;
9800
- case "font-weight":
9801
- this.updateTypography(attrName, oldValue, newValue, fontweightValues);
9802
- break;
9803
- case "text-align":
9804
- case "text-align--mobile":
9805
- case "text-align--tablet":
9806
- case "text-align--laptop":
9807
- this.updateTypography(attrName, oldValue, newValue, textalignValues);
9808
- break;
9809
- case "disabled":
9810
- this.color = "state-disabled";
9811
- break;
9812
- default:
9813
- super.attributeChangedCallback(attrName, oldValue, newValue);
9814
- break;
9815
- }
9816
- }
9817
- }
9818
- toggleClass(oldValue, newValue) {
9819
- if (oldValue !== null && oldValue !== "" && oldValue !== "default") {
9820
- this.$el.classList.toggle(`style-${oldValue}`);
9821
- }
9822
- if (newValue !== null && newValue !== "" && newValue !== "default") {
9823
- this.$el.classList.toggle(`style-${newValue}`);
9824
- }
9825
- }
9826
- updateVariant(attrName, oldValue, newValue, attrValue) {
9827
- if (!this.checkName(attrValue, newValue)) {
9828
- console.error(`${newValue} is not a valid value for ${attrName}`);
9829
- } else {
9830
- this.toggleClass(oldValue, newValue);
9831
- }
9832
- }
9833
- updateTypography(attrName, oldValue, newValue, attrValue) {
9834
- if (!this.checkName(attrValue, newValue)) {
9835
- console.error(`${newValue} is not an allowed ${attrName} value`);
9836
- } else {
9837
- const splitResult = this.splitAttrNameFromBreakpoint(attrName);
9838
- const breakpoint = splitResult.breakpoint;
9839
- if (oldValue !== null && oldValue !== "") {
9840
- this.$el.classList.toggle(
9841
- `${splitResult.attrName}-${oldValue}${breakpoint}`
9842
- );
9843
- }
9844
- if (newValue !== null && newValue !== "") {
9845
- this.$el.classList.toggle(
9846
- `${splitResult.attrName}-${newValue}${breakpoint}`
9847
- );
9848
- }
9849
- }
9850
- }
9851
- splitAttrNameFromBreakpoint(attrName) {
9852
- let breakpoint = "";
9853
- if (["--mobile", "--tablet", "--laptop"].some(
9854
- (suffix) => attrName.includes(suffix)
9855
- )) {
9856
- const attrNameSplit = attrName.split("--");
9857
- attrName = attrNameSplit[0];
9858
- breakpoint = `--${attrNameSplit[1]}`;
9955
+ updateTypography(attrName, oldValue, newValue, attrValue) {
9956
+ if (oldValue !== null && oldValue !== "" && oldValue !== "default") {
9957
+ this.$el.classList.toggle(`${attrName}-${oldValue}`);
9859
9958
  }
9860
- return { attrName, breakpoint };
9959
+ if (newValue !== null && newValue !== "" && newValue !== "default") {
9960
+ this.$el.classList.toggle(`${attrName}-${newValue}`);
9961
+ }
9962
+ if (!this.checkName(attrValue, newValue)) {
9963
+ console.error(`Bad ${attrName} value: ${newValue}`);
9964
+ }
9965
+ }
9966
+ updateExtended(attributeName, newValue) {
9967
+ if (newValue === null) {
9968
+ this.$el.style.setProperty(`--button-${attributeName}`, "");
9969
+ } else {
9970
+ this.$el.style.setProperty(`--button-${attributeName}`, "100%");
9971
+ }
9972
+ }
9973
+ get $before() {
9974
+ return this.querySelector('[slot="before"]');
9975
+ }
9976
+ get $after() {
9977
+ return this.querySelector('[slot="after"]');
9978
+ }
9979
+ get $iconNotBeforeAfter() {
9980
+ return this.querySelector(
9981
+ 'px-icon:not([slot="before"], [slot="after"])'
9982
+ );
9983
+ }
9984
+ get disabled() {
9985
+ return this.getAttribute("disabled");
9986
+ }
9987
+ set disabled(value) {
9988
+ this.setAttribute("disabled", value);
9861
9989
  }
9862
9990
  get variant() {
9863
9991
  return this.getAttribute("variant");
@@ -9865,515 +9993,419 @@ const _Paragraph = class _Paragraph extends PxElement {
9865
9993
  set variant(value) {
9866
9994
  this.setAttribute("variant", value);
9867
9995
  }
9868
- get color() {
9869
- return this.getAttribute("color");
9870
- }
9871
- set color(value) {
9872
- this.setAttribute("color", value);
9873
- }
9874
- get fontSize() {
9875
- return this.getAttribute("font-size");
9996
+ get shape() {
9997
+ return this.getAttribute("shape");
9876
9998
  }
9877
- set fontSize(value) {
9878
- this.setAttribute("font-size", value);
9999
+ set shape(value) {
10000
+ this.setAttribute("shape", value);
9879
10001
  }
9880
- get fontWeight() {
9881
- return this.getAttribute("font-weight");
10002
+ get shapeMobile() {
10003
+ return this.getAttribute("shape--mobile");
9882
10004
  }
9883
- set fontWeight(value) {
9884
- this.setAttribute("font-weight", value);
10005
+ set shapeMobile(value) {
10006
+ this.setAttribute("shape--mobile", value);
9885
10007
  }
9886
- get textAlign() {
9887
- return this.getAttribute("text-align");
10008
+ get shapeTablet() {
10009
+ return this.getAttribute("shape--tablet");
9888
10010
  }
9889
- set textAlign(value) {
9890
- this.setAttribute("text-align", value);
10011
+ set shapeTablet(value) {
10012
+ this.setAttribute("shape--tablet", value);
9891
10013
  }
9892
- get textAlignMobile() {
9893
- return this.getAttribute("text-align--mobile");
10014
+ get shapeLaptop() {
10015
+ return this.getAttribute("shape--laptop");
9894
10016
  }
9895
- set textAlignMobile(value) {
9896
- this.setAttribute("text-align--mobile", value);
10017
+ set shapeLaptop(value) {
10018
+ this.setAttribute("shape--laptop", value);
9897
10019
  }
9898
- get textAlignTablet() {
9899
- return this.getAttribute("text-align--tablet");
10020
+ get shapeDesktop() {
10021
+ return this.getAttribute("shape--desktop");
9900
10022
  }
9901
- set textAlignTablet(value) {
9902
- this.setAttribute("text-align--tablet", value);
10023
+ set shapeDesktop(value) {
10024
+ this.setAttribute("shape--desktop", value);
9903
10025
  }
9904
- get textAlignLaptop() {
9905
- return this.getAttribute("text-align--laptop");
10026
+ get extended() {
10027
+ return this.getAttribute("extended");
9906
10028
  }
9907
- set textAlignLaptop(value) {
9908
- this.setAttribute("text-align--laptop", value);
10029
+ set extended(value) {
10030
+ this.setAttribute("extended", value);
9909
10031
  }
9910
- get inverted() {
9911
- return this.getAttribute("inverted");
10032
+ get extendedMobile() {
10033
+ return this.getAttribute("extended--mobile");
9912
10034
  }
9913
- set inverted(value) {
9914
- this.setAttribute("inverted", value);
10035
+ set extendedMobile(value) {
10036
+ this.setAttribute("extended--mobile", value);
9915
10037
  }
9916
- get disabled() {
9917
- return this.getAttribute("disabled");
10038
+ get extendedTablet() {
10039
+ return this.getAttribute("extended--tablet");
9918
10040
  }
9919
- set disabled(value) {
9920
- this.setAttribute("disabled", value);
10041
+ set extendedTablet(value) {
10042
+ this.setAttribute("extended--tablet", value);
9921
10043
  }
9922
- };
9923
- _Paragraph.nativeName = "p";
9924
- let Paragraph = _Paragraph;
9925
- if (!customElements.get("px-p")) {
9926
- customElements.define("px-p", Paragraph);
9927
- }
9928
- const _FooterSitemap = class _FooterSitemap extends PxElement {
9929
- constructor() {
9930
- super();
9931
- this.template = () => `<div class="footer-sitemap">
9932
- <px-grid grid-cols="4" grid-cols--mobile="1" role="list" gap--mobile="none">
9933
- <slot></slot>
9934
- </px-grid>
9935
- </div>`;
9936
- this.shadowRoot.innerHTML = this.template();
10044
+ get extendedLaptop() {
10045
+ return this.getAttribute("extended--laptop");
9937
10046
  }
9938
- static get observedAttributes() {
9939
- return [...super.observedAttributes, "inverted"];
10047
+ set extendedLaptop(value) {
10048
+ this.setAttribute("extended--laptop", value);
9940
10049
  }
9941
- attributeChangedCallback(attrName, oldValue, newValue) {
9942
- if (oldValue !== newValue) {
9943
- switch (attrName) {
9944
- case "inverted":
9945
- for (let i = 0; i < this.$children.length; i++) {
9946
- if (!this.$children[i].hasAttribute("inverted")) {
9947
- this.$children[i].toggleAttribute("inverted");
9948
- }
9949
- }
9950
- break;
9951
- default:
9952
- super.attributeChangedCallback(attrName, oldValue, newValue);
9953
- break;
9954
- }
9955
- }
10050
+ get extendedDesktop() {
10051
+ return this.getAttribute("extended--desktop");
9956
10052
  }
9957
- get $children() {
9958
- return this.querySelectorAll("px-footer-sitemap > *");
10053
+ set extendedDesktop(value) {
10054
+ this.setAttribute("extended--desktop", value);
9959
10055
  }
9960
10056
  get inverted() {
9961
- return this.hasAttribute("inverted");
10057
+ return this.getAttribute("inverted");
9962
10058
  }
9963
10059
  set inverted(value) {
9964
- if (value) {
9965
- this.setAttribute("inverted", "");
9966
- } else {
9967
- this.removeAttribute("inverted");
9968
- }
9969
- }
9970
- };
9971
- _FooterSitemap.nativeName = "div";
9972
- let FooterSitemap = _FooterSitemap;
9973
- if (!customElements.get("px-footer-sitemap")) {
9974
- customElements.define("px-footer-sitemap", FooterSitemap);
9975
- }
9976
- const styles$t = ":host,:host>*{display:block;box-sizing:border-box}::slotted(ul){margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:10px}::slotted(ul.link-list-img){display:flex;flex-wrap:wrap;flex-direction:row;gap:20px}";
9977
- const styleSheet$o = new CSSStyleSheet();
9978
- styleSheet$o.replaceSync(styles$t);
9979
- const _FooterSitemapItem = class _FooterSitemapItem extends PxElement {
9980
- constructor() {
9981
- super(styleSheet$o);
9982
- this.templateMobile = () => `<div role="listitem">
9983
- <px-accordion ${this.inverted ? "inverted" : ""}>
9984
- <span slot="title"><slot name="links-list-title"></slot></span>
9985
- <span slot="content">
9986
- <slot name="links-list"></slot>
9987
- </span>
9988
- </px-accordion>
9989
- </div>`;
9990
- this.templateDesktop = () => `<div role="listitem">
9991
- <px-vstack gap="default">
9992
- <px-p variant="title-l" ${this.inverted ? "inverted" : ""}>
9993
- <slot name="links-list-title"></slot>
9994
- </px-p>
9995
- <slot name="links-list"></slot>
9996
- </px-vstack>
9997
- </div>`;
9998
- this.throttledLoadTemplate = throttle(this.loadTemplate.bind(this), 50);
9999
- this.loadTemplate();
10000
- }
10001
- static get observedAttributes() {
10002
- return [...super.observedAttributes, "inverted"];
10003
- }
10004
- connectedCallback() {
10005
- super.connectedCallback();
10006
- this.loadTemplate();
10007
- window.addEventListener("resize", this.throttledLoadTemplate);
10008
- if (!this.$ul) {
10009
- console.error(
10010
- "The footer sitemap item must contain a <ul> element with links."
10011
- );
10012
- } else {
10013
- if (this.$ul.querySelector("px-img")) {
10014
- this.$ul.classList.add("link-list-img");
10015
- }
10016
- }
10060
+ this.setAttribute("inverted", value);
10017
10061
  }
10018
- disconnectedCallback() {
10019
- window.removeEventListener("resize", this.throttledLoadTemplate);
10062
+ get fontsize() {
10063
+ return this.getAttribute("font-size");
10020
10064
  }
10021
- loadTemplate() {
10022
- const previousSize = this.lastSize;
10023
- const currentSize = window.innerWidth < 768 ? "mobile" : "desktop";
10024
- if (previousSize !== currentSize) {
10025
- if (currentSize === "mobile") {
10026
- this.shadowRoot.innerHTML = this.templateMobile();
10027
- } else {
10028
- this.shadowRoot.innerHTML = this.templateDesktop();
10029
- }
10030
- this.lastSize = currentSize;
10031
- }
10065
+ set fontsize(value) {
10066
+ this.setAttribute("font-size", value);
10032
10067
  }
10033
- attributeChangedCallback(attrName, oldValue, newValue) {
10034
- if (oldValue !== newValue) {
10035
- switch (attrName) {
10036
- case "inverted":
10037
- for (let i = 0; i < this.$children.length; i++) {
10038
- if (!this.$children[i].hasAttribute("inverted")) {
10039
- this.$children[i].toggleAttribute("inverted");
10040
- }
10041
- }
10042
- this.$ul.querySelectorAll("px-a").forEach((link) => {
10043
- link.toggleAttribute("inverted");
10044
- });
10045
- break;
10046
- default:
10047
- super.attributeChangedCallback(attrName, oldValue, newValue);
10048
- break;
10049
- }
10050
- }
10068
+ get color() {
10069
+ return this.getAttribute("color");
10051
10070
  }
10052
- get $ul() {
10053
- return this.querySelector("ul");
10071
+ set color(value) {
10072
+ this.setAttribute("color", value);
10054
10073
  }
10055
- get $children() {
10056
- return this.querySelectorAll("px-footer-sitemap-item > *");
10074
+ get fontweight() {
10075
+ return this.getAttribute("font-weight");
10057
10076
  }
10058
- get inverted() {
10059
- return this.hasAttribute("inverted");
10077
+ set fontweight(value) {
10078
+ this.setAttribute("font-weight", value);
10060
10079
  }
10061
- set inverted(value) {
10080
+ get title() {
10081
+ return this.getAttribute("title");
10082
+ }
10083
+ set title(value) {
10062
10084
  if (value) {
10063
- this.setAttribute("inverted", "");
10085
+ this.setAttribute("title", value);
10064
10086
  } else {
10065
- this.removeAttribute("inverted");
10087
+ this.removeAttribute("title");
10066
10088
  }
10067
10089
  }
10068
10090
  };
10069
- _FooterSitemapItem.nativeName = "div";
10070
- let FooterSitemapItem = _FooterSitemapItem;
10071
- if (!customElements.get("px-footer-sitemap-item")) {
10072
- customElements.define("px-footer-sitemap-item", FooterSitemapItem);
10091
+ _Link.nativeName = "a";
10092
+ let Link = _Link;
10093
+ if (!customElements.get("px-a")) {
10094
+ customElements.define("px-a", Link);
10073
10095
  }
10074
- const styles$s = ':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 only screen and (min-width: 77em){.content-wrapper{margin-inline:auto}}.overlapped{margin-bottom:calc(var(--px-overlapped-mobile) * -1)}::slotted([slot="overlap"]){margin-top:var(--px-overlapped-mobile)}@media only screen and (min-width: 48em){.overlapped{margin-bottom:calc(var(--px-overlapped-desktop) * -1)}::slotted([slot="overlap"]){margin-top:var(--px-overlapped-desktop)}}@media only screen and (min-width: 64.0625em){.overlapped{margin-bottom:calc(var(--px-overlapped-desktop) * -1)}::slotted([slot="overlap"]){margin-top:var(--px-overlapped-desktop)}}';
10075
- const styleSheet$n = new CSSStyleSheet();
10076
- styleSheet$n.replaceSync(styles$s);
10077
- class Section extends HTMLElement {
10096
+ const paragraphCss = "p,::slotted(p){font-family:var(--px-font-family);color:var(--px-color-text-neutral-default);font-size:var(--px-text-size-body-m-mobile);font-weight:var(--px-font-weight-body);line-height:var(--px-line-height-ratio-l);margin:0}::slotted(p){margin-bottom:var(--px-spacing-xs-mobile)}.text-align-left{text-align:left}.text-align-center{text-align:center}.text-align-right{text-align:right}:host([inverted]) p,:host([inverted]) ::slotted(p){color:var(--px-color-text-neutral-inverted)}@media only screen and (max-width: 768px){.text-align-left--mobile{text-align:left}.text-align-center--mobile{text-align:center}.text-align-right--mobile{text-align:right}}@media only screen and (min-width: 768px){p,::slotted(p){font-size:var(--px-text-size-body-m-desktop)}::slotted(p){margin-bottom:var(--px-spacing-xs-tablet)}.text-align-left--tablet{text-align:left}.text-align-center--tablet{text-align:center}.text-align-right--tablet{text-align:right}}@media only screen and (min-width: 1025px){p,::slotted(p){font-size:var(--px-text-size-body-m-desktop)}::slotted(p){margin-bottom:var(--px-spacing-xs-laptop)}.text-align-left--laptop{text-align:left}.text-align-center--laptop{text-align:center}.text-align-right--laptop{text-align:right}}@media only screen and (min-width: 90.0625em){::slotted(p){margin-bottom:var(--px-spacing-xs-desktop)}}";
10097
+ const paragraphStyles$1 = new CSSStyleSheet();
10098
+ const typographyStyles$2 = new CSSStyleSheet();
10099
+ const headingStyles$1 = new CSSStyleSheet();
10100
+ paragraphStyles$1.replaceSync(paragraphCss);
10101
+ typographyStyles$2.replaceSync(typographyCss$1);
10102
+ headingStyles$1.replaceSync(headingCss);
10103
+ const _Paragraph = class _Paragraph extends PxElement {
10078
10104
  constructor() {
10079
- super();
10080
- this.template = () => `
10081
- <px-container border-radius="none" padding-inline="none" background-color="${this.backgroundColor}">
10082
- <div class="content-wrapper ${this.$slotOverlap ? "overlapped" : ""}">
10083
- <px-vstack gap="heading-to-content">
10084
- <slot name="heading"></slot>
10085
- <px-vstack gap="none">
10086
- <slot></slot>
10087
- </px-vstack>
10088
- </px-vstack>
10089
- </div>
10090
- </px-container>
10091
- <div class="content-wrapper">
10092
- <slot name="overlap"></slot>
10093
- </div>
10094
- `;
10095
- this.attachShadow({ mode: "open" });
10105
+ super(typographyStyles$2, headingStyles$1, paragraphStyles$1);
10106
+ this.template = () => `<p><slot></slot></p>`;
10096
10107
  this.shadowRoot.innerHTML = this.template();
10097
- this.shadowRoot.adoptedStyleSheets = [styleSheet$n];
10098
- }
10099
- connectedCallback() {
10100
- const headingSlot = this.querySelector('[slot="heading"]');
10101
- if (!this.paddingBlock && !this.paddingTop && !this.paddingBottom && !this.paddingBlockMobile && !this.paddingTopMobile && !this.paddingBottomMobile && !this.paddingBlockTablet && !this.paddingTopTablet && !this.paddingBottomTablet && !this.paddingBlockLaptop && !this.paddingTopLaptop && !this.paddingBottomLaptop) {
10102
- this.$container.paddingBlock = "none";
10103
- }
10104
- if (!headingSlot) {
10105
- this.shadowRoot.querySelector("px-vstack").setAttribute("gap", "none");
10106
- }
10107
10108
  }
10108
10109
  static get observedAttributes() {
10109
10110
  return [
10110
- "background-color",
10111
- "background-gradient",
10112
- "background-image",
10113
- "background-image--mobile",
10114
- "background-image--tablet",
10115
- "background-image--laptop",
10116
- "background-size",
10117
- "background-position",
10118
- "padding-block",
10119
- "padding-top",
10120
- "padding-bottom",
10121
- "padding-block--mobile",
10122
- "padding-top--mobile",
10123
- "padding-bottom--mobile",
10124
- "padding-block--tablet",
10125
- "padding-top--tablet",
10126
- "padding-bottom--tablet",
10127
- "padding-block--laptop",
10128
- "padding-top--laptop",
10129
- "padding-bottom--laptop",
10130
- "border",
10131
- "border-side",
10132
- "border-side--mobile",
10133
- "border-side--tablet",
10134
- "border-side--laptop"
10111
+ ...super.observedAttributes,
10112
+ "variant",
10113
+ "color",
10114
+ "font-size",
10115
+ "font-weight",
10116
+ "text-align",
10117
+ "text-align--mobile",
10118
+ "text-align--tablet",
10119
+ "text-align--laptop",
10120
+ "inverted",
10121
+ "disabled"
10135
10122
  ];
10136
10123
  }
10137
- get $container() {
10138
- return this.shadowRoot.querySelector("px-container");
10139
- }
10140
- attributeChangedCallback(name, oldValue, newValue) {
10124
+ attributeChangedCallback(attrName, oldValue, newValue) {
10141
10125
  if (oldValue !== newValue) {
10142
- switch (name) {
10143
- case "background-color":
10144
- this.$container.backgroundColor = backgroundColorValues.indexOf(newValue) > 0 ? newValue : "none";
10145
- break;
10146
- case "background-gradient":
10147
- this.$container.gradient = this.gradient;
10148
- break;
10149
- case "background-image":
10150
- this.$container.backgroundImage = newValue;
10151
- break;
10152
- case "background-image--mobile":
10153
- this.$container.backgroundImageMobile = newValue;
10154
- break;
10155
- case "background-image--tablet":
10156
- this.$container.backgroundImageTablet = newValue;
10157
- break;
10158
- case "background-image--laptop":
10159
- this.$container.backgroundImageLaptop = newValue;
10160
- break;
10161
- case "background-size":
10162
- this.$container.backgroundSize = newValue;
10163
- break;
10164
- case "background-position":
10165
- this.$container.backgroundPosition = newValue;
10166
- break;
10167
- case "padding-block":
10168
- this.$container.paddingBlock = newValue;
10169
- break;
10170
- case "padding-top":
10171
- this.$container.paddingTop = newValue;
10172
- break;
10173
- case "padding-bottom":
10174
- this.$container.paddingBottom = newValue;
10175
- break;
10176
- case "padding-block--mobile":
10177
- this.$container.paddingBlockMobile = newValue;
10178
- break;
10179
- case "padding-top--mobile":
10180
- this.$container.paddingTopMobile = newValue;
10181
- break;
10182
- case "padding-bottom--mobile":
10183
- this.$container.paddingBottomMobile = newValue;
10184
- break;
10185
- case "padding-block--tablet":
10186
- this.$container.paddingBlockTablet = newValue;
10187
- break;
10188
- case "padding-top--tablet":
10189
- this.$container.paddingTopTablet = newValue;
10190
- break;
10191
- case "padding-bottom--tablet":
10192
- this.$container.paddingBottomTablet = newValue;
10193
- break;
10194
- case "padding-block--laptop":
10195
- this.$container.paddingBlockLaptop = newValue;
10196
- break;
10197
- case "padding-top--laptop":
10198
- this.$container.paddingTopLaptop = newValue;
10126
+ switch (attrName) {
10127
+ case "variant":
10128
+ this.updateVariant(attrName, oldValue, newValue, headingValues);
10199
10129
  break;
10200
- case "padding-bottom--laptop":
10201
- this.$container.paddingBottomLaptop = newValue;
10130
+ case "color":
10131
+ this.updateTypography(attrName, oldValue, newValue, colorValues);
10202
10132
  break;
10203
- case "border":
10204
- this.$container.border = newValue;
10133
+ case "font-size":
10134
+ this.updateTypography(attrName, oldValue, newValue, fontsizeValues);
10205
10135
  break;
10206
- case "border-side":
10207
- this.$container.borderSide = newValue;
10136
+ case "font-weight":
10137
+ this.updateTypography(attrName, oldValue, newValue, fontweightValues);
10208
10138
  break;
10209
- case "border-side--mobile":
10210
- this.$container.borderSideMobile = newValue;
10139
+ case "text-align":
10140
+ case "text-align--mobile":
10141
+ case "text-align--tablet":
10142
+ case "text-align--laptop":
10143
+ this.updateTypography(attrName, oldValue, newValue, textalignValues);
10211
10144
  break;
10212
- case "border-side--tablet":
10213
- this.$container.borderSideTablet = newValue;
10145
+ case "disabled":
10146
+ this.color = "state-disabled";
10214
10147
  break;
10215
- case "border-side--laptop":
10216
- this.$container.borderSideLaptop = newValue;
10148
+ default:
10149
+ super.attributeChangedCallback(attrName, oldValue, newValue);
10217
10150
  break;
10218
10151
  }
10219
10152
  }
10220
10153
  }
10221
- get $slotOverlap() {
10222
- return this.querySelector('[slot="overlap"]');
10223
- }
10224
- get backgroundColor() {
10225
- return this.getAttribute("background-color") || "none";
10226
- }
10227
- set backgroundColor(value) {
10228
- this.setAttribute("background-color", value);
10229
- }
10230
- get gradient() {
10231
- return this.getAttribute("background-gradient");
10232
- }
10233
- set gradient(value) {
10234
- this.setAttribute("background-gradient", value);
10235
- }
10236
- get backgroundImage() {
10237
- return this.getAttribute("background-image");
10238
- }
10239
- set backgroundImage(value) {
10240
- this.setAttribute("background-image", value);
10241
- }
10242
- get backgroundImageMobile() {
10243
- return this.getAttribute("background-image--mobile");
10244
- }
10245
- set backgroundImageMobile(value) {
10246
- this.setAttribute("background-image--mobile", value);
10247
- }
10248
- get backgroundImageTablet() {
10249
- return this.getAttribute("background-image--tablet");
10250
- }
10251
- set backgroundImageTablet(value) {
10252
- this.setAttribute("background-image--tablet", value);
10253
- }
10254
- get backgroundImageLaptop() {
10255
- return this.getAttribute("background-image--laptop");
10154
+ toggleClass(oldValue, newValue) {
10155
+ if (oldValue !== null && oldValue !== "" && oldValue !== "default") {
10156
+ this.$el.classList.toggle(`style-${oldValue}`);
10157
+ }
10158
+ if (newValue !== null && newValue !== "" && newValue !== "default") {
10159
+ this.$el.classList.toggle(`style-${newValue}`);
10160
+ }
10256
10161
  }
10257
- set backgroundImageLaptop(value) {
10258
- this.setAttribute("background-image--laptop", value);
10162
+ updateVariant(attrName, oldValue, newValue, attrValue) {
10163
+ if (!this.checkName(attrValue, newValue)) {
10164
+ console.error(`${newValue} is not a valid value for ${attrName}`);
10165
+ } else {
10166
+ this.toggleClass(oldValue, newValue);
10167
+ }
10259
10168
  }
10260
- get backgroundSize() {
10261
- return this.getAttribute("background-size");
10169
+ updateTypography(attrName, oldValue, newValue, attrValue) {
10170
+ if (!this.checkName(attrValue, newValue)) {
10171
+ console.error(`${newValue} is not an allowed ${attrName} value`);
10172
+ } else {
10173
+ const splitResult = this.splitAttrNameFromBreakpoint(attrName);
10174
+ const breakpoint = splitResult.breakpoint;
10175
+ if (oldValue !== null && oldValue !== "") {
10176
+ this.$el.classList.toggle(
10177
+ `${splitResult.attrName}-${oldValue}${breakpoint}`
10178
+ );
10179
+ }
10180
+ if (newValue !== null && newValue !== "") {
10181
+ this.$el.classList.toggle(
10182
+ `${splitResult.attrName}-${newValue}${breakpoint}`
10183
+ );
10184
+ }
10185
+ }
10262
10186
  }
10263
- set backgroundSize(value) {
10264
- this.setAttribute("background-size", value);
10187
+ splitAttrNameFromBreakpoint(attrName) {
10188
+ let breakpoint = "";
10189
+ if (["--mobile", "--tablet", "--laptop"].some(
10190
+ (suffix) => attrName.includes(suffix)
10191
+ )) {
10192
+ const attrNameSplit = attrName.split("--");
10193
+ attrName = attrNameSplit[0];
10194
+ breakpoint = `--${attrNameSplit[1]}`;
10195
+ }
10196
+ return { attrName, breakpoint };
10265
10197
  }
10266
- get backgroundPosition() {
10267
- return this.getAttribute("background-position");
10198
+ get variant() {
10199
+ return this.getAttribute("variant");
10268
10200
  }
10269
- set backgroundPosition(value) {
10270
- this.setAttribute("background-position", value);
10201
+ set variant(value) {
10202
+ this.setAttribute("variant", value);
10271
10203
  }
10272
- get paddingBlock() {
10273
- return this.getAttribute("padding-block");
10204
+ get color() {
10205
+ return this.getAttribute("color");
10274
10206
  }
10275
- set paddingBlock(value) {
10276
- this.setAttribute("padding-block", value);
10207
+ set color(value) {
10208
+ this.setAttribute("color", value);
10277
10209
  }
10278
- get paddingTop() {
10279
- return this.getAttribute("padding-top");
10210
+ get fontSize() {
10211
+ return this.getAttribute("font-size");
10280
10212
  }
10281
- set paddingTop(value) {
10282
- this.setAttribute("padding-top", value);
10213
+ set fontSize(value) {
10214
+ this.setAttribute("font-size", value);
10283
10215
  }
10284
- get paddingBottom() {
10285
- return this.getAttribute("padding-bottom");
10216
+ get fontWeight() {
10217
+ return this.getAttribute("font-weight");
10286
10218
  }
10287
- set paddingBottom(value) {
10288
- this.setAttribute("padding-bottom", value);
10219
+ set fontWeight(value) {
10220
+ this.setAttribute("font-weight", value);
10289
10221
  }
10290
- get paddingBlockMobile() {
10291
- return this.getAttribute("padding-block--mobile");
10222
+ get textAlign() {
10223
+ return this.getAttribute("text-align");
10292
10224
  }
10293
- set paddingBlockMobile(value) {
10294
- this.setAttribute("padding-block--mobile", value);
10225
+ set textAlign(value) {
10226
+ this.setAttribute("text-align", value);
10295
10227
  }
10296
- get paddingTopMobile() {
10297
- return this.getAttribute("padding-top--mobile");
10228
+ get textAlignMobile() {
10229
+ return this.getAttribute("text-align--mobile");
10298
10230
  }
10299
- set paddingTopMobile(value) {
10300
- this.setAttribute("padding-top--mobile", value);
10231
+ set textAlignMobile(value) {
10232
+ this.setAttribute("text-align--mobile", value);
10301
10233
  }
10302
- get paddingBottomMobile() {
10303
- return this.getAttribute("padding-bottom--mobile");
10234
+ get textAlignTablet() {
10235
+ return this.getAttribute("text-align--tablet");
10304
10236
  }
10305
- set paddingBottomMobile(value) {
10306
- this.setAttribute("padding-bottom--mobile", value);
10237
+ set textAlignTablet(value) {
10238
+ this.setAttribute("text-align--tablet", value);
10307
10239
  }
10308
- get paddingBlockTablet() {
10309
- return this.getAttribute("padding-block--tablet");
10240
+ get textAlignLaptop() {
10241
+ return this.getAttribute("text-align--laptop");
10310
10242
  }
10311
- set paddingBlockTablet(value) {
10312
- this.setAttribute("padding-block--tablet", value);
10243
+ set textAlignLaptop(value) {
10244
+ this.setAttribute("text-align--laptop", value);
10313
10245
  }
10314
- get paddingTopTablet() {
10315
- return this.getAttribute("padding-top--tablet");
10246
+ get inverted() {
10247
+ return this.getAttribute("inverted");
10316
10248
  }
10317
- set paddingTopTablet(value) {
10318
- this.setAttribute("padding-top--tablet", value);
10249
+ set inverted(value) {
10250
+ this.setAttribute("inverted", value);
10319
10251
  }
10320
- get paddingBottomTablet() {
10321
- return this.getAttribute("padding-bottom--tablet");
10252
+ get disabled() {
10253
+ return this.getAttribute("disabled");
10322
10254
  }
10323
- set paddingBottomTablet(value) {
10324
- this.setAttribute("padding-bottom--tablet", value);
10255
+ set disabled(value) {
10256
+ this.setAttribute("disabled", value);
10325
10257
  }
10326
- get paddingBlockLaptop() {
10327
- return this.getAttribute("padding-block--laptop");
10258
+ };
10259
+ _Paragraph.nativeName = "p";
10260
+ let Paragraph = _Paragraph;
10261
+ if (!customElements.get("px-p")) {
10262
+ customElements.define("px-p", Paragraph);
10263
+ }
10264
+ const _FooterSitemap = class _FooterSitemap extends PxElement {
10265
+ constructor() {
10266
+ super();
10267
+ this.template = () => `<div class="footer-sitemap">
10268
+ <px-grid grid-cols="4" grid-cols--mobile="1" role="list" gap--mobile="none">
10269
+ <slot></slot>
10270
+ </px-grid>
10271
+ </div>`;
10272
+ this.shadowRoot.innerHTML = this.template();
10328
10273
  }
10329
- set paddingBlockLaptop(value) {
10330
- this.setAttribute("padding-block--laptop", value);
10274
+ static get observedAttributes() {
10275
+ return [...super.observedAttributes, "inverted"];
10331
10276
  }
10332
- get paddingTopLaptop() {
10333
- return this.getAttribute("padding-top--laptop");
10277
+ attributeChangedCallback(attrName, oldValue, newValue) {
10278
+ if (oldValue !== newValue) {
10279
+ switch (attrName) {
10280
+ case "inverted":
10281
+ for (let i = 0; i < this.$children.length; i++) {
10282
+ if (!this.$children[i].hasAttribute("inverted")) {
10283
+ this.$children[i].toggleAttribute("inverted");
10284
+ }
10285
+ }
10286
+ break;
10287
+ default:
10288
+ super.attributeChangedCallback(attrName, oldValue, newValue);
10289
+ break;
10290
+ }
10291
+ }
10334
10292
  }
10335
- set paddingTopLaptop(value) {
10336
- this.setAttribute("padding-top--laptop", value);
10293
+ get $children() {
10294
+ return this.querySelectorAll("px-footer-sitemap > *");
10337
10295
  }
10338
- get paddingBottomLaptop() {
10339
- return this.getAttribute("padding-bottom--laptop");
10296
+ get inverted() {
10297
+ return this.hasAttribute("inverted");
10340
10298
  }
10341
- set paddingBottomLaptop(value) {
10342
- this.setAttribute("padding-bottom--laptop", value);
10299
+ set inverted(value) {
10300
+ if (value) {
10301
+ this.setAttribute("inverted", "");
10302
+ } else {
10303
+ this.removeAttribute("inverted");
10304
+ }
10343
10305
  }
10344
- get border() {
10345
- return this.getAttribute("border");
10306
+ };
10307
+ _FooterSitemap.nativeName = "div";
10308
+ let FooterSitemap = _FooterSitemap;
10309
+ if (!customElements.get("px-footer-sitemap")) {
10310
+ customElements.define("px-footer-sitemap", FooterSitemap);
10311
+ }
10312
+ const styles$s = ":host,:host>*{display:block;box-sizing:border-box}::slotted(ul){margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:10px}::slotted(ul.link-list-img){display:flex;flex-wrap:wrap;flex-direction:row;gap:20px}";
10313
+ const styleSheet$n = new CSSStyleSheet();
10314
+ styleSheet$n.replaceSync(styles$s);
10315
+ const _FooterSitemapItem = class _FooterSitemapItem extends PxElement {
10316
+ constructor() {
10317
+ super(styleSheet$n);
10318
+ this.templateMobile = () => `<div role="listitem">
10319
+ <px-accordion ${this.inverted ? "inverted" : ""}>
10320
+ <span slot="title"><slot name="links-list-title"></slot></span>
10321
+ <span slot="content">
10322
+ <slot name="links-list"></slot>
10323
+ </span>
10324
+ </px-accordion>
10325
+ </div>`;
10326
+ this.templateDesktop = () => `<div role="listitem">
10327
+ <px-vstack gap="default">
10328
+ <px-p variant="title-l" ${this.inverted ? "inverted" : ""}>
10329
+ <slot name="links-list-title"></slot>
10330
+ </px-p>
10331
+ <slot name="links-list"></slot>
10332
+ </px-vstack>
10333
+ </div>`;
10334
+ this.throttledLoadTemplate = throttle(this.loadTemplate.bind(this), 50);
10335
+ this.loadTemplate();
10346
10336
  }
10347
- set border(value) {
10348
- this.setAttribute("border", value);
10337
+ static get observedAttributes() {
10338
+ return [...super.observedAttributes, "inverted"];
10349
10339
  }
10350
- get borderSide() {
10351
- return this.getAttribute("border-side");
10340
+ connectedCallback() {
10341
+ super.connectedCallback();
10342
+ this.loadTemplate();
10343
+ window.addEventListener("resize", this.throttledLoadTemplate);
10344
+ if (!this.$ul) {
10345
+ console.error(
10346
+ "The footer sitemap item must contain a <ul> element with links."
10347
+ );
10348
+ } else {
10349
+ if (this.$ul.querySelector("px-img")) {
10350
+ this.$ul.classList.add("link-list-img");
10351
+ }
10352
+ }
10352
10353
  }
10353
- set borderSide(value) {
10354
- this.setAttribute("border-side", value);
10354
+ disconnectedCallback() {
10355
+ window.removeEventListener("resize", this.throttledLoadTemplate);
10355
10356
  }
10356
- get borderSideMobile() {
10357
- return this.getAttribute("border-side--mobile");
10357
+ loadTemplate() {
10358
+ const previousSize = this.lastSize;
10359
+ const currentSize = window.innerWidth < 768 ? "mobile" : "desktop";
10360
+ if (previousSize !== currentSize) {
10361
+ if (currentSize === "mobile") {
10362
+ this.shadowRoot.innerHTML = this.templateMobile();
10363
+ } else {
10364
+ this.shadowRoot.innerHTML = this.templateDesktop();
10365
+ }
10366
+ this.lastSize = currentSize;
10367
+ }
10358
10368
  }
10359
- set borderSideMobile(value) {
10360
- this.setAttribute("border-side--mobile", value);
10369
+ attributeChangedCallback(attrName, oldValue, newValue) {
10370
+ if (oldValue !== newValue) {
10371
+ switch (attrName) {
10372
+ case "inverted":
10373
+ for (let i = 0; i < this.$children.length; i++) {
10374
+ if (!this.$children[i].hasAttribute("inverted")) {
10375
+ this.$children[i].toggleAttribute("inverted");
10376
+ }
10377
+ }
10378
+ this.$ul.querySelectorAll("px-a").forEach((link) => {
10379
+ link.toggleAttribute("inverted");
10380
+ });
10381
+ break;
10382
+ default:
10383
+ super.attributeChangedCallback(attrName, oldValue, newValue);
10384
+ break;
10385
+ }
10386
+ }
10361
10387
  }
10362
- get borderSideTablet() {
10363
- return this.getAttribute("border-side--tablet");
10388
+ get $ul() {
10389
+ return this.querySelector("ul");
10364
10390
  }
10365
- set borderSideTablet(value) {
10366
- this.setAttribute("border-side--tablet", value);
10391
+ get $children() {
10392
+ return this.querySelectorAll("px-footer-sitemap-item > *");
10367
10393
  }
10368
- get borderSideLaptop() {
10369
- return this.getAttribute("border-side--laptop");
10394
+ get inverted() {
10395
+ return this.hasAttribute("inverted");
10370
10396
  }
10371
- set borderSideLaptop(value) {
10372
- this.setAttribute("border-side--laptop", value);
10397
+ set inverted(value) {
10398
+ if (value) {
10399
+ this.setAttribute("inverted", "");
10400
+ } else {
10401
+ this.removeAttribute("inverted");
10402
+ }
10373
10403
  }
10374
- }
10375
- if (!customElements.get("px-section")) {
10376
- customElements.define("px-section", Section);
10404
+ };
10405
+ _FooterSitemapItem.nativeName = "div";
10406
+ let FooterSitemapItem = _FooterSitemapItem;
10407
+ if (!customElements.get("px-footer-sitemap-item")) {
10408
+ customElements.define("px-footer-sitemap-item", FooterSitemapItem);
10377
10409
  }
10378
10410
  const styles$r = ":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:2em 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:calc(2em - 2px)}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 only screen and (min-width: 48em){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 only screen and (min-width: 64.0625em){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 only screen and (min-width: 90.0625em){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)}}";
10379
10411
  const stylesheet$7 = new CSSStyleSheet();
@@ -10388,6 +10420,7 @@ class HeaderItem extends WithExtraAttributes {
10388
10420
  this.shadowRoot.innerHTML = this.template();
10389
10421
  this.shadowRoot.adoptedStyleSheets = [stylesheet$7];
10390
10422
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
10423
+ this.role = "listitem";
10391
10424
  if (this.internals) {
10392
10425
  this.internals.role = "listitem";
10393
10426
  }
@@ -10538,9 +10571,9 @@ class Header extends WithExtraAttributes {
10538
10571
  });
10539
10572
  this.shadowRoot.innerHTML = this.template;
10540
10573
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
10574
+ this.role = "navigation";
10541
10575
  if (this.internals) {
10542
10576
  this.internals.role = "navigation";
10543
- this.internals.ariaOrientation = "horizontal";
10544
10577
  }
10545
10578
  }
10546
10579
  connectedCallback() {
@@ -11926,6 +11959,7 @@ class MegaDropDown extends HTMLElement {
11926
11959
  this.shadowRoot.innerHTML = this.template;
11927
11960
  this.shadowRoot.adoptedStyleSheets = [stylesheet$3];
11928
11961
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
11962
+ this.role = "menu";
11929
11963
  if (this.internals) {
11930
11964
  this.internals.role = "menu";
11931
11965
  }
@@ -11942,6 +11976,7 @@ class MegaDropDown extends HTMLElement {
11942
11976
  if (this.internals) {
11943
11977
  this.internals.ariaHidden = "true";
11944
11978
  }
11979
+ this.ariaHidden = "true";
11945
11980
  this.setAttribute("slot", "header-panels");
11946
11981
  this.shadowRoot.addEventListener("click", (event) => {
11947
11982
  if (event.target.closest("px-button-icon")) {
@@ -12001,7 +12036,9 @@ class MegaDropDown extends HTMLElement {
12001
12036
  this.id = newValue;
12002
12037
  }
12003
12038
  if (name === "hidden" && this.internals) {
12004
- this.internals.ariaHidden = newValue === "true" || newValue === "" ? "true" : "false";
12039
+ const val = newValue === "true" || newValue === "" ? "true" : "false";
12040
+ this.internals.ariaHidden = val;
12041
+ this.ariaHidden = val;
12005
12042
  const mddFooterHeightPx = __privateGet(this, _MegaDropDown_instances, $footer_get).offsetHeight;
12006
12043
  const mddFooterHeight = mddFooterHeightPx / parseFloat(getComputedStyle(document.documentElement).fontSize);
12007
12044
  this.style.setProperty(
@@ -12039,6 +12076,7 @@ class MegaDropDown extends HTMLElement {
12039
12076
  if (this.internals) {
12040
12077
  this.internals.ariaHidden = "true";
12041
12078
  }
12079
+ this.ariaHidden = "true";
12042
12080
  this.setAttribute("hidden", "");
12043
12081
  if (this.$dialog.open) {
12044
12082
  this.$dialog.close();
@@ -12047,6 +12085,7 @@ class MegaDropDown extends HTMLElement {
12047
12085
  if (this.internals) {
12048
12086
  this.internals.ariaHidden = "false";
12049
12087
  }
12088
+ this.ariaHidden = "false";
12050
12089
  if (!this.$dialog.open) {
12051
12090
  this.$dialog.showModal();
12052
12091
  setTimeout(() => {
@@ -12199,6 +12238,7 @@ class MddSectionItem extends HTMLElement {
12199
12238
  this.attachShadow({ mode: "open" });
12200
12239
  this.shadowRoot.adoptedStyleSheets = [stylesheet$1];
12201
12240
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
12241
+ this.role = "listitem";
12202
12242
  if (this.internals) {
12203
12243
  this.internals.role = "listitem";
12204
12244
  }
@@ -12924,10 +12964,12 @@ class SelectableBoxCheckbox extends WithExtraAttributes {
12924
12964
  this.shadowRoot.innerHTML = this.template();
12925
12965
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
12926
12966
  this.toggleFooterVisibility = this.toggleFooterVisibility.bind(this);
12967
+ this.role = "checkbox";
12927
12968
  if (this.internals) {
12928
12969
  this.internals.role = "checkbox";
12929
12970
  this.internals.ariaChecked = `${this.checked}`;
12930
12971
  }
12972
+ this.ariaChecked = `${this.checked}`;
12931
12973
  }
12932
12974
  connectedCallback() {
12933
12975
  this.tabIndex = 0;
@@ -13027,12 +13069,14 @@ class SelectableBoxCheckbox extends WithExtraAttributes {
13027
13069
  if (this.internals) {
13028
13070
  this.internals.ariaDisabled = "true";
13029
13071
  }
13072
+ this.ariaDisabled = "true";
13030
13073
  this.$checkbox.setAttribute("disabled", "");
13031
13074
  } else {
13032
13075
  this.disabled = false;
13033
13076
  if (this.internals) {
13034
13077
  this.internals.ariaDisabled = "false";
13035
13078
  }
13079
+ this.ariaDisabled = "false";
13036
13080
  this.$checkbox.removeAttribute("disabled");
13037
13081
  }
13038
13082
  }
@@ -13043,6 +13087,7 @@ class SelectableBoxCheckbox extends WithExtraAttributes {
13043
13087
  if (this.internals) {
13044
13088
  this.internals.ariaChecked = "false";
13045
13089
  }
13090
+ this.ariaChecked = "false";
13046
13091
  this.checked = false;
13047
13092
  if (this.$checkbox) {
13048
13093
  this.$checkbox.removeAttribute("checked");
@@ -13051,6 +13096,7 @@ class SelectableBoxCheckbox extends WithExtraAttributes {
13051
13096
  if (this.internals) {
13052
13097
  this.internals.ariaChecked = "true";
13053
13098
  }
13099
+ this.ariaChecked = "true";
13054
13100
  this.checked = true;
13055
13101
  if (this.$checkbox) {
13056
13102
  this.$checkbox.setAttribute("checked", "");
@@ -13191,10 +13237,12 @@ class SelectableBoxRadio extends WithExtraAttributes {
13191
13237
  this.shadowRoot.innerHTML = this.template();
13192
13238
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
13193
13239
  this.toggleFooterVisibility = this.toggleFooterVisibility.bind(this);
13240
+ this.role = "radio";
13194
13241
  if (this.internals) {
13195
13242
  this.internals.role = "radio";
13196
13243
  this.internals.ariaChecked = `${this.checked}`;
13197
13244
  }
13245
+ this.ariaChecked = `${this.checked}`;
13198
13246
  }
13199
13247
  connectedCallback() {
13200
13248
  var _a;
@@ -13296,12 +13344,14 @@ class SelectableBoxRadio extends WithExtraAttributes {
13296
13344
  if (this.internals) {
13297
13345
  this.internals.ariaDisabled = "true";
13298
13346
  }
13347
+ this.ariaDisabled = "true";
13299
13348
  this.$radio.setAttribute("disabled", "");
13300
13349
  } else {
13301
13350
  this.disabled = false;
13302
13351
  if (this.internals) {
13303
13352
  this.internals.ariaDisabled = "false";
13304
13353
  }
13354
+ this.ariaDisabled = "false";
13305
13355
  this.$radio.removeAttribute("disabled");
13306
13356
  }
13307
13357
  }
@@ -13312,6 +13362,7 @@ class SelectableBoxRadio extends WithExtraAttributes {
13312
13362
  if (this.internals) {
13313
13363
  this.internals.ariaChecked = "false";
13314
13364
  }
13365
+ this.ariaChecked = "false";
13315
13366
  this.tabIndex = -1;
13316
13367
  this.checked = false;
13317
13368
  if (this.$radio) {
@@ -13321,6 +13372,7 @@ class SelectableBoxRadio extends WithExtraAttributes {
13321
13372
  if (this.internals) {
13322
13373
  this.internals.ariaChecked = "true";
13323
13374
  }
13375
+ this.ariaChecked = "true";
13324
13376
  this.tabIndex = 0;
13325
13377
  this.checked = true;
13326
13378
  if (this.$radio) {
@@ -13557,6 +13609,7 @@ class Spinner extends HTMLElement {
13557
13609
  connectedCallback() {
13558
13610
  if (!this.ariaLabel && this.internals) {
13559
13611
  this.internals.ariaHidden = "true";
13612
+ this.ariaHidden = "true";
13560
13613
  }
13561
13614
  }
13562
13615
  attributeChangedCallback(attrName, oldValue, newValue) {
@@ -13568,6 +13621,9 @@ class Spinner extends HTMLElement {
13568
13621
  case "aria-label":
13569
13622
  if (newValue !== "") {
13570
13623
  this.internals.ariaHidden = "false";
13624
+ this.ariaHidden = "false";
13625
+ this.internals.role = "status";
13626
+ this.role = "status";
13571
13627
  }
13572
13628
  break;
13573
13629
  }
@@ -13575,6 +13631,7 @@ class Spinner extends HTMLElement {
13575
13631
  }
13576
13632
  configureAccessibility(value) {
13577
13633
  this.internals.ariaHidden = value;
13634
+ this.ariaHidden = value;
13578
13635
  }
13579
13636
  updateAttribute(attrName, oldValue, newValue, attrValues) {
13580
13637
  if (oldValue !== null && oldValue !== "" && oldValue !== "default") {
@@ -14380,6 +14437,7 @@ class Tabs extends HTMLElement {
14380
14437
  this.shadowRoot.innerHTML = this.template();
14381
14438
  this.shadowRoot.adoptedStyleSheets = [styleSheet$7];
14382
14439
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
14440
+ this.role = "tablist";
14383
14441
  if (this.internals) {
14384
14442
  this.internals.role = "tablist";
14385
14443
  }
@@ -14569,9 +14627,11 @@ class Tab extends HTMLElement {
14569
14627
  this.shadowRoot.innerHTML = this.template();
14570
14628
  this.shadowRoot.adoptedStyleSheets = [styleSheet$6];
14571
14629
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
14630
+ this.role = "tab";
14572
14631
  if (this.internals) {
14573
14632
  this.internals.role = "tab";
14574
14633
  }
14634
+ this.ariaSelected = `${this.selected}`;
14575
14635
  }
14576
14636
  static get observedAttributes() {
14577
14637
  return ["selected", "for", "name"];
@@ -14635,12 +14695,14 @@ class Tab extends HTMLElement {
14635
14695
  if (this.internals) {
14636
14696
  this.internals.ariaSelected = `false`;
14637
14697
  }
14698
+ this.ariaSelected = `false`;
14638
14699
  } else {
14639
14700
  this.focus();
14640
14701
  this.tabIndex = 0;
14641
14702
  if (this.internals) {
14642
14703
  this.internals.ariaSelected = `true`;
14643
14704
  }
14705
+ this.ariaSelected = `true`;
14644
14706
  }
14645
14707
  }
14646
14708
  }
@@ -15194,10 +15256,12 @@ class TileCheckbox extends WithExtraAttributes {
15194
15256
  this.shadowRoot.innerHTML = this.template();
15195
15257
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
15196
15258
  this.tabIndex = 0;
15259
+ this.role = "checkbox";
15197
15260
  if (this.internals) {
15198
15261
  this.internals.role = "checkbox";
15199
15262
  this.internals.ariaChecked = `${this.checked}`;
15200
15263
  }
15264
+ this.ariaChecked = `${this.checked}`;
15201
15265
  }
15202
15266
  connectedCallback() {
15203
15267
  if (this.$slotPrefix) {
@@ -15286,6 +15350,7 @@ class TileCheckbox extends WithExtraAttributes {
15286
15350
  if (this.internals) {
15287
15351
  this.internals.ariaDisabled = "true";
15288
15352
  }
15353
+ this.ariaDisabled = "true";
15289
15354
  this.$tile.disabled = true;
15290
15355
  this.$checkbox.setAttribute("disabled", "");
15291
15356
  } else {
@@ -15293,6 +15358,7 @@ class TileCheckbox extends WithExtraAttributes {
15293
15358
  if (this.internals) {
15294
15359
  this.internals.ariaDisabled = "false";
15295
15360
  }
15361
+ this.ariaDisabled = "false";
15296
15362
  this.$tile.disabled = false;
15297
15363
  this.$checkbox.removeAttribute("disabled");
15298
15364
  }
@@ -15304,6 +15370,7 @@ class TileCheckbox extends WithExtraAttributes {
15304
15370
  if (this.internals) {
15305
15371
  this.internals.ariaChecked = "false";
15306
15372
  }
15373
+ this.ariaChecked = "false";
15307
15374
  this.checked = false;
15308
15375
  if (this.$checkbox) {
15309
15376
  this.$checkbox.removeAttribute("checked");
@@ -15312,6 +15379,7 @@ class TileCheckbox extends WithExtraAttributes {
15312
15379
  if (this.internals) {
15313
15380
  this.internals.ariaChecked = "true";
15314
15381
  }
15382
+ this.ariaChecked = "true";
15315
15383
  this.checked = true;
15316
15384
  if (this.$checkbox) {
15317
15385
  this.$checkbox.setAttribute("checked", "");
@@ -15465,10 +15533,12 @@ class TileRadio extends WithExtraAttributes {
15465
15533
  super(commonStyleSheet$2);
15466
15534
  this.shadowRoot.innerHTML = this.template();
15467
15535
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
15536
+ this.role = "radio";
15468
15537
  if (this.internals) {
15469
15538
  this.internals.role = "radio";
15470
15539
  this.internals.ariaChecked = `${this.checked}`;
15471
15540
  }
15541
+ this.ariaChecked = `${this.checked}`;
15472
15542
  }
15473
15543
  connectedCallback() {
15474
15544
  var _a;
@@ -15561,6 +15631,7 @@ class TileRadio extends WithExtraAttributes {
15561
15631
  if (this.internals) {
15562
15632
  this.internals.ariaDisabled = "true";
15563
15633
  }
15634
+ this.ariaDisabled = "true";
15564
15635
  this.$tile.disabled = true;
15565
15636
  this.$radio.setAttribute("disabled", "");
15566
15637
  } else {
@@ -15568,6 +15639,7 @@ class TileRadio extends WithExtraAttributes {
15568
15639
  if (this.internals) {
15569
15640
  this.internals.ariaDisabled = "false";
15570
15641
  }
15642
+ this.ariaDisabled = "false";
15571
15643
  this.$tile.disabled = false;
15572
15644
  this.$radio.removeAttribute("disabled");
15573
15645
  }
@@ -15579,6 +15651,7 @@ class TileRadio extends WithExtraAttributes {
15579
15651
  if (this.internals) {
15580
15652
  this.internals.ariaChecked = "false";
15581
15653
  }
15654
+ this.ariaChecked = "false";
15582
15655
  this.tabIndex = -1;
15583
15656
  this.checked = false;
15584
15657
  if (this.$radio) {
@@ -15588,6 +15661,7 @@ class TileRadio extends WithExtraAttributes {
15588
15661
  if (this.internals) {
15589
15662
  this.internals.ariaChecked = "true";
15590
15663
  }
15664
+ this.ariaChecked = "true";
15591
15665
  this.tabIndex = 0;
15592
15666
  this.checked = true;
15593
15667
  if (this.$radio) {
@@ -15901,10 +15975,12 @@ class TileSwitch extends WithExtraAttributes {
15901
15975
  this.shadowRoot.innerHTML = this.template();
15902
15976
  this.internals = (_a = this.attachInternals) == null ? void 0 : _a.call(this);
15903
15977
  this.tabIndex = 0;
15978
+ this.role = "checkbox";
15904
15979
  if (this.internals) {
15905
15980
  this.internals.role = "checkbox";
15906
15981
  this.internals.ariaChecked = `${this.checked}`;
15907
15982
  }
15983
+ this.ariaChecked = `${this.checked}`;
15908
15984
  }
15909
15985
  connectedCallback() {
15910
15986
  if (this.$slotPrefix) {
@@ -15982,6 +16058,7 @@ class TileSwitch extends WithExtraAttributes {
15982
16058
  if (this.internals) {
15983
16059
  this.internals.ariaDisabled = "true";
15984
16060
  }
16061
+ this.ariaDisabled = "true";
15985
16062
  this.$tile.disabled = true;
15986
16063
  this.$switch.setAttribute("disabled", "");
15987
16064
  } else {
@@ -15989,6 +16066,7 @@ class TileSwitch extends WithExtraAttributes {
15989
16066
  if (this.internals) {
15990
16067
  this.internals.ariaDisabled = "false";
15991
16068
  }
16069
+ this.ariaDisabled = "false";
15992
16070
  this.$tile.disabled = false;
15993
16071
  this.$switch.removeAttribute("disabled");
15994
16072
  }
@@ -16000,6 +16078,7 @@ class TileSwitch extends WithExtraAttributes {
16000
16078
  if (this.internals) {
16001
16079
  this.internals.ariaChecked = "false";
16002
16080
  }
16081
+ this.ariaChecked = "false";
16003
16082
  this.checked = false;
16004
16083
  if (this.$switch) {
16005
16084
  this.$switch.removeAttribute("checked");
@@ -16008,6 +16087,7 @@ class TileSwitch extends WithExtraAttributes {
16008
16087
  if (this.internals) {
16009
16088
  this.internals.ariaChecked = "true";
16010
16089
  }
16090
+ this.ariaChecked = "true";
16011
16091
  this.checked = true;
16012
16092
  if (this.$switch) {
16013
16093
  this.$switch.setAttribute("checked", "");
@@ -16268,8 +16348,8 @@ class TimelineItem extends HTMLElement {
16268
16348
  if (!customElements.get("px-timeline-item")) {
16269
16349
  customElements.define("px-timeline-item", TimelineItem);
16270
16350
  }
16271
- const typographyCss = "*{font-family:var(--px-font-family);font-weight:var(--px-font-weight-body);color:var(--px-color-text-neutral-default)}::slotted(ul),::slotted(ol){margin:0 0 0 var(--px-spacing-default-desktop);padding:0}::slotted(b),::slotted(strong){font-weight:var(--px-font-weight-title)}::slotted(address){font-style:normal;font-weight:var(--px-font-weight-body)}::slotted(img){max-width:100%;height:auto}:host([inverted]) slot{color:var(--px-color-text-neutral-inverted)}";
16272
- const lightStyles = ".li{padding-bottom:var(--px-padding-xs-desktop)}";
16351
+ const typographyCss = ":host{font-family:var(--px-font-family);font-weight:var(--px-font-weight-body);color:var(--px-color-text-neutral-default)}::slotted(ul),::slotted(ol){padding:0;margin:0 0 var(--px-spacing-xs-mobile) var(--px-spacing-default-mobile)}::slotted(blockquote){margin-bottom:var(--px-spacing-xs-mobile)}::slotted(b),::slotted(strong){font-weight:var(--px-font-weight-title)}::slotted(address){font-style:normal;font-weight:var(--px-font-weight-body)}::slotted(img){max-width:100%;height:auto}@media only screen and (min-width: 48em){::slotted(ul),::slotted(ol){margin:0 0 var(--px-spacing-xs-tablet) var(--px-spacing-default-tablet)}::slotted(blockquote){margin-bottom:var(--px-spacing-xs-tablet)}}@media only screen and (min-width: 64.0625em){::slotted(ul),::slotted(ol){margin:0 0 var(--px-spacing-xs-laptop) var(--px-spacing-default-laptop)}::slotted(blockquote){margin-bottom:var(--px-spacing-xs-laptop)}}@media only screen and (min-width: 90.0625em){::slotted(ul),::slotted(ol){margin:0 0 var(--px-spacing-xs-desktop) var(--px-spacing-default-desktop)}::slotted(blockquote){margin-bottom:var(--px-spacing-xs-desktop)}}:host([inverted]){color:var(--px-color-text-neutral-inverted)}";
16352
+ const lightStyles = ".li{margin-bottom:var(--px-padding-xs-mobile)}@media only screen and (min-width: 48em){.li{margin-bottom:var(--px-padding-xs-tablet)}}@media only screen and (min-width: 64.0625em){.li{margin-bottom:var(--px-padding-xs-laptop)}}@media only screen and (min-width: 90.0625em){.li{margin-bottom:var(--px-padding-xs-desktop)}}";
16273
16353
  const typographyStyles = new CSSStyleSheet();
16274
16354
  const headingStyles = new CSSStyleSheet();
16275
16355
  const linkStyles = new CSSStyleSheet();