Skip to content
This repository has been archived by the owner on Aug 14, 2024. It is now read-only.

Commit

Permalink
update deps and bump to 2.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Lunarequest committed May 11, 2023
1 parent 32dbd66 commit 2f3d7ac
Show file tree
Hide file tree
Showing 17 changed files with 94 additions and 60 deletions.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
1 change: 1 addition & 0 deletions app/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -110,4 +110,5 @@ <h3 id="prompt">Open File with CTRL+O</h3>
</div>
<script type="module" src="./render/render.mjs"></script>
</body>
<!--trans rights-->

This comment has been minimized.

Copy link
@zeyus

zeyus May 11, 2023

Contributor

🖤

</html>
26 changes: 12 additions & 14 deletions app/render/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
//trans rights

import "electron-tabs";
import { Tab, TabGroup } from "electron-tabs";
Expand Down Expand Up @@ -50,7 +51,6 @@ declare global {
interface File {
path: string;
}

}

const nightPDF = (async function () {
Expand Down Expand Up @@ -84,16 +84,16 @@ const nightPDF = (async function () {
_tabGroup?.on("ready", (tabGroup: TabGroup) => {
// replace new tabe default "click" event handler
tabGroup.buttonContainer
.getElementsByTagName("button")[0]
.addEventListener(
"click",
(e: Event) => {
e.stopImmediatePropagation();
window.api.openNewPDF(null);
},
true,
);
.getElementsByTagName("button")[0]
.addEventListener(
"click",
(e: Event) => {
e.stopImmediatePropagation();
window.api.openNewPDF(null);
},
true,
);

console.info("TabGroup is ready, moving container");
_appContainerElement.appendChild(tabGroup.viewContainer);
tabGroup?.viewContainer.addEventListener(
Expand Down Expand Up @@ -150,7 +150,7 @@ const nightPDF = (async function () {

window.api.removeAllListeners("file-print");
window.api.on("file-print", (_e: Event, _msg: string) => {
const tab = _tabGroup?.getActiveTab()
const tab = _tabGroup?.getActiveTab();
if (tab) {
// the webview's window.print() method is intercepted
// by pdfjs and opens the print dialog.
Expand Down Expand Up @@ -221,8 +221,6 @@ const nightPDF = (async function () {
_hideDarkConfigurator();
});



_splashElement.addEventListener("click", (_e: Event) => {
window.api.openNewPDF(null);
});
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "nightpdf",
"version": "1.2.9",
"version": "2.0.0",
"description": "Dark Mode for PDFs",
"main": "out/main/app.js",
"packageManager": "yarn@3.5.1",
Expand Down Expand Up @@ -28,13 +28,13 @@
"devDependencies": {
"@types/gulp": "^4.0.10",
"@types/gulp-postcss": "^8.0.2",
"@types/gulp-sass": "^5.0.0",
"@types/node": "^20.1.0",
"@types/gulp-sass": "^5.0.1",
"@types/node": "^20.1.2",
"@types/yargs": "^17.0.24",
"cssnano": "^6.0.1",
"cssnano-preset-advanced": "^6.0.1",
"electron": "^24.2.0",
"electron-builder": "^24.3.0",
"electron": "^24.3.0",
"electron-builder": "^24.4.0",
"esbuild": "^0.17.18",
"gulp": "^4.0.2",
"gulp-esbuild": "^0.11.1",
Expand Down
117 changes: 76 additions & 41 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -497,13 +497,31 @@ __metadata:
languageName: node
linkType: hard

"@types/debug@npm:^4.1.6":
version: 4.1.7
resolution: "@types/debug@npm:4.1.7"
dependencies:
"@types/ms": "*"
checksum: 0a7b89d8ed72526858f0b61c6fd81f477853e8c4415bb97f48b1b5545248d2ae389931680b94b393b993a7cfe893537a200647d93defe6d87159b96812305adc
languageName: node
linkType: hard

"@types/expect@npm:^1.20.4":
version: 1.20.4
resolution: "@types/expect@npm:1.20.4"
checksum: c09a9abec2c1776dd8948920dc3bad87b1206c843509d3d3002040983b1769b2e3914202a6c20b72e5c3fb5738a1ab87cb7be9d3fe9efabf2a324173b222a224
languageName: node
linkType: hard

"@types/fs-extra@npm:9.0.13, @types/fs-extra@npm:^9.0.11":
version: 9.0.13
resolution: "@types/fs-extra@npm:9.0.13"
dependencies:
"@types/node": "*"
checksum: add79e212acd5ac76b97b9045834e03a7996aef60a814185e0459088fd290519a3c1620865d588fa36c4498bf614210d2a703af5cf80aa1dbc125db78f6edac3
languageName: node
linkType: hard

"@types/glob-stream@npm:*":
version: 6.1.2
resolution: "@types/glob-stream@npm:6.1.2"
Expand Down Expand Up @@ -534,13 +552,13 @@ __metadata:
languageName: node
linkType: hard

"@types/gulp-sass@npm:^5.0.0":
version: 5.0.0
resolution: "@types/gulp-sass@npm:5.0.0"
"@types/gulp-sass@npm:^5.0.1":
version: 5.0.1
resolution: "@types/gulp-sass@npm:5.0.1"
dependencies:
"@types/node": "*"
"@types/node-sass": "*"
checksum: bea3995c4a37b3d9c81eb30f1544698469d11e12948ce1b73e6d7ec1e225c4a383ec5add05c5393931a7c51a45cf91a34d76afb7f2b9453b309b7c0a1bdf3bc9
checksum: 50b8a33d9a8e1988bc7a9fd92c8fb8d1d364ec34a0970840ec3142a1550ee7eaab9c1c05ee00a923b9571f4ef5755ad80304ea778629cef535e3b7ea88c8a3db
languageName: node
linkType: hard

Expand Down Expand Up @@ -578,6 +596,13 @@ __metadata:
languageName: node
linkType: hard

"@types/ms@npm:*":
version: 0.7.31
resolution: "@types/ms@npm:0.7.31"
checksum: daadd354aedde024cce6f5aa873fefe7b71b22cd0e28632a69e8b677aeb48ae8caa1c60e5919bb781df040d116b01cb4316335167a3fc0ef6a63fa3614c0f6da
languageName: node
linkType: hard

"@types/node-sass@npm:*":
version: 4.11.3
resolution: "@types/node-sass@npm:4.11.3"
Expand All @@ -587,7 +612,7 @@ __metadata:
languageName: node
linkType: hard

"@types/node@npm:*, @types/node@npm:^20.1.0":
"@types/node@npm:*":
version: 20.1.1
resolution: "@types/node@npm:20.1.1"
checksum: 47961ee23f873c14c3f6045422ff3059f3bfb10231ef3080a7a72d7215cc8c2623fa8cedb7b246305962fa9c1e0c9e381e04b12eb3e9ec5d076025c6231ac8da
Expand All @@ -601,6 +626,13 @@ __metadata:
languageName: node
linkType: hard

"@types/node@npm:^20.1.2":
version: 20.1.2
resolution: "@types/node@npm:20.1.2"
checksum: 9bb2cf0a846e60cc06c44a5622c1998d8373c8675b24d11c86845a29f32c60f5bca9627f2a2535640f902be3dbcc60f126a895abe8e10f12e1467ae3deaba56d
languageName: node
linkType: hard

"@types/plist@npm:^3.0.1":
version: 3.0.2
resolution: "@types/plist@npm:3.0.2"
Expand Down Expand Up @@ -854,9 +886,9 @@ __metadata:
languageName: node
linkType: hard

"app-builder-lib@npm:24.3.0":
version: 24.3.0
resolution: "app-builder-lib@npm:24.3.0"
"app-builder-lib@npm:24.4.0":
version: 24.4.0
resolution: "app-builder-lib@npm:24.4.0"
dependencies:
7zip-bin: ~5.1.1
"@develar/schema-utils": ~2.6.5
Expand All @@ -865,14 +897,15 @@ __metadata:
"@electron/rebuild": ^3.2.13
"@electron/universal": 1.3.4
"@malept/flatpak-bundler": ^0.4.0
"@types/fs-extra": 9.0.13
async-exit-hook: ^2.0.1
bluebird-lst: ^1.0.9
builder-util: 24.3.0
builder-util: 24.4.0
builder-util-runtime: 9.2.1
chromium-pickle-js: ^0.2.0
debug: ^4.3.4
ejs: ^3.1.8
electron-publish: 24.3.0
electron-publish: 24.4.0
form-data: ^4.0.0
fs-extra: ^10.1.0
hosted-git-info: ^4.1.0
Expand All @@ -886,7 +919,7 @@ __metadata:
semver: ^7.3.8
tar: ^6.1.12
temp-file: ^3.4.0
checksum: 63ce0bda36e38e0360b8472503ee846c040ccb957300a7d5d6b789304592d19782e980d4b353bba549e29c51d337cca11b31d7358fe364b100f3282b85ac90d0
checksum: 143428feaf61a0a915eab35b844cc6d4e57105e644f314c27f838f41e3282ae6cbf154d5c51133c746fa7a0dcf0665e848326dc1e479acc2d7c90713f1d1b973
languageName: node
linkType: hard

Expand Down Expand Up @@ -1342,11 +1375,12 @@ __metadata:
languageName: node
linkType: hard

"builder-util@npm:24.3.0":
version: 24.3.0
resolution: "builder-util@npm:24.3.0"
"builder-util@npm:24.4.0":
version: 24.4.0
resolution: "builder-util@npm:24.4.0"
dependencies:
7zip-bin: ~5.1.1
"@types/debug": ^4.1.6
app-builder-bin: 4.0.0
bluebird-lst: ^1.0.9
builder-util-runtime: 9.2.1
Expand All @@ -1361,7 +1395,7 @@ __metadata:
source-map-support: ^0.5.19
stat-mode: ^1.0.0
temp-file: ^3.4.0
checksum: 56a4d04ddc8f1d2909c120a9f683873478c45eb9f5d5441017f9ec853b2363d8766860a83ac8ecd2feb0778d06f3995e9a938d9980930bf52e948f43eb536dae
checksum: 46d9fb10f3919464c724040ae20aae8c5d5b885c995d6f84989a8713ee648cf05c2780035fd891c0b1999c7990b018bf42f561b1beb1d8527ba9d63be1bea13e
languageName: node
linkType: hard

Expand Down Expand Up @@ -2178,12 +2212,12 @@ __metadata:
languageName: node
linkType: hard

"dmg-builder@npm:24.3.0":
version: 24.3.0
resolution: "dmg-builder@npm:24.3.0"
"dmg-builder@npm:24.4.0":
version: 24.4.0
resolution: "dmg-builder@npm:24.4.0"
dependencies:
app-builder-lib: 24.3.0
builder-util: 24.3.0
app-builder-lib: 24.4.0
builder-util: 24.4.0
builder-util-runtime: 9.2.1
dmg-license: ^1.0.11
fs-extra: ^10.1.0
Expand All @@ -2192,7 +2226,7 @@ __metadata:
dependenciesMeta:
dmg-license:
optional: true
checksum: 263f8bc1952724d9aee222d17071f8c2d974b2f12ff0a8c95210b288e54845de0c810c914be8a066526e0cd76cf7ffec0ae672f64374915ff0884fec2e1067ba
checksum: 4f86e425be0e79c7275f8d917678bf05ad5fd38e2d1185cc0c80e70de5f5d3a9636d3b7ab0a81e364d03ded15ed099425a2891c871aef5017b257592a7d7b572
languageName: node
linkType: hard

Expand Down Expand Up @@ -2306,15 +2340,15 @@ __metadata:
languageName: node
linkType: hard

"electron-builder@npm:^24.3.0":
version: 24.3.0
resolution: "electron-builder@npm:24.3.0"
"electron-builder@npm:^24.4.0":
version: 24.4.0
resolution: "electron-builder@npm:24.4.0"
dependencies:
app-builder-lib: 24.3.0
builder-util: 24.3.0
app-builder-lib: 24.4.0
builder-util: 24.4.0
builder-util-runtime: 9.2.1
chalk: ^4.1.2
dmg-builder: 24.3.0
dmg-builder: 24.4.0
fs-extra: ^10.1.0
is-ci: ^3.0.0
lazy-val: ^1.0.5
Expand All @@ -2324,7 +2358,7 @@ __metadata:
bin:
electron-builder: cli.js
install-app-deps: install-app-deps.js
checksum: ca57020fcaf55de2cdffcd5945fbbc2e8688e70bb90b9c67c4e504ee9a840c1502592ffd72c577645d29ab773b10aeaaf296e05669f19fcc2b69d96317fa9187
checksum: 10a80032cd68acefffe272e9cf6c8540a0ec0469c1c284f896ff5651b6fc7b34688e910dd126552a274fb141f86481c815ce891903958db9cb4074290897f02b
languageName: node
linkType: hard

Expand All @@ -2335,17 +2369,18 @@ __metadata:
languageName: node
linkType: hard

"electron-publish@npm:24.3.0":
version: 24.3.0
resolution: "electron-publish@npm:24.3.0"
"electron-publish@npm:24.4.0":
version: 24.4.0
resolution: "electron-publish@npm:24.4.0"
dependencies:
builder-util: 24.3.0
"@types/fs-extra": ^9.0.11
builder-util: 24.4.0
builder-util-runtime: 9.2.1
chalk: ^4.1.2
fs-extra: ^10.1.0
lazy-val: ^1.0.5
mime: ^2.5.2
checksum: 62b951c922cfc4e6a81a612c59136dcaa18b396ef35ae14b0a06ad2cf3eaf434da1625dabba9e701a3186a72a19eff01df9db41156d6d0ab179f15417079246f
checksum: 835b630757257e4f3603bd735a10f404a346dde377debb4fa2ac1574fb796c4d907a73c691d1f9415a1e36f25b393f4c3cc4c5076d257f46410d78c80fdbc6e6
languageName: node
linkType: hard

Expand Down Expand Up @@ -2379,16 +2414,16 @@ __metadata:
languageName: node
linkType: hard

"electron@npm:^24.2.0":
version: 24.2.0
resolution: "electron@npm:24.2.0"
"electron@npm:^24.3.0":
version: 24.3.0
resolution: "electron@npm:24.3.0"
dependencies:
"@electron/get": ^2.0.0
"@types/node": ^18.11.18
extract-zip: ^2.0.1
bin:
electron: cli.js
checksum: fb45726693d7df2b22ca37520f4777d2ebf0baefa5eae984f58490bab15b81d3a22ab1669ba523c58ed1a6ea7eb6d4b65c17feada0fe6e51c45219ce5cc6def2
checksum: 8377882a5246cfc5e4d11acf9bc800f95e3269710d3e3dce5ea81578ee5c36156fc111ddf932d02ab876111586712d2efea726775746bf3da3d8e5d02f6ee685
languageName: node
linkType: hard

Expand Down Expand Up @@ -4596,13 +4631,13 @@ __metadata:
dependencies:
"@types/gulp": ^4.0.10
"@types/gulp-postcss": ^8.0.2
"@types/gulp-sass": ^5.0.0
"@types/node": ^20.1.0
"@types/gulp-sass": ^5.0.1
"@types/node": ^20.1.2
"@types/yargs": ^17.0.24
cssnano: ^6.0.1
cssnano-preset-advanced: ^6.0.1
electron: ^24.2.0
electron-builder: ^24.3.0
electron: ^24.3.0
electron-builder: ^24.4.0
electron-log: ^4.4.8
electron-tabs: ^1.0.1
electron-updater: 6.1.0
Expand Down

0 comments on commit 2f3d7ac

Please sign in to comment.