Merge branch '17782-react-scripts-ts-migration' into main. Closes #17782
[arvados.git] / src / store / file-uploader / file-uploader-actions.ts
index 5a82958d4773a4e90df7ecdd6144b7f16fea8274..8436c485f9ba098efbe0fa880c44c8df7f0c4cb9 100644 (file)
@@ -2,9 +2,9 @@
 //
 // SPDX-License-Identifier: AGPL-3.0
 
-import { unionize, ofType, UnionOf } from "~/common/unionize";
+import { unionize, ofType, UnionOf } from "common/unionize";
 import { Dispatch } from "redux";
-import { RootState } from '~/store/store';
+import { RootState } from 'store/store';
 
 export interface UploadFile {
     id: number;
@@ -17,17 +17,13 @@ export interface UploadFile {
     currentTime: number;
 }
 
-export interface FileWithId extends File {
-    id: number;
-}
-
 export const fileUploaderActions = unionize({
     CLEAR_UPLOAD: ofType(),
     SET_UPLOAD_FILES: ofType<File[]>(),
     UPDATE_UPLOAD_FILES: ofType<File[]>(),
     SET_UPLOAD_PROGRESS: ofType<{ fileId: number, loaded: number, total: number, currentTime: number }>(),
     START_UPLOAD: ofType(),
-    DELETE_UPLOAD_FILE: ofType<FileWithId[]>(),
+    DELETE_UPLOAD_FILE: ofType<UploadFile>(),
 });
 
 export type FileUploaderAction = UnionOf<typeof fileUploaderActions>;