@salesforcedevs/dx-components 0.79.2-alpha.0 → 0.79.3
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/lwc.config.json +4 -1
- package/package.json +2 -2
- package/src/modules/dx/cardDocs/cardDocs.html +1 -0
- package/src/modules/dx/cardEvent/cardEvent.html +1 -2
- package/src/modules/dx/cardEvent/cardEvent.ts +1 -1
- package/src/modules/dx/cardExpanded/cardExpanded.html +1 -6
- package/src/modules/dx/cardExpanded/cardExpanded.ts +2 -2
- package/src/modules/dx/cardMinimal/cardMinimal.html +1 -6
- package/src/modules/dx/metadataBadge/metadataBadge.css +49 -0
- package/src/modules/dx/metadataBadge/metadataBadge.html +5 -0
- package/src/modules/dx/metadataBadge/metadataBadge.ts +24 -0
- package/src/modules/dx/tooltip/microtip.css +105 -101
- package/src/modules/dx/treeTile/treeTile.css +17 -17
- package/src/modules/dx/treeTile/treeTile.html +4 -3
- package/src/modules/dx/treeTile/treeTile.ts +16 -3
- package/src/modules/dx/typeBadge/typeBadge.css +15 -56
- package/src/modules/dx/typeBadge/typeBadge.html +6 -0
- package/src/modules/dx/typeBadge/typeBadge.ts +142 -46
- package/src/modules/dxBaseElements/archiveCard/archiveCard.ts +2 -6
- package/src/modules/dxConstants/brands/brands.ts +14 -0
- package/src/modules/dxConstants/colors/colors.ts +14 -0
- package/src/modules/dxConstants/contentTypes/contentTypes.ts +10 -0
- package/src/modules/dxUtils/css/css.ts +10 -0
- package/src/modules/dx/typeBadgeGroup/typeBadgeGroup.css +0 -12
- package/src/modules/dx/typeBadgeGroup/typeBadgeGroup.html +0 -11
- package/src/modules/dx/typeBadgeGroup/typeBadgeGroup.ts +0 -18
package/lwc.config.json
CHANGED
|
@@ -46,6 +46,7 @@
|
|
|
46
46
|
"dx/imageAndLabel",
|
|
47
47
|
"dx/input",
|
|
48
48
|
"dx/logo",
|
|
49
|
+
"dx/metadataBadge",
|
|
49
50
|
"dx/modalDrawer",
|
|
50
51
|
"dx/pagination",
|
|
51
52
|
"dx/podcastHost",
|
|
@@ -68,10 +69,12 @@
|
|
|
68
69
|
"dx/tooltip",
|
|
69
70
|
"dx/tree",
|
|
70
71
|
"dx/typeBadge",
|
|
71
|
-
"dx/typeBadgeGroup",
|
|
72
72
|
"dx/vimeoPlayer",
|
|
73
73
|
"dxBaseElements/headerBase",
|
|
74
74
|
"dxBaseElements/matchMediaElement",
|
|
75
|
+
"dxConstants/brands",
|
|
76
|
+
"dxConstants/colors",
|
|
77
|
+
"dxConstants/contentTypes",
|
|
75
78
|
"dxHelpers/animations",
|
|
76
79
|
"dxHelpers/button",
|
|
77
80
|
"dxHelpers/card",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforcedevs/dx-components",
|
|
3
|
-
"version": "0.79.
|
|
3
|
+
"version": "0.79.3",
|
|
4
4
|
"description": "DX Lightning web components",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"engines": {
|
|
@@ -28,5 +28,5 @@
|
|
|
28
28
|
"@types/lodash.kebabcase": "^4.1.7",
|
|
29
29
|
"@types/vimeo__player": "^2.16.2"
|
|
30
30
|
},
|
|
31
|
-
"gitHead": "
|
|
31
|
+
"gitHead": "1ac28eaeb46528d77fbaabad4471b9e87e39d08e"
|
|
32
32
|
}
|
|
@@ -1,11 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class={containerClass}>
|
|
3
|
-
<dx-type-badge
|
|
4
|
-
color={badgeColor}
|
|
5
|
-
type="content-type"
|
|
6
|
-
value={contentType}
|
|
7
|
-
size={badgeSize}
|
|
8
|
-
></dx-type-badge>
|
|
3
|
+
<dx-type-badge variant={contentType} size={badgeSize}></dx-type-badge>
|
|
9
4
|
<dx-card-title
|
|
10
5
|
if:true={title}
|
|
11
6
|
href={href}
|
|
@@ -10,8 +10,8 @@ export default class ExpandedCard extends ArchiveCard {
|
|
|
10
10
|
@api authorImgSrc?: string | null = null;
|
|
11
11
|
@api length?: string;
|
|
12
12
|
|
|
13
|
-
private get isBlog() {
|
|
14
|
-
return this.contentType === "
|
|
13
|
+
private get isBlog(): boolean {
|
|
14
|
+
return this.contentType === "blog";
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
private get hasAuthor(): boolean {
|
|
@@ -3,11 +3,6 @@
|
|
|
3
3
|
<a class="dx-text-truncate" href={href} target={target}>
|
|
4
4
|
<h4>{title}</h4>
|
|
5
5
|
</a>
|
|
6
|
-
<dx-type-badge
|
|
7
|
-
color={badgeColor}
|
|
8
|
-
size={badgeSize}
|
|
9
|
-
type="content-type"
|
|
10
|
-
value={contentType}
|
|
11
|
-
></dx-type-badge>
|
|
6
|
+
<dx-type-badge variant={contentType} size={badgeSize}></dx-type-badge>
|
|
12
7
|
</div>
|
|
13
8
|
</template>
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
@import "dxHelpers/reset";
|
|
2
|
+
|
|
3
|
+
.badge {
|
|
4
|
+
--background: var(--dx-g-cloud-blue-natural-90);
|
|
5
|
+
--border-radius: var(--dx-g-spacing-xs);
|
|
6
|
+
--color: var(--dx-g-blue-vibrant-20);
|
|
7
|
+
--height: var(--dx-g-spacing-lg);
|
|
8
|
+
--horizontal-spacing: var(--dx-g-spacing-sm);
|
|
9
|
+
|
|
10
|
+
color: var(--dx-c-metadata-badge-color, var(--color));
|
|
11
|
+
background: var(--dx-c-metadata-badge-background, var(--background));
|
|
12
|
+
display: flex;
|
|
13
|
+
align-items: center;
|
|
14
|
+
justify-content: center;
|
|
15
|
+
height: var(--height);
|
|
16
|
+
width: min-content;
|
|
17
|
+
padding: 0 var(--horizontal-spacing);
|
|
18
|
+
border-radius: var(--border-radius);
|
|
19
|
+
font-family: var(--dx-g-font-display);
|
|
20
|
+
font-size: 10px;
|
|
21
|
+
text-align: center;
|
|
22
|
+
letter-spacing: 0.6px;
|
|
23
|
+
text-transform: uppercase;
|
|
24
|
+
white-space: nowrap;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.badge.size-small {
|
|
28
|
+
--height: var(--dx-g-spacing-md);
|
|
29
|
+
--horizontal-spacing: var(--dx-g-spacing-xs);
|
|
30
|
+
|
|
31
|
+
font-size: 8px;
|
|
32
|
+
letter-spacing: 0.5px;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.badge span {
|
|
36
|
+
transform: translateY(2px);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.badge.size-small span {
|
|
40
|
+
transform: translateY(1px);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
@media screen and (max-width: 768px) {
|
|
44
|
+
.badge:not(.size-small) {
|
|
45
|
+
height: var(--dx-g-spacing-lg);
|
|
46
|
+
padding: 0 var(--dx-g-spacing-sm);
|
|
47
|
+
font-size: var(--dx-g-text-2xs);
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { LightningElement, api } from "lwc";
|
|
2
|
+
import cx from "classnames";
|
|
3
|
+
import { Color, TypeBadgeSize } from "typings/custom";
|
|
4
|
+
import { colorToDxColors, buildStyleColorVariables } from "dxUtils/css";
|
|
5
|
+
|
|
6
|
+
export default class MetadataBadge extends LightningElement {
|
|
7
|
+
@api size: TypeBadgeSize = "default";
|
|
8
|
+
@api color?: Color;
|
|
9
|
+
@api value!: string;
|
|
10
|
+
|
|
11
|
+
private get className(): string {
|
|
12
|
+
return cx("badge", `size-${this.size}`);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
private get style(): string {
|
|
16
|
+
if (this.color) {
|
|
17
|
+
const variables = colorToDxColors(this.color as Color);
|
|
18
|
+
if (variables) {
|
|
19
|
+
return buildStyleColorVariables(variables);
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
return "";
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/* Code generated by scripts/postinstall.js DO NOT EDIT*/
|
|
2
2
|
|
|
3
|
+
|
|
3
4
|
/* -------------------------------------------------------------------
|
|
4
5
|
Microtip
|
|
5
6
|
|
|
@@ -15,251 +16,254 @@
|
|
|
15
16
|
3. Position Modifiers
|
|
16
17
|
--------------------------------------------------------------------*/
|
|
17
18
|
|
|
19
|
+
|
|
18
20
|
/* ------------------------------------------------
|
|
19
21
|
[1] Base Styles
|
|
20
22
|
-------------------------------------------------*/
|
|
21
23
|
|
|
22
24
|
[aria-label][role~="tooltip"] {
|
|
23
|
-
|
|
25
|
+
position: relative;
|
|
24
26
|
}
|
|
25
27
|
|
|
26
28
|
[aria-label][role~="tooltip"]::before,
|
|
27
29
|
[aria-label][role~="tooltip"]::after {
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
z-index: 10;
|
|
40
|
-
transform-origin: top;
|
|
30
|
+
transform: translate3d(0, 0, 0);
|
|
31
|
+
-webkit-backface-visibility: hidden;
|
|
32
|
+
backface-visibility: hidden;
|
|
33
|
+
will-change: transform;
|
|
34
|
+
opacity: 0;
|
|
35
|
+
pointer-events: none;
|
|
36
|
+
transition: all var(--microtip-transition-duration, .18s) var(--microtip-transition-easing, ease-in-out) var(--microtip-transition-delay, 0s);
|
|
37
|
+
position: absolute;
|
|
38
|
+
box-sizing: border-box;
|
|
39
|
+
z-index: 10;
|
|
40
|
+
transform-origin: top;
|
|
41
41
|
}
|
|
42
42
|
|
|
43
43
|
[aria-label][role~="tooltip"]::before {
|
|
44
|
-
|
|
45
|
-
|
|
44
|
+
background-size: 100% auto !important;
|
|
45
|
+
content: "";
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
[aria-label][role~="tooltip"]::after {
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
49
|
+
background: rgba(17, 17, 17, .9);
|
|
50
|
+
border-radius: 4px;
|
|
51
|
+
color: #ffffff;
|
|
52
|
+
content: attr(aria-label);
|
|
53
|
+
font-size: var(--microtip-font-size, 13px);
|
|
54
|
+
font-weight: var(--microtip-font-weight, normal);
|
|
55
|
+
text-transform: var(--microtip-text-transform, none);
|
|
56
|
+
padding: .5em 1em;
|
|
57
|
+
white-space: nowrap;
|
|
58
|
+
box-sizing: content-box;
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
[aria-label][role~="tooltip"]:hover::before,
|
|
62
62
|
[aria-label][role~="tooltip"]:hover::after,
|
|
63
63
|
[aria-label][role~="tooltip"]:focus::before,
|
|
64
64
|
[aria-label][role~="tooltip"]:focus::after {
|
|
65
|
-
|
|
66
|
-
|
|
65
|
+
opacity: 1;
|
|
66
|
+
pointer-events: auto;
|
|
67
67
|
}
|
|
68
68
|
|
|
69
|
+
|
|
70
|
+
|
|
69
71
|
/* ------------------------------------------------
|
|
70
72
|
[2] Position Modifiers
|
|
71
73
|
-------------------------------------------------*/
|
|
72
74
|
|
|
73
75
|
[role~="tooltip"][data-microtip-position|="top"]::before {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
margin-bottom: 5px;
|
|
76
|
+
background: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20width%3D%2236px%22%20height%3D%2212px%22%3E%3Cpath%20fill%3D%22rgba%2817,%2017,%2017,%200.9%29%22%20transform%3D%22rotate%280%29%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E") no-repeat;
|
|
77
|
+
height: 6px;
|
|
78
|
+
width: 18px;
|
|
79
|
+
margin-bottom: 5px;
|
|
79
80
|
}
|
|
80
81
|
|
|
81
82
|
[role~="tooltip"][data-microtip-position|="top"]::after {
|
|
82
|
-
|
|
83
|
+
margin-bottom: 11px;
|
|
83
84
|
}
|
|
84
85
|
|
|
85
86
|
[role~="tooltip"][data-microtip-position|="top"]::before {
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
87
|
+
transform: translate3d(-50%, 0, 0);
|
|
88
|
+
bottom: 100%;
|
|
89
|
+
left: 50%;
|
|
89
90
|
}
|
|
90
91
|
|
|
91
92
|
[role~="tooltip"][data-microtip-position|="top"]:hover::before {
|
|
92
|
-
|
|
93
|
+
transform: translate3d(-50%, -5px, 0);
|
|
93
94
|
}
|
|
94
95
|
|
|
95
96
|
[role~="tooltip"][data-microtip-position|="top"]::after {
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
97
|
+
transform: translate3d(-50%, 0, 0);
|
|
98
|
+
bottom: 100%;
|
|
99
|
+
left: 50%;
|
|
99
100
|
}
|
|
100
101
|
|
|
101
102
|
[role~="tooltip"][data-microtip-position="top"]:hover::after {
|
|
102
|
-
|
|
103
|
+
transform: translate3d(-50%, -5px, 0);
|
|
103
104
|
}
|
|
104
105
|
|
|
105
106
|
/* ------------------------------------------------
|
|
106
107
|
[2.1] Top Left
|
|
107
108
|
-------------------------------------------------*/
|
|
108
109
|
[role~="tooltip"][data-microtip-position="top-left"]::after {
|
|
109
|
-
|
|
110
|
-
|
|
110
|
+
transform: translate3d(calc(-100% + 16px), 0, 0);
|
|
111
|
+
bottom: 100%;
|
|
111
112
|
}
|
|
112
113
|
|
|
113
114
|
[role~="tooltip"][data-microtip-position="top-left"]:hover::after {
|
|
114
|
-
|
|
115
|
+
transform: translate3d(calc(-100% + 16px), -5px, 0);
|
|
115
116
|
}
|
|
116
117
|
|
|
118
|
+
|
|
117
119
|
/* ------------------------------------------------
|
|
118
120
|
[2.2] Top Right
|
|
119
121
|
-------------------------------------------------*/
|
|
120
122
|
[role~="tooltip"][data-microtip-position="top-right"]::after {
|
|
121
|
-
|
|
122
|
-
|
|
123
|
+
transform: translate3d(calc(0% + -16px), 0, 0);
|
|
124
|
+
bottom: 100%;
|
|
123
125
|
}
|
|
124
126
|
|
|
125
127
|
[role~="tooltip"][data-microtip-position="top-right"]:hover::after {
|
|
126
|
-
|
|
128
|
+
transform: translate3d(calc(0% + -16px), -5px, 0);
|
|
127
129
|
}
|
|
128
130
|
|
|
131
|
+
|
|
129
132
|
/* ------------------------------------------------
|
|
130
133
|
[2.3] Bottom
|
|
131
134
|
-------------------------------------------------*/
|
|
132
135
|
[role~="tooltip"][data-microtip-position|="bottom"]::before {
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
margin-bottom: 0;
|
|
136
|
+
background: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20width%3D%2236px%22%20height%3D%2212px%22%3E%3Cpath%20fill%3D%22rgba%2817,%2017,%2017,%200.9%29%22%20transform%3D%22rotate%28180%2018%206%29%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E") no-repeat;
|
|
137
|
+
height: 6px;
|
|
138
|
+
width: 18px;
|
|
139
|
+
margin-top: 5px;
|
|
140
|
+
margin-bottom: 0;
|
|
139
141
|
}
|
|
140
142
|
|
|
141
143
|
[role~="tooltip"][data-microtip-position|="bottom"]::after {
|
|
142
|
-
|
|
144
|
+
margin-top: 11px;
|
|
143
145
|
}
|
|
144
146
|
|
|
145
147
|
[role~="tooltip"][data-microtip-position|="bottom"]::before {
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
148
|
+
transform: translate3d(-50%, -10px, 0);
|
|
149
|
+
bottom: auto;
|
|
150
|
+
left: 50%;
|
|
151
|
+
top: 100%;
|
|
150
152
|
}
|
|
151
153
|
|
|
152
154
|
[role~="tooltip"][data-microtip-position|="bottom"]:hover::before {
|
|
153
|
-
|
|
155
|
+
transform: translate3d(-50%, 0, 0);
|
|
154
156
|
}
|
|
155
157
|
|
|
156
158
|
[role~="tooltip"][data-microtip-position|="bottom"]::after {
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
159
|
+
transform: translate3d(-50%, -10px, 0);
|
|
160
|
+
top: 100%;
|
|
161
|
+
left: 50%;
|
|
160
162
|
}
|
|
161
163
|
|
|
162
164
|
[role~="tooltip"][data-microtip-position="bottom"]:hover::after {
|
|
163
|
-
|
|
165
|
+
transform: translate3d(-50%, 0, 0);
|
|
164
166
|
}
|
|
165
167
|
|
|
168
|
+
|
|
166
169
|
/* ------------------------------------------------
|
|
167
170
|
[2.4] Bottom Left
|
|
168
171
|
-------------------------------------------------*/
|
|
169
172
|
[role~="tooltip"][data-microtip-position="bottom-left"]::after {
|
|
170
|
-
|
|
171
|
-
|
|
173
|
+
transform: translate3d(calc(-100% + 16px), -10px, 0);
|
|
174
|
+
top: 100%;
|
|
172
175
|
}
|
|
173
176
|
|
|
174
177
|
[role~="tooltip"][data-microtip-position="bottom-left"]:hover::after {
|
|
175
|
-
|
|
178
|
+
transform: translate3d(calc(-100% + 16px), 0, 0);
|
|
176
179
|
}
|
|
177
180
|
|
|
181
|
+
|
|
178
182
|
/* ------------------------------------------------
|
|
179
183
|
[2.5] Bottom Right
|
|
180
184
|
-------------------------------------------------*/
|
|
181
185
|
[role~="tooltip"][data-microtip-position="bottom-right"]::after {
|
|
182
|
-
|
|
183
|
-
|
|
186
|
+
transform: translate3d(calc(0% + -16px), -10px, 0);
|
|
187
|
+
top: 100%;
|
|
184
188
|
}
|
|
185
189
|
|
|
186
190
|
[role~="tooltip"][data-microtip-position="bottom-right"]:hover::after {
|
|
187
|
-
|
|
191
|
+
transform: translate3d(calc(0% + -16px), 0, 0);
|
|
188
192
|
}
|
|
189
193
|
|
|
194
|
+
|
|
190
195
|
/* ------------------------------------------------
|
|
191
196
|
[2.6] Left
|
|
192
197
|
-------------------------------------------------*/
|
|
193
198
|
[role~="tooltip"][data-microtip-position="left"]::before,
|
|
194
199
|
[role~="tooltip"][data-microtip-position="left"]::after {
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
+
bottom: auto;
|
|
201
|
+
left: auto;
|
|
202
|
+
right: 100%;
|
|
203
|
+
top: 50%;
|
|
204
|
+
transform: translate3d(10px, -50%, 0);
|
|
200
205
|
}
|
|
201
206
|
|
|
202
207
|
[role~="tooltip"][data-microtip-position="left"]::before {
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
margin-bottom: 0;
|
|
208
|
+
background: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20width%3D%2212px%22%20height%3D%2236px%22%3E%3Cpath%20fill%3D%22rgba%2817,%2017,%2017,%200.9%29%22%20transform%3D%22rotate%28-90%2018%2018%29%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E") no-repeat;
|
|
209
|
+
height: 18px;
|
|
210
|
+
width: 6px;
|
|
211
|
+
margin-right: 5px;
|
|
212
|
+
margin-bottom: 0;
|
|
209
213
|
}
|
|
210
214
|
|
|
211
215
|
[role~="tooltip"][data-microtip-position="left"]::after {
|
|
212
|
-
|
|
216
|
+
margin-right: 11px;
|
|
213
217
|
}
|
|
214
218
|
|
|
215
219
|
[role~="tooltip"][data-microtip-position="left"]:hover::before,
|
|
216
220
|
[role~="tooltip"][data-microtip-position="left"]:hover::after {
|
|
217
|
-
|
|
221
|
+
transform: translate3d(0, -50%, 0);
|
|
218
222
|
}
|
|
219
223
|
|
|
224
|
+
|
|
220
225
|
/* ------------------------------------------------
|
|
221
226
|
[2.7] Right
|
|
222
227
|
-------------------------------------------------*/
|
|
223
228
|
[role~="tooltip"][data-microtip-position="right"]::before,
|
|
224
229
|
[role~="tooltip"][data-microtip-position="right"]::after {
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
230
|
+
bottom: auto;
|
|
231
|
+
left: 100%;
|
|
232
|
+
top: 50%;
|
|
233
|
+
transform: translate3d(-10px, -50%, 0);
|
|
229
234
|
}
|
|
230
235
|
|
|
231
236
|
[role~="tooltip"][data-microtip-position="right"]::before {
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
margin-left: 5px;
|
|
237
|
+
background: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20width%3D%2212px%22%20height%3D%2236px%22%3E%3Cpath%20fill%3D%22rgba%2817,%2017,%2017,%200.9%29%22%20transform%3D%22rotate%2890%206%206%29%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E") no-repeat;
|
|
238
|
+
height: 18px;
|
|
239
|
+
width: 6px;
|
|
240
|
+
margin-bottom: 0;
|
|
241
|
+
margin-left: 5px;
|
|
238
242
|
}
|
|
239
243
|
|
|
240
244
|
[role~="tooltip"][data-microtip-position="right"]::after {
|
|
241
|
-
|
|
245
|
+
margin-left: 11px;
|
|
242
246
|
}
|
|
243
247
|
|
|
244
248
|
[role~="tooltip"][data-microtip-position="right"]:hover::before,
|
|
245
249
|
[role~="tooltip"][data-microtip-position="right"]:hover::after {
|
|
246
|
-
|
|
250
|
+
transform: translate3d(0, -50%, 0);
|
|
247
251
|
}
|
|
248
252
|
|
|
249
253
|
/* ------------------------------------------------
|
|
250
254
|
[3] Size
|
|
251
255
|
-------------------------------------------------*/
|
|
252
256
|
[role~="tooltip"][data-microtip-size="small"]::after {
|
|
253
|
-
|
|
254
|
-
|
|
257
|
+
white-space: initial;
|
|
258
|
+
width: 80px;
|
|
255
259
|
}
|
|
256
260
|
|
|
257
261
|
[role~="tooltip"][data-microtip-size="medium"]::after {
|
|
258
|
-
|
|
259
|
-
|
|
262
|
+
white-space: initial;
|
|
263
|
+
width: 150px;
|
|
260
264
|
}
|
|
261
265
|
|
|
262
266
|
[role~="tooltip"][data-microtip-size="large"]::after {
|
|
263
|
-
|
|
264
|
-
|
|
267
|
+
white-space: initial;
|
|
268
|
+
width: 260px;
|
|
265
269
|
}
|
|
@@ -145,33 +145,33 @@
|
|
|
145
145
|
--indentation: calc(20 * var(--base-indentation));
|
|
146
146
|
}
|
|
147
147
|
|
|
148
|
-
dx-
|
|
149
|
-
--dx-c-
|
|
148
|
+
dx-metadata-badge {
|
|
149
|
+
--dx-c-metadata-badge-text-width: 21px;
|
|
150
150
|
}
|
|
151
151
|
|
|
152
|
-
dx-
|
|
153
|
-
--dx-c-
|
|
154
|
-
--dx-c-
|
|
152
|
+
dx-metadata-badge.get {
|
|
153
|
+
--dx-c-metadata-badge-color: var(--dx-g-blue-vibrant-50);
|
|
154
|
+
--dx-c-metadata-badge-background: var(--dx-g-blue-vibrant-90);
|
|
155
155
|
}
|
|
156
156
|
|
|
157
|
-
dx-
|
|
158
|
-
--dx-c-
|
|
159
|
-
--dx-c-
|
|
157
|
+
dx-metadata-badge.put {
|
|
158
|
+
--dx-c-metadata-badge-color: var(--dx-g-yellow-vibrant-40);
|
|
159
|
+
--dx-c-metadata-badge-background: var(--dx-g-yellow-vibrant-90);
|
|
160
160
|
}
|
|
161
161
|
|
|
162
|
-
dx-
|
|
163
|
-
--dx-c-
|
|
164
|
-
--dx-c-
|
|
162
|
+
dx-metadata-badge.post {
|
|
163
|
+
--dx-c-metadata-badge-color: var(--dx-g-green-vibrant-40);
|
|
164
|
+
--dx-c-metadata-badge-background: var(--dx-g-green-vibrant-90);
|
|
165
165
|
}
|
|
166
166
|
|
|
167
|
-
dx-
|
|
168
|
-
--dx-c-
|
|
169
|
-
--dx-c-
|
|
167
|
+
dx-metadata-badge.patch {
|
|
168
|
+
--dx-c-metadata-badge-color: var(--dx-g-teal-vibrant-40);
|
|
169
|
+
--dx-c-metadata-badge-background: var(--dx-g-teal-vibrant-90);
|
|
170
170
|
}
|
|
171
171
|
|
|
172
|
-
dx-
|
|
173
|
-
--dx-c-
|
|
174
|
-
--dx-c-
|
|
172
|
+
dx-metadata-badge.delete {
|
|
173
|
+
--dx-c-metadata-badge-color: var(--dx-g-red-vibrant-40);
|
|
174
|
+
--dx-c-metadata-badge-background: var(--dx-g-hot-orange-vibrant-90);
|
|
175
175
|
}
|
|
176
176
|
|
|
177
177
|
a {
|
|
@@ -16,12 +16,13 @@
|
|
|
16
16
|
onclick={onClickIcon}
|
|
17
17
|
></dx-icon>
|
|
18
18
|
</div>
|
|
19
|
-
<dx-
|
|
19
|
+
<dx-metadata-badge
|
|
20
20
|
if:true={showMethod}
|
|
21
|
-
class=
|
|
21
|
+
class="flex tile-icon"
|
|
22
22
|
size="small"
|
|
23
23
|
value={methodText}
|
|
24
|
-
|
|
24
|
+
color={metadataBadgeColor}
|
|
25
|
+
></dx-metadata-badge>
|
|
25
26
|
</div>
|
|
26
27
|
</a>
|
|
27
28
|
</template>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { LightningElement, api } from "lwc";
|
|
2
2
|
import cx from "classnames";
|
|
3
|
-
import { InternalTreeNode } from "typings/custom";
|
|
3
|
+
import { Color, InternalTreeNode } from "typings/custom";
|
|
4
4
|
|
|
5
5
|
const methodTextMap: {
|
|
6
6
|
[key: string]: string;
|
|
@@ -12,6 +12,16 @@ const methodTextMap: {
|
|
|
12
12
|
delete: "DELE"
|
|
13
13
|
};
|
|
14
14
|
|
|
15
|
+
const metadataBadgeColorMap: {
|
|
16
|
+
[key: string]: Color;
|
|
17
|
+
} = {
|
|
18
|
+
get: "blue",
|
|
19
|
+
put: "yellow",
|
|
20
|
+
post: "green",
|
|
21
|
+
patch: "teal",
|
|
22
|
+
delete: "red"
|
|
23
|
+
};
|
|
24
|
+
|
|
15
25
|
export default class TreeTile extends LightningElement {
|
|
16
26
|
@api isRoot = false;
|
|
17
27
|
@api treeNode!: InternalTreeNode;
|
|
@@ -29,8 +39,11 @@ export default class TreeTile extends LightningElement {
|
|
|
29
39
|
return this.isRoot ? "small" : "xsmall";
|
|
30
40
|
}
|
|
31
41
|
|
|
32
|
-
private get
|
|
33
|
-
|
|
42
|
+
private get metadataBadgeColor(): string | undefined {
|
|
43
|
+
if (this.treeNode.method) {
|
|
44
|
+
return metadataBadgeColorMap[this.treeNode.method];
|
|
45
|
+
}
|
|
46
|
+
return undefined;
|
|
34
47
|
}
|
|
35
48
|
|
|
36
49
|
private get showMethod() {
|
|
@@ -1,33 +1,6 @@
|
|
|
1
1
|
@import "dxHelpers/reset";
|
|
2
2
|
|
|
3
|
-
.
|
|
4
|
-
align-items: center;
|
|
5
|
-
background: var(--dx-c-type-badge-background, var(--background));
|
|
6
|
-
border-radius: var(--dx-c-type-badge-border-radius, var(--border-radius));
|
|
7
|
-
color: var(--dx-c-type-badge-color, var(--color));
|
|
8
|
-
display: flex;
|
|
9
|
-
justify-content: center;
|
|
10
|
-
height: var(--dx-c-type-badge-height, var(--height));
|
|
11
|
-
text-align: center;
|
|
12
|
-
white-space: nowrap;
|
|
13
|
-
width: min-content;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.typebadge.typebadge_metadata {
|
|
17
|
-
--background: var(--dx-g-cloud-blue-natural-90);
|
|
18
|
-
--border-radius: var(--dx-g-spacing-xs);
|
|
19
|
-
--color: var(--dx-g-blue-vibrant-20);
|
|
20
|
-
--height: var(--dx-g-spacing-md);
|
|
21
|
-
--horizontal-spacing: var(--dx-g-spacing-sm);
|
|
22
|
-
|
|
23
|
-
font-family: var(--dx-g-font-display);
|
|
24
|
-
font-size: 10px;
|
|
25
|
-
letter-spacing: 0.6px;
|
|
26
|
-
text-transform: var(--dx-c-type-badge-text-transform, uppercase);
|
|
27
|
-
padding: 0 var(--horizontal-spacing);
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.typebadge.typebadge_content-type {
|
|
3
|
+
.badge {
|
|
31
4
|
--background: var(--sds-g-gray-3);
|
|
32
5
|
--border-radius: var(--dx-g-spacing-smd);
|
|
33
6
|
--color: var(--sds-g-gray-10);
|
|
@@ -35,40 +8,26 @@
|
|
|
35
8
|
--horizontal-spacing: var(--dx-g-spacing-smd);
|
|
36
9
|
--vertical-spacing: var(--dx-g-spacing-xs);
|
|
37
10
|
|
|
11
|
+
color: var(--dx-c-type-badge-color, var(--color));
|
|
12
|
+
background: var(--dx-c-type-badge-background, var(--background));
|
|
13
|
+
border-radius: var(--border-radius);
|
|
14
|
+
display: flex;
|
|
15
|
+
align-items: center;
|
|
16
|
+
justify-content: center;
|
|
17
|
+
height: var(--height);
|
|
18
|
+
width: min-content;
|
|
19
|
+
text-align: center;
|
|
20
|
+
white-space: nowrap;
|
|
38
21
|
font-family: var(--dx-g-font-sans);
|
|
39
|
-
font-size:
|
|
22
|
+
font-size: 10px;
|
|
40
23
|
font-weight: var(--dx-g-font-bold);
|
|
41
24
|
padding: var(--vertical-spacing) var(--horizontal-spacing);
|
|
42
25
|
}
|
|
43
26
|
|
|
44
|
-
.
|
|
27
|
+
.badge.size-small {
|
|
45
28
|
--height: var(--dx-g-spacing-mlg);
|
|
46
|
-
--horizontal-spacing: var(--dx-g-spacing-sm);
|
|
47
|
-
|
|
48
|
-
font-size: 10px;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
.typebadge.typebadge_metadata.size-small {
|
|
52
|
-
--height: var(--dx-g-spacing-md);
|
|
53
|
-
--horizontal-spacing: var(--dx-g-spacing-xs);
|
|
54
|
-
|
|
55
|
-
font-size: 8px;
|
|
56
|
-
letter-spacing: 0.5px;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
.typebadge.typebadge_metadata span {
|
|
60
|
-
transform: translateY(2px);
|
|
61
|
-
width: var(--dx-c-type-badge-text-width, unset);
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
.typebadge.typebadge_metadata.size-small span {
|
|
65
|
-
transform: translateY(1px);
|
|
66
29
|
}
|
|
67
30
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
height: var(--dx-g-spacing-lg);
|
|
71
|
-
padding: 0 var(--dx-g-spacing-sm);
|
|
72
|
-
font-size: var(--dx-g-text-2xs);
|
|
73
|
-
}
|
|
31
|
+
dx-icon {
|
|
32
|
+
margin-right: var(--dx-g-spacing-sm);
|
|
74
33
|
}
|
|
@@ -1,65 +1,161 @@
|
|
|
1
1
|
import { LightningElement, api } from "lwc";
|
|
2
2
|
import cx from "classnames";
|
|
3
3
|
import {
|
|
4
|
-
|
|
4
|
+
Brand,
|
|
5
5
|
Color,
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
ContentType,
|
|
7
|
+
IconSprite,
|
|
8
|
+
IconSymbol,
|
|
9
|
+
TypeBadgeSize
|
|
9
10
|
} from "typings/custom";
|
|
10
|
-
import { colorToDxColors } from "dxUtils/css";
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"
|
|
18
|
-
"
|
|
19
|
-
"
|
|
20
|
-
"
|
|
21
|
-
"
|
|
22
|
-
"
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
11
|
+
import { colorToDxColors, buildStyleColorVariables } from "dxUtils/css";
|
|
12
|
+
import { BRANDS } from "dxConstants/brands";
|
|
13
|
+
import { CONTENT_TYPES } from "dxConstants/contentTypes";
|
|
14
|
+
|
|
15
|
+
const contentTypeLabels = {
|
|
16
|
+
documentation: "Documentation",
|
|
17
|
+
trailhead: "Trailhead",
|
|
18
|
+
blog: "Blog",
|
|
19
|
+
forum: "Forum",
|
|
20
|
+
api: "API",
|
|
21
|
+
event: "Event",
|
|
22
|
+
website: "Website",
|
|
23
|
+
podcast: "Podcast"
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
type IconData = {
|
|
27
|
+
iconSymbol: IconSymbol;
|
|
28
|
+
iconSprite: IconSprite;
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
const contentTypeIcons: {
|
|
32
|
+
[K in ContentType]: IconData;
|
|
33
|
+
} = {
|
|
34
|
+
documentation: {
|
|
35
|
+
iconSprite: "utility",
|
|
36
|
+
iconSymbol: "knowledge_base"
|
|
37
|
+
},
|
|
38
|
+
trailhead: {
|
|
39
|
+
iconSprite: "salesforcebrand",
|
|
40
|
+
iconSymbol: "learning"
|
|
41
|
+
},
|
|
42
|
+
blog: {
|
|
43
|
+
iconSprite: "utility",
|
|
44
|
+
iconSymbol: "comments"
|
|
45
|
+
},
|
|
46
|
+
forum: {
|
|
47
|
+
iconSprite: "general",
|
|
48
|
+
iconSymbol: "question-circle"
|
|
49
|
+
},
|
|
50
|
+
api: {
|
|
51
|
+
iconSprite: "utility",
|
|
52
|
+
iconSymbol: "settings"
|
|
53
|
+
},
|
|
54
|
+
event: {
|
|
55
|
+
iconSprite: "utility",
|
|
56
|
+
iconSymbol: "event"
|
|
57
|
+
},
|
|
58
|
+
website: {
|
|
59
|
+
iconSprite: "utility",
|
|
60
|
+
iconSymbol: "home"
|
|
61
|
+
},
|
|
62
|
+
podcast: {
|
|
63
|
+
iconSprite: "utility",
|
|
64
|
+
iconSymbol: "unmuted"
|
|
65
|
+
}
|
|
66
|
+
};
|
|
27
67
|
|
|
28
68
|
export default class TypeBadge extends LightningElement {
|
|
29
69
|
@api size: TypeBadgeSize = "default";
|
|
30
|
-
@api
|
|
31
|
-
@api color?:
|
|
32
|
-
|
|
70
|
+
@api variant?: Brand | ContentType = "default";
|
|
71
|
+
@api color?: Color;
|
|
72
|
+
|
|
73
|
+
@api
|
|
74
|
+
get iconSymbol(): IconSymbol | undefined {
|
|
75
|
+
return this.variantIconData
|
|
76
|
+
? this.variantIconData.iconSymbol
|
|
77
|
+
: this._iconSymbol;
|
|
78
|
+
}
|
|
79
|
+
set iconSymbol(value: IconSymbol | undefined) {
|
|
80
|
+
if (value) {
|
|
81
|
+
this._iconSymbol = value;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
@api
|
|
86
|
+
get iconSprite(): IconSprite | undefined {
|
|
87
|
+
return this.variantIconData
|
|
88
|
+
? this.variantIconData.iconSprite
|
|
89
|
+
: this._iconSprite;
|
|
90
|
+
}
|
|
91
|
+
set iconSprite(value: IconSprite | undefined) {
|
|
92
|
+
if (value) {
|
|
93
|
+
this._iconSprite = value;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
@api
|
|
98
|
+
get value(): string {
|
|
99
|
+
return this._value || this.variantLabel || "";
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
set value(value) {
|
|
103
|
+
if (value) {
|
|
104
|
+
this._value = value;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
private _value?: string;
|
|
109
|
+
private _iconSprite?: IconSprite;
|
|
110
|
+
private _iconSymbol?: IconSymbol;
|
|
111
|
+
|
|
112
|
+
private get variantIconData(): IconData | null {
|
|
113
|
+
if (this.variant && this.variant in contentTypeIcons) {
|
|
114
|
+
return contentTypeIcons[this.variant as ContentType];
|
|
115
|
+
}
|
|
116
|
+
return null;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
private get variantLabel(): string | null {
|
|
120
|
+
if (this.isContentType) {
|
|
121
|
+
return contentTypeLabels[this.variant as ContentType];
|
|
122
|
+
}
|
|
123
|
+
return null;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
private get variantColorScope(): string | null {
|
|
127
|
+
if (this.isContentType) {
|
|
128
|
+
return "content-type";
|
|
129
|
+
}
|
|
130
|
+
if (this.isBrand) {
|
|
131
|
+
return "brand";
|
|
132
|
+
}
|
|
133
|
+
return null;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
private get isContentType(): boolean {
|
|
137
|
+
return CONTENT_TYPES.includes(this.variant as ContentType);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
private get isBrand(): boolean {
|
|
141
|
+
return BRANDS.includes(this.variant as ContentType);
|
|
142
|
+
}
|
|
33
143
|
|
|
34
144
|
private get className(): string {
|
|
35
|
-
return cx(
|
|
36
|
-
"typebadge",
|
|
37
|
-
`size-${this.size}`,
|
|
38
|
-
(this.type && `typebadge_${this.type}`) || DEFAULT_TYPE
|
|
39
|
-
);
|
|
145
|
+
return cx("badge", `size-${this.size}`);
|
|
40
146
|
}
|
|
41
147
|
|
|
42
148
|
private get style(): string {
|
|
43
|
-
if (
|
|
44
|
-
return
|
|
45
|
-
background: `--dx-g
|
|
46
|
-
color: `--dx-g
|
|
149
|
+
if (this.variantColorScope) {
|
|
150
|
+
return buildStyleColorVariables({
|
|
151
|
+
background: `--dx-g-${this.variantColorScope}-${this.variant}-color-background`,
|
|
152
|
+
color: `--dx-g-${this.variantColorScope}-${this.variant}-color`
|
|
47
153
|
});
|
|
48
154
|
}
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
return
|
|
155
|
+
if (this.color) {
|
|
156
|
+
const variables = colorToDxColors(this.color as Color);
|
|
157
|
+
return buildStyleColorVariables(variables);
|
|
52
158
|
}
|
|
53
159
|
return "";
|
|
54
160
|
}
|
|
55
|
-
|
|
56
|
-
private buildStyleString({
|
|
57
|
-
background,
|
|
58
|
-
color
|
|
59
|
-
}: {
|
|
60
|
-
background: string;
|
|
61
|
-
color: string;
|
|
62
|
-
}): string {
|
|
63
|
-
return `--color: var(${color}); --background: var(${background})`;
|
|
64
|
-
}
|
|
65
161
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { LightningElement, api } from "lwc";
|
|
2
|
-
import { LinkTarget,
|
|
2
|
+
import { LinkTarget, ContentType } from "typings/custom";
|
|
3
3
|
|
|
4
4
|
const MOBILE_QUERY = "(max-width: 640px)";
|
|
5
5
|
|
|
6
6
|
export abstract class ArchiveCard extends LightningElement {
|
|
7
|
-
@api contentType
|
|
7
|
+
@api contentType!: ContentType;
|
|
8
8
|
@api href!: string;
|
|
9
9
|
@api title!: string;
|
|
10
10
|
@api target: LinkTarget = "_self";
|
|
@@ -12,10 +12,6 @@ export abstract class ArchiveCard extends LightningElement {
|
|
|
12
12
|
private matchMedia!: MediaQueryList;
|
|
13
13
|
protected mobile = false;
|
|
14
14
|
|
|
15
|
-
protected get badgeColor(): Color {
|
|
16
|
-
return this.contentType === "Blog" ? "teal" : "blue";
|
|
17
|
-
}
|
|
18
|
-
|
|
19
15
|
connectedCallback(): void {
|
|
20
16
|
this.matchMedia = window.matchMedia(MOBILE_QUERY);
|
|
21
17
|
this.onMediaChange(this.matchMedia);
|
|
@@ -41,3 +41,13 @@ export const colorToDxColors = (
|
|
|
41
41
|
|
|
42
42
|
export const toDxColor = (color: string) =>
|
|
43
43
|
["white", "transparent"].includes(color) ? color : `var(--dx-g-${color})`;
|
|
44
|
+
|
|
45
|
+
export const buildStyleColorVariables = ({
|
|
46
|
+
background,
|
|
47
|
+
color
|
|
48
|
+
}: {
|
|
49
|
+
background: string;
|
|
50
|
+
color: string;
|
|
51
|
+
}): string => {
|
|
52
|
+
return `--color: var(${color}); --background: var(${background})`;
|
|
53
|
+
};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { LightningElement, api } from "lwc";
|
|
2
|
-
import { normalizeToArray } from "dxUtils/normalizers";
|
|
3
|
-
import { TypeBadgeSize } from "typings/custom";
|
|
4
|
-
|
|
5
|
-
export default class TypeBadgeGroup extends LightningElement {
|
|
6
|
-
@api size: TypeBadgeSize = "medium";
|
|
7
|
-
|
|
8
|
-
@api
|
|
9
|
-
get badges() {
|
|
10
|
-
return this._badges;
|
|
11
|
-
}
|
|
12
|
-
set badges(value: string[] | string | null) {
|
|
13
|
-
this._badges = normalizeToArray(value);
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
// can be an array of strings or a comma delimited string
|
|
17
|
-
private _badges!: string | string[] | null;
|
|
18
|
-
}
|