Update
This commit is contained in:
@@ -14,7 +14,7 @@ import {
|
||||
import { t } from "i18next";
|
||||
import { useCallback, useMemo, useState } from "react";
|
||||
import AutoSizer from "react-virtualized-auto-sizer";
|
||||
import uploadManager from "services/upload/uploadManager";
|
||||
import { uploadManager } from "services/upload-manager";
|
||||
import { SetFilesDownloadProgressAttributesCreator } from "types/gallery";
|
||||
import { downloadSingleFile } from "utils/file";
|
||||
import {
|
||||
|
||||
@@ -8,7 +8,7 @@ import {
|
||||
} from "ente-shared/components/Container";
|
||||
import { t } from "i18next";
|
||||
import { Trans } from "react-i18next";
|
||||
import uploadManager from "services/upload/uploadManager";
|
||||
import { uploadManager } from "services/upload-manager";
|
||||
|
||||
export default function GalleryEmptyState({ openUploader }) {
|
||||
return (
|
||||
|
||||
@@ -65,8 +65,8 @@ import type {
|
||||
UploadCounter,
|
||||
UploadFileNames,
|
||||
UploadItemWithCollection,
|
||||
} from "services/upload/uploadManager";
|
||||
import uploadManager from "services/upload/uploadManager";
|
||||
} from "services/upload-manager";
|
||||
import { uploadManager } from "services/upload-manager";
|
||||
import watcher from "services/watch";
|
||||
import { SetLoading } from "types/gallery";
|
||||
import { getOrCreateAlbum } from "utils/collection";
|
||||
|
||||
@@ -39,7 +39,7 @@ import type {
|
||||
SegregatedFinishedUploads,
|
||||
UploadCounter,
|
||||
UploadFileNames,
|
||||
} from "services/upload/uploadManager";
|
||||
} from "services/upload-manager";
|
||||
|
||||
interface UploadProgressProps {
|
||||
open: boolean;
|
||||
|
||||
@@ -116,7 +116,7 @@ import {
|
||||
removeFromFavorites,
|
||||
} from "services/collectionService";
|
||||
import exportService from "services/export";
|
||||
import uploadManager from "services/upload/uploadManager";
|
||||
import { uploadManager } from "services/upload-manager";
|
||||
import { isTokenValid } from "services/userService";
|
||||
import {
|
||||
GalleryContextType,
|
||||
|
||||
@@ -73,7 +73,7 @@ import {
|
||||
savePublicCollectionPassword,
|
||||
syncPublicFiles,
|
||||
} from "services/publicCollectionService";
|
||||
import uploadManager from "services/upload/uploadManager";
|
||||
import { uploadManager } from "services/upload-manager";
|
||||
import {
|
||||
SelectedState,
|
||||
SetFilesDownloadProgressAttributes,
|
||||
|
||||
@@ -12,7 +12,7 @@ import { logoutSearch } from "ente-new/photos/services/search";
|
||||
import { logoutSettings } from "ente-new/photos/services/settings";
|
||||
import { logoutUserDetails } from "ente-new/photos/services/user-details";
|
||||
import exportService from "./export";
|
||||
import uploadManager from "./upload/uploadManager";
|
||||
import { uploadManager } from "./upload-manager";
|
||||
|
||||
/**
|
||||
* Logout sequence for the photos app.
|
||||
|
||||
@@ -14,6 +14,18 @@ import {
|
||||
type UploadPhase,
|
||||
type UploadResult,
|
||||
} from "ente-gallery/services/upload";
|
||||
import {
|
||||
metadataJSONMapKeyForJSON,
|
||||
tryParseTakeoutMetadataJSON,
|
||||
type ParsedMetadataJSON,
|
||||
} from "ente-gallery/services/upload/takeout";
|
||||
import UploadService, {
|
||||
areLivePhotoAssets,
|
||||
uploadItemFileName,
|
||||
uploader,
|
||||
type PotentialLivePhotoAsset,
|
||||
type UploadAsset,
|
||||
} from "ente-gallery/services/upload/upload-service";
|
||||
import { processVideoNewUpload } from "ente-gallery/services/video";
|
||||
import type { Collection } from "ente-media/collection";
|
||||
import {
|
||||
@@ -34,18 +46,6 @@ import {
|
||||
} from "services/publicCollectionService";
|
||||
import watcher from "services/watch";
|
||||
import { getUserOwnedFiles } from "utils/file";
|
||||
import {
|
||||
metadataJSONMapKeyForJSON,
|
||||
tryParseTakeoutMetadataJSON,
|
||||
type ParsedMetadataJSON,
|
||||
} from "./takeout";
|
||||
import UploadService, {
|
||||
areLivePhotoAssets,
|
||||
uploadItemFileName,
|
||||
uploader,
|
||||
type PotentialLivePhotoAsset,
|
||||
type UploadAsset,
|
||||
} from "./upload-service";
|
||||
|
||||
export type FileID = number;
|
||||
|
||||
@@ -705,7 +705,10 @@ class UploadManager {
|
||||
};
|
||||
}
|
||||
|
||||
export default new UploadManager();
|
||||
/**
|
||||
* Singleton instance of {@link UploadManager}.
|
||||
*/
|
||||
export const uploadManager = new UploadManager();
|
||||
|
||||
/**
|
||||
* The data operated on by the intermediate stages of the upload.
|
||||
|
||||
@@ -20,10 +20,8 @@ import {
|
||||
groupFilesByCollectionID,
|
||||
} from "ente-new/photos/services/files";
|
||||
import { ensureString } from "ente-utils/ensure";
|
||||
import uploadManager, {
|
||||
type UploadItemWithCollection,
|
||||
} from "services/upload/uploadManager";
|
||||
import { removeFromCollection } from "./collectionService";
|
||||
import { type UploadItemWithCollection, uploadManager } from "./upload-manager";
|
||||
|
||||
/**
|
||||
* Watch for file system folders and automatically update the corresponding Ente
|
||||
|
||||
@@ -57,7 +57,7 @@ import {
|
||||
generateThumbnailNative,
|
||||
generateThumbnailWeb,
|
||||
} from "./thumbnail";
|
||||
import type { UploadableUploadItem } from "./uploadManager";
|
||||
import type { UploadableUploadItem } from "./upload-manager";
|
||||
|
||||
const publicUploadHttpClient = new PublicUploadHttpClient();
|
||||
const UploadHttpClient = new PhotosUploadHttpClient();
|
||||
|
||||
Reference in New Issue
Block a user