import { CircularProgress } from "@material-ui/core"; import { FunctionComponent } from "react"; import { formatByteCount } from "@figurl/core-utils"; type Props = { loaded?: number total?: number } const ProgressComponent: FunctionComponent = ({loaded, total}) => { return (
{ total ? ( Loaded {formatByteCount(loaded || 0)} of {formatByteCount(total || 0)} ) : Waiting for data }
) } export default ProgressComponent