diff --git a/package-lock.json b/package-lock.json index 6094797b..7b5df90b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -24,6 +24,7 @@ "filesize": "5.0.x", "fuse.js": "3.4.x", "interactjs": "1.6.x", + "jszip": "^3.10.1", "lodash": "4.17.x", "lru-cache": "5.1.x", "normalize.css": "8.0.x", @@ -3235,12 +3236,6 @@ "@types/ms": "*" } }, - "node_modules/@types/electron-devtools-installer": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/@types/electron-devtools-installer/-/electron-devtools-installer-2.2.2.tgz", - "integrity": "sha512-8o2XkyAw2HZoVD5KpIoUJmEgZ7BPVv33p7rY1jmn/wJUbugtQUc44vNMDTguUNUGiLv+oqgtyYmiYctHDZEzdQ==", - "dev": true - }, "node_modules/@types/enzyme": { "version": "3.10.12", "resolved": "https://registry.npmjs.org/@types/enzyme/-/enzyme-3.10.12.tgz", @@ -7862,46 +7857,6 @@ "node": ">= 10.0.0" } }, - "node_modules/electron-devtools-installer": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/electron-devtools-installer/-/electron-devtools-installer-3.1.1.tgz", - "integrity": "sha512-g2D4J6APbpsiIcnLkFMyKZ6bOpEJ0Ltcc2m66F7oKUymyGAt628OWeU9nRZoh1cNmUs/a6Cls2UfOmsZtE496Q==", - "dependencies": { - "rimraf": "^3.0.2", - "semver": "^7.2.1", - "unzip-crx-3": "^0.2.0" - } - }, - "node_modules/electron-devtools-installer/node_modules/lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "dependencies": { - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/electron-devtools-installer/node_modules/semver": { - "version": "7.3.7", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.7.tgz", - "integrity": "sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g==", - "dependencies": { - "lru-cache": "^6.0.0" - }, - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/electron-devtools-installer/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" - }, "node_modules/electron-mocha": { "version": "11.0.2", "resolved": "https://registry.npmjs.org/electron-mocha/-/electron-mocha-11.0.2.tgz", @@ -10940,7 +10895,7 @@ "node_modules/immediate": { "version": "3.0.6", "resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz", - "integrity": "sha1-nbHb0Pr43m++D13V5Wu2BigN5ps=" + "integrity": "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ==" }, "node_modules/import-fresh": { "version": "3.3.0", @@ -11933,14 +11888,14 @@ } }, "node_modules/jszip": { - "version": "3.9.1", - "resolved": "https://registry.npmjs.org/jszip/-/jszip-3.9.1.tgz", - "integrity": "sha512-H9A60xPqJ1CuC4Ka6qxzXZeU8aNmgOeP5IFqwJbQQwtu2EUYxota3LdsiZWplF7Wgd9tkAd0mdu36nceSaPuYw==", + "version": "3.10.1", + "resolved": "https://registry.npmjs.org/jszip/-/jszip-3.10.1.tgz", + "integrity": "sha512-xXDvecyTpGLrqFrvkrUSoxxfJI5AH7U8zxxtVclpsUtMCq4JQ290LY8AW5c7Ggnr/Y/oK+bQMbqK2qmtk3pN4g==", "dependencies": { "lie": "~3.3.0", "pako": "~1.0.2", "readable-stream": "~2.3.6", - "set-immediate-shim": "~1.0.1" + "setimmediate": "^1.0.5" } }, "node_modules/just-extend": { @@ -12986,7 +12941,8 @@ "node_modules/minimist": { "version": "1.2.6", "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", - "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==" + "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==", + "dev": true }, "node_modules/minipass": { "version": "4.0.3", @@ -13168,6 +13124,7 @@ "version": "0.5.6", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz", "integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==", + "dev": true, "dependencies": { "minimist": "^1.2.6" }, @@ -16733,13 +16690,10 @@ "node": ">= 0.4" } }, - "node_modules/set-immediate-shim": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz", - "integrity": "sha1-SysbJ+uAip+NzEgaWOXlb1mfP2E=", - "engines": { - "node": ">=0.10.0" - } + "node_modules/setimmediate": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", + "integrity": "sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==" }, "node_modules/setprototypeof": { "version": "1.2.0", @@ -18184,16 +18138,6 @@ "integrity": "sha512-vRCqFv6UhXpWxZPyGDh/F3ZpNv8/qo7w6iufLpQg9aKnQ71qM4B5KiI7Mia9COcjEhrO9LueHpMYjYzsWH3OIg==", "dev": true }, - "node_modules/unzip-crx-3": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/unzip-crx-3/-/unzip-crx-3-0.2.0.tgz", - "integrity": "sha512-0+JiUq/z7faJ6oifVB5nSwt589v1KCduqIJupNVDoWSXZtWDmjDGO3RAEOvwJ07w90aoXoP4enKsR7ecMrJtWQ==", - "dependencies": { - "jszip": "^3.1.0", - "mkdirp": "^0.5.1", - "yaku": "^0.16.6" - } - }, "node_modules/unzipit": { "version": "1.4.3", "resolved": "https://registry.npmjs.org/unzipit/-/unzipit-1.4.3.tgz", @@ -19222,11 +19166,6 @@ "node": ">=10" } }, - "node_modules/yaku": { - "version": "0.16.7", - "resolved": "https://registry.npmjs.org/yaku/-/yaku-0.16.7.tgz", - "integrity": "sha1-HRlceKqbW/hHnIlblQT9TwhHmE4=" - }, "node_modules/yallist": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", @@ -19405,14 +19344,12 @@ "@aics/frontend-insights": "0.2.x", "@aics/frontend-insights-plugin-amplitude-node": "0.2.x", "duckdb": "0.8.x", - "electron-devtools-installer": "3.1.x", "electron-store": "8.0.x", "regenerator-runtime": "0.13.x", "semver": "7.3.x", "webpack-node-externals": "^3.0.0" }, "devDependencies": { - "@types/electron-devtools-installer": "2.2.x", "@types/semver": "7.3.x", "babel-loader": "8.2.x", "clean-webpack-plugin": "4.x", @@ -21817,12 +21754,6 @@ "@types/ms": "*" } }, - "@types/electron-devtools-installer": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/@types/electron-devtools-installer/-/electron-devtools-installer-2.2.2.tgz", - "integrity": "sha512-8o2XkyAw2HZoVD5KpIoUJmEgZ7BPVv33p7rY1jmn/wJUbugtQUc44vNMDTguUNUGiLv+oqgtyYmiYctHDZEzdQ==", - "dev": true - }, "@types/enzyme": { "version": "3.10.12", "resolved": "https://registry.npmjs.org/@types/enzyme/-/enzyme-3.10.12.tgz", @@ -25431,39 +25362,6 @@ } } }, - "electron-devtools-installer": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/electron-devtools-installer/-/electron-devtools-installer-3.1.1.tgz", - "integrity": "sha512-g2D4J6APbpsiIcnLkFMyKZ6bOpEJ0Ltcc2m66F7oKUymyGAt628OWeU9nRZoh1cNmUs/a6Cls2UfOmsZtE496Q==", - "requires": { - "rimraf": "^3.0.2", - "semver": "^7.2.1", - "unzip-crx-3": "^0.2.0" - }, - "dependencies": { - "lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "requires": { - "yallist": "^4.0.0" - } - }, - "semver": { - "version": "7.3.7", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.7.tgz", - "integrity": "sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g==", - "requires": { - "lru-cache": "^6.0.0" - } - }, - "yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" - } - } - }, "electron-mocha": { "version": "11.0.2", "resolved": "https://registry.npmjs.org/electron-mocha/-/electron-mocha-11.0.2.tgz", @@ -26693,7 +26591,6 @@ "requires": { "@aics/frontend-insights": "0.2.x", "@aics/frontend-insights-plugin-amplitude-node": "0.2.x", - "@types/electron-devtools-installer": "2.2.x", "@types/semver": "7.3.x", "babel-loader": "8.2.x", "clean-webpack-plugin": "4.x", @@ -26702,7 +26599,6 @@ "duckdb": "0.8.x", "electron": "16.0.x", "electron-builder": "23.6.x", - "electron-devtools-installer": "3.1.x", "electron-mocha": "11.0.x", "electron-store": "8.0.x", "fork-ts-checker-webpack-plugin": "6.x", @@ -27829,7 +27725,7 @@ "immediate": { "version": "3.0.6", "resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz", - "integrity": "sha1-nbHb0Pr43m++D13V5Wu2BigN5ps=" + "integrity": "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ==" }, "import-fresh": { "version": "3.3.0", @@ -28530,14 +28426,14 @@ } }, "jszip": { - "version": "3.9.1", - "resolved": "https://registry.npmjs.org/jszip/-/jszip-3.9.1.tgz", - "integrity": "sha512-H9A60xPqJ1CuC4Ka6qxzXZeU8aNmgOeP5IFqwJbQQwtu2EUYxota3LdsiZWplF7Wgd9tkAd0mdu36nceSaPuYw==", + "version": "3.10.1", + "resolved": "https://registry.npmjs.org/jszip/-/jszip-3.10.1.tgz", + "integrity": "sha512-xXDvecyTpGLrqFrvkrUSoxxfJI5AH7U8zxxtVclpsUtMCq4JQ290LY8AW5c7Ggnr/Y/oK+bQMbqK2qmtk3pN4g==", "requires": { "lie": "~3.3.0", "pako": "~1.0.2", "readable-stream": "~2.3.6", - "set-immediate-shim": "~1.0.1" + "setimmediate": "^1.0.5" } }, "just-extend": { @@ -29335,7 +29231,8 @@ "minimist": { "version": "1.2.6", "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", - "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==" + "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==", + "dev": true }, "minipass": { "version": "4.0.3", @@ -29488,6 +29385,7 @@ "version": "0.5.6", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz", "integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==", + "dev": true, "requires": { "minimist": "^1.2.6" } @@ -32139,10 +32037,10 @@ "has-property-descriptors": "^1.0.2" } }, - "set-immediate-shim": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz", - "integrity": "sha1-SysbJ+uAip+NzEgaWOXlb1mfP2E=" + "setimmediate": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", + "integrity": "sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==" }, "setprototypeof": { "version": "1.2.0", @@ -33260,16 +33158,6 @@ "integrity": "sha512-vRCqFv6UhXpWxZPyGDh/F3ZpNv8/qo7w6iufLpQg9aKnQ71qM4B5KiI7Mia9COcjEhrO9LueHpMYjYzsWH3OIg==", "dev": true }, - "unzip-crx-3": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/unzip-crx-3/-/unzip-crx-3-0.2.0.tgz", - "integrity": "sha512-0+JiUq/z7faJ6oifVB5nSwt589v1KCduqIJupNVDoWSXZtWDmjDGO3RAEOvwJ07w90aoXoP4enKsR7ecMrJtWQ==", - "requires": { - "jszip": "^3.1.0", - "mkdirp": "^0.5.1", - "yaku": "^0.16.6" - } - }, "unzipit": { "version": "1.4.3", "resolved": "https://registry.npmjs.org/unzipit/-/unzipit-1.4.3.tgz", @@ -34024,11 +33912,6 @@ "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", "dev": true }, - "yaku": { - "version": "0.16.7", - "resolved": "https://registry.npmjs.org/yaku/-/yaku-0.16.7.tgz", - "integrity": "sha1-HRlceKqbW/hHnIlblQT9TwhHmE4=" - }, "yallist": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", diff --git a/package.json b/package.json index b120d571..86f86e53 100644 --- a/package.json +++ b/package.json @@ -78,6 +78,7 @@ "filesize": "5.0.x", "fuse.js": "3.4.x", "interactjs": "1.6.x", + "jszip": "^3.10.1", "lodash": "4.17.x", "lru-cache": "5.1.x", "normalize.css": "8.0.x", diff --git a/packages/desktop/package.json b/packages/desktop/package.json index eaff5e0f..79afcdae 100644 --- a/packages/desktop/package.json +++ b/packages/desktop/package.json @@ -55,7 +55,6 @@ "author": "Allen Institute for Cell Science", "license": "SEE LICENSE IN LICENSE.txt", "devDependencies": { - "@types/electron-devtools-installer": "2.2.x", "@types/semver": "7.3.x", "babel-loader": "8.2.x", "clean-webpack-plugin": "4.x", @@ -81,7 +80,6 @@ "@aics/frontend-insights": "0.2.x", "@aics/frontend-insights-plugin-amplitude-node": "0.2.x", "duckdb": "0.8.x", - "electron-devtools-installer": "3.1.x", "electron-store": "8.0.x", "regenerator-runtime": "0.13.x", "semver": "7.3.x", diff --git a/packages/desktop/src/main/index.ts b/packages/desktop/src/main/index.ts index 0d3015f4..fb250cff 100644 --- a/packages/desktop/src/main/index.ts +++ b/packages/desktop/src/main/index.ts @@ -1,7 +1,6 @@ import * as path from "path"; import { app, BrowserWindow, Menu } from "electron"; -import installExtension, { REACT_DEVELOPER_TOOLS } from "electron-devtools-installer"; import template from "./menu"; import ExecutionEnvServicElectron from "../services/ExecutionEnvServiceElectron"; @@ -54,28 +53,11 @@ const createMainWindow = () => { }); if (isDevelopment) { - installExtension(REACT_DEVELOPER_TOOLS) - .then((name: string) => { - console.log(`Added extension: ${name}`); - - if (!mainWindow) { - throw new Error("mainWindow not defined"); - } - - mainWindow - .loadURL(`http://localhost:${process.env.WEBPACK_DEV_SERVER_PORT}`) - .then(() => { - if (mainWindow) { - mainWindow.webContents.openDevTools(); - } - }) - .catch((error: Error) => { - console.error("Failed to load from webpack-dev-server", error); - }); - }) - .catch((err: Error) => - console.error("An error occurred loading React Dev Tools: ", err) - ); + mainWindow + .loadURL(`http://localhost:${process.env.WEBPACK_DEV_SERVER_PORT}`) + .catch((error: Error) => { + console.error("Failed to load from webpack-dev-server", error); + }); } else { mainWindow.loadFile(path.join("dist", "renderer", "index.html")).catch((error: Error) => { console.error("Failed to load from file", error);