enum InputState {
Command,
+ View,
}
var inputState = InputState.Command;
if (event.key == "X") return BrowserUI.setState("deleted");
if (event.key == "u") return BrowserUI.undo();
if (event.key == "e") return BrowserUI.beginEdit(event);
+ if (event.key == "v") return (inputState = InputState.View);
+ } else if (inputState === InputState.View) {
+ return (inputState = InputState.Command);
}
}
}