chore: clean up package dependencies and remove unused i18n generation script

Signed-off-by: Innei <tukon479@gmail.com>
This commit is contained in:
Innei 2025-07-09 00:23:51 +08:00
parent 084b9bd1a0
commit 8b37c5314f
No known key found for this signature in database
GPG Key ID: 0F62D33977F021F7
12 changed files with 33 additions and 753 deletions

View File

@ -1,5 +1,3 @@
import "dotenv/config"
import crypto from "node:crypto"
import fs, { readdirSync } from "node:fs"
import { cp, readdir } from "node:fs/promises"

View File

@ -30,7 +30,6 @@
"@sentry/electron": "6.8.0",
"@sindresorhus/slugify": "2.2.1",
"builder-util-runtime": "9.3.1",
"cookie-es": "2.0.0",
"electron-context-menu": "4.0.5",
"electron-log": "5.4.1",
"electron-squirrel-startup": "1.0.1",
@ -45,6 +44,7 @@
"msedge-tts": "2.0.0",
"node-machine-id": "1.1.12",
"ofetch": "1.4.1",
"pathe": "2.0.3",
"semver": "7.7.2",
"tar": "7.4.3",
"vscode-languagedetection": "npm:@vscode/vscode-languagedetection@1.0.22"

View File

@ -21,6 +21,7 @@
"@follow/store": "workspace:*",
"@follow/tracker": "workspace:*",
"@fontsource/sn-pro": "5.2.5",
"@hcaptcha/react-hcaptcha": "1.12.0",
"@headlessui/react": "2.2.4",
"@hookform/resolvers": "5.1.1",
"@lottiefiles/dotlottie-react": "0.14.2",
@ -47,6 +48,7 @@
"camelcase-keys": "9.1.3",
"clsx": "2.1.1",
"cmdk": "1.1.1",
"cookie-es": "2.0.0",
"dayjs": "1.11.13",
"dnum": "2.15.0",
"embla-carousel-react": "8.6.0",

View File

@ -1,4 +1,3 @@
// This file is auto-generated by scripts/generate-i18n-locale.ts
// DONT EDIT THIS FILE MANUALLY
const langs = ["en", "zh-CN", "zh-TW", "ja"] as const
export const currentSupportedLanguages = langs as readonly string[]

View File

@ -1,4 +1,3 @@
// This file is auto-generated by scripts/generate-i18n-locale.ts
// DONT EDIT THIS FILE MANUALLY
import en from "@locales/app/en.json"
import app_ja from "@locales/app/ja.json"

View File

@ -1,4 +1,3 @@
// This file is auto-generated by scripts/generate-i18n-locale.ts
// DONT EDIT THIS FILE MANUALLY
import en from "@locales/app/en.json"
import common_en from "@locales/common/en.json"

View File

