feature(console): autofocus input field after click on a command
Signed-off-by: Stefan Dej <meteyou@gmail.com>
This commit is contained in:
@@ -139,6 +139,10 @@ export default class MiniconsolePanel extends Mixins(BaseMixin) {
|
|||||||
|
|
||||||
commandClick(msg: string): void {
|
commandClick(msg: string): void {
|
||||||
this.gcode = msg
|
this.gcode = msg
|
||||||
|
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.gcodeCommandField.focus()
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
doSend(cmd: KeyboardEvent) {
|
doSend(cmd: KeyboardEvent) {
|
||||||
|
@@ -133,6 +133,10 @@ export default class PageConsole extends Mixins(BaseMixin) {
|
|||||||
|
|
||||||
commandClick(msg: string): void {
|
commandClick(msg: string): void {
|
||||||
this.gcode = msg
|
this.gcode = msg
|
||||||
|
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.gcodeCommandField.focus()
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
doSend(cmd: KeyboardEvent): void {
|
doSend(cmd: KeyboardEvent): void {
|
||||||
|
Reference in New Issue
Block a user