@wonderflow/react-components 5.5.0 → 5.6.0
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.
|
@@ -16,8 +16,9 @@ export declare type IconProps = SVGAttributes<SVGElement | SVGSVGElement> & {
|
|
|
16
16
|
dimension?: TokensTypes['icon']['size'];
|
|
17
17
|
/**
|
|
18
18
|
* Set the weight of the icon.
|
|
19
|
-
* The default weight is `
|
|
20
|
-
*
|
|
19
|
+
* The default weight is `outline` if `dimension` is greather than `12` or `undefined`.
|
|
20
|
+
* If `dimension` is set to `12`, the weight is ignored and the icon forced to use
|
|
21
|
+
* the `solid` style to improve the readability.
|
|
21
22
|
*/
|
|
22
23
|
weight?: 'solid' | 'outline' | 'duotone';
|
|
23
24
|
};
|
|
@@ -36,8 +37,9 @@ export declare const Icon: import("react").ForwardRefExoticComponent<SVGAttribut
|
|
|
36
37
|
dimension?: 16 | 24 | 12 | 32 | 40 | 48 | 56 | undefined;
|
|
37
38
|
/**
|
|
38
39
|
* Set the weight of the icon.
|
|
39
|
-
* The default weight is `
|
|
40
|
-
*
|
|
40
|
+
* The default weight is `outline` if `dimension` is greather than `12` or `undefined`.
|
|
41
|
+
* If `dimension` is set to `12`, the weight is ignored and the icon forced to use
|
|
42
|
+
* the `solid` style to improve the readability.
|
|
41
43
|
*/
|
|
42
44
|
weight?: "solid" | "outline" | "duotone" | undefined;
|
|
43
45
|
} & import("react").RefAttributes<SVGSVGElement>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icon.d.ts","sourceRoot":"","sources":["../../../src/components/icon/icon.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAA;AAC7C,OAAO,EAIL,YAAY,EACZ,aAAa,EAEd,MAAM,OAAO,CAAA;AAEd,OAAO,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAA;AAI9D,oBAAY,SAAS,GAAG,aAAa,CAAC,UAAU,GAAG,aAAa,CAAC,GAAG;IAClE;;;;;OAKG;IACH,MAAM,EAAE,SAAS,GAAG,YAAY,CAAC,gBAAgB,CAAC,CAAC;IACnD;;;OAGG;IACH,SAAS,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC,CAAC;IACxC
|
|
1
|
+
{"version":3,"file":"icon.d.ts","sourceRoot":"","sources":["../../../src/components/icon/icon.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAA;AAC7C,OAAO,EAIL,YAAY,EACZ,aAAa,EAEd,MAAM,OAAO,CAAA;AAEd,OAAO,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAA;AAI9D,oBAAY,SAAS,GAAG,aAAa,CAAC,UAAU,GAAG,aAAa,CAAC,GAAG;IAClE;;;;;OAKG;IACH,MAAM,EAAE,SAAS,GAAG,YAAY,CAAC,gBAAgB,CAAC,CAAC;IACnD;;;OAGG;IACH,SAAS,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC,CAAC;IACxC;;;;;MAKE;IACF,MAAM,CAAC,EAAE,OAAO,GAAG,SAAS,GAAG,SAAS,CAAC;CAC1C,CAAA;AAED,eAAO,MAAM,IAAI;IArBf;;;;;OAKG;YACK,SAAS,GAAG,aAAa,gBAAgB,CAAC;IAClD;;;OAGG;;IAEH;;;;;MAKE;;iDAyCF,CAAA"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { Children, cloneElement, forwardRef, useMemo } from 'react';
|
|
3
|
-
import sprite from '@wonderflow/icons/sprite';
|
|
3
|
+
import sprite from '@wonderflow/icons/sprite.svg';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
5
|
import styles from './icon.module.css';
|
|
6
6
|
export const Icon = forwardRef(({ className, source, dimension = 16, weight = 'outline', fill, ...otherProps }, forwardedRef) => {
|