update: re-add progress bar.

This commit is contained in:
ItzNotABug committed 2024-09-27 20:06:48 +05:30
1 parent 0d467f6e4b
commit 4bfd82adb5
2 files changed
+8 -5

No files matched your search

+5 -4
View File
@@ -1,6 +1,6 @@
<script lang="ts">
import { sdk } from '$lib/stores/sdk';
import { type Models, Query } from '@appwrite.io/console';
import { Query } from '@appwrite.io/console';
import { onMount } from 'svelte';
import { isCloud, isSelfHosted } from '$lib/system';
import { organization } from '$lib/stores/organization';
@@ -9,10 +9,11 @@
import { addNotification } from '$lib/stores/notifications';
import { base } from '$app/paths';
import { page } from '$app/stores';
import type { BackupArchive, BackupRestoration } from '$lib/sdk/backups';
let backupRestoreItems: {
archives: Models.BackupArchive[];
restorations: Models.BackupRestoration[];
archives: BackupArchive[];
restorations: BackupRestoration[];
} = {
archives: [],
restorations: []
@@ -147,7 +148,7 @@
};
// TODO: `startedAt` is probably not correct here. need more info.
const backupName = (item: Models.BackupArchive | Models.BackupRestoration, key: string) => {
const backupName = (item: BackupArchive | BackupRestoration, key: string) => {
const attribute = key === 'archives' ? '$createdAt' : 'startedAt';
const date = new Date(item[attribute]);
return `${date.toDateString().slice(4, 10)}, ${date.toTimeString().slice(0, 5)}`;
@@ -1,5 +1,5 @@
<script lang="ts">
import { MigrationBox, UploadBox } from '$lib/components';
import { BackupRestoreBox, MigrationBox, UploadBox } from '$lib/components';
import { sdk } from '$lib/stores/sdk';
import { onMount } from 'svelte';
import { project, stats } from './store';
@@ -105,3 +105,5 @@
<UploadBox />
<MigrationBox />
<BackupRestoreBox />