diff --git a/src/@next/Select/components/Activator/ActivatorTextInput.tsx b/src/@next/Select/components/Activator/ActivatorTextInput.tsx index e2b97c91e..11c90ce0a 100644 --- a/src/@next/Select/components/Activator/ActivatorTextInput.tsx +++ b/src/@next/Select/components/Activator/ActivatorTextInput.tsx @@ -31,6 +31,7 @@ export const ActivatorTextInput = ({ disabled = false, hasError = false, onChange, + onBlur, onFocus, onSelect, prefix = , @@ -81,6 +82,7 @@ export const ActivatorTextInput = ({ ref={activatorRef} prefix={prefix} onChange={value => handleChange({ value })} + onBlur={onBlur} onFocus={onFocus} error={hasError} disabled={disabled} @@ -92,6 +94,7 @@ export const ActivatorTextInput = ({ ref={activatorRef} prefix={prefix} filterOptions={filterOptions} + onBlur={onBlur} onFocus={onFocus} onInputChange={onChange} onSelect={onSelect} diff --git a/src/@next/Select/components/SearchableSelectInput/SearchableSelectInput.tsx b/src/@next/Select/components/SearchableSelectInput/SearchableSelectInput.tsx index aaf83aae0..26cb38e7c 100644 --- a/src/@next/Select/components/SearchableSelectInput/SearchableSelectInput.tsx +++ b/src/@next/Select/components/SearchableSelectInput/SearchableSelectInput.tsx @@ -49,6 +49,7 @@ export const SearchableSelectInput = forwardRef< inputValue, updateInputValue, onInputChange, + onBlur, onFocus, searchableSelectState: { showInput, showPlaceholder, showSelected }, updateSearchableSelectState, @@ -116,7 +117,7 @@ export const SearchableSelectInput = forwardRef< updateMenuOptions(options); }; - const handleInputBlur = () => { + const handleInputBlur = (e: React.FocusEvent) => { if (disabled) return; setIsSelectedClicked(false); @@ -132,6 +133,8 @@ export const SearchableSelectInput = forwardRef< }); }, 100); } + + onBlur?.(e); }; useEffect(() => {