diff --git a/package-lock.json b/package-lock.json index 4621230..f643e9e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,6 +13,7 @@ "@hookform/error-message": "^2.0.1", "@hookform/resolvers": "^3.10.0", "@reduxjs/toolkit": "^2.5.0", + "classnames": "^2.5.1", "moment": "^2.30.1", "motion": "^12.7.4", "react": "^18.3.1", @@ -2440,6 +2441,11 @@ "node": ">= 6" } }, + "node_modules/classnames": { + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/classnames/-/classnames-2.5.1.tgz", + "integrity": "sha512-saHYOzhIQs6wy2sVxTM6bUDsQO4F50V9RQ22qBpEdCW+I+/Wmke2HOl6lS6dTpdxVhb88/I6+Hs+438c3lfUow==" + }, "node_modules/cli-cursor": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-5.0.0.tgz", diff --git a/package.json b/package.json index afbfa99..1a56901 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,7 @@ "@hookform/error-message": "^2.0.1", "@hookform/resolvers": "^3.10.0", "@reduxjs/toolkit": "^2.5.0", + "classnames": "^2.5.1", "moment": "^2.30.1", "motion": "^12.7.4", "react": "^18.3.1", diff --git a/src/components/Button/index.tsx b/src/components/Button/index.tsx index 2f993cf..589cc47 100644 --- a/src/components/Button/index.tsx +++ b/src/components/Button/index.tsx @@ -1,3 +1,5 @@ +import {twMerge} from 'tailwind-merge'; + import {TButtonProps} from './types'; import {buttonVariants} from './variants'; @@ -6,15 +8,15 @@ const Button = ({ startIcon = null, endIcon = null, text = '', - className, + className = '', children, ...restProps }: TButtonProps) => { return (