@ukic/web-components 2.35.0 → 2.35.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/dist/cjs/core.cjs.js +1 -1
- package/dist/cjs/ic-badge.cjs.entry.js +23 -0
- package/dist/cjs/ic-badge.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-button_3.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-button.cjs.entry.js +2 -2
- package/dist/cjs/ic-navigation-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-item.cjs.entry.js +1 -1
- package/dist/cjs/ic-navigation-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-toast.cjs.entry.js +2 -2
- package/dist/cjs/ic-toast.cjs.entry.js.map +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/ic-accordion/ic-accordion.stories.js +635 -0
- package/dist/collection/components/ic-alert/ic-alert.stories.js +257 -0
- package/dist/collection/components/ic-back-to-top/ic-back-to-top.stories.js +162 -0
- package/dist/collection/components/ic-badge/ic-badge.js +39 -1
- package/dist/collection/components/ic-badge/ic-badge.js.map +1 -1
- package/dist/collection/components/ic-badge/ic-badge.stories.js +1082 -0
- package/dist/collection/components/ic-badge/test/basic/ic-badge.spec.js +194 -0
- package/dist/collection/components/ic-badge/test/basic/ic-badge.spec.js.map +1 -1
- package/dist/collection/components/ic-breadcrumb-group/ic-breadcrumb-group.stories.js +502 -0
- package/dist/collection/components/ic-button/ic-button.stories.js +2218 -0
- package/dist/collection/components/ic-card/ic-card.stories.js +1034 -0
- package/dist/collection/components/ic-checkbox-group/ic-checkbox-group.stories.js +687 -0
- package/dist/collection/components/ic-chip/ic-chip.stories.js +670 -0
- package/dist/collection/components/ic-classification-banner/ic-classification-banner.stories.js +131 -0
- package/dist/collection/components/ic-data-entity/ic-data-entity.stories.js +487 -0
- package/dist/collection/components/ic-dialog/ic-dialog.stories.js +1256 -0
- package/dist/collection/components/ic-empty-state/ic-empty-state.stories.js +397 -0
- package/dist/collection/components/ic-footer/ic-footer.stories.js +383 -0
- package/dist/collection/components/ic-hero/ic-hero.stories.js +489 -0
- package/dist/collection/components/ic-link/ic-link.stories.js +114 -0
- package/dist/collection/components/ic-loading-indicator/ic-loading-indicator.stories.js +416 -0
- package/dist/collection/components/ic-navigation-button/ic-navigation-button.css +4 -0
- package/dist/collection/components/ic-navigation-button/ic-navigation-button.js +1 -1
- package/dist/collection/components/ic-navigation-button/ic-navigation-button.js.map +1 -1
- package/dist/collection/components/ic-navigation-item/ic-navigation-item.css +7 -35
- package/dist/collection/components/ic-page-header/ic-page-header.stories.js +557 -0
- package/dist/collection/components/ic-pagination/ic-pagination.stories.js +125 -0
- package/dist/collection/components/ic-popover-menu/ic-popover-menu.stories.js +486 -0
- package/dist/collection/components/ic-radio-group/ic-radio-group.stories.js +450 -0
- package/dist/collection/components/ic-search-bar/ic-search-bar.stories.js +591 -0
- package/dist/collection/components/ic-section-container/ic-section-container.stories.js +62 -0
- package/dist/collection/components/ic-select/ic-select-searchable.stories.js +953 -0
- package/dist/collection/components/ic-select/ic-select-single.stories.js +780 -0
- package/dist/collection/components/ic-side-navigation/ic-side-navigation.stories.js +2526 -0
- package/dist/collection/components/ic-skeleton/ic-skeleton.stories.js +141 -0
- package/dist/collection/components/ic-status-tag/ic-status-tag.stories.js +161 -0
- package/dist/collection/components/ic-stepper/ic-stepper.stories.js +327 -0
- package/dist/collection/components/ic-switch/ic-switch.stories.js +171 -0
- package/dist/collection/components/ic-tab-context/ic-tabs.stories.js +388 -0
- package/dist/collection/components/ic-text-field/ic-text-field.stories.js +1083 -0
- package/dist/collection/components/ic-theme/ic-theme.stories.js +171 -0
- package/dist/collection/components/ic-toast/ic-toast.js +2 -2
- package/dist/collection/components/ic-toast/ic-toast.js.map +1 -1
- package/dist/collection/components/ic-toast/ic-toast.stories.js +413 -0
- package/dist/collection/components/ic-toast/test/basic/ic-toast.spec.js +3 -3
- package/dist/collection/components/ic-toast/test/basic/ic-toast.spec.js.map +1 -1
- package/dist/collection/components/ic-toggle-button/ic-toggle-button.stories.js +537 -0
- package/dist/collection/components/ic-toggle-button-group/ic-toggle-button-group.stories.js +610 -0
- package/dist/collection/components/ic-tooltip/ic-tooltip.js +2 -5
- package/dist/collection/components/ic-tooltip/ic-tooltip.js.map +1 -1
- package/dist/collection/components/ic-tooltip/ic-tooltip.stories.js +356 -0
- package/dist/collection/components/ic-top-navigation/ic-top-navigation.stories.js +1083 -0
- package/dist/collection/components/ic-typography/ic-typography.stories.js +437 -0
- package/dist/collection/patterns/top-nav-content-footer.stories.js +109 -0
- package/dist/collection/patterns/z-index.stories.js +474 -0
- package/dist/components/ic-badge.js +25 -2
- package/dist/components/ic-badge.js.map +1 -1
- package/dist/components/ic-navigation-button.js +2 -2
- package/dist/components/ic-navigation-button.js.map +1 -1
- package/dist/components/ic-navigation-item.js +1 -1
- package/dist/components/ic-navigation-item.js.map +1 -1
- package/dist/components/ic-toast.js +2 -2
- package/dist/components/ic-toast.js.map +1 -1
- package/dist/components/ic-tooltip2.js.map +1 -1
- package/dist/core/core.esm.js +1 -1
- package/dist/core/core.esm.js.map +1 -1
- package/dist/core/p-3e8023ff.entry.js +2 -0
- package/dist/core/p-3e8023ff.entry.js.map +1 -0
- package/dist/core/p-ba06cc95.entry.js.map +1 -1
- package/dist/core/{p-7e8a4abd.entry.js → p-bfaa257c.entry.js} +2 -2
- package/dist/core/{p-7e8a4abd.entry.js.map → p-bfaa257c.entry.js.map} +1 -1
- package/dist/core/p-c05474f3.entry.js +2 -0
- package/dist/core/p-c05474f3.entry.js.map +1 -0
- package/dist/core/{p-5d3c6ea1.entry.js → p-d0299926.entry.js} +2 -2
- package/dist/core/p-d0299926.entry.js.map +1 -0
- package/dist/esm/core.js +1 -1
- package/dist/esm/ic-badge.entry.js +23 -0
- package/dist/esm/ic-badge.entry.js.map +1 -1
- package/dist/esm/ic-button_3.entry.js.map +1 -1
- package/dist/esm/ic-navigation-button.entry.js +2 -2
- package/dist/esm/ic-navigation-button.entry.js.map +1 -1
- package/dist/esm/ic-navigation-item.entry.js +1 -1
- package/dist/esm/ic-navigation-item.entry.js.map +1 -1
- package/dist/esm/ic-toast.entry.js +2 -2
- package/dist/esm/ic-toast.entry.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/ic-badge/ic-badge.d.ts +5 -0
- package/dist/types/components/ic-tooltip/ic-tooltip.d.ts +1 -1
- package/dist/types/components.d.ts +7 -0
- package/hydrate/index.js +30 -7
- package/package.json +17 -12
- package/vscode-data.json +4 -0
- package/dist/core/p-405d89bb.entry.js +0 -2
- package/dist/core/p-405d89bb.entry.js.map +0 -1
- package/dist/core/p-5d3c6ea1.entry.js.map +0 -1
- package/dist/core/p-dfb3e76e.entry.js +0 -2
- package/dist/core/p-dfb3e76e.entry.js.map +0 -1
@@ -0,0 +1,397 @@
|
|
1
|
+
import { html } from "lit-html";
|
2
|
+
|
3
|
+
const defaultArgs = {
|
4
|
+
aligned: "left",
|
5
|
+
body: "This is the body text for the empty state.",
|
6
|
+
bodyMaxLines: 3,
|
7
|
+
heading: "This is the heading",
|
8
|
+
imageSize: "default",
|
9
|
+
subheading: "This is the subheading",
|
10
|
+
showImage: false,
|
11
|
+
showActions: false,
|
12
|
+
};
|
13
|
+
|
14
|
+
export default {
|
15
|
+
title: "Web Components/Empty state",
|
16
|
+
component: "ic-empty-state",
|
17
|
+
};
|
18
|
+
|
19
|
+
export const WithSubheadingAndBodyText = {
|
20
|
+
render: () =>
|
21
|
+
html`<ic-empty-state
|
22
|
+
heading="Empty state title"
|
23
|
+
subheading="Empty state subtitle"
|
24
|
+
body="Body text for the empty state."
|
25
|
+
></ic-empty-state>`,
|
26
|
+
|
27
|
+
name: "With subheading and body text",
|
28
|
+
};
|
29
|
+
|
30
|
+
export const WithActions = {
|
31
|
+
render: () =>
|
32
|
+
html`<ic-empty-state
|
33
|
+
heading="Empty state title"
|
34
|
+
subheading="Empty state subtitle"
|
35
|
+
body="Body text for the empty state."
|
36
|
+
>
|
37
|
+
<ic-button slot="actions">Action</ic-button>
|
38
|
+
<ic-link href="/" slot="actions">Standalone link</ic-link></ic-empty-state
|
39
|
+
>`,
|
40
|
+
|
41
|
+
name: "With actions",
|
42
|
+
};
|
43
|
+
|
44
|
+
export const WithImage = {
|
45
|
+
render: () => html`<ic-empty-state
|
46
|
+
heading="Empty state title"
|
47
|
+
subheading="Empty state subtitle"
|
48
|
+
body="Body text for the empty state."
|
49
|
+
>
|
50
|
+
<svg
|
51
|
+
slot="image"
|
52
|
+
height:326px;width:326px;"
|
53
|
+
xmlns="http://www.w3.org/2000/svg"
|
54
|
+
viewBox="0 0 1600 900"
|
55
|
+
>
|
56
|
+
<rect fill="#ff7700" width="1600" height="1600" y="-350" />
|
57
|
+
<polygon fill="#cc0000" points="957 450 539 900 1396 900" />
|
58
|
+
<polygon fill="#aa0000" points="957 450 872.9 900 1396 900" />
|
59
|
+
<polygon fill="#c50022" points="-60 900 398 662 816 900" />
|
60
|
+
<polygon fill="#a3001b" points="337 900 398 662 816 900" />
|
61
|
+
<polygon fill="#be0044" points="1203 546 1552 900 876 900" />
|
62
|
+
<polygon fill="#9c0036" points="1203 546 1552 900 1162 900" />
|
63
|
+
<polygon fill="#b80066" points="641 695 886 900 367 900" />
|
64
|
+
<polygon fill="#960052" points="587 900 641 695 886 900" />
|
65
|
+
<polygon fill="#b10088" points="1710 900 1401 632 1096 900" />
|
66
|
+
<polygon fill="#8f006d" points="1710 900 1401 632 1365 900" />
|
67
|
+
<polygon fill="#aa00aa" points="1210 900 971 687 725 900" />
|
68
|
+
<polygon fill="#880088" points="943 900 1210 900 971 687" /></svg
|
69
|
+
></ic-empty-state>`,
|
70
|
+
|
71
|
+
name: "With image",
|
72
|
+
};
|
73
|
+
|
74
|
+
export const WithSmallImage = {
|
75
|
+
render: () => html`<ic-empty-state
|
76
|
+
heading="Empty state title"
|
77
|
+
subheading="Empty state subtitle"
|
78
|
+
body="Body text for empty state."
|
79
|
+
image-size="small"
|
80
|
+
>
|
81
|
+
<svg
|
82
|
+
slot="image"
|
83
|
+
height:326px;width:326px;"
|
84
|
+
xmlns="http://www.w3.org/2000/svg"
|
85
|
+
viewBox="0 0 1600 900"
|
86
|
+
>
|
87
|
+
<rect fill="#ff7700" width="1600" height="1600" y="-350" />
|
88
|
+
<polygon fill="#cc0000" points="957 450 539 900 1396 900" />
|
89
|
+
<polygon fill="#aa0000" points="957 450 872.9 900 1396 900" />
|
90
|
+
<polygon fill="#c50022" points="-60 900 398 662 816 900" />
|
91
|
+
<polygon fill="#a3001b" points="337 900 398 662 816 900" />
|
92
|
+
<polygon fill="#be0044" points="1203 546 1552 900 876 900" />
|
93
|
+
<polygon fill="#9c0036" points="1203 546 1552 900 1162 900" />
|
94
|
+
<polygon fill="#b80066" points="641 695 886 900 367 900" />
|
95
|
+
<polygon fill="#960052" points="587 900 641 695 886 900" />
|
96
|
+
<polygon fill="#b10088" points="1710 900 1401 632 1096 900" />
|
97
|
+
<polygon fill="#8f006d" points="1710 900 1401 632 1365 900" />
|
98
|
+
<polygon fill="#aa00aa" points="1210 900 971 687 725 900" />
|
99
|
+
<polygon fill="#880088" points="943 900 1210 900 971 687" /></svg
|
100
|
+
></ic-empty-state>`,
|
101
|
+
|
102
|
+
name: "With small image",
|
103
|
+
};
|
104
|
+
|
105
|
+
export const WithLargeImage = {
|
106
|
+
render: () =>
|
107
|
+
html`<ic-empty-state
|
108
|
+
heading="Empty state title"
|
109
|
+
subheading="Empty state subtitle"
|
110
|
+
body="Body text for empty state."
|
111
|
+
image-size="large"
|
112
|
+
>
|
113
|
+
<svg
|
114
|
+
slot="image"
|
115
|
+
style="height:326px;width:326px;"
|
116
|
+
xmlns="http://www.w3.org/2000/svg"
|
117
|
+
viewBox="0 0 1600 900"
|
118
|
+
>
|
119
|
+
<rect fill="#ff7700" width="1600" height="1600" y="-350" />
|
120
|
+
<polygon fill="#cc0000" points="957 450 539 900 1396 900" />
|
121
|
+
<polygon fill="#aa0000" points="957 450 872.9 900 1396 900" />
|
122
|
+
<polygon fill="#c50022" points="-60 900 398 662 816 900" />
|
123
|
+
<polygon fill="#a3001b" points="337 900 398 662 816 900" />
|
124
|
+
<polygon fill="#be0044" points="1203 546 1552 900 876 900" />
|
125
|
+
<polygon fill="#9c0036" points="1203 546 1552 900 1162 900" />
|
126
|
+
<polygon fill="#b80066" points="641 695 886 900 367 900" />
|
127
|
+
<polygon fill="#960052" points="587 900 641 695 886 900" />
|
128
|
+
<polygon fill="#b10088" points="1710 900 1401 632 1096 900" />
|
129
|
+
<polygon fill="#8f006d" points="1710 900 1401 632 1365 900" />
|
130
|
+
<polygon fill="#aa00aa" points="1210 900 971 687 725 900" />
|
131
|
+
<polygon fill="#880088" points="943 900 1210 900 971 687" /></svg
|
132
|
+
></ic-empty-state>`,
|
133
|
+
|
134
|
+
name: "With large image",
|
135
|
+
};
|
136
|
+
|
137
|
+
export const WithIcon = {
|
138
|
+
render: () =>
|
139
|
+
html`<ic-empty-state
|
140
|
+
heading="Empty state title"
|
141
|
+
subheading="Empty state subtitle"
|
142
|
+
body="Body text for the empty state."
|
143
|
+
>
|
144
|
+
<svg
|
145
|
+
slot="image"
|
146
|
+
aria-labelledby="warning-title"
|
147
|
+
xmlns="http://www.w3.org/2000/svg"
|
148
|
+
viewBox="0 0 24 24"
|
149
|
+
fill="#D07932"
|
150
|
+
>
|
151
|
+
<title id="warning-title">Warning</title>
|
152
|
+
<path d="M0 0h24v24H0z" fill="none" />
|
153
|
+
<path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z" />
|
154
|
+
</svg>
|
155
|
+
</ic-empty-state>`,
|
156
|
+
|
157
|
+
name: "With icon",
|
158
|
+
};
|
159
|
+
|
160
|
+
export const CentreAligned = {
|
161
|
+
render: () =>
|
162
|
+
html`<ic-empty-state
|
163
|
+
heading="Empty state title"
|
164
|
+
subheading="Empty state subtitle"
|
165
|
+
body="Body text for empty state."
|
166
|
+
aligned="center"
|
167
|
+
>
|
168
|
+
<svg
|
169
|
+
slot="image"
|
170
|
+
style="height:326px;width:326px;"
|
171
|
+
xmlns="http://www.w3.org/2000/svg"
|
172
|
+
viewBox="0 0 1600 900"
|
173
|
+
>
|
174
|
+
<rect fill="#ff7700" width="1600" height="1600" y="-350" />
|
175
|
+
<polygon fill="#cc0000" points="957 450 539 900 1396 900" />
|
176
|
+
<polygon fill="#aa0000" points="957 450 872.9 900 1396 900" />
|
177
|
+
<polygon fill="#c50022" points="-60 900 398 662 816 900" />
|
178
|
+
<polygon fill="#a3001b" points="337 900 398 662 816 900" />
|
179
|
+
<polygon fill="#be0044" points="1203 546 1552 900 876 900" />
|
180
|
+
<polygon fill="#9c0036" points="1203 546 1552 900 1162 900" />
|
181
|
+
<polygon fill="#b80066" points="641 695 886 900 367 900" />
|
182
|
+
<polygon fill="#960052" points="587 900 641 695 886 900" />
|
183
|
+
<polygon fill="#b10088" points="1710 900 1401 632 1096 900" />
|
184
|
+
<polygon fill="#8f006d" points="1710 900 1401 632 1365 900" />
|
185
|
+
<polygon fill="#aa00aa" points="1210 900 971 687 725 900" />
|
186
|
+
<polygon fill="#880088" points="943 900 1210 900 971 687" /></svg
|
187
|
+
><ic-button slot="actions">Action</ic-button>
|
188
|
+
<ic-link href="/" slot="actions">Standalone link</ic-link></ic-empty-state
|
189
|
+
>`,
|
190
|
+
|
191
|
+
name: "Centre aligned",
|
192
|
+
};
|
193
|
+
|
194
|
+
export const RightAligned = {
|
195
|
+
render: () =>
|
196
|
+
html`<ic-empty-state
|
197
|
+
heading="Empty state title"
|
198
|
+
subheading="Empty state subtitle"
|
199
|
+
body="Body text for empty state."
|
200
|
+
aligned="right"
|
201
|
+
>
|
202
|
+
<svg
|
203
|
+
slot="image"
|
204
|
+
style="height:326px;width:326px;"
|
205
|
+
xmlns="http://www.w3.org/2000/svg"
|
206
|
+
viewBox="0 0 1600 900"
|
207
|
+
>
|
208
|
+
<rect fill="#ff7700" width="1600" height="1600" y="-350" />
|
209
|
+
<polygon fill="#cc0000" points="957 450 539 900 1396 900" />
|
210
|
+
<polygon fill="#aa0000" points="957 450 872.9 900 1396 900" />
|
211
|
+
<polygon fill="#c50022" points="-60 900 398 662 816 900" />
|
212
|
+
<polygon fill="#a3001b" points="337 900 398 662 816 900" />
|
213
|
+
<polygon fill="#be0044" points="1203 546 1552 900 876 900" />
|
214
|
+
<polygon fill="#9c0036" points="1203 546 1552 900 1162 900" />
|
215
|
+
<polygon fill="#b80066" points="641 695 886 900 367 900" />
|
216
|
+
<polygon fill="#960052" points="587 900 641 695 886 900" />
|
217
|
+
<polygon fill="#b10088" points="1710 900 1401 632 1096 900" />
|
218
|
+
<polygon fill="#8f006d" points="1710 900 1401 632 1365 900" />
|
219
|
+
<polygon fill="#aa00aa" points="1210 900 971 687 725 900" />
|
220
|
+
<polygon fill="#880088" points="943 900 1210 900 971 687" /></svg
|
221
|
+
><ic-button slot="actions">Action</ic-button>
|
222
|
+
<ic-link href="/" slot="actions">Standalone link</ic-link></ic-empty-state
|
223
|
+
>`,
|
224
|
+
|
225
|
+
name: "Right aligned",
|
226
|
+
};
|
227
|
+
|
228
|
+
export const MaxLines = {
|
229
|
+
render: () =>
|
230
|
+
html`<ic-empty-state
|
231
|
+
heading="Empty state title"
|
232
|
+
subheading="Empty state subtitle"
|
233
|
+
body="Body of text that is truncated to two lines. Click the 'See more' link to expand the text, then click 'See less' to truncate the text once more!
|
234
|
+
Dripper caramelization java saucer grounds galão, mocha, and robusta kopi-luwak, percolator, instant, qui saucer latte in brewed café au lait. Con panna, cup, cream, body americano affogato cup espresso, rich milk seasonal saucer grinder spoon that cultivar strong redeye frappuccino barista extraction redeye mazagran. Grounds, french press dripper organic and foam id saucer, crema, black rich dark, grounds breve coffee steamed caramelization percolator."
|
235
|
+
body-max-lines="2"
|
236
|
+
>
|
237
|
+
<svg
|
238
|
+
slot="image"
|
239
|
+
style="height:326px;width:326px;"
|
240
|
+
xmlns="http://www.w3.org/2000/svg"
|
241
|
+
viewBox="0 0 1600 900"
|
242
|
+
>
|
243
|
+
<rect fill="#ff7700" width="1600" height="1600" y="-350" />
|
244
|
+
<polygon fill="#cc0000" points="957 450 539 900 1396 900" />
|
245
|
+
<polygon fill="#aa0000" points="957 450 872.9 900 1396 900" />
|
246
|
+
<polygon fill="#c50022" points="-60 900 398 662 816 900" />
|
247
|
+
<polygon fill="#a3001b" points="337 900 398 662 816 900" />
|
248
|
+
<polygon fill="#be0044" points="1203 546 1552 900 876 900" />
|
249
|
+
<polygon fill="#9c0036" points="1203 546 1552 900 1162 900" />
|
250
|
+
<polygon fill="#b80066" points="641 695 886 900 367 900" />
|
251
|
+
<polygon fill="#960052" points="587 900 641 695 886 900" />
|
252
|
+
<polygon fill="#b10088" points="1710 900 1401 632 1096 900" />
|
253
|
+
<polygon fill="#8f006d" points="1710 900 1401 632 1365 900" />
|
254
|
+
<polygon fill="#aa00aa" points="1210 900 971 687 725 900" />
|
255
|
+
<polygon fill="#880088" points="943 900 1210 900 971 687" /></svg
|
256
|
+
><ic-button slot="actions">Action</ic-button>
|
257
|
+
<ic-link href="/" slot="actions">Standalone link</ic-link></ic-empty-state
|
258
|
+
>`,
|
259
|
+
|
260
|
+
name: "Max lines",
|
261
|
+
};
|
262
|
+
|
263
|
+
export const SlottedContent = {
|
264
|
+
render: () =>
|
265
|
+
html`<ic-empty-state>
|
266
|
+
<ic-typography slot="heading" variant="h4">
|
267
|
+
Empty state title
|
268
|
+
</ic-typography>
|
269
|
+
<ic-typography slot="subheading" variant="subtitle-small">
|
270
|
+
Empty state subtitle
|
271
|
+
</ic-typography>
|
272
|
+
<ic-typography slot="body"> Body text for empty state. </ic-typography>
|
273
|
+
<svg
|
274
|
+
slot="image"
|
275
|
+
style="height:326px;width:326px;"
|
276
|
+
xmlns="http://www.w3.org/2000/svg"
|
277
|
+
viewBox="0 0 1600 900"
|
278
|
+
>
|
279
|
+
<rect fill="#ff7700" width="1600" height="1600" y="-350" />
|
280
|
+
<polygon fill="#cc0000" points="957 450 539 900 1396 900" />
|
281
|
+
<polygon fill="#aa0000" points="957 450 872.9 900 1396 900" />
|
282
|
+
<polygon fill="#c50022" points="-60 900 398 662 816 900" />
|
283
|
+
<polygon fill="#a3001b" points="337 900 398 662 816 900" />
|
284
|
+
<polygon fill="#be0044" points="1203 546 1552 900 876 900" />
|
285
|
+
<polygon fill="#9c0036" points="1203 546 1552 900 1162 900" />
|
286
|
+
<polygon fill="#b80066" points="641 695 886 900 367 900" />
|
287
|
+
<polygon fill="#960052" points="587 900 641 695 886 900" />
|
288
|
+
<polygon fill="#b10088" points="1710 900 1401 632 1096 900" />
|
289
|
+
<polygon fill="#8f006d" points="1710 900 1401 632 1365 900" />
|
290
|
+
<polygon fill="#aa00aa" points="1210 900 971 687 725 900" />
|
291
|
+
<polygon fill="#880088" points="943 900 1210 900 971 687" /></svg
|
292
|
+
><ic-button slot="actions">Action</ic-button>
|
293
|
+
<ic-link href="/" slot="actions">Standalone link</ic-link></ic-empty-state
|
294
|
+
>`,
|
295
|
+
|
296
|
+
name: "Slotted content",
|
297
|
+
};
|
298
|
+
|
299
|
+
export const WithinDiv = {
|
300
|
+
render: () =>
|
301
|
+
html`<div style="width:357px;border:1px solid black;background:#D3D3D3;">
|
302
|
+
<ic-empty-state
|
303
|
+
heading="Empty state title"
|
304
|
+
subheading="Empty state subtitle"
|
305
|
+
body="Body text for empty state."
|
306
|
+
>
|
307
|
+
<svg
|
308
|
+
slot="image"
|
309
|
+
style="height:326px;width:326px;"
|
310
|
+
xmlns="http://www.w3.org/2000/svg"
|
311
|
+
viewBox="0 0 1600 900"
|
312
|
+
>
|
313
|
+
<rect fill="#ff7700" width="1600" height="1600" y="-350" />
|
314
|
+
<polygon fill="#cc0000" points="957 450 539 900 1396 900" />
|
315
|
+
<polygon fill="#aa0000" points="957 450 872.9 900 1396 900" />
|
316
|
+
<polygon fill="#c50022" points="-60 900 398 662 816 900" />
|
317
|
+
<polygon fill="#a3001b" points="337 900 398 662 816 900" />
|
318
|
+
<polygon fill="#be0044" points="1203 546 1552 900 876 900" />
|
319
|
+
<polygon fill="#9c0036" points="1203 546 1552 900 1162 900" />
|
320
|
+
<polygon fill="#b80066" points="641 695 886 900 367 900" />
|
321
|
+
<polygon fill="#960052" points="587 900 641 695 886 900" />
|
322
|
+
<polygon fill="#b10088" points="1710 900 1401 632 1096 900" />
|
323
|
+
<polygon fill="#8f006d" points="1710 900 1401 632 1365 900" />
|
324
|
+
<polygon fill="#aa00aa" points="1210 900 971 687 725 900" />
|
325
|
+
<polygon fill="#880088" points="943 900 1210 900 971 687" /></svg
|
326
|
+
><ic-button slot="actions">Action</ic-button>
|
327
|
+
<ic-link href="/" slot="actions"
|
328
|
+
>Standalone link</ic-link
|
329
|
+
></ic-empty-state
|
330
|
+
>
|
331
|
+
</div>`,
|
332
|
+
|
333
|
+
name: "Within div",
|
334
|
+
};
|
335
|
+
|
336
|
+
export const Playground = {
|
337
|
+
render: (args) =>
|
338
|
+
html`<ic-empty-state
|
339
|
+
heading=${args.heading}
|
340
|
+
subheading=${args.subheading}
|
341
|
+
body=${args.body}
|
342
|
+
image-size=${args.imageSize}
|
343
|
+
body-max-lines=${args.bodyMaxLines}
|
344
|
+
aligned=${args.aligned}
|
345
|
+
>
|
346
|
+
${args.showImage &&
|
347
|
+
html`
|
348
|
+
<svg
|
349
|
+
slot="image"
|
350
|
+
height:326px;width:326px;"
|
351
|
+
xmlns="http://www.w3.org/2000/svg"
|
352
|
+
viewBox="0 0 1600 900"
|
353
|
+
>
|
354
|
+
<rect fill="#ff7700" width="1600" height="1600" y="-350" />
|
355
|
+
<polygon fill="#cc0000" points="957 450 539 900 1396 900" />
|
356
|
+
<polygon fill="#aa0000" points="957 450 872.9 900 1396 900" />
|
357
|
+
<polygon fill="#c50022" points="-60 900 398 662 816 900" />
|
358
|
+
<polygon fill="#a3001b" points="337 900 398 662 816 900" />
|
359
|
+
<polygon fill="#be0044" points="1203 546 1552 900 876 900" />
|
360
|
+
<polygon fill="#9c0036" points="1203 546 1552 900 1162 900" />
|
361
|
+
<polygon fill="#b80066" points="641 695 886 900 367 900" />
|
362
|
+
<polygon fill="#960052" points="587 900 641 695 886 900" />
|
363
|
+
<polygon fill="#b10088" points="1710 900 1401 632 1096 900" />
|
364
|
+
<polygon fill="#8f006d" points="1710 900 1401 632 1365 900" />
|
365
|
+
<polygon fill="#aa00aa" points="1210 900 971 687 725 900" />
|
366
|
+
<polygon fill="#880088" points="943 900 1210 900 971 687" />
|
367
|
+
</svg>
|
368
|
+
`}
|
369
|
+
${args.showActions &&
|
370
|
+
html`
|
371
|
+
<ic-button slot="actions">Action</ic-button>
|
372
|
+
<ic-link href="/" slot="actions">Standalone link</ic-link>
|
373
|
+
`}
|
374
|
+
</ic-empty-state>`,
|
375
|
+
|
376
|
+
args: defaultArgs,
|
377
|
+
|
378
|
+
argTypes: {
|
379
|
+
aligned: {
|
380
|
+
options: ["left", "center", "right"],
|
381
|
+
|
382
|
+
control: {
|
383
|
+
type: "radio",
|
384
|
+
},
|
385
|
+
},
|
386
|
+
|
387
|
+
imageSize: {
|
388
|
+
options: ["default", "small", "large"],
|
389
|
+
|
390
|
+
control: {
|
391
|
+
type: "radio",
|
392
|
+
},
|
393
|
+
},
|
394
|
+
},
|
395
|
+
|
396
|
+
name: "Playground",
|
397
|
+
};
|