From dba076e3fa769a6e055a81bff36c17897cf29909 Mon Sep 17 00:00:00 2001 From: Damir Modyarov Date: Sun, 7 Jul 2024 23:45:27 +0300 Subject: [PATCH] feat!: Rewrite everything with mtcute (#3) - reimplements bot logic using `mtcute` instead of `grammy` :3 - reimplements i18n using raw `@fluent/bundle` instead of `@grammy/i18n` - updates project structure, separates data and telegram logic - adds support for files up to 2GB instead of 50MB (as a side effect of not using bot api), fixes #2 - adds support for parallel downloads (as a side effect of using mtcute) - removes weird & ugly inline upload fix (as a side effect of not using bot api) - improves error handling --- .dockerignore | 2 +- .env.example | 3 +- .gitignore | 4 +- README.md | 2 +- drizzle.config.ts | 2 +- migrations/0000_slim_maestro.sql | 5 - migrations/0000_supreme_ben_urich.sql | 20 + migrations/0001_giant_vin_gonzales.sql | 8 - migrations/0002_dry_screwball.sql | 1 - migrations/meta/0000_snapshot.json | 80 +- migrations/meta/0001_snapshot.json | 90 - migrations/meta/0002_snapshot.json | 97 - migrations/meta/_journal.json | 18 +- package.json | 8 +- pnpm-lock.yaml | 2914 +++++++++++++---------- src/{request.ts => core/data/cobalt.ts} | 38 +- src/{ => core/data}/db/database.ts | 4 +- src/{ => core/data}/db/schema.ts | 6 +- src/core/data/request.ts | 94 + src/core/data/settings.ts | 55 + src/{ => core/data}/stats.ts | 4 +- src/core/utils/i18n.ts | 41 + src/{ => core/utils}/result.ts | 0 src/{ => core/utils}/text.ts | 13 +- src/handler.ts | 91 - src/i18n.ts | 11 - src/index.ts | 222 +- src/settings.ts | 90 - src/telegram/bot/download.ts | 141 ++ src/telegram/bot/errors.ts | 48 + src/telegram/bot/index.ts | 32 + src/telegram/bot/settings.ts | 34 + src/telegram/bot/start.ts | 8 + src/telegram/bot/stats.ts | 18 + src/{ => telegram/helpers}/env.ts | 3 +- src/telegram/helpers/handler.ts | 44 + src/telegram/helpers/i18n.ts | 14 + src/telegram/helpers/settings.ts | 28 + src/telegram/helpers/text.ts | 21 + 39 files changed, 2358 insertions(+), 1956 deletions(-) delete mode 100644 migrations/0000_slim_maestro.sql create mode 100644 migrations/0000_supreme_ben_urich.sql delete mode 100644 migrations/0001_giant_vin_gonzales.sql delete mode 100644 migrations/0002_dry_screwball.sql delete mode 100644 migrations/meta/0001_snapshot.json delete mode 100644 migrations/meta/0002_snapshot.json rename src/{request.ts => core/data/cobalt.ts} (65%) rename src/{ => core/data}/db/database.ts (72%) rename src/{ => core/data}/db/schema.ts (75%) create mode 100644 src/core/data/request.ts create mode 100644 src/core/data/settings.ts rename src/{ => core/data}/stats.ts (87%) create mode 100644 src/core/utils/i18n.ts rename src/{ => core/utils}/result.ts (100%) rename src/{ => core/utils}/text.ts (55%) delete mode 100644 src/handler.ts delete mode 100644 src/i18n.ts delete mode 100644 src/settings.ts create mode 100644 src/telegram/bot/download.ts create mode 100644 src/telegram/bot/errors.ts create mode 100644 src/telegram/bot/index.ts create mode 100644 src/telegram/bot/settings.ts create mode 100644 src/telegram/bot/start.ts create mode 100644 src/telegram/bot/stats.ts rename src/{ => telegram/helpers}/env.ts (90%) create mode 100644 src/telegram/helpers/handler.ts create mode 100644 src/telegram/helpers/i18n.ts create mode 100644 src/telegram/helpers/settings.ts create mode 100644 src/telegram/helpers/text.ts diff --git a/.dockerignore b/.dockerignore index 535b1f6..521b729 100644 --- a/.dockerignore +++ b/.dockerignore @@ -8,4 +8,4 @@ build .git .idea .vscode -sqlite.db \ No newline at end of file +data \ No newline at end of file diff --git a/.env.example b/.env.example index 72836a2..5e0d257 100644 --- a/.env.example +++ b/.env.example @@ -1,6 +1,7 @@ # Required variables +API_ID= +API_HASH= BOT_TOKEN= -INLINE_FIX_CHAT_ID= # Optional variables, defaults shown API_BASE_URL=https://co.wuk.sh/api diff --git a/.gitignore b/.gitignore index 81e313b..e03e3f8 100644 --- a/.gitignore +++ b/.gitignore @@ -32,5 +32,5 @@ yarn-error.log* .fleet .vscode -# SQLite DB -sqlite.db \ No newline at end of file +# Runtime Persistence +/data diff --git a/README.md b/README.md index 09c371b..9e41c07 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ powered by [cobalt](https://github.com/imputnet/cobalt). pnpm start ``` -> note: if you're using docker, don't forget to mount sqlite.db database file! +> note: if you're using docker, don't forget to create a volume for /app/data! ## license diff --git a/drizzle.config.ts b/drizzle.config.ts index e557e07..3c83ffc 100644 --- a/drizzle.config.ts +++ b/drizzle.config.ts @@ -2,7 +2,7 @@ import { defineConfig } from "drizzle-kit" export default defineConfig({ out: "./migrations", - schema: "./src/db/schema.ts", + schema: "./src/core/data/db/schema.ts", driver: "better-sqlite", dbCredentials: { url: "./sqlite.db", diff --git a/migrations/0000_slim_maestro.sql b/migrations/0000_slim_maestro.sql deleted file mode 100644 index 5f65723..0000000 --- a/migrations/0000_slim_maestro.sql +++ /dev/null @@ -1,5 +0,0 @@ -CREATE TABLE `requests` ( - `id` text PRIMARY KEY NOT NULL, - `author_id` integer NOT NULL, - `url` text NOT NULL -); diff --git a/migrations/0000_supreme_ben_urich.sql b/migrations/0000_supreme_ben_urich.sql new file mode 100644 index 0000000..9e6d726 --- /dev/null +++ b/migrations/0000_supreme_ben_urich.sql @@ -0,0 +1,20 @@ +CREATE TABLE `requests` ( + `id` text PRIMARY KEY NOT NULL, + `author_id` integer NOT NULL, + `url` text NOT NULL +); +--> statement-breakpoint +CREATE TABLE `settings` ( + `id` integer PRIMARY KEY NOT NULL, + `output` text, + `attribution` integer DEFAULT 0 NOT NULL, + `language` text +); +--> statement-breakpoint +CREATE TABLE `users` ( + `id` integer PRIMARY KEY NOT NULL, + `downloads` integer DEFAULT 0 +); +--> statement-breakpoint +CREATE UNIQUE INDEX `settings_id_unique` ON `settings` (`id`);--> statement-breakpoint +CREATE UNIQUE INDEX `users_id_unique` ON `users` (`id`); \ No newline at end of file diff --git a/migrations/0001_giant_vin_gonzales.sql b/migrations/0001_giant_vin_gonzales.sql deleted file mode 100644 index 0c97011..0000000 --- a/migrations/0001_giant_vin_gonzales.sql +++ /dev/null @@ -1,8 +0,0 @@ -CREATE TABLE `users` ( - `id` integer PRIMARY KEY NOT NULL, - `output` text, - `attribution` integer DEFAULT 0 NOT NULL, - `language` text -); ---> statement-breakpoint -CREATE UNIQUE INDEX `users_id_unique` ON `users` (`id`); \ No newline at end of file diff --git a/migrations/0002_dry_screwball.sql b/migrations/0002_dry_screwball.sql deleted file mode 100644 index 05eb72a..0000000 --- a/migrations/0002_dry_screwball.sql +++ /dev/null @@ -1 +0,0 @@ -ALTER TABLE users ADD `downloads` integer; \ No newline at end of file diff --git a/migrations/meta/0000_snapshot.json b/migrations/meta/0000_snapshot.json index 101a54c..11eda68 100644 --- a/migrations/meta/0000_snapshot.json +++ b/migrations/meta/0000_snapshot.json @@ -1,7 +1,7 @@ { "version": "5", "dialect": "sqlite", - "id": "b3eb1cd5-4852-47c0-9dce-5cb78200f5c8", + "id": "a3959bd4-7853-4642-b401-7ed157ba3283", "prevId": "00000000-0000-0000-0000-000000000000", "tables": { "requests": { @@ -33,6 +33,84 @@ "foreignKeys": {}, "compositePrimaryKeys": {}, "uniqueConstraints": {} + }, + "settings": { + "name": "settings", + "columns": { + "id": { + "name": "id", + "type": "integer", + "primaryKey": true, + "notNull": true, + "autoincrement": false + }, + "output": { + "name": "output", + "type": "text", + "primaryKey": false, + "notNull": false, + "autoincrement": false + }, + "attribution": { + "name": "attribution", + "type": "integer", + "primaryKey": false, + "notNull": true, + "autoincrement": false, + "default": 0 + }, + "language": { + "name": "language", + "type": "text", + "primaryKey": false, + "notNull": false, + "autoincrement": false + } + }, + "indexes": { + "settings_id_unique": { + "name": "settings_id_unique", + "columns": [ + "id" + ], + "isUnique": true + } + }, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "users": { + "name": "users", + "columns": { + "id": { + "name": "id", + "type": "integer", + "primaryKey": true, + "notNull": true, + "autoincrement": false + }, + "downloads": { + "name": "downloads", + "type": "integer", + "primaryKey": false, + "notNull": false, + "autoincrement": false, + "default": 0 + } + }, + "indexes": { + "users_id_unique": { + "name": "users_id_unique", + "columns": [ + "id" + ], + "isUnique": true + } + }, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} } }, "enums": {}, diff --git a/migrations/meta/0001_snapshot.json b/migrations/meta/0001_snapshot.json deleted file mode 100644 index e48076d..0000000 --- a/migrations/meta/0001_snapshot.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "version": "5", - "dialect": "sqlite", - "id": "e6eab90c-c703-4ac7-907f-2ad96aedb224", - "prevId": "b3eb1cd5-4852-47c0-9dce-5cb78200f5c8", - "tables": { - "requests": { - "name": "requests", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": true, - "notNull": true, - "autoincrement": false - }, - "author_id": { - "name": "author_id", - "type": "integer", - "primaryKey": false, - "notNull": true, - "autoincrement": false - }, - "url": { - "name": "url", - "type": "text", - "primaryKey": false, - "notNull": true, - "autoincrement": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "users": { - "name": "users", - "columns": { - "id": { - "name": "id", - "type": "integer", - "primaryKey": true, - "notNull": true, - "autoincrement": false - }, - "output": { - "name": "output", - "type": "text", - "primaryKey": false, - "notNull": false, - "autoincrement": false - }, - "attribution": { - "name": "attribution", - "type": "integer", - "primaryKey": false, - "notNull": true, - "autoincrement": false, - "default": 0 - }, - "language": { - "name": "language", - "type": "text", - "primaryKey": false, - "notNull": false, - "autoincrement": false - } - }, - "indexes": { - "users_id_unique": { - "name": "users_id_unique", - "columns": [ - "id" - ], - "isUnique": true - } - }, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - } - }, - "enums": {}, - "_meta": { - "schemas": {}, - "tables": {}, - "columns": {} - } -} \ No newline at end of file diff --git a/migrations/meta/0002_snapshot.json b/migrations/meta/0002_snapshot.json deleted file mode 100644 index c30e870..0000000 --- a/migrations/meta/0002_snapshot.json +++ /dev/null @@ -1,97 +0,0 @@ -{ - "version": "5", - "dialect": "sqlite", - "id": "7cf9cdab-b059-4b49-b8ff-c3b620bc0151", - "prevId": "e6eab90c-c703-4ac7-907f-2ad96aedb224", - "tables": { - "requests": { - "name": "requests", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": true, - "notNull": true, - "autoincrement": false - }, - "author_id": { - "name": "author_id", - "type": "integer", - "primaryKey": false, - "notNull": true, - "autoincrement": false - }, - "url": { - "name": "url", - "type": "text", - "primaryKey": false, - "notNull": true, - "autoincrement": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "users": { - "name": "users", - "columns": { - "id": { - "name": "id", - "type": "integer", - "primaryKey": true, - "notNull": true, - "autoincrement": false - }, - "output": { - "name": "output", - "type": "text", - "primaryKey": false, - "notNull": false, - "autoincrement": false - }, - "attribution": { - "name": "attribution", - "type": "integer", - "primaryKey": false, - "notNull": true, - "autoincrement": false, - "default": 0 - }, - "language": { - "name": "language", - "type": "text", - "primaryKey": false, - "notNull": false, - "autoincrement": false - }, - "downloads": { - "name": "downloads", - "type": "integer", - "primaryKey": false, - "notNull": false, - "autoincrement": false - } - }, - "indexes": { - "users_id_unique": { - "name": "users_id_unique", - "columns": [ - "id" - ], - "isUnique": true - } - }, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - } - }, - "enums": {}, - "_meta": { - "schemas": {}, - "tables": {}, - "columns": {} - } -} \ No newline at end of file diff --git a/migrations/meta/_journal.json b/migrations/meta/_journal.json index ad23d98..b885043 100644 --- a/migrations/meta/_journal.json +++ b/migrations/meta/_journal.json @@ -5,22 +5,8 @@ { "idx": 0, "version": "5", - "when": 1706452128457, - "tag": "0000_slim_maestro", - "breakpoints": true - }, - { - "idx": 1, - "version": "5", - "when": 1708695593228, - "tag": "0001_giant_vin_gonzales", - "breakpoints": true - }, - { - "idx": 2, - "version": "5", - "when": 1718465870677, - "tag": "0002_dry_screwball", + "when": 1720203773408, + "tag": "0000_supreme_ben_urich", "breakpoints": true } ] diff --git a/package.json b/package.json index 4fc1b50..82d43b0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "cobold", - "version": "0.1.0", + "version": "1.0.0", "private": true, "main": "build/index.js", "scripts": { @@ -27,12 +27,14 @@ "typescript": "^5.3.3" }, "dependencies": { - "@grammyjs/i18n": "^1.0.1", + "@fluent/bundle": "^0.18.0", + "@mtcute/crypto-node": "^0.15.0", + "@mtcute/dispatcher": "^0.15.2", + "@mtcute/node": "^0.15.1", "@t3-oss/env-core": "^0.7.1", "better-sqlite3": "^9.3.0", "dotenv": "^16.3.1", "drizzle-orm": "^0.29.3", - "grammy": "^1.20.1", "mime-types": "^2.1.35", "zod": "^3.22.4" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index bf2dbb5..abf4506 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,669 +1,465 @@ -lockfileVersion: '6.0' +lockfileVersion: '9.0' settings: autoInstallPeers: true excludeLinksFromLockfile: false -dependencies: - '@grammyjs/i18n': - specifier: ^1.0.1 - version: 1.0.1(grammy@1.20.1) - '@t3-oss/env-core': - specifier: ^0.7.1 - version: 0.7.1(typescript@5.3.3)(zod@3.22.4) - better-sqlite3: - specifier: ^9.3.0 - version: 9.3.0 - dotenv: - specifier: ^16.3.1 - version: 16.3.1 - drizzle-orm: - specifier: ^0.29.3 - version: 0.29.3(@types/better-sqlite3@7.6.8)(better-sqlite3@9.3.0) - grammy: - specifier: ^1.20.1 - version: 1.20.1 - mime-types: - specifier: ^2.1.35 - version: 2.1.35 - zod: - specifier: ^3.22.4 - version: 3.22.4 - -devDependencies: - '@stylistic/eslint-plugin': - specifier: ^1.5.1 - version: 1.5.1(eslint@8.56.0)(typescript@5.3.3) - '@types/better-sqlite3': - specifier: ^7.6.8 - version: 7.6.8 - '@types/mime-types': - specifier: ^2.1.4 - version: 2.1.4 - '@types/node': - specifier: ^20.10.5 - version: 20.10.5 - '@typescript-eslint/eslint-plugin': - specifier: ^6.16.0 - version: 6.16.0(@typescript-eslint/parser@6.16.0)(eslint@8.56.0)(typescript@5.3.3) - '@typescript-eslint/parser': - specifier: ^6.16.0 - version: 6.16.0(eslint@8.56.0)(typescript@5.3.3) - drizzle-kit: - specifier: ^0.20.13 - version: 0.20.13 - eslint: - specifier: ^8.56.0 - version: 8.56.0 - tsx: - specifier: ^4.7.0 - version: 4.7.0 - typescript: - specifier: ^5.3.3 - version: 5.3.3 +importers: + + .: + dependencies: + '@fluent/bundle': + specifier: ^0.18.0 + version: 0.18.0 + '@mtcute/crypto-node': + specifier: ^0.15.0 + version: 0.15.0 + '@mtcute/dispatcher': + specifier: ^0.15.2 + version: 0.15.2 + '@mtcute/node': + specifier: ^0.15.1 + version: 0.15.1 + '@t3-oss/env-core': + specifier: ^0.7.1 + version: 0.7.1(typescript@5.3.3)(zod@3.22.4) + better-sqlite3: + specifier: ^9.3.0 + version: 9.3.0 + dotenv: + specifier: ^16.3.1 + version: 16.3.1 + drizzle-orm: + specifier: ^0.29.3 + version: 0.29.3(@types/better-sqlite3@7.6.8)(better-sqlite3@9.3.0) + mime-types: + specifier: ^2.1.35 + version: 2.1.35 + zod: + specifier: ^3.22.4 + version: 3.22.4 + devDependencies: + '@stylistic/eslint-plugin': + specifier: ^1.5.1 + version: 1.5.1(eslint@8.56.0)(typescript@5.3.3) + '@types/better-sqlite3': + specifier: ^7.6.8 + version: 7.6.8 + '@types/mime-types': + specifier: ^2.1.4 + version: 2.1.4 + '@types/node': + specifier: ^20.10.5 + version: 20.10.5 + '@typescript-eslint/eslint-plugin': + specifier: ^6.16.0 + version: 6.16.0(@typescript-eslint/parser@6.16.0(eslint@8.56.0)(typescript@5.3.3))(eslint@8.56.0)(typescript@5.3.3) + '@typescript-eslint/parser': + specifier: ^6.16.0 + version: 6.16.0(eslint@8.56.0)(typescript@5.3.3) + drizzle-kit: + specifier: ^0.20.13 + version: 0.20.13 + eslint: + specifier: ^8.56.0 + version: 8.56.0 + tsx: + specifier: ^4.7.0 + version: 4.7.0 + typescript: + specifier: ^5.3.3 + version: 5.3.3 packages: - /@aashutoshrathi/word-wrap@1.2.6: + '@aashutoshrathi/word-wrap@1.2.6': resolution: {integrity: sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA==} engines: {node: '>=0.10.0'} - dev: true - - /@deno/shim-deno-test@0.3.3: - resolution: {integrity: sha512-Ge0Tnl7zZY0VvEfgsyLhjid8DzI1d0La0dgm+3m0/A8gZXgp5xwlyIyue5e4SCUuVB/3AH/0lun9LcJhhTwmbg==} - dev: false - /@deno/shim-deno@0.9.0: - resolution: {integrity: sha512-iP+qdI4Oy/Mw9yv40TqdjNKL+stpKDo8drki2cKisTXgZf+GoIdMhIuODxSypRyv6wxIuHNx7ZiKE3Sl3kAHuw==} - dependencies: - '@deno/shim-deno-test': 0.3.3 - which: 2.0.2 - dev: false - - /@drizzle-team/studio@0.0.39: + '@drizzle-team/studio@0.0.39': resolution: {integrity: sha512-c5Hkm7MmQC2n5qAsKShjQrHoqlfGslB8+qWzsGGZ+2dHMRTNG60UuzalF0h0rvBax5uzPXuGkYLGaQ+TUX3yMw==} - dependencies: - superjson: 2.2.1 - dev: true - /@esbuild-kit/core-utils@3.3.2: + '@esbuild-kit/core-utils@3.3.2': resolution: {integrity: sha512-sPRAnw9CdSsRmEtnsl2WXWdyquogVpB3yZ3dgwJfe8zrOzTsV7cJvmwrKVa+0ma5BoiGJ+BoqkMvawbayKUsqQ==} - dependencies: - esbuild: 0.18.20 - source-map-support: 0.5.21 - dev: true - /@esbuild-kit/esm-loader@2.6.5: + '@esbuild-kit/esm-loader@2.6.5': resolution: {integrity: sha512-FxEMIkJKnodyA1OaCUoEvbYRkoZlLZ4d/eXFu9Fh8CbBBgP5EmZxrfTRyN0qpXZ4vOvqnE5YdRdcrmUUXuU+dA==} - dependencies: - '@esbuild-kit/core-utils': 3.3.2 - get-tsconfig: 4.7.2 - dev: true - /@esbuild/aix-ppc64@0.19.10: + '@esbuild/aix-ppc64@0.19.10': resolution: {integrity: sha512-Q+mk96KJ+FZ30h9fsJl+67IjNJm3x2eX+GBWGmocAKgzp27cowCOOqSdscX80s0SpdFXZnIv/+1xD1EctFx96Q==} engines: {node: '>=12'} cpu: [ppc64] os: [aix] - requiresBuild: true - dev: true - optional: true - /@esbuild/android-arm64@0.18.20: + '@esbuild/android-arm64@0.18.20': resolution: {integrity: sha512-Nz4rJcchGDtENV0eMKUNa6L12zz2zBDXuhj/Vjh18zGqB44Bi7MBMSXjgunJgjRhCmKOjnPuZp4Mb6OKqtMHLQ==} engines: {node: '>=12'} cpu: [arm64] os: [android] - requiresBuild: true - dev: true - optional: true - /@esbuild/android-arm64@0.19.10: + '@esbuild/android-arm64@0.19.10': resolution: {integrity: sha512-1X4CClKhDgC3by7k8aOWZeBXQX8dHT5QAMCAQDArCLaYfkppoARvh0fit3X2Qs+MXDngKcHv6XXyQCpY0hkK1Q==} engines: {node: '>=12'} cpu: [arm64] os: [android] - requiresBuild: true - dev: true - optional: true - /@esbuild/android-arm@0.18.20: + '@esbuild/android-arm@0.18.20': resolution: {integrity: sha512-fyi7TDI/ijKKNZTUJAQqiG5T7YjJXgnzkURqmGj13C6dCqckZBLdl4h7bkhHt/t0WP+zO9/zwroDvANaOqO5Sw==} engines: {node: '>=12'} cpu: [arm] os: [android] - requiresBuild: true - dev: true - optional: true - /@esbuild/android-arm@0.19.10: + '@esbuild/android-arm@0.19.10': resolution: {integrity: sha512-7W0bK7qfkw1fc2viBfrtAEkDKHatYfHzr/jKAHNr9BvkYDXPcC6bodtm8AyLJNNuqClLNaeTLuwURt4PRT9d7w==} engines: {node: '>=12'} cpu: [arm] os: [android] - requiresBuild: true - dev: true - optional: true - /@esbuild/android-x64@0.18.20: + '@esbuild/android-x64@0.18.20': resolution: {integrity: sha512-8GDdlePJA8D6zlZYJV/jnrRAi6rOiNaCC/JclcXpB+KIuvfBN4owLtgzY2bsxnx666XjJx2kDPUmnTtR8qKQUg==} engines: {node: '>=12'} cpu: [x64] os: [android] - requiresBuild: true - dev: true - optional: true - /@esbuild/android-x64@0.19.10: + '@esbuild/android-x64@0.19.10': resolution: {integrity: sha512-O/nO/g+/7NlitUxETkUv/IvADKuZXyH4BHf/g/7laqKC4i/7whLpB0gvpPc2zpF0q9Q6FXS3TS75QHac9MvVWw==} engines: {node: '>=12'} cpu: [x64] os: [android] - requiresBuild: true - dev: true - optional: true - /@esbuild/darwin-arm64@0.18.20: + '@esbuild/darwin-arm64@0.18.20': resolution: {integrity: sha512-bxRHW5kHU38zS2lPTPOyuyTm+S+eobPUnTNkdJEfAddYgEcll4xkT8DB9d2008DtTbl7uJag2HuE5NZAZgnNEA==} engines: {node: '>=12'} cpu: [arm64] os: [darwin] - requiresBuild: true - dev: true - optional: true - /@esbuild/darwin-arm64@0.19.10: + '@esbuild/darwin-arm64@0.19.10': resolution: {integrity: sha512-YSRRs2zOpwypck+6GL3wGXx2gNP7DXzetmo5pHXLrY/VIMsS59yKfjPizQ4lLt5vEI80M41gjm2BxrGZ5U+VMA==} engines: {node: '>=12'} cpu: [arm64] os: [darwin] - requiresBuild: true - dev: true - optional: true - /@esbuild/darwin-x64@0.18.20: + '@esbuild/darwin-x64@0.18.20': resolution: {integrity: sha512-pc5gxlMDxzm513qPGbCbDukOdsGtKhfxD1zJKXjCCcU7ju50O7MeAZ8c4krSJcOIJGFR+qx21yMMVYwiQvyTyQ==} engines: {node: '>=12'} cpu: [x64] os: [darwin] - requiresBuild: true - dev: true - optional: true - /@esbuild/darwin-x64@0.19.10: + '@esbuild/darwin-x64@0.19.10': resolution: {integrity: sha512-alfGtT+IEICKtNE54hbvPg13xGBe4GkVxyGWtzr+yHO7HIiRJppPDhOKq3zstTcVf8msXb/t4eavW3jCDpMSmA==} engines: {node: '>=12'} cpu: [x64] os: [darwin] - requiresBuild: true - dev: true - optional: true - /@esbuild/freebsd-arm64@0.18.20: + '@esbuild/freebsd-arm64@0.18.20': resolution: {integrity: sha512-yqDQHy4QHevpMAaxhhIwYPMv1NECwOvIpGCZkECn8w2WFHXjEwrBn3CeNIYsibZ/iZEUemj++M26W3cNR5h+Tw==} engines: {node: '>=12'} cpu: [arm64] os: [freebsd] - requiresBuild: true - dev: true - optional: true - /@esbuild/freebsd-arm64@0.19.10: + '@esbuild/freebsd-arm64@0.19.10': resolution: {integrity: sha512-dMtk1wc7FSH8CCkE854GyGuNKCewlh+7heYP/sclpOG6Cectzk14qdUIY5CrKDbkA/OczXq9WesqnPl09mj5dg==} engines: {node: '>=12'} cpu: [arm64] os: [freebsd] - requiresBuild: true - dev: true - optional: true - /@esbuild/freebsd-x64@0.18.20: + '@esbuild/freebsd-x64@0.18.20': resolution: {integrity: sha512-tgWRPPuQsd3RmBZwarGVHZQvtzfEBOreNuxEMKFcd5DaDn2PbBxfwLcj4+aenoh7ctXcbXmOQIn8HI6mCSw5MQ==} engines: {node: '>=12'} cpu: [x64] os: [freebsd] - requiresBuild: true - dev: true - optional: true - /@esbuild/freebsd-x64@0.19.10: + '@esbuild/freebsd-x64@0.19.10': resolution: {integrity: sha512-G5UPPspryHu1T3uX8WiOEUa6q6OlQh6gNl4CO4Iw5PS+Kg5bVggVFehzXBJY6X6RSOMS8iXDv2330VzaObm4Ag==} engines: {node: '>=12'} cpu: [x64] os: [freebsd] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-arm64@0.18.20: + '@esbuild/linux-arm64@0.18.20': resolution: {integrity: sha512-2YbscF+UL7SQAVIpnWvYwM+3LskyDmPhe31pE7/aoTMFKKzIc9lLbyGUpmmb8a8AixOL61sQ/mFh3jEjHYFvdA==} engines: {node: '>=12'} cpu: [arm64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-arm64@0.19.10: + '@esbuild/linux-arm64@0.19.10': resolution: {integrity: sha512-QxaouHWZ+2KWEj7cGJmvTIHVALfhpGxo3WLmlYfJ+dA5fJB6lDEIg+oe/0//FuyVHuS3l79/wyBxbHr0NgtxJQ==} engines: {node: '>=12'} cpu: [arm64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-arm@0.18.20: + '@esbuild/linux-arm@0.18.20': resolution: {integrity: sha512-/5bHkMWnq1EgKr1V+Ybz3s1hWXok7mDFUMQ4cG10AfW3wL02PSZi5kFpYKrptDsgb2WAJIvRcDm+qIvXf/apvg==} engines: {node: '>=12'} cpu: [arm] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-arm@0.19.10: + '@esbuild/linux-arm@0.19.10': resolution: {integrity: sha512-j6gUW5aAaPgD416Hk9FHxn27On28H4eVI9rJ4az7oCGTFW48+LcgNDBN+9f8rKZz7EEowo889CPKyeaD0iw9Kg==} engines: {node: '>=12'} cpu: [arm] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-ia32@0.18.20: + '@esbuild/linux-ia32@0.18.20': resolution: {integrity: sha512-P4etWwq6IsReT0E1KHU40bOnzMHoH73aXp96Fs8TIT6z9Hu8G6+0SHSw9i2isWrD2nbx2qo5yUqACgdfVGx7TA==} engines: {node: '>=12'} cpu: [ia32] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-ia32@0.19.10: + '@esbuild/linux-ia32@0.19.10': resolution: {integrity: sha512-4ub1YwXxYjj9h1UIZs2hYbnTZBtenPw5NfXCRgEkGb0b6OJ2gpkMvDqRDYIDRjRdWSe/TBiZltm3Y3Q8SN1xNg==} engines: {node: '>=12'} cpu: [ia32] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-loong64@0.18.20: + '@esbuild/linux-loong64@0.18.20': resolution: {integrity: sha512-nXW8nqBTrOpDLPgPY9uV+/1DjxoQ7DoB2N8eocyq8I9XuqJ7BiAMDMf9n1xZM9TgW0J8zrquIb/A7s3BJv7rjg==} engines: {node: '>=12'} cpu: [loong64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-loong64@0.19.10: + '@esbuild/linux-loong64@0.19.10': resolution: {integrity: sha512-lo3I9k+mbEKoxtoIbM0yC/MZ1i2wM0cIeOejlVdZ3D86LAcFXFRdeuZmh91QJvUTW51bOK5W2BznGNIl4+mDaA==} engines: {node: '>=12'} cpu: [loong64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-mips64el@0.18.20: + '@esbuild/linux-mips64el@0.18.20': resolution: {integrity: sha512-d5NeaXZcHp8PzYy5VnXV3VSd2D328Zb+9dEq5HE6bw6+N86JVPExrA6O68OPwobntbNJ0pzCpUFZTo3w0GyetQ==} engines: {node: '>=12'} cpu: [mips64el] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-mips64el@0.19.10: + '@esbuild/linux-mips64el@0.19.10': resolution: {integrity: sha512-J4gH3zhHNbdZN0Bcr1QUGVNkHTdpijgx5VMxeetSk6ntdt+vR1DqGmHxQYHRmNb77tP6GVvD+K0NyO4xjd7y4A==} engines: {node: '>=12'} cpu: [mips64el] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-ppc64@0.18.20: + '@esbuild/linux-ppc64@0.18.20': resolution: {integrity: sha512-WHPyeScRNcmANnLQkq6AfyXRFr5D6N2sKgkFo2FqguP44Nw2eyDlbTdZwd9GYk98DZG9QItIiTlFLHJHjxP3FA==} engines: {node: '>=12'} cpu: [ppc64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-ppc64@0.19.10: + '@esbuild/linux-ppc64@0.19.10': resolution: {integrity: sha512-tgT/7u+QhV6ge8wFMzaklOY7KqiyitgT1AUHMApau32ZlvTB/+efeCtMk4eXS+uEymYK249JsoiklZN64xt6oQ==} engines: {node: '>=12'} cpu: [ppc64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-riscv64@0.18.20: + '@esbuild/linux-riscv64@0.18.20': resolution: {integrity: sha512-WSxo6h5ecI5XH34KC7w5veNnKkju3zBRLEQNY7mv5mtBmrP/MjNBCAlsM2u5hDBlS3NGcTQpoBvRzqBcRtpq1A==} engines: {node: '>=12'} cpu: [riscv64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-riscv64@0.19.10: + '@esbuild/linux-riscv64@0.19.10': resolution: {integrity: sha512-0f/spw0PfBMZBNqtKe5FLzBDGo0SKZKvMl5PHYQr3+eiSscfJ96XEknCe+JoOayybWUFQbcJTrk946i3j9uYZA==} engines: {node: '>=12'} cpu: [riscv64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-s390x@0.18.20: + '@esbuild/linux-s390x@0.18.20': resolution: {integrity: sha512-+8231GMs3mAEth6Ja1iK0a1sQ3ohfcpzpRLH8uuc5/KVDFneH6jtAJLFGafpzpMRO6DzJ6AvXKze9LfFMrIHVQ==} engines: {node: '>=12'} cpu: [s390x] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-s390x@0.19.10: + '@esbuild/linux-s390x@0.19.10': resolution: {integrity: sha512-pZFe0OeskMHzHa9U38g+z8Yx5FNCLFtUnJtQMpwhS+r4S566aK2ci3t4NCP4tjt6d5j5uo4h7tExZMjeKoehAA==} engines: {node: '>=12'} cpu: [s390x] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-x64@0.18.20: + '@esbuild/linux-x64@0.18.20': resolution: {integrity: sha512-UYqiqemphJcNsFEskc73jQ7B9jgwjWrSayxawS6UVFZGWrAAtkzjxSqnoclCXxWtfwLdzU+vTpcNYhpn43uP1w==} engines: {node: '>=12'} cpu: [x64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/linux-x64@0.19.10: + '@esbuild/linux-x64@0.19.10': resolution: {integrity: sha512-SpYNEqg/6pZYoc+1zLCjVOYvxfZVZj6w0KROZ3Fje/QrM3nfvT2llI+wmKSrWuX6wmZeTapbarvuNNK/qepSgA==} engines: {node: '>=12'} cpu: [x64] os: [linux] - requiresBuild: true - dev: true - optional: true - /@esbuild/netbsd-x64@0.18.20: + '@esbuild/netbsd-x64@0.18.20': resolution: {integrity: sha512-iO1c++VP6xUBUmltHZoMtCUdPlnPGdBom6IrO4gyKPFFVBKioIImVooR5I83nTew5UOYrk3gIJhbZh8X44y06A==} engines: {node: '>=12'} cpu: [x64] os: [netbsd] - requiresBuild: true - dev: true - optional: true - /@esbuild/netbsd-x64@0.19.10: + '@esbuild/netbsd-x64@0.19.10': resolution: {integrity: sha512-ACbZ0vXy9zksNArWlk2c38NdKg25+L9pr/mVaj9SUq6lHZu/35nx2xnQVRGLrC1KKQqJKRIB0q8GspiHI3J80Q==} engines: {node: '>=12'} cpu: [x64] os: [netbsd] - requiresBuild: true - dev: true - optional: true - /@esbuild/openbsd-x64@0.18.20: + '@esbuild/openbsd-x64@0.18.20': resolution: {integrity: sha512-e5e4YSsuQfX4cxcygw/UCPIEP6wbIL+se3sxPdCiMbFLBWu0eiZOJ7WoD+ptCLrmjZBK1Wk7I6D/I3NglUGOxg==} engines: {node: '>=12'} cpu: [x64] os: [openbsd] - requiresBuild: true - dev: true - optional: true - /@esbuild/openbsd-x64@0.19.10: + '@esbuild/openbsd-x64@0.19.10': resolution: {integrity: sha512-PxcgvjdSjtgPMiPQrM3pwSaG4kGphP+bLSb+cihuP0LYdZv1epbAIecHVl5sD3npkfYBZ0ZnOjR878I7MdJDFg==} engines: {node: '>=12'} cpu: [x64] os: [openbsd] - requiresBuild: true - dev: true - optional: true - /@esbuild/sunos-x64@0.18.20: + '@esbuild/sunos-x64@0.18.20': resolution: {integrity: sha512-kDbFRFp0YpTQVVrqUd5FTYmWo45zGaXe0X8E1G/LKFC0v8x0vWrhOWSLITcCn63lmZIxfOMXtCfti/RxN/0wnQ==} engines: {node: '>=12'} cpu: [x64] os: [sunos] - requiresBuild: true - dev: true - optional: true - /@esbuild/sunos-x64@0.19.10: + '@esbuild/sunos-x64@0.19.10': resolution: {integrity: sha512-ZkIOtrRL8SEJjr+VHjmW0znkPs+oJXhlJbNwfI37rvgeMtk3sxOQevXPXjmAPZPigVTncvFqLMd+uV0IBSEzqA==} engines: {node: '>=12'} cpu: [x64] os: [sunos] - requiresBuild: true - dev: true - optional: true - /@esbuild/win32-arm64@0.18.20: + '@esbuild/win32-arm64@0.18.20': resolution: {integrity: sha512-ddYFR6ItYgoaq4v4JmQQaAI5s7npztfV4Ag6NrhiaW0RrnOXqBkgwZLofVTlq1daVTQNhtI5oieTvkRPfZrePg==} engines: {node: '>=12'} cpu: [arm64] os: [win32] - requiresBuild: true - dev: true - optional: true - /@esbuild/win32-arm64@0.19.10: + '@esbuild/win32-arm64@0.19.10': resolution: {integrity: sha512-+Sa4oTDbpBfGpl3Hn3XiUe4f8TU2JF7aX8cOfqFYMMjXp6ma6NJDztl5FDG8Ezx0OjwGikIHw+iA54YLDNNVfw==} engines: {node: '>=12'} cpu: [arm64] os: [win32] - requiresBuild: true - dev: true - optional: true - /@esbuild/win32-ia32@0.18.20: + '@esbuild/win32-ia32@0.18.20': resolution: {integrity: sha512-Wv7QBi3ID/rROT08SABTS7eV4hX26sVduqDOTe1MvGMjNd3EjOz4b7zeexIR62GTIEKrfJXKL9LFxTYgkyeu7g==} engines: {node: '>=12'} cpu: [ia32] os: [win32] - requiresBuild: true - dev: true - optional: true - /@esbuild/win32-ia32@0.19.10: + '@esbuild/win32-ia32@0.19.10': resolution: {integrity: sha512-EOGVLK1oWMBXgfttJdPHDTiivYSjX6jDNaATeNOaCOFEVcfMjtbx7WVQwPSE1eIfCp/CaSF2nSrDtzc4I9f8TQ==} engines: {node: '>=12'} cpu: [ia32] os: [win32] - requiresBuild: true - dev: true - optional: true - /@esbuild/win32-x64@0.18.20: + '@esbuild/win32-x64@0.18.20': resolution: {integrity: sha512-kTdfRcSiDfQca/y9QIkng02avJ+NCaQvrMejlsB3RRv5sE9rRoeBPISaZpKxHELzRxZyLvNts1P27W3wV+8geQ==} engines: {node: '>=12'} cpu: [x64] os: [win32] - requiresBuild: true - dev: true - optional: true - /@esbuild/win32-x64@0.19.10: + '@esbuild/win32-x64@0.19.10': resolution: {integrity: sha512-whqLG6Sc70AbU73fFYvuYzaE4MNMBIlR1Y/IrUeOXFrWHxBEjjbZaQ3IXIQS8wJdAzue2GwYZCjOrgrU1oUHoA==} engines: {node: '>=12'} cpu: [x64] os: [win32] - requiresBuild: true - dev: true - optional: true - /@eslint-community/eslint-utils@4.4.0(eslint@8.56.0): + '@eslint-community/eslint-utils@4.4.0': resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 - dependencies: - eslint: 8.56.0 - eslint-visitor-keys: 3.4.3 - dev: true - /@eslint-community/regexpp@4.10.0: + '@eslint-community/regexpp@4.10.0': resolution: {integrity: sha512-Cu96Sd2By9mCNTx2iyKOmq10v22jUVQv0lQnlGNy16oE9589yE+QADPbrMGCkA51cKZSg3Pu/aTJVTGfL/qjUA==} engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} - dev: true - /@eslint/eslintrc@2.1.4: + '@eslint/eslintrc@2.1.4': resolution: {integrity: sha512-269Z39MS6wVJtsoUl10L60WdkhJVdPG24Q4eZTH3nnF6lpvSShEK3wQjDX9JRWAUPvPh7COouPpU9IrqaZFvtQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - dependencies: - ajv: 6.12.6 - debug: 4.3.4 - espree: 9.6.1 - globals: 13.24.0 - ignore: 5.3.0 - import-fresh: 3.3.0 - js-yaml: 4.1.0 - minimatch: 3.1.2 - strip-json-comments: 3.1.1 - transitivePeerDependencies: - - supports-color - dev: true - /@eslint/js@8.56.0: + '@eslint/js@8.56.0': resolution: {integrity: sha512-gMsVel9D7f2HLkBma9VbtzZRehRogVRfbr++f06nL2vnCGCNlzOD+/MUov/F4p8myyAHspEhVobgjpX64q5m6A==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - dev: true - - /@grammyjs/i18n@1.0.1(grammy@1.20.1): - resolution: {integrity: sha512-oNUIj00QOde2XI7s03UPx2psULdr+nu63gavTFr9ZSNzwMZgCfzFHF9fvQ93KVu4AAJI9bjN1xrqANUFOdToKg==} - engines: {node: '>=12'} - peerDependencies: - grammy: ^1.10.0 - dependencies: - '@deno/shim-deno': 0.9.0 - grammy: 1.20.1 - dev: false - /@grammyjs/types@3.4.4: - resolution: {integrity: sha512-r/m54PnAb1Yh76SNlU/3uc2K9t0cYfZXiYZ6IqJfb245m7QeIH7DnjFTg/OtymybKehdkm3PFlw7QODJNyDqhQ==} - dev: false + '@fluent/bundle@0.18.0': + resolution: {integrity: sha512-8Wfwu9q8F9g2FNnv82g6Ch/E1AW1wwljsUOolH5NEtdJdv0sZTuWvfCM7c3teB9dzNaJA8rn4khpidpozHWYEA==} + engines: {node: '>=14.0.0', npm: '>=7.0.0'} - /@humanwhocodes/config-array@0.11.13: + '@humanwhocodes/config-array@0.11.13': resolution: {integrity: sha512-JSBDMiDKSzQVngfRjOdFXgFfklaXI4K9nLF49Auh21lmBWRLIK3+xTErTWD4KU54pb6coM6ESE7Awz/FNU3zgQ==} engines: {node: '>=10.10.0'} - dependencies: - '@humanwhocodes/object-schema': 2.0.1 - debug: 4.3.4 - minimatch: 3.1.2 - transitivePeerDependencies: - - supports-color - dev: true - /@humanwhocodes/module-importer@1.0.1: + '@humanwhocodes/module-importer@1.0.1': resolution: {integrity: sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==} engines: {node: '>=12.22'} - dev: true - /@humanwhocodes/object-schema@2.0.1: + '@humanwhocodes/object-schema@2.0.1': resolution: {integrity: sha512-dvuCeX5fC9dXgJn9t+X5atfmgQAzUOWqS1254Gh0m6i8wKd10ebXkfNKiRK+1GWi/yTvvLDHpoxLr0xxxeslWw==} - dev: true - /@nodelib/fs.scandir@2.1.5: + '@mtcute/core@0.15.3': + resolution: {integrity: sha512-+DGDTlcmAcXwg9kELxpQwSaBoR5pDDfYAa2qdvBq40LhglOt9awhI2CtWfIeaM4Sre4XCba/91a+0uDNG4F0UA==} + + '@mtcute/crypto-node@0.15.0': + resolution: {integrity: sha512-Bw38NNIuGLdxHBMC5w5jqVajo8M9ePOerzAwf04DZVGoFCnELd5FiqlstBuc2vV4IFpEvf5dsXsza/tZnTQPcw==} + + '@mtcute/dispatcher@0.15.2': + resolution: {integrity: sha512-W7l33NoCoxK2eDhSBWi3EylIaEP3BaJ3eFY8H+qyEhX/FnJmBTxmVKyPlIFVdb1LmKXxRPW+Keo0aOiknDFqZQ==} + + '@mtcute/file-id@0.15.0': + resolution: {integrity: sha512-5roqboDrBePPWXk8KamZNxnuwv/sJKo/BYJBWLhaki9F7bH74OCct8UrO62mv0aMeZH10hg6FcT9frKjLWclNw==} + + '@mtcute/html-parser@0.15.0': + resolution: {integrity: sha512-hmqI0xbtmbYWNEXUmfbSJVP1tzRjQ5BHufLR6LbslL3DRiRTwMGhQQkx/HT/SHzZ8/KQFK8GjcD2/07eGuauwg==} + + '@mtcute/markdown-parser@0.15.0': + resolution: {integrity: sha512-tZpqPfhgPYGvT7XumqGrzmU4IoL0RtKQPVA2lQ03xQD5Geev2iGrC31yniBa9gC4o4B98EHTLsqPaVg5BvXfZA==} + + '@mtcute/node@0.15.1': + resolution: {integrity: sha512-o3JdpE74bF3O8G/cpHuHS7RWs+gPfr2HTXtNgoIcxA9gOkmPeEnJInRFtvBQlhtOXgElU1wvzJ+4h7DzfmDWaw==} + + '@mtcute/tl-runtime@0.15.0': + resolution: {integrity: sha512-lUlSFaa6cJYl+kW/6YGgCDZDkI/NtH9phkwN7cNdmS0PmuG/sqrO7tJHDkU9ItxECOYeIZghN/sK/30L49o4ig==} + + '@mtcute/tl@183.0.0': + resolution: {integrity: sha512-j4pTEdv1Hq7N9P+q3H++xVp0Zvd41+iv1v05+lwUu5fFgA0Fs/DdrXBzyjZ3ypZCj6+ltK058ArdQsp3V2prtw==} + + '@mtcute/wasm@0.15.0': + resolution: {integrity: sha512-pxKeB0Fn/4pzKFKQEBWupxHOMhZSgJ2rR4RcEG0mrMnfr2J2jyenw9vjqt0yaXfZM8zsGx2XsmSrQGaoB50Tkg==} + + '@nodelib/fs.scandir@2.1.5': resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==} engines: {node: '>= 8'} - dependencies: - '@nodelib/fs.stat': 2.0.5 - run-parallel: 1.2.0 - dev: true - /@nodelib/fs.stat@2.0.5: + '@nodelib/fs.stat@2.0.5': resolution: {integrity: sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==} engines: {node: '>= 8'} - dev: true - /@nodelib/fs.walk@1.2.8: + '@nodelib/fs.walk@1.2.8': resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==} engines: {node: '>= 8'} - dependencies: - '@nodelib/fs.scandir': 2.1.5 - fastq: 1.16.0 - dev: true - /@stylistic/eslint-plugin-js@1.5.1(eslint@8.56.0): + '@stylistic/eslint-plugin-js@1.5.1': resolution: {integrity: sha512-iZF0rF+uOhAmOJYOJx1Yvmm3CZ1uz9n0SRd9dpBYHA3QAvfABUORh9LADWwZCigjHJkp2QbCZelGFJGwGz7Siw==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: '>=8.40.0' - dependencies: - acorn: 8.11.3 - escape-string-regexp: 4.0.0 - eslint: 8.56.0 - eslint-visitor-keys: 3.4.3 - espree: 9.6.1 - dev: true - /@stylistic/eslint-plugin-jsx@1.5.1(eslint@8.56.0): + '@stylistic/eslint-plugin-jsx@1.5.1': resolution: {integrity: sha512-JuX+jsbVdpZ6EZXkbxYr9ERcGc0ndSMFgOuwEPHhOWPZ+7F8JP/nzpBjrRf7dUPMX7ezTYLZ2a3KRGRNme6rWQ==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: '>=8.40.0' - dependencies: - '@stylistic/eslint-plugin-js': 1.5.1(eslint@8.56.0) - eslint: 8.56.0 - estraverse: 5.3.0 - dev: true - /@stylistic/eslint-plugin-plus@1.5.1(eslint@8.56.0)(typescript@5.3.3): + '@stylistic/eslint-plugin-plus@1.5.1': resolution: {integrity: sha512-yxkFHsUgoqEf/j1Og0FGkpEmeQoqx0CMmtgoyZGr34hka0ElCy9fRpsFkLcwx60SfiHXspbvs2YUMXiWIffnjg==} peerDependencies: eslint: '*' - dependencies: - '@typescript-eslint/utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) - eslint: 8.56.0 - transitivePeerDependencies: - - supports-color - - typescript - dev: true - /@stylistic/eslint-plugin-ts@1.5.1(eslint@8.56.0)(typescript@5.3.3): + '@stylistic/eslint-plugin-ts@1.5.1': resolution: {integrity: sha512-oXM1V7Jp8G9+udxQTy+Igo79LR2e5HXiWqlA/3v+/PAqWxniR9nJqJSBjtQKJTPsGplDqn/ASpHUOETP4EI/4A==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: '>=8.40.0' - dependencies: - '@stylistic/eslint-plugin-js': 1.5.1(eslint@8.56.0) - '@typescript-eslint/utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) - eslint: 8.56.0 - transitivePeerDependencies: - - supports-color - - typescript - dev: true - /@stylistic/eslint-plugin@1.5.1(eslint@8.56.0)(typescript@5.3.3): + '@stylistic/eslint-plugin@1.5.1': resolution: {integrity: sha512-y7ynUMh5Hq1MhYApAccl1iuQem5Sf2JSEIjV/qsBfmW1WfRDs74V+0kLkcOn1Y600W3t8orIFrrEuWmJSetAgw==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: '>=8.40.0' - dependencies: - '@stylistic/eslint-plugin-js': 1.5.1(eslint@8.56.0) - '@stylistic/eslint-plugin-jsx': 1.5.1(eslint@8.56.0) - '@stylistic/eslint-plugin-plus': 1.5.1(eslint@8.56.0)(typescript@5.3.3) - '@stylistic/eslint-plugin-ts': 1.5.1(eslint@8.56.0)(typescript@5.3.3) - eslint: 8.56.0 - transitivePeerDependencies: - - supports-color - - typescript - dev: true - /@t3-oss/env-core@0.7.1(typescript@5.3.3)(zod@3.22.4): + '@t3-oss/env-core@0.7.1': resolution: {integrity: sha512-3+SQt39OlmSaRLqYVFv8uRm1BpFepM5TIiMytRqO9cjH+wB77o6BIJdeyM5h5U4qLBMEzOJWCY4MBaU/rLwbYw==} peerDependencies: typescript: '>=4.7.2' @@ -671,34 +467,26 @@ packages: peerDependenciesMeta: typescript: optional: true - dependencies: - typescript: 5.3.3 - zod: 3.22.4 - dev: false - /@types/better-sqlite3@7.6.8: + '@types/better-sqlite3@7.6.8': resolution: {integrity: sha512-ASndM4rdGrzk7iXXqyNC4fbwt4UEjpK0i3j4q4FyeQrLAthfB6s7EF135ZJE0qQxtKIMFwmyT6x0switET7uIw==} - dependencies: - '@types/node': 20.10.5 - /@types/json-schema@7.0.15: + '@types/events@3.0.0': + resolution: {integrity: sha512-EaObqwIvayI5a8dCzhFrjKzVwKLxjoG9T6Ppd5CEo07LRKfQ8Yokw54r5+Wq7FaBQ+yXRvQAYPrHwya1/UFt9g==} + + '@types/json-schema@7.0.15': resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} - dev: true - /@types/mime-types@2.1.4: + '@types/mime-types@2.1.4': resolution: {integrity: sha512-lfU4b34HOri+kAY5UheuFMWPDOI+OPceBSHZKp69gEyTL/mmJ4cnU6Y/rlme3UL3GyOn6Y42hyIEw0/q8sWx5w==} - dev: true - /@types/node@20.10.5: + '@types/node@20.10.5': resolution: {integrity: sha512-nNPsNE65wjMxEKI93yOP+NPGGBJz/PoN3kZsVLee0XMiJolxSekEVD8wRwBUBqkwc7UWop0edW50yrCQW4CyRw==} - dependencies: - undici-types: 5.26.5 - /@types/semver@7.5.6: + '@types/semver@7.5.6': resolution: {integrity: sha512-dn1l8LaMea/IjDoHNd9J52uBbInB796CDffS6VdIxvqYCPSG0V0DzHp76GpaWnlhg88uYyPbXCDIowa86ybd5A==} - dev: true - /@typescript-eslint/eslint-plugin@6.16.0(@typescript-eslint/parser@6.16.0)(eslint@8.56.0)(typescript@5.3.3): + '@typescript-eslint/eslint-plugin@6.16.0': resolution: {integrity: sha512-O5f7Kv5o4dLWQtPX4ywPPa+v9G+1q1x8mz0Kr0pXUtKsevo+gIJHLkGc8RxaZWtP8RrhwhSNIWThnW42K9/0rQ==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -708,26 +496,8 @@ packages: peerDependenciesMeta: typescript: optional: true - dependencies: - '@eslint-community/regexpp': 4.10.0 - '@typescript-eslint/parser': 6.16.0(eslint@8.56.0)(typescript@5.3.3) - '@typescript-eslint/scope-manager': 6.16.0 - '@typescript-eslint/type-utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) - '@typescript-eslint/utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) - '@typescript-eslint/visitor-keys': 6.16.0 - debug: 4.3.4 - eslint: 8.56.0 - graphemer: 1.4.0 - ignore: 5.3.0 - natural-compare: 1.4.0 - semver: 7.5.4 - ts-api-utils: 1.0.3(typescript@5.3.3) - typescript: 5.3.3 - transitivePeerDependencies: - - supports-color - dev: true - /@typescript-eslint/parser@6.16.0(eslint@8.56.0)(typescript@5.3.3): + '@typescript-eslint/parser@6.16.0': resolution: {integrity: sha512-H2GM3eUo12HpKZU9njig3DF5zJ58ja6ahj1GoHEHOgQvYxzoFJJEvC1MQ7T2l9Ha+69ZSOn7RTxOdpC/y3ikMw==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -736,27 +506,12 @@ packages: peerDependenciesMeta: typescript: optional: true - dependencies: - '@typescript-eslint/scope-manager': 6.16.0 - '@typescript-eslint/types': 6.16.0 - '@typescript-eslint/typescript-estree': 6.16.0(typescript@5.3.3) - '@typescript-eslint/visitor-keys': 6.16.0 - debug: 4.3.4 - eslint: 8.56.0 - typescript: 5.3.3 - transitivePeerDependencies: - - supports-color - dev: true - /@typescript-eslint/scope-manager@6.16.0: + '@typescript-eslint/scope-manager@6.16.0': resolution: {integrity: sha512-0N7Y9DSPdaBQ3sqSCwlrm9zJwkpOuc6HYm7LpzLAPqBL7dmzAUimr4M29dMkOP/tEwvOCC/Cxo//yOfJD3HUiw==} engines: {node: ^16.0.0 || >=18.0.0} - dependencies: - '@typescript-eslint/types': 6.16.0 - '@typescript-eslint/visitor-keys': 6.16.0 - dev: true - /@typescript-eslint/type-utils@6.16.0(eslint@8.56.0)(typescript@5.3.3): + '@typescript-eslint/type-utils@6.16.0': resolution: {integrity: sha512-ThmrEOcARmOnoyQfYkHw/DX2SEYBalVECmoldVuH6qagKROp/jMnfXpAU/pAIWub9c4YTxga+XwgAkoA0pxfmg==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -765,23 +520,12 @@ packages: peerDependenciesMeta: typescript: optional: true - dependencies: - '@typescript-eslint/typescript-estree': 6.16.0(typescript@5.3.3) - '@typescript-eslint/utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) - debug: 4.3.4 - eslint: 8.56.0 - ts-api-utils: 1.0.3(typescript@5.3.3) - typescript: 5.3.3 - transitivePeerDependencies: - - supports-color - dev: true - /@typescript-eslint/types@6.16.0: + '@typescript-eslint/types@6.16.0': resolution: {integrity: sha512-hvDFpLEvTJoHutVl87+MG/c5C8I6LOgEx05zExTSJDEVU7hhR3jhV8M5zuggbdFCw98+HhZWPHZeKS97kS3JoQ==} engines: {node: ^16.0.0 || >=18.0.0} - dev: true - /@typescript-eslint/typescript-estree@6.16.0(typescript@5.3.3): + '@typescript-eslint/typescript-estree@6.16.0': resolution: {integrity: sha512-VTWZuixh/vr7nih6CfrdpmFNLEnoVBF1skfjdyGnNwXOH1SLeHItGdZDHhhAIzd3ACazyY2Fg76zuzOVTaknGA==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: @@ -789,245 +533,131 @@ packages: peerDependenciesMeta: typescript: optional: true - dependencies: - '@typescript-eslint/types': 6.16.0 - '@typescript-eslint/visitor-keys': 6.16.0 - debug: 4.3.4 - globby: 11.1.0 - is-glob: 4.0.3 - minimatch: 9.0.3 - semver: 7.5.4 - ts-api-utils: 1.0.3(typescript@5.3.3) - typescript: 5.3.3 - transitivePeerDependencies: - - supports-color - dev: true - /@typescript-eslint/utils@6.16.0(eslint@8.56.0)(typescript@5.3.3): + '@typescript-eslint/utils@6.16.0': resolution: {integrity: sha512-T83QPKrBm6n//q9mv7oiSvy/Xq/7Hyw9SzSEhMHJwznEmQayfBM87+oAlkNAMEO7/MjIwKyOHgBJbxB0s7gx2A==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: ^7.0.0 || ^8.0.0 - dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.56.0) - '@types/json-schema': 7.0.15 - '@types/semver': 7.5.6 - '@typescript-eslint/scope-manager': 6.16.0 - '@typescript-eslint/types': 6.16.0 - '@typescript-eslint/typescript-estree': 6.16.0(typescript@5.3.3) - eslint: 8.56.0 - semver: 7.5.4 - transitivePeerDependencies: - - supports-color - - typescript - dev: true - /@typescript-eslint/visitor-keys@6.16.0: + '@typescript-eslint/visitor-keys@6.16.0': resolution: {integrity: sha512-QSFQLruk7fhs91a/Ep/LqRdbJCZ1Rq03rqBdKT5Ky17Sz8zRLUksqIe9DW0pKtg/Z35/ztbLQ6qpOCN6rOC11A==} engines: {node: ^16.0.0 || >=18.0.0} - dependencies: - '@typescript-eslint/types': 6.16.0 - eslint-visitor-keys: 3.4.3 - dev: true - /@ungap/structured-clone@1.2.0: + '@ungap/structured-clone@1.2.0': resolution: {integrity: sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==} - dev: true - - /abort-controller@3.0.0: - resolution: {integrity: sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==} - engines: {node: '>=6.5'} - dependencies: - event-target-shim: 5.0.1 - dev: false - /acorn-jsx@5.3.2(acorn@8.11.3): + acorn-jsx@5.3.2: resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==} peerDependencies: acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 - dependencies: - acorn: 8.11.3 - dev: true - /acorn@8.11.3: + acorn@8.11.3: resolution: {integrity: sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==} engines: {node: '>=0.4.0'} hasBin: true - dev: true - /ajv@6.12.6: + ajv@6.12.6: resolution: {integrity: sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==} - dependencies: - fast-deep-equal: 3.1.3 - fast-json-stable-stringify: 2.1.0 - json-schema-traverse: 0.4.1 - uri-js: 4.4.1 - dev: true - /ansi-regex@5.0.1: + ansi-regex@5.0.1: resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} engines: {node: '>=8'} - dev: true - /ansi-styles@4.3.0: + ansi-styles@4.3.0: resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==} engines: {node: '>=8'} - dependencies: - color-convert: 2.0.1 - dev: true - /argparse@2.0.1: + argparse@2.0.1: resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==} - dev: true - /array-union@2.1.0: + array-union@2.1.0: resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} engines: {node: '>=8'} - dev: true - /balanced-match@1.0.2: + balanced-match@1.0.2: resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} - dev: true - /base64-js@1.5.1: + base64-js@1.5.1: resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} - dev: false - /better-sqlite3@9.3.0: + better-sqlite3@9.3.0: resolution: {integrity: sha512-ww73jVpQhRRdS9uMr761ixlkl4bWoXi8hMQlBGhoN6vPNlUHpIsNmw4pKN6kjknlt/wopdvXHvLk1W75BI+n0Q==} - requiresBuild: true - dependencies: - bindings: 1.5.0 - prebuild-install: 7.1.1 - dev: false - /bindings@1.5.0: + better-sqlite3@9.5.0: + resolution: {integrity: sha512-01qVcM4gPNwE+PX7ARNiHINwzVuD6nx0gdldaAAcu+MrzyIAukQ31ZDKEpzRO/CNA9sHpxoTZ8rdjoyAin4dyg==} + + bindings@1.5.0: resolution: {integrity: sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==} - dependencies: - file-uri-to-path: 1.0.0 - dev: false - /bl@4.1.0: + bl@4.1.0: resolution: {integrity: sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==} - dependencies: - buffer: 5.7.1 - inherits: 2.0.4 - readable-stream: 3.6.2 - dev: false - /brace-expansion@1.1.11: + brace-expansion@1.1.11: resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==} - dependencies: - balanced-match: 1.0.2 - concat-map: 0.0.1 - dev: true - /brace-expansion@2.0.1: + brace-expansion@2.0.1: resolution: {integrity: sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==} - dependencies: - balanced-match: 1.0.2 - dev: true - /braces@3.0.2: + braces@3.0.2: resolution: {integrity: sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==} engines: {node: '>=8'} - dependencies: - fill-range: 7.0.1 - dev: true - /buffer-from@1.1.2: + buffer-from@1.1.2: resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} - dev: true - /buffer@5.7.1: + buffer@5.7.1: resolution: {integrity: sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==} - dependencies: - base64-js: 1.5.1 - ieee754: 1.2.1 - dev: false - /callsites@3.1.0: + callsites@3.1.0: resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==} engines: {node: '>=6'} - dev: true - /camelcase@7.0.1: + camelcase@7.0.1: resolution: {integrity: sha512-xlx1yCK2Oc1APsPXDL2LdlNP6+uu8OCDdhOBSVT279M/S+y75O30C2VuD8T2ogdePBBl7PfPF4504tnLgX3zfw==} engines: {node: '>=14.16'} - dev: true - /chalk@4.1.2: + chalk@4.1.2: resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==} engines: {node: '>=10'} - dependencies: - ansi-styles: 4.3.0 - supports-color: 7.2.0 - dev: true - /chalk@5.3.0: + chalk@5.3.0: resolution: {integrity: sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==} engines: {node: ^12.17.0 || ^14.13 || >=16.0.0} - dev: true - /chownr@1.1.4: + chownr@1.1.4: resolution: {integrity: sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==} - dev: false - /cli-color@2.0.3: + cli-color@2.0.3: resolution: {integrity: sha512-OkoZnxyC4ERN3zLzZaY9Emb7f/MhBOIpePv0Ycok0fJYT+Ouo00UBEIwsVsr0yoow++n5YWlSUgST9GKhNHiRQ==} engines: {node: '>=0.10'} - dependencies: - d: 1.0.1 - es5-ext: 0.10.62 - es6-iterator: 2.0.3 - memoizee: 0.4.15 - timers-ext: 0.1.7 - dev: true - /color-convert@2.0.1: + color-convert@2.0.1: resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} engines: {node: '>=7.0.0'} - dependencies: - color-name: 1.1.4 - dev: true - /color-name@1.1.4: + color-name@1.1.4: resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} - dev: true - /commander@9.5.0: + commander@9.5.0: resolution: {integrity: sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ==} engines: {node: ^12.20.0 || >=14} - dev: true - /concat-map@0.0.1: + concat-map@0.0.1: resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} - dev: true - /copy-anything@3.0.5: + copy-anything@3.0.5: resolution: {integrity: sha512-yCEafptTtb4bk7GLEQoM8KVJpxAfdBJYaXyzQEgQQQgYrZiDp8SJmGKlYza6CYjEDNstAdNdKA3UuoULlEbS6w==} engines: {node: '>=12.13'} - dependencies: - is-what: 4.1.16 - dev: true - /cross-spawn@7.0.3: + cross-spawn@7.0.3: resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==} engines: {node: '>= 8'} - dependencies: - path-key: 3.1.1 - shebang-command: 2.0.0 - which: 2.0.2 - dev: true - /d@1.0.1: + d@1.0.1: resolution: {integrity: sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==} - dependencies: - es5-ext: 0.10.62 - type: 1.2.0 - dev: true - /debug@4.3.4: + debug@4.3.4: resolution: {integrity: sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==} engines: {node: '>=6.0'} peerDependencies: @@ -1035,85 +665,59 @@ packages: peerDependenciesMeta: supports-color: optional: true - dependencies: - ms: 2.1.2 - /decompress-response@6.0.0: + decompress-response@6.0.0: resolution: {integrity: sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==} engines: {node: '>=10'} - dependencies: - mimic-response: 3.1.0 - dev: false - /deep-extend@0.6.0: + deep-extend@0.6.0: resolution: {integrity: sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==} engines: {node: '>=4.0.0'} - dev: false - /deep-is@0.1.4: + deep-is@0.1.4: resolution: {integrity: sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==} - dev: true - /detect-libc@2.0.2: - resolution: {integrity: sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw==} + detect-libc@2.0.3: + resolution: {integrity: sha512-bwy0MGW55bG41VqxxypOsdSdGqLwXPI/focwgTYCFMbdUiBAxLg9CFzG08sz2aqzknwiX7Hkl0bQENjg8iLByw==} engines: {node: '>=8'} - dev: false - /difflib@0.2.4: + difflib@0.2.4: resolution: {integrity: sha512-9YVwmMb0wQHQNr5J9m6BSj6fk4pfGITGQOOs+D9Fl+INODWFOfvhIU1hNv6GgR1RBoC/9NJcwu77zShxV0kT7w==} - dependencies: - heap: 0.2.7 - dev: true - /dir-glob@3.0.1: + dir-glob@3.0.1: resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} engines: {node: '>=8'} - dependencies: - path-type: 4.0.0 - dev: true - /doctrine@3.0.0: + doctrine@3.0.0: resolution: {integrity: sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==} engines: {node: '>=6.0.0'} - dependencies: - esutils: 2.0.3 - dev: true - /dotenv@16.3.1: + dom-serializer@1.4.1: + resolution: {integrity: sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==} + + domelementtype@2.3.0: + resolution: {integrity: sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==} + + domhandler@4.3.1: + resolution: {integrity: sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==} + engines: {node: '>= 4'} + + domutils@2.8.0: + resolution: {integrity: sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==} + + dotenv@16.3.1: resolution: {integrity: sha512-IPzF4w4/Rd94bA9imS68tZBaYyBWSCE47V1RGuMrB94iyTOIEwRmVL2x/4An+6mETpLrKJ5hQkB8W4kFAadeIQ==} engines: {node: '>=12'} - dev: false - /dreamopt@0.8.0: + dreamopt@0.8.0: resolution: {integrity: sha512-vyJTp8+mC+G+5dfgsY+r3ckxlz+QMX40VjPQsZc5gxVAxLmi64TBoVkP54A/pRAXMXsbu2GMMBrZPxNv23waMg==} engines: {node: '>=0.4.0'} - dependencies: - wordwrap: 1.0.0 - dev: true - /drizzle-kit@0.20.13: + drizzle-kit@0.20.13: resolution: {integrity: sha512-j9oZSQXNWG+KBJm0Sg3S/zJpncHGKnpqNfFuM4NUxUMGTcihDHhP9SW6Jncqwb5vsP1Xm0a8JLm3PZUIspC/oA==} hasBin: true - dependencies: - '@drizzle-team/studio': 0.0.39 - '@esbuild-kit/esm-loader': 2.6.5 - camelcase: 7.0.1 - chalk: 5.3.0 - commander: 9.5.0 - env-paths: 3.0.0 - esbuild: 0.19.10 - esbuild-register: 3.5.0(esbuild@0.19.10) - glob: 8.1.0 - hanji: 0.0.5 - json-diff: 0.9.0 - minimatch: 7.4.6 - semver: 7.5.4 - zod: 3.22.4 - transitivePeerDependencies: - - supports-color - dev: true - /drizzle-orm@0.29.3(@types/better-sqlite3@7.6.8)(better-sqlite3@9.3.0): + drizzle-orm@0.29.3: resolution: {integrity: sha512-uSE027csliGSGYD0pqtM+SAQATMREb3eSM/U8s6r+Y0RFwTKwftnwwSkqx3oS65UBgqDOM0gMTl5UGNpt6lW0A==} peerDependencies: '@aws-sdk/client-rds-data': '>=3' @@ -1183,150 +787,1275 @@ packages: optional: true sqlite3: optional: true - dependencies: - '@types/better-sqlite3': 7.6.8 - better-sqlite3: 9.3.0 - dev: false - /end-of-stream@1.4.4: + end-of-stream@1.4.4: resolution: {integrity: sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==} - dependencies: - once: 1.4.0 - dev: false - /env-paths@3.0.0: + entities@2.2.0: + resolution: {integrity: sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==} + + env-paths@3.0.0: resolution: {integrity: sha512-dtJUTepzMW3Lm/NPxRf3wP4642UWhjL2sQxc+ym2YMj1m/H2zDNQOlezafzkHwn6sMstjHTwG6iQQsctDW/b1A==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dev: true - /es5-ext@0.10.62: + es5-ext@0.10.62: resolution: {integrity: sha512-BHLqn0klhEpnOKSrzn/Xsz2UIW8j+cGmo9JLzr8BiUapV8hPL9+FliFqjwr9ngW7jWdnxv6eO+/LqyhJVqgrjA==} engines: {node: '>=0.10'} - requiresBuild: true - dependencies: - es6-iterator: 2.0.3 - es6-symbol: 3.1.3 - next-tick: 1.1.0 - dev: true - /es6-iterator@2.0.3: + es6-iterator@2.0.3: resolution: {integrity: sha512-zw4SRzoUkd+cl+ZoE15A9o1oQd920Bb0iOJMQkQhl3jNc03YqVjAhG7scf9C5KWRU/R13Orf588uCC6525o02g==} - dependencies: - d: 1.0.1 - es5-ext: 0.10.62 - es6-symbol: 3.1.3 - dev: true - /es6-symbol@3.1.3: + es6-symbol@3.1.3: resolution: {integrity: sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA==} - dependencies: - d: 1.0.1 - ext: 1.7.0 - dev: true - /es6-weak-map@2.0.3: + es6-weak-map@2.0.3: resolution: {integrity: sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA==} - dependencies: - d: 1.0.1 - es5-ext: 0.10.62 - es6-iterator: 2.0.3 - es6-symbol: 3.1.3 - dev: true - /esbuild-register@3.5.0(esbuild@0.19.10): + esbuild-register@3.5.0: resolution: {integrity: sha512-+4G/XmakeBAsvJuDugJvtyF1x+XJT4FMocynNpxrvEBViirpfUn2PgNpCHedfWhF4WokNsO/OvMKrmJOIJsI5A==} peerDependencies: esbuild: '>=0.12 <1' - dependencies: - debug: 4.3.4 - esbuild: 0.19.10 - transitivePeerDependencies: - - supports-color - dev: true - /esbuild@0.18.20: + esbuild@0.18.20: resolution: {integrity: sha512-ceqxoedUrcayh7Y7ZX6NdbbDzGROiyVBgC4PriJThBKSVPWnnFHZAkfI1lJT8QFkOwH4qOS2SJkS4wvpGl8BpA==} engines: {node: '>=12'} hasBin: true - requiresBuild: true - optionalDependencies: - '@esbuild/android-arm': 0.18.20 - '@esbuild/android-arm64': 0.18.20 - '@esbuild/android-x64': 0.18.20 - '@esbuild/darwin-arm64': 0.18.20 - '@esbuild/darwin-x64': 0.18.20 - '@esbuild/freebsd-arm64': 0.18.20 - '@esbuild/freebsd-x64': 0.18.20 - '@esbuild/linux-arm': 0.18.20 - '@esbuild/linux-arm64': 0.18.20 - '@esbuild/linux-ia32': 0.18.20 - '@esbuild/linux-loong64': 0.18.20 - '@esbuild/linux-mips64el': 0.18.20 - '@esbuild/linux-ppc64': 0.18.20 - '@esbuild/linux-riscv64': 0.18.20 - '@esbuild/linux-s390x': 0.18.20 - '@esbuild/linux-x64': 0.18.20 - '@esbuild/netbsd-x64': 0.18.20 - '@esbuild/openbsd-x64': 0.18.20 - '@esbuild/sunos-x64': 0.18.20 - '@esbuild/win32-arm64': 0.18.20 - '@esbuild/win32-ia32': 0.18.20 - '@esbuild/win32-x64': 0.18.20 - dev: true - /esbuild@0.19.10: + esbuild@0.19.10: resolution: {integrity: sha512-S1Y27QGt/snkNYrRcswgRFqZjaTG5a5xM3EQo97uNBnH505pdzSNe/HLBq1v0RO7iK/ngdbhJB6mDAp0OK+iUA==} engines: {node: '>=12'} hasBin: true - requiresBuild: true - optionalDependencies: - '@esbuild/aix-ppc64': 0.19.10 - '@esbuild/android-arm': 0.19.10 - '@esbuild/android-arm64': 0.19.10 - '@esbuild/android-x64': 0.19.10 - '@esbuild/darwin-arm64': 0.19.10 - '@esbuild/darwin-x64': 0.19.10 - '@esbuild/freebsd-arm64': 0.19.10 - '@esbuild/freebsd-x64': 0.19.10 - '@esbuild/linux-arm': 0.19.10 - '@esbuild/linux-arm64': 0.19.10 - '@esbuild/linux-ia32': 0.19.10 - '@esbuild/linux-loong64': 0.19.10 - '@esbuild/linux-mips64el': 0.19.10 - '@esbuild/linux-ppc64': 0.19.10 - '@esbuild/linux-riscv64': 0.19.10 - '@esbuild/linux-s390x': 0.19.10 - '@esbuild/linux-x64': 0.19.10 - '@esbuild/netbsd-x64': 0.19.10 - '@esbuild/openbsd-x64': 0.19.10 - '@esbuild/sunos-x64': 0.19.10 - '@esbuild/win32-arm64': 0.19.10 - '@esbuild/win32-ia32': 0.19.10 - '@esbuild/win32-x64': 0.19.10 - dev: true - /escape-string-regexp@4.0.0: + escape-string-regexp@4.0.0: resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==} engines: {node: '>=10'} - dev: true - /eslint-scope@7.2.2: + eslint-scope@7.2.2: resolution: {integrity: sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + + eslint-visitor-keys@3.4.3: + resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + + eslint@8.56.0: + resolution: {integrity: sha512-Go19xM6T9puCOWntie1/P997aXxFsOi37JIHRWI514Hc6ZnaHGKY9xFhrU65RT6CcBEzZoGG1e6Nq+DT04ZtZQ==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + hasBin: true + + espree@9.6.1: + resolution: {integrity: sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + + esquery@1.5.0: + resolution: {integrity: sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==} + engines: {node: '>=0.10'} + + esrecurse@4.3.0: + resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} + engines: {node: '>=4.0'} + + estraverse@5.3.0: + resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} + engines: {node: '>=4.0'} + + esutils@2.0.3: + resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==} + engines: {node: '>=0.10.0'} + + event-emitter@0.3.5: + resolution: {integrity: sha512-D9rRn9y7kLPnJ+hMq7S/nhvoKwwvVJahBi2BPmx3bvbsEdK3W9ii8cBSGjP+72/LnM4n6fo3+dkCX5FeTQruXA==} + + events@3.2.0: + resolution: {integrity: sha512-/46HWwbfCX2xTawVfkKLGxMifJYQBWMwY1mjywRtb4c9x8l5NP3KoJtnIOiL1hfdRkIuYhETxQlo62IF8tcnlg==} + engines: {node: '>=0.8.x'} + + expand-template@2.0.3: + resolution: {integrity: sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==} + engines: {node: '>=6'} + + ext@1.7.0: + resolution: {integrity: sha512-6hxeJYaL110a9b5TEJSj0gojyHQAmA2ch5Os+ySCiA1QGdS697XWY1pzsrSjqA9LDEEgdB/KypIlR59RcLuHYw==} + + fast-deep-equal@3.1.3: + resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} + + fast-glob@3.3.2: + resolution: {integrity: sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==} + engines: {node: '>=8.6.0'} + + fast-json-stable-stringify@2.1.0: + resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==} + + fast-levenshtein@2.0.6: + resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} + + fastq@1.16.0: + resolution: {integrity: sha512-ifCoaXsDrsdkWTtiNJX5uzHDsrck5TzfKKDcuFFTIrrc/BS076qgEIfoIy1VeZqViznfKiysPYTh/QeHtnIsYA==} + + file-entry-cache@6.0.1: + resolution: {integrity: sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==} + engines: {node: ^10.12.0 || >=12.0.0} + + file-uri-to-path@1.0.0: + resolution: {integrity: sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==} + + fill-range@7.0.1: + resolution: {integrity: sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==} + engines: {node: '>=8'} + + find-up@5.0.0: + resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} + engines: {node: '>=10'} + + flat-cache@3.2.0: + resolution: {integrity: sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==} + engines: {node: ^10.12.0 || >=12.0.0} + + flatted@3.2.9: + resolution: {integrity: sha512-36yxDn5H7OFZQla0/jFJmbIKTdZAQHngCedGxiMmpNfEZM0sdEeT+WczLQrjK6D7o2aiyLYDnkw0R3JK0Qv1RQ==} + + fs-constants@1.0.0: + resolution: {integrity: sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==} + + fs.realpath@1.0.0: + resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} + + fsevents@2.3.3: + resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} + engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} + os: [darwin] + + get-tsconfig@4.7.2: + resolution: {integrity: sha512-wuMsz4leaj5hbGgg4IvDU0bqJagpftG5l5cXIAvo8uZrqn0NJqwtfupTN00VnkQJPcIRrxYrm1Ue24btpCha2A==} + + github-from-package@0.0.0: + resolution: {integrity: sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==} + + glob-parent@5.1.2: + resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==} + engines: {node: '>= 6'} + + glob-parent@6.0.2: + resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==} + engines: {node: '>=10.13.0'} + + glob@7.2.3: + resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} + + glob@8.1.0: + resolution: {integrity: sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==} + engines: {node: '>=12'} + + globals@13.24.0: + resolution: {integrity: sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==} + engines: {node: '>=8'} + + globby@11.1.0: + resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} + engines: {node: '>=10'} + + graphemer@1.4.0: + resolution: {integrity: sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==} + + hanji@0.0.5: + resolution: {integrity: sha512-Abxw1Lq+TnYiL4BueXqMau222fPSPMFtya8HdpWsz/xVAhifXou71mPh/kY2+08RgFcVccjG3uZHs6K5HAe3zw==} + + has-flag@4.0.0: + resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} + engines: {node: '>=8'} + + heap@0.2.7: + resolution: {integrity: sha512-2bsegYkkHO+h/9MGbn6KWcE45cHZgPANo5LXF7EvWdT0yT2EguSVO1nDgU5c8+ZOPwp2vMNa7YFsJhVcDR9Sdg==} + + htmlparser2@6.1.0: + resolution: {integrity: sha512-gyyPk6rgonLFEDGoeRgQNaEUvdJ4ktTmmUh/h2t7s+M8oPpIPxgNACWa+6ESR57kXstwqPiCut0V8NRpcwgU7A==} + + ieee754@1.2.1: + resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} + + ignore@5.3.0: + resolution: {integrity: sha512-g7dmpshy+gD7mh88OC9NwSGTKoc3kyLAZQRU1mt53Aw/vnvfXnbC+F/7F7QoYVKbV+KNvJx8wArewKy1vXMtlg==} + engines: {node: '>= 4'} + + import-fresh@3.3.0: + resolution: {integrity: sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==} + engines: {node: '>=6'} + + imurmurhash@0.1.4: + resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==} + engines: {node: '>=0.8.19'} + + inflight@1.0.6: + resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} + + inherits@2.0.4: + resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} + + ini@1.3.8: + resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} + + is-extglob@2.1.1: + resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} + engines: {node: '>=0.10.0'} + + is-glob@4.0.3: + resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} + engines: {node: '>=0.10.0'} + + is-number@7.0.0: + resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} + engines: {node: '>=0.12.0'} + + is-path-inside@3.0.3: + resolution: {integrity: sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==} + engines: {node: '>=8'} + + is-promise@2.2.2: + resolution: {integrity: sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==} + + is-what@4.1.16: + resolution: {integrity: sha512-ZhMwEosbFJkA0YhFnNDgTM4ZxDRsS6HqTo7qsZM08fehyRYIYa0yHu5R6mgo1n/8MgaPBXiPimPD77baVFYg+A==} + engines: {node: '>=12.13'} + + isexe@2.0.0: + resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==} + + js-yaml@4.1.0: + resolution: {integrity: sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==} + hasBin: true + + json-buffer@3.0.1: + resolution: {integrity: sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==} + + json-diff@0.9.0: + resolution: {integrity: sha512-cVnggDrVkAAA3OvFfHpFEhOnmcsUpleEKq4d4O8sQWWSH40MBrWstKigVB1kGrgLWzuom+7rRdaCsnBD6VyObQ==} + hasBin: true + + json-schema-traverse@0.4.1: + resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} + + json-stable-stringify-without-jsonify@1.0.1: + resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==} + + keyv@4.5.4: + resolution: {integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==} + + levn@0.4.1: + resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==} + engines: {node: '>= 0.8.0'} + + locate-path@6.0.0: + resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==} + engines: {node: '>=10'} + + lodash.merge@4.6.2: + resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==} + + lodash.throttle@4.1.1: + resolution: {integrity: sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==} + + long@5.2.3: + resolution: {integrity: sha512-lcHwpNoggQTObv5apGNCTdJrO69eHOZMi4BNC+rTLER8iHAqGrUVeLh/irVIM7zTw2bOXA8T6uNPeujwOLg/2Q==} + + lru-cache@6.0.0: + resolution: {integrity: sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==} + engines: {node: '>=10'} + + lru-queue@0.1.0: + resolution: {integrity: sha512-BpdYkt9EvGl8OfWHDQPISVpcl5xZthb+XPsbELj5AQXxIC8IriDZIQYjBJPEm5rS420sjZ0TLEzRcq5KdBhYrQ==} + + memoizee@0.4.15: + resolution: {integrity: sha512-UBWmJpLZd5STPm7PMUlOw/TSy972M+z8gcyQ5veOnSDRREz/0bmpyTfKt3/51DhEBqCZQn1udM/5flcSPYhkdQ==} + + merge2@1.4.1: + resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} + engines: {node: '>= 8'} + + micromatch@4.0.5: + resolution: {integrity: sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==} + engines: {node: '>=8.6'} + + mime-db@1.52.0: + resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} + engines: {node: '>= 0.6'} + + mime-types@2.1.35: + resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} + engines: {node: '>= 0.6'} + + mimic-response@3.1.0: + resolution: {integrity: sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==} + engines: {node: '>=10'} + + minimatch@3.1.2: + resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} + + minimatch@5.1.6: + resolution: {integrity: sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==} + engines: {node: '>=10'} + + minimatch@7.4.6: + resolution: {integrity: sha512-sBz8G/YjVniEz6lKPNpKxXwazJe4c19fEfV2GDMX6AjFz+MX9uDWIZW8XreVhkFW3fkIdTv/gxWr/Kks5FFAVw==} + engines: {node: '>=10'} + + minimatch@9.0.3: + resolution: {integrity: sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==} + engines: {node: '>=16 || 14 >=14.17'} + + minimist@1.2.8: + resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} + + mkdirp-classic@0.5.3: + resolution: {integrity: sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==} + + ms@2.1.2: + resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} + + napi-build-utils@1.0.2: + resolution: {integrity: sha512-ONmRUqK7zj7DWX0D9ADe03wbwOBZxNAfF20PlGfCWQcD3+/MakShIHrMqx9YwPTfxDdF1zLeL+RGZiR9kGMLdg==} + + natural-compare@1.4.0: + resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} + + next-tick@1.1.0: + resolution: {integrity: sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ==} + + node-abi@3.65.0: + resolution: {integrity: sha512-ThjYBfoDNr08AWx6hGaRbfPwxKV9kVzAzOzlLKbk2CuqXE2xnCh+cbAGnwM3t8Lq4v9rUB7VfondlkBckcJrVA==} + engines: {node: '>=10'} + + node-gyp-build@4.8.1: + resolution: {integrity: sha512-OSs33Z9yWr148JZcbZd5WiAXhh/n9z8TxQcdMhIOlpN9AhWpLfvVFO73+m77bBABQMaY9XSvIa+qk0jlI7Gcaw==} + hasBin: true + + once@1.4.0: + resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} + + optionator@0.9.3: + resolution: {integrity: sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==} + engines: {node: '>= 0.8.0'} + + p-limit@3.1.0: + resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==} + engines: {node: '>=10'} + + p-locate@5.0.0: + resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==} + engines: {node: '>=10'} + + parent-module@1.0.1: + resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} + engines: {node: '>=6'} + + path-exists@4.0.0: + resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} + engines: {node: '>=8'} + + path-is-absolute@1.0.1: + resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} + engines: {node: '>=0.10.0'} + + path-key@3.1.1: + resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} + engines: {node: '>=8'} + + path-type@4.0.0: + resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} + engines: {node: '>=8'} + + picomatch@2.3.1: + resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} + engines: {node: '>=8.6'} + + prebuild-install@7.1.1: + resolution: {integrity: sha512-jAXscXWMcCK8GgCoHOfIr0ODh5ai8mj63L2nWrjuAgXE6tDyYGnx4/8o/rCgU+B4JSyZBKbeZqzhtwtC3ovxjw==} + engines: {node: '>=10'} + hasBin: true + + prebuild-install@7.1.2: + resolution: {integrity: sha512-UnNke3IQb6sgarcZIDU3gbMeTp/9SSU1DAIkil7PrqG1vZlBtY5msYccSKSHDqa3hNg436IXK+SNImReuA1wEQ==} + engines: {node: '>=10'} + hasBin: true + + prelude-ls@1.2.1: + resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} + engines: {node: '>= 0.8.0'} + + pump@3.0.0: + resolution: {integrity: sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==} + + punycode@2.3.1: + resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} + engines: {node: '>=6'} + + queue-microtask@1.2.3: + resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==} + + rc@1.2.8: + resolution: {integrity: sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==} + hasBin: true + + readable-stream@3.6.2: + resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==} + engines: {node: '>= 6'} + + resolve-from@4.0.0: + resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==} + engines: {node: '>=4'} + + resolve-pkg-maps@1.0.0: + resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==} + + reusify@1.0.4: + resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==} + engines: {iojs: '>=1.0.0', node: '>=0.10.0'} + + rimraf@3.0.2: + resolution: {integrity: sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==} + hasBin: true + + run-parallel@1.2.0: + resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==} + + safe-buffer@5.2.1: + resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} + + semver@7.5.4: + resolution: {integrity: sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==} + engines: {node: '>=10'} + hasBin: true + + semver@7.6.2: + resolution: {integrity: sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==} + engines: {node: '>=10'} + hasBin: true + + shebang-command@2.0.0: + resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} + engines: {node: '>=8'} + + shebang-regex@3.0.0: + resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==} + engines: {node: '>=8'} + + simple-concat@1.0.1: + resolution: {integrity: sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==} + + simple-get@4.0.1: + resolution: {integrity: sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==} + + sisteransi@1.0.5: + resolution: {integrity: sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==} + + slash@3.0.0: + resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} + engines: {node: '>=8'} + + source-map-support@0.5.21: + resolution: {integrity: sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==} + + source-map@0.6.1: + resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==} + engines: {node: '>=0.10.0'} + + string_decoder@1.3.0: + resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==} + + strip-ansi@6.0.1: + resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} + engines: {node: '>=8'} + + strip-json-comments@2.0.1: + resolution: {integrity: sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==} + engines: {node: '>=0.10.0'} + + strip-json-comments@3.1.1: + resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} + engines: {node: '>=8'} + + superjson@2.2.1: + resolution: {integrity: sha512-8iGv75BYOa0xRJHK5vRLEjE2H/i4lulTjzpUXic3Eg8akftYjkmQDa8JARQ42rlczXyFR3IeRoeFCc7RxHsYZA==} + engines: {node: '>=16'} + + supports-color@7.2.0: + resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} + engines: {node: '>=8'} + + tar-fs@2.1.1: + resolution: {integrity: sha512-V0r2Y9scmbDRLCNex/+hYzvp/zyYjvFbHPNgVTKfQvVrb6guiE/fxP+XblDNR011utopbkex2nM4dHNV6GDsng==} + + tar-stream@2.2.0: + resolution: {integrity: sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==} + engines: {node: '>=6'} + + text-table@0.2.0: + resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} + + timers-ext@0.1.7: + resolution: {integrity: sha512-b85NUNzTSdodShTIbky6ZF02e8STtVVfD+fu4aXXShEELpozH+bCpJLYMPZbsABN2wDH7fJpqIoXxJpzbf0NqQ==} + + to-regex-range@5.0.1: + resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} + engines: {node: '>=8.0'} + + ts-api-utils@1.0.3: + resolution: {integrity: sha512-wNMeqtMz5NtwpT/UZGY5alT+VoKdSsOOP/kqHFcUW1P/VRhH2wJ48+DN2WwUliNbQ976ETwDL0Ifd2VVvgonvg==} + engines: {node: '>=16.13.0'} + peerDependencies: + typescript: '>=4.2.0' + + tsx@4.7.0: + resolution: {integrity: sha512-I+t79RYPlEYlHn9a+KzwrvEwhJg35h/1zHsLC2JXvhC2mdynMv6Zxzvhv5EMV6VF5qJlLlkSnMVvdZV3PSIGcg==} + engines: {node: '>=18.0.0'} + hasBin: true + + tunnel-agent@0.6.0: + resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==} + + type-check@0.4.0: + resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} + engines: {node: '>= 0.8.0'} + + type-fest@0.20.2: + resolution: {integrity: sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==} + engines: {node: '>=10'} + + type@1.2.0: + resolution: {integrity: sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg==} + + type@2.7.2: + resolution: {integrity: sha512-dzlvlNlt6AXU7EBSfpAscydQ7gXB+pPGsPnfJnZpiNJBDj7IaJzQlBZYGdEi4R9HmPdBv2XmWJ6YUtoTa7lmCw==} + + typescript@5.3.3: + resolution: {integrity: sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==} + engines: {node: '>=14.17'} + hasBin: true + + undici-types@5.26.5: + resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} + + uri-js@4.4.1: + resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} + + util-deprecate@1.0.2: + resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} + + which@2.0.2: + resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==} + engines: {node: '>= 8'} + hasBin: true + + wordwrap@1.0.0: + resolution: {integrity: sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==} + + wrappy@1.0.2: + resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} + + yallist@4.0.0: + resolution: {integrity: sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==} + + yocto-queue@0.1.0: + resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} + engines: {node: '>=10'} + + zod@3.22.4: + resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} + +snapshots: + + '@aashutoshrathi/word-wrap@1.2.6': {} + + '@drizzle-team/studio@0.0.39': + dependencies: + superjson: 2.2.1 + + '@esbuild-kit/core-utils@3.3.2': + dependencies: + esbuild: 0.18.20 + source-map-support: 0.5.21 + + '@esbuild-kit/esm-loader@2.6.5': + dependencies: + '@esbuild-kit/core-utils': 3.3.2 + get-tsconfig: 4.7.2 + + '@esbuild/aix-ppc64@0.19.10': + optional: true + + '@esbuild/android-arm64@0.18.20': + optional: true + + '@esbuild/android-arm64@0.19.10': + optional: true + + '@esbuild/android-arm@0.18.20': + optional: true + + '@esbuild/android-arm@0.19.10': + optional: true + + '@esbuild/android-x64@0.18.20': + optional: true + + '@esbuild/android-x64@0.19.10': + optional: true + + '@esbuild/darwin-arm64@0.18.20': + optional: true + + '@esbuild/darwin-arm64@0.19.10': + optional: true + + '@esbuild/darwin-x64@0.18.20': + optional: true + + '@esbuild/darwin-x64@0.19.10': + optional: true + + '@esbuild/freebsd-arm64@0.18.20': + optional: true + + '@esbuild/freebsd-arm64@0.19.10': + optional: true + + '@esbuild/freebsd-x64@0.18.20': + optional: true + + '@esbuild/freebsd-x64@0.19.10': + optional: true + + '@esbuild/linux-arm64@0.18.20': + optional: true + + '@esbuild/linux-arm64@0.19.10': + optional: true + + '@esbuild/linux-arm@0.18.20': + optional: true + + '@esbuild/linux-arm@0.19.10': + optional: true + + '@esbuild/linux-ia32@0.18.20': + optional: true + + '@esbuild/linux-ia32@0.19.10': + optional: true + + '@esbuild/linux-loong64@0.18.20': + optional: true + + '@esbuild/linux-loong64@0.19.10': + optional: true + + '@esbuild/linux-mips64el@0.18.20': + optional: true + + '@esbuild/linux-mips64el@0.19.10': + optional: true + + '@esbuild/linux-ppc64@0.18.20': + optional: true + + '@esbuild/linux-ppc64@0.19.10': + optional: true + + '@esbuild/linux-riscv64@0.18.20': + optional: true + + '@esbuild/linux-riscv64@0.19.10': + optional: true + + '@esbuild/linux-s390x@0.18.20': + optional: true + + '@esbuild/linux-s390x@0.19.10': + optional: true + + '@esbuild/linux-x64@0.18.20': + optional: true + + '@esbuild/linux-x64@0.19.10': + optional: true + + '@esbuild/netbsd-x64@0.18.20': + optional: true + + '@esbuild/netbsd-x64@0.19.10': + optional: true + + '@esbuild/openbsd-x64@0.18.20': + optional: true + + '@esbuild/openbsd-x64@0.19.10': + optional: true + + '@esbuild/sunos-x64@0.18.20': + optional: true + + '@esbuild/sunos-x64@0.19.10': + optional: true + + '@esbuild/win32-arm64@0.18.20': + optional: true + + '@esbuild/win32-arm64@0.19.10': + optional: true + + '@esbuild/win32-ia32@0.18.20': + optional: true + + '@esbuild/win32-ia32@0.19.10': + optional: true + + '@esbuild/win32-x64@0.18.20': + optional: true + + '@esbuild/win32-x64@0.19.10': + optional: true + + '@eslint-community/eslint-utils@4.4.0(eslint@8.56.0)': + dependencies: + eslint: 8.56.0 + eslint-visitor-keys: 3.4.3 + + '@eslint-community/regexpp@4.10.0': {} + + '@eslint/eslintrc@2.1.4': + dependencies: + ajv: 6.12.6 + debug: 4.3.4 + espree: 9.6.1 + globals: 13.24.0 + ignore: 5.3.0 + import-fresh: 3.3.0 + js-yaml: 4.1.0 + minimatch: 3.1.2 + strip-json-comments: 3.1.1 + transitivePeerDependencies: + - supports-color + + '@eslint/js@8.56.0': {} + + '@fluent/bundle@0.18.0': {} + + '@humanwhocodes/config-array@0.11.13': + dependencies: + '@humanwhocodes/object-schema': 2.0.1 + debug: 4.3.4 + minimatch: 3.1.2 + transitivePeerDependencies: + - supports-color + + '@humanwhocodes/module-importer@1.0.1': {} + + '@humanwhocodes/object-schema@2.0.1': {} + + '@mtcute/core@0.15.3': + dependencies: + '@mtcute/file-id': 0.15.0 + '@mtcute/tl': 183.0.0 + '@mtcute/tl-runtime': 0.15.0 + '@types/events': 3.0.0 + events: 3.2.0 + long: 5.2.3 + + '@mtcute/crypto-node@0.15.0': + dependencies: + '@mtcute/node': 0.15.1 + node-gyp-build: 4.8.1 + + '@mtcute/dispatcher@0.15.2': + dependencies: + '@mtcute/core': 0.15.3 + events: 3.2.0 + + '@mtcute/file-id@0.15.0': + dependencies: + '@mtcute/tl-runtime': 0.15.0 + long: 5.2.3 + + '@mtcute/html-parser@0.15.0': + dependencies: + '@mtcute/core': 0.15.3 + htmlparser2: 6.1.0 + long: 5.2.3 + + '@mtcute/markdown-parser@0.15.0': + dependencies: + '@mtcute/core': 0.15.3 + long: 5.2.3 + + '@mtcute/node@0.15.1': + dependencies: + '@mtcute/core': 0.15.3 + '@mtcute/html-parser': 0.15.0 + '@mtcute/markdown-parser': 0.15.0 + '@mtcute/wasm': 0.15.0 + better-sqlite3: 9.5.0 + + '@mtcute/tl-runtime@0.15.0': + dependencies: + long: 5.2.3 + + '@mtcute/tl@183.0.0': + dependencies: + long: 5.2.3 + + '@mtcute/wasm@0.15.0': {} + + '@nodelib/fs.scandir@2.1.5': + dependencies: + '@nodelib/fs.stat': 2.0.5 + run-parallel: 1.2.0 + + '@nodelib/fs.stat@2.0.5': {} + + '@nodelib/fs.walk@1.2.8': + dependencies: + '@nodelib/fs.scandir': 2.1.5 + fastq: 1.16.0 + + '@stylistic/eslint-plugin-js@1.5.1(eslint@8.56.0)': + dependencies: + acorn: 8.11.3 + escape-string-regexp: 4.0.0 + eslint: 8.56.0 + eslint-visitor-keys: 3.4.3 + espree: 9.6.1 + + '@stylistic/eslint-plugin-jsx@1.5.1(eslint@8.56.0)': + dependencies: + '@stylistic/eslint-plugin-js': 1.5.1(eslint@8.56.0) + eslint: 8.56.0 + estraverse: 5.3.0 + + '@stylistic/eslint-plugin-plus@1.5.1(eslint@8.56.0)(typescript@5.3.3)': + dependencies: + '@typescript-eslint/utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) + eslint: 8.56.0 + transitivePeerDependencies: + - supports-color + - typescript + + '@stylistic/eslint-plugin-ts@1.5.1(eslint@8.56.0)(typescript@5.3.3)': + dependencies: + '@stylistic/eslint-plugin-js': 1.5.1(eslint@8.56.0) + '@typescript-eslint/utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) + eslint: 8.56.0 + transitivePeerDependencies: + - supports-color + - typescript + + '@stylistic/eslint-plugin@1.5.1(eslint@8.56.0)(typescript@5.3.3)': + dependencies: + '@stylistic/eslint-plugin-js': 1.5.1(eslint@8.56.0) + '@stylistic/eslint-plugin-jsx': 1.5.1(eslint@8.56.0) + '@stylistic/eslint-plugin-plus': 1.5.1(eslint@8.56.0)(typescript@5.3.3) + '@stylistic/eslint-plugin-ts': 1.5.1(eslint@8.56.0)(typescript@5.3.3) + eslint: 8.56.0 + transitivePeerDependencies: + - supports-color + - typescript + + '@t3-oss/env-core@0.7.1(typescript@5.3.3)(zod@3.22.4)': + dependencies: + zod: 3.22.4 + optionalDependencies: + typescript: 5.3.3 + + '@types/better-sqlite3@7.6.8': + dependencies: + '@types/node': 20.10.5 + + '@types/events@3.0.0': {} + + '@types/json-schema@7.0.15': {} + + '@types/mime-types@2.1.4': {} + + '@types/node@20.10.5': + dependencies: + undici-types: 5.26.5 + + '@types/semver@7.5.6': {} + + '@typescript-eslint/eslint-plugin@6.16.0(@typescript-eslint/parser@6.16.0(eslint@8.56.0)(typescript@5.3.3))(eslint@8.56.0)(typescript@5.3.3)': + dependencies: + '@eslint-community/regexpp': 4.10.0 + '@typescript-eslint/parser': 6.16.0(eslint@8.56.0)(typescript@5.3.3) + '@typescript-eslint/scope-manager': 6.16.0 + '@typescript-eslint/type-utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) + '@typescript-eslint/utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) + '@typescript-eslint/visitor-keys': 6.16.0 + debug: 4.3.4 + eslint: 8.56.0 + graphemer: 1.4.0 + ignore: 5.3.0 + natural-compare: 1.4.0 + semver: 7.5.4 + ts-api-utils: 1.0.3(typescript@5.3.3) + optionalDependencies: + typescript: 5.3.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/parser@6.16.0(eslint@8.56.0)(typescript@5.3.3)': + dependencies: + '@typescript-eslint/scope-manager': 6.16.0 + '@typescript-eslint/types': 6.16.0 + '@typescript-eslint/typescript-estree': 6.16.0(typescript@5.3.3) + '@typescript-eslint/visitor-keys': 6.16.0 + debug: 4.3.4 + eslint: 8.56.0 + optionalDependencies: + typescript: 5.3.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/scope-manager@6.16.0': + dependencies: + '@typescript-eslint/types': 6.16.0 + '@typescript-eslint/visitor-keys': 6.16.0 + + '@typescript-eslint/type-utils@6.16.0(eslint@8.56.0)(typescript@5.3.3)': + dependencies: + '@typescript-eslint/typescript-estree': 6.16.0(typescript@5.3.3) + '@typescript-eslint/utils': 6.16.0(eslint@8.56.0)(typescript@5.3.3) + debug: 4.3.4 + eslint: 8.56.0 + ts-api-utils: 1.0.3(typescript@5.3.3) + optionalDependencies: + typescript: 5.3.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/types@6.16.0': {} + + '@typescript-eslint/typescript-estree@6.16.0(typescript@5.3.3)': + dependencies: + '@typescript-eslint/types': 6.16.0 + '@typescript-eslint/visitor-keys': 6.16.0 + debug: 4.3.4 + globby: 11.1.0 + is-glob: 4.0.3 + minimatch: 9.0.3 + semver: 7.6.2 + ts-api-utils: 1.0.3(typescript@5.3.3) + optionalDependencies: + typescript: 5.3.3 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/utils@6.16.0(eslint@8.56.0)(typescript@5.3.3)': + dependencies: + '@eslint-community/eslint-utils': 4.4.0(eslint@8.56.0) + '@types/json-schema': 7.0.15 + '@types/semver': 7.5.6 + '@typescript-eslint/scope-manager': 6.16.0 + '@typescript-eslint/types': 6.16.0 + '@typescript-eslint/typescript-estree': 6.16.0(typescript@5.3.3) + eslint: 8.56.0 + semver: 7.6.2 + transitivePeerDependencies: + - supports-color + - typescript + + '@typescript-eslint/visitor-keys@6.16.0': + dependencies: + '@typescript-eslint/types': 6.16.0 + eslint-visitor-keys: 3.4.3 + + '@ungap/structured-clone@1.2.0': {} + + acorn-jsx@5.3.2(acorn@8.11.3): + dependencies: + acorn: 8.11.3 + + acorn@8.11.3: {} + + ajv@6.12.6: + dependencies: + fast-deep-equal: 3.1.3 + fast-json-stable-stringify: 2.1.0 + json-schema-traverse: 0.4.1 + uri-js: 4.4.1 + + ansi-regex@5.0.1: {} + + ansi-styles@4.3.0: + dependencies: + color-convert: 2.0.1 + + argparse@2.0.1: {} + + array-union@2.1.0: {} + + balanced-match@1.0.2: {} + + base64-js@1.5.1: {} + + better-sqlite3@9.3.0: + dependencies: + bindings: 1.5.0 + prebuild-install: 7.1.1 + + better-sqlite3@9.5.0: + dependencies: + bindings: 1.5.0 + prebuild-install: 7.1.2 + + bindings@1.5.0: + dependencies: + file-uri-to-path: 1.0.0 + + bl@4.1.0: + dependencies: + buffer: 5.7.1 + inherits: 2.0.4 + readable-stream: 3.6.2 + + brace-expansion@1.1.11: + dependencies: + balanced-match: 1.0.2 + concat-map: 0.0.1 + + brace-expansion@2.0.1: + dependencies: + balanced-match: 1.0.2 + + braces@3.0.2: + dependencies: + fill-range: 7.0.1 + + buffer-from@1.1.2: {} + + buffer@5.7.1: + dependencies: + base64-js: 1.5.1 + ieee754: 1.2.1 + + callsites@3.1.0: {} + + camelcase@7.0.1: {} + + chalk@4.1.2: + dependencies: + ansi-styles: 4.3.0 + supports-color: 7.2.0 + + chalk@5.3.0: {} + + chownr@1.1.4: {} + + cli-color@2.0.3: + dependencies: + d: 1.0.1 + es5-ext: 0.10.62 + es6-iterator: 2.0.3 + memoizee: 0.4.15 + timers-ext: 0.1.7 + + color-convert@2.0.1: + dependencies: + color-name: 1.1.4 + + color-name@1.1.4: {} + + commander@9.5.0: {} + + concat-map@0.0.1: {} + + copy-anything@3.0.5: + dependencies: + is-what: 4.1.16 + + cross-spawn@7.0.3: + dependencies: + path-key: 3.1.1 + shebang-command: 2.0.0 + which: 2.0.2 + + d@1.0.1: + dependencies: + es5-ext: 0.10.62 + type: 1.2.0 + + debug@4.3.4: + dependencies: + ms: 2.1.2 + + decompress-response@6.0.0: + dependencies: + mimic-response: 3.1.0 + + deep-extend@0.6.0: {} + + deep-is@0.1.4: {} + + detect-libc@2.0.3: {} + + difflib@0.2.4: + dependencies: + heap: 0.2.7 + + dir-glob@3.0.1: + dependencies: + path-type: 4.0.0 + + doctrine@3.0.0: + dependencies: + esutils: 2.0.3 + + dom-serializer@1.4.1: + dependencies: + domelementtype: 2.3.0 + domhandler: 4.3.1 + entities: 2.2.0 + + domelementtype@2.3.0: {} + + domhandler@4.3.1: + dependencies: + domelementtype: 2.3.0 + + domutils@2.8.0: + dependencies: + dom-serializer: 1.4.1 + domelementtype: 2.3.0 + domhandler: 4.3.1 + + dotenv@16.3.1: {} + + dreamopt@0.8.0: + dependencies: + wordwrap: 1.0.0 + + drizzle-kit@0.20.13: + dependencies: + '@drizzle-team/studio': 0.0.39 + '@esbuild-kit/esm-loader': 2.6.5 + camelcase: 7.0.1 + chalk: 5.3.0 + commander: 9.5.0 + env-paths: 3.0.0 + esbuild: 0.19.10 + esbuild-register: 3.5.0(esbuild@0.19.10) + glob: 8.1.0 + hanji: 0.0.5 + json-diff: 0.9.0 + minimatch: 7.4.6 + semver: 7.5.4 + zod: 3.22.4 + transitivePeerDependencies: + - supports-color + + drizzle-orm@0.29.3(@types/better-sqlite3@7.6.8)(better-sqlite3@9.3.0): + optionalDependencies: + '@types/better-sqlite3': 7.6.8 + better-sqlite3: 9.3.0 + + end-of-stream@1.4.4: + dependencies: + once: 1.4.0 + + entities@2.2.0: {} + + env-paths@3.0.0: {} + + es5-ext@0.10.62: + dependencies: + es6-iterator: 2.0.3 + es6-symbol: 3.1.3 + next-tick: 1.1.0 + + es6-iterator@2.0.3: + dependencies: + d: 1.0.1 + es5-ext: 0.10.62 + es6-symbol: 3.1.3 + + es6-symbol@3.1.3: + dependencies: + d: 1.0.1 + ext: 1.7.0 + + es6-weak-map@2.0.3: + dependencies: + d: 1.0.1 + es5-ext: 0.10.62 + es6-iterator: 2.0.3 + es6-symbol: 3.1.3 + + esbuild-register@3.5.0(esbuild@0.19.10): + dependencies: + debug: 4.3.4 + esbuild: 0.19.10 + transitivePeerDependencies: + - supports-color + + esbuild@0.18.20: + optionalDependencies: + '@esbuild/android-arm': 0.18.20 + '@esbuild/android-arm64': 0.18.20 + '@esbuild/android-x64': 0.18.20 + '@esbuild/darwin-arm64': 0.18.20 + '@esbuild/darwin-x64': 0.18.20 + '@esbuild/freebsd-arm64': 0.18.20 + '@esbuild/freebsd-x64': 0.18.20 + '@esbuild/linux-arm': 0.18.20 + '@esbuild/linux-arm64': 0.18.20 + '@esbuild/linux-ia32': 0.18.20 + '@esbuild/linux-loong64': 0.18.20 + '@esbuild/linux-mips64el': 0.18.20 + '@esbuild/linux-ppc64': 0.18.20 + '@esbuild/linux-riscv64': 0.18.20 + '@esbuild/linux-s390x': 0.18.20 + '@esbuild/linux-x64': 0.18.20 + '@esbuild/netbsd-x64': 0.18.20 + '@esbuild/openbsd-x64': 0.18.20 + '@esbuild/sunos-x64': 0.18.20 + '@esbuild/win32-arm64': 0.18.20 + '@esbuild/win32-ia32': 0.18.20 + '@esbuild/win32-x64': 0.18.20 + + esbuild@0.19.10: + optionalDependencies: + '@esbuild/aix-ppc64': 0.19.10 + '@esbuild/android-arm': 0.19.10 + '@esbuild/android-arm64': 0.19.10 + '@esbuild/android-x64': 0.19.10 + '@esbuild/darwin-arm64': 0.19.10 + '@esbuild/darwin-x64': 0.19.10 + '@esbuild/freebsd-arm64': 0.19.10 + '@esbuild/freebsd-x64': 0.19.10 + '@esbuild/linux-arm': 0.19.10 + '@esbuild/linux-arm64': 0.19.10 + '@esbuild/linux-ia32': 0.19.10 + '@esbuild/linux-loong64': 0.19.10 + '@esbuild/linux-mips64el': 0.19.10 + '@esbuild/linux-ppc64': 0.19.10 + '@esbuild/linux-riscv64': 0.19.10 + '@esbuild/linux-s390x': 0.19.10 + '@esbuild/linux-x64': 0.19.10 + '@esbuild/netbsd-x64': 0.19.10 + '@esbuild/openbsd-x64': 0.19.10 + '@esbuild/sunos-x64': 0.19.10 + '@esbuild/win32-arm64': 0.19.10 + '@esbuild/win32-ia32': 0.19.10 + '@esbuild/win32-x64': 0.19.10 + + escape-string-regexp@4.0.0: {} + + eslint-scope@7.2.2: dependencies: esrecurse: 4.3.0 estraverse: 5.3.0 - dev: true - /eslint-visitor-keys@3.4.3: - resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - dev: true + eslint-visitor-keys@3.4.3: {} - /eslint@8.56.0: - resolution: {integrity: sha512-Go19xM6T9puCOWntie1/P997aXxFsOi37JIHRWI514Hc6ZnaHGKY9xFhrU65RT6CcBEzZoGG1e6Nq+DT04ZtZQ==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - hasBin: true + eslint@8.56.0: dependencies: '@eslint-community/eslint-utils': 4.4.0(eslint@8.56.0) '@eslint-community/regexpp': 4.10.0 @@ -1368,174 +2097,101 @@ packages: text-table: 0.2.0 transitivePeerDependencies: - supports-color - dev: true - /espree@9.6.1: - resolution: {integrity: sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + espree@9.6.1: dependencies: acorn: 8.11.3 acorn-jsx: 5.3.2(acorn@8.11.3) eslint-visitor-keys: 3.4.3 - dev: true - /esquery@1.5.0: - resolution: {integrity: sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==} - engines: {node: '>=0.10'} + esquery@1.5.0: dependencies: estraverse: 5.3.0 - dev: true - /esrecurse@4.3.0: - resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} - engines: {node: '>=4.0'} + esrecurse@4.3.0: dependencies: estraverse: 5.3.0 - dev: true - /estraverse@5.3.0: - resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} - engines: {node: '>=4.0'} - dev: true + estraverse@5.3.0: {} - /esutils@2.0.3: - resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==} - engines: {node: '>=0.10.0'} - dev: true + esutils@2.0.3: {} - /event-emitter@0.3.5: - resolution: {integrity: sha512-D9rRn9y7kLPnJ+hMq7S/nhvoKwwvVJahBi2BPmx3bvbsEdK3W9ii8cBSGjP+72/LnM4n6fo3+dkCX5FeTQruXA==} + event-emitter@0.3.5: dependencies: d: 1.0.1 es5-ext: 0.10.62 - dev: true - /event-target-shim@5.0.1: - resolution: {integrity: sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==} - engines: {node: '>=6'} - dev: false + events@3.2.0: {} - /expand-template@2.0.3: - resolution: {integrity: sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==} - engines: {node: '>=6'} - dev: false + expand-template@2.0.3: {} - /ext@1.7.0: - resolution: {integrity: sha512-6hxeJYaL110a9b5TEJSj0gojyHQAmA2ch5Os+ySCiA1QGdS697XWY1pzsrSjqA9LDEEgdB/KypIlR59RcLuHYw==} + ext@1.7.0: dependencies: type: 2.7.2 - dev: true - /fast-deep-equal@3.1.3: - resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} - dev: true + fast-deep-equal@3.1.3: {} - /fast-glob@3.3.2: - resolution: {integrity: sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==} - engines: {node: '>=8.6.0'} + fast-glob@3.3.2: dependencies: '@nodelib/fs.stat': 2.0.5 '@nodelib/fs.walk': 1.2.8 glob-parent: 5.1.2 merge2: 1.4.1 micromatch: 4.0.5 - dev: true - /fast-json-stable-stringify@2.1.0: - resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==} - dev: true + fast-json-stable-stringify@2.1.0: {} - /fast-levenshtein@2.0.6: - resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} - dev: true + fast-levenshtein@2.0.6: {} - /fastq@1.16.0: - resolution: {integrity: sha512-ifCoaXsDrsdkWTtiNJX5uzHDsrck5TzfKKDcuFFTIrrc/BS076qgEIfoIy1VeZqViznfKiysPYTh/QeHtnIsYA==} + fastq@1.16.0: dependencies: reusify: 1.0.4 - dev: true - /file-entry-cache@6.0.1: - resolution: {integrity: sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==} - engines: {node: ^10.12.0 || >=12.0.0} + file-entry-cache@6.0.1: dependencies: flat-cache: 3.2.0 - dev: true - /file-uri-to-path@1.0.0: - resolution: {integrity: sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==} - dev: false + file-uri-to-path@1.0.0: {} - /fill-range@7.0.1: - resolution: {integrity: sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==} - engines: {node: '>=8'} + fill-range@7.0.1: dependencies: to-regex-range: 5.0.1 - dev: true - /find-up@5.0.0: - resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} - engines: {node: '>=10'} + find-up@5.0.0: dependencies: locate-path: 6.0.0 path-exists: 4.0.0 - dev: true - /flat-cache@3.2.0: - resolution: {integrity: sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==} - engines: {node: ^10.12.0 || >=12.0.0} + flat-cache@3.2.0: dependencies: flatted: 3.2.9 keyv: 4.5.4 rimraf: 3.0.2 - dev: true - /flatted@3.2.9: - resolution: {integrity: sha512-36yxDn5H7OFZQla0/jFJmbIKTdZAQHngCedGxiMmpNfEZM0sdEeT+WczLQrjK6D7o2aiyLYDnkw0R3JK0Qv1RQ==} - dev: true + flatted@3.2.9: {} - /fs-constants@1.0.0: - resolution: {integrity: sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==} - dev: false + fs-constants@1.0.0: {} - /fs.realpath@1.0.0: - resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} - dev: true + fs.realpath@1.0.0: {} - /fsevents@2.3.3: - resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} - engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} - os: [darwin] - requiresBuild: true - dev: true + fsevents@2.3.3: optional: true - /get-tsconfig@4.7.2: - resolution: {integrity: sha512-wuMsz4leaj5hbGgg4IvDU0bqJagpftG5l5cXIAvo8uZrqn0NJqwtfupTN00VnkQJPcIRrxYrm1Ue24btpCha2A==} + get-tsconfig@4.7.2: dependencies: resolve-pkg-maps: 1.0.0 - dev: true - /github-from-package@0.0.0: - resolution: {integrity: sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==} - dev: false + github-from-package@0.0.0: {} - /glob-parent@5.1.2: - resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==} - engines: {node: '>= 6'} + glob-parent@5.1.2: dependencies: is-glob: 4.0.3 - dev: true - /glob-parent@6.0.2: - resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==} - engines: {node: '>=10.13.0'} + glob-parent@6.0.2: dependencies: is-glob: 4.0.3 - dev: true - /glob@7.2.3: - resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} + glob@7.2.3: dependencies: fs.realpath: 1.0.0 inflight: 1.0.6 @@ -1543,29 +2199,20 @@ packages: minimatch: 3.1.2 once: 1.4.0 path-is-absolute: 1.0.1 - dev: true - /glob@8.1.0: - resolution: {integrity: sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==} - engines: {node: '>=12'} + glob@8.1.0: dependencies: fs.realpath: 1.0.0 inflight: 1.0.6 inherits: 2.0.4 minimatch: 5.1.6 once: 1.4.0 - dev: true - /globals@13.24.0: - resolution: {integrity: sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==} - engines: {node: '>=8'} + globals@13.24.0: dependencies: type-fest: 0.20.2 - dev: true - /globby@11.1.0: - resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} - engines: {node: '>=10'} + globby@11.1.0: dependencies: array-union: 2.1.0 dir-glob: 3.0.1 @@ -1573,182 +2220,105 @@ packages: ignore: 5.3.0 merge2: 1.4.1 slash: 3.0.0 - dev: true - - /grammy@1.20.1: - resolution: {integrity: sha512-/vQiO3EGVVl3KmebXOnZLOA3Lfh1h4edi/f7Pu/dFuEijYrdX0hwg2v+vmH5qQn17Fp4i2P2wjbwr2dku5sLzA==} - engines: {node: ^12.20.0 || >=14.13.1} - dependencies: - '@grammyjs/types': 3.4.4 - abort-controller: 3.0.0 - debug: 4.3.4 - node-fetch: 2.7.0 - transitivePeerDependencies: - - encoding - - supports-color - dev: false - /graphemer@1.4.0: - resolution: {integrity: sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==} - dev: true + graphemer@1.4.0: {} - /hanji@0.0.5: - resolution: {integrity: sha512-Abxw1Lq+TnYiL4BueXqMau222fPSPMFtya8HdpWsz/xVAhifXou71mPh/kY2+08RgFcVccjG3uZHs6K5HAe3zw==} + hanji@0.0.5: dependencies: lodash.throttle: 4.1.1 sisteransi: 1.0.5 - dev: true - /has-flag@4.0.0: - resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} - engines: {node: '>=8'} - dev: true + has-flag@4.0.0: {} - /heap@0.2.7: - resolution: {integrity: sha512-2bsegYkkHO+h/9MGbn6KWcE45cHZgPANo5LXF7EvWdT0yT2EguSVO1nDgU5c8+ZOPwp2vMNa7YFsJhVcDR9Sdg==} - dev: true + heap@0.2.7: {} - /ieee754@1.2.1: - resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} - dev: false + htmlparser2@6.1.0: + dependencies: + domelementtype: 2.3.0 + domhandler: 4.3.1 + domutils: 2.8.0 + entities: 2.2.0 - /ignore@5.3.0: - resolution: {integrity: sha512-g7dmpshy+gD7mh88OC9NwSGTKoc3kyLAZQRU1mt53Aw/vnvfXnbC+F/7F7QoYVKbV+KNvJx8wArewKy1vXMtlg==} - engines: {node: '>= 4'} - dev: true + ieee754@1.2.1: {} - /import-fresh@3.3.0: - resolution: {integrity: sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==} - engines: {node: '>=6'} + ignore@5.3.0: {} + + import-fresh@3.3.0: dependencies: parent-module: 1.0.1 resolve-from: 4.0.0 - dev: true - /imurmurhash@0.1.4: - resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==} - engines: {node: '>=0.8.19'} - dev: true + imurmurhash@0.1.4: {} - /inflight@1.0.6: - resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} + inflight@1.0.6: dependencies: once: 1.4.0 wrappy: 1.0.2 - dev: true - /inherits@2.0.4: - resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} + inherits@2.0.4: {} - /ini@1.3.8: - resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} - dev: false + ini@1.3.8: {} - /is-extglob@2.1.1: - resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} - engines: {node: '>=0.10.0'} - dev: true + is-extglob@2.1.1: {} - /is-glob@4.0.3: - resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} - engines: {node: '>=0.10.0'} + is-glob@4.0.3: dependencies: is-extglob: 2.1.1 - dev: true - /is-number@7.0.0: - resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} - engines: {node: '>=0.12.0'} - dev: true + is-number@7.0.0: {} - /is-path-inside@3.0.3: - resolution: {integrity: sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==} - engines: {node: '>=8'} - dev: true + is-path-inside@3.0.3: {} - /is-promise@2.2.2: - resolution: {integrity: sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==} - dev: true + is-promise@2.2.2: {} - /is-what@4.1.16: - resolution: {integrity: sha512-ZhMwEosbFJkA0YhFnNDgTM4ZxDRsS6HqTo7qsZM08fehyRYIYa0yHu5R6mgo1n/8MgaPBXiPimPD77baVFYg+A==} - engines: {node: '>=12.13'} - dev: true + is-what@4.1.16: {} - /isexe@2.0.0: - resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==} + isexe@2.0.0: {} - /js-yaml@4.1.0: - resolution: {integrity: sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==} - hasBin: true + js-yaml@4.1.0: dependencies: argparse: 2.0.1 - dev: true - /json-buffer@3.0.1: - resolution: {integrity: sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==} - dev: true + json-buffer@3.0.1: {} - /json-diff@0.9.0: - resolution: {integrity: sha512-cVnggDrVkAAA3OvFfHpFEhOnmcsUpleEKq4d4O8sQWWSH40MBrWstKigVB1kGrgLWzuom+7rRdaCsnBD6VyObQ==} - hasBin: true + json-diff@0.9.0: dependencies: cli-color: 2.0.3 difflib: 0.2.4 dreamopt: 0.8.0 - dev: true - /json-schema-traverse@0.4.1: - resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} - dev: true + json-schema-traverse@0.4.1: {} - /json-stable-stringify-without-jsonify@1.0.1: - resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==} - dev: true + json-stable-stringify-without-jsonify@1.0.1: {} - /keyv@4.5.4: - resolution: {integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==} + keyv@4.5.4: dependencies: json-buffer: 3.0.1 - dev: true - /levn@0.4.1: - resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==} - engines: {node: '>= 0.8.0'} + levn@0.4.1: dependencies: prelude-ls: 1.2.1 type-check: 0.4.0 - dev: true - /locate-path@6.0.0: - resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==} - engines: {node: '>=10'} + locate-path@6.0.0: dependencies: p-locate: 5.0.0 - dev: true - /lodash.merge@4.6.2: - resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==} - dev: true + lodash.merge@4.6.2: {} - /lodash.throttle@4.1.1: - resolution: {integrity: sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==} - dev: true + lodash.throttle@4.1.1: {} - /lru-cache@6.0.0: - resolution: {integrity: sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==} - engines: {node: '>=10'} + long@5.2.3: {} + + lru-cache@6.0.0: dependencies: yallist: 4.0.0 - /lru-queue@0.1.0: - resolution: {integrity: sha512-BpdYkt9EvGl8OfWHDQPISVpcl5xZthb+XPsbELj5AQXxIC8IriDZIQYjBJPEm5rS420sjZ0TLEzRcq5KdBhYrQ==} + lru-queue@0.1.0: dependencies: es5-ext: 0.10.62 - dev: true - /memoizee@0.4.15: - resolution: {integrity: sha512-UBWmJpLZd5STPm7PMUlOw/TSy972M+z8gcyQ5veOnSDRREz/0bmpyTfKt3/51DhEBqCZQn1udM/5flcSPYhkdQ==} + memoizee@0.4.15: dependencies: d: 1.0.1 es5-ext: 0.10.62 @@ -1758,115 +2328,61 @@ packages: lru-queue: 0.1.0 next-tick: 1.1.0 timers-ext: 0.1.7 - dev: true - /merge2@1.4.1: - resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} - engines: {node: '>= 8'} - dev: true + merge2@1.4.1: {} - /micromatch@4.0.5: - resolution: {integrity: sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==} - engines: {node: '>=8.6'} + micromatch@4.0.5: dependencies: braces: 3.0.2 picomatch: 2.3.1 - dev: true - /mime-db@1.52.0: - resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} - engines: {node: '>= 0.6'} - dev: false + mime-db@1.52.0: {} - /mime-types@2.1.35: - resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} - engines: {node: '>= 0.6'} + mime-types@2.1.35: dependencies: mime-db: 1.52.0 - dev: false - /mimic-response@3.1.0: - resolution: {integrity: sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==} - engines: {node: '>=10'} - dev: false + mimic-response@3.1.0: {} - /minimatch@3.1.2: - resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} + minimatch@3.1.2: dependencies: brace-expansion: 1.1.11 - dev: true - /minimatch@5.1.6: - resolution: {integrity: sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==} - engines: {node: '>=10'} + minimatch@5.1.6: dependencies: brace-expansion: 2.0.1 - dev: true - /minimatch@7.4.6: - resolution: {integrity: sha512-sBz8G/YjVniEz6lKPNpKxXwazJe4c19fEfV2GDMX6AjFz+MX9uDWIZW8XreVhkFW3fkIdTv/gxWr/Kks5FFAVw==} - engines: {node: '>=10'} + minimatch@7.4.6: dependencies: brace-expansion: 2.0.1 - dev: true - /minimatch@9.0.3: - resolution: {integrity: sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==} - engines: {node: '>=16 || 14 >=14.17'} + minimatch@9.0.3: dependencies: brace-expansion: 2.0.1 - dev: true - /minimist@1.2.8: - resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} - dev: false + minimist@1.2.8: {} - /mkdirp-classic@0.5.3: - resolution: {integrity: sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==} - dev: false + mkdirp-classic@0.5.3: {} - /ms@2.1.2: - resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} + ms@2.1.2: {} - /napi-build-utils@1.0.2: - resolution: {integrity: sha512-ONmRUqK7zj7DWX0D9ADe03wbwOBZxNAfF20PlGfCWQcD3+/MakShIHrMqx9YwPTfxDdF1zLeL+RGZiR9kGMLdg==} - dev: false + napi-build-utils@1.0.2: {} - /natural-compare@1.4.0: - resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} - dev: true + natural-compare@1.4.0: {} - /next-tick@1.1.0: - resolution: {integrity: sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ==} - dev: true + next-tick@1.1.0: {} - /node-abi@3.54.0: - resolution: {integrity: sha512-p7eGEiQil0YUV3ItH4/tBb781L5impVmmx2E9FRKF7d18XXzp4PGT2tdYMFY6wQqgxD0IwNZOiSJ0/K0fSi/OA==} - engines: {node: '>=10'} + node-abi@3.65.0: dependencies: - semver: 7.5.4 - dev: false + semver: 7.6.2 - /node-fetch@2.7.0: - resolution: {integrity: sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==} - engines: {node: 4.x || >=6.0.0} - peerDependencies: - encoding: ^0.1.0 - peerDependenciesMeta: - encoding: - optional: true - dependencies: - whatwg-url: 5.0.0 - dev: false + node-gyp-build@4.8.1: {} - /once@1.4.0: - resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} + once@1.4.0: dependencies: wrappy: 1.0.2 - /optionator@0.9.3: - resolution: {integrity: sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==} - engines: {node: '>= 0.8.0'} + optionator@0.9.3: dependencies: '@aashutoshrathi/word-wrap': 1.2.6 deep-is: 0.1.4 @@ -1874,371 +2390,221 @@ packages: levn: 0.4.1 prelude-ls: 1.2.1 type-check: 0.4.0 - dev: true - /p-limit@3.1.0: - resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==} - engines: {node: '>=10'} + p-limit@3.1.0: dependencies: yocto-queue: 0.1.0 - dev: true - /p-locate@5.0.0: - resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==} - engines: {node: '>=10'} + p-locate@5.0.0: dependencies: p-limit: 3.1.0 - dev: true - /parent-module@1.0.1: - resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} - engines: {node: '>=6'} + parent-module@1.0.1: dependencies: callsites: 3.1.0 - dev: true - /path-exists@4.0.0: - resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} - engines: {node: '>=8'} - dev: true + path-exists@4.0.0: {} - /path-is-absolute@1.0.1: - resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} - engines: {node: '>=0.10.0'} - dev: true + path-is-absolute@1.0.1: {} - /path-key@3.1.1: - resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} - engines: {node: '>=8'} - dev: true + path-key@3.1.1: {} - /path-type@4.0.0: - resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} - engines: {node: '>=8'} - dev: true + path-type@4.0.0: {} - /picomatch@2.3.1: - resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} - engines: {node: '>=8.6'} - dev: true + picomatch@2.3.1: {} - /prebuild-install@7.1.1: - resolution: {integrity: sha512-jAXscXWMcCK8GgCoHOfIr0ODh5ai8mj63L2nWrjuAgXE6tDyYGnx4/8o/rCgU+B4JSyZBKbeZqzhtwtC3ovxjw==} - engines: {node: '>=10'} - hasBin: true + prebuild-install@7.1.1: dependencies: - detect-libc: 2.0.2 + detect-libc: 2.0.3 expand-template: 2.0.3 github-from-package: 0.0.0 minimist: 1.2.8 mkdirp-classic: 0.5.3 napi-build-utils: 1.0.2 - node-abi: 3.54.0 + node-abi: 3.65.0 pump: 3.0.0 rc: 1.2.8 simple-get: 4.0.1 tar-fs: 2.1.1 tunnel-agent: 0.6.0 - dev: false - /prelude-ls@1.2.1: - resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} - engines: {node: '>= 0.8.0'} - dev: true + prebuild-install@7.1.2: + dependencies: + detect-libc: 2.0.3 + expand-template: 2.0.3 + github-from-package: 0.0.0 + minimist: 1.2.8 + mkdirp-classic: 0.5.3 + napi-build-utils: 1.0.2 + node-abi: 3.65.0 + pump: 3.0.0 + rc: 1.2.8 + simple-get: 4.0.1 + tar-fs: 2.1.1 + tunnel-agent: 0.6.0 - /pump@3.0.0: - resolution: {integrity: sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==} + prelude-ls@1.2.1: {} + + pump@3.0.0: dependencies: end-of-stream: 1.4.4 once: 1.4.0 - dev: false - /punycode@2.3.1: - resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} - engines: {node: '>=6'} - dev: true + punycode@2.3.1: {} - /queue-microtask@1.2.3: - resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==} - dev: true + queue-microtask@1.2.3: {} - /rc@1.2.8: - resolution: {integrity: sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==} - hasBin: true + rc@1.2.8: dependencies: deep-extend: 0.6.0 ini: 1.3.8 minimist: 1.2.8 strip-json-comments: 2.0.1 - dev: false - /readable-stream@3.6.2: - resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==} - engines: {node: '>= 6'} + readable-stream@3.6.2: dependencies: inherits: 2.0.4 string_decoder: 1.3.0 util-deprecate: 1.0.2 - dev: false - /resolve-from@4.0.0: - resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==} - engines: {node: '>=4'} - dev: true + resolve-from@4.0.0: {} - /resolve-pkg-maps@1.0.0: - resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==} - dev: true + resolve-pkg-maps@1.0.0: {} - /reusify@1.0.4: - resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==} - engines: {iojs: '>=1.0.0', node: '>=0.10.0'} - dev: true + reusify@1.0.4: {} - /rimraf@3.0.2: - resolution: {integrity: sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==} - hasBin: true + rimraf@3.0.2: dependencies: glob: 7.2.3 - dev: true - /run-parallel@1.2.0: - resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==} + run-parallel@1.2.0: dependencies: queue-microtask: 1.2.3 - dev: true - /safe-buffer@5.2.1: - resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} - dev: false + safe-buffer@5.2.1: {} - /semver@7.5.4: - resolution: {integrity: sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==} - engines: {node: '>=10'} - hasBin: true + semver@7.5.4: dependencies: lru-cache: 6.0.0 - /shebang-command@2.0.0: - resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} - engines: {node: '>=8'} + semver@7.6.2: {} + + shebang-command@2.0.0: dependencies: shebang-regex: 3.0.0 - dev: true - /shebang-regex@3.0.0: - resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==} - engines: {node: '>=8'} - dev: true + shebang-regex@3.0.0: {} - /simple-concat@1.0.1: - resolution: {integrity: sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==} - dev: false + simple-concat@1.0.1: {} - /simple-get@4.0.1: - resolution: {integrity: sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==} + simple-get@4.0.1: dependencies: decompress-response: 6.0.0 once: 1.4.0 simple-concat: 1.0.1 - dev: false - /sisteransi@1.0.5: - resolution: {integrity: sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==} - dev: true + sisteransi@1.0.5: {} - /slash@3.0.0: - resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} - engines: {node: '>=8'} - dev: true + slash@3.0.0: {} - /source-map-support@0.5.21: - resolution: {integrity: sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==} + source-map-support@0.5.21: dependencies: buffer-from: 1.1.2 source-map: 0.6.1 - dev: true - /source-map@0.6.1: - resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==} - engines: {node: '>=0.10.0'} - dev: true + source-map@0.6.1: {} - /string_decoder@1.3.0: - resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==} + string_decoder@1.3.0: dependencies: safe-buffer: 5.2.1 - dev: false - /strip-ansi@6.0.1: - resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} - engines: {node: '>=8'} + strip-ansi@6.0.1: dependencies: ansi-regex: 5.0.1 - dev: true - /strip-json-comments@2.0.1: - resolution: {integrity: sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==} - engines: {node: '>=0.10.0'} - dev: false + strip-json-comments@2.0.1: {} - /strip-json-comments@3.1.1: - resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} - engines: {node: '>=8'} - dev: true + strip-json-comments@3.1.1: {} - /superjson@2.2.1: - resolution: {integrity: sha512-8iGv75BYOa0xRJHK5vRLEjE2H/i4lulTjzpUXic3Eg8akftYjkmQDa8JARQ42rlczXyFR3IeRoeFCc7RxHsYZA==} - engines: {node: '>=16'} + superjson@2.2.1: dependencies: copy-anything: 3.0.5 - dev: true - /supports-color@7.2.0: - resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} - engines: {node: '>=8'} + supports-color@7.2.0: dependencies: has-flag: 4.0.0 - dev: true - /tar-fs@2.1.1: - resolution: {integrity: sha512-V0r2Y9scmbDRLCNex/+hYzvp/zyYjvFbHPNgVTKfQvVrb6guiE/fxP+XblDNR011utopbkex2nM4dHNV6GDsng==} + tar-fs@2.1.1: dependencies: chownr: 1.1.4 mkdirp-classic: 0.5.3 pump: 3.0.0 tar-stream: 2.2.0 - dev: false - /tar-stream@2.2.0: - resolution: {integrity: sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==} - engines: {node: '>=6'} + tar-stream@2.2.0: dependencies: bl: 4.1.0 end-of-stream: 1.4.4 fs-constants: 1.0.0 inherits: 2.0.4 readable-stream: 3.6.2 - dev: false - /text-table@0.2.0: - resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} - dev: true + text-table@0.2.0: {} - /timers-ext@0.1.7: - resolution: {integrity: sha512-b85NUNzTSdodShTIbky6ZF02e8STtVVfD+fu4aXXShEELpozH+bCpJLYMPZbsABN2wDH7fJpqIoXxJpzbf0NqQ==} + timers-ext@0.1.7: dependencies: es5-ext: 0.10.62 next-tick: 1.1.0 - dev: true - /to-regex-range@5.0.1: - resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} - engines: {node: '>=8.0'} + to-regex-range@5.0.1: dependencies: is-number: 7.0.0 - dev: true - - /tr46@0.0.3: - resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==} - dev: false - /ts-api-utils@1.0.3(typescript@5.3.3): - resolution: {integrity: sha512-wNMeqtMz5NtwpT/UZGY5alT+VoKdSsOOP/kqHFcUW1P/VRhH2wJ48+DN2WwUliNbQ976ETwDL0Ifd2VVvgonvg==} - engines: {node: '>=16.13.0'} - peerDependencies: - typescript: '>=4.2.0' + ts-api-utils@1.0.3(typescript@5.3.3): dependencies: typescript: 5.3.3 - dev: true - /tsx@4.7.0: - resolution: {integrity: sha512-I+t79RYPlEYlHn9a+KzwrvEwhJg35h/1zHsLC2JXvhC2mdynMv6Zxzvhv5EMV6VF5qJlLlkSnMVvdZV3PSIGcg==} - engines: {node: '>=18.0.0'} - hasBin: true + tsx@4.7.0: dependencies: esbuild: 0.19.10 get-tsconfig: 4.7.2 optionalDependencies: fsevents: 2.3.3 - dev: true - /tunnel-agent@0.6.0: - resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==} + tunnel-agent@0.6.0: dependencies: safe-buffer: 5.2.1 - dev: false - /type-check@0.4.0: - resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} - engines: {node: '>= 0.8.0'} + type-check@0.4.0: dependencies: prelude-ls: 1.2.1 - dev: true - /type-fest@0.20.2: - resolution: {integrity: sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==} - engines: {node: '>=10'} - dev: true + type-fest@0.20.2: {} - /type@1.2.0: - resolution: {integrity: sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg==} - dev: true + type@1.2.0: {} - /type@2.7.2: - resolution: {integrity: sha512-dzlvlNlt6AXU7EBSfpAscydQ7gXB+pPGsPnfJnZpiNJBDj7IaJzQlBZYGdEi4R9HmPdBv2XmWJ6YUtoTa7lmCw==} - dev: true + type@2.7.2: {} - /typescript@5.3.3: - resolution: {integrity: sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==} - engines: {node: '>=14.17'} - hasBin: true + typescript@5.3.3: {} - /undici-types@5.26.5: - resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} + undici-types@5.26.5: {} - /uri-js@4.4.1: - resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} + uri-js@4.4.1: dependencies: punycode: 2.3.1 - dev: true - - /util-deprecate@1.0.2: - resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} - dev: false - - /webidl-conversions@3.0.1: - resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} - dev: false - /whatwg-url@5.0.0: - resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==} - dependencies: - tr46: 0.0.3 - webidl-conversions: 3.0.1 - dev: false + util-deprecate@1.0.2: {} - /which@2.0.2: - resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==} - engines: {node: '>= 8'} - hasBin: true + which@2.0.2: dependencies: isexe: 2.0.0 - /wordwrap@1.0.0: - resolution: {integrity: sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==} - dev: true + wordwrap@1.0.0: {} - /wrappy@1.0.2: - resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} + wrappy@1.0.2: {} - /yallist@4.0.0: - resolution: {integrity: sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==} + yallist@4.0.0: {} - /yocto-queue@0.1.0: - resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} - engines: {node: '>=10'} - dev: true + yocto-queue@0.1.0: {} - /zod@3.22.4: - resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} + zod@3.22.4: {} diff --git a/src/request.ts b/src/core/data/cobalt.ts similarity index 65% rename from src/request.ts rename to src/core/data/cobalt.ts index a0fe1c1..753f760 100644 --- a/src/request.ts +++ b/src/core/data/cobalt.ts @@ -1,11 +1,12 @@ import { z } from "zod" -import { env } from "#env" -import { Text, literal, translatable, compound } from "#text" +import { Text, literal, translatable } from "#core/utils/text" +import { error, ok, Result } from "#core/utils/result" const genericErrorSchema = z.object({ status: z.literal("error"), text: z.string(), }) +export type GenericCobaltError = z.infer // Main @@ -31,33 +32,18 @@ const mediaResponseSchema = z.discriminatedUnion("status", [ genericErrorSchema, ]) -type FailResponse = { - status: "fail", - fails: Text, -} +export type CobaltMediaResponse = z.infer +export type SuccessfulCobaltMediaResponse = Exclude -type FetchMediaResponse = - Exclude, z.infer> | FailResponse export const fetchMedia = async ( - { url, lang, isAudioOnly = false, fails = [] }: { + { url, lang, apiBaseUrl, isAudioOnly = false }: { url: string, lang?: string, isAudioOnly?: boolean, - fails?: Text[], + apiBaseUrl: string, }, -): Promise => { - if (fails.length >= env.API_BASE_URL.length) - return { - status: "fail", - fails: compound(...fails), - } - - const currentBaseUrl = env.API_BASE_URL[fails.length] - const next = async (reason: Text) => await fetchMedia( - { url, lang, isAudioOnly, fails: [...fails, compound(literal(`\n${currentBaseUrl} - `), reason)] }, - ) - - const res = await fetch(`${currentBaseUrl}/json`, { +): Promise> => { + const res = await fetch(`${apiBaseUrl}/json`, { method: "POST", headers: [ ["Accept", "application/json"], @@ -69,10 +55,10 @@ export const fetchMedia = async ( const body = await res.json().catch(() => null) const data = mediaResponseSchema.safeParse(body) - if (!data.success) return next(translatable("error-invalid-response")) - if (data.data.status === "error") return next(literal(data.data.text)) + if (!data.success) return error(translatable("error-invalid-response")) + if (data.data.status === "error") return error(literal(data.data.text)) - return data.data + return ok(data.data) } // Stream diff --git a/src/db/database.ts b/src/core/data/db/database.ts similarity index 72% rename from src/db/database.ts rename to src/core/data/db/database.ts index 362ce98..a1d8549 100644 --- a/src/db/database.ts +++ b/src/core/data/db/database.ts @@ -1,9 +1,9 @@ import { drizzle } from "drizzle-orm/better-sqlite3" import Database from "better-sqlite3" import { migrate } from "drizzle-orm/better-sqlite3/migrator" -import * as schema from "#db/schema" +import * as schema from "#core/data/db/schema" -const sqlite = new Database("sqlite.db") +const sqlite = new Database("data/sqlite.db") export const db = drizzle(sqlite, { schema }) migrate(db, { migrationsFolder: "migrations" }) diff --git a/src/db/schema.ts b/src/core/data/db/schema.ts similarity index 75% rename from src/db/schema.ts rename to src/core/data/db/schema.ts index 80be902..d25650f 100644 --- a/src/db/schema.ts +++ b/src/core/data/db/schema.ts @@ -7,9 +7,13 @@ export const requests = sqliteTable("requests", { }) export const users = sqliteTable("users", { + id: int("id").notNull().primaryKey().unique(), + downloadCount: int("downloads").default(0), +}) + +export const settings = sqliteTable("settings", { id: int("id").notNull().primaryKey().unique(), preferredOutput: text("output"), preferredAttribution: int("attribution").notNull().default(0), languageOverride: text("language"), - downloadCount: int("downloads"), }) diff --git a/src/core/data/request.ts b/src/core/data/request.ts new file mode 100644 index 0000000..f092d80 --- /dev/null +++ b/src/core/data/request.ts @@ -0,0 +1,94 @@ +import { z } from "zod" +import { eq, InferSelectModel } from "drizzle-orm" +import { requests } from "#core/data/db/schema" +import { error, ok, Result } from "#core/utils/result" +import { compound, CompoundText, literal, Text, translatable } from "#core/utils/text" +import { randomUUID } from "node:crypto" +import { db } from "#core/data/db/database" +import { fetchMedia, fetchStream, SuccessfulCobaltMediaResponse } from "#core/data/cobalt" + +const mediaUrlSchema = z.string().url() + +export type MediaRequest = InferSelectModel + +export const createRequest = async ( + userInput: string, + authorId: number, +): Promise> => { + const url = mediaUrlSchema.safeParse(userInput) + if (!url.success) return error(translatable("error-not-url")) + + const id = randomUUID() + const req = { + id, + authorId, + url: url.data, + } + await db + .insert(requests) + .values(req) + + return ok(req) +} + +export const getRequest = (requestId: string) => db.query.requests.findFirst({ where: eq(requests.id, requestId) }) + +export type OutputMedia = { fileName?: string, file: Buffer | URL } +export const outputOptions = ["auto", "audio"] +export const finishRequest = async ( + outputType: string, + request: MediaRequest, + baseApiUrlPool: string[], + lang?: string, +): Promise> => { + await db.delete(requests).where(eq(requests.id, request.id)) + + const res = await tryDownload(outputType, request, baseApiUrlPool, lang) + if (!res.success) return res + + if (res.result.status === "stream") { + const data = await fetchStream(res.result.url) + if (data.status === "error") return error(literal(data.text)) + + return ok({ + file: data.buffer, + fileName: data.filename, + }) + } + + const source = new URL(res.result.url) + return ok({ + fileName: source.pathname.split("/").at(-1), + file: source, + }) +} + +const tryDownload = async ( + outputType: string, + request: MediaRequest, + baseApiUrlPool: string[], + lang?: string, + fails: Text[] = [], +): Promise> => { + const currentBaseApiUrl = baseApiUrlPool.at(0) + if (!currentBaseApiUrl) + return error(compound(...fails)) + + const res = await fetchMedia({ + url: request.url, + isAudioOnly: outputType === "audio", + lang, + apiBaseUrl: baseApiUrlPool[0], + }) + + if (!res.success) + return tryDownload( + outputType, + request, + baseApiUrlPool.slice(1), + lang, + [...fails, compound(literal(`\n${currentBaseApiUrl}: `), res.error)], + ) + + return res +} diff --git a/src/core/data/settings.ts b/src/core/data/settings.ts new file mode 100644 index 0000000..37bc272 --- /dev/null +++ b/src/core/data/settings.ts @@ -0,0 +1,55 @@ +import { eq, InferSelectModel } from "drizzle-orm" +import { settings as settingsTable } from "#core/data/db/schema" +import { locales } from "#core/utils/i18n" +import { outputOptions } from "#core/data/request" +import { db } from "#core/data/db/database" + +export type Settings = Omit, "id"> + +export const defaultSettings: Settings = { + preferredOutput: null, + preferredAttribution: 0, + languageOverride: null, +} + +export const settingOptions: { + [K in keyof Settings]: Settings[K][] +} = { + preferredOutput: [null, ...outputOptions], + preferredAttribution: [0, 1], + languageOverride: [null, ...locales], +} + +export const settingI18n: { + [K in keyof Settings]: { key: string, mode: "translatable" | "literal" } +} = { + preferredOutput: { key: "output", mode: "translatable" }, + preferredAttribution: { key: "attribution", mode: "translatable" }, + languageOverride: { key: "lang", mode: "literal" }, +} + +export const getSettings = async (id: number): Promise => { + const { id: _, ...settings } = await db.query.settings.findFirst({ + where: eq(settingsTable.id, id), + }) || { id, ...defaultSettings } + return settings +} + +export const updateSetting = async (key: string, current: Settings, user: number) => { + const validKey = key as keyof Settings + + const thisSettingOptions = settingOptions[validKey] as (typeof settingOptions[typeof validKey][number])[] | null + if (!thisSettingOptions) return // Invalid key + + const currentIndex = thisSettingOptions.indexOf(current[validKey]) + const newIndex = (currentIndex + 1) % thisSettingOptions.length + const newOption = thisSettingOptions[newIndex] + + const newData = await db.insert(settingsTable) + .values({ id: user, [validKey]: newOption }) + .onConflictDoUpdate({ target: settingsTable.id, set: { [validKey]: newOption } }) + .returning() + + const { id: _, ...newSettings } = newData[0] + return newSettings +} diff --git a/src/stats.ts b/src/core/data/stats.ts similarity index 87% rename from src/stats.ts rename to src/core/data/stats.ts index cf905c9..a076d86 100644 --- a/src/stats.ts +++ b/src/core/data/stats.ts @@ -1,5 +1,5 @@ -import { db } from "#db/database" -import { users } from "#db/schema" +import { db } from "#core/data/db/database" +import { users } from "#core/data/db/schema" import { eq, sql, sum } from "drizzle-orm" export async function incrementDownloadCount(user: number) { diff --git a/src/core/utils/i18n.ts b/src/core/utils/i18n.ts new file mode 100644 index 0000000..2beb942 --- /dev/null +++ b/src/core/utils/i18n.ts @@ -0,0 +1,41 @@ +import { FluentBundle, FluentResource, FluentVariable } from "@fluent/bundle" +import { readdirSync, readFileSync } from "fs" +import path from "node:path" + +const errorEmoticons = ["( • ᴖ • 。)", "(ᴗ_ ᴗ。)", "(,,>﹏<,,)"] +export const fallbackLocale = "en" +const localeDirectory = "locales" + +export type TranslationParams = { [key: string]: FluentVariable } + +function getErrorEmoticonContext() { + const errorEmoticon = errorEmoticons[Math.floor(Math.random() * errorEmoticons.length)] + return { "error-emoticon": errorEmoticon } +} + +function setupI18n() { + const localeDirContents = readdirSync(localeDirectory) + return localeDirContents.map((localeFile) => { + const locale = localeFile.replace(".ftl", "") + const bundle = new FluentBundle(locale) + const resource = new FluentResource(readFileSync(path.join(localeDirectory, localeFile), "utf8")) + bundle.addResource(resource) + return bundle + }) +} + +const bundles = setupI18n() +export const locales = bundles.flatMap(b => b.locales) + +export function translate(locale: string, key: string, params?: TranslationParams) { + const bundle + = bundles.find(bundle => bundle.locales.includes(locale)) + ?? bundles.find(bundle => bundle.locales.includes(fallbackLocale)) + + if (!bundle) + throw new Error(`Could not find bundle for language ${navigator.language} or fallback locale ${fallbackLocale}`) + + const message = bundle.getMessage(key) + if (!message?.value) return key + return bundle.formatPattern(message.value, { ...params, ...getErrorEmoticonContext() }) +} diff --git a/src/result.ts b/src/core/utils/result.ts similarity index 100% rename from src/result.ts rename to src/core/utils/result.ts diff --git a/src/text.ts b/src/core/utils/text.ts similarity index 55% rename from src/text.ts rename to src/core/utils/text.ts index 471acbc..a86a5ed 100644 --- a/src/text.ts +++ b/src/core/utils/text.ts @@ -1,5 +1,4 @@ -import { Context, MiddlewareFn } from "grammy" -import { I18nFlavor } from "@grammyjs/i18n" +import { TranslationParams } from "#core/utils/i18n" export type LiteralText = { type: "literal", @@ -9,6 +8,7 @@ export type LiteralText = { export type TranslatableText = { type: "translatable", key: string, + params?: TranslationParams, } export type CompoundText = { @@ -25,12 +25,3 @@ export type Text = LiteralText | TranslatableText | CompoundText export const literal = (text: string): LiteralText => ({ type: "literal", text }) export const translatable = (key: string): TranslatableText => ({ type: "translatable", key }) export const compound = (...content: Text[]): CompoundText => ({ type: "compound", content }) -export const textMiddleware: MiddlewareFn = async (ctx, next) => { - ctx.evaluateText = (text: Text): string => { - if (text.type === "literal") return text.text - if (text.type === "translatable") return ctx.t(text.key) - if (text.type === "compound") return text.content.map(t => ctx.evaluateText(t)).join("") - return "" - } - await next() -} diff --git a/src/handler.ts b/src/handler.ts deleted file mode 100644 index ddacbfa..0000000 --- a/src/handler.ts +++ /dev/null @@ -1,91 +0,0 @@ -import { z } from "zod" -import { fetchMedia, fetchStream } from "#request" -import { ok, error, Result } from "#result" -import { literal, Text, translatable } from "#text" -import { env } from "#env" -import { randomUUID } from "node:crypto" -import { InputMedia } from "grammy/types" -import { InputFile } from "grammy" -import mime from "mime-types" -import { db } from "#db/database" -import { requests } from "#db/schema" -import { eq, InferSelectModel } from "drizzle-orm" - -const mediaUrlSchema = z.string().url() - -export type MediaRequest = InferSelectModel -export const createRequest = async ( - userInput: string, - authorId: number, -): Promise> => { - const url = mediaUrlSchema.safeParse(userInput) - if (!url.success) return error(translatable("error-not-url")) - - const id = randomUUID() - const req = { - id, - authorId, - url: url.data, - } - await db - .insert(requests) - .values(req) - - return ok(req) -} - -export const getRequest = (requestId: string) => db.query.requests.findFirst({ where: eq(requests.id, requestId) }) - -export const outputOptions = ["auto", "audio"] - -export const getOutputSelectionMessage = (requestId: string) => ({ - image: env.SELECT_TYPE_PHOTO_URL, - caption: translatable("type-select-title"), - options: outputOptions.map(option => ({ - key: `${option}:${requestId}`, - name: translatable(`setting-output-${option}`), - })), -}) - -const getFileType = (filename?: string) => { - if (!filename) return "document" - - const mimeType = mime.lookup(filename) - if (!mimeType) return "document" - - if (mimeType.startsWith("video/")) return "video" - if (mimeType.startsWith("audio/")) return "audio" - return "document" -} - -export const handleMediaDownload = async ( - outputType: string, - request: MediaRequest | undefined, - lang?: string, -): Promise> => { - if (!request) return error(translatable("error-request-not-found")) - await db.delete(requests).where(eq(requests.id, request.id)) - - const res = await fetchMedia({ - url: request.url, - isAudioOnly: outputType === "audio", - lang, - }) - if (res.status === "fail") return error(res.fails) - - if (res.status === "stream") { - const data = await fetchStream(res.url) - if (data.status === "error") return error(literal(data.text)) - - return ok({ - type: getFileType(data.filename), - media: new InputFile(data.buffer, data.filename), - }) - } - - const source = new URL(res.url) - return ok({ - type: getFileType(source.pathname.split("/").at(-1)), - media: new InputFile(source), - }) -} diff --git a/src/i18n.ts b/src/i18n.ts deleted file mode 100644 index 98fb419..0000000 --- a/src/i18n.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { I18n } from "@grammyjs/i18n" - -const errorEmoticons = ["( • ᴖ • 。)", "(ᴗ_ ᴗ。)", "(,,>﹏<,,)"] -export const i18n = new I18n({ - defaultLocale: "en", - directory: "locales", - globalTranslationContext() { - const errorEmoticon = errorEmoticons[Math.floor(Math.random() * errorEmoticons.length)] - return { "error-emoticon": errorEmoticon } - }, -}) diff --git a/src/index.ts b/src/index.ts index 6cd1a64..e4cdcea 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,221 +1,3 @@ -import { env } from "#env" -import { Api, Bot, Context } from "grammy" -import { I18nFlavor } from "@grammyjs/i18n" -import { getRequest, handleMediaDownload, createRequest, getOutputSelectionMessage, MediaRequest } from "#handler" -import { randomUUID } from "node:crypto" -import { TextFlavor, textMiddleware } from "#text" -import { InlineKeyboardMarkup, InputMedia } from "grammy/types" -import { i18n } from "#i18n" -import { - getSettingsMenu, - settingCallbackPrefix, - Settings, - SettingsFlavor, - settingsMiddleware, - updateSetting, -} from "#settings" -import { getDownloadStats, incrementDownloadCount } from "#stats" +import { startBot } from "#telegram/bot" -type CoboldContext = Context & I18nFlavor & TextFlavor & SettingsFlavor -const bot = new Bot(env.BOT_TOKEN) - -bot.use(i18n, textMiddleware, settingsMiddleware) - -const report = async (msg: string) => { - if (env.ERROR_CHAT_ID) - await bot.api.sendMessage(env.ERROR_CHAT_ID, msg) -} - -bot.catch((err) => { - if (err.message.includes("(413: Request Entity Too Large)")) - return err.ctx.editMessageCaption({ - caption: err.ctx.t("error", { message: err.ctx.t("error-too-large") }), - }) - if (err.ctx.inlineMessageId !== undefined || err.ctx.msg?.from?.id === err.ctx.me.id) { - void err.ctx.editMessageCaption({ - caption: err.ctx.t("error", { message: err.ctx.t("error-unknown") }), - }) - } - console.error("Unhandled Error:", err) - report(`${err.name}: ${err.message}\n${err.stack}\nIn ${err.ctx.chat?.id}`) - .catch(() => console.error("Additionally, failed to report error to Telegram")) -}) - -bot.command("start", ctx => - ctx.reply(ctx.t("start")), -) - -const settingsReplyMarkup = (ctx: CoboldContext, settingsOverride?: Settings): InlineKeyboardMarkup => ({ - inline_keyboard: getSettingsMenu(settingsOverride ?? ctx.userSettings).map(d => ([ - { - text: `${ctx.evaluateText(d.title)}: ${ctx.evaluateText(d.value)}`, - callback_data: d.key, - }, - ])), -}) - -bot.command("stats", async (ctx) => { - const count = await getDownloadStats() - await ctx.reply(ctx.t("stats-global", { count })) -}) - -bot.command("mystats", async (ctx) => { - const id = ctx.from?.id - if (!id) return - const count = await getDownloadStats(id) - await ctx.reply(ctx.t("stats-personal", { count })) -}) - -bot.command("settings", async (ctx) => { - await ctx.reply(ctx.t("settings-title"), { - reply_markup: settingsReplyMarkup(ctx), - }) -}) - -bot.on("message", async (ctx) => { - if (ctx.message.chat.type !== "private") return - - const req = await createRequest(ctx.message.text ?? "", ctx.message.from.id) - - if (!req.success) - return await ctx.reply(ctx.t("error", { message: ctx.evaluateText(req.error) })) - - const msg = getOutputSelectionMessage(req.result.id) - await ctx.replyWithPhoto(msg.image, { - reply_markup: { - inline_keyboard: [ - msg.options.map(option => ( - { text: ctx.evaluateText(option.name), callback_data: option.key } - )), - ], - }, - caption: ctx.evaluateText(msg.caption), - }) -}) - -bot.on("inline_query", async (ctx) => { - const req = await createRequest(ctx.inlineQuery.query, ctx.inlineQuery.from.id) - - if (!req.success) - return await ctx.answerInlineQuery([{ - id: randomUUID(), - type: "article", - title: ctx.t("error-title"), - description: ctx.evaluateText(req.error), - input_message_content: { - message_text: ctx.t("error", { message: ctx.evaluateText(req.error) }), - }, - }]) - - const msg = getOutputSelectionMessage(req.result.id) - await ctx.answerInlineQuery([{ - id: req.result.id, - type: "photo", - photo_url: env.SELECT_TYPE_PHOTO_URL, - thumbnail_url: env.SELECT_TYPE_PHOTO_URL, - title: ctx.t("download-title"), - reply_markup: { - inline_keyboard: [ - msg.options.map(option => ( - { text: ctx.evaluateText(option.name), callback_data: option.key } - )), - ], - }, - caption: ctx.evaluateText(msg.caption), - }], { - cache_time: 0, - }) -}) - -const capitalize = (str: S): Capitalize => - str.charAt(0).toUpperCase() + str.slice(1) as Capitalize - -const sendInputMedia = async (api: Api, chat: number, media: InputMedia) => { - const msg = await api[`send${capitalize(media.type)}`](chat, media.media) - // @ts-expect-error This way of getting file_id based by type works, but TS isn't smart enough to know that - const fileId: string = msg[media.type].file_id - return { chat: msg.chat.id, msg: msg.message_id, file: fileId } -} - -const onOutputSelected = async ( - ctx: CoboldContext, - outputType: string, - request: MediaRequest | undefined, -) => { - await ctx.editMessageReplyMarkup(undefined) - await ctx.editMessageCaption({ - caption: ctx.t("downloading-title"), - }) - - const result = await handleMediaDownload( - outputType, - request, - ctx.userSettings.languageOverride ?? ctx.from?.language_code, - ) - - if (!result.success) - return await ctx.editMessageCaption({ - caption: ctx.t("error", { message: ctx.evaluateText(result.error) }), - }) - - const fromId = ctx.from?.id - if (fromId) incrementDownloadCount(fromId).catch(() => { /* noop */ }) - - await ctx.editMessageCaption({ - caption: ctx.t("uploading-title"), - }) - - const caption = ctx.userSettings.preferredAttribution ? request?.url : undefined - // Weird fix for inline messages - if (ctx.inlineMessageId) { - const msg = await sendInputMedia(ctx.api, env.INLINE_FIX_CHAT_ID, result.result) - - await ctx.editMessageMedia({ - ...result.result, - media: msg.file, - caption, - }) - - await ctx.api.deleteMessage( - msg.chat, - msg.msg, - ) - - return - } - - await ctx.editMessageMedia({ - ...result.result, - caption, - }) -} - -bot.on("callback_query", async (ctx) => { - const [outputType, requestId] = (ctx.callbackQuery.data ?? "").split(":") - - if (outputType === settingCallbackPrefix) { - const newSettings = await updateSetting(requestId ?? "", ctx.userSettings, ctx.from.id) - ctx.i18n.useLocale(newSettings?.languageOverride ?? ctx.from.language_code ?? "en") - await ctx.editMessageText(ctx.t("settings-title")) - await ctx.editMessageReplyMarkup({ - reply_markup: settingsReplyMarkup(ctx, newSettings), - }) - return - } - - const request = await getRequest(requestId) - if (!outputType || !requestId || (request && request.authorId !== ctx.callbackQuery.from.id)) - return await ctx.answerCallbackQuery({ - text: ctx.t("error-not-button-owner"), - }) - await onOutputSelected(ctx, outputType, request) -}) - -bot.on("chosen_inline_result", async (ctx) => { - const request = await getRequest(ctx.chosenInlineResult.result_id) - if (ctx.userSettings.preferredOutput !== null) - return await onOutputSelected(ctx, ctx.userSettings.preferredOutput, request) -}) - -bot.start().then(() => report("Bot going down")) -report("Started bot").then() +void startBot() diff --git a/src/settings.ts b/src/settings.ts deleted file mode 100644 index be5b2c6..0000000 --- a/src/settings.ts +++ /dev/null @@ -1,90 +0,0 @@ -import { eq, InferSelectModel } from "drizzle-orm" -import { users } from "#db/schema" -import { i18n } from "#i18n" -import { outputOptions } from "#handler" -import { db } from "#db/database" -import { Context, MiddlewareFn } from "grammy" -import { literal, translatable } from "#text" -import { I18nFlavor } from "@grammyjs/i18n" - -export const settingCallbackPrefix = "setting" -export type Settings = Omit, "id" | "downloadCount"> -export type SettingsFlavor = { - userSettings: Settings, -} - -export const defaultSettings: Settings = { - preferredOutput: null, - preferredAttribution: 0, - languageOverride: null, -} - -export const settingOptions: { - [K in keyof Settings]: Settings[K][] -} = { - preferredOutput: [null, ...outputOptions], - preferredAttribution: [0, 1], - languageOverride: [null, ...i18n.locales], -} - -export const settingI18n: { - [K in keyof Settings]: { key: string, mode: "translatable" | "literal" } -} = { - preferredOutput: { key: "output", mode: "translatable" }, - preferredAttribution: { key: "attribution", mode: "translatable" }, - languageOverride: { key: "lang", mode: "literal" }, -} - -type SettingsEntries = [keyof Settings, Settings[keyof Settings]][] - -export const getSettingsMenu = (settings: Settings) => { - return (Object.entries(settings) as SettingsEntries) - .map(([key, value]) => { - const i18nData = settingI18n[key] - const settingKey = `setting-${i18nData.key}` - const valueText = value === null - ? translatable(`${settingKey}-unset`) - : i18nData.mode === "translatable" - ? translatable(`${settingKey}-${value}`) - : literal(String(value)) - return { - title: translatable(settingKey), - value: valueText, - key: `${settingCallbackPrefix}:${key}`, - } - }) -} - -const getSettings = async (id?: number | null) => { - if (id === null || id === undefined) return defaultSettings - const { id: _, downloadCount: __, ...settings } = await db.query.users.findFirst({ - where: eq(users.id, id), - }) || { id, downloadCount: 0, ...defaultSettings } - return settings -} - -export const updateSetting = async (key: string, current: Settings, user: number) => { - const validKey = key as keyof Settings - - const thisSettingOptions = settingOptions[validKey] as (typeof settingOptions[typeof validKey][number])[] | null - if (!thisSettingOptions) return // Invalid key - - const currentIndex = thisSettingOptions.indexOf(current[validKey]) - const newIndex = (currentIndex + 1) % thisSettingOptions.length - const newOption = thisSettingOptions[newIndex] - - const newData = await db.insert(users) - .values({ id: user, [validKey]: newOption }) - .onConflictDoUpdate({ target: users.id, set: { [validKey]: newOption } }) - .returning() - - const { id: _, downloadCount: __, ...newSettings } = newData[0] - return newSettings -} - -export const settingsMiddleware: MiddlewareFn = async (ctx, next) => { - ctx.userSettings = await getSettings(ctx.from?.id) - if (ctx.userSettings.languageOverride) - ctx.i18n.useLocale(ctx.userSettings.languageOverride) - await next() -} diff --git a/src/telegram/bot/download.ts b/src/telegram/bot/download.ts new file mode 100644 index 0000000..395ad72 --- /dev/null +++ b/src/telegram/bot/download.ts @@ -0,0 +1,141 @@ +import { Dispatcher, filters } from "@mtcute/dispatcher" +import { + getOutputSelectionMessage, + handleMediaDownload, + OutputButton, +} from "#telegram/helpers/handler" +import { BotInline, BotKeyboard, InputMedia, InputMediaLike, Peer } from "@mtcute/node" +import { randomUUID } from "node:crypto" +import { env } from "#telegram/helpers/env" +import { Evaluators, evaluatorsFor } from "#telegram/helpers/text" +import { createRequest, getRequest, MediaRequest } from "#core/data/request" +import { incrementDownloadCount } from "#core/data/stats" +import { getPeerSettings } from "#telegram/helpers/settings" + +export const downloadDp = Dispatcher.child() + +downloadDp.onNewMessage(filters.chat("private"), async (msg) => { + const { e, t } = await evaluatorsFor(msg.sender) + + const req = await createRequest(msg.text, msg.sender.id) + if (!req.success) { + await msg.replyText(e(req.error)) + return + } + + const selectMsg = getOutputSelectionMessage(req.result.id) + const reply = await msg.replyMedia(InputMedia.photo(selectMsg.image), { + caption: e(selectMsg.caption), + replyMarkup: BotKeyboard.inline([ + selectMsg.options.map(o => BotKeyboard.callback( + e(o.name), + o.key, + )), + ]), + }) + + const settings = await getPeerSettings(msg.sender) + if (settings.preferredOutput) { + await onOutputSelected( + settings.preferredOutput, + req.result, + args => msg.client.editMessage({ ...args, message: reply }), + { e, t }, + msg.sender, + !!settings.preferredAttribution, + ) + } +}) + +downloadDp.onInlineQuery(async (ctx) => { + const { t, e } = await evaluatorsFor(ctx.user) + + const req = await createRequest(ctx.query, ctx.user.id) + if (!req.success) { + await ctx.answer([ + BotInline.article(randomUUID(), { + title: t("error-title"), + description: e(req.error), + }), + ], { cacheTime: 0 }) + return + } + + const selectMsg = getOutputSelectionMessage(req.result.id) + await ctx.answer([ + BotInline.photo(req.result.id, env.SELECT_TYPE_PHOTO_URL, { + message: { + type: "media", + replyMarkup: BotKeyboard.inline([ + selectMsg.options.map(o => BotKeyboard.callback( + e(o.name), + o.key, + )), + ]), + text: e(selectMsg.caption), + }, + }), + ], { cacheTime: 0 }) +}) + +downloadDp.onAnyCallbackQuery(OutputButton.filter(), async (upd) => { + const settings = await getPeerSettings(upd.user) + const { t, e } = await evaluatorsFor(upd.user) + const { output: outputType, request: requestId } = upd.match + + const request = await getRequest(requestId) + if (request && request.authorId !== upd.user.id) + return await upd.answer({ + text: t("error-not-button-owner"), + }) + + await onOutputSelected( + outputType, + request, + args => upd.editMessage(args), + { t, e }, + upd.user, + !!settings.preferredAttribution, + ) +}) + +downloadDp.onChosenInlineResult(async (upd) => { + const { messageId } = upd + if (!messageId) + return + const settings = await getPeerSettings(upd.user) + if (settings.preferredOutput) { + const request = await getRequest(upd.id) + await onOutputSelected( + settings.preferredOutput, + request, + args => upd.editMessage({ ...args, messageId }), + await evaluatorsFor(upd.user), + upd.user, + !!settings.preferredAttribution, + ) + } +}) + +const onOutputSelected = async ( + outputType: string, + request: MediaRequest | undefined, + editMessage: (edit: { text?: string, media?: InputMediaLike }) => Promise, + { t, e }: Evaluators, + peer: Peer, + leaveSourceLink: boolean, +) => { + await editMessage({ text: t("downloading-title") }) + const res = await handleMediaDownload(outputType, request, peer) + if (!res.success) { + await editMessage({ text: t("error", { message: e(res.error) }) }) + return + } + + await editMessage({ text: t("uploading-title") }) + await editMessage({ media: res.result }) + await editMessage({ text: (leaveSourceLink && request?.url) || "" }) + + incrementDownloadCount(peer.id) + .catch(() => { /* noop */ }) +} diff --git a/src/telegram/bot/errors.ts b/src/telegram/bot/errors.ts new file mode 100644 index 0000000..4fa8a3c --- /dev/null +++ b/src/telegram/bot/errors.ts @@ -0,0 +1,48 @@ +import { randomUUID } from "node:crypto" +import { ParsedUpdate, TelegramClient, tl } from "@mtcute/node" +import { translatorFor } from "#telegram/helpers/i18n" +import { env } from "#telegram/helpers/env" + +export const createDispatcherErrorHandler = (client: TelegramClient) => async (err: Error, ctx: ParsedUpdate) => { + // Ignoring errors when user deleted the message or blocked the bot + if (tl.RpcError.is(err, "MESSAGE_ID_INVALID") || tl.RpcError.is(err, "USER_IS_BLOCKED")) + return true + + console.error("Unhandled Error:", err) + if (env.ERROR_CHAT_ID) + await client.sendText( + env.ERROR_CHAT_ID, + `unhandled error з:\n${err.name}: ${err.message}\n${err.stack}\nIn ${ctx.name}`, + ) + + if (ctx.name === "new_message") { + const t = await translatorFor(ctx.data.sender) + await client.replyText(ctx.data, t("error-unknown")) + } else if (ctx.name === "callback_query") { + const t = await translatorFor(ctx.data.user) + await client.editMessage({ + chatId: ctx.data.chat.id, + message: ctx.data.messageId, + text: t("error-unknown"), + }) + } else if (ctx.name === "chosen_inline_result") { + const t = await translatorFor(ctx.data.user) + if (ctx.data.messageId) + await client.editInlineMessage({ + messageId: ctx.data.messageId, + text: t("error-unknown"), + }) + } else if (ctx.name === "inline_query") { + const t = await translatorFor(ctx.data.user) + await client.answerInlineQuery(ctx.data, [ + { + id: randomUUID(), + type: "article", + title: "error", + description: t("error-unknown"), + }, + ]) + } + + return true +} diff --git a/src/telegram/bot/index.ts b/src/telegram/bot/index.ts new file mode 100644 index 0000000..355d063 --- /dev/null +++ b/src/telegram/bot/index.ts @@ -0,0 +1,32 @@ +import { Dispatcher } from "@mtcute/dispatcher" +import { downloadDp } from "#telegram/bot/download" +import { settingsDp } from "#telegram/bot/settings" +import { statsDp } from "#telegram/bot/stats" +import { createDispatcherErrorHandler } from "#telegram/bot/errors" +import { TelegramClient } from "@mtcute/node" +import { env } from "#telegram/helpers/env" +import { startDp } from "#telegram/bot/start" + +const bot = new TelegramClient({ + apiId: env.API_ID, + apiHash: env.API_HASH, + storage: "data/session", + updates: { + catchUp: true, + }, +}) + +const dp = Dispatcher.for(bot) + +dp.onError(createDispatcherErrorHandler(bot)) +dp.extend(startDp) +dp.extend(settingsDp) +dp.extend(statsDp) +dp.extend(downloadDp) + +export const startBot = async () => { + bot.run({ botToken: env.BOT_TOKEN }, async () => { + if (env.ERROR_CHAT_ID) + await bot.sendText(env.ERROR_CHAT_ID, "started bot :з") + }) +} diff --git a/src/telegram/bot/settings.ts b/src/telegram/bot/settings.ts new file mode 100644 index 0000000..ffc8d92 --- /dev/null +++ b/src/telegram/bot/settings.ts @@ -0,0 +1,34 @@ +import { Dispatcher, filters } from "@mtcute/dispatcher" +import { BotKeyboard, InlineKeyboardMarkup } from "@mtcute/node" +import { Settings, updateSetting } from "#core/data/settings" +import { evaluatorsFor, TextEvaluator } from "#telegram/helpers/text" +import { getPeerSettings, getSettingsMenu, SettingButton } from "#telegram/helpers/settings" + +export const settingsDp = Dispatcher.child() + +const settingsReplyMarkup = (e: TextEvaluator, settings: Settings): InlineKeyboardMarkup => + BotKeyboard.inline( + getSettingsMenu(settings).map(d => ([ + BotKeyboard.callback(`${e(d.title)}: ${e(d.value)}`, d.key), + ])), + ) + +settingsDp.onNewMessage(filters.command("settings"), async (msg) => { + const { t, e } = await evaluatorsFor(msg.sender) + const settings = await getPeerSettings(msg.sender) + await msg.replyText(t("settings-title"), { + replyMarkup: settingsReplyMarkup(e, settings), + }) +}) + +settingsDp.onAnyCallbackQuery(SettingButton.filter(), async (upd) => { + const settings = await getPeerSettings(upd.user) + const newSettings = await updateSetting(upd.match.setting, settings, upd.user.id) + + // We're getting evaluators AFTER the locale update + const { t, e } = await evaluatorsFor(upd.user) + await upd.editMessage({ + text: t("settings-title"), + replyMarkup: settingsReplyMarkup(e, newSettings ?? settings), + }) +}) diff --git a/src/telegram/bot/start.ts b/src/telegram/bot/start.ts new file mode 100644 index 0000000..69beabe --- /dev/null +++ b/src/telegram/bot/start.ts @@ -0,0 +1,8 @@ +import { Dispatcher, filters } from "@mtcute/dispatcher" +import { translatorFor } from "#telegram/helpers/i18n" + +export const startDp = Dispatcher.child() +startDp.onNewMessage(filters.command("start"), async (msg) => { + const t = await translatorFor(msg.sender) + await msg.replyText(t("start")) +}) diff --git a/src/telegram/bot/stats.ts b/src/telegram/bot/stats.ts new file mode 100644 index 0000000..91563b9 --- /dev/null +++ b/src/telegram/bot/stats.ts @@ -0,0 +1,18 @@ +import { Dispatcher, filters } from "@mtcute/dispatcher" +import { evaluatorsFor } from "#telegram/helpers/text" +import { getDownloadStats } from "#core/data/stats" + +export const statsDp = Dispatcher.child() + +statsDp.onNewMessage(filters.command("stats"), async (msg) => { + const { t } = await evaluatorsFor(msg.sender) + const count = await getDownloadStats() + await msg.replyText(t("stats-global", { count })) +}) + +statsDp.onNewMessage(filters.command("mystats"), async (msg) => { + const { t } = await evaluatorsFor(msg.sender) + const id = msg.sender.id + const count = await getDownloadStats(id) + await msg.replyText(t("stats-personal", { count })) +}) diff --git a/src/env.ts b/src/telegram/helpers/env.ts similarity index 90% rename from src/env.ts rename to src/telegram/helpers/env.ts index ffdc809..eb6a259 100644 --- a/src/env.ts +++ b/src/telegram/helpers/env.ts @@ -6,8 +6,9 @@ config() export const env = createEnv({ server: { + API_ID: z.coerce.number(), + API_HASH: z.string(), BOT_TOKEN: z.string(), - INLINE_FIX_CHAT_ID: z.coerce.number().int(), API_BASE_URL: z.string() .default("https://api.cobalt.tools/api") .transform(s => s.split(";")) diff --git a/src/telegram/helpers/handler.ts b/src/telegram/helpers/handler.ts new file mode 100644 index 0000000..880e9f3 --- /dev/null +++ b/src/telegram/helpers/handler.ts @@ -0,0 +1,44 @@ +import { ok, error, Result } from "#core/utils/result" +import { Text, translatable } from "#core/utils/text" +import { env } from "#telegram/helpers/env" +import type { InputMediaLike, Peer } from "@mtcute/node" +import mime from "mime-types" +import { CallbackDataBuilder } from "@mtcute/dispatcher" +import { finishRequest, MediaRequest, outputOptions } from "#core/data/request" +import { getPeerLocale } from "#telegram/helpers/i18n" + +export const OutputButton = new CallbackDataBuilder("dl", "output", "request") +export const getOutputSelectionMessage = (requestId: string) => ({ + image: env.SELECT_TYPE_PHOTO_URL, + caption: translatable("type-select-title"), + options: outputOptions.map(option => ({ + key: OutputButton.build({ request: requestId, output: option }), + name: translatable(`setting-output-${option}`), + })), +}) + +const getTelegramFileType = (filename?: string) => { + if (!filename) return "document" + + const mimeType = mime.lookup(filename) + if (!mimeType) return "document" + + if (mimeType.startsWith("video/")) return "video" + if (mimeType.startsWith("audio/")) return "audio" + return "document" +} + +export const handleMediaDownload = async ( + outputType: string, + request: MediaRequest | undefined, + peer: Peer, +): Promise> => { + if (!request) return error(translatable("error-request-not-found")) + const res = await finishRequest(outputType, request, env.API_BASE_URL, await getPeerLocale(peer)) + if (!res.success) return res + + return ok({ + ...res.result, + type: getTelegramFileType(res.result.fileName), + }) +} diff --git a/src/telegram/helpers/i18n.ts b/src/telegram/helpers/i18n.ts new file mode 100644 index 0000000..47dd9d7 --- /dev/null +++ b/src/telegram/helpers/i18n.ts @@ -0,0 +1,14 @@ +import type { Peer } from "@mtcute/node" +import { fallbackLocale, translate, TranslationParams } from "#core/utils/i18n" +import { getPeerSettings } from "#telegram/helpers/settings" + +export async function getPeerLocale(peer: Peer) { + const { languageOverride } = await getPeerSettings(peer) + return languageOverride ?? ("language" in peer ? peer.language : null) ?? fallbackLocale +} + +export type Translator = Awaited> +export async function translatorFor(peer: Peer) { + const locale = await getPeerLocale(peer) + return (key: string, params?: TranslationParams) => translate(locale, key, params) +} diff --git a/src/telegram/helpers/settings.ts b/src/telegram/helpers/settings.ts new file mode 100644 index 0000000..f391baf --- /dev/null +++ b/src/telegram/helpers/settings.ts @@ -0,0 +1,28 @@ +import { CallbackDataBuilder } from "@mtcute/dispatcher" +import { literal, translatable } from "#core/utils/text" +import { getSettings, settingI18n, Settings } from "#core/data/settings" +import { Peer } from "@mtcute/node" + +type SettingsEntries = [keyof Settings, Settings[keyof Settings]][] +export const SettingButton = new CallbackDataBuilder("setting", "setting") +export const getSettingsMenu = (settings: Settings) => { + return (Object.entries(settings) as SettingsEntries) + .map(([key, value]) => { + const i18nData = settingI18n[key] + const settingKey = `setting-${i18nData.key}` + const valueText = value === null + ? translatable(`${settingKey}-unset`) + : i18nData.mode === "translatable" + ? translatable(`${settingKey}-${value}`) + : literal(String(value)) + return { + title: translatable(settingKey), + value: valueText, + key: SettingButton.build({ setting: key }), + } + }) +} + +export const getPeerSettings = async (user: Peer) => { + return await getSettings(user.id) +} diff --git a/src/telegram/helpers/text.ts b/src/telegram/helpers/text.ts new file mode 100644 index 0000000..492c331 --- /dev/null +++ b/src/telegram/helpers/text.ts @@ -0,0 +1,21 @@ +import { Peer } from "@mtcute/node" +import { Text } from "#core/utils/text" +import { Translator, translatorFor } from "#telegram/helpers/i18n" + +export type TextEvaluator = (text: Text) => string +export function evaluateText(translator: Translator, text: Text): string { + if (text.type === "literal") return text.text + if (text.type === "translatable") return translator(text.key, text.params) + if (text.type === "compound") return text.content.map(t => evaluateText(translator, t)).join("") + return "" +} + +export type Evaluators = { + t: Translator, + e: TextEvaluator, +} +export async function evaluatorsFor(peer: Peer): Promise { + const t = await translatorFor(peer) + const e = (text: Text) => evaluateText(t, text) + return { t, e } +}