@ukic/web-components 2.35.0 → 2.35.1

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.
Files changed (68) hide show
  1. package/README.md +1 -0
  2. package/dist/cjs/ic-navigation-item.cjs.entry.js +1 -1
  3. package/dist/cjs/ic-navigation-item.cjs.entry.js.map +1 -1
  4. package/dist/cjs/ic-toast.cjs.entry.js +2 -2
  5. package/dist/cjs/ic-toast.cjs.entry.js.map +1 -1
  6. package/dist/collection/components/ic-accordion/ic-accordion.stories.js +635 -0
  7. package/dist/collection/components/ic-alert/ic-alert.stories.js +257 -0
  8. package/dist/collection/components/ic-back-to-top/ic-back-to-top.stories.js +162 -0
  9. package/dist/collection/components/ic-badge/ic-badge.stories.js +1082 -0
  10. package/dist/collection/components/ic-breadcrumb-group/ic-breadcrumb-group.stories.js +502 -0
  11. package/dist/collection/components/ic-button/ic-button.stories.js +2218 -0
  12. package/dist/collection/components/ic-card/ic-card.stories.js +1034 -0
  13. package/dist/collection/components/ic-checkbox-group/ic-checkbox-group.stories.js +687 -0
  14. package/dist/collection/components/ic-chip/ic-chip.stories.js +670 -0
  15. package/dist/collection/components/ic-classification-banner/ic-classification-banner.stories.js +131 -0
  16. package/dist/collection/components/ic-data-entity/ic-data-entity.stories.js +487 -0
  17. package/dist/collection/components/ic-dialog/ic-dialog.stories.js +1256 -0
  18. package/dist/collection/components/ic-empty-state/ic-empty-state.stories.js +397 -0
  19. package/dist/collection/components/ic-footer/ic-footer.stories.js +383 -0
  20. package/dist/collection/components/ic-hero/ic-hero.stories.js +489 -0
  21. package/dist/collection/components/ic-link/ic-link.stories.js +114 -0
  22. package/dist/collection/components/ic-loading-indicator/ic-loading-indicator.stories.js +416 -0
  23. package/dist/collection/components/ic-navigation-item/ic-navigation-item.css +7 -35
  24. package/dist/collection/components/ic-page-header/ic-page-header.stories.js +557 -0
  25. package/dist/collection/components/ic-pagination/ic-pagination.stories.js +125 -0
  26. package/dist/collection/components/ic-popover-menu/ic-popover-menu.stories.js +486 -0
  27. package/dist/collection/components/ic-radio-group/ic-radio-group.stories.js +450 -0
  28. package/dist/collection/components/ic-search-bar/ic-search-bar.stories.js +591 -0
  29. package/dist/collection/components/ic-section-container/ic-section-container.stories.js +62 -0
  30. package/dist/collection/components/ic-select/ic-select-searchable.stories.js +953 -0
  31. package/dist/collection/components/ic-select/ic-select-single.stories.js +780 -0
  32. package/dist/collection/components/ic-side-navigation/ic-side-navigation.stories.js +2526 -0
  33. package/dist/collection/components/ic-skeleton/ic-skeleton.stories.js +141 -0
  34. package/dist/collection/components/ic-status-tag/ic-status-tag.stories.js +161 -0
  35. package/dist/collection/components/ic-stepper/ic-stepper.stories.js +327 -0
  36. package/dist/collection/components/ic-switch/ic-switch.stories.js +171 -0
  37. package/dist/collection/components/ic-tab-context/ic-tabs.stories.js +388 -0
  38. package/dist/collection/components/ic-text-field/ic-text-field.stories.js +1083 -0
  39. package/dist/collection/components/ic-theme/ic-theme.stories.js +171 -0
  40. package/dist/collection/components/ic-toast/ic-toast.js +2 -2
  41. package/dist/collection/components/ic-toast/ic-toast.js.map +1 -1
  42. package/dist/collection/components/ic-toast/ic-toast.stories.js +413 -0
  43. package/dist/collection/components/ic-toast/test/basic/ic-toast.spec.js +3 -3
  44. package/dist/collection/components/ic-toast/test/basic/ic-toast.spec.js.map +1 -1
  45. package/dist/collection/components/ic-toggle-button/ic-toggle-button.stories.js +537 -0
  46. package/dist/collection/components/ic-toggle-button-group/ic-toggle-button-group.stories.js +610 -0
  47. package/dist/collection/components/ic-tooltip/ic-tooltip.stories.js +356 -0
  48. package/dist/collection/components/ic-top-navigation/ic-top-navigation.stories.js +1083 -0
  49. package/dist/collection/components/ic-typography/ic-typography.stories.js +437 -0
  50. package/dist/collection/patterns/top-nav-content-footer.stories.js +109 -0
  51. package/dist/collection/patterns/z-index.stories.js +474 -0
  52. package/dist/components/ic-navigation-item.js +1 -1
  53. package/dist/components/ic-navigation-item.js.map +1 -1
  54. package/dist/components/ic-toast.js +2 -2
  55. package/dist/components/ic-toast.js.map +1 -1
  56. package/dist/core/core.esm.js +1 -1
  57. package/dist/core/p-3e8023ff.entry.js +2 -0
  58. package/dist/core/p-3e8023ff.entry.js.map +1 -0
  59. package/dist/core/{p-7e8a4abd.entry.js → p-bfaa257c.entry.js} +2 -2
  60. package/dist/core/{p-7e8a4abd.entry.js.map → p-bfaa257c.entry.js.map} +1 -1
  61. package/dist/esm/ic-navigation-item.entry.js +1 -1
  62. package/dist/esm/ic-navigation-item.entry.js.map +1 -1
  63. package/dist/esm/ic-toast.entry.js +2 -2
  64. package/dist/esm/ic-toast.entry.js.map +1 -1
  65. package/hydrate/index.js +3 -3
  66. package/package.json +15 -11
  67. package/dist/core/p-dfb3e76e.entry.js +0 -2
  68. package/dist/core/p-dfb3e76e.entry.js.map +0 -1
