import { full_screen_selector } from "./full-screen-selector.js"; import { selector } from "./selector.js"; import { selector_item } from "./selector-item.js"; import { types } from "assets/types.js"; class mode_selector extends full_screen_selector { #on_shelf; #on_space; constructor(app) { super(app, "mode-selector"); this.#on_shelf = () => {}; this.#on_space = () => {}; this.add(new selector_item( "Shelf", "./theme/icons/shelf.svg", () => { this.#on_shelf(app); } )); this.add(new selector_item( "Space", "./theme/icons/space.svg", () => { this.#on_space(app); } )); } set on_space(target) { types.check_callback(target); this.#on_space = target; } get on_space() { return this.#on_space; } set on_shelf(target) { types.check_callback(target); this.#on_shelf = target; } get on_shelf() { return this.#on_shelf; } } export { mode_selector };