diff --git a/desktop/src/main/ipc.ts b/desktop/src/main/ipc.ts index 23e8604c2..0fdd10056 100644 --- a/desktop/src/main/ipc.ts +++ b/desktop/src/main/ipc.ts @@ -180,12 +180,12 @@ export const attachIPCHandlers = () => { ipcMain.handle( "saveStreamToDisk", - (_, path: string, fileStream: ReadableStream) => + (_, path: string, fileStream: ReadableStream) => saveStreamToDisk(path, fileStream), ); - ipcMain.handle("saveFileToDisk", (_, path: string, file: any) => - saveFileToDisk(path, file), + ipcMain.handle("saveFileToDisk", (_, path: string, contents: string) => + saveFileToDisk(path, contents), ); ipcMain.handle("readTextFile", (_, path: string) => readTextFile(path)); diff --git a/desktop/src/preload.ts b/desktop/src/preload.ts index b4efd862e..0d2c8f7bf 100644 --- a/desktop/src/preload.ts +++ b/desktop/src/preload.ts @@ -32,9 +32,9 @@ * and when changing one of them, remember to see if the other two also need * changing: * - * - [renderer] web/packages/shared/electron/types.ts contains docs - * - [preload] desktop/src/preload.ts ↕︎ - * - [main] desktop/src/main/ipc.ts contains impl + * - [renderer] web/packages/next/types/electron.ts contains docs + * - [preload] desktop/src/preload.ts ↕︎ + * - [main] desktop/src/main/ipc.ts contains impl */ import { contextBridge, ipcRenderer } from "electron/renderer"; @@ -227,11 +227,11 @@ const checkExistsAndCreateDir = (dirPath: string): Promise => const saveStreamToDisk = ( path: string, - fileStream: ReadableStream, + fileStream: ReadableStream, ): Promise => ipcRenderer.invoke("saveStreamToDisk", path, fileStream); -const saveFileToDisk = (path: string, file: any): Promise => - ipcRenderer.invoke("saveFileToDisk", path, file); +const saveFileToDisk = (path: string, contents: string): Promise => + ipcRenderer.invoke("saveFileToDisk", path, contents); const readTextFile = (path: string): Promise => ipcRenderer.invoke("readTextFile", path); diff --git a/web/apps/photos/src/components/Directory/index.tsx b/web/apps/photos/src/components/Directory/index.tsx index a87202771..154db456e 100644 --- a/web/apps/photos/src/components/Directory/index.tsx +++ b/web/apps/photos/src/components/Directory/index.tsx @@ -1,5 +1,5 @@ +import ElectronAPIs from "@/next/electron"; import LinkButton from "@ente/shared/components/LinkButton"; -import ElectronAPIs from "@ente/shared/electron"; import { logError } from "@ente/shared/sentry"; import { Tooltip } from "@mui/material"; import { styled } from "@mui/material/styles"; diff --git a/web/apps/photos/src/components/FilesDownloadProgress.tsx b/web/apps/photos/src/components/FilesDownloadProgress.tsx index 8c86f8757..1185cc61c 100644 --- a/web/apps/photos/src/components/FilesDownloadProgress.tsx +++ b/web/apps/photos/src/components/FilesDownloadProgress.tsx @@ -1,4 +1,4 @@ -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import Notification from "components/Notification"; import { t } from "i18next"; import isElectron from "is-electron"; diff --git a/web/apps/photos/src/components/Sidebar/DebugSection.tsx b/web/apps/photos/src/components/Sidebar/DebugSection.tsx index b2d07bb47..93967b8f8 100644 --- a/web/apps/photos/src/components/Sidebar/DebugSection.tsx +++ b/web/apps/photos/src/components/Sidebar/DebugSection.tsx @@ -3,7 +3,7 @@ import { AppContext } from "pages/_app"; import { useContext, useEffect, useState } from "react"; import { Trans } from "react-i18next"; -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { addLogLine } from "@ente/shared/logging"; import { getDebugLogs } from "@ente/shared/logging/web"; import { downloadAsFile } from "@ente/shared/utils"; diff --git a/web/apps/photos/src/components/Upload/Uploader.tsx b/web/apps/photos/src/components/Upload/Uploader.tsx index f1d6d03ff..b1557c77b 100644 --- a/web/apps/photos/src/components/Upload/Uploader.tsx +++ b/web/apps/photos/src/components/Upload/Uploader.tsx @@ -1,4 +1,4 @@ -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { CustomError } from "@ente/shared/error"; import { addLogLine } from "@ente/shared/logging"; import { logError } from "@ente/shared/sentry"; diff --git a/web/apps/photos/src/components/WatchFolder/index.tsx b/web/apps/photos/src/components/WatchFolder/index.tsx index ee002f3dc..9c8d536e0 100644 --- a/web/apps/photos/src/components/WatchFolder/index.tsx +++ b/web/apps/photos/src/components/WatchFolder/index.tsx @@ -6,8 +6,8 @@ import watchFolderService from "services/watchFolder/watchFolderService"; import { WatchMapping } from "types/watchFolder"; import { MappingList } from "./mappingList"; +import ElectronAPIs from "@/next/electron"; import DialogTitleWithCloseButton from "@ente/shared/components/DialogBox/TitleWithCloseButton"; -import ElectronAPIs from "@ente/shared/electron"; import UploadStrategyChoiceModal from "components/Upload/UploadStrategyChoiceModal"; import { PICKED_UPLOAD_TYPE, UPLOAD_STRATEGY } from "constants/upload"; import isElectron from "is-electron"; diff --git a/web/apps/photos/src/pages/_app.tsx b/web/apps/photos/src/pages/_app.tsx index b8b289c11..dfcc0536d 100644 --- a/web/apps/photos/src/pages/_app.tsx +++ b/web/apps/photos/src/pages/_app.tsx @@ -1,5 +1,7 @@ import { CustomHead } from "@/next/components/Head"; +import ElectronAPIs from "@/next/electron"; import { setupI18n } from "@/next/i18n"; +import { AppUpdateInfo } from "@/next/types/ipc"; import { APPS, APP_TITLES, @@ -20,8 +22,6 @@ import EnteSpinner from "@ente/shared/components/EnteSpinner"; import { MessageContainer } from "@ente/shared/components/MessageContainer"; import AppNavbar from "@ente/shared/components/Navbar/app"; import { PHOTOS_PAGES as PAGES } from "@ente/shared/constants/pages"; -import ElectronAPIs from "@ente/shared/electron"; -import { AppUpdateInfo } from "@ente/shared/electron/types"; import { CustomError } from "@ente/shared/error"; import { Events, eventBus } from "@ente/shared/events"; import { useLocalState } from "@ente/shared/hooks/useLocalState"; diff --git a/web/apps/photos/src/pages/gallery/index.tsx b/web/apps/photos/src/pages/gallery/index.tsx index 5930dd30b..606216afa 100644 --- a/web/apps/photos/src/pages/gallery/index.tsx +++ b/web/apps/photos/src/pages/gallery/index.tsx @@ -89,9 +89,9 @@ import { splitNormalAndHiddenCollections, } from "utils/collection"; +import ElectronAPIs from "@/next/electron"; import { APPS } from "@ente/shared/apps/constants"; import { CenteredFlex } from "@ente/shared/components/Container"; -import ElectronAPIs from "@ente/shared/electron"; import useFileInput from "@ente/shared/hooks/useFileInput"; import useMemoSingleThreaded from "@ente/shared/hooks/useMemoSingleThreaded"; import InMemoryStore, { MS_KEYS } from "@ente/shared/storage/InMemoryStore"; diff --git a/web/apps/photos/src/pages/index.tsx b/web/apps/photos/src/pages/index.tsx index c789e0ae4..1b46f199b 100644 --- a/web/apps/photos/src/pages/index.tsx +++ b/web/apps/photos/src/pages/index.tsx @@ -1,3 +1,4 @@ +import ElectronAPIs from "@/next/electron"; import Login from "@ente/accounts/components/Login"; import SignUp from "@ente/accounts/components/SignUp"; import { APPS } from "@ente/shared/apps/constants"; @@ -5,7 +6,6 @@ import { EnteLogo } from "@ente/shared/components/EnteLogo"; import EnteSpinner from "@ente/shared/components/EnteSpinner"; import { PHOTOS_PAGES as PAGES } from "@ente/shared/constants/pages"; import { saveKeyInSessionStore } from "@ente/shared/crypto/helpers"; -import ElectronAPIs from "@ente/shared/electron"; import { getAlbumsURL } from "@ente/shared/network/api"; import { logError } from "@ente/shared/sentry"; import localForage from "@ente/shared/storage/localForage"; diff --git a/web/apps/photos/src/services/clipService.ts b/web/apps/photos/src/services/clipService.ts index 71cc17131..278c406d7 100644 --- a/web/apps/photos/src/services/clipService.ts +++ b/web/apps/photos/src/services/clipService.ts @@ -1,5 +1,5 @@ +import ElectronAPIs from "@/next/electron"; import ComlinkCryptoWorker from "@ente/shared/crypto"; -import ElectronAPIs from "@ente/shared/electron"; import { CustomError } from "@ente/shared/error"; import { Events, eventBus } from "@ente/shared/events"; import { addLogLine } from "@ente/shared/logging"; diff --git a/web/apps/photos/src/services/export/index.ts b/web/apps/photos/src/services/export/index.ts index 35d23b72a..c1fa2cbe1 100644 --- a/web/apps/photos/src/services/export/index.ts +++ b/web/apps/photos/src/services/export/index.ts @@ -37,7 +37,7 @@ import { } from "utils/file"; import { decodeLivePhoto } from "../livePhotoService"; -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { CustomError } from "@ente/shared/error"; import { Events, eventBus } from "@ente/shared/events"; import { addLogLine } from "@ente/shared/logging"; diff --git a/web/apps/photos/src/services/ffmpeg/ffmpegFactory.ts b/web/apps/photos/src/services/ffmpeg/ffmpegFactory.ts index 040f15047..decd32521 100644 --- a/web/apps/photos/src/services/ffmpeg/ffmpegFactory.ts +++ b/web/apps/photos/src/services/ffmpeg/ffmpegFactory.ts @@ -1,4 +1,4 @@ -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import isElectron from "is-electron"; import { ElectronFile } from "types/upload"; import ComlinkFFmpegWorker from "utils/comlink/ComlinkFFmpegWorker"; diff --git a/web/apps/photos/src/services/importService.ts b/web/apps/photos/src/services/importService.ts index c663524b3..833e1b3e2 100644 --- a/web/apps/photos/src/services/importService.ts +++ b/web/apps/photos/src/services/importService.ts @@ -1,4 +1,4 @@ -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { logError } from "@ente/shared/sentry"; import { PICKED_UPLOAD_TYPE } from "constants/upload"; import { Collection } from "types/collection"; diff --git a/web/apps/photos/src/services/upload/thumbnailService.ts b/web/apps/photos/src/services/upload/thumbnailService.ts index 61e42f9e9..788d110ce 100644 --- a/web/apps/photos/src/services/upload/thumbnailService.ts +++ b/web/apps/photos/src/services/upload/thumbnailService.ts @@ -1,4 +1,4 @@ -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { CustomError } from "@ente/shared/error"; import { addLogLine } from "@ente/shared/logging"; import { getFileNameSize } from "@ente/shared/logging/web"; diff --git a/web/apps/photos/src/services/watchFolder/watchFolderService.ts b/web/apps/photos/src/services/watchFolder/watchFolderService.ts index 8ebc38afd..184ba5256 100644 --- a/web/apps/photos/src/services/watchFolder/watchFolderService.ts +++ b/web/apps/photos/src/services/watchFolder/watchFolderService.ts @@ -1,4 +1,4 @@ -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { addLocalLog, addLogLine } from "@ente/shared/logging"; import { logError } from "@ente/shared/sentry"; import { UPLOAD_RESULT, UPLOAD_STRATEGY } from "constants/upload"; diff --git a/web/apps/photos/src/utils/collection/index.ts b/web/apps/photos/src/utils/collection/index.ts index bf9b7face..a2f066ac8 100644 --- a/web/apps/photos/src/utils/collection/index.ts +++ b/web/apps/photos/src/utils/collection/index.ts @@ -1,4 +1,4 @@ -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { CustomError } from "@ente/shared/error"; import { addLogLine } from "@ente/shared/logging"; import { getAlbumsURL } from "@ente/shared/network/api"; diff --git a/web/apps/photos/src/utils/file/index.ts b/web/apps/photos/src/utils/file/index.ts index 2e02794c4..b432ab4d5 100644 --- a/web/apps/photos/src/utils/file/index.ts +++ b/web/apps/photos/src/utils/file/index.ts @@ -52,7 +52,7 @@ import { } from "services/fileService"; import { FileTypeInfo } from "types/upload"; -import { default as ElectronAPIs } from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { workerBridge } from "@ente/shared/worker/worker-bridge"; import { t } from "i18next"; import { getFileExportPath, getUniqueFileExportName } from "utils/export"; diff --git a/web/apps/photos/src/utils/ui/index.tsx b/web/apps/photos/src/utils/ui/index.tsx index 75b0cd23d..d193ba960 100644 --- a/web/apps/photos/src/utils/ui/index.tsx +++ b/web/apps/photos/src/utils/ui/index.tsx @@ -1,7 +1,7 @@ +import ElectronAPIs from "@/next/electron"; +import { AppUpdateInfo } from "@/next/types/ipc"; import { logoutUser } from "@ente/accounts/services/user"; import { DialogBoxAttributes } from "@ente/shared/components/DialogBox/types"; -import ElectronAPIs from "@ente/shared/electron"; -import { AppUpdateInfo } from "@ente/shared/electron/types"; import AutoAwesomeOutlinedIcon from "@mui/icons-material/AutoAwesomeOutlined"; import InfoOutlined from "@mui/icons-material/InfoRounded"; import { Link } from "@mui/material"; diff --git a/web/apps/photos/tests/zip-file-reading.test.ts b/web/apps/photos/tests/zip-file-reading.test.ts index 0152e5897..afc647634 100644 --- a/web/apps/photos/tests/zip-file-reading.test.ts +++ b/web/apps/photos/tests/zip-file-reading.test.ts @@ -1,4 +1,4 @@ -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { getFileNameSize } from "@ente/shared/logging/web"; import { FILE_READER_CHUNK_SIZE, PICKED_UPLOAD_TYPE } from "constants/upload"; import isElectron from "is-electron"; diff --git a/web/packages/accounts/pages/credentials.tsx b/web/packages/accounts/pages/credentials.tsx index 3ce2a9c27..98a78c1b4 100644 --- a/web/packages/accounts/pages/credentials.tsx +++ b/web/packages/accounts/pages/credentials.tsx @@ -24,6 +24,7 @@ import { PAGES } from "../constants/pages"; import { generateSRPSetupAttributes } from "../services/srp"; import { logoutUser } from "../services/user"; +import ElectronAPIs from "@/next/electron"; import { APP_HOMES } from "@ente/shared/apps/constants"; import { PageProps } from "@ente/shared/apps/types"; import { VerticallyCentered } from "@ente/shared/components/Container"; @@ -37,7 +38,6 @@ import VerifyMasterPasswordForm, { } from "@ente/shared/components/VerifyMasterPasswordForm"; import ComlinkCryptoWorker from "@ente/shared/crypto"; import { B64EncryptionResult } from "@ente/shared/crypto/types"; -import ElectronAPIs from "@ente/shared/electron"; import { CustomError } from "@ente/shared/error"; import { addLocalLog } from "@ente/shared/logging"; import { getAccountsURL } from "@ente/shared/network/api"; diff --git a/web/packages/accounts/services/user.ts b/web/packages/accounts/services/user.ts index 4fb56db63..6a2da8521 100644 --- a/web/packages/accounts/services/user.ts +++ b/web/packages/accounts/services/user.ts @@ -1,4 +1,4 @@ -import ElectronAPIs from "@ente/shared/electron"; +import ElectronAPIs from "@/next/electron"; import { Events, eventBus } from "@ente/shared/events"; import { logError } from "@ente/shared/sentry"; import InMemoryStore from "@ente/shared/storage/InMemoryStore"; diff --git a/web/packages/next/electron.ts b/web/packages/next/electron.ts new file mode 100644 index 000000000..9f02bf799 --- /dev/null +++ b/web/packages/next/electron.ts @@ -0,0 +1,10 @@ +import type { ElectronAPIsType } from "./types/ipc"; + +// TODO (MR): +// eslint-disable-next-line @typescript-eslint/no-explicit-any +const ElectronAPIs = (globalThis as unknown as any)[ + // eslint-disable-next-line @typescript-eslint/dot-notation, @typescript-eslint/no-unsafe-member-access + "ElectronAPIs" +] as ElectronAPIsType; + +export default ElectronAPIs; diff --git a/web/packages/shared/upload/types.ts b/web/packages/next/types/file.ts similarity index 53% rename from web/packages/shared/upload/types.ts rename to web/packages/next/types/file.ts index d9811bef9..e7d3ced5a 100644 --- a/web/packages/shared/upload/types.ts +++ b/web/packages/next/types/file.ts @@ -1,3 +1,8 @@ +export enum UPLOAD_STRATEGY { + SINGLE_COLLECTION, + COLLECTION_PER_FOLDER, +} + /* * ElectronFile is a custom interface that is used to represent * any file on disk as a File-like object in the Electron desktop app. @@ -20,3 +25,25 @@ export interface DataStream { stream: ReadableStream; chunkCount: number; } + +export interface WatchMappingSyncedFile { + path: string; + uploadedFileID: number; + collectionID: number; +} + +export interface WatchMapping { + rootFolderName: string; + folderPath: string; + uploadStrategy: UPLOAD_STRATEGY; + syncedFiles: WatchMappingSyncedFile[]; + ignoredFiles: string[]; +} + +export interface EventQueueItem { + type: "upload" | "trash"; + folderPath: string; + collectionName?: string; + paths?: string[]; + files?: ElectronFile[]; +} diff --git a/web/packages/shared/electron/types.ts b/web/packages/next/types/ipc.ts similarity index 96% rename from web/packages/shared/electron/types.ts rename to web/packages/next/types/ipc.ts index b48ab3bd3..46c4a4293 100644 --- a/web/packages/shared/electron/types.ts +++ b/web/packages/next/types/ipc.ts @@ -3,8 +3,7 @@ // // See [Note: types.ts <-> preload.ts <-> ipc.ts] -import type { ElectronFile } from "@ente/shared/upload/types"; -import type { WatchMapping } from "@ente/shared/watchFolder/types"; +import type { ElectronFile, WatchMapping } from "./file"; export interface AppUpdateInfo { autoUpdatable: boolean; @@ -199,9 +198,9 @@ export interface ElectronAPIsType { checkExistsAndCreateDir: (dirPath: string) => Promise; saveStreamToDisk: ( path: string, - fileStream: ReadableStream, + fileStream: ReadableStream, ) => Promise; - saveFileToDisk: (path: string, file: any) => Promise; + saveFileToDisk: (path: string, contents: string) => Promise; readTextFile: (path: string) => Promise; isFolder: (dirPath: string) => Promise; moveFile: (oldPath: string, newPath: string) => Promise; diff --git a/web/packages/shared/components/Directory/index.tsx b/web/packages/shared/components/Directory/index.tsx index a87202771..154db456e 100644 --- a/web/packages/shared/components/Directory/index.tsx +++ b/web/packages/shared/components/Directory/index.tsx @@ -1,5 +1,5 @@ +import ElectronAPIs from "@/next/electron"; import LinkButton from "@ente/shared/components/LinkButton"; -import ElectronAPIs from "@ente/shared/electron"; import { logError } from "@ente/shared/sentry"; import { Tooltip } from "@mui/material"; import { styled } from "@mui/material/styles"; diff --git a/web/packages/shared/crypto/helpers.ts b/web/packages/shared/crypto/helpers.ts index a29dc465f..ba659f9aa 100644 --- a/web/packages/shared/crypto/helpers.ts +++ b/web/packages/shared/crypto/helpers.ts @@ -7,7 +7,7 @@ import { getActualKey } from "@ente/shared/user"; import { KeyAttributes } from "@ente/shared/user/types"; import isElectron from "is-electron"; import ComlinkCryptoWorker from "."; -import ElectronAPIs from "../electron"; +import ElectronAPIs from "@/next/electron"; import { addLogLine } from "../logging"; const LOGIN_SUB_KEY_LENGTH = 32; diff --git a/web/packages/shared/crypto/types.ts b/web/packages/shared/crypto/types.ts index 2eeea7027..4cf4c56b1 100644 --- a/web/packages/shared/crypto/types.ts +++ b/web/packages/shared/crypto/types.ts @@ -1,4 +1,4 @@ -import { DataStream } from "@ente/shared/upload/types"; +import { DataStream } from "@/next/types/file"; export interface LocalFileAttributes< T extends string | Uint8Array | DataStream, diff --git a/web/packages/shared/electron/index.ts b/web/packages/shared/electron/index.ts deleted file mode 100644 index 38e38e3a4..000000000 --- a/web/packages/shared/electron/index.ts +++ /dev/null @@ -1,5 +0,0 @@ -import { ElectronAPIsType } from "./types"; - -const ElectronAPIs: ElectronAPIsType = globalThis["ElectronAPIs"]; - -export default ElectronAPIs; diff --git a/web/packages/shared/logging/index.ts b/web/packages/shared/logging/index.ts index db9938300..961b2d3a0 100644 --- a/web/packages/shared/logging/index.ts +++ b/web/packages/shared/logging/index.ts @@ -1,7 +1,7 @@ import { inWorker, isDevBuild } from "@/next/env"; import { logError } from "@ente/shared/sentry"; import isElectron from "is-electron"; -import ElectronAPIs from "../electron"; +import ElectronAPIs from "@/next/electron"; import { workerBridge } from "../worker/worker-bridge"; import { formatLog, logWeb } from "./web"; diff --git a/web/packages/shared/logging/web.ts b/web/packages/shared/logging/web.ts index 69e00533e..fe54931fc 100644 --- a/web/packages/shared/logging/web.ts +++ b/web/packages/shared/logging/web.ts @@ -1,4 +1,5 @@ import { isDevBuild } from "@/next/env"; +import { ElectronFile } from "@/next/types/file"; import { logError } from "@ente/shared/sentry"; import { LS_KEYS, @@ -8,7 +9,6 @@ import { } from "@ente/shared/storage/localStorage"; import { addLogLine } from "."; import { formatDateTimeShort } from "../time/format"; -import { ElectronFile } from "../upload/types"; import type { User } from "../user/types"; import { convertBytesToHumanReadable } from "../utils/size"; diff --git a/web/packages/shared/upload/constants.ts b/web/packages/shared/upload/constants.ts deleted file mode 100644 index aaa7f60d2..000000000 --- a/web/packages/shared/upload/constants.ts +++ /dev/null @@ -1,4 +0,0 @@ -export enum UPLOAD_STRATEGY { - SINGLE_COLLECTION, - COLLECTION_PER_FOLDER, -} diff --git a/web/packages/shared/watchFolder/types.ts b/web/packages/shared/watchFolder/types.ts index bea23247a..e69de29bb 100644 --- a/web/packages/shared/watchFolder/types.ts +++ b/web/packages/shared/watchFolder/types.ts @@ -1,24 +0,0 @@ -import { UPLOAD_STRATEGY } from "@ente/shared/upload/constants"; -import { ElectronFile } from "@ente/shared/upload/types"; - -export interface WatchMappingSyncedFile { - path: string; - uploadedFileID: number; - collectionID: number; -} - -export interface WatchMapping { - rootFolderName: string; - folderPath: string; - uploadStrategy: UPLOAD_STRATEGY; - syncedFiles: WatchMappingSyncedFile[]; - ignoredFiles: string[]; -} - -export interface EventQueueItem { - type: "upload" | "trash"; - folderPath: string; - collectionName?: string; - paths?: string[]; - files?: ElectronFile[]; -} diff --git a/web/packages/shared/worker/comlinkWorker.ts b/web/packages/shared/worker/comlinkWorker.ts index f8e72778f..b1d9d4fde 100644 --- a/web/packages/shared/worker/comlinkWorker.ts +++ b/web/packages/shared/worker/comlinkWorker.ts @@ -1,6 +1,6 @@ import { addLocalLog, logToDisk } from "@ente/shared/logging"; import { Remote, expose, wrap } from "comlink"; -import ElectronAPIs from "../electron"; +import ElectronAPIs from "@/next/electron"; import { logError } from "../sentry"; export class ComlinkWorker InstanceType> {