@scouterna/ui-webc 2.0.0 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{index-D42maJcS.js → index-5z4HClQY.js} +7 -8
- package/dist/cjs/index-5z4HClQY.js.map +1 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/scout-bottom-bar-item.cjs.entry.js +8 -2
- package/dist/cjs/scout-bottom-bar-item.entry.cjs.js.map +1 -1
- package/dist/cjs/scout-bottom-bar.cjs.entry.js +2 -2
- package/dist/cjs/scout-button.cjs.entry.js +18 -3
- package/dist/cjs/scout-button.entry.cjs.js.map +1 -1
- package/dist/cjs/scout-card.cjs.entry.js +2 -2
- package/dist/cjs/scout-checkbox.cjs.entry.js +2 -2
- package/dist/cjs/scout-divider.cjs.entry.js +19 -0
- package/dist/cjs/scout-divider.entry.cjs.js.map +1 -0
- package/dist/cjs/scout-field.cjs.entry.js +2 -2
- package/dist/cjs/scout-input.cjs.entry.js +1 -1
- package/dist/cjs/scout-link.cjs.entry.js +64 -0
- package/dist/cjs/scout-link.entry.cjs.js.map +1 -0
- package/dist/cjs/scout-list-view-item.cjs.entry.js +64 -0
- package/dist/cjs/scout-list-view-item.entry.cjs.js.map +1 -0
- package/dist/cjs/scout-list-view.cjs.entry.js +21 -0
- package/dist/cjs/scout-list-view.entry.cjs.js.map +1 -0
- package/dist/cjs/scout-loader.cjs.entry.js +73 -0
- package/dist/cjs/scout-loader.entry.cjs.js.map +1 -0
- package/dist/cjs/scout-select.cjs.entry.js +60 -0
- package/dist/cjs/scout-select.entry.cjs.js.map +1 -0
- package/dist/cjs/scout-stack.cjs.entry.js +39 -0
- package/dist/cjs/scout-stack.entry.cjs.js.map +1 -0
- package/dist/cjs/scout-switch.cjs.entry.js +2 -2
- package/dist/cjs/ui-webc.cjs.js +3 -3
- package/dist/cjs/ui-webc.cjs.js.map +1 -1
- package/dist/collection/collection-manifest.json +8 -1
- package/dist/collection/components/bottom-bar/bottom-bar.js +1 -1
- package/dist/collection/components/bottom-bar-item/bottom-bar-item.js +46 -2
- package/dist/collection/components/bottom-bar-item/bottom-bar-item.js.map +1 -1
- package/dist/collection/components/button/button.css +19 -17
- package/dist/collection/components/button/button.js +76 -4
- package/dist/collection/components/button/button.js.map +1 -1
- package/dist/collection/components/card/card.js +1 -1
- package/dist/collection/components/checkbox/checkbox.js +1 -1
- package/dist/collection/components/divider/divider.css +5 -0
- package/dist/collection/components/divider/divider.js +20 -0
- package/dist/collection/components/divider/divider.js.map +1 -0
- package/dist/collection/components/field/field.js +1 -1
- package/dist/collection/components/input/input.js +2 -2
- package/dist/collection/components/link/link.css +30 -0
- package/dist/collection/components/link/link.js +207 -0
- package/dist/collection/components/link/link.js.map +1 -0
- package/dist/collection/components/list-view/list-view.css +5 -0
- package/dist/collection/components/list-view/list-view.js +22 -0
- package/dist/collection/components/list-view/list-view.js.map +1 -0
- package/dist/collection/components/list-view-item/list-view-item.css +72 -0
- package/dist/collection/components/list-view-item/list-view-item.js +226 -0
- package/dist/collection/components/list-view-item/list-view-item.js.map +1 -0
- package/dist/collection/components/loader/loader.css +121 -0
- package/dist/collection/components/loader/loader.js +111 -0
- package/dist/collection/components/loader/loader.js.map +1 -0
- package/dist/collection/components/loader/symbols/adventurer.svg +22 -0
- package/dist/collection/components/loader/symbols/challenger.svg +22 -0
- package/dist/collection/components/loader/symbols/discoverer.svg +22 -0
- package/dist/collection/components/loader/symbols/family-scout.svg +22 -0
- package/dist/collection/components/loader/symbols/rover.svg +22 -0
- package/dist/collection/components/loader/symbols/tracker.svg +22 -0
- package/dist/collection/components/select/select.css +60 -0
- package/dist/collection/components/select/select.js +176 -0
- package/dist/collection/components/select/select.js.map +1 -0
- package/dist/collection/components/stack/stack.css +6 -0
- package/dist/collection/components/stack/stack.js +96 -0
- package/dist/collection/components/stack/stack.js.map +1 -0
- package/dist/collection/components/switch/switch.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/{p-MfRr-Vl1.js → p-S6Ssep7K.js} +7 -9
- package/dist/components/p-S6Ssep7K.js.map +1 -0
- package/dist/components/scout-bottom-bar-item.js +11 -3
- package/dist/components/scout-bottom-bar-item.js.map +1 -1
- package/dist/components/scout-bottom-bar.js +2 -2
- package/dist/components/scout-button.js +22 -4
- package/dist/components/scout-button.js.map +1 -1
- package/dist/components/scout-card.js +2 -2
- package/dist/components/scout-checkbox.js +3 -3
- package/dist/components/scout-divider.d.ts +11 -0
- package/dist/components/scout-divider.js +39 -0
- package/dist/components/scout-divider.js.map +1 -0
- package/dist/components/scout-field.js +3 -3
- package/dist/components/scout-input.js +2 -2
- package/dist/components/scout-link.d.ts +11 -0
- package/dist/components/scout-link.js +91 -0
- package/dist/components/scout-link.js.map +1 -0
- package/dist/components/scout-list-view-item.d.ts +11 -0
- package/dist/components/scout-list-view-item.js +92 -0
- package/dist/components/scout-list-view-item.js.map +1 -0
- package/dist/components/scout-list-view.d.ts +11 -0
- package/dist/components/scout-list-view.js +41 -0
- package/dist/components/scout-list-view.js.map +1 -0
- package/dist/components/scout-loader.d.ts +11 -0
- package/dist/components/scout-loader.js +96 -0
- package/dist/components/scout-loader.js.map +1 -0
- package/dist/components/scout-select.d.ts +11 -0
- package/dist/components/scout-select.js +84 -0
- package/dist/components/scout-select.js.map +1 -0
- package/dist/components/scout-stack.d.ts +11 -0
- package/dist/components/scout-stack.js +62 -0
- package/dist/components/scout-stack.js.map +1 -0
- package/dist/components/scout-switch.js +3 -3
- package/dist/custom-elements.json +1016 -66
- package/dist/esm/{index-DByXnE9g.js → index-BI7oh__S.js} +7 -9
- package/dist/esm/index-BI7oh__S.js.map +1 -0
- package/dist/esm/loader.js +3 -3
- package/dist/esm/scout-bottom-bar-item.entry.js +8 -2
- package/dist/esm/scout-bottom-bar-item.entry.js.map +1 -1
- package/dist/esm/scout-bottom-bar.entry.js +2 -2
- package/dist/esm/scout-button.entry.js +18 -3
- package/dist/esm/scout-button.entry.js.map +1 -1
- package/dist/esm/scout-card.entry.js +2 -2
- package/dist/esm/scout-checkbox.entry.js +2 -2
- package/dist/esm/scout-divider.entry.js +17 -0
- package/dist/esm/scout-divider.entry.js.map +1 -0
- package/dist/esm/scout-field.entry.js +2 -2
- package/dist/esm/scout-input.entry.js +1 -1
- package/dist/esm/scout-link.entry.js +62 -0
- package/dist/esm/scout-link.entry.js.map +1 -0
- package/dist/esm/scout-list-view-item.entry.js +62 -0
- package/dist/esm/scout-list-view-item.entry.js.map +1 -0
- package/dist/esm/scout-list-view.entry.js +19 -0
- package/dist/esm/scout-list-view.entry.js.map +1 -0
- package/dist/esm/scout-loader.entry.js +71 -0
- package/dist/esm/scout-loader.entry.js.map +1 -0
- package/dist/esm/scout-select.entry.js +58 -0
- package/dist/esm/scout-select.entry.js.map +1 -0
- package/dist/esm/scout-stack.entry.js +37 -0
- package/dist/esm/scout-stack.entry.js.map +1 -0
- package/dist/esm/scout-switch.entry.js +2 -2
- package/dist/esm/ui-webc.js +4 -4
- package/dist/esm/ui-webc.js.map +1 -1
- package/dist/types/components/bottom-bar-item/bottom-bar-item.d.ts +2 -0
- package/dist/types/components/button/button.d.ts +4 -1
- package/dist/types/components/divider/divider.d.ts +3 -0
- package/dist/types/components/link/link.d.ts +39 -0
- package/dist/types/components/list-view/list-view.d.ts +3 -0
- package/dist/types/components/list-view-item/list-view-item.d.ts +16 -0
- package/dist/types/components/loader/loader.d.ts +15 -0
- package/dist/types/components/select/select.d.ts +31 -0
- package/dist/types/components/stack/stack.d.ts +22 -0
- package/dist/types/components.d.ts +295 -2
- package/dist/types/stencil-public-runtime.d.ts +20 -11
- package/dist/ui-webc/p-15634492.entry.js +2 -0
- package/dist/ui-webc/p-15634492.entry.js.map +1 -0
- package/dist/ui-webc/{p-383736c1.entry.js → p-316eed06.entry.js} +2 -2
- package/dist/ui-webc/p-4064b941.entry.js +2 -0
- package/dist/ui-webc/{p-24632b65.entry.js.map → p-4064b941.entry.js.map} +1 -1
- package/dist/ui-webc/p-5e2c0abc.entry.js +2 -0
- package/dist/ui-webc/p-5e2c0abc.entry.js.map +1 -0
- package/dist/ui-webc/{p-9b7c270d.entry.js → p-662554f2.entry.js} +2 -2
- package/dist/ui-webc/p-72e5904f.entry.js +2 -0
- package/dist/ui-webc/p-72e5904f.entry.js.map +1 -0
- package/dist/ui-webc/p-939fb179.entry.js +2 -0
- package/dist/ui-webc/p-939fb179.entry.js.map +1 -0
- package/dist/ui-webc/p-93c5edd1.entry.js +2 -0
- package/dist/ui-webc/p-93c5edd1.entry.js.map +1 -0
- package/dist/ui-webc/p-9c2bb8d7.entry.js +2 -0
- package/dist/ui-webc/p-9c2bb8d7.entry.js.map +1 -0
- package/dist/ui-webc/p-BI7oh__S.js +3 -0
- package/dist/ui-webc/p-BI7oh__S.js.map +1 -0
- package/dist/ui-webc/{p-7245a55a.entry.js → p-b24cd5e8.entry.js} +2 -2
- package/dist/ui-webc/p-b7e542b2.entry.js +2 -0
- package/dist/ui-webc/p-b7e542b2.entry.js.map +1 -0
- package/dist/ui-webc/p-d0b4b8c4.entry.js +2 -0
- package/dist/ui-webc/p-df4ec2af.entry.js +2 -0
- package/dist/ui-webc/p-df4ec2af.entry.js.map +1 -0
- package/dist/ui-webc/{p-2b434594.entry.js → p-eb235f73.entry.js} +2 -2
- package/dist/ui-webc/p-f164c4f7.entry.js +2 -0
- package/dist/ui-webc/p-f164c4f7.entry.js.map +1 -0
- package/dist/ui-webc/scout-bottom-bar-item.entry.esm.js.map +1 -1
- package/dist/ui-webc/scout-button.entry.esm.js.map +1 -1
- package/dist/ui-webc/scout-divider.entry.esm.js.map +1 -0
- package/dist/ui-webc/scout-link.entry.esm.js.map +1 -0
- package/dist/ui-webc/scout-list-view-item.entry.esm.js.map +1 -0
- package/dist/ui-webc/scout-list-view.entry.esm.js.map +1 -0
- package/dist/ui-webc/scout-loader.entry.esm.js.map +1 -0
- package/dist/ui-webc/scout-select.entry.esm.js.map +1 -0
- package/dist/ui-webc/scout-stack.entry.esm.js.map +1 -0
- package/dist/ui-webc/ui-webc.css +2 -2
- package/dist/ui-webc/ui-webc.esm.js +1 -1
- package/dist/ui-webc/ui-webc.esm.js.map +1 -1
- package/package.json +9 -9
- package/dist/cjs/index-D42maJcS.js.map +0 -1
- package/dist/components/p-MfRr-Vl1.js.map +0 -1
- package/dist/esm/index-DByXnE9g.js.map +0 -1
- package/dist/ui-webc/p-24632b65.entry.js +0 -2
- package/dist/ui-webc/p-99329c64.entry.js +0 -2
- package/dist/ui-webc/p-99329c64.entry.js.map +0 -1
- package/dist/ui-webc/p-DByXnE9g.js +0 -3
- package/dist/ui-webc/p-DByXnE9g.js.map +0 -1
- package/dist/ui-webc/p-c0c3a4af.entry.js +0 -2
- package/dist/ui-webc/p-e7602729.entry.js +0 -2
- package/dist/ui-webc/p-e7602729.entry.js.map +0 -1
- /package/dist/ui-webc/{p-383736c1.entry.js.map → p-316eed06.entry.js.map} +0 -0
- /package/dist/ui-webc/{p-9b7c270d.entry.js.map → p-662554f2.entry.js.map} +0 -0
- /package/dist/ui-webc/{p-7245a55a.entry.js.map → p-b24cd5e8.entry.js.map} +0 -0
- /package/dist/ui-webc/{p-c0c3a4af.entry.js.map → p-d0b4b8c4.entry.js.map} +0 -0
- /package/dist/ui-webc/{p-2b434594.entry.js.map → p-eb235f73.entry.js.map} +0 -0
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
display: inline-flex;
|
|
3
3
|
}
|
|
4
4
|
|
|
5
|
-
button {
|
|
5
|
+
.button {
|
|
6
6
|
display: inline-flex;
|
|
7
7
|
align-items: center;
|
|
8
8
|
justify-content: center;
|
|
@@ -13,6 +13,8 @@ button {
|
|
|
13
13
|
border-radius: var(--spacing-2);
|
|
14
14
|
border: 1px solid transparent;
|
|
15
15
|
cursor: pointer;
|
|
16
|
+
-webkit-text-decoration: none;
|
|
17
|
+
text-decoration: none;
|
|
16
18
|
}
|
|
17
19
|
|
|
18
20
|
.icon {
|
|
@@ -26,69 +28,69 @@ button {
|
|
|
26
28
|
height: 100%;
|
|
27
29
|
}
|
|
28
30
|
|
|
29
|
-
button.primary {
|
|
31
|
+
.button.primary {
|
|
30
32
|
background-color: var(--color-background-brand-base);
|
|
31
33
|
color: var(--color-text-brand-inverse);
|
|
32
34
|
}
|
|
33
35
|
|
|
34
|
-
button.primary:hover {
|
|
36
|
+
.button.primary:hover {
|
|
35
37
|
background-color: var(--color-background-brand-hovered);
|
|
36
38
|
}
|
|
37
39
|
|
|
38
|
-
button.primary:active {
|
|
40
|
+
.button.primary:active {
|
|
39
41
|
background-color: var(--color-background-brand-pressed);
|
|
40
42
|
}
|
|
41
43
|
|
|
42
|
-
button.outlined {
|
|
44
|
+
.button.outlined {
|
|
43
45
|
background-color: transparent;
|
|
44
46
|
border-color: var(--color-background-brand-subtle-base);
|
|
45
47
|
color: var(--color-text-brand-base);
|
|
46
48
|
}
|
|
47
49
|
|
|
48
|
-
button.outlined:hover {
|
|
50
|
+
.button.outlined:hover {
|
|
49
51
|
background-color: var(--color-background-brand-subtle-hovered);
|
|
50
52
|
}
|
|
51
53
|
|
|
52
|
-
button.outlined:active {
|
|
54
|
+
.button.outlined:active {
|
|
53
55
|
background-color: var(--color-background-brand-subtle-pressed);
|
|
54
56
|
}
|
|
55
57
|
|
|
56
|
-
button.text {
|
|
58
|
+
.button.text {
|
|
57
59
|
background-color: transparent;
|
|
58
60
|
border-color: transparent;
|
|
59
61
|
color: var(--color-text-brand-base);
|
|
60
62
|
}
|
|
61
63
|
|
|
62
|
-
button.text:hover {
|
|
64
|
+
.button.text:hover {
|
|
63
65
|
background-color: var(--color-background-brand-subtle-hovered);
|
|
64
66
|
}
|
|
65
67
|
|
|
66
|
-
button.text:active {
|
|
68
|
+
.button.text:active {
|
|
67
69
|
background-color: var(--color-background-brand-subtle-pressed);
|
|
68
70
|
}
|
|
69
71
|
|
|
70
|
-
button.caution {
|
|
72
|
+
.button.caution {
|
|
71
73
|
background-color: var(--color-background-caution-bold-base);
|
|
72
74
|
color: var(--color-text-caution-bold-base);
|
|
73
75
|
}
|
|
74
76
|
|
|
75
|
-
button.caution:hover {
|
|
77
|
+
.button.caution:hover {
|
|
76
78
|
background-color: var(--color-background-caution-bold-hovered);
|
|
77
79
|
}
|
|
78
80
|
|
|
79
|
-
button.caution:active {
|
|
81
|
+
.button.caution:active {
|
|
80
82
|
background-color: var(--color-background-caution-bold-pressed);
|
|
81
83
|
}
|
|
82
84
|
|
|
83
|
-
button.danger {
|
|
85
|
+
.button.danger {
|
|
84
86
|
background-color: var(--color-background-danger-bold-base);
|
|
85
87
|
color: var(--color-text-danger-bold-base);
|
|
86
88
|
}
|
|
87
89
|
|
|
88
|
-
button.danger:hover {
|
|
90
|
+
.button.danger:hover {
|
|
89
91
|
background-color: var(--color-background-danger-bold-hovered);
|
|
90
92
|
}
|
|
91
93
|
|
|
92
|
-
button.danger:active {
|
|
94
|
+
.button.danger:active {
|
|
93
95
|
background-color: var(--color-background-danger-bold-pressed);
|
|
94
|
-
}
|
|
96
|
+
}
|
|
@@ -4,6 +4,9 @@ import { h } from "@stencil/core";
|
|
|
4
4
|
*/
|
|
5
5
|
export class ScoutButton {
|
|
6
6
|
type = "button";
|
|
7
|
+
href;
|
|
8
|
+
target;
|
|
9
|
+
rel;
|
|
7
10
|
/**
|
|
8
11
|
* The variant primarily affects the color of the button.
|
|
9
12
|
*/
|
|
@@ -14,7 +17,19 @@ export class ScoutButton {
|
|
|
14
17
|
icon;
|
|
15
18
|
scoutClick;
|
|
16
19
|
render() {
|
|
17
|
-
|
|
20
|
+
const Tag = this.type === "link" ? "a" : "button";
|
|
21
|
+
const props = this.type === "link"
|
|
22
|
+
? {
|
|
23
|
+
href: this.href,
|
|
24
|
+
target: this.target,
|
|
25
|
+
// This might not be our job, but better safe than sorry.
|
|
26
|
+
rel: this.rel ??
|
|
27
|
+
(this.target === "_blank" ? "noopener noreferrer" : undefined),
|
|
28
|
+
}
|
|
29
|
+
: {
|
|
30
|
+
type: this.type,
|
|
31
|
+
};
|
|
32
|
+
return (h(Tag, { key: 'fc7b2867c649782e166b7a363c5e3b43955a8011', class: `button ${this.variant}`, onClick: () => this.scoutClick.emit(), ...props }, h("slot", { key: '60d6e548ddf0da4bca40f1daea0fb656da8fb733' }), this.icon && h("span", { key: 'aef054b5de8cc20f5f26a9e2e82b76f43a9d3f32', class: "icon", innerHTML: this.icon })));
|
|
18
33
|
}
|
|
19
34
|
static get is() { return "scout-button"; }
|
|
20
35
|
static get encapsulation() { return "shadow"; }
|
|
@@ -35,8 +50,8 @@ export class ScoutButton {
|
|
|
35
50
|
"type": "string",
|
|
36
51
|
"mutable": false,
|
|
37
52
|
"complexType": {
|
|
38
|
-
"original": "\"button\" | \"submit\" | \"reset\"",
|
|
39
|
-
"resolved": "\"button\" | \"reset\" | \"submit\"",
|
|
53
|
+
"original": "\"button\" | \"submit\" | \"reset\" | \"link\"",
|
|
54
|
+
"resolved": "\"button\" | \"link\" | \"reset\" | \"submit\"",
|
|
40
55
|
"references": {}
|
|
41
56
|
},
|
|
42
57
|
"required": false,
|
|
@@ -51,6 +66,63 @@ export class ScoutButton {
|
|
|
51
66
|
"attribute": "type",
|
|
52
67
|
"defaultValue": "\"button\""
|
|
53
68
|
},
|
|
69
|
+
"href": {
|
|
70
|
+
"type": "string",
|
|
71
|
+
"mutable": false,
|
|
72
|
+
"complexType": {
|
|
73
|
+
"original": "string",
|
|
74
|
+
"resolved": "string",
|
|
75
|
+
"references": {}
|
|
76
|
+
},
|
|
77
|
+
"required": false,
|
|
78
|
+
"optional": true,
|
|
79
|
+
"docs": {
|
|
80
|
+
"tags": [],
|
|
81
|
+
"text": ""
|
|
82
|
+
},
|
|
83
|
+
"getter": false,
|
|
84
|
+
"setter": false,
|
|
85
|
+
"reflect": false,
|
|
86
|
+
"attribute": "href"
|
|
87
|
+
},
|
|
88
|
+
"target": {
|
|
89
|
+
"type": "string",
|
|
90
|
+
"mutable": false,
|
|
91
|
+
"complexType": {
|
|
92
|
+
"original": "string",
|
|
93
|
+
"resolved": "string",
|
|
94
|
+
"references": {}
|
|
95
|
+
},
|
|
96
|
+
"required": false,
|
|
97
|
+
"optional": true,
|
|
98
|
+
"docs": {
|
|
99
|
+
"tags": [],
|
|
100
|
+
"text": ""
|
|
101
|
+
},
|
|
102
|
+
"getter": false,
|
|
103
|
+
"setter": false,
|
|
104
|
+
"reflect": false,
|
|
105
|
+
"attribute": "target"
|
|
106
|
+
},
|
|
107
|
+
"rel": {
|
|
108
|
+
"type": "string",
|
|
109
|
+
"mutable": false,
|
|
110
|
+
"complexType": {
|
|
111
|
+
"original": "string",
|
|
112
|
+
"resolved": "string",
|
|
113
|
+
"references": {}
|
|
114
|
+
},
|
|
115
|
+
"required": false,
|
|
116
|
+
"optional": true,
|
|
117
|
+
"docs": {
|
|
118
|
+
"tags": [],
|
|
119
|
+
"text": ""
|
|
120
|
+
},
|
|
121
|
+
"getter": false,
|
|
122
|
+
"setter": false,
|
|
123
|
+
"reflect": false,
|
|
124
|
+
"attribute": "rel"
|
|
125
|
+
},
|
|
54
126
|
"variant": {
|
|
55
127
|
"type": "string",
|
|
56
128
|
"mutable": false,
|
|
@@ -60,7 +132,7 @@ export class ScoutButton {
|
|
|
60
132
|
"references": {
|
|
61
133
|
"Variant": {
|
|
62
134
|
"location": "local",
|
|
63
|
-
"path": "/home/runner/work/j26-
|
|
135
|
+
"path": "/home/runner/work/j26-components/j26-components/packages/ui-webc/src/components/button/button.tsx",
|
|
64
136
|
"id": "src/components/button/button.tsx::Variant"
|
|
65
137
|
}
|
|
66
138
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../../src/components/button/button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAqB,CAAC,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAI7E;;GAEG;AAQH,MAAM,OAAO,WAAW;IACd,IAAI,
|
|
1
|
+
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../../src/components/button/button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAqB,CAAC,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAI7E;;GAEG;AAQH,MAAM,OAAO,WAAW;IACd,IAAI,GAA2C,QAAQ,CAAC;IAExD,IAAI,CAAU;IACd,MAAM,CAAU;IAChB,GAAG,CAAU;IAErB;;OAEG;IACK,OAAO,GAAY,UAAU,CAAC;IAEtC;;OAEG;IACK,IAAI,CAAU;IAEb,UAAU,CAAqB;IAExC,MAAM;QACJ,MAAM,GAAG,GAAG,IAAI,CAAC,IAAI,KAAK,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,QAAQ,CAAC;QAElD,MAAM,KAAK,GACT,IAAI,CAAC,IAAI,KAAK,MAAM;YAClB,CAAC,CAAC;gBACE,IAAI,EAAE,IAAI,CAAC,IAAI;gBACf,MAAM,EAAE,IAAI,CAAC,MAAM;gBACnB,yDAAyD;gBACzD,GAAG,EACD,IAAI,CAAC,GAAG;oBACR,CAAC,IAAI,CAAC,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,qBAAqB,CAAC,CAAC,CAAC,SAAS,CAAC;aACjE;YACH,CAAC,CAAC;gBACE,IAAI,EAAE,IAAI,CAAC,IAAI;aAChB,CAAC;QAER,OAAO,CACL,EAAC,GAAG,qDACF,KAAK,EAAE,UAAU,IAAI,CAAC,OAAO,EAAE,EAC/B,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE,KACjC,KAAK;YAET,8DAAQ;YACP,IAAI,CAAC,IAAI,IAAI,6DAAM,KAAK,EAAC,MAAM,EAAC,SAAS,EAAE,IAAI,CAAC,IAAI,GAAI,CACrD,CACP,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Event, type EventEmitter, h, Prop } from \"@stencil/core\";\n\nexport type Variant = \"primary\" | \"outlined\" | \"text\" | \"caution\" | \"danger\";\n\n/**\n * A simple button component.\n */\n@Component({\n tag: \"scout-button\",\n styleUrl: \"button.css\",\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class ScoutButton {\n @Prop() type: \"button\" | \"submit\" | \"reset\" | \"link\" = \"button\";\n\n @Prop() href?: string;\n @Prop() target?: string;\n @Prop() rel?: string;\n\n /**\n * The variant primarily affects the color of the button.\n */\n @Prop() variant: Variant = \"outlined\";\n\n /**\n * An optional icon to display alongside the button text. Must be an SVG string.\n */\n @Prop() icon?: string;\n\n @Event() scoutClick: EventEmitter<void>;\n\n render() {\n const Tag = this.type === \"link\" ? \"a\" : \"button\";\n\n const props =\n this.type === \"link\"\n ? {\n href: this.href,\n target: this.target,\n // This might not be our job, but better safe than sorry.\n rel:\n this.rel ??\n (this.target === \"_blank\" ? \"noopener noreferrer\" : undefined),\n }\n : {\n type: this.type,\n };\n\n return (\n <Tag\n class={`button ${this.variant}`}\n onClick={() => this.scoutClick.emit()}\n {...props}\n >\n <slot />\n {this.icon && <span class=\"icon\" innerHTML={this.icon} />}\n </Tag>\n );\n }\n}\n"]}
|
|
@@ -4,7 +4,7 @@ import { h } from "@stencil/core";
|
|
|
4
4
|
*/
|
|
5
5
|
export class ScoutCard {
|
|
6
6
|
render() {
|
|
7
|
-
return h("slot", { key: '
|
|
7
|
+
return h("slot", { key: '44e84e98fac4b83c20fdec40a532c752f41dffd7' });
|
|
8
8
|
}
|
|
9
9
|
static get is() { return "scout-card"; }
|
|
10
10
|
static get encapsulation() { return "shadow"; }
|
|
@@ -33,7 +33,7 @@ export class ScoutCheckbox {
|
|
|
33
33
|
*/
|
|
34
34
|
render() {
|
|
35
35
|
const Tag = this.label && this.label.length ? "label" : "div";
|
|
36
|
-
return (h(Tag, { key: '
|
|
36
|
+
return (h(Tag, { key: '39d7814c3af4261c7b60423464d5b3167ad96003' }, this.label, h("span", { key: '10375644d673913047c66460c2c0395f0110b644', class: "inlineDivider" }), h("input", { key: '3e5c5fa2571874e75325a7a3161a15e00332cd36', class: "checkbox", onChange: (event) => this.onClick(event), style: { "--icon-checkbox": `url(${checkIcon})` }, type: "checkbox", id: this.ariaId, "aria-labelledby": this.ariaLabelledby, "aria-disabled": this.disabled, disabled: this.disabled, checked: this.checked })));
|
|
37
37
|
}
|
|
38
38
|
static get is() { return "scout-checkbox"; }
|
|
39
39
|
static get encapsulation() { return "scoped"; }
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
|
2
|
+
export class ScoutDivider {
|
|
3
|
+
render() {
|
|
4
|
+
return h(Host, { key: '78c9366fcd393e53b579481d31feafa643b63690' });
|
|
5
|
+
}
|
|
6
|
+
static get is() { return "scout-divider"; }
|
|
7
|
+
static get encapsulation() { return "shadow"; }
|
|
8
|
+
static get delegatesFocus() { return true; }
|
|
9
|
+
static get originalStyleUrls() {
|
|
10
|
+
return {
|
|
11
|
+
"$": ["divider.css"]
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
static get styleUrls() {
|
|
15
|
+
return {
|
|
16
|
+
"$": ["divider.css"]
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=divider.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"divider.js","sourceRoot":"","sources":["../../../src/components/divider/divider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AASnD,MAAM,OAAO,YAAY;IACvB,MAAM;QACJ,OAAO,EAAC,IAAI,sDAAG,CAAC;IAClB,CAAC;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, h } from \"@stencil/core\";\n\n@Component({\n tag: \"scout-divider\",\n styleUrl: \"divider.css\",\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class ScoutDivider {\n render() {\n return <Host />;\n }\n}\n"]}
|
|
@@ -30,7 +30,7 @@ export class ScoutField {
|
|
|
30
30
|
this.errorHidden = false;
|
|
31
31
|
}
|
|
32
32
|
render() {
|
|
33
|
-
return (h("div", { key: '
|
|
33
|
+
return (h("div", { key: 'e38499f35a268b15962a31a2dc45361fb803a8e3', class: "field" }, h("label", { key: '3e6ba58b91285a082964bd01336fd4c7d8260835', htmlFor: this.inputId, class: "label" }, this.label), h("slot", { key: '75de87617caef28b9d90d0e112870a5cf2b08bfc' }), h("p", { key: 'f152609ade3a840a4bfd6bfef5f5aadf8060fab2', class: "error-text", "aria-live": "polite" }, !this.errorHidden && this.errorText), this.helpText && h("p", { key: '86069ef5f19840e44e79a274152742070b51e7a8', class: "help-text" }, this.helpText)));
|
|
34
34
|
}
|
|
35
35
|
static get is() { return "scout-field"; }
|
|
36
36
|
static get encapsulation() { return "scoped"; }
|
|
@@ -77,7 +77,7 @@ export class ScoutInput {
|
|
|
77
77
|
"references": {
|
|
78
78
|
"InputType": {
|
|
79
79
|
"location": "local",
|
|
80
|
-
"path": "/home/runner/work/j26-
|
|
80
|
+
"path": "/home/runner/work/j26-components/j26-components/packages/ui-webc/src/components/input/input.tsx",
|
|
81
81
|
"id": "src/components/input/input.tsx::InputType"
|
|
82
82
|
}
|
|
83
83
|
}
|
|
@@ -103,7 +103,7 @@ export class ScoutInput {
|
|
|
103
103
|
"references": {
|
|
104
104
|
"InputMode": {
|
|
105
105
|
"location": "local",
|
|
106
|
-
"path": "/home/runner/work/j26-
|
|
106
|
+
"path": "/home/runner/work/j26-components/j26-components/packages/ui-webc/src/components/input/input.tsx",
|
|
107
107
|
"id": "src/components/input/input.tsx::InputMode"
|
|
108
108
|
}
|
|
109
109
|
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
:host {
|
|
2
|
+
display: inline;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
a,
|
|
6
|
+
button {
|
|
7
|
+
color: var(--color-text-brand-base);
|
|
8
|
+
-webkit-text-decoration: none;
|
|
9
|
+
text-decoration: none;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
a:hover,
|
|
13
|
+
button:hover {
|
|
14
|
+
-webkit-text-decoration: underline;
|
|
15
|
+
text-decoration: underline;
|
|
16
|
+
color: var(--color-background-brand-hover);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
a:active,
|
|
20
|
+
button:active {
|
|
21
|
+
color: var(--color-background-brand-pressed);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
button {
|
|
25
|
+
display: inline;
|
|
26
|
+
background: none;
|
|
27
|
+
border: none;
|
|
28
|
+
padding: 0;
|
|
29
|
+
cursor: pointer;
|
|
30
|
+
}
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
import { h } from "@stencil/core";
|
|
2
|
+
export class ScoutLink {
|
|
3
|
+
/**
|
|
4
|
+
* The URL that the link points to. Required when type is set to link
|
|
5
|
+
*/
|
|
6
|
+
href;
|
|
7
|
+
/**
|
|
8
|
+
* Text to be displayed for the link
|
|
9
|
+
*/
|
|
10
|
+
label;
|
|
11
|
+
rel;
|
|
12
|
+
/**
|
|
13
|
+
* If the label property is not sufficient to describe its use, add an aria-label describing what happens
|
|
14
|
+
* when pressing the button or where the user navigates if it is a link.
|
|
15
|
+
*/
|
|
16
|
+
linkAriaLabel;
|
|
17
|
+
/**
|
|
18
|
+
* There are two types. If you intend to use it as a button with onclick, a button is rendered, however if you want to you it
|
|
19
|
+
* as a normal link, a link with href is rendered.
|
|
20
|
+
*/
|
|
21
|
+
type = "link";
|
|
22
|
+
/**
|
|
23
|
+
* _blank Opens the linked document in a new window or tab
|
|
24
|
+
*
|
|
25
|
+
* _self Opens the linked document in the same frame as it was clicked (this is default)
|
|
26
|
+
*
|
|
27
|
+
* _parent Opens the linked document in the parent frame
|
|
28
|
+
*
|
|
29
|
+
* _top Opens the linked document in the full body of the window
|
|
30
|
+
*
|
|
31
|
+
* _framename Opens the linked document in the named iframe
|
|
32
|
+
*/
|
|
33
|
+
target = "_self";
|
|
34
|
+
/**
|
|
35
|
+
* Only sent if the link is a button.
|
|
36
|
+
*/
|
|
37
|
+
scoutLinkClick;
|
|
38
|
+
render() {
|
|
39
|
+
if (this.type === "button") {
|
|
40
|
+
return (h("button", { type: "button", "aria-label": this.linkAriaLabel || "", onClick: () => this.scoutLinkClick.emit() }, this.label));
|
|
41
|
+
}
|
|
42
|
+
if (!this.href) {
|
|
43
|
+
throw new Error("Href is requied when type is set to link");
|
|
44
|
+
}
|
|
45
|
+
return (h("a", { href: this.href, target: this.target, "aria-label": this.linkAriaLabel || "", rel:
|
|
46
|
+
// This might not be our job, but better safe than sorry.
|
|
47
|
+
this.rel ??
|
|
48
|
+
(this.target === "_blank" ? "noopener noreferrer" : undefined) }, this.label));
|
|
49
|
+
}
|
|
50
|
+
static get is() { return "scout-link"; }
|
|
51
|
+
static get encapsulation() { return "shadow"; }
|
|
52
|
+
static get delegatesFocus() { return true; }
|
|
53
|
+
static get originalStyleUrls() {
|
|
54
|
+
return {
|
|
55
|
+
"$": ["link.css"]
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
static get styleUrls() {
|
|
59
|
+
return {
|
|
60
|
+
"$": ["link.css"]
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
static get properties() {
|
|
64
|
+
return {
|
|
65
|
+
"href": {
|
|
66
|
+
"type": "string",
|
|
67
|
+
"mutable": false,
|
|
68
|
+
"complexType": {
|
|
69
|
+
"original": "string",
|
|
70
|
+
"resolved": "string",
|
|
71
|
+
"references": {}
|
|
72
|
+
},
|
|
73
|
+
"required": false,
|
|
74
|
+
"optional": true,
|
|
75
|
+
"docs": {
|
|
76
|
+
"tags": [],
|
|
77
|
+
"text": "The URL that the link points to. Required when type is set to link"
|
|
78
|
+
},
|
|
79
|
+
"getter": false,
|
|
80
|
+
"setter": false,
|
|
81
|
+
"reflect": false,
|
|
82
|
+
"attribute": "href"
|
|
83
|
+
},
|
|
84
|
+
"label": {
|
|
85
|
+
"type": "string",
|
|
86
|
+
"mutable": false,
|
|
87
|
+
"complexType": {
|
|
88
|
+
"original": "string",
|
|
89
|
+
"resolved": "string",
|
|
90
|
+
"references": {}
|
|
91
|
+
},
|
|
92
|
+
"required": false,
|
|
93
|
+
"optional": false,
|
|
94
|
+
"docs": {
|
|
95
|
+
"tags": [],
|
|
96
|
+
"text": "Text to be displayed for the link"
|
|
97
|
+
},
|
|
98
|
+
"getter": false,
|
|
99
|
+
"setter": false,
|
|
100
|
+
"reflect": false,
|
|
101
|
+
"attribute": "label"
|
|
102
|
+
},
|
|
103
|
+
"rel": {
|
|
104
|
+
"type": "string",
|
|
105
|
+
"mutable": false,
|
|
106
|
+
"complexType": {
|
|
107
|
+
"original": "string",
|
|
108
|
+
"resolved": "string",
|
|
109
|
+
"references": {}
|
|
110
|
+
},
|
|
111
|
+
"required": false,
|
|
112
|
+
"optional": true,
|
|
113
|
+
"docs": {
|
|
114
|
+
"tags": [],
|
|
115
|
+
"text": ""
|
|
116
|
+
},
|
|
117
|
+
"getter": false,
|
|
118
|
+
"setter": false,
|
|
119
|
+
"reflect": false,
|
|
120
|
+
"attribute": "rel"
|
|
121
|
+
},
|
|
122
|
+
"linkAriaLabel": {
|
|
123
|
+
"type": "string",
|
|
124
|
+
"mutable": false,
|
|
125
|
+
"complexType": {
|
|
126
|
+
"original": "string",
|
|
127
|
+
"resolved": "string",
|
|
128
|
+
"references": {}
|
|
129
|
+
},
|
|
130
|
+
"required": false,
|
|
131
|
+
"optional": true,
|
|
132
|
+
"docs": {
|
|
133
|
+
"tags": [],
|
|
134
|
+
"text": "If the label property is not sufficient to describe its use, add an aria-label describing what happens\nwhen pressing the button or where the user navigates if it is a link."
|
|
135
|
+
},
|
|
136
|
+
"getter": false,
|
|
137
|
+
"setter": false,
|
|
138
|
+
"reflect": false,
|
|
139
|
+
"attribute": "link-aria-label"
|
|
140
|
+
},
|
|
141
|
+
"type": {
|
|
142
|
+
"type": "string",
|
|
143
|
+
"mutable": false,
|
|
144
|
+
"complexType": {
|
|
145
|
+
"original": "\"link\" | \"button\"",
|
|
146
|
+
"resolved": "\"button\" | \"link\"",
|
|
147
|
+
"references": {}
|
|
148
|
+
},
|
|
149
|
+
"required": false,
|
|
150
|
+
"optional": false,
|
|
151
|
+
"docs": {
|
|
152
|
+
"tags": [],
|
|
153
|
+
"text": "There are two types. If you intend to use it as a button with onclick, a button is rendered, however if you want to you it\nas a normal link, a link with href is rendered."
|
|
154
|
+
},
|
|
155
|
+
"getter": false,
|
|
156
|
+
"setter": false,
|
|
157
|
+
"reflect": false,
|
|
158
|
+
"attribute": "type",
|
|
159
|
+
"defaultValue": "\"link\""
|
|
160
|
+
},
|
|
161
|
+
"target": {
|
|
162
|
+
"type": "string",
|
|
163
|
+
"mutable": false,
|
|
164
|
+
"complexType": {
|
|
165
|
+
"original": "\"_blank\" | \"_self\" | \"_parent\" | \"_top\" | \"framename\"",
|
|
166
|
+
"resolved": "\"_blank\" | \"_parent\" | \"_self\" | \"_top\" | \"framename\"",
|
|
167
|
+
"references": {}
|
|
168
|
+
},
|
|
169
|
+
"required": false,
|
|
170
|
+
"optional": true,
|
|
171
|
+
"docs": {
|
|
172
|
+
"tags": [],
|
|
173
|
+
"text": "_blank\tOpens the linked document in a new window or tab\n\n_self\tOpens the linked document in the same frame as it was clicked (this is default)\n\n_parent\tOpens the linked document in the parent frame\n\n_top\tOpens the linked document in the full body of the window\n\n_framename\tOpens the linked document in the named iframe"
|
|
174
|
+
},
|
|
175
|
+
"getter": false,
|
|
176
|
+
"setter": false,
|
|
177
|
+
"reflect": false,
|
|
178
|
+
"attribute": "target",
|
|
179
|
+
"defaultValue": "\"_self\""
|
|
180
|
+
}
|
|
181
|
+
};
|
|
182
|
+
}
|
|
183
|
+
static get events() {
|
|
184
|
+
return [{
|
|
185
|
+
"method": "scoutLinkClick",
|
|
186
|
+
"name": "scoutLinkClick",
|
|
187
|
+
"bubbles": true,
|
|
188
|
+
"cancelable": true,
|
|
189
|
+
"composed": true,
|
|
190
|
+
"docs": {
|
|
191
|
+
"tags": [],
|
|
192
|
+
"text": "Only sent if the link is a button."
|
|
193
|
+
},
|
|
194
|
+
"complexType": {
|
|
195
|
+
"original": "HTMLButtonElement",
|
|
196
|
+
"resolved": "HTMLButtonElement",
|
|
197
|
+
"references": {
|
|
198
|
+
"HTMLButtonElement": {
|
|
199
|
+
"location": "global",
|
|
200
|
+
"id": "global::HTMLButtonElement"
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
}];
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
//# sourceMappingURL=link.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"link.js","sourceRoot":"","sources":["../../../src/components/link/link.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAqB,CAAC,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAS7E,MAAM,OAAO,SAAS;IACpB;;OAEG;IACK,IAAI,CAAU;IAEtB;;OAEG;IACK,KAAK,CAAS;IAEd,GAAG,CAAU;IAErB;;;OAGG;IACK,aAAa,CAAU;IAE/B;;;OAGG;IACK,IAAI,GAAsB,MAAM,CAAC;IAEzC;;;;;;;;;;OAUG;IACK,MAAM,GACZ,OAAO,CAAC;IAEV;;OAEG;IACM,cAAc,CAAkC;IAEzD,MAAM;QACJ,IAAI,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAE,CAAC;YAC3B,OAAO,CACL,cACE,IAAI,EAAC,QAAQ,gBACD,IAAI,CAAC,aAAa,IAAI,EAAE,EACpC,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,cAAc,CAAC,IAAI,EAAE,IAExC,IAAI,CAAC,KAAK,CACJ,CACV,CAAC;QACJ,CAAC;QAED,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC;YACf,MAAM,IAAI,KAAK,CAAC,0CAA0C,CAAC,CAAC;QAC9D,CAAC;QAED,OAAO,CACL,SACE,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,MAAM,EAAE,IAAI,CAAC,MAAM,gBACP,IAAI,CAAC,aAAa,IAAI,EAAE,EACpC,GAAG;YACD,yDAAyD;YACzD,IAAI,CAAC,GAAG;gBACR,CAAC,IAAI,CAAC,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,qBAAqB,CAAC,CAAC,CAAC,SAAS,CAAC,IAG/D,IAAI,CAAC,KAAK,CACT,CACL,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Event, type EventEmitter, h, Prop } from \"@stencil/core\";\n\n@Component({\n tag: \"scout-link\",\n styleUrl: \"link.css\",\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class ScoutLink {\n /**\n * The URL that the link points to. Required when type is set to link\n */\n @Prop() href?: string;\n\n /**\n * Text to be displayed for the link\n */\n @Prop() label: string;\n\n @Prop() rel?: string;\n\n /**\n * If the label property is not sufficient to describe its use, add an aria-label describing what happens\n * when pressing the button or where the user navigates if it is a link.\n */\n @Prop() linkAriaLabel?: string;\n\n /**\n * There are two types. If you intend to use it as a button with onclick, a button is rendered, however if you want to you it\n * as a normal link, a link with href is rendered.\n */\n @Prop() type: \"link\" | \"button\" = \"link\";\n\n /**\n * _blank\tOpens the linked document in a new window or tab\n *\n * _self\tOpens the linked document in the same frame as it was clicked (this is default)\n *\n * _parent\tOpens the linked document in the parent frame\n *\n * _top\tOpens the linked document in the full body of the window\n *\n * _framename\tOpens the linked document in the named iframe\n */\n @Prop() target?: \"_blank\" | \"_self\" | \"_parent\" | \"_top\" | \"framename\" =\n \"_self\";\n\n /**\n * Only sent if the link is a button.\n */\n @Event() scoutLinkClick: EventEmitter<HTMLButtonElement>;\n\n render() {\n if (this.type === \"button\") {\n return (\n <button\n type=\"button\"\n aria-label={this.linkAriaLabel || \"\"}\n onClick={() => this.scoutLinkClick.emit()}\n >\n {this.label}\n </button>\n );\n }\n\n if (!this.href) {\n throw new Error(\"Href is requied when type is set to link\");\n }\n\n return (\n <a\n href={this.href}\n target={this.target}\n aria-label={this.linkAriaLabel || \"\"}\n rel={\n // This might not be our job, but better safe than sorry.\n this.rel ??\n (this.target === \"_blank\" ? \"noopener noreferrer\" : undefined)\n }\n >\n {this.label}\n </a>\n );\n }\n}\n"]}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
|
2
|
+
export class ScoutListView {
|
|
3
|
+
render() {
|
|
4
|
+
return (
|
|
5
|
+
// biome-ignore lint/a11y/useSemanticElements: We can't use <ul> because we're using shadow DOM.
|
|
6
|
+
h(Host, { key: '162a45f1de284bc6f737769753837c29ca51155a', role: "list" }, h("slot", { key: '6a66f07a8082b94330dc33a183a7a915139d1e39' })));
|
|
7
|
+
}
|
|
8
|
+
static get is() { return "scout-list-view"; }
|
|
9
|
+
static get encapsulation() { return "shadow"; }
|
|
10
|
+
static get delegatesFocus() { return true; }
|
|
11
|
+
static get originalStyleUrls() {
|
|
12
|
+
return {
|
|
13
|
+
"$": ["list-view.css"]
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
static get styleUrls() {
|
|
17
|
+
return {
|
|
18
|
+
"$": ["list-view.css"]
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
//# sourceMappingURL=list-view.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-view.js","sourceRoot":"","sources":["../../../src/components/list-view/list-view.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AASnD,MAAM,OAAO,aAAa;IACxB,MAAM;QACJ,OAAO;QACL,gGAAgG;QAChG,EAAC,IAAI,qDAAC,IAAI,EAAC,MAAM;YACf,8DAAQ,CACH,CACR,CAAC;IACJ,CAAC;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, h } from \"@stencil/core\";\n\n@Component({\n tag: \"scout-list-view\",\n styleUrl: \"list-view.css\",\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class ScoutListView {\n render() {\n return (\n // biome-ignore lint/a11y/useSemanticElements: We can't use <ul> because we're using shadow DOM.\n <Host role=\"list\">\n <slot />\n </Host>\n );\n }\n}\n"]}
|