mapcomplete/UI/Input/InputElement.ts

19 lines
456 B
TypeScript
Raw Normal View History

2022-09-08 21:40:48 +02:00
import { Store, UIEventSource } from "../../Logic/UIEventSource"
import BaseUIElement from "../BaseUIElement"
/**
* @deprecated
*/
2022-09-08 21:40:48 +02:00
export interface ReadonlyInputElement<T> extends BaseUIElement {
GetValue(): Store<T>
IsValid(t: T): boolean
}
/**
* @deprecated
*/
2022-09-08 21:40:48 +02:00
export abstract class InputElement<T> extends BaseUIElement implements ReadonlyInputElement<any> {
abstract GetValue(): UIEventSource<T>
abstract IsValid(t: T): boolean
2020-07-23 17:32:18 +02:00
}