@skf-design-system/ui-components 1.0.2-beta.2 → 1.0.2-beta.4
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 +7 -1
- package/dist/components/accordion/accordion-item.component.js +49 -38
- package/dist/components/accordion/accordion.component.d.ts +1 -1
- package/dist/components/accordion/accordion.component.js +10 -10
- package/dist/components/alert/alert.component.d.ts +5 -1
- package/dist/components/alert/alert.component.js +57 -54
- package/dist/components/alert/alert.styles.js +51 -47
- package/dist/components/breadcrumb/breadcrumb-item.component.js +24 -25
- package/dist/components/breadcrumb/breadcrumb-item.d.ts +2 -2
- package/dist/components/breadcrumb/breadcrumb-item.styles.js +16 -15
- package/dist/components/breadcrumb/breadcrumb.component.d.ts +5 -2
- package/dist/components/breadcrumb/breadcrumb.component.js +51 -46
- package/dist/components/breadcrumb/breadcrumb.d.ts +2 -2
- package/dist/components/breadcrumb/breadcrumb.styles.js +13 -10
- package/dist/components/button/button.component.js +39 -39
- package/dist/components/button/button.styles.js +2 -1
- package/dist/components/card/card.component.d.ts +5 -0
- package/dist/components/card/card.component.js +46 -24
- package/dist/components/card/card.styles.js +31 -14
- package/dist/components/{date-picker/datepicker.calendar.component.d.ts → datepicker/datepicker-calendar.component.d.ts} +4 -1
- package/dist/components/{date-picker/datepicker.calendar.component.js → datepicker/datepicker-calendar.component.js} +7 -7
- package/dist/components/datepicker/datepicker-calendar.d.ts +8 -0
- package/dist/components/datepicker/datepicker-calendar.js +6 -0
- package/dist/components/{date-picker/datepicker.component.d.ts → datepicker/datepicker-popup.component.d.ts} +5 -20
- package/dist/components/{date-picker/datepicker.component.js → datepicker/datepicker-popup.component.js} +12 -12
- package/dist/components/datepicker/datepicker-popup.d.ts +8 -0
- package/dist/components/{date-picker/datepicker.helpers.d.ts → datepicker/datepicker-popup.helpers.d.ts} +3 -3
- package/dist/components/datepicker/datepicker-popup.helpers.js +83 -0
- package/dist/components/datepicker/datepicker-popup.js +6 -0
- package/dist/components/{date-picker/datepicker.styles.js → datepicker/datepicker-popup.styles.js} +3 -3
- package/dist/components/{date-picker-input/datepicker-input.component.d.ts → datepicker/datepicker.component.d.ts} +17 -12
- package/dist/components/{date-picker-input/datepicker-input.component.js → datepicker/datepicker.component.js} +110 -97
- package/dist/components/datepicker/datepicker.d.ts +8 -0
- package/dist/components/datepicker/datepicker.js +6 -0
- package/dist/components/dialog/dialog.component.js +1 -1
- package/dist/components/dialog/dialog.d.ts +2 -2
- package/dist/components/drawer/drawer.d.ts +2 -2
- package/dist/components/header/header.d.ts +2 -2
- package/dist/components/heading/heading.component.d.ts +5 -1
- package/dist/components/heading/heading.component.js +54 -27
- package/dist/components/heading/heading.styles.js +34 -36
- package/dist/components/icon/icon.component.d.ts +4 -0
- package/dist/components/icon/icon.component.js +52 -43
- package/dist/components/icon/icon.styles.js +60 -60
- package/dist/components/input/input.component.js +26 -26
- package/dist/components/logo/logo.component.d.ts +4 -1
- package/dist/components/logo/logo.component.js +55 -51
- package/dist/components/logo/logo.styles.js +26 -16
- package/dist/components/menu/menu-item.d.ts +2 -2
- package/dist/components/menu/menu.d.ts +2 -2
- package/dist/components/nav/nav-item.component.d.ts +2 -2
- package/dist/components/nav/nav.d.ts +2 -2
- package/dist/components/popover/popover.component.js +1 -1
- package/dist/components/popover/popover.d.ts +2 -2
- package/dist/components/progress/progress.d.ts +2 -2
- package/dist/components/progress/progress.styles.js +8 -6
- package/dist/components/segmented-button/segmented-button-item.d.ts +2 -2
- package/dist/components/segmented-button/segmented-button.d.ts +2 -2
- package/dist/components/select/select-option-group.d.ts +2 -2
- package/dist/components/select/select-option.component.d.ts +2 -2
- package/dist/components/select/select-option.component.js +9 -9
- package/dist/components/select/select.component.d.ts +2 -2
- package/dist/components/select/select.component.js +3 -4
- package/dist/components/select/select.controllers.js +11 -14
- package/dist/components/stepper/stepper-item.component.js +47 -47
- package/dist/components/stepper/stepper-item.d.ts +2 -2
- package/dist/components/stepper/stepper.d.ts +2 -2
- package/dist/components/switch/switch.d.ts +2 -2
- package/dist/components/{tab-panel → tabs}/tab-panel.d.ts +2 -2
- package/dist/components/{tab → tabs}/tab.component.d.ts +2 -2
- package/dist/components/{tab → tabs}/tab.d.ts +2 -2
- package/dist/components/{tab-group/tab-group.component.d.ts → tabs/tabs.component.d.ts} +3 -4
- package/dist/components/{tab-group/tab-group.component.js → tabs/tabs.component.js} +35 -36
- package/dist/components/tabs/tabs.d.ts +8 -0
- package/dist/components/tabs/tabs.js +6 -0
- package/dist/components/{tab-group/tab-group.styles.js → tabs/tabs.styles.js} +16 -16
- package/dist/components/tag/tag.component.d.ts +7 -2
- package/dist/components/tag/tag.component.js +69 -65
- package/dist/components/tag/tag.d.ts +2 -2
- package/dist/components/tag/tag.styles.js +63 -50
- package/dist/components/tooltip/tooltip.d.ts +2 -2
- package/dist/custom-elements.json +233 -126
- package/dist/index.d.ts +6 -5
- package/dist/index.js +96 -93
- package/dist/internal/base-classes/popover/popover.base.js +1 -1
- package/dist/internal/components/skf-element.d.ts +1 -3
- package/dist/internal/components/skf-element.js +4 -9
- package/dist/internal/helpers/stateMap.d.ts +14 -0
- package/dist/internal/helpers/stateMap.js +68 -0
- package/dist/internal/helpers/watch.d.ts +1 -1
- package/dist/internal/helpers/watch.js +12 -12
- package/dist/styles/component.styles.js +37 -36
- package/dist/styles/{global-without-fonts.css → global-alt.css} +1 -1
- package/dist/styles/global.css +1 -1
- package/dist/types/jsx/custom-element-jsx.d.ts +86 -44
- package/dist/types/vue/index.d.ts +86 -44
- package/dist/vscode.html-custom-data.json +103 -17
- package/dist/web-types.json +208 -55
- package/package.json +14 -20
- package/dist/components/accordion/accordion-item.test.d.ts +0 -1
- package/dist/components/accordion/accordion.test.d.ts +0 -1
- package/dist/components/checkbox/checkbox.test.d.ts +0 -1
- package/dist/components/date-picker/datepicker.d.ts +0 -10
- package/dist/components/date-picker/datepicker.helpers.js +0 -76
- package/dist/components/date-picker/datepicker.js +0 -8
- package/dist/components/date-picker-input/datepicker-input.d.ts +0 -8
- package/dist/components/date-picker-input/datepicker-input.js +0 -6
- package/dist/components/input/input.test.d.ts +0 -1
- package/dist/components/radio/radio.test.d.ts +0 -1
- package/dist/components/switch/switch.test.d.ts +0 -1
- package/dist/components/tab-group/tab-group.d.ts +0 -8
- package/dist/components/tab-group/tab-group.js +0 -6
- package/dist/internal/playwright/index.d.ts +0 -1
- /package/dist/components/{date-picker/datepicker.calendar.styles.d.ts → datepicker/datepicker-calendar.styles.d.ts} +0 -0
- /package/dist/components/{date-picker/datepicker.calendar.styles.js → datepicker/datepicker-calendar.styles.js} +0 -0
- /package/dist/components/{date-picker/datepicker.styles.d.ts → datepicker/datepicker-popup.styles.d.ts} +0 -0
- /package/dist/components/{date-picker-input/datepicker-input.helpers.d.ts → datepicker/datepicker.helpers.d.ts} +0 -0
- /package/dist/components/{date-picker-input/datepicker-input.helpers.js → datepicker/datepicker.helpers.js} +0 -0
- /package/dist/components/{date-picker-input/datepicker-input.styles.d.ts → datepicker/datepicker.styles.d.ts} +0 -0
- /package/dist/components/{date-picker-input/datepicker-input.styles.js → datepicker/datepicker.styles.js} +0 -0
- /package/dist/components/select/{select.stories.icons.d.ts → stories/select.stories.icons.d.ts} +0 -0
- /package/dist/components/{tab-panel → tabs}/tab-panel.component.d.ts +0 -0
- /package/dist/components/{tab-panel → tabs}/tab-panel.component.js +0 -0
- /package/dist/components/{tab-panel → tabs}/tab-panel.js +0 -0
- /package/dist/components/{tab-panel → tabs}/tab-panel.styles.d.ts +0 -0
- /package/dist/components/{tab-panel → tabs}/tab-panel.styles.js +0 -0
- /package/dist/components/{tab → tabs}/tab.component.js +0 -0
- /package/dist/components/{tab → tabs}/tab.js +0 -0
- /package/dist/components/{tab → tabs}/tab.styles.d.ts +0 -0
- /package/dist/components/{tab → tabs}/tab.styles.js +0 -0
- /package/dist/components/{tab-group/tab-group.styles.d.ts → tabs/tabs.styles.d.ts} +0 -0
@@ -1,79 +1,83 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
import { html as n } from "lit";
|
4
|
-
import { property as p } from "lit/decorators.js";
|
5
|
-
import { classMap as a } from "lit/directives/class-map.js";
|
6
|
-
import { styles as d } from "./logo.styles.js";
|
7
|
-
var g = Object.defineProperty, v = (e, l, s, y) => {
|
8
|
-
for (var c = void 0, r = e.length - 1, h; r >= 0; r--)
|
9
|
-
(h = e[r]) && (c = h(l, s, c) || c);
|
10
|
-
return c && g(l, s, c), c;
|
1
|
+
var f = (c) => {
|
2
|
+
throw TypeError(c);
|
11
3
|
};
|
12
|
-
|
4
|
+
var g = (c, t, r) => t.has(c) || f("Cannot " + r);
|
5
|
+
var a = (c, t, r) => (g(c, t, "read from private field"), r ? r.call(c) : t.get(c)), v = (c, t, r) => t.has(c) ? f("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(c) : t.set(c, r), n = (c, t, r, e) => (g(c, t, "write to private field"), e ? e.call(c, r) : t.set(c, r), r);
|
6
|
+
import { SkfElement as w } from "../../internal/components/skf-element.js";
|
7
|
+
import { stateMap as H } from "../../internal/helpers/stateMap.js";
|
8
|
+
import { watch as M } from "../../internal/helpers/watch.js";
|
9
|
+
import { componentStyles as V } from "../../styles/component.styles.js";
|
10
|
+
import { html as x } from "lit";
|
11
|
+
import { property as d } from "lit/decorators.js";
|
12
|
+
import { styles as z } from "./logo.styles.js";
|
13
|
+
var C = Object.defineProperty, _ = Object.getOwnPropertyDescriptor, m = (c, t, r, e) => {
|
14
|
+
for (var s = e > 1 ? void 0 : e ? _(t, r) : t, i = c.length - 1, l; i >= 0; i--)
|
15
|
+
(l = c[i]) && (s = (e ? l(t, r, s) : l(s)) || s);
|
16
|
+
return e && s && C(t, r, s), s;
|
17
|
+
}, h, p;
|
18
|
+
const y = class y extends w {
|
13
19
|
constructor() {
|
14
|
-
super(...arguments)
|
20
|
+
super(...arguments);
|
21
|
+
v(this, h);
|
22
|
+
v(this, p);
|
23
|
+
n(this, h, this.attachInternals()), n(this, p, a(this, h).states), this.title = "SKF logotype", this.color = "primary";
|
24
|
+
}
|
25
|
+
_handleStateChange() {
|
26
|
+
const r = ["inverse", "primary", "secondary"];
|
27
|
+
H(a(this, p), r).set(this.color);
|
15
28
|
}
|
16
29
|
render() {
|
17
|
-
return
|
18
|
-
<svg
|
19
|
-
class=${a({
|
20
|
-
logo: !0,
|
21
|
-
"logo--color-inverse": this.color === "inverse",
|
22
|
-
"logo--color-secondary": this.color === "secondary"
|
23
|
-
})}
|
24
|
-
viewBox="0 0 1300 300"
|
25
|
-
xmlns="http://www.w3.org/2000/svg"
|
26
|
-
x="0px"
|
27
|
-
y="0px"
|
28
|
-
>
|
30
|
+
return x`
|
31
|
+
<svg id="root" viewBox="0 0 1300 300" xmlns="http://www.w3.org/2000/svg" x="0px" y="0px">
|
29
32
|
<title>${this.title}</title>
|
30
33
|
<g>
|
31
|
-
<
|
32
|
-
|
33
|
-
d="M363.7,300c6.2,0,11.2-5,11.2-11.3v-165c0-6.2-5-11.3-11.3-11.2H157.5c-4.1,0-7.5-3.4-7.5-7.5V45
|
34
|
+
<path
|
35
|
+
d="M363.7,300c6.2,0,11.2-5,11.2-11.3v-165c0-6.2-5-11.3-11.3-11.2H157.5c-4.1,0-7.5-3.4-7.5-7.5V45
|
34
36
|
c0-4.1,3.4-7.5,7.5-7.5l60,0c4.1,0,7.5,3.4,7.5,7.5v18.8c0,6.2,5,11.2,11.2,11.2h90c6.2,0,11.3-5,11.3-11.2V11.2
|
35
37
|
c0-6.2-5-11.2-11.3-11.2L48.7,0c-6.2,0-11.2,5-11.2,11.3v127.5c0,6.2,5,11.2,11.3,11.2H255c4.1,0,7.5,3.4,7.5,7.5V255
|
36
38
|
c0,4.1-3.4,7.5-7.5,7.5H120c-4.1,0-7.5-3.4-7.5-7.5v-56.2c0-6.2-5-11.2-11.3-11.2h-90c-6.2,0-11.3,5-11.3,11.2v90
|
37
39
|
C0,295,5,300,11.3,300H363.7z"
|
38
|
-
|
39
|
-
|
40
|
-
|
40
|
+
/>
|
41
|
+
<path
|
42
|
+
d="M562.5,192.3c0-1,0.8-1.9,1.9-1.9c0.5,0,1,0.2,1.3,0.5c0.3,0.3,104.9,105,105.8,105.9
|
41
43
|
c0.6,0.6,3.4,3.2,7.9,3.2h134.4c6.2,0,11.2-5,11.2-11.2v-90c0-6.2-5-11.2-11.2-11.2h-97c-4.3,0-7.1-2.4-7.8-3.1
|
42
44
|
c-1.4-1.4-70.2-70.3-70.6-70.6c-0.3-0.3-0.6-0.8-0.6-1.3c0-0.5,0.2-1,0.6-1.3c0.3-0.3,32.3-32.4,32.8-32.9
|
43
45
|
c1.8-1.8,4.6-3.2,7.9-3.2c2.8,0,97.1,0,97.1,0c6.2,0,11.3-5,11.3-11.2l0-52.5c0-6.2-5-11.2-11.2-11.2h-96.9
|
44
46
|
c-4.5,0-7.2,2.6-7.9,3.2C670.9,3.8,566,108.8,565.7,109.1c-0.3,0.3-0.8,0.5-1.3,0.5c-1,0-1.9-0.8-1.9-1.9l0-96.5
|
45
47
|
c0-6.2-5-11.2-11.3-11.2H442.5c-6.2,0-11.2,5-11.2,11.2v90c0,6.2,5,11.3,11.2,11.3c4.1,0,7.5,3.4,7.5,7.5v60
|
46
48
|
c0,4.1-3.4,7.5-7.5,7.5c-6.2,0-11.2,5-11.2,11.2v90c0,6.2,5,11.3,11.2,11.3h108.7c6.2,0,11.3-5,11.3-11.3L562.5,192.3z"
|
47
|
-
|
48
|
-
|
49
|
-
|
49
|
+
/>
|
50
|
+
<path
|
51
|
+
d="M1001.2,300c6.2,0,11.3-5,11.3-11.3v-90c0-6.2-5-11.2-11.3-11.2c-4.1,0-7.5-3.4-7.5-7.5v-22.5
|
50
52
|
c0-4.2,3.4-7.5,7.5-7.5h41.2c4.1,0,7.5,3.4,7.5,7.5c0,6.2,5,11.2,11.3,11.2h90.1c6.2,0,11.2-5,11.2-11.2V105
|
51
53
|
c0-6.2-5-11.2-11.2-11.2h-90.1c-6.2,0-11.3,5-11.3,11.2c0,4.1-3.4,7.5-7.5,7.5l-41.2,0c-4.1,0-7.5-3.4-7.5-7.5V45
|
52
54
|
c0-4.1,3.4-7.5,7.5-7.5h116.3c4.1,0,7.5,3.4,7.5,7.5v18.8c0,6.2,5,11.2,11.3,11.2h127.5c6.2,0,11.3-5,11.3-11.2V11.2
|
53
55
|
c0-6.2-5-11.2-11.3-11.2H892.5c-6.2,0-11.2,5-11.2,11.2v90c0,6.2,5,11.3,11.2,11.3c4.1,0,7.5,3.4,7.5,7.5v60
|
54
56
|
c0,4.1-3.4,7.5-7.5,7.5c-6.2,0-11.2,5-11.2,11.2v90c0,6.2,5,11.3,11.2,11.3H1001.2z"
|
55
|
-
|
56
|
-
|
57
|
+
/>
|
58
|
+
<path
|
59
|
+
d="M1207.4,262.9c0-17.5,13.2-30.7,30.1-30.7c16.7,0,30,13.2,30,30.7c0,17.8-13.2,30.9-30,30.9
|
60
|
+
C1220.7,293.8,1207.4,280.7,1207.4,262.9z M1237.6,300c20.2,0,37.4-15.7,37.4-37.1c0-21.2-17.2-36.9-37.4-36.9
|
61
|
+
c-20.4,0-37.6,15.7-37.6,36.9C1200,284.3,1217.2,300,1237.6,300z M1230.9,265.5h6.5l9.9,16.3h6.4l-10.7-16.5
|
62
|
+
c5.5-0.7,9.7-3.6,9.7-10.3c0-7.4-4.4-10.7-13.3-10.7h-14.3v37.6h5.7V265.5z M1230.9,260.7V249h7.7c4,0,8.2,0.9,8.2,5.5
|
63
|
+
c0,5.8-4.3,6.1-9.1,6.1H1230.9z"
|
64
|
+
/>
|
57
65
|
</g>
|
58
|
-
<path
|
59
|
-
d="M1207.4,262.9c0-17.5,13.2-30.7,30.1-30.7c16.7,0,30,13.2,30,30.7c0,17.8-13.2,30.9-30,30.9
|
60
|
-
C1220.7,293.8,1207.4,280.7,1207.4,262.9z M1237.6,300c20.2,0,37.4-15.7,37.4-37.1c0-21.2-17.2-36.9-37.4-36.9
|
61
|
-
c-20.4,0-37.6,15.7-37.6,36.9C1200,284.3,1217.2,300,1237.6,300z M1230.9,265.5h6.5l9.9,16.3h6.4l-10.7-16.5
|
62
|
-
c5.5-0.7,9.7-3.6,9.7-10.3c0-7.4-4.4-10.7-13.3-10.7h-14.3v37.6h5.7V265.5z M1230.9,260.7V249h7.7c4,0,8.2,0.9,8.2,5.5
|
63
|
-
c0,5.8-4.3,6.1-9.1,6.1H1230.9z"
|
64
|
-
/>
|
65
66
|
</svg>
|
66
67
|
`;
|
67
68
|
}
|
68
69
|
};
|
69
|
-
|
70
|
-
let
|
71
|
-
|
72
|
-
|
73
|
-
],
|
74
|
-
|
75
|
-
|
76
|
-
],
|
70
|
+
h = new WeakMap(), p = new WeakMap(), y.styles = [V, z];
|
71
|
+
let o = y;
|
72
|
+
m([
|
73
|
+
d({ type: String })
|
74
|
+
], o.prototype, "title", 2);
|
75
|
+
m([
|
76
|
+
d({ type: String })
|
77
|
+
], o.prototype, "color", 2);
|
78
|
+
m([
|
79
|
+
M("color")
|
80
|
+
], o.prototype, "_handleStateChange", 1);
|
77
81
|
export {
|
78
|
-
|
82
|
+
o as SkfLogo
|
79
83
|
};
|
@@ -1,25 +1,35 @@
|
|
1
1
|
import { css as o } from "lit";
|
2
|
-
const
|
3
|
-
|
2
|
+
const r = o`
|
3
|
+
@layer components {
|
4
|
+
@layer base {
|
5
|
+
:host {
|
6
|
+
display: inline-flex;
|
7
|
+
}
|
4
8
|
|
5
|
-
|
6
|
-
|
7
|
-
}
|
9
|
+
#root {
|
10
|
+
--_skf-logo-color: var(--skf-logo-primary);
|
8
11
|
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
12
|
+
aspect-ratio: 13 / 3;
|
13
|
+
block-size: var(--mod-logo-height, var(--skf-size-32));
|
14
|
+
fill: var(--_skf-logo-color);
|
15
|
+
}
|
16
|
+
}
|
14
17
|
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
+
@layer mods {
|
19
|
+
:host(:state(secondary)) {
|
20
|
+
#root {
|
21
|
+
--_skf-logo-color: var(--skf-logo-secondary);
|
22
|
+
}
|
23
|
+
}
|
18
24
|
|
19
|
-
|
20
|
-
|
25
|
+
:host(:state(inverse)) {
|
26
|
+
#root {
|
27
|
+
--_skf-logo-color: var(--skf-logo-inverse);
|
28
|
+
}
|
29
|
+
}
|
30
|
+
}
|
21
31
|
}
|
22
32
|
`;
|
23
33
|
export {
|
24
|
-
|
34
|
+
r as styles
|
25
35
|
};
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { SkfMenuItem } from './menu-item.component';
|
2
|
-
export * from './menu-item.component';
|
1
|
+
import { SkfMenuItem } from './menu-item.component.js';
|
2
|
+
export * from './menu-item.component.js';
|
3
3
|
export default SkfMenuItem;
|
4
4
|
declare global {
|
5
5
|
interface HTMLElementTagNameMap {
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import '../link/link.js';
|
2
|
-
import type SkfLink from '../link/link.js';
|
3
2
|
import { SkfElement } from '../../internal/components/skf-element';
|
3
|
+
import type { Icon } from '../../internal/types.js';
|
4
4
|
import { type CSSResultGroup } from 'lit';
|
5
5
|
/**
|
6
6
|
* The `<skf-nav>` is a component that displays a list of <nav-items>.
|
@@ -12,7 +12,7 @@ import { type CSSResultGroup } from 'lit';
|
|
12
12
|
export declare class SkfNavItem extends SkfElement {
|
13
13
|
static styles: CSSResultGroup;
|
14
14
|
href: string;
|
15
|
-
icon?:
|
15
|
+
icon?: Icon;
|
16
16
|
connectedCallback(): void;
|
17
17
|
render(): import("lit").TemplateResult<1>;
|
18
18
|
}
|
@@ -9,7 +9,7 @@ var c = Object.defineProperty, m = Object.getOwnPropertyDescriptor, a = (l, r, o
|
|
9
9
|
};
|
10
10
|
const n = class n extends h {
|
11
11
|
constructor() {
|
12
|
-
super(), this.offset = 8, this.hideArrow = !1, this.
|
12
|
+
super(), this.offset = 8, this.hideArrow = !1, this.arrow = !this.hideArrow, this.placement = "bottom-start", this.triggerEvent = "click", this.variant = "popup", h.classMap = { popover: !0 };
|
13
13
|
}
|
14
14
|
hideArrowChanged() {
|
15
15
|
this.arrow = !this.hideArrow;
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { SkfPopover } from './popover.component';
|
2
|
-
export * from './popover.component';
|
1
|
+
import { SkfPopover } from './popover.component.js';
|
2
|
+
export * from './popover.component.js';
|
3
3
|
export default SkfPopover;
|
4
4
|
declare global {
|
5
5
|
interface HTMLElementTagNameMap {
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { SkfProgress } from './progress.component';
|
2
|
-
export * from './progress.component';
|
1
|
+
import { SkfProgress } from './progress.component.js';
|
2
|
+
export * from './progress.component.js';
|
3
3
|
export default SkfProgress;
|
4
4
|
declare global {
|
5
5
|
interface HTMLElementTagNameMap {
|
@@ -1,8 +1,10 @@
|
|
1
1
|
import { css as r } from "lit";
|
2
|
-
const
|
2
|
+
const o = r`
|
3
3
|
@layer components {
|
4
4
|
@layer base {
|
5
5
|
#root {
|
6
|
+
--_skf-progress-value: 0%;
|
7
|
+
|
6
8
|
background: var(--skf-bg-color-neutral-3);
|
7
9
|
block-size: var(--skf-size-8);
|
8
10
|
border-radius: 0.25rem; /* Missing token */
|
@@ -14,7 +16,7 @@ const e = r`
|
|
14
16
|
border-radius: inherit;
|
15
17
|
content: '';
|
16
18
|
display: block;
|
17
|
-
inline-size: var(--_skf-progress-value
|
19
|
+
inline-size: var(--_skf-progress-value);
|
18
20
|
transition: inline-size calc(var(--skf-motion-duration-slow) * 1ms)
|
19
21
|
cubic-bezier(0.4, 0.93, 0.71, 0.89);
|
20
22
|
}
|
@@ -28,11 +30,11 @@ const e = r`
|
|
28
30
|
infinite reverse;
|
29
31
|
background-image: linear-gradient(
|
30
32
|
-45deg,
|
31
|
-
|
33
|
+
rgb(255 255 255 / 20%) 25%,
|
32
34
|
transparent 25%,
|
33
35
|
transparent 50%,
|
34
|
-
|
35
|
-
|
36
|
+
rgb(255 255 255 / 20%) 50%,
|
37
|
+
rgb(255 255 255 / 20%) 75%,
|
36
38
|
transparent 75%,
|
37
39
|
transparent
|
38
40
|
);
|
@@ -49,5 +51,5 @@ const e = r`
|
|
49
51
|
}
|
50
52
|
`;
|
51
53
|
export {
|
52
|
-
|
54
|
+
o as styles
|
53
55
|
};
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { SkfSegmentedButtonItem } from './segmented-button-item.component';
|
2
|
-
export * from './segmented-button-item.component';
|
1
|
+
import { SkfSegmentedButtonItem } from './segmented-button-item.component.js';
|
2
|
+
export * from './segmented-button-item.component.js';
|
3
3
|
export default SkfSegmentedButtonItem;
|
4
4
|
declare global {
|
5
5
|
interface HTMLElementTagNameMap {
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { SkfSegmentedButton } from './segmented-button.component';
|
2
|
-
export * from './segmented-button.component';
|
1
|
+
import { SkfSegmentedButton } from './segmented-button.component.js';
|
2
|
+
export * from './segmented-button.component.js';
|
3
3
|
export default SkfSegmentedButton;
|
4
4
|
declare global {
|
5
5
|
interface HTMLElementTagNameMap {
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { SkfSelectOptionGroup } from './select-option-group.component';
|
2
|
-
export * from './select-option-group.component';
|
1
|
+
import { SkfSelectOptionGroup } from './select-option-group.component.js';
|
2
|
+
export * from './select-option-group.component.js';
|
3
3
|
export default SkfSelectOptionGroup;
|
4
4
|
declare global {
|
5
5
|
interface HTMLElementTagNameMap {
|
@@ -1,8 +1,8 @@
|
|
1
|
+
import '../icon/icon.js';
|
1
2
|
import { SkfElement } from '../../internal/components/skf-element.js';
|
2
3
|
import type { Icon, IconColor } from '../../internal/types.js';
|
3
4
|
import { type CSSResultGroup } from 'lit';
|
4
|
-
import '
|
5
|
-
import type { SkfSelect } from '../select/select.component.js';
|
5
|
+
import type { SkfSelect } from './select.component.js';
|
6
6
|
export interface SelectOptionEvent {
|
7
7
|
value: string | null;
|
8
8
|
option: SkfSelectOption;
|
@@ -1,13 +1,13 @@
|
|
1
|
+
import "../icon/icon.js";
|
1
2
|
import { SkfElement as u } from "../../internal/components/skf-element.js";
|
2
3
|
import { componentStyles as f } from "../../styles/component.styles.js";
|
3
|
-
import { LitElement as m, html as
|
4
|
+
import { LitElement as m, html as d } from "lit";
|
4
5
|
import { property as l, queryAssignedNodes as _ } from "lit/decorators.js";
|
5
6
|
import { ifDefined as p } from "lit/directives/if-defined.js";
|
6
|
-
import "../icon/icon.js";
|
7
7
|
import { styles as y } from "./select-option.styles.js";
|
8
|
-
var v = Object.defineProperty, b = Object.getOwnPropertyDescriptor, o = (
|
9
|
-
for (var r = i > 1 ? void 0 : i ? b(t, s) : t, a =
|
10
|
-
(c =
|
8
|
+
var v = Object.defineProperty, b = Object.getOwnPropertyDescriptor, o = (h, t, s, i) => {
|
9
|
+
for (var r = i > 1 ? void 0 : i ? b(t, s) : t, a = h.length - 1, c; a >= 0; a--)
|
10
|
+
(c = h[a]) && (r = (i ? c(t, s, r) : c(r)) || r);
|
11
11
|
return i && r && v(t, s, r), r;
|
12
12
|
};
|
13
13
|
const n = class n extends u {
|
@@ -67,7 +67,7 @@ const n = class n extends u {
|
|
67
67
|
) : "";
|
68
68
|
}
|
69
69
|
render() {
|
70
|
-
return
|
70
|
+
return d`
|
71
71
|
<button
|
72
72
|
?disabled=${this.disabled}
|
73
73
|
@click=${this._handleClick}
|
@@ -78,15 +78,15 @@ const n = class n extends u {
|
|
78
78
|
<slot>${this.text}</slot>
|
79
79
|
<div id="adornments">
|
80
80
|
<slot name="icon">
|
81
|
-
${this.icon &&
|
81
|
+
${this.icon && d`
|
82
82
|
<skf-icon
|
83
|
-
class=${p((this.disabled || !this.iconColor) && "skf-icon-host")}
|
84
83
|
color=${p(this.iconColor)}
|
84
|
+
data-color=${p((this.disabled || !this.iconColor) && "custom")}
|
85
85
|
name=${this.icon}
|
86
86
|
></skf-icon>
|
87
87
|
`}
|
88
88
|
</slot>
|
89
|
-
${this.shortLabel &&
|
89
|
+
${this.shortLabel && d`<div id="short-label">${this.shortLabel}</div>`}
|
90
90
|
</div>
|
91
91
|
</button>
|
92
92
|
`;
|
@@ -1,9 +1,9 @@
|
|
1
|
+
import '../tag/tag.js';
|
1
2
|
import { FormBase } from '../../internal/components/formBase.js';
|
3
|
+
import '../../internal/components/hint/hint.js';
|
2
4
|
import { PopoverController } from '../../internal/controllers/popover.controller.js';
|
3
5
|
import type { FormFieldSeverity } from '../../internal/types.js';
|
4
6
|
import { type CSSResultGroup } from 'lit';
|
5
|
-
import '../../internal/components/hint/hint';
|
6
|
-
import '../tag/tag';
|
7
7
|
import type { SelectOptionEvent, SkfSelectOption } from './select-option.component.js';
|
8
8
|
import { DeveloperFeedbackController, GlobalClickController, KeyboardNavigationController } from './select.controllers.js';
|
9
9
|
/**
|
@@ -1,5 +1,7 @@
|
|
1
|
+
import "../tag/tag.js";
|
1
2
|
import { computePosition as v, flip as f, shift as _, offset as g } from "@floating-ui/dom";
|
2
3
|
import { FormBase as b } from "../../internal/components/formBase.js";
|
4
|
+
import "../../internal/components/hint/hint.js";
|
3
5
|
import { PopoverController as y } from "../../internal/controllers/popover.controller.js";
|
4
6
|
import { findMatchingTags as O } from "../../internal/helpers/findMatchingTags.js";
|
5
7
|
import { hintSeverity as x } from "../../internal/helpers/hintSeverity.js";
|
@@ -11,8 +13,6 @@ import { nothing as C, html as n } from "lit";
|
|
11
13
|
import { property as o, state as h, query as p } from "lit/decorators.js";
|
12
14
|
import { classMap as E } from "lit/directives/class-map.js";
|
13
15
|
import { ifDefined as m } from "lit/directives/if-defined.js";
|
14
|
-
import "../../internal/components/hint/hint.js";
|
15
|
-
import "../tag/tag.js";
|
16
16
|
import { GlobalClickController as L, KeyboardNavigationController as k, DeveloperFeedbackController as A } from "./select.controllers.js";
|
17
17
|
import { styles as P } from "./select.styles.js";
|
18
18
|
var T = Object.defineProperty, D = Object.getOwnPropertyDescriptor, s = (u, t, e, l) => {
|
@@ -199,7 +199,6 @@ const c = class c extends b {
|
|
199
199
|
aria-expanded=${this._expanded}
|
200
200
|
aria-invalid=${this._invalid}
|
201
201
|
aria-haspopup="listbox"
|
202
|
-
class="skf-icon-host"
|
203
202
|
id="select-button"
|
204
203
|
role="combobox"
|
205
204
|
>
|
@@ -208,7 +207,7 @@ const c = class c extends b {
|
|
208
207
|
class=${E({ "selected-value": !0, "contains-meta-info": !this.value })}>
|
209
208
|
${this._computeVisibleValue()}
|
210
209
|
</span>
|
211
|
-
<skf-icon class="arrow" name="chevronDown"></skf-icon>
|
210
|
+
<skf-icon class="arrow" data-color="custom" name="chevronDown"></skf-icon>
|
212
211
|
</button>
|
213
212
|
</label>
|
214
213
|
<div aria-multiselectable=${m(this.multiple && !0)} id="select-dropdown" popover role="listbox">
|
@@ -2,8 +2,8 @@ import { raiseError as a } from "../../internal/helpers/raiseError.js";
|
|
2
2
|
class d {
|
3
3
|
constructor(t) {
|
4
4
|
this._globalClickHandler = (e) => {
|
5
|
-
var
|
6
|
-
!((
|
5
|
+
var s;
|
6
|
+
!((s = this.host) != null && s.localName) || e.target.closest(this.host.localName) || (this.host._expanded = !1);
|
7
7
|
}, (this.host = t).addController(this);
|
8
8
|
}
|
9
9
|
// hostConnected() {
|
@@ -64,16 +64,16 @@ class p {
|
|
64
64
|
});
|
65
65
|
}
|
66
66
|
_focusSiblingOption(t) {
|
67
|
-
const e = (l) => l === document.activeElement,
|
68
|
-
if (!
|
67
|
+
const e = (l) => l === document.activeElement, i = this._selectableOptions.find((l) => e(l));
|
68
|
+
if (!i) {
|
69
69
|
this._focusFirstOption();
|
70
70
|
return;
|
71
71
|
}
|
72
|
-
const
|
73
|
-
let o =
|
72
|
+
const s = this._selectableOptions.indexOf(i);
|
73
|
+
let o = s - 1, n = s + 1;
|
74
74
|
o < 0 && (o = this._selectableOptions.length - 1), n >= this._selectableOptions.length && (n = 0);
|
75
75
|
const h = this._selectableOptions[t === "next" ? n : o];
|
76
|
-
|
76
|
+
i.blur(), h.focus();
|
77
77
|
}
|
78
78
|
_selectFocusedOption(t) {
|
79
79
|
t.selected = !0;
|
@@ -82,7 +82,7 @@ class p {
|
|
82
82
|
return !this.host || !this.host._optionsList ? [] : this.host._optionsList.filter((t) => !t.disabled);
|
83
83
|
}
|
84
84
|
}
|
85
|
-
class
|
85
|
+
class b {
|
86
86
|
constructor(t) {
|
87
87
|
(this.host = t).addController(this);
|
88
88
|
}
|
@@ -103,18 +103,15 @@ class u {
|
|
103
103
|
),
|
104
104
|
reason: "attribute-mismatch",
|
105
105
|
replaceStrings: [t, "min or max", "together with multiple"]
|
106
|
-
})
|
107
|
-
|
108
|
-
a({
|
109
|
-
// eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
|
110
|
-
assert: e || s,
|
106
|
+
}), a({
|
107
|
+
assert: (this.host.hideTags && this.host.multiple) ?? !this.host.hideTags,
|
111
108
|
reason: "attribute-mismatch",
|
112
109
|
replaceStrings: [t, "hide-tags", "together with multiple"]
|
113
110
|
});
|
114
111
|
}
|
115
112
|
}
|
116
113
|
export {
|
117
|
-
|
114
|
+
b as DeveloperFeedbackController,
|
118
115
|
d as GlobalClickController,
|
119
116
|
p as KeyboardNavigationController
|
120
117
|
};
|
@@ -2,34 +2,34 @@ var v = (e) => {
|
|
2
2
|
throw TypeError(e);
|
3
3
|
};
|
4
4
|
var u = (e, i, t) => i.has(e) || v("Cannot " + t);
|
5
|
-
var d = (e, i, t) => (u(e, i, "read from private field"), t ? t.call(e) : i.get(e)), _ = (e, i, t) => i.has(e) ? v("Cannot add the same private member more than once") : i instanceof WeakSet ? i.add(e) : i.set(e, t), r = (e, i, t,
|
5
|
+
var d = (e, i, t) => (u(e, i, "read from private field"), t ? t.call(e) : i.get(e)), _ = (e, i, t) => i.has(e) ? v("Cannot add the same private member more than once") : i instanceof WeakSet ? i.add(e) : i.set(e, t), r = (e, i, t, a) => (u(e, i, "write to private field"), a ? a.call(e, t) : i.set(e, t), t);
|
6
6
|
import "../icon/icon.js";
|
7
|
-
import { SkfElement as
|
8
|
-
import { watch as
|
9
|
-
import { componentStyles as
|
7
|
+
import { SkfElement as g } from "../../internal/components/skf-element.js";
|
8
|
+
import { watch as C } from "../../internal/helpers/watch.js";
|
9
|
+
import { componentStyles as x } from "../../styles/component.styles.js";
|
10
10
|
import "lit";
|
11
|
-
import { property as
|
11
|
+
import { property as b, state as c } from "lit/decorators.js";
|
12
12
|
import { classMap as $ } from "lit/directives/class-map.js";
|
13
|
-
import { ifDefined as
|
14
|
-
import { literal as
|
13
|
+
import { ifDefined as w } from "lit/directives/if-defined.js";
|
14
|
+
import { literal as S, html as y } from "lit/static-html.js";
|
15
15
|
import { styles as U } from "./stepper-item.styles.js";
|
16
|
-
var I = Object.defineProperty, O = Object.getOwnPropertyDescriptor,
|
17
|
-
for (var p =
|
18
|
-
(m = e[h]) && (p = (
|
19
|
-
return
|
20
|
-
},
|
21
|
-
const f = class f extends
|
16
|
+
var I = Object.defineProperty, O = Object.getOwnPropertyDescriptor, o = (e, i, t, a) => {
|
17
|
+
for (var p = a > 1 ? void 0 : a ? O(i, t) : i, h = e.length - 1, m; h >= 0; h--)
|
18
|
+
(m = e[h]) && (p = (a ? m(i, t, p) : m(p)) || p);
|
19
|
+
return a && p && I(i, t, p), p;
|
20
|
+
}, l, n;
|
21
|
+
const f = class f extends g {
|
22
22
|
constructor() {
|
23
23
|
super();
|
24
|
-
_(this,
|
24
|
+
_(this, l);
|
25
25
|
_(this, n);
|
26
|
-
r(this,
|
26
|
+
r(this, l, !1), r(this, n, !1), this.completed = !1, this._index = 0, this._linear = !1, this._handleClick = () => {
|
27
27
|
this._linear || (this.state = "active");
|
28
28
|
}, this.role = "listitem";
|
29
29
|
}
|
30
30
|
set _setInternalState(t) {
|
31
|
-
r(this,
|
32
|
-
r(this,
|
31
|
+
r(this, l, !0), this._uiState = t, t === "active" || t === "activeCompleted" ? this.state = t === "active" ? "active" : "completed" : this.state = void 0, setTimeout(() => {
|
32
|
+
r(this, l, !1);
|
33
33
|
});
|
34
34
|
}
|
35
35
|
get _setInternalState() {
|
@@ -44,8 +44,8 @@ const f = class f extends b {
|
|
44
44
|
this._setInternalState = "activeCompleted";
|
45
45
|
return;
|
46
46
|
}
|
47
|
-
if (d(this,
|
48
|
-
r(this,
|
47
|
+
if (d(this, l)) {
|
48
|
+
r(this, l, !1);
|
49
49
|
return;
|
50
50
|
}
|
51
51
|
r(this, n, ["active", "completed"].includes(String(this.state)) && !["active", "activeCompleted"].includes(String(this._uiState))), this._emitUpdate();
|
@@ -60,9 +60,9 @@ const f = class f extends b {
|
|
60
60
|
}), r(this, n, !1);
|
61
61
|
}
|
62
62
|
render() {
|
63
|
-
const t = this._linear ?
|
64
|
-
return
|
65
|
-
<${
|
63
|
+
const t = this._linear ? S`div` : S`button`;
|
64
|
+
return y`
|
65
|
+
<${t}
|
66
66
|
@click=${this._handleClick}
|
67
67
|
?disabled=${this._disabled}
|
68
68
|
class=${$({
|
@@ -72,42 +72,42 @@ const f = class f extends b {
|
|
72
72
|
"stepper-item--completed": this._uiState === "completed",
|
73
73
|
"stepper-item--enabled": this._uiState === "enabled"
|
74
74
|
})}
|
75
|
-
type=${
|
75
|
+
type=${w(this._linear ? void 0 : "button")}
|
76
76
|
>
|
77
77
|
<div class="stepper-item__circle">
|
78
|
-
${this._uiState === "activeCompleted" ?
|
78
|
+
${this._uiState === "activeCompleted" ? y`<skf-icon color="inverse" name="check"></skf-icon>` : this._index}
|
79
79
|
</div>
|
80
80
|
<slot class="stepper-item__label"></slot>
|
81
|
-
</${
|
81
|
+
</${t}>
|
82
82
|
`;
|
83
83
|
}
|
84
84
|
};
|
85
|
-
|
86
|
-
let
|
87
|
-
|
88
|
-
|
89
|
-
],
|
90
|
-
|
91
|
-
|
92
|
-
],
|
93
|
-
|
85
|
+
l = new WeakMap(), n = new WeakMap(), f.styles = [x, U];
|
86
|
+
let s = f;
|
87
|
+
o([
|
88
|
+
b({ reflect: !0 })
|
89
|
+
], s.prototype, "state", 2);
|
90
|
+
o([
|
91
|
+
b({ type: Boolean })
|
92
|
+
], s.prototype, "completed", 2);
|
93
|
+
o([
|
94
94
|
c()
|
95
|
-
],
|
96
|
-
|
95
|
+
], s.prototype, "_disabled", 2);
|
96
|
+
o([
|
97
97
|
c()
|
98
|
-
],
|
99
|
-
|
98
|
+
], s.prototype, "_index", 2);
|
99
|
+
o([
|
100
100
|
c()
|
101
|
-
],
|
102
|
-
|
101
|
+
], s.prototype, "_linear", 2);
|
102
|
+
o([
|
103
103
|
c()
|
104
|
-
],
|
105
|
-
|
104
|
+
], s.prototype, "_uiState", 2);
|
105
|
+
o([
|
106
106
|
c()
|
107
|
-
],
|
108
|
-
|
109
|
-
|
110
|
-
],
|
107
|
+
], s.prototype, "_setInternalState", 1);
|
108
|
+
o([
|
109
|
+
C("state")
|
110
|
+
], s.prototype, "_handleState", 1);
|
111
111
|
export {
|
112
|
-
|
112
|
+
s as SkfStepperItem
|
113
113
|
};
|