@bothub-chat/ui
Version:
Bothub UI Components
29 lines (28 loc) • 931 B
TypeScript
import { UploadedFileStatus } from './types';
export type Primary = {
variant?: 'primary';
sizeInBytes: number;
fullWidth?: boolean;
};
export type Secondary = {
variant: 'secondary';
loading?: boolean;
};
export type UploadedFileProps = {
filename: string;
progress: number;
status?: UploadedFileStatus;
doneLabel?: React.ReactNode;
errorLabel?: React.ReactNode;
className?: string;
onDelete?: {
disabled?: boolean;
action: () => void;
};
onPause?: () => void;
onResume?: () => void;
onRetry?: () => void;
} & (Primary | Secondary);
export declare const UploadedFile: ({ filename, progress, status, doneLabel, errorLabel, className, onDelete, onPause, onResume, onRetry, ...props }: UploadedFileProps) => import("react/jsx-runtime").JSX.Element;
export * from './types';
export { UploadedFileStatusChip, UploadedFileStatusChipText } from './styled';