import { ChangeDetectorRef } from "@angular/core"; import { FeedbackService } from "./feedback.service"; import { FeedbackConfiguration } from "./feedback-configuration.model"; import { DomSanitizer } from "@angular/platform-browser"; export declare class FeedbackScreenshotComponent { private changeDetection; private feedback; configuration: FeedbackConfiguration; domSanitizer: DomSanitizer; screenshots: string[]; uploadErrorMessage: string; private canvas; private canvasContext; private isDrawing; private centerX; private centerY; private highlight; private highlightLeft; private highlightTop; private highlightWidth; private highlightHeight; private preRenderScrollPosition; private mouseDownListener; private mouseMoveListener; private mouseUpListener; constructor(changeDetection: ChangeDetectorRef, domSanitizer: DomSanitizer, feedback: FeedbackService); /** * Add transparent background to canvas. */ private addCanvasAlphaBackground(); /** * Add a screenshot from local machine. * @param event the event of selecting image. */ addScreenshot(event: any): void; /** * Adjust the drawing according to user movement. * @param x the x-axis movement position. * @param y the y-axis movement position. */ private adjustDrawing(x, y); /** * Clear highlight params. */ private clearHighlightParams(); /** * Clear all screenshots. */ clearScreenshots(): void; /** * Check if upload file is allowed. * @param file the file. * @return {boolean} wheter allowed or not. */ private checkIsUploadFileAllowed(file); /** * Create a canvas of the page. */ private createCanvas(); /** * Destroy the page canvas. */ destroyCanvas(): void; /** * Enter the screenshot mode. */ enterScreenshotMode(): void; /** * Finish drawing at given position. * @param x the x-axis page position to finish at. * @param y the y-axis page position to finish at. */ private finishDrawing(x, y); /** * Get the max image count allowed. * @return {boolean} the count. */ getMaxImageCount(): number; /** * Check whether max image count has been reached. * @return {boolean} whether max image count has been reached. */ isMaxImageCountReached(): boolean; /** * Process rendered screenshot. * @param canvas the canvas. * @param onlyHighlighted whether to capture only highlighted area. */ private processRenderedScreenshot(canvas, onlyHighlighted); /** * Redraw the canvas context. */ private redraw(); /** * Remove image at given index. * @param index the index in screenshot array. */ remove(index: number): void; /** * Remove transparent background from canvas. */ private removeCanvasAlphaBackground(); /** * Remove the mouse drawing events. */ private removeMouseDrawingEvents(); /** * Setup mouse drawing events. */ private setupMouseDrawingEvents(); /** * Start drawing from given position. * @param x the x-axis page position to start at. * @param y the y-axis page position to start at. */ private startDrawing(x, y); /** * Capture a screenshot. */ takeScreenshot(): void; }