@sbb-esta/lyne-elements 2.2.0 → 2.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.
- package/accordion.js +6 -6
- package/alert/alert-group.js +4 -4
- package/alert/alert.js +9 -9
- package/autocomplete-grid/autocomplete-grid-button.js +4 -4
- package/autocomplete-grid/autocomplete-grid-optgroup.js +4 -4
- package/autocomplete-grid/autocomplete-grid-row.js +4 -4
- package/autocomplete.js +1 -1
- package/badge.css +31 -0
- package/breadcrumb/breadcrumb-group.js +4 -4
- package/breadcrumb/breadcrumb.js +19 -19
- 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/calendar.js +1 -1
- package/card/card-badge.js +9 -9
- package/card/card-button.js +5 -5
- package/card/card-link.js +7 -7
- package/card/card.js +1 -1
- 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.js +4 -4
- package/core/base-elements.js +10 -10
- package/core/controllers.js +4 -4
- package/core/datetime.js +6 -6
- package/core/eventing.js +4 -4
- package/core/i18n/i18n.d.ts +2 -0
- package/core/i18n/i18n.d.ts.map +1 -1
- package/core/i18n.js +43 -31
- package/core/mixins/form-associated-checkbox-mixin.d.ts.map +1 -1
- package/core/mixins/form-associated-mixin.d.ts +3 -0
- package/core/mixins/form-associated-mixin.d.ts.map +1 -1
- package/core/mixins/form-associated-radio-button-mixin.d.ts.map +1 -1
- package/core/mixins.js +342 -248
- package/core/styles/badge.scss +3 -0
- package/core/styles/mixins/badge.scss +26 -1
- package/core/styles/mixins/font-face.scss +12 -12
- package/core/styles/mixins/link.scss +32 -8
- package/core/styles/standard-theme.scss +1 -0
- package/core/testing.js +14 -14
- package/core.css +3 -3
- package/custom-elements.json +7323 -169
- package/datepicker/datepicker-toggle.js +14 -14
- package/development/alert/alert-group.js +1 -1
- package/development/alert/alert.js +1 -1
- package/development/autocomplete.js +1 -1
- package/development/breadcrumb/breadcrumb.js +5 -2
- package/development/button/common.js +18 -14
- package/development/calendar.js +1 -1
- package/development/card/card.js +1 -1
- package/development/checkbox/checkbox-panel.js +1 -1
- package/development/core/i18n/i18n.d.ts +2 -0
- package/development/core/i18n/i18n.d.ts.map +1 -1
- package/development/core/i18n.js +15 -1
- package/development/core/mixins/form-associated-checkbox-mixin.d.ts.map +1 -1
- package/development/core/mixins/form-associated-mixin.d.ts +3 -0
- package/development/core/mixins/form-associated-mixin.d.ts.map +1 -1
- package/development/core/mixins/form-associated-radio-button-mixin.d.ts.map +1 -1
- package/development/core/mixins.js +159 -22
- package/development/datepicker/datepicker-toggle.js +1 -1
- package/development/dialog/dialog-title.js +1 -1
- package/development/expansion-panel/expansion-panel-header.js +1 -1
- package/development/expansion-panel/expansion-panel.js +1 -1
- package/development/file-selector/common.js +1 -1
- package/development/footer.js +1 -1
- package/development/form-field/form-field/form-field.d.ts.map +1 -1
- package/development/form-field/form-field.js +5 -2
- package/development/image.js +1 -1
- package/development/journey-header.js +1 -1
- package/development/link/common.js +19 -7
- package/development/link-list/common.js +1 -1
- package/development/map-container.js +1 -1
- package/development/menu/common/menu-action-common.d.ts +3 -0
- package/development/menu/common/menu-action-common.d.ts.map +1 -1
- package/development/menu/common.js +35 -12
- package/development/navigation/navigation-section.js +1 -1
- package/development/notification.js +1 -1
- package/development/overlay.js +1 -1
- package/development/radio-button/radio-button-panel.js +1 -1
- package/development/select/select.d.ts +4 -1
- package/development/select/select.d.ts.map +1 -1
- package/development/select.js +22 -4
- package/development/skiplink-list.js +1 -1
- package/development/slider.js +1 -1
- package/development/tabs/tab-label.js +1 -1
- package/development/timetable-occupancy.js +1 -1
- package/development/toast.js +1 -1
- package/development/toggle/toggle/toggle.d.ts +25 -6
- package/development/toggle/toggle/toggle.d.ts.map +1 -1
- package/development/toggle/toggle-option/toggle-option.d.ts +2 -6
- package/development/toggle/toggle-option/toggle-option.d.ts.map +1 -1
- package/development/toggle/toggle-option.js +21 -39
- package/development/toggle/toggle.js +57 -39
- package/development/train/train-formation.js +1 -1
- package/development/train/train.js +1 -1
- package/development/visual-checkbox.js +1 -1
- package/dialog/dialog-content.js +3 -3
- package/dialog/dialog-title.js +8 -8
- package/divider.js +12 -12
- package/expansion-panel/expansion-panel-header.js +1 -1
- package/expansion-panel/expansion-panel.js +1 -1
- package/file-selector/common.js +9 -9
- 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/font-characters-extension.css +3 -3
- package/footer.js +4 -4
- package/form-field/form-field/form-field.d.ts.map +1 -1
- package/form-field/form-field.js +7 -5
- package/header/header-button.js +5 -5
- package/header/header-link.js +5 -5
- package/icon.js +36 -36
- package/image.js +1 -1
- package/journey-header.js +5 -5
- 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 +28 -28
- 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 +15 -15
- package/loading-indicator-circle.js +11 -11
- package/map-container.js +5 -5
- package/menu/common/menu-action-common.d.ts +3 -0
- package/menu/common/menu-action-common.d.ts.map +1 -1
- package/menu/common.js +34 -30
- package/menu/menu-button.js +8 -8
- package/menu/menu-link.js +6 -6
- package/menu/menu.js +7 -7
- 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-section.js +1 -1
- package/notification.js +18 -18
- package/option/optgroup.js +11 -11
- package/overlay.js +14 -14
- package/package.json +6 -2
- package/paginator/common.js +6 -6
- package/popover/popover.js +13 -13
- package/radio-button/radio-button-panel.js +6 -6
- package/screen-reader-only.js +5 -5
- package/select/select.d.ts +4 -1
- package/select/select.d.ts.map +1 -1
- package/select.js +35 -28
- package/skiplink-list.js +3 -3
- package/slider.js +13 -13
- package/standard-theme.css +35 -3
- 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-label.js +1 -1
- package/tabs/tab.js +4 -4
- 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.js +5 -5
- package/toggle/toggle/toggle.d.ts +25 -6
- package/toggle/toggle/toggle.d.ts.map +1 -1
- package/toggle/toggle-option/toggle-option.d.ts +2 -6
- package/toggle/toggle-option/toggle-option.d.ts.map +1 -1
- package/toggle/toggle-option.js +44 -52
- package/toggle/toggle.js +103 -83
- package/toggle-check.js +5 -5
- package/train/train-formation.js +1 -1
- package/train/train.js +29 -29
- package/visual-checkbox.js +1 -1
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { __esDecorate as
|
|
2
|
-
import { customElement as
|
|
1
|
+
import { __esDecorate as s, __runInitializers as m } from "tslib";
|
|
2
|
+
import { customElement as n } from "lit/decorators.js";
|
|
3
3
|
import { SbbActionBaseElement as c } from "../core/base-elements.js";
|
|
4
4
|
import { SbbDisabledMixin as b } from "../core/mixins.js";
|
|
5
5
|
import { SbbBlockLinkCommonElementMixin as u } from "./common.js";
|
|
6
6
|
let k = (() => {
|
|
7
|
-
var
|
|
8
|
-
let
|
|
9
|
-
return
|
|
10
|
-
},
|
|
11
|
-
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(
|
|
12
|
-
|
|
13
|
-
})(),
|
|
7
|
+
var e;
|
|
8
|
+
let r = [n("sbb-block-link-static")], l, i = [], t, o = u(b(c));
|
|
9
|
+
return e = class extends o {
|
|
10
|
+
}, t = e, (() => {
|
|
11
|
+
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
12
|
+
s(null, l = { value: t }, r, { kind: "class", name: t.name, metadata: a }, null, i), t = l.value, a && Object.defineProperty(t, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: a }), m(t, i);
|
|
13
|
+
})(), t;
|
|
14
14
|
})();
|
|
15
15
|
export {
|
|
16
16
|
k as SbbBlockLinkStaticElement
|
package/link/block-link.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { __esDecorate as
|
|
2
|
-
import { customElement as
|
|
1
|
+
import { __esDecorate as m, __runInitializers as s } from "tslib";
|
|
2
|
+
import { customElement as n } from "lit/decorators.js";
|
|
3
3
|
import { SbbLinkBaseElement as c } from "../core/base-elements.js";
|
|
4
4
|
import { SbbDisabledMixin as b } from "../core/mixins.js";
|
|
5
5
|
import { SbbBlockLinkCommonElementMixin as u } from "./common.js";
|
|
6
6
|
let k = (() => {
|
|
7
7
|
var t;
|
|
8
|
-
let
|
|
8
|
+
let o = [n("sbb-block-link")], l, i = [], e, r = u(b(c));
|
|
9
9
|
return t = class extends r {
|
|
10
10
|
}, e = t, (() => {
|
|
11
11
|
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(r[Symbol.metadata] ?? null) : void 0;
|
|
12
|
-
|
|
12
|
+
m(null, l = { value: e }, o, { kind: "class", name: e.name, metadata: a }, null, i), e = l.value, a && Object.defineProperty(e, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: a }), s(e, i);
|
|
13
13
|
})(), e;
|
|
14
14
|
})();
|
|
15
15
|
export {
|
package/link/common.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
var _ = (t) => {
|
|
2
2
|
throw TypeError(t);
|
|
3
3
|
};
|
|
4
|
-
var z = (t,
|
|
5
|
-
var h = (t,
|
|
6
|
-
import { __esDecorate as
|
|
4
|
+
var z = (t, o, e) => o.has(t) || _("Cannot " + e);
|
|
5
|
+
var h = (t, o, e) => (z(t, o, "read from private field"), e ? e.call(t) : o.get(t)), f = (t, o, e) => o.has(t) ? _("Cannot add the same private member more than once") : o instanceof WeakSet ? o.add(t) : o.set(t, e), v = (t, o, e, a) => (z(t, o, "write to private field"), a ? a.call(t, e) : o.set(t, e), e);
|
|
6
|
+
import { __esDecorate as x, __runInitializers as m } from "tslib";
|
|
7
7
|
import { property as S } from "lit/decorators.js";
|
|
8
8
|
import { html as w } from "lit/static-html.js";
|
|
9
9
|
import { SbbIconNameMixin as I } from "../icon.js";
|
|
10
10
|
import { hostAttributes as M, slotState as j } from "../core/decorators.js";
|
|
11
11
|
import { isLean as B } from "../core/dom.js";
|
|
12
12
|
import { SbbNegativeMixin as E } from "../core/mixins.js";
|
|
13
|
-
import { css as
|
|
14
|
-
const
|
|
15
|
-
var
|
|
16
|
-
let e = [M({ "data-sbb-link": "" }), j()],
|
|
17
|
-
return
|
|
13
|
+
import { css as p } from "lit";
|
|
14
|
+
const g = p`*,:before,:after{box-sizing:border-box}:host{outline:none!important}@media (forced-colors: active){:host([data-button]){--sbb-link-color-normal: ButtonText;--sbb-link-color-hover: ButtonText;--sbb-link-color-active: ButtonText}}.sbb-action-base{color:var(--sbb-link-color-normal);text-decoration-line:var(--sbb-link-text-decoration, underline);text-decoration-color:var(--sbb-link-text-decoration-color);text-decoration-thickness:.0625rem;text-underline-offset:.3125em;-webkit-user-select:none;user-select:none}@media (forced-colors: active){.sbb-action-base{text-decoration:underline}}.sbb-action-base{display:flex;align-items:center;width:100%;cursor:pointer;padding:var(--sbb-link-padding, 0);outline:none}:host(:is([disabled],:disabled,[disabled-interactive])) .sbb-action-base{pointer-events:none;cursor:default}@media (forced-colors: active){:host(:is([disabled],:disabled,[disabled-interactive])) .sbb-action-base{color:GrayText}}:host(:focus-visible:not([data-focus-origin=mouse],[data-focus-origin=touch])) .sbb-action-base,:host(:not([data-focus-origin=mouse],[data-focus-origin=touch])) .sbb-action-base:focus-visible{outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) solid var(--sbb-focus-outline-width);border-radius:calc(var(--sbb-border-radius-4x) - var(--sbb-focus-outline-offset))}@media (any-hover: hover){:host(:hover:not([disabled],:disabled,[disabled-interactive])) .sbb-action-base{color:var(--sbb-link-color-hover);text-decoration-line:var(--sbb-link-hover-text-decoration, underline);text-decoration-color:var(--sbb-link-text-decoration-color-hover)}}:host(:is(:active,[data-active]):not([disabled],:disabled,[disabled-interactive])) .sbb-action-base{color:var(--sbb-link-color-active)}`, P = (t) => (() => {
|
|
15
|
+
var r, i;
|
|
16
|
+
let e = [M({ "data-sbb-link": "" }), j()], a, c = [], n, l = E(t), s, k = [], u = [];
|
|
17
|
+
return i = class extends l {
|
|
18
18
|
constructor() {
|
|
19
19
|
super(...arguments);
|
|
20
|
-
f(this,
|
|
20
|
+
f(this, r, m(this, k, B() ? "xs" : "s"));
|
|
21
21
|
m(this, u);
|
|
22
22
|
}
|
|
23
23
|
/**
|
|
@@ -26,23 +26,23 @@ const y = g`*,:before,:after{box-sizing:border-box}:host{outline:none!important}
|
|
|
26
26
|
* @default 's' / 'xs' (lean)
|
|
27
27
|
*/
|
|
28
28
|
get size() {
|
|
29
|
-
return h(this,
|
|
29
|
+
return h(this, r);
|
|
30
30
|
}
|
|
31
31
|
set size(b) {
|
|
32
|
-
v(this,
|
|
32
|
+
v(this, r, b);
|
|
33
33
|
}
|
|
34
34
|
renderTemplate() {
|
|
35
35
|
return w`<slot></slot>`;
|
|
36
36
|
}
|
|
37
|
-
},
|
|
37
|
+
}, r = new WeakMap(), n = i, (() => {
|
|
38
38
|
const b = typeof Symbol == "function" && Symbol.metadata ? Object.create(l[Symbol.metadata] ?? null) : void 0;
|
|
39
|
-
s = [S({ reflect: !0 })],
|
|
39
|
+
s = [S({ reflect: !0 })], x(i, null, s, { kind: "accessor", name: "size", static: !1, private: !1, access: { has: (d) => "size" in d, get: (d) => d.size, set: (d, T) => {
|
|
40
40
|
d.size = T;
|
|
41
|
-
} }, metadata: b },
|
|
42
|
-
})(),
|
|
43
|
-
})(), L =
|
|
41
|
+
} }, metadata: b }, k, u), x(null, a = { value: n }, e, { kind: "class", name: n.name, metadata: b }, null, c), n = a.value, b && Object.defineProperty(n, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: b });
|
|
42
|
+
})(), i.styles = g, m(n, c), n;
|
|
43
|
+
})(), L = p`:host{--sbb-link-color-hover: var(--sbb-color-red125);--sbb-link-color-active: var(--sbb-color-red150);--sbb-link-text-decoration-color: color-mix(in srgb, currentcolor 80%, white);--sbb-link-text-decoration-color-hover: currentcolor;--sbb-link-color-normal: var(--sbb-color-granite);--sbb-link-gap: var(--sbb-spacing-fixed-1x);display:block}:host([negative]){--sbb-focus-outline-color: var(--sbb-focus-outline-color-dark);--sbb-link-text-decoration-color: color-mix(in srgb, currentcolor 80%, black);--sbb-link-text-decoration-color-hover: currentcolor;--sbb-link-color-normal: var(--sbb-color-white);--sbb-link-color-hover: var(--sbb-color-cloud);--sbb-link-color-active: var(--sbb-color-silver)}.sbb-action-base{gap:var(--sbb-link-gap)}:host([size=xs]) .sbb-action-base{--sbb-text-font-size: var(--sbb-font-size-text-xs);font-family:var(--sbb-typo-font-family);font-weight:400;line-height:var(--sbb-typo-line-height-body-text);letter-spacing:var(--sbb-typo-letter-spacing-body-text);font-size:var(--sbb-text-font-size)}:host([size=s]) .sbb-action-base{--sbb-text-font-size: var(--sbb-font-size-text-s);font-family:var(--sbb-typo-font-family);font-weight:400;line-height:var(--sbb-typo-line-height-body-text);letter-spacing:var(--sbb-typo-letter-spacing-body-text);font-size:var(--sbb-text-font-size)}:host([size=m]) .sbb-action-base{--sbb-text-font-size: var(--sbb-font-size-text-m);font-family:var(--sbb-typo-font-family);font-weight:400;line-height:var(--sbb-typo-line-height-body-text);letter-spacing:var(--sbb-typo-letter-spacing-body-text);font-size:var(--sbb-text-font-size)}.sbb-link__icon{position:relative;height:calc(var(--sbb-typo-line-height-body-text) * 1em);width:var(--sbb-size-icon-ui-small);flex:0 0 auto;align-self:start}:host(:not([data-slot-names~=icon],[icon-name])) .sbb-link__icon{display:none}:host([icon-placement=end]) .sbb-link__icon{order:2}.sbb-link__icon ::slotted([slot=icon]),.sbb-link__icon sbb-icon{position:absolute;top:50%;transform:translateY(-50%)}`, H = (t) => (() => {
|
|
44
44
|
var l, s;
|
|
45
|
-
let e = P(I(t)),
|
|
45
|
+
let e = P(I(t)), a, c = [], n = [];
|
|
46
46
|
return s = class extends e {
|
|
47
47
|
constructor() {
|
|
48
48
|
super(...arguments);
|
|
@@ -53,8 +53,8 @@ const y = g`*,:before,:after{box-sizing:border-box}:host{outline:none!important}
|
|
|
53
53
|
get iconPlacement() {
|
|
54
54
|
return h(this, l);
|
|
55
55
|
}
|
|
56
|
-
set iconPlacement(
|
|
57
|
-
v(this, l,
|
|
56
|
+
set iconPlacement(r) {
|
|
57
|
+
v(this, l, r);
|
|
58
58
|
}
|
|
59
59
|
renderTemplate() {
|
|
60
60
|
return w`
|
|
@@ -63,17 +63,17 @@ const y = g`*,:before,:after{box-sizing:border-box}:host{outline:none!important}
|
|
|
63
63
|
`;
|
|
64
64
|
}
|
|
65
65
|
}, l = new WeakMap(), (() => {
|
|
66
|
-
const
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
} }, metadata:
|
|
70
|
-
})(), s.styles = [
|
|
71
|
-
})(), O =
|
|
66
|
+
const r = typeof Symbol == "function" && Symbol.metadata ? Object.create(e[Symbol.metadata] ?? null) : void 0;
|
|
67
|
+
a = [S({ attribute: "icon-placement", reflect: !0 })], x(s, null, a, { kind: "accessor", name: "iconPlacement", static: !1, private: !1, access: { has: (i) => "iconPlacement" in i, get: (i) => i.iconPlacement, set: (i, y) => {
|
|
68
|
+
i.iconPlacement = y;
|
|
69
|
+
} }, metadata: r }, c, n), r && Object.defineProperty(s, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: r });
|
|
70
|
+
})(), s.styles = [g, L], s;
|
|
71
|
+
})(), O = p`:host{font-family:inherit;font-weight:inherit;line-height:inherit;letter-spacing:inherit;font-size:inherit;text-align:inherit;--sbb-link-color-hover: var(--sbb-color-red125);--sbb-link-color-active: var(--sbb-color-red150);--sbb-link-text-decoration-color: color-mix(in srgb, currentcolor 80%, white);--sbb-link-text-decoration-color-hover: currentcolor;--sbb-link-color-normal: inherit;color:inherit;display:inline-block}:host([negative]){--sbb-focus-outline-color: var(--sbb-focus-outline-color-dark);--sbb-link-text-decoration-color: color-mix(in srgb, currentcolor 80%, black);--sbb-link-text-decoration-color-hover: currentcolor;--sbb-link-color-hover: var(--sbb-color-graphite);--sbb-link-color-active: var(--sbb-color-metal)}.sbb-action-base{font-family:inherit;font-weight:inherit;line-height:inherit;letter-spacing:inherit;font-size:inherit;text-align:inherit}`, J = (t) => {
|
|
72
72
|
const e = class e extends P(t) {
|
|
73
73
|
};
|
|
74
|
-
e.styles = [
|
|
75
|
-
let
|
|
76
|
-
return
|
|
74
|
+
e.styles = [g, O];
|
|
75
|
+
let o = e;
|
|
76
|
+
return o;
|
|
77
77
|
};
|
|
78
78
|
export {
|
|
79
79
|
H as SbbBlockLinkCommonElementMixin,
|
package/link/link-button.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { __esDecorate as
|
|
1
|
+
import { __esDecorate as r, __runInitializers as m } from "tslib";
|
|
2
2
|
import { customElement as s } from "lit/decorators.js";
|
|
3
3
|
import { SbbButtonBaseElement as b } from "../core/base-elements.js";
|
|
4
4
|
import { SbbDisabledTabIndexActionMixin as c } from "../core/mixins.js";
|
|
5
5
|
import { SbbInlineLinkCommonElementMixin as u } from "./common.js";
|
|
6
6
|
let x = (() => {
|
|
7
|
-
var
|
|
8
|
-
let
|
|
9
|
-
return
|
|
10
|
-
},
|
|
7
|
+
var e;
|
|
8
|
+
let o = [s("sbb-link-button")], l, n = [], t, i = u(c(b));
|
|
9
|
+
return e = class extends i {
|
|
10
|
+
}, t = e, (() => {
|
|
11
11
|
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(i[Symbol.metadata] ?? null) : void 0;
|
|
12
|
-
|
|
13
|
-
})(),
|
|
12
|
+
r(null, l = { value: t }, o, { kind: "class", name: t.name, metadata: a }, null, n), t = l.value, a && Object.defineProperty(t, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: a }), m(t, n);
|
|
13
|
+
})(), t;
|
|
14
14
|
})();
|
|
15
15
|
export {
|
|
16
16
|
x as SbbLinkButtonElement
|
package/link/link-static.js
CHANGED
|
@@ -4,13 +4,13 @@ import { SbbActionBaseElement as c } from "../core/base-elements.js";
|
|
|
4
4
|
import { SbbDisabledMixin as b } from "../core/mixins.js";
|
|
5
5
|
import { SbbInlineLinkCommonElementMixin as u } from "./common.js";
|
|
6
6
|
let y = (() => {
|
|
7
|
-
var
|
|
8
|
-
let
|
|
9
|
-
return
|
|
10
|
-
},
|
|
11
|
-
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(
|
|
12
|
-
s(null, l = { value:
|
|
13
|
-
})(),
|
|
7
|
+
var e;
|
|
8
|
+
let n = [o("sbb-link-static")], l, i = [], t, r = u(b(c));
|
|
9
|
+
return e = class extends r {
|
|
10
|
+
}, t = e, (() => {
|
|
11
|
+
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(r[Symbol.metadata] ?? null) : void 0;
|
|
12
|
+
s(null, l = { value: t }, n, { kind: "class", name: t.name, metadata: a }, null, i), t = l.value, a && Object.defineProperty(t, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: a }), m(t, i);
|
|
13
|
+
})(), t;
|
|
14
14
|
})();
|
|
15
15
|
export {
|
|
16
16
|
y as SbbLinkStaticElement
|
package/link/link.js
CHANGED
|
@@ -5,11 +5,11 @@ import { SbbDisabledMixin as c } from "../core/mixins.js";
|
|
|
5
5
|
import { SbbInlineLinkCommonElementMixin as u } from "./common.js";
|
|
6
6
|
let y = (() => {
|
|
7
7
|
var t;
|
|
8
|
-
let
|
|
9
|
-
return t = class extends
|
|
8
|
+
let n = [o("sbb-link")], l, i = [], e, r = u(c(b));
|
|
9
|
+
return t = class extends r {
|
|
10
10
|
}, e = t, (() => {
|
|
11
|
-
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(
|
|
12
|
-
m(null, l = { value: e },
|
|
11
|
+
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(r[Symbol.metadata] ?? null) : void 0;
|
|
12
|
+
m(null, l = { value: e }, n, { kind: "class", name: e.name, metadata: a }, null, i), e = l.value, a && Object.defineProperty(e, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: a }), s(e, i);
|
|
13
13
|
})(), e;
|
|
14
14
|
})();
|
|
15
15
|
export {
|
package/link-list/common.js
CHANGED
|
@@ -2,9 +2,9 @@ var w = (e) => {
|
|
|
2
2
|
throw TypeError(e);
|
|
3
3
|
};
|
|
4
4
|
var I = (e, s, l) => s.has(e) || w("Cannot " + l);
|
|
5
|
-
var d = (e, s, l) => (I(e, s, "read from private field"), l ? l.call(e) : s.get(e)),
|
|
6
|
-
import { __esDecorate as
|
|
7
|
-
import { LitElement as E,
|
|
5
|
+
var d = (e, s, l) => (I(e, s, "read from private field"), l ? l.call(e) : s.get(e)), _ = (e, s, l) => s.has(e) ? w("Cannot add the same private member more than once") : s instanceof WeakSet ? s.add(e) : s.set(e, l), r = (e, s, l, a) => (I(e, s, "write to private field"), a ? a.call(e, l) : s.set(e, l), l);
|
|
6
|
+
import { __esDecorate as u, __runInitializers as o } from "tslib";
|
|
7
|
+
import { LitElement as E, nothing as $, html as B, css as D } from "lit";
|
|
8
8
|
import { property as v } from "lit/decorators.js";
|
|
9
9
|
import { slotState as N, forceType as j, omitEmptyConverter as M } from "../core/decorators.js";
|
|
10
10
|
import { isLean as O } from "../core/dom.js";
|
|
@@ -12,13 +12,13 @@ import { SbbNegativeMixin as T, SbbNamedSlotListMixin as U } from "../core/mixin
|
|
|
12
12
|
import "../title.js";
|
|
13
13
|
let V = (() => {
|
|
14
14
|
var c, b, m, n;
|
|
15
|
-
let e = [N()], s, l = [], a,
|
|
16
|
-
return n = class extends
|
|
15
|
+
let e = [N()], s, l = [], a, p = T(U(E)), f, k = [], z = [], L, g = [], x = [], C, y = [], S = [];
|
|
16
|
+
return n = class extends p {
|
|
17
17
|
constructor() {
|
|
18
18
|
super(...arguments);
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
19
|
+
_(this, c);
|
|
20
|
+
_(this, b);
|
|
21
|
+
_(this, m);
|
|
22
22
|
this.listChildLocalNames = [
|
|
23
23
|
"sbb-block-link",
|
|
24
24
|
"sbb-block-link-button",
|
|
@@ -56,11 +56,11 @@ let V = (() => {
|
|
|
56
56
|
t.negative = this.negative, t.size = this.size;
|
|
57
57
|
}
|
|
58
58
|
render() {
|
|
59
|
-
return
|
|
59
|
+
return B`
|
|
60
60
|
<div class="sbb-link-list-wrapper">
|
|
61
61
|
<sbb-title
|
|
62
62
|
class="sbb-link-list-title"
|
|
63
|
-
level=${this.titleLevel ||
|
|
63
|
+
level=${this.titleLevel || $}
|
|
64
64
|
visual-level="5"
|
|
65
65
|
?negative=${this.negative}
|
|
66
66
|
id="sbb-link-list-title-id"
|
|
@@ -72,14 +72,14 @@ let V = (() => {
|
|
|
72
72
|
`;
|
|
73
73
|
}
|
|
74
74
|
}, c = new WeakMap(), b = new WeakMap(), m = new WeakMap(), a = n, (() => {
|
|
75
|
-
const i = typeof Symbol == "function" && Symbol.metadata ? Object.create(
|
|
76
|
-
|
|
75
|
+
const i = typeof Symbol == "function" && Symbol.metadata ? Object.create(p[Symbol.metadata] ?? null) : void 0;
|
|
76
|
+
f = [j(), v({ attribute: "title-content", reflect: !0, converter: M })], L = [v({ attribute: "title-level" })], C = [v({ reflect: !0 })], u(n, null, f, { kind: "accessor", name: "titleContent", static: !1, private: !1, access: { has: (t) => "titleContent" in t, get: (t) => t.titleContent, set: (t, h) => {
|
|
77
77
|
t.titleContent = h;
|
|
78
|
-
} }, metadata: i }, k, z),
|
|
78
|
+
} }, metadata: i }, k, z), u(n, null, L, { kind: "accessor", name: "titleLevel", static: !1, private: !1, access: { has: (t) => "titleLevel" in t, get: (t) => t.titleLevel, set: (t, h) => {
|
|
79
79
|
t.titleLevel = h;
|
|
80
|
-
} }, metadata: i }, g, x),
|
|
80
|
+
} }, metadata: i }, g, x), u(n, null, C, { kind: "accessor", name: "size", static: !1, private: !1, access: { has: (t) => "size" in t, get: (t) => t.size, set: (t, h) => {
|
|
81
81
|
t.size = h;
|
|
82
|
-
} }, metadata: i }, y, S),
|
|
82
|
+
} }, metadata: i }, y, S), u(null, s = { value: a }, e, { kind: "class", name: a.name, metadata: i }, null, l), a = s.value, i && Object.defineProperty(a, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: i }), o(a, l);
|
|
83
83
|
})(), a;
|
|
84
84
|
})();
|
|
85
85
|
const W = D`*,:before,:after{box-sizing:border-box}:host{display:block}.sbb-link-list-wrapper{display:flex;flex-direction:column;gap:var(--sbb-spacing-fixed-3x)}.sbb-link-list-title{margin:0}:host(:not([data-slot-names~=title],[title-content])) .sbb-link-list-title{display:none}`;
|
|
@@ -3,18 +3,18 @@ var m = (i) => {
|
|
|
3
3
|
};
|
|
4
4
|
var u = (i, a, r) => a.has(i) || m("Cannot " + r);
|
|
5
5
|
var h = (i, a, r) => (u(i, a, "read from private field"), r ? r.call(i) : a.get(i)), p = (i, a, r) => a.has(i) ? m("Cannot add the same private member more than once") : a instanceof WeakSet ? a.add(i) : a.set(i, r), v = (i, a, r, o) => (u(i, a, "write to private field"), o ? o.call(i, r) : a.set(i, r), r);
|
|
6
|
-
import { __esDecorate as
|
|
6
|
+
import { __esDecorate as _, __runInitializers as l } from "tslib";
|
|
7
7
|
import { css as k, LitElement as y, html as w } from "lit";
|
|
8
8
|
import { customElement as x, property as S } from "lit/decorators.js";
|
|
9
9
|
import { hostAttributes as z } from "./core/decorators.js";
|
|
10
10
|
const E = k`*,:before,:after{box-sizing:border-box}:host{display:inline-block;line-height:0;--sbb-loading-indicator-circle-color: var(--sbb-color-red);--sbb-loading-indicator-circle-padding: .125rem;--sbb-loading-indicator-circle-duration: var(--sbb-disable-animation-duration, 1.5s);--sbb-loading-indicator-circle-background-color: var(--sbb-color-white);--sbb-loading-indicator-circle-background: conic-gradient( from 90deg, var(--sbb-loading-indicator-circle-background-color), var(--sbb-loading-indicator-circle-color) );--sbb-loading-indicator-circle-animated-width: .1875em;--sbb-loading-indicator-circle-animated-height: .1875em;--sbb-loading-indicator-circle-animated-border-radius: 50%}@media (forced-colors: active){:host{--sbb-loading-indicator-circle-color: CanvasText !important;--sbb-loading-indicator-circle-animated-width: 50%;--sbb-loading-indicator-circle-animated-height: 100%;--sbb-loading-indicator-circle-animated-border-radius: 0;--sbb-loading-indicator-circle-background: transparent}}:host([color=smoke]){--sbb-loading-indicator-circle-color: var(--sbb-color-smoke)}:host([color=white]){--sbb-loading-indicator-circle-color: var(--sbb-color-white)}:host([color=white]){--sbb-loading-indicator-circle-background-color: var(--sbb-color-iron)}.sbb-loading-indicator{display:inline-flex;padding:var(--sbb-loading-indicator-circle-padding);vertical-align:middle;line-height:1}.sbb-loading-indicator__animated-element{width:1.25em;height:1.25em;display:inline-block;color:transparent;position:relative;margin:0 auto;overflow:hidden;border-radius:50%;background:var(--sbb-loading-indicator-circle-background);mask:radial-gradient(circle .4375em,rgba(0,0,0,0) 98%,var(--sbb-loading-indicator-circle-background-color));animation:rotation var(--sbb-loading-indicator-circle-duration) infinite linear}.sbb-loading-indicator__animated-element:after{content:"";width:var(--sbb-loading-indicator-circle-animated-width);height:var(--sbb-loading-indicator-circle-animated-height);background:var(--sbb-loading-indicator-circle-color);border-radius:var(--sbb-loading-indicator-circle-animated-border-radius);position:absolute;top:50%;right:0;translate:0 -50%;overflow:hidden;margin:auto}@keyframes rotation{0%{rotate:0deg}to{rotate:359deg}}`;
|
|
11
11
|
let T = (() => {
|
|
12
|
-
var c,
|
|
12
|
+
var c, t;
|
|
13
13
|
let i = [x("sbb-loading-indicator-circle"), z({
|
|
14
14
|
role: "progressbar",
|
|
15
15
|
"aria-busy": "true"
|
|
16
16
|
})], a, r = [], o, d = y, s, b = [], g = [];
|
|
17
|
-
return
|
|
17
|
+
return t = class extends d {
|
|
18
18
|
constructor() {
|
|
19
19
|
super(...arguments);
|
|
20
20
|
p(this, c, l(this, b, "default"));
|
|
@@ -24,8 +24,8 @@ let T = (() => {
|
|
|
24
24
|
get color() {
|
|
25
25
|
return h(this, c);
|
|
26
26
|
}
|
|
27
|
-
set color(
|
|
28
|
-
v(this, c,
|
|
27
|
+
set color(e) {
|
|
28
|
+
v(this, c, e);
|
|
29
29
|
}
|
|
30
30
|
render() {
|
|
31
31
|
return w`
|
|
@@ -34,12 +34,12 @@ let T = (() => {
|
|
|
34
34
|
</span>
|
|
35
35
|
`;
|
|
36
36
|
}
|
|
37
|
-
}, c = new WeakMap(), o =
|
|
38
|
-
const
|
|
39
|
-
s = [S({ reflect: !0 })],
|
|
40
|
-
n.color =
|
|
41
|
-
} }, metadata:
|
|
42
|
-
})(),
|
|
37
|
+
}, c = new WeakMap(), o = t, (() => {
|
|
38
|
+
const e = typeof Symbol == "function" && Symbol.metadata ? Object.create(d[Symbol.metadata] ?? null) : void 0;
|
|
39
|
+
s = [S({ reflect: !0 })], _(t, null, s, { kind: "accessor", name: "color", static: !1, private: !1, access: { has: (n) => "color" in n, get: (n) => n.color, set: (n, f) => {
|
|
40
|
+
n.color = f;
|
|
41
|
+
} }, metadata: e }, b, g), _(null, a = { value: o }, i, { kind: "class", name: o.name, metadata: e }, null, r), o = a.value, e && Object.defineProperty(o, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: e });
|
|
42
|
+
})(), t.styles = E, l(o, r), o;
|
|
43
43
|
})();
|
|
44
44
|
export {
|
|
45
45
|
T as SbbLoadingIndicatorCircleElement
|
package/map-container.js
CHANGED
|
@@ -5,7 +5,7 @@ var y = (a, i, o) => i.has(a) || B("Cannot " + o);
|
|
|
5
5
|
var m = (a, i, o) => (y(a, i, "read from private field"), o ? o.call(a) : i.get(a)), p = (a, i, o) => i.has(a) ? B("Cannot add the same private member more than once") : i instanceof WeakSet ? i.add(a) : i.set(a, o), c = (a, i, o, s) => (y(a, i, "write to private field"), s ? s.call(a, o) : i.set(a, o), o);
|
|
6
6
|
import { __runInitializers as d, __esDecorate as u } from "tslib";
|
|
7
7
|
import { IntersectionController as x } from "@lit-labs/observers/intersection-controller.js";
|
|
8
|
-
import { css as S, LitElement as V,
|
|
8
|
+
import { css as S, LitElement as V, nothing as z, html as U } from "lit";
|
|
9
9
|
import { customElement as I, property as E, state as C } from "lit/decorators.js";
|
|
10
10
|
import { SbbLanguageController as $ } from "./core/controllers.js";
|
|
11
11
|
import { forceType as O } from "./core/decorators.js";
|
|
@@ -15,13 +15,13 @@ import "./button/accent-button.js";
|
|
|
15
15
|
const j = S`*,:before,:after{box-sizing:border-box}:host{display:block;--sbb-map-container-map-height-zero: 18.4375rem;--sbb-map-container-map-height-small: 20rem;--sbb-map-container-sidebar-width: 25rem;--sbb-map-container-sidebar-background-color: var(--sbb-color-white);--sbb-map-container-border-radius: var(--sbb-border-radius-4x);--sbb-map-container-animation-duration: var( --sbb-disable-animation-duration, var(--sbb-animation-duration-4x) );--sbb-map-container-map-height: calc( var(--sbb-map-container-map-height-zero) + var(--sbb-map-container-border-radius) );--sbb-map-container-mobile-sticky-block-start: 0}@media (min-width: 37.5rem){:host{--sbb-map-container-map-height: calc( var(--sbb-map-container-map-height-small) + var(--sbb-map-container-border-radius) )}}@media (min-width: 80rem){:host{--sbb-map-container-sidebar-width: 30rem}}.sbb-map-container{display:grid;grid-template-rows:auto auto}@media (min-width: 52.5rem){.sbb-map-container{grid-template-columns:max(var(--sbb-map-container-sidebar-width)) calc(100% - var(--sbb-map-container-sidebar-width));position:fixed;inset:var(--sbb-map-container-margin-start, var(--sbb-header-height)) 0 0 0}}.sbb-map-container__sidebar-button{position:fixed;left:50%;inset-block-end:var(--sbb-spacing-fixed-5x);visibility:hidden;opacity:0;transform:translate(-50%) translateY(calc(100% + var(--sbb-spacing-fixed-5x)));transition:opacity var(--sbb-map-container-animation-duration) var(--sbb-animation-easing),visibility var(--sbb-map-container-animation-duration) var(--sbb-animation-easing) var(--sbb-map-container-animation-duration),transform var(--sbb-map-container-animation-duration) var(--sbb-animation-easing)}:host([data-scroll-up-button-visible]) .sbb-map-container__sidebar-button{transition:visibility var(--sbb-map-container-animation-duration) var(--sbb-animation-easing),opacity var(--sbb-map-container-animation-duration) var(--sbb-animation-easing),transform var(--sbb-map-container-animation-duration) ease-out;visibility:visible;opacity:1;transform:translate(-50%) translateY(0)}@media (min-width: 52.5rem){.sbb-map-container__sidebar-button{display:none}}.sbb-map-container__sidebar{--sbb-scrollbar-thumb-width: .5rem;--sbb-scrollbar-thumb-width-hover: var(--sbb-scrollbar-thumb-width);--sbb-scrollbar-width-firefox: auto;--sbb-scrollbar-color: var(--sbb-color-black-alpha-30);--sbb-scrollbar-color-hover: var(--sbb-color-black-alpha-60);--sbb-scrollbar-track-color: var(--sbb-color-cloud);--sbb-scrollbar-width: var(--sbb-spacing-fixed-3x)}.sbb-map-container__sidebar::-webkit-scrollbar{width:var(--sbb-scrollbar-width);height:var(--sbb-scrollbar-width);background-color:var(--sbb-scrollbar-track-color, transparent)}.sbb-map-container__sidebar::-webkit-scrollbar-corner{background-color:var(--sbb-scrollbar-track-color, transparent)}.sbb-map-container__sidebar::-webkit-scrollbar-thumb{background-color:var(--sbb-scrollbar-color, currentcolor);border:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width))) solid transparent;border-radius:var(--sbb-border-radius-4x);background-clip:padding-box}.sbb-map-container__sidebar::-webkit-scrollbar-thumb:hover{background-color:var(--sbb-scrollbar-color-hover, currentcolor);border-width:calc(.5 * (var(--sbb-scrollbar-width) - var(--sbb-scrollbar-thumb-width-hover)))}.sbb-map-container__sidebar::-webkit-scrollbar-button,.sbb-map-container__sidebar::-webkit-scrollbar-corner{display:none}@supports not selector(::-webkit-scrollbar){.sbb-map-container__sidebar{scrollbar-width:var(--sbb-scrollbar-width-firefox);scrollbar-color:var(--sbb-scrollbar-color, currentcolor) var(--sbb-scrollbar-track-color, transparent)}}.sbb-map-container__sidebar{grid-column:1/3;grid-row:2/3;width:100%;overflow:hidden auto;position:relative;border-start-end-radius:var(--sbb-map-container-border-radius);border-start-start-radius:var(--sbb-map-container-border-radius);margin-block-start:calc(var(--sbb-map-container-border-radius) * -1);background-color:var(--sbb-map-container-sidebar-background-color)}@media (min-width: 52.5rem){.sbb-map-container__sidebar{grid-column:1/2;grid-row:1/3;border-radius:0;margin-block-start:0;border-block-start:var(--sbb-border-width-1x) solid var(--sbb-color-cloud)}}.sbb-map-container__map{position:sticky;inset-block-start:0;inset-inline:0;grid-row:1/2;grid-column:1/3}@media (max-width: 52.4375rem){.sbb-map-container__map{inset-block-start:var(--sbb-map-container-mobile-sticky-block-start);height:var(--sbb-map-container-map-height)}}@media (min-width: 52.5rem){.sbb-map-container__map{grid-row:1/3;grid-column:2/3;position:relative}}`;
|
|
16
16
|
let N = (() => {
|
|
17
17
|
var n, b, e;
|
|
18
|
-
let a = [I("sbb-map-container")], i, o = [], s, h = V,
|
|
18
|
+
let a = [I("sbb-map-container")], i, o = [], s, h = V, v, _ = [], g = [], w, f = [], k = [];
|
|
19
19
|
return e = class extends h {
|
|
20
20
|
constructor() {
|
|
21
21
|
super(...arguments);
|
|
22
22
|
p(this, n);
|
|
23
23
|
p(this, b);
|
|
24
|
-
c(this, n, d(this,
|
|
24
|
+
c(this, n, d(this, _, !1)), c(this, b, (d(this, g), d(this, f, !1))), this._language = (d(this, k), new $(this)), this._observer = new x(this, {
|
|
25
25
|
target: null,
|
|
26
26
|
callback: (r) => this._toggleButtonVisibilityOnIntersect(r)
|
|
27
27
|
});
|
|
@@ -97,9 +97,9 @@ let N = (() => {
|
|
|
97
97
|
}
|
|
98
98
|
}, n = new WeakMap(), b = new WeakMap(), s = e, (() => {
|
|
99
99
|
const r = typeof Symbol == "function" && Symbol.metadata ? Object.create(h[Symbol.metadata] ?? null) : void 0;
|
|
100
|
-
|
|
100
|
+
v = [O(), E({ attribute: "hide-scroll-up-button", reflect: !0, type: Boolean })], w = [C()], u(e, null, v, { kind: "accessor", name: "hideScrollUpButton", static: !1, private: !1, access: { has: (t) => "hideScrollUpButton" in t, get: (t) => t.hideScrollUpButton, set: (t, l) => {
|
|
101
101
|
t.hideScrollUpButton = l;
|
|
102
|
-
} }, metadata: r },
|
|
102
|
+
} }, metadata: r }, _, g), u(e, null, w, { kind: "accessor", name: "_scrollUpButtonVisible", static: !1, private: !1, access: { has: (t) => "_scrollUpButtonVisible" in t, get: (t) => t._scrollUpButtonVisible, set: (t, l) => {
|
|
103
103
|
t._scrollUpButtonVisible = l;
|
|
104
104
|
} }, metadata: r }, f, k), u(null, i = { value: s }, a, { kind: "class", name: s.name, metadata: r }, null, o), s = i.value, r && Object.defineProperty(s, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: r });
|
|
105
105
|
})(), e.styles = j, d(s, o), s;
|
|
@@ -2,6 +2,9 @@ import { SbbActionBaseElement } from '../../core/base-elements.js';
|
|
|
2
2
|
import { AbstractConstructor, SbbDisabledMixinType } from '../../core/mixins.js';
|
|
3
3
|
import { SbbIconNameMixinType } from '../../icon.js';
|
|
4
4
|
export declare class SbbMenuActionCommonElementMixinType extends SbbDisabledMixinType implements Partial<SbbIconNameMixinType> {
|
|
5
|
+
/**
|
|
6
|
+
* @deprecated Will be removed with next major version. Use the sbb-badge attribute on a sbb-icon as alternative.
|
|
7
|
+
*/
|
|
5
8
|
accessor amount: string;
|
|
6
9
|
accessor iconName: string;
|
|
7
10
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"menu-action-common.d.ts","sourceRoot":"","sources":["../../../../src/elements/menu/common/menu-action-common.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AAExE,OAAO,
|
|
1
|
+
{"version":3,"file":"menu-action-common.d.ts","sourceRoot":"","sources":["../../../../src/elements/menu/common/menu-action-common.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AAExE,OAAO,EACL,KAAK,mBAAmB,EAExB,KAAK,oBAAoB,EAC1B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAoB,KAAK,oBAAoB,EAAE,MAAM,eAAe,CAAC;AAI5E,MAAM,CAAC,OAAO,OAAO,mCACnB,SAAQ,oBACR,YAAW,OAAO,CAAC,oBAAoB,CAAC;IAExC;;OAEG;IACH,SAAgB,MAAM,EAAE,MAAM,CAAC;IAC/B,SAAgB,QAAQ,EAAE,MAAM,CAAC;CAClC;AAGD,eAAO,MAAM,+BAA+B,GAC1C,CAAC,SAAS,mBAAmB,CAAC,oBAAoB,CAAC,cAEvC,CAAC,KACZ,mBAAmB,CAAC,mCAAmC,CAAC,GAAG,CAiC7D,CAAC"}
|
package/menu/common.js
CHANGED
|
@@ -1,49 +1,53 @@
|
|
|
1
|
-
var
|
|
2
|
-
throw TypeError(
|
|
1
|
+
var p = (t) => {
|
|
2
|
+
throw TypeError(t);
|
|
3
3
|
};
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
import { __esDecorate as
|
|
7
|
-
import { css as
|
|
8
|
-
import { property as
|
|
9
|
-
import { html as
|
|
10
|
-
import { forceType as
|
|
11
|
-
import { SbbDisabledMixin as
|
|
12
|
-
import { SbbIconNameMixin as
|
|
13
|
-
const
|
|
14
|
-
var
|
|
15
|
-
let e =
|
|
16
|
-
return n = class extends
|
|
4
|
+
var v = (t, o, e) => o.has(t) || p("Cannot " + e);
|
|
5
|
+
var g = (t, o, e) => (v(t, o, "read from private field"), e ? e.call(t) : o.get(t)), h = (t, o, e) => o.has(t) ? p("Cannot add the same private member more than once") : o instanceof WeakSet ? o.add(t) : o.set(t, e), x = (t, o, e, s) => (v(t, o, "write to private field"), s ? s.call(t, e) : o.set(t, e), e);
|
|
6
|
+
import { __esDecorate as _, __runInitializers as c } from "tslib";
|
|
7
|
+
import { css as w, nothing as k } from "lit";
|
|
8
|
+
import { property as S } from "lit/decorators.js";
|
|
9
|
+
import { html as y } from "lit/static-html.js";
|
|
10
|
+
import { slotState as T, forceType as M } from "../core/decorators.js";
|
|
11
|
+
import { SbbDisabledMixin as I } from "../core/mixins.js";
|
|
12
|
+
import { SbbIconNameMixin as C } from "../icon.js";
|
|
13
|
+
const D = w`*,:before,:after{box-sizing:border-box}:host{outline:none!important;--sbb-menu-action-border-radius: var(--sbb-border-radius-infinity);--sbb-menu-action-outer-horizontal-padding: var(--sbb-spacing-fixed-3x);--sbb-menu-action-outer-vertical-padding: var(--sbb-spacing-fixed-1x);--sbb-menu-action-gap: var(--sbb-spacing-fixed-2x);--sbb-menu-action-cursor: pointer;--sbb-menu-action-color: var(--sbb-color-white);--sbb-menu-action-forced-color-border-color: CanvasText;--sbb-menu-action-content-padding-inline: var(--sbb-spacing-fixed-2x);--sbb-menu-action-content-padding-block: var(--sbb-spacing-fixed-1x);display:block}@media (any-hover: hover){:host(:hover:not([disabled],:disabled,[disabled-interactive])){--sbb-menu-background-color: var(--sbb-color-iron);--sbb-menu-action-forced-color-border-color: Highlight}}:host(:is([disabled],:disabled,[disabled-interactive])){--sbb-menu-action-cursor: default;--sbb-menu-action-color: var(--sbb-color-graphite);--sbb-menu-action-forced-color-border-color: GrayText;pointer-events:none;cursor:default}@media (forced-colors: active){:host(:is([disabled],:disabled,[disabled-interactive])){--sbb-menu-action-color: GrayText}}@media (forced-colors: active){:host([data-button]){--sbb-menu-action-color: ButtonText}}:host([sbb-badge]:not([icon-name],[data-slot-names~=icon])):after{inset:50% calc(100% - var(--sbb-menu-action-outer-horizontal-padding) - var(--sbb-menu-action-content-padding-inline) - .5 * var(--sbb-size-icon-ui-small)) auto auto!important;translate:50% -50%}:host([sbb-badge]:is([icon-name],[data-slot-names~=icon])):after{inset:calc(var(--sbb-menu-action-outer-vertical-padding) + var(--sbb-menu-action-content-padding-block) + var(--sbb-badge-position-offset)) calc(100% - var(--sbb-menu-action-outer-horizontal-padding) - var(--sbb-menu-action-content-padding-inline) - var(--sbb-size-icon-ui-small) + var(--sbb-badge-position-offset)) auto auto!important}:is(.sbb-menu-button,.sbb-menu-link){text-decoration:none;display:block;width:100%;color:var(--sbb-menu-action-color);padding:var(--sbb-menu-action-outer-vertical-padding) var(--sbb-menu-action-outer-horizontal-padding);cursor:var(--sbb-menu-action-cursor);outline:none}.sbb-menu-action__content{--sbb-text-font-size: var(--sbb-font-size-text-xs);font-family:var(--sbb-typo-font-family);font-weight:400;line-height:var(--sbb-typo-line-height-body-text);letter-spacing:var(--sbb-typo-letter-spacing-body-text);font-size:var(--sbb-text-font-size);display:flex;align-items:center;gap:var(--sbb-menu-action-gap);padding:var(--sbb-menu-action-content-padding-block) var(--sbb-menu-action-content-padding-inline);border-radius:var(--sbb-menu-action-border-radius);-webkit-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent;background-color:var(--sbb-menu-background-color)}:host(:focus-visible:not([data-focus-origin=mouse],[data-focus-origin=touch])) .sbb-menu-action__content,:host(:not([data-focus-origin=mouse],[data-focus-origin=touch])) :focus-visible .sbb-menu-action__content{--sbb-focus-outline-color: var(--sbb-focus-outline-color-dark);outline-offset:var(--sbb-focus-outline-offset);outline:var(--sbb-focus-outline-color) solid var(--sbb-focus-outline-width)}@media (forced-colors: active){.sbb-menu-action__content{border:var(--sbb-border-width-2x) solid var(--sbb-menu-action-forced-color-border-color)}}.sbb-menu-action__icon{display:flex;min-width:var(--sbb-size-icon-ui-small);min-height:var(--sbb-size-icon-ui-small)}.sbb-menu-action__label{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host(:is([disabled],:disabled,[disabled-interactive])) .sbb-menu-action__label{text-decoration:line-through}.sbb-menu-action__amount{--sbb-text-font-size: var(--sbb-font-size-text-xxs);font-family:var(--sbb-typo-font-family);font-weight:400;line-height:var(--sbb-typo-line-height-body-text);letter-spacing:var(--sbb-typo-letter-spacing-body-text);font-size:var(--sbb-text-font-size);font-weight:700;display:flex;align-items:center;justify-content:center;padding-inline:var(--sbb-spacing-fixed-1x);border-radius:var(--sbb-border-radius-infinity);background-color:var(--sbb-color-red);color:var(--sbb-color-white);min-width:var(--sbb-spacing-fixed-4x);max-height:var(--sbb-spacing-fixed-4x);flex-shrink:0;margin-inline-start:auto}@media (forced-colors: active){.sbb-menu-action__amount{color:var(--sbb-menu-action-color)}}`, P = (t) => (() => {
|
|
14
|
+
var r, n;
|
|
15
|
+
let e = [T()], s, l = [], a, d = C(I(t)), u, m = [], f = [];
|
|
16
|
+
return n = class extends d {
|
|
17
17
|
constructor() {
|
|
18
18
|
super(...arguments);
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
h(this, r, c(this, m, ""));
|
|
20
|
+
c(this, f);
|
|
21
21
|
}
|
|
22
|
-
/**
|
|
22
|
+
/**
|
|
23
|
+
* Value shown as badge at component end.
|
|
24
|
+
* @deprecated Will be removed with next major version. Use the sbb-badge attribute on a sbb-icon as alternative.
|
|
25
|
+
* @internal
|
|
26
|
+
*/
|
|
23
27
|
get amount() {
|
|
24
|
-
return
|
|
28
|
+
return g(this, r);
|
|
25
29
|
}
|
|
26
|
-
set amount(
|
|
27
|
-
|
|
30
|
+
set amount(i) {
|
|
31
|
+
x(this, r, i);
|
|
28
32
|
}
|
|
29
33
|
renderTemplate() {
|
|
30
|
-
return
|
|
34
|
+
return y`
|
|
31
35
|
<span class="sbb-menu-action__content">
|
|
32
36
|
<span class="sbb-menu-action__icon"> ${super.renderIconSlot()} </span>
|
|
33
37
|
<span class="sbb-menu-action__label">
|
|
34
38
|
<slot></slot>
|
|
35
39
|
</span>
|
|
36
|
-
${this.amount && !this.disabled ?
|
|
40
|
+
${this.amount && !this.disabled ? y`<span class="sbb-menu-action__amount">${this.amount}</span>` : k}
|
|
37
41
|
</span>
|
|
38
42
|
`;
|
|
39
43
|
}
|
|
40
|
-
},
|
|
41
|
-
const
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
} }, metadata: s },
|
|
45
|
-
})(), n.styles =
|
|
44
|
+
}, r = new WeakMap(), a = n, (() => {
|
|
45
|
+
const i = typeof Symbol == "function" && Symbol.metadata ? Object.create(d[Symbol.metadata] ?? null) : void 0;
|
|
46
|
+
u = [M(), S()], _(n, null, u, { kind: "accessor", name: "amount", static: !1, private: !1, access: { has: (b) => "amount" in b, get: (b) => b.amount, set: (b, z) => {
|
|
47
|
+
b.amount = z;
|
|
48
|
+
} }, metadata: i }, m, f), _(null, s = { value: a }, e, { kind: "class", name: a.name, metadata: i }, null, l), a = s.value, i && Object.defineProperty(a, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: i });
|
|
49
|
+
})(), n.styles = D, c(a, l), a;
|
|
46
50
|
})();
|
|
47
51
|
export {
|
|
48
|
-
|
|
52
|
+
P as SbbMenuActionCommonElementMixin
|
|
49
53
|
};
|
package/menu/menu-button.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { __esDecorate as i, __runInitializers as m } from "tslib";
|
|
2
2
|
import { customElement as s } from "lit/decorators.js";
|
|
3
|
-
import { SbbButtonBaseElement as
|
|
4
|
-
import { SbbDisabledTabIndexActionMixin as
|
|
3
|
+
import { SbbButtonBaseElement as b } from "../core/base-elements.js";
|
|
4
|
+
import { SbbDisabledTabIndexActionMixin as u } from "../core/mixins.js";
|
|
5
5
|
import { SbbMenuActionCommonElementMixin as c } from "./common.js";
|
|
6
6
|
let x = (() => {
|
|
7
|
-
var
|
|
8
|
-
let r = [s("sbb-menu-button")], l, n = [],
|
|
9
|
-
return
|
|
10
|
-
},
|
|
7
|
+
var e;
|
|
8
|
+
let r = [s("sbb-menu-button")], l, n = [], t, o = u(c(b));
|
|
9
|
+
return e = class extends o {
|
|
10
|
+
}, t = e, (() => {
|
|
11
11
|
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(o[Symbol.metadata] ?? null) : void 0;
|
|
12
|
-
i(null, l = { value:
|
|
13
|
-
})(),
|
|
12
|
+
i(null, l = { value: t }, r, { kind: "class", name: t.name, metadata: a }, null, n), t = l.value, a && Object.defineProperty(t, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: a }), m(t, n);
|
|
13
|
+
})(), t;
|
|
14
14
|
})();
|
|
15
15
|
export {
|
|
16
16
|
x as SbbMenuButtonElement
|
package/menu/menu-link.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { __esDecorate as m, __runInitializers as
|
|
2
|
-
import { customElement as
|
|
1
|
+
import { __esDecorate as m, __runInitializers as o } from "tslib";
|
|
2
|
+
import { customElement as s } from "lit/decorators.js";
|
|
3
3
|
import { SbbLinkBaseElement as c } from "../core/base-elements.js";
|
|
4
4
|
import { SbbDisabledInteractiveMixin as b } from "../core/mixins.js";
|
|
5
5
|
import { SbbMenuActionCommonElementMixin as u } from "./common.js";
|
|
6
6
|
let y = (() => {
|
|
7
7
|
var t;
|
|
8
|
-
let
|
|
9
|
-
return t = class extends
|
|
8
|
+
let n = [s("sbb-menu-link")], l, i = [], e, r = b(u(c));
|
|
9
|
+
return t = class extends r {
|
|
10
10
|
}, e = t, (() => {
|
|
11
|
-
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(
|
|
12
|
-
m(null, l = { value: e },
|
|
11
|
+
const a = typeof Symbol == "function" && Symbol.metadata ? Object.create(r[Symbol.metadata] ?? null) : void 0;
|
|
12
|
+
m(null, l = { value: e }, n, { kind: "class", name: e.name, metadata: a }, null, i), e = l.value, a && Object.defineProperty(e, Symbol.metadata, { enumerable: !0, configurable: !0, writable: !0, value: a }), o(e, i);
|
|
13
13
|
})(), e;
|
|
14
14
|
})();
|
|
15
15
|
export {
|