electron-screenshots 0.5.6 → 0.5.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.js +0 -2
- package/lib/screenshots.js +4 -2
- package/package.json +6 -6
package/lib/index.js
CHANGED
|
@@ -10,7 +10,6 @@ electron_1.app.whenReady().then(function () {
|
|
|
10
10
|
lang: {
|
|
11
11
|
operation_rectangle_title: '矩形2323'
|
|
12
12
|
},
|
|
13
|
-
// logger: (...args: unknown[]) => console.log(args),
|
|
14
13
|
singleWindow: true
|
|
15
14
|
});
|
|
16
15
|
screenshots.$view.webContents.openDevTools();
|
|
@@ -38,7 +37,6 @@ electron_1.app.whenReady().then(function () {
|
|
|
38
37
|
console.log('capture', buffer, bounds);
|
|
39
38
|
});
|
|
40
39
|
var mainWin = new electron_1.BrowserWindow({
|
|
41
|
-
fullscreen: true,
|
|
42
40
|
show: true
|
|
43
41
|
});
|
|
44
42
|
mainWin.removeMenu();
|
package/lib/screenshots.js
CHANGED
|
@@ -159,8 +159,7 @@ var Screenshots = /** @class */ (function (_super) {
|
|
|
159
159
|
this.$win.hide();
|
|
160
160
|
}
|
|
161
161
|
else {
|
|
162
|
-
this.$win.
|
|
163
|
-
this.$win = null;
|
|
162
|
+
this.$win.destroy();
|
|
164
163
|
}
|
|
165
164
|
return [2 /*return*/];
|
|
166
165
|
}
|
|
@@ -261,6 +260,9 @@ var Screenshots = /** @class */ (function (_super) {
|
|
|
261
260
|
// 导致显示效果不符合预期
|
|
262
261
|
(_b = _this.$win) === null || _b === void 0 ? void 0 : _b.setKiosk(true);
|
|
263
262
|
});
|
|
263
|
+
this.$win.on('closed', function () {
|
|
264
|
+
_this.$win = null;
|
|
265
|
+
});
|
|
264
266
|
}
|
|
265
267
|
this.$win.setBrowserView(this.$view);
|
|
266
268
|
// 适定平台
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "electron-screenshots",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.9",
|
|
4
4
|
"description": "electron 截图插件",
|
|
5
5
|
"types": "lib/screenshots.d.ts",
|
|
6
6
|
"main": "lib/screenshots.js",
|
|
@@ -37,11 +37,11 @@
|
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"debug": "^4.3.3",
|
|
39
39
|
"fs-extra": "^10.1.0",
|
|
40
|
-
"node-screenshots": "^0.0.
|
|
41
|
-
"react-screenshots": "^0.5.
|
|
40
|
+
"node-screenshots": "^0.0.9",
|
|
41
|
+
"react-screenshots": "^0.5.9"
|
|
42
42
|
},
|
|
43
43
|
"peerDependencies": {
|
|
44
|
-
"electron": ">=
|
|
44
|
+
"electron": ">=14"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@types/debug": "^4.1.7",
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
"@typescript-eslint/eslint-plugin": "^5.10.0",
|
|
50
50
|
"@typescript-eslint/parser": "^5.10.0",
|
|
51
51
|
"cross-env": "^7.0.3",
|
|
52
|
-
"electron": "^
|
|
52
|
+
"electron": "^17.4.10",
|
|
53
53
|
"eslint": "^8.7.0",
|
|
54
54
|
"eslint-config-standard": "^16.0.3",
|
|
55
55
|
"eslint-plugin-import": "^2.25.4",
|
|
@@ -58,5 +58,5 @@
|
|
|
58
58
|
"rimraf": "^3.0.2",
|
|
59
59
|
"typescript": "^4.5.5"
|
|
60
60
|
},
|
|
61
|
-
"gitHead": "
|
|
61
|
+
"gitHead": "9ecc9c6db0e6cf2929525ced3e6f3c60555ab051"
|
|
62
62
|
}
|