conjure-os/frontend/src/inputs/key-contexts/sidebar-key-context.ts
2025-07-19 19:58:57 +00:00

33 lines
756 B
TypeScript

import { KeyContext } from "./key-context";
import { InputManager } from "../input-manager";
export class SidebarKeyContext extends KeyContext {
readonly name: string = "SidebarContext";
protected onKeyUp() {
super.onKeyUp();
this.store.moveTagUp();
}
protected onKeyDown() {
super.onKeyDown();
this.store.moveTagDown();
}
protected onKeyRight() {
super.onKeyRight();
this.store.moveGameRight();
InputManager.switchContext("carousel")
}
protected onEnter() {
super.onEnter();
this.store.moveGameRight();
InputManager.switchContext("carousel")
}
protected onEscape() {
super.onEscape();
// TODO options menu
}
}