import * as Y from 'yjs';
import EventEmitter from 'eventemitter3';
import { type UserManager } from '@netless/forge-room';
import { WhiteboardToolType } from '../WhiteboardApplication';
import { CurveModel } from './renderable/CurveModel';
import { ElementModel } from './renderable/ElementModel';
import { SelectorModel } from './renderable/SelectorModel';
import { SegmentsModel, SegmentsType } from './renderable/SegmentsModel';
import { LineModel } from './renderable/LineModel';
import { PointTextModel } from './renderable/PointTextModel';
import { ToolbarModel } from './ToolbarModel';
import { TriangleModel } from './renderable/TriangleModel';
import { RectangleModel } from './renderable/RectangleModel';
import { EraserModel } from './renderable/EraserModel';
import { LaserPointerModel } from './renderable/LaserPointerModel';
import { WhiteboardPermissionFlag } from '../WhitePermissions';
import { ShadowEmitter } from '../utils/ShadowEmitter';
import { StraightLineModel } from './renderable/StraightLineModel';
import { LiveCursor } from '../LiveCursor';
export interface DrawableElement {
    tool: WhiteboardToolType;
    points: number[];
    stroke: string;
    fill: string;
    strokeWidth: number;
}
interface WhiteboardModelEvents {
    elementClear: () => void;
    elementInsert: (elements: ElementModel[]) => void;
    elementRemove: (elementId: string, layerId: string) => void;
}
export declare class RenderableModel extends EventEmitter<WhiteboardModelEvents> {
    private scope;
    private toolbarModel;
    private userManager;
    elementModels: Map<string, ElementModel>;
    elements: Y.Map<Y.Map<any>>;
    private layerId;
    private maxIndex;
    private hasPermission;
    private shadowEmitter;
    private imageSets;
    private liveCursor;
    private isPerformanceMode;
    private get uuid();
    constructor(options: {
        layerId: string;
        shadowEmitter: ShadowEmitter;
        elements: Y.Map<Y.Map<any>>;
        scope: paper.PaperScope;
        toolbarModel: ToolbarModel;
        userManager: UserManager;
        imageSets: HTMLDivElement;
        liveCursor: LiveCursor;
        hasPermission: (flag: WhiteboardPermissionFlag) => boolean;
        isPerformanceMode: () => boolean;
    });
    flushRenderables(): void;
    private onElementsChange;
    convertToModel(yMap: Y.Map<any>): ElementModel | null;
    private initElement;
    removeElementItem(uuid: string): void;
    private confirmPermission;
    createImage(src: string): void;
    private fitImageToViewport;
    private setElementPointsMatrix;
    createCurve(shadow?: boolean): CurveModel | null;
    createLaserPointer(): LaserPointerModel | null;
    createEraser(): EraserModel | null;
    createTriangle(shadow: boolean): TriangleModel | null;
    createRectangle(shadow: boolean): RectangleModel | null;
    createSegmentedPath(type: SegmentsType, shadow: boolean): SegmentsModel | null;
    createSelector(_shadow?: boolean): SelectorModel | null;
    createStraightLine(shadow: boolean): StraightLineModel | null;
    createLinePath(shadow: boolean): LineModel | null;
    createPointText(x: number, y: number, shadow: boolean): PointTextModel | null;
    clearElement(): void;
    dispose(clearElements: boolean): void;
}
export {};
//# sourceMappingURL=RenderableModel.d.ts.map