Skip to content

Build your personal knowledge base with Trilium Notes

cleanup of app.js, wwww

zadam64db5e254271
diff --git a/package-lock.json b/package-lock.json
index 084afc6374..b19edbc764 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -5,6 +5,7 @@
"requires": true,
"packages": {
"": {
+ "name": "trilium",
"version": "0.59.4",
"hasInstallScript": true,
"license": "AGPL-3.0-only",
@@ -35,18 +36,18 @@
"express-rate-limit": "6.7.0",
"express-session": "1.17.3",
"fs-extra": "11.1.1",
- "helmet": "6.1.5",
+ "helmet": "7.0.0",
"html": "1.0.0",
"html2plaintext": "2.1.4",
- "http-proxy-agent": "5.0.0",
- "https-proxy-agent": "5.0.1",
+ "http-proxy-agent": "6.0.1",
+ "https-proxy-agent": "6.1.0",
"image-type": "4.1.0",
"ini": "3.0.1",
"is-animated": "2.0.2",
"is-svg": "4.3.2",
"jimp": "0.22.7",
"joplin-turndown-plugin-gfm": "1.0.12",
- "jsdom": "21.1.1",
+ "jsdom": "22.0.0",
"mime-types": "2.1.35",
"multer": "1.4.5-lts.1",
"node-abi": "3.40.0",
@@ -78,28 +79,28 @@
},
"devDependencies": {
"cross-env": "7.0.3",
- "electron": "25.0.0-beta.1",
+ "electron": "25.0.0-beta.2",
"electron-builder": "23.6.0",
"electron-packager": "17.1.1",
"electron-rebuild": "3.2.9",
- "eslint": "8.39.0",
- "eslint-config-airbnb-base": "^15.0.0",
- "eslint-config-prettier": "^8.8.0",
- "eslint-plugin-import": "^2.27.5",
- "eslint-plugin-jsonc": "^2.7.0",
- "eslint-plugin-prettier": "^4.2.1",
+ "eslint": "8.40.0",
+ "eslint-config-airbnb-base": "15.0.0",
+ "eslint-config-prettier": "8.8.0",
+ "eslint-plugin-import": "2.27.5",
+ "eslint-plugin-jsonc": "2.7.0",
+ "eslint-plugin-prettier": "4.2.1",
"esm": "3.2.25",
"husky": "8.0.3",
"jasmine": "4.6.0",
"jsdoc": "4.0.2",
- "jsonc-eslint-parser": "^2.2.0",
- "lint-staged": "^13.2.1",
+ "jsonc-eslint-parser": "2.2.0",
+ "lint-staged": "13.2.2",
"lorem-ipsum": "2.0.8",
"nodemon": "2.0.22",
"prettier": "2.8.8",
"rcedit": "3.0.1",
- "webpack": "5.81.0",
- "webpack-cli": "5.0.2"
+ "webpack": "5.82.0",
+ "webpack-cli": "5.1.0"
},
"optionalDependencies": {
"electron-installer-debian": "3.1.0"
@@ -402,14 +403,14 @@
}
},
"node_modules/@eslint/eslintrc": {
- "version": "2.0.2",
- "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.0.2.tgz",
- "integrity": "sha512-3W4f5tDUra+pA+FzgugqL2pRimUTDJWKr7BINqOpkZrC0uYI0NIc0/JFgBROCU07HR6GieA5m3/rsPIhDmCXTQ==",
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.0.3.tgz",
+ "integrity": "sha512-+5gy6OQfk+xx3q0d6jGZZC3f3KzAkXc/IanVxd1is/VIIziRqqt3ongQz0FiTUXqTk0c7aDB3OaFuKnuSoJicQ==",
"dev": true,
"dependencies": {
"ajv": "^6.12.4",
"debug": "^4.3.2",
- "espree": "^9.5.1",
+ "espree": "^9.5.2",
"globals": "^13.19.0",
"ignore": "^5.2.0",
"import-fresh": "^3.2.1",
@@ -449,9 +450,9 @@
}
},
"node_modules/@eslint/js": {
- "version": "8.39.0",
- "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.39.0.tgz",
- "integrity": "sha512-kf9RB0Fg7NZfap83B3QOqOGg9QmD9yBudqQXzzOtn3i4y7ZUXe5ONeW34Gwi+TxhH4mvj72R1Zc300KUMa9Bng==",
+ "version": "8.40.0",
+ "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.40.0.tgz",
+ "integrity": "sha512-ElyB54bJIhXQYVKjDSvCkPO1iU1tSAeVQJbllWJq1XQSmmA4dgFk8CbiBGpiOPxleE48vDogxCtmMYku4HSVLA==",
"dev": true,
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
@@ -1077,6 +1078,20 @@
"node-pre-gyp": "bin/node-pre-gyp"
}
},
+ "node_modules/@mapbox/node-pre-gyp/node_modules/https-proxy-agent": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
+ "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "optional": true,
+ "peer": true,
+ "dependencies": {
+ "agent-base": "6",
+ "debug": "4"
+ },
+ "engines": {
+ "node": ">= 6"
+ }
+ },
"node_modules/@mapbox/node-pre-gyp/node_modules/rimraf": {
"version": "3.0.2",
"resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz",
@@ -1542,9 +1557,9 @@
}
},
"node_modules/@webpack-cli/configtest": {
- "version": "2.0.1",
- "resolved": "https://registry.npmjs.org/@webpack-cli/configtest/-/configtest-2.0.1.tgz",
- "integrity": "sha512-njsdJXJSiS2iNbQVS0eT8A/KPnmyH4pv1APj2K0d1wrZcBLw+yppxOy4CGqa0OxDJkzfL/XELDhD8rocnIwB5A==",
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/@webpack-cli/configtest/-/configtest-2.1.0.tgz",
+ "integrity": "sha512-K/vuv72vpfSEZoo5KIU0a2FsEoYdW0DUMtMpB5X3LlUwshetMZRZRxB7sCsVji/lFaSxtQQ3aM9O4eMolXkU9w==",
"dev": true,
"engines": {
"node": ">=14.15.0"
@@ -1568,9 +1583,9 @@
}
},
"node_modules/@webpack-cli/serve": {
- "version": "2.0.2",
- "resolved": "https://registry.npmjs.org/@webpack-cli/serve/-/serve-2.0.2.tgz",
- "integrity": "sha512-S9h3GmOmzUseyeFW3tYNnWS7gNUuwxZ3mmMq0JyW78Vx1SGKPSkt5bT4pB0rUnVfHjP0EL9gW2bOzmtiTfQt0A==",
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/@webpack-cli/serve/-/serve-2.0.3.tgz",
+ "integrity": "sha512-Bwxd73pHuYc0cyl7vulPp2I6kAYtmJPkfUivbts7by6wDAVyFdKzGX3AksbvCRyNVFUJu7o2ZTcWXdT90T3qbg==",
"dev": true,
"engines": {
"node": ">=14.15.0"
@@ -1630,6 +1645,7 @@
"version": "8.8.2",
"resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz",
"integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==",
+ "dev": true,
"bin": {
"acorn": "bin/acorn"
},
@@ -1637,15 +1653,6 @@
"node": ">=0.4.0"
}
},
- "node_modules/acorn-globals": {
- "version": "7.0.1",
- "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-7.0.1.tgz",
- "integrity": "sha512-umOSDSDrfHbTNPuNpC2NSnnA3LUrqpevPb4T9jRx4MagXNS0rs+gwiTcAvqCRmsD6utzsrzNt+ebm00SNWiC3Q==",
- "dependencies": {
- "acorn": "^8.1.0",
- "acorn-walk": "^8.0.2"
- }
- },
"node_modules/acorn-import-assertions": {
"version": "1.8.0",
"resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.8.0.tgz",
@@ -1664,14 +1671,6 @@
"acorn": "^6.0.0 || ^7.0.0 || ^8.0.0"
}
},
- "node_modules/acorn-walk": {
- "version": "8.2.0",
- "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz",
- "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==",
- "engines": {
- "node": ">=0.4.0"
- }
- },
"node_modules/agent-base": {
"version": "6.0.2",
"resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz",
@@ -2625,6 +2624,33 @@
"node": ">=12"
}
},
+ "node_modules/builder-util/node_modules/http-proxy-agent": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz",
+ "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==",
+ "dev": true,
+ "dependencies": {
+ "@tootallnate/once": "2",
+ "agent-base": "6",
+ "debug": "4"
+ },
+ "engines": {
+ "node": ">= 6"
+ }
+ },
+ "node_modules/builder-util/node_modules/https-proxy-agent": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
+ "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "dev": true,
+ "dependencies": {
+ "agent-base": "6",
+ "debug": "4"
+ },
+ "engines": {
+ "node": ">= 6"
+ }
+ },
"node_modules/builder-util/node_modules/jsonfile": {
"version": "6.1.0",
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
@@ -3732,7 +3758,8 @@
"node_modules/deep-is": {
"version": "0.1.4",
"resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz",
- "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ=="
+ "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==",
+ "dev": true
},
"node_modules/deepmerge": {
"version": "4.2.2",
@@ -4076,9 +4103,9 @@
}
},
"node_modules/electron": {
- "version": "25.0.0-beta.1",
- "resolved": "https://registry.npmjs.org/electron/-/electron-25.0.0-beta.1.tgz",
- "integrity": "sha512-iUEuOKtjzzENNv+wvpvaMR9iRTjribFAttBTAEvd0Aemvoy8WH1P0UAxe4GxTLkoEpMQUToxqIHZnpN3K2Qcnw==",
+ "version": "25.0.0-beta.2",
+ "resolved": "https://registry.npmjs.org/electron/-/electron-25.0.0-beta.2.tgz",
+ "integrity": "sha512-fjlNM5gEvFCAhzznJ15ReY3lY4REBZ2Ba9YLJNLYUsuZVAuwrqfen30pJ3EKmAnf5VkqIFHVkXEEQO9VdbbVxQ==",
"hasInstallScript": true,
"dependencies": {
"@electron/get": "^2.0.0",
@@ -4908,37 +4935,16 @@
"node": ">=0.8.0"
}
},
- "node_modules/escodegen": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-2.0.0.tgz",
- "integrity": "sha512-mmHKys/C8BFUGI+MAWNcSYoORYLMdPzjrknd2Vc+bUsjN5bXcr8EhrNB+UTqfL1y3I9c4fw2ihgtMPQLBRiQxw==",
- "dependencies": {
- "esprima": "^4.0.1",
- "estraverse": "^5.2.0",
- "esutils": "^2.0.2",
- "optionator": "^0.8.1"
- },
- "bin": {
- "escodegen": "bin/escodegen.js",
- "esgenerate": "bin/esgenerate.js"
- },
- "engines": {
- "node": ">=6.0"
- },
- "optionalDependencies": {
- "source-map": "~0.6.1"
- }
- },
"node_modules/eslint": {
- "version": "8.39.0",
- "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.39.0.tgz",
- "integrity": "sha512-mwiok6cy7KTW7rBpo05k6+p4YVZByLNjAZ/ACB9DRCu4YDRwjXI01tWHp6KAUWelsBetTxKK/2sHB0vdS8Z2Og==",
+ "version": "8.40.0",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.40.0.tgz",
+ "integrity": "sha512-bvR+TsP9EHL3TqNtj9sCNJVAFK3fBN8Q7g5waghxyRsPLIMwL73XSKnZFK0hk/O2ANC+iAoq6PWMQ+IfBAJIiQ==",
"dev": true,
"dependencies": {
"@eslint-community/eslint-utils": "^4.2.0",
"@eslint-community/regexpp": "^4.4.0",
- "@eslint/eslintrc": "^2.0.2",
- "@eslint/js": "8.39.0",
+ "@eslint/eslintrc": "^2.0.3",
+ "@eslint/js": "8.40.0",
"@humanwhocodes/config-array": "^0.11.8",
"@humanwhocodes/module-importer": "^1.0.1",
"@nodelib/fs.walk": "^1.2.8",
@@ -4949,8 +4955,8 @@
"doctrine": "^3.0.0",
"escape-string-regexp": "^4.0.0",
"eslint-scope": "^7.2.0",
- "eslint-visitor-keys": "^3.4.0",
- "espree": "^9.5.1",
+ "eslint-visitor-keys": "^3.4.1",
+ "espree": "^9.5.2",
"esquery": "^1.4.2",
"esutils": "^2.0.2",
"fast-deep-equal": "^3.1.3",
@@ -5225,9 +5231,9 @@
}
},
"node_modules/eslint-visitor-keys": {
- "version": "3.4.0",
- "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.0.tgz",
- "integrity": "sha512-HPpKPUBQcAsZOsHAFwTtIKcYlCje62XB7SEAcxjtmW6TD1WVpkS6i6/hOVtTZIl4zGj/mBqpFVGvaDneik+VoQ==",
+ "version": "3.4.1",
+ "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.1.tgz",
+ "integrity": "sha512-pZnmmLwYzf+kWaM/Qgrvpen51upAktaaiI01nsJD/Yr3lMOdNtq0cxkrrg16w64VtisN6okbs7Q8AfGqj4c9fA==",
"dev": true,
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
@@ -5431,14 +5437,14 @@
}
},
"node_modules/espree": {
- "version": "9.5.1",
- "resolved": "https://registry.npmjs.org/espree/-/espree-9.5.1.tgz",
- "integrity": "sha512-5yxtHSZXRSW5pvv3hAlXM5+/Oswi1AUFqBmbibKb5s6bp3rGIDkyXU6xCoyuuLhijr4SFwPrXRoZjz0AZDN9tg==",
+ "version": "9.5.2",
+ "resolved": "https://registry.npmjs.org/espree/-/espree-9.5.2.tgz",
+ "integrity": "sha512-7OASN1Wma5fum5SrNhFMAMJxOUAbhyfQ8dQ//PJaJbNw0URTPWqIghHWt1MmAANKhHZIYOHruW4Kw4ruUWOdGw==",
"dev": true,
"dependencies": {
"acorn": "^8.8.0",
"acorn-jsx": "^5.3.2",
- "eslint-visitor-keys": "^3.4.0"
+ "eslint-visitor-keys": "^3.4.1"
},
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
@@ -5447,18 +5453,6 @@
"url": "https://opencollective.com/eslint"
}
},
- "node_modules/esprima": {
- "version": "4.0.1",
- "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz",
- "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==",
- "bin": {
- "esparse": "bin/esparse.js",
- "esvalidate": "bin/esvalidate.js"
- },
- "engines": {
- "node": ">=4"
- }
- },
"node_modules/esquery": {
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz",
@@ -5487,6 +5481,7 @@
"version": "5.3.0",
"resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz",
"integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==",
+ "dev": true,
"engines": {
"node": ">=4.0"
}
@@ -5495,6 +5490,7 @@
"version": "2.0.3",
"resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz",
"integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==",
+ "dev": true,
"engines": {
"node": ">=0.10.0"
}
@@ -5861,7 +5857,8 @@
"node_modules/fast-levenshtein": {
"version": "2.0.6",
"resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz",
- "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc="
+ "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=",
+ "dev": true
},
"node_modules/fast-xml-parser": {
"version": "3.21.1",
@@ -6735,11 +6732,11 @@
}
},
"node_modules/helmet": {
- "version": "6.1.5",
- "resolved": "https://registry.npmjs.org/helmet/-/helmet-6.1.5.tgz",
- "integrity": "sha512-UgAvdoG0BhF9vcCh/j0bWtElo2ZHHk6OzC98NLCM6zK03DEVSM0vUAtT7iR+oTo2Mi6sGelAH3tL6B/uUWxV4g==",
+ "version": "7.0.0",
+ "resolved": "https://registry.npmjs.org/helmet/-/helmet-7.0.0.tgz",
+ "integrity": "sha512-MsIgYmdBh460ZZ8cJC81q4XJknjG567wzEmv46WOBblDb6TUd3z8/GhgmsM9pn8g2B80tAJ4m5/d3Bi1KrSUBQ==",
"engines": {
- "node": ">=14.0.0"
+ "node": ">=16.0.0"
}
},
"node_modules/hosted-git-info": {
@@ -6848,16 +6845,26 @@
}
},
"node_modules/http-proxy-agent": {
- "version": "5.0.0",
- "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz",
- "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==",
+ "version": "6.0.1",
+ "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-6.0.1.tgz",
+ "integrity": "sha512-rD8wrfJHbnVll9lkIpQH3vDbKON1Ssciggwydom/r89HLBXEqdMhL6wx7QF5WePDPSr0OdoztdXoojbrXadG5Q==",
"dependencies": {
- "@tootallnate/once": "2",
- "agent-base": "6",
- "debug": "4"
+ "agent-base": "^7.0.1",
+ "debug": "^4.3.4"
},
"engines": {
- "node": ">= 6"
+ "node": ">= 14"
+ }
+ },
+ "node_modules/http-proxy-agent/node_modules/agent-base": {
+ "version": "7.0.1",
+ "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.0.1.tgz",
+ "integrity": "sha512-V9to8gr2GK7eA+xskWGAFUX/TLSQKuH2TI06c/jGLL6yLp3oEjtnqM7a5tPV9fC1rabLeAgThZeBwsYX+WWHpw==",
+ "dependencies": {
+ "debug": "^4.3.4"
+ },
+ "engines": {
+ "node": ">= 14"
}
},
"node_modules/http-signature": {
@@ -6887,15 +6894,26 @@
}
},
"node_modules/https-proxy-agent": {
- "version": "5.0.1",
- "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
- "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "version": "6.1.0",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-6.1.0.tgz",
+ "integrity": "sha512-rvGRAlc3y+iS7AC9Os2joN91mX8wHpJ4TEklmHHxr7Gz2Juqa7fJmJ8wWxXNpTaRt56MQTwojxV5d82UW/+jwg==",
"dependencies": {
- "agent-base": "6",
+ "agent-base": "^7.0.1",
"debug": "4"
},
"engines": {
- "node": ">= 6"
+ "node": ">= 14"
+ }
+ },
+ "node_modules/https-proxy-agent/node_modules/agent-base": {
+ "version": "7.0.1",
+ "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.0.1.tgz",
+ "integrity": "sha512-V9to8gr2GK7eA+xskWGAFUX/TLSQKuH2TI06c/jGLL6yLp3oEjtnqM7a5tPV9fC1rabLeAgThZeBwsYX+WWHpw==",
+ "dependencies": {
+ "debug": "^4.3.4"
+ },
+ "engines": {
+ "node": ">= 14"
}
},
"node_modules/human-signals": {
@@ -7788,24 +7806,21 @@
}
},
"node_modules/jsdom": {
- "version": "21.1.1",
- "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-21.1.1.tgz",
- "integrity": "sha512-Jjgdmw48RKcdAIQyUD1UdBh2ecH7VqwaXPN3ehoZN6MqgVbMn+lRm1aAT1AsdJRAJpwfa4IpwgzySn61h2qu3w==",
+ "version": "22.0.0",
+ "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-22.0.0.tgz",
+ "integrity": "sha512-p5ZTEb5h+O+iU02t0GfEjAnkdYPrQSkfuTSMkMYyIoMvUNEHsbG0bHHbfXIcfTqD2UfvjQX7mmgiFsyRwGscVw==",
"dependencies": {
"abab": "^2.0.6",
- "acorn": "^8.8.2",
- "acorn-globals": "^7.0.0",
"cssstyle": "^3.0.0",
"data-urls": "^4.0.0",
"decimal.js": "^10.4.3",
"domexception": "^4.0.0",
- "escodegen": "^2.0.0",
"form-data": "^4.0.0",
"html-encoding-sniffer": "^3.0.0",
"http-proxy-agent": "^5.0.0",
"https-proxy-agent": "^5.0.1",
"is-potential-custom-element-name": "^1.0.1",
- "nwsapi": "^2.2.2",
+ "nwsapi": "^2.2.4",
"parse5": "^7.1.2",
"rrweb-cssom": "^0.6.0",
"saxes": "^6.0.0",
@@ -7820,7 +7835,7 @@
"xml-name-validator": "^4.0.0"
},
"engines": {
- "node": ">=14"
+ "node": ">=16"
},
"peerDependencies": {
"canvas": "^2.5.0"
@@ -7855,6 +7870,31 @@
"node": ">= 6"
}
},
+ "node_modules/jsdom/node_modules/http-proxy-agent": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz",
+ "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==",
+ "dependencies": {
+ "@tootallnate/once": "2",
+ "agent-base": "6",
+ "debug": "4"
+ },
+ "engines": {
+ "node": ">= 6"
+ }
+ },
+ "node_modules/jsdom/node_modules/https-proxy-agent": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
+ "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "dependencies": {
+ "agent-base": "6",
+ "debug": "4"
+ },
+ "engines": {
+ "node": ">= 6"
+ }
+ },
"node_modules/jsdom/node_modules/parse5": {
"version": "7.1.2",
"resolved": "https://registry.npmjs.org/parse5/-/parse5-7.1.2.tgz",
@@ -8023,18 +8063,6 @@
"node": ">= 0.6.3"
}
},
- "node_modules/levn": {
- "version": "0.3.0",
- "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz",
- "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=",
- "dependencies": {
- "prelude-ls": "~1.1.2",
- "type-check": "~0.3.2"
- },
- "engines": {
- "node": ">= 0.8.0"
- }
- },
"node_modules/lilconfig": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-2.1.0.tgz",
@@ -8059,9 +8087,9 @@
}
},
"node_modules/lint-staged": {
- "version": "13.2.1",
- "resolved": "https://registry.npmjs.org/lint-staged/-/lint-staged-13.2.1.tgz",
- "integrity": "sha512-8gfzinVXoPfga5Dz/ZOn8I2GOhf81Wvs+KwbEXQn/oWZAvCVS2PivrXfVbFJc93zD16uC0neS47RXHIjXKYZQw==",
+ "version": "13.2.2",
+ "resolved": "https://registry.npmjs.org/lint-staged/-/lint-staged-13.2.2.tgz",
+ "integrity": "sha512-71gSwXKy649VrSU09s10uAT0rWCcY3aewhMaHyl2N84oBk4Xs9HgxvUp3AYu+bNsK4NrOYYxvSgg7FyGJ+jGcA==",
"dev": true,
"dependencies": {
"chalk": "5.2.0",
@@ -8076,7 +8104,7 @@
"object-inspect": "^1.12.3",
"pidtree": "^0.6.0",
"string-argv": "^0.3.1",
- "yaml": "^2.2.1"
+ "yaml": "^2.2.2"
},
"bin": {
"lint-staged": "bin/lint-staged.js"
@@ -8551,6 +8579,33 @@
"node": "^12.13.0 || ^14.15.0 || >=16.0.0"
}
},
+ "node_modules/make-fetch-happen/node_modules/http-proxy-agent": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz",
+ "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==",
+ "dev": true,
+ "dependencies": {
+ "@tootallnate/once": "2",
+ "agent-base": "6",
+ "debug": "4"
+ },
+ "engines": {
+ "node": ">= 6"
+ }
+ },
+ "node_modules/make-fetch-happen/node_modules/https-proxy-agent": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
+ "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "dev": true,
+ "dependencies": {
+ "agent-base": "6",
+ "debug": "4"
+ },
+ "engines": {
+ "node": ">= 6"
+ }
+ },
"node_modules/make-fetch-happen/node_modules/lru-cache": {
"version": "7.13.1",
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-7.13.1.tgz",
@@ -9313,9 +9368,9 @@
}
},
"node_modules/nwsapi": {
- "version": "2.2.2",
- "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.2.tgz",
- "integrity": "sha512-90yv+6538zuvUMnN+zCr8LuV6bPFdq50304114vJYJ8RDyK8D5O9Phpbd6SZWgI7PwzmmfN1upeOJlvybDSgCw=="
+ "version": "2.2.4",
+ "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.4.tgz",
+ "integrity": "sha512-NHj4rzRo0tQdijE9ZqAx6kYDcoRwYwSYzCA8MY3JzfxlrvEU0jhnhJT9BhqhJs7I/dKcrDm6TyulaRqZPIhN5g=="
},
"node_modules/oauth-sign": {
"version": "0.9.0",
@@ -9462,22 +9517,6 @@
"url": "https://github.com/sponsors/sindresorhus"
}
},
- "node_modules/optionator": {
- "version": "0.8.3",
- "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz",
- "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==",
- "dependencies": {
- "deep-is": "~0.1.3",
- "fast-levenshtein": "~2.0.6",
- "levn": "~0.3.0",
- "prelude-ls": "~1.1.2",
- "type-check": "~0.3.2",
- "word-wrap": "~1.2.3"
- },
- "engines": {
- "node": ">= 0.8.0"
- }
- },
"node_modules/ora": {
"version": "5.4.1",
"resolved": "https://registry.npmjs.org/ora/-/ora-5.4.1.tgz",
@@ -9958,14 +9997,6 @@
"node": ">=10"
}
},
- "node_modules/prelude-ls": {
- "version": "1.1.2",
- "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz",
- "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=",
- "engines": {
- "node": ">= 0.8.0"
- }
- },
"node_modules/prettier": {
"version": "2.8.8",
"resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz",
@@ -11271,7 +11302,7 @@
"version": "0.6.1",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
"integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==",
- "devOptional": true,
+ "dev": true,
"engines": {
"node": ">=0.10.0"
}
@@ -12044,17 +12075,6 @@
"resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz",
"integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q="
},
- "node_modules/type-check": {
- "version": "0.3.2",
- "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz",
- "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=",
- "dependencies": {
- "prelude-ls": "~1.1.2"
- },
- "engines": {
- "node": ">= 0.8.0"
- }
- },
"node_modules/type-fest": {
"version": "0.13.1",
"resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.13.1.tgz",
@@ -12340,9 +12360,9 @@
}
},
"node_modules/webpack": {
- "version": "5.81.0",
- "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.81.0.tgz",
- "integrity": "sha512-AAjaJ9S4hYCVODKLQTgG5p5e11hiMawBwV2v8MYLE0C/6UAGLuAF4n1qa9GOwdxnicaP+5k6M5HrLmD4+gIB8Q==",
+ "version": "5.82.0",
+ "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.82.0.tgz",
+ "integrity": "sha512-iGNA2fHhnDcV1bONdUu554eZx+XeldsaeQ8T67H6KKHl2nUSwX8Zm7cmzOA46ox/X1ARxf7Bjv8wQ/HsB5fxBg==",
"dev": true,
"dependencies": {
"@types/eslint-scope": "^3.7.3",
@@ -12387,15 +12407,15 @@
}
},
"node_modules/webpack-cli": {
- "version": "5.0.2",
- "resolved": "https://registry.npmjs.org/webpack-cli/-/webpack-cli-5.0.2.tgz",
- "integrity": "sha512-4y3W5Dawri5+8dXm3+diW6Mn1Ya+Dei6eEVAdIduAmYNLzv1koKVAqsfgrrc9P2mhrYHQphx5htnGkcNwtubyQ==",
+ "version": "5.1.0",
+ "resolved": "https://registry.npmjs.org/webpack-cli/-/webpack-cli-5.1.0.tgz",
+ "integrity": "sha512-a7KRJnCxejFoDpYTOwzm5o21ZXMaNqtRlvS183XzGDUPRdVEzJNImcQokqYZ8BNTnk9DkKiuWxw75+DCCoZ26w==",
"dev": true,
"dependencies": {
"@discoveryjs/json-ext": "^0.5.0",
- "@webpack-cli/configtest": "^2.0.1",
+ "@webpack-cli/configtest": "^2.1.0",
"@webpack-cli/info": "^2.0.1",
- "@webpack-cli/serve": "^2.0.2",
+ "@webpack-cli/serve": "^2.0.3",
"colorette": "^2.0.14",
"commander": "^10.0.1",
"cross-spawn": "^7.0.3",
@@ -12574,6 +12594,7 @@
"version": "1.2.3",
"resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz",
"integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==",
+ "devOptional": true,
"engines": {
"node": ">=0.10.0"
}
@@ -12703,9 +12724,9 @@
"integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="
},
"node_modules/yaml": {
- "version": "2.2.1",
- "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.2.1.tgz",
- "integrity": "sha512-e0WHiYql7+9wr4cWMx3TVQrNwejKaEe7/rHNmQmqRjazfOP5W8PB6Jpebb5o6fIapbz9o9+2ipcaTM2ZwDI6lw==",
+ "version": "2.2.2",
+ "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.2.2.tgz",
+ "integrity": "sha512-CBKFWExMn46Foo4cldiChEzn7S7SRV+wqiluAb6xmueD/fGyRHIhX8m14vVGgeFWjN540nKCNVj6P21eQjgTuA==",
"dev": true,
"engines": {
"node": ">= 14"
@@ -13049,14 +13070,14 @@
"dev": true
},
"@eslint/eslintrc": {
- "version": "2.0.2",
- "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.0.2.tgz",
- "integrity": "sha512-3W4f5tDUra+pA+FzgugqL2pRimUTDJWKr7BINqOpkZrC0uYI0NIc0/JFgBROCU07HR6GieA5m3/rsPIhDmCXTQ==",
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.0.3.tgz",
+ "integrity": "sha512-+5gy6OQfk+xx3q0d6jGZZC3f3KzAkXc/IanVxd1is/VIIziRqqt3ongQz0FiTUXqTk0c7aDB3OaFuKnuSoJicQ==",
"dev": true,
"requires": {
"ajv": "^6.12.4",
"debug": "^4.3.2",
- "espree": "^9.5.1",
+ "espree": "^9.5.2",
"globals": "^13.19.0",
"ignore": "^5.2.0",
"import-fresh": "^3.2.1",
@@ -13083,9 +13104,9 @@
}
},
"@eslint/js": {
- "version": "8.39.0",
- "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.39.0.tgz",
- "integrity": "sha512-kf9RB0Fg7NZfap83B3QOqOGg9QmD9yBudqQXzzOtn3i4y7ZUXe5ONeW34Gwi+TxhH4mvj72R1Zc300KUMa9Bng==",
+ "version": "8.40.0",
+ "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.40.0.tgz",
+ "integrity": "sha512-ElyB54bJIhXQYVKjDSvCkPO1iU1tSAeVQJbllWJq1XQSmmA4dgFk8CbiBGpiOPxleE48vDogxCtmMYku4HSVLA==",
"dev": true
},
"@excalidraw/excalidraw": {
@@ -13557,6 +13578,17 @@
"tar": "^6.1.11"
},
"dependencies": {
+ "https-proxy-agent": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
+ "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "optional": true,
+ "peer": true,
+ "requires": {
+ "agent-base": "6",
+ "debug": "4"
+ }
+ },
"rimraf": {
"version": "3.0.2",
"resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz",
@@ -13981,9 +14013,9 @@
}
},
"@webpack-cli/configtest": {
- "version": "2.0.1",
- "resolved": "https://registry.npmjs.org/@webpack-cli/configtest/-/configtest-2.0.1.tgz",
- "integrity": "sha512-njsdJXJSiS2iNbQVS0eT8A/KPnmyH4pv1APj2K0d1wrZcBLw+yppxOy4CGqa0OxDJkzfL/XELDhD8rocnIwB5A==",
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/@webpack-cli/configtest/-/configtest-2.1.0.tgz",
+ "integrity": "sha512-K/vuv72vpfSEZoo5KIU0a2FsEoYdW0DUMtMpB5X3LlUwshetMZRZRxB7sCsVji/lFaSxtQQ3aM9O4eMolXkU9w==",
"dev": true,
"requires": {}
},
@@ -13995,9 +14027,9 @@
"requires": {}
},
"@webpack-cli/serve": {
- "version": "2.0.2",
- "resolved": "https://registry.npmjs.org/@webpack-cli/serve/-/serve-2.0.2.tgz",
- "integrity": "sha512-S9h3GmOmzUseyeFW3tYNnWS7gNUuwxZ3mmMq0JyW78Vx1SGKPSkt5bT4pB0rUnVfHjP0EL9gW2bOzmtiTfQt0A==",
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/@webpack-cli/serve/-/serve-2.0.3.tgz",
+ "integrity": "sha512-Bwxd73pHuYc0cyl7vulPp2I6kAYtmJPkfUivbts7by6wDAVyFdKzGX3AksbvCRyNVFUJu7o2ZTcWXdT90T3qbg==",
"dev": true,
"requires": {}
},
@@ -14042,16 +14074,8 @@
"acorn": {
"version": "8.8.2",
"resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz",
- "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw=="
- },
- "acorn-globals": {
- "version": "7.0.1",
- "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-7.0.1.tgz",
- "integrity": "sha512-umOSDSDrfHbTNPuNpC2NSnnA3LUrqpevPb4T9jRx4MagXNS0rs+gwiTcAvqCRmsD6utzsrzNt+ebm00SNWiC3Q==",
- "requires": {
- "acorn": "^8.1.0",
- "acorn-walk": "^8.0.2"
- }
+ "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==",
+ "dev": true
},
"acorn-import-assertions": {
"version": "1.8.0",
@@ -14067,11 +14091,6 @@
"dev": true,
"requires": {}
},
- "acorn-walk": {
- "version": "8.2.0",
- "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz",
- "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA=="
- },
"agent-base": {
"version": "6.0.2",
"resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz",
@@ -14828,6 +14847,27 @@
"universalify": "^2.0.0"
}
},
+ "http-proxy-agent": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz",
+ "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==",
+ "dev": true,
+ "requires": {
+ "@tootallnate/once": "2",
+ "agent-base": "6",
+ "debug": "4"
+ }
+ },
+ "https-proxy-agent": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
+ "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "dev": true,
+ "requires": {
+ "agent-base": "6",
+ "debug": "4"
+ }
+ },
"jsonfile": {
"version": "6.1.0",
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
@@ -15670,7 +15710,8 @@
"deep-is": {
"version": "0.1.4",
"resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz",
- "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ=="
+ "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==",
+ "dev": true
},
"deepmerge": {
"version": "4.2.2",
@@ -15929,9 +15970,9 @@
}
},
"electron": {
- "version": "25.0.0-beta.1",
- "resolved": "https://registry.npmjs.org/electron/-/electron-25.0.0-beta.1.tgz",
- "integrity": "sha512-iUEuOKtjzzENNv+wvpvaMR9iRTjribFAttBTAEvd0Aemvoy8WH1P0UAxe4GxTLkoEpMQUToxqIHZnpN3K2Qcnw==",
+ "version": "25.0.0-beta.2",
+ "resolved": "https://registry.npmjs.org/electron/-/electron-25.0.0-beta.2.tgz",
+ "integrity": "sha512-fjlNM5gEvFCAhzznJ15ReY3lY4REBZ2Ba9YLJNLYUsuZVAuwrqfen30pJ3EKmAnf5VkqIFHVkXEEQO9VdbbVxQ==",
"requires": {
"@electron/get": "^2.0.0",
"@types/node": "^18.11.18",
@@ -16579,28 +16620,16 @@
"integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=",
"dev": true
},
- "escodegen": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-2.0.0.tgz",
- "integrity": "sha512-mmHKys/C8BFUGI+MAWNcSYoORYLMdPzjrknd2Vc+bUsjN5bXcr8EhrNB+UTqfL1y3I9c4fw2ihgtMPQLBRiQxw==",
- "requires": {
- "esprima": "^4.0.1",
- "estraverse": "^5.2.0",
- "esutils": "^2.0.2",
- "optionator": "^0.8.1",
- "source-map": "~0.6.1"
- }
- },
"eslint": {
- "version": "8.39.0",
- "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.39.0.tgz",
- "integrity": "sha512-mwiok6cy7KTW7rBpo05k6+p4YVZByLNjAZ/ACB9DRCu4YDRwjXI01tWHp6KAUWelsBetTxKK/2sHB0vdS8Z2Og==",
+ "version": "8.40.0",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.40.0.tgz",
+ "integrity": "sha512-bvR+TsP9EHL3TqNtj9sCNJVAFK3fBN8Q7g5waghxyRsPLIMwL73XSKnZFK0hk/O2ANC+iAoq6PWMQ+IfBAJIiQ==",
"dev": true,
"requires": {
"@eslint-community/eslint-utils": "^4.2.0",
"@eslint-community/regexpp": "^4.4.0",
- "@eslint/eslintrc": "^2.0.2",
- "@eslint/js": "8.39.0",
+ "@eslint/eslintrc": "^2.0.3",
+ "@eslint/js": "8.40.0",
"@humanwhocodes/config-array": "^0.11.8",
"@humanwhocodes/module-importer": "^1.0.1",
"@nodelib/fs.walk": "^1.2.8",
@@ -16611,8 +16640,8 @@
"doctrine": "^3.0.0",
"escape-string-regexp": "^4.0.0",
"eslint-scope": "^7.2.0",
- "eslint-visitor-keys": "^3.4.0",
- "espree": "^9.5.1",
+ "eslint-visitor-keys": "^3.4.1",
+ "espree": "^9.5.2",
"esquery": "^1.4.2",
"esutils": "^2.0.2",
"fast-deep-equal": "^3.1.3",
@@ -16947,9 +16976,9 @@
}
},
"eslint-visitor-keys": {
- "version": "3.4.0",
- "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.0.tgz",
- "integrity": "sha512-HPpKPUBQcAsZOsHAFwTtIKcYlCje62XB7SEAcxjtmW6TD1WVpkS6i6/hOVtTZIl4zGj/mBqpFVGvaDneik+VoQ==",
+ "version": "3.4.1",
+ "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.1.tgz",
+ "integrity": "sha512-pZnmmLwYzf+kWaM/Qgrvpen51upAktaaiI01nsJD/Yr3lMOdNtq0cxkrrg16w64VtisN6okbs7Q8AfGqj4c9fA==",
"dev": true
},
"esm": {
@@ -16959,21 +16988,16 @@
"dev": true
},
"espree": {
- "version": "9.5.1",
- "resolved": "https://registry.npmjs.org/espree/-/espree-9.5.1.tgz",
- "integrity": "sha512-5yxtHSZXRSW5pvv3hAlXM5+/Oswi1AUFqBmbibKb5s6bp3rGIDkyXU6xCoyuuLhijr4SFwPrXRoZjz0AZDN9tg==",
+ "version": "9.5.2",
+ "resolved": "https://registry.npmjs.org/espree/-/espree-9.5.2.tgz",
+ "integrity": "sha512-7OASN1Wma5fum5SrNhFMAMJxOUAbhyfQ8dQ//PJaJbNw0URTPWqIghHWt1MmAANKhHZIYOHruW4Kw4ruUWOdGw==",
"dev": true,
"requires": {
"acorn": "^8.8.0",
"acorn-jsx": "^5.3.2",
- "eslint-visitor-keys": "^3.4.0"
+ "eslint-visitor-keys": "^3.4.1"
}
},
- "esprima": {
- "version": "4.0.1",
- "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz",
- "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A=="
- },
"esquery": {
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz",
@@ -16995,12 +17019,14 @@
"estraverse": {
"version": "5.3.0",
"resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz",
- "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA=="
+ "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==",
+ "dev": true
},
"esutils": {
"version": "2.0.3",
"resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz",
- "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g=="
+ "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==",
+ "dev": true
},
"etag": {
"version": "1.8.1",
@@ -17258,7 +17284,8 @@
"fast-levenshtein": {
"version": "2.0.6",
"resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz",
- "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc="
+ "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=",
+ "dev": true
},
"fast-xml-parser": {
"version": "3.21.1",
@@ -17934,9 +17961,9 @@
"integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw=="
},
"helmet": {
- "version": "6.1.5",
- "resolved": "https://registry.npmjs.org/helmet/-/helmet-6.1.5.tgz",
- "integrity": "sha512-UgAvdoG0BhF9vcCh/j0bWtElo2ZHHk6OzC98NLCM6zK03DEVSM0vUAtT7iR+oTo2Mi6sGelAH3tL6B/uUWxV4g=="
+ "version": "7.0.0",
+ "resolved": "https://registry.npmjs.org/helmet/-/helmet-7.0.0.tgz",
+ "integrity": "sha512-MsIgYmdBh460ZZ8cJC81q4XJknjG567wzEmv46WOBblDb6TUd3z8/GhgmsM9pn8g2B80tAJ4m5/d3Bi1KrSUBQ=="
},
"hosted-git-info": {
"version": "2.8.9",
@@ -18021,13 +18048,22 @@
}
},
"http-proxy-agent": {
- "version": "5.0.0",
- "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz",
- "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==",
+ "version": "6.0.1",
+ "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-6.0.1.tgz",
+ "integrity": "sha512-rD8wrfJHbnVll9lkIpQH3vDbKON1Ssciggwydom/r89HLBXEqdMhL6wx7QF5WePDPSr0OdoztdXoojbrXadG5Q==",
"requires": {
- "@tootallnate/once": "2",
- "agent-base": "6",
- "debug": "4"
+ "agent-base": "^7.0.1",
+ "debug": "^4.3.4"
+ },
+ "dependencies": {
+ "agent-base": {
+ "version": "7.0.1",
+ "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.0.1.tgz",
+ "integrity": "sha512-V9to8gr2GK7eA+xskWGAFUX/TLSQKuH2TI06c/jGLL6yLp3oEjtnqM7a5tPV9fC1rabLeAgThZeBwsYX+WWHpw==",
+ "requires": {
+ "debug": "^4.3.4"
+ }
+ }
}
},
"http-signature": {
@@ -18050,12 +18086,22 @@
}
},
"https-proxy-agent": {
- "version": "5.0.1",
- "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
- "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "version": "6.1.0",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-6.1.0.tgz",
+ "integrity": "sha512-rvGRAlc3y+iS7AC9Os2joN91mX8wHpJ4TEklmHHxr7Gz2Juqa7fJmJ8wWxXNpTaRt56MQTwojxV5d82UW/+jwg==",
"requires": {
- "agent-base": "6",
+ "agent-base": "^7.0.1",
"debug": "4"
+ },
+ "dependencies": {
+ "agent-base": {
+ "version": "7.0.1",
+ "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.0.1.tgz",
+ "integrity": "sha512-V9to8gr2GK7eA+xskWGAFUX/TLSQKuH2TI06c/jGLL6yLp3oEjtnqM7a5tPV9fC1rabLeAgThZeBwsYX+WWHpw==",
+ "requires": {
+ "debug": "^4.3.4"
+ }
+ }
}
},
"human-signals": {
@@ -18696,24 +18742,21 @@
}
},
"jsdom": {
- "version": "21.1.1",
- "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-21.1.1.tgz",
- "integrity": "sha512-Jjgdmw48RKcdAIQyUD1UdBh2ecH7VqwaXPN3ehoZN6MqgVbMn+lRm1aAT1AsdJRAJpwfa4IpwgzySn61h2qu3w==",
+ "version": "22.0.0",
+ "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-22.0.0.tgz",
+ "integrity": "sha512-p5ZTEb5h+O+iU02t0GfEjAnkdYPrQSkfuTSMkMYyIoMvUNEHsbG0bHHbfXIcfTqD2UfvjQX7mmgiFsyRwGscVw==",
"requires": {
"abab": "^2.0.6",
- "acorn": "^8.8.2",
- "acorn-globals": "^7.0.0",
"cssstyle": "^3.0.0",
"data-urls": "^4.0.0",
"decimal.js": "^10.4.3",
"domexception": "^4.0.0",
- "escodegen": "^2.0.0",
"form-data": "^4.0.0",
"html-encoding-sniffer": "^3.0.0",
"http-proxy-agent": "^5.0.0",
"https-proxy-agent": "^5.0.1",
"is-potential-custom-element-name": "^1.0.1",
- "nwsapi": "^2.2.2",
+ "nwsapi": "^2.2.4",
"parse5": "^7.1.2",
"rrweb-cssom": "^0.6.0",
"saxes": "^6.0.0",
@@ -18743,6 +18786,25 @@
"mime-types": "^2.1.12"
}
},
+ "http-proxy-agent": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz",
+ "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==",
+ "requires": {
+ "@tootallnate/once": "2",
+ "agent-base": "6",
+ "debug": "4"
+ }
+ },
+ "https-proxy-agent": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
+ "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "requires": {
+ "agent-base": "6",
+ "debug": "4"
+ }
+ },
"parse5": {
"version": "7.1.2",
"resolved": "https://registry.npmjs.org/parse5/-/parse5-7.1.2.tgz",
@@ -18883,15 +18945,6 @@
"readable-stream": "^2.0.5"
}
},
- "levn": {
- "version": "0.3.0",
- "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz",
- "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=",
- "requires": {
- "prelude-ls": "~1.1.2",
- "type-check": "~0.3.2"
- }
- },
"lilconfig": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-2.1.0.tgz",
@@ -18913,9 +18966,9 @@
}
},
"lint-staged": {
- "version": "13.2.1",
- "resolved": "https://registry.npmjs.org/lint-staged/-/lint-staged-13.2.1.tgz",
- "integrity": "sha512-8gfzinVXoPfga5Dz/ZOn8I2GOhf81Wvs+KwbEXQn/oWZAvCVS2PivrXfVbFJc93zD16uC0neS47RXHIjXKYZQw==",
+ "version": "13.2.2",
+ "resolved": "https://registry.npmjs.org/lint-staged/-/lint-staged-13.2.2.tgz",
+ "integrity": "sha512-71gSwXKy649VrSU09s10uAT0rWCcY3aewhMaHyl2N84oBk4Xs9HgxvUp3AYu+bNsK4NrOYYxvSgg7FyGJ+jGcA==",
"dev": true,
"requires": {
"chalk": "5.2.0",
@@ -18930,7 +18983,7 @@
"object-inspect": "^1.12.3",
"pidtree": "^0.6.0",
"string-argv": "^0.3.1",
- "yaml": "^2.2.1"
+ "yaml": "^2.2.2"
},
"dependencies": {
"ansi-regex": {
@@ -19272,6 +19325,27 @@
"ssri": "^9.0.0"
},
"dependencies": {
+ "http-proxy-agent": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz",
+ "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==",
+ "dev": true,
+ "requires": {
+ "@tootallnate/once": "2",
+ "agent-base": "6",
+ "debug": "4"
+ }
+ },
+ "https-proxy-agent": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz",
+ "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==",
+ "dev": true,
+ "requires": {
+ "agent-base": "6",
+ "debug": "4"
+ }
+ },
"lru-cache": {
"version": "7.13.1",
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-7.13.1.tgz",
@@ -19851,9 +19925,9 @@
}
},
"nwsapi": {
- "version": "2.2.2",
- "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.2.tgz",
- "integrity": "sha512-90yv+6538zuvUMnN+zCr8LuV6bPFdq50304114vJYJ8RDyK8D5O9Phpbd6SZWgI7PwzmmfN1upeOJlvybDSgCw=="
+ "version": "2.2.4",
+ "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.4.tgz",
+ "integrity": "sha512-NHj4rzRo0tQdijE9ZqAx6kYDcoRwYwSYzCA8MY3JzfxlrvEU0jhnhJT9BhqhJs7I/dKcrDm6TyulaRqZPIhN5g=="
},
"oauth-sign": {
"version": "0.9.0",
@@ -19955,19 +20029,6 @@
"is-wsl": "^2.2.0"
}
},
- "optionator": {
- "version": "0.8.3",
- "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz",
- "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==",
- "requires": {
- "deep-is": "~0.1.3",
- "fast-levenshtein": "~2.0.6",
- "levn": "~0.3.0",
- "prelude-ls": "~1.1.2",
- "type-check": "~0.3.2",
- "word-wrap": "~1.2.3"
- }
- },
"ora": {
"version": "5.4.1",
"resolved": "https://registry.npmjs.org/ora/-/ora-5.4.1.tgz",
@@ -20335,11 +20396,6 @@
"tunnel-agent": "^0.6.0"
}
},
- "prelude-ls": {
- "version": "1.1.2",
- "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz",
- "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ="
- },
"prettier": {
"version": "2.8.8",
"resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz",
@@ -21323,7 +21379,7 @@
"version": "0.6.1",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
"integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==",
- "devOptional": true
+ "dev": true
},
"source-map-js": {
"version": "1.0.1",
@@ -21919,14 +21975,6 @@
"resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz",
"integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q="
},
- "type-check": {
- "version": "0.3.2",
- "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz",
- "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=",
- "requires": {
- "prelude-ls": "~1.1.2"
- }
- },
"type-fest": {
"version": "0.13.1",
"resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.13.1.tgz",
@@ -22159,9 +22207,9 @@
"integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g=="
},
"webpack": {
- "version": "5.81.0",
- "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.81.0.tgz",
- "integrity": "sha512-AAjaJ9S4hYCVODKLQTgG5p5e11hiMawBwV2v8MYLE0C/6UAGLuAF4n1qa9GOwdxnicaP+5k6M5HrLmD4+gIB8Q==",
+ "version": "5.82.0",
+ "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.82.0.tgz",
+ "integrity": "sha512-iGNA2fHhnDcV1bONdUu554eZx+XeldsaeQ8T67H6KKHl2nUSwX8Zm7cmzOA46ox/X1ARxf7Bjv8wQ/HsB5fxBg==",
"dev": true,
"requires": {
"@types/eslint-scope": "^3.7.3",
@@ -22191,15 +22239,15 @@
}
},
"webpack-cli": {
- "version": "5.0.2",
- "resolved": "https://registry.npmjs.org/webpack-cli/-/webpack-cli-5.0.2.tgz",
- "integrity": "sha512-4y3W5Dawri5+8dXm3+diW6Mn1Ya+Dei6eEVAdIduAmYNLzv1koKVAqsfgrrc9P2mhrYHQphx5htnGkcNwtubyQ==",
+ "version": "5.1.0",
+ "resolved": "https://registry.npmjs.org/webpack-cli/-/webpack-cli-5.1.0.tgz",
+ "integrity": "sha512-a7KRJnCxejFoDpYTOwzm5o21ZXMaNqtRlvS183XzGDUPRdVEzJNImcQokqYZ8BNTnk9DkKiuWxw75+DCCoZ26w==",
"dev": true,
"requires": {
"@discoveryjs/json-ext": "^0.5.0",
- "@webpack-cli/configtest": "^2.0.1",
+ "@webpack-cli/configtest": "^2.1.0",
"@webpack-cli/info": "^2.0.1",
- "@webpack-cli/serve": "^2.0.2",
+ "@webpack-cli/serve": "^2.0.3",
"colorette": "^2.0.14",
"commander": "^10.0.1",
"cross-spawn": "^7.0.3",
@@ -22322,7 +22370,8 @@
"word-wrap": {
"version": "1.2.3",
"resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz",
- "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ=="
+ "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==",
+ "devOptional": true
},
"wrap-ansi": {
"version": "6.2.0",
@@ -22420,9 +22469,9 @@
"integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="
},
"yaml": {
- "version": "2.2.1",
- "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.2.1.tgz",
- "integrity": "sha512-e0WHiYql7+9wr4cWMx3TVQrNwejKaEe7/rHNmQmqRjazfOP5W8PB6Jpebb5o6fIapbz9o9+2ipcaTM2ZwDI6lw==",
+ "version": "2.2.2",
+ "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.2.2.tgz",
+ "integrity": "sha512-CBKFWExMn46Foo4cldiChEzn7S7SRV+wqiluAb6xmueD/fGyRHIhX8m14vVGgeFWjN540nKCNVj6P21eQjgTuA==",
"dev": true
},
"yargs": {
diff --git a/package.json b/package.json
index 6be30351c0..f05c8e8486 100644
--- a/package.json
+++ b/package.json
@@ -57,18 +57,18 @@
"express-rate-limit": "6.7.0",
"express-session": "1.17.3",
"fs-extra": "11.1.1",
- "helmet": "6.1.5",
+ "helmet": "7.0.0",
"html": "1.0.0",
"html2plaintext": "2.1.4",
- "http-proxy-agent": "5.0.0",
- "https-proxy-agent": "5.0.1",
+ "http-proxy-agent": "6.0.1",
+ "https-proxy-agent": "6.1.0",
"image-type": "4.1.0",
"ini": "3.0.1",
"is-animated": "2.0.2",
"is-svg": "4.3.2",
"jimp": "0.22.7",
"joplin-turndown-plugin-gfm": "1.0.12",
- "jsdom": "21.1.1",
+ "jsdom": "22.0.0",
"mime-types": "2.1.35",
"multer": "1.4.5-lts.1",
"node-abi": "3.40.0",
@@ -97,28 +97,28 @@
},
"devDependencies": {
"cross-env": "7.0.3",
- "electron": "25.0.0-beta.1",
+ "electron": "25.0.0-beta.2",
"electron-builder": "23.6.0",
"electron-packager": "17.1.1",
"electron-rebuild": "3.2.9",
- "eslint": "8.39.0",
- "eslint-config-airbnb-base": "^15.0.0",
- "eslint-config-prettier": "^8.8.0",
- "eslint-plugin-import": "^2.27.5",
- "eslint-plugin-jsonc": "^2.7.0",
- "eslint-plugin-prettier": "^4.2.1",
+ "eslint": "8.40.0",
+ "eslint-config-airbnb-base": "15.0.0",
+ "eslint-config-prettier": "8.8.0",
+ "eslint-plugin-import": "2.27.5",
+ "eslint-plugin-jsonc": "2.7.0",
+ "eslint-plugin-prettier": "4.2.1",
"esm": "3.2.25",
"husky": "8.0.3",
- "jsonc-eslint-parser": "^2.2.0",
- "lint-staged": "^13.2.1",
+ "jsonc-eslint-parser": "2.2.0",
+ "lint-staged": "13.2.2",
"jasmine": "4.6.0",
"jsdoc": "4.0.2",
"lorem-ipsum": "2.0.8",
"prettier": "2.8.8",
"nodemon": "2.0.22",
"rcedit": "3.0.1",
- "webpack": "5.81.0",
- "webpack-cli": "5.0.2"
+ "webpack": "5.82.0",
+ "webpack-cli": "5.1.0"
},
"optionalDependencies": {
"electron-installer-debian": "3.1.0"
diff --git a/src/app.js b/src/app.js
index c876fceab9..dc3adb7e81 100644
--- a/src/app.js
+++ b/src/app.js
@@ -1,17 +1,12 @@
-const log = require('./services/log');
const express = require('express');
const path = require('path');
const favicon = require('serve-favicon');
const cookieParser = require('cookie-parser');
const helmet = require('helmet');
-const session = require('express-session');
const compression = require('compression');
-const FileStore = require('session-file-store')(session);
-const sessionSecret = require('./services/session_secret');
-const dataDir = require('./services/data_dir');
+const sessionParser = require('./routes/session_parser');
const utils = require('./services/utils');
-const assetPath = require('./services/asset_path');
-const env = require('./services/env');
+
require('./services/handlers');
require('./becca/becca_loader');
@@ -31,99 +26,21 @@ app.use(helmet({
crossOriginEmbedderPolicy: false
}));
-const persistentCacheStatic = (root, options) => {
- if (!env.isDev()) {
- options = {
- maxAge: '1y',
- ...options
- };
- }
- return express.static(root, options);
-};
-
app.use(express.text({limit: '500mb'}));
app.use(express.json({limit: '500mb'}));
app.use(express.raw({limit: '500mb'}));
app.use(express.urlencoded({extended: false}));
app.use(cookieParser());
app.use(express.static(path.join(__dirname, 'public/root')));
-app.use(`/${assetPath}/app`, persistentCacheStatic(path.join(__dirname, 'public/app')));
-app.use(`/${assetPath}/app-dist`, persistentCacheStatic(path.join(__dirname, 'public/app-dist')));
-app.use(`/${assetPath}/fonts`, persistentCacheStatic(path.join(__dirname, 'public/fonts')));
-app.use(`/assets/vX/fonts`, express.static(path.join(__dirname, 'public/fonts')));
-app.use(`/${assetPath}/stylesheets`, persistentCacheStatic(path.join(__dirname, 'public/stylesheets')));
-app.use(`/assets/vX/stylesheets`, express.static(path.join(__dirname, 'public/stylesheets')));
-app.use(`/${assetPath}/libraries`, persistentCacheStatic(path.join(__dirname, '..', 'libraries')));
-app.use(`/assets/vX/libraries`, express.static(path.join(__dirname, '..', 'libraries')));
-// excalidraw-view mode in shared notes
-app.use(`/${assetPath}/node_modules/react/umd/react.production.min.js`, persistentCacheStatic(path.join(__dirname, '..', 'node_modules/react/umd/react.production.min.js')));
-app.use(`/${assetPath}/node_modules/react-dom/umd/react-dom.production.min.js`, persistentCacheStatic(path.join(__dirname, '..', 'node_modules/react-dom/umd/react-dom.production.min.js')));
-// expose whole dist folder since complete assets are needed in edit and share
-app.use(`/node_modules/@excalidraw/excalidraw/dist/`, express.static(path.join(__dirname, '..', 'node_modules/@excalidraw/excalidraw/dist/')));
-app.use(`/${assetPath}/node_modules/@excalidraw/excalidraw/dist/`, persistentCacheStatic(path.join(__dirname, '..', 'node_modules/@excalidraw/excalidraw/dist/')));
-app.use(`/${assetPath}/images`, persistentCacheStatic(path.join(__dirname, '..', 'images')));
-app.use(`/assets/vX/images`, express.static(path.join(__dirname, '..', 'images')));
app.use(`/manifest.webmanifest`, express.static(path.join(__dirname, 'public/manifest.webmanifest')));
app.use(`/robots.txt`, express.static(path.join(__dirname, 'public/robots.txt')));
-const sessionParser = session({
- secret: sessionSecret,
- resave: false, // true forces the session to be saved back to the session store, even if the session was never modified during the request.
- saveUninitialized: false, // true forces a session that is "uninitialized" to be saved to the store. A session is uninitialized when it is new but not modified.
- cookie: {
- // path: "/",
- httpOnly: true,
- maxAge: 24 * 60 * 60 * 1000 // in milliseconds
- },
- name: 'trilium.sid',
- store: new FileStore({
- ttl: 30 * 24 * 3600,
- path: `${dataDir.TRILIUM_DATA_DIR}/sessions`
- })
-});
app.use(sessionParser);
-
app.use(favicon(`${__dirname}/../images/app-icons/win/icon.ico`));
+require('./routes/assets').register(app);
require('./routes/routes').register(app);
-
require('./routes/custom').register(app);
-
-app.use((err, req, res, next) => {
- if (err.code !== 'EBADCSRFTOKEN') {
- return next(err);
- }
-
- log.error(`Invalid CSRF token: ${req.headers['x-csrf-token']}, secret: ${req.cookies['_csrf']}`);
-
- err = new Error('Invalid CSRF token');
- err.status = 403;
- next(err);
-});
-
-// catch 404 and forward to error handler
-app.use((req, res, next) => {
- const err = new Error(`Router not found for request ${req.url}`);
- err.status = 404;
- next(err);
-});
-
-// error handler
-app.use((err, req, res, next) => {
- if (err && err.message && (
- (err.message.includes("Router not found for request") && err.message.includes(".js.map"))
- || (err.message.includes("Router not found for request") && err.message.includes(".css.map"))
- )) {
- // ignore
- }
- else {
- log.info(err);
- }
-
- res.status(err.status || 500);
- res.send({
- message: err.message
- });
-});
+require('./routes/error_handlers').register(app);
// triggers sync timer
require('./services/sync');
@@ -140,7 +57,4 @@ if (utils.isElectron()) {
require('@electron/remote/main').initialize();
}
-module.exports = {
- app,
- sessionParser
-};
+module.exports = app;
diff --git a/src/routes/assets.js b/src/routes/assets.js
new file mode 100644
index 0000000000..ce00521b0f
--- /dev/null
+++ b/src/routes/assets.js
@@ -0,0 +1,38 @@
+const assetPath = require("../services/asset_path.js");
+const path = require("path");
+const express = require("express");
+const env = require("../services/env.js");
+
+const persistentCacheStatic = (root, options) => {
+ if (!env.isDev()) {
+ options = {
+ maxAge: '1y',
+ ...options
+ };
+ }
+ return express.static(root, options);
+};
+
+function register(app) {
+ const srcRoot = path.join(__dirname, '..');
+ app.use(`/${assetPath}/app`, persistentCacheStatic(path.join(srcRoot, 'public/app')));
+ app.use(`/${assetPath}/app-dist`, persistentCacheStatic(path.join(srcRoot, 'public/app-dist')));
+ app.use(`/${assetPath}/fonts`, persistentCacheStatic(path.join(srcRoot, 'public/fonts')));
+ app.use(`/assets/vX/fonts`, express.static(path.join(srcRoot, 'public/fonts')));
+ app.use(`/${assetPath}/stylesheets`, persistentCacheStatic(path.join(srcRoot, 'public/stylesheets')));
+ app.use(`/assets/vX/stylesheets`, express.static(path.join(srcRoot, 'public/stylesheets')));
+ app.use(`/${assetPath}/libraries`, persistentCacheStatic(path.join(srcRoot, '..', 'libraries')));
+ app.use(`/assets/vX/libraries`, express.static(path.join(srcRoot, '..', 'libraries')));
+ // excalidraw-view mode in shared notes
+ app.use(`/${assetPath}/node_modules/react/umd/react.production.min.js`, persistentCacheStatic(path.join(srcRoot, '..', 'node_modules/react/umd/react.production.min.js')));
+ app.use(`/${assetPath}/node_modules/react-dom/umd/react-dom.production.min.js`, persistentCacheStatic(path.join(srcRoot, '..', 'node_modules/react-dom/umd/react-dom.production.min.js')));
+ // expose the whole dist folder since complete assets are needed in edit and share
+ app.use(`/node_modules/@excalidraw/excalidraw/dist/`, express.static(path.join(srcRoot, '..', 'node_modules/@excalidraw/excalidraw/dist/')));
+ app.use(`/${assetPath}/node_modules/@excalidraw/excalidraw/dist/`, persistentCacheStatic(path.join(srcRoot, '..', 'node_modules/@excalidraw/excalidraw/dist/')));
+ app.use(`/${assetPath}/images`, persistentCacheStatic(path.join(srcRoot, '..', 'images')));
+ app.use(`/assets/vX/images`, express.static(path.join(srcRoot, '..', 'images')));
+}
+
+module.exports = {
+ register
+};
diff --git a/src/routes/error_handlers.js b/src/routes/error_handlers.js
new file mode 100644
index 0000000000..52ea33da79
--- /dev/null
+++ b/src/routes/error_handlers.js
@@ -0,0 +1,43 @@
+const log = require("../services/log");
+
+function register(app) {
+ app.use((err, req, res, next) => {
+ if (err.code !== 'EBADCSRFTOKEN') {
+ return next(err);
+ }
+
+ log.error(`Invalid CSRF token: ${req.headers['x-csrf-token']}, secret: ${req.cookies['_csrf']}`);
+
+ err = new Error('Invalid CSRF token');
+ err.status = 403;
+ next(err);
+ });
+
+ // catch 404 and forward to error handler
+ app.use((req, res, next) => {
+ const err = new Error(`Router not found for request ${req.url}`);
+ err.status = 404;
+ next(err);
+ });
+
+ // error handler
+ app.use((err, req, res, next) => {
+ if (err && err.message && (
+ (err.message.includes("Router not found for request") && err.message.includes(".js.map"))
+ || (err.message.includes("Router not found for request") && err.message.includes(".css.map"))
+ )) {
+ // ignore
+ } else {
+ log.info(err);
+ }
+
+ res.status(err.status || 500);
+ res.send({
+ message: err.message
+ });
+ });
+}
+
+module.exports = {
+ register
+};
diff --git a/src/routes/session_parser.js b/src/routes/session_parser.js
new file mode 100644
index 0000000000..b9619a6153
--- /dev/null
+++ b/src/routes/session_parser.js
@@ -0,0 +1,22 @@
+const session = require("express-session");
+const sessionSecret = require("../services/session_secret.js");
+const dataDir = require("../services/data_dir.js");
+const FileStore = require('session-file-store')(session);
+
+const sessionParser = session({
+ secret: sessionSecret,
+ resave: false, // true forces the session to be saved back to the session store, even if the session was never modified during the request.
+ saveUninitialized: false, // true forces a session that is "uninitialized" to be saved to the store. A session is uninitialized when it is new but not modified.
+ cookie: {
+ // path: "/",
+ httpOnly: true,
+ maxAge: 24 * 60 * 60 * 1000 // in milliseconds
+ },
+ name: 'trilium.sid',
+ store: new FileStore({
+ ttl: 30 * 24 * 3600,
+ path: `${dataDir.TRILIUM_DATA_DIR}/sessions`
+ })
+});
+
+module.exports = sessionParser;
diff --git a/src/services/sql_init.js b/src/services/sql_init.js
index 847a96f08f..7048186bba 100644
--- a/src/services/sql_init.js
+++ b/src/services/sql_init.js
@@ -99,8 +99,8 @@ async function createInitialDatabase() {
await zipImportService.importZip(dummyTaskContext, demoFile, rootNote);
sql.transactional(() => {
- // this needs to happen after ZIP import
- // previous solution was to move option initialization here but then the important parts of initialization
+ // this needs to happen after ZIP import,
+ // the previous solution was to move option initialization here, but then the important parts of initialization
// are not all in one transaction (because ZIP import is async and thus not transactional)
const startNoteId = sql.getValue("SELECT noteId FROM branches WHERE parentNoteId = 'root' AND isDeleted = 0 ORDER BY notePosition");
diff --git a/src/www b/src/www
index 136feabf3b..1cfbff9e09 100644
--- a/src/www
+++ b/src/www
@@ -1,5 +1,7 @@
#!/usr/bin/env node
+// setup basic error handling even before requiring dependencies, since those can produce errors as well
+
process.on('unhandledRejection', error => {
// this makes sure that stacktrace of failed promise is printed out
console.log(error);
@@ -16,7 +18,8 @@ function exit() {
process.on('SIGINT', exit);
process.on('SIGTERM', exit);
-const { app, sessionParser } = require('./app');
+const app = require('./app');
+const sessionParser = require('./routes/session_parser');
const fs = require('fs');
const http = require('http');
const https = require('https');
@@ -25,7 +28,6 @@ const log = require('./services/log');
const appInfo = require('./services/app_info');
const ws = require('./services/ws');
const utils = require('./services/utils');
-const sqlInit = require('./services/sql_init');
const port = require('./services/port');
const host = require('./services/host');
const semver = require('semver');
@@ -35,9 +37,9 @@ if (!semver.satisfies(process.version, ">=10.5.0")) {
process.exit(1);
}
-let httpServer;
+startTrilium();
-async function startTrilium() {
+function startTrilium() {
/**
* The intended behavior is to detect when a second instance is running, in that case open the old instance
* instead of the new one. This is complicated by the fact that it is possible to run multiple instances of Trilium
@@ -48,13 +50,29 @@ async function startTrilium() {
*
* A bit weird is that "second-instance" is triggered also on the valid usecases (different port/data dir) and
* focuses the existing window. But the new process is start as well and will steal the focus too, it will win, because
- * its startup is slower than focusing the existing process/window. So in the end it works out without having
- * to do complex evaluation.
+ * its startup is slower than focusing the existing process/window. So in the end, it works out without having
+ * to do a complex evaluation.
*/
if (utils.isElectron()) {
require("electron").app.requestSingleInstanceLock();
}
+ log.info(JSON.stringify(appInfo, null, 2));
+
+ const cpuInfos = require('os').cpus();
+ log.info(`CPU model: ${cpuInfos[0].model}, logical cores: ${cpuInfos.length} freq: ${cpuInfos[0].speed} Mhz`); // for perf. issues it's good to know the rough configuration
+
+ const httpServer = startHttpServer();
+
+ ws.init(httpServer, sessionParser);
+
+ if (utils.isElectron()) {
+ const electronRouting = require('./routes/electron');
+ electronRouting(app);
+ }
+}
+
+function startHttpServer() {
app.set('port', port);
app.set('host', host);
@@ -64,8 +82,11 @@ async function startTrilium() {
app.set('trust proxy', config['Network']['trustedReverseProxy'])
}
}
+
log.info(`Trusted reverse proxy: ${app.get('trust proxy')}`)
+ let httpServer;
+
if (config['Network']['https']) {
if (!config['Network']['keyPath'] || !config['Network']['keyPath'].trim().length) {
throw new Error("keyPath in config.ini is required when https=true, but it's empty");
@@ -83,29 +104,25 @@ async function startTrilium() {
httpServer = https.createServer(options, app);
log.info(`App HTTPS server starting up at port ${port}`);
- }
- else {
+ } else {
httpServer = http.createServer(app);
log.info(`App HTTP server starting up at port ${port}`);
}
- log.info(JSON.stringify(appInfo, null, 2));
-
- const cpuInfos = require('os').cpus();
- log.info(`CPU model: ${cpuInfos[0].model}, logical cores: ${cpuInfos.length} freq: ${cpuInfos[0].speed} Mhz`); // for perf. issues it's good to know the rough configuration
-
/**
* Listen on provided port, on all network interfaces.
*/
httpServer.keepAliveTimeout = 120000 * 5;
const listenOnTcp = port !== 0;
+
if (listenOnTcp) {
- httpServer.listen(port, host); // TCP socket.
+ httpServer.listen(port, host); // TCP socket.
} else {
- httpServer.listen(host); // Unix socket.
+ httpServer.listen(host); // Unix socket.
}
+
httpServer.on('error', error => {
if (!listenOnTcp || error.syscall !== 'listen') {
throw error;
@@ -137,12 +154,5 @@ async function startTrilium() {
}
});
- ws.init(httpServer, sessionParser);
-
- if (utils.isElectron()) {
- const electronRouting = require('./routes/electron');
- electronRouting(app);
- }
+ return httpServer;
}
-
-startTrilium();