@sbb-esta/lyne-elements 4.1.0 → 4.3.0

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.
Files changed (168) hide show
  1. package/accordion/accordion.component.d.ts.map +1 -1
  2. package/accordion/accordion.component.js +12 -16
  3. package/action-group/action-group.component.d.ts.map +1 -1
  4. package/action-group/action-group.component.js +18 -21
  5. package/autocomplete/autocomplete-base-element.d.ts.map +1 -1
  6. package/autocomplete/autocomplete-base-element.js +25 -26
  7. package/autocomplete/autocomplete.component.d.ts.map +1 -1
  8. package/autocomplete/autocomplete.component.js +1 -1
  9. package/breadcrumb/breadcrumb-group/breadcrumb-group.component.d.ts +3 -1
  10. package/breadcrumb/breadcrumb-group/breadcrumb-group.component.d.ts.map +1 -1
  11. package/breadcrumb/breadcrumb-group/breadcrumb-group.component.js +45 -52
  12. package/button/common.d.ts.map +1 -1
  13. package/button/common.js +5 -4
  14. package/button/mini-button/mini-button.component.d.ts +2 -2
  15. package/button/mini-button/mini-button.component.d.ts.map +1 -1
  16. package/button/mini-button/mini-button.component.js +22 -20
  17. package/button/mini-button-group/mini-button-group.component.d.ts.map +1 -1
  18. package/button/mini-button-group/mini-button-group.component.js +14 -10
  19. package/button/mini-button-link/mini-button-link.component.d.ts +21 -0
  20. package/button/mini-button-link/mini-button-link.component.d.ts.map +1 -0
  21. package/button/mini-button-link/mini-button-link.component.js +35 -0
  22. package/button/mini-button-link.d.ts +5 -0
  23. package/button/mini-button-link.d.ts.map +1 -0
  24. package/button/mini-button-link.js +4 -0
  25. package/button.d.ts +1 -0
  26. package/button.d.ts.map +1 -1
  27. package/button.js +28 -25
  28. package/calendar/calendar.component.js +52 -52
  29. package/card/card/card.component.js +14 -14
  30. package/chip/chip-group/chip-group.component.d.ts +2 -5
  31. package/chip/chip-group/chip-group.component.d.ts.map +1 -1
  32. package/chip/chip-group/chip-group.component.js +70 -68
  33. package/core/controllers/media-matchers-controller.js +2 -2
  34. package/core/interfaces/overlay-close-details.d.ts +1 -0
  35. package/core/interfaces/overlay-close-details.d.ts.map +1 -1
  36. package/core/styles/core.scss +19 -0
  37. package/core/styles/mixins/buttons.scss +1 -2
  38. package/core/styles/mixins/card.scss +9 -3
  39. package/core/styles/mixins/inputs.scss +1 -1
  40. package/core/styles/normalize.scss +4 -6
  41. package/core.css +32 -4
  42. package/custom-elements.json +2080 -1104
  43. package/development/accordion/accordion.component.d.ts.map +1 -1
  44. package/development/accordion/accordion.component.js +2 -6
  45. package/development/action-group/action-group.component.d.ts.map +1 -1
  46. package/development/action-group/action-group.component.js +13 -22
  47. package/development/autocomplete/autocomplete-base-element.d.ts.map +1 -1
  48. package/development/autocomplete/autocomplete-base-element.js +4 -2
  49. package/development/autocomplete/autocomplete.component.d.ts.map +1 -1
  50. package/development/autocomplete/autocomplete.component.js +2 -2
  51. package/development/breadcrumb/breadcrumb-group/breadcrumb-group.component.d.ts +3 -1
  52. package/development/breadcrumb/breadcrumb-group/breadcrumb-group.component.d.ts.map +1 -1
  53. package/development/breadcrumb/breadcrumb-group/breadcrumb-group.component.js +27 -31
  54. package/development/button/common.d.ts.map +1 -1
  55. package/development/button/common.js +3 -2
  56. package/development/button/mini-button/mini-button.component.d.ts +2 -2
  57. package/development/button/mini-button/mini-button.component.d.ts.map +1 -1
  58. package/development/button/mini-button/mini-button.component.js +7 -35
  59. package/development/button/mini-button-group/mini-button-group.component.d.ts.map +1 -1
  60. package/development/button/mini-button-group/mini-button-group.component.js +8 -4
  61. package/development/button/mini-button-link/mini-button-link.component.d.ts +21 -0
  62. package/development/button/mini-button-link/mini-button-link.component.d.ts.map +1 -0
  63. package/development/button/mini-button-link/mini-button-link.component.js +47 -0
  64. package/development/button/mini-button-link.d.ts +5 -0
  65. package/development/button/mini-button-link.d.ts.map +1 -0
  66. package/development/button/mini-button-link.js +5 -0
  67. package/development/button.d.ts +1 -0
  68. package/development/button.d.ts.map +1 -1
  69. package/development/button.js +6 -3
  70. package/development/calendar/calendar.component.js +3 -5
  71. package/development/card/card/card.component.js +11 -1
  72. package/development/chip/chip-group/chip-group.component.d.ts +2 -5
  73. package/development/chip/chip-group/chip-group.component.d.ts.map +1 -1
  74. package/development/chip/chip-group/chip-group.component.js +78 -14
  75. package/development/core/controllers/media-matchers-controller.js +1 -1
  76. package/development/core/interfaces/overlay-close-details.d.ts +1 -0
  77. package/development/core/interfaces/overlay-close-details.d.ts.map +1 -1
  78. package/development/dialog/dialog/dialog.component.d.ts +4 -0
  79. package/development/dialog/dialog/dialog.component.d.ts.map +1 -1
  80. package/development/dialog/dialog/dialog.component.js +23 -3
  81. package/development/dialog/dialog-actions/dialog-actions.component.js +2 -1
  82. package/development/dialog/dialog.js +5 -2
  83. package/development/dialog.js +5 -2
  84. package/development/divider/divider.component.d.ts +2 -2
  85. package/development/divider/divider.component.d.ts.map +1 -1
  86. package/development/divider/divider.component.js +4 -6
  87. package/development/expansion-panel/expansion-panel/expansion-panel.component.d.ts.map +1 -1
  88. package/development/expansion-panel/expansion-panel/expansion-panel.component.js +39 -34
  89. package/development/expansion-panel/expansion-panel-content/expansion-panel-content.component.d.ts.map +1 -1
  90. package/development/expansion-panel/expansion-panel-content/expansion-panel-content.component.js +15 -13
  91. package/development/expansion-panel/expansion-panel-header/expansion-panel-header.component.js +23 -21
  92. package/development/flip-card/flip-card/flip-card.component.js +2 -3
  93. package/development/form-field/form-field/form-field.component.d.ts +2 -0
  94. package/development/form-field/form-field/form-field.component.d.ts.map +1 -1
  95. package/development/form-field/form-field/form-field.component.js +6 -2
  96. package/development/image/image.component.js +1 -1
  97. package/development/lead-container/lead-container.component.d.ts +3 -1
  98. package/development/lead-container/lead-container.component.d.ts.map +1 -1
  99. package/development/lead-container/lead-container.component.js +7 -2
  100. package/development/{mini-button-common-CWTMR_Lu.js → mini-button-label-common-DzMdb-kV.js} +37 -3
  101. package/development/navigation/navigation-section/navigation-section.component.js +4 -4
  102. package/development/option/option-hint/option-hint.component.js +2 -1
  103. package/development/overlay/overlay-base-element.d.ts +29 -3
  104. package/development/overlay/overlay-base-element.d.ts.map +1 -1
  105. package/development/overlay/overlay-base-element.js +19 -15
  106. package/development/overlay/overlay.component.d.ts +3 -0
  107. package/development/overlay/overlay.component.d.ts.map +1 -1
  108. package/development/overlay/overlay.component.js +19 -2
  109. package/development/overlay.js +3 -1
  110. package/development/paginator/paginator/paginator.component.js +2 -3
  111. package/development/{sbb-tokens-CZCt5L4q.js → sbb-tokens-DQT_xEIZ.js} +7 -7
  112. package/development/stepper/step/step.component.d.ts +4 -0
  113. package/development/stepper/step/step.component.d.ts.map +1 -1
  114. package/development/stepper/step/step.component.js +5 -1
  115. package/development/stepper/stepper/stepper.component.d.ts +15 -0
  116. package/development/stepper/stepper/stepper.component.d.ts.map +1 -1
  117. package/development/stepper/stepper/stepper.component.js +19 -4
  118. package/development/stepper/stepper.js +2 -1
  119. package/development/stepper.js +2 -1
  120. package/dialog/dialog/dialog.component.d.ts +4 -0
  121. package/dialog/dialog/dialog.component.d.ts.map +1 -1
  122. package/dialog/dialog/dialog.component.js +46 -26
  123. package/dialog/dialog-actions/dialog-actions.component.js +1 -1
  124. package/dialog/dialog.js +5 -2
  125. package/dialog.js +9 -6
  126. package/divider/divider.component.d.ts +2 -2
  127. package/divider/divider.component.d.ts.map +1 -1
  128. package/divider/divider.component.js +12 -12
  129. package/expansion-panel/expansion-panel/expansion-panel.component.d.ts.map +1 -1
  130. package/expansion-panel/expansion-panel/expansion-panel.component.js +31 -31
  131. package/expansion-panel/expansion-panel-content/expansion-panel-content.component.d.ts.map +1 -1
  132. package/expansion-panel/expansion-panel-content/expansion-panel-content.component.js +10 -14
  133. package/expansion-panel/expansion-panel-header/expansion-panel-header.component.js +19 -19
  134. package/flip-card/flip-card/flip-card.component.js +11 -11
  135. package/form-field/form-field/form-field.component.d.ts +2 -0
  136. package/form-field/form-field/form-field.component.d.ts.map +1 -1
  137. package/form-field/form-field/form-field.component.js +5 -1
  138. package/image/image.component.js +1 -1
  139. package/index.d.ts +2 -0
  140. package/index.js +2 -0
  141. package/lead-container/lead-container.component.d.ts +3 -1
  142. package/lead-container/lead-container.component.d.ts.map +1 -1
  143. package/lead-container/lead-container.component.js +9 -8
  144. package/{mini-button-common-Bb4ri3Rn.js → mini-button-label-common-ps7PVXtB.js} +4 -3
  145. package/navigation/navigation-section/navigation-section.component.js +1 -1
  146. package/normalize.css +4 -6
  147. package/off-brand-theme.css +36 -10
  148. package/option/option-hint/option-hint.component.js +7 -7
  149. package/overlay/overlay-base-element.d.ts +29 -3
  150. package/overlay/overlay-base-element.d.ts.map +1 -1
  151. package/overlay/overlay-base-element.js +51 -54
  152. package/overlay/overlay.component.d.ts +3 -0
  153. package/overlay/overlay.component.d.ts.map +1 -1
  154. package/overlay/overlay.component.js +48 -31
  155. package/overlay.js +7 -5
  156. package/package.json +6 -1
  157. package/paginator/paginator/paginator.component.js +1 -1
  158. package/safety-theme.css +36 -10
  159. package/{sbb-tokens-DruExozg.js → sbb-tokens-HiNSQasB.js} +6 -6
  160. package/standard-theme.css +36 -10
  161. package/stepper/step/step.component.d.ts +4 -0
  162. package/stepper/step/step.component.d.ts.map +1 -1
  163. package/stepper/step/step.component.js +4 -0
  164. package/stepper/stepper/stepper.component.d.ts +15 -0
  165. package/stepper/stepper/stepper.component.d.ts.map +1 -1
  166. package/stepper/stepper/stepper.component.js +41 -33
  167. package/stepper/stepper.js +3 -2
  168. package/stepper.js +4 -3
