import React from 'react';
import { type MediaClient, type FileState } from '@atlaskit/media-client';
import { Outcome } from '../../domain';
import { MediaViewerError } from '../../errors';
import { BaseViewer } from '../base-viewer';
import { type MediaTraceContext } from '@atlaskit/media-common';
export type ObjectUrl = string;
export type ImageViewerProps = {
    mediaClient: MediaClient;
    item: FileState;
    collectionName?: string;
    onLoad: () => void;
    onError: (error: MediaViewerError) => void;
    onClose?: () => void;
    contextId?: string;
    traceContext: MediaTraceContext;
};
export interface ImageViewerContent {
    objectUrl: ObjectUrl;
    originalBinaryImageUrl?: string;
    orientation?: number;
}
export declare class ImageViewer extends BaseViewer<ImageViewerContent, ImageViewerProps> {
    protected get initialState(): {
        content: Outcome<ImageViewerContent, MediaViewerError>;
    };
    private cancelImageFetch?;
    protected init(): Promise<void>;
    protected release(): void;
    revokeObjectUrl(objectUrl: string): void;
    protected renderSuccessful(content: ImageViewerContent): React.JSX.Element | null;
    private onLoad;
    private onImgError;
}
