From 64fcef23e338ac398328db9e58d4feee2fb56db4 Mon Sep 17 00:00:00 2001 From: Tristan Yang Date: Fri, 17 Mar 2023 20:51:08 +0800 Subject: [PATCH] chore: disabled style in textarea and input --- src/common/component/styled/Input.tsx | 7 ++++++- src/common/component/styled/Textarea.tsx | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/common/component/styled/Input.tsx b/src/common/component/styled/Input.tsx index d71e23ed..f6a1a5d0 100644 --- a/src/common/component/styled/Input.tsx +++ b/src/common/component/styled/Input.tsx @@ -37,7 +37,12 @@ const Input: FC = ({ type = "text", prefix = "", className = "", ...rest const isNone = className.includes("none"); // const noInner=!className.includes("inner"); const isPwd = type == "password"; - const inputClass = clsx(`w-full bg-white dark:bg-gray-800 text-sm text-gray-800 dark:text-gray-200 p-2 outline-none disabled:text-gray-500 disabled:bg-gray-100 dark:disabled:text-gray-500 dark:disabled:bg-gray-800/50 placeholder:text-gray-400`, + const inputClass = clsx(`w-full bg-white dark:bg-gray-800 text-sm text-gray-800 dark:text-gray-200 p-2 outline-none + disabled:text-gray-500 disabled:bg-gray-100 + dark:disabled:text-gray-500 + dark:disabled:bg-gray-800/50 + dark:disabled:border-gray-600 + placeholder:text-gray-400`, // noInner && 'rounded border border-solid border-gray-200 shadow', isLarge && 'py-3', isNone && "border-none bg-transparent shadow-none", diff --git a/src/common/component/styled/Textarea.tsx b/src/common/component/styled/Textarea.tsx index 0420156f..284823e7 100644 --- a/src/common/component/styled/Textarea.tsx +++ b/src/common/component/styled/Textarea.tsx @@ -4,7 +4,7 @@ type Props = TextareaHTMLAttributes const StyledTextarea = forwardRef(({ className, ...rest }: Props, ref) => { return