@sbb-esta/lyne-elements 4.2.0 → 4.3.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.
- package/accordion/accordion.component.d.ts.map +1 -1
- package/accordion/accordion.component.js +12 -16
- package/action-group/action-group.component.d.ts.map +1 -1
- package/action-group/action-group.component.js +18 -21
- package/autocomplete/autocomplete-base-element.d.ts.map +1 -1
- package/autocomplete/autocomplete-base-element.js +25 -26
- package/autocomplete/autocomplete.component.d.ts.map +1 -1
- package/autocomplete/autocomplete.component.js +1 -1
- package/breadcrumb/breadcrumb/breadcrumb.component.js +11 -11
- package/breadcrumb/breadcrumb-group/breadcrumb-group.component.d.ts +3 -1
- package/breadcrumb/breadcrumb-group/breadcrumb-group.component.d.ts.map +1 -1
- package/breadcrumb/breadcrumb-group/breadcrumb-group.component.js +45 -52
- package/button/common.d.ts.map +1 -1
- package/button/common.js +5 -4
- package/button/mini-button/mini-button.component.d.ts +2 -2
- package/button/mini-button/mini-button.component.d.ts.map +1 -1
- package/button/mini-button/mini-button.component.js +22 -20
- package/button/mini-button-group/mini-button-group.component.d.ts.map +1 -1
- package/button/mini-button-group/mini-button-group.component.js +14 -10
- package/button/mini-button-link/mini-button-link.component.d.ts +21 -0
- package/button/mini-button-link/mini-button-link.component.d.ts.map +1 -0
- package/button/mini-button-link/mini-button-link.component.js +35 -0
- package/button/mini-button-link.d.ts +5 -0
- package/button/mini-button-link.d.ts.map +1 -0
- package/button/mini-button-link.js +4 -0
- package/button.d.ts +1 -0
- package/button.d.ts.map +1 -1
- package/button.js +28 -25
- package/checkbox/checkbox/checkbox.component.d.ts.map +1 -1
- package/checkbox/checkbox/checkbox.component.js +18 -20
- package/chip/chip/chip.component.js +10 -10
- package/chip/chip-group/chip-group.component.d.ts +2 -5
- package/chip/chip-group/chip-group.component.d.ts.map +1 -1
- package/chip/chip-group/chip-group.component.js +70 -68
- package/clock/clock.component.d.ts.map +1 -1
- package/clock/clock.component.js +36 -38
- package/container/sticky-bar/sticky-bar.component.js +1 -1
- package/core/controllers/media-matchers-controller.js +2 -2
- package/core/styles/core.scss +32 -0
- package/core/testing/event-spy.d.ts.map +1 -1
- package/core/testing/event-spy.js +4 -4
- package/core.css +55 -0
- package/custom-elements.json +1648 -893
- package/development/accordion/accordion.component.d.ts.map +1 -1
- package/development/accordion/accordion.component.js +2 -6
- package/development/action-group/action-group.component.d.ts.map +1 -1
- package/development/action-group/action-group.component.js +13 -22
- package/development/autocomplete/autocomplete-base-element.d.ts.map +1 -1
- package/development/autocomplete/autocomplete-base-element.js +4 -2
- package/development/autocomplete/autocomplete.component.d.ts.map +1 -1
- package/development/autocomplete/autocomplete.component.js +2 -2
- package/development/breadcrumb/breadcrumb/breadcrumb.component.js +6 -19
- package/development/breadcrumb/breadcrumb-group/breadcrumb-group.component.d.ts +3 -1
- package/development/breadcrumb/breadcrumb-group/breadcrumb-group.component.d.ts.map +1 -1
- package/development/breadcrumb/breadcrumb-group/breadcrumb-group.component.js +27 -43
- package/development/button/common.d.ts.map +1 -1
- package/development/button/common.js +3 -2
- package/development/button/mini-button/mini-button.component.d.ts +2 -2
- package/development/button/mini-button/mini-button.component.d.ts.map +1 -1
- package/development/button/mini-button/mini-button.component.js +7 -35
- package/development/button/mini-button-group/mini-button-group.component.d.ts.map +1 -1
- package/development/button/mini-button-group/mini-button-group.component.js +8 -4
- package/development/button/mini-button-link/mini-button-link.component.d.ts +21 -0
- package/development/button/mini-button-link/mini-button-link.component.d.ts.map +1 -0
- package/development/button/mini-button-link/mini-button-link.component.js +47 -0
- package/development/button/mini-button-link.d.ts +5 -0
- package/development/button/mini-button-link.d.ts.map +1 -0
- package/development/button/mini-button-link.js +5 -0
- package/development/button.d.ts +1 -0
- package/development/button.d.ts.map +1 -1
- package/development/button.js +6 -3
- package/development/checkbox/checkbox/checkbox.component.d.ts.map +1 -1
- package/development/checkbox/checkbox/checkbox.component.js +5 -4
- package/development/chip/chip/chip.component.js +2 -1
- package/development/chip/chip-group/chip-group.component.d.ts +2 -5
- package/development/chip/chip-group/chip-group.component.d.ts.map +1 -1
- package/development/chip/chip-group/chip-group.component.js +78 -14
- package/development/clock/clock.component.d.ts.map +1 -1
- package/development/clock/clock.component.js +25 -40
- package/development/container/sticky-bar/sticky-bar.component.js +1 -1
- package/development/core/controllers/media-matchers-controller.js +1 -1
- package/development/core/testing/event-spy.d.ts.map +1 -1
- package/development/core/testing/event-spy.js +3 -3
- package/development/dialog/dialog-actions/dialog-actions.component.js +2 -1
- package/development/divider/divider.component.d.ts +2 -2
- package/development/divider/divider.component.d.ts.map +1 -1
- package/development/divider/divider.component.js +4 -6
- package/development/expansion-panel/expansion-panel/expansion-panel.component.d.ts.map +1 -1
- package/development/expansion-panel/expansion-panel/expansion-panel.component.js +39 -34
- package/development/expansion-panel/expansion-panel-content/expansion-panel-content.component.d.ts.map +1 -1
- package/development/expansion-panel/expansion-panel-content/expansion-panel-content.component.js +15 -13
- package/development/expansion-panel/expansion-panel-header/expansion-panel-header.component.js +23 -21
- package/development/form-field/form-field/form-field.component.d.ts +2 -0
- package/development/form-field/form-field/form-field.component.d.ts.map +1 -1
- package/development/form-field/form-field/form-field.component.js +7 -2
- package/development/image/image.component.js +1 -1
- package/development/lead-container/lead-container.component.d.ts +3 -1
- package/development/lead-container/lead-container.component.d.ts.map +1 -1
- package/development/lead-container/lead-container.component.js +7 -2
- package/development/{mini-button-common-CWTMR_Lu.js → mini-button-label-common-0DeEC1qs.js} +41 -3
- package/development/navigation/navigation-section/navigation-section.component.js +4 -4
- package/development/{sbb-tokens-CZCt5L4q.js → sbb-tokens-DQT_xEIZ.js} +7 -7
- package/development/selection-action-panel/selection-action-panel.component.d.ts +1 -0
- package/development/selection-action-panel/selection-action-panel.component.d.ts.map +1 -1
- package/development/selection-action-panel/selection-action-panel.component.js +27 -3
- package/development/stepper/step-label/step-label.component.d.ts +9 -0
- package/development/stepper/step-label/step-label.component.d.ts.map +1 -1
- package/development/stepper/step-label/step-label.component.js +25 -3
- package/development/stepper/stepper/stepper.component.d.ts +5 -3
- package/development/stepper/stepper/stepper.component.d.ts.map +1 -1
- package/development/stepper/stepper/stepper.component.js +48 -22
- package/development/toggle/toggle/toggle.component.d.ts +1 -0
- package/development/toggle/toggle/toggle.component.d.ts.map +1 -1
- package/development/toggle/toggle/toggle.component.js +19 -10
- package/dialog/dialog-actions/dialog-actions.component.js +1 -1
- package/divider/divider.component.d.ts +2 -2
- package/divider/divider.component.d.ts.map +1 -1
- package/divider/divider.component.js +12 -12
- package/expansion-panel/expansion-panel/expansion-panel.component.d.ts.map +1 -1
- package/expansion-panel/expansion-panel/expansion-panel.component.js +31 -31
- package/expansion-panel/expansion-panel-content/expansion-panel-content.component.d.ts.map +1 -1
- package/expansion-panel/expansion-panel-content/expansion-panel-content.component.js +10 -14
- package/expansion-panel/expansion-panel-header/expansion-panel-header.component.js +19 -19
- package/form-field/form-field/form-field.component.d.ts +2 -0
- package/form-field/form-field/form-field.component.d.ts.map +1 -1
- package/form-field/form-field/form-field.component.js +6 -2
- package/image/image.component.js +1 -1
- package/index.d.ts +2 -0
- package/index.js +2 -0
- package/lead-container/lead-container.component.d.ts +3 -1
- package/lead-container/lead-container.component.d.ts.map +1 -1
- package/lead-container/lead-container.component.js +9 -8
- package/{mini-button-common-Bb4ri3Rn.js → mini-button-label-common-BOB7JQKi.js} +4 -3
- package/navigation/navigation-section/navigation-section.component.js +1 -1
- package/off-brand-theme.css +55 -0
- package/package.json +6 -1
- package/safety-theme.css +55 -0
- package/{sbb-tokens-DruExozg.js → sbb-tokens-HiNSQasB.js} +6 -6
- package/selection-action-panel/selection-action-panel.component.d.ts +1 -0
- package/selection-action-panel/selection-action-panel.component.d.ts.map +1 -1
- package/selection-action-panel/selection-action-panel.component.js +25 -16
- package/standard-theme.css +55 -0
- package/stepper/step-label/step-label.component.d.ts +9 -0
- package/stepper/step-label/step-label.component.d.ts.map +1 -1
- package/stepper/step-label/step-label.component.js +38 -16
- package/stepper/stepper/stepper.component.d.ts +5 -3
- package/stepper/stepper/stepper.component.d.ts.map +1 -1
- package/stepper/stepper/stepper.component.js +62 -68
- package/toggle/toggle/toggle.component.d.ts +1 -0
- package/toggle/toggle/toggle.component.d.ts.map +1 -1
- package/toggle/toggle/toggle.component.js +46 -44
|
@@ -3,14 +3,14 @@ import { css as c, html as d } from "lit";
|
|
|
3
3
|
import { customElement as h } from "lit/decorators.js";
|
|
4
4
|
import { SbbButtonBaseElement as f } from "../../core/base-elements.js";
|
|
5
5
|
import { SbbPropertyWatcherController as v } from "../../core/controllers.js";
|
|
6
|
-
import { SbbDisabledMixin as x, removeAriaElements as
|
|
6
|
+
import { SbbDisabledMixin as x, removeAriaElements as u, appendAriaElements as m } from "../../core/mixins.js";
|
|
7
7
|
import { boxSizingStyles as g } from "../../core/styles.js";
|
|
8
|
-
import { SbbIconNameMixin as
|
|
9
|
-
const
|
|
8
|
+
import { SbbIconNameMixin as y } from "../../icon.js";
|
|
9
|
+
const z = c`:host{--sbb-step-label-color: var(--sbb-color-4);--sbb-step-label-animation-duration: var( --sbb-disable-animation-duration, var(--sbb-animation-duration-2x) );--sbb-step-label-prefix-size: var(--sbb-size-element-xxs);--sbb-step-label-prefix-border-style: solid;--sbb-step-label-prefix-border-color: var(--sbb-border-color-4-inverted);--sbb-step-label-prefix-background-color: var(--sbb-background-color-1);--sbb-step-label-gap: var(--sbb-spacing-fixed-4x);position:relative;min-width:0;max-width:fit-content}:host:before{--sbb-text-font-size: var(--sbb-text-font-size-xxs);font-family:var(--sbb-typo-font-family);font-weight:400;line-height:var(--sbb-typo-line-height-text);letter-spacing:var(--sbb-typo-letter-spacing-text);font-size:var(--sbb-text-font-size);position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);cursor:var(--sbb-step-label-cursor);color:var(--sbb-step-label-color);inset-block-start:calc(var(--sbb-text-font-size-l) * var(--sbb-typo-line-height-text) / 2 + var(--sbb-border-width-1x) / 2);inset-inline-start:calc(var(--sbb-step-label-prefix-size) / 2);line-height:1;z-index:1;transform:translate(-50%,calc(-50% + var(--sbb-step-label-translate-y-content-hover, 0rem)));transition:transform var(--sbb-step-label-animation-duration) var(--sbb-animation-easing)}@media(forced-colors:active){:host{--sbb-step-label-color: ButtonText;--sbb-step-label-prefix-border-color: ButtonText}}:host(:is(:state(selected),[state--selected])){--sbb-text-font-size: var(--sbb-text-font-size-xxs);font-family:var(--sbb-typo-font-family);font-weight:400;line-height:var(--sbb-typo-line-height-text);letter-spacing:var(--sbb-typo-letter-spacing-text);font-size:var(--sbb-text-font-size);font-weight:700;--sbb-step-label-color: var(--sbb-color-3)}@media(forced-colors:active){:host(:is(:state(selected),[state--selected])){--sbb-step-label-color: Highlight !important}}:host(:is(:state(size-s),[state--size-s])){--sbb-step-label-gap: var(--sbb-spacing-fixed-3x);--sbb-step-label-prefix-size: var(--sbb-size-element-xxxs)}:host(:is(:state(size-s),[state--size-s])):before{inset-block-start:calc(var(--sbb-text-font-size-m) * var(--sbb-typo-line-height-text) / 2 + var(--sbb-border-width-1x) / 2)}:host(:disabled){--sbb-step-label-color: var(--sbb-color-granite);--sbb-step-label-color: light-dark(var(--sbb-color-granite), var(--sbb-color-graphite));--sbb-step-label-prefix-border-style: dashed}@media(forced-colors:active){:host(:disabled){--sbb-step-label-color: GrayText !important}}@media(any-hover:hover){:host(:hover:not(:disabled)){--sbb-step-label-cursor: var(--sbb-cursor-pointer);--sbb-step-label-prefix-background-color: var(--sbb-background-color-3);--sbb-step-label-translate-y-content-hover: -.0625rem;--sbb-step-label-prefix-size-grow-hover: calc(var(--sbb-border-width-2x) * -1)}}:host(:focus-visible){outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) var(--sbb-focus-outline-style, solid) var(--sbb-focus-outline-width);border-radius:var(--sbb-border-radius-1x)}:host(:is(:state(orientation-vertical),[state--orientation-vertical])){transition:margin var(--sbb-stepper-animation-duration) var(--sbb-animation-easing)}:host(:is(:state(orientation-vertical),[state--orientation-vertical]):not(:first-of-type)){margin-block-start:var(--sbb-spacing-fixed-6x)}:host(:is(:state(selected),[state--selected]):is(:state(orientation-vertical),[state--orientation-vertical])){margin-block-end:var(--sbb-spacing-fixed-8x)}.sbb-step-label{--sbb-text-font-size: var(--sbb-text-font-size-l);font-family:var(--sbb-typo-font-family);font-weight:400;line-height:var(--sbb-typo-line-height-text);letter-spacing:var(--sbb-typo-letter-spacing-text);font-size:var(--sbb-text-font-size);font-weight:700;cursor:var(--sbb-step-label-cursor);position:relative;display:flex;gap:var(--sbb-step-label-gap);color:var(--sbb-step-label-color)}:host(:is(:state(size-s),[state--size-s])) .sbb-step-label{--sbb-text-font-size: var(--sbb-text-font-size-m);font-family:var(--sbb-typo-font-family);font-weight:400;line-height:var(--sbb-typo-line-height-text);letter-spacing:var(--sbb-typo-letter-spacing-text);font-size:var(--sbb-text-font-size);font-weight:700}.sbb-step-label__prefix{position:relative;display:flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--sbb-step-label-prefix-size);height:var(--sbb-step-label-prefix-size);inset-block-start:calc(1em * var(--sbb-typo-line-height-text) / 2 + var(--sbb-border-width-1x) / 2 - var(--sbb-step-label-prefix-size) / 2)}.sbb-step-label__prefix:before{content:"";position:absolute;inset:calc(var(--sbb-step-label-prefix-size-grow-hover, 0rem));border-radius:var(--sbb-border-radius-infinity);border:var(--sbb-border-width-1x) var(--sbb-step-label-prefix-border-style) var(--sbb-step-label-prefix-border-color);background-color:var(--sbb-step-label-prefix-background-color);transition-duration:var(--sbb-step-label-animation-duration);transition-timing-function:var(--sbb-animation-easing);transition-property:background-color,inset}:host(:is(:state(orientation-horizontal),[state--orientation-horizontal])) .sbb-step-label__text{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}::slotted(sbb-icon),sbb-icon{z-index:1;background-color:var(--sbb-step-label-prefix-background-color);border-radius:var(--sbb-border-radius-infinity);transform:translateY(var(--sbb-step-label-translate-y-content-hover, 0rem));transition-duration:var(--sbb-step-label-animation-duration);transition-timing-function:var(--sbb-animation-easing);transition-property:background-color,transform}`;
|
|
10
10
|
let _ = 0, B = (() => {
|
|
11
|
-
var
|
|
12
|
-
let
|
|
13
|
-
return
|
|
11
|
+
var s;
|
|
12
|
+
let l = [h("sbb-step-label")], r, o = [], i, b = y(x(f));
|
|
13
|
+
return s = class extends b {
|
|
14
14
|
/** The step controlled by the label. */
|
|
15
15
|
get step() {
|
|
16
16
|
return this._step;
|
|
@@ -18,10 +18,16 @@ let _ = 0, B = (() => {
|
|
|
18
18
|
get stepper() {
|
|
19
19
|
return this.closest("sbb-stepper");
|
|
20
20
|
}
|
|
21
|
+
set disabled(t) {
|
|
22
|
+
super.disabled = t, this.toggleState("user-disabled", t);
|
|
23
|
+
}
|
|
24
|
+
get disabled() {
|
|
25
|
+
return super.disabled;
|
|
26
|
+
}
|
|
21
27
|
constructor() {
|
|
22
28
|
super(), this._step = null, this.addEventListener?.("click", () => {
|
|
23
29
|
const t = this.stepper;
|
|
24
|
-
t && this.step && (t.selected = this.step);
|
|
30
|
+
t && this.step && this._isNotDeactivatedByLinearMode(this.step) && (t.selected = this.step);
|
|
25
31
|
}), this.addController(new v(this, () => this.stepper, {
|
|
26
32
|
orientation: (t) => {
|
|
27
33
|
this._previousOrientation && this.internals.states.delete(`orientation-${this._previousOrientation}`), this._previousOrientation = t.orientation, this._previousOrientation && this.internals.states.add(`orientation-${this._previousOrientation}`);
|
|
@@ -31,8 +37,16 @@ let _ = 0, B = (() => {
|
|
|
31
37
|
}
|
|
32
38
|
}));
|
|
33
39
|
}
|
|
40
|
+
_isNotDeactivatedByLinearMode(t) {
|
|
41
|
+
const e = this.stepper;
|
|
42
|
+
if (e?.linear && e.selectedIndex !== null) {
|
|
43
|
+
const a = e.steps.indexOf(t);
|
|
44
|
+
return a < e.selectedIndex || a === e.selectedIndex + 1;
|
|
45
|
+
}
|
|
46
|
+
return !0;
|
|
47
|
+
}
|
|
34
48
|
connectedCallback() {
|
|
35
|
-
super.connectedCallback(), this.id ||= `sbb-step-label-${_++}`, this.slot ||= "step-label", this.internals.ariaSelected = "false", this.tabIndex = -1, this._assignStep()
|
|
49
|
+
super.connectedCallback(), this.id ||= `sbb-step-label-${_++}`, this.slot ||= "step-label", this.internals.ariaSelected = "false", this.tabIndex = -1, this._assignStep();
|
|
36
50
|
}
|
|
37
51
|
/**
|
|
38
52
|
* Selects and configures the step label.
|
|
@@ -52,15 +66,23 @@ let _ = 0, B = (() => {
|
|
|
52
66
|
* Configures the step label.
|
|
53
67
|
* @internal
|
|
54
68
|
*/
|
|
55
|
-
configure(t,
|
|
56
|
-
|
|
69
|
+
configure(t, e, a) {
|
|
70
|
+
a && this._assignStep(), this.internals.ariaPosInSet = `${t}`, this.internals.ariaSetSize = `${e}`;
|
|
57
71
|
}
|
|
58
72
|
_assignStep() {
|
|
59
73
|
let t = this.nextElementSibling;
|
|
60
74
|
for (; t && t.localName !== "sbb-step"; )
|
|
61
75
|
t = t.nextElementSibling;
|
|
62
|
-
const
|
|
63
|
-
this.internals.ariaControlsElements =
|
|
76
|
+
const e = t;
|
|
77
|
+
this.internals.ariaControlsElements = u(this.internals.ariaControlsElements, this._step), this._step = e instanceof Element ? e : null, this.internals.ariaControlsElements = m(this.internals.ariaControlsElements, this._step);
|
|
78
|
+
}
|
|
79
|
+
/**
|
|
80
|
+
* @internal
|
|
81
|
+
* Disables the step label and avoids setting the `disabled` state to preserve the initial
|
|
82
|
+
* disabled state in case of switching between linear and non-linear mode.
|
|
83
|
+
*/
|
|
84
|
+
disable(t) {
|
|
85
|
+
super.disabled = t;
|
|
64
86
|
}
|
|
65
87
|
render() {
|
|
66
88
|
return d`
|
|
@@ -70,10 +92,10 @@ let _ = 0, B = (() => {
|
|
|
70
92
|
</div>
|
|
71
93
|
`;
|
|
72
94
|
}
|
|
73
|
-
},
|
|
74
|
-
const t = typeof Symbol == "function" && Symbol.metadata ? Object.create(
|
|
75
|
-
n(null,
|
|
76
|
-
})(),
|
|
95
|
+
}, i = s, (() => {
|
|
96
|
+
const t = typeof Symbol == "function" && Symbol.metadata ? Object.create(b[Symbol.metadata] ?? null) : void 0;
|
|
97
|
+
n(null, r = { value: i }, l, { kind: "class", name: i.name, metadata: t }, null, o), i = r.value, t && Object.defineProperty(i, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: t });
|
|
98
|
+
})(), s.role = "tab", s.styles = [g, z], p(i, o), i;
|
|
77
99
|
})();
|
|
78
100
|
export {
|
|
79
101
|
B as SbbStepLabelElement
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CSSResultGroup, LitElement,
|
|
1
|
+
import { CSSResultGroup, LitElement, PropertyValues, TemplateResult } from 'lit';
|
|
2
2
|
import { SbbHorizontalFrom, SbbOrientation } from '../../core/interfaces.ts';
|
|
3
3
|
import { SbbStepElement } from '../step.ts';
|
|
4
4
|
export declare class SbbStepChangeEvent extends Event {
|
|
@@ -34,7 +34,7 @@ export declare class SbbStepperElement extends SbbStepperElement_base {
|
|
|
34
34
|
private _observer;
|
|
35
35
|
/** If set to true, only the current and previous labels can be clicked and selected. */
|
|
36
36
|
accessor linear: boolean;
|
|
37
|
-
/** Overrides the
|
|
37
|
+
/** Overrides the behavior of `orientation` property. */
|
|
38
38
|
set horizontalFrom(value: SbbHorizontalFrom | null);
|
|
39
39
|
get horizontalFrom(): SbbHorizontalFrom | null;
|
|
40
40
|
private _horizontalFrom;
|
|
@@ -48,9 +48,11 @@ export declare class SbbStepperElement extends SbbStepperElement_base {
|
|
|
48
48
|
/** The currently selected step. */
|
|
49
49
|
set selected(step: SbbStepElement | null);
|
|
50
50
|
get selected(): SbbStepElement | null;
|
|
51
|
+
private _requestedSelected;
|
|
51
52
|
/** The currently selected step index. */
|
|
52
53
|
set selectedIndex(index: number | null);
|
|
53
54
|
get selectedIndex(): number | null;
|
|
55
|
+
private _requestedSelectedIndex;
|
|
54
56
|
/** The steps of the stepper. */
|
|
55
57
|
get steps(): SbbStepElement[];
|
|
56
58
|
private get _enabledSteps();
|
|
@@ -64,7 +66,7 @@ export declare class SbbStepperElement extends SbbStepperElement_base {
|
|
|
64
66
|
previous(): void;
|
|
65
67
|
/** Resets the form in which the stepper is nested or every form of each step, if any. */
|
|
66
68
|
reset(): void;
|
|
67
|
-
private
|
|
69
|
+
private _isSelectable;
|
|
68
70
|
private _select;
|
|
69
71
|
private _setMarkerSize;
|
|
70
72
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stepper.component.d.ts","sourceRoot":"","sources":["../../../../src/elements/stepper/stepper/stepper.component.ts"],"names":[],"mappings":"AACA,OAAO,EACL,KAAK,cAAc,EAEnB,UAAU,EACV,KAAK,cAAc,EACnB,KAAK,cAAc,EACpB,MAAM,KAAK,CAAC;AAab,OAAO,KAAK,EAAE,iBAAiB,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAGlF,OAAO,KAAK,EAAE,cAAc,EAA+B,MAAM,YAAY,CAAC;AAa9E,qBAAa,kBAAmB,SAAQ,KAAK;IAC3C,4CAA4C;IAC5C,SAAgB,aAAa,EAAE,MAAM,GAAG,IAAI,CAAC;IAE7C,iDAAiD;IACjD,SAAgB,aAAa,EAAE,MAAM,GAAG,IAAI,CAAC;IAE7C,uCAAuC;IACvC,SAAgB,YAAY,EAAE,cAAc,GAAG,IAAI,CAAC;IAEpD,4CAA4C;IAC5C,SAAgB,YAAY,EAAE,cAAc,GAAG,IAAI,CAAC;gBAGlD,aAAa,EAAE,MAAM,GAAG,IAAI,EAC5B,aAAa,EAAE,MAAM,GAAG,IAAI,EAC5B,YAAY,EAAE,cAAc,GAAG,IAAI,EACnC,YAAY,EAAE,cAAc,GAAG,IAAI;CAQtC;;AACD;;;;;;GAMG;AACH,qBAEM,iBAAkB,SAAQ,sBAAuD;IACrF,OAAuB,MAAM,EAAE,cAAc,CAA4B;IACzE,gBAAuB,MAAM;;MAElB;IAEX;;;;;OAKG;IACH,OAAO,CAAC,SAAS,CAUd;IAEH,wFAAwF;IACxF,SAEgB,MAAM,EAAE,OAAO,CAAS;IAExC,
|
|
1
|
+
{"version":3,"file":"stepper.component.d.ts","sourceRoot":"","sources":["../../../../src/elements/stepper/stepper/stepper.component.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,66 +1,66 @@
|
|
|
1
|
-
var
|
|
1
|
+
var q = (s) => {
|
|
2
2
|
throw TypeError(s);
|
|
3
3
|
};
|
|
4
|
-
var T = (s, r, a) => r.has(s) ||
|
|
5
|
-
var
|
|
6
|
-
import { __esDecorate as
|
|
7
|
-
import { IntersectionController as
|
|
8
|
-
import { css as
|
|
9
|
-
import { customElement as
|
|
10
|
-
import { isArrowKeyPressed as
|
|
11
|
-
import { SbbMediaQueryBreakpointUltraAndAbove as
|
|
4
|
+
var T = (s, r, a) => r.has(s) || q("Cannot " + a);
|
|
5
|
+
var f = (s, r, a) => (T(s, r, "read from private field"), a ? a.call(s) : r.get(s)), v = (s, r, a) => r.has(s) ? q("Cannot add the same private member more than once") : r instanceof WeakSet ? r.add(s) : r.set(s, a), d = (s, r, a, n) => (T(s, r, "write to private field"), n ? n.call(s, a) : r.set(s, a), a);
|
|
6
|
+
import { __esDecorate as c, __runInitializers as o } from "tslib";
|
|
7
|
+
import { IntersectionController as H } from "@lit-labs/observers/intersection-controller.js";
|
|
8
|
+
import { css as R, LitElement as B, html as D } from "lit";
|
|
9
|
+
import { customElement as U, property as u } from "lit/decorators.js";
|
|
10
|
+
import { isArrowKeyPressed as Q, getNextElementIndex as $ } from "../../core/a11y.js";
|
|
11
|
+
import { SbbMediaQueryBreakpointUltraAndAbove as j, SbbMediaQueryBreakpointLargeAndAbove as K, SbbMediaQueryBreakpointSmallAndAbove as N, SbbMediaQueryBreakpointZeroAndAbove as P, SbbMediaMatcherController as V } from "../../core/controllers/media-matchers-controller.js";
|
|
12
12
|
import { forceType as W } from "../../core/decorators.js";
|
|
13
13
|
import { isLean as Z } from "../../core/dom.js";
|
|
14
14
|
import { SbbHydrationMixin as G, SbbElementInternalsMixin as J } from "../../core/mixins.js";
|
|
15
15
|
import { boxSizingStyles as X } from "../../core/styles.js";
|
|
16
|
-
const Y =
|
|
16
|
+
const Y = R`:host{--sbb-stepper-orientation: row;--sbb-stepper-border-width: var(--sbb-border-width-1x);--sbb-stepper-marker-size: 0;--sbb-stepper-marker-width: var(--sbb-border-width-3x);--sbb-stepper-animation-duration: var( --sbb-disable-animation-duration, var(--sbb-animation-duration-6x) );--sbb-stepper-marker-color: var(--sbb-color-3);display:block;position:relative;counter-reset:step-label}@media(forced-colors:active){:host{--sbb-stepper-marker-color: ButtonText}}:host(:is(:state(disable-animation),[state--disable-animation])){--sbb-disable-animation-duration: 0s}:host([orientation=vertical]){--sbb-stepper-orientation: column}.sbb-stepper{width:100%}.sbb-stepper__labels{display:flex;flex-direction:var(--sbb-stepper-orientation);position:relative;justify-content:start;margin-block-end:var(--sbb-spacing-responsive-m)}.sbb-stepper__labels:before{content:"";position:absolute;inset-inline-start:calc(var(--sbb-stepper-border-width) * -1);background-color:var(--sbb-stepper-marker-color)}:host([orientation=horizontal]) .sbb-stepper__labels{gap:var(--sbb-spacing-responsive-m);padding-block-end:var(--sbb-spacing-fixed-4x);border-block-end:var(--sbb-stepper-border-width) solid var(--sbb-border-color-4-inverted)}:host([orientation=horizontal]) .sbb-stepper__labels:before{inset-block-end:calc(var(--sbb-stepper-border-width) * -1);height:var(--sbb-stepper-marker-width);width:var(--sbb-stepper-marker-size);transition:width var(--sbb-stepper-animation-duration) var(--sbb-animation-easing)}:host([orientation=vertical]) .sbb-stepper__labels{padding-inline-start:var(--sbb-spacing-fixed-4x);border-inline-start:var(--sbb-stepper-border-width) solid var(--sbb-border-color-4-inverted)}:host([orientation=vertical]) .sbb-stepper__labels:before{inset-block-start:0;width:var(--sbb-stepper-marker-width);height:var(--sbb-stepper-marker-size);transition:height var(--sbb-stepper-animation-duration) var(--sbb-animation-easing)}.sbb-stepper__steps{position:relative}:host([orientation=horizontal]) .sbb-stepper__steps{height:var(--sbb-stepper-content-height);transition:height var(--sbb-stepper-animation-duration) var(--sbb-animation-easing)}::slotted(sbb-step-label):before{content:counter(step-label);counter-increment:step-label}`, A = 150, C = {
|
|
17
17
|
zero: P,
|
|
18
|
-
small:
|
|
19
|
-
large:
|
|
20
|
-
ultra:
|
|
18
|
+
small: N,
|
|
19
|
+
large: K,
|
|
20
|
+
ultra: j
|
|
21
21
|
};
|
|
22
22
|
class ee extends Event {
|
|
23
|
-
constructor(r, a,
|
|
24
|
-
super("stepchange", { bubbles: !0, composed: !0 }), this.selectedIndex = r, this.previousIndex = a, this.selectedStep =
|
|
23
|
+
constructor(r, a, n, _) {
|
|
24
|
+
super("stepchange", { bubbles: !0, composed: !0 }), this.selectedIndex = r, this.previousIndex = a, this.selectedStep = n, this.previousStep = _;
|
|
25
25
|
}
|
|
26
26
|
}
|
|
27
27
|
let ue = (() => {
|
|
28
|
-
var
|
|
29
|
-
let s = [
|
|
30
|
-
return
|
|
28
|
+
var h, b, p, l;
|
|
29
|
+
let s = [U("sbb-stepper")], r, a = [], n, _ = G(J(B)), m = [], x, z = [], S = [], k, I, y = [], E = [], w, M = [], L = [], O, F;
|
|
30
|
+
return l = class extends _ {
|
|
31
31
|
constructor() {
|
|
32
32
|
super();
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
this._observer = (o(this,
|
|
33
|
+
v(this, h);
|
|
34
|
+
v(this, b);
|
|
35
|
+
v(this, p);
|
|
36
|
+
this._observer = (o(this, m), new H(this, {
|
|
37
37
|
target: null,
|
|
38
38
|
callback: (e) => {
|
|
39
39
|
e.forEach((t) => {
|
|
40
40
|
t.intersectionRatio > 0 && (this._setStepperHeight(this.selected), this._setMarkerSize());
|
|
41
41
|
});
|
|
42
42
|
}
|
|
43
|
-
})), d(this,
|
|
44
|
-
this._checkOrientation(), this._setStepperHeight(this.selected), clearTimeout(this._resizeObserverTimeout), this.internals.states.add("disable-animation"), this._resizeObserverTimeout = setTimeout(() => this.internals.states.delete("disable-animation"),
|
|
43
|
+
})), d(this, h, o(this, z, !1)), this._horizontalFrom = (o(this, S), null), d(this, b, o(this, y, "horizontal")), d(this, p, (o(this, E), o(this, M, Z() ? "s" : "m"))), this._requestedSelected = (o(this, L), null), this._requestedSelectedIndex = null, this._loaded = !1, this._resizeObserverTimeout = null, this._mediaMatcher = new V(this, {}), this._onStepperResize = () => {
|
|
44
|
+
this._checkOrientation(), this._setStepperHeight(this.selected), clearTimeout(this._resizeObserverTimeout), this.internals.states.add("disable-animation"), this._resizeObserverTimeout = setTimeout(() => this.internals.states.delete("disable-animation"), A);
|
|
45
45
|
}, this.addEventListener?.("keydown", (e) => this._handleKeyDown(e)), this.addEventListener?.("resizechange", (e) => this._onSelectedStepResize(e));
|
|
46
46
|
}
|
|
47
47
|
/** If set to true, only the current and previous labels can be clicked and selected. */
|
|
48
48
|
get linear() {
|
|
49
|
-
return
|
|
49
|
+
return f(this, h);
|
|
50
50
|
}
|
|
51
51
|
set linear(e) {
|
|
52
|
-
d(this,
|
|
52
|
+
d(this, h, e);
|
|
53
53
|
}
|
|
54
|
-
/** Overrides the
|
|
54
|
+
/** Overrides the behavior of `orientation` property. */
|
|
55
55
|
set horizontalFrom(e) {
|
|
56
|
-
this._horizontalFrom = e &&
|
|
56
|
+
this._horizontalFrom = e && C[e] ? e : null, this._horizontalFrom && this._loaded && this._checkOrientation();
|
|
57
57
|
}
|
|
58
58
|
get horizontalFrom() {
|
|
59
59
|
return this._horizontalFrom;
|
|
60
60
|
}
|
|
61
61
|
/** Steps orientation, either horizontal or vertical. */
|
|
62
62
|
get orientation() {
|
|
63
|
-
return
|
|
63
|
+
return f(this, b);
|
|
64
64
|
}
|
|
65
65
|
set orientation(e) {
|
|
66
66
|
d(this, b, e);
|
|
@@ -70,31 +70,34 @@ let ue = (() => {
|
|
|
70
70
|
* @default 'm' / 's' (lean)
|
|
71
71
|
*/
|
|
72
72
|
get size() {
|
|
73
|
-
return
|
|
73
|
+
return f(this, p);
|
|
74
74
|
}
|
|
75
75
|
set size(e) {
|
|
76
76
|
d(this, p, e);
|
|
77
77
|
}
|
|
78
78
|
/** The currently selected step. */
|
|
79
79
|
set selected(e) {
|
|
80
|
-
this._loaded && this._select(e);
|
|
80
|
+
this._loaded && this._select(e), this._requestedSelected = e;
|
|
81
81
|
}
|
|
82
82
|
get selected() {
|
|
83
83
|
return this.querySelector?.("sbb-step:is(:state(selected),[state--selected])") ?? null;
|
|
84
84
|
}
|
|
85
85
|
/** The currently selected step index. */
|
|
86
86
|
set selectedIndex(e) {
|
|
87
|
-
this._loaded && e !== null && this._select(this.steps[e]);
|
|
87
|
+
this._loaded && e !== null && this._select(this.steps[e]), this._requestedSelectedIndex = e;
|
|
88
88
|
}
|
|
89
89
|
get selectedIndex() {
|
|
90
90
|
return this.selected ? this.steps.indexOf(this.selected) : null;
|
|
91
91
|
}
|
|
92
92
|
/** The steps of the stepper. */
|
|
93
93
|
get steps() {
|
|
94
|
-
|
|
94
|
+
const e = [];
|
|
95
|
+
return this.querySelectorAll?.("sbb-step").forEach((t) => {
|
|
96
|
+
customElements.upgrade(t), e.push(t);
|
|
97
|
+
}), e;
|
|
95
98
|
}
|
|
96
99
|
get _enabledSteps() {
|
|
97
|
-
return this.steps.filter((e) => !e.label
|
|
100
|
+
return this.steps.filter((e) => e.label ? (customElements.upgrade(e.label), !e.label.disabled) : !1);
|
|
98
101
|
}
|
|
99
102
|
/** Selects the next step. */
|
|
100
103
|
next() {
|
|
@@ -109,27 +112,19 @@ let ue = (() => {
|
|
|
109
112
|
const e = this.closest("form");
|
|
110
113
|
e ? e.reset() : this.querySelectorAll("form").forEach((t) => t.reset()), this.selectedIndex = 0, document.activeElement?.closest("sbb-stepper") === this && this.selected?.label?.focus();
|
|
111
114
|
}
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
return !1;
|
|
115
|
-
if (this.linear && !this.selected)
|
|
116
|
-
return e === this.steps[0];
|
|
117
|
-
if (this.linear && this.selectedIndex !== null) {
|
|
118
|
-
const t = this.steps.indexOf(e);
|
|
119
|
-
return t < this.selectedIndex || t === this.selectedIndex + 1;
|
|
120
|
-
}
|
|
121
|
-
return !0;
|
|
115
|
+
_isSelectable(e) {
|
|
116
|
+
return e ? (customElements.upgrade(e), !(e.label && (customElements.upgrade(e.label), !this.linear && e.label.disabled))) : !1;
|
|
122
117
|
}
|
|
123
118
|
_select(e) {
|
|
124
|
-
if (!this.
|
|
119
|
+
if (!this._isSelectable(e) || e === this.selected)
|
|
125
120
|
return;
|
|
126
|
-
const t = this.selectedIndex, i = this.selected,
|
|
121
|
+
const t = this.selectedIndex, i = this.selected, g = {
|
|
127
122
|
currentIndex: t,
|
|
128
123
|
currentStep: i,
|
|
129
124
|
nextIndex: this.selectedIndex !== null ? this.selectedIndex + 1 : null,
|
|
130
125
|
nextStep: this.selectedIndex !== null ? this.steps[this.selectedIndex + 1] : null
|
|
131
126
|
};
|
|
132
|
-
if (this.selected && !this.selected.validate(
|
|
127
|
+
if (this.selected && !this.selected.validate(g))
|
|
133
128
|
return;
|
|
134
129
|
this.selected?.deselect(), e.select(), this.dispatchEvent(new ee(this.selectedIndex, t, this.selected, i)), this._setMarkerSize(), this._setStepperHeight(e), this._configureLinearMode(), document.activeElement?.closest("sbb-stepper") === this && this.selected?.label?.focus();
|
|
135
130
|
}
|
|
@@ -163,9 +158,8 @@ let ue = (() => {
|
|
|
163
158
|
this._setStepperHeight(e.target);
|
|
164
159
|
}
|
|
165
160
|
_configure() {
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
t.configure(i + 1, _.length, this._loaded);
|
|
161
|
+
this.steps.forEach((e, t, i) => {
|
|
162
|
+
e.configure(this._loaded), e.label?.configure(t + 1, i.length, this._loaded);
|
|
169
163
|
}), this._select(this.selected || this._enabledSteps[0]);
|
|
170
164
|
}
|
|
171
165
|
_updateLabels() {
|
|
@@ -174,11 +168,11 @@ let ue = (() => {
|
|
|
174
168
|
});
|
|
175
169
|
}
|
|
176
170
|
_checkOrientation() {
|
|
177
|
-
this.horizontalFrom && (this.orientation = this._mediaMatcher.matches(
|
|
171
|
+
this.horizontalFrom && (this.orientation = this._mediaMatcher.matches(C[this.horizontalFrom]) ? "horizontal" : "vertical", this._updateLabels()), setTimeout(() => this._setMarkerSize(), 0);
|
|
178
172
|
}
|
|
179
173
|
_configureLinearMode() {
|
|
180
174
|
this.steps.forEach((e, t) => {
|
|
181
|
-
e.label
|
|
175
|
+
e.label && (customElements.upgrade(e.label), e.label.disable(this.linear && t > this.selectedIndex || !this.linear && e.label.matches(":is(:state(user-disabled),[state--user-disabled])")));
|
|
182
176
|
});
|
|
183
177
|
}
|
|
184
178
|
connectedCallback() {
|
|
@@ -191,7 +185,7 @@ let ue = (() => {
|
|
|
191
185
|
}
|
|
192
186
|
firstUpdated(e) {
|
|
193
187
|
super.firstUpdated(e), this.updateComplete.then(() => {
|
|
194
|
-
this._loaded = !0, this.selectedIndex = this.
|
|
188
|
+
this._loaded = !0, this._configure(), this._requestedSelected && this.steps.indexOf(this._requestedSelected) !== -1 ? this.selectedIndex = this.steps.indexOf(this._requestedSelected) : this._requestedSelectedIndex ? this.selectedIndex = this._requestedSelectedIndex : this.selectedIndex = 0, this._observer.observe(this), this._checkOrientation(), setTimeout(() => this.internals.states.delete("disable-animation"), A);
|
|
195
189
|
});
|
|
196
190
|
}
|
|
197
191
|
willUpdate(e) {
|
|
@@ -200,13 +194,13 @@ let ue = (() => {
|
|
|
200
194
|
_handleKeyDown(e) {
|
|
201
195
|
const t = this._enabledSteps;
|
|
202
196
|
if (!(!t || // don't trap nested handling
|
|
203
|
-
e.target !== this && e.target.parentElement !== this) &&
|
|
204
|
-
const i = t.indexOf(this.selected),
|
|
205
|
-
this._select(t[
|
|
197
|
+
e.target !== this && e.target.parentElement !== this) && Q(e)) {
|
|
198
|
+
const i = t.indexOf(this.selected), g = $(e, i, t.length);
|
|
199
|
+
this._select(t[g]), e.preventDefault();
|
|
206
200
|
}
|
|
207
201
|
}
|
|
208
202
|
render() {
|
|
209
|
-
return
|
|
203
|
+
return D`
|
|
210
204
|
<div class="sbb-stepper">
|
|
211
205
|
<div class="sbb-stepper__labels" role="tablist">
|
|
212
206
|
<slot name="step-label" @slotchange=${this._configure}></slot>
|
|
@@ -217,24 +211,24 @@ let ue = (() => {
|
|
|
217
211
|
</div>
|
|
218
212
|
`;
|
|
219
213
|
}
|
|
220
|
-
},
|
|
221
|
-
const e = typeof Symbol == "function" && Symbol.metadata ? Object.create(
|
|
222
|
-
x = [W(), u({ type: Boolean })], k = [u({ attribute: "horizontal-from", reflect: !0 })], I = [u({ reflect: !0 })],
|
|
214
|
+
}, h = new WeakMap(), b = new WeakMap(), p = new WeakMap(), n = l, (() => {
|
|
215
|
+
const e = typeof Symbol == "function" && Symbol.metadata ? Object.create(_[Symbol.metadata] ?? null) : void 0;
|
|
216
|
+
x = [W(), u({ type: Boolean })], k = [u({ attribute: "horizontal-from", reflect: !0 })], I = [u({ reflect: !0 })], w = [u({ reflect: !0 })], O = [u({ attribute: !1 })], F = [u({ attribute: "selected-index", type: Number })], c(l, null, x, { kind: "accessor", name: "linear", static: !1, private: !1, access: { has: (t) => "linear" in t, get: (t) => t.linear, set: (t, i) => {
|
|
223
217
|
t.linear = i;
|
|
224
|
-
} }, metadata: e }, z, S),
|
|
218
|
+
} }, metadata: e }, z, S), c(l, null, k, { kind: "setter", name: "horizontalFrom", static: !1, private: !1, access: { has: (t) => "horizontalFrom" in t, set: (t, i) => {
|
|
225
219
|
t.horizontalFrom = i;
|
|
226
|
-
} }, metadata: e }, null,
|
|
220
|
+
} }, metadata: e }, null, m), c(l, null, I, { kind: "accessor", name: "orientation", static: !1, private: !1, access: { has: (t) => "orientation" in t, get: (t) => t.orientation, set: (t, i) => {
|
|
227
221
|
t.orientation = i;
|
|
228
|
-
} }, metadata: e }, y,
|
|
222
|
+
} }, metadata: e }, y, E), c(l, null, w, { kind: "accessor", name: "size", static: !1, private: !1, access: { has: (t) => "size" in t, get: (t) => t.size, set: (t, i) => {
|
|
229
223
|
t.size = i;
|
|
230
|
-
} }, metadata: e }, M,
|
|
224
|
+
} }, metadata: e }, M, L), c(l, null, O, { kind: "setter", name: "selected", static: !1, private: !1, access: { has: (t) => "selected" in t, set: (t, i) => {
|
|
231
225
|
t.selected = i;
|
|
232
|
-
} }, metadata: e }, null,
|
|
226
|
+
} }, metadata: e }, null, m), c(l, null, F, { kind: "setter", name: "selectedIndex", static: !1, private: !1, access: { has: (t) => "selectedIndex" in t, set: (t, i) => {
|
|
233
227
|
t.selectedIndex = i;
|
|
234
|
-
} }, metadata: e }, null,
|
|
235
|
-
})(),
|
|
228
|
+
} }, metadata: e }, null, m), c(null, r = { value: n }, s, { kind: "class", name: n.name, metadata: e }, null, a), n = r.value, e && Object.defineProperty(n, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: e });
|
|
229
|
+
})(), l.styles = [X, Y], l.events = {
|
|
236
230
|
stepchange: "stepchange"
|
|
237
|
-
}, o(
|
|
231
|
+
}, o(n, a), n;
|
|
238
232
|
})();
|
|
239
233
|
export {
|
|
240
234
|
ee as SbbStepChangeEvent,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toggle.component.d.ts","sourceRoot":"","sources":["../../../../src/elements/toggle/toggle/toggle.component.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,cAAc,EAGnB,UAAU,EACV,KAAK,cAAc,EACnB,KAAK,cAAc,EACpB,MAAM,KAAK,CAAC;AAMb,OAAO,EACL,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EAItB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;;AAIlE;;;;;GAKG;AACH,qBAEM,gBAAgB,CAAC,CAAC,GAAG,MAAM,CAAE,SAAQ,qBAE1C;IACC,gBAAgC,IAAI,gBAAgB;IACpD,OAAuB,MAAM,EAAE,cAAc,CAA4B;IACzE,gBAAuB,MAAM;;MAElB;IAEX;;;OAGG;IACH,SAEgB,IAAI,EAAE,OAAO,CAAS;IAEtC;;;OAGG;IACH,SAA6C,IAAI,EAAE,GAAG,GAAG,GAAG,CAAwB;IAEpF;;;OAGG;IACH,IACW,KAAK,CAAC,KAAK,EAAE,CAAC,GAAG,IAAI,EAM/B;IACD,IAAW,KAAK,IAAI,CAAC,GAAG,IAAI,CAI3B;IACD,OAAO,CAAC,cAAc,CAAkB;IAExC,4DAA4D;IAC5D,IAAW,OAAO,IAAI,sBAAsB,CAAC,CAAC,CAAC,EAAE,CAIhD;;cAQkB,UAAU,CAAC,iBAAiB,EAAE,cAAc,GAAG,IAAI;IAatE;;;OAGG;IACI,aAAa,IAAI,IAAI;IAK5B;;;OAGG;IACI,iBAAiB,IAAI,IAAI;IAIhC;;OAEG;IACI,wBAAwB,CAC7B,KAAK,EAAE,gBAAgB,GAAG,IAAI,EAC9B,OAAO,EAAE,iBAAiB,GACzB,IAAI;YAUO,aAAa;IAK3B,gBAAgB;IACT,kBAAkB,CAAC,QAAQ,UAAQ,GAAG,IAAI;IAqCjD,OAAO,CAAC,aAAa;IAKrB,OAAO,CAAC,aAAa;IAgBrB,OAAO,CAAC,eAAe;IAMvB;;OAEG;IACH,OAAO,CAAC,YAAY;IAUpB,OAAO,CAAC,cAAc;
|
|
1
|
+
{"version":3,"file":"toggle.component.d.ts","sourceRoot":"","sources":["../../../../src/elements/toggle/toggle/toggle.component.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,cAAc,EAGnB,UAAU,EACV,KAAK,cAAc,EACnB,KAAK,cAAc,EACpB,MAAM,KAAK,CAAC;AAMb,OAAO,EACL,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EAItB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;;AAIlE;;;;;GAKG;AACH,qBAEM,gBAAgB,CAAC,CAAC,GAAG,MAAM,CAAE,SAAQ,qBAE1C;IACC,gBAAgC,IAAI,gBAAgB;IACpD,OAAuB,MAAM,EAAE,cAAc,CAA4B;IACzE,gBAAuB,MAAM;;MAElB;IAEX;;;OAGG;IACH,SAEgB,IAAI,EAAE,OAAO,CAAS;IAEtC;;;OAGG;IACH,SAA6C,IAAI,EAAE,GAAG,GAAG,GAAG,CAAwB;IAEpF;;;OAGG;IACH,IACW,KAAK,CAAC,KAAK,EAAE,CAAC,GAAG,IAAI,EAM/B;IACD,IAAW,KAAK,IAAI,CAAC,GAAG,IAAI,CAI3B;IACD,OAAO,CAAC,cAAc,CAAkB;IAExC,4DAA4D;IAC5D,IAAW,OAAO,IAAI,sBAAsB,CAAC,CAAC,CAAC,EAAE,CAIhD;;cAQkB,UAAU,CAAC,iBAAiB,EAAE,cAAc,GAAG,IAAI;IAatE;;;OAGG;IACI,aAAa,IAAI,IAAI;IAK5B;;;OAGG;IACI,iBAAiB,IAAI,IAAI;IAIhC;;OAEG;IACI,wBAAwB,CAC7B,KAAK,EAAE,gBAAgB,GAAG,IAAI,EAC9B,OAAO,EAAE,iBAAiB,GACzB,IAAI;YAUO,aAAa;IAK3B,gBAAgB;IACT,kBAAkB,CAAC,QAAQ,UAAQ,GAAG,IAAI;IAqCjD,OAAO,CAAC,aAAa;IAKrB,OAAO,CAAC,aAAa;IAgBrB,OAAO,CAAC,eAAe;IAMvB;;OAEG;IACH,OAAO,CAAC,YAAY;IAUpB,OAAO,CAAC,cAAc;IA6BtB,OAAO,CAAC,qBAAqB;cASV,MAAM,IAAI,cAAc;CAO5C;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAE7B,YAAY,EAAE,gBAAgB,CAAC;KAChC;CACF"}
|