From a3fff8cbd88f476143b0fbc0826bb6c190a7bae7 Mon Sep 17 00:00:00 2001 From: sohee Date: Wed, 17 Apr 2024 16:11:14 +0900 Subject: [PATCH] hotfix: change inputProps style --- apps/docs/src/stories/TextArea.stories.tsx | 9 +++++---- packages/ui/Input/TextArea.tsx | 4 ++-- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/apps/docs/src/stories/TextArea.stories.tsx b/apps/docs/src/stories/TextArea.stories.tsx index c446cc1..00285ba 100644 --- a/apps/docs/src/stories/TextArea.stories.tsx +++ b/apps/docs/src/stories/TextArea.stories.tsx @@ -12,6 +12,7 @@ interface TextAreaProps extends Omit height?: string; isError?: boolean; onSubmit: () => void; + fixedHeight?: number; } const useTextArea = (props: TextAreaProps) => { @@ -30,7 +31,7 @@ export default { tags: ['autodocs'], args: { value: '', - style: { width: '335px', height: '48px' }, + style: { width: '335px' }, onSubmit: fn(), }, argTypes: { @@ -54,19 +55,19 @@ export const Default: StoryObj = { } }; -export const DoubleLine: StoryObj = { +export const FixedHeight: StoryObj = { args: { labelText: 'Label', descriptionText: 'Description', placeholder: 'Placeholder...', - value: 'text\ntext', + value: 'text\ntext\ntest', maxLength: 300, isError: false, errorMessage: 'error message', required: true, readOnly: false, disabled: false, - style: { width: '335px', height: '76px' }, + fixedHeight: 100, } }; diff --git a/packages/ui/Input/TextArea.tsx b/packages/ui/Input/TextArea.tsx index 1570e85..82ceecb 100644 --- a/packages/ui/Input/TextArea.tsx +++ b/packages/ui/Input/TextArea.tsx @@ -57,12 +57,12 @@ function TextArea(props: TextAreaProps) { const required = inputProps.required ? * : null; const description = descriptionText ?

{descriptionText}

: null; - const input =