A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
desktop: add support for switching release tracks
Abdullah Atta15f4f2accbd3
diff --git a/apps/desktop/.gitignore b/apps/desktop/.gitignoreindex d50f5712f..bd160cd26 100644--- a/apps/desktop/.gitignore+++ b/apps/desktop/.gitignore@@ -2,4 +2,6 @@ node_modulesbuildoutputdist-_catalog\ No newline at end of file+_catalog+test-results+test-artifactsdiff --git a/apps/desktop/__tests__/auto-updates.test.ts b/apps/desktop/__tests__/auto-updates.test.tsnew file mode 100644index 000000000..3a3a6ef6f--- /dev/null+++ b/apps/desktop/__tests__/auto-updates.test.ts@@ -0,0 +1,119 @@+/*+This file is part of the Notesnook project (https://notesnook.com/)++Copyright (C) 2023 Streetwriters (Private) Limited++This program is free software: you can redistribute it and/or modify+it under the terms of the GNU General Public License as published by+the Free Software Foundation, either version 3 of the License, or+(at your option) any later version.++This program is distributed in the hope that it will be useful,+but WITHOUT ANY WARRANTY; without even the implied warranty of+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+GNU General Public License for more details.++You should have received a copy of the GNU General Public License+along with this program. If not, see <http://www.gnu.org/licenses/>.+*/++import { test } from "vitest";+import { harness } from "./utils.js";+import assert from "assert";+import { writeFile } from "fs/promises";++test("update starts downloading if version is outdated", async (t) => {+ await harness(+ t,+ async ({ page }) => {+ await page.waitForSelector("#authForm");++ assert.ok(+ await page.getByRole("button", { name: "Create account" }).isVisible()+ );++ await page+ .getByRole("button", { name: "Skip & go directly to the app" })+ .click();++ await page+ .waitForSelector(".ReactModal__Content", {+ timeout: 1000+ })+ .catch(() => {})+ .then(async () => {+ const positiveButton = page.locator(+ "button[data-role='positive-button']"+ );+ const negativeButton = page.locator(+ "button[data-role='negative-button']"+ );+ if (await positiveButton.isVisible()) await positiveButton.click();+ else if (await negativeButton.isVisible())+ await negativeButton.click();+ });++ await page.waitForSelector(".ProseMirror");++ await page+ .locator(".theme-scope-statusBar")+ .getByRole("button", { name: /updating/i })+ .waitFor({ state: "attached" });+ },+ { version: "3.0.0" }+ );+});++test("update is only shown if version is outdated and auto updates are disabled", async (t) => {+ await harness(+ t,+ async (ctx) => {+ await ctx.app.close();+ await writeFile(+ ctx.configPath,+ JSON.stringify({+ automaticUpdates: false+ })+ );++ await ctx.relaunch();++ const { page } = ctx;++ await page.waitForSelector("#authForm");++ assert.ok(+ await page.getByRole("button", { name: "Create account" }).isVisible()+ );++ await page+ .getByRole("button", { name: "Skip & go directly to the app" })+ .click();++ await page+ .waitForSelector(".ReactModal__Content", {+ timeout: 1000+ })+ .catch(() => {})+ .then(async () => {+ const positiveButton = page.locator(+ "button[data-role='positive-button']"+ );+ const negativeButton = page.locator(+ "button[data-role='negative-button']"+ );+ if (await positiveButton.isVisible()) await positiveButton.click();+ else if (await negativeButton.isVisible())+ await negativeButton.click();+ });++ await page.waitForSelector(".ProseMirror");++ await page+ .locator(".theme-scope-statusBar")+ .getByRole("button", { name: /available/i })+ .waitFor({ state: "attached" });+ },+ { version: "3.0.0" }+ );+});diff --git a/apps/desktop/__tests__/launch.test.mjs b/apps/desktop/__tests__/launch.test.tssimilarity index 68%rename from apps/desktop/__tests__/launch.test.mjsrename to apps/desktop/__tests__/launch.test.tsindex 2391a2223..938a0ed01 100644--- a/apps/desktop/__tests__/launch.test.mjs+++ b/apps/desktop/__tests__/launch.test.ts@@ -17,16 +17,12 @@ You should have received a copy of the GNU General Public Licensealong with this program. If not, see <http://www.gnu.org/licenses/>.*/-import test from "node:test";-import { launchApp } from "./utils.mjs";+import { test } from "vitest";+import { harness } from "./utils.js";import assert from "assert";-import slugify from "slugify";-import path from "path";-import { mkdir } from "fs/promises";test("make sure app loads", async (t) => {- const { app, page } = await launchApp();- try {+ await harness(t, async ({ page }) => {await page.waitForSelector("#authForm");assert.ok(@@ -38,16 +34,5 @@ test("make sure app loads", async (t) => {.click();await page.waitForSelector(".ProseMirror");- } catch (e) {- await mkdir("test-results", { recursive: true });- await page.screenshot({- path: path.join(- "test-results",- `${slugify(t.name)}-${process.platform}-${process.arch}-error.png`- )- });- throw e;- } finally {- await app.close();- }+ });});diff --git a/apps/desktop/__tests__/utils.ts b/apps/desktop/__tests__/utils.tsnew file mode 100644index 000000000..d80d5d00f--- /dev/null+++ b/apps/desktop/__tests__/utils.ts@@ -0,0 +1,158 @@+/*+This file is part of the Notesnook project (https://notesnook.com/)++Copyright (C) 2023 Streetwriters (Private) Limited++This program is free software: you can redistribute it and/or modify+it under the terms of the GNU General Public License as published by+the Free Software Foundation, either version 3 of the License, or+(at your option) any later version.++This program is distributed in the hope that it will be useful,+but WITHOUT ANY WARRANTY; without even the implied warranty of+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+GNU General Public License for more details.++You should have received a copy of the GNU General Public License+along with this program. If not, see <http://www.gnu.org/licenses/>.+*/++import { execSync } from "child_process";+import { mkdir } from "fs/promises";+import path from "path";+import { _electron as electron } from "playwright";+import slugify from "slugify";+import { TaskContext } from "vitest";++const __dirname = path.dirname(new URL(import.meta.url).pathname);++interface AppContext {+ app: import("playwright").ElectronApplication;+ page: import("playwright").Page;+ configPath: string;+ relaunch: () => Promise<void>;+}++interface TestOptions {+ version: string;+}++export async function harness(+ t: TaskContext,+ cb: (ctx: AppContext) => Promise<void>,+ options?: TestOptions+) {+ const ctx = await buildAndLaunchApp(options);++ t.onTestFinished(async (result) => {+ if (result.state === "fail") {+ await mkdir("test-results", { recursive: true });+ await ctx.page.screenshot({+ path: path.join(+ "test-results",+ `${slugify(t.task.name)}-${process.platform}-${+ process.arch+ }-error.png`+ )+ });+ }+ await ctx.app.close();+ });++ await cb(ctx);+}++async function buildAndLaunchApp(options?: TestOptions): Promise<AppContext> {+ const productName = makeid(10);+ const executablePath = await buildApp({ ...options, productName });+ const { app, page, configPath } = await launchApp(executablePath);+ const ctx: AppContext = {+ app,+ page,+ configPath,+ relaunch: async () => {+ const { app, page, configPath } = await launchApp(executablePath);+ ctx.app = app;+ ctx.page = page;+ ctx.configPath = configPath;+ }+ };+ return ctx;+}++async function launchApp(executablePath: string) {+ const app = await electron.launch({+ executablePath,+ args: process.env.NN_DEBUG ? [] : ["--hidden"]+ });++ const page = await app.firstWindow();++ const userDataDirectory = await app.evaluate((a) => {+ return a.app.getPath("userData");+ });+ const configPath = path.join(userDataDirectory, "config.json");+ return {+ app,+ page,+ configPath+ };+}++async function buildApp({+ version,+ productName+}: {+ version?: string;+ productName: string;+}) {+ const buildRoot = path.join("test-artifacts", `${productName}-build`);+ const output = path.join("test-artifacts", `${productName}-output`);+ execSync(`npm run release -- --root ${buildRoot}`, {+ stdio: process.env.NN_DEBUG ? "inherit" : "ignore"+ });++ const args = [+ `--config electron-builder.config.js`,+ `--c.extraMetadata.productName=${productName}`+ ];+ if (version) args.push(`--c.extraMetadata.version=${version}`);++ execSync(`npx electron-builder --dir --${process.arch} ${args.join(" ")}`, {+ stdio: process.env.NN_DEBUG ? "inherit" : "ignore",+ env: {+ ...process.env,+ NN_BUILD_ROOT: buildRoot,+ NN_PRODUCT_NAME: productName,+ NN_APP_ID: `com.notesnook.test.${productName}`,+ NN_OUTPUT_DIR: output+ }+ });++ return path.join(+ __dirname,+ "..",+ output,+ process.platform === "linux"+ ? "linux-unpacked"+ : process.platform === "darwin"+ ? process.arch === "arm64"+ ? `mac-arm64/${productName}.app/Contents/MacOS/`+ : `mac/${productName}.app/Contents/MacOS/`+ : "win-unpacked",+ process.platform === "win32" ? `${productName}.exe` : productName+ );+}++function makeid(length: number) {+ let result = "";+ const characters =+ "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";+ const charactersLength = characters.length;+ let counter = 0;+ while (counter < length) {+ result += characters.charAt(Math.floor(Math.random() * charactersLength));+ counter += 1;+ }+ return result;+}diff --git a/apps/desktop/electron-builder.config.js b/apps/desktop/electron-builder.config.jsnew file mode 100644index 000000000..247c4e5d6--- /dev/null+++ b/apps/desktop/electron-builder.config.js@@ -0,0 +1,197 @@+/*+This file is part of the Notesnook project (https://notesnook.com/)++Copyright (C) 2023 Streetwriters (Private) Limited++This program is free software: you can redistribute it and/or modify+it under the terms of the GNU General Public License as published by+the Free Software Foundation, either version 3 of the License, or+(at your option) any later version.++This program is distributed in the hope that it will be useful,+but WITHOUT ANY WARRANTY; without even the implied warranty of+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+GNU General Public License for more details.++You should have received a copy of the GNU General Public License+along with this program. If not, see <http://www.gnu.org/licenses/>.+*/++const path = require("path");++const buildRoot = process.env.NN_BUILD_ROOT || ".";+const buildFiles = [+ `${buildRoot}/build/`,+ `!${buildRoot}/build/screenshots\${/*}`,+ `!${buildRoot}/build/banner.jpg`,+ `!${buildRoot}/build/*.ico`,+ `!${buildRoot}/build/*.png`+];++const productName = process.env.NN_PRODUCT_NAME || "Notesnook";+const appId = process.env.NN_APP_ID || "org.streetwriters.notesnook";+const outputDir = process.env.NN_OUTPUT_DIR || "output";+const year = new Date().getFullYear();++module.exports = {+ appId: appId,+ productName: productName,+ copyright: `Copyright © ${year} Streetwriters (Private) Limited`,+ artifactName: "notesnook_${os}_${arch}.${ext}",+ generateUpdatesFilesForAllChannels: true,+ asar: false,+ files: [+ "!*.chunk.js.map",+ "!*.chunk.js.LICENSE.txt",+ ...buildFiles,+ "!node_modules${/*}",+ "node_modules/better-sqlite3-multiple-ciphers/build/Release/better_sqlite3.node",+ "node_modules/better-sqlite3-multiple-ciphers/lib",+ "node_modules/better-sqlite3-multiple-ciphers/package.json",+ "node_modules/file-uri-to-path",+ "node_modules/bindings",+ "node_modules/node-gyp-build",+ "node_modules/sqlite-better-trigram",+ "node_modules/sodium-native/prebuilds/${platform}-${arch}",+ {+ from: "node_modules/sqlite-better-trigram-linux-${arch}",+ to: "node_modules/sqlite-better-trigram-linux-${arch}"+ },+ {+ from: "node_modules/sqlite-better-trigram-darwin-${arch}",+ to: "node_modules/sqlite-better-trigram-darwin-${arch}"+ },+ {+ from: "node_modules/sqlite-better-trigram-windows-${arch}",+ to: "node_modules/sqlite-better-trigram-windows-${arch}"+ },+ "node_modules/sodium-native/index.js",+ "node_modules/sodium-native/package.json"+ ],+ afterPack: "./scripts/removeLocales.js",+ mac: {+ bundleVersion: "240",+ minimumSystemVersion: "10.12.0",+ target: [+ {+ target: "dmg",+ arch: ["arm64", "x64"]+ },+ {+ target: "zip",+ arch: ["arm64", "x64"]+ }+ ],+ category: "public.app-category.productivity",+ darkModeSupport: true,+ type: "distribution",+ hardenedRuntime: true,+ entitlements: "assets/entitlements.mac.plist",+ entitlementsInherit: "assets/entitlements.mac.plist",+ gatekeeperAssess: false,+ icon: "assets/icons/app.icns",+ notarize: true+ },+ dmg: {+ contents: [+ {+ x: 130,+ y: 220+ },+ {+ x: 410,+ y: 220,+ type: "link",+ path: "/Applications"+ }+ ],+ icon: "assets/icons/app.icns",+ title: "Install Notesnook"+ },+ mas: {+ entitlements: "assets/entitlements.mas.plist",+ entitlementsInherit: "assets/entitlements.mas.inherit.plist",+ entitlementsLoginHelper: "assets/entitlements.mas.loginhelper.plist",+ hardenedRuntime: true+ },+ win: {+ target: [+ {+ target: "nsis",+ arch: ["x64", "arm64"]+ },+ {+ target: "portable",+ arch: ["x64", "arm64"]+ }+ ],+ signtoolOptions: {+ signingHashAlgorithms: ["sha256"],+ sign: "./scripts/sign.js"+ },+ icon: "assets/icons/app.ico"+ },+ portable: {+ artifactName: "notesnook_${os}_${arch}_portable.${ext}"+ },+ nsis: {+ oneClick: true,+ createDesktopShortcut: "always",+ deleteAppDataOnUninstall: true+ },+ linux: {+ target: [+ {+ target: "AppImage",+ arch: ["x64", "arm64"]+ },+ {+ target: "snap",+ arch: ["x64", "arm64"]+ }+ ],+ category: "Office",+ icon: "assets/icons/app.icns",+ description: "Your private note taking space",+ executableName: "notesnook",+ desktop: {+ actions: [+ {+ id: "new-note",+ name: "New note",+ args: "new note"+ },+ {+ id: "new-notebook",+ name: "New notebook",+ args: "new notebook"+ },+ {+ id: "new-reminder",+ name: "New reminder",+ args: "new reminder"+ }+ ]+ }+ },+ snap: {+ autoStart: false,+ confinement: "strict",+ allowNativeWayland: true+ },+ extraResources: ["app-update.yml", "./assets/**"],+ extraMetadata: {+ main: path.join(buildRoot, "build", "electron.js")+ },+ directories: {+ buildResources: "assets",+ output: outputDir+ },+ publish: [+ {+ provider: "github",+ repo: "notesnook",+ owner: "streetwriters"+ }+ ]+};diff --git a/apps/desktop/package-lock.json b/apps/desktop/package-lock.jsonindex 75c85c6ef..b1d645b5e 100644--- a/apps/desktop/package-lock.json+++ b/apps/desktop/package-lock.json@@ -15,7 +15,7 @@"@trpc/client": "10.45.2","@trpc/server": "10.45.2","better-sqlite3-multiple-ciphers": "11.5.0",- "electron-trpc": "0.6.1",+ "electron-trpc": "0.7.1","electron-updater": "^6.3.4","icojs": "^0.19.4","sqlite-better-trigram": "0.0.2",@@ -38,7 +38,7 @@"slugify": "1.6.6","tree-kill": "^1.2.2","undici": "^6.19.8",- "vitest": "2.1.8"+ "vitest": "^2.1.8"},"optionalDependencies": {"dmg-license": "^1.0.11"@@ -150,7 +150,6 @@"version": "2.0.3","resolved": "https://registry.npmjs.org/@electron/get/-/get-2.0.3.tgz","integrity": "sha512-Qkzpg2s9GnVV2I2BjRksUi43U5e6+zaQMcjoJy0C+C5oxaKl+fmckGDQFtRpZpZV0NQekuZZ+tGz7EA9TVnQtQ==",- "dev": true,"license": "MIT","dependencies": {"debug": "^4.1.1",@@ -939,6 +938,101 @@"@jimp/custom": ">=0.3.5"}},+ "node_modules/@jimp/core": {+ "version": "0.22.12",+ "resolved": "https://registry.npmjs.org/@jimp/core/-/core-0.22.12.tgz",+ "integrity": "sha512-l0RR0dOPyzMKfjUW1uebzueFEDtCOj9fN6pyTYWWOM/VS4BciXQ1VVrJs8pO3kycGYZxncRKhCoygbNr8eEZQA==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "@jimp/utils": "^0.22.12",+ "any-base": "^1.1.0",+ "buffer": "^5.2.0",+ "exif-parser": "^0.1.12",+ "file-type": "^16.5.4",+ "isomorphic-fetch": "^3.0.0",+ "pixelmatch": "^4.0.2",+ "tinycolor2": "^1.6.0"+ }+ },+ "node_modules/@jimp/core/node_modules/file-type": {+ "version": "16.5.4",+ "resolved": "https://registry.npmjs.org/file-type/-/file-type-16.5.4.tgz",+ "integrity": "sha512-/yFHK0aGjFEgDJjEKP0pWCplsPFPhwyfwevf/pVxiN0tmE4L9LmwWxWukdJSHdoCli4VgQLehjJtwQBnqmsKcw==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "readable-web-to-node-stream": "^3.0.0",+ "strtok3": "^6.2.4",+ "token-types": "^4.1.1"+ },+ "engines": {+ "node": ">=10"+ },+ "funding": {+ "url": "https://github.com/sindresorhus/file-type?sponsor=1"+ }+ },+ "node_modules/@jimp/core/node_modules/peek-readable": {+ "version": "4.1.0",+ "resolved": "https://registry.npmjs.org/peek-readable/-/peek-readable-4.1.0.tgz",+ "integrity": "sha512-ZI3LnwUv5nOGbQzD9c2iDG6toheuXSZP5esSHBjopsXH4dg19soufvpUGA3uohi5anFtGb2lhAVdHzH6R/Evvg==",+ "license": "MIT",+ "peer": true,+ "engines": {+ "node": ">=8"+ },+ "funding": {+ "type": "github",+ "url": "https://github.com/sponsors/Borewit"+ }+ },+ "node_modules/@jimp/core/node_modules/strtok3": {+ "version": "6.3.0",+ "resolved": "https://registry.npmjs.org/strtok3/-/strtok3-6.3.0.tgz",+ "integrity": "sha512-fZtbhtvI9I48xDSywd/somNqgUHl2L2cstmXCCif0itOf96jeW18MBSyrLuNicYQVkvpOxkZtkzujiTJ9LW5Jw==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "@tokenizer/token": "^0.3.0",+ "peek-readable": "^4.1.0"+ },+ "engines": {+ "node": ">=10"+ },+ "funding": {+ "type": "github",+ "url": "https://github.com/sponsors/Borewit"+ }+ },+ "node_modules/@jimp/core/node_modules/token-types": {+ "version": "4.2.1",+ "resolved": "https://registry.npmjs.org/token-types/-/token-types-4.2.1.tgz",+ "integrity": "sha512-6udB24Q737UD/SDsKAHI9FCRP7Bqc9D/MQUV02ORQg5iskjtLJlZJNdN4kKtcdtwCeWIwIHDGaUsTsCCAa8sFQ==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "@tokenizer/token": "^0.3.0",+ "ieee754": "^1.2.1"+ },+ "engines": {+ "node": ">=10"+ },+ "funding": {+ "type": "github",+ "url": "https://github.com/sponsors/Borewit"+ }+ },+ "node_modules/@jimp/custom": {+ "version": "0.22.12",+ "resolved": "https://registry.npmjs.org/@jimp/custom/-/custom-0.22.12.tgz",+ "integrity": "sha512-xcmww1O/JFP2MrlGUMd3Q78S3Qu6W3mYTXYuIqFq33EorgYHV/HqymHfXy9GjiCJ7OI+7lWx6nYFOzU7M4rd1Q==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "@jimp/core": "^0.22.12"+ }+ },"node_modules/@jimp/utils": {"version": "0.22.12","resolved": "https://registry.npmjs.org/@jimp/utils/-/utils-0.22.12.tgz",@@ -1397,7 +1491,6 @@"version": "4.6.0","resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.6.0.tgz","integrity": "sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw==",- "dev": true,"license": "MIT","engines": {"node": ">=10"@@ -1420,7 +1513,6 @@"version": "4.0.6","resolved": "https://registry.npmjs.org/@szmarczak/http-timer/-/http-timer-4.0.6.tgz","integrity": "sha512-4BAffykYOgO+5nzBWYwE3W90sBgLJoUPRWWcL8wlyiM8IB8ipJz3UMJ9KXQd1RKQXpKp8Tutn80HZtWsu2u76w==",- "dev": true,"license": "MIT","dependencies": {"defer-to-connect": "^2.0.0"@@ -1470,7 +1562,6 @@"version": "6.0.3","resolved": "https://registry.npmjs.org/@types/cacheable-request/-/cacheable-request-6.0.3.tgz","integrity": "sha512-IQ3EbTzGxIigb1I3qPZc1rWJnH0BmSKv5QYTalEwweFvyBDLSAe24zP0le/hyi7ecGfZVlIVAg4BZqb8WBwKqw==",- "dev": true,"license": "MIT","dependencies": {"@types/http-cache-semantics": "*",@@ -1509,14 +1600,12 @@"version": "4.0.4","resolved": "https://registry.npmjs.org/@types/http-cache-semantics/-/http-cache-semantics-4.0.4.tgz","integrity": "sha512-1m0bIFVc7eJWyve9S0RnuRgcQqF/Xd5QsUZAZeQFr1Q3/p9JWoQQEqmVy+DPTNpGXwhgIetAoYF8JSc33q29QA==",- "dev": true,"license": "MIT"},"node_modules/@types/keyv": {"version": "3.1.4","resolved": "https://registry.npmjs.org/@types/keyv/-/keyv-3.1.4.tgz","integrity": "sha512-BQ5aZNSCpj7D6K2ksrRCTmKRLEpnPvWDiLPfoGyhZ++8YtiK9d/3DBKPJgry359X/P1PfruyYwvnvwFjuEiEIg==",- "dev": true,"license": "MIT","dependencies": {"@types/node": "*"@@ -1533,7 +1622,6 @@"version": "22.7.0","resolved": "https://registry.npmjs.org/@types/node/-/node-22.7.0.tgz","integrity": "sha512-MOdOibwBs6KW1vfqz2uKMlxq5xAfAZ98SZjO8e3XnAbFnTJtAspqhWk7hrdSAs9/Y14ZWMiy7/MxMUzAOadYEw==",- "devOptional": true,"license": "MIT","dependencies": {"undici-types": "~6.19.2"@@ -1554,7 +1642,6 @@"version": "1.0.3","resolved": "https://registry.npmjs.org/@types/responselike/-/responselike-1.0.3.tgz","integrity": "sha512-H/+L+UkTV33uf49PH5pCAUBVPNj2nDBXTN+qS1dOwyyg24l3CcicicCA7ca+HMvJBZcFgl5r8e+RR6elsb4Lyw==",- "dev": true,"license": "MIT","dependencies": {"@types/node": "*"@@ -1588,7 +1675,6 @@"version": "2.10.3","resolved": "https://registry.npmjs.org/@types/yauzl/-/yauzl-2.10.3.tgz","integrity": "sha512-oJoftv0LSuaDZE3Le4DbKX+KS9G36NzOeSap90UIK0yMA/NhKJhqlSGtNDORNRaIbQfzjXDrQa0ytJ6mNRGz/Q==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -1725,6 +1811,19 @@"dev": true,"license": "ISC"},+ "node_modules/abort-controller": {+ "version": "3.0.0",+ "resolved": "https://registry.npmjs.org/abort-controller/-/abort-controller-3.0.0.tgz",+ "integrity": "sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "event-target-shim": "^5.0.0"+ },+ "engines": {+ "node": ">=6.5"+ }+ },"node_modules/agent-base": {"version": "7.1.1","resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.1.tgz",@@ -1816,6 +1915,13 @@"url": "https://github.com/chalk/ansi-styles?sponsor=1"}},+ "node_modules/any-base": {+ "version": "1.1.0",+ "resolved": "https://registry.npmjs.org/any-base/-/any-base-1.1.0.tgz",+ "integrity": "sha512-uMgjozySS8adZZYePpaWs8cxB9/kdzmpX6SgJZ+wbz1K5eYk5QMYDVJaZKhxyIHUdnnJkfR7SVgStgH7LkGUyg==",+ "license": "MIT",+ "peer": true+ },"node_modules/app-builder-bin": {"version": "5.0.0-alpha.10","resolved": "https://registry.npmjs.org/app-builder-bin/-/app-builder-bin-5.0.0-alpha.10.tgz",@@ -1929,6 +2035,85 @@"dev": true,"license": "ISC"},+ "node_modules/archiver": {+ "version": "5.3.2",+ "resolved": "https://registry.npmjs.org/archiver/-/archiver-5.3.2.tgz",+ "integrity": "sha512-+25nxyyznAXF7Nef3y0EbBeqmGZgeN/BxHX29Rs39djAfaFalmQ89SE6CWyDCHzGL0yt/ycBtNOmGTW0FyGWNw==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "archiver-utils": "^2.1.0",+ "async": "^3.2.4",+ "buffer-crc32": "^0.2.1",+ "readable-stream": "^3.6.0",+ "readdir-glob": "^1.1.2",+ "tar-stream": "^2.2.0",+ "zip-stream": "^4.1.0"+ },+ "engines": {+ "node": ">= 10"+ }+ },+ "node_modules/archiver-utils": {+ "version": "2.1.0",+ "resolved": "https://registry.npmjs.org/archiver-utils/-/archiver-utils-2.1.0.tgz",+ "integrity": "sha512-bEL/yUb/fNNiNTuUz979Z0Yg5L+LzLxGJz8x79lYmR54fmTIb6ob/hNQgkQnIUDWIFjZVQwl9Xs356I6BAMHfw==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "glob": "^7.1.4",+ "graceful-fs": "^4.2.0",+ "lazystream": "^1.0.0",+ "lodash.defaults": "^4.2.0",+ "lodash.difference": "^4.5.0",+ "lodash.flatten": "^4.4.0",+ "lodash.isplainobject": "^4.0.6",+ "lodash.union": "^4.6.0",+ "normalize-path": "^3.0.0",+ "readable-stream": "^2.0.0"+ },+ "engines": {+ "node": ">= 6"+ }+ },+ "node_modules/archiver-utils/node_modules/readable-stream": {+ "version": "2.3.8",+ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz",+ "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "core-util-is": "~1.0.0",+ "inherits": "~2.0.3",+ "isarray": "~1.0.0",+ "process-nextick-args": "~2.0.0",+ "safe-buffer": "~5.1.1",+ "string_decoder": "~1.1.1",+ "util-deprecate": "~1.0.1"+ }+ },+ "node_modules/archiver-utils/node_modules/safe-buffer": {+ "version": "5.1.2",+ "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",+ "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==",+ "dev": true,+ "license": "MIT",+ "peer": true+ },+ "node_modules/archiver-utils/node_modules/string_decoder": {+ "version": "1.1.1",+ "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",+ "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "safe-buffer": "~5.1.0"+ }+ },"node_modules/are-we-there-yet": {"version": "3.0.1","resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-3.0.1.tgz",@@ -2098,7 +2283,6 @@"version": "3.2.0","resolved": "https://registry.npmjs.org/boolean/-/boolean-3.2.0.tgz","integrity": "sha512-d0II/GO9uf9lfUHH2BQsjxzRJZBdsjgsBiW4BvhWk/3qoKwQFjIDVN19PfX8F2D/r9PCMTtLWjYVCFrpeYUzsw==",- "dev": true,"license": "MIT","optional": true},@@ -2140,7 +2324,6 @@"version": "0.2.13","resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz","integrity": "sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==",- "dev": true,"license": "MIT","engines": {"node": "*"@@ -2316,7 +2499,6 @@"version": "5.0.4","resolved": "https://registry.npmjs.org/cacheable-lookup/-/cacheable-lookup-5.0.4.tgz","integrity": "sha512-2/kNscPhpcxrOigMZzbiWF7dz8ilhb/nIHU3EyZiXWXpeq/au8qJ8VhdftMkty3n7Gj6HIGalQG8oiBNB3AJgA==",- "dev": true,"license": "MIT","engines": {"node": ">=10.6.0"@@ -2326,7 +2508,6 @@"version": "7.0.4","resolved": "https://registry.npmjs.org/cacheable-request/-/cacheable-request-7.0.4.tgz","integrity": "sha512-v+p6ongsrp0yTGbJXjgxPow2+DL93DASP4kXCDKb8/bwRtt9OEF3whggkkDkGNzgcWy2XaF4a8nZglC7uElscg==",- "dev": true,"license": "MIT","dependencies": {"clone-response": "^1.0.2",@@ -2513,7 +2694,6 @@"version": "1.0.3","resolved": "https://registry.npmjs.org/clone-response/-/clone-response-1.0.3.tgz","integrity": "sha512-ROoL94jJH2dUVML2Y/5PEDNaSHgeOdSDicUyS7izcF63G6sTc/FTjLub4b8Il9S8S0beOfYt0TaA5qvFK+w0wA==",- "dev": true,"license": "MIT","dependencies": {"mimic-response": "^1.0.0"@@ -2583,6 +2763,23 @@"node": ">=0.10.0"}},+ "node_modules/compress-commons": {+ "version": "4.1.2",+ "resolved": "https://registry.npmjs.org/compress-commons/-/compress-commons-4.1.2.tgz",+ "integrity": "sha512-D3uMHtGc/fcO1Gt1/L7i1e33VOvD4A9hfQLP+6ewd+BvG/gQ84Yh4oftEhAdjSMgBgwGL+jsppT7JYNpo6MHHg==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "buffer-crc32": "^0.2.13",+ "crc32-stream": "^4.0.2",+ "normalize-path": "^3.0.0",+ "readable-stream": "^3.6.0"+ },+ "engines": {+ "node": ">= 10"+ }+ },"node_modules/concat-map": {"version": "0.0.1","resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",@@ -2659,8 +2856,8 @@"version": "1.0.2","resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz","integrity": "sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==",- "license": "MIT",- "optional": true+ "devOptional": true,+ "license": "MIT"},"node_modules/crc": {"version": "3.8.0",@@ -2672,6 +2869,35 @@"buffer": "^5.1.0"}},+ "node_modules/crc-32": {+ "version": "1.2.2",+ "resolved": "https://registry.npmjs.org/crc-32/-/crc-32-1.2.2.tgz",+ "integrity": "sha512-ROmzCKrTnOwybPcJApAA6WBWij23HVfGVNKqqrZpuyZOHqK2CwHSvpGuyt/UNNvaIjEd8X5IFGp4Mh+Ie1IHJQ==",+ "dev": true,+ "license": "Apache-2.0",+ "peer": true,+ "bin": {+ "crc32": "bin/crc32.njs"+ },+ "engines": {+ "node": ">=0.8"+ }+ },+ "node_modules/crc32-stream": {+ "version": "4.0.3",+ "resolved": "https://registry.npmjs.org/crc32-stream/-/crc32-stream-4.0.3.tgz",+ "integrity": "sha512-NT7w2JVU7DFroFdYkeq8cywxrgjPHWkdX1wjpRQXPX5Asews3tA+Ght6lddQO5Mkumffp3X7GEqku3epj2toIw==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "crc-32": "^1.2.0",+ "readable-stream": "^3.4.0"+ },+ "engines": {+ "node": ">= 10"+ }+ },"node_modules/cross-spawn": {"version": "7.0.5","resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.5.tgz",@@ -2805,7 +3031,6 @@"version": "2.0.1","resolved": "https://registry.npmjs.org/defer-to-connect/-/defer-to-connect-2.0.1.tgz","integrity": "sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg==",- "dev": true,"license": "MIT","engines": {"node": ">=10"@@ -2815,7 +3040,6 @@"version": "1.1.4","resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz","integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -2834,7 +3058,6 @@"version": "1.2.1","resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz","integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -2879,7 +3102,6 @@"version": "2.1.0","resolved": "https://registry.npmjs.org/detect-node/-/detect-node-2.1.0.tgz","integrity": "sha512-T0NIuQpnTvFDATNuHN5roPwSBG83rFsuO+MXXH9/3N1eFbn4wcPjttvjMLEPWJ0RGUYgQE7cGgS3tNxbqCGM7g==",- "dev": true,"license": "MIT","optional": true},@@ -3056,7 +3278,6 @@"version": "31.7.4","resolved": "https://registry.npmjs.org/electron/-/electron-31.7.4.tgz","integrity": "sha512-uvSxcYq349bbCp60vmsTJGviI0pBfrvZK+YQHs3L0nzhZeBin0+o7bC1j3vmK+CeTxAZlWWjtgtc3z7XYrHm5w==",- "dev": true,"hasInstallScript": true,"license": "MIT","dependencies": {@@ -3097,6 +3318,61 @@"node": ">=14.0.0"}},+ "node_modules/electron-builder-squirrel-windows": {+ "version": "25.1.8",+ "resolved": "https://registry.npmjs.org/electron-builder-squirrel-windows/-/electron-builder-squirrel-windows-25.1.8.tgz",+ "integrity": "sha512-2ntkJ+9+0GFP6nAISiMabKt6eqBB0kX1QqHNWFWAXgi0VULKGisM46luRFpIBiU3u/TDmhZMM8tzvo2Abn3ayg==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "app-builder-lib": "25.1.8",+ "archiver": "^5.3.1",+ "builder-util": "25.1.7",+ "fs-extra": "^10.1.0"+ }+ },+ "node_modules/electron-builder-squirrel-windows/node_modules/fs-extra": {+ "version": "10.1.0",+ "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz",+ "integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "graceful-fs": "^4.2.0",+ "jsonfile": "^6.0.1",+ "universalify": "^2.0.0"+ },+ "engines": {+ "node": ">=12"+ }+ },+ "node_modules/electron-builder-squirrel-windows/node_modules/jsonfile": {+ "version": "6.1.0",+ "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",+ "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "universalify": "^2.0.0"+ },+ "optionalDependencies": {+ "graceful-fs": "^4.1.6"+ }+ },+ "node_modules/electron-builder-squirrel-windows/node_modules/universalify": {+ "version": "2.0.1",+ "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",+ "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "engines": {+ "node": ">= 10.0.0"+ }+ },"node_modules/electron-builder/node_modules/fs-extra": {"version": "10.1.0","resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz",@@ -3190,9 +3466,9 @@}},"node_modules/electron-trpc": {- "version": "0.6.1",- "resolved": "https://registry.npmjs.org/electron-trpc/-/electron-trpc-0.6.1.tgz",- "integrity": "sha512-Yj13UrjjjOW4+TD06YunAML2tgmtSYJMiFw6E6r1D4in/0EZ2MRwMoQc7AtMPAA6In23e+Kmq71e8h0ir+c3Jg==",+ "version": "0.7.1",+ "resolved": "https://registry.npmjs.org/electron-trpc/-/electron-trpc-0.7.1.tgz",+ "integrity": "sha512-aWjZ5pLeVhrX9A9d8O8YgR8N+q4IXXzc76CJT1PwtDijIw+y5I+c75IAAtZ4JayYLeR3ll95PNGl5RTBu2qePw==","license": "MIT","dependencies": {"debug": "^4.3.4"@@ -3270,7 +3546,6 @@"version": "20.16.11","resolved": "https://registry.npmjs.org/@types/node/-/node-20.16.11.tgz","integrity": "sha512-y+cTCACu92FyA5fgQSAI8A1H429g7aSK2HsO7K4XYUWc4dY5IUz55JSDIYT6/VsOLfGy8vmvQYC2hfb0iF16Uw==",- "dev": true,"license": "MIT","dependencies": {"undici-types": "~6.19.2"@@ -3286,7 +3561,6 @@"version": "0.1.13","resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.13.tgz","integrity": "sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -3306,7 +3580,6 @@"version": "2.2.1","resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz","integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==",- "dev": true,"license": "MIT","engines": {"node": ">=6"@@ -3323,7 +3596,6 @@"version": "1.0.0","resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz","integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -3337,7 +3609,6 @@"version": "1.3.0","resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz","integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==",- "dev": true,"license": "MIT","optional": true,"engines": {@@ -3354,7 +3625,6 @@"version": "4.1.1","resolved": "https://registry.npmjs.org/es6-error/-/es6-error-4.1.1.tgz","integrity": "sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg==",- "dev": true,"license": "MIT","optional": true},@@ -3409,7 +3679,6 @@"version": "4.0.0","resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz","integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==",- "dev": true,"license": "MIT","optional": true,"engines": {@@ -3428,6 +3697,32 @@"@types/estree": "^1.0.0"}},+ "node_modules/event-target-shim": {+ "version": "5.0.1",+ "resolved": "https://registry.npmjs.org/event-target-shim/-/event-target-shim-5.0.1.tgz",+ "integrity": "sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==",+ "license": "MIT",+ "peer": true,+ "engines": {+ "node": ">=6"+ }+ },+ "node_modules/events": {+ "version": "3.3.0",+ "resolved": "https://registry.npmjs.org/events/-/events-3.3.0.tgz",+ "integrity": "sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==",+ "license": "MIT",+ "peer": true,+ "engines": {+ "node": ">=0.8.x"+ }+ },+ "node_modules/exif-parser": {+ "version": "0.1.12",+ "resolved": "https://registry.npmjs.org/exif-parser/-/exif-parser-0.1.12.tgz",+ "integrity": "sha512-c2bQfLNbMzLPmzQuOr8fy0csy84WmwnER81W88DzTp9CYNPJ6yzOj2EZAh9pywYpqHnshVLHQJ8WzldAyfY+Iw==",+ "peer": true+ },"node_modules/expand-template": {"version": "2.0.3","resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz",@@ -3458,7 +3753,6 @@"version": "2.0.1","resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-2.0.1.tgz","integrity": "sha512-GDhU9ntwuKyGXdZBUgTIe+vXnWj0fppUEtMDL0+idd5Sta8TGpHssn/eusA9mrPr9qNDym6SxAYZjNvCn/9RBg==",- "dev": true,"license": "BSD-2-Clause","dependencies": {"debug": "^4.1.1",@@ -3503,7 +3797,6 @@"version": "1.1.0","resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.1.0.tgz","integrity": "sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==",- "dev": true,"license": "MIT","dependencies": {"pend": "~1.2.0"@@ -3627,7 +3920,6 @@"version": "8.1.0","resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz","integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==",- "dev": true,"license": "MIT","dependencies": {"graceful-fs": "^4.2.0",@@ -3677,7 +3969,6 @@"version": "1.1.2","resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz","integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==",- "dev": true,"license": "MIT","optional": true,"funding": {@@ -3718,7 +4009,6 @@"version": "1.2.4","resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz","integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -3739,7 +4029,6 @@"version": "5.2.0","resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz","integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==",- "dev": true,"license": "MIT","dependencies": {"pump": "^3.0.0"@@ -3807,7 +4096,6 @@"version": "3.0.0","resolved": "https://registry.npmjs.org/global-agent/-/global-agent-3.0.0.tgz","integrity": "sha512-PT6XReJ+D07JvGoxQMkT6qji/jVNfX/h364XHZOWeRzy64sSFr+xJ5OX7LI3b4MPQzdL4H8Y8M0xzPpsVMwA8Q==",- "dev": true,"license": "BSD-3-Clause","optional": true,"dependencies": {@@ -3826,7 +4114,6 @@"version": "7.6.3","resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz","integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==",- "dev": true,"license": "ISC","optional": true,"bin": {@@ -3840,7 +4127,6 @@"version": "1.0.4","resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.4.tgz","integrity": "sha512-DpLKbNU4WylpxJykQujfCcwYWiV/Jhm50Goo0wrVILAv5jOr9d+H+UR3PhSCD2rCCEIg0uc+G+muBTwD54JhDQ==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -3858,7 +4144,6 @@"version": "1.0.1","resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz","integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -3872,7 +4157,6 @@"version": "11.8.6","resolved": "https://registry.npmjs.org/got/-/got-11.8.6.tgz","integrity": "sha512-6tfZ91bOr7bOXnK7PRDCGBLa1H4U080YHNaAQ2KsMGlLEzRbk44nsZF2E1IeRc3vtJHPVbKCYgdFbaGO2ljd8g==",- "dev": true,"license": "MIT","dependencies": {"@sindresorhus/is": "^4.0.0",@@ -3914,7 +4198,6 @@"version": "1.0.2","resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz","integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -3928,7 +4211,6 @@"version": "1.0.3","resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz","integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==",- "dev": true,"license": "MIT","optional": true,"engines": {@@ -3942,7 +4224,6 @@"version": "1.0.3","resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz","integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==",- "dev": true,"license": "MIT","optional": true,"engines": {@@ -3963,7 +4244,6 @@"version": "2.0.2","resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz","integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -3990,7 +4270,6 @@"version": "4.1.1","resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz","integrity": "sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==",- "dev": true,"license": "BSD-2-Clause"},"node_modules/http-proxy-agent": {@@ -4011,7 +4290,6 @@"version": "1.0.3","resolved": "https://registry.npmjs.org/http2-wrapper/-/http2-wrapper-1.0.3.tgz","integrity": "sha512-V+23sDMr12Wnz7iTcDeJr3O6AIxlnvT/bmaAAAP/Xda35C90p9599p0F1eHR/N1KILWSoWVAiOMFjBBXaXSMxg==",- "dev": true,"license": "MIT","dependencies": {"quick-lru": "^5.1.1",@@ -4083,7 +4361,7 @@"version": "0.6.3","resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz","integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==",- "dev": true,+ "devOptional": true,"license": "MIT","dependencies": {"safer-buffer": ">= 2.1.2 < 3.0.0"@@ -4241,6 +4519,14 @@"url": "https://github.com/sponsors/sindresorhus"}},+ "node_modules/isarray": {+ "version": "1.0.0",+ "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",+ "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==",+ "dev": true,+ "license": "MIT",+ "peer": true+ },"node_modules/isbinaryfile": {"version": "5.0.4","resolved": "https://registry.npmjs.org/isbinaryfile/-/isbinaryfile-5.0.4.tgz",@@ -4261,6 +4547,17 @@"dev": true,"license": "ISC"},+ "node_modules/isomorphic-fetch": {+ "version": "3.0.0",+ "resolved": "https://registry.npmjs.org/isomorphic-fetch/-/isomorphic-fetch-3.0.0.tgz",+ "integrity": "sha512-qvUtwJ3j6qwsF3jLxkZ72qCgjMysPzDfeV240JHiGZsANBYd+EEuu35v7dfrJ9Up0Ak07D7GGSkGhCHTqg/5wA==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "node-fetch": "^2.6.1",+ "whatwg-fetch": "^3.4.1"+ }+ },"node_modules/jackspeak": {"version": "3.4.3","resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-3.4.3.tgz",@@ -4354,7 +4651,6 @@"version": "3.0.1","resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz","integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==",- "dev": true,"license": "MIT"},"node_modules/json-schema-traverse": {@@ -4368,7 +4664,6 @@"version": "5.0.1","resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz","integrity": "sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==",- "dev": true,"license": "ISC","optional": true},@@ -4389,7 +4684,6 @@"version": "4.0.0","resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz","integrity": "sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==",- "dev": true,"license": "MIT","optionalDependencies": {"graceful-fs": "^4.1.6"@@ -4399,7 +4693,6 @@"version": "4.5.4","resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz","integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==",- "dev": true,"license": "MIT","dependencies": {"json-buffer": "3.0.1"@@ -4411,6 +4704,56 @@"integrity": "sha512-0/BnGCCfyUMkBpeDgWihanIAF9JmZhHBgUhEqzvf+adhNGLoP6TaiI5oF8oyb3I45P+PcnrqihSf01M0l0G5+Q==","license": "MIT"},+ "node_modules/lazystream": {+ "version": "1.0.1",+ "resolved": "https://registry.npmjs.org/lazystream/-/lazystream-1.0.1.tgz",+ "integrity": "sha512-b94GiNHQNy6JNTrt5w6zNyffMrNkXZb3KTkCZJb2V1xaEGCk093vkZ2jk3tpaeP33/OiXC+WvK9AxUebnf5nbw==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "readable-stream": "^2.0.5"+ },+ "engines": {+ "node": ">= 0.6.3"+ }+ },+ "node_modules/lazystream/node_modules/readable-stream": {+ "version": "2.3.8",+ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz",+ "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "core-util-is": "~1.0.0",+ "inherits": "~2.0.3",+ "isarray": "~1.0.0",+ "process-nextick-args": "~2.0.0",+ "safe-buffer": "~5.1.1",+ "string_decoder": "~1.1.1",+ "util-deprecate": "~1.0.1"+ }+ },+ "node_modules/lazystream/node_modules/safe-buffer": {+ "version": "5.1.2",+ "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",+ "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==",+ "dev": true,+ "license": "MIT",+ "peer": true+ },+ "node_modules/lazystream/node_modules/string_decoder": {+ "version": "1.1.1",+ "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",+ "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "safe-buffer": "~5.1.0"+ }+ },"node_modules/lodash": {"version": "4.17.21","resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",@@ -4418,18 +4761,58 @@"dev": true,"license": "MIT"},+ "node_modules/lodash.defaults": {+ "version": "4.2.0",+ "resolved": "https://registry.npmjs.org/lodash.defaults/-/lodash.defaults-4.2.0.tgz",+ "integrity": "sha512-qjxPLHd3r5DnsdGacqOMU6pb/avJzdh9tFX2ymgoZE27BmjXrNy/y4LoaiTeAb+O3gL8AfpJGtqfX/ae2leYYQ==",+ "dev": true,+ "license": "MIT",+ "peer": true+ },+ "node_modules/lodash.difference": {+ "version": "4.5.0",+ "resolved": "https://registry.npmjs.org/lodash.difference/-/lodash.difference-4.5.0.tgz",+ "integrity": "sha512-dS2j+W26TQ7taQBGN8Lbbq04ssV3emRw4NY58WErlTO29pIqS0HmoT5aJ9+TUQ1N3G+JOZSji4eugsWwGp9yPA==",+ "dev": true,+ "license": "MIT",+ "peer": true+ },"node_modules/lodash.escaperegexp": {"version": "4.1.2","resolved": "https://registry.npmjs.org/lodash.escaperegexp/-/lodash.escaperegexp-4.1.2.tgz","integrity": "sha512-TM9YBvyC84ZxE3rgfefxUWiQKLilstD6k7PTGt6wfbtXF8ixIJLOL3VYyV/z+ZiPLsVxAsKAFVwWlWeb2Y8Yyw==","license": "MIT"},+ "node_modules/lodash.flatten": {+ "version": "4.4.0",+ "resolved": "https://registry.npmjs.org/lodash.flatten/-/lodash.flatten-4.4.0.tgz",+ "integrity": "sha512-C5N2Z3DgnnKr0LOpv/hKCgKdb7ZZwafIrsesve6lmzvZIRZRGaZ/l6Q8+2W7NaT+ZwO3fFlSCzCzrDCFdJfZ4g==",+ "dev": true,+ "license": "MIT",+ "peer": true+ },"node_modules/lodash.isequal": {"version": "4.5.0","resolved": "https://registry.npmjs.org/lodash.isequal/-/lodash.isequal-4.5.0.tgz","integrity": "sha512-pDo3lu8Jhfjqls6GkMgpahsF9kCyayhgykjyLMNFTKWrpVdAQtYyB4muAMWozBB4ig/dtWAmsMxLEI8wuz+DYQ==","license": "MIT"},+ "node_modules/lodash.isplainobject": {+ "version": "4.0.6",+ "resolved": "https://registry.npmjs.org/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz",+ "integrity": "sha512-oSXzaWypCMHkPC3NvBEaPHf0KsA5mvPrOPgQWDsbg8n7orZ290M0BmC/jgRZ4vcJ6DTAhjrsSYgdsW/F+MFOBA==",+ "dev": true,+ "license": "MIT",+ "peer": true+ },+ "node_modules/lodash.union": {+ "version": "4.6.0",+ "resolved": "https://registry.npmjs.org/lodash.union/-/lodash.union-4.6.0.tgz",+ "integrity": "sha512-c4pB2CdGrGdjMKYLA+XiRDO7Y0PRQbm/Gzg8qMj+QH+pFVAoTp5sBpO0odL3FjoPCGjK96p6qsP+yQoiLoOBcw==",+ "dev": true,+ "license": "MIT",+ "peer": true+ },"node_modules/log-symbols": {"version": "4.1.0","resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz",@@ -4457,7 +4840,6 @@"version": "2.0.0","resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-2.0.0.tgz","integrity": "sha512-tqNXrS78oMOE73NMxK4EMLQsQowWf8jKooH9g7xPavRT706R6bkQJ6DY2Te7QukaZsulxa30wQ7bk0pm4XiHmA==",- "dev": true,"license": "MIT","engines": {"node": ">=8"@@ -4569,7 +4951,6 @@"version": "3.0.0","resolved": "https://registry.npmjs.org/matcher/-/matcher-3.0.0.tgz","integrity": "sha512-OkeDaAZ/bQCxeFAozM55PKcKU0yJMPGifLwV4Qgjitu+5MoAfSQN4lsLJeXZ1b8w0x+/Emda6MZgXS1jvsapng==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -4629,7 +5010,6 @@"version": "1.0.1","resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-1.0.1.tgz","integrity": "sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ==",- "dev": true,"license": "MIT","engines": {"node": ">=4"@@ -4875,6 +5255,27 @@"node": ">=10"}},+ "node_modules/node-fetch": {+ "version": "2.7.0",+ "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz",+ "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "whatwg-url": "^5.0.0"+ },+ "engines": {+ "node": "4.x || >=6.0.0"+ },+ "peerDependencies": {+ "encoding": "^0.1.0"+ },+ "peerDependenciesMeta": {+ "encoding": {+ "optional": true+ }+ }+ },"node_modules/node-gyp": {"version": "9.4.1","resolved": "https://registry.npmjs.org/node-gyp/-/node-gyp-9.4.1.tgz",@@ -4942,11 +5343,21 @@"node": "^12.13.0 || ^14.15.0 || >=16.0.0"}},+ "node_modules/normalize-path": {+ "version": "3.0.0",+ "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz",+ "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "engines": {+ "node": ">=0.10.0"+ }+ },"node_modules/normalize-url": {"version": "6.1.0","resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-6.1.0.tgz","integrity": "sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==",- "dev": true,"license": "MIT","engines": {"node": ">=10"@@ -4989,7 +5400,6 @@"version": "1.1.1","resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz","integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==",- "dev": true,"license": "MIT","optional": true,"engines": {@@ -5049,7 +5459,6 @@"version": "2.1.1","resolved": "https://registry.npmjs.org/p-cancelable/-/p-cancelable-2.1.1.tgz","integrity": "sha512-BZOr3nRQHOntUjTrH8+Lh54smKHoHyur8We1V8DSMVrl5A2malOOwuJRnKRDjSnkoeBh4at6BwEnb5I7Jl31wg==",- "dev": true,"license": "MIT","engines": {"node": ">=8"@@ -5195,7 +5604,6 @@"version": "1.2.0","resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz","integrity": "sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==",- "dev": true,"license": "MIT"},"node_modules/picocolors": {@@ -5204,6 +5612,29 @@"integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==","dev": true},+ "node_modules/pixelmatch": {+ "version": "4.0.2",+ "resolved": "https://registry.npmjs.org/pixelmatch/-/pixelmatch-4.0.2.tgz",+ "integrity": "sha512-J8B6xqiO37sU/gkcMglv6h5Jbd9xNER7aHzpfRdNmV4IbQBzBpe4l9XmbG+xPF/znacgu2jfEw+wHffaq/YkXA==",+ "license": "ISC",+ "peer": true,+ "dependencies": {+ "pngjs": "^3.0.0"+ },+ "bin": {+ "pixelmatch": "bin/pixelmatch"+ }+ },+ "node_modules/pixelmatch/node_modules/pngjs": {+ "version": "3.4.0",+ "resolved": "https://registry.npmjs.org/pngjs/-/pngjs-3.4.0.tgz",+ "integrity": "sha512-NCrCHhWmnQklfH4MtJMRjZ2a8c80qXeMlQMv2uVp9ISJMTt562SbGd6n2oq0PaPgKm7Z6pL9E2UlLIhC+SHL3w==",+ "license": "MIT",+ "peer": true,+ "engines": {+ "node": ">=4.0.0"+ }+ },"node_modules/playwright": {"version": "1.48.2","resolved": "https://registry.npmjs.org/playwright/-/playwright-1.48.2.tgz",@@ -5332,11 +5763,28 @@"prebuildify": "bin.js"}},+ "node_modules/process": {+ "version": "0.11.10",+ "resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz",+ "integrity": "sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==",+ "license": "MIT",+ "peer": true,+ "engines": {+ "node": ">= 0.6.0"+ }+ },+ "node_modules/process-nextick-args": {+ "version": "2.0.1",+ "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz",+ "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==",+ "dev": true,+ "license": "MIT",+ "peer": true+ },"node_modules/progress": {"version": "2.0.3","resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz","integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==",- "dev": true,"license": "MIT","engines": {"node": ">=0.4.0"@@ -5387,7 +5835,6 @@"version": "5.1.1","resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-5.1.1.tgz","integrity": "sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==",- "dev": true,"license": "MIT","engines": {"node": ">=10"@@ -5438,6 +5885,90 @@"node": ">= 6"}},+ "node_modules/readable-web-to-node-stream": {+ "version": "3.0.4",+ "resolved": "https://registry.npmjs.org/readable-web-to-node-stream/-/readable-web-to-node-stream-3.0.4.tgz",+ "integrity": "sha512-9nX56alTf5bwXQ3ZDipHJhusu9NTQJ/CVPtb/XHAJCXihZeitfJvIRS4GqQ/mfIoOE3IelHMrpayVrosdHBuLw==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "readable-stream": "^4.7.0"+ },+ "engines": {+ "node": ">=8"+ },+ "funding": {+ "type": "github",+ "url": "https://github.com/sponsors/Borewit"+ }+ },+ "node_modules/readable-web-to-node-stream/node_modules/buffer": {+ "version": "6.0.3",+ "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz",+ "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==",+ "funding": [+ {+ "type": "github",+ "url": "https://github.com/sponsors/feross"+ },+ {+ "type": "patreon",+ "url": "https://www.patreon.com/feross"+ },+ {+ "type": "consulting",+ "url": "https://feross.org/support"+ }+ ],+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "base64-js": "^1.3.1",+ "ieee754": "^1.2.1"+ }+ },+ "node_modules/readable-web-to-node-stream/node_modules/readable-stream": {+ "version": "4.7.0",+ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-4.7.0.tgz",+ "integrity": "sha512-oIGGmcpTLwPga8Bn6/Z75SVaH1z5dUut2ibSyAMVhmUggWpmDn2dapB0n7f8nwaSiRtepAsfJyfXIO5DCVAODg==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "abort-controller": "^3.0.0",+ "buffer": "^6.0.3",+ "events": "^3.3.0",+ "process": "^0.11.10",+ "string_decoder": "^1.3.0"+ },+ "engines": {+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"+ }+ },+ "node_modules/readdir-glob": {+ "version": "1.1.3",+ "resolved": "https://registry.npmjs.org/readdir-glob/-/readdir-glob-1.1.3.tgz",+ "integrity": "sha512-v05I2k7xN8zXvPD9N+z/uhXPaj0sUFCe2rcWZIpBsqxfP7xXFQ0tipAd/wjj1YxWyWtUS5IDJpOG82JKt2EAVA==",+ "dev": true,+ "license": "Apache-2.0",+ "peer": true,+ "dependencies": {+ "minimatch": "^5.1.0"+ }+ },+ "node_modules/readdir-glob/node_modules/minimatch": {+ "version": "5.1.6",+ "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.6.tgz",+ "integrity": "sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==",+ "dev": true,+ "license": "ISC",+ "peer": true,+ "dependencies": {+ "brace-expansion": "^2.0.1"+ },+ "engines": {+ "node": ">=10"+ }+ },"node_modules/readdirp": {"version": "4.0.2","resolved": "https://registry.npmjs.org/readdirp/-/readdirp-4.0.2.tgz",@@ -5489,14 +6020,12 @@"version": "1.2.1","resolved": "https://registry.npmjs.org/resolve-alpn/-/resolve-alpn-1.2.1.tgz","integrity": "sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g==",- "dev": true,"license": "MIT"},"node_modules/responselike": {"version": "2.0.1","resolved": "https://registry.npmjs.org/responselike/-/responselike-2.0.1.tgz","integrity": "sha512-4gl03wn3hj1HP3yzgdI7d3lCkF95F21Pz4BPGvKHinyQzALR5CapwC8yIi0Rh58DEMQ/SguC03wFj2k0M/mHhw==",- "dev": true,"license": "MIT","dependencies": {"lowercase-keys": "^2.0.0"@@ -5550,7 +6079,6 @@"version": "2.15.4","resolved": "https://registry.npmjs.org/roarr/-/roarr-2.15.4.tgz","integrity": "sha512-CHhPh+UNHD2GTXNYhPWLnU8ONHdI+5DI+4EYIAOaiD63rHeYlZvyh8P+in5999TTSFgUYuKUAjzRI4mdh/p+2A==",- "dev": true,"license": "BSD-3-Clause","optional": true,"dependencies": {@@ -5637,7 +6165,7 @@"version": "2.1.2","resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz","integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==",- "dev": true,+ "devOptional": true,"license": "MIT"},"node_modules/sanitize-filename": {@@ -5660,7 +6188,6 @@"version": "6.3.1","resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz","integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==",- "dev": true,"license": "ISC","bin": {"semver": "bin/semver.js"@@ -5670,7 +6197,6 @@"version": "1.0.0","resolved": "https://registry.npmjs.org/semver-compare/-/semver-compare-1.0.0.tgz","integrity": "sha512-YM3/ITh2MJ5MtzaM429anh+x2jiLVjqILF4m4oyQB18W7Ggea7BfqdH/wGMK7dDiMghv/6WG7znWMwUDzJiXow==",- "dev": true,"license": "MIT","optional": true},@@ -5678,7 +6204,6 @@"version": "7.0.1","resolved": "https://registry.npmjs.org/serialize-error/-/serialize-error-7.0.1.tgz","integrity": "sha512-8I8TjW5KMOKsZQTvoxjuSIa7foAwPWGOts+6o7sgjz41/qMD9VQHEDxi6PBvK2l0MXUmqZyNpUK+T2tQaaElvw==",- "dev": true,"license": "MIT","optional": true,"dependencies": {@@ -5919,7 +6444,7 @@"version": "1.1.3","resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.1.3.tgz","integrity": "sha512-Oo+0REFV59/rz3gfJNKQiBlwfHaSESl1pcGyABQsnnIfWOFt6JNj5gCog2U6MLZ//IGYD+nA8nI+mTShREReaA==",- "dev": true,+ "devOptional": true,"license": "BSD-3-Clause"},"node_modules/sqlite-better-trigram": {@@ -6146,7 +6671,6 @@"version": "3.0.1","resolved": "https://registry.npmjs.org/sumchecker/-/sumchecker-3.0.1.tgz","integrity": "sha512-MvjXzkz/BOfyVDkG0oFOtBxHX2u3gKbMHIF/dXblZsgD3BWOFLmHovIpZY7BykJdAjcqRCBi1WYBNdEC9yI7vg==",- "dev": true,"license": "Apache-2.0","dependencies": {"debug": "^4.1.0"@@ -6292,6 +6816,13 @@"dev": true,"license": "MIT"},+ "node_modules/tinycolor2": {+ "version": "1.6.0",+ "resolved": "https://registry.npmjs.org/tinycolor2/-/tinycolor2-1.6.0.tgz",+ "integrity": "sha512-XPaBkWQJdsf3pLKJV9p4qN/S+fm2Oj8AIPo1BTUhg5oxkvm9+SVEGFdhyOz7tTdUTfvxMiAs4sp6/eZO2Ew+pw==",+ "license": "MIT",+ "peer": true+ },"node_modules/tinyexec": {"version": "0.3.1","resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-0.3.1.tgz",@@ -6373,6 +6904,13 @@"url": "https://github.com/sponsors/Borewit"}},+ "node_modules/tr46": {+ "version": "0.0.3",+ "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz",+ "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==",+ "license": "MIT",+ "peer": true+ },"node_modules/tree-kill": {"version": "1.2.2","resolved": "https://registry.npmjs.org/tree-kill/-/tree-kill-1.2.2.tgz",@@ -6416,7 +6954,6 @@"version": "0.13.1","resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.13.1.tgz","integrity": "sha512-34R7HTnG0XIJcBSn5XhDd7nNFPRcXYRZrBB2O2jdKqYODldSzBAqzsWoZYYvduky73toYS/ESqxPvkDf/F0XMg==",- "dev": true,"license": "(MIT OR CC0-1.0)","optional": true,"engines": {@@ -6475,7 +7012,6 @@"version": "6.19.8","resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz","integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==",- "devOptional": true,"license": "MIT"},"node_modules/unique-filename": {@@ -6508,7 +7044,6 @@"version": "0.1.2","resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz","integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==",- "dev": true,"license": "MIT","engines": {"node": ">= 4.0.0"@@ -6658,6 +7193,7 @@"resolved": "https://registry.npmjs.org/vitest/-/vitest-2.1.8.tgz","integrity": "sha512-1vBKTZskHw/aosXqQUlVWWlGUxSJR8YtiyZDJAFeW2kPAeX6S3Sool0mjspO+kXLuxVWlEDDowBAeqeAQefqLQ==","dev": true,+ "license": "MIT","dependencies": {"@vitest/expect": "2.1.8","@vitest/mocker": "2.1.8",@@ -6728,6 +7264,31 @@"defaults": "^1.0.3"}},+ "node_modules/webidl-conversions": {+ "version": "3.0.1",+ "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz",+ "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==",+ "license": "BSD-2-Clause",+ "peer": true+ },+ "node_modules/whatwg-fetch": {+ "version": "3.6.20",+ "resolved": "https://registry.npmjs.org/whatwg-fetch/-/whatwg-fetch-3.6.20.tgz",+ "integrity": "sha512-EqhiFU6daOA8kpjOWTL0olhVOF3i7OrFzSYiGsEMB8GcXS+RrzauAERX65xMeNWVqxA6HXH2m69Z9LaKKdisfg==",+ "license": "MIT",+ "peer": true+ },+ "node_modules/whatwg-url": {+ "version": "5.0.0",+ "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz",+ "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==",+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "tr46": "~0.0.3",+ "webidl-conversions": "^3.0.0"+ }+ },"node_modules/which": {"version": "2.0.2","resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz",@@ -6870,7 +7431,6 @@"version": "2.10.0","resolved": "https://registry.npmjs.org/yauzl/-/yauzl-2.10.0.tgz","integrity": "sha512-p4a9I6X6nu6IhoGmBqAcbJy1mlC4j27vEPZX9F4L4/vZT3Lyq1VkFHw/V/PUcB9Buo+DG3iHkT0x3Qya58zc3g==",- "dev": true,"license": "MIT","dependencies": {"buffer-crc32": "~0.2.3",@@ -6890,6 +7450,45 @@"url": "https://github.com/sponsors/sindresorhus"}},+ "node_modules/zip-stream": {+ "version": "4.1.1",+ "resolved": "https://registry.npmjs.org/zip-stream/-/zip-stream-4.1.1.tgz",+ "integrity": "sha512-9qv4rlDiopXg4E69k+vMHjNN63YFMe9sZMrdlvKnCjlCRWeCBswPPMPUfx+ipsAWq1LXHe70RcbaHdJJpS6hyQ==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "archiver-utils": "^3.0.4",+ "compress-commons": "^4.1.2",+ "readable-stream": "^3.6.0"+ },+ "engines": {+ "node": ">= 10"+ }+ },+ "node_modules/zip-stream/node_modules/archiver-utils": {+ "version": "3.0.4",+ "resolved": "https://registry.npmjs.org/archiver-utils/-/archiver-utils-3.0.4.tgz",+ "integrity": "sha512-KVgf4XQVrTjhyWmx6cte4RxonPLR9onExufI1jhvw/MQ4BB6IsZD5gT8Lq+u/+pRkWna/6JoHpiQioaqFP5Rzw==",+ "dev": true,+ "license": "MIT",+ "peer": true,+ "dependencies": {+ "glob": "^7.2.3",+ "graceful-fs": "^4.2.0",+ "lazystream": "^1.0.0",+ "lodash.defaults": "^4.2.0",+ "lodash.difference": "^4.5.0",+ "lodash.flatten": "^4.4.0",+ "lodash.isplainobject": "^4.0.6",+ "lodash.union": "^4.6.0",+ "normalize-path": "^3.0.0",+ "readable-stream": "^3.6.0"+ },+ "engines": {+ "node": ">= 10"+ }+ },"node_modules/zod": {"version": "3.23.8","resolved": "https://registry.npmjs.org/zod/-/zod-3.23.8.tgz",diff --git a/apps/desktop/package.json b/apps/desktop/package.jsonindex 84c094216..8bfd95acf 100644--- a/apps/desktop/package.json+++ b/apps/desktop/package.json@@ -30,7 +30,7 @@"@trpc/client": "10.45.2","@trpc/server": "10.45.2","better-sqlite3-multiple-ciphers": "11.5.0",- "electron-trpc": "0.6.1",+ "electron-trpc": "0.7.1","electron-updater": "^6.3.4","icojs": "^0.19.4","sqlite-better-trigram": "0.0.2",@@ -46,14 +46,14 @@"electron": "^31.7.4","electron-builder": "^25.1.8","esbuild": "0.21.5",- "vitest": "2.1.8","node-abi": "^3.68.0","node-gyp-build": "^4.8.2","playwright": "^1.48.2","prebuildify": "^6.0.1","slugify": "1.6.6","tree-kill": "^1.2.2",- "undici": "^6.19.8"+ "undici": "^6.19.8",+ "vitest": "^2.1.8"},"optionalDependencies": {"dmg-license": "^1.0.11"@@ -63,203 +63,14 @@"staging": "node scripts/build.mjs --run","release": "node scripts/build.mjs","build": "node ../../scripts/build.mjs",- "bundle": "esbuild electron=./src/main.ts ./src/preload.ts --external:electron --external:fsevents --external:better-sqlite3-multiple-ciphers --external:sodium-native --minify --bundle --outdir=./build --platform=node --tsconfig=tsconfig.json --define:MAC_APP_STORE=false --define:RELEASE=true",+ "bundle": "esbuild electron=./src/main.ts ./src/preload.ts --external:electron --external:fsevents --external:better-sqlite3-multiple-ciphers --external:sodium-native --bundle --outdir=./build --platform=node --tsconfig=tsconfig.json --define:MAC_APP_STORE=false --define:RELEASE=true","bundle:mas": "esbuild electron=./src/main.ts ./src/preload.ts --minify --external:electron --external:fsevents --bundle --outdir=./build --platform=node --tsconfig=tsconfig.json --define:MAC_APP_STORE=true --define:RELEASE=true","postinstall": "patch-package",- "test": "node --test --test-timeout 30000 --test-force-exit"+ "test": "node --test --test-timeout 30000 --test-force-exit --test-concurrency=8"},"author": {"name": "Streetwriters (Private) Limited","email": "[email protected]","url": "https://streetwriters.co"- },- "build": {- "appId": "org.streetwriters.notesnook",- "productName": "Notesnook",- "copyright": "Copyright © 2023 Streetwriters (Private) Limited",- "artifactName": "notesnook_${os}_${arch}.${ext}",- "generateUpdatesFilesForAllChannels": true,- "asar": false,- "files": [- "!*.chunk.js.map",- "!*.chunk.js.LICENSE.txt",- "build/",- "!build/screenshots${/*}",- "!build/banner.jpg",- "!build/*.ico",- "!build/*.png",- "!node_modules${/*}",- "node_modules/better-sqlite3-multiple-ciphers/build/Release/better_sqlite3.node",- "node_modules/better-sqlite3-multiple-ciphers/lib",- "node_modules/better-sqlite3-multiple-ciphers/package.json",- "node_modules/file-uri-to-path",- "node_modules/bindings",- "node_modules/node-gyp-build",- "node_modules/sqlite-better-trigram",- "node_modules/sodium-native/prebuilds/${platform}-${arch}",- {- "from": "node_modules/sqlite-better-trigram-linux-${arch}",- "to": "node_modules/sqlite-better-trigram-linux-${arch}"- },- {- "from": "node_modules/sqlite-better-trigram-darwin-${arch}",- "to": "node_modules/sqlite-better-trigram-darwin-${arch}"- },- {- "from": "node_modules/sqlite-better-trigram-windows-${arch}",- "to": "node_modules/sqlite-better-trigram-windows-${arch}"- },- "node_modules/sodium-native/index.js",- "node_modules/sodium-native/package.json"- ],- "afterPack": "./scripts/removeLocales.js",- "mac": {- "bundleVersion": "240",- "minimumSystemVersion": "10.12.0",- "target": [- {- "target": "dmg",- "arch": [- "arm64",- "x64"- ]- },- {- "target": "zip",- "arch": [- "arm64",- "x64"- ]- }- ],- "category": "public.app-category.productivity",- "darkModeSupport": true,- "type": "distribution",- "hardenedRuntime": true,- "entitlements": "assets/entitlements.mac.plist",- "entitlementsInherit": "assets/entitlements.mac.plist",- "gatekeeperAssess": false,- "icon": "assets/icons/app.icns",- "notarize": true- },- "dmg": {- "contents": [- {- "x": 130,- "y": 220- },- {- "x": 410,- "y": 220,- "type": "link",- "path": "/Applications"- }- ],- "icon": "assets/icons/app.icns",- "title": "Install Notesnook"- },- "mas": {- "entitlements": "assets/entitlements.mas.plist",- "entitlementsInherit": "assets/entitlements.mas.inherit.plist",- "entitlementsLoginHelper": "assets/entitlements.mas.loginhelper.plist",- "hardenedRuntime": true- },- "win": {- "target": [- {- "target": "nsis",- "arch": [- "x64",- "arm64"- ]- },- {- "target": "portable",- "arch": [- "x64",- "arm64"- ]- }- ],- "signtoolOptions": {- "signingHashAlgorithms": [- "sha256"- ],- "sign": "./scripts/sign.js"- },- "icon": "assets/icons/app.ico"- },- "portable": {- "artifactName": "notesnook_${os}_${arch}_portable.${ext}"- },- "nsis": {- "oneClick": true,- "createDesktopShortcut": "always",- "deleteAppDataOnUninstall": true- },- "linux": {- "target": [- {- "target": "AppImage",- "arch": [- "x64",- "arm64"- ]- },- {- "target": "snap",- "arch": [- "x64",- "arm64"- ]- }- ],- "category": "Office",- "icon": "assets/icons/app.icns",- "description": "Your private note taking space",- "executableName": "notesnook",- "desktop": {- "actions": [- {- "id": "new-note",- "name": "New note",- "args": "new note"- },- {- "id": "new-notebook",- "name": "New notebook",- "args": "new notebook"- },- {- "id": "new-reminder",- "name": "New reminder",- "args": "new reminder"- }- ]- }- },- "snap": {- "autoStart": false,- "confinement": "strict",- "allowNativeWayland": true- },- "extraResources": [- "app-update.yml",- "./assets/**"- ],- "extraMetadata": {- "main": "./build/electron.js"- },- "directories": {- "buildResources": "assets",- "output": "./output/"- },- "publish": [- {- "provider": "github",- "repo": "notesnook",- "owner": "streetwriters"- }- ]}}diff --git a/apps/desktop/scripts/build.mjs b/apps/desktop/scripts/build.mjsindex b081bc23e..6ebb7e0d6 100644--- a/apps/desktop/scripts/build.mjs+++ b/apps/desktop/scripts/build.mjs@@ -29,10 +29,11 @@ import { patchBetterSQLite3 } from "./patch-better-sqlite3.mjs";const args = yargs(process.argv);const __filename = fileURLToPath(import.meta.url);const __dirname = path.dirname(__filename);+const root = args.root || path.join(__dirname, "..");const webAppPath = path.resolve(path.join(__dirname, "..", "..", "web"));-await fs.rm("./build/", { force: true, recursive: true });+await fs.rm(path.join(root, "build"), { force: true, recursive: true });if (args.rebuild || !existsSync(path.join(webAppPath, "build"))) {await exec(@@ -44,15 +45,15 @@ if (args.rebuild || !existsSync(path.join(webAppPath, "build"))) {// temporary until there's support for prebuilt binaries for linux ARMif (os.platform() === "linux") await patchBetterSQLite3();-await fs.cp(path.join(webAppPath, "build"), "build", {+await fs.cp(path.join(webAppPath, "build"), path.join(root, "build"), {recursive: true,force: true});if (args.variant === "mas") {- await exec(`yarn run bundle:mas`);+ await exec(`yarn run bundle:mas --outdir=${path.join(root, "build")}`);} else {- await exec(`yarn run bundle`);+ await exec(`yarn run bundle --outdir=${path.join(root, "build")}`);}await exec(`yarn run build`);diff --git a/apps/desktop/src/api/updater.ts b/apps/desktop/src/api/updater.tsindex 1f5768e8e..a84628503 100644--- a/apps/desktop/src/api/updater.ts+++ b/apps/desktop/src/api/updater.ts@@ -23,6 +23,7 @@ import { CancellationToken, autoUpdater } from "electron-updater";import type { AppUpdaterEvents } from "electron-updater/out/AppUpdater";import { z } from "zod";import { config } from "../utils/config";+import { app } from "electron";type UpdateInfo = { version: string };type Progress = { percent: number };@@ -33,6 +34,7 @@ let downloadTimeout: NodeJS.Timeout | undefined = undefined;export const updaterRouter = t.router({autoUpdates: t.procedure.query(() => config.automaticUpdates),+ releaseTrack: t.procedure.query(() => config.releaseTrack),install: t.procedure.query(() => autoUpdater.quitAndInstall()),download: t.procedure.query(async () => {if (cancellationToken) return;@@ -67,7 +69,13 @@ export const updaterRouter = t.router({.mutation(({ input: { enabled } }) => {config.automaticUpdates = enabled;}),-+ changeReleaseTrack: t.procedure+ .input(z.object({ track: z.string() }))+ .mutation(({ input: { track } }) => {+ config.releaseTrack = track;+ app.relaunch();+ app.exit();+ }),onChecking: createSubscription("checking-for-update"),onDownloaded: createSubscription<"update-downloaded", UpdateInfo>("update-downloaded"diff --git a/apps/desktop/src/utils/autoupdater.ts b/apps/desktop/src/utils/autoupdater.tsindex d4e167994..c0e59009c 100644--- a/apps/desktop/src/utils/autoupdater.ts+++ b/apps/desktop/src/utils/autoupdater.ts@@ -20,19 +20,22 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.import { autoUpdater } from "electron-updater";import { config } from "./config";-const CHANNEL = autoUpdater.currentVersion.raw.endsWith("-beta")- ? "beta"- : "latest";async function configureAutoUpdater() {+ const releaseTrack =+ config.releaseTrack === "stable" ? "latest" : config.releaseTrack;autoUpdater.setFeedURL({provider: "generic",- url: `https://notesnook.com/api/v1/releases/${process.platform}/${CHANNEL}`,+ url: `https://notesnook.com/api/v1/releases/${process.platform}/${releaseTrack}`,useMultipleRangeRequest: false,- channel: CHANNEL+ channel: releaseTrack});autoUpdater.autoDownload = config.automaticUpdates;- autoUpdater.allowDowngrade = false;+ autoUpdater.allowDowngrade =+ // only allow downgrade if the current version is a prerelease+ // and the user has changed the release track to stable+ config.releaseTrack === "stable" &&+ autoUpdater.currentVersion.prerelease.length > 0;autoUpdater.allowPrerelease = false;autoUpdater.autoInstallOnAppQuit = true;autoUpdater.disableWebInstaller = true;diff --git a/apps/desktop/src/utils/config.ts b/apps/desktop/src/utils/config.tsindex f1b3bcdaa..2e13a8f30 100644--- a/apps/desktop/src/utils/config.ts+++ b/apps/desktop/src/utils/config.ts@@ -20,6 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.import { nativeTheme } from "electron";import { JSONStorage } from "./json-storage";import { z } from "zod";+import { autoUpdater } from "electron-updater";export const DesktopIntegration = z.object({autoStart: z.boolean().optional(),@@ -46,6 +47,9 @@ export const config = {automaticUpdates: true,proxyRules: "",customDns: true,+ releaseTrack: autoUpdater.currentVersion.raw.includes("-beta")+ ? "beta"+ : "stable",backgroundColor: nativeTheme.themeSource === "dark" ? "#0f0f0f" : "#ffffff",windowControlsIconColor:diff --git a/apps/desktop/__tests__/utils.mjs b/apps/desktop/vitest.config.tssimilarity index 58%rename from apps/desktop/__tests__/utils.mjsrename to apps/desktop/vitest.config.tsindex 82c89c49e..7f578fd7c 100644--- a/apps/desktop/__tests__/utils.mjs+++ b/apps/desktop/vitest.config.ts@@ -17,22 +17,24 @@ You should have received a copy of the GNU General Public Licensealong with this program. If not, see <http://www.gnu.org/licenses/>.*/-import { _electron as electron } from "playwright";--const executablePath = process.env.EXECUTABLE_PATH;--// process.platform === "linux"-// ? "output/linux-unpacked/Notesnook"-// : process.platform === "darwin"-// ? "output/mac/Notesnook.app/Contents/MacOS/Notesnook"-// : "output/win-unpacked/Notesnook.exe";--export async function launchApp() {- const app = await electron.launch({- executablePath- });-- const page = await app.firstWindow();-- return { app, page };-}+import { defineConfig } from "vitest/config";++export default defineConfig({+ test: {+ testTimeout: 30 * 1000,+ sequence: {+ concurrent: true,+ shuffle: true+ },+ dir: "./__tests__/",+ exclude: [+ "**/node_modules/**",+ "**/dist/**",+ "**/cypress/**",+ "**/.{idea,git,cache,output,temp}/**",+ "**/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build,eslint,prettier}.config.*",+ "**/test-results/**",+ "**/test-artifacts/**"+ ]+ }+});diff --git a/apps/web/src/common/desktop-bridge/index.desktop.ts b/apps/web/src/common/desktop-bridge/index.desktop.tsindex 1774b76c4..245a74bca 100644--- a/apps/web/src/common/desktop-bridge/index.desktop.ts+++ b/apps/web/src/common/desktop-bridge/index.desktop.ts@@ -70,6 +70,7 @@ function attachListeners() {function attachListener(event: string) {return {onData(...args: any[]) {+ console.log("Received data:", args);AppEventManager.publish(event, ...args);}};diff --git a/apps/web/src/components/dialog/index.tsx b/apps/web/src/components/dialog/index.tsxindex 7fe46edd5..e4396a038 100644--- a/apps/web/src/components/dialog/index.tsx+++ b/apps/web/src/components/dialog/index.tsx@@ -33,6 +33,7 @@ type DialogButtonProps = ButtonProps & {disabled?: boolean;text: JSX.Element | string;loading?: boolean;+ role?: string;};type DialogProps = SxProp & {@@ -190,6 +191,7 @@ function BaseDialog(props: React.PropsWithChildren<DialogProps>) {{...props.negativeButton}color="paragraph"data-test-id="dialog-no"+ role="negative-button"/>)}{props.positiveButton && (@@ -197,6 +199,7 @@ function BaseDialog(props: React.PropsWithChildren<DialogProps>) {{...props.positiveButton}color="accent"data-test-id="dialog-yes"+ role="positive-button"/>)}</Flex>@@ -209,13 +212,21 @@ function BaseDialog(props: React.PropsWithChildren<DialogProps>) {export default BaseDialog;-export function DialogButton(props: DialogButtonProps) {+export function DialogButton({+ disabled,+ onClick,+ loading,+ text,+ role,+ ...props+}: DialogButtonProps) {return (<Button{...props}variant="dialog"- disabled={props.disabled}- onClick={props.disabled ? undefined : props.onClick}+ disabled={disabled}+ onClick={disabled ? undefined : onClick}+ data-role={role}sx={{maxWidth: "100%",textOverflow: "ellipsis",@@ -223,7 +234,7 @@ export function DialogButton(props: DialogButtonProps) {whiteSpace: "nowrap"}}>- {props.loading ? <Loading size={16} color="accent" /> : props.text}+ {loading ? <Loading size={16} color="accent" /> : text}</Button>);}diff --git a/apps/web/src/dialogs/settings/other-settings.ts b/apps/web/src/dialogs/settings/other-settings.tsindex c7eef3654..611b1a1d0 100644--- a/apps/web/src/dialogs/settings/other-settings.ts+++ b/apps/web/src/dialogs/settings/other-settings.ts@@ -27,6 +27,7 @@ import { clearLogs, downloadLogs } from "../../utils/logger";import { useAutoUpdateStore } from "../../hooks/use-auto-updater";import { IssueDialog } from "../issue-dialog";import { strings } from "@notesnook/intl";+import { desktop } from "../../common/desktop-bridge";export const AboutSettings: SettingsGroup[] = [{@@ -90,7 +91,12 @@ export const AboutSettings: SettingsGroup[] = [value: "beta"}],- selectedOption: () => {+ selectedOption: async () => {+ if (IS_DESKTOP_APP)+ return (+ (await desktop?.updater.releaseTrack.query()) || "stable"+ );+return (document.cookie.split("; ")@@ -99,7 +105,11 @@ export const AboutSettings: SettingsGroup[] = [);},async onSelectionChanged(value) {- document.cookie = `release-track=${value}; Secure`;+ if (IS_DESKTOP_APP) {+ return await desktop?.updater.changeReleaseTrack.mutate({+ track: value+ });+ }const registrations =(await navigator.serviceWorker?.getRegistrations()) || [];for (const registration of registrations) {diff --git a/apps/web/src/service-worker.ts b/apps/web/src/service-worker.tsindex 187b9d100..c6cb46d3c 100644--- a/apps/web/src/service-worker.ts+++ b/apps/web/src/service-worker.ts@@ -99,7 +99,8 @@ self.addEventListener("message", (event) => {event.source.postMessage({type: data.type,version: APP_VERSION,- hash: GIT_HASH+ hash: GIT_HASH,+ isBeta: IS_BETA});}break;diff --git a/apps/web/src/utils/version.ts b/apps/web/src/utils/version.tsindex 730386d3c..0f0cb28f8 100644--- a/apps/web/src/utils/version.ts+++ b/apps/web/src/utils/version.ts@@ -20,26 +20,19 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.export type Platforms = "web" | "desktop";export type AppVersion = typeof appVersion;export const appVersion = {- formatted: format(APP_VERSION, GIT_HASH, PLATFORM, IS_BETA),- clean: formatVersion(APP_VERSION),- numerical: parseInt(APP_VERSION || "0"),+ formatted: format(APP_VERSION, GIT_HASH, PLATFORM),+ clean: APP_VERSION,+ numerical: versionAsNumber(APP_VERSION),hash: GIT_HASH,isBeta: IS_BETA};-function format(- version?: string,- hash?: string,- type?: "web" | "desktop",- beta?: boolean-) {- return `${formatVersion(version)}-${hash}-${type}${beta ? "-beta" : ""}`;+function format(version?: string, hash?: string, type?: "web" | "desktop") {+ return `${version}-${hash}-${type}`;}-function formatVersion(version?: string) {- if (!version) return "";- const [major, minor, bugfix0, bugfix1] = version.toString().split("");- return `${major}.${minor}.${bugfix0}${bugfix1 || ""}`;+function versionAsNumber(version: string) {+ return parseInt(version.replace(/\D/g, ""));}export function getServiceWorkerVersion(@@ -55,13 +48,13 @@ export function getServiceWorkerVersion(if (type !== "GET_VERSION") return;clearTimeout(timeout);- const { version, hash } = ev.data;+ const { version, hash, isBeta } = ev.data;resolve({- formatted: formatVersion(version),- numerical: parseInt(version),- clean: formatVersion(version),+ formatted: format(version, hash, PLATFORM),+ numerical: versionAsNumber(version),+ clean: version,hash,- isBeta: appVersion.isBeta+ isBeta});});serviceWorker.postMessage({ type: "GET_VERSION" });diff --git a/apps/web/vite.config.ts b/apps/web/vite.config.tsindex 56275fced..e01fa8815 100644--- a/apps/web/vite.config.ts+++ b/apps/web/vite.config.ts@@ -37,8 +37,8 @@ const gitHash = (() => {return process.env.GIT_HASH || "gitless";}})();-const appVersion = version.replaceAll(".", "").replace("-beta", "");-const isBeta = process.env.BETA === "true";+// const appVersion = version.replaceAll(".", "").replace("-beta", "");+const isBeta = version.includes("-beta");const isTesting =process.env.TEST === "true" || process.env.NODE_ENV === "development";const isDesktop = process.env.PLATFORM === "desktop";@@ -76,7 +76,7 @@ export default defineConfig({define: {APP_TITLE: `"${isThemeBuilder ? "Notesnook Theme Builder" : "Notesnook"}"`,GIT_HASH: `"${gitHash}"`,- APP_VERSION: `"${appVersion}"`,+ APP_VERSION: `"${version}"`,PUBLIC_URL: `"${process.env.PUBLIC_URL || ""}"`,IS_DESKTOP_APP: isDesktop,PLATFORM: `"${process.env.PLATFORM}"`,