From ed971c53fd08b17d42cb3c784897da337ac6de64 Mon Sep 17 00:00:00 2001 From: Jialecl Date: Wed, 16 Oct 2024 16:48:44 +0200 Subject: [PATCH] Added new valid size to the dateinput --- .../screens/components/date-input/code/DateInputCodePage.tsx | 2 +- packages/lib/src/date-input/DateInput.stories.tsx | 4 ++++ packages/lib/src/date-input/types.ts | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/apps/website/screens/components/date-input/code/DateInputCodePage.tsx b/apps/website/screens/components/date-input/code/DateInputCodePage.tsx index 2d9912210..3984fa188 100644 --- a/apps/website/screens/components/date-input/code/DateInputCodePage.tsx +++ b/apps/website/screens/components/date-input/code/DateInputCodePage.tsx @@ -209,7 +209,7 @@ const sections = [ size - 'medium' | 'large' | 'fillParent' + 'small' | 'medium' | 'large' | 'fillParent' Size of the component. diff --git a/packages/lib/src/date-input/DateInput.stories.tsx b/packages/lib/src/date-input/DateInput.stories.tsx index 8fe5370ea..fce54ba07 100644 --- a/packages/lib/src/date-input/DateInput.stories.tsx +++ b/packages/lib/src/date-input/DateInput.stories.tsx @@ -101,6 +101,10 @@ const DateInputChromatic = () => ( + <ExampleContainer> + <Title title="Small size" theme="light" level={4} /> + <DxcDateInput label="Small" size="small" /> + </ExampleContainer> <ExampleContainer> <Title title="Medium size" theme="light" level={4} /> <DxcDateInput label="Medium" size="medium" /> diff --git a/packages/lib/src/date-input/types.ts b/packages/lib/src/date-input/types.ts index 0f33da44a..9480e0321 100644 --- a/packages/lib/src/date-input/types.ts +++ b/packages/lib/src/date-input/types.ts @@ -95,7 +95,7 @@ type Props = { /** * Size of the component. */ - size?: "medium" | "large" | "fillParent"; + size?: "small" | "medium" | "large" | "fillParent"; /** * Value of the tabindex attribute. */