import HTMLElement_ from '../../../../../client/html';
import { System } from '../../../../../system';
import { Dict } from '../../../../../types/Dict';
import { CA } from '../../../../../types/interface/CA';
export declare function clearCanvas(context: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D): void;
export interface Props {
    className?: string;
    style?: Dict<string>;
    attr?: Dict<string>;
    width?: number | string;
    height?: number | string;
    sx?: number;
    sy?: number;
    d?: any[];
}
export default class CanvasComp extends HTMLElement_<HTMLCanvasElement, Props> implements CA {
    private _context;
    private _d;
    constructor($props: Props, $system: System);
    reset(): void;
    private _setup;
    private _get_parent_width;
    private _get_parent_height;
    private _get_frame_width;
    private _get_frame_height;
    private _create_canvas;
    private _reset;
    private _reset_redraw;
    private _set_width;
    private _set_height;
    private _width_frame_unlisten;
    private _height_frame_unlisten;
    private _get_fill_style;
    private _unlisten_frame_width;
    private _unlisten_frame_height;
    private _draw;
    private _draw_steps;
    private _redraw;
    private _reset_context;
    onMount(): void;
    draw(step: any[]): Promise<void>;
    clear(_?: undefined): Promise<void>;
    drawImage(image: CanvasImageSource, x: number, y: number, width: number, height: number): Promise<void>;
    strokePath(d: string): void;
    private _strokePath;
    fillPath(d: string, fillRule: CanvasFillRule): void;
    private _fillPath;
    translate(x: number, y: number): void;
    scale(sx: number, sy: number): void;
    toBlob(type: string, quality: number): Promise<Blob>;
    toDataUrl(type: string, quality: number): Promise<string>;
    captureStream({ frameRate, }: {
        frameRate: number;
    }): Promise<MediaStream>;
    getImageData(x: number, y: number, width: number, height: number, opt: ImageDataSettings): Promise<ImageData>;
    putImageData(image: ImageData, dx: number, dy: number, x: number, y: number, width: number, height: number): Promise<void>;
}
