scb-wc 0.1.265 → 0.1.267
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/README.md +20 -17
- package/_virtual/{_@oxc-project_runtime@0.139.0 → _@oxc-project_runtime@0.160.0}/helpers/esm/decorate.js +1 -2
- package/all.d.ts +16 -0
- package/all.js +16 -0
- package/bin/scb-wc.mjs +5 -1
- package/component-defaults.js +2 -2
- package/index.js +102 -86
- package/mvc/components/all.js +11 -0
- package/mvc/components/scb-accordion/scb-accordion-item.js +1 -1
- package/mvc/components/scb-accordion/scb-accordion.js +6 -6
- package/mvc/components/scb-app-bar/scb-app-bar.js +3 -3
- package/mvc/components/scb-avatar/scb-avatar.js +1 -1
- package/mvc/components/scb-badge/scb-badge.js +3 -3
- package/mvc/components/scb-breadcrumb/scb-breadcrumb-item.js +1 -1
- package/mvc/components/scb-breadcrumb/scb-breadcrumb.js +4 -4
- package/mvc/components/scb-button/scb-button.js +3 -3
- package/mvc/components/scb-calendar/scb-calendar-event.js +2 -2
- package/mvc/components/scb-calendar/scb-calendar.js +42 -37
- package/mvc/components/scb-calendar-card/scb-calendar-card.js +2 -2
- package/mvc/components/scb-card/scb-card.js +23 -23
- package/mvc/components/scb-checkbox/scb-checkbox-group.js +5 -5
- package/mvc/components/scb-checkbox/scb-checkbox.js +3 -3
- package/mvc/components/scb-chevron/scb-chevron.js +10 -0
- package/mvc/components/scb-chip/scb-chip.js +3 -3
- package/mvc/components/scb-collapse/scb-collapse.js +4 -4
- package/mvc/components/scb-cookies-consent/scb-cookies-consent.js +2 -2
- package/mvc/components/scb-datepicker/scb-datepicker.js +143 -0
- package/mvc/components/scb-dialog/scb-dialog.js +5 -5
- package/mvc/components/scb-divider/scb-divider.js +1 -1
- package/mvc/components/scb-drawer/scb-drawer.js +3 -3
- package/mvc/components/scb-drop-zone/scb-drop-zone.js +3 -3
- package/mvc/components/scb-dropdown/scb-dropdown.js +6 -6
- package/mvc/components/scb-fact-card/scb-fact-card-content.js +6 -6
- package/mvc/components/scb-fact-card/scb-fact-card.js +3 -3
- package/mvc/components/scb-footer/scb-footer-section.js +1 -1
- package/mvc/components/scb-footer/scb-footer.js +1 -1
- package/mvc/components/scb-form-error-summary/scb-form-error-summary.js +2 -2
- package/mvc/components/scb-gallery-grid/scb-gallery-grid.js +1 -1
- package/mvc/components/scb-grid/scb-grid-item.js +1 -1
- package/mvc/components/scb-grid/scb-grid.js +1 -1
- package/mvc/components/scb-grid/scb-stack.js +1 -1
- package/mvc/components/scb-header/scb-header-menu-item.js +1 -1
- package/mvc/components/scb-header/scb-header-tab.js +1 -1
- package/mvc/components/scb-header/scb-header-utility.js +1 -1
- package/mvc/components/scb-header/scb-header.js +11 -11
- package/mvc/components/scb-horizontal-scroller/scb-horizontal-scroller.js +6 -6
- package/mvc/components/scb-icon/scb-icon.js +2 -2
- package/mvc/components/scb-icon-button/scb-icon-button.js +7 -7
- package/mvc/components/scb-keyfigure-card/scb-keyfigure-card.js +6 -6
- package/mvc/components/scb-link/scb-link.js +2 -2
- package/mvc/components/scb-link-button/scb-link-button.js +3 -3
- package/mvc/components/scb-list/scb-list-item.js +9 -9
- package/mvc/components/scb-list/scb-list.js +1 -1
- package/mvc/components/scb-menu/scb-menu-item.js +3 -3
- package/mvc/components/scb-menu/scb-menu-section.js +3 -3
- package/mvc/components/scb-menu/scb-menu.js +5 -5
- package/mvc/components/scb-menu/scb-sub-menu.js +2 -2
- package/mvc/components/scb-nav/scb-nav-item.js +1 -1
- package/mvc/components/scb-nav/scb-nav.js +1 -1
- package/mvc/components/scb-notification-card/scb-notification-card.js +1 -1
- package/mvc/components/scb-options-menu/scb-options-menu-item.js +2 -2
- package/mvc/components/scb-options-menu/scb-options-menu.js +2 -2
- package/mvc/components/scb-options-menu/scb-options-sub-menu.js +2 -2
- package/mvc/components/scb-overlay/scb-overlay.js +3 -3
- package/mvc/components/scb-pagination/scb-pagination.js +6 -6
- package/mvc/components/scb-progress-stepper/scb-progress-step.js +6 -6
- package/mvc/components/scb-progress-stepper/scb-progress-stepper.js +2 -2
- package/mvc/components/scb-radio-button/scb-radio-button.js +4 -4
- package/mvc/components/scb-radio-button/scb-radio-group.js +4 -4
- package/mvc/components/scb-scrollspy/scb-scrollspy.js +6 -6
- package/mvc/components/scb-search/scb-search.js +4 -4
- package/mvc/components/scb-segmented-button/scb-segmented-button.js +1 -1
- package/mvc/components/scb-segmented-button/scb-segmented-item.js +2 -2
- package/mvc/components/scb-select/scb-select-option.js +4 -4
- package/mvc/components/scb-select/scb-select.js +4 -4
- package/mvc/components/scb-skeleton/scb-skeleton.js +2 -2
- package/mvc/components/scb-slider/scb-slider.js +8 -8
- package/mvc/components/scb-snackbar/scb-snackbar.js +3 -3
- package/mvc/components/scb-status-pill/scb-status-pill.js +2 -2
- package/mvc/components/scb-stepper/scb-step.js +2 -2
- package/mvc/components/scb-stepper/scb-stepper.js +2 -2
- package/mvc/components/scb-switch/scb-switch.js +23 -23
- package/mvc/components/scb-table/scb-table.js +1 -1
- package/mvc/components/scb-table-advanced/scb-table-advanced.js +2 -2
- package/mvc/components/scb-table-next/read-table.js +1 -0
- package/mvc/components/scb-table-next/scb-table-next.js +6 -0
- package/mvc/components/scb-tabs/scb-primary-tab.js +2 -2
- package/mvc/components/scb-tabs/scb-secondary-tab.js +2 -2
- package/mvc/components/scb-tabs/scb-tabs.js +4 -4
- package/mvc/components/scb-textfield/scb-textfield.js +34 -176
- package/mvc/components/scb-toc/scb-toc-item.js +1 -1
- package/mvc/components/scb-toc/scb-toc.js +2 -2
- package/mvc/components/scb-tooltip/scb-tooltip.js +3 -3
- package/mvc/components/scb-tour/scb-tour-step.js +1 -0
- package/mvc/components/scb-tour/scb-tour.js +33 -0
- package/mvc/components/scb-viz/scb-viz.js +5 -5
- package/mvc/{vendor → components/shared}/component-size-token.js +1 -1
- package/mvc/components/shared/lazy-focus-ring.js +2 -0
- package/mvc/components/shared/lazy-ripple.js +2 -0
- package/mvc/{vendor → components/shared}/manual-popover.js +1 -1
- package/mvc/components/shared/scb-icon-svg.js +11 -0
- package/mvc/vendor/chip.js +1 -1
- package/mvc/vendor/component-defaults.js +1 -1
- package/mvc/vendor/filter-chip.js +3 -3
- package/mvc/vendor/md-focus-ring.js +1 -1
- package/mvc/vendor/preload-helper.js +1 -1
- package/mvc/vendor/ripple.js +2 -2
- package/mvc/vendor/rolldown-runtime.js +1 -1
- package/mvc/vendor/vendor.js +2 -2
- package/package.json +22 -2
- package/scb-accordion/scb-accordion-item.js +37 -44
- package/scb-accordion/scb-accordion.js +31 -40
- package/scb-action-card/scb-action-card.js +1 -2
- package/scb-app-bar/scb-app-bar.js +44 -49
- package/scb-avatar/scb-avatar.js +42 -43
- package/scb-badge/scb-badge.js +24 -25
- package/scb-breadcrumb/scb-breadcrumb-item.js +11 -15
- package/scb-breadcrumb/scb-breadcrumb.js +37 -38
- package/scb-button/scb-button.js +67 -76
- package/scb-calendar/scb-calendar-event.js +15 -13
- package/scb-calendar/scb-calendar.js +204 -129
- package/scb-calendar-card/scb-calendar-card.js +49 -56
- package/scb-card/scb-card-variants.internal.js +1 -2
- package/scb-card/scb-card.js +119 -138
- package/scb-checkbox/scb-checkbox-group.js +25 -26
- package/scb-checkbox/scb-checkbox.js +39 -38
- package/scb-chevron/scb-chevron.js +9 -10
- package/scb-chip/scb-chip.js +27 -32
- package/scb-collapse/scb-collapse.js +38 -46
- package/scb-components/scb-calendar/scb-calendar-event.d.ts +3 -0
- package/scb-components/scb-calendar/scb-calendar.d.ts +7 -0
- package/scb-components/scb-link/scb-link.d.ts +1 -0
- package/scb-components/scb-table-next/read-table.d.ts +29 -0
- package/scb-components/scb-table-next/scb-table-next.d.ts +22 -0
- package/scb-components/scb-tour/scb-tour-step.d.ts +13 -0
- package/scb-components/scb-tour/scb-tour.d.ts +57 -0
- package/scb-components/scb-viz/scb-viz-actions-runtime.d.ts +26 -0
- package/scb-components/scb-viz/scb-viz-print-runtime.d.ts +36 -0
- package/scb-components/scb-viz/scb-viz-series-differentiation-registry.d.ts +21 -0
- package/scb-components/scb-viz/scb-viz-series-differentiation-runtime.d.ts +42 -0
- package/scb-components/scb-viz/scb-viz-table-runtime.d.ts +31 -0
- package/scb-components/shared/component-size-token.d.ts +1 -0
- package/scb-components/shared/lazy-focus-ring.d.ts +4 -0
- package/scb-components/shared/lazy-ripple.d.ts +9 -0
- package/scb-components/shared/manual-popover.d.ts +7 -0
- package/scb-components/shared/scb-icon-svg.d.ts +3 -0
- package/scb-cookies-consent/scb-cookies-consent.js +28 -39
- package/scb-datepicker/scb-datepicker.js +56 -57
- package/scb-dialog/scb-dialog.js +101 -152
- package/scb-divider/scb-divider.js +14 -15
- package/scb-drawer/scb-drawer.js +36 -58
- package/scb-drop-zone/scb-drop-zone.js +109 -127
- package/scb-dropdown/scb-dropdown.js +50 -81
- package/scb-fact-card/scb-fact-card-content.js +15 -16
- package/scb-fact-card/scb-fact-card.js +38 -40
- package/scb-footer/scb-footer-section.js +9 -10
- package/scb-footer/scb-footer.js +24 -25
- package/scb-form-error-summary/scb-form-error-summary.js +15 -16
- package/scb-gallery-grid/scb-gallery-grid.js +18 -23
- package/scb-grid/scb-grid-item.js +19 -20
- package/scb-grid/scb-grid.js +20 -21
- package/scb-grid/scb-stack.js +16 -17
- package/scb-header/scb-header-drawer.internal.js +1 -2
- package/scb-header/scb-header-menu-group.js +1 -2
- package/scb-header/scb-header-menu-item.js +8 -9
- package/scb-header/scb-header-tab.js +9 -10
- package/scb-header/scb-header-utility.js +1 -2
- package/scb-header/scb-header.js +149 -176
- package/scb-horizontal-scroller/scb-horizontal-scroller.js +37 -41
- package/scb-icon/scb-icon.js +16 -17
- package/scb-icon-button/scb-icon-button.js +48 -57
- package/scb-keyfigure-card/scb-keyfigure-card.js +42 -49
- package/scb-link/scb-link.js +57 -35
- package/scb-link-button/scb-link-button.js +29 -30
- package/scb-list/scb-list-item.js +71 -73
- package/scb-list/scb-list.js +20 -28
- package/scb-menu/scb-menu-item.js +33 -35
- package/scb-menu/scb-menu-section.js +9 -10
- package/scb-menu/scb-menu.js +27 -28
- package/scb-menu/scb-sub-menu.js +8 -9
- package/scb-nav/scb-nav-item.js +13 -34
- package/scb-nav/scb-nav.js +33 -38
- package/scb-notification-card/scb-notification-card.js +44 -45
- package/scb-options-menu/scb-options-menu-item.js +26 -37
- package/scb-options-menu/scb-options-menu.js +31 -42
- package/scb-options-menu/scb-options-sub-menu.js +28 -29
- package/scb-overlay/scb-overlay.js +28 -46
- package/scb-pagination/scb-pagination.js +59 -68
- package/scb-progress-indicator/scb-progress-indicator.js +24 -30
- package/scb-progress-stepper/scb-progress-step.js +34 -39
- package/scb-progress-stepper/scb-progress-stepper.js +24 -25
- package/scb-radio-button/scb-radio-button.js +23 -24
- package/scb-radio-button/scb-radio-group.js +24 -25
- package/scb-scrollspy/scb-scrollspy.js +35 -55
- package/scb-search/scb-search.js +64 -84
- package/scb-segmented-button/scb-segmented-button.js +26 -30
- package/scb-segmented-button/scb-segmented-item.js +20 -21
- package/scb-select/scb-select-option.js +18 -19
- package/scb-select/scb-select.js +76 -102
- package/scb-skeleton/scb-skeleton.js +16 -21
- package/scb-slider/scb-slider.js +36 -37
- package/scb-snackbar/scb-snackbar.js +35 -36
- package/scb-status-pill/scb-status-pill.js +17 -18
- package/scb-stepper/scb-step.js +25 -26
- package/scb-stepper/scb-stepper.js +24 -29
- package/scb-switch/scb-switch.js +47 -46
- package/scb-table/scb-table.js +33 -38
- package/scb-table-advanced/scb-table-advanced.js +51 -82
- package/scb-table-next/read-table.js +86 -0
- package/scb-table-next/scb-table-next.js +225 -0
- package/scb-tabs/scb-primary-tab.js +12 -16
- package/scb-tabs/scb-secondary-tab.js +11 -15
- package/scb-tabs/scb-tabs.js +14 -15
- package/scb-textfield/scb-textfield.js +72 -73
- package/scb-toc/scb-toc-item.js +28 -35
- package/scb-toc/scb-toc.js +16 -17
- package/scb-tooltip/scb-tooltip.js +43 -58
- package/scb-tour/scb-tour-step.js +26 -0
- package/scb-tour/scb-tour.js +367 -0
- package/scb-viz/scb-viz-actions-runtime.js +2 -7
- package/scb-viz/scb-viz-print-runtime.js +3 -4
- package/scb-viz/scb-viz-series-differentiation-registry.js +11 -9
- package/scb-viz/scb-viz-series-differentiation-runtime.js +3 -4
- package/scb-viz/scb-viz-table-runtime.js +4 -13
- package/scb-viz/scb-viz.js +142 -143
- package/scb-wc.bundle.js +10422 -10079
- package/scb-wc.d.ts +32 -0
- package/shared/aria-references.internal.js +1 -2
- package/shared/component-size-token.js +1 -2
- package/shared/lazy-focus-ring.js +1 -2
- package/shared/lazy-ripple.js +2 -3
- package/shared/manual-popover.js +2 -15
- package/shared/scb-icon-svg.js +6 -4
- package/tokens/generated/runtime-colors.js +1 -2
- package/mvc/vendor/lazy-focus-ring.js +0 -2
- package/mvc/vendor/lazy-ripple.js +0 -2
- package/mvc/vendor/scb-chevron.js +0 -10
- package/mvc/vendor/scb-icon-svg.js +0 -11
package/scb-menu/scb-menu.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import e from "
|
|
1
|
+
import { LitElement as e, css as t, html as n, nothing as r } from "lit";
|
|
2
|
+
import { customElement as i, property as a } from "lit/decorators.js";
|
|
2
3
|
import "../scb-divider/scb-divider.js";
|
|
3
4
|
import "./scb-menu-item.js";
|
|
4
5
|
import "./scb-menu-section.js";
|
|
5
6
|
import "./scb-sub-menu.js";
|
|
6
|
-
import
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
var s = class extends t {
|
|
7
|
+
import o from "../_virtual/_@oxc-project_runtime@0.160.0/helpers/esm/decorate.js";
|
|
8
|
+
// src/scb-components/scb-menu/scb-menu.ts
|
|
9
|
+
var s = class extends e {
|
|
10
10
|
constructor(...e) {
|
|
11
11
|
super(...e), this.label = "", this.subLabel = "", this.noHighlightSelected = !1, this.elevation = !1, this.lazySrc = "", this.lazyIdParam = "id", this.lazyChildrenField = "", this.lazyIdField = "id", this.lazyLabelField = "label", this.lazyHrefField = "href", this.lazyHasChildrenField = "hasChildren", this.lazyHasLinkField = "hasLink", this.spacing = void 0, this.spacingTop = void 0, this.spacingBottom = void 0, this.spacingLeft = void 0, this.spacingRight = void 0, this._lazyCache = /* @__PURE__ */ new Map(), this._onGlobalSelect = (e) => {
|
|
12
12
|
let t = e;
|
|
@@ -18,7 +18,7 @@ var s = class extends t {
|
|
|
18
18
|
};
|
|
19
19
|
}
|
|
20
20
|
static {
|
|
21
|
-
this.styles =
|
|
21
|
+
this.styles = t`
|
|
22
22
|
/*
|
|
23
23
|
Designbrygga:
|
|
24
24
|
- Ändra tokenvärden i src/tokens/source/sizing.json eller src/tokens/source/typography.json.
|
|
@@ -117,11 +117,11 @@ var s = class extends t {
|
|
|
117
117
|
`;
|
|
118
118
|
}
|
|
119
119
|
render() {
|
|
120
|
-
return
|
|
120
|
+
return n`
|
|
121
121
|
<nav
|
|
122
|
-
aria-label=${this.label ||
|
|
122
|
+
aria-label=${this.label || r}
|
|
123
123
|
>
|
|
124
|
-
${this.label ?
|
|
124
|
+
${this.label ? n`
|
|
125
125
|
<div class="scb-menu-label-wrapper">
|
|
126
126
|
<div class="scb-menu-label">${this.label}</div>
|
|
127
127
|
<div class="scb-menu-sublabel">
|
|
@@ -129,7 +129,7 @@ var s = class extends t {
|
|
|
129
129
|
</div>
|
|
130
130
|
</div>
|
|
131
131
|
<scb-divider></scb-divider>
|
|
132
|
-
` :
|
|
132
|
+
` : r}
|
|
133
133
|
<div class="panel">
|
|
134
134
|
<slot></slot>
|
|
135
135
|
</div>
|
|
@@ -255,59 +255,58 @@ var s = class extends t {
|
|
|
255
255
|
return typeof e == "boolean" ? e : typeof e == "number" ? e !== 0 : typeof e == "string" ? !/^(false|0|off|no|nej)$/i.test(e.trim()) : !!e;
|
|
256
256
|
}
|
|
257
257
|
};
|
|
258
|
-
|
|
258
|
+
o([a({ type: String })], s.prototype, "label", void 0), o([a({
|
|
259
259
|
type: String,
|
|
260
260
|
attribute: "sub-label"
|
|
261
|
-
})], s.prototype, "subLabel", void 0),
|
|
261
|
+
})], s.prototype, "subLabel", void 0), o([a({
|
|
262
262
|
type: Boolean,
|
|
263
263
|
attribute: "no-highlight-selected",
|
|
264
264
|
reflect: !0
|
|
265
|
-
})], s.prototype, "noHighlightSelected", void 0),
|
|
265
|
+
})], s.prototype, "noHighlightSelected", void 0), o([a({
|
|
266
266
|
type: Boolean,
|
|
267
267
|
reflect: !0
|
|
268
|
-
})], s.prototype, "elevation", void 0),
|
|
268
|
+
})], s.prototype, "elevation", void 0), o([a({
|
|
269
269
|
type: String,
|
|
270
270
|
attribute: "lazy-src"
|
|
271
|
-
})], s.prototype, "lazySrc", void 0),
|
|
271
|
+
})], s.prototype, "lazySrc", void 0), o([a({
|
|
272
272
|
type: String,
|
|
273
273
|
attribute: "lazy-id-param"
|
|
274
|
-
})], s.prototype, "lazyIdParam", void 0),
|
|
274
|
+
})], s.prototype, "lazyIdParam", void 0), o([a({
|
|
275
275
|
type: String,
|
|
276
276
|
attribute: "lazy-children-field"
|
|
277
|
-
})], s.prototype, "lazyChildrenField", void 0),
|
|
277
|
+
})], s.prototype, "lazyChildrenField", void 0), o([a({
|
|
278
278
|
type: String,
|
|
279
279
|
attribute: "lazy-id-field"
|
|
280
|
-
})], s.prototype, "lazyIdField", void 0),
|
|
280
|
+
})], s.prototype, "lazyIdField", void 0), o([a({
|
|
281
281
|
type: String,
|
|
282
282
|
attribute: "lazy-label-field"
|
|
283
|
-
})], s.prototype, "lazyLabelField", void 0),
|
|
283
|
+
})], s.prototype, "lazyLabelField", void 0), o([a({
|
|
284
284
|
type: String,
|
|
285
285
|
attribute: "lazy-href-field"
|
|
286
|
-
})], s.prototype, "lazyHrefField", void 0),
|
|
286
|
+
})], s.prototype, "lazyHrefField", void 0), o([a({
|
|
287
287
|
type: String,
|
|
288
288
|
attribute: "lazy-has-children-field"
|
|
289
|
-
})], s.prototype, "lazyHasChildrenField", void 0),
|
|
289
|
+
})], s.prototype, "lazyHasChildrenField", void 0), o([a({
|
|
290
290
|
type: String,
|
|
291
291
|
attribute: "lazy-has-link-field"
|
|
292
|
-
})], s.prototype, "lazyHasLinkField", void 0),
|
|
292
|
+
})], s.prototype, "lazyHasLinkField", void 0), o([a({
|
|
293
293
|
type: String,
|
|
294
294
|
reflect: !0
|
|
295
|
-
})], s.prototype, "spacing", void 0),
|
|
295
|
+
})], s.prototype, "spacing", void 0), o([a({
|
|
296
296
|
type: String,
|
|
297
297
|
attribute: "spacing-top",
|
|
298
298
|
reflect: !0
|
|
299
|
-
})], s.prototype, "spacingTop", void 0),
|
|
299
|
+
})], s.prototype, "spacingTop", void 0), o([a({
|
|
300
300
|
type: String,
|
|
301
301
|
attribute: "spacing-bottom",
|
|
302
302
|
reflect: !0
|
|
303
|
-
})], s.prototype, "spacingBottom", void 0),
|
|
303
|
+
})], s.prototype, "spacingBottom", void 0), o([a({
|
|
304
304
|
type: String,
|
|
305
305
|
attribute: "spacing-left",
|
|
306
306
|
reflect: !0
|
|
307
|
-
})], s.prototype, "spacingLeft", void 0),
|
|
307
|
+
})], s.prototype, "spacingLeft", void 0), o([a({
|
|
308
308
|
type: String,
|
|
309
309
|
attribute: "spacing-right",
|
|
310
310
|
reflect: !0
|
|
311
|
-
})], s.prototype, "spacingRight", void 0), s =
|
|
312
|
-
//#endregion
|
|
311
|
+
})], s.prototype, "spacingRight", void 0), s = o([i("scb-menu")], s);
|
|
313
312
|
export { s as ScbMenu };
|
package/scb-menu/scb-sub-menu.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import e from "
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
var o = class extends
|
|
1
|
+
import { LitElement as e, css as t, html as n } from "lit";
|
|
2
|
+
import { customElement as r, property as i } from "lit/decorators.js";
|
|
3
|
+
import a from "../_virtual/_@oxc-project_runtime@0.160.0/helpers/esm/decorate.js";
|
|
4
|
+
// src/scb-components/scb-menu/scb-sub-menu.ts
|
|
5
|
+
var o = class extends e {
|
|
6
6
|
constructor(...e) {
|
|
7
7
|
super(...e), this.label = "", this._onGlobalSelect = (e) => {
|
|
8
8
|
let t = e;
|
|
@@ -10,7 +10,7 @@ var o = class extends t {
|
|
|
10
10
|
};
|
|
11
11
|
}
|
|
12
12
|
static {
|
|
13
|
-
this.styles =
|
|
13
|
+
this.styles = t`
|
|
14
14
|
:host {
|
|
15
15
|
display: block;
|
|
16
16
|
width: 100%;
|
|
@@ -24,13 +24,12 @@ var o = class extends t {
|
|
|
24
24
|
window.removeEventListener("scb-menu-select", this._onGlobalSelect), super.disconnectedCallback();
|
|
25
25
|
}
|
|
26
26
|
render() {
|
|
27
|
-
return
|
|
27
|
+
return n`
|
|
28
28
|
<nav aria-label="${this.label}">
|
|
29
29
|
<slot></slot>
|
|
30
30
|
</nav>
|
|
31
31
|
`;
|
|
32
32
|
}
|
|
33
33
|
};
|
|
34
|
-
|
|
35
|
-
//#endregion
|
|
34
|
+
a([i({ type: String })], o.prototype, "label", void 0), o = a([r("scb-sub-menu")], o);
|
|
36
35
|
export { o as ScbSubmenu };
|
package/scb-nav/scb-nav-item.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import e from "
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
var o = class extends
|
|
1
|
+
import { LitElement as e, css as t, html as n } from "lit";
|
|
2
|
+
import { customElement as r, property as i } from "lit/decorators.js";
|
|
3
|
+
import a from "../_virtual/_@oxc-project_runtime@0.160.0/helpers/esm/decorate.js";
|
|
4
|
+
// src/scb-components/scb-nav/scb-nav-item.ts
|
|
5
|
+
var o = class extends e {
|
|
6
6
|
constructor(...e) {
|
|
7
7
|
super(...e), this.href = "", this.dataHref = "", this.disabled = !1, this.__onClick = (e) => {
|
|
8
8
|
if (e.defaultPrevented) return;
|
|
@@ -11,31 +11,15 @@ var o = class extends t {
|
|
|
11
11
|
return;
|
|
12
12
|
}
|
|
13
13
|
let t = (this.href || "").trim();
|
|
14
|
-
|
|
15
|
-
if (t.startsWith("#")) {
|
|
16
|
-
typeof window < "u" && (window.location.hash = t.slice(1));
|
|
17
|
-
return;
|
|
18
|
-
}
|
|
19
|
-
if ((this.getAttribute("target") || "").trim() === "_blank") {
|
|
20
|
-
window.open(t, "_blank", "noopener,noreferrer");
|
|
21
|
-
return;
|
|
22
|
-
}
|
|
23
|
-
window.location.href = t;
|
|
24
|
-
}
|
|
14
|
+
t && (t.startsWith("#") ? typeof window < "u" && (window.location.hash = t.slice(1)) : (this.getAttribute("target") || "").trim() === "_blank" ? window.open(t, "_blank", "noopener,noreferrer") : window.location.href = t);
|
|
25
15
|
}, this.__onKeyDown = (e) => {
|
|
26
|
-
|
|
27
|
-
if (e.key === "Enter") {
|
|
28
|
-
e.preventDefault(), this.click();
|
|
29
|
-
return;
|
|
30
|
-
}
|
|
31
|
-
e.key === " " && e.preventDefault();
|
|
32
|
-
}
|
|
16
|
+
this.disabled || (e.key === "Enter" ? (e.preventDefault(), this.click()) : e.key === " " && e.preventDefault());
|
|
33
17
|
}, this.__onKeyUp = (e) => {
|
|
34
18
|
this.disabled || e.key === " " && (e.preventDefault(), this.click());
|
|
35
19
|
};
|
|
36
20
|
}
|
|
37
21
|
static {
|
|
38
|
-
this.styles =
|
|
22
|
+
this.styles = t`
|
|
39
23
|
:host {
|
|
40
24
|
display: inline-flex;
|
|
41
25
|
align-items: center;
|
|
@@ -75,22 +59,17 @@ var o = class extends t {
|
|
|
75
59
|
}
|
|
76
60
|
__syncA11y() {
|
|
77
61
|
let e = !!(this.href || "").trim();
|
|
78
|
-
|
|
79
|
-
this.setAttribute("aria-disabled", "true"), this.tabIndex = -1, this.removeAttribute("role");
|
|
80
|
-
return;
|
|
81
|
-
}
|
|
82
|
-
this.removeAttribute("aria-disabled"), this.tabIndex = 0, this.setAttribute("role", e ? "link" : "button");
|
|
62
|
+
this.disabled ? (this.setAttribute("aria-disabled", "true"), this.tabIndex = -1, this.removeAttribute("role")) : (this.removeAttribute("aria-disabled"), this.tabIndex = 0, this.setAttribute("role", e ? "link" : "button"));
|
|
83
63
|
}
|
|
84
64
|
render() {
|
|
85
|
-
return
|
|
65
|
+
return n`<span class="label"><slot></slot></span>`;
|
|
86
66
|
}
|
|
87
67
|
};
|
|
88
|
-
|
|
68
|
+
a([i({ type: String })], o.prototype, "href", void 0), a([i({
|
|
89
69
|
type: String,
|
|
90
70
|
attribute: "data-href"
|
|
91
|
-
})], o.prototype, "dataHref", void 0),
|
|
71
|
+
})], o.prototype, "dataHref", void 0), a([i({
|
|
92
72
|
type: Boolean,
|
|
93
73
|
reflect: !0
|
|
94
|
-
})], o.prototype, "disabled", void 0), o =
|
|
95
|
-
//#endregion
|
|
74
|
+
})], o.prototype, "disabled", void 0), o = a([r("scb-nav-item")], o);
|
|
96
75
|
export { o as ScbNavItem };
|
package/scb-nav/scb-nav.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import { renderScbIcon as n } from "../shared/scb-icon-svg.js";
|
|
4
|
-
import "./scb-nav-item.js";
|
|
5
|
-
import { LitElement as r, css as i, html as a } from "lit";
|
|
6
|
-
import { customElement as o, property as s, state as c } from "lit/decorators.js";
|
|
1
|
+
import { LitElement as e, css as t, html as n } from "lit";
|
|
2
|
+
import { customElement as r, property as i, state as a } from "lit/decorators.js";
|
|
7
3
|
import "@material/web/ripple/ripple.js";
|
|
8
|
-
|
|
4
|
+
import { addLazyFocusRingListeners as o } from "../shared/lazy-focus-ring.js";
|
|
5
|
+
import { renderScbIcon as s } from "../shared/scb-icon-svg.js";
|
|
6
|
+
import "./scb-nav-item.js";
|
|
7
|
+
import c from "../_virtual/_@oxc-project_runtime@0.160.0/helpers/esm/decorate.js";
|
|
8
|
+
// src/scb-components/scb-nav/scb-nav.ts
|
|
9
9
|
var l = { fromAttribute(e) {
|
|
10
10
|
return e !== null && e.toLowerCase() !== "false";
|
|
11
|
-
} }, u = class extends
|
|
11
|
+
} }, u = class extends e {
|
|
12
12
|
constructor(...e) {
|
|
13
13
|
super(...e), this.__itemsEl = null, this.__resizeObserver = null, this.__resizeRaf = null, this.__canScrollLeft = !1, this.__canScrollRight = !1, this.label = "", this.activeHref = "", this.activateOnClick = !0, this.scrollShadow = !1, this.leftScrollButtonLabel = "Scrolla vänster", this.rightScrollButtonLabel = "Scrolla höger", this.sticky = !1, this.stickyTop = "0px", this.stickyZIndex = 5, this.stickyBackground = "", this.spacing = void 0, this.spacingTop = void 0, this.spacingBottom = void 0, this.spacingLeft = void 0, this.spacingRight = void 0, this.__autoAriaLabel = !1, this.__itemIdPrefix = `scb-nav-${Math.random().toString(36).slice(2)}`, this.__itemIdCounter = 0, this.__onSlotChange = async () => {
|
|
14
14
|
await this.__decorateItems(), this.__applyActiveHref(), this.__scheduleScrollControlUpdate();
|
|
@@ -50,7 +50,7 @@ var l = { fromAttribute(e) {
|
|
|
50
50
|
};
|
|
51
51
|
}
|
|
52
52
|
static {
|
|
53
|
-
this.styles =
|
|
53
|
+
this.styles = t`
|
|
54
54
|
/*
|
|
55
55
|
Designbrygga:
|
|
56
56
|
- Ändra tokenvärden i src/tokens/source/sizing.json eller src/tokens/source/typography.json.
|
|
@@ -377,7 +377,7 @@ var l = { fromAttribute(e) {
|
|
|
377
377
|
this.style.setProperty("--_scb-nav-sticky-background", r);
|
|
378
378
|
}
|
|
379
379
|
connectedCallback() {
|
|
380
|
-
super.connectedCallback(), this.__removeLazyFocusRingListeners =
|
|
380
|
+
super.connectedCallback(), this.__removeLazyFocusRingListeners = o(this, this.renderRoot), this.hasAttribute("role") || this.setAttribute("role", "navigation"), this.__syncStickyStyles(), this.__syncAriaLabel();
|
|
381
381
|
}
|
|
382
382
|
disconnectedCallback() {
|
|
383
383
|
this.__removeLazyFocusRingListeners?.(), this.__removeLazyFocusRingListeners = void 0, this.__itemsEl?.removeEventListener("scroll", this.__onItemsScroll), this.__itemsEl = null, this.__resizeObserver?.disconnect(), this.__resizeObserver = null, this.__resizeRaf !== null && (cancelAnimationFrame(this.__resizeRaf), this.__resizeRaf = null), super.disconnectedCallback();
|
|
@@ -398,11 +398,7 @@ var l = { fromAttribute(e) {
|
|
|
398
398
|
return;
|
|
399
399
|
}
|
|
400
400
|
let e = (this.label || "").trim();
|
|
401
|
-
|
|
402
|
-
this.__autoAriaLabel &&= (this.removeAttribute("aria-label"), !1);
|
|
403
|
-
return;
|
|
404
|
-
}
|
|
405
|
-
this.setAttribute("aria-label", e), this.__autoAriaLabel = !0;
|
|
401
|
+
e ? (this.setAttribute("aria-label", e), this.__autoAriaLabel = !0) : this.__autoAriaLabel &&= (this.removeAttribute("aria-label"), !1);
|
|
406
402
|
}
|
|
407
403
|
async __decorateItems() {
|
|
408
404
|
let e = this.__getSlottedItems();
|
|
@@ -467,85 +463,84 @@ var l = { fromAttribute(e) {
|
|
|
467
463
|
this.__canScrollLeft = t, this.__canScrollRight = n, this.toggleAttribute("data-scroll-left", t), this.toggleAttribute("data-scroll-right", n);
|
|
468
464
|
}
|
|
469
465
|
render() {
|
|
470
|
-
return
|
|
466
|
+
return n`
|
|
471
467
|
<div class="scb-nav">
|
|
472
|
-
${this.__canScrollLeft ?
|
|
468
|
+
${this.__canScrollLeft ? n`
|
|
473
469
|
<button
|
|
474
470
|
class="scb-nav__scroll-control scb-nav__scroll-control--left"
|
|
475
471
|
type="button"
|
|
476
472
|
aria-label=${this.leftScrollButtonLabel}
|
|
477
473
|
@click=${this.__scrollLeft}
|
|
478
474
|
>
|
|
479
|
-
${
|
|
475
|
+
${s("chevron_left", "scb-nav__scroll-control-icon")}
|
|
480
476
|
</button>
|
|
481
477
|
` : ""}
|
|
482
|
-
${this.scrollShadow ?
|
|
478
|
+
${this.scrollShadow ? n`<div class="scb-nav__scroll-shadow-left"></div>` : ""}
|
|
483
479
|
<div class="scb-nav__items" @click=${this.__onClick} @wheel=${this.__onWheel}>
|
|
484
480
|
<slot @slotchange=${this.__onSlotChange}></slot>
|
|
485
481
|
</div>
|
|
486
|
-
${this.scrollShadow ?
|
|
487
|
-
${this.__canScrollRight ?
|
|
482
|
+
${this.scrollShadow ? n`<div class="scb-nav__scroll-shadow-right"></div>` : ""}
|
|
483
|
+
${this.__canScrollRight ? n`
|
|
488
484
|
<button
|
|
489
485
|
class="scb-nav__scroll-control scb-nav__scroll-control--right"
|
|
490
486
|
type="button"
|
|
491
487
|
aria-label=${this.rightScrollButtonLabel}
|
|
492
488
|
@click=${this.__scrollRight}
|
|
493
489
|
>
|
|
494
|
-
${
|
|
490
|
+
${s("chevron_right", "scb-nav__scroll-control-icon")}
|
|
495
491
|
</button>
|
|
496
492
|
` : ""}
|
|
497
493
|
</div>
|
|
498
494
|
`;
|
|
499
495
|
}
|
|
500
496
|
};
|
|
501
|
-
|
|
497
|
+
c([a()], u.prototype, "__canScrollLeft", void 0), c([a()], u.prototype, "__canScrollRight", void 0), c([i({ type: String })], u.prototype, "label", void 0), c([i({
|
|
502
498
|
type: String,
|
|
503
499
|
attribute: "active-href"
|
|
504
|
-
})], u.prototype, "activeHref", void 0),
|
|
500
|
+
})], u.prototype, "activeHref", void 0), c([i({
|
|
505
501
|
type: Boolean,
|
|
506
502
|
attribute: "activate-on-click",
|
|
507
503
|
converter: l
|
|
508
|
-
})], u.prototype, "activateOnClick", void 0),
|
|
504
|
+
})], u.prototype, "activateOnClick", void 0), c([i({
|
|
509
505
|
type: Boolean,
|
|
510
506
|
attribute: "scroll-shadow",
|
|
511
507
|
converter: l
|
|
512
|
-
})], u.prototype, "scrollShadow", void 0),
|
|
508
|
+
})], u.prototype, "scrollShadow", void 0), c([i({
|
|
513
509
|
type: String,
|
|
514
510
|
attribute: "left-scroll-button-label"
|
|
515
|
-
})], u.prototype, "leftScrollButtonLabel", void 0),
|
|
511
|
+
})], u.prototype, "leftScrollButtonLabel", void 0), c([i({
|
|
516
512
|
type: String,
|
|
517
513
|
attribute: "right-scroll-button-label"
|
|
518
|
-
})], u.prototype, "rightScrollButtonLabel", void 0),
|
|
514
|
+
})], u.prototype, "rightScrollButtonLabel", void 0), c([i({
|
|
519
515
|
type: Boolean,
|
|
520
516
|
reflect: !0
|
|
521
|
-
})], u.prototype, "sticky", void 0),
|
|
517
|
+
})], u.prototype, "sticky", void 0), c([i({
|
|
522
518
|
type: String,
|
|
523
519
|
attribute: "sticky-top"
|
|
524
|
-
})], u.prototype, "stickyTop", void 0),
|
|
520
|
+
})], u.prototype, "stickyTop", void 0), c([i({
|
|
525
521
|
type: Number,
|
|
526
522
|
attribute: "sticky-z-index"
|
|
527
|
-
})], u.prototype, "stickyZIndex", void 0),
|
|
523
|
+
})], u.prototype, "stickyZIndex", void 0), c([i({
|
|
528
524
|
type: String,
|
|
529
525
|
attribute: "sticky-background"
|
|
530
|
-
})], u.prototype, "stickyBackground", void 0),
|
|
526
|
+
})], u.prototype, "stickyBackground", void 0), c([i({
|
|
531
527
|
type: String,
|
|
532
528
|
reflect: !0
|
|
533
|
-
})], u.prototype, "spacing", void 0),
|
|
529
|
+
})], u.prototype, "spacing", void 0), c([i({
|
|
534
530
|
type: String,
|
|
535
531
|
attribute: "spacing-top",
|
|
536
532
|
reflect: !0
|
|
537
|
-
})], u.prototype, "spacingTop", void 0),
|
|
533
|
+
})], u.prototype, "spacingTop", void 0), c([i({
|
|
538
534
|
type: String,
|
|
539
535
|
attribute: "spacing-bottom",
|
|
540
536
|
reflect: !0
|
|
541
|
-
})], u.prototype, "spacingBottom", void 0),
|
|
537
|
+
})], u.prototype, "spacingBottom", void 0), c([i({
|
|
542
538
|
type: String,
|
|
543
539
|
attribute: "spacing-left",
|
|
544
540
|
reflect: !0
|
|
545
|
-
})], u.prototype, "spacingLeft", void 0),
|
|
541
|
+
})], u.prototype, "spacingLeft", void 0), c([i({
|
|
546
542
|
type: String,
|
|
547
543
|
attribute: "spacing-right",
|
|
548
544
|
reflect: !0
|
|
549
|
-
})], u.prototype, "spacingRight", void 0), u =
|
|
550
|
-
//#endregion
|
|
545
|
+
})], u.prototype, "spacingRight", void 0), u = c([r("scb-nav")], u);
|
|
551
546
|
export { u as ScbNav };
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import "../scb-icon-button/scb-icon-button.js";
|
|
4
|
-
import "../scb-icon/scb-icon.js";
|
|
5
|
-
import { LitElement as n, css as r, html as i } from "lit";
|
|
6
|
-
import { customElement as a, property as o, state as s } from "lit/decorators.js";
|
|
1
|
+
import { LitElement as e, css as t, html as n } from "lit";
|
|
2
|
+
import { customElement as r, property as i, state as a } from "lit/decorators.js";
|
|
7
3
|
import "@material/web/icon/icon.js";
|
|
8
|
-
|
|
4
|
+
import "../scb-icon/scb-icon.js";
|
|
5
|
+
import "../scb-icon-button/scb-icon-button.js";
|
|
6
|
+
import { componentSizeToken as o } from "../shared/component-size-token.js";
|
|
7
|
+
import s from "../_virtual/_@oxc-project_runtime@0.160.0/helpers/esm/decorate.js";
|
|
8
|
+
// src/scb-components/scb-notification-card/scb-notification-card.ts
|
|
9
9
|
var c = {
|
|
10
10
|
fromAttribute: (e) => e ?? "",
|
|
11
11
|
toAttribute: (e) => typeof e == "string" ? e.trim() === "" ? null : e : null
|
|
12
|
-
}, l = class extends
|
|
12
|
+
}, l = class extends e {
|
|
13
13
|
constructor(...e) {
|
|
14
14
|
super(...e), this.variant = "success", this.direction = "horizontal", this.title = "", this.notificationCardTitle = "", this.subtitle = "", this.supportingText = "", this.open = !1, this.linkText = "", this.linkHref = "#", this.href = "", this.showIcon = !1, this.showCloseButton = !1, this.closeLabel = "Stäng meddelande", this.sizing = "", this.width = "", this.maxWidth = "", this.height = "", this.maxHeight = "", this.fullHeight = !1, this.fullWidth = !1, this.spacing = void 0, this.spacingTop = void 0, this.spacingBottom = void 0, this.spacingLeft = void 0, this.spacingRight = void 0, this.__hasHeading = !1, this.__hasSubtitle = !1, this.__hasSupportingText = !1, this.__hasFooter = !1, this.__hasIcon = !1, this._closeNotification = () => {
|
|
15
15
|
this.open = !1;
|
|
@@ -45,7 +45,7 @@ var c = {
|
|
|
45
45
|
return this.notificationCardTitle || this.title;
|
|
46
46
|
}
|
|
47
47
|
static {
|
|
48
|
-
this.styles = [
|
|
48
|
+
this.styles = [t`
|
|
49
49
|
/*
|
|
50
50
|
Designbrygga:
|
|
51
51
|
- Ändra tokenvärden i src/tokens/source/sizing.json eller src/tokens/source/typography.json.
|
|
@@ -548,22 +548,22 @@ var c = {
|
|
|
548
548
|
super.updated(e), e.has("width") && (this.width && this.width.trim() !== "" ? this.style.inlineSize = this.width : this.style.removeProperty("inline-size")), e.has("maxWidth") && (this.maxWidth && this.maxWidth.trim() !== "" ? this.style.maxInlineSize = this.maxWidth : this.style.removeProperty("max-inline-size")), e.has("height") && (this.height && this.height.trim() !== "" ? this.style.blockSize = this.height : this.style.removeProperty("block-size")), e.has("maxHeight") && (this.maxHeight && this.maxHeight.trim() !== "" ? this.style.maxBlockSize = this.maxHeight : this.style.removeProperty("max-block-size")), (e.has("spacing") || e.has("spacingTop") || e.has("spacingBottom") || e.has("spacingLeft") || e.has("spacingRight")) && this.__applySpacing();
|
|
549
549
|
}
|
|
550
550
|
render() {
|
|
551
|
-
let
|
|
552
|
-
return
|
|
551
|
+
let e = this.direction === "vertical" ? "vertical" : "horizontal", t = this.__hasHeading || this.__hasLightDomSlot("heading"), r = this.__hasSubtitle || this.__hasLightDomSlot("subtitle"), i = this.__hasSupportingText || this.__hasLightDomSlot("supporting-text"), a = this.__hasFooter || this.__hasLightDomSlot("footer"), s = this.#e, c = this.subtitle, l = this.supportingText, u = t || !!s, d = r || !!c, f = i || !!l, p = a || !!this.linkText, m = !!(u || d), h = !(!f || u || d || p), g = !!(this.showIcon || this.__hasIcon || this.__hasLightDomSlot("icon")), _ = this.linkHref && this.linkHref !== "#" ? this.linkHref : this.href || this.linkHref, v = this.variant === "success" ? "--_icon-color: var(--scb-notification-card-success-content-color, var(--md-sys-color-on-success-container, var(--t-30)));" : this.variant === "error" ? "--_icon-color: var(--scb-notification-card-error-content-color, var(--md-sys-color-on-error-container, var(--e-30)));" : this.variant === "warning" ? "--_icon-color: var(--scb-notification-card-warning-content-color, var(--md-sys-color-on-warning-container, var(--w-20)));" : "--_icon-color: var(--scb-notification-card-info-content-color, var(--md-sys-color-on-info-container, var(--p-30)));";
|
|
552
|
+
return n`
|
|
553
553
|
<div class="notification" type=${this.variant} role="alert" aria-live="assertive" aria-atomic="true">
|
|
554
|
-
<div class="notification-main ${
|
|
555
|
-
${g ?
|
|
554
|
+
<div class="notification-main ${e}">
|
|
555
|
+
${g ? n`
|
|
556
556
|
<div class="notification-leading-icon">
|
|
557
557
|
<slot name="icon" @slotchange=${this.__syncSlots}>
|
|
558
|
-
${this.showIcon ?
|
|
558
|
+
${this.showIcon ? n`<scb-icon aria-hidden="true" icon=${this._iconForVariant()}></scb-icon>` : null}
|
|
559
559
|
</slot>
|
|
560
560
|
</div>
|
|
561
561
|
` : null}
|
|
562
562
|
<div class="notification-text-container ${h ? "no-gap" : ""}">
|
|
563
563
|
<div class="notification-title-container" ?hidden=${!m}>
|
|
564
564
|
<div class="notification-title" ?hidden=${!u}>
|
|
565
|
-
<slot name="heading" ?hidden=${!
|
|
566
|
-
${
|
|
565
|
+
<slot name="heading" ?hidden=${!t} @slotchange=${this.__syncSlots}></slot>
|
|
566
|
+
${t ? "" : s}
|
|
567
567
|
</div>
|
|
568
568
|
<div class="notification-subtitle" ?hidden=${!d}>
|
|
569
569
|
<slot name="subtitle" ?hidden=${!r} @slotchange=${this.__syncSlots}></slot>
|
|
@@ -571,19 +571,19 @@ var c = {
|
|
|
571
571
|
</div>
|
|
572
572
|
</div>
|
|
573
573
|
<div class="notification-text" ?hidden=${!f}>
|
|
574
|
-
<slot name="supporting-text" ?hidden=${!
|
|
575
|
-
${
|
|
574
|
+
<slot name="supporting-text" ?hidden=${!i} @slotchange=${this.__syncSlots}></slot>
|
|
575
|
+
${i ? "" : l}
|
|
576
576
|
</div>
|
|
577
577
|
<div class="notification-footer" ?hidden=${!p}>
|
|
578
|
-
<slot name="footer" ?hidden=${!
|
|
579
|
-
${
|
|
578
|
+
<slot name="footer" ?hidden=${!a} @slotchange=${this.__syncSlots}></slot>
|
|
579
|
+
${a ? "" : n`<a class="footer-link" href="${_}">${this.linkText}</a>`}
|
|
580
580
|
</div>
|
|
581
581
|
</div>
|
|
582
582
|
</div>
|
|
583
|
-
${this.showCloseButton ?
|
|
583
|
+
${this.showCloseButton ? n`
|
|
584
584
|
<div class="notification-close-button">
|
|
585
585
|
<scb-icon-button
|
|
586
|
-
size=${
|
|
586
|
+
size=${o(this, "--scb-notification-close-icon-button-size", [
|
|
587
587
|
"tiny",
|
|
588
588
|
"extra-small",
|
|
589
589
|
"small",
|
|
@@ -602,74 +602,73 @@ var c = {
|
|
|
602
602
|
`;
|
|
603
603
|
}
|
|
604
604
|
};
|
|
605
|
-
|
|
605
|
+
s([i({
|
|
606
606
|
type: String,
|
|
607
607
|
reflect: !0
|
|
608
|
-
})], l.prototype, "variant", void 0),
|
|
608
|
+
})], l.prototype, "variant", void 0), s([i({
|
|
609
609
|
type: String,
|
|
610
610
|
reflect: !0
|
|
611
|
-
})], l.prototype, "direction", void 0),
|
|
611
|
+
})], l.prototype, "direction", void 0), s([i({ type: String })], l.prototype, "title", void 0), s([i({
|
|
612
612
|
type: String,
|
|
613
613
|
attribute: "notification-card-title"
|
|
614
|
-
})], l.prototype, "notificationCardTitle", void 0),
|
|
614
|
+
})], l.prototype, "notificationCardTitle", void 0), s([i({ type: String })], l.prototype, "subtitle", void 0), s([i({
|
|
615
615
|
type: String,
|
|
616
616
|
attribute: "supporting-text"
|
|
617
|
-
})], l.prototype, "supportingText", void 0),
|
|
617
|
+
})], l.prototype, "supportingText", void 0), s([i({
|
|
618
618
|
type: Boolean,
|
|
619
619
|
reflect: !0
|
|
620
|
-
})], l.prototype, "open", void 0),
|
|
620
|
+
})], l.prototype, "open", void 0), s([i({
|
|
621
621
|
type: String,
|
|
622
622
|
attribute: "link-text"
|
|
623
|
-
})], l.prototype, "linkText", void 0),
|
|
623
|
+
})], l.prototype, "linkText", void 0), s([i({
|
|
624
624
|
type: String,
|
|
625
625
|
attribute: "link-href"
|
|
626
|
-
})], l.prototype, "linkHref", void 0),
|
|
626
|
+
})], l.prototype, "linkHref", void 0), s([i({ type: String })], l.prototype, "href", void 0), s([i({
|
|
627
627
|
type: Boolean,
|
|
628
628
|
attribute: "show-icon"
|
|
629
|
-
})], l.prototype, "showIcon", void 0),
|
|
629
|
+
})], l.prototype, "showIcon", void 0), s([i({
|
|
630
630
|
type: Boolean,
|
|
631
631
|
attribute: "show-close-button"
|
|
632
|
-
})], l.prototype, "showCloseButton", void 0),
|
|
632
|
+
})], l.prototype, "showCloseButton", void 0), s([i({
|
|
633
633
|
type: String,
|
|
634
634
|
attribute: "close-label"
|
|
635
|
-
})], l.prototype, "closeLabel", void 0),
|
|
635
|
+
})], l.prototype, "closeLabel", void 0), s([i({
|
|
636
636
|
type: String,
|
|
637
637
|
reflect: !0,
|
|
638
638
|
converter: c
|
|
639
|
-
})], l.prototype, "sizing", void 0),
|
|
639
|
+
})], l.prototype, "sizing", void 0), s([i({
|
|
640
640
|
type: String,
|
|
641
641
|
reflect: !0
|
|
642
|
-
})], l.prototype, "width", void 0),
|
|
642
|
+
})], l.prototype, "width", void 0), s([i({
|
|
643
643
|
type: String,
|
|
644
644
|
reflect: !0,
|
|
645
645
|
attribute: "max-width"
|
|
646
|
-
})], l.prototype, "maxWidth", void 0),
|
|
646
|
+
})], l.prototype, "maxWidth", void 0), s([i({
|
|
647
647
|
type: String,
|
|
648
648
|
reflect: !0
|
|
649
|
-
})], l.prototype, "height", void 0),
|
|
649
|
+
})], l.prototype, "height", void 0), s([i({
|
|
650
650
|
type: String,
|
|
651
651
|
reflect: !0,
|
|
652
652
|
attribute: "max-height"
|
|
653
|
-
})], l.prototype, "maxHeight", void 0),
|
|
653
|
+
})], l.prototype, "maxHeight", void 0), s([i({
|
|
654
654
|
type: Boolean,
|
|
655
655
|
reflect: !0,
|
|
656
656
|
attribute: "full-height"
|
|
657
|
-
})], l.prototype, "fullHeight", void 0),
|
|
657
|
+
})], l.prototype, "fullHeight", void 0), s([i({
|
|
658
658
|
type: Boolean,
|
|
659
659
|
reflect: !0,
|
|
660
660
|
attribute: "full-width"
|
|
661
|
-
})], l.prototype, "fullWidth", void 0),
|
|
661
|
+
})], l.prototype, "fullWidth", void 0), s([i({ type: String })], l.prototype, "spacing", void 0), s([i({
|
|
662
662
|
type: String,
|
|
663
663
|
attribute: "spacing-top"
|
|
664
|
-
})], l.prototype, "spacingTop", void 0),
|
|
664
|
+
})], l.prototype, "spacingTop", void 0), s([i({
|
|
665
665
|
type: String,
|
|
666
666
|
attribute: "spacing-bottom"
|
|
667
|
-
})], l.prototype, "spacingBottom", void 0),
|
|
667
|
+
})], l.prototype, "spacingBottom", void 0), s([i({
|
|
668
668
|
type: String,
|
|
669
669
|
attribute: "spacing-left"
|
|
670
|
-
})], l.prototype, "spacingLeft", void 0),
|
|
670
|
+
})], l.prototype, "spacingLeft", void 0), s([i({
|
|
671
671
|
type: String,
|
|
672
672
|
attribute: "spacing-right"
|
|
673
|
-
})], l.prototype, "spacingRight", void 0),
|
|
674
|
-
//#endregion
|
|
673
|
+
})], l.prototype, "spacingRight", void 0), s([a()], l.prototype, "__hasHeading", void 0), s([a()], l.prototype, "__hasSubtitle", void 0), s([a()], l.prototype, "__hasSupportingText", void 0), s([a()], l.prototype, "__hasFooter", void 0), s([a()], l.prototype, "__hasIcon", void 0), l = s([r("scb-notification-card")], l);
|
|
675
674
|
export { l as ScbNotificationCard };
|