import { ServiceContainer } from '../../services/ServiceContainer.js';
import { InstanceServiceContainer } from '../../services/InstanceServiceContainer.js';
import { IDesignItem } from '../../item/IDesignItem.js';
import { BaseCustomWebComponentLazyAppend, TypedEvent } from '@node-projects/base-custom-webcomponent';
import { IDesignerCanvas } from './IDesignerCanvas.js';
import { Snaplines } from './Snaplines.js';
import { IUiCommandHandler } from '../../../commandHandling/IUiCommandHandler.js';
import { IUiCommand } from '../../../commandHandling/IUiCommand.js';
import { IExtensionManager } from './extensions/IExtensionManger.js';
import { IPoint } from '../../../interfaces/IPoint.js';
import { OverlayLayerView } from './overlayLayerView.js';
import { IRect } from "../../../interfaces/IRect.js";
import { ISize } from "../../../interfaces/ISize.js";
import { ITool } from "./tools/ITool.js";
import { ContextMenu } from '../../helper/contextMenu/ContextMenu.js';
export declare class DesignerCanvas extends BaseCustomWebComponentLazyAppend implements IDesignerCanvas, IUiCommandHandler {
    #private;
    serviceContainer: ServiceContainer;
    instanceServiceContainer: InstanceServiceContainer;
    containerBoundingRect: DOMRect;
    outerRect: DOMRect;
    clickOverlay: HTMLDivElement;
    private _activeTool;
    private _gridSize;
    get gridSize(): number;
    set gridSize(value: number);
    pasteOffset: number;
    alignOnGrid: boolean;
    alignOnSnap: boolean;
    snapLines: Snaplines;
    overlayLayer: OverlayLayerView;
    rootDesignItem: IDesignItem;
    private _currentPasteOffset;
    private _zoomFactor;
    private _scaleFactor;
    private _canvasOffset;
    private _additionalStyle;
    private _backgroundImage;
    private _enableSelectTextNodesOnClick;
    private _moveGroup;
    private _touchGestureHelper;
    get zoomFactor(): number;
    set zoomFactor(value: number);
    get scaleFactor(): number;
    get canvasOffset(): IPoint;
    set canvasOffset(value: IPoint);
    get canvasOffsetUnzoomed(): IPoint;
    set canvasOffsetUnzoomed(value: IPoint);
    private _pauseAnimations;
    get pauseAnimations(): boolean;
    set pauseAnimations(value: boolean);
    /** Offset when using an iframe as container */
    get containerOffset(): IPoint;
    raiseDesignItemsChanged(designItems: IDesignItem[], action: 'resize' | 'place', operationFinished: boolean): void;
    designItemsChanged: (designItems: IDesignItem[], action: 'resize' | 'place', operationFinished: boolean) => void;
    onZoomFactorChanged: TypedEvent<number>;
    get canvas(): HTMLElement;
    get outercanvas2(): HTMLDivElement;
    private _canvas;
    private _canvasShadowRoot;
    private _canvasContainer;
    private _outercanvas2;
    private _lastHoverDesignItem;
    private _firstConnect;
    static readonly style: CSSStyleSheet;
    static readonly template: HTMLTemplateElement;
    extensionManager: IExtensionManager;
    private _pointerextensions;
    private _lastCopiedPrimaryItem;
    private _ignoreEvent;
    private _useIframe;
    private _iframe;
    private _window;
    private _resizeObserver;
    readonly iframes: HTMLIFrameElement[];
    get readOnly(): boolean;
    set readOnly(v: boolean);
    constructor(useIframe?: boolean);
    get designerWidth(): string;
    set designerWidth(value: string);
    get designerHeight(): string;
    set designerHeight(value: string);
    get designerPixelSize(): {
        width: number;
        height: number;
    };
    getDesignSurfaceDimensions(): ISize;
    get designerOffsetWidth(): number;
    get designerOffsetHeight(): number;
    set additionalStyles(value: CSSStyleSheet[]);
    get additionalStyles(): CSSStyleSheet[];
    private applyAllStyles;
    ignoreEvent(event: Event): void;
    canExecuteCommand(command: IUiCommand): boolean;
    executeCommand(command: IUiCommand): Promise<void>;
    disableBackgroud(): void;
    enableBackground(): void;
    zoomToFit(): void;
    handleSelectAll(): void;
    handleCopyCommand(): Promise<void>;
    handlePasteCommand(disableRestoreOfPositions: boolean): Promise<void>;
    handleDeleteCommand(): void;
    initialize(serviceContainer: ServiceContainer): void;
    connectedCallback(): void;
    disconnectedCallback(): void;
    private _zoomFactorChanged;
    private _resizeBackgroundGrid;
    private _updateTransform;
    setDesignItems(designItems: IDesignItem[]): void;
    _internalSetDesignItems(designItems: IDesignItem[]): void;
    reparseTimeout: NodeJS.Timeout | null;
    lazyTriggerReparseDocumentStylesheets(): void;
    private reparseDocumentStylesheets;
    addDesignItems(designItems: IDesignItem[]): void;
    private _onDragEnter;
    private _onDragLeave;
    private _lastDdElement;
    private _onDragOver;
    private _onDrop;
    showDesignItemContextMenu(designItem: IDesignItem, event: MouseEvent): ContextMenu;
    private _onDblClick;
    private _searchShowOverlay;
    private _searchHideOverlay;
    private _searchRun;
    private onKeyUp;
    private onKeyDown;
    /**
     * Converts the Event x/y coordinates, to the mouse position on the canvas
     */
    getNormalizedEventCoordinates(event: MouseEvent): IPoint;
    /**
     * Converts the Event x/y coordinates, to the mouse position in the viewport
     */
    getViewportCoordinates(event: MouseEvent): IPoint;
    getNormalizedTextNodeCoordinates(element: Text, ignoreScalefactor?: boolean): IRect;
    getNormalizedElementCoordinates(element: Element, ignoreScalefactor?: boolean): IRect;
    getNormalizedElementCoordinatesAndRealSizes(element: Element): IRect & {
        realWidth: number;
        realHeight: number;
    };
    getNormalizedOffsetInElement(event: MouseEvent, element: Element): IPoint;
    private transformPoint;
    elementsFromPoint(x: number, y: number): Element[];
    getElementAtPoint(point: IPoint, ignoreElementCallback?: (element: HTMLElement) => boolean): HTMLElement;
    getDesignItemById(id: string): IDesignItem;
    querySelectorDesignItem(selector: string): IDesignItem;
    querySelectorAllDesignItems(selector: string): IDesignItem[];
    private _hoverElement;
    showHoverExtension(element: Element, event: Event): void;
    private _onWheel;
    private _pointerEventHandlerCapture;
    private _pointerEventHandler;
    captureActiveTool(tool: ITool): void;
    releaseActiveTool(): void;
    get activeTool(): ITool;
    fillCalculationrects(): void;
    removeOverlay(element: SVGGraphicsElement): void;
    zoomOntoRectangle(startPoint: IPoint, endPoint: IPoint): void;
    zoomPoint(canvasPoint: IPoint, newZoom: number): void;
    private zoomConvertEventToViewPortCoordinates;
    zoomTowardsPoint(canvasPoint: IPoint, newZoom: number): void;
}
