/** * Manages the state and positioning of tiles within a tile manager. * * @public */ export declare class TileManagerTilesState { private _nextEmptyPosition; private _tiles; /** * Constructs a new instance of the `TileManagerTilesState` class. * * @public */ constructor(); /** * Returns the current tiles sorted by their position. * * @public * @readonly */ get tiles(): Array; /** * Updates the tiles state with a new list of tiles. * * @param tiles - The tiles to update. * * @public */ update(tiles: Array): void; /** * Assigns positions to tiles, respecting explicitly set positions. * * @public */ assignPositions(): void; /** * Adds a new tile to the state. * * @param tile - The tile to add. * * @public */ add(tile: ITileElement): void; /** * Checks and adjusts tile spans based on the column count. * * @param columnCount - The column count. * * @public */ adjustTileGridPosition(columnCount: number): void; } /** * Factory function to create a new TileManagerTilesState instance. * * @returns A new TileManagerTilesState instance. * * @public */ export declare function createTileManagerTilesState(): TileManagerTilesState; /** * Manages the drag stack during tile drag operations. * * @public */ export declare class TileManagerDragStack { private _stack; /** * Constructs a new instance of the `TileManagerDragStack` class. * * @public */ constructor(); /** * Gets the current stack. * * @public * @readonly */ get stack(): Array; /** * Gets the length of the stack. * * @public * @readonly */ get length(): number; /** * Pushes a tile onto the stack with its current state. * * @param tile - The tile to push. * * @public */ push(tile: ITileElement): void; /** * Pops the last entry from the stack. * * @returns The popped entry, or undefined. * * @public */ pop(): ITileDragStackEntry | undefined; /** * Clears the stack. * * @public */ reset(): void; /** * Returns the tile from the last entry in the stack. * * @returns The last tile, or undefined. * * @public */ peek(): ITileElement | undefined; /** * Restores all tiles to their original state when the drag operation was started. * Processes the stack in reverse order to correctly restore positions. * * @public */ restore(): void; } /** * Factory function to create a new TileManagerDragStack instance. * * @returns A new TileManagerDragStack instance. * * @public */ export declare function createTileManagerDragStack(): TileManagerDragStack; /** * Swaps the positions of two tiles. * * @param sourceTile - The source tile. * @param targetTile - The target tile. * * @public */ export declare function swapTiles(sourceTile: ITileElement, targetTile: ITileElement): void; //# sourceMappingURL=TileManagerPosition.d.ts.map