|
@@ -155,7 +155,7 @@ class AutoCompleteFoundation<P = Record<string, any>, S = Record<string, any>> e
|
|
|
this._adapter.notifySearch(inputValue);
|
|
|
this._adapter.notifyChange(inputValue);
|
|
|
this._modifyFocusIndex(inputValue);
|
|
|
- if (!this.isPanelOpen){
|
|
|
+ if (!this.isPanelOpen) {
|
|
|
this.openDropdown();
|
|
|
}
|
|
|
}
|
|
@@ -335,6 +335,9 @@ class AutoCompleteFoundation<P = Record<string, any>, S = Record<string, any>> e
|
|
|
case KeyCode.ESC:
|
|
|
this.closeDropdown();
|
|
|
break;
|
|
|
+ case KeyCode.TAB:
|
|
|
+ this.closeDropdown();
|
|
|
+ break;
|
|
|
default:
|
|
|
break;
|
|
|
}
|
|
@@ -383,7 +386,7 @@ class AutoCompleteFoundation<P = Record<string, any>, S = Record<string, any>> e
|
|
|
|
|
|
_handleArrowKeyDown(offset: number): void {
|
|
|
const { visible } = this.getStates();
|
|
|
- if (!visible){
|
|
|
+ if (!visible) {
|
|
|
this.openDropdown();
|
|
|
} else {
|
|
|
this._getEnableFocusIndex(offset);
|
|
@@ -392,7 +395,7 @@ class AutoCompleteFoundation<P = Record<string, any>, S = Record<string, any>> e
|
|
|
|
|
|
_handleEnterKeyDown() {
|
|
|
const { visible, options, focusIndex } = this.getStates();
|
|
|
- if (!visible){
|
|
|
+ if (!visible) {
|
|
|
this.openDropdown();
|
|
|
} else {
|
|
|
if (focusIndex !== undefined && focusIndex !== -1 && options.length !== 0) {
|
|
@@ -424,7 +427,7 @@ class AutoCompleteFoundation<P = Record<string, any>, S = Record<string, any>> e
|
|
|
// internal-issues:1231
|
|
|
setTimeout(() => {
|
|
|
this._adapter.notifyBlur(e);
|
|
|
- this.closeDropdown();
|
|
|
+ // this.closeDropdown();
|
|
|
}, 100);
|
|
|
}
|
|
|
}
|