@factorialco/f0-react-native 0.29.0 → 0.30.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.
- package/lib/module/components/Avatars/IconAvatar/index.js +1 -1
- package/lib/module/components/Avatars/IconAvatar/index.js.map +1 -1
- package/lib/module/components/Avatars/ModuleAvatar/index.js +1 -1
- package/lib/module/components/Avatars/ModuleAvatar/index.js.map +1 -1
- package/lib/module/components/Badge/index.js +1 -1
- package/lib/module/components/Badge/index.js.map +1 -1
- package/lib/module/components/Button/index.js +1 -1
- package/lib/module/components/Button/index.js.map +1 -1
- package/lib/module/components/Button/index.spec.js +1 -1
- package/lib/module/components/Button/index.spec.js.map +1 -1
- package/lib/module/components/Icon/index.js +1 -1
- package/lib/module/components/Icon/index.js.map +1 -1
- package/lib/module/components/OneChip/index.js +1 -1
- package/lib/module/components/OneChip/index.js.map +1 -1
- package/lib/module/components/Tags/AlertTab/index.js +1 -1
- package/lib/module/components/Tags/AlertTab/index.js.map +1 -1
- package/lib/module/components/Tags/RawTag/index.js +1 -1
- package/lib/module/components/Tags/RawTag/index.js.map +1 -1
- package/lib/module/components/experimental/Lists/DataList/ItemContainer.js +1 -1
- package/lib/module/components/experimental/Lists/DataList/ItemContainer.js.map +1 -1
- package/lib/module/components/experimental/Lists/DataList/actions/CopyAction.js +1 -1
- package/lib/module/components/experimental/Lists/DataList/actions/CopyAction.js.map +1 -1
- package/lib/module/components/experimental/Lists/DataList/actions/GenericAction.js +1 -1
- package/lib/module/components/experimental/Lists/DataList/actions/GenericAction.js.map +1 -1
- package/lib/module/components/exports.js +1 -1
- package/lib/module/components/exports.js.map +1 -1
- package/lib/module/components/primitives/F0Icon/F0Icon.js +2 -0
- package/lib/module/components/primitives/F0Icon/F0Icon.js.map +1 -0
- package/lib/module/components/primitives/F0Icon/F0Icon.md +187 -0
- package/lib/module/components/primitives/F0Icon/F0Icon.styles.js +2 -0
- package/lib/module/components/primitives/F0Icon/F0Icon.styles.js.map +1 -0
- package/lib/module/components/primitives/F0Icon/F0Icon.types.js +2 -0
- package/lib/module/components/primitives/F0Icon/F0Icon.types.js.map +1 -0
- package/lib/module/components/primitives/F0Icon/index.js +2 -0
- package/lib/module/components/primitives/F0Icon/index.js.map +1 -0
- package/lib/module/icons/index.js +1 -1
- package/lib/module/icons/index.js.map +1 -1
- package/lib/typescript/components/Activity/ActivityItem/index.d.ts +1 -1
- package/lib/typescript/components/Activity/ActivityItem/index.d.ts.map +1 -1
- package/lib/typescript/components/Avatars/IconAvatar/index.d.ts +1 -1
- package/lib/typescript/components/Avatars/IconAvatar/index.d.ts.map +1 -1
- package/lib/typescript/components/Avatars/ModuleAvatar/index.d.ts +1 -1
- package/lib/typescript/components/Avatars/ModuleAvatar/index.d.ts.map +1 -1
- package/lib/typescript/components/Badge/index.d.ts +1 -1
- package/lib/typescript/components/Badge/index.d.ts.map +1 -1
- package/lib/typescript/components/Button/index.d.ts +1 -1
- package/lib/typescript/components/Button/index.d.ts.map +1 -1
- package/lib/typescript/components/Icon/index.d.ts +7 -14
- package/lib/typescript/components/Icon/index.d.ts.map +1 -1
- package/lib/typescript/components/OneChip/index.d.ts +1 -1
- package/lib/typescript/components/OneChip/index.d.ts.map +1 -1
- package/lib/typescript/components/Tags/RawTag/index.d.ts +1 -1
- package/lib/typescript/components/Tags/RawTag/index.d.ts.map +1 -1
- package/lib/typescript/components/experimental/Lists/DataList/ItemContainer.d.ts +1 -1
- package/lib/typescript/components/experimental/Lists/DataList/ItemContainer.d.ts.map +1 -1
- package/lib/typescript/components/experimental/Lists/DataList/actions/CopyAction.d.ts.map +1 -1
- package/lib/typescript/components/experimental/Lists/DataList/index.d.ts +1 -1
- package/lib/typescript/components/experimental/Lists/DataList/index.d.ts.map +1 -1
- package/lib/typescript/components/exports.d.ts +2 -1
- package/lib/typescript/components/exports.d.ts.map +1 -1
- package/lib/typescript/components/primitives/F0Icon/F0Icon.d.ts +25 -0
- package/lib/typescript/components/primitives/F0Icon/F0Icon.d.ts.map +1 -0
- package/lib/typescript/components/primitives/F0Icon/F0Icon.styles.d.ts +90 -0
- package/lib/typescript/components/primitives/F0Icon/F0Icon.styles.d.ts.map +1 -0
- package/lib/typescript/components/primitives/F0Icon/F0Icon.types.d.ts +47 -0
- package/lib/typescript/components/primitives/F0Icon/F0Icon.types.d.ts.map +1 -0
- package/lib/typescript/components/primitives/F0Icon/index.d.ts +10 -0
- package/lib/typescript/components/primitives/F0Icon/index.d.ts.map +1 -0
- package/lib/typescript/icons/index.d.ts +0 -1
- package/lib/typescript/icons/index.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/components/Activity/ActivityItem/index.spec.tsx +1 -1
- package/src/components/Activity/ActivityItem/index.tsx +1 -1
- package/src/components/Avatars/IconAvatar/index.tsx +6 -2
- package/src/components/Avatars/ModuleAvatar/index.tsx +1 -1
- package/src/components/Badge/index.tsx +2 -2
- package/src/components/Button/index.spec.tsx +3 -4
- package/src/components/Button/index.tsx +19 -13
- package/src/components/Icon/__tests__/Icon.spec.tsx +0 -4
- package/src/components/Icon/index.tsx +7 -26
- package/src/components/OneChip/index.tsx +3 -3
- package/src/components/Tags/AlertTab/index.tsx +2 -2
- package/src/components/Tags/RawTag/index.tsx +2 -2
- package/src/components/experimental/Lists/DataList/ItemContainer.tsx +2 -2
- package/src/components/experimental/Lists/DataList/actions/CopyAction.tsx +7 -10
- package/src/components/experimental/Lists/DataList/actions/GenericAction.tsx +2 -2
- package/src/components/experimental/Lists/DataList/index.tsx +1 -1
- package/src/components/experimental/Lists/DetailsItem/__snapshots__/index.spec.tsx.snap +4 -4
- package/src/components/experimental/Lists/DetailsItemsList/__snapshots__/index.spec.tsx.snap +1 -1
- package/src/components/exports.ts +2 -1
- package/src/components/primitives/F0Icon/F0Icon.md +187 -0
- package/src/components/primitives/F0Icon/F0Icon.styles.ts +43 -0
- package/src/components/primitives/F0Icon/F0Icon.tsx +73 -0
- package/src/components/primitives/F0Icon/F0Icon.types.ts +77 -0
- package/src/components/primitives/F0Icon/__tests__/F0Icon.spec.tsx +131 -0
- package/src/components/primitives/F0Icon/__tests__/F0Icon.tokens.spec.ts +39 -0
- package/src/components/primitives/F0Icon/index.ts +10 -0
- package/src/icons/index.ts +0 -1
- package/lib/module/components/Icon/README.md +0 -63
- package/src/components/Icon/README.md +0 -63
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{tv}from"tailwind-variants";export var iconVariants=tv({base:"shrink-0",variants:{size:{xl:"w-8 h-8 stroke-xl",lg:"w-6 h-6 stroke-lg",md:"w-5 h-5 stroke-md",sm:"w-4 h-4 stroke-sm",xs:"w-3 h-3 stroke-xs"},color:{default:"text-f0-icon",secondary:"text-f0-icon-secondary",inverse:"text-f0-icon-inverse",bold:"text-f0-icon-bold",critical:"text-f0-icon-critical","critical-bold":"text-f0-icon-critical-bold",accent:"text-f0-icon-accent",info:"text-f0-icon-info",warning:"text-f0-icon-warning",positive:"text-f0-icon-positive",promote:"text-f0-icon-promote",selected:"text-f0-icon-selected","selected-hover":"text-f0-icon-selected-hover","mood-super-negative":"text-f0-icon-mood-super-negative","mood-negative":"text-f0-icon-mood-negative","mood-neutral":"text-f0-icon-mood-neutral","mood-positive":"text-f0-icon-mood-positive","mood-super-positive":"text-f0-icon-mood-super-positive"}},defaultVariants:{size:"md"}});
|
|
2
|
+
//# sourceMappingURL=F0Icon.styles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["tv","iconVariants","base","variants","size","xl","lg","md","sm","xs","color","default","secondary","inverse","bold","critical","accent","info","warning","positive","promote","selected","defaultVariants"],"sourceRoot":"../../../../../src","sources":["components/primitives/F0Icon/F0Icon.styles.ts"],"mappings":"AAAA,OAASA,EAAE,KAAQ,mBAAmB,CAMtC,MAAO,IAAM,CAAAC,YAAY,CAAGD,EAAE,CAAC,CAC7BE,IAAI,CAAE,UAAU,CAEhBC,QAAQ,CAAE,CACRC,IAAI,CAAE,CACJC,EAAE,CAAE,mBAAmB,CACvBC,EAAE,CAAE,mBAAmB,CACvBC,EAAE,CAAE,mBAAmB,CACvBC,EAAE,CAAE,mBAAmB,CACvBC,EAAE,CAAE,mBACN,CAAC,CACDC,KAAK,CAAE,CACLC,OAAO,CAAE,cAAc,CACvBC,SAAS,CAAE,wBAAwB,CACnCC,OAAO,CAAE,sBAAsB,CAC/BC,IAAI,CAAE,mBAAmB,CACzBC,QAAQ,CAAE,uBAAuB,CACjC,eAAe,CAAE,4BAA4B,CAC7CC,MAAM,CAAE,qBAAqB,CAC7BC,IAAI,CAAE,mBAAmB,CACzBC,OAAO,CAAE,sBAAsB,CAC/BC,QAAQ,CAAE,uBAAuB,CACjCC,OAAO,CAAE,sBAAsB,CAC/BC,QAAQ,CAAE,uBAAuB,CACjC,gBAAgB,CAAE,6BAA6B,CAC/C,qBAAqB,CAAE,kCAAkC,CACzD,eAAe,CAAE,4BAA4B,CAC7C,cAAc,CAAE,2BAA2B,CAC3C,eAAe,CAAE,4BAA4B,CAC7C,qBAAqB,CAAE,kCACzB,CACF,CAAC,CAEDC,eAAe,CAAE,CACflB,IAAI,CAAE,IACR,CACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export var ICON_COLORS=["default","secondary","inverse","bold","critical","critical-bold","accent","info","warning","positive","promote","selected","selected-hover","mood-super-negative","mood-negative","mood-neutral","mood-positive","mood-super-positive"];
|
|
2
|
+
//# sourceMappingURL=F0Icon.types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["ICON_COLORS"],"sourceRoot":"../../../../../src","sources":["components/primitives/F0Icon/F0Icon.types.ts"],"mappings":"AAqBA,MAAO,IAAM,CAAAA,WAAW,CAAG,CACzB,SAAS,CACT,WAAW,CACX,SAAS,CACT,MAAM,CACN,UAAU,CACV,eAAe,CACf,QAAQ,CACR,MAAM,CACN,SAAS,CACT,UAAU,CACV,SAAS,CACT,UAAU,CACV,gBAAgB,CAChB,qBAAqB,CACrB,eAAe,CACf,cAAc,CACd,eAAe,CACf,qBAAqB,CACb","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["default","F0Icon","ICON_COLORS","applyIconInterop"],"sourceRoot":"../../../../../src","sources":["components/primitives/F0Icon/index.ts"],"mappings":"AAMA,OAASA,OAAO,GAAI,CAAAC,MAAM,KAAQ,UAAU,CAE5C,OAASC,WAAW,KAAQ,gBAAgB,CAC5C,OAASC,gBAAgB,KAAQ,UAAU","ignoreList":[]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as AppIcons from"./app";import*as ModuleIcons from"./modules";export{AppIcons,ModuleIcons};export*from"./types";
|
|
1
|
+
import*as AppIcons from"./app";import*as ModuleIcons from"./modules";export{AppIcons,ModuleIcons};export*from"./types";
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["AppIcons","ModuleIcons"
|
|
1
|
+
{"version":3,"names":["AppIcons","ModuleIcons"],"sourceRoot":"../../../src","sources":["icons/index.ts"],"mappings":"AAAA,MAAO,GAAK,CAAAA,QAAQ,KAAM,OAAO,CACjC,MAAO,GAAK,CAAAC,WAAW,KAAM,WAAW,CACxC,OAASD,QAAQ,CAAEC,WAAW,EAC9B,WAAc,SAAS","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Activity/ActivityItem/index.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,QAAQ,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Activity/ActivityItem/index.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,yBAAyB,CAAA;AAEvD,MAAM,MAAM,iBAAiB,GAAG;IAC9B,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,EAAE,MAAM,CAAA;IACZ,KAAK,EAAE,MAAM,CAAA;IACb,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,IAAI,CAAC,EAAE,QAAQ,CAAA;IACf,QAAQ,EAAE,MAAM,CAAA;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;CAC9B,CAAA;AAED,eAAO,MAAM,YAAY,GAAI,sEAS1B,iBAAiB,gCAqCnB,CAAA;AAED,eAAO,MAAM,oBAAoB,mCAyBhC,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Avatars/IconAvatar/index.tsx"],"names":[],"mappings":"AAGA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Avatars/IconAvatar/index.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAU,KAAK,QAAQ,EAAE,MAAM,yBAAyB,CAAA;AAE/D,KAAK,KAAK,GAAG;IACX,IAAI,EAAE,QAAQ,CAAA;IACd,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAA;IACzB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AAQD,eAAO,MAAM,UAAU;gCAAsC,KAAK;;CAgBjE,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type VariantProps } from "tailwind-variants";
|
|
2
|
-
import { IconType } from "../../
|
|
2
|
+
import { type IconType } from "../../primitives/F0Icon";
|
|
3
3
|
import { ModuleId } from "./modules";
|
|
4
4
|
declare const moduleAvatarVariants: import("tailwind-variants").TVReturnType<{
|
|
5
5
|
size: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Avatars/ModuleAvatar/index.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAEzD,OAAO,EAAE,QAAQ,EAAoB,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Avatars/ModuleAvatar/index.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAEzD,OAAO,EAAE,KAAK,QAAQ,EAAoB,MAAM,yBAAyB,CAAA;AAEzE,OAAO,EAAE,QAAQ,EAAW,MAAM,WAAW,CAAA;AAE7C,QAAA,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;iGAaxB,CAAA;AAgCF,MAAM,MAAM,iBAAiB,GAAG,YAAY,CAAC,OAAO,oBAAoB,CAAC,GACvE,CACI;IACE,MAAM,EAAE,QAAQ,CAAA;CACjB,GACD;IACE;;OAEG;IACH,IAAI,EAAE,QAAQ,CAAA;CACf,CACJ,CAAA;AAKH,eAAO,MAAM,YAAY;yBAA+B,iBAAiB;;CAoCxE,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Badge/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAEzD,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Badge/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAEzD,OAAO,EAAU,KAAK,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AAE5D,QAAA,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qGAqBjB,CAAA;AAEF,QAAA,MAAM,SAAS;;;;;CAKL,CAAA;AAEV,MAAM,WAAW,UAAW,SAAQ,YAAY,CAAC,OAAO,aAAa,CAAC;IACpE,IAAI,EAAE,QAAQ,CAAA;IACd,IAAI,CAAC,EAAE,MAAM,OAAO,SAAS,CAAA;CAC9B;AAED,eAAO,MAAM,KAAK,GAAI,sBAA6B,UAAU,gCAQ5D,CAAA"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { View } from "react-native";
|
|
3
3
|
import { type VariantProps } from "tailwind-variants";
|
|
4
|
-
import { type IconType } from "../
|
|
4
|
+
import { type IconType } from "../primitives/F0Icon";
|
|
5
5
|
export declare const variants: readonly ["default", "outline", "critical", "neutral", "ghost", "promote"];
|
|
6
6
|
export type ButtonVariant = (typeof variants)[number];
|
|
7
7
|
export declare const sizes: readonly ["sm", "md", "lg"];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA+B,MAAM,OAAO,CAAA;AACnD,OAAO,EAAmB,IAAI,EAAE,MAAM,cAAc,CAAA;AACpD,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAGzD,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA+B,MAAM,OAAO,CAAA;AACnD,OAAO,EAAmB,IAAI,EAAE,MAAM,cAAc,CAAA;AACpD,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAGzD,OAAO,EAAU,KAAK,QAAQ,EAAkB,MAAM,sBAAsB,CAAA;AAE5E,eAAO,MAAM,QAAQ,4EAOX,CAAA;AACV,MAAM,MAAM,aAAa,GAAG,CAAC,OAAO,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAA;AAErD,eAAO,MAAM,KAAK,6BAA8B,CAAA;AAChD,MAAM,MAAM,UAAU,GAAG,CAAC,OAAO,KAAK,CAAC,CAAC,MAAM,CAAC,CAAA;AAE/C,QAAA,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8GA+BlB,CAAA;AAkEF,MAAM,WAAW,WAAY,SAAQ,YAAY,CAAC,OAAO,cAAc,CAAC;IACtE,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,CAAC,EAAE,MAAM,IAAI,GAAG,OAAO,CAAC,OAAO,CAAC,CAAA;IACvC,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,IAAI,CAAC,EAAE,QAAQ,CAAA;IACf,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB;AAED,eAAO,MAAM,MAAM,0EA4GjB,CAAA"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import React
|
|
1
|
+
import React from "react";
|
|
2
2
|
import { Svg, SvgProps } from "react-native-svg";
|
|
3
3
|
import { type VariantProps } from "tailwind-variants";
|
|
4
|
+
import { type IconType } from "../primitives/F0Icon";
|
|
4
5
|
declare const iconVariants: import("tailwind-variants").TVReturnType<{
|
|
5
6
|
size: {
|
|
6
7
|
xl: string;
|
|
@@ -33,19 +34,11 @@ export interface IconProps extends SvgProps, VariantProps<typeof iconVariants> {
|
|
|
33
34
|
variant?: "default" | "critical" | "neutral" | "ghost" | "outline" | "promote";
|
|
34
35
|
isPressed?: boolean;
|
|
35
36
|
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
fontClassName?: string | undefined;
|
|
42
|
-
} & {
|
|
43
|
-
colorClassName?: string | undefined;
|
|
44
|
-
} & Omit<SvgProps & React.RefAttributes<Svg> & {
|
|
45
|
-
className?: string;
|
|
46
|
-
}, "ref"> & {
|
|
47
|
-
ref?: ((instance: Svg | null) => void | React.DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof React.DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | React.RefObject<Svg> | null | undefined;
|
|
48
|
-
}) => React.ReactNode;
|
|
37
|
+
/**
|
|
38
|
+
* @deprecated Use F0Icon instead. This component will be removed in a future version.
|
|
39
|
+
* Migration: Replace <Icon icon={X} /> with <F0Icon icon={X} />.
|
|
40
|
+
* F0Icon supports the same `icon`, `size`, `testID`, and `className` props, plus semantic `color` variants.
|
|
41
|
+
*/
|
|
49
42
|
export declare const Icon: React.ForwardRefExoticComponent<IconProps & React.RefAttributes<Svg>>;
|
|
50
43
|
export {};
|
|
51
44
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Icon/index.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Icon/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAA;AACzC,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAA;AAChD,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAGzD,OAAO,EAAoB,KAAK,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AAEtE,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;uDAchB,CAAA;AAEF,MAAM,WAAW,SAAU,SAAQ,QAAQ,EAAE,YAAY,CAAC,OAAO,YAAY,CAAC;IAC5E,IAAI,EAAE,QAAQ,CAAA;IACd,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,OAAO,CAAC,EAAE,SAAS,GAAG,UAAU,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,GAAG,SAAS,CAAA;IAC9E,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB;AAED;;;;GAIG;AACH,eAAO,MAAM,IAAI,uEAiBf,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type VariantProps } from "tailwind-variants";
|
|
2
|
-
import { type IconType } from "../
|
|
2
|
+
import { type IconType } from "../primitives/F0Icon";
|
|
3
3
|
export declare const chipContainerVariants: import("tailwind-variants").TVReturnType<{
|
|
4
4
|
variant: {
|
|
5
5
|
default: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/OneChip/index.tsx"],"names":[],"mappings":"AACA,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/OneChip/index.tsx"],"names":[],"mappings":"AACA,OAAO,EAAM,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAKzD,OAAO,EAAU,KAAK,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AAE5D,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;2IAWhC,CAAA;AAEF,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;0DAW3B,CAAA;AAEF,UAAU,SAAU,SAAQ,YAAY,CAAC,OAAO,qBAAqB,CAAC;IACpE,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,QAAQ,CAAA;IACf,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACrB;AAED,eAAO,MAAM,OAAO,GAAI,6CAMrB,SAAS,gCA4CX,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Tags/RawTag/index.tsx"],"names":[],"mappings":"AAEA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Tags/RawTag/index.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAU,KAAK,QAAQ,EAAE,MAAM,yBAAyB,CAAA;AAG/D,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,uBAAuB,CAAC,EAAE,MAAM,CAAA;IAChC,IAAI,CAAC,EAAE,QAAQ,CAAA;IACf,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AAED,eAAO,MAAM,MAAM;oEAMhB,WAAW;;CAmBb,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ItemContainer.d.ts","sourceRoot":"","sources":["../../../../../../src/components/experimental/Lists/DataList/ItemContainer.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAa,MAAM,OAAO,CAAA;AAI/C,OAAO,
|
|
1
|
+
{"version":3,"file":"ItemContainer.d.ts","sourceRoot":"","sources":["../../../../../../src/components/experimental/Lists/DataList/ItemContainer.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAa,MAAM,OAAO,CAAA;AAI/C,OAAO,EAAU,KAAK,QAAQ,EAAE,MAAM,4BAA4B,CAAA;AAKlE,OAAO,EAAE,UAAU,EAAE,MAAM,GAAG,CAAA;AAE9B,KAAK,kBAAkB,GAAG;IACxB,QAAQ,CAAC,EAAE,QAAQ,GAAG,CAAC,MAAM,YAAY,CAAC,CAAA;IAC1C,MAAM,CAAC,EAAE,UAAU,CAAA;IACnB,IAAI,EAAE,MAAM,CAAA;IACZ,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AAED,eAAO,MAAM,aAAa,GAAI,OAAO,kBAAkB,gCA0BtD,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CopyAction.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/experimental/Lists/DataList/actions/CopyAction.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAuB,MAAM,OAAO,CAAA;AAGtD,OAAO,EAAE,cAAc,EAAE,MAAM,IAAI,CAAA;AAOnC,MAAM,MAAM,eAAe,GAAG;IAC5B,QAAQ,EAAE,SAAS,CAAA;CACpB,GAAG,cAAc,CAAA;AAElB,eAAO,MAAM,UAAU,GAAI,oBAAoB,eAAe,
|
|
1
|
+
{"version":3,"file":"CopyAction.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/experimental/Lists/DataList/actions/CopyAction.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAuB,MAAM,OAAO,CAAA;AAGtD,OAAO,EAAE,cAAc,EAAE,MAAM,IAAI,CAAA;AAOnC,MAAM,MAAM,eAAe,GAAG;IAC5B,QAAQ,EAAE,SAAS,CAAA;CACpB,GAAG,cAAc,CAAA;AAElB,eAAO,MAAM,UAAU,GAAI,oBAAoB,eAAe,gCAsD7D,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactElement } from "react";
|
|
2
|
-
import { IconType } from "../../../
|
|
2
|
+
import { type IconType } from "../../../primitives/F0Icon";
|
|
3
3
|
import { DotTagProps } from "../../../Tags/DotTag";
|
|
4
4
|
export type DataListProps = {
|
|
5
5
|
children: ReactElement<Items>[] | ReactElement<Items>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/components/experimental/Lists/DataList/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,OAAO,CAAA;AAOpC,OAAO,EAAE,QAAQ,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/components/experimental/Lists/DataList/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,OAAO,CAAA;AAOpC,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,4BAA4B,CAAA;AAC1D,OAAO,EAAU,WAAW,EAAE,MAAM,sBAAsB,CAAA;AAI1D,MAAM,MAAM,aAAa,GAAG;IAC1B,QAAQ,EAAE,YAAY,CAAC,KAAK,CAAC,EAAE,GAAG,YAAY,CAAC,KAAK,CAAC,CAAA;IACrD,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB,CAAA;AAED,KAAK,KAAK,GACN,OAAO,IAAI,GACX,OAAO,UAAU,GACjB,OAAO,WAAW,GAClB,OAAO,QAAQ,CAAA;AAkCnB,MAAM,MAAM,SAAS,GAAG;IACtB,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,CAAC,EAAE,QAAQ,CAAA;IACf,MAAM,CAAC,EAAE,UAAU,CAAA;CACpB,CAAA;AAED,MAAM,MAAM,UAAU,GAAG,cAAc,GAAG,iBAAiB,GAAG,cAAc,CAAA;AAE5E,MAAM,MAAM,cAAc,GAAG;IAC3B,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,CAAC,EAAE,MAAM,CAAA;CACd,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG;IAC9B,IAAI,EAAE,SAAS,CAAA;IACf,WAAW,CAAC,EAAE,MAAM,IAAI,CAAA;CACzB,CAAA;AAED,MAAM,MAAM,cAAc,GAAG;IAC3B,IAAI,EAAE,MAAM,CAAA;CACb,CAAA;AAED,QAAA,MAAM,IAAI,GAAI,wBAAwB,SAAS,gCAQ9C,CAAA;AAED,KAAK,GAAG,GAAG,MAAM,CAAA;AAEjB,KAAK,iBAAiB,GAAG;IACvB,SAAS,EAAE,MAAM,CAAA;IACjB,QAAQ,EAAE,MAAM,CAAA;IAChB,SAAS,CAAC,EAAE,GAAG,CAAA;IACf,MAAM,CAAC,EAAE,UAAU,CAAA;CACpB,CAAA;AAED,QAAA,MAAM,UAAU,GAAI,6CAKjB,iBAAiB,gCAgBnB,CAAA;AAED,KAAK,gBAAgB,GAAG;IACtB,IAAI,EAAE,MAAM,CAAA;IACZ,SAAS,CAAC,EAAE,GAAG,CAAA;IACf,MAAM,CAAC,EAAE,UAAU,CAAA;CACpB,CAAA;AAED,QAAA,MAAM,WAAW,GAAI,6BAA6B,gBAAgB,gCAUjE,CAAA;AAED,KAAK,aAAa,GAAG;IACnB,IAAI,EAAE,MAAM,CAAA;IACZ,MAAM,CAAC,EAAE,UAAU,CAAA;CACpB,CAAA;AAED,QAAA,MAAM,QAAQ,GAAI,kBAAkB,aAAa,gCAQhD,CAAA;AAED,KAAK,eAAe,GAAG,WAAW,CAAA;AA0BlC,eAAO,MAAM,QAAQ,uDAtJlB,aAAa;mCAiDsB,SAAS;+CAgDG,gBAAgB;8DAxB/D,iBAAiB;iCAyCgB,aAAa;+BAYf,eAAe;CA8B/C,CAAA"}
|
|
@@ -4,7 +4,7 @@ export * from "./Badge";
|
|
|
4
4
|
export * from "./Button";
|
|
5
5
|
export * from "./Counter";
|
|
6
6
|
export * from "./ExampleComponent";
|
|
7
|
-
export
|
|
7
|
+
export { Icon, type IconProps } from "./Icon";
|
|
8
8
|
export * from "./Navigation/PageHeader";
|
|
9
9
|
export * from "./OneChip";
|
|
10
10
|
export * from "./OnePreset";
|
|
@@ -14,4 +14,5 @@ export * from "./experimental/Lists/DataList";
|
|
|
14
14
|
export * from "./experimental/Lists/DetailsItem";
|
|
15
15
|
export * from "./experimental/Lists/DetailsItemsList";
|
|
16
16
|
export * from "./primitives/F0Text";
|
|
17
|
+
export * from "./primitives/F0Icon";
|
|
17
18
|
//# sourceMappingURL=exports.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exports.d.ts","sourceRoot":"","sources":["../../../src/components/exports.ts"],"names":[],"mappings":"AACA,cAAc,yBAAyB,CAAA;AACvC,cAAc,mBAAmB,CAAA;AACjC,cAAc,SAAS,CAAA;AACvB,cAAc,UAAU,CAAA;AACxB,cAAc,WAAW,CAAA;AACzB,cAAc,oBAAoB,CAAA;AAClC,
|
|
1
|
+
{"version":3,"file":"exports.d.ts","sourceRoot":"","sources":["../../../src/components/exports.ts"],"names":[],"mappings":"AACA,cAAc,yBAAyB,CAAA;AACvC,cAAc,mBAAmB,CAAA;AACjC,cAAc,SAAS,CAAA;AACvB,cAAc,UAAU,CAAA;AACxB,cAAc,WAAW,CAAA;AACzB,cAAc,oBAAoB,CAAA;AAClC,OAAO,EAAE,IAAI,EAAE,KAAK,SAAS,EAAE,MAAM,QAAQ,CAAA;AAC7C,cAAc,yBAAyB,CAAA;AACvC,cAAc,WAAW,CAAA;AACzB,cAAc,aAAa,CAAA;AAC3B,cAAc,qBAAqB,CAAA;AACnC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,+BAA+B,CAAA;AAC7C,cAAc,kCAAkC,CAAA;AAChD,cAAc,uCAAuC,CAAA;AAGrD,cAAc,qBAAqB,CAAA;AACnC,cAAc,qBAAqB,CAAA"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import type { Svg } from "react-native-svg";
|
|
3
|
+
import type { F0IconProps, IconType } from "./F0Icon.types";
|
|
4
|
+
/**
|
|
5
|
+
* Applies UniWind interop to an icon component
|
|
6
|
+
* Ensures withUniwind is only applied once per icon type
|
|
7
|
+
* @internal
|
|
8
|
+
*/
|
|
9
|
+
export declare function applyIconInterop(icon: IconType): IconType;
|
|
10
|
+
/**
|
|
11
|
+
* F0Icon - Icon component for the F0 Design System
|
|
12
|
+
*
|
|
13
|
+
* Renders SVG icons with consistent sizing and semantic colors.
|
|
14
|
+
* Icons are automatically wrapped with UniWind for className support.
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* import { Archive } from '@/icons/app';
|
|
18
|
+
*
|
|
19
|
+
* <F0Icon icon={Archive} size="lg" />
|
|
20
|
+
* <F0Icon icon={Archive} color="critical" />
|
|
21
|
+
* <F0Icon icon={Archive} size="sm" color="positive" />
|
|
22
|
+
*/
|
|
23
|
+
declare const F0Icon: React.MemoExoticComponent<React.ForwardRefExoticComponent<F0IconProps & React.RefAttributes<Svg>>>;
|
|
24
|
+
export default F0Icon;
|
|
25
|
+
//# sourceMappingURL=F0Icon.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"F0Icon.d.ts","sourceRoot":"","sources":["../../../../../src/components/primitives/F0Icon/F0Icon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAA;AACtC,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,kBAAkB,CAAA;AAM3C,OAAO,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AAK3D;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,QAAQ,GAAG,QAAQ,CAOzD;AAED;;;;;;;;;;;;GAYG;AACH,QAAA,MAAM,MAAM,oGA6BX,CAAA;AAID,eAAe,MAAM,CAAA"}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* F0Icon tailwind-variants configuration
|
|
3
|
+
* Size and color variants from the F0 design system
|
|
4
|
+
*/
|
|
5
|
+
export declare const iconVariants: import("tailwind-variants").TVReturnType<{
|
|
6
|
+
size: {
|
|
7
|
+
xl: string;
|
|
8
|
+
lg: string;
|
|
9
|
+
md: string;
|
|
10
|
+
sm: string;
|
|
11
|
+
xs: string;
|
|
12
|
+
};
|
|
13
|
+
color: {
|
|
14
|
+
default: string;
|
|
15
|
+
secondary: string;
|
|
16
|
+
inverse: string;
|
|
17
|
+
bold: string;
|
|
18
|
+
critical: string;
|
|
19
|
+
"critical-bold": string;
|
|
20
|
+
accent: string;
|
|
21
|
+
info: string;
|
|
22
|
+
warning: string;
|
|
23
|
+
positive: string;
|
|
24
|
+
promote: string;
|
|
25
|
+
selected: string;
|
|
26
|
+
"selected-hover": string;
|
|
27
|
+
"mood-super-negative": string;
|
|
28
|
+
"mood-negative": string;
|
|
29
|
+
"mood-neutral": string;
|
|
30
|
+
"mood-positive": string;
|
|
31
|
+
"mood-super-positive": string;
|
|
32
|
+
};
|
|
33
|
+
}, undefined, "shrink-0", {
|
|
34
|
+
size: {
|
|
35
|
+
xl: string;
|
|
36
|
+
lg: string;
|
|
37
|
+
md: string;
|
|
38
|
+
sm: string;
|
|
39
|
+
xs: string;
|
|
40
|
+
};
|
|
41
|
+
color: {
|
|
42
|
+
default: string;
|
|
43
|
+
secondary: string;
|
|
44
|
+
inverse: string;
|
|
45
|
+
bold: string;
|
|
46
|
+
critical: string;
|
|
47
|
+
"critical-bold": string;
|
|
48
|
+
accent: string;
|
|
49
|
+
info: string;
|
|
50
|
+
warning: string;
|
|
51
|
+
positive: string;
|
|
52
|
+
promote: string;
|
|
53
|
+
selected: string;
|
|
54
|
+
"selected-hover": string;
|
|
55
|
+
"mood-super-negative": string;
|
|
56
|
+
"mood-negative": string;
|
|
57
|
+
"mood-neutral": string;
|
|
58
|
+
"mood-positive": string;
|
|
59
|
+
"mood-super-positive": string;
|
|
60
|
+
};
|
|
61
|
+
}, undefined, import("tailwind-variants").TVReturnType<{
|
|
62
|
+
size: {
|
|
63
|
+
xl: string;
|
|
64
|
+
lg: string;
|
|
65
|
+
md: string;
|
|
66
|
+
sm: string;
|
|
67
|
+
xs: string;
|
|
68
|
+
};
|
|
69
|
+
color: {
|
|
70
|
+
default: string;
|
|
71
|
+
secondary: string;
|
|
72
|
+
inverse: string;
|
|
73
|
+
bold: string;
|
|
74
|
+
critical: string;
|
|
75
|
+
"critical-bold": string;
|
|
76
|
+
accent: string;
|
|
77
|
+
info: string;
|
|
78
|
+
warning: string;
|
|
79
|
+
positive: string;
|
|
80
|
+
promote: string;
|
|
81
|
+
selected: string;
|
|
82
|
+
"selected-hover": string;
|
|
83
|
+
"mood-super-negative": string;
|
|
84
|
+
"mood-negative": string;
|
|
85
|
+
"mood-neutral": string;
|
|
86
|
+
"mood-positive": string;
|
|
87
|
+
"mood-super-positive": string;
|
|
88
|
+
};
|
|
89
|
+
}, undefined, "shrink-0", unknown, unknown, undefined>>;
|
|
90
|
+
//# sourceMappingURL=F0Icon.styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"F0Icon.styles.d.ts","sourceRoot":"","sources":["../../../../../src/components/primitives/F0Icon/F0Icon.styles.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uDAoCvB,CAAA"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import type { ForwardRefExoticComponent, RefAttributes } from "react";
|
|
2
|
+
import type { SvgProps } from "react-native-svg";
|
|
3
|
+
import type { Svg } from "react-native-svg";
|
|
4
|
+
import type { VariantProps } from "tailwind-variants";
|
|
5
|
+
import type { iconVariants } from "./F0Icon.styles";
|
|
6
|
+
/**
|
|
7
|
+
* Icon component type - forward ref to SVG component with className support
|
|
8
|
+
*/
|
|
9
|
+
export type IconType = ForwardRefExoticComponent<SvgProps & RefAttributes<Svg> & {
|
|
10
|
+
className?: string;
|
|
11
|
+
}>;
|
|
12
|
+
/**
|
|
13
|
+
* Icon color variants derived from f0-icon-* tokens in src/styles/theme.css
|
|
14
|
+
* Sync is enforced by F0Icon.tokens.spec.ts
|
|
15
|
+
*/
|
|
16
|
+
export declare const ICON_COLORS: readonly ["default", "secondary", "inverse", "bold", "critical", "critical-bold", "accent", "info", "warning", "positive", "promote", "selected", "selected-hover", "mood-super-negative", "mood-negative", "mood-neutral", "mood-positive", "mood-super-positive"];
|
|
17
|
+
export type IconColor = (typeof ICON_COLORS)[number];
|
|
18
|
+
/**
|
|
19
|
+
* Public F0Icon props
|
|
20
|
+
* Supports semantic color via `color` prop, with `className` as escape hatch.
|
|
21
|
+
*/
|
|
22
|
+
export interface F0IconProps extends Omit<SvgProps, "style"> {
|
|
23
|
+
/**
|
|
24
|
+
* Tailwind className for custom styling or color overrides.
|
|
25
|
+
* Prefer the `color` prop for semantic icon colors.
|
|
26
|
+
*/
|
|
27
|
+
className?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Semantic icon color from the F0 design system
|
|
30
|
+
* Maps to f0-icon-* tokens (e.g. color="critical" -> text-f0-icon-critical)
|
|
31
|
+
*/
|
|
32
|
+
color?: IconColor;
|
|
33
|
+
/**
|
|
34
|
+
* Icon component to render (from icons directory)
|
|
35
|
+
*/
|
|
36
|
+
icon: IconType;
|
|
37
|
+
/**
|
|
38
|
+
* Icon size variant
|
|
39
|
+
* @default 'md'
|
|
40
|
+
*/
|
|
41
|
+
size?: VariantProps<typeof iconVariants>["size"];
|
|
42
|
+
/**
|
|
43
|
+
* Test ID for testing
|
|
44
|
+
*/
|
|
45
|
+
testID?: string;
|
|
46
|
+
}
|
|
47
|
+
//# sourceMappingURL=F0Icon.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"F0Icon.types.d.ts","sourceRoot":"","sources":["../../../../../src/components/primitives/F0Icon/F0Icon.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,aAAa,EAAE,MAAM,OAAO,CAAA;AACrE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAA;AAChD,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,kBAAkB,CAAA;AAC3C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAErD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AAEnD;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,yBAAyB,CAC9C,QAAQ,GACN,aAAa,CAAC,GAAG,CAAC,GAAG;IACnB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CACJ,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,WAAW,qQAmBd,CAAA;AAEV,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,WAAW,CAAC,CAAC,MAAM,CAAC,CAAA;AAEpD;;;GAGG;AACH,MAAM,WAAW,WAAY,SAAQ,IAAI,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC1D;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAElB;;;OAGG;IACH,KAAK,CAAC,EAAE,SAAS,CAAA;IAEjB;;OAEG;IACH,IAAI,EAAE,QAAQ,CAAA;IAEd;;;OAGG;IACH,IAAI,CAAC,EAAE,YAAY,CAAC,OAAO,YAAY,CAAC,CAAC,MAAM,CAAC,CAAA;IAEhD;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* F0Icon - Icon primitive component
|
|
3
|
+
*
|
|
4
|
+
* @see F0Icon.md for documentation
|
|
5
|
+
*/
|
|
6
|
+
export { default as F0Icon } from "./F0Icon";
|
|
7
|
+
export type { F0IconProps, IconType, IconColor } from "./F0Icon.types";
|
|
8
|
+
export { ICON_COLORS } from "./F0Icon.types";
|
|
9
|
+
export { applyIconInterop } from "./F0Icon";
|
|
10
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/primitives/F0Icon/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,UAAU,CAAA;AAC5C,YAAY,EAAE,WAAW,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AACtE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AAC5C,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/icons/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,QAAQ,MAAM,OAAO,CAAA;AACjC,OAAO,KAAK,WAAW,MAAM,WAAW,CAAA;AACxC,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,CAAA;AAChC,cAAc,SAAS,CAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/icons/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,QAAQ,MAAM,OAAO,CAAA;AACjC,OAAO,KAAK,WAAW,MAAM,WAAW,CAAA;AACxC,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,CAAA;AAChC,cAAc,SAAS,CAAA"}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@ import { render, fireEvent, screen } from "@testing-library/react-native"
|
|
|
2
2
|
import React from "react"
|
|
3
3
|
|
|
4
4
|
import { ActivityItem, ActivityItemSkeleton } from "../../Activity/ActivityItem"
|
|
5
|
-
import { IconType } from "../../
|
|
5
|
+
import { type IconType } from "../../primitives/F0Icon"
|
|
6
6
|
|
|
7
7
|
// Mock the IconAvatar component
|
|
8
8
|
jest.mock("../../Avatars/IconAvatar", () => ({
|
|
@@ -2,7 +2,7 @@ import { useState } from "react"
|
|
|
2
2
|
import { View, Text, Pressable } from "react-native"
|
|
3
3
|
|
|
4
4
|
import { IconAvatar } from "../../Avatars/exports"
|
|
5
|
-
import { IconType } from "../../
|
|
5
|
+
import { type IconType } from "../../primitives/F0Icon"
|
|
6
6
|
|
|
7
7
|
export type ActivityItemProps = {
|
|
8
8
|
id: string
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { View } from "react-native"
|
|
2
2
|
|
|
3
3
|
import { cn } from "../../../lib/utils"
|
|
4
|
-
import {
|
|
4
|
+
import { F0Icon, type IconType } from "../../primitives/F0Icon"
|
|
5
5
|
|
|
6
6
|
type Props = {
|
|
7
7
|
icon: IconType
|
|
@@ -24,7 +24,11 @@ export const IconAvatar = ({ icon, size = "md", className }: Props) => {
|
|
|
24
24
|
className
|
|
25
25
|
)}
|
|
26
26
|
>
|
|
27
|
-
<
|
|
27
|
+
<F0Icon
|
|
28
|
+
icon={icon}
|
|
29
|
+
size={size}
|
|
30
|
+
className="text-f0-foreground-secondary"
|
|
31
|
+
/>
|
|
28
32
|
</View>
|
|
29
33
|
)
|
|
30
34
|
}
|
|
@@ -2,7 +2,7 @@ import { View } from "react-native"
|
|
|
2
2
|
import Svg, { Defs, LinearGradient, Stop, Path } from "react-native-svg"
|
|
3
3
|
import { tv, type VariantProps } from "tailwind-variants"
|
|
4
4
|
|
|
5
|
-
import { IconType, applyIconInterop } from "../../
|
|
5
|
+
import { type IconType, applyIconInterop } from "../../primitives/F0Icon"
|
|
6
6
|
|
|
7
7
|
import { ModuleId, modules } from "./modules"
|
|
8
8
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { tv, type VariantProps } from "tailwind-variants"
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { F0Icon, type IconType } from "../primitives/F0Icon"
|
|
4
4
|
|
|
5
5
|
const badgeVariants = tv({
|
|
6
6
|
base: "flex shrink-0 items-center justify-center rounded-full",
|
|
@@ -39,7 +39,7 @@ export interface BadgeProps extends VariantProps<typeof badgeVariants> {
|
|
|
39
39
|
|
|
40
40
|
export const Badge = ({ type, size = "md", icon }: BadgeProps) => {
|
|
41
41
|
return (
|
|
42
|
-
<
|
|
42
|
+
<F0Icon
|
|
43
43
|
className={badgeVariants({ type, size })}
|
|
44
44
|
icon={icon}
|
|
45
45
|
size={iconSizes[size]}
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import { render, fireEvent, screen } from "@testing-library/react-native"
|
|
2
2
|
import React from "react"
|
|
3
3
|
|
|
4
|
-
import { IconType } from "../
|
|
4
|
+
import { type IconType } from "../primitives/F0Icon"
|
|
5
5
|
|
|
6
6
|
import { Button } from "./"
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
Icon: () => null,
|
|
8
|
+
jest.mock("../primitives/F0Icon", () => ({
|
|
9
|
+
F0Icon: () => null,
|
|
11
10
|
}))
|
|
12
11
|
|
|
13
12
|
// Mock dependencies
|