@@ -1,57 +1,64 @@
1
- var z = (s) => {
2
- throw TypeError(s);
1
+ var x = (i) => {
2
+ throw TypeError(i);
3
3
  };
4
- var I = (s, a, r) => a.has(s) || z("Cannot " + r);
5
- var b = (s, a, r) => (I(s, a, "read from private field"), r ? r.call(s) : a.get(s)), _ = (s, a, r) => a.has(s) ? z("Cannot add the same private member more than once") : a instanceof WeakSet ? a.add(s) : a.set(s, r), d = (s, a, r, h) => (I(s, a, "write to private field"), h ? h.call(s, r) : a.set(s, r), r);
6
- import { __esDecorate as m, __runInitializers as c } from "tslib";
7
- import { css as O, LitElement as K, isServer as f, html as F } from "lit";
8
- import { customElement as W, property as v } from "lit/decorators.js";
4
+ var I = (i, a, r) => a.has(i) || x("Cannot " + r);
5
+ var d = (i, a, r) => (I(i, a, "read from private field"), r ? r.call(i) : a.get(i)), _ = (i, a, r) => a.has(i) ? x("Cannot add the same private member more than once") : a instanceof WeakSet ? a.add(i) : a.set(i, r), m = (i, a, r, p) => (I(i, a, "write to private field"), p ? p.call(i, r) : a.set(i, r), r);
6
+ import { __esDecorate as c, __runInitializers as b } from "tslib";
7
+ import { css as K, LitElement as L, isServer as A, html as O } from "lit";
8
+ import { customElement as W, property as g } from "lit/decorators.js";
9
9
  import { isArrowKeyPressed as T, getNextElementIndex as q } from "../../core/a11y.js";
10
- import { SbbLanguageController as L } from "../../core/controllers.js";
11
- import { isLean as M } from "../../core/dom.js";
12
- import { i18nSelectionRequired as V, i18nChipGroupInputDescription as R } from "../../core/i18n.js";
13
- import { SbbRequiredMixin as $, SbbDisabledMixin as B, SbbNegativeMixin as N, SbbFormAssociatedMixin as j, SbbElementInternalsMixin as G } from "../../core/mixins.js";
14
- import { boxSizingStyles as U } from "../../core/styles.js";
15
- import { SbbChipElement as J } from "../chip.js";
16
- const H = O`:host{--sbb-chip-group-input-min-width: 9.375rem;max-width:100%}:host(:is(:state(size-s),[state--size-s]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: .375rem .3125rem}@media(min-width:64rem){:host(:is(:state(size-s),[state--size-s]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: .3125rem .1875rem}}::slotted(input){flex:1 1 var(--sbb-chip-group-input-min-width)}::slotted(sbb-chip){max-width:100%}.sbb-chip-group{width:100%;display:flex;flex-wrap:wrap;gap:var(--sbb-spacing-fixed-1x);align-items:center;margin-block:var(--sbb-chip-group-margin-block)}`;
17
- let lt = (() => {
18
- var p, u, l;
19
- let s = [W("sbb-chip-group")], a, r = [], h, y = $(B(N(j(G(K))))), g = [], E, C, S = [], w = [], x, k = [], A = [];
20
- return l = class extends y {
10
+ import { SbbLanguageController as F, SbbPropertyWatcherController as M } from "../../core/controllers.js";
11
+ import { isLean as V } from "../../core/dom/lean-context.js";
12
+ import { i18nSelectionRequired as R, i18nChipGroupInputDescription as $ } from "../../core/i18n.js";
13
+ import { SbbRequiredMixin as B, SbbDisabledMixin as N, SbbNegativeMixin as j, SbbFormAssociatedMixin as G, SbbElementInternalsMixin as U } from "../../core/mixins.js";
14
+ import { boxSizingStyles as J } from "../../core/styles.js";
15
+ import { SbbChipElement as P } from "../chip.js";
16
+ const H = K`:host{--sbb-chip-group-input-min-width: 9.375rem;--_sbb-chip-group-margin-block-start-default: .125rem;--_sbb-chip-group-margin-block-start-default-large: .21875rem;max-width:100%}:host(:is(:state(size-s),[state--size-s]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: .375rem .3125rem}@media(min-width:64rem){:host(:is(:state(size-s),[state--size-s]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: .3125rem .1875rem}}:host(:is(:state(without-label),[state--without-label]):is(:state(size-s),[state--size-s]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: 0 .4375rem}@media(min-width:64rem){:host(:is(:state(without-label),[state--without-label]):is(:state(size-s),[state--size-s]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: 0 .3125rem}}:host(:is(:is(:state(size-l),[state--size-l]),:is(:state(size-m),[state--size-m]))){--sbb-chip-group-margin-block: var(--_sbb-chip-group-margin-block-start-default) var(0)}@media(min-width:64rem){:host(:is(:is(:state(size-l),[state--size-l]),:is(:state(size-m),[state--size-m]))){--sbb-chip-group-margin-block: var(--_sbb-chip-group-margin-block-start-default-large) var(0)}}:host(:is(:state(without-label),[state--without-label]):is(:state(size-m),[state--size-m]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: .1875rem .6875rem}@media(min-width:64rem){:host(:is(:state(without-label),[state--without-label]):is(:state(size-m),[state--size-m]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: .1875rem .875rem}}:host(:not(:is(:state(without-label),[state--without-label])):is(:state(size-m),[state--size-m]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: var(--_sbb-chip-group-margin-block-start-default) var(--_sbb-chip-group-margin-block-start-default-large)}@media(min-width:64rem){:host(:not(:is(:state(without-label),[state--without-label])):is(:state(size-m),[state--size-m]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: var(--_sbb-chip-group-margin-block-start-default-large) var(--_sbb-chip-group-margin-block-start-default-large)}}:host(:is(:state(without-label),[state--without-label]):is(:state(size-l),[state--size-l]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: var(--_sbb-chip-group-margin-block-start-default) 1rem}@media(min-width:64rem){:host(:is(:state(without-label),[state--without-label]):is(:state(size-l),[state--size-l]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: var(--_sbb-chip-group-margin-block-start-default-large) 1.25rem}}:host(:not(:is(:state(without-label),[state--without-label])):is(:state(size-l),[state--size-l]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: var(--_sbb-chip-group-margin-block-start-default) .46875rem}@media(min-width:64rem){:host(:not(:is(:state(without-label),[state--without-label])):is(:state(size-l),[state--size-l]):not(:is(:state(empty),[state--empty]))){--sbb-chip-group-margin-block: var(--_sbb-chip-group-margin-block-start-default-large) .46875rem}}::slotted(input){flex:1 1 var(--sbb-chip-group-input-min-width);max-height:1.5rem}::slotted(sbb-chip){max-width:100%}.sbb-chip-group{width:100%;display:flex;flex-wrap:wrap;gap:var(--sbb-spacing-fixed-1x);align-items:center;margin-block:var(--sbb-chip-group-margin-block)}`;
17
+ let ot = (() => {
18
+ var h, u, n;
19
+ let i = [W("sbb-chip-group")], a, r = [], p, f = B(N(j(G(U(L))))), y = [], v, w, E = [], z = [], k, C = [], S = [];
20
+ return n = class extends f {
21
21
  constructor() {
22
22
  super();
23
- _(this, p);
23
+ _(this, h);
24
24
  _(this, u);
25
- d(this, p, (c(this, g), c(this, S, null))), d(this, u, (c(this, w), c(this, k, ["Enter"]))), this._inputAttributeObserver = (c(this, A), f ? null : new MutationObserver(() => this._reactToInputChanges())), this._formFieldAttributeObserver = f ? null : new MutationObserver(() => this._inheritSize()), this._language = new L(this), this.addEventListener?.(J.events.requestdelete, (t) => this._deleteChip(t.target)), this.addEventListener?.("keydown", (t) => this._onChipKeyDown(t));
25
+ m(this, h, (b(this, y), b(this, E, null))), m(this, u, (b(this, z), b(this, C, ["Enter"]))), this._inputAttributeObserver = (b(this, S), A ? null : new MutationObserver(() => this._reactToInputChanges())), this._language = new F(this), this.addEventListener?.(P.events.requestdelete, (t) => this._deleteChip(t.target)), this.addEventListener?.("keydown", (t) => this._onChipKeyDown(t)), this.addController(new M(this, () => this.closest("sbb-form-field"), {
26
+ size: (t) => this._updateSize(t.size),
27
+ label: (t) => this._updateLabelState(t),
28
+ hiddenLabel: (t) => this._updateLabelState(t)
29
+ }));
26
30
  }
27
31
  /** Value of the form element. */
28
32
  set value(t) {
29
33
  t = t ?? [];
30
- const e = this.value, i = [...e];
31
- for (const n of t)
32
- i.includes(n) && i.splice(i.indexOf(n), 1);
33
- i.forEach((n) => this._chipElements().find((D) => D.value === n)?.remove());
34
+ const e = this.value, s = [...e];
35
+ for (const l of t)
36
+ s.includes(l) && s.splice(s.indexOf(l), 1);
37
+ s.forEach((l) => this._chipElements().find((D) => D.value === l)?.remove());
34
38
  const o = [...t];
35
- for (const n of e)
36
- o.includes(n) && o.splice(o.indexOf(n), 1);
37
- o.forEach((n) => this._createChipElement(n));
39
+ for (const l of e)
40
+ o.includes(l) && o.splice(o.indexOf(l), 1);
41
+ o.forEach((l) => this._createChipElement(l));
38
42
  }
39
43
  get value() {
40
44
  return this._chipElements().map((t) => t.value);
41
45
  }
42
46
  /** Function that maps a chip's value to its display value. */
43
47
  get displayWith() {
44
- return b(this, p);
48
+ return d(this, h);
45
49
  }
46
50
  set displayWith(t) {
47
- d(this, p, t);
51
+ m(this, h, t);
48
52
  }
49
53
  /** The array of keys that will trigger a `chipinputtokenend` event. Default `['Enter']` */
50
54
  get separatorKeys() {
51
- return b(this, u);
55
+ return d(this, u);
52
56
  }
53
57
  set separatorKeys(t) {
54
- d(this, u, t);
58
+ m(this, u, t);
59
+ }
60
+ _updateLabelState(t) {
61
+ this.toggleState("without-label", !t.label || t.hiddenLabel);
55
62
  }
56
63
  connectedCallback() {
57
64
  super.connectedCallback(), this._setupComponent();
@@ -69,7 +76,7 @@ let lt = (() => {
69
76
  this.value = null;
70
77
  return;
71
78
  }
72
- this._readFormData(t).then((i) => this.value = i);
79
+ this._readFormData(t).then((s) => this.value = s);
73
80
  }
74
81
  async _readFormData(t) {
75
82
  return Promise.all(t.getAll(this.name).map(async (e) => e instanceof Blob ? JSON.parse(await e.text()) : e));
@@ -78,7 +85,7 @@ let lt = (() => {
78
85
  return super.shouldValidate(t) || t === "required" || t === "value";
79
86
  }
80
87
  validate() {
81
- super.validate(), this.required && this.value.length === 0 ? this.setValidityFlag("valueMissing", V[this._language.current]) : this.removeValidityFlag("valueMissing");
88
+ super.validate(), this.required && this.value.length === 0 ? this.setValidityFlag("valueMissing", R[this._language.current]) : this.removeValidityFlag("valueMissing");
82
89
  }
83
90
  /** Return the list of chip elements **/
84
91
  _chipElements() {
@@ -90,21 +97,16 @@ let lt = (() => {
90
97
  }
91
98
  _setupComponent() {
92
99
  const t = this.querySelector("input");
93
- t && t !== this._inputElement && (this._inputAbortController?.abort(), this._inputAttributeObserver?.disconnect(), this._inputElement = t, this._inputAbortController = new AbortController(), this._inputElement.addEventListener("keydown", (i) => this._onInputKeyDown(i), {
100
+ t && t !== this._inputElement && (this._inputAbortController?.abort(), this._inputAttributeObserver?.disconnect(), this._inputElement = t, this._inputAbortController = new AbortController(), this._inputElement.addEventListener("keydown", (e) => this._onInputKeyDown(e), {
94
101
  signal: this._inputAbortController.signal
95
- }), this._inputElement.addEventListener("inputAutocomplete", (i) => {
96
- this._createChipFromInput("autocomplete", i.detail?.option.value);
102
+ }), this._inputElement.addEventListener("inputAutocomplete", (e) => {
103
+ this._createChipFromInput("autocomplete", e.detail?.option.value);
97
104
  }, {
98
105
  signal: this._inputAbortController.signal
99
106
  }), this._inputAttributeObserver?.observe(this._inputElement, {
100
107
  attributes: !0,
101
108
  attributeFilter: ["readonly", "disabled"]
102
- })), this._inheritSize(), this._formFieldAttributeObserver?.disconnect();
103
- const e = this.closest("sbb-form-field");
104
- e && this._formFieldAttributeObserver?.observe(e, {
105
- attributes: !0,
106
- attributeFilter: ["size"]
107
- }), this.toggleState("empty", this.value.length === 0), this._reactToInputChanges(), this._updateInputDescription(), this.updateFormValue();
109
+ })), (!this._previousSize || !this.closest("sbb-form-field")) && this._updateSize(V() ? "s" : "m"), this.toggleState("empty", this.value.length === 0), this._reactToInputChanges(), this._updateInputDescription(), this.updateFormValue();
108
110
  }
109
111
  /**
110
112
  * Listen for keyboard events on the chip elements
@@ -113,8 +115,8 @@ let lt = (() => {
113
115
  const e = t.target;
114
116
  if (e.localName === "sbb-chip") {
115
117
  if (T(t)) {
116
- const i = this._enabledChipElements(), o = q(t, i.indexOf(e), i.length);
117
- i[o].focus();
118
+ const s = this._enabledChipElements(), o = q(t, s.indexOf(e), s.length);
119
+ s[o].focus();
118
120
  return;
119
121
  }
120
122
  switch (t.key) {
@@ -144,15 +146,15 @@ let lt = (() => {
144
146
  * If the input is not empty, create a chip with its value
145
147
  */
146
148
  _createChipFromInput(t = "input", e) {
147
- const i = e ?? this._inputElement.value.trim();
148
- if (!i)
149
+ const s = e ?? this._inputElement.value.trim();
150
+ if (!s)
149
151
  return;
150
152
  const o = {
151
153
  origin: t,
152
- value: i,
154
+ value: s,
153
155
  label: (e ? this.displayWith?.(e) : null) ?? void 0,
154
- setValue: (n) => o.value = n,
155
- setLabel: (n) => o.label = n
156
+ setValue: (l) => o.value = l,
157
+ setLabel: (l) => o.label = l
156
158
  };
157
159
  this._dispatchChipInputTokenEnd(o) && (this._createChipElement(o.value, o.label), this._inputElement.value = "", this._emitInputEvents());
158
160
  }
@@ -188,10 +190,10 @@ let lt = (() => {
188
190
  this.dispatchEvent(new InputEvent("input", { bubbles: !0, composed: !0 })), this.dispatchEvent(new Event("change", { bubbles: !0 }));
189
191
  }
190
192
  _createChipElement(t, e) {
191
- if (f)
193
+ if (A)
192
194
  return;
193
- const i = document.createElement("sbb-chip");
194
- i.value = t, i.innerText = e ?? (t ? this.displayWith?.(t) : null) ?? "", this.insertBefore(i, this._inputElement ?? this.querySelector("input"));
195
+ const s = document.createElement("sbb-chip");
196
+ s.value = t, s.innerText = e ?? (t ? this.displayWith?.(t) : null) ?? "", this.insertBefore(s, this._inputElement ?? this.querySelector("input"));
195
197
  }
196
198
  _reactToInputChanges() {
197
199
  this.disabled = this._inputElement?.disabled ?? !1, this._proxyStateToChips();
@@ -201,34 +203,34 @@ let lt = (() => {
201
203
  t.disabled = this.disabled || this.formDisabled, t.readOnly = this._inputElement?.hasAttribute("readonly") ?? !1, t.negative = this.negative;
202
204
  });
203
205
  }
204
- _inheritSize() {
205
- this._previousSize && this.internals.states.delete(`size-${this._previousSize}`), this._previousSize = this.closest("sbb-form-field")?.size ?? (M() ? "s" : "m"), this._previousSize && this.internals.states.add(`size-${this._previousSize}`);
206
+ _updateSize(t) {
207
+ this._previousSize && this.internals.states.delete(`size-${this._previousSize}`), this._previousSize = t, this._previousSize && this.internals.states.add(`size-${this._previousSize}`);
206
208
  }
207
209
  _updateInputDescription() {
208
- this._inputElement && this._inputElement.setAttribute("aria-description", `${R[this._language.current]} ${this.value.length}`);
210
+ this._inputElement && this._inputElement.setAttribute("aria-description", `${$[this._language.current]} ${this.value.length}`);
209
211
  }
210
212
  render() {
211
- return F`
213
+ return O`
212
214
  <div class="sbb-chip-group">
213
215
  <slot @slotchange=${this._setupComponent}></slot>
214
216
  </div>
215
217
  `;
216
218
  }
217
- }, p = new WeakMap(), u = new WeakMap(), h = l, (() => {
218
- const t = typeof Symbol == "function" && Symbol.metadata ? Object.create(y[Symbol.metadata] ?? null) : void 0;
219
- E = [v({ type: Array })], C = [v({ attribute: !1 })], x = [v({ attribute: "separator-keys", type: Array })], m(l, null, E, { kind: "setter", name: "value", static: !1, private: !1, access: { has: (e) => "value" in e, set: (e, i) => {
220
- e.value = i;
221
- } }, metadata: t }, null, g), m(l, null, C, { kind: "accessor", name: "displayWith", static: !1, private: !1, access: { has: (e) => "displayWith" in e, get: (e) => e.displayWith, set: (e, i) => {
222
- e.displayWith = i;
223
- } }, metadata: t }, S, w), m(l, null, x, { kind: "accessor", name: "separatorKeys", static: !1, private: !1, access: { has: (e) => "separatorKeys" in e, get: (e) => e.separatorKeys, set: (e, i) => {
224
- e.separatorKeys = i;
225
- } }, metadata: t }, k, A), m(null, a = { value: h }, s, { kind: "class", name: h.name, metadata: t }, null, r), h = a.value, t && Object.defineProperty(h, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: t });
226
- })(), l.role = "listbox", l.styles = [U, H], l.events = {
219
+ }, h = new WeakMap(), u = new WeakMap(), p = n, (() => {
220
+ const t = typeof Symbol == "function" && Symbol.metadata ? Object.create(f[Symbol.metadata] ?? null) : void 0;
221
+ v = [g({ type: Array })], w = [g({ attribute: !1 })], k = [g({ attribute: "separator-keys", type: Array })], c(n, null, v, { kind: "setter", name: "value", static: !1, private: !1, access: { has: (e) => "value" in e, set: (e, s) => {
222
+ e.value = s;
223
+ } }, metadata: t }, null, y), c(n, null, w, { kind: "accessor", name: "displayWith", static: !1, private: !1, access: { has: (e) => "displayWith" in e, get: (e) => e.displayWith, set: (e, s) => {
224
+ e.displayWith = s;
225
+ } }, metadata: t }, E, z), c(n, null, k, { kind: "accessor", name: "separatorKeys", static: !1, private: !1, access: { has: (e) => "separatorKeys" in e, get: (e) => e.separatorKeys, set: (e, s) => {
226
+ e.separatorKeys = s;
227
+ } }, metadata: t }, C, S), c(null, a = { value: p }, i, { kind: "class", name: p.name, metadata: t }, null, r), p = a.value, t && Object.defineProperty(p, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: t });
228
+ })(), n.role = "listbox", n.styles = [J, H], n.events = {
227
229
  input: "input",
228
230
  change: "change",
229
231
  chipinputtokenend: "chipinputtokenend"
230
- }, c(h, r), h;
232
+ }, b(p, r), p;
231
233
  })();
232
234
  export {
233
- lt as SbbChipGroupElement
235
+ ot as SbbChipGroupElement
234
236
  };
@@ -1,7 +1,7 @@
1
- import { S as m, a as b, b as p, c as f, d as g, e as y } from "../../sbb-tokens-DruExozg.js";
1
+ import { S as m, a as b, b as p, c as f, d as g, e as y } from "../../sbb-tokens-HiNSQasB.js";
2
2
  import { isServer as i } from "lit";
3
3
  import { ɵstateController as M } from "../mixins/element-internals-mixin.js";
4
- const L = "(forced-colors: active)", n = "(prefers-color-scheme: dark)", w = "(any-hover: hover)", A = "(pointer: coarse)", C = `(min-width: ${m})`, _ = `(min-width: ${b})`, q = `(min-width: ${p})`, U = `(min-width: ${f})`, x = `(max-width: ${g})`, E = `(max-width: ${y})`, a = /* @__PURE__ */ new Map();
4
+ const L = "(forced-colors: active)", n = "(prefers-color-scheme: dark)", w = "(any-hover: hover)", A = "(pointer: coarse)", C = `(min-width: ${y})`, _ = `(min-width: ${p})`, q = `(min-width: ${m})`, U = `(min-width: ${g})`, x = `(max-width: ${f})`, E = `(max-width: ${b})`, a = /* @__PURE__ */ new Map();
5
5
  class S {
6
6
  constructor(e, t) {
7
7
  this._queries = t, e.addController(this);
@@ -1,3 +1,4 @@
1
+ /** @deprecated */
1
2
  export type SbbOverlayCloseEventDetails = {
2
3
  returnValue?: any;
3
4
  closeTarget?: HTMLElement;
@@ -1 +1 @@
1
- {"version":3,"file":"overlay-close-details.d.ts","sourceRoot":"","sources":["../../../../src/elements/core/interfaces/overlay-close-details.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,2BAA2B,GAAG;IACxC,WAAW,CAAC,EAAE,GAAG,CAAC;IAClB,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B,CAAC"}
1
+ {"version":3,"file":"overlay-close-details.d.ts","sourceRoot":"","sources":["../../../../src/elements/core/interfaces/overlay-close-details.ts"],"names":[],"mappings":"AAAA,kBAAkB;AAClB,MAAM,MAAM,2BAA2B,GAAG;IACxC,WAAW,CAAC,EAAE,GAAG,CAAC;IAClB,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B,CAAC"}
@@ -32,6 +32,20 @@ $theme: 'standard' !default;
32
32
  @use '../../checkbox/common/checkbox-common.global' as checkbox-common with (
33
33
  $theme: $theme
34
34
  );
35
+ @use '../../divider/divider.global' as divider with (
36
+ $theme: $theme
37
+ );
38
+ @use '../../expansion-panel/expansion-panel/expansion-panel.global' as expansion-panel with (
39
+ $theme: $theme
40
+ );
41
+ @use '../../expansion-panel/expansion-panel-content/expansion-panel-content.global' as
42
+ expansion-panel-content with (
43
+ $theme: $theme
44
+ );
45
+ @use '../../expansion-panel/expansion-panel-header/expansion-panel-header.global' as
46
+ expansion-panel-header with (
47
+ $theme: $theme
48
+ );
35
49
  @use '../../radio-button/common/radio-button-common.global' as radio-button-common with (
36
50
  $theme: $theme
37
51
  );
@@ -71,6 +85,10 @@ $theme: 'standard' !default;
71
85
  @include checkbox.base;
72
86
  @include checkbox-group.base;
73
87
  @include checkbox-common.base;
88
+ @include divider.base;
89
+ @include expansion-panel.base;
90
+ @include expansion-panel-content.base;
91
+ @include expansion-panel-header.base;
74
92
  @include radio-button-common.base;
75
93
  @include radio-button-group.base;
76
94
  @include selection-action-panel.base;
@@ -84,6 +102,7 @@ $theme: 'standard' !default;
84
102
 
85
103
  @include card.base-forced-colors;
86
104
  @include card-badge.base-forced-colors;
105
+ @include expansion-panel-header.base-forced-colors;
87
106
  @include visual-checkbox.base-forced-colors;
88
107
  @include radio-button-common.base-forced-colors;
89
108
  }
@@ -1,6 +1,5 @@
1
1
  @mixin button-reset {
2
- -webkit-appearance: none;
3
- -moz-appearance: none;
2
+ appearance: none;
4
3
  box-sizing: border-box;
5
4
  margin: 0;
6
5
  outline: none;
@@ -13,21 +13,21 @@
13
13
  --sbb-card-border-radius: var(--sbb-border-radius-4x);
14
14
  --sbb-card-animation-easing: var(--sbb-animation-easing);
15
15
  --sbb-card-border-style: solid;
16
- --sbb-card-padding-inline: #{functions.theme-pattern-select(
16
+ --sbb-card-padding-inline-default: #{functions.theme-pattern-select(
17
17
  (
18
18
  'standard': var(--sbb-spacing-responsive-s),
19
19
  'lean': var(--sbb-spacing-responsive-xxs),
20
20
  ),
21
21
  $theme
22
22
  )};
23
- --sbb-card-padding-block: #{functions.theme-pattern-select(
23
+ --sbb-card-padding-block-default: #{functions.theme-pattern-select(
24
24
  (
25
25
  'standard': var(--sbb-spacing-responsive-xxxs),
26
26
  'lean': var(--sbb-spacing-fixed-3x),
27
27
  ),
28
28
  $theme
29
29
  )};
30
- --sbb-card-with-badge-padding-block: #{functions.theme-pattern-select(
30
+ --sbb-card-with-badge-padding-block-default: #{functions.theme-pattern-select(
31
31
  (
32
32
  'standard': var(--sbb-spacing-fixed-6x) var(--sbb-spacing-responsive-xxxs),
33
33
  'lean': var(--sbb-spacing-fixed-6x) var(--sbb-spacing-fixed-3x),
@@ -85,6 +85,12 @@
85
85
  }
86
86
 
87
87
  // Card sizing
88
+ @mixin card-variables--spacing-default {
89
+ --sbb-card-padding-block: var(--sbb-card-padding-block-default);
90
+ --sbb-card-with-badge-padding-block: var(--sbb-card-with-badge-padding-block-default);
91
+ --sbb-card-padding-inline: var(--sbb-card-padding-inline-default);
92
+ }
93
+
88
94
  @mixin card-variables--spacing-3x-xxs {
89
95
  --sbb-card-padding-block: var(--sbb-spacing-fixed-3x);
90
96
  --sbb-card-with-badge-padding-block: var(--sbb-spacing-fixed-6x) var(--sbb-spacing-fixed-3x);
@@ -7,5 +7,5 @@
7
7
  border: none;
8
8
  background-color: transparent;
9
9
  padding: 0;
10
- -webkit-appearance: none;
10
+ appearance: none;
11
11
  }
@@ -8,8 +8,6 @@
8
8
  // 3. Use a more readable tab size (opinionated).
9
9
  html {
10
10
  // line-height: 1.15; // 1
11
- -webkit-text-size-adjust: 100%; // 2
12
- -moz-text-size-adjust: 100%; // 2
13
11
  text-size-adjust: 100%; // 2
14
12
  tab-size: 4; // 3
15
13
  }
@@ -94,7 +92,7 @@ select {
94
92
  // Correct the inability to style clickable types in iOS and Safari.
95
93
  button,
96
94
  :is(button, input):where([type='button'], [type='reset'], [type='submit']) {
97
- -webkit-appearance: button;
95
+ appearance: auto;
98
96
  }
99
97
 
100
98
  // Remove the additional ':invalid' styles in Firefox.
@@ -122,19 +120,19 @@ progress {
122
120
  // 1. Correct the odd appearance in Chrome and Safari.
123
121
  // 2. Correct the outline style in Safari.
124
122
  [type='search'] {
125
- -webkit-appearance: textfield; // 1
123
+ appearance: textfield; // 1
126
124
  outline-offset: -2px; // 2
127
125
  }
128
126
 
129
127
  // Remove the inner padding in Chrome and Safari on macOS.
130
128
  ::-webkit-search-decoration {
131
- -webkit-appearance: none;
129
+ appearance: none;
132
130
  }
133
131
 
134
132
  // 1. Correct the inability to style clickable types in iOS and Safari.
135
133
  // 2. Change font properties to 'inherit' in Safari.
136
134
  ::-webkit-file-upload-button {
137
- -webkit-appearance: button; // 1
135
+ appearance: auto; // 1
138
136
  font: inherit; // 2
139
137
  }
140
138
 
package/core.css CHANGED
@@ -1246,9 +1246,9 @@
1246
1246
  --sbb-card-border-radius: var(--sbb-border-radius-4x);
1247
1247
  --sbb-card-animation-easing: var(--sbb-animation-easing);
1248
1248
  --sbb-card-border-style: solid;
1249
- --sbb-card-padding-inline: var(--sbb-spacing-responsive-s);
1250
- --sbb-card-padding-block: var(--sbb-spacing-responsive-xxxs);
1251
- --sbb-card-with-badge-padding-block: var(--sbb-spacing-fixed-6x) var(--sbb-spacing-responsive-xxxs);
1249
+ --sbb-card-padding-inline-default: var(--sbb-spacing-responsive-s);
1250
+ --sbb-card-padding-block-default: var(--sbb-spacing-responsive-xxxs);
1251
+ --sbb-card-with-badge-padding-block-default: var(--sbb-spacing-fixed-6x) var(--sbb-spacing-responsive-xxxs);
1252
1252
  }
1253
1253
  :root.sbb-lean {
1254
1254
  --sbb-card-padding-inline: var(--sbb-spacing-responsive-xxs);
@@ -1301,6 +1301,33 @@
1301
1301
  --sbb-checkbox-font-size: var(--sbb-text-font-size-m);
1302
1302
  --sbb-checkbox-label-color: var(--sbb-color-color-3);
1303
1303
  --sbb-checkbox-cursor: var(--sbb-cursor-pointer);
1304
+ --sbb-divider-color: var(--sbb-background-color-4);
1305
+ --sbb-divider-color-negative: var(--sbb-background-color-4-negative);
1306
+ --sbb-divider-border-width: var(--sbb-border-width-1x);
1307
+ --sbb-expansion-panel-background-color: var(--sbb-background-color-1);
1308
+ --sbb-expansion-panel-background-color-hover: var(--sbb-background-color-3);
1309
+ --sbb-expansion-panel-border-radius: var(--sbb-border-radius-4x);
1310
+ --sbb-expansion-panel-icon-size: var(--sbb-size-icon-ui-medium);
1311
+ --sbb-expansion-panel-title-gap-s: var(--sbb-spacing-fixed-2x);
1312
+ --sbb-expansion-panel-title-gap-l: var(--sbb-spacing-fixed-4x);
1313
+ --sbb-expansion-panel-title-gap-default: var(--sbb-expansion-panel-title-gap-l);
1314
+ --sbb-expansion-panel-content-padding-block-end: var(--sbb-spacing-responsive-s);
1315
+ --sbb-expansion-panel-content-padding-inline-s: var(--sbb-spacing-fixed-5x);
1316
+ --sbb-expansion-panel-content-padding-inline-l: var(--sbb-spacing-fixed-6x);
1317
+ --sbb-expansion-panel-content-padding-inline-default: var(--sbb-expansion-panel-content-padding-inline-l);
1318
+ --sbb-expansion-panel-header-cursor: var(--sbb-cursor-pointer);
1319
+ --sbb-expansion-panel-header-font-size: var(--sbb-text-font-size-l);
1320
+ --sbb-expansion-panel-header-text-color: var(--sbb-color-2);
1321
+ --sbb-expansion-panel-header-justify-content: space-between;
1322
+ --sbb-expansion-panel-header-gap-s: var(--sbb-spacing-fixed-2x);
1323
+ --sbb-expansion-panel-header-gap-l: var(--sbb-spacing-fixed-6x);
1324
+ --sbb-expansion-panel-header-gap-default: var(--sbb-expansion-panel-header-gap-l);
1325
+ --sbb-expansion-panel-header-padding-block-s: var(--sbb-spacing-fixed-3x);
1326
+ --sbb-expansion-panel-header-padding-block-l: var(--sbb-spacing-responsive-xs);
1327
+ --sbb-expansion-panel-header-padding-block-default: var(--sbb-expansion-panel-header-padding-block-l);
1328
+ --sbb-expansion-panel-header-padding-inline-s: var(--sbb-spacing-fixed-5x);
1329
+ --sbb-expansion-panel-header-padding-inline-l: var(--sbb-spacing-fixed-6x);
1330
+ --sbb-expansion-panel-header-padding-inline-default: var(--sbb-expansion-panel-header-padding-inline-l);
1304
1331
  --sbb-radio-button-label-color: var(--sbb-color-3);
1305
1332
  --sbb-radio-button-background-color: var(--sbb-background-color-1);
1306
1333
  --sbb-radio-button-border-width: var(--sbb-border-width-1x);
@@ -1379,6 +1406,7 @@
1379
1406
  --sbb-card-border-width: var(--sbb-border-width-2x);
1380
1407
  --sbb-card-badge-border-display: block;
1381
1408
  --sbb-card-badge-inline-border-display: none;
1409
+ --sbb-expansion-panel-header-text-color: ButtonText;
1382
1410
  --sbb-visual-checkbox-selection-color: Canvas;
1383
1411
  --sbb-visual-checkbox-selection-color-negative: Canvas;
1384
1412
  --sbb-visual-checkbox-selection-color-disabled: Canvas;
@@ -1573,7 +1601,7 @@ html {
1573
1601
  border: none;
1574
1602
  background-color: transparent;
1575
1603
  padding: 0;
1576
- -webkit-appearance: none;
1604
+ appearance: none;
1577
1605
  outline: none !important;
1578
1606
  overflow: var(--sbb-form-field-overflow);
1579
1607
  width: 100%;