chore: de-dedupe dependencies and make the build green 🤞

Signed-off-by: blam <ben@blam.sh>
This commit is contained in:
blam
2022-02-09 11:50:56 +01:00
parent b947238d1d
commit c2cbcaf234
4 changed files with 209 additions and 12 deletions
@@ -15,7 +15,7 @@
*/
import React, { CSSProperties, DependencyList } from 'react';
import { useAsync } from 'react-use';
import useAsync from 'react-use/lib/useAsync';
import { Box, LinearProgress } from '@material-ui/core';
import Timeline from '@material-ui/lab/Timeline';
import TimelineItem from '@material-ui/lab/TimelineItem';
@@ -16,6 +16,7 @@
import React, { CSSProperties } from 'react';
import { DateTime, Duration } from 'luxon';
import humanizeDuration from 'humanize-duration';
import { capitalize } from 'lodash';
const infoText: CSSProperties = { color: 'InfoText' };
@@ -124,7 +125,7 @@ export function formatDuration(millis: number) {
...(seconds && !days && !hours && { seconds }),
});
return dur.toHuman({ unitDisplay: 'narrow' }).replace(/, /g, '');
return humanizeDuration(dur.toMillis(), { round: true });
}
export function formatDurationFromSeconds(seconds: number) {