feat(web): show download size (#3270)

* feat(web): show download size

* chore: never over 100%

* chore: use percentage

* fix: unselect assets before download finishes
This commit is contained in:
Jason Rasmussen 2023-07-14 21:25:13 -04:00 committed by GitHub
parent 81e07fda08
commit 382341f550
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 99 additions and 42 deletions

View file

@ -1,7 +1,12 @@
import type { ApiError } from '@api';
import { CanceledError } from 'axios';
import { notificationController, NotificationType } from '../components/shared-components/notification/notification';
export async function handleError(error: unknown, message: string) {
if (error instanceof CanceledError) {
return;
}
console.error(`[handleError]: ${message}`, error);
let data = (error as ApiError)?.response?.data;