@cypress-design/react-statusicon 0.4.6 → 0.4.8
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/.turbo/turbo-build.log +1 -1
- package/CHANGELOG.md +16 -0
- package/_OutlineStatusIcon.ts +1 -0
- package/_SimpleStatusIcon.ts +1 -0
- package/_SolidStatusIcon.ts +1 -0
- package/compileProps.ts +3 -0
- package/dist/_OutlineStatusIcon.d.ts.map +1 -1
- package/dist/_SimpleStatusIcon.d.ts.map +1 -1
- package/dist/_SolidStatusIcon.d.ts.map +1 -1
- package/dist/compileProps.d.ts +38 -31
- package/dist/compileProps.d.ts.map +1 -1
- package/dist/index.es.mjs +36 -8
- package/dist/index.es.mjs.map +1 -1
- package/dist/index.umd.js +36 -8
- package/dist/index.umd.js.map +1 -1
- package/package.json +2 -2
package/.turbo/turbo-build.log
CHANGED
|
@@ -8,5 +8,5 @@ $ rollup -c ./rollup.config.mjs
|
|
|
8
8
|
index.ts
|
|
9
9
|
|
|
10
10
|
Consumers of your bundle will have to use chunk.default to access their default export, which may not be what you want. Use `output.exports: "named"` to disable this warning.
|
|
11
|
-
[32mcreated [1m./dist/index.umd.js, ./dist/index.es.mjs[22m in [
|
|
11
|
+
[32mcreated [1m./dist/index.umd.js, ./dist/index.es.mjs[22m in [1m21.8s[22m[39m
|
|
12
12
|
$ tsc --project ./tsconfig.build.json
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @cypress-design/react-statusicon
|
|
2
2
|
|
|
3
|
+
## 0.4.8
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`e390827`](https://github.com/cypress-io/cypress-design/commit/e3908270ece513886c64cebcb78cebe0cd0d8c3d)]:
|
|
8
|
+
- @cypress-design/react-icon@0.23.0
|
|
9
|
+
|
|
10
|
+
## 0.4.7
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- [#234](https://github.com/cypress-io/cypress-design/pull/234) [`ff95963`](https://github.com/cypress-io/cypress-design/commit/ff95963feb7ae5d9eb01e6122e5e411517f105b9) Thanks [@elevatebart](https://github.com/elevatebart)! - allow to use a gradient icon more than once
|
|
15
|
+
|
|
16
|
+
- Updated dependencies [[`ff95963`](https://github.com/cypress-io/cypress-design/commit/ff95963feb7ae5d9eb01e6122e5e411517f105b9)]:
|
|
17
|
+
- @cypress-design/react-icon@0.22.2
|
|
18
|
+
|
|
3
19
|
## 0.4.6
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
package/_OutlineStatusIcon.ts
CHANGED
package/_SimpleStatusIcon.ts
CHANGED
package/_SolidStatusIcon.ts
CHANGED
package/compileProps.ts
CHANGED
|
@@ -11,9 +11,11 @@ export const compileProps = ({
|
|
|
11
11
|
statuses,
|
|
12
12
|
className,
|
|
13
13
|
size,
|
|
14
|
+
variantName,
|
|
14
15
|
}: VariantStatusIconProps & {
|
|
15
16
|
statuses: Record<string, IconSet>
|
|
16
17
|
className: string | undefined
|
|
18
|
+
variantName: string
|
|
17
19
|
}) => {
|
|
18
20
|
const statusInfo = status ? statuses[status] : statuses.placeholder
|
|
19
21
|
|
|
@@ -34,5 +36,6 @@ export const compileProps = ({
|
|
|
34
36
|
body: iconData,
|
|
35
37
|
compiledClasses: [...compiledClasses, classes],
|
|
36
38
|
size,
|
|
39
|
+
name: `status_${status}_${size}_${variantName}`,
|
|
37
40
|
})
|
|
38
41
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"_OutlineStatusIcon.d.ts","sourceRoot":"./","sources":["_OutlineStatusIcon.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAEhC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAA;AAGlF,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CACtC,sBAAsB,GAAG,QAAQ,CAAC,aAAa,CAAC,
|
|
1
|
+
{"version":3,"file":"_OutlineStatusIcon.d.ts","sourceRoot":"./","sources":["_OutlineStatusIcon.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAEhC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAA;AAGlF,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CACtC,sBAAsB,GAAG,QAAQ,CAAC,aAAa,CAAC,CAYjD,CAAA;AAED,eAAe,iBAAiB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"_SimpleStatusIcon.d.ts","sourceRoot":"./","sources":["_SimpleStatusIcon.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAEhC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAA;AAGlF,eAAO,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CACrC,sBAAsB,GAAG,QAAQ,CAAC,aAAa,CAAC,
|
|
1
|
+
{"version":3,"file":"_SimpleStatusIcon.d.ts","sourceRoot":"./","sources":["_SimpleStatusIcon.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAEhC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAA;AAGlF,eAAO,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CACrC,sBAAsB,GAAG,QAAQ,CAAC,aAAa,CAAC,CAYjD,CAAA;AAED,eAAe,gBAAgB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"_SolidStatusIcon.d.ts","sourceRoot":"./","sources":["_SolidStatusIcon.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAEhC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAA;AAGlF,eAAO,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CACpC,sBAAsB,GAAG,QAAQ,CAAC,aAAa,CAAC,
|
|
1
|
+
{"version":3,"file":"_SolidStatusIcon.d.ts","sourceRoot":"./","sources":["_SolidStatusIcon.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAEhC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAA;AAGlF,eAAO,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CACpC,sBAAsB,GAAG,QAAQ,CAAC,aAAa,CAAC,CAYjD,CAAA;AAED,eAAe,eAAe,CAAA"}
|
package/dist/compileProps.d.ts
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
/// <reference types="react" />
|
|
3
3
|
import type { IconSet, VariantStatusIconProps } from '@cypress-design/constants-statusicon';
|
|
4
|
-
export declare const compileProps: ({ status, statuses, className, size, }: VariantStatusIconProps & {
|
|
4
|
+
export declare const compileProps: ({ status, statuses, className, size, variantName, }: VariantStatusIconProps & {
|
|
5
5
|
statuses: Record<string, IconSet>;
|
|
6
6
|
className: string | undefined;
|
|
7
|
+
variantName: string;
|
|
7
8
|
}) => {
|
|
9
|
+
suppressHydrationWarning?: boolean | undefined;
|
|
8
10
|
className: string | undefined;
|
|
9
11
|
color?: string | undefined;
|
|
10
12
|
height: string | number;
|
|
@@ -24,8 +26,8 @@ export declare const compileProps: ({ status, statuses, className, size, }: Vari
|
|
|
24
26
|
crossOrigin?: "" | "anonymous" | "use-credentials" | undefined;
|
|
25
27
|
accentHeight?: string | number | undefined;
|
|
26
28
|
accumulate?: "none" | "sum" | undefined;
|
|
27
|
-
additive?: "
|
|
28
|
-
alignmentBaseline?: "alphabetic" | "hanging" | "ideographic" | "mathematical" | "
|
|
29
|
+
additive?: "sum" | "replace" | undefined;
|
|
30
|
+
alignmentBaseline?: "alphabetic" | "hanging" | "ideographic" | "mathematical" | "auto" | "baseline" | "before-edge" | "text-before-edge" | "middle" | "central" | "after-edge" | "text-after-edge" | "inherit" | undefined;
|
|
29
31
|
allowReorder?: "no" | "yes" | undefined;
|
|
30
32
|
alphabetic?: string | number | undefined;
|
|
31
33
|
amplitude?: string | number | undefined;
|
|
@@ -33,7 +35,7 @@ export declare const compileProps: ({ status, statuses, className, size, }: Vari
|
|
|
33
35
|
ascent?: string | number | undefined;
|
|
34
36
|
attributeName?: string | undefined;
|
|
35
37
|
attributeType?: string | undefined;
|
|
36
|
-
autoReverse?: boolean | "
|
|
38
|
+
autoReverse?: boolean | "true" | "false" | undefined;
|
|
37
39
|
azimuth?: string | number | undefined;
|
|
38
40
|
baseFrequency?: string | number | undefined;
|
|
39
41
|
baselineShift?: string | number | undefined;
|
|
@@ -49,7 +51,7 @@ export declare const compileProps: ({ status, statuses, className, size, }: Vari
|
|
|
49
51
|
clipPathUnits?: string | number | undefined;
|
|
50
52
|
clipRule?: string | number | undefined;
|
|
51
53
|
colorInterpolation?: string | number | undefined;
|
|
52
|
-
colorInterpolationFilters?: "
|
|
54
|
+
colorInterpolationFilters?: "auto" | "inherit" | "sRGB" | "linearRGB" | undefined;
|
|
53
55
|
colorProfile?: string | number | undefined;
|
|
54
56
|
colorRendering?: string | number | undefined;
|
|
55
57
|
contentScriptType?: string | number | undefined;
|
|
@@ -73,16 +75,16 @@ export declare const compileProps: ({ status, statuses, className, size, }: Vari
|
|
|
73
75
|
enableBackground?: string | number | undefined;
|
|
74
76
|
end?: string | number | undefined;
|
|
75
77
|
exponent?: string | number | undefined;
|
|
76
|
-
externalResourcesRequired?: boolean | "
|
|
78
|
+
externalResourcesRequired?: boolean | "true" | "false" | undefined;
|
|
77
79
|
fill: string;
|
|
78
80
|
fillOpacity?: string | number | undefined;
|
|
79
|
-
fillRule?: "inherit" | "
|
|
81
|
+
fillRule?: "inherit" | "nonzero" | "evenodd" | undefined;
|
|
80
82
|
filter?: string | undefined;
|
|
81
83
|
filterRes?: string | number | undefined;
|
|
82
84
|
filterUnits?: string | number | undefined;
|
|
83
85
|
floodColor?: string | number | undefined;
|
|
84
86
|
floodOpacity?: string | number | undefined;
|
|
85
|
-
focusable?: boolean | "auto" | "
|
|
87
|
+
focusable?: boolean | "auto" | "true" | "false" | undefined;
|
|
86
88
|
fontFamily?: string | undefined;
|
|
87
89
|
fontSize?: string | number | undefined;
|
|
88
90
|
fontSizeAdjust?: string | number | undefined;
|
|
@@ -162,7 +164,7 @@ export declare const compileProps: ({ status, statuses, className, size, }: Vari
|
|
|
162
164
|
pointsAtX?: string | number | undefined;
|
|
163
165
|
pointsAtY?: string | number | undefined;
|
|
164
166
|
pointsAtZ?: string | number | undefined;
|
|
165
|
-
preserveAlpha?: boolean | "
|
|
167
|
+
preserveAlpha?: boolean | "true" | "false" | undefined;
|
|
166
168
|
preserveAspectRatio?: string | undefined;
|
|
167
169
|
primitiveUnits?: string | number | undefined;
|
|
168
170
|
r?: string | number | undefined;
|
|
@@ -201,8 +203,8 @@ export declare const compileProps: ({ status, statuses, className, size, }: Vari
|
|
|
201
203
|
stroke?: string | undefined;
|
|
202
204
|
strokeDasharray?: string | number | undefined;
|
|
203
205
|
strokeDashoffset?: string | number | undefined;
|
|
204
|
-
strokeLinecap?: "inherit" | "
|
|
205
|
-
strokeLinejoin?: "inherit" | "round" | "
|
|
206
|
+
strokeLinecap?: "inherit" | "butt" | "round" | "square" | undefined;
|
|
207
|
+
strokeLinejoin?: "inherit" | "round" | "miter" | "bevel" | undefined;
|
|
206
208
|
strokeMiterlimit?: string | number | undefined;
|
|
207
209
|
strokeOpacity?: string | number | undefined;
|
|
208
210
|
strokeWidth?: string | number | undefined;
|
|
@@ -265,47 +267,52 @@ export declare const compileProps: ({ status, statuses, className, size, }: Vari
|
|
|
265
267
|
z?: string | number | undefined;
|
|
266
268
|
zoomAndPan?: string | undefined;
|
|
267
269
|
'aria-activedescendant'?: string | undefined;
|
|
268
|
-
'aria-atomic'?: boolean | "
|
|
269
|
-
'aria-autocomplete'?: "
|
|
270
|
-
'aria-
|
|
271
|
-
'aria-
|
|
270
|
+
'aria-atomic'?: boolean | "true" | "false" | undefined;
|
|
271
|
+
'aria-autocomplete'?: "list" | "none" | "inline" | "both" | undefined;
|
|
272
|
+
'aria-braillelabel'?: string | undefined;
|
|
273
|
+
'aria-brailleroledescription'?: string | undefined;
|
|
274
|
+
'aria-busy'?: boolean | "true" | "false" | undefined;
|
|
275
|
+
'aria-checked'?: boolean | "true" | "false" | "mixed" | undefined;
|
|
272
276
|
'aria-colcount'?: number | undefined;
|
|
273
277
|
'aria-colindex'?: number | undefined;
|
|
278
|
+
'aria-colindextext'?: string | undefined;
|
|
274
279
|
'aria-colspan'?: number | undefined;
|
|
275
280
|
'aria-controls'?: string | undefined;
|
|
276
|
-
'aria-current'?: boolean | "time" | "
|
|
281
|
+
'aria-current'?: boolean | "time" | "true" | "false" | "page" | "step" | "location" | "date" | undefined;
|
|
277
282
|
'aria-describedby'?: string | undefined;
|
|
283
|
+
'aria-description'?: string | undefined;
|
|
278
284
|
'aria-details'?: string | undefined;
|
|
279
|
-
'aria-disabled'?: boolean | "
|
|
280
|
-
'aria-dropeffect'?: "link" | "none" | "copy" | "
|
|
285
|
+
'aria-disabled'?: boolean | "true" | "false" | undefined;
|
|
286
|
+
'aria-dropeffect'?: "link" | "none" | "copy" | "execute" | "move" | "popup" | undefined;
|
|
281
287
|
'aria-errormessage'?: string | undefined;
|
|
282
|
-
'aria-expanded'?: boolean | "
|
|
288
|
+
'aria-expanded'?: boolean | "true" | "false" | undefined;
|
|
283
289
|
'aria-flowto'?: string | undefined;
|
|
284
|
-
'aria-grabbed'?: boolean | "
|
|
285
|
-
'aria-haspopup'?: boolean | "dialog" | "menu" | "
|
|
286
|
-
'aria-hidden'?: boolean | "
|
|
287
|
-
'aria-invalid'?: boolean | "
|
|
290
|
+
'aria-grabbed'?: boolean | "true" | "false" | undefined;
|
|
291
|
+
'aria-haspopup'?: boolean | "dialog" | "menu" | "grid" | "listbox" | "tree" | "true" | "false" | undefined;
|
|
292
|
+
'aria-hidden'?: boolean | "true" | "false" | undefined;
|
|
293
|
+
'aria-invalid'?: boolean | "true" | "false" | "grammar" | "spelling" | undefined;
|
|
288
294
|
'aria-keyshortcuts'?: string | undefined;
|
|
289
295
|
'aria-label'?: string | undefined;
|
|
290
296
|
'aria-labelledby'?: string | undefined;
|
|
291
297
|
'aria-level'?: number | undefined;
|
|
292
298
|
'aria-live'?: "off" | "assertive" | "polite" | undefined;
|
|
293
|
-
'aria-modal'?: boolean | "
|
|
294
|
-
'aria-multiline'?: boolean | "
|
|
295
|
-
'aria-multiselectable'?: boolean | "
|
|
299
|
+
'aria-modal'?: boolean | "true" | "false" | undefined;
|
|
300
|
+
'aria-multiline'?: boolean | "true" | "false" | undefined;
|
|
301
|
+
'aria-multiselectable'?: boolean | "true" | "false" | undefined;
|
|
296
302
|
'aria-orientation'?: "horizontal" | "vertical" | undefined;
|
|
297
303
|
'aria-owns'?: string | undefined;
|
|
298
304
|
'aria-placeholder'?: string | undefined;
|
|
299
305
|
'aria-posinset'?: number | undefined;
|
|
300
|
-
'aria-pressed'?: boolean | "
|
|
301
|
-
'aria-readonly'?: boolean | "
|
|
302
|
-
'aria-relevant'?: "
|
|
303
|
-
'aria-required'?: boolean | "
|
|
306
|
+
'aria-pressed'?: boolean | "true" | "false" | "mixed" | undefined;
|
|
307
|
+
'aria-readonly'?: boolean | "true" | "false" | undefined;
|
|
308
|
+
'aria-relevant'?: "additions" | "additions removals" | "additions text" | "all" | "removals" | "removals additions" | "removals text" | "text" | "text additions" | "text removals" | undefined;
|
|
309
|
+
'aria-required'?: boolean | "true" | "false" | undefined;
|
|
304
310
|
'aria-roledescription'?: string | undefined;
|
|
305
311
|
'aria-rowcount'?: number | undefined;
|
|
306
312
|
'aria-rowindex'?: number | undefined;
|
|
313
|
+
'aria-rowindextext'?: string | undefined;
|
|
307
314
|
'aria-rowspan'?: number | undefined;
|
|
308
|
-
'aria-selected'?: boolean | "
|
|
315
|
+
'aria-selected'?: boolean | "true" | "false" | undefined;
|
|
309
316
|
'aria-setsize'?: number | undefined;
|
|
310
317
|
'aria-sort'?: "none" | "ascending" | "descending" | "other" | undefined;
|
|
311
318
|
'aria-valuemax'?: number | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compileProps.d.ts","sourceRoot":"./","sources":["compileProps.ts"],"names":[],"mappings":";;AAAA,OAAO,KAAK,EACV,OAAO,EACP,sBAAsB,EACvB,MAAM,sCAAsC,CAAA;AAK7C,eAAO,MAAM,YAAY;
|
|
1
|
+
{"version":3,"file":"compileProps.d.ts","sourceRoot":"./","sources":["compileProps.ts"],"names":[],"mappings":";;AAAA,OAAO,KAAK,EACV,OAAO,EACP,sBAAsB,EACvB,MAAM,sCAAsC,CAAA;AAK7C,eAAO,MAAM,YAAY;cAOb,OAAO,MAAM,EAAE,OAAO,CAAC;eACtB,MAAM,GAAG,SAAS;iBAChB,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuBpB,CAAA"}
|
package/dist/index.es.mjs
CHANGED
|
@@ -16,7 +16,7 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
16
16
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
17
17
|
PERFORMANCE OF THIS SOFTWARE.
|
|
18
18
|
***************************************************************************** */
|
|
19
|
-
/* global Reflect, Promise */
|
|
19
|
+
/* global Reflect, Promise, SuppressedError, Symbol */
|
|
20
20
|
|
|
21
21
|
|
|
22
22
|
var __assign$1 = function() {
|
|
@@ -50,7 +50,12 @@ function __spreadArray(to, from, pack) {
|
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
52
|
return to.concat(ar || Array.prototype.slice.call(from));
|
|
53
|
-
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
|
|
56
|
+
var e = new Error(message);
|
|
57
|
+
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
58
|
+
};
|
|
54
59
|
|
|
55
60
|
/**
|
|
56
61
|
* This "const" is used to create the list of statuses
|
|
@@ -416,7 +421,7 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
416
421
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
417
422
|
PERFORMANCE OF THIS SOFTWARE.
|
|
418
423
|
***************************************************************************** */
|
|
419
|
-
/* global Reflect, Promise */
|
|
424
|
+
/* global Reflect, Promise, SuppressedError, Symbol */
|
|
420
425
|
|
|
421
426
|
|
|
422
427
|
var __assign = function() {
|
|
@@ -440,10 +445,15 @@ function __rest(s, e) {
|
|
|
440
445
|
t[p[i]] = s[p[i]];
|
|
441
446
|
}
|
|
442
447
|
return t;
|
|
443
|
-
}
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
|
|
451
|
+
var e = new Error(message);
|
|
452
|
+
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
453
|
+
};
|
|
444
454
|
|
|
445
455
|
var compileReactIconProperties = function (_a) {
|
|
446
|
-
var body = _a.body, compiledClasses = _a.compiledClasses, size = _a.size, attributes = __rest(_a, ["body", "compiledClasses", "size"]);
|
|
456
|
+
var body = _a.body, defs = _a.defs, compiledClasses = _a.compiledClasses, size = _a.size, name = _a.name, attributes = __rest(_a, ["body", "defs", "compiledClasses", "size", "name"]);
|
|
447
457
|
var filteredAttributes = Object.keys(attributes).reduce(function (newAttributes, attrName) {
|
|
448
458
|
if (!ICON_COLOR_PROP_NAMES.includes(attrName) &&
|
|
449
459
|
attrName !== 'name') {
|
|
@@ -454,6 +464,20 @@ var compileReactIconProperties = function (_a) {
|
|
|
454
464
|
}
|
|
455
465
|
return newAttributes;
|
|
456
466
|
}, {});
|
|
467
|
+
React.useEffect(function () {
|
|
468
|
+
var iconFileId = "".concat(name, "_").concat(size);
|
|
469
|
+
if (defs) {
|
|
470
|
+
if (document.querySelector("[data-cy-svg-defs=\"".concat(iconFileId, "\"]"))) {
|
|
471
|
+
return;
|
|
472
|
+
}
|
|
473
|
+
var svgElement = document.createElementNS('http://www.w3.org/2000/svg', 'svg');
|
|
474
|
+
svgElement.setAttribute('data-cy-svg-defs', iconFileId);
|
|
475
|
+
svgElement.setAttribute('width', '0');
|
|
476
|
+
svgElement.setAttribute('height', '0');
|
|
477
|
+
svgElement.innerHTML = defs;
|
|
478
|
+
document.body.appendChild(svgElement);
|
|
479
|
+
}
|
|
480
|
+
}, [defs]);
|
|
457
481
|
var componentProps = __assign({ width: size, height: size, viewBox: "0 0 ".concat(size, " ").concat(size), fill: 'none', dangerouslySetInnerHTML: {
|
|
458
482
|
__html: body,
|
|
459
483
|
}, className: undefined }, filteredAttributes);
|
|
@@ -467,10 +491,10 @@ var compileReactIconProperties = function (_a) {
|
|
|
467
491
|
};
|
|
468
492
|
|
|
469
493
|
|
|
470
|
-
/* <wind-keep class="filter"> */
|
|
494
|
+
/* <wind-keep class="filter icon-light-secondary icon-dark-secondary"> */
|
|
471
495
|
|
|
472
496
|
var compileProps = function (_a) {
|
|
473
|
-
var status = _a.status, statuses = _a.statuses, className = _a.className, size = _a.size;
|
|
497
|
+
var status = _a.status, statuses = _a.statuses, className = _a.className, size = _a.size, variantName = _a.variantName;
|
|
474
498
|
var statusInfo = status ? statuses[status] : statuses.placeholder;
|
|
475
499
|
var iconInfo = status ? statuses$3[status] : statuses$3.placeholder;
|
|
476
500
|
var iconData = statusInfo["size".concat(size, "Icon")].data;
|
|
@@ -485,6 +509,7 @@ var compileProps = function (_a) {
|
|
|
485
509
|
body: iconData,
|
|
486
510
|
compiledClasses: __spreadArray(__spreadArray([], compiledClasses, true), [classes], false),
|
|
487
511
|
size: size,
|
|
512
|
+
name: "status_".concat(status, "_").concat(size, "_").concat(variantName),
|
|
488
513
|
});
|
|
489
514
|
};
|
|
490
515
|
|
|
@@ -495,6 +520,7 @@ var OutlineStatusIcon = function (_a) {
|
|
|
495
520
|
statuses: statuses$2,
|
|
496
521
|
className: rest.className,
|
|
497
522
|
size: size,
|
|
523
|
+
variantName: 'outline',
|
|
498
524
|
})));
|
|
499
525
|
};
|
|
500
526
|
|
|
@@ -505,6 +531,7 @@ var SimpleStatusIcon = function (_a) {
|
|
|
505
531
|
statuses: statuses$1,
|
|
506
532
|
className: rest.className,
|
|
507
533
|
size: size,
|
|
534
|
+
variantName: 'simple',
|
|
508
535
|
})));
|
|
509
536
|
};
|
|
510
537
|
|
|
@@ -515,6 +542,7 @@ var SolidStatusIcon = function (_a) {
|
|
|
515
542
|
statuses: statuses,
|
|
516
543
|
className: rest.className,
|
|
517
544
|
size: size,
|
|
545
|
+
variantName: 'solid',
|
|
518
546
|
})));
|
|
519
547
|
};
|
|
520
548
|
|
|
@@ -532,4 +560,4 @@ var StatusIcon = function (_a) {
|
|
|
532
560
|
export { OutlineStatusIcon, SimpleStatusIcon, SolidStatusIcon, StatusIcon as default };
|
|
533
561
|
//# sourceMappingURL=index.es.mjs.map
|
|
534
562
|
|
|
535
|
-
/* <wind-keep class="outline inline-block"> */
|
|
563
|
+
/* <wind-keep class="outline inline-block icon-dark-indigo-400 icon-light-gray-100 icon-dark-jade-400 icon-dark-red-400 icon-dark-gray-100 icon-dark-gray-300 icon-dark-orange-400 icon-dark-gray-400"> */
|