5
5
6
6
import type { TemplateOnlyComponent } from ' @ember/component/template-only' ;
7
7
import { notEq } from ' ember-truth-helpers' ;
8
+ import { array } from ' @ember/helper' ;
8
9
9
10
import ShwTextH2 from ' showcase/components/shw/text/h2' ;
10
11
import ShwFlex from ' showcase/components/shw/flex' ;
@@ -80,6 +81,24 @@ const SubSectionCarbonization: TemplateOnlyComponent = <template>
80
81
{{/each }}
81
82
</ShwFlex >
82
83
</: theming >
84
+ <: reference >
85
+ <ShwFlex @ direction =" column" as | SF | >
86
+ {{#let ( array " sm" " md" " lg" ) as | SIZES | }}
87
+ {{#each SIZES as | size | }}
88
+ <SF.Item >
89
+ <cds-tag size ={{size }} ><HdsIcon
90
+ @ name =" activity"
91
+ slot =" icon"
92
+ /></cds-tag >
93
+ <cds-tag size ={{size }} ><HdsIcon
94
+ @ name =" activity"
95
+ slot =" icon"
96
+ />Lorem ipsum</cds-tag >
97
+ </SF.Item >
98
+ {{/each }}
99
+ {{/let }}
100
+ </ShwFlex >
101
+ </: reference >
83
102
</ShwCarbonizationComparisonGrid >
84
103
85
104
<ShwTextH2 >Type</ShwTextH2 >
@@ -100,37 +119,215 @@ const SubSectionCarbonization: TemplateOnlyComponent = <template>
100
119
{{/each }}
101
120
</ShwFlex >
102
121
</: theming >
122
+ <: reference >
123
+ <ShwFlex @ direction =" column" as | SF | >
124
+ {{#let ( array " gray" " high-contrast" " outline" ) as | TYPES | }}
125
+ {{#each TYPES as | type | }}
126
+ <SF.Item >
127
+ <cds-tag type ={{type }} ><HdsIcon
128
+ @ name =" activity"
129
+ slot =" icon"
130
+ /></cds-tag >
131
+ <cds-tag type ={{type }} ><HdsIcon @ name =" activity" slot =" icon" />
132
+ Lorem ipsum</cds-tag >
133
+ </SF.Item >
134
+ {{/each }}
135
+ {{/let }}
136
+ </ShwFlex >
137
+ </: reference >
103
138
</ShwCarbonizationComparisonGrid >
104
139
105
140
<ShwTextH2 >Color</ShwTextH2 >
106
141
107
- {{#each COLORS as | color index | }}
108
- <ShwCarbonizationComparisonGrid
109
- @ hideThemeLabels ={{( if ( notEq index 0 ) true) }}
110
- >
111
- <: theming >
112
- <ShwFlex @ direction =" column" @ gap =" 0.5rem" as | SF | >
113
- {{#each TYPES as | type | }}
114
- <SF.Item class =" shw-component-badge-sample-color--{{color }} " >
115
- <HdsBadge
116
- @ icon =" activity"
117
- @ text =" Lorem Ipsum"
118
- @ type ={{type }}
119
- @ color ={{color }}
120
- @ isIconOnly ={{ true }}
121
- />
122
- <HdsBadge
123
- @ icon =" activity"
124
- @ text =" Lorem ipsum"
125
- @ type ={{type }}
126
- @ color ={{color }}
127
- />
128
- </SF.Item >
129
- {{/each }}
130
- </ShwFlex >
131
- </: theming >
132
- </ShwCarbonizationComparisonGrid >
133
- {{/each }}
142
+ <ShwCarbonizationComparisonGrid @ label =" neutral" >
143
+ <: theming >
144
+ <ShwFlex @ direction =" column" @ gap =" 0.5rem" as | SF | >
145
+ {{#each TYPES as | type | }}
146
+ <SF.Item class =" shw-component-badge-sample-color--neutral" >
147
+ <HdsBadge
148
+ @ icon =" activity"
149
+ @ text =" Lorem Ipsum"
150
+ @ type ={{type }}
151
+ @ color =" neutral"
152
+ @ isIconOnly ={{ true }}
153
+ />
154
+ <HdsBadge
155
+ @ icon =" activity"
156
+ @ text =" Lorem ipsum"
157
+ @ type ={{type }}
158
+ @ color =" neutral"
159
+ />
160
+ </SF.Item >
161
+ {{/each }}
162
+ </ShwFlex >
163
+ </: theming >
164
+ <: reference >
165
+ <ShwFlex @ direction =" column" as | SF | >
166
+ <SF.Item >
167
+ <cds-tag type =" gray" ><HdsIcon
168
+ @ name =" activity"
169
+ slot =" icon"
170
+ /></cds-tag >
171
+ <cds-tag type =" gray" ><HdsIcon @ name =" activity" slot =" icon" />
172
+ Lorem ipsum</cds-tag >
173
+ </SF.Item >
174
+ <SF.Item >
175
+ <cds-tag type =" outline" ><HdsIcon
176
+ @ name =" activity"
177
+ slot =" icon"
178
+ /></cds-tag >
179
+ <cds-tag type =" outline" ><HdsIcon @ name =" activity" slot =" icon" />
180
+ Lorem ipsum</cds-tag >
181
+ </SF.Item >
182
+ </ShwFlex >
183
+ </: reference >
184
+ </ShwCarbonizationComparisonGrid >
185
+
186
+ <ShwCarbonizationComparisonGrid @ label =" neutral-dark-mode" >
187
+ <: theming >
188
+ <ShwFlex @ direction =" column" @ gap =" 0.5rem" as | SF | >
189
+ {{#each TYPES as | type | }}
190
+ <SF.Item class =" shw-component-badge-sample-color--neutral-dark-mode" >
191
+ <HdsBadge
192
+ @ icon =" activity"
193
+ @ text =" Lorem Ipsum"
194
+ @ type ={{type }}
195
+ @ color =" neutral-dark-mode"
196
+ @ isIconOnly ={{ true }}
197
+ />
198
+ <HdsBadge
199
+ @ icon =" activity"
200
+ @ text =" Lorem ipsum"
201
+ @ type ={{type }}
202
+ @ color =" neutral-dark-mode"
203
+ />
204
+ </SF.Item >
205
+ {{/each }}
206
+ </ShwFlex >
207
+ </: theming >
208
+ <: reference >
209
+ <cds-tag type =" high-contrast" ><HdsIcon
210
+ @ name =" activity"
211
+ slot =" icon"
212
+ /></cds-tag >
213
+ <cds-tag type =" high-contrast" ><HdsIcon @ name =" activity" slot =" icon" />
214
+ Lorem ipsum</cds-tag >
215
+ </: reference >
216
+ </ShwCarbonizationComparisonGrid >
217
+
218
+ <ShwCarbonizationComparisonGrid @ label =" highlight" >
219
+ <: theming >
220
+ <ShwFlex @ direction =" column" @ gap =" 0.5rem" as | SF | >
221
+ {{#each TYPES as | type | }}
222
+ <SF.Item class =" shw-component-badge-sample-color--highlight" >
223
+ <HdsBadge
224
+ @ icon =" activity"
225
+ @ text =" Lorem Ipsum"
226
+ @ type ={{type }}
227
+ @ color =" highlight"
228
+ @ isIconOnly ={{ true }}
229
+ />
230
+ <HdsBadge
231
+ @ icon =" activity"
232
+ @ text =" Lorem ipsum"
233
+ @ type ={{type }}
234
+ @ color =" highlight"
235
+ />
236
+ </SF.Item >
237
+ {{/each }}
238
+ </ShwFlex >
239
+ </: theming >
240
+ <: reference >
241
+ <cds-tag type =" purple" ><HdsIcon @ name =" activity" slot =" icon" /></cds-tag >
242
+ <cds-tag type =" purple" ><HdsIcon @ name =" activity" slot =" icon" />
243
+ Lorem ipsum</cds-tag >
244
+ </: reference >
245
+ </ShwCarbonizationComparisonGrid >
246
+
247
+ <ShwCarbonizationComparisonGrid @ label =" success" >
248
+ <: theming >
249
+ <ShwFlex @ direction =" column" @ gap =" 0.5rem" as | SF | >
250
+ {{#each TYPES as | type | }}
251
+ <SF.Item class =" shw-component-badge-sample-color--success" >
252
+ <HdsBadge
253
+ @ icon =" activity"
254
+ @ text =" Lorem Ipsum"
255
+ @ type ={{type }}
256
+ @ color =" success"
257
+ @ isIconOnly ={{ true }}
258
+ />
259
+ <HdsBadge
260
+ @ icon =" activity"
261
+ @ text =" Lorem ipsum"
262
+ @ type ={{type }}
263
+ @ color =" success"
264
+ />
265
+ </SF.Item >
266
+ {{/each }}
267
+ </ShwFlex >
268
+ </: theming >
269
+ <: reference >
270
+ <cds-tag type =" green" ><HdsIcon @ name =" activity" slot =" icon" /></cds-tag >
271
+ <cds-tag type =" green" ><HdsIcon @ name =" activity" slot =" icon" />
272
+ Lorem ipsum</cds-tag >
273
+ </: reference >
274
+ </ShwCarbonizationComparisonGrid >
275
+
276
+ <ShwCarbonizationComparisonGrid @ label =" warning" >
277
+ <: theming >
278
+ <ShwFlex @ direction =" column" @ gap =" 0.5rem" as | SF | >
279
+ {{#each TYPES as | type | }}
280
+ <SF.Item class =" shw-component-badge-sample-color--warning" >
281
+ <HdsBadge
282
+ @ icon =" activity"
283
+ @ text =" Lorem Ipsum"
284
+ @ type ={{type }}
285
+ @ color =" warning"
286
+ @ isIconOnly ={{ true }}
287
+ />
288
+ <HdsBadge
289
+ @ icon =" activity"
290
+ @ text =" Lorem ipsum"
291
+ @ type ={{type }}
292
+ @ color =" warning"
293
+ />
294
+ </SF.Item >
295
+ {{/each }}
296
+ </ShwFlex >
297
+ </: theming >
298
+ <: reference >
299
+ <code >???</code >
300
+ </: reference >
301
+ </ShwCarbonizationComparisonGrid >
302
+
303
+ <ShwCarbonizationComparisonGrid @ hideThemeLabels ={{ true }} @ label =" critical" >
304
+ <: theming >
305
+ <ShwFlex @ direction =" column" @ gap =" 0.5rem" as | SF | >
306
+ {{#each TYPES as | type | }}
307
+ <SF.Item class =" shw-component-badge-sample-color--critical" >
308
+ <HdsBadge
309
+ @ icon =" activity"
310
+ @ text =" Lorem Ipsum"
311
+ @ type ={{type }}
312
+ @ color =" critical"
313
+ @ isIconOnly ={{ true }}
314
+ />
315
+ <HdsBadge
316
+ @ icon =" activity"
317
+ @ text =" Lorem ipsum"
318
+ @ type ={{type }}
319
+ @ color =" critical"
320
+ />
321
+ </SF.Item >
322
+ {{/each }}
323
+ </ShwFlex >
324
+ </: theming >
325
+ <: reference >
326
+ <cds-tag type =" red" ><HdsIcon @ name =" activity" slot =" icon" /></cds-tag >
327
+ <cds-tag type =" red" ><HdsIcon @ name =" activity" slot =" icon" />
328
+ Lorem ipsum</cds-tag >
329
+ </: reference >
330
+ </ShwCarbonizationComparisonGrid >
134
331
</template >;
135
332
136
333
export default SubSectionCarbonization ;
0 commit comments