Show completions only command

This commit is contained in:
Shin'ya Ueoka 2018-10-20 16:13:06 +09:00
parent 5ecada5b23
commit 7acbdbfef2

View file

@ -97,9 +97,12 @@ export default class ConsoleComponent {
} }
onInput(e) { onInput(e) {
let state = this.store.getState();
let text = e.target.value; let text = e.target.value;
this.store.dispatch(consoleActions.setConsoleText(text)); this.store.dispatch(consoleActions.setConsoleText(text));
this.store.dispatch(consoleActions.getCompletions(text)); if (state.mode === 'command') {
this.store.dispatch(consoleActions.getCompletions(text));
}
} }
onInputShown(state) { onInputShown(state) {