/** * @Author: Alex Sorafumo * @Date: 19/09/2016 1:51 PM * @Email: alex@yuion.net * @Filename: img-crop.component.ts * @Last modified by: Yuion * @Last modified time: 15/12/2016 11:30 AM */ import { EventEmitter, OnChanges } from '@angular/core'; import { DropService } from '../../../services/drop-service/drop-service.service'; import 'cropperjs'; export declare class ImageCropComponent implements OnChanges { private drop_service; id: string; circle: boolean; file: any; select: boolean; ratio: string; width: number; saved: EventEmitter<{}>; model: any; private image; private stream; private sub; constructor(drop_service: DropService); ngOnChanges(changes: any): void; ngAfterViewInit(): void; /** * Sets up the size of the cropped image * @return */ setupSize(): void; /** * Loads the image and injects it into the image cropper component * @param Image file from file input field * @return */ loadImage(file: File): void; setImage(img: any): void; /** * Emits the cropped image data. * @return */ saveImage(): void; ngOnDestroy(): void; private setupCropper; }