@ -33,13 +33,7 @@
"start": "electron-vite preview",
"update:main-hash": "tsx plugins/vite/generate-main-hash.ts"
},
"dependencies": {
"@hcaptcha/react-hcaptcha": "1.12.0",
"cookie-es": "2.0.0",
"pathe": "2.0.3"
},
"devDependencies": {
"@clack/prompts": "0.11.0",
"@electron-forge/cli": "7.8.0",
"@electron-forge/maker-appx": "7.8.0",
"@electron-forge/maker-dmg": "7.8.0",
@ -69,7 +63,6 @@
"bufferutil": "4.0.9",
"code-inspector-plugin": "0.20.15",
"cssnano": "7.0.7",
"dotenv": "16.5.0",
"drizzle-orm": "0.44.2",
"electron": "37.2.0",
"electron-devtools-installer": "4.0.0",
@ -82,13 +75,13 @@
"html-minifier-terser": "7.2.0",
"js-yaml": "4.1.0",
"nbump": "2.1.3",
"pathe": "2.0.3",
"react": "19.0.0",
"react-dom": "19.0.0",
"tailwindcss-content-visibility": "1.0.2",
"tailwindcss-multi": "0.4.6",
"tar": "7.4.3",
"unplugin-ast": "0.15.0",
"utf-8-validate": "6.0.5",
"vite-bundle-analyzer": "1.0.0",
"vite-plugin-mkcert": "1.17.8",
"vite-plugin-pwa": "1.0.1",

View File

@ -1,4 +1,3 @@
// This file is auto-generated by scripts/generate-i18n-locale.ts
// DONT EDIT THIS FILE MANUALLY
const langs = ["en", "ja", "zh-CN", "zh-TW"] as const
export const currentSupportedLanguages = langs as readonly string[]

View File

@ -1,4 +1,3 @@
// This file is auto-generated by scripts/generate-i18n-locale.ts
// DONT EDIT THIS FILE MANUALLY
import common_en from "@locales/common/en.json"
import common_ja from "@locales/common/ja.json"

View File

@ -18,7 +18,6 @@
"depcheck": "npx depcheck --quiet",
"format": "prettier --write .",
"format:check": "prettier --check .",
"generator:i18n-template": "tsx scripts/generate-i18n-locale.ts",
"icons:sync": "tsx scripts/svg-to-rn.ts && prettier --write apps/mobile/src/icons/**/*.tsx && eslint --fix apps/mobile/src/icons/**/*.tsx",
"icons:update": "tsx scripts/update-icon.ts",
"lint": "pnpm run lint:tsl && eslint",

View File

@ -160,20 +160,7 @@ importers:
version: 3.2.4(@edge-runtime/vm@3.2.0)(@types/debug@4.1.12)(@types/node@24.0.10)(happy-dom@18.0.1)(jiti@2.4.2)(lightningcss@1.30.1)(terser@5.39.2)(tsx@4.20.3)(yaml@2.8.0)
apps/desktop:
dependencies:
'@hcaptcha/react-hcaptcha':
specifier: 1.12.0
version: 1.12.0(react-dom@19.0.0(react@19.0.0))(react@19.0.0)
cookie-es:
specifier: 2.0.0
version: 2.0.0
pathe:
specifier: 2.0.3
version: 2.0.3
devDependencies:
'@clack/prompts':
specifier: 0.11.0
version: 0.11.0
'@electron-forge/cli':
specifier: 7.8.0
version: 7.8.0(encoding@0.1.13)
@ -261,12 +248,9 @@ importers:
cssnano:
specifier: 7.0.7
version: 7.0.7(postcss@8.5.6)
dotenv:
specifier: 16.5.0
version: 16.5.0
drizzle-orm:
specifier: 0.44.2
version: 0.44.2(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(kysely@0.28.2)
version: 0.44.2(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)
electron:
specifier: 37.2.0
version: 37.2.0
@ -300,6 +284,9 @@ importers:
nbump:
specifier: 2.1.3
version: 2.1.3(conventional-commits-filter@5.0.0)
pathe:
specifier: 2.0.3
version: 2.0.3
react:
specifier: 19.0.0
version: 19.0.0
@ -318,9 +305,6 @@ importers:
unplugin-ast:
specifier: 0.15.0
version: 0.15.0
utf-8-validate:
specifier: 6.0.5
version: 6.0.5
vite-bundle-analyzer:
specifier: 1.0.0
version: 1.0.0
@ -366,9 +350,6 @@ importers:
builder-util-runtime:
specifier: 9.3.1
version: 9.3.1
cookie-es:
specifier: 2.0.0
version: 2.0.0
electron-context-menu:
specifier: 4.0.5
version: 4.0.5(patch_hash=15ed04a0d246eb9e701f47314b91328c64a8a7374914ad58b4053a3f84075fab)
@ -411,6 +392,9 @@ importers:
ofetch:
specifier: 1.4.1
version: 1.4.1
pathe:
specifier: 2.0.3
version: 2.0.3
semver:
specifier: 7.7.2
version: 7.7.2
@ -475,6 +459,9 @@ importers:
'@fontsource/sn-pro':
specifier: 5.2.5
version: 5.2.5
'@hcaptcha/react-hcaptcha':
specifier: 1.12.0
version: 1.12.0(react-dom@19.0.0(react@19.0.0))(react@19.0.0)
'@headlessui/react':
specifier: 2.2.4
version: 2.2.4(react-dom@19.0.0(react@19.0.0))(react@19.0.0)
@ -553,6 +540,9 @@ importers:
cmdk:
specifier: 1.1.1
version: 1.1.1(@types/react-dom@19.1.6(@types/react@19.1.8))(@types/react@19.1.8)(react-dom@19.0.0(react@19.0.0))(react@19.0.0)
cookie-es:
specifier: 2.0.0
version: 2.0.0
dayjs:
specifier: 1.11.13
version: 1.11.13
@ -2681,12 +2671,6 @@ packages:
'@clack/core@0.3.5':
resolution: {integrity: sha512-5cfhQNH+1VQ2xLQlmzXMqUoiaH0lRBq9/CLW9lTyMbuKLC3+xEK01tHVvyut++mLOn5urSHmkm6I0Lg9MaJSTQ==}
'@clack/core@0.5.0':
resolution: {integrity: sha512-p3y0FIOwaYRUPRcMO7+dlmLh8PSRcrjuTndsiA0WAFbWES0mLZlrjVoBRZ9DzkPFJZG6KGkJmoEAY0ZcVWTkow==}
'@clack/prompts@0.11.0':
resolution: {integrity: sha512-pMN5FcrEw9hUkZA4f+zLlzivQSeQf5dRGJjSUbvVYDLvpKCdQx5OaknvKzgbtXOizhP+SJJJjqEbOe55uKKfAw==}
'@clack/prompts@0.8.2':
resolution: {integrity: sha512-6b9Ab2UiZwJYA9iMyboYyW9yJvAO9V753ZhS+DHKEjZRKAxPPOb7MXXu84lsPFG+vZt6FRFniZ8rXi+zCIw4yQ==}
@ -16485,17 +16469,6 @@ snapshots:
picocolors: 1.1.1
sisteransi: 1.0.5
'@clack/core@0.5.0':
dependencies:
picocolors: 1.1.1
sisteransi: 1.0.5
'@clack/prompts@0.11.0':
dependencies:
'@clack/core': 0.5.0
picocolors: 1.1.1
sisteransi: 1.0.5
'@clack/prompts@0.8.2':
dependencies:
'@clack/core': 0.3.5
@ -17399,7 +17372,7 @@ snapshots:
dependencies:
uuid: 8.3.2
'@expo/cli@0.24.15(bufferutil@4.0.9)(graphql@16.8.1)(utf-8-validate@6.0.5)':
'@expo/cli@0.24.15(bufferutil@4.0.9)(graphql@16.8.1)':
dependencies:
'@0no-co/graphql.web': 1.1.2(graphql@16.8.1)
'@babel/runtime': 7.27.6
@ -17418,7 +17391,7 @@ snapshots:
'@expo/spawn-async': 1.7.2
'@expo/ws-tunnel': 1.0.6
'@expo/xcpretty': 4.3.2
'@react-native/dev-middleware': 0.79.4(bufferutil@4.0.9)(utf-8-validate@6.0.5)
'@react-native/dev-middleware': 0.79.4(bufferutil@4.0.9)
'@urql/core': 5.1.1(graphql@16.8.1)
'@urql/exchange-retry': 1.3.1(@urql/core@5.1.1(graphql@16.8.1))
accepts: 1.3.8
@ -17712,11 +17685,6 @@ snapshots:
transitivePeerDependencies:
- supports-color
'@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))':
dependencies:
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
optional: true
'@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))':
dependencies:
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)
@ -17892,13 +17860,6 @@ snapshots:
'@expo/timeago.js@1.0.0': {}
'@expo/vector-icons@14.1.0(expo-font@13.3.1(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)':
dependencies:
expo-font: 13.3.1(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)
react: 19.0.0
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
optional: true
'@expo/vector-icons@14.1.0(expo-font@13.3.1(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0)':
dependencies:
expo-font: 13.3.1(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react@19.0.0)
@ -20435,7 +20396,7 @@ snapshots:
'@react-native/community-cli-plugin@0.79.1(bufferutil@4.0.9)':
dependencies:
'@react-native/dev-middleware': 0.79.1(bufferutil@4.0.9)(utf-8-validate@6.0.5)
'@react-native/dev-middleware': 0.79.1(bufferutil@4.0.9)
chalk: 4.1.2
debug: 2.6.9
invariant: 2.2.4
@ -20448,27 +20409,11 @@ snapshots:
- supports-color
- utf-8-validate
'@react-native/community-cli-plugin@0.79.1(bufferutil@4.0.9)(utf-8-validate@6.0.5)':
dependencies:
'@react-native/dev-middleware': 0.79.1(bufferutil@4.0.9)(utf-8-validate@6.0.5)
chalk: 4.1.2
debug: 2.6.9
invariant: 2.2.4
metro: 0.82.4(bufferutil@4.0.9)(utf-8-validate@6.0.5)
metro-config: 0.82.4(bufferutil@4.0.9)(utf-8-validate@6.0.5)
metro-core: 0.82.4
semver: 7.7.2
transitivePeerDependencies:
- bufferutil
- supports-color
- utf-8-validate
optional: true
'@react-native/debugger-frontend@0.79.1': {}
'@react-native/debugger-frontend@0.79.4': {}
'@react-native/dev-middleware@0.79.1(bufferutil@4.0.9)(utf-8-validate@6.0.5)':
'@react-native/dev-middleware@0.79.1(bufferutil@4.0.9)':
dependencies:
'@isaacs/ttlcache': 1.4.1
'@react-native/debugger-frontend': 0.79.1
@ -20480,13 +20425,13 @@ snapshots:
nullthrows: 1.1.1
open: 7.4.2
serve-static: 1.16.2
ws: 6.2.3(bufferutil@4.0.9)(utf-8-validate@6.0.5)
ws: 6.2.3(bufferutil@4.0.9)
transitivePeerDependencies:
- bufferutil
- supports-color
- utf-8-validate
'@react-native/dev-middleware@0.79.4(bufferutil@4.0.9)(utf-8-validate@6.0.5)':
'@react-native/dev-middleware@0.79.4(bufferutil@4.0.9)':
dependencies:
'@isaacs/ttlcache': 1.4.1
'@react-native/debugger-frontend': 0.79.4
@ -20498,7 +20443,7 @@ snapshots:
nullthrows: 1.1.1
open: 7.4.2
serve-static: 1.16.2
ws: 6.2.3(bufferutil@4.0.9)(utf-8-validate@6.0.5)
ws: 6.2.3(bufferutil@4.0.9)
transitivePeerDependencies:
- bufferutil
- supports-color
@ -20518,16 +20463,6 @@ snapshots:
'@react-native/normalize-colors@0.79.4': {}
'@react-native/virtualized-lists@0.79.1(@types/react@19.1.8)(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)':
dependencies:
invariant: 2.2.4
nullthrows: 1.1.1
react: 19.0.0
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
optionalDependencies:
'@types/react': 19.1.8
optional: true
'@react-native/virtualized-lists@0.79.1(@types/react@19.1.8)(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0)':
dependencies:
invariant: 2.2.4
@ -23765,13 +23700,6 @@ snapshots:
transitivePeerDependencies:
- supports-color
drizzle-orm@0.44.2(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(kysely@0.28.2):
optionalDependencies:
'@opentelemetry/api': 1.9.0
'@types/pg': 8.6.1
expo-sqlite: 15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)
kysely: 0.28.2
drizzle-orm@0.44.2(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2):
optionalDependencies:
'@opentelemetry/api': 1.9.0
@ -24892,17 +24820,6 @@ snapshots:
dependencies:
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0)
expo-asset@11.1.5(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0):
dependencies:
'@expo/image-utils': 0.7.4
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5)
expo-constants: 17.1.6(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))
react: 19.0.0
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
transitivePeerDependencies:
- supports-color
optional: true
expo-asset@11.1.5(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0):
dependencies:
'@expo/image-utils': 0.7.4
@ -24938,16 +24855,6 @@ snapshots:
react: 19.0.0
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)
expo-constants@17.1.6(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)):
dependencies:
'@expo/config': 11.0.10
'@expo/env': 1.0.5
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5)
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
transitivePeerDependencies:
- supports-color
optional: true
expo-constants@17.1.6(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)):
dependencies:
'@expo/config': 11.0.10
@ -25006,24 +24913,11 @@ snapshots:
expo-eas-client@0.14.3: {}
expo-file-system@18.1.10(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)):
dependencies:
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5)
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
optional: true
expo-file-system@18.1.10(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)):
dependencies:
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0)
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)
expo-font@13.3.1(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0):
dependencies:
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5)
fontfaceobserver: 2.3.0
react: 19.0.0
optional: true
expo-font@13.3.1(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react@19.0.0):
dependencies:
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0)
@ -25058,12 +24952,6 @@ snapshots:
expo-json-utils@0.15.0: {}
expo-keep-awake@14.1.4(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0):
dependencies:
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5)
react: 19.0.0
optional: true
expo-keep-awake@14.1.4(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react@19.0.0):
dependencies:
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0)
@ -25148,14 +25036,6 @@ snapshots:
transitivePeerDependencies:
- supports-color
expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0):
dependencies:
await-lock: 2.2.2
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5)
react: 19.0.0
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
optional: true
expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0):
dependencies:
await-lock: 2.2.2
@ -25230,43 +25110,10 @@ snapshots:
expo: 53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0)
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)
expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5):
dependencies:
'@babel/runtime': 7.27.6
'@expo/cli': 0.24.15(bufferutil@4.0.9)(graphql@16.8.1)(utf-8-validate@6.0.5)
'@expo/config': 11.0.10
'@expo/config-plugins': 10.0.3
'@expo/fingerprint': 0.13.1
'@expo/metro-config': 0.20.15
'@expo/vector-icons': 14.1.0(expo-font@13.3.1(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)
babel-preset-expo: 13.2.1(@babel/core@7.28.0)
expo-asset: 11.1.5(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)
expo-constants: 17.1.6(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))
expo-file-system: 18.1.10(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))
expo-font: 13.3.1(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)
expo-keep-awake: 14.1.4(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)
expo-modules-autolinking: 2.1.12
expo-modules-core: 2.4.0
react: 19.0.0
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
react-native-edge-to-edge: 1.6.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)
whatwg-url-without-unicode: 8.0.0-3
optionalDependencies:
'@expo/metro-runtime': 5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))
react-native-webview: 13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)
transitivePeerDependencies:
- '@babel/core'
- babel-plugin-react-compiler
- bufferutil
- graphql
- supports-color
- utf-8-validate
optional: true
expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0):
dependencies:
'@babel/runtime': 7.27.6
'@expo/cli': 0.24.15(bufferutil@4.0.9)(graphql@16.8.1)(utf-8-validate@6.0.5)
'@expo/cli': 0.24.15(bufferutil@4.0.9)(graphql@16.8.1)
'@expo/config': 11.0.10
'@expo/config-plugins': 10.0.3
'@expo/fingerprint': 0.13.1
@ -27641,22 +27488,6 @@ snapshots:
- supports-color
- utf-8-validate
metro-config@0.82.4(bufferutil@4.0.9)(utf-8-validate@6.0.5):
dependencies:
connect: 3.7.0
cosmiconfig: 5.2.1
flow-enums-runtime: 0.0.6
jest-validate: 29.7.0
metro: 0.82.4(bufferutil@4.0.9)(utf-8-validate@6.0.5)
metro-cache: 0.82.4
metro-core: 0.82.4
metro-runtime: 0.82.4
transitivePeerDependencies:
- bufferutil
- supports-color
- utf-8-validate
optional: true
metro-core@0.82.4:
dependencies:
flow-enums-runtime: 0.0.6
@ -27748,27 +27579,6 @@ snapshots:
- supports-color
- utf-8-validate
metro-transform-worker@0.82.4(bufferutil@4.0.9)(utf-8-validate@6.0.5):
dependencies:
'@babel/core': 7.28.0
'@babel/generator': 7.28.0
'@babel/parser': 7.28.0
'@babel/types': 7.28.0
flow-enums-runtime: 0.0.6
metro: 0.82.4(bufferutil@4.0.9)(utf-8-validate@6.0.5)
metro-babel-transformer: 0.82.4
metro-cache: 0.82.4
metro-cache-key: 0.82.4
metro-minify-terser: 0.82.4
metro-source-map: 0.82.4
metro-transform-plugins: 0.82.4
nullthrows: 1.1.1
transitivePeerDependencies:
- bufferutil
- supports-color
- utf-8-validate
optional: true
metro@0.82.4(bufferutil@4.0.9):
dependencies:
'@babel/code-frame': 7.27.1
@ -27809,61 +27619,13 @@ snapshots:
serialize-error: 2.1.0
source-map: 0.5.7
throat: 5.0.0
ws: 7.5.10(bufferutil@4.0.9)(utf-8-validate@6.0.5)
ws: 7.5.10(bufferutil@4.0.9)
yargs: 17.7.2
transitivePeerDependencies:
- bufferutil
- supports-color
- utf-8-validate
metro@0.82.4(bufferutil@4.0.9)(utf-8-validate@6.0.5):
dependencies:
'@babel/code-frame': 7.27.1
'@babel/core': 7.28.0
'@babel/generator': 7.28.0
'@babel/parser': 7.28.0
'@babel/template': 7.27.2
'@babel/traverse': 7.28.0
'@babel/types': 7.28.0
accepts: 1.3.8
chalk: 4.1.2
ci-info: 2.0.0
connect: 3.7.0
debug: 4.4.1(supports-color@8.1.1)
error-stack-parser: 2.1.4
flow-enums-runtime: 0.0.6
graceful-fs: 4.2.11
hermes-parser: 0.28.1
image-size: 1.2.1
invariant: 2.2.4
jest-worker: 29.7.0
jsc-safe-url: 0.2.4
lodash.throttle: 4.1.1
metro-babel-transformer: 0.82.4
metro-cache: 0.82.4
metro-cache-key: 0.82.4
metro-config: 0.82.4(bufferutil@4.0.9)(utf-8-validate@6.0.5)
metro-core: 0.82.4
metro-file-map: 0.82.4
metro-resolver: 0.82.4
metro-runtime: 0.82.4
metro-source-map: 0.82.4
metro-symbolicate: 0.82.4
metro-transform-plugins: 0.82.4
metro-transform-worker: 0.82.4(bufferutil@4.0.9)(utf-8-validate@6.0.5)
mime-types: 2.1.35
nullthrows: 1.1.1
serialize-error: 2.1.0
source-map: 0.5.7
throat: 5.0.0
ws: 7.5.10(bufferutil@4.0.9)(utf-8-validate@6.0.5)
yargs: 17.7.2
transitivePeerDependencies:
- bufferutil
- supports-color
- utf-8-validate
optional: true
micromark-core-commonmark@2.0.3:
dependencies:
decode-named-character-reference: 1.1.0
@ -29363,10 +29125,10 @@ snapshots:
blurhash: 2.0.5
react: 19.0.0
react-devtools-core@6.1.2(bufferutil@4.0.9)(utf-8-validate@6.0.5):
react-devtools-core@6.1.2(bufferutil@4.0.9):
dependencies:
shell-quote: 1.8.2
ws: 7.5.10(bufferutil@4.0.9)(utf-8-validate@6.0.5)
ws: 7.5.10(bufferutil@4.0.9)
transitivePeerDependencies:
- bufferutil
- utf-8-validate
@ -29466,12 +29228,6 @@ snapshots:
dependencies:
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)
react-native-edge-to-edge@1.6.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0):
dependencies:
react: 19.0.0
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
optional: true
react-native-edge-to-edge@1.6.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0):
dependencies:
react: 19.0.0
@ -29612,14 +29368,6 @@ snapshots:
transitivePeerDependencies:
- encoding
react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0):
dependencies:
escape-string-regexp: 4.0.0
invariant: 2.2.4
react: 19.0.0
react-native: 0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5)
optional: true
react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0):
dependencies:
escape-string-regexp: 4.0.0
@ -29657,14 +29405,14 @@ snapshots:
pretty-format: 29.7.0
promise: 8.3.0
react: 19.0.0
react-devtools-core: 6.1.2(bufferutil@4.0.9)(utf-8-validate@6.0.5)
react-devtools-core: 6.1.2(bufferutil@4.0.9)
react-refresh: 0.14.2
regenerator-runtime: 0.13.11
scheduler: 0.25.0
semver: 7.7.2
stacktrace-parser: 0.1.11
whatwg-fetch: 3.6.20
ws: 6.2.3(bufferutil@4.0.9)(utf-8-validate@6.0.5)
ws: 6.2.3(bufferutil@4.0.9)
yargs: 17.7.2
optionalDependencies:
'@types/react': 19.1.8
@ -29675,55 +29423,6 @@ snapshots:
- supports-color
- utf-8-validate
react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5):
dependencies:
'@jest/create-cache-key-function': 29.7.0
'@react-native/assets-registry': 0.79.1
'@react-native/codegen': 0.79.1(@babel/core@7.28.0)
'@react-native/community-cli-plugin': 0.79.1(bufferutil@4.0.9)(utf-8-validate@6.0.5)
'@react-native/gradle-plugin': 0.79.1
'@react-native/js-polyfills': 0.79.1
'@react-native/normalize-colors': 0.79.1
'@react-native/virtualized-lists': 0.79.1(@types/react@19.1.8)(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)(utf-8-validate@6.0.5))(react@19.0.0)
abort-controller: 3.0.0
anser: 1.4.10
ansi-regex: 5.0.1
babel-jest: 29.7.0(@babel/core@7.28.0)
babel-plugin-syntax-hermes-parser: 0.25.1
base64-js: 1.5.1
chalk: 4.1.2
commander: 12.1.0
event-target-shim: 5.0.1
flow-enums-runtime: 0.0.6
glob: 7.2.3
invariant: 2.2.4
jest-environment-node: 29.7.0
memoize-one: 5.2.1
metro-runtime: 0.82.4
metro-source-map: 0.82.4
nullthrows: 1.1.1
pretty-format: 29.7.0
promise: 8.3.0
react: 19.0.0
react-devtools-core: 6.1.2(bufferutil@4.0.9)(utf-8-validate@6.0.5)
react-refresh: 0.14.2
regenerator-runtime: 0.13.11
scheduler: 0.25.0
semver: 7.7.2
stacktrace-parser: 0.1.11
whatwg-fetch: 3.6.20
ws: 6.2.3(bufferutil@4.0.9)(utf-8-validate@6.0.5)
yargs: 17.7.2
optionalDependencies:
'@types/react': 19.1.8
transitivePeerDependencies:
- '@babel/core'
- '@react-native-community/cli'
- bufferutil
- supports-color
- utf-8-validate
optional: true
react-photo-view@1.2.7(react-dom@19.0.0(react@19.0.0))(react@19.0.0):
dependencies:
react: 19.0.0
@ -31713,6 +31412,7 @@ snapshots:
utf-8-validate@6.0.5:
dependencies:
node-gyp-build: 4.8.4
optional: true
utf8-byte-length@1.0.5: {}
@ -32218,17 +31918,15 @@ snapshots:
imurmurhash: 0.1.4
signal-exit: 3.0.7
ws@6.2.3(bufferutil@4.0.9)(utf-8-validate@6.0.5):
ws@6.2.3(bufferutil@4.0.9):
dependencies:
async-limiter: 1.0.1
optionalDependencies:
bufferutil: 4.0.9
utf-8-validate: 6.0.5
ws@7.5.10(bufferutil@4.0.9)(utf-8-validate@6.0.5):
ws@7.5.10(bufferutil@4.0.9):
optionalDependencies:
bufferutil: 4.0.9
utf-8-validate: 6.0.5
ws@8.18.2(bufferutil@4.0.9)(utf-8-validate@6.0.5):
optionalDependencies:

