another small improvement
This commit is contained in:
1 parent
79ab1285c5
commit
d43cbcc5c9
2 files changed
+1
-6
No files matched your search
@@ -61,7 +61,7 @@
|
||||
(click)="handleCursorActivity()"
|
||||
(keyup)="handleCursorActivity()"
|
||||
(keydown)="onKeydown($event)"
|
||||
(keydown.enter)="onEnter($event)"
|
||||
(keydown.enter)="$event.preventDefault(); runCommand()"
|
||||
(focus)="onFocus()"
|
||||
(blur)="onBlur()"
|
||||
class="terminal-field"
|
||||
|
||||
@@ -113,11 +113,6 @@ export class TerminalEmulatorComponent implements OnInit, OnChanges {
|
||||
}
|
||||
}
|
||||
|
||||
onEnter(event: Event): void {
|
||||
event.preventDefault();
|
||||
this.runCommand();
|
||||
}
|
||||
|
||||
runCommand() {
|
||||
const cmd = this.command.trim();
|
||||
if (!cmd || this.booting) return;
|
||||
|
||||
Reference in new issue
Block a user