Skip to content
This repository has been archived by the owner on May 2, 2022. It is now read-only.

Commit

Permalink
Upgrade to [email protected] (#1553)
Browse files Browse the repository at this point in the history
  • Loading branch information
quanglam2807 authored Oct 31, 2021
1 parent 6f2e928 commit ab49fb2
Show file tree
Hide file tree
Showing 8 changed files with 1,042 additions and 1,693 deletions.
6 changes: 3 additions & 3 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"presets": [
["env", {
["@babel/preset-env", {
"targets": {
"electron": "8"
"electron": "12"
}
}],
"react"
"@babel/preset-react"
]
}
2 changes: 1 addition & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"parser": "babel-eslint",
"parser": "@babel/eslint-parser",
"extends": "airbnb",
"globals": {
"window": true,
Expand Down
29 changes: 15 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,22 @@
},
"dependencies": {},
"devDependencies": {
"@babel/eslint-parser": "7.16.0",
"@babel/preset-env": "7.16.0",
"@babel/preset-react": "7.16.0",
"@elastic/app-search-javascript": "7.15.0",
"@elastic/react-search-ui": "1.7.0",
"@elastic/search-ui-app-search-connector": "1.7.0",
"@electron/get": "1.13.0",
"@electron/get": "1.13.1",
"@electron/remote": "2.0.1",
"@fontsource/roboto": "4.5.1",
"@material-ui/core": "4.12.3",
"@material-ui/icons": "4.11.2",
"@sentry/electron": "2.5.4",
"amplitude-js": "8.8.0",
"amplitude-js": "8.9.0",
"auto-launch": "5.0.5",
"axios": "0.22.0",
"babel-eslint": "10.1.0",
"babel-preset-env": "1.7.0",
"babel-preset-react": "6.24.1",
"babel-loader": "8.1.0",
"blueimp-md5": "2.19.0",
"cheerio": "1.0.0-rc.10",
"classnames": "2.3.1",
Expand All @@ -51,8 +52,8 @@
"copy-webpack-plugin": "6.4.1",
"cross-env": "7.0.3",
"decompress": "4.2.1",
"electron": "15.1.2",
"electron-builder": "22.11.11",
"electron": "15.3.0",
"electron-builder": "22.13.1",
"electron-context-menu": "3.1.1",
"electron-fetch": "1.7.4",
"electron-notarize": "1.1.1",
Expand All @@ -64,21 +65,21 @@
"eslint": "6.8.0",
"eslint-config-airbnb": "18.2.1",
"eslint-plugin-header": "3.1.1",
"eslint-plugin-import": "2.24.2",
"eslint-plugin-import": "2.25.2",
"eslint-plugin-jsx-a11y": "6.4.1",
"eslint-plugin-react": "7.26.1",
"eslint-plugin-react-hooks": "1.7.0",
"file-saver": "2.0.5",
"firebase": "9.1.2",
"follow-redirects": "1.14.4",
"firebase": "9.2.0",
"follow-redirects": "1.14.5",
"fs-extra": "10.0.0",
"gravatar": "1.8.2",
"hasha": "5.2.2",
"icon-gen": "2.1.0",
"is-url": "1.2.4",
"jimp": "0.16.1",
"jszip": "3.7.1",
"menubar": "9.0.5",
"menubar": "9.1.0",
"node-cache": "5.1.2",
"node-fetch": "2.6.5",
"node-machine-id": "1.1.12",
Expand All @@ -89,12 +90,12 @@
"react-dom": "16.14.0",
"react-dropzone": "11.4.2",
"react-markdown": "5.0.3",
"react-redux": "7.2.5",
"react-redux": "7.2.6",
"react-scripts": "3.4.4",
"react-window": "1.8.6",
"react-window-infinite-loader": "1.0.7",
"redux": "4.1.1",
"redux-thunk": "2.3.0",
"redux": "4.1.2",
"redux-thunk": "2.4.0",
"regedit": "5.0.0",
"semver": "7.3.5",
"slugify": "1.6.1",
Expand Down
File renamed without changes.
6 changes: 3 additions & 3 deletions patches/menubar+9.0.5.patch → patches/menubar+9.1.0.patch
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
diff --git a/node_modules/menubar/lib/Menubar.js b/node_modules/menubar/lib/Menubar.js
index 558399c..b2f3da7 100644
index 565434b..457e670 100644
--- a/node_modules/menubar/lib/Menubar.js
+++ b/node_modules/menubar/lib/Menubar.js
@@ -229,6 +229,11 @@ var Menubar = /** @class */ (function (_super) {
Expand All @@ -22,15 +22,15 @@ index 558399c..b2f3da7 100644
this._browserWindow.show();
this._isVisible = true;
this.emit('after-show');
@@ -340,6 +346,7 @@ var Menubar = /** @class */ (function (_super) {
@@ -342,6 +348,7 @@ var Menubar = /** @class */ (function (_super) {
frame: false,
};
this._browserWindow = new electron_1.BrowserWindow(__assign(__assign({}, defaults), this._options.browserWindow));
+ require("@electron/remote/main").enable(this._browserWindow.webContents);
this._positioner = new electron_positioner_1.default(this._browserWindow);
this._browserWindow.on('blur', function () {
if (!_this._browserWindow) {
@@ -353,7 +360,10 @@ var Menubar = /** @class */ (function (_super) {
@@ -355,7 +362,10 @@ var Menubar = /** @class */ (function (_super) {
}, 100));
});
if (this._options.showOnAllWorkspaces !== false) {
Expand Down
136 changes: 4 additions & 132 deletions public/open-source-notices.txt

Large diffs are not rendered by default.

27 changes: 27 additions & 0 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,15 @@ const getForkedScriptsConfig = () => {
'prepare-electron-forked': path.join(__dirname, 'main-src', 'libs', 'app-management', 'prepare-electron-async', 'prepare-electron-forked.js'),
'uninstall-app-forked': path.join(__dirname, 'main-src', 'libs', 'app-management', 'uninstall-app-async', 'uninstall-app-forked.js'),
},
module: {
rules: [
{
test: /\.(js)$/,
exclude: /node_modules/,
use: ['babel-loader'],
},
],
},
target: 'node',
output: {
path: path.join(__dirname, 'build'),
Expand All @@ -65,6 +74,15 @@ const getPreloadScriptsConfig = () => {
'preload-main': path.join(__dirname, 'main-src', 'libs', 'windows', 'preload-main.js'),
'preload-menubar': path.join(__dirname, 'main-src', 'libs', 'windows', 'preload-menubar.js'),
},
module: {
rules: [
{
test: /\.(js)$/,
exclude: /node_modules/,
use: ['babel-loader'],
},
],
},
target: 'electron-renderer',
output: {
path: path.join(__dirname, 'build'),
Expand Down Expand Up @@ -116,6 +134,15 @@ const getElectronMainConfig = () => {
entry: {
electron: path.join(__dirname, 'main-src', 'electron.js'),
},
module: {
rules: [
{
test: /\.(js)$/,
exclude: /node_modules/,
use: ['babel-loader'],
},
],
},
target: 'electron-main',
output: {
path: path.join(__dirname, 'build'),
Expand Down
Loading

0 comments on commit ab49fb2

Please sign in to comment.