@@ -0,0 +1,670 @@
1
+ import { html } from "lit-html";
2
+
3
+ const defaultArgs = {
4
+ customColor: null,
5
+ disabled: false,
6
+ dismissible: false,
7
+ dismissLabel: "Dismiss",
8
+ label: "Default",
9
+ size: "default",
10
+ transparentBackground: true,
11
+ variant: "filled",
12
+ badgeSlot: "badge",
13
+ };
14
+
15
+ export default {
16
+ title: "Web Components/Chip",
17
+ component: "ic-chip",
18
+ };
19
+
20
+ export const Static = {
21
+ render: () =>
22
+ html`<ic-chip label="Small" size="small">
23
+ <svg
24
+ slot="icon"
25
+ width="20"
26
+ height="20"
27
+ viewBox="0 0 20 20"
28
+ fill="currentColor"
29
+ xmlns="http://www.w3.org/2000/svg"
30
+ aria-label="account"
31
+ >
32
+ <path
33
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
34
+ />
35
+ </svg>
36
+ </ic-chip>
37
+ <ic-chip label="Default">
38
+ <svg
39
+ slot="icon"
40
+ width="20"
41
+ height="20"
42
+ viewBox="0 0 20 20"
43
+ fill="currentColor"
44
+ xmlns="http://www.w3.org/2000/svg"
45
+ aria-label="account"
46
+ >
47
+ <path
48
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
49
+ />
50
+ </svg>
51
+ </ic-chip>
52
+ <ic-chip label="Large" size="large">
53
+ <svg
54
+ slot="icon"
55
+ width="20"
56
+ height="20"
57
+ viewBox="0 0 20 20"
58
+ fill="currentColor"
59
+ xmlns="http://www.w3.org/2000/svg"
60
+ aria-hidden="true"
61
+ >
62
+ <path
63
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
64
+ />
65
+ </svg>
66
+ </ic-chip>`,
67
+
68
+ name: "Static",
69
+ };
70
+
71
+ export const Outline = {
72
+ render: () =>
73
+ html`<ic-chip label="Small" size="small" variant="outlined">
74
+ <svg
75
+ slot="icon"
76
+ width="20"
77
+ height="20"
78
+ viewBox="0 0 20 20"
79
+ fill="currentColor"
80
+ xmlns="http://www.w3.org/2000/svg"
81
+ aria-label="account"
82
+ >
83
+ <path
84
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
85
+ />
86
+ </svg>
87
+ </ic-chip>
88
+ <ic-chip label="Default" variant="outlined">
89
+ <svg
90
+ slot="icon"
91
+ width="20"
92
+ height="20"
93
+ viewBox="0 0 20 20"
94
+ fill="currentColor"
95
+ xmlns="http://www.w3.org/2000/svg"
96
+ aria-label="account"
97
+ >
98
+ <path
99
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
100
+ />
101
+ </svg>
102
+ </ic-chip>
103
+ <ic-chip label="Large" size="large" variant="outlined">
104
+ <svg
105
+ slot="icon"
106
+ width="20"
107
+ height="20"
108
+ viewBox="0 0 20 20"
109
+ fill="currentColor"
110
+ xmlns="http://www.w3.org/2000/svg"
111
+ aria-hidden="true"
112
+ >
113
+ <path
114
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
115
+ />
116
+ </svg>
117
+ </ic-chip>`,
118
+
119
+ name: "Outline",
120
+ };
121
+
122
+ export const DeprecatedAppearance = {
123
+ render: () =>
124
+ html`<ic-chip label="Small" size="small" appearance="outline">
125
+ <svg
126
+ slot="icon"
127
+ width="20"
128
+ height="20"
129
+ viewBox="0 0 20 20"
130
+ fill="currentColor"
131
+ xmlns="http://www.w3.org/2000/svg"
132
+ aria-label="account"
133
+ >
134
+ <path
135
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
136
+ />
137
+ </svg>
138
+ </ic-chip>
139
+ <ic-chip label="Default" appearance="outline">
140
+ <svg
141
+ slot="icon"
142
+ width="20"
143
+ height="20"
144
+ viewBox="0 0 20 20"
145
+ fill="currentColor"
146
+ xmlns="http://www.w3.org/2000/svg"
147
+ aria-label="account"
148
+ >
149
+ <path
150
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
151
+ />
152
+ </svg>
153
+ </ic-chip>
154
+ <ic-chip label="Large" size="large" appearance="outline">
155
+ <svg
156
+ slot="icon"
157
+ width="20"
158
+ height="20"
159
+ viewBox="0 0 20 20"
160
+ fill="currentColor"
161
+ xmlns="http://www.w3.org/2000/svg"
162
+ aria-hidden="true"
163
+ >
164
+ <path
165
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
166
+ />
167
+ </svg>
168
+ </ic-chip>`,
169
+
170
+ name: "Deprecated - appearance",
171
+ };
172
+
173
+ export const Dismissible = {
174
+ render: () =>
175
+ html`<ic-chip label="Small" dismissible="true" size="small">
176
+ <svg
177
+ slot="icon"
178
+ width="20"
179
+ height="20"
180
+ viewBox="0 0 20 20"
181
+ fill="currentColor"
182
+ xmlns="http://www.w3.org/2000/svg"
183
+ aria-label="account"
184
+ >
185
+ <path
186
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
187
+ />
188
+ </svg>
189
+ </ic-chip>
190
+ <ic-chip label="Default" dismissible="true">
191
+ <svg
192
+ slot="icon"
193
+ width="20"
194
+ height="20"
195
+ viewBox="0 0 20 20"
196
+ fill="currentColor"
197
+ xmlns="http://www.w3.org/2000/svg"
198
+ aria-label="account"
199
+ >
200
+ <path
201
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
202
+ />
203
+ </svg>
204
+ </ic-chip>
205
+ <ic-chip label="Large" dismissible="true" size="large">
206
+ <svg
207
+ slot="icon"
208
+ width="20"
209
+ height="20"
210
+ viewBox="0 0 20 20"
211
+ fill="currentColor"
212
+ xmlns="http://www.w3.org/2000/svg"
213
+ aria-label="account"
214
+ >
215
+ <path
216
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
217
+ />
218
+ </svg>
219
+ </ic-chip>
220
+ <ic-chip label="Small" dismissible="true" size="small" variant="outlined">
221
+ <svg
222
+ slot="icon"
223
+ width="20"
224
+ height="20"
225
+ viewBox="0 0 20 20"
226
+ fill="currentColor"
227
+ xmlns="http://www.w3.org/2000/svg"
228
+ aria-label="account"
229
+ >
230
+ <path
231
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
232
+ />
233
+ </svg>
234
+ </ic-chip>
235
+ <ic-chip label="Default" dismissible="true" variant="outlined">
236
+ <svg
237
+ slot="icon"
238
+ width="20"
239
+ height="20"
240
+ viewBox="0 0 20 20"
241
+ fill="currentColor"
242
+ xmlns="http://www.w3.org/2000/svg"
243
+ aria-label="account"
244
+ >
245
+ <path
246
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
247
+ />
248
+ </svg>
249
+ </ic-chip>
250
+ <ic-chip label="Large" dismissible="true" size="large" variant="outlined">
251
+ <svg
252
+ slot="icon"
253
+ width="20"
254
+ height="20"
255
+ viewBox="0 0 20 20"
256
+ fill="currentColor"
257
+ xmlns="http://www.w3.org/2000/svg"
258
+ aria-hidden="true"
259
+ >
260
+ <path
261
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
262
+ />
263
+ </svg>
264
+ </ic-chip>`,
265
+
266
+ name: "Dismissible",
267
+ };
268
+
269
+ export const Disabled = {
270
+ render: () =>
271
+ html`<ic-chip label="Small" dismissible="true" disabled="true" size="small">
272
+ <svg
273
+ slot="icon"
274
+ width="20"
275
+ height="20"
276
+ viewBox="0 0 20 20"
277
+ fill="currentColor"
278
+ xmlns="http://www.w3.org/2000/svg"
279
+ aria-label="account"
280
+ >
281
+ <path
282
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
283
+ />
284
+ </svg>
285
+ </ic-chip>
286
+ <ic-chip label="Default" dismissible="true" disabled="true">
287
+ <svg
288
+ slot="icon"
289
+ width="20"
290
+ height="20"
291
+ viewBox="0 0 20 20"
292
+ fill="currentColor"
293
+ xmlns="http://www.w3.org/2000/svg"
294
+ aria-label="account"
295
+ >
296
+ <path
297
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
298
+ />
299
+ </svg>
300
+ </ic-chip>
301
+ <ic-chip label="Large" dismissible="true" disabled="true" size="large">
302
+ <svg
303
+ slot="icon"
304
+ width="20"
305
+ height="20"
306
+ viewBox="0 0 20 20"
307
+ fill="currentColor"
308
+ xmlns="http://www.w3.org/2000/svg"
309
+ aria-label="account"
310
+ >
311
+ <path
312
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
313
+ />
314
+ </svg>
315
+ </ic-chip>
316
+ <ic-chip
317
+ label="Small"
318
+ dismissible="true"
319
+ disabled="true"
320
+ variant="outlined"
321
+ size="small"
322
+ >
323
+ <svg
324
+ slot="icon"
325
+ width="20"
326
+ height="20"
327
+ viewBox="0 0 20 20"
328
+ fill="currentColor"
329
+ xmlns="http://www.w3.org/2000/svg"
330
+ aria-label="account"
331
+ >
332
+ <path
333
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
334
+ />
335
+ </svg>
336
+ </ic-chip>
337
+ <ic-chip
338
+ label="Default"
339
+ dismissible="true"
340
+ disabled="true"
341
+ variant="outlined"
342
+ >
343
+ <svg
344
+ slot="icon"
345
+ width="20"
346
+ height="20"
347
+ viewBox="0 0 20 20"
348
+ fill="currentColor"
349
+ xmlns="http://www.w3.org/2000/svg"
350
+ aria-label="account"
351
+ >
352
+ <path
353
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
354
+ />
355
+ </svg>
356
+ </ic-chip>
357
+ <ic-chip
358
+ label="Large"
359
+ dismissible="true"
360
+ disabled="true"
361
+ variant="outlined"
362
+ size="large"
363
+ >
364
+ <svg
365
+ slot="icon"
366
+ width="20"
367
+ height="20"
368
+ viewBox="0 0 20 20"
369
+ fill="currentColor"
370
+ xmlns="http://www.w3.org/2000/svg"
371
+ aria-hidden="true"
372
+ >
373
+ <path
374
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
375
+ />
376
+ </svg>
377
+ </ic-chip>`,
378
+
379
+ name: "Disabled",
380
+ };
381
+
382
+ export const WithoutIcons = {
383
+ render: () => html`
384
+ <ic-chip label="Label"></ic-chip>
385
+ <ic-chip label="Label" variant="outlined"></ic-chip>
386
+ <ic-chip label="Label" dismissible="true"></ic-chip>
387
+ <ic-chip label="Label" variant="outlined" dismissible="true"></ic-chip>
388
+ `,
389
+
390
+ name: "Without icons",
391
+ };
392
+
393
+ export const LongLabel = {
394
+ render: () =>
395
+ html`<ic-chip
396
+ label="Really long name for a chip that should wrap"
397
+ dismissible="true"
398
+ size="small"
399
+ style="max-width: 150px"
400
+ >
401
+ <svg
402
+ slot="icon"
403
+ width="20"
404
+ height="20"
405
+ viewBox="0 0 20 20"
406
+ fill="currentColor"
407
+ xmlns="http://www.w3.org/2000/svg"
408
+ aria-label="account"
409
+ >
410
+ <path
411
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
412
+ />
413
+ </svg>
414
+ </ic-chip>
415
+ <ic-chip
416
+ label="Really long name for a chip that should wrap"
417
+ dismissible="true"
418
+ style="max-width: 150px"
419
+ >
420
+ <svg
421
+ slot="icon"
422
+ width="20"
423
+ height="20"
424
+ viewBox="0 0 20 20"
425
+ fill="currentColor"
426
+ xmlns="http://www.w3.org/2000/svg"
427
+ aria-label="account"
428
+ >
429
+ <path
430
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
431
+ />
432
+ </svg>
433
+ </ic-chip>
434
+ <ic-chip
435
+ label="Really long name for a chip that should wrap"
436
+ dismissible="true"
437
+ size="large"
438
+ style="max-width: 150px"
439
+ >
440
+ <svg
441
+ slot="icon"
442
+ width="20"
443
+ height="20"
444
+ viewBox="0 0 20 20"
445
+ fill="currentColor"
446
+ xmlns="http://www.w3.org/2000/svg"
447
+ aria-hidden="true"
448
+ >
449
+ <path
450
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
451
+ />
452
+ </svg>
453
+ </ic-chip>`,
454
+
455
+ name: "Long label",
456
+ };
457
+
458
+ export const WhiteBackground = {
459
+ render: () =>
460
+ html`<div
461
+ style="background-color:#2c2f34; padding:6px 10px; width:fit-content"
462
+ >
463
+ <ic-chip
464
+ label="White background"
465
+ variant="outlined"
466
+ transparent-background="false"
467
+ >
468
+ <svg
469
+ slot="icon"
470
+ width="20"
471
+ height="20"
472
+ viewBox="0 0 20 20"
473
+ fill="currentColor"
474
+ xmlns="http://www.w3.org/2000/svg"
475
+ aria-label="account"
476
+ >
477
+ <path
478
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
479
+ />
480
+ </svg>
481
+ </ic-chip>
482
+ <ic-chip
483
+ label="White background"
484
+ dismissible="true"
485
+ variant="outlined"
486
+ transparent-background="false"
487
+ >
488
+ <svg
489
+ slot="icon"
490
+ width="20"
491
+ height="20"
492
+ viewBox="0 0 20 20"
493
+ fill="currentColor"
494
+ xmlns="http://www.w3.org/2000/svg"
495
+ aria-hidden="true"
496
+ >
497
+ <path
498
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
499
+ />
500
+ </svg>
501
+ </ic-chip>
502
+ </div>`,
503
+
504
+ name: "White background",
505
+ };
506
+
507
+ export const CustomColour = {
508
+ render: () => html`
509
+ <ic-chip label="Default" custom-color="#F8C8DC">
510
+ <svg
511
+ slot="icon"
512
+ width="20"
513
+ height="20"
514
+ viewBox="0 0 20 20"
515
+ fill="currentColor"
516
+ xmlns="http://www.w3.org/2000/svg"
517
+ aria-label="account"
518
+ >
519
+ <path
520
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
521
+ />
522
+ </svg>
523
+ </ic-chip>
524
+ <ic-chip label="Label" variant="outlined" custom-color="#F8C8DC">
525
+ <svg
526
+ slot="icon"
527
+ width="20"
528
+ height="20"
529
+ viewBox="0 0 20 20"
530
+ fill="currentColor"
531
+ xmlns="http://www.w3.org/2000/svg"
532
+ aria-label="account"
533
+ >
534
+ <path
535
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
536
+ />
537
+ </svg>
538
+ </ic-chip>
539
+ <ic-chip
540
+ label="Label"
541
+ variant="outlined"
542
+ transparent-background="false"
543
+ custom-color="#F8C8DC"
544
+ >
545
+ <svg
546
+ slot="icon"
547
+ width="20"
548
+ height="20"
549
+ viewBox="0 0 20 20"
550
+ fill="currentColor"
551
+ xmlns="http://www.w3.org/2000/svg"
552
+ aria-label="account"
553
+ >
554
+ <path
555
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
556
+ />
557
+ </svg>
558
+ </ic-chip>
559
+ `,
560
+
561
+ name: "Custom colour",
562
+ };
563
+
564
+ export const SwitchColour = {
565
+ render: () => html`
566
+ <ic-chip label="Default" custom-color="#F8C8DC">
567
+ <svg
568
+ slot="icon"
569
+ width="20"
570
+ height="20"
571
+ viewBox="0 0 20 20"
572
+ fill="currentColor"
573
+ xmlns="http://www.w3.org/2000/svg"
574
+ aria-label="account"
575
+ >
576
+ <path
577
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
578
+ />
579
+ </svg>
580
+ </ic-chip>
581
+ <br />
582
+ <br />
583
+ <ic-button
584
+ variant="primary"
585
+ id="default-btn"
586
+ onClick="document.querySelector('ic-chip').customColor='#F8C8DC'"
587
+ >
588
+ Colour 1
589
+ </ic-button>
590
+ <ic-button
591
+ variant="primary"
592
+ id="custom-btn"
593
+ onClick="document.querySelector('ic-chip').customColor='#00008B'"
594
+ >
595
+ Colour 2
596
+ </ic-button>
597
+ `,
598
+
599
+ name: "Switch colour",
600
+ };
601
+
602
+ export const Playground = {
603
+ render: (args) =>
604
+ html`<ic-chip
605
+ label=${args.label}
606
+ custom-color=${args.customColor}
607
+ dismissible=${args.dismissible}
608
+ disabled=${args.disabled}
609
+ size=${args.size}
610
+ variant=${args.variant}
611
+ transparent-background=${args.transparentBackground}
612
+ dismiss-label=${args.dismissLabel}
613
+ >
614
+ <svg
615
+ slot="icon"
616
+ width="20"
617
+ height="20"
618
+ viewBox="0 0 20 20"
619
+ fill="currentColor"
620
+ xmlns="http://www.w3.org/2000/svg"
621
+ aria-label="account"
622
+ >
623
+ <path
624
+ d="M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z"
625
+ />
626
+ </svg>
627
+ <ic-badge
628
+ text-label="1"
629
+ slot=${args.badgeSlot}
630
+ variant="success"
631
+ position="near"
632
+ ></ic-badge>
633
+ </ic-chip>`,
634
+
635
+ args: defaultArgs,
636
+
637
+ argTypes: {
638
+ customColor: {
639
+ control: {
640
+ type: "text",
641
+ },
642
+ },
643
+
644
+ size: {
645
+ options: ["small", "default", "large"],
646
+
647
+ control: {
648
+ type: "radio",
649
+ },
650
+ },
651
+
652
+ variant: {
653
+ options: ["filled", "outlined"],
654
+
655
+ control: {
656
+ type: "inline-radio",
657
+ },
658
+ },
659
+
660
+ badgeSlot: {
661
+ options: ["badge", ""],
662
+
663
+ control: {
664
+ type: "select",
665
+ },
666
+ },
667
+ },
668
+
669
+ name: "Playground",
670
+ };