@sbb-esta/lyne-elements 2.0.2 → 2.1.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.
- package/accordion/accordion.d.ts.map +1 -1
- package/accordion.js +6 -6
- package/alert/alert.js +8 -8
- package/autocomplete/autocomplete-base-element.d.ts.map +1 -1
- package/autocomplete-grid/autocomplete-grid-button.js +4 -4
- package/autocomplete-grid/autocomplete-grid-optgroup.js +4 -4
- package/autocomplete-grid/autocomplete-grid-option/autocomplete-grid-option.d.ts +1 -1
- package/autocomplete-grid/autocomplete-grid-option/autocomplete-grid-option.d.ts.map +1 -1
- package/autocomplete-grid/autocomplete-grid-option.js +10 -10
- package/autocomplete-grid/autocomplete-grid-row.js +4 -4
- package/autocomplete.js +92 -89
- package/breadcrumb/breadcrumb-group.js +4 -4
- package/button/accent-button-link.js +9 -9
- package/button/accent-button-static.js +6 -6
- package/button/accent-button.js +6 -6
- package/button/button-link.js +7 -7
- package/button/button-static.js +7 -7
- package/button/button.js +8 -8
- package/button/common.js +1 -1
- package/button/mini-button-group.js +8 -8
- package/button/secondary-button-link.js +7 -7
- package/button/secondary-button-static.js +7 -7
- package/button/secondary-button.js +3 -3
- package/button/transparent-button-link.js +6 -6
- package/button/transparent-button-static.js +5 -5
- package/button/transparent-button.js +6 -6
- package/card/card-badge.js +9 -9
- package/card/card-button.js +5 -5
- package/card/card-link.js +7 -7
- package/checkbox/checkbox-panel.js +16 -16
- package/checkbox/checkbox.js +15 -15
- package/checkbox/common.js +3 -3
- package/clock.js +8 -8
- package/container/container/container.d.ts +1 -1
- package/container/container/container.d.ts.map +1 -1
- package/container/container.js +21 -21
- package/container/sticky-bar/sticky-bar.d.ts +1 -1
- package/container/sticky-bar/sticky-bar.d.ts.map +1 -1
- package/container/sticky-bar.js +4 -4
- package/core/base-elements.js +8 -8
- package/core/controllers.js +4 -4
- package/core/datetime/date-adapter.d.ts +1 -1
- package/core/datetime/date-adapter.d.ts.map +1 -1
- package/core/datetime/native-date-adapter.d.ts +1 -1
- package/core/datetime/native-date-adapter.d.ts.map +1 -1
- package/core/datetime.js +6 -6
- package/core/dom/scroll.d.ts +1 -1
- package/core/dom/scroll.d.ts.map +1 -1
- package/core/dom.js +39 -39
- package/core/eventing.js +4 -4
- package/core/mixins/form-associated-mixin.d.ts +2 -4
- package/core/mixins/form-associated-mixin.d.ts.map +1 -1
- package/core/mixins/form-associated-radio-button-mixin.d.ts +3 -3
- package/core/mixins/form-associated-radio-button-mixin.d.ts.map +1 -1
- package/core/mixins.js +276 -276
- package/core/styles/core.scss +21 -2
- package/core/testing.js +14 -14
- package/core.css +18 -2
- package/custom-elements.json +528 -554
- package/datepicker/common/datepicker-association-controllers.d.ts +21 -0
- package/datepicker/common/datepicker-association-controllers.d.ts.map +1 -0
- package/datepicker/common/datepicker-button.d.ts +17 -9
- package/datepicker/common/datepicker-button.d.ts.map +1 -1
- package/datepicker/common.d.ts +1 -0
- package/datepicker/common.d.ts.map +1 -1
- package/datepicker/common.js +130 -92
- package/datepicker/datepicker/datepicker.d.ts +19 -4
- package/datepicker/datepicker/datepicker.d.ts.map +1 -1
- package/datepicker/datepicker-toggle/datepicker-toggle.d.ts +14 -8
- package/datepicker/datepicker-toggle/datepicker-toggle.d.ts.map +1 -1
- package/datepicker/datepicker-toggle.js +108 -112
- package/datepicker/datepicker.js +95 -80
- package/development/accordion/accordion.d.ts.map +1 -1
- package/development/accordion.js +1 -1
- package/development/autocomplete/autocomplete-base-element.d.ts.map +1 -1
- package/development/autocomplete-grid/autocomplete-grid-option/autocomplete-grid-option.d.ts +1 -1
- package/development/autocomplete-grid/autocomplete-grid-option/autocomplete-grid-option.d.ts.map +1 -1
- package/development/autocomplete-grid/autocomplete-grid-option.js +3 -3
- package/development/autocomplete.js +24 -8
- package/development/button/common.js +4 -2
- package/development/calendar.js +1 -1
- package/development/container/container/container.d.ts +1 -1
- package/development/container/container/container.d.ts.map +1 -1
- package/development/container/container.js +17 -1
- package/development/container/sticky-bar/sticky-bar.d.ts +1 -1
- package/development/container/sticky-bar/sticky-bar.d.ts.map +1 -1
- package/development/container/sticky-bar.js +9 -1
- package/development/core/datetime/date-adapter.d.ts +1 -1
- package/development/core/datetime/date-adapter.d.ts.map +1 -1
- package/development/core/datetime/native-date-adapter.d.ts +1 -1
- package/development/core/datetime/native-date-adapter.d.ts.map +1 -1
- package/development/core/datetime.js +1 -1
- package/development/core/dom/scroll.d.ts +1 -1
- package/development/core/dom/scroll.d.ts.map +1 -1
- package/development/core/dom.js +4 -4
- package/development/core/mixins/form-associated-mixin.d.ts +2 -4
- package/development/core/mixins/form-associated-mixin.d.ts.map +1 -1
- package/development/core/mixins/form-associated-radio-button-mixin.d.ts +3 -3
- package/development/core/mixins/form-associated-radio-button-mixin.d.ts.map +1 -1
- package/development/core/mixins.js +45 -49
- package/development/datepicker/common/datepicker-association-controllers.d.ts +21 -0
- package/development/datepicker/common/datepicker-association-controllers.d.ts.map +1 -0
- package/development/datepicker/common/datepicker-button.d.ts +17 -9
- package/development/datepicker/common/datepicker-button.d.ts.map +1 -1
- package/development/datepicker/common.d.ts +1 -0
- package/development/datepicker/common.d.ts.map +1 -1
- package/development/datepicker/common.js +139 -90
- package/development/datepicker/datepicker/datepicker.d.ts +19 -4
- package/development/datepicker/datepicker/datepicker.d.ts.map +1 -1
- package/development/datepicker/datepicker-toggle/datepicker-toggle.d.ts +14 -8
- package/development/datepicker/datepicker-toggle/datepicker-toggle.d.ts.map +1 -1
- package/development/datepicker/datepicker-toggle.js +65 -69
- package/development/datepicker/datepicker.js +54 -36
- package/development/dialog/dialog/dialog.d.ts +2 -0
- package/development/dialog/dialog/dialog.d.ts.map +1 -1
- package/development/dialog/dialog.js +37 -11
- package/development/menu/menu/menu.d.ts.map +1 -1
- package/development/menu/menu.js +35 -12
- package/development/navigation/navigation/navigation.d.ts.map +1 -1
- package/development/navigation/navigation.js +15 -8
- package/development/option/option/option-base-element.d.ts +3 -2
- package/development/option/option/option-base-element.d.ts.map +1 -1
- package/development/option/option.js +15 -8
- package/development/overlay/overlay-base-element.d.ts.map +1 -1
- package/development/overlay/overlay.d.ts.map +1 -1
- package/development/overlay.js +29 -13
- package/development/popover/popover/popover.d.ts.map +1 -1
- package/development/popover/popover.js +16 -13
- package/development/radio-button/common/radio-button-common.d.ts +0 -2
- package/development/radio-button/common/radio-button-common.d.ts.map +1 -1
- package/development/radio-button/common.js +2 -18
- package/development/radio-button/radio-button-group.js +2 -2
- package/development/radio-button/radio-button-panel/radio-button-panel.d.ts +9 -1
- package/development/radio-button/radio-button-panel/radio-button-panel.d.ts.map +1 -1
- package/development/radio-button/radio-button-panel.js +17 -7
- package/development/select/select.d.ts +11 -0
- package/development/select/select.d.ts.map +1 -1
- package/development/select.js +60 -9
- package/development/toast/toast.d.ts.map +1 -1
- package/development/toast.js +14 -8
- package/development/toggle/toggle.js +1 -1
- package/development/train/train-wagon.js +1 -1
- package/dialog/dialog/dialog.d.ts +2 -0
- package/dialog/dialog/dialog.d.ts.map +1 -1
- package/dialog/dialog-content.js +3 -3
- package/dialog/dialog-title.js +8 -8
- package/dialog/dialog.js +59 -49
- package/divider.js +12 -12
- package/file-selector/file-selector-dropzone.js +5 -5
- package/file-selector/file-selector.js +6 -6
- package/flip-card/flip-card-details.js +4 -4
- package/flip-card/flip-card-summary.js +9 -9
- package/header/header-button.js +5 -5
- package/header/header-link.js +5 -5
- package/icon.js +36 -36
- package/link/block-link-button.js +4 -4
- package/link/block-link-static.js +9 -9
- package/link/block-link.js +4 -4
- package/link/common.js +16 -16
- package/link/link-button.js +7 -7
- package/link/link-static.js +7 -7
- package/link/link.js +4 -4
- package/link-list/common.js +12 -12
- package/loading-indicator-circle.js +11 -11
- package/map-container.js +4 -4
- package/menu/common.js +7 -7
- package/menu/menu/menu.d.ts.map +1 -1
- package/menu/menu-button.js +8 -8
- package/menu/menu-link.js +6 -6
- package/menu/menu.js +64 -42
- package/navigation/navigation/navigation.d.ts.map +1 -1
- package/navigation/navigation-button.js +4 -4
- package/navigation/navigation-link.js +7 -7
- package/navigation/navigation-list.js +4 -4
- package/navigation/navigation-marker.js +3 -3
- package/navigation/navigation.js +21 -20
- package/notification.js +17 -17
- package/option/optgroup.js +11 -11
- package/option/option/option-base-element.d.ts +3 -2
- package/option/option/option-base-element.d.ts.map +1 -1
- package/option/option.js +113 -101
- package/overlay/overlay-base-element.d.ts.map +1 -1
- package/overlay/overlay.d.ts.map +1 -1
- package/overlay.js +87 -84
- package/package.json +1 -1
- package/paginator/common.js +6 -6
- package/popover/popover/popover.d.ts.map +1 -1
- package/popover/popover.js +73 -73
- package/radio-button/common/radio-button-common.d.ts +0 -2
- package/radio-button/common/radio-button-common.d.ts.map +1 -1
- package/radio-button/common.js +13 -18
- package/radio-button/radio-button-group.js +1 -1
- package/radio-button/radio-button-panel/radio-button-panel.d.ts +9 -1
- package/radio-button/radio-button-panel/radio-button-panel.d.ts.map +1 -1
- package/radio-button/radio-button-panel.js +40 -38
- package/screen-reader-only.js +5 -5
- package/select/select.d.ts +11 -0
- package/select/select.d.ts.map +1 -1
- package/select.js +111 -83
- package/slider.js +8 -8
- package/standard-theme.css +18 -2
- package/status.js +3 -3
- package/stepper/step-label.js +4 -4
- package/table/table-wrapper.js +4 -4
- package/tabs/tab-group.js +24 -24
- package/tabs/tab.js +3 -3
- package/tag/tag-group.js +7 -7
- package/teaser-product/common.js +5 -5
- package/teaser-product/teaser-product-static.js +2 -2
- package/timetable-occupancy-icon.js +3 -3
- package/timetable-occupancy.js +6 -6
- package/toast/toast.d.ts.map +1 -1
- package/toast.js +58 -54
- package/toggle/toggle-option.js +11 -11
- package/toggle-check.js +5 -5
- package/train/train.js +28 -28
package/core/mixins.js
CHANGED
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
var D = (
|
|
2
|
-
throw TypeError(
|
|
1
|
+
var D = (l) => {
|
|
2
|
+
throw TypeError(l);
|
|
3
3
|
};
|
|
4
|
-
var M = (
|
|
5
|
-
var
|
|
6
|
-
import { __esDecorate as
|
|
7
|
-
import { property as
|
|
8
|
-
import { forceType as
|
|
9
|
-
import { defaultConverter as
|
|
10
|
-
import { preventScrollOnSpacebarPress as $, EventEmitter as
|
|
11
|
-
import { interactivityChecker as
|
|
12
|
-
import { SbbConnectedAbortController as
|
|
4
|
+
var M = (l, p, o) => p.has(l) || D("Cannot " + o);
|
|
5
|
+
var k = (l, p, o) => (M(l, p, "read from private field"), o ? o.call(l) : p.get(l)), x = (l, p, o) => p.has(l) ? D("Cannot add the same private member more than once") : p instanceof WeakSet ? p.add(l) : p.set(l, o), v = (l, p, o, r) => (M(l, p, "write to private field"), r ? r.call(l, o) : p.set(l, o), o);
|
|
6
|
+
import { __esDecorate as y, __runInitializers as f } from "tslib";
|
|
7
|
+
import { property as S, state as F } from "lit/decorators.js";
|
|
8
|
+
import { forceType as w, getOverride as N, hostAttributes as j } from "./decorators.js";
|
|
9
|
+
import { defaultConverter as A, isServer as G, html as R, nothing as E, css as V } from "lit";
|
|
10
|
+
import { preventScrollOnSpacebarPress as $, EventEmitter as P } from "./eventing.js";
|
|
11
|
+
import { interactivityChecker as T, isArrowKeyPressed as H, getNextElementIndex as K } from "./a11y.js";
|
|
12
|
+
import { SbbConnectedAbortController as W } from "./controllers.js";
|
|
13
13
|
import "../screen-reader-only.js";
|
|
14
|
-
const I = (
|
|
15
|
-
var
|
|
16
|
-
let
|
|
17
|
-
return
|
|
14
|
+
const I = (l) => (() => {
|
|
15
|
+
var u, e;
|
|
16
|
+
let o = l, r, h = [], a = [];
|
|
17
|
+
return e = class extends o {
|
|
18
18
|
constructor() {
|
|
19
19
|
super(...arguments);
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
x(this, u, f(this, h, !1));
|
|
21
|
+
f(this, a);
|
|
22
22
|
}
|
|
23
23
|
/** Whether the component is disabled. */
|
|
24
24
|
get disabled() {
|
|
25
|
-
return
|
|
25
|
+
return k(this, u);
|
|
26
26
|
}
|
|
27
|
-
set disabled(
|
|
28
|
-
|
|
27
|
+
set disabled(t) {
|
|
28
|
+
v(this, u, t);
|
|
29
29
|
}
|
|
30
30
|
/**
|
|
31
31
|
* Will be used as 'or' check to the current disabled state.
|
|
@@ -34,49 +34,49 @@ const I = (o) => (() => {
|
|
|
34
34
|
isDisabledExternally() {
|
|
35
35
|
return !1;
|
|
36
36
|
}
|
|
37
|
-
},
|
|
38
|
-
const
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
} }, metadata:
|
|
42
|
-
})(),
|
|
43
|
-
})(),
|
|
44
|
-
var
|
|
45
|
-
let
|
|
46
|
-
return
|
|
37
|
+
}, u = new WeakMap(), (() => {
|
|
38
|
+
const t = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
39
|
+
r = [w(), S({ reflect: !0, type: Boolean }), N((s, i) => i || s.isDisabledExternally())], y(e, null, r, { kind: "accessor", name: "disabled", static: !1, private: !1, access: { has: (s) => "disabled" in s, get: (s) => s.disabled, set: (s, i) => {
|
|
40
|
+
s.disabled = i;
|
|
41
|
+
} }, metadata: t }, h, a), t && Object.defineProperty(e, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: t });
|
|
42
|
+
})(), e;
|
|
43
|
+
})(), X = (l) => (() => {
|
|
44
|
+
var u, e;
|
|
45
|
+
let o = l, r, h = [], a = [];
|
|
46
|
+
return e = class extends o {
|
|
47
47
|
constructor() {
|
|
48
48
|
super(...arguments);
|
|
49
|
-
|
|
50
|
-
|
|
49
|
+
x(this, u, f(this, h, !1));
|
|
50
|
+
f(this, a);
|
|
51
51
|
}
|
|
52
52
|
/** Whether the button should be aria-disabled but stay interactive. */
|
|
53
53
|
get disabledInteractive() {
|
|
54
|
-
return
|
|
55
|
-
}
|
|
56
|
-
set disabledInteractive(
|
|
57
|
-
|
|
58
|
-
}
|
|
59
|
-
},
|
|
60
|
-
const
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
} }, metadata:
|
|
64
|
-
})(),
|
|
65
|
-
})(),
|
|
66
|
-
class
|
|
67
|
-
willUpdate(
|
|
68
|
-
super.willUpdate(
|
|
54
|
+
return k(this, u);
|
|
55
|
+
}
|
|
56
|
+
set disabledInteractive(t) {
|
|
57
|
+
v(this, u, t);
|
|
58
|
+
}
|
|
59
|
+
}, u = new WeakMap(), (() => {
|
|
60
|
+
const t = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
61
|
+
r = [w(), S({ attribute: "disabled-interactive", type: Boolean, reflect: !0 })], y(e, null, r, { kind: "accessor", name: "disabledInteractive", static: !1, private: !1, access: { has: (s) => "disabledInteractive" in s, get: (s) => s.disabledInteractive, set: (s, i) => {
|
|
62
|
+
s.disabledInteractive = i;
|
|
63
|
+
} }, metadata: t }, h, a), t && Object.defineProperty(e, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: t });
|
|
64
|
+
})(), e;
|
|
65
|
+
})(), le = (l) => {
|
|
66
|
+
class p extends X(I(l)) {
|
|
67
|
+
willUpdate(r) {
|
|
68
|
+
super.willUpdate(r), r.has("disabledInteractive") && (this.internals.ariaDisabled = this.disabledInteractive ? "true" : null), r.has("disabled") && (this.disabled ? this.removeAttribute("tabindex") : this.setAttribute("tabindex", "0"));
|
|
69
69
|
}
|
|
70
70
|
}
|
|
71
|
-
return
|
|
72
|
-
}, L = (
|
|
73
|
-
var
|
|
74
|
-
let
|
|
75
|
-
return
|
|
71
|
+
return p;
|
|
72
|
+
}, L = (l) => (() => {
|
|
73
|
+
var d, t;
|
|
74
|
+
let o = l, r = [], h, a, u, e = [], n = [];
|
|
75
|
+
return t = class extends o {
|
|
76
76
|
constructor() {
|
|
77
77
|
super(...arguments);
|
|
78
|
-
|
|
79
|
-
this._value = (
|
|
78
|
+
x(this, d);
|
|
79
|
+
this._value = (f(this, r), null), this.internals = this.attachInternals(), v(this, d, f(this, e, !1)), f(this, n);
|
|
80
80
|
}
|
|
81
81
|
/**
|
|
82
82
|
* Returns the form owner of the internals of the target element.
|
|
@@ -90,8 +90,8 @@ const I = (o) => (() => {
|
|
|
90
90
|
* @description Developer note: In this case updating the attribute must be synchronous.
|
|
91
91
|
* Due to this it is implemented as a getter/setter and the attributeChangedCallback() handles the diff check.
|
|
92
92
|
*/
|
|
93
|
-
set name(
|
|
94
|
-
this.setAttribute("name", `${
|
|
93
|
+
set name(c) {
|
|
94
|
+
this.setAttribute("name", `${c}`), this.updateFormValue();
|
|
95
95
|
}
|
|
96
96
|
get name() {
|
|
97
97
|
return this.getAttribute("name") ?? "";
|
|
@@ -101,8 +101,8 @@ const I = (o) => (() => {
|
|
|
101
101
|
return this.localName;
|
|
102
102
|
}
|
|
103
103
|
/** Value of the form element. */
|
|
104
|
-
set value(
|
|
105
|
-
this._value =
|
|
104
|
+
set value(c) {
|
|
105
|
+
this._value = c, this.updateFormValue();
|
|
106
106
|
}
|
|
107
107
|
get value() {
|
|
108
108
|
return this._value;
|
|
@@ -135,13 +135,13 @@ const I = (o) => (() => {
|
|
|
135
135
|
}
|
|
136
136
|
/** Whenever a surrounding form or fieldset is changing its disabled state. */
|
|
137
137
|
get formDisabled() {
|
|
138
|
-
return
|
|
138
|
+
return k(this, d);
|
|
139
139
|
}
|
|
140
|
-
set formDisabled(
|
|
141
|
-
|
|
140
|
+
set formDisabled(c) {
|
|
141
|
+
v(this, d, c);
|
|
142
142
|
}
|
|
143
|
-
attributeChangedCallback(
|
|
144
|
-
(
|
|
143
|
+
attributeChangedCallback(c, b, m) {
|
|
144
|
+
(c !== "name" || b !== m) && super.attributeChangedCallback(c, b, m);
|
|
145
145
|
}
|
|
146
146
|
/**
|
|
147
147
|
* Returns true if internals target element has no validity problems; false otherwise.
|
|
@@ -168,37 +168,37 @@ const I = (o) => (() => {
|
|
|
168
168
|
*
|
|
169
169
|
* @internal
|
|
170
170
|
*/
|
|
171
|
-
formDisabledCallback(
|
|
171
|
+
formDisabledCallback(c) {
|
|
172
172
|
Promise.resolve().then(() => {
|
|
173
|
-
this.formDisabled =
|
|
173
|
+
this.formDisabled = c;
|
|
174
174
|
});
|
|
175
175
|
}
|
|
176
|
-
},
|
|
177
|
-
const
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
} }, metadata:
|
|
181
|
-
|
|
182
|
-
} }, metadata:
|
|
183
|
-
|
|
184
|
-
} }, metadata:
|
|
185
|
-
})(),
|
|
186
|
-
})(), U = (
|
|
187
|
-
var
|
|
188
|
-
let
|
|
189
|
-
return
|
|
176
|
+
}, d = new WeakMap(), (() => {
|
|
177
|
+
const c = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
178
|
+
h = [S()], a = [S()], u = [F()], y(t, null, h, { kind: "setter", name: "name", static: !1, private: !1, access: { has: (b) => "name" in b, set: (b, m) => {
|
|
179
|
+
b.name = m;
|
|
180
|
+
} }, metadata: c }, null, r), y(t, null, a, { kind: "setter", name: "value", static: !1, private: !1, access: { has: (b) => "value" in b, set: (b, m) => {
|
|
181
|
+
b.value = m;
|
|
182
|
+
} }, metadata: c }, null, r), y(t, null, u, { kind: "accessor", name: "formDisabled", static: !1, private: !1, access: { has: (b) => "formDisabled" in b, get: (b) => b.formDisabled, set: (b, m) => {
|
|
183
|
+
b.formDisabled = m;
|
|
184
|
+
} }, metadata: c }, e, n), c && Object.defineProperty(t, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: c });
|
|
185
|
+
})(), t.formAssociated = !0, t;
|
|
186
|
+
})(), U = (l) => (() => {
|
|
187
|
+
var a;
|
|
188
|
+
let o = l, r = [], h;
|
|
189
|
+
return a = class extends o {
|
|
190
190
|
constructor() {
|
|
191
|
-
super(...arguments), this._required = (
|
|
191
|
+
super(...arguments), this._required = (f(this, r), !1);
|
|
192
192
|
}
|
|
193
193
|
/** Whether the component is required. */
|
|
194
|
-
set required(
|
|
195
|
-
this._required = !!
|
|
194
|
+
set required(e) {
|
|
195
|
+
this._required = !!e;
|
|
196
196
|
}
|
|
197
197
|
get required() {
|
|
198
198
|
return this._required || this.isRequiredExternally();
|
|
199
199
|
}
|
|
200
|
-
willUpdate(
|
|
201
|
-
super.willUpdate(
|
|
200
|
+
willUpdate(e) {
|
|
201
|
+
super.willUpdate(e), e.has("required") && (this.internals.ariaRequired = `${this.required}`);
|
|
202
202
|
}
|
|
203
203
|
/**
|
|
204
204
|
* Will be used as 'or' check to the current required state.
|
|
@@ -208,21 +208,21 @@ const I = (o) => (() => {
|
|
|
208
208
|
return !1;
|
|
209
209
|
}
|
|
210
210
|
}, (() => {
|
|
211
|
-
const
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
} }, metadata:
|
|
215
|
-
})(),
|
|
216
|
-
})(),
|
|
217
|
-
var
|
|
218
|
-
let
|
|
211
|
+
const e = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
212
|
+
h = [S({ reflect: !0, type: Boolean })], y(a, null, h, { kind: "setter", name: "required", static: !1, private: !1, access: { has: (n) => "required" in n, set: (n, d) => {
|
|
213
|
+
n.required = d;
|
|
214
|
+
} }, metadata: e }, null, r), e && Object.defineProperty(a, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: e });
|
|
215
|
+
})(), a;
|
|
216
|
+
})(), oe = (l) => (() => {
|
|
217
|
+
var d;
|
|
218
|
+
let o = [j({
|
|
219
219
|
tabindex: "0"
|
|
220
|
-
})],
|
|
221
|
-
return
|
|
220
|
+
})], r, h = [], a, u = I(U(L(l))), e = [], n;
|
|
221
|
+
return d = class extends u {
|
|
222
222
|
/** Whether the checkbox is checked. */
|
|
223
|
-
set checked(
|
|
224
|
-
const
|
|
225
|
-
|
|
223
|
+
set checked(s) {
|
|
224
|
+
const i = typeof s == "object" ? s.attribute : !1;
|
|
225
|
+
i && (s = s.value), this.hasUpdated && !i && (this._attributeMutationBlocked = !0), this._checked = !!s, this.updateFormValue();
|
|
226
226
|
}
|
|
227
227
|
get checked() {
|
|
228
228
|
return this._checked;
|
|
@@ -235,16 +235,16 @@ const I = (o) => (() => {
|
|
|
235
235
|
return "checkbox";
|
|
236
236
|
}
|
|
237
237
|
constructor() {
|
|
238
|
-
var
|
|
239
|
-
super(), this._attributeMutationBlocked = (
|
|
240
|
-
|
|
238
|
+
var s, i, c;
|
|
239
|
+
super(), this._attributeMutationBlocked = (f(this, e), !1), this._checked = !1, this._handleKeyboardInteraction = (b) => {
|
|
240
|
+
b.key === " " && this._handleUserInteraction();
|
|
241
241
|
}, this._handleUserInteraction = () => {
|
|
242
|
-
var
|
|
243
|
-
this.disabled || ((
|
|
244
|
-
}, this.internals.role = "checkbox", (
|
|
242
|
+
var b;
|
|
243
|
+
this.disabled || ((b = this.withUserInteraction) == null || b.call(this), this.checked = !this.checked, this._attributeMutationBlocked = !0, this.dispatchEvent(new InputEvent("input", { composed: !0, bubbles: !0 })), this.dispatchEvent(new Event("change", { bubbles: !0 })));
|
|
244
|
+
}, this.internals.role = "checkbox", (s = this.addEventListener) == null || s.call(this, "click", this._handleUserInteraction), (i = this.addEventListener) == null || i.call(this, "keydown", $), (c = this.addEventListener) == null || c.call(this, "keyup", this._handleKeyboardInteraction);
|
|
245
245
|
}
|
|
246
|
-
attributeChangedCallback(
|
|
247
|
-
(
|
|
246
|
+
attributeChangedCallback(s, i, c) {
|
|
247
|
+
(s !== "checked" || !this._attributeMutationBlocked) && super.attributeChangedCallback(s, i, c);
|
|
248
248
|
}
|
|
249
249
|
/**
|
|
250
250
|
* Is called whenever the form is being reset.
|
|
@@ -263,46 +263,46 @@ const I = (o) => (() => {
|
|
|
263
263
|
*
|
|
264
264
|
* @internal
|
|
265
265
|
*/
|
|
266
|
-
formStateRestoreCallback(
|
|
267
|
-
|
|
266
|
+
formStateRestoreCallback(s, i) {
|
|
267
|
+
s && (this.checked = s === "true");
|
|
268
268
|
}
|
|
269
269
|
updateFormValue() {
|
|
270
270
|
this.checked ? this.internals.setFormValue(this.value, `${this.checked}`) : this.internals.setFormValue(null);
|
|
271
271
|
}
|
|
272
|
-
},
|
|
273
|
-
const
|
|
274
|
-
|
|
272
|
+
}, a = d, (() => {
|
|
273
|
+
const s = typeof Symbol == "function" && Symbol.metadata ? Object.create(u[Symbol.metadata] ?? null) : void 0;
|
|
274
|
+
n = [S({
|
|
275
275
|
type: Boolean,
|
|
276
276
|
converter: {
|
|
277
|
-
...
|
|
277
|
+
...A,
|
|
278
278
|
// We need to pass information to the setter so that we know it was called by attribute change.
|
|
279
|
-
fromAttribute: (
|
|
280
|
-
var
|
|
281
|
-
return { value: (B = (
|
|
279
|
+
fromAttribute: (i, c) => {
|
|
280
|
+
var m, B;
|
|
281
|
+
return { value: (B = (m = A).fromAttribute) == null ? void 0 : B.call(m, i, c), attribute: !0 };
|
|
282
282
|
}
|
|
283
283
|
}
|
|
284
|
-
})],
|
|
285
|
-
|
|
286
|
-
} }, metadata:
|
|
287
|
-
})(),
|
|
288
|
-
})(),
|
|
289
|
-
var
|
|
290
|
-
let
|
|
291
|
-
return
|
|
292
|
-
constructor() {
|
|
293
|
-
var e;
|
|
294
|
-
super();
|
|
295
|
-
S(this, r);
|
|
296
|
-
_(this, r, m(this, u, !1)), this.abort = (m(this, l), new K(this)), this._didLoad = !1, this.internals.role = "radio", (e = this.addEventListener) == null || e.call(this, "keydown", (t) => this._handleArrowKeyDown(t));
|
|
297
|
-
}
|
|
284
|
+
})], y(d, null, n, { kind: "setter", name: "checked", static: !1, private: !1, access: { has: (i) => "checked" in i, set: (i, c) => {
|
|
285
|
+
i.checked = c;
|
|
286
|
+
} }, metadata: s }, null, e), y(null, r = { value: a }, o, { kind: "class", name: a.name, metadata: s }, null, h), a = r.value, s && Object.defineProperty(a, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: s }), f(a, h);
|
|
287
|
+
})(), a;
|
|
288
|
+
})(), O = /* @__PURE__ */ new WeakMap(), de = (l) => (() => {
|
|
289
|
+
var a;
|
|
290
|
+
let o = I(U(L(l))), r = [], h;
|
|
291
|
+
return a = class extends o {
|
|
298
292
|
/**
|
|
299
293
|
* Whether the radio button is checked.
|
|
300
294
|
*/
|
|
295
|
+
set checked(e) {
|
|
296
|
+
this._checked = !!e, this.toggleAttribute("data-checked", this.checked), this.internals.ariaChecked = this.checked.toString(), this.updateFormValue(), this._synchronizeGroupState();
|
|
297
|
+
}
|
|
301
298
|
get checked() {
|
|
302
|
-
return
|
|
299
|
+
return this._checked;
|
|
303
300
|
}
|
|
304
|
-
set
|
|
305
|
-
|
|
301
|
+
set name(e) {
|
|
302
|
+
super.name = e, this._disconnectFromRegistry(), this._connectToRegistry(), this._synchronizeGroupState();
|
|
303
|
+
}
|
|
304
|
+
get name() {
|
|
305
|
+
return super.name;
|
|
306
306
|
}
|
|
307
307
|
/**
|
|
308
308
|
* Form type of element.
|
|
@@ -311,8 +311,12 @@ const I = (o) => (() => {
|
|
|
311
311
|
get type() {
|
|
312
312
|
return "radio";
|
|
313
313
|
}
|
|
314
|
+
constructor() {
|
|
315
|
+
var e;
|
|
316
|
+
super(), this._checked = (f(this, r), !1), this.abort = new W(this), this._didLoad = !1, this.internals.role = "radio", (e = this.addEventListener) == null || e.call(this, "keydown", (n) => this._handleArrowKeyDown(n));
|
|
317
|
+
}
|
|
314
318
|
connectedCallback() {
|
|
315
|
-
super.connectedCallback(), this._connectToRegistry();
|
|
319
|
+
super.connectedCallback(), this._connectToRegistry(), this._synchronizeGroupState();
|
|
316
320
|
}
|
|
317
321
|
disconnectedCallback() {
|
|
318
322
|
super.disconnectedCallback(), this._disconnectFromRegistry();
|
|
@@ -330,11 +334,11 @@ const I = (o) => (() => {
|
|
|
330
334
|
* user in which case reason is “autocomplete”.
|
|
331
335
|
* @internal
|
|
332
336
|
*/
|
|
333
|
-
formStateRestoreCallback(e,
|
|
337
|
+
formStateRestoreCallback(e, n) {
|
|
334
338
|
e && (this.checked = e === this.value);
|
|
335
339
|
}
|
|
336
340
|
willUpdate(e) {
|
|
337
|
-
super.willUpdate(e), e.has("
|
|
341
|
+
super.willUpdate(e), e.has("disabled") && this.updateFocusableRadios();
|
|
338
342
|
}
|
|
339
343
|
firstUpdated(e) {
|
|
340
344
|
super.firstUpdated(e), this._didLoad = !0, this.updateFocusableRadios();
|
|
@@ -344,14 +348,7 @@ const I = (o) => (() => {
|
|
|
344
348
|
* If 'checked', update the value. Otherwise, do nothing.
|
|
345
349
|
*/
|
|
346
350
|
updateFormValue() {
|
|
347
|
-
this.checked
|
|
348
|
-
}
|
|
349
|
-
/**
|
|
350
|
-
* Called on `checked` change
|
|
351
|
-
* If 'checked', update the value. Otherwise, reset it.
|
|
352
|
-
*/
|
|
353
|
-
updateFormValueOnCheckedChange() {
|
|
354
|
-
this.internals.setFormValue(this.checked ? this.value : null);
|
|
351
|
+
this.checked ? this.internals.setFormValue(this.value, this.value) : this.internals.setFormValue(null);
|
|
355
352
|
}
|
|
356
353
|
/**
|
|
357
354
|
* Only a single radio should be focusable in the group. Defined as:
|
|
@@ -361,8 +358,8 @@ const I = (o) => (() => {
|
|
|
361
358
|
updateFocusableRadios() {
|
|
362
359
|
if (!this._didLoad)
|
|
363
360
|
return;
|
|
364
|
-
const e = this._interactableGroupedRadios(),
|
|
365
|
-
|
|
361
|
+
const e = this._interactableGroupedRadios(), n = e.findIndex((t) => t.checked && !t.disabled && !t.formDisabled), d = n !== -1 ? n : e.findIndex((t) => !t.disabled && !t.formDisabled);
|
|
362
|
+
d !== -1 && (e[d].tabIndex = 0, e.splice(d, 1)), e.forEach((t) => t.removeAttribute("tabindex"));
|
|
366
363
|
}
|
|
367
364
|
async navigateByKeyboard(e) {
|
|
368
365
|
e.checked = !0, this.emitChangeEvents(), await e.updateComplete, e.focus();
|
|
@@ -370,31 +367,34 @@ const I = (o) => (() => {
|
|
|
370
367
|
emitChangeEvents() {
|
|
371
368
|
this.dispatchEvent(new InputEvent("input", { bubbles: !0, cancelable: !0, composed: !0 })), this.dispatchEvent(new Event("change", { bubbles: !0 }));
|
|
372
369
|
}
|
|
370
|
+
_synchronizeGroupState() {
|
|
371
|
+
this.checked && this._deselectGroupedRadios(), this.updateFocusableRadios();
|
|
372
|
+
}
|
|
373
373
|
/**
|
|
374
374
|
* Add `this` to the radioButton registry
|
|
375
375
|
*/
|
|
376
376
|
_connectToRegistry() {
|
|
377
|
-
if (!this.name)
|
|
377
|
+
if (!this.name || G)
|
|
378
378
|
return;
|
|
379
379
|
const e = this.form ?? this.getRootNode();
|
|
380
|
-
this._radioButtonGroupsMap =
|
|
381
|
-
const
|
|
380
|
+
this._radioButtonGroupsMap = O.get(e), this._radioButtonGroupsMap || (this._radioButtonGroupsMap = /* @__PURE__ */ new Map(), O.set(e, this._radioButtonGroupsMap)), this.associatedRadioButtons = this._radioButtonGroupsMap.get(this.name), this.associatedRadioButtons || (this.associatedRadioButtons = /* @__PURE__ */ new Set(), this._radioButtonGroupsMap.set(this.name, this.associatedRadioButtons));
|
|
381
|
+
const n = Array.from(this.associatedRadioButtons);
|
|
382
382
|
this.associatedRadioButtons.clear();
|
|
383
|
-
const
|
|
384
|
-
|
|
383
|
+
const d = n.findIndex((t) => this.compareDocumentPosition(t) & Node.DOCUMENT_POSITION_FOLLOWING);
|
|
384
|
+
d !== -1 ? n.splice(d, 0, this) : n.push(this), n.forEach((t) => this.associatedRadioButtons.add(t));
|
|
385
385
|
}
|
|
386
386
|
/**
|
|
387
387
|
* Remove `this` from the radioButton registry and, if the group is empty, delete the entry from the groups Map
|
|
388
388
|
*/
|
|
389
389
|
_disconnectFromRegistry() {
|
|
390
|
-
var e,
|
|
391
|
-
(e = this.associatedRadioButtons) == null || e.delete(this), ((
|
|
390
|
+
var e, n, d;
|
|
391
|
+
(e = this.associatedRadioButtons) == null || e.delete(this), ((n = this.associatedRadioButtons) == null ? void 0 : n.size) === 0 && ((d = this._radioButtonGroupsMap) == null || d.delete(this.name)), this.associatedRadioButtons = void 0, this._radioButtonGroupsMap = void 0;
|
|
392
392
|
}
|
|
393
393
|
/**
|
|
394
394
|
* Return a list of 'interactable' grouped radios, ordered in DOM order
|
|
395
395
|
*/
|
|
396
396
|
_interactableGroupedRadios() {
|
|
397
|
-
return Array.from(this.associatedRadioButtons ?? []).filter((e) =>
|
|
397
|
+
return Array.from(this.associatedRadioButtons ?? []).filter((e) => T.isVisible(e));
|
|
398
398
|
}
|
|
399
399
|
/**
|
|
400
400
|
* Deselect other radio of the same group
|
|
@@ -403,20 +403,20 @@ const I = (o) => (() => {
|
|
|
403
403
|
Array.from(this.associatedRadioButtons ?? []).filter((e) => e !== this).forEach((e) => e.checked = !1);
|
|
404
404
|
}
|
|
405
405
|
async _handleArrowKeyDown(e) {
|
|
406
|
-
if (!
|
|
406
|
+
if (!H(e))
|
|
407
407
|
return;
|
|
408
408
|
e.preventDefault();
|
|
409
|
-
const
|
|
410
|
-
await this.navigateByKeyboard(t
|
|
411
|
-
}
|
|
412
|
-
},
|
|
413
|
-
const e = typeof Symbol == "function" && Symbol.metadata ? Object.create(
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
} }, metadata: e },
|
|
417
|
-
})(),
|
|
418
|
-
})(),
|
|
419
|
-
class
|
|
409
|
+
const n = this._interactableGroupedRadios().filter((s) => !s.disabled && !s.formDisabled), d = n.indexOf(this), t = K(e, d, n.length);
|
|
410
|
+
await this.navigateByKeyboard(n[t]);
|
|
411
|
+
}
|
|
412
|
+
}, (() => {
|
|
413
|
+
const e = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
414
|
+
h = [S({ type: Boolean })], y(a, null, h, { kind: "setter", name: "checked", static: !1, private: !1, access: { has: (n) => "checked" in n, set: (n, d) => {
|
|
415
|
+
n.checked = d;
|
|
416
|
+
} }, metadata: e }, null, r), e && Object.defineProperty(a, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: e });
|
|
417
|
+
})(), a;
|
|
418
|
+
})(), J = (l) => {
|
|
419
|
+
class p extends l {
|
|
420
420
|
/**
|
|
421
421
|
* Returns a Promise that resolves when the element has completed hydration.
|
|
422
422
|
* The Promise value is a boolean that is `true` if the element required hydration
|
|
@@ -432,34 +432,34 @@ const I = (o) => (() => {
|
|
|
432
432
|
get hydrationRequired() {
|
|
433
433
|
return this._hydrationRequired;
|
|
434
434
|
}
|
|
435
|
-
constructor(...
|
|
436
|
-
var
|
|
437
|
-
if (super(...
|
|
435
|
+
constructor(...r) {
|
|
436
|
+
var h;
|
|
437
|
+
if (super(...r), this._hydrationComplete = new Promise((a) => this._resolveHydration = a), this._hydrationRequired = !!this.shadowRoot, !this._hydrationRequired)
|
|
438
438
|
this._resolveHydration(!1);
|
|
439
439
|
else {
|
|
440
|
-
const
|
|
441
|
-
this._hydrationRequired &&
|
|
442
|
-
},
|
|
443
|
-
|
|
444
|
-
|
|
440
|
+
const a = (n) => {
|
|
441
|
+
this._hydrationRequired && n.stopImmediatePropagation();
|
|
442
|
+
}, u = { capture: !0 }, e = (h = this.shadowRoot) == null ? void 0 : h.querySelectorAll("slot");
|
|
443
|
+
e != null && e.length && (e.forEach((n) => n.addEventListener("slotchange", a, u)), this.hydrationComplete.then(() => e.forEach((n) => {
|
|
444
|
+
n.removeEventListener("slotchange", a, u), n.assignedNodes().length && n.dispatchEvent(new Event("slotchange", { bubbles: !0 }));
|
|
445
445
|
})));
|
|
446
446
|
}
|
|
447
447
|
}
|
|
448
|
-
update(
|
|
449
|
-
super.update(
|
|
448
|
+
update(r) {
|
|
449
|
+
super.update(r), this._hydrationRequired && (this._hydrationRequired = !1, this._resolveHydration(!0));
|
|
450
450
|
}
|
|
451
451
|
}
|
|
452
|
-
return
|
|
453
|
-
}, z = "data-ssr-child-count",
|
|
454
|
-
var
|
|
455
|
-
let
|
|
456
|
-
return
|
|
452
|
+
return p;
|
|
453
|
+
}, z = "data-ssr-child-count", q = "li", ce = (l) => (() => {
|
|
454
|
+
var u, e;
|
|
455
|
+
let o = J(l), r, h = [], a = [];
|
|
456
|
+
return e = class extends o {
|
|
457
457
|
constructor() {
|
|
458
458
|
super(...arguments);
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
const
|
|
462
|
-
|
|
459
|
+
x(this, u);
|
|
460
|
+
v(this, u, f(this, h, [])), this._handleSlotchange = (f(this, a), () => {
|
|
461
|
+
const t = Array.from(this.children ?? []).filter((s) => this.listChildLocalNames.includes(s.localName));
|
|
462
|
+
t.length === this.listChildren.length && this.listChildren.every((s, i) => t[i] === s) || (this.listChildren.filter((s) => !t.includes(s)).forEach((s) => s.removeAttribute("slot")), this.listChildren = t, this.listChildren.forEach((s, i) => s.setAttribute("slot", `${q}-${i}`)), this.removeAttribute(z));
|
|
463
463
|
});
|
|
464
464
|
}
|
|
465
465
|
/**
|
|
@@ -468,18 +468,18 @@ const I = (o) => (() => {
|
|
|
468
468
|
* to the child elements.
|
|
469
469
|
*/
|
|
470
470
|
get listChildren() {
|
|
471
|
-
return
|
|
471
|
+
return k(this, u);
|
|
472
472
|
}
|
|
473
|
-
set listChildren(
|
|
474
|
-
|
|
473
|
+
set listChildren(t) {
|
|
474
|
+
v(this, u, t);
|
|
475
475
|
}
|
|
476
476
|
connectedCallback() {
|
|
477
|
-
var
|
|
478
|
-
super.connectedCallback(), (
|
|
477
|
+
var t;
|
|
478
|
+
super.connectedCallback(), (t = this.shadowRoot) == null || t.addEventListener("slotchange", this._handleSlotchange, { passive: !0 });
|
|
479
479
|
}
|
|
480
480
|
disconnectedCallback() {
|
|
481
|
-
var
|
|
482
|
-
super.disconnectedCallback(), (
|
|
481
|
+
var t;
|
|
482
|
+
super.disconnectedCallback(), (t = this.shadowRoot) == null || t.removeEventListener("slotchange", this._handleSlotchange);
|
|
483
483
|
}
|
|
484
484
|
/**
|
|
485
485
|
* Renders list and list slots for slotted children or a number of list slots
|
|
@@ -490,24 +490,24 @@ const I = (o) => (() => {
|
|
|
490
490
|
* framework wrapper (like e.g. React). This allows to provide the number of
|
|
491
491
|
* children to be passed via the `data-ssr-child-count` attribute value.
|
|
492
492
|
*/
|
|
493
|
-
renderList(
|
|
494
|
-
const
|
|
495
|
-
return
|
|
493
|
+
renderList(t = {}, s = {}) {
|
|
494
|
+
const i = this.listSlotEntries(s);
|
|
495
|
+
return i.length >= 2 ? R`
|
|
496
496
|
<ul
|
|
497
|
-
class=${
|
|
498
|
-
aria-label=${
|
|
499
|
-
aria-labelledby=${
|
|
497
|
+
class=${t.class || this.localName}
|
|
498
|
+
aria-label=${t.ariaLabel || E}
|
|
499
|
+
aria-labelledby=${t.ariaLabelledby || E}
|
|
500
500
|
>
|
|
501
|
-
${
|
|
502
|
-
<li aria-hidden=${
|
|
503
|
-
<slot name=${
|
|
501
|
+
${i.map((c) => R`
|
|
502
|
+
<li aria-hidden=${c.ariaHidden || E}>
|
|
503
|
+
<slot name=${c.name}></slot>
|
|
504
504
|
</li>
|
|
505
505
|
`)}
|
|
506
506
|
</ul>
|
|
507
507
|
${this.renderHiddenSlot()}
|
|
508
|
-
` :
|
|
509
|
-
<span class=${
|
|
510
|
-
<span><slot name=${
|
|
508
|
+
` : i.length === 1 ? R`<sbb-screen-reader-only>${t.ariaLabel}</sbb-screen-reader-only>
|
|
509
|
+
<span class=${t.class || this.localName}>
|
|
510
|
+
<span><slot name=${i[0].name}></slot></span>
|
|
511
511
|
</span>
|
|
512
512
|
${this.renderHiddenSlot()} ` : this.renderHiddenSlot();
|
|
513
513
|
}
|
|
@@ -520,12 +520,12 @@ const I = (o) => (() => {
|
|
|
520
520
|
* framework wrapper (like e.g. React). This allows to provide the number of
|
|
521
521
|
* children to be passed via the `data-ssr-child-count` attribute value.
|
|
522
522
|
*/
|
|
523
|
-
listSlotEntries(
|
|
524
|
-
return (this.listChildren.length ? this.listChildren : Array.from({ length: +(this.getAttribute(z) ?? 0) })).map((
|
|
525
|
-
var
|
|
523
|
+
listSlotEntries(t) {
|
|
524
|
+
return (this.listChildren.length ? this.listChildren : Array.from({ length: +(this.getAttribute(z) ?? 0) })).map((i, c) => {
|
|
525
|
+
var b;
|
|
526
526
|
return {
|
|
527
|
-
name: `${
|
|
528
|
-
ariaHidden: ((
|
|
527
|
+
name: `${q}-${c}`,
|
|
528
|
+
ariaHidden: ((b = t == null ? void 0 : t.localNameVisualOnly) == null ? void 0 : b.includes(i.localName)) ?? !1
|
|
529
529
|
};
|
|
530
530
|
});
|
|
531
531
|
}
|
|
@@ -537,113 +537,113 @@ const I = (o) => (() => {
|
|
|
537
537
|
renderHiddenSlot() {
|
|
538
538
|
return R`<span hidden><slot></slot></span>`;
|
|
539
539
|
}
|
|
540
|
-
},
|
|
541
|
-
const
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
} }, metadata:
|
|
545
|
-
})(),
|
|
546
|
-
})(),
|
|
547
|
-
var
|
|
548
|
-
let
|
|
549
|
-
return
|
|
540
|
+
}, u = new WeakMap(), (() => {
|
|
541
|
+
const t = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
542
|
+
r = [F()], y(e, null, r, { kind: "accessor", name: "listChildren", static: !1, private: !1, access: { has: (s) => "listChildren" in s, get: (s) => s.listChildren, set: (s, i) => {
|
|
543
|
+
s.listChildren = i;
|
|
544
|
+
} }, metadata: t }, h, a), t && Object.defineProperty(e, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: t });
|
|
545
|
+
})(), e;
|
|
546
|
+
})(), ue = (l) => (() => {
|
|
547
|
+
var u, e;
|
|
548
|
+
let o = l, r, h = [], a = [];
|
|
549
|
+
return e = class extends o {
|
|
550
550
|
constructor() {
|
|
551
551
|
super(...arguments);
|
|
552
|
-
|
|
553
|
-
|
|
552
|
+
x(this, u, f(this, h, !1));
|
|
553
|
+
f(this, a);
|
|
554
554
|
}
|
|
555
555
|
/** Negative coloring variant flag. */
|
|
556
556
|
get negative() {
|
|
557
|
-
return
|
|
558
|
-
}
|
|
559
|
-
set negative(
|
|
560
|
-
|
|
561
|
-
}
|
|
562
|
-
},
|
|
563
|
-
const
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
} }, metadata:
|
|
567
|
-
})(),
|
|
568
|
-
})(),
|
|
569
|
-
var
|
|
570
|
-
let
|
|
571
|
-
return
|
|
557
|
+
return k(this, u);
|
|
558
|
+
}
|
|
559
|
+
set negative(t) {
|
|
560
|
+
v(this, u, t);
|
|
561
|
+
}
|
|
562
|
+
}, u = new WeakMap(), (() => {
|
|
563
|
+
const t = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
564
|
+
r = [w(), S({ reflect: !0, type: Boolean })], y(e, null, r, { kind: "accessor", name: "negative", static: !1, private: !1, access: { has: (s) => "negative" in s, get: (s) => s.negative, set: (s, i) => {
|
|
565
|
+
s.negative = i;
|
|
566
|
+
} }, metadata: t }, h, a), t && Object.defineProperty(e, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: t });
|
|
567
|
+
})(), e;
|
|
568
|
+
})(), be = (l) => (() => {
|
|
569
|
+
var i, c, b, m;
|
|
570
|
+
let o = l, r, h = [], a = [], u, e = [], n = [], d, t = [], s = [];
|
|
571
|
+
return m = class extends o {
|
|
572
572
|
constructor() {
|
|
573
573
|
super(...arguments);
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
574
|
+
x(this, i);
|
|
575
|
+
x(this, c);
|
|
576
|
+
x(this, b);
|
|
577
|
+
v(this, i, f(this, h, "white")), v(this, c, (f(this, a), f(this, e, !1))), v(this, b, (f(this, n), f(this, t, ""))), this._panelConnected = (f(this, s), new P(this, m.events.panelConnected, { bubbles: !0 }));
|
|
578
578
|
}
|
|
579
579
|
/** The background color of the panel. */
|
|
580
580
|
get color() {
|
|
581
|
-
return
|
|
581
|
+
return k(this, i);
|
|
582
582
|
}
|
|
583
|
-
set color(
|
|
584
|
-
|
|
583
|
+
set color(g) {
|
|
584
|
+
v(this, i, g);
|
|
585
585
|
}
|
|
586
586
|
/** Whether the unselected panel has a border. */
|
|
587
587
|
get borderless() {
|
|
588
|
-
return
|
|
588
|
+
return k(this, c);
|
|
589
589
|
}
|
|
590
|
-
set borderless(
|
|
591
|
-
|
|
590
|
+
set borderless(g) {
|
|
591
|
+
v(this, c, g);
|
|
592
592
|
}
|
|
593
593
|
/** @internal used for accessibility label when in expansion panel */
|
|
594
594
|
get expansionState() {
|
|
595
|
-
return
|
|
595
|
+
return k(this, b);
|
|
596
596
|
}
|
|
597
|
-
set expansionState(
|
|
598
|
-
|
|
597
|
+
set expansionState(g) {
|
|
598
|
+
v(this, b, g);
|
|
599
599
|
}
|
|
600
600
|
connectedCallback() {
|
|
601
601
|
super.connectedCallback(), this._panelConnected.emit();
|
|
602
602
|
}
|
|
603
|
-
},
|
|
604
|
-
const
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
} }, metadata:
|
|
608
|
-
|
|
609
|
-
} }, metadata:
|
|
610
|
-
|
|
611
|
-
} }, metadata:
|
|
612
|
-
})(),
|
|
603
|
+
}, i = new WeakMap(), c = new WeakMap(), b = new WeakMap(), (() => {
|
|
604
|
+
const g = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
605
|
+
r = [S()], u = [w(), S({ reflect: !0, type: Boolean })], d = [w(), S()], y(m, null, r, { kind: "accessor", name: "color", static: !1, private: !1, access: { has: (_) => "color" in _, get: (_) => _.color, set: (_, C) => {
|
|
606
|
+
_.color = C;
|
|
607
|
+
} }, metadata: g }, h, a), y(m, null, u, { kind: "accessor", name: "borderless", static: !1, private: !1, access: { has: (_) => "borderless" in _, get: (_) => _.borderless, set: (_, C) => {
|
|
608
|
+
_.borderless = C;
|
|
609
|
+
} }, metadata: g }, e, n), y(m, null, d, { kind: "accessor", name: "expansionState", static: !1, private: !1, access: { has: (_) => "expansionState" in _, get: (_) => _.expansionState, set: (_, C) => {
|
|
610
|
+
_.expansionState = C;
|
|
611
|
+
} }, metadata: g }, t, s), g && Object.defineProperty(m, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: g });
|
|
612
|
+
})(), m.events = {
|
|
613
613
|
panelConnected: "panelConnected"
|
|
614
|
-
},
|
|
615
|
-
})(),
|
|
616
|
-
class
|
|
614
|
+
}, m;
|
|
615
|
+
})(), he = (l) => {
|
|
616
|
+
class p extends l {
|
|
617
617
|
constructor() {
|
|
618
618
|
super(...arguments), this._updatePromise = Promise.resolve(), this._updateResolve = () => {
|
|
619
619
|
};
|
|
620
620
|
}
|
|
621
621
|
startUpdate() {
|
|
622
|
-
this._updatePromise = new Promise((
|
|
622
|
+
this._updatePromise = new Promise((r) => this._updateResolve = r);
|
|
623
623
|
}
|
|
624
624
|
completeUpdate() {
|
|
625
625
|
this._updateResolve();
|
|
626
626
|
}
|
|
627
627
|
async getUpdateComplete() {
|
|
628
|
-
const
|
|
629
|
-
return await this._updatePromise,
|
|
628
|
+
const r = await super.getUpdateComplete();
|
|
629
|
+
return await this._updatePromise, r;
|
|
630
630
|
}
|
|
631
631
|
}
|
|
632
|
-
return
|
|
633
|
-
},
|
|
632
|
+
return p;
|
|
633
|
+
}, pe = V`:host{--sbb-selection-panel-background: var( --sbb-selection-expansion-panel-inner-background, var(--sbb-color-white) );--sbb-selection-panel-border-color: var(--sbb-color-cloud);--sbb-selection-panel-border-radius: var( --sbb-selection-expansion-panel-border-radius, var(--sbb-border-radius-4x) );--sbb-selection-panel-border-width: var( --sbb-selection-expansion-panel-inner-border-width, var(--sbb-border-width-1x) );--sbb-selection-panel-input-padding: var(--sbb-spacing-responsive-xs) var(--sbb-spacing-responsive-xxs);--sbb-selection-panel-animation-duration: var( --sbb-disable-animation-duration, var(--sbb-animation-duration-4x) );--sbb-selection-panel-cursor: pointer;--sbb-selection-panel-suffix-color: var(--sbb-color-charcoal);--sbb-selection-panel-subtext-color: var(--sbb-color-granite);display:block;outline:none!important}:host([size=s]){--sbb-selection-panel-input-padding: var(--sbb-spacing-responsive-xxs) var(--sbb-spacing-responsive-xxxs)}:host([color=milk]){--sbb-selection-panel-background: var( --sbb-selection-expansion-panel-inner-background, var(--sbb-color-milk) )}:host([borderless]:not([data-checked])){--sbb-selection-panel-border-color: transparent}:host(:is([data-checked]):not(:disabled,[disabled])){--sbb-selection-panel-border-color: var(--sbb-color-charcoal);--sbb-selection-panel-border-width: var( --sbb-selection-expansion-panel-inner-border-width, var(--sbb-border-width-2x) )}:host(:is(:disabled,[disabled])){--sbb-selection-panel-cursor: default}.sbb-selection-panel{display:block;cursor:var(--sbb-selection-panel-cursor);position:relative;border-radius:var(--sbb-selection-panel-border-radius);box-shadow:inset 0 0 0 var(--sbb-selection-panel-border-width) var(--sbb-selection-panel-border-color);padding:var(--sbb-selection-panel-input-padding);background-color:var(--sbb-selection-panel-background);transition-duration:var(--sbb-selection-panel-animation-duration);transition-timing-function:var(--sbb-animation-easing);transition-property:box-shadow}@media (forced-colors: active){.sbb-selection-panel:after{content:"";display:block;position:absolute;top:0;right:0;bottom:0;left:0;pointer-events:none;border:var(--sbb-selection-panel-border-width) solid var(--sbb-selection-panel-border-color);border-radius:var(--sbb-selection-panel-border-radius)}}:host(:focus-visible) .sbb-selection-panel{outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) solid var(--sbb-focus-outline-width)}.sbb-selection-panel__badge{-webkit-user-select:none;user-select:none;pointer-events:none;position:absolute;top:0;right:0;bottom:0;left:0;border-radius:var(--sbb-selection-panel-border-radius);overflow:hidden}slot[name=suffix]{color:var(--sbb-selection-panel-suffix-color)}slot[name=subtext]{display:block;color:var(--sbb-selection-panel-subtext-color);padding-inline-start:var(--sbb-spacing-fixed-8x)}:host(:not([data-slot-names~=subtext])) slot[name=subtext]{display:none}`;
|
|
634
634
|
export {
|
|
635
|
-
|
|
635
|
+
X as SbbDisabledInteractiveMixin,
|
|
636
636
|
I as SbbDisabledMixin,
|
|
637
|
-
|
|
638
|
-
|
|
637
|
+
le as SbbDisabledTabIndexActionMixin,
|
|
638
|
+
oe as SbbFormAssociatedCheckboxMixin,
|
|
639
639
|
L as SbbFormAssociatedMixin,
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
640
|
+
de as SbbFormAssociatedRadioButtonMixin,
|
|
641
|
+
J as SbbHydrationMixin,
|
|
642
|
+
ce as SbbNamedSlotListMixin,
|
|
643
|
+
ue as SbbNegativeMixin,
|
|
644
|
+
be as SbbPanelMixin,
|
|
645
645
|
U as SbbRequiredMixin,
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
646
|
+
he as SbbUpdateSchedulerMixin,
|
|
647
|
+
pe as panelCommonStyle,
|
|
648
|
+
O as radioButtonRegistry
|
|
649
649
|
};
|