@bbl-digital/snorre 3.0.9 → 3.0.10

Sign up to get free protection for your applications and to get access to all the features.
@@ -12,8 +12,8 @@ const useAutocomplete = props => {
12
12
  const [inputValues, setInputValues] = useState(props.values);
13
13
 
14
14
  const handleValueClick = value => {
15
- props.onSelectItem?.(value);
16
15
  setShowValues(false);
16
+ props.onSelectItem?.(value);
17
17
  };
18
18
 
19
19
  const clearSelectedItem = () => handleValueClick({
@@ -48,10 +48,7 @@ const useAutocomplete = props => {
48
48
  setValueChanged(val);
49
49
  handleValueClick(valueInInputValues);
50
50
  return;
51
- } // Otherwise we should return to the original input value
52
-
53
-
54
- setValueChanged(props.value ?? '');
51
+ }
55
52
  }
56
53
  };
57
54