From 29e32695fe64bd86cc7f17c9a176dfc9b4d75d9e Mon Sep 17 00:00:00 2001 From: Vitaly Baev Date: Mon, 30 Aug 2021 23:57:00 +0300 Subject: [PATCH] fix: added role --- src/BaseSuggestions.tsx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/BaseSuggestions.tsx b/src/BaseSuggestions.tsx index 16c7f4d..815365a 100644 --- a/src/BaseSuggestions.tsx +++ b/src/BaseSuggestions.tsx @@ -297,8 +297,13 @@ export abstract class BaseSuggestions extends React.Pu const Component = typeof customInput !== 'undefined' ? (customInput as ElementType) : 'input'; + const optionsExpanded = isFocused && suggestions && displaySuggestions && suggestions.length > 0; return ( -
+
extends React.Pu onBlur={this.handleInputBlur} />
- {isFocused && suggestions && displaySuggestions && suggestions.length > 0 && ( + {optionsExpanded && (
{typeof hintText !== 'undefined' && (
{hintText}