diff --git a/.size-snapshot.json b/.size-snapshot.json index bf36f04..abe8709 100644 --- a/.size-snapshot.json +++ b/.size-snapshot.json @@ -1,37 +1,37 @@ { "react-local-toast.cjs.development.js": { - "bundled": 19762, - "minified": 9871, - "gzipped": 3037 + "bundled": 23250, + "minified": 12659, + "gzipped": 3811 }, "react-local-toast.cjs.production.js": { - "bundled": 19762, - "minified": 9871, - "gzipped": 3037 + "bundled": 23250, + "minified": 12659, + "gzipped": 3811 }, "react-local-toast.esm.js": { - "bundled": 18547, - "minified": 8879, - "gzipped": 2886, + "bundled": 21702, + "minified": 11366, + "gzipped": 3645, "treeshaked": { "rollup": { - "code": 262, - "import_statements": 262 + "code": 169, + "import_statements": 169 }, "webpack": { - "code": 8763 + "code": 11045 } } }, "react-local-toast.umd.development.js": { - "bundled": 110082, - "minified": 34483, - "gzipped": 11267 + "bundled": 108949, + "minified": 33947, + "gzipped": 10979 }, "react-local-toast.umd.production.js": { - "bundled": 59554, - "minified": 21489, - "gzipped": 7176 + "bundled": 58421, + "minified": 20966, + "gzipped": 6878 }, "internals.js": { "bundled": 10559, diff --git a/package.json b/package.json index bf500b3..6f00cd0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-local-toast", - "version": "1.1.4", + "version": "1.2.0", "description": "Local toast helps you to provide feedback related to particular components on page", "main": "dist/index.js", "module": "dist/react-local-toast.esm.js", @@ -52,7 +52,6 @@ "@radix-ui/react-compose-refs": "^1.0.0", "@radix-ui/react-slot": "^0.1.2", "clsx": "^1.1.1", - "react-icons": "^4.4.0", "react-transition-group": "^4.4.2", "tslib": "^2.3.0", "uuid": "^8.3.2" @@ -97,4 +96,4 @@ "shx": "0.3.3", "typescript": "4.3.5" } -} \ No newline at end of file +} diff --git a/src/default-implementation.tsx b/src/default-implementation.tsx index dbcd0ae..103e263 100644 --- a/src/default-implementation.tsx +++ b/src/default-implementation.tsx @@ -1,13 +1,10 @@ import React from 'react'; import clsx from 'clsx'; -import { IoIosCheckmarkCircle, IoIosInformationCircle } from 'react-icons/io'; -import { IoCloseCircleSharp } from 'react-icons/io5'; -import { RiErrorWarningFill } from 'react-icons/ri'; -import { AiOutlineLoading } from 'react-icons/ai'; import { createCustomLocalToast } from './factory'; import { DefaultToastData, ToastPlacement, ToastComponentProps } from './types'; import { DEFAULT_PLACEMENT } from './const'; import { createHocFromHook } from './hoc'; +import { AiOutlineLoading, IoCloseCircleSharp, IoIosCheckmarkCircle, IoIosInformationCircle, RiErrorWarningFill } from './icons'; const animations = { top: 'rltTop', diff --git a/src/icons.tsx b/src/icons.tsx new file mode 100644 index 0000000..3d5b426 --- /dev/null +++ b/src/icons.tsx @@ -0,0 +1,21 @@ +import React, { ComponentProps, forwardRef } from "react"; + +export const IoIosCheckmarkCircle = forwardRef>((props, ref) => { + return (); +}); + +export const IoIosInformationCircle = forwardRef>((props, ref) => { + return (); +}); + +export const IoCloseCircleSharp = forwardRef>((props, ref) => { + return (); +}); + +export const RiErrorWarningFill = forwardRef>((props, ref) => { + return (); +}); + +export const AiOutlineLoading = forwardRef>((props, ref) => { + return (); +}); \ No newline at end of file diff --git a/yarn.lock b/yarn.lock index 0feb83b..b5e180d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5287,11 +5287,6 @@ randomfill@^1.0.3: randombytes "^2.0.5" safe-buffer "^5.1.0" -react-icons@^4.4.0: - version "4.4.0" - resolved "https://registry.yarnpkg.com/react-icons/-/react-icons-4.4.0.tgz#a13a8a20c254854e1ec9aecef28a95cdf24ef703" - integrity sha512-fSbvHeVYo/B5/L4VhB7sBA1i2tS8MkT0Hb9t2H1AVPkwGfVHLJCqyr2Py9dKMxsyM63Eng1GkdZfbWj+Fmv8Rg== - "react-is@^16.12.0 || ^17.0.0 || ^18.0.0": version "18.2.0" resolved "https://registry.yarnpkg.com/react-is/-/react-is-18.2.0.tgz#199431eeaaa2e09f86427efbb4f1473edb47609b"