import type Pointer from "./../../input/pointer.ts";
import type { Vector2d } from "../../math/vector2d.ts";
import Container from "../container.js";
/**
* This is a basic clickable and draggable container which you can use in your game UI.
* Use this for example if you want to display a panel that contains text, images or other UI elements.
* @category UI
*/
export default class UIBaseElement extends Container {
/**
* UI base elements use screen coordinates by default
* (Note: any child elements added to a UIBaseElement should have their floating property to false)
* @see Renderable.floating
* @default true
*/
floating: boolean;
/**
* object can be clicked or not
* @default true
*/
isClickable: boolean;
/**
* object can be dragged or not
* @default false
*/
isDraggable: boolean;
/**
* Tap and hold threshold timeout in ms
* @default 250
*/
holdThreshold: number;
/**
* object can be tap and hold
* @default false
*/
isHoldable: boolean;
/**
* true if the pointer is over the object
* @default false
*/
hover: boolean;
/**
* false if the pointer is down, or true when the pointer status is up
* @default true
*/
released: boolean;
holdTimeout: number;
grabOffset: Vector2d | undefined;
/**
* @param x - The x position of the container
* @param y - The y position of the container
* @param w - width of the container
* @param h - height of the container
*/
constructor(x: number, y: number, w?: number, h?: number);
/**
* function callback for the pointerdown event
* @ignore
*/
clicked(event: Pointer): boolean | void;
/**
* function called when the object is pressed (to be extended)
* @param _event - the event object
* @returns return false if we need to stop propagating the event
*/
onClick(_event?: Pointer): boolean;
/**
* function callback for the pointerEnter event
* @ignore
*/
enter(event: Pointer): void;
/**
* pointermove function
* @ignore
*/
pointerMove(event: Pointer): void;
/**
* function called when the pointer is moved over the object
* @param _event - the event object
*/
onMove(_event?: Pointer): void;
/**
* function called when the pointer is over the object
* @param _event - the event object
*/
onOver(_event?: Pointer): void;
/**
* function callback for the pointerLeave event
* @ignore
*/
leave(event: Pointer): void;
/**
* function called when the pointer is leaving the object area
* @param _event - the event object
*/
onOut(_event?: Pointer): void;
/**
* function callback for the pointerup event
* @ignore
*/
release(event: Pointer): boolean | void;
/**
* function called when the object is pressed and released (to be extended)
* @param _event - the event object
* @returns return false if we need to stop propagating the event
*/
onRelease(_event?: Pointer): boolean;
/**
* function callback for the tap and hold timer event
* @ignore
*/
hold(): void;
/**
* function called when the object is pressed and held
* to be extended
*/
onHold(): void;
/**
* function called when added to the game world or a container
* @ignore
*/
onActivateEvent(): void;
/**
* function called when removed from the game world or a container
* @ignore
*/
onDeactivateEvent(): void;
}
//# sourceMappingURL=uibaseelement.d.ts.map