From d5aae5838b27a665b5350fb6a862ac67d01a904e Mon Sep 17 00:00:00 2001 From: Jitendra Nirnejak Date: Wed, 15 May 2024 19:39:47 +0530 Subject: [PATCH] Button: disable option added --- components/atoms/Button.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/components/atoms/Button.tsx b/components/atoms/Button.tsx index 9ae9568..8141f7d 100644 --- a/components/atoms/Button.tsx +++ b/components/atoms/Button.tsx @@ -32,6 +32,7 @@ interface Props { children: React.ReactNode type?: "reset" | "button" | "submit" className?: string + disabled?: boolean isBlock?: boolean onClick?: () => void } @@ -42,6 +43,7 @@ const Button: React.FC = ({ type = "button", className, onClick, + disabled, isBlock = false, ...props }) => { @@ -68,6 +70,7 @@ const Button: React.FC = ({ isBlock && "block", className )} + disabled={disabled} {...props} > {children}