import React from 'react';
import { UseAsyncReturn } from 'react-async-hook';
import { IBackup } from '@shared/interfaces/model';
import ExtendedSelection, { ItemsOrKeys } from '@admin/helpers/selection';
import { SelectionMode } from '@fluentui/react';
import { ModelState } from '@admin/helpers/hooks';
declare type Arrayable<T> = T | T[];
interface IFileWithData {
    file: File;
    data?: any;
}
interface IUpload {
    status?: 'uploading' | 'done';
    name?: string;
    progress?: number;
}
interface IUploads {
    [key: string]: IUpload;
}
export interface IBackupContext {
    list: UseAsyncReturn<IBackup[], []>;
    get: UseAsyncReturn<IBackup, [id: number]>;
    create: UseAsyncReturn<IBackup, [partial: Partial<IBackup>]>;
    download: (id: number) => void;
    remove: UseAsyncReturn<null, [id: number]>;
    restore: UseAsyncReturn<any, [id: number, force?: boolean]>;
    selectedBackups: IBackup[];
    selection: ExtendedSelection<IBackup>;
    upload: UseAsyncReturn<any, [Arrayable<IFileWithData>]>;
    uploads: IUploads;
    backupState: ModelState<IBackup>;
    backups: IBackup[];
}
export interface IBackupContextProviderProps {
    defaultSelectedBackups?: ItemsOrKeys<IBackup>;
    selectionMode?: SelectionMode;
}
declare const BackupContextProvider: React.FC<IBackupContextProviderProps>;
declare const useBackups: () => IBackupContext;
export { BackupContextProvider, useBackups };
