From 0efc5da1b0d905185511108bf35b8162b8e1198c Mon Sep 17 00:00:00 2001 From: emyarod Date: Tue, 22 Oct 2019 17:07:36 -0500 Subject: [PATCH] fix(FilterableMultiSelect): move invalid icon location to match listbox (#4419) --- .../MultiSelect/FilterableMultiSelect.js | 15 +++++++++------ .../FilterableMultiSelect-test.js.snap | 2 +- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/packages/react/src/components/MultiSelect/FilterableMultiSelect.js b/packages/react/src/components/MultiSelect/FilterableMultiSelect.js index fa368bbfaaa8..39ad4ff56641 100644 --- a/packages/react/src/components/MultiSelect/FilterableMultiSelect.js +++ b/packages/react/src/components/MultiSelect/FilterableMultiSelect.js @@ -295,6 +295,9 @@ export default class FilterableMultiSelect extends React.Component { const helper = helperText ? (
{helperText}
) : null; + const inputClasses = cx(`${prefix}--text-input`, { + [`${prefix}--text-input--empty`]: !this.state.inputValue, + }); const input = ( - {invalid && ( - - )} )} (this.inputNode = el)} @@ -373,6 +371,11 @@ export default class FilterableMultiSelect extends React.Component { onKeyDown: this.handleOnInputKeyDown, })} /> + {invalid && ( + + )} {inputValue && isOpen && (