From 21da02d83afe7ae85660d4334406d102430975f3 Mon Sep 17 00:00:00 2001 From: TJ Egan Date: Thu, 23 Jan 2020 15:53:52 -0800 Subject: [PATCH 1/2] fix(text-input): rename sizing props --- .../components/src/components/text-input/_text-input.scss | 4 ++-- packages/react/src/components/TextInput/TextInput-story.js | 6 +++--- packages/react/src/components/TextInput/TextInput.js | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/components/src/components/text-input/_text-input.scss b/packages/components/src/components/text-input/_text-input.scss index c52f019894b7..26a544d3f06f 100644 --- a/packages/components/src/components/text-input/_text-input.scss +++ b/packages/components/src/components/text-input/_text-input.scss @@ -44,11 +44,11 @@ } } - .#{$prefix}--text-input--large { + .#{$prefix}--text-input--xl { height: rem(48px); } - .#{$prefix}--text-input--small { + .#{$prefix}--text-input--sm { height: rem(32px); } diff --git a/packages/react/src/components/TextInput/TextInput-story.js b/packages/react/src/components/TextInput/TextInput-story.js index e8de9266088c..2da5d32abcf9 100644 --- a/packages/react/src/components/TextInput/TextInput-story.js +++ b/packages/react/src/components/TextInput/TextInput-story.js @@ -20,9 +20,9 @@ const types = { }; const sizes = { - Large: 'large', - Default: '', - Small: 'small', + 'Extra large size (xl)': 'xl', + 'Regular size (lg)': '', + 'Small size (sm)': 'sm', }; function ControlledPasswordInputApp(props) { diff --git a/packages/react/src/components/TextInput/TextInput.js b/packages/react/src/components/TextInput/TextInput.js index 1e20126ef1c2..3b96ea2965a9 100644 --- a/packages/react/src/components/TextInput/TextInput.js +++ b/packages/react/src/components/TextInput/TextInput.js @@ -146,7 +146,7 @@ TextInput.propTypes = { placeholder: PropTypes.string, /** - * Specify the size of the Text Input. Currently supports either `small` or `large` as an option. If omitted, defaults to standard size + * Specify the size of the Text Input. Currently supports either `sm` or `xl` as an option. */ size: PropTypes.string, From 9650c85b57159a996931ed9e7831553258c00092 Mon Sep 17 00:00:00 2001 From: TJ Egan Date: Thu, 23 Jan 2020 19:17:12 -0800 Subject: [PATCH 2/2] Update packages/react/src/components/TextInput/TextInput.js Co-Authored-By: Vince Picone --- packages/react/src/components/TextInput/TextInput.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/react/src/components/TextInput/TextInput.js b/packages/react/src/components/TextInput/TextInput.js index 3b96ea2965a9..51b72c793f1d 100644 --- a/packages/react/src/components/TextInput/TextInput.js +++ b/packages/react/src/components/TextInput/TextInput.js @@ -148,7 +148,7 @@ TextInput.propTypes = { /** * Specify the size of the Text Input. Currently supports either `sm` or `xl` as an option. */ - size: PropTypes.string, + size: PropTypes.oneOf(['sm', 'xl']), /** * Specify the type of the