42 lines
1.3 KiB
TypeScript
Raw Permalink Normal View History

2017-04-04 20:24:55 +02:00
declare module "react-native-image-crop-picker" {
export interface Options {
cropping?: boolean;
width?: number;
height?: number;
multiple?: boolean;
path?: string;
includeBase64?: boolean;
cropperTintColor?: string;
cropperCircleOverlay?: boolean;
maxFiles?: number;
waitAnimationEnd?: boolean;
smartAlbums?: string[];
useFrontCamera?: boolean;
compressVideoPreset?: string;
compressImageMaxWidth?: number;
compressImageMaxHeight?: number;
compressImageQuality?: number;
loadingLabelText?: string;
mediaType?: string;
showsSelectedCount?: boolean;
showCropGuidelines?: boolean;
hideBottomControls?: boolean;
enableRotationGesture?: boolean;
}
export interface Image {
path: string;
size: number;
data: null | string;
width: number;
height: number;
mime: string;
}
export function openPicker(options: Options): Promise<Image | Image[]>;
export function openCamera(options: Options): Promise<Image | Image[]>;
2017-04-14 10:12:14 +08:00
export function openCropper(options: Options): Promise<Image>;
export function clean(): Promise<void>;
export function cleanSingle(path: string): Promise<void>;
2017-04-04 20:24:55 +02:00
}