View File

@ -1,405 +0,0 @@
import { execSync } from "node:child_process"
import { readdirSync, readFileSync, writeFileSync } from "node:fs"
import { fileURLToPath } from "node:url"
import { intro, outro, select } from "@clack/prompts"
import path, { dirname } from "pathe"
import color from "picocolors"
import * as ts from "typescript"
const locales = [
"af",
"am",
"ar-DZ",
"ar-IQ",
"ar-KW",
"ar-LY",
"ar-MA",
"ar-SA",
"ar-TN",
"az",
"be",
"bg",
"bi",
"bm",
"bn-BD",
"bn",
"bo",
"br",
"bs",
"ca",
"cs",
"cv",
"cy",
"da-AT",
"da-CH",
"da",
"dv",
"el",
"en-AU",
"en-CA",
"en-GB",
"en-IE",
"en-IL",
"en-IN",
"en-NZ",
"en-SG",
"en-TT",
"eo",
"es-DO",
"es-MX",
"es-PR",
"es-US",
"es",
"et",
"eu",
"fa",
"fi",
"fo",
"fr-CA",
"fr-CH",
"fr",
"fy",
"ga",
"gd",
"gl",
"gom-LATN",
"gu",
"he",
"hi",
"hr",
"ht",
"hu",
"hy-AM",
"id",
"is",
"it-CH",
"it",
"ja",
"jv",
"ka",
"kk",
"km",
"kn",
"ko",
"ku",
"ky",
"lb",
"lo",
"lt",
"lv",
"me",
"mi",
"mk",
"ml",
"mn",
"mr",
"ms-MY",
"ms",
"mt",
"my",
"nb",
"ne",
"nl-BE",
"nl",
"oc-LNC",
"pa-IN",
"pl",
"pt-BR",
"pt",
"rn",
"ro",
"ru",
"sd",
"se",
"si",
"sk",
"sl",
"sq",
"sr-CYRL",
"sr",
"ss",
"sv-FI",
"sv",
"sw",
"ta",
"te",
"tet",
"tg",
"th",
"tk",
"tl-PH",
"tlh",
"tr",
"tzl",
"tzm-LATN",
"tzm",
"ug-CN",
"uk",
"ur",
"uz-LATN",
"uz",
"vi",
"x-PSEUDO",
"yo",
"zh-CN",
"zh-HK",
"zh-TW",
"zh",
]
async function selectLocale(): Promise<string> {
intro(color.blue("Locale Selection"))
const selectedLocale = await select({
message: "Select a locale:",
options: locales.map((locale) => ({ value: locale, label: locale })),
maxItems: 10,
})
if (typeof selectedLocale !== "string") {
throw new TypeError("No locale selected")
}
return selectedLocale
}
const __dirname = dirname(fileURLToPath(import.meta.url))
const LOCALE_DIR = path.resolve(__dirname, "../locales")
const CONFIG_DIR = path.resolve(__dirname, "../apps/desktop/src/renderer/src/@types")
async function main() {
const selectedLocale = await selectLocale()
outro(`You selected: ${color.green(selectedLocale)}`)
const readdirLocales = readdirSync(LOCALE_DIR)
for (const ns of readdirLocales) {
const isExistResource = readdirSync(path.resolve(LOCALE_DIR, ns)).includes(
`${selectedLocale}.json`,
)
if (!isExistResource) {
// Create new resource file, write a empty json
writeFileSync(path.resolve(LOCALE_DIR, ns, `${selectedLocale}.json`), "{}")
}
}
// Update config file
const defaultResourceFilePath = path.resolve(CONFIG_DIR, "default-resource.ts")
const defaultResourceFileContent = readFileSync(defaultResourceFilePath, "utf8")
const sourceFile = ts.createSourceFile(
defaultResourceFilePath,
defaultResourceFileContent,
ts.ScriptTarget.Latest,
true,
)
const updatedContent = updateDefaultResourceFile(sourceFile, selectedLocale)
if (updatedContent !== defaultResourceFileContent) {
writeFileSync(defaultResourceFilePath, updatedContent)
console.info(`Updated ${defaultResourceFilePath} with new locale: ${selectedLocale}`)
} else {
console.info(`Locale ${selectedLocale} already exists in default-resource.ts`)
}
// Update constants file
const constantsFilePath = path.resolve(CONFIG_DIR, "constants.ts")
const constantsFileContent = readFileSync(constantsFilePath, "utf8")
const constantsSourceFile = ts.createSourceFile(
constantsFilePath,
constantsFileContent,
ts.ScriptTarget.Latest,
true,
)
const updatedConstantsContent = updateConstantsFile(constantsSourceFile, selectedLocale)
if (updatedConstantsContent !== constantsFileContent) {
writeFileSync(constantsFilePath, updatedConstantsContent)
console.info(`Updated ${constantsFilePath} with new locale: ${selectedLocale}`)
} else {
console.info(`Locale ${selectedLocale} already exists in constants.ts`)
}
// format these files
execSync(`npx prettier --write ${defaultResourceFilePath} ${constantsFilePath}`)
console.info("Done!")
console.info("Please open your editor and fill in the missing translations.")
console.info(`Resources: ${color.green("locales/")}${color.green(selectedLocale)}`)
}
function updateDefaultResourceFile(sourceFile: ts.SourceFile, locale: string): string {
const printer = ts.createPrinter({ newLine: ts.NewLineKind.LineFeed })
const result = ts.transform(sourceFile, [
(context) => (rootNode) => {
let importsAdded = false
function visit(node: ts.Node): ts.Node {
if (ts.isImportDeclaration(node) && !importsAdded) {
const newImports = [
createImportDeclaration(
`lang_${locale.replace("-", "")}`,
`@locales/lang/${locale}.json`,
),
createImportDeclaration(
`common_${locale.replace("-", "")}`,
`@locales/common/${locale}.json`,
),
]
importsAdded = true
return [node, ...newImports] as unknown as ts.Node
}
if (
ts.isVariableDeclaration(node) &&
ts.isIdentifier(node.name) &&
node.name.text === "defaultResources" &&
node.initializer &&
ts.isObjectLiteralExpression(node.initializer)
) {
const existingLocale = node.initializer.properties.find(
(prop) => ts.isPropertyAssignment(prop) && prop.name.getText() === `"${locale}"`,
)
if (existingLocale) {
return node
}
const newProperties = [
...node.initializer.properties,
ts.factory.createPropertyAssignment(
ts.factory.createStringLiteral(locale),
ts.factory.createObjectLiteralExpression([
ts.factory.createPropertyAssignment(
"lang",
ts.factory.createIdentifier(`lang_${locale.replace("-", "")}`),
),
ts.factory.createPropertyAssignment(
"common",
ts.factory.createIdentifier(`common_${locale.replace("-", "")}`),
),
]),
),
]
return ts.factory.updateVariableDeclaration(
node,
node.name,
node.exclamationToken,
node.type,
ts.factory.createObjectLiteralExpression(newProperties, true),
)
}
return ts.visitEachChild(node, visit, context)
}
return ts.visitNode(rootNode, visit) as ts.SourceFile
},
])
return printer.printFile(result.transformed[0] as ts.SourceFile)
}
function createImportDeclaration(identifier: string, path: string): ts.ImportDeclaration {
return ts.factory.createImportDeclaration(
undefined,
ts.factory.createImportClause(false, ts.factory.createIdentifier(identifier), void 0),
ts.factory.createStringLiteral(path),
)
}
function updateConstantsFile(sourceFile: ts.SourceFile, locale: string): string {
const printer = ts.createPrinter({ newLine: ts.NewLineKind.LineFeed })
const result = ts.transform(sourceFile, [
(context) => (rootNode) => {
function visit(node: ts.Node): ts.Node {
if (ts.isVariableDeclaration(node) && ts.isIdentifier(node.name)) {
if (node.name.text === "currentSupportedLanguages") {
return updateLangsArray(node, locale)
}
if (node.name.text === "dayjsLocaleImportMap") {
return updateDayjsLocaleImportMap(node, locale)
}
}
return ts.visitEachChild(node, visit, context)
}
return ts.visitNode(rootNode, visit) as ts.SourceFile
},
])
return printer.printFile(result.transformed[0] as ts.SourceFile)
}
function updateLangsArray(node: ts.VariableDeclaration, locale: string): ts.VariableDeclaration {
if (node.initializer && ts.isArrayLiteralExpression(node.initializer)) {
const existingElements = node.initializer.elements
if (!existingElements.some((el) => ts.isStringLiteral(el) && el.text === locale)) {
const newElements = [...existingElements, ts.factory.createStringLiteral(locale)]
const newInitializer = ts.factory.createArrayLiteralExpression(newElements, true)
return ts.factory.updateVariableDeclaration(
node,
node.name,
node.exclamationToken,
node.type,
newInitializer,
)
}
}
return node
}
function updateDayjsLocaleImportMap(
node: ts.VariableDeclaration,
locale: string,
): ts.VariableDeclaration {
if (node.initializer && ts.isObjectLiteralExpression(node.initializer)) {
const existingProperties = node.initializer.properties
if (
!existingProperties.some(
(prop) => ts.isPropertyAssignment(prop) && prop.name.getText() === `["${locale}"]`,
)
) {
const newProperty = ts.factory.createPropertyAssignment(
ts.factory.createComputedPropertyName(ts.factory.createStringLiteral(locale)),
ts.factory.createArrayLiteralExpression([
ts.factory.createStringLiteral(locale.toLowerCase()),
ts.factory.createArrowFunction(
undefined,
undefined,
[],
undefined,
ts.factory.createToken(ts.SyntaxKind.EqualsGreaterThanToken),
ts.factory.createCallExpression(ts.factory.createIdentifier("import"), undefined, [
ts.factory.createStringLiteral(`dayjs/locale/${locale.toLowerCase()}`),
]),
),
]),
)
const newProperties = [...existingProperties, newProperty]
return ts.factory.updateVariableDeclaration(
node,
node.name,
node.exclamationToken,
node.type,
ts.factory.createObjectLiteralExpression(newProperties, true),
)
}
}
return node
}
main().catch(console.error)