fix: update input flow
This commit is contained in:
@@ -42,6 +42,7 @@ function initKeyboardBridge() {
|
||||
const line = buffer;
|
||||
buffer = "";
|
||||
InputModule.submitLocal(line);
|
||||
InputModule.updateLocalDisplay("");
|
||||
} else if (e.key === "Escape") {
|
||||
buffer = "";
|
||||
InputModule.clear();
|
||||
|
||||
+2
-2
@@ -3,7 +3,7 @@ const InputModule = {
|
||||
localBuffer: "",
|
||||
|
||||
submitLine(text, username) {
|
||||
const line = text.trim().toLowerCase();
|
||||
const line = text.trim().toLowerCase().split(/\s+/)[0];
|
||||
if (!line) return;
|
||||
if (introPlaying) return;
|
||||
|
||||
@@ -25,7 +25,7 @@ const InputModule = {
|
||||
},
|
||||
|
||||
submitLocal(text) {
|
||||
const line = text.trim().toLowerCase();
|
||||
const line = text.trim().toLowerCase().split(/\s+/)[0];
|
||||
if (!line) return;
|
||||
if (introPlaying) return;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user