diff --git a/.clinerules b/.clinerules deleted file mode 100644 index 1063fcd..0000000 --- a/.clinerules +++ /dev/null @@ -1,53 +0,0 @@ -# Cursor Rules - -- When merging tailwind classes, use the `cn` function. -- When using Tailwind and you need to merge classes use the `cn` function if avilable. -- We use Tailwind 4 (the latest version), make sure to not use outdated classes. -- Instead of using the syntax`Array`, use `T[]`. -- Use TypeScript `type` over `interface`. -- You are forbiddent o add comments unless explicitly stated by the user. -- Avoid sending JavaScript to the client. The JS send should be optional. -- In prisma preffer `select` over `include` when making queries. -- Import the types from prisma instead of hardcoding duplicates. -- Avoid duplicating similar html code, and parametrize it when possible or create separate components. -- Remember to check the prisma schema when doing things related to the database. -- Avoid hardcoding enums from the database, import them from prisma. -- Avoid using client-side JavaScript as much as possible. And if it has to be done, make it optional. -- The admin pages can use client-side JavaScript. -- Keep README.md in sync with new capabilities. -- The package manager is npm. -- For icons use the `Icon` component from `astro-icon/components`. -- For icons use the Remix Icon library preferably. -- Use the `Image` component from `astro:assets` for images. -- Use the `zod` library for schema validation. -- In the astro actions return, don't return success: true, or similar, just return an object with the newly created/edited objects or nothing. -- When adding actions, don't create and export a new variable called actions. Notice that Astro already provides that variable from `import { actions } from 'astro:actions'`. So just add the new actions to the `server` variable in `web/src/actions/index.ts` and that's it. -- Don't forget that the astro files have thre dashes (`---`) at the begining of the file and where the server js ends. I noticed that sometimes you forget them. -- The admin actions go into a separate folder. -- In Actro actions when throwing errors use ActionError. -- @deprecated Don't import this object, use {@link actions} instead, like: `import { actions } from 'astro:actions'`. Example: - - ```ts - import { actions } from "astro:actions"; /* CORRECT */ - import { server } from "~/actions"; /* WRONG!!!! DON'T DO THIS */ - import { adminAttributeActions } from "~/actions/admin/attribute.ts"; /* WRONG!!!! DON'T DO THIS */ - - const result = Astro.getActionResult(actions.admin.attribute.create); - ``` - -- Always use Astro actions instead of with API routes or `if (Astro.request.method === "POST")`. -- When adding clientside js do it with HTMX. -- When adding HTMX, the layout component BaseLayout accepts a prop htmx to load it in that page. No need to use a cdn. -- When redirecting to login use the `makeLoginUrl` function from web/src/lib/redirectUrls.ts - - ```ts - function makeLoginUrl( - currentUrl: URL, - options: { - redirect?: URL | string | null; - error?: string | null; - logout?: boolean; - message?: string | null; - } = {} - ); - ``` diff --git a/.cursorrules b/.cursorrules deleted file mode 100644 index 41c5415..0000000 --- a/.cursorrules +++ /dev/null @@ -1,307 +0,0 @@ -# Cursor Rules - -- When merging tailwind classes, use the `cn` function. -- When using Tailwind and you need to merge classes use the `cn` function if avilable. -- We use Tailwind 4 (the latest version), make sure to not use outdated classes. -- Instead of using the syntax`Array`, use `T[]`. -- Use TypeScript `type` over `interface`. -- You are forbiddent o add comments unless explicitly stated by the user. -- Avoid sending JavaScript to the client. The JS send should be optional. -- In prisma preffer `select` over `include` when making queries. -- Import the types from prisma instead of hardcoding duplicates. -- Avoid duplicating similar html code, and parametrize it when possible or create separate components. -- Remember to check the prisma schema when doing things related to the database. -- Avoid hardcoding enums from the database, import them from prisma. -- Avoid using client-side JavaScript as much as possible. And if it has to be done, make it optional. -- The admin pages can use client-side JavaScript. -- Keep README.md in sync with new capabilities. -- The package manager is npm. -- For icons use the `Icon` component from `astro-icon/components`. -- For icons use the Remix Icon library preferably. -- Use the `Image` component from `astro:assets` for images. -- Use the `zod` library for schema validation. -- In the astro actions return, don't return success: true, or similar, just return an object with the newly created/edited objects or nothing. -- When adding actions, don't create and export a new variable called actions. Notice that Astro already provides that variable from `import { actions } from 'astro:actions'`. So just add the new actions to the `server` variable in `web/src/actions/index.ts` and that's it. -- Don't forget that the astro files have three dashes (`---`) at the begining of the file and where the server js ends. I noticed that sometimes you forget them. -- The admin actions go into a separate folder. -- In Actro actions when throwing errors use ActionError. -- @deprecated Don't import this object, use {@link actions} instead, like: `import { actions } from 'astro:actions'`. Example: - - ```ts - import { actions } from 'astro:actions'; /* CORRECT */ - import { server } from '~/actions'; /* WRONG!!!! DON'T DO THIS */ - import { adminAttributeActions } from '~/actions/admin/attribute.ts'; /* WRONG!!!! DON'T DO THIS */ - - const result = Astro.getActionResult(actions.admin.attribute.create); - ``` - -- Always use Astro actions instead of with API routes or `if (Astro.request.method === "POST")`. -- When adding clientside js do it with HTMX. -- When adding HTMX, the layout component BaseLayout accepts a prop htmx to load it in that page. No need to use a cdn. -- When redirecting to login use the `makeLoginUrl` function from web/src/lib/redirectUrls.ts and if the link is for an `` tag, use the `data-astro-reload` attribute. - - ```ts - function makeLoginUrl( - currentUrl: URL, - options: { - redirect?: URL | string | null; - error?: string | null; - logout?: boolean; - message?: string | null; - } = {} - ); - ``` - -- When adding client scripts remember to use the event `astro:page-load`, `querySelectorAll` and add an explanation comment, like so: - - ```tsx - - ``` - -- When creating forms, we already have utilities, components and established design patterns. Follow this example: - - ```astro - --- - import { actions, isInputError } from 'astro:actions' - import { z } from 'astro:content' - - import Captcha from '../../components/Captcha.astro' - import InputCardGroup from '../../components/InputCardGroup.astro' - import InputCheckboxGroup from '../../components/InputCheckboxGroup.astro' - import InputHoneypotTrap from '../../components/InputHoneypotTrap.astro' - import InputImageFile from '../../components/InputImageFile.astro' - import InputSubmitButton from '../../components/InputSubmitButton.astro' - import InputText from '../../components/InputText.astro' - import InputTextArea from '../../components/InputTextArea.astro' - import { kycLevels } from '../../constants/kycLevels' - import BaseLayout from '../../layouts/BaseLayout.astro' - import { zodParseQueryParamsStoringErrors } from '../../lib/parseUrlFilters' - import { prisma } from '../../lib/prisma' - import { makeLoginUrl } from '../../lib/redirectUrls' - - const user = Astro.locals.user - if (!user) { - return Astro.redirect(makeLoginUrl(Astro.url, { message: 'Login to suggest a new service' })) - } - - const result = Astro.getActionResult(actions.serviceSuggestion.editService) - if (result && !result.error) { - return Astro.redirect(`/service-suggestion/${result.data.serviceSuggestion.id}`) - } - const inputErrors = isInputError(result?.error) ? result.error.fields : {} - - const { data: params } = zodParseQueryParamsStoringErrors( - { - serviceId: z.coerce.number().int().positive(), - notes: z.string().default(''), - }, - Astro - ) - - if (!params.serviceId) return Astro.rewrite('/404') - - const service = await Astro.locals.banners.try( - 'Failed to fetch service', - async () => - prisma.service.findUnique({ - select: { - id: true, - name: true, - slug: true, - description: true, - overallScore: true, - kycLevel: true, - imageUrl: true, - verificationStatus: true, - acceptedCurrencies: true, - categories: { - select: { - name: true, - icon: true, - }, - }, - }, - where: { id: params.serviceId }, - }), - null - ) - - if (!service) return Astro.rewrite('/404') - --- - - -

Edit service

- -
- - - - - ({ - label: kycLevel.name, - value: kycLevel.id.toString(), - icon: kycLevel.icon, - description: `${kycLevel.description}\n\n_KYC Level ${kycLevel.value}/5_`, - }))} - iconSize="md" - cardSize="md" - required - error={inputErrors.kycLevel} - /> - - ({ - label: category.name, - value: category.id.toString(), - icon: category.icon, - }))} - error={inputErrors.categories} - /> - - - - - - - - - - - -
- ``` - -- Don't use the `web/src/pages/admin` pages as example unless explicitly stated or you're creating/editing an admin page. -- When creating constants or enums, use the `makeHelpersForOptions` function like in this example. Save the file in the `web/src/constants` folder. Note that it's not necessary to use all the options the example has, just the ones you need. - -```ts -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions'; -import { transformCase } from '../lib/strings'; - -import type { AttributeType } from '@prisma/client'; - -type AttributeTypeInfo = { - value: T; - slug: string; - label: string; - icon: string; - order: number; - classNames: { - text: string; - icon: string; - }; -}; - -export const { - dataArray: attributeTypes, - dataObject: attributeTypesById, - getFn: getAttributeTypeInfo, - getFnSlug: getAttributeTypeInfoBySlug, - zodEnumBySlug: attributeTypesZodEnumBySlug, - zodEnumById: attributeTypesZodEnumById, - keyToSlug: attributeTypeIdToSlug, - slugToKey: attributeTypeSlugToId, -} = makeHelpersForOptions( - 'value', - (value): AttributeTypeInfo => ({ - value, - slug: value ? value.toLowerCase() : '', - label: value - ? transformCase(value.replace('_', ' '), 'title') - : String(value), - icon: 'ri:question-line', - order: Infinity, - classNames: { - text: 'text-current/60', - icon: 'text-current/60', - }, - }), - [ - { - value: 'BAD', - slug: 'bad', - label: 'Bad', - icon: 'ri:close-line', - order: 1, - classNames: { - text: 'text-red-200', - icon: 'text-red-400', - }, - }, - { - value: 'WARNING', - slug: 'warning', - label: 'Warning', - icon: 'ri:alert-line', - order: 2, - classNames: { - text: 'text-yellow-200', - icon: 'text-yellow-400', - }, - }, - { - value: 'GOOD', - slug: 'good', - label: 'Good', - icon: 'ri:check-line', - order: 3, - classNames: { - text: 'text-green-200', - icon: 'text-green-400', - }, - }, - { - value: 'INFO', - slug: 'info', - label: 'Info', - icon: 'ri:information-line', - order: 4, - classNames: { - text: 'text-blue-200', - icon: 'text-blue-400', - }, - }, - ] as const satisfies AttributeTypeInfo[] -); -``` diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 54e225b..0000000 --- a/.gitignore +++ /dev/null @@ -1,15 +0,0 @@ -local_data/ -TODO.md -webhook -docker-compose.override.yml - -web/public/uploads/ -.env -backups/ -loki* -grafana* -dump*.sql -*.dump -*.log -*.bak -migrate.py \ No newline at end of file diff --git a/.npmrc b/.npmrc deleted file mode 100644 index cffe8cd..0000000 --- a/.npmrc +++ /dev/null @@ -1 +0,0 @@ -save-exact=true diff --git a/.platform/README.md b/.platform/README.md deleted file mode 100644 index 615c72b..0000000 --- a/.platform/README.md +++ /dev/null @@ -1,64 +0,0 @@ -# .platform Hooks - -This directory contains deployment hooks that are executed during the deployment process. The structure follows AWS Elastic Beanstalk's `.platform` hooks pattern, although we are not using AWS we think it is a good practice to use this standard. - -## Directory Structure - -``` -.platform/ -├── hooks/ -│ ├── predeploy/ # Scripts executed before staging deployment -│ └── postdeploy/ # Scripts executed after successful production deployment -``` - -## Hook Execution - -- Scripts in each hook directory are executed in alphabetical order -- If any hook fails (returns non-zero), the deployment process is aborted -- Hook failures are reported through the notification system - -## Available Hooks - -### Predeploy Hooks - -Located in `.platform/hooks/predeploy/` - -- Executed before the staging deployment starts -- Use for tasks like: - - Environment validation - - Resource preparation - - Database migrations - - Asset compilation - -### Postdeploy Hooks - -Located in `.platform/hooks/postdeploy/` - -- Executed after successful production deployment -- Use for tasks like: - - Cache warming - - Service notifications - - Cleanup operations - - Import triggers (current implementation) - -## Example Hook - -```bash -#!/bin/bash -# .platform/hooks/postdeploy/01_import_triggers.sh - -cd ../../../ -just import-triggers -``` - -## Environment - -Hooks have access to all environment variables available to the deployment script, including: - -- `HOOK_PUSHER` -- `HOOK_MESSAGE` -- `GITEA_USERNAME` -- `GITEA_TOKEN` -- `GITEA_SERVER` -- `GITEA_REPO_USERNAME` -- `GITEA_REPO_NAME` diff --git a/.platform/hooks/postdeploy/01_import_triggers.sh b/.platform/hooks/postdeploy/01_import_triggers.sh deleted file mode 100644 index 4f25622..0000000 --- a/.platform/hooks/postdeploy/01_import_triggers.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/bash - -pwd -just import-triggers \ No newline at end of file diff --git a/.vscode/extensions.json b/.vscode/extensions.json deleted file mode 100644 index 908dc5d..0000000 --- a/.vscode/extensions.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "recommendations": [ - "astro-build.astro-vscode", - "esbenp.prettier-vscode", - "dbaeumer.vscode-eslint", - "davidanson.vscode-markdownlint", - "golang.go", - "bradlc.vscode-tailwindcss", - "craigrbroughton.htmx-attributes", - "nefrob.vscode-just-syntax" - ], - "unwantedRecommendations": [] -} diff --git a/.vscode/launch.json b/.vscode/launch.json deleted file mode 100644 index 51fbc35..0000000 --- a/.vscode/launch.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "version": "0.2.0", - "configurations": [ - { - "name": "npm run dev", - "request": "launch", - "type": "node-terminal", - "cwd": "${workspaceFolder}/web", - "command": "npm run dev" - } - ] -} diff --git a/.vscode/settings.json b/.vscode/settings.json deleted file mode 100644 index 0adfe61..0000000 --- a/.vscode/settings.json +++ /dev/null @@ -1,60 +0,0 @@ -{ - "editor.formatOnSave": true, - "editor.tabSize": 2, - "editor.insertSpaces": true, - "editor.wordWrap": "wordWrapColumn", - "editor.wordWrapColumn": 110, - "editor.rulers": [110], - "prettier.documentSelectors": ["**/*.astro"], - "[javascript]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[typescript]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[astro]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[markdown]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[json]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[yaml]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[prisma]": { - "editor.wordWrap": "off" - }, - "files.exclude": { - "**/node_modules": true - }, - "eslint.validate": [ - "javascript", - "javascriptreact", - "astro", - "typescript", - "typescriptreact" - ], - "editor.codeActionsOnSave": { - "source.fixAll": "explicit", - "source.organizeImports": "never", - "source.fixAll.eslint": "explicit" - }, - "eslint.enable": true, - "typescript.preferences.importModuleSpecifier": "non-relative", - "debug.javascript.autoAttachFilter": "always", - "tailwindCSS.classAttributes": [ - "class", - "className", - "classNames", - "ngClass", - "class:list", - ".*classNames?" - ], - "tailwindCSS.classFunctions": ["tv", "cn"], - "tailwindCSS.experimental.classRegex": [ - ["([\"'`][^\"'`]*.*?[\"'`])", "[\"'`]([^\"'`]*).*?[\"'`]"] - ] -} diff --git a/.vscode/tasks.json b/.vscode/tasks.json deleted file mode 100644 index 0bddd6f..0000000 --- a/.vscode/tasks.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "version": "2.0.0", - "tasks": [ - { - "label": "install", - "type": "shell", - "command": "cd web && npm i", - "icon": { - "id": "package", - "color": "terminal.ansiGreen" - }, - "detail": "Install npm dependencies" - }, - { - "label": "web", - "type": "shell", - "command": "cd web && npm run dev", - "icon": { - "id": "browser", - "color": "terminal.ansiBlue" - }, - "detail": "Start web development server", - "problemMatcher": ["$tsc-watch"], - "isBackground": true - }, - { - "label": "db", - "type": "shell", - "command": "docker compose -f docker-compose.yml -f docker-compose.dev.yml up database redis db-admin", - "runOptions": { - "runOn": "folderOpen" - }, - "icon": { - "id": "database", - "color": "terminal.ansiYellow" - }, - "detail": "Start database services" - }, - { - "label": "Install and run", - "dependsOrder": "sequence", - "dependsOn": ["install", "web"], - "runOptions": { - "runOn": "folderOpen" - }, - "icon": { - "id": "play", - "color": "terminal.ansiMagenta" - }, - "detail": "Setup and launch development environment" - } - ] -} diff --git a/README.md b/README.md deleted file mode 100644 index 7f465ff..0000000 --- a/README.md +++ /dev/null @@ -1,62 +0,0 @@ -# KYCnot.me - -[KYCnot.me](https://kycnot.me) - -## Development - -### Installations - -Install the following tools: - -- [nvm](https://github.com/nvm-sh/nvm) (or [node](https://nodejs.org/en/download/)) -- [docker](https://docs.docker.com/get-docker/) -- [just](https://just.systems) - -### Initialization - -Run this the first time you setup the project: - -```zsh -# you can alternatively use `just dev-database` -docker compose -f docker-compose.yml -f docker-compose.dev.yml up -d --wait database redis -cd web -nvm install -npm i -cp -n .env.example .env -npm run db-push -npm run db-fill-clean -``` - -Now open the [.env](web/.env) file and fill in the missing values. - -> Default users are created with tokens: `admin`, `verifier`, `verified`, `normal` (configurable via env vars) - -### Running the project - -In separate terminals, run the following commands: - -- Database - - ```zsh - # you can alternatively use `just dev-database` - docker compose -f docker-compose.yml -f docker-compose.dev.yml up -d --wait database redis - ``` - -- Website - - ```zsh - cd web - nvm use - npm run dev - ``` - -- Database Admin (Optional) - - ```zsh - cd web - nvm use - npm run db-admin - ``` - -> [!TIP] -> VS Code will run the project in development mode automatically when you open the project. diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml deleted file mode 100644 index d14fad1..0000000 --- a/docker-compose.dev.yml +++ /dev/null @@ -1,45 +0,0 @@ -services: - database: - volumes: - - ./local_data/postgres:/var/lib/postgresql/data:z - ports: - - 3399:5432 - restart: no - environment: - POSTGRES_USER: kycnot - POSTGRES_PASSWORD: kycnot - POSTGRES_DB: kycnot - healthcheck: - test: ["CMD-SHELL", "pg_isready -U kycnot -d kycnot"] - interval: 10s - timeout: 5s - retries: 5 - - db-admin: - image: node:20 - working_dir: /app - volumes: - - ./web:/app - restart: unless-stopped - environment: - POSTGRES_USER: ${POSTGRES_USER:-kycnot} - POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-kycnot} - POSTGRES_DB: ${POSTGRES_DATABASE:-kycnot} - DATABASE_URL: "postgresql://${POSTGRES_USER:-kycnot}:${POSTGRES_PASSWORD:-kycnot}@database:5432/${POSTGRES_DATABASE:-kycnot}?schema=public" - depends_on: - database: - condition: service_healthy - expose: - - 5555 - ports: - - "5555:5555" - command: ["npm", "run", "db-admin"] - healthcheck: - test: ["CMD", "curl", "-k", "--silent", "--fail", "http://localhost:5555"] - interval: 10s - timeout: 5s - retries: 5 - - redis: - ports: - - "6379:6379" diff --git a/docker-compose.yml b/docker-compose.yml deleted file mode 100644 index c86b674..0000000 --- a/docker-compose.yml +++ /dev/null @@ -1,76 +0,0 @@ -volumes: - database: - -services: - database: - image: postgres:latest - volumes: - - database:/var/lib/postgresql/data:z - restart: unless-stopped - environment: - POSTGRES_USER: ${POSTGRES_USER:-kycnot} - POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-kycnot} - POSTGRES_DB: ${POSTGRES_DATABASE:-kycnot} - healthcheck: - test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-kycnot} -d ${POSTGRES_DATABASE:-kycnot}"] - interval: 10s - timeout: 5s - retries: 5 - - pyworker: - build: - context: ./pyworker - restart: always - environment: - DATABASE_URL: "postgresql://${POSTGRES_USER:-kycnot}:${POSTGRES_PASSWORD:-kycnot}@database:5432/${POSTGRES_DATABASE:-kycnot}?schema=public" - CRAWL4AI_BASE_URL: "http://crawl4ai:11235" - CRAWL4AI_API_TOKEN: ${CRAWL4AI_API_TOKEN:-testing} - - crawl4ai: - image: unclecode/crawl4ai:basic-amd64 - expose: - - "11235" - environment: - CRAWL4AI_API_TOKEN: ${CRAWL4AI_API_TOKEN:-testing} # Optional API security - MAX_CONCURRENT_TASKS: 10 - volumes: - - /dev/shm:/dev/shm - deploy: - resources: - limits: - memory: 4G - reservations: - memory: 1G - - redis: - image: redis:latest - restart: unless-stopped - healthcheck: - test: ["CMD", "redis-cli", "ping"] - interval: 10s - timeout: 5s - retries: 5 - - astro: - build: - context: ./web - image: kycnotme/astro:${ASTRO_IMAGE_TAG:-latest} - restart: unless-stopped - environment: - POSTGRES_USER: ${POSTGRES_USER:-kycnot} - POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-kycnot} - POSTGRES_DB: ${POSTGRES_DATABASE:-kycnot} - DATABASE_URL: "postgresql://${POSTGRES_USER:-kycnot}:${POSTGRES_PASSWORD:-kycnot}@database:5432/${POSTGRES_DATABASE:-kycnot}?schema=public" - REDIS_URL: "redis://redis:6379" - depends_on: - database: - condition: service_healthy - redis: - condition: service_healthy - expose: - - 4321 - healthcheck: - test: ["CMD", "curl", "-k", "--silent", "--fail", "http://localhost:4321"] - interval: 10s - timeout: 5s - retries: 5 diff --git a/justfile b/justfile deleted file mode 100644 index 33a74f8..0000000 --- a/justfile +++ /dev/null @@ -1,50 +0,0 @@ -set dotenv-load - -@default: - just --list - -# Start the development database and redis services -dev-database: - docker compose -f docker-compose.yml -f docker-compose.dev.yml up database redis db-admin - -# Import all triggers to the database -import-triggers: - #!/bin/bash - for sql_file in web/prisma/triggers/*.sql; do - echo "Importing $sql_file..." - docker compose exec -T database psql -U ${DATABASE_USER:-kycnot} -d ${DATABASE_NAME:-kycnot} < "$sql_file" - done - -dump-db: - #!/bin/bash - mkdir -p backups - TIMESTAMP=$(date +%Y%m%d_%H%M%S) - echo "Creating database backup (excluding _prisma_migrations table)..." - docker compose exec -T database pg_dump -U ${POSTGRES_USER:-kycnot} -d ${POSTGRES_DATABASE:-kycnot} -c -F c -T _prisma_migrations > backups/db_backup_${TIMESTAMP}.dump - echo "Backup saved to backups/db_backup_${TIMESTAMP}.dump" - -# Import a database backup. Usage: just import-db [filename] -# If no filename is provided, it will use the most recent backup -import-db file="": - #!/bin/bash - if [ -z "{{file}}" ]; then - BACKUP_FILE=$(find backups/ -name 'db_backup_*.dump' | sort -r | head -n 1) - if [ -z "$BACKUP_FILE" ]; then - echo "Error: No backup files found in the backups directory" - exit 1 - fi - else - BACKUP_FILE="{{file}}" - if [ ! -f "$BACKUP_FILE" ]; then - echo "Error: Backup file '$BACKUP_FILE' not found" - exit 1 - fi - fi - - echo "Restoring database from $BACKUP_FILE..." - # First drop all connections to the database - docker compose exec -T database psql -U ${POSTGRES_USER:-kycnot} -c "SELECT pg_terminate_backend(pg_stat_activity.pid) FROM pg_stat_activity WHERE pg_stat_activity.datname = '${POSTGRES_DATABASE:-kycnot}' AND pid <> pg_backend_pid();" postgres - # Then restore the database - cat "$BACKUP_FILE" | docker compose exec -T database pg_restore -U ${POSTGRES_USER:-kycnot} -d ${POSTGRES_DATABASE:-kycnot} --clean --if-exists - echo "Database restored successfully!" - \ No newline at end of file diff --git a/pyworker/.env.example b/pyworker/.env.example deleted file mode 100644 index 012ad1b..0000000 --- a/pyworker/.env.example +++ /dev/null @@ -1,21 +0,0 @@ -# Database connection -DATABASE_URL=postgresql://kycnot:kycnot@localhost:3399/kycnot - -# API settings -TOS_API_BASE_URL=https://r.jina.ai - -# Logging -LOG_LEVEL=INFO -LOG_FORMAT=%(asctime)s - %(name)s - %(levelname)s - %(message)s - -# OpenAI -OPENAI_API_KEY="xxxxxxxxx" -OPENAI_BASE_URL="https://xxxxxx/api/v1" -OPENAI_MODEL="xxxxxxxxx" -OPENAI_RETRY=3 - -CRON_TOSREVIEW_TASK=0 0 1 * * # Every month -CRON_USER_SENTIMENT_TASK=0 0 * * * # Every day -CRON_COMMENT_MODERATION_TASK=0 0 * * * # Every hour -CRON_FORCE_TRIGGERS_TASK=0 2 * * * # Every day -CRON_SERVICE_SCORE_RECALC_TASK=*/5 * * * * # Every 10 minutes \ No newline at end of file diff --git a/pyworker/.gitignore b/pyworker/.gitignore deleted file mode 100644 index 0a19790..0000000 --- a/pyworker/.gitignore +++ /dev/null @@ -1,174 +0,0 @@ -# Byte-compiled / optimized / DLL files -__pycache__/ -*.py[cod] -*$py.class - -# C extensions -*.so - -# Distribution / packaging -.Python -build/ -develop-eggs/ -dist/ -downloads/ -eggs/ -.eggs/ -lib/ -lib64/ -parts/ -sdist/ -var/ -wheels/ -share/python-wheels/ -*.egg-info/ -.installed.cfg -*.egg -MANIFEST - -# PyInstaller -# Usually these files are written by a python script from a template -# before PyInstaller builds the exe, so as to inject date/other infos into it. -*.manifest -*.spec - -# Installer logs -pip-log.txt -pip-delete-this-directory.txt - -# Unit test / coverage reports -htmlcov/ -.tox/ -.nox/ -.coverage -.coverage.* -.cache -nosetests.xml -coverage.xml -*.cover -*.py,cover -.hypothesis/ -.pytest_cache/ -cover/ - -# Translations -*.mo -*.pot - -# Django stuff: -*.log -local_settings.py -db.sqlite3 -db.sqlite3-journal - -# Flask stuff: -instance/ -.webassets-cache - -# Scrapy stuff: -.scrapy - -# Sphinx documentation -docs/_build/ - -# PyBuilder -.pybuilder/ -target/ - -# Jupyter Notebook -.ipynb_checkpoints - -# IPython -profile_default/ -ipython_config.py - -# pyenv -# For a library or package, you might want to ignore these files since the code is -# intended to run in multiple environments; otherwise, check them in: -# .python-version - -# pipenv -# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. -# However, in case of collaboration, if having platform-specific dependencies or dependencies -# having no cross-platform support, pipenv may install dependencies that don't work, or not -# install all needed dependencies. -#Pipfile.lock - -# UV -# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control. -# This is especially recommended for binary packages to ensure reproducibility, and is more -# commonly ignored for libraries. -#uv.lock - -# poetry -# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control. -# This is especially recommended for binary packages to ensure reproducibility, and is more -# commonly ignored for libraries. -# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control -#poetry.lock - -# pdm -# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control. -#pdm.lock -# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it -# in version control. -# https://pdm.fming.dev/latest/usage/project/#working-with-version-control -.pdm.toml -.pdm-python -.pdm-build/ - -# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm -__pypackages__/ - -# Celery stuff -celerybeat-schedule -celerybeat.pid - -# SageMath parsed files -*.sage.py - -# Environments -.env -.venv -env/ -venv/ -ENV/ -env.bak/ -venv.bak/ - -# Spyder project settings -.spyderproject -.spyproject - -# Rope project settings -.ropeproject - -# mkdocs documentation -/site - -# mypy -.mypy_cache/ -.dmypy.json -dmypy.json - -# Pyre type checker -.pyre/ - -# pytype static type analyzer -.pytype/ - -# Cython debug symbols -cython_debug/ - -# PyCharm -# JetBrains specific template is maintained in a separate JetBrains.gitignore that can -# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore -# and can be added to the global gitignore or merged into this file. For a more nuclear -# option (not recommended) you can uncomment the following to ignore the entire idea folder. -#.idea/ - -# Ruff stuff: -.ruff_cache/ - -# PyPI configuration file -.pypirc diff --git a/pyworker/.python-version b/pyworker/.python-version deleted file mode 100644 index 24ee5b1..0000000 --- a/pyworker/.python-version +++ /dev/null @@ -1 +0,0 @@ -3.13 diff --git a/pyworker/Dockerfile b/pyworker/Dockerfile deleted file mode 100644 index d6cc491..0000000 --- a/pyworker/Dockerfile +++ /dev/null @@ -1,10 +0,0 @@ -FROM ghcr.io/astral-sh/uv:alpine - -WORKDIR /app - -COPY . . - -RUN uv sync --frozen - -EXPOSE 8000 -CMD ["uv", "run", "-m", "pyworker", "--worker"] diff --git a/pyworker/README.md b/pyworker/README.md deleted file mode 100644 index bba9c6e..0000000 --- a/pyworker/README.md +++ /dev/null @@ -1,149 +0,0 @@ -# KYC Not Worker - -A Python worker for processing and analyzing data for the KYC Not project. - -## Features - -- TOS (Terms of Service) text retrieval and analysis -- User sentiment analysis from comments -- Comment moderation -- Service score recalculation -- Database trigger maintenance -- Scheduled task execution -- Database operations for services and comments - -## Installation - -1. Clone the repository -2. Sync dependencies with [uv](https://docs.astral.sh/uv/): - - ```bash - uv sync - ``` - -## Configuration - -Copy `.env.example` to `.env` and fill in the required values: - -```bash -cp .env.example .env -``` - -Required environment variables: - -- `DATABASE_URL`: PostgreSQL connection string -- `OPENAI_API_KEY`: OpenAI API key for AI tasks -- `CRON_TOSREVIEW_TASK`: Cron expression for TOS review task -- `CRON_SENTIMENT_TASK`: Cron expression for user sentiment analysis task -- `CRON_MODERATION_TASK`: Cron expression for comment moderation task -- `CRON_FORCE_TRIGGERS_TASK`: Cron expression for force triggers task -- `CRON_SERVICE_SCORE_RECALC_TASK`: Cron expression for service score recalculation task - -## Usage - -### Command Line Interface - -Run tasks directly: - -```bash -# Run TOS review task -uv run -m pyworker tos [--service-id ID] - -# Run user sentiment analysis task -uv run -m pyworker sentiment [--service-id ID] - -# Run comment moderation task -uv run -m pyworker moderation [--service-id ID] - -# Run force triggers task -uv run -m pyworker force-triggers - -# Run service score recalculation task -uv run -m pyworker service-score-recalc [--service-id ID] -``` - -### Worker Mode - -Run in worker mode to execute tasks on a schedule: - -```bash -uv run -m pyworker --worker -``` - -Tasks will run according to their configured cron schedules. - -## Tasks - -### TOS Review Task - -- Retrieves and analyzes Terms of Service documents -- Updates service records with TOS information -- Scheduled via `CRON_TOSREVIEW_TASK` - -### User Sentiment Task - -- Analyzes user comments to determine overall sentiment -- Updates service records with sentiment analysis -- Scheduled via `CRON_SENTIMENT_TASK` - -### Comment Moderation Task - -- Makes a basic first moderation of comments -- Flags comments as needed -- Adds content if needed -- Scheduled via `CRON_MODERATION_TASK` - -### Force Triggers Task - -- Maintains database triggers by forcing them to run under certain conditions -- Currently handles updating the "isRecentlyListed" flag for services after 15 days -- Scheduled via `CRON_FORCE-TRIGGERS_TASK` - -### Service Score Recalculation Task - -- Recalculates service scores based on attribute changes -- Processes jobs from the ServiceScoreRecalculationJob table -- Calculates privacy, trust, and overall scores -- Scheduled via `CRON_SERVICE-SCORE-RECALC_TASK` - -## Development - -### Project Structure - -```text -pyworker/ -├── pyworker/ -│ ├── __init__.py -│ ├── __main__.py -│ ├── cli.py -│ ├── config.py -│ ├── database.py -│ ├── scheduler.py -│ ├── tasks/ -│ │ ├── __init__.py -│ │ ├── base.py -│ │ ├── comment_moderation.py -│ │ ├── force_triggers.py -│ │ ├── service_score_recalc.py -│ │ ├── tos_review.py -│ │ └── user_sentiment.py -│ └── utils/ -│ ├── __init__.py -│ ├── ai.py -│ └── logging.py -├── tests/ -├── setup.py -├── requirements.txt -└── README.md -``` - -### Adding New Tasks - -1. Create a new task class in `pyworker/tasks/` -2. Implement the `run` method -3. Add the task to `pyworker/tasks/__init__.py` -4. Update the CLI and scheduler to handle the new task - -## License - -MIT diff --git a/pyworker/docker-compose.yml b/pyworker/docker-compose.yml deleted file mode 100644 index 5af72ee..0000000 --- a/pyworker/docker-compose.yml +++ /dev/null @@ -1,12 +0,0 @@ -services: - pyworker: - build: - context: . - dockerfile: Dockerfile - restart: always - env_file: - - .env - environment: - - OPENAI_API_KEY=${OPENAI_API_KEY} - - OPENAI_MODEL=${OPENAI_MODEL} - - DATABASE_URL=${DATABASE_URL} diff --git a/pyworker/pyproject.toml b/pyworker/pyproject.toml deleted file mode 100644 index 42e20cd..0000000 --- a/pyworker/pyproject.toml +++ /dev/null @@ -1,24 +0,0 @@ -[project] -name = "pyworker" -version = "0.1.0" -description = "AI workers for kycnot.me" -readme = "README.md" -requires-python = ">=3.13" -dependencies = [ - "croniter>=6.0.0", - "json-repair>=0.41.1", - "openai>=1.74.0", - "psycopg[binary,pool]>=3.2.6", - "python-dotenv>=1.1.0", - "requests>=2.32.3", -] - -[project.scripts] -pyworker = "pyworker.cli:main" - -[tool.setuptools] -packages = ["pyworker"] - -[build-system] -requires = ["setuptools>=61.0"] -build-backend = "setuptools.build_meta" diff --git a/pyworker/pyworker/__init__.py b/pyworker/pyworker/__init__.py deleted file mode 100644 index f34beef..0000000 --- a/pyworker/pyworker/__init__.py +++ /dev/null @@ -1,7 +0,0 @@ -""" -KYC Not Worker Package - -A package for worker tasks related to the KYC Not platform. -""" - -__version__ = "0.1.0" \ No newline at end of file diff --git a/pyworker/pyworker/__main__.py b/pyworker/pyworker/__main__.py deleted file mode 100644 index e03d561..0000000 --- a/pyworker/pyworker/__main__.py +++ /dev/null @@ -1,10 +0,0 @@ -#!/usr/bin/env python3 -""" -Entry point for the pyworker package when executed as a module. -""" - -import sys -from pyworker.cli import main - -if __name__ == "__main__": - sys.exit(main()) \ No newline at end of file diff --git a/pyworker/pyworker/cli.py b/pyworker/pyworker/cli.py deleted file mode 100644 index a8d5c01..0000000 --- a/pyworker/pyworker/cli.py +++ /dev/null @@ -1,437 +0,0 @@ -""" -Command line interface for the pyworker package. -""" - -import argparse -import sys -import time -from typing import List, Optional, Dict, Any - -from pyworker.config import config -from pyworker.database import ( - close_db_pool, - fetch_all_services, - fetch_services_with_pending_comments, -) -from pyworker.scheduler import TaskScheduler -from .tasks import ( - CommentModerationTask, - ForceTriggersTask, - ServiceScoreRecalculationTask, - TosReviewTask, - UserSentimentTask, -) -from pyworker.utils.app_logging import setup_logging - -logger = setup_logging(__name__) - - -def parse_args(args: List[str]) -> argparse.Namespace: - """ - Parse command line arguments. - - Args: - args: Command line arguments. - - Returns: - Parsed arguments. - """ - parser = argparse.ArgumentParser(description="KYC Not Worker") - - # Global options - parser.add_argument( - "--worker", - action="store_true", - help="Run in worker mode (schedule tasks to run periodically)", - ) - - # Add subparsers for different tasks - subparsers = parser.add_subparsers(dest="task", help="Task to run") - - # TOS retrieval task - tos_parser = subparsers.add_parser( - "tos", help="Retrieve Terms of Service (TOS) text" - ) - tos_parser.add_argument( - "--service-id", type=int, help="Specific service ID to process (optional)" - ) - - # User sentiment task - sentiment_parser = subparsers.add_parser( - "sentiment", help="Analyze user sentiment from comments" - ) - sentiment_parser.add_argument( - "--service-id", type=int, help="Specific service ID to process (optional)" - ) - - # Comment moderation task - moderation_parser = subparsers.add_parser( - "moderation", help="Moderate pending comments" - ) - moderation_parser.add_argument( - "--service-id", type=int, help="Specific service ID to process (optional)" - ) - - # New Service Penalty task - penalty_parser = subparsers.add_parser( - "force-triggers", - help="Force triggers to run under certain conditions", - ) - penalty_parser.add_argument( - "--service-id", type=int, help="Specific service ID to process (optional)" - ) - - # Service Score Recalculation task - score_recalc_parser = subparsers.add_parser( - "service-score-recalc", - help="Recalculate service scores based on attribute changes", - ) - score_recalc_parser.add_argument( - "--service-id", type=int, help="Specific service ID to process (optional)" - ) - - return parser.parse_args(args) - - -def run_tos_task(service_id: Optional[int] = None) -> int: - """ - Run the TOS retrieval task. - - Args: - service_id: Optional specific service ID to process. - - Returns: - Exit code. - """ - logger.info("Starting TOS retrieval task") - - try: - # Fetch services - services = fetch_all_services() - if not services: - logger.error("No services found") - return 1 - - # Filter by service ID if specified - if service_id: - services = [s for s in services if s["id"] == service_id] - if not services: - logger.error(f"Service with ID {service_id} not found") - return 1 - - # Initialize task and use as context manager - with TosReviewTask() as task: # type: ignore - # Process services using the same database connection - for service in services: - if not service.get("tosUrls"): - logger.info( - f"Skipping service {service['name']} (ID: {service['id']}) - no TOS URLs" - ) - continue - - result = task.run(service) # type: ignore - if result: - logger.info( - f"Successfully retrieved TOS for service {service['name']}" - ) - else: - logger.warning( - f"Failed to retrieve TOS for service {service['name']}" - ) - - logger.info("TOS retrieval task completed") - return 0 - finally: - # Ensure connection pool is closed even if an error occurs - close_db_pool() - - -def run_sentiment_task(service_id: Optional[int] = None) -> int: - """ - Run the user sentiment analysis task. - - Args: - service_id: Optional specific service ID to process. - - Returns: - Exit code. - """ - logger.info("Starting user sentiment analysis task") - - try: - # Fetch services - services = fetch_all_services() - if not services: - logger.error("No services found") - return 1 - - # Filter by service ID if specified - if service_id: - services = [s for s in services if s["id"] == service_id] - if not services: - logger.error(f"Service with ID {service_id} not found") - return 1 - - # Initialize task and use as context manager - with UserSentimentTask() as task: # type: ignore - # Process services using the same database connection - for service in services: - result = task.run(service) # type: ignore - if result is not None: - logger.info( - f"Successfully analyzed sentiment for service {service['name']}" - ) - - logger.info("User sentiment analysis task completed") - return 0 - finally: - # Ensure connection pool is closed even if an error occurs - close_db_pool() - - -def run_moderation_task(service_id: Optional[int] = None) -> int: - """ - Run the comment moderation task. - - Args: - service_id: Optional specific service ID to process. - - Returns: - Exit code. - """ - logger.info("Starting comment moderation task") - - try: - services_to_process: List[Dict[str, Any]] = [] - if service_id: - # Fetch specific service if ID is provided - # Consider creating a fetch_service_by_id for efficiency if this path is common - all_services = fetch_all_services() - services_to_process = [s for s in all_services if s["id"] == service_id] - if not services_to_process: - logger.error( - f"Service with ID {service_id} not found or does not meet general fetch criteria." - ) - return 1 - logger.info(f"Processing specifically for service ID: {service_id}") - else: - # No specific service ID, fetch only services with pending comments - logger.info( - "No specific service ID provided. Querying for services with pending comments." - ) - services_to_process = fetch_services_with_pending_comments() - if not services_to_process: - logger.info( - "No services found with pending comments for moderation at this time." - ) - # Task completed its check, nothing to do. - # Fall through to common completion log. - - any_service_had_comments_processed = False - if not services_to_process and not service_id: - # This case is when no service_id was given AND no services with pending comments were found. - # Already logged above. - pass - elif not services_to_process and service_id: - # This case should have been caught by the 'return 1' if service_id was specified but not found. - # If it reaches here, it implies an issue or the service had no pending comments (which the task will handle). - logger.info( - f"Service ID {service_id} was specified, but no matching service found or it has no pending items for the task." - ) - else: - logger.info( - f"Identified {len(services_to_process)} service(s) to check for comment moderation." - ) - - # Initialize task and use as context manager - with CommentModerationTask() as task: # type: ignore - for service in services_to_process: - # The CommentModerationTask.run() method now returns a boolean - # and handles its own logging regarding finding/processing comments for the service. - if task.run(service): # type: ignore - logger.info( - f"Comment moderation task ran for service {service['name']} (ID: {service['id']}) and processed comments." - ) - any_service_had_comments_processed = True - else: - logger.info( - f"Comment moderation task ran for service {service['name']} (ID: {service['id']}), but no new comments were moderated." - ) - - if services_to_process and not any_service_had_comments_processed: - logger.info( - "Completed iterating through services; no comments were moderated in this run." - ) - - logger.info("Comment moderation task completed") - return 0 - finally: - # Ensure connection pool is closed even if an error occurs - close_db_pool() - - -def run_force_triggers_task() -> int: - """ - Runs the force triggers task. - - Returns: - Exit code. - """ - logger.info("Starting force triggers task") - - try: - # Initialize task and use as context manager - with ForceTriggersTask() as task: # type: ignore - success = task.run() # type: ignore - - if success: - logger.info("Force triggers task completed successfully.") - return 0 - else: - logger.error("Force triggers task failed.") - return 1 - finally: - # Ensure connection pool is closed even if an error occurs - close_db_pool() - - -def run_service_score_recalc_task(service_id: Optional[int] = None) -> int: - """ - Run the service score recalculation task. - - Args: - service_id: Optional specific service ID to process. - - Returns: - Exit code. - """ - logger.info("Starting service score recalculation task") - - try: - # Initialize task and use as context manager - with ServiceScoreRecalculationTask() as task: # type: ignore - result = task.run(service_id) # type: ignore - if result: - logger.info("Successfully recalculated service scores") - else: - logger.warning("Failed to recalculate service scores") - - logger.info("Service score recalculation task completed") - return 0 - finally: - # Ensure connection pool is closed even if an error occurs - close_db_pool() - - -def run_worker_mode() -> int: - """ - Run in worker mode, scheduling tasks to run periodically. - - Returns: - Exit code. - """ - logger.info("Starting worker mode") - - # Get task schedules from config - task_schedules = config.task_schedules - if not task_schedules: - logger.error( - "No task schedules defined. Set CRON_TASKNAME_TASK environment variables." - ) - return 1 - - logger.info( - f"Found {len(task_schedules)} scheduled tasks: {', '.join(task_schedules.keys())}" - ) - - # Initialize the scheduler - scheduler = TaskScheduler() - - # Register tasks with their schedules - for task_name, cron_expression in task_schedules.items(): - if task_name.lower() == "tosreview": - scheduler.register_task(task_name, cron_expression, run_tos_task) - elif task_name.lower() == "user_sentiment": - scheduler.register_task(task_name, cron_expression, run_sentiment_task) - elif task_name.lower() == "comment_moderation": - scheduler.register_task(task_name, cron_expression, run_moderation_task) - elif task_name.lower() == "force_triggers": - scheduler.register_task(task_name, cron_expression, run_force_triggers_task) - elif task_name.lower() == "service_score_recalc": - scheduler.register_task( - task_name, cron_expression, run_service_score_recalc_task - ) - else: - logger.warning(f"Unknown task '{task_name}', skipping") - - # Register service score recalculation task (every 5 minutes) - scheduler.register_task( - "service-score-recalc", - "*/5 * * * *", - run_service_score_recalc_task, - ) - - # Start the scheduler if tasks were registered - if scheduler.tasks: - try: - scheduler.start() - logger.info("Worker started, press Ctrl+C to stop") - - # Keep the main thread alive - while scheduler.is_running(): - time.sleep(1) - - return 0 - except KeyboardInterrupt: - logger.info("Keyboard interrupt received, shutting down...") - scheduler.stop() - return 0 - except Exception as e: - logger.exception(f"Error in worker mode: {e}") - scheduler.stop() - return 1 - else: - logger.error("No valid tasks registered") - return 1 - - -def main() -> int: - """ - Main entry point. - - Returns: - Exit code. - """ - args = parse_args(sys.argv[1:]) - - try: - # If worker mode is specified, run the scheduler - if args.worker: - return run_worker_mode() - - # Otherwise, run the specified task once - if args.task == "tos": - return run_tos_task(args.service_id) - elif args.task == "sentiment": - return run_sentiment_task(args.service_id) - elif args.task == "moderation": - return run_moderation_task(args.service_id) - elif args.task == "force-triggers": - return run_force_triggers_task() - elif args.task == "service-score-recalc": - return run_service_score_recalc_task(args.service_id) - elif args.task: - logger.error(f"Unknown task: {args.task}") - return 1 - else: - logger.error( - "No task specified. Use --worker for scheduled execution or specify a task to run once." - ) - return 1 - except Exception as e: - logger.exception(f"Error running task: {e}") - return 1 - - -if __name__ == "__main__": - sys.exit(main()) diff --git a/pyworker/pyworker/config.py b/pyworker/pyworker/config.py deleted file mode 100644 index 0b83f52..0000000 --- a/pyworker/pyworker/config.py +++ /dev/null @@ -1,67 +0,0 @@ -""" -Configuration module for pyworker. - -Handles loading environment variables and configuration settings. -""" - -import os -import re -from typing import Dict - -from dotenv import load_dotenv - -# Load environment variables from .env file -load_dotenv() - - -class Config: - """Configuration class for the worker application.""" - - # Database settings - DATABASE_URL: str = os.getenv( - "DATABASE_URL", "postgresql://kycnot:kycnot@localhost:3399/kycnot" - ) - - # Clean the URL by removing any query parameters - @property - def db_connection_string(self) -> str: - """Get the clean database connection string without query parameters.""" - if "?" in self.DATABASE_URL: - return self.DATABASE_URL.split("?")[0] - return self.DATABASE_URL - - # API settings - TOS_API_BASE_URL: str = os.getenv("TOS_API_BASE_URL", "https://r.jina.ai") - - # Logging settings - LOG_LEVEL: str = os.getenv("LOG_LEVEL", "INFO") - LOG_FORMAT: str = os.getenv( - "LOG_FORMAT", "%(asctime)s - %(name)s - %(levelname)s - %(message)s" - ) - - # Task scheduling - @property - def task_schedules(self) -> Dict[str, str]: - """ - Get cron schedules for tasks from environment variables. - - Looks for environment variables with the pattern CRON_TASKNAME_TASK - and returns a dictionary mapping task names to cron schedules. - - Returns: - Dictionary mapping task names to cron schedules. - """ - schedules: Dict[str, str] = {} - cron_pattern = re.compile(r"^CRON_(\w+)_TASK$") - - for key, value in os.environ.items(): - match = cron_pattern.match(key) - if match: - task_name = match.group(1).lower() - schedules[task_name] = value - - return schedules - - -# Create a singleton instance -config = Config() diff --git a/pyworker/pyworker/database.py b/pyworker/pyworker/database.py deleted file mode 100644 index ab18eaf..0000000 --- a/pyworker/pyworker/database.py +++ /dev/null @@ -1,733 +0,0 @@ -""" -Database operations for the pyworker package. -""" - -import json -from contextlib import contextmanager -from datetime import datetime -from typing import Any, Dict, Generator, List, Optional, TypedDict, Union -from typing import Literal as TypeLiteral - -import psycopg -from psycopg.rows import dict_row -from psycopg.sql import SQL, Composed, Literal -from psycopg_pool import ConnectionPool # Proper import for the connection pool - -from pyworker.config import config -from pyworker.utils.app_logging import setup_logging - -logger = setup_logging(__name__) - -# --- Type Definitions --- - - -# Moved from tasks/comment_moderation.py -class CommentType(TypedDict): - id: int - upvotes: int - status: str # Assuming CommentStatus Enum isn't used across modules yet - suspicious: bool - requiresAdminReview: bool - communityNote: Optional[str] - internalNote: Optional[str] - privateContext: Optional[str] - content: str - rating: Optional[float] - createdAt: datetime - updatedAt: datetime - authorId: int - serviceId: int - parentId: Optional[int] - # Add author/service/reply fields if needed by update_comment - - -# Moved from utils/ai.py -RatingType = TypeLiteral["info", "warning", "alert"] - - -class UserRightType(TypedDict): - text: str - rating: RatingType - - -class DataSharingType(TypedDict): - text: str - rating: RatingType - - -class DataCollectedType(TypedDict): - text: str - rating: RatingType - - -class KycOrSourceOfFundsType(TypedDict): - text: str - rating: RatingType - - -class TosReviewType(TypedDict, total=False): - contentHash: str - kycLevel: int - summary: str - complexity: TypeLiteral["low", "medium", "high"] - highlights: List[Dict[str, Any]] - - -class CommentSentimentSummaryType(TypedDict): - summary: str - sentiment: TypeLiteral["positive", "negative", "neutral"] - whatUsersLike: List[str] - whatUsersDislike: List[str] - - -class CommentModerationType(TypedDict): - isSpam: bool - requiresAdminReview: bool - contextNote: str - internalNote: str - commentQuality: int - - -QueryType = Union[str, bytes, SQL, Composed, Literal] - - -# --- Database Connection Pool --- -_db_pool: Optional[ConnectionPool] = None - - -def get_db_pool() -> ConnectionPool: - """ - Get or create the database connection pool. - - Returns: - A connection pool object. - """ - global _db_pool - if _db_pool is None: - try: - # Create a new connection pool with min connections of 2 and max of 10 - _db_pool = ConnectionPool( - conninfo=config.db_connection_string, - min_size=2, - max_size=10, - # Configure how connections are initialized - kwargs={ - "autocommit": False, - }, - ) - logger.info("Database connection pool initialized") - except Exception as e: - logger.error(f"Error creating database connection pool: {e}") - raise - return _db_pool - - -def close_db_pool(): - """ - Close the database connection pool. - This should be called when the application is shutting down. - """ - global _db_pool - if _db_pool is not None: - logger.info("Closing database connection pool") - _db_pool.close() - _db_pool = None - - -@contextmanager -def get_db_connection() -> Generator[psycopg.Connection, None, None]: - """ - Context manager for database connections. - - Yields: - A database connection object from the pool. - """ - pool = get_db_pool() - try: - # Use the connection method which returns a connection as a context manager - with pool.connection() as conn: - # Set the schema explicitly after connection - with conn.cursor() as cursor: - cursor.execute("SET search_path TO public") - yield conn - # The connection will be automatically returned to the pool - # when the with block exits - except Exception as e: - logger.error(f"Error connecting to the database: {e}") - raise - - -# --- Database Functions --- - - -def fetch_all_services() -> List[Dict[str, Any]]: - """ - Fetch all public and verified services from the database. - - Returns: - A list of service dictionaries. - """ - services = [] - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute(""" - SELECT id, name, slug, description, "kycLevel", "overallScore", - "privacyScore", "trustScore", "verificationStatus", - "serviceVisibility", "tosUrls", "serviceUrls", "onionUrls", "i2pUrls", - "tosReview", "tosReviewAt", "userSentiment", "userSentimentAt" - FROM "Service" - WHERE "serviceVisibility" = 'PUBLIC' - AND ("verificationStatus" = 'VERIFICATION_SUCCESS' - OR "verificationStatus" = 'COMMUNITY_CONTRIBUTED' - OR "verificationStatus" = 'APPROVED') - ORDER BY id - """) - services = cursor.fetchall() - logger.info(f"Fetched {len(services)} services from the database") - except Exception as e: - logger.error(f"Error fetching services: {e}") - - return services - - -def fetch_services_with_pending_comments() -> List[Dict[str, Any]]: - """ - Fetch all public and verified services that have at least one pending comment. - - Returns: - A list of service dictionaries. - """ - services = [] - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute(""" - SELECT DISTINCT s.id, s.name, s.slug, s.description, s."kycLevel", s."overallScore", - s."privacyScore", s."trustScore", s."verificationStatus", - s."serviceVisibility", s."tosUrls", s."serviceUrls", s."onionUrls", s."i2pUrls", - s."tosReview", s."tosReviewAt", s."userSentiment", s."userSentimentAt" - FROM "Service" s - JOIN "Comment" c ON s.id = c."serviceId" - WHERE c.status = 'PENDING' - AND s."serviceVisibility" = 'PUBLIC' - AND (s."verificationStatus" = 'VERIFICATION_SUCCESS' - OR s."verificationStatus" = 'COMMUNITY_CONTRIBUTED' - OR s."verificationStatus" = 'APPROVED') - ORDER BY s.id - """) - services = cursor.fetchall() - logger.info( - f"Fetched {len(services)} services with pending comments from the database" - ) - except Exception as e: - logger.error(f"Error fetching services with pending comments: {e}") - - return services - - -def fetch_service_attributes(service_id: int) -> List[Dict[str, Any]]: - """ - Fetch attributes for a specific service. - - Args: - service_id: The ID of the service. - - Returns: - A list of attribute dictionaries. - """ - attributes = [] - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute( - """ - SELECT a.id, a.slug, a.title, a.description, a.category, a.type - FROM "Attribute" a - JOIN "ServiceAttribute" sa ON a.id = sa."attributeId" - WHERE sa."serviceId" = %s - """, - (service_id,), - ) - attributes = cursor.fetchall() - except Exception as e: - logger.error(f"Error fetching attributes for service {service_id}: {e}") - - return attributes - - -def get_attribute_id_by_slug(slug: str) -> Optional[int]: - attribute_id = None - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute('SELECT id FROM "Attribute" WHERE slug = %s', (slug,)) - row = cursor.fetchone() - if row: - attribute_id = row["id"] - except Exception as e: - logger.error(f"Error fetching attribute id for slug '{slug}': {e}") - return attribute_id - - -def add_service_attribute(service_id: int, attribute_id: int) -> bool: - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute( - 'SELECT 1 FROM "ServiceAttribute" WHERE "serviceId" = %s AND "attributeId" = %s', - (service_id, attribute_id), - ) - if cursor.fetchone(): - return True - cursor.execute( - 'INSERT INTO "ServiceAttribute" ("serviceId", "attributeId", "createdAt") VALUES (%s, %s, NOW())', - (service_id, attribute_id), - ) - conn.commit() - logger.info( - f"Added attribute id {attribute_id} to service {service_id}" - ) - return True - except Exception as e: - logger.error( - f"Error adding attribute id {attribute_id} to service {service_id}: {e}" - ) - return False - - -def remove_service_attribute(service_id: int, attribute_id: int) -> bool: - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute( - 'DELETE FROM "ServiceAttribute" WHERE "serviceId" = %s AND "attributeId" = %s', - (service_id, attribute_id), - ) - conn.commit() - logger.info( - f"Removed attribute id {attribute_id} from service {service_id}" - ) - return True - except Exception as e: - logger.error( - f"Error removing attribute id {attribute_id} from service {service_id}: {e}" - ) - return False - - -def add_service_attribute_by_slug(service_id: int, attribute_slug: str) -> bool: - attribute_id = get_attribute_id_by_slug(attribute_slug) - if attribute_id is None: - logger.error(f"Attribute with slug '{attribute_slug}' not found.") - return False - return add_service_attribute(service_id, attribute_id) - - -def remove_service_attribute_by_slug(service_id: int, attribute_slug: str) -> bool: - attribute_id = get_attribute_id_by_slug(attribute_slug) - if attribute_id is None: - logger.error(f"Attribute with slug '{attribute_slug}' not found.") - return False - return remove_service_attribute(service_id, attribute_id) - - -def save_tos_review(service_id: int, review: TosReviewType): - """ - Save a TOS review for a specific service. - - Args: - service_id: The ID of the service. - review: A TypedDict containing the review data. - """ - try: - # Serialize the dictionary to a JSON string for the database - review_json = json.dumps(review) - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute( - """ - UPDATE "Service" - SET "tosReview" = %s, "tosReviewAt" = NOW() - WHERE id = %s - """, - (review_json, service_id), - ) - conn.commit() - logger.info(f"Successfully saved TOS review for service {service_id}") - except Exception as e: - logger.error(f"Error saving TOS review for service {service_id}: {e}") - - -def update_kyc_level(service_id: int, kyc_level: int) -> bool: - """ - Update the KYC level for a specific service. - - Args: - service_id: The ID of the service. - kyc_level: The new KYC level (0-4). - - Returns: - bool: True if the update was successful, False otherwise. - """ - try: - # Ensure the kyc_level is within the valid range - if not 0 <= kyc_level <= 4: - logger.error( - f"Invalid KYC level ({kyc_level}) for service {service_id}. Must be between 0 and 4." - ) - return False - - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute( - """ - UPDATE "Service" - SET "kycLevel" = %s, "updatedAt" = NOW() - WHERE id = %s - """, - (kyc_level, service_id), - ) - conn.commit() - logger.info( - f"Successfully updated KYC level to {kyc_level} for service {service_id}" - ) - return True - except Exception as e: - logger.error(f"Error updating KYC level for service {service_id}: {e}") - return False - - -def get_comments(service_id: int, status: str = "APPROVED") -> List[Dict[str, Any]]: - """ - Get all comments for a specific service with the specified status. - - Args: - service_id: The ID of the service. - status: The status of comments to fetch (e.g. 'APPROVED', 'PENDING'). Defaults to 'APPROVED'. - - Returns: - A list of comment dictionaries. - NOTE: The structure returned by the SQL query might be different from CommentType. - Adjust CommentType or parsing if needed elsewhere. - """ - comments = [] - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute( - """ - WITH RECURSIVE comment_tree AS ( - -- Base case: get all root comments (no parent) - SELECT - c.id, - c.content, - c.rating, - c.upvotes, - c."createdAt", - c."updatedAt", - c."parentId", - c.status, - u.id as "authorId", - u.name as "authorName", - u."displayName" as "authorDisplayName", - u.picture as "authorPicture", - u.verified as "authorVerified", - 0 as depth - FROM "Comment" c - JOIN "User" u ON c."authorId" = u.id - WHERE c."serviceId" = %s - AND c.status = %s - AND c."parentId" IS NULL - - UNION ALL - - -- Recursive case: get all replies - SELECT - c.id, - c.content, - c.rating, - c.upvotes, - c."createdAt", - c."updatedAt", - c."parentId", - c.status, - u.id as "authorId", - u.name as "authorName", - u."displayName" as "authorDisplayName", - u.picture as "authorPicture", - u.verified as "authorVerified", - ct.depth + 1 - FROM "Comment" c - JOIN "User" u ON c."authorId" = u.id - JOIN comment_tree ct ON c."parentId" = ct.id - WHERE c.status = %s - ) - SELECT * FROM comment_tree - ORDER BY "createdAt" DESC, depth ASC - """, - (service_id, status, status), - ) - comments = cursor.fetchall() - except Exception as e: - logger.error( - f"Error fetching comments for service {service_id} with status {status}: {e}" - ) - - return comments - - -def get_max_comment_updated_at( - service_id: int, status: str = "APPROVED" -) -> Optional[datetime]: - """ - Get the maximum 'updatedAt' timestamp for comments of a specific service and status. - - Args: - service_id: The ID of the service. - status: The status of comments to consider. - - Returns: - The maximum 'updatedAt' timestamp as a datetime object, or None if no matching comments. - """ - max_updated_at = None - try: - with get_db_connection() as conn: - with ( - conn.cursor() as cursor - ): # dict_row not strictly needed for single value - cursor.execute( - """ - SELECT MAX("updatedAt") - FROM "Comment" - WHERE "serviceId" = %s AND status = %s - """, - (service_id, status), - ) - result = cursor.fetchone() - if result and result[0] is not None: - max_updated_at = result[0] - except Exception as e: - logger.error( - f"Error fetching max comment updatedAt for service {service_id} with status {status}: {e}" - ) - return max_updated_at - - -def save_user_sentiment( - service_id: int, - sentiment: Optional[CommentSentimentSummaryType], - last_processed_comment_timestamp: Optional[datetime], -): - """ - Save user sentiment for a specific service and the timestamp of the last comment processed. - - Args: - service_id: The ID of the service. - sentiment: A dictionary containing the sentiment data, or None to clear it. - last_processed_comment_timestamp: The 'updatedAt' timestamp of the most recent comment - considered in this sentiment analysis. Can be None. - """ - try: - sentiment_json = json.dumps(sentiment) if sentiment is not None else None - with get_db_connection() as conn: - with conn.cursor() as cursor: # row_factory not needed for UPDATE - cursor.execute( - """ - UPDATE "Service" - SET "userSentiment" = %s, "userSentimentAt" = %s - WHERE id = %s - """, - (sentiment_json, last_processed_comment_timestamp, service_id), - ) - conn.commit() - if sentiment: - logger.info( - f"Successfully saved user sentiment for service {service_id} with last comment processed at {last_processed_comment_timestamp}" - ) - else: - logger.info( - f"Successfully cleared user sentiment for service {service_id}, last comment processed at set to {last_processed_comment_timestamp}" - ) - except Exception as e: - logger.error(f"Error saving user sentiment for service {service_id}: {e}") - - -def update_comment_moderation(comment_data: CommentType): - """ - Update an existing comment in the database based on moderation results. - - Args: - comment_data: A TypedDict representing the comment data to update. - Expected keys are defined in CommentType. - """ - comment_id = comment_data.get("id") - if not comment_id: - logger.error("Cannot update comment: 'id' is missing from comment_data.") - return - - try: - with get_db_connection() as conn: - with conn.cursor() as cursor: - cursor.execute( - """ - UPDATE "Comment" - SET - status = %(status)s, - "requiresAdminReview" = %(requiresAdminReview)s, - "communityNote" = %(communityNote)s, - "internalNote" = %(internalNote)s, - "updatedAt" = NOW() - WHERE id = %(id)s - """, - comment_data, - ) - conn.commit() - logger.info(f"Successfully updated comment {comment_id}") - except Exception as e: - logger.error(f"Error updating comment {comment_id}: {e}") - - -def touch_service_updated_at(service_id: int) -> bool: - """ - Update the updatedAt field for a specific service to now. - - Args: - service_id: The ID of the service. - - Returns: - bool: True if the update was successful, False otherwise. - """ - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - cursor.execute( - """ - UPDATE "Service" - SET "updatedAt" = NOW() - WHERE id = %s - """, - (service_id,), - ) - conn.commit() - logger.info(f"Successfully touched updatedAt for service {service_id}") - return True - except Exception as e: - logger.error(f"Error touching updatedAt for service {service_id}: {e}") - return False - - -def run_db_query(query: Any, params: Optional[Any] = None) -> List[Dict[str, Any]]: - results = [] - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - if params is None: - cursor.execute(query) - else: - cursor.execute(query, params) - results = cursor.fetchall() - except Exception as e: - logger.error(f"Error running query: {e}") - return results - - -def execute_db_command(command: str, params: Optional[Any] = None) -> int: - """ - Execute a database command (INSERT, UPDATE, DELETE) and return affected rows. - - Args: - command: The SQL command string. - params: Optional parameters for the command. - - Returns: - The number of rows affected by the command. - """ - affected_rows = 0 - try: - with get_db_connection() as conn: - with conn.cursor() as cursor: - # Cast the string to the expected type to satisfy the type checker - # In runtime, this is equivalent to passing the command directly - cursor.execute(command, params) # type: ignore - affected_rows = cursor.rowcount - conn.commit() - logger.info(f"Executed command, {affected_rows} rows affected.") - except Exception as e: - logger.error(f"Error executing command: {e}") - return affected_rows - - -def create_attribute( - slug: str, - title: str, - description: str, - category: str, - type: str, - privacy_points: float = 0, - trust_points: float = 0, - overall_points: float = 0, -) -> Optional[int]: - """ - Create a new attribute in the database if it doesn't already exist. - - Args: - slug: The unique slug for the attribute. - title: The display title of the attribute. - description: The description of the attribute. - category: The category of the attribute (e.g., 'TRUST', 'PRIVACY'). - type: The type of the attribute (e.g., 'WARNING', 'FEATURE'). - privacy_points: Points affecting privacy score (default: 0). - trust_points: Points affecting trust score (default: 0). - overall_points: Points affecting overall score (default: 0). - - Returns: - The ID of the created (or existing) attribute, or None if creation failed. - """ - try: - with get_db_connection() as conn: - with conn.cursor(row_factory=dict_row) as cursor: - # First check if the attribute already exists - cursor.execute('SELECT id FROM "Attribute" WHERE slug = %s', (slug,)) - row = cursor.fetchone() - if row: - logger.info( - f"Attribute with slug '{slug}' already exists, id: {row['id']}" - ) - return row["id"] - - # Create the attribute if it doesn't exist - cursor.execute( - """ - INSERT INTO "Attribute" ( - slug, title, description, "privacyPoints", "trustPoints", - category, type, "createdAt", "updatedAt" - ) VALUES ( - %s, %s, %s, %s, %s, %s, %s, NOW(), NOW() - ) RETURNING id - """, - ( - slug, - title, - description, - privacy_points, - trust_points, - category, - type, - ), - ) - conn.commit() - result = cursor.fetchone() - if result is None: - logger.error( - f"Failed to retrieve ID for newly created attribute with slug '{slug}'" - ) - return None - attribute_id = result["id"] - logger.info( - f"Created new attribute with slug '{slug}', id: {attribute_id}" - ) - return attribute_id - except Exception as e: - logger.error(f"Error creating attribute with slug '{slug}': {e}") - return None diff --git a/pyworker/pyworker/scheduler.py b/pyworker/pyworker/scheduler.py deleted file mode 100644 index bd6164f..0000000 --- a/pyworker/pyworker/scheduler.py +++ /dev/null @@ -1,184 +0,0 @@ -""" -Scheduler module for managing task execution with cron. -""" - -import signal -import threading -from datetime import datetime -from types import FrameType -from typing import Any, Callable, Dict, List, ParamSpec, TypeVar - -from croniter import croniter - -from pyworker.database import close_db_pool -from .tasks import ( - CommentModerationTask, - ForceTriggersTask, - ServiceScoreRecalculationTask, - TosReviewTask, - UserSentimentTask, -) -from pyworker.utils.app_logging import setup_logging - -logger = setup_logging(__name__) - -P = ParamSpec("P") -R = TypeVar("R") - - -class TaskScheduler: - """Task scheduler for running tasks on a cron schedule.""" - - def __init__(self): - """Initialize the task scheduler.""" - self.tasks: Dict[str, Dict[str, Any]] = {} - self.running = False - self.threads: List[threading.Thread] = [] - self.stop_event = threading.Event() - self.logger = logger - - # Set up signal handlers - signal.signal(signal.SIGINT, self._handle_signal) - signal.signal(signal.SIGTERM, self._handle_signal) - - def _handle_signal(self, signum: int, frame: FrameType | None) -> None: - """Handle termination signals.""" - self.logger.info(f"Received signal {signum}, shutting down...") - self.stop() - - def register_task( - self, - task_name: str, - cron_expression: str, - task_func: Callable[P, R], - *args: P.args, - **kwargs: P.kwargs, - ) -> None: - """ - Register a task to be scheduled. - - Args: - task_name: Name of the task. - cron_expression: Cron expression defining the schedule. - task_func: Function to execute. - *args: Arguments to pass to the task function. - **kwargs: Keyword arguments to pass to the task function. - """ - # Declare task_instance variable with type annotation upfront - task_instance: Any = None - - # Initialize the appropriate task class based on the task name - if task_name.lower() == "tosreview": - task_instance = TosReviewTask() - elif task_name.lower() == "user_sentiment": - task_instance = UserSentimentTask() - elif task_name.lower() == "comment_moderation": - task_instance = CommentModerationTask() - elif task_name.lower() == "force_triggers": - task_instance = ForceTriggersTask() - elif task_name.lower() == "service_score_recalc": - task_instance = ServiceScoreRecalculationTask() - else: - self.logger.warning(f"Unknown task '{task_name}', skipping") - return - - self.tasks[task_name] = { - "cron": cron_expression, - "func": task_func, - "instance": task_instance, - "args": args, - "kwargs": kwargs, - } - self.logger.info( - f"Registered task '{task_name}' with schedule: {cron_expression}" - ) - - def _run_task(self, task_name: str, task_info: Dict[str, Any]): - """ - Run a task on its schedule. - - Args: - task_name: Name of the task. - task_info: Task information including function and schedule. - """ - self.logger.info(f"Starting scheduler for task '{task_name}'") - - # Parse the cron expression - cron = croniter(task_info["cron"], datetime.now()) - - while not self.stop_event.is_set(): - # Get the next run time - next_run = cron.get_next(datetime) - self.logger.info(f"Next run for task '{task_name}': {next_run}") - - # Sleep until the next run time - now = datetime.now() - sleep_seconds = (next_run - now).total_seconds() - - if sleep_seconds > 0: - # Wait until next run time or until stop event is set - if self.stop_event.wait(sleep_seconds): - break - - # Run the task if we haven't been stopped - if not self.stop_event.is_set(): - try: - self.logger.info(f"Running task '{task_name}'") - # Use task instance as a context manager to ensure - # a single database connection is used for the entire task - with task_info["instance"] as task_instance: - # Execute the task instance's run method directly - task_instance.run() - self.logger.info(f"Task '{task_name}' completed") - except Exception as e: - self.logger.exception(f"Error running task '{task_name}': {e}") - finally: - # Close the database pool after task execution - close_db_pool() - - def start(self): - """Start the scheduler.""" - if self.running: - self.logger.warning("Scheduler is already running") - return - - self.logger.info("Starting scheduler") - self.running = True - self.stop_event.clear() - - # Start a thread for each task - for task_name, task_info in self.tasks.items(): - thread = threading.Thread( - target=self._run_task, - args=(task_name, task_info), - name=f"scheduler-{task_name}", - ) - thread.daemon = True - thread.start() - self.threads.append(thread) - - self.logger.info(f"Started {len(self.threads)} scheduler threads") - - def stop(self): - """Stop the scheduler.""" - if not self.running: - return - - self.logger.info("Stopping scheduler") - self.running = False - self.stop_event.set() - - # Wait for all threads to terminate - for thread in self.threads: - thread.join(timeout=5.0) - - self.threads = [] - - # Close database pool when the scheduler stops - close_db_pool() - - self.logger.info("Scheduler stopped") - - def is_running(self) -> bool: - """Check if the scheduler is running.""" - return self.running diff --git a/pyworker/pyworker/tasks/__init__.py b/pyworker/pyworker/tasks/__init__.py deleted file mode 100644 index 4c1143a..0000000 --- a/pyworker/pyworker/tasks/__init__.py +++ /dev/null @@ -1,17 +0,0 @@ -"""Task modules for the pyworker package.""" - -from .base import Task -from .comment_moderation import CommentModerationTask -from .force_triggers import ForceTriggersTask -from .service_score_recalc import ServiceScoreRecalculationTask -from .tos_review import TosReviewTask -from .user_sentiment import UserSentimentTask - -__all__ = [ - "Task", - "CommentModerationTask", - "ForceTriggersTask", - "ServiceScoreRecalculationTask", - "TosReviewTask", - "UserSentimentTask", -] diff --git a/pyworker/pyworker/tasks/base.py b/pyworker/pyworker/tasks/base.py deleted file mode 100644 index 6d1d260..0000000 --- a/pyworker/pyworker/tasks/base.py +++ /dev/null @@ -1,64 +0,0 @@ -""" -Base task module for the pyworker package. -""" - -from abc import ABC, abstractmethod -from contextlib import AbstractContextManager -from typing import Any, Optional, Type - -from pyworker.database import get_db_connection -from pyworker.utils.app_logging import setup_logging - -logger = setup_logging(__name__) - - -class Task(ABC): - """Base class for all worker tasks.""" - - def __init__(self, name: str): - """ - Initialize a task. - - Args: - name: The name of the task. - """ - self.name = name - self.logger = setup_logging(f"pyworker.task.{name}") - self.conn: Optional[Any] = None - self._context: Optional[AbstractContextManager[Any]] = None - - def __enter__(self): - """Enter context manager, acquiring a database connection.""" - self._context = get_db_connection() - self.conn = self._context.__enter__() - return self - - def __exit__( - self, - exc_type: Optional[Type[BaseException]], - exc_val: Optional[BaseException], - exc_tb: Optional[Any], - ) -> Optional[bool]: - """Exit context manager, releasing the database connection.""" - if self._context: - return self._context.__exit__(exc_type, exc_val, exc_tb) - return None - - @abstractmethod - def run(self, *args: Any, **kwargs: Any) -> Any: - """ - Run the task. - - This method must be implemented by subclasses. - - Args: - *args: Variable length argument list. - **kwargs: Arbitrary keyword arguments. - - Returns: - The result of the task. - """ - pass - - def __str__(self) -> str: - return f"{self.__class__.__name__}(name={self.name})" diff --git a/pyworker/pyworker/tasks/comment_moderation.py b/pyworker/pyworker/tasks/comment_moderation.py deleted file mode 100644 index 5833ec1..0000000 --- a/pyworker/pyworker/tasks/comment_moderation.py +++ /dev/null @@ -1,112 +0,0 @@ -""" -Task for summarizing comments and getting overal sentiment -""" - -import json -from datetime import datetime -from typing import Any, Dict, List - -# Import types from database.py -from pyworker.database import ( # type: ignore - CommentType, - get_comments, - update_comment_moderation, -) -from pyworker.tasks.base import Task # type: ignore -from pyworker.utils.ai import prompt_comment_moderation - - -class DateTimeEncoder(json.JSONEncoder): - def default(self, o: Any) -> Any: - if isinstance(o, datetime): - return o.isoformat() - return super().default(o) - - -class CommentModerationTask(Task): - """Task for summarizing comments and getting overal sentiment""" - - def __init__(self): - """Initialize the comment moderation task.""" - super().__init__("comment_moderation") - - def run(self, service: Dict[str, Any]) -> bool: - """ - Run the comment moderation task. - Returns True if comments were processed, False otherwise. - """ - service_id = service["id"] - service_name = service["name"] - - # Query the approved comments for the service - # get_comments is type ignored, so we assume it returns List[Dict[str, Any]] - comments: List[Dict[str, Any]] = get_comments(service_id, status="PENDING") - - if not comments: - self.logger.info( - f"No pending comments found for service {service_name} (ID: {service_id}) during task run." - ) - return False - - self.logger.info( - f"Found {len(comments)} pending comments for service {service_name} (ID: {service_id}). Starting processing." - ) - - processed_at_least_one = False - for comment_data in comments: - # Assert the type for the individual dictionary for type checking within the loop - comment: CommentType = comment_data # type: ignore - - # Query OpenAI to get the sentiment summary - moderation = prompt_comment_moderation( - f"Information about the service: {service}\\nCurrent time: {datetime.now()}\\n\\nComment to moderate: {json.dumps(comment, cls=DateTimeEncoder)}" - ) - - modstring = f"Comment {comment['id']} " - - if moderation["isSpam"] and moderation["commentQuality"] > 5: - comment["status"] = "HUMAN_PENDING" - modstring += " marked as HUMAN_PENDING" - elif moderation["isSpam"] and moderation["commentQuality"] <= 5: - comment["status"] = "REJECTED" - modstring += " marked as REJECTED" - - if moderation["requiresAdminReview"]: - comment["requiresAdminReview"] = True - modstring += " requires admin review" - # Ensure status is HUMAN_PENDING if admin review is required, unless already REJECTED - if comment.get("status") != "REJECTED": - comment["status"] = "HUMAN_PENDING" - if ( - "marked as HUMAN_PENDING" not in modstring - ): # Avoid duplicate message - modstring += " marked as HUMAN_PENDING" - else: - comment["requiresAdminReview"] = False - if ( - comment.get("status") != "HUMAN_PENDING" - and comment.get("status") != "REJECTED" - ): - comment["status"] = "APPROVED" - modstring += " marked as APPROVED" - - if moderation.get("moderationNote"): # Check if key exists - comment["communityNote"] = moderation["contextNote"] - modstring += " with moderation note: " + moderation["contextNote"] - else: - comment["communityNote"] = None - - if moderation.get("internalNote"): # Check if key exists - comment["internalNote"] = moderation["internalNote"] - modstring += ( - " with internal note: " + moderation["internalNote"] - ) # Changed from spam reason for clarity - else: - comment["internalNote"] = None - - # Save the sentiment summary to the database - self.logger.info(f"{modstring}") - update_comment_moderation(comment) - processed_at_least_one = True - - return processed_at_least_one diff --git a/pyworker/pyworker/tasks/force_triggers.py b/pyworker/pyworker/tasks/force_triggers.py deleted file mode 100644 index 60dfefd..0000000 --- a/pyworker/pyworker/tasks/force_triggers.py +++ /dev/null @@ -1,43 +0,0 @@ -from pyworker.tasks.base import Task -from pyworker.utils.app_logging import setup_logging - -logger = setup_logging(__name__) - - -class ForceTriggersTask(Task): - """ - Force triggers to run under certain conditions. - """ - - RECENT_LISTED_INTERVAL_DAYS = 15 - - def __init__(self): - super().__init__("force_triggers") - - def run(self) -> bool: - logger.info(f"Starting {self.name} task.") - - # Use the connection provided by the base Task class - if not self.conn: - logger.error("No database connection available") - return False - - update_query = f""" - UPDATE "Service" - SET "isRecentlyListed" = FALSE, "updatedAt" = NOW() - WHERE "isRecentlyListed" = TRUE - AND "listedAt" IS NOT NULL - AND "listedAt" < NOW() - INTERVAL '{self.RECENT_LISTED_INTERVAL_DAYS} days' - """ - try: - with self.conn.cursor() as cursor: - cursor.execute(update_query) - self.conn.commit() - added_count = cursor.rowcount - logger.info(f"Updated {added_count} services.") - except Exception as e: - logger.error(f"Error updating services: {e}") - return False - - logger.info(f"{self.name} task completed successfully.") - return True diff --git a/pyworker/pyworker/tasks/service_score_recalc.py b/pyworker/pyworker/tasks/service_score_recalc.py deleted file mode 100644 index abb8304..0000000 --- a/pyworker/pyworker/tasks/service_score_recalc.py +++ /dev/null @@ -1,325 +0,0 @@ -""" -Task to recalculate service scores based on attribute changes. -""" - -from typing import Optional - -from pyworker.tasks.base import Task -from pyworker.utils.app_logging import setup_logging - -logger = setup_logging(__name__) - - -class ServiceScoreRecalculationTask(Task): - """ - Process pending service score recalculation jobs. - - This task fetches jobs from the ServiceScoreRecalculationJob table - and recalculates service scores using the PostgreSQL functions. - """ - - def __init__(self): - super().__init__("service_score_recalc") - - def run(self, service_id: Optional[int] = None) -> bool: - """ - Process score recalculation jobs from the ServiceScoreRecalculationJob table. - - Args: - service_id: Optional service ID to process only that specific service - - Returns: - bool: True if successful, False otherwise - """ - logger.info(f"Starting {self.name} task.") - processed_count = 0 - error_count = 0 - batch_size = 50 - - # Use the connection provided by the base Task class - if not self.conn: - logger.error("No database connection available") - return False - - try: - # Build query - either for a specific service or all pending jobs - if service_id: - select_query = """ - SELECT id, "serviceId" - FROM "ServiceScoreRecalculationJob" - WHERE "serviceId" = %s AND "processedAt" IS NULL - ORDER BY "createdAt" ASC - """ - params = [service_id] - else: - select_query = """ - SELECT id, "serviceId" - FROM "ServiceScoreRecalculationJob" - WHERE "processedAt" IS NULL - ORDER BY "createdAt" ASC - LIMIT %s - """ - params = [batch_size] - - # Fetch jobs - with self.conn.cursor() as cursor: - cursor.execute(select_query, params) - unprocessed_jobs = cursor.fetchall() - - if not unprocessed_jobs: - logger.info("No pending service score recalculation jobs found.") - return True - - logger.info( - f"Processing {len(unprocessed_jobs)} service score recalculation jobs." - ) - - # Process each job - for job in unprocessed_jobs: - job_id = job[0] # First column is id - svc_id = job[1] # Second column is serviceId - - try: - self._process_service_score(svc_id, job_id) - processed_count += 1 - logger.debug( - f"Successfully processed job {job_id} for service {svc_id}" - ) - except Exception as e: - if self.conn: - self.conn.rollback() - error_count += 1 - logger.error( - f"Error processing job {job_id} for service {svc_id}: {str(e)}", - exc_info=True, - ) - - logger.info( - f"{self.name} task completed. Processed: {processed_count}, Errors: {error_count}" - ) - return processed_count > 0 or error_count == 0 - - except Exception as e: - if self.conn: - self.conn.rollback() - logger.error(f"Failed to run {self.name} task: {str(e)}", exc_info=True) - return False - - def _process_service_score(self, service_id: int, job_id: int) -> None: - """ - Process a single service score recalculation job. - - Args: - service_id: The service ID to recalculate scores for - job_id: The job ID to mark as processed - """ - if not self.conn: - raise ValueError("No database connection available") - - with self.conn.cursor() as cursor: - # 1. Calculate privacy score - cursor.execute("SELECT calculate_privacy_score(%s)", [service_id]) - privacy_score = cursor.fetchone()[0] - - # 2. Calculate trust score - cursor.execute("SELECT calculate_trust_score(%s)", [service_id]) - trust_score = cursor.fetchone()[0] - - # 3. Calculate overall score - cursor.execute( - "SELECT calculate_overall_score(%s, %s, %s)", - [service_id, privacy_score, trust_score], - ) - overall_score = cursor.fetchone()[0] - - # 4. Check for verification status and cap score if needed - cursor.execute( - 'SELECT "verificationStatus" FROM "Service" WHERE id = %s', - [service_id], - ) - result = cursor.fetchone() - if result is None: - logger.warning( - f"Service with ID {service_id} not found. Deleting job {job_id}." - ) - # Delete the job if the service is gone - cursor.execute( - """ - DELETE FROM "ServiceScoreRecalculationJob" - WHERE id = %s - """, - [job_id], - ) - self.conn.commit() - return # Skip the rest of the processing for this job - - status = result[0] - - if status == "VERIFICATION_FAILED": - if overall_score > 3: - overall_score = 3 - elif overall_score < 0: - overall_score = 0 - - # 5. Update the service with recalculated scores - cursor.execute( - """ - UPDATE "Service" - SET "privacyScore" = %s, "trustScore" = %s, "overallScore" = %s - WHERE id = %s - """, - [privacy_score, trust_score, overall_score, service_id], - ) - - # 6. Mark the job as processed - cursor.execute( - """ - UPDATE "ServiceScoreRecalculationJob" - SET "processedAt" = NOW() - WHERE id = %s - """, - [job_id], - ) - - # Commit the transaction - if self.conn: - self.conn.commit() - - def recalculate_all_services(self) -> bool: - """ - Recalculate scores for all active services. - Useful for batch updates after attribute changes. - - Returns: - bool: True if successful, False otherwise - """ - logger.info("Starting recalculation for all active services.") - - if not self.conn: - logger.error("No database connection available") - return False - - try: - # Get all active service IDs - with self.conn.cursor() as cursor: - cursor.execute( - """ - SELECT id - FROM "Service" - WHERE "isActive" = TRUE - """ - ) - services = cursor.fetchall() - - if not services: - logger.info("No active services found.") - return True - - logger.info(f"Found {len(services)} active services to recalculate.") - - # Queue recalculation jobs for all services - inserted_count = 0 - for service in services: - service_id = service[0] - try: - if self.conn: - with self.conn.cursor() as cursor: - cursor.execute( - """ - INSERT INTO "ServiceScoreRecalculationJob" ("serviceId", "createdAt", "processedAt") - VALUES (%s, NOW(), NULL) - ON CONFLICT ("serviceId") DO UPDATE - SET "processedAt" = NULL, "createdAt" = NOW() - """, - [service_id], - ) - self.conn.commit() - inserted_count += 1 - except Exception as e: - if self.conn: - self.conn.rollback() - logger.error( - f"Error queueing job for service {service_id}: {str(e)}" - ) - - logger.info(f"Successfully queued {inserted_count} recalculation jobs.") - return True - - except Exception as e: - if self.conn: - self.conn.rollback() - logger.error(f"Failed to queue recalculation jobs: {str(e)}", exc_info=True) - return False - - def recalculate_for_attribute(self, attribute_id: int) -> bool: - """ - Recalculate scores for all services associated with a specific attribute. - - Args: - attribute_id: The attribute ID to recalculate scores for - - Returns: - bool: True if successful, False otherwise - """ - logger.info( - f"Starting recalculation for services with attribute ID {attribute_id}." - ) - - if not self.conn: - logger.error("No database connection available") - return False - - try: - # Get all services associated with this attribute - with self.conn.cursor() as cursor: - cursor.execute( - """ - SELECT DISTINCT sa."serviceId" - FROM "ServiceAttribute" sa - WHERE sa."attributeId" = %s - """, - [attribute_id], - ) - services = cursor.fetchall() - - if not services: - logger.info(f"No services found with attribute ID {attribute_id}.") - return True - - logger.info( - f"Found {len(services)} services with attribute ID {attribute_id}." - ) - - # Queue recalculation jobs for all services with this attribute - inserted_count = 0 - for service in services: - service_id = service[0] - try: - if self.conn: - with self.conn.cursor() as cursor: - cursor.execute( - """ - INSERT INTO "ServiceScoreRecalculationJob" ("serviceId", "createdAt", "processedAt") - VALUES (%s, NOW(), NULL) - ON CONFLICT ("serviceId") DO UPDATE - SET "processedAt" = NULL, "createdAt" = NOW() - """, - [service_id], - ) - self.conn.commit() - inserted_count += 1 - except Exception as e: - if self.conn: - self.conn.rollback() - logger.error( - f"Error queueing job for service {service_id}: {str(e)}" - ) - - logger.info(f"Successfully queued {inserted_count} recalculation jobs.") - return True - - except Exception as e: - if self.conn: - self.conn.rollback() - logger.error(f"Failed to queue recalculation jobs: {str(e)}", exc_info=True) - return False diff --git a/pyworker/pyworker/tasks/tos_review.py b/pyworker/pyworker/tasks/tos_review.py deleted file mode 100644 index c5d8da9..0000000 --- a/pyworker/pyworker/tasks/tos_review.py +++ /dev/null @@ -1,116 +0,0 @@ -""" -Task for retrieving Terms of Service (TOS) text. -""" - -import hashlib -from typing import Any, Dict, Optional - -from pyworker.database import TosReviewType, save_tos_review, update_kyc_level -from pyworker.tasks.base import Task -from pyworker.utils.ai import prompt_check_tos_review, prompt_tos_review -from pyworker.utils.crawl import fetch_markdown - - -class TosReviewTask(Task): - """Task for retrieving Terms of Service (TOS) text.""" - - def __init__(self): - """Initialize the TOS review task.""" - super().__init__("tos_review") - - def run(self, service: Dict[str, Any]) -> Optional[TosReviewType]: - """ - Review TOS text for a service. - - Args: - service: A dictionary containing service information. - - Returns: - A dictionary mapping TOS URLs to their retrieved text, or None if no TOS URLs. - """ - service_id = service["id"] - service_name = service["name"] - verification_status = service.get("verificationStatus") - - # Only process verified or approved services - if verification_status not in ["VERIFICATION_SUCCESS", "APPROVED"]: - self.logger.info( - f"Skipping TOS review for service: {service_name} (ID: {service_id}) - Status: {verification_status}" - ) - return None - - tos_urls = service.get("tosUrls", []) - - if not tos_urls: - self.logger.info( - f"No TOS URLs found for service: {service_name} (ID: {service_id})" - ) - return None - - self.logger.info( - f"Reviewing TOS for service: {service_name} (ID: {service_id})" - ) - self.logger.info(f"TOS URLs: {tos_urls}") - - for tos_url in tos_urls: - api_url = f"{tos_url}" - self.logger.info(f"Fetching TOS from URL: {api_url}") - - # Sleep for 1 second to avoid rate limiting - content = fetch_markdown(api_url) - - if content: - # Hash the content to avoid repeating the same content - content_hash = hashlib.sha256(content.encode()).hexdigest() - self.logger.info(f"Content hash: {content_hash}") - - # service.get("tosReview") can be None if the DB field is NULL. - # Default to an empty dict to prevent AttributeError on .get() - tos_review_data_from_service: Optional[Dict[str, Any]] = service.get( - "tosReview" - ) - tos_review: Dict[str, Any] = ( - tos_review_data_from_service - if tos_review_data_from_service is not None - else {} - ) - - stored_hash = tos_review.get("contentHash") - - # Skip processing if we've seen this content before - if stored_hash == content_hash: - self.logger.info( - f"Skipping already processed TOS content with hash: {content_hash}" - ) - continue - - # Skip incomplete TOS content - check = prompt_check_tos_review(content) - if not check: - continue - elif not check["isComplete"]: - continue - - # Query OpenAI to summarize the content - review = prompt_tos_review(content) - - if review: - review["contentHash"] = content_hash - # Save the review to the database - save_tos_review(service_id, review) - - # Update the KYC level based on the review - if "kycLevel" in review: - kyc_level = review["kycLevel"] - self.logger.info( - f"Updating KYC level to {kyc_level} for service {service_name}" - ) - update_kyc_level(service_id, kyc_level) - # no need to check other TOS URLs - break - - return review - else: - self.logger.warning( - f"Failed to retrieve TOS content for URL: {tos_url}" - ) diff --git a/pyworker/pyworker/tasks/user_sentiment.py b/pyworker/pyworker/tasks/user_sentiment.py deleted file mode 100644 index 6e20ee6..0000000 --- a/pyworker/pyworker/tasks/user_sentiment.py +++ /dev/null @@ -1,134 +0,0 @@ -""" -Task for summarizing comments and getting overal sentiment -""" - -import json -from datetime import datetime -from typing import Any, Dict, Optional - -from pyworker.database import ( - CommentSentimentSummaryType, - get_comments, - get_max_comment_updated_at, - save_user_sentiment, -) -from pyworker.tasks.base import Task -from pyworker.utils.ai import ( - prompt_comment_sentiment_summary, -) - - -class DateTimeEncoder(json.JSONEncoder): - def default(self, o: Any) -> Any: - if isinstance(o, datetime): - return o.isoformat() - return super().default(o) - - -class UserSentimentTask(Task): - """Task for summarizing comments and getting overal sentiment""" - - def __init__(self): - """Initialize the comment sentiment summary task.""" - super().__init__("comment_sentiment_summary") - - def run(self, service: Dict[str, Any]) -> Optional[CommentSentimentSummaryType]: - """ - Run the comment sentiment summary task. - Skips execution if no new comments are found since the last run. - Clears sentiment if all comments are removed. - """ - service_id = service["id"] - service_name = service["name"] - current_user_sentiment_at: Optional[datetime] = service.get("userSentimentAt") - - if isinstance(current_user_sentiment_at, str): - try: - current_user_sentiment_at = datetime.fromisoformat( - str(current_user_sentiment_at).replace("Z", "+00:00") - ) - except ValueError: - self.logger.warning( - f"Could not parse userSentimentAt string '{current_user_sentiment_at}' for service {service_id}. Treating as None." - ) - current_user_sentiment_at = None - - # Get the timestamp of the most recent approved comment - max_comment_updated_at = get_max_comment_updated_at( - service_id, status="APPROVED" - ) - - self.logger.info( - f"Service {service_name} (ID: {service_id}): Current userSentimentAt: {current_user_sentiment_at}, Max approved comment updatedAt: {max_comment_updated_at}" - ) - - if max_comment_updated_at is None: - self.logger.info( - f"No approved comments found for service {service_name} (ID: {service_id})." - ) - # If there was a sentiment before and now no comments, clear it. - if service.get("userSentiment") is not None: - self.logger.info( - f"Clearing existing sentiment for service {service_name} (ID: {service_id}) as no approved comments are present." - ) - save_user_sentiment(service_id, None, None) - return None - - if ( - current_user_sentiment_at is not None - and max_comment_updated_at <= current_user_sentiment_at - ): - self.logger.info( - f"No new approved comments for service {service_name} (ID: {service_id}) since last sentiment analysis ({current_user_sentiment_at}). Skipping." - ) - # Optionally, return the existing sentiment if needed: - # existing_sentiment = service.get("userSentiment") - # return existing_sentiment if isinstance(existing_sentiment, dict) else None - return None - - # Query the approved comments for the service - # get_comments defaults to status="APPROVED" - comments = get_comments(service_id) - - self.logger.info( - f"Found {len(comments)} comments for service {service_name} (ID: {service_id}) to process." - ) - - if not comments: - # This case could occur if max_comment_updated_at found a comment, - # but get_comments filters it out or it was deleted just before get_comments ran. - self.logger.info( - f"No comments to process for service {service_name} (ID: {service_id}) after fetching (e.g. due to filtering or deletion)." - ) - if service.get("userSentiment") is not None: - self.logger.info( - f"Clearing existing sentiment for service {service_name} (ID: {service_id}) as no processable comments found." - ) - # Use max_comment_updated_at as the reference point for when this check was made. - save_user_sentiment(service_id, None, max_comment_updated_at) - return None - - # Query OpenAI to get the sentiment summary - try: - sentiment_summary = prompt_comment_sentiment_summary( - json.dumps(comments, cls=DateTimeEncoder) - ) - except Exception as e: - self.logger.error( - f"Failed to generate sentiment summary for service {service_name} (ID: {service_id}): {e}" - ) - return None - - if not sentiment_summary: # Defensive check if prompt could return None/empty - self.logger.warning( - f"Sentiment summary generation returned empty for service {service_name} (ID: {service_id})." - ) - return None - - # Save the sentiment summary to the database, using max_comment_updated_at - save_user_sentiment(service_id, sentiment_summary, max_comment_updated_at) - self.logger.info( - f"Successfully processed and saved user sentiment for service {service_name} (ID: {service_id})." - ) - - return sentiment_summary diff --git a/pyworker/pyworker/utils/__init__.py b/pyworker/pyworker/utils/__init__.py deleted file mode 100644 index d381a9c..0000000 --- a/pyworker/pyworker/utils/__init__.py +++ /dev/null @@ -1 +0,0 @@ -"""Utility modules for the pyworker package.""" \ No newline at end of file diff --git a/pyworker/pyworker/utils/ai.py b/pyworker/pyworker/utils/ai.py deleted file mode 100644 index b7025df..0000000 --- a/pyworker/pyworker/utils/ai.py +++ /dev/null @@ -1,261 +0,0 @@ -import os -import time -from typing import Any, Dict, List, Literal, TypedDict, cast - -from json_repair import repair_json -from openai import OpenAI, OpenAIError -from openai.types.chat import ChatCompletionMessageParam - -from pyworker.database import ( - CommentModerationType, - CommentSentimentSummaryType, - TosReviewType, -) -from pyworker.utils.app_logging import setup_logging - -logger = setup_logging(__name__) - - -client = OpenAI( - base_url=os.environ.get("OPENAI_BASE_URL"), - api_key=os.environ.get("OPENAI_API_KEY"), -) - - -def query_openai_json( - messages: List[ChatCompletionMessageParam], - model: str = os.environ.get("OPENAI_MODEL", "deepseek-chat-cheaper"), -) -> Dict[str, Any]: - max_retries = int(os.environ.get("OPENAI_RETRY", 3)) - retry_delay = 30 - last_error = None - - for attempt in range(max_retries): - try: - completion = client.chat.completions.create( - model=model, - messages=messages, - ) - content = completion.choices[0].message.content - if content is None: - raise ValueError("OpenAI response content is None") - - logger.debug(f"Raw AI response content: {content}") - - try: - result = repair_json(content) - - if isinstance(result, str): - import json - - result = json.loads(result) - - if not isinstance(result, dict): - logger.error( - f"Repaired JSON is not a dictionary. Type: {type(result)}, Value: {result}" - ) - raise TypeError( - f"Expected a dictionary from AI response, but got {type(result)}" - ) - - return result - except Exception as e: - logger.error(f"Failed to process JSON response: {e}") - logger.error(f"Raw content was: {content}") - raise - - except (OpenAIError, ValueError, TypeError) as e: - last_error = e - if attempt == max_retries - 1: # Last attempt - logger.error(f"Failed after {max_retries} attempts. Last error: {e}") - raise last_error - logger.warning( - f"Attempt {attempt + 1} failed: {e}. Retrying in {retry_delay} seconds..." - ) - time.sleep(retry_delay) - retry_delay *= 2 # Exponential backoff - - # This line should never be reached due to the raise in the last attempt - raise last_error # type: ignore - - -ReasonType = Literal["js_required", "firewalled", "other"] - - -class TosReviewCheck(TypedDict): - isComplete: bool - - -def prompt_check_tos_review(content: str) -> TosReviewCheck: - messages: List[ChatCompletionMessageParam] = [ - {"role": "system", "content": PROMPT_CHECK_TOS_REVIEW}, - {"role": "user", "content": content}, - ] - - result_dict = query_openai_json(messages, model="openai/gpt-4.1-mini") - - return cast(TosReviewCheck, result_dict) - - -def prompt_tos_review(content: str) -> TosReviewType: - messages: List[ChatCompletionMessageParam] = [ - {"role": "system", "content": PROMPT_TOS_REVIEW}, - {"role": "user", "content": content}, - ] - - result_dict = query_openai_json(messages) - - return cast(TosReviewType, result_dict) - - -def prompt_comment_sentiment_summary(content: str) -> CommentSentimentSummaryType: - messages: List[ChatCompletionMessageParam] = [ - {"role": "system", "content": PROMPT_COMMENT_SENTIMENT_SUMMARY}, - {"role": "user", "content": content}, - ] - - result_dict = query_openai_json(messages) - return cast(CommentSentimentSummaryType, result_dict) - - -def prompt_comment_moderation(content: str) -> CommentModerationType: - messages: List[ChatCompletionMessageParam] = [ - {"role": "system", "content": PROMPT_COMMENT_MODERATION}, - {"role": "user", "content": content}, - ] - - result_dict = query_openai_json(messages) - - return cast(CommentModerationType, result_dict) - - -PROMPT_CHECK_TOS_REVIEW = """ -You will receive the Markdown content of a website page. Determine if the page is a complete. If the page was blocked (e.g. by Cloudflare or similar), incomplete (e.g. requires JavaScript), irrelevant (login/signup/CAPTCHA), set isComplete to false. - -If the page contains meaningful, coherent, valid service information or policy content, with no obvious blocking or truncation, set isComplete to true. - -Return only this JSON and nothing else: - -{"isComplete": true} or {"isComplete": false} -""" - -PROMPT_TOS_REVIEW = """ -You are a privacy analysis AI tasked with reviewing Terms of Service documents. -Your goal is to identify key information about data collection, privacy implications, and user rights. -You are a privacy advocate and you are looking for the most important information for the user in regards to privacy, kyc, self-sovereignity, anonymity, etc. -Analyze the provided Terms of Service and extract the following information: - -1. KYC level is on a scale of 1 to 4: - - **Guaranteed no KYC (Level 0)**: Terms explicitly state KYC will never be requested. - - **No KYC mention (Level 1)**: No mention of current or future KYC requirements. The document does not mention KYC at all. - - **KYC on authorities request (Level 2)**: No routine KYC, but may share data, block funds or reject transactions. Cooperates with authorities. - - **Shotgun KYC (Level 3)**: May request KYC and block funds based on automated transaction flagging system. It is not mandatory by default, but can be requested at any time, for any reason. - - **Mandatory KYC (Level 4)**: Required for key features or for user registration. -2. Overall summary of the terms of service, must be concise and to the point, no more than 250 characters. Use markdown formatting to highlight the most important information. Plain english. -3. Complexity of the terms of service text for a non-technical user, must be a string of 'low', 'medium', 'high'. -4. 'highlights': The important bits of information from the ToS document for the user to know. Always related to privacy, kyc, self-sovereignity, anonymity, custody, censorship resistance, etc. No need to mention these topics, just the important bits of information from the ToS document. - - important things to look for: automated transaction scanning, rejection or block of funds, refund policy (does it require KYC?), data sharing, logging, kyc requirements, etc. - - if No reference to KYC or proof of funds checks is mentioned or required, you don't need to mention it in the highlights, it is already implied from the kycLevel. - - Try to avoid obvious statements that can be infered from other, more important, highlights. Keep it short and concise only with the most important information for the user. - - You must strictly adhere to the document information, do not make up or infer information, do not make assumptions, do not add any information that is not explicitly stated in the document. -Format your response as a valid JSON object with the following structure: - -type TosReview = { - kycLevel: 0 | 1 | 2 | 3 | 4 - /** Less than 200 characters */ - summary: MarkdownString - complexity: 'high' | 'low' | 'medium' - highlights: { - /** Very short title, max 2-3 words */ - title: string - /** Less than 200 characters. Highlight the most important information with markdown formatting. */ - content: MarkdownString - /** In regards to KYC, Privacy, Anonymity, Self-Sovereignity, etc. */ - /** anything that could harm the user's privacy, identity, self-sovereignity or anonymity is negative, anything that otherwise helps is positive. else it is neutral. */ - rating: 'negative' | 'neutral' | 'positive' - }[] -} - -The rating is a number between 0 and 2, where 0 is informative, 1 is warning, and 2 is critical. - -Be concise but thorough, and make sure your output is properly formatted JSON. -""" - -PROMPT_COMMENT_SENTIMENT_SUMMARY = """ -You will be given a list of user comments to a service. -Your task is to summarize the comments in a way that is easy to understand and to the point. -The summary should be concise and to the point, no more than 150 words. -Use markdown formatting to highlight in bold the most important information. Only bold is allowed. - -You must format your response as a valid JSON object with the following structure: - -interface CommentSummary { - summary: string; - sentiment: 'positive'|'negative'|'neutral'; - whatUsersLike: string[]; // Concise, 2-3 words, max 4 - whatUsersDislike: string[]; // Concise, 2-3 words, max 4 -} - -Always avoid repeating information in the list of what users like or dislike. Also, make sure you keep the summary short and concise, no more than 150 words. Ignore irrelevant comments. Make an item for each like/dislike, avoid something like 'No logs / Audited', it should be 'No logs' and 'Audited' as separate items. - -You must return a valid raw JSON object, without any other text or formatting. -""" - -PROMPT_COMMENT_MODERATION = """ -You are kycnot.me’s comment moderation API. Your sole responsibility is to analyze user comments on directory listings (cryptocurrency, anonymity, privacy services) and decide, in strict accordance with the schema and rules below, whether each comment is spam, needs admin review, and its overall quality for our platform. Output ONLY a plain, valid JSON object, with NO markdown, extra text, annotations, or code blocks. - -## Output Schema - -interface CommentModeration { - isSpam: boolean; - requiresAdminReview: boolean; - contextNote: string; - internalNote: string; - commentQuality: 0|1|2|3|4|5|6|7|8|9|10; -} - -## FIELD EXPLANATION - -- isSpam: Mark true if the comment is spam, irrelevant, repetitive, misleading, self-promoting, or fails minimum quality standards. -- requiresAdminReview: Mark true ONLY if the comment reports: service non-functionality, listing inaccuracies, clear scams, exit-scams, critical policy changes, malfunctions, service outages, or sensitive platform issues. If true, always add internalNote to explain why you made this decision. -- contextNote: Optional, visible to users. Add ONLY when clarification or warning is necessary―e.g., unsubstantiated claims or potential spam. -- internalNote: Internal note that is not visible to users. Example: explain why you marked a comment as spam or low quality. You should leave this empty if no relevant information would be added. -- commentQuality: 0 (lowest) to 10 (highest). Rate purely on informativeness, relevance, helpfulness, and evidence. - -## STRICT MODERATION RULES - -- Reject ALL comments that are generic, extremely short, or meaningless on their own, unless replying with added value or genuine context. Examples: "hey", "hello", "hi", "ok", "good", "great", "thanks", "test", "scam"—these are LOW quality and must generally be flagged as spam or rated VERY low, unless context justifies. - - Exception: Replies allowed if they significantly clarify, elaborate, or engage with a previous comment, and ADD new value. -- Comments must provide context, detail, experience, a clear perspective, or evidence. Approve only if the comment adds meaningful insight to the listing’s discussion. -- Mark as spam: - - Meaningless, contextless, very short comments (“hi”, “hey”). - - Comments entirely self-promotional, containing excessive emojis, special characters, random text, or multiple unrelated links. -- Use the surrounding context (such as parent comments, service description, previous discussions) to evaluate if a short comment is a valid reply, or still too low quality to approve. -- Rate "commentQuality" based on: - - 0-2: Meaningless, off-topic, one-word, no value. - - 3-5: Vague, minimal, only slightly relevant, lacking evidence. - - 6-8: Detailed, relevant, some insight or evidence, well-explained. - - 9-10: Exceptionally thorough, informative, well-documented experience. -- For claims (positive or negative) without evidence, add a warning context note: "This comment makes claims without supporting evidence." -- For extended, unstructured, or incoherent text (e.g. spam, or AI-generated nonsense), mark as spam. - -## EXAMPLES - -- "hello": - isSpam: true, internalNote: "Comment provides no value or context.", commentQuality: 0 -- "works": - isSpam: true, internalNote: "Comment too short and contextless.", commentQuality: 0 -- "Service did not work on my device—got error 503.": - isSpam: false, requiresAdminReview: true, commentQuality: 7 -- "Scam!": - isSpam: true, internalNote: "Unsubstantiated, one-word negative claim.", commentQuality: 0, contextNote: "This is a one-word claim without details or evidence." -- "Instant transactions, responsive customer support. Used for 6 months.": - isSpam: false, commentQuality: 8 - -## INSTRUCTIONS - -- Always evaluate if a comment stands on its own, adds value, and has relevance to the listing. Reject one-word, contextless, or “drive-by” comments. -- Replies: Only approve short replies if they directly answer or clarify something above and ADD useful new information. - -Format your output EXACTLY as a raw JSON object using the schema, with NO extra formatting, markdown, or text. -""" diff --git a/pyworker/pyworker/utils/app_http.py b/pyworker/pyworker/utils/app_http.py deleted file mode 100644 index 1edd4ee..0000000 --- a/pyworker/pyworker/utils/app_http.py +++ /dev/null @@ -1,31 +0,0 @@ -""" -HTTP utilities for the pyworker package. -""" - -from typing import Optional - -import requests - -from pyworker.utils.app_logging import setup_logging - -logger = setup_logging(__name__) - - -def fetch_url(url: str, timeout: int = 30) -> Optional[str]: - """ - Fetch content from a URL. - - Args: - url: The URL to fetch. - timeout: The timeout in seconds. - - Returns: - The text content of the response, or None if the request failed. - """ - try: - response = requests.get(url, timeout=timeout) - response.raise_for_status() - return response.text - except requests.RequestException as e: - logger.error(f"Error fetching URL {url}: {e}") - return None diff --git a/pyworker/pyworker/utils/app_logging.py b/pyworker/pyworker/utils/app_logging.py deleted file mode 100644 index cb31d8e..0000000 --- a/pyworker/pyworker/utils/app_logging.py +++ /dev/null @@ -1,36 +0,0 @@ -""" -Logging utilities for the pyworker package. -""" - -import logging -import sys -from pyworker.config import config - -def setup_logging(name: str = "pyworker") -> logging.Logger: - """ - Set up logging for the application. - - Args: - name: The name of the logger. - - Returns: - A configured logger instance. - """ - logger = logging.getLogger(name) - - # Set log level from configuration - log_level = getattr(logging, config.LOG_LEVEL.upper(), logging.INFO) - logger.setLevel(log_level) - - # Create console handler - handler = logging.StreamHandler(sys.stdout) - handler.setLevel(log_level) - - # Create formatter - formatter = logging.Formatter(config.LOG_FORMAT) - handler.setFormatter(formatter) - - # Add handler to logger - logger.addHandler(handler) - - return logger \ No newline at end of file diff --git a/pyworker/pyworker/utils/crawl.py b/pyworker/pyworker/utils/crawl.py deleted file mode 100644 index f2bf6e1..0000000 --- a/pyworker/pyworker/utils/crawl.py +++ /dev/null @@ -1,100 +0,0 @@ -import argparse -import os -import time -import requests -from dotenv import load_dotenv -from pyworker.utils.app_logging import setup_logging -from typing import Any - -logger = setup_logging(__name__) - - -# Load environment variables from .env file -load_dotenv() - -# Include API token header if set -CRAWL4AI_API_TOKEN = os.environ.get("CRAWL4AI_API_TOKEN", "") -HEADERS = ( - {"Authorization": f"Bearer {CRAWL4AI_API_TOKEN}"} if CRAWL4AI_API_TOKEN else {} -) - -CRAWL4AI_BASE_URL = os.environ.get("CRAWL4AI_BASE_URL", "http://crawl4ai:11235") -CRAWL4AI_TIMEOUT = int(os.environ.get("CRAWL4AI_TIMEOUT", 300)) -CRAWL4AI_POLL_INTERVAL = int(os.environ.get("CRAWL4AI_POLL_INTERVAL", 2)) - - -def fetch_fallback(url: str) -> str: - if not url: - raise ValueError("URL must not be empty") - logger.info(f"Fetching fallback for {url}") - fallback_url = f"https://r.jina.ai/{url.lstrip('/')}" - response = requests.get(fallback_url, timeout=80) - response.raise_for_status() - return response.text - - -def fetch_markdown(url: str, wait_for_dynamic_content: bool = True) -> str: - if not CRAWL4AI_API_TOKEN: - return fetch_fallback(url) - - try: - payload: dict[str, Any] = {"urls": url} - if wait_for_dynamic_content: - # According to Crawl4AI docs, wait_for_images=True also waits for network idle state, - # which is helpful for JS-generated content. - # Adding scan_full_page and scroll_delay helps trigger lazy-loaded content. - payload["config"] = { - "wait_for_images": True, - "scan_full_page": True, - "scroll_delay": 0.5, - "magic": True, - } - - response = requests.post( - f"{CRAWL4AI_BASE_URL}/crawl", - json=payload, - headers=HEADERS, - ) - response.raise_for_status() - task_id = response.json().get("task_id") - start_time = time.time() - while True: - if time.time() - start_time > CRAWL4AI_TIMEOUT: - raise TimeoutError(f"Task {task_id} timeout") - status_resp = requests.get( - f"{CRAWL4AI_BASE_URL}/task/{task_id}", - headers=HEADERS, - ) - status_resp.raise_for_status() - status = status_resp.json() - if status.get("status") == "completed": - markdown = status["result"].get("markdown", "") - metadata = status["result"].get("metadata", {}) - return f""" -URL: {url} -Page Metadata: `{metadata}` - -Markdown Content ----------------- -{markdown} - """ - time.sleep(CRAWL4AI_POLL_INTERVAL) - except (requests.exceptions.RequestException, TimeoutError): - return fetch_fallback(url) - - -def main(): - parser = argparse.ArgumentParser( - description="Crawl a URL and print its markdown content." - ) - parser.add_argument("--url", required=True, help="The URL to crawl") - - args = parser.parse_args() - print(f"Crawling {args.url}...") - markdown_content = fetch_markdown(args.url) - print("\n--- Markdown Content ---") - print(markdown_content) - - -if __name__ == "__main__": - main() diff --git a/pyworker/tests/__init__.py b/pyworker/tests/__init__.py deleted file mode 100644 index da44c7f..0000000 --- a/pyworker/tests/__init__.py +++ /dev/null @@ -1 +0,0 @@ -"""Test package for the pyworker.""" \ No newline at end of file diff --git a/pyworker/tests/test_tasks.py b/pyworker/tests/test_tasks.py deleted file mode 100644 index a5c2c51..0000000 --- a/pyworker/tests/test_tasks.py +++ /dev/null @@ -1,74 +0,0 @@ -""" -Tests for task modules. -""" - -import unittest -from unittest.mock import patch, MagicMock -from typing import Dict, Any - -from pyworker.tasks import TosReviewTask - -class TestTosRetrievalTask(unittest.TestCase): - """Tests for the TOS retrieval task.""" - - def setUp(self): - """Set up test fixtures.""" - self.task = TosReviewTask() - self.service = { - 'id': 1, - 'name': 'Test Service', - 'tosUrls': ['test1', 'test2'] - } - - @patch('pyworker.tasks.tos_review.fetch_url') - def test_run_success(self, mock_fetch_url: MagicMock) -> None: - """Test successful TOS retrieval.""" - # Mock the fetch_url function to return test responses - mock_fetch_url.side_effect = ["Test TOS 1", "Test TOS 2"] - - # Run the task - result = self.task.run(self.service) - - # Check that the function was called twice with the correct arguments - self.assertEqual(mock_fetch_url.call_count, 2) - mock_fetch_url.assert_any_call('https://r.jina.ai/test1') - mock_fetch_url.assert_any_call('https://r.jina.ai/test2') - - # Check that the result contains the expected content - self.assertEqual(result, { - 'test1': 'Test TOS 1', - 'test2': 'Test TOS 2' - }) - - @patch('pyworker.tasks.tos_review.fetch_url') - def test_run_failure(self, mock_fetch_url: MagicMock) -> None: - """Test TOS retrieval failure.""" - # Mock the fetch_url function to return None (failure) - mock_fetch_url.return_value = None - - # Run the task - result = self.task.run(self.service) - - # Check that the function was called twice - self.assertEqual(mock_fetch_url.call_count, 2) - - # Check that the result is None since all fetches failed - self.assertIsNone(result) - - def test_run_no_urls(self): - """Test TOS retrieval with no URLs.""" - # Create a service with no TOS URLs - service_no_urls: Dict[str, Any] = { - 'id': 2, - 'name': 'Service With No TOS', - 'tosUrls': [] - } - - # Run the task - result = self.task.run(service_no_urls) - - # Check that the result is None - self.assertIsNone(result) - -if __name__ == '__main__': - unittest.main() \ No newline at end of file diff --git a/pyworker/uv.lock b/pyworker/uv.lock deleted file mode 100644 index 9ee010a..0000000 --- a/pyworker/uv.lock +++ /dev/null @@ -1,414 +0,0 @@ -version = 1 -revision = 1 -requires-python = ">=3.13" - -[[package]] -name = "annotated-types" -version = "0.7.0" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/ee/67/531ea369ba64dcff5ec9c3402f9f51bf748cec26dde048a2f973a4eea7f5/annotated_types-0.7.0.tar.gz", hash = "sha256:aff07c09a53a08bc8cfccb9c85b05f1aa9a2a6f23728d790723543408344ce89", size = 16081 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/78/b6/6307fbef88d9b5ee7421e68d78a9f162e0da4900bc5f5793f6d3d0e34fb8/annotated_types-0.7.0-py3-none-any.whl", hash = "sha256:1f02e8b43a8fbbc3f3e0d4f0f4bfc8131bcb4eebe8849b8e5c773f3a1c582a53", size = 13643 }, -] - -[[package]] -name = "anyio" -version = "4.9.0" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "idna" }, - { name = "sniffio" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/95/7d/4c1bd541d4dffa1b52bd83fb8527089e097a106fc90b467a7313b105f840/anyio-4.9.0.tar.gz", hash = "sha256:673c0c244e15788651a4ff38710fea9675823028a6f08a5eda409e0c9840a028", size = 190949 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/a1/ee/48ca1a7c89ffec8b6a0c5d02b89c305671d5ffd8d3c94acf8b8c408575bb/anyio-4.9.0-py3-none-any.whl", hash = "sha256:9f76d541cad6e36af7beb62e978876f3b41e3e04f2c1fbf0884604c0a9c4d93c", size = 100916 }, -] - -[[package]] -name = "certifi" -version = "2025.1.31" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/1c/ab/c9f1e32b7b1bf505bf26f0ef697775960db7932abeb7b516de930ba2705f/certifi-2025.1.31.tar.gz", hash = "sha256:3d5da6925056f6f18f119200434a4780a94263f10d1c21d032a6f6b2baa20651", size = 167577 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/38/fc/bce832fd4fd99766c04d1ee0eead6b0ec6486fb100ae5e74c1d91292b982/certifi-2025.1.31-py3-none-any.whl", hash = "sha256:ca78db4565a652026a4db2bcdf68f2fb589ea80d0be70e03929ed730746b84fe", size = 166393 }, -] - -[[package]] -name = "charset-normalizer" -version = "3.4.1" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/16/b0/572805e227f01586461c80e0fd25d65a2115599cc9dad142fee4b747c357/charset_normalizer-3.4.1.tar.gz", hash = "sha256:44251f18cd68a75b56585dd00dae26183e102cd5e0f9f1466e6df5da2ed64ea3", size = 123188 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/38/94/ce8e6f63d18049672c76d07d119304e1e2d7c6098f0841b51c666e9f44a0/charset_normalizer-3.4.1-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:aabfa34badd18f1da5ec1bc2715cadc8dca465868a4e73a0173466b688f29dda", size = 195698 }, - { url = "https://files.pythonhosted.org/packages/24/2e/dfdd9770664aae179a96561cc6952ff08f9a8cd09a908f259a9dfa063568/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:22e14b5d70560b8dd51ec22863f370d1e595ac3d024cb8ad7d308b4cd95f8313", size = 140162 }, - { url = "https://files.pythonhosted.org/packages/24/4e/f646b9093cff8fc86f2d60af2de4dc17c759de9d554f130b140ea4738ca6/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:8436c508b408b82d87dc5f62496973a1805cd46727c34440b0d29d8a2f50a6c9", size = 150263 }, - { url = "https://files.pythonhosted.org/packages/5e/67/2937f8d548c3ef6e2f9aab0f6e21001056f692d43282b165e7c56023e6dd/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2d074908e1aecee37a7635990b2c6d504cd4766c7bc9fc86d63f9c09af3fa11b", size = 142966 }, - { url = "https://files.pythonhosted.org/packages/52/ed/b7f4f07de100bdb95c1756d3a4d17b90c1a3c53715c1a476f8738058e0fa/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:955f8851919303c92343d2f66165294848d57e9bba6cf6e3625485a70a038d11", size = 144992 }, - { url = "https://files.pythonhosted.org/packages/96/2c/d49710a6dbcd3776265f4c923bb73ebe83933dfbaa841c5da850fe0fd20b/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:44ecbf16649486d4aebafeaa7ec4c9fed8b88101f4dd612dcaf65d5e815f837f", size = 147162 }, - { url = "https://files.pythonhosted.org/packages/b4/41/35ff1f9a6bd380303dea55e44c4933b4cc3c4850988927d4082ada230273/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:0924e81d3d5e70f8126529951dac65c1010cdf117bb75eb02dd12339b57749dd", size = 140972 }, - { url = "https://files.pythonhosted.org/packages/fb/43/c6a0b685fe6910d08ba971f62cd9c3e862a85770395ba5d9cad4fede33ab/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:2967f74ad52c3b98de4c3b32e1a44e32975e008a9cd2a8cc8966d6a5218c5cb2", size = 149095 }, - { url = "https://files.pythonhosted.org/packages/4c/ff/a9a504662452e2d2878512115638966e75633519ec11f25fca3d2049a94a/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:c75cb2a3e389853835e84a2d8fb2b81a10645b503eca9bcb98df6b5a43eb8886", size = 152668 }, - { url = "https://files.pythonhosted.org/packages/6c/71/189996b6d9a4b932564701628af5cee6716733e9165af1d5e1b285c530ed/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:09b26ae6b1abf0d27570633b2b078a2a20419c99d66fb2823173d73f188ce601", size = 150073 }, - { url = "https://files.pythonhosted.org/packages/e4/93/946a86ce20790e11312c87c75ba68d5f6ad2208cfb52b2d6a2c32840d922/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:fa88b843d6e211393a37219e6a1c1df99d35e8fd90446f1118f4216e307e48cd", size = 145732 }, - { url = "https://files.pythonhosted.org/packages/cd/e5/131d2fb1b0dddafc37be4f3a2fa79aa4c037368be9423061dccadfd90091/charset_normalizer-3.4.1-cp313-cp313-win32.whl", hash = "sha256:eb8178fe3dba6450a3e024e95ac49ed3400e506fd4e9e5c32d30adda88cbd407", size = 95391 }, - { url = "https://files.pythonhosted.org/packages/27/f2/4f9a69cc7712b9b5ad8fdb87039fd89abba997ad5cbe690d1835d40405b0/charset_normalizer-3.4.1-cp313-cp313-win_amd64.whl", hash = "sha256:b1ac5992a838106edb89654e0aebfc24f5848ae2547d22c2c3f66454daa11971", size = 102702 }, - { url = "https://files.pythonhosted.org/packages/0e/f6/65ecc6878a89bb1c23a086ea335ad4bf21a588990c3f535a227b9eea9108/charset_normalizer-3.4.1-py3-none-any.whl", hash = "sha256:d98b1668f06378c6dbefec3b92299716b931cd4e6061f3c875a71ced1780ab85", size = 49767 }, -] - -[[package]] -name = "colorama" -version = "0.4.6" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/d8/53/6f443c9a4a8358a93a6792e2acffb9d9d5cb0a5cfd8802644b7b1c9a02e4/colorama-0.4.6.tar.gz", hash = "sha256:08695f5cb7ed6e0531a20572697297273c47b8cae5a63ffc6d6ed5c201be6e44", size = 27697 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/d1/d6/3965ed04c63042e047cb6a3e6ed1a63a35087b6a609aa3a15ed8ac56c221/colorama-0.4.6-py2.py3-none-any.whl", hash = "sha256:4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6", size = 25335 }, -] - -[[package]] -name = "croniter" -version = "6.0.0" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "python-dateutil" }, - { name = "pytz" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/ad/2f/44d1ae153a0e27be56be43465e5cb39b9650c781e001e7864389deb25090/croniter-6.0.0.tar.gz", hash = "sha256:37c504b313956114a983ece2c2b07790b1f1094fe9d81cc94739214748255577", size = 64481 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/07/4b/290b4c3efd6417a8b0c284896de19b1d5855e6dbdb97d2a35e68fa42de85/croniter-6.0.0-py2.py3-none-any.whl", hash = "sha256:2f878c3856f17896979b2a4379ba1f09c83e374931ea15cc835c5dd2eee9b368", size = 25468 }, -] - -[[package]] -name = "distro" -version = "1.9.0" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/fc/f8/98eea607f65de6527f8a2e8885fc8015d3e6f5775df186e443e0964a11c3/distro-1.9.0.tar.gz", hash = "sha256:2fa77c6fd8940f116ee1d6b94a2f90b13b5ea8d019b98bc8bafdcabcdd9bdbed", size = 60722 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/12/b3/231ffd4ab1fc9d679809f356cebee130ac7daa00d6d6f3206dd4fd137e9e/distro-1.9.0-py3-none-any.whl", hash = "sha256:7bffd925d65168f85027d8da9af6bddab658135b840670a223589bc0c8ef02b2", size = 20277 }, -] - -[[package]] -name = "h11" -version = "0.14.0" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/f5/38/3af3d3633a34a3316095b39c8e8fb4853a28a536e55d347bd8d8e9a14b03/h11-0.14.0.tar.gz", hash = "sha256:8f19fbbe99e72420ff35c00b27a34cb9937e902a8b810e2c88300c6f0a3b699d", size = 100418 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/95/04/ff642e65ad6b90db43e668d70ffb6736436c7ce41fcc549f4e9472234127/h11-0.14.0-py3-none-any.whl", hash = "sha256:e3fe4ac4b851c468cc8363d500db52c2ead036020723024a109d37346efaa761", size = 58259 }, -] - -[[package]] -name = "httpcore" -version = "1.0.8" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "certifi" }, - { name = "h11" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/9f/45/ad3e1b4d448f22c0cff4f5692f5ed0666658578e358b8d58a19846048059/httpcore-1.0.8.tar.gz", hash = "sha256:86e94505ed24ea06514883fd44d2bc02d90e77e7979c8eb71b90f41d364a1bad", size = 85385 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/18/8d/f052b1e336bb2c1fc7ed1aaed898aa570c0b61a09707b108979d9fc6e308/httpcore-1.0.8-py3-none-any.whl", hash = "sha256:5254cf149bcb5f75e9d1b2b9f729ea4a4b883d1ad7379fc632b727cec23674be", size = 78732 }, -] - -[[package]] -name = "httpx" -version = "0.28.1" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "anyio" }, - { name = "certifi" }, - { name = "httpcore" }, - { name = "idna" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/b1/df/48c586a5fe32a0f01324ee087459e112ebb7224f646c0b5023f5e79e9956/httpx-0.28.1.tar.gz", hash = "sha256:75e98c5f16b0f35b567856f597f06ff2270a374470a5c2392242528e3e3e42fc", size = 141406 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/2a/39/e50c7c3a983047577ee07d2a9e53faf5a69493943ec3f6a384bdc792deb2/httpx-0.28.1-py3-none-any.whl", hash = "sha256:d909fcccc110f8c7faf814ca82a9a4d816bc5a6dbfea25d6591d6985b8ba59ad", size = 73517 }, -] - -[[package]] -name = "idna" -version = "3.10" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/f1/70/7703c29685631f5a7590aa73f1f1d3fa9a380e654b86af429e0934a32f7d/idna-3.10.tar.gz", hash = "sha256:12f65c9b470abda6dc35cf8e63cc574b1c52b11df2c86030af0ac09b01b13ea9", size = 190490 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/76/c6/c88e154df9c4e1a2a66ccf0005a88dfb2650c1dffb6f5ce603dfbd452ce3/idna-3.10-py3-none-any.whl", hash = "sha256:946d195a0d259cbba61165e88e65941f16e9b36ea6ddb97f00452bae8b1287d3", size = 70442 }, -] - -[[package]] -name = "jiter" -version = "0.9.0" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/1e/c2/e4562507f52f0af7036da125bb699602ead37a2332af0788f8e0a3417f36/jiter-0.9.0.tar.gz", hash = "sha256:aadba0964deb424daa24492abc3d229c60c4a31bfee205aedbf1acc7639d7893", size = 162604 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/e7/1b/4cd165c362e8f2f520fdb43245e2b414f42a255921248b4f8b9c8d871ff1/jiter-0.9.0-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:2764891d3f3e8b18dce2cff24949153ee30c9239da7c00f032511091ba688ff7", size = 308197 }, - { url = "https://files.pythonhosted.org/packages/13/aa/7a890dfe29c84c9a82064a9fe36079c7c0309c91b70c380dc138f9bea44a/jiter-0.9.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:387b22fbfd7a62418d5212b4638026d01723761c75c1c8232a8b8c37c2f1003b", size = 318160 }, - { url = "https://files.pythonhosted.org/packages/6a/38/5888b43fc01102f733f085673c4f0be5a298f69808ec63de55051754e390/jiter-0.9.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:40d8da8629ccae3606c61d9184970423655fb4e33d03330bcdfe52d234d32f69", size = 341259 }, - { url = "https://files.pythonhosted.org/packages/3d/5e/bbdbb63305bcc01006de683b6228cd061458b9b7bb9b8d9bc348a58e5dc2/jiter-0.9.0-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:a1be73d8982bdc278b7b9377426a4b44ceb5c7952073dd7488e4ae96b88e1103", size = 363730 }, - { url = "https://files.pythonhosted.org/packages/75/85/53a3edc616992fe4af6814c25f91ee3b1e22f7678e979b6ea82d3bc0667e/jiter-0.9.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:2228eaaaa111ec54b9e89f7481bffb3972e9059301a878d085b2b449fbbde635", size = 405126 }, - { url = "https://files.pythonhosted.org/packages/ae/b3/1ee26b12b2693bd3f0b71d3188e4e5d817b12e3c630a09e099e0a89e28fa/jiter-0.9.0-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:11509bfecbc319459647d4ac3fd391d26fdf530dad00c13c4dadabf5b81f01a4", size = 393668 }, - { url = "https://files.pythonhosted.org/packages/11/87/e084ce261950c1861773ab534d49127d1517b629478304d328493f980791/jiter-0.9.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3f22238da568be8bbd8e0650e12feeb2cfea15eda4f9fc271d3b362a4fa0604d", size = 352350 }, - { url = "https://files.pythonhosted.org/packages/f0/06/7dca84b04987e9df563610aa0bc154ea176e50358af532ab40ffb87434df/jiter-0.9.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:17f5d55eb856597607562257c8e36c42bc87f16bef52ef7129b7da11afc779f3", size = 384204 }, - { url = "https://files.pythonhosted.org/packages/16/2f/82e1c6020db72f397dd070eec0c85ebc4df7c88967bc86d3ce9864148f28/jiter-0.9.0-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:6a99bed9fbb02f5bed416d137944419a69aa4c423e44189bc49718859ea83bc5", size = 520322 }, - { url = "https://files.pythonhosted.org/packages/36/fd/4f0cd3abe83ce208991ca61e7e5df915aa35b67f1c0633eb7cf2f2e88ec7/jiter-0.9.0-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:e057adb0cd1bd39606100be0eafe742de2de88c79df632955b9ab53a086b3c8d", size = 512184 }, - { url = "https://files.pythonhosted.org/packages/a0/3c/8a56f6d547731a0b4410a2d9d16bf39c861046f91f57c98f7cab3d2aa9ce/jiter-0.9.0-cp313-cp313-win32.whl", hash = "sha256:f7e6850991f3940f62d387ccfa54d1a92bd4bb9f89690b53aea36b4364bcab53", size = 206504 }, - { url = "https://files.pythonhosted.org/packages/f4/1c/0c996fd90639acda75ed7fa698ee5fd7d80243057185dc2f63d4c1c9f6b9/jiter-0.9.0-cp313-cp313-win_amd64.whl", hash = "sha256:c8ae3bf27cd1ac5e6e8b7a27487bf3ab5f82318211ec2e1346a5b058756361f7", size = 204943 }, - { url = "https://files.pythonhosted.org/packages/78/0f/77a63ca7aa5fed9a1b9135af57e190d905bcd3702b36aca46a01090d39ad/jiter-0.9.0-cp313-cp313t-macosx_11_0_arm64.whl", hash = "sha256:f0b2827fb88dda2cbecbbc3e596ef08d69bda06c6f57930aec8e79505dc17001", size = 317281 }, - { url = "https://files.pythonhosted.org/packages/f9/39/a3a1571712c2bf6ec4c657f0d66da114a63a2e32b7e4eb8e0b83295ee034/jiter-0.9.0-cp313-cp313t-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:062b756ceb1d40b0b28f326cba26cfd575a4918415b036464a52f08632731e5a", size = 350273 }, - { url = "https://files.pythonhosted.org/packages/ee/47/3729f00f35a696e68da15d64eb9283c330e776f3b5789bac7f2c0c4df209/jiter-0.9.0-cp313-cp313t-win_amd64.whl", hash = "sha256:6f7838bc467ab7e8ef9f387bd6de195c43bad82a569c1699cb822f6609dd4cdf", size = 206867 }, -] - -[[package]] -name = "json-repair" -version = "0.41.1" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/6d/6a/6c7a75a10da6dc807b582f2449034da1ed74415e8899746bdfff97109012/json_repair-0.41.1.tar.gz", hash = "sha256:bba404b0888c84a6b86ecc02ec43b71b673cfee463baf6da94e079c55b136565", size = 31208 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/10/5c/abd7495c934d9af5c263c2245ae30cfaa716c3c0cf027b2b8fa686ee7bd4/json_repair-0.41.1-py3-none-any.whl", hash = "sha256:0e181fd43a696887881fe19fed23422a54b3e4c558b6ff27a86a8c3ddde9ae79", size = 21578 }, -] - -[[package]] -name = "openai" -version = "1.74.0" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "anyio" }, - { name = "distro" }, - { name = "httpx" }, - { name = "jiter" }, - { name = "pydantic" }, - { name = "sniffio" }, - { name = "tqdm" }, - { name = "typing-extensions" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/75/86/c605a6e84da0248f2cebfcd864b5a6076ecf78849245af5e11d2a5ec7977/openai-1.74.0.tar.gz", hash = "sha256:592c25b8747a7cad33a841958f5eb859a785caea9ee22b9e4f4a2ec062236526", size = 427571 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/a9/91/8c150f16a96367e14bd7d20e86e0bbbec3080e3eb593e63f21a7f013f8e4/openai-1.74.0-py3-none-any.whl", hash = "sha256:aff3e0f9fb209836382ec112778667027f4fd6ae38bdb2334bc9e173598b092a", size = 644790 }, -] - -[[package]] -name = "psycopg" -version = "3.2.6" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "tzdata", marker = "sys_platform == 'win32'" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/67/97/eea08f74f1c6dd2a02ee81b4ebfe5b558beb468ebbd11031adbf58d31be0/psycopg-3.2.6.tar.gz", hash = "sha256:16fa094efa2698f260f2af74f3710f781e4a6f226efe9d1fd0c37f384639ed8a", size = 156322 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/d7/7d/0ba52deff71f65df8ec8038adad86ba09368c945424a9bd8145d679a2c6a/psycopg-3.2.6-py3-none-any.whl", hash = "sha256:f3ff5488525890abb0566c429146add66b329e20d6d4835662b920cbbf90ac58", size = 199077 }, -] - -[package.optional-dependencies] -binary = [ - { name = "psycopg-binary", marker = "implementation_name != 'pypy'" }, -] -pool = [ - { name = "psycopg-pool" }, -] - -[[package]] -name = "psycopg-binary" -version = "3.2.6" -source = { registry = "https://pypi.org/simple" } -wheels = [ - { url = "https://files.pythonhosted.org/packages/bf/32/3d06c478fd3070ac25a49c2e8ca46b6d76b0048fa9fa255b99ee32f32312/psycopg_binary-3.2.6-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:54af3fbf871baa2eb19df96fd7dc0cbd88e628a692063c3d1ab5cdd00aa04322", size = 3852672 }, - { url = "https://files.pythonhosted.org/packages/34/97/e581030e279500ede3096adb510f0e6071874b97cfc047a9a87b7d71fc77/psycopg_binary-3.2.6-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:ad5da1e4636776c21eaeacdec42f25fa4612631a12f25cd9ab34ddf2c346ffb9", size = 3936562 }, - { url = "https://files.pythonhosted.org/packages/74/b6/6a8df4cb23c3d327403a83406c06c9140f311cb56c4e4d720ee7abf6fddc/psycopg_binary-3.2.6-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f7956b9ea56f79cd86eddcfbfc65ae2af1e4fe7932fa400755005d903c709370", size = 4499167 }, - { url = "https://files.pythonhosted.org/packages/e4/5b/950eafef61e5e0b8ddb5afc5b6b279756411aa4bf70a346a6f091ad679bb/psycopg_binary-3.2.6-cp313-cp313-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1e2efb763188008cf2914820dcb9fb23c10fe2be0d2c97ef0fac7cec28e281d8", size = 4311651 }, - { url = "https://files.pythonhosted.org/packages/72/b9/b366c49afc854c26b3053d4d35376046eea9aebdc48ded18ea249ea1f80c/psycopg_binary-3.2.6-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:4b3aab3451679f1e7932270e950259ed48c3b79390022d3f660491c0e65e4838", size = 4547852 }, - { url = "https://files.pythonhosted.org/packages/ab/d4/0e047360e2ea387dc7171ca017ffcee5214a0762f74b9dd982035f2e52fb/psycopg_binary-3.2.6-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:849a370ac4e125f55f2ad37f928e588291a67ccf91fa33d0b1e042bb3ee1f986", size = 4261725 }, - { url = "https://files.pythonhosted.org/packages/e3/ea/a1b969804250183900959ebe845d86be7fed2cbd9be58f64cd0fc24b2892/psycopg_binary-3.2.6-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:566d4ace928419d91f1eb3227fc9ef7b41cf0ad22e93dd2c3368d693cf144408", size = 3850073 }, - { url = "https://files.pythonhosted.org/packages/e5/71/ec2907342f0675092b76aea74365b56f38d960c4c635984dcfe25d8178c8/psycopg_binary-3.2.6-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:f1981f13b10de2f11cfa2f99a8738b35b3f0a0f3075861446894a8d3042430c0", size = 3320323 }, - { url = "https://files.pythonhosted.org/packages/d7/d7/0d2cb4b42f231e2efe8ea1799ce917973d47486212a2c4d33cd331e7ac28/psycopg_binary-3.2.6-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:36f598300b55b3c983ae8df06473ad27333d2fd9f3e2cfdb913b3a5aaa3a8bcf", size = 3402335 }, - { url = "https://files.pythonhosted.org/packages/66/92/7050c372f78e53eba14695cec6c3a91b2d9ca56feaf0bfe95fe90facf730/psycopg_binary-3.2.6-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:0f4699fa5fe1fffb0d6b2d14b31fd8c29b7ea7375f89d5989f002aaf21728b21", size = 3440442 }, - { url = "https://files.pythonhosted.org/packages/5f/4c/bebcaf754189283b2f3d457822a3d9b233d08ff50973d8f1e8d51f4d35ed/psycopg_binary-3.2.6-cp313-cp313-win_amd64.whl", hash = "sha256:afe697b8b0071f497c5d4c0f41df9e038391534f5614f7fb3a8c1ca32d66e860", size = 2783465 }, -] - -[[package]] -name = "psycopg-pool" -version = "3.2.6" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "typing-extensions" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/cf/13/1e7850bb2c69a63267c3dbf37387d3f71a00fd0e2fa55c5db14d64ba1af4/psycopg_pool-3.2.6.tar.gz", hash = "sha256:0f92a7817719517212fbfe2fd58b8c35c1850cdd2a80d36b581ba2085d9148e5", size = 29770 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/47/fd/4feb52a55c1a4bd748f2acaed1903ab54a723c47f6d0242780f4d97104d4/psycopg_pool-3.2.6-py3-none-any.whl", hash = "sha256:5887318a9f6af906d041a0b1dc1c60f8f0dda8340c2572b74e10907b51ed5da7", size = 38252 }, -] - -[[package]] -name = "pydantic" -version = "2.11.3" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "annotated-types" }, - { name = "pydantic-core" }, - { name = "typing-extensions" }, - { name = "typing-inspection" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/10/2e/ca897f093ee6c5f3b0bee123ee4465c50e75431c3d5b6a3b44a47134e891/pydantic-2.11.3.tar.gz", hash = "sha256:7471657138c16adad9322fe3070c0116dd6c3ad8d649300e3cbdfe91f4db4ec3", size = 785513 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/b0/1d/407b29780a289868ed696d1616f4aad49d6388e5a77f567dcd2629dcd7b8/pydantic-2.11.3-py3-none-any.whl", hash = "sha256:a082753436a07f9ba1289c6ffa01cd93db3548776088aa917cc43b63f68fa60f", size = 443591 }, -] - -[[package]] -name = "pydantic-core" -version = "2.33.1" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "typing-extensions" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/17/19/ed6a078a5287aea7922de6841ef4c06157931622c89c2a47940837b5eecd/pydantic_core-2.33.1.tar.gz", hash = "sha256:bcc9c6fdb0ced789245b02b7d6603e17d1563064ddcfc36f046b61c0c05dd9df", size = 434395 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/7a/24/eed3466a4308d79155f1cdd5c7432c80ddcc4530ba8623b79d5ced021641/pydantic_core-2.33.1-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:70af6a21237b53d1fe7b9325b20e65cbf2f0a848cf77bed492b029139701e66a", size = 2033551 }, - { url = "https://files.pythonhosted.org/packages/ab/14/df54b1a0bc9b6ded9b758b73139d2c11b4e8eb43e8ab9c5847c0a2913ada/pydantic_core-2.33.1-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:282b3fe1bbbe5ae35224a0dbd05aed9ccabccd241e8e6b60370484234b456266", size = 1852785 }, - { url = "https://files.pythonhosted.org/packages/fa/96/e275f15ff3d34bb04b0125d9bc8848bf69f25d784d92a63676112451bfb9/pydantic_core-2.33.1-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4b315e596282bbb5822d0c7ee9d255595bd7506d1cb20c2911a4da0b970187d3", size = 1897758 }, - { url = "https://files.pythonhosted.org/packages/b7/d8/96bc536e975b69e3a924b507d2a19aedbf50b24e08c80fb00e35f9baaed8/pydantic_core-2.33.1-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:1dfae24cf9921875ca0ca6a8ecb4bb2f13c855794ed0d468d6abbec6e6dcd44a", size = 1986109 }, - { url = "https://files.pythonhosted.org/packages/90/72/ab58e43ce7e900b88cb571ed057b2fcd0e95b708a2e0bed475b10130393e/pydantic_core-2.33.1-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:6dd8ecfde08d8bfadaea669e83c63939af76f4cf5538a72597016edfa3fad516", size = 2129159 }, - { url = "https://files.pythonhosted.org/packages/dc/3f/52d85781406886c6870ac995ec0ba7ccc028b530b0798c9080531b409fdb/pydantic_core-2.33.1-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2f593494876eae852dc98c43c6f260f45abdbfeec9e4324e31a481d948214764", size = 2680222 }, - { url = "https://files.pythonhosted.org/packages/f4/56/6e2ef42f363a0eec0fd92f74a91e0ac48cd2e49b695aac1509ad81eee86a/pydantic_core-2.33.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:948b73114f47fd7016088e5186d13faf5e1b2fe83f5e320e371f035557fd264d", size = 2006980 }, - { url = "https://files.pythonhosted.org/packages/4c/c0/604536c4379cc78359f9ee0aa319f4aedf6b652ec2854953f5a14fc38c5a/pydantic_core-2.33.1-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:e11f3864eb516af21b01e25fac915a82e9ddad3bb0fb9e95a246067398b435a4", size = 2120840 }, - { url = "https://files.pythonhosted.org/packages/1f/46/9eb764814f508f0edfb291a0f75d10854d78113fa13900ce13729aaec3ae/pydantic_core-2.33.1-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:549150be302428b56fdad0c23c2741dcdb5572413776826c965619a25d9c6bde", size = 2072518 }, - { url = "https://files.pythonhosted.org/packages/42/e3/fb6b2a732b82d1666fa6bf53e3627867ea3131c5f39f98ce92141e3e3dc1/pydantic_core-2.33.1-cp313-cp313-musllinux_1_1_armv7l.whl", hash = "sha256:495bc156026efafd9ef2d82372bd38afce78ddd82bf28ef5276c469e57c0c83e", size = 2248025 }, - { url = "https://files.pythonhosted.org/packages/5c/9d/fbe8fe9d1aa4dac88723f10a921bc7418bd3378a567cb5e21193a3c48b43/pydantic_core-2.33.1-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:ec79de2a8680b1a67a07490bddf9636d5c2fab609ba8c57597e855fa5fa4dacd", size = 2254991 }, - { url = "https://files.pythonhosted.org/packages/aa/99/07e2237b8a66438d9b26482332cda99a9acccb58d284af7bc7c946a42fd3/pydantic_core-2.33.1-cp313-cp313-win32.whl", hash = "sha256:ee12a7be1742f81b8a65b36c6921022301d466b82d80315d215c4c691724986f", size = 1915262 }, - { url = "https://files.pythonhosted.org/packages/8a/f4/e457a7849beeed1e5defbcf5051c6f7b3c91a0624dd31543a64fc9adcf52/pydantic_core-2.33.1-cp313-cp313-win_amd64.whl", hash = "sha256:ede9b407e39949d2afc46385ce6bd6e11588660c26f80576c11c958e6647bc40", size = 1956626 }, - { url = "https://files.pythonhosted.org/packages/20/d0/e8d567a7cff7b04e017ae164d98011f1e1894269fe8e90ea187a3cbfb562/pydantic_core-2.33.1-cp313-cp313-win_arm64.whl", hash = "sha256:aa687a23d4b7871a00e03ca96a09cad0f28f443690d300500603bd0adba4b523", size = 1909590 }, - { url = "https://files.pythonhosted.org/packages/ef/fd/24ea4302d7a527d672c5be06e17df16aabfb4e9fdc6e0b345c21580f3d2a/pydantic_core-2.33.1-cp313-cp313t-macosx_11_0_arm64.whl", hash = "sha256:401d7b76e1000d0dd5538e6381d28febdcacb097c8d340dde7d7fc6e13e9f95d", size = 1812963 }, - { url = "https://files.pythonhosted.org/packages/5f/95/4fbc2ecdeb5c1c53f1175a32d870250194eb2fdf6291b795ab08c8646d5d/pydantic_core-2.33.1-cp313-cp313t-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7aeb055a42d734c0255c9e489ac67e75397d59c6fbe60d155851e9782f276a9c", size = 1986896 }, - { url = "https://files.pythonhosted.org/packages/71/ae/fe31e7f4a62431222d8f65a3bd02e3fa7e6026d154a00818e6d30520ea77/pydantic_core-2.33.1-cp313-cp313t-win_amd64.whl", hash = "sha256:338ea9b73e6e109f15ab439e62cb3b78aa752c7fd9536794112e14bee02c8d18", size = 1931810 }, -] - -[[package]] -name = "python-dateutil" -version = "2.9.0.post0" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "six" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/66/c0/0c8b6ad9f17a802ee498c46e004a0eb49bc148f2fd230864601a86dcf6db/python-dateutil-2.9.0.post0.tar.gz", hash = "sha256:37dd54208da7e1cd875388217d5e00ebd4179249f90fb72437e91a35459a0ad3", size = 342432 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/ec/57/56b9bcc3c9c6a792fcbaf139543cee77261f3651ca9da0c93f5c1221264b/python_dateutil-2.9.0.post0-py2.py3-none-any.whl", hash = "sha256:a8b2bc7bffae282281c8140a97d3aa9c14da0b136dfe83f850eea9a5f7470427", size = 229892 }, -] - -[[package]] -name = "python-dotenv" -version = "1.1.0" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/88/2c/7bb1416c5620485aa793f2de31d3df393d3686aa8a8506d11e10e13c5baf/python_dotenv-1.1.0.tar.gz", hash = "sha256:41f90bc6f5f177fb41f53e87666db362025010eb28f60a01c9143bfa33a2b2d5", size = 39920 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/1e/18/98a99ad95133c6a6e2005fe89faedf294a748bd5dc803008059409ac9b1e/python_dotenv-1.1.0-py3-none-any.whl", hash = "sha256:d7c01d9e2293916c18baf562d95698754b0dbbb5e74d457c45d4f6561fb9d55d", size = 20256 }, -] - -[[package]] -name = "pytz" -version = "2025.2" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/f8/bf/abbd3cdfb8fbc7fb3d4d38d320f2441b1e7cbe29be4f23797b4a2b5d8aac/pytz-2025.2.tar.gz", hash = "sha256:360b9e3dbb49a209c21ad61809c7fb453643e048b38924c765813546746e81c3", size = 320884 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/81/c4/34e93fe5f5429d7570ec1fa436f1986fb1f00c3e0f43a589fe2bbcd22c3f/pytz-2025.2-py2.py3-none-any.whl", hash = "sha256:5ddf76296dd8c44c26eb8f4b6f35488f3ccbf6fbbd7adee0b7262d43f0ec2f00", size = 509225 }, -] - -[[package]] -name = "pyworker" -version = "0.1.0" -source = { editable = "." } -dependencies = [ - { name = "croniter" }, - { name = "json-repair" }, - { name = "openai" }, - { name = "psycopg", extra = ["binary", "pool"] }, - { name = "python-dotenv" }, - { name = "requests" }, -] - -[package.metadata] -requires-dist = [ - { name = "croniter", specifier = ">=6.0.0" }, - { name = "json-repair", specifier = ">=0.41.1" }, - { name = "openai", specifier = ">=1.74.0" }, - { name = "psycopg", extras = ["binary", "pool"], specifier = ">=3.2.6" }, - { name = "python-dotenv", specifier = ">=1.1.0" }, - { name = "requests", specifier = ">=2.32.3" }, -] - -[[package]] -name = "requests" -version = "2.32.3" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "certifi" }, - { name = "charset-normalizer" }, - { name = "idna" }, - { name = "urllib3" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/63/70/2bf7780ad2d390a8d301ad0b550f1581eadbd9a20f896afe06353c2a2913/requests-2.32.3.tar.gz", hash = "sha256:55365417734eb18255590a9ff9eb97e9e1da868d4ccd6402399eaf68af20a760", size = 131218 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/f9/9b/335f9764261e915ed497fcdeb11df5dfd6f7bf257d4a6a2a686d80da4d54/requests-2.32.3-py3-none-any.whl", hash = "sha256:70761cfe03c773ceb22aa2f671b4757976145175cdfca038c02654d061d6dcc6", size = 64928 }, -] - -[[package]] -name = "six" -version = "1.17.0" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/94/e7/b2c673351809dca68a0e064b6af791aa332cf192da575fd474ed7d6f16a2/six-1.17.0.tar.gz", hash = "sha256:ff70335d468e7eb6ec65b95b99d3a2836546063f63acc5171de367e834932a81", size = 34031 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/b7/ce/149a00dd41f10bc29e5921b496af8b574d8413afcd5e30dfa0ed46c2cc5e/six-1.17.0-py2.py3-none-any.whl", hash = "sha256:4721f391ed90541fddacab5acf947aa0d3dc7d27b2e1e8eda2be8970586c3274", size = 11050 }, -] - -[[package]] -name = "sniffio" -version = "1.3.1" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/a2/87/a6771e1546d97e7e041b6ae58d80074f81b7d5121207425c964ddf5cfdbd/sniffio-1.3.1.tar.gz", hash = "sha256:f4324edc670a0f49750a81b895f35c3adb843cca46f0530f79fc1babb23789dc", size = 20372 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/e9/44/75a9c9421471a6c4805dbf2356f7c181a29c1879239abab1ea2cc8f38b40/sniffio-1.3.1-py3-none-any.whl", hash = "sha256:2f6da418d1f1e0fddd844478f41680e794e6051915791a034ff65e5f100525a2", size = 10235 }, -] - -[[package]] -name = "tqdm" -version = "4.67.1" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "colorama", marker = "sys_platform == 'win32'" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/a8/4b/29b4ef32e036bb34e4ab51796dd745cdba7ed47ad142a9f4a1eb8e0c744d/tqdm-4.67.1.tar.gz", hash = "sha256:f8aef9c52c08c13a65f30ea34f4e5aac3fd1a34959879d7e59e63027286627f2", size = 169737 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/d0/30/dc54f88dd4a2b5dc8a0279bdd7270e735851848b762aeb1c1184ed1f6b14/tqdm-4.67.1-py3-none-any.whl", hash = "sha256:26445eca388f82e72884e0d580d5464cd801a3ea01e63e5601bdff9ba6a48de2", size = 78540 }, -] - -[[package]] -name = "typing-extensions" -version = "4.13.2" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/f6/37/23083fcd6e35492953e8d2aaaa68b860eb422b34627b13f2ce3eb6106061/typing_extensions-4.13.2.tar.gz", hash = "sha256:e6c81219bd689f51865d9e372991c540bda33a0379d5573cddb9a3a23f7caaef", size = 106967 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/8b/54/b1ae86c0973cc6f0210b53d508ca3641fb6d0c56823f288d108bc7ab3cc8/typing_extensions-4.13.2-py3-none-any.whl", hash = "sha256:a439e7c04b49fec3e5d3e2beaa21755cadbbdc391694e28ccdd36ca4a1408f8c", size = 45806 }, -] - -[[package]] -name = "typing-inspection" -version = "0.4.0" -source = { registry = "https://pypi.org/simple" } -dependencies = [ - { name = "typing-extensions" }, -] -sdist = { url = "https://files.pythonhosted.org/packages/82/5c/e6082df02e215b846b4b8c0b887a64d7d08ffaba30605502639d44c06b82/typing_inspection-0.4.0.tar.gz", hash = "sha256:9765c87de36671694a67904bf2c96e395be9c6439bb6c87b5142569dcdd65122", size = 76222 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/31/08/aa4fdfb71f7de5176385bd9e90852eaf6b5d622735020ad600f2bab54385/typing_inspection-0.4.0-py3-none-any.whl", hash = "sha256:50e72559fcd2a6367a19f7a7e610e6afcb9fac940c650290eed893d61386832f", size = 14125 }, -] - -[[package]] -name = "tzdata" -version = "2025.2" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/95/32/1a225d6164441be760d75c2c42e2780dc0873fe382da3e98a2e1e48361e5/tzdata-2025.2.tar.gz", hash = "sha256:b60a638fcc0daffadf82fe0f57e53d06bdec2f36c4df66280ae79bce6bd6f2b9", size = 196380 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/5c/23/c7abc0ca0a1526a0774eca151daeb8de62ec457e77262b66b359c3c7679e/tzdata-2025.2-py2.py3-none-any.whl", hash = "sha256:1a403fada01ff9221ca8044d701868fa132215d84beb92242d9acd2147f667a8", size = 347839 }, -] - -[[package]] -name = "urllib3" -version = "2.4.0" -source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/8a/78/16493d9c386d8e60e442a35feac5e00f0913c0f4b7c217c11e8ec2ff53e0/urllib3-2.4.0.tar.gz", hash = "sha256:414bc6535b787febd7567804cc015fee39daab8ad86268f1310a9250697de466", size = 390672 } -wheels = [ - { url = "https://files.pythonhosted.org/packages/6b/11/cc635220681e93a0183390e26485430ca2c7b5f9d33b15c74c2861cb8091/urllib3-2.4.0-py3-none-any.whl", hash = "sha256:4e16665048960a0900c702d4a66415956a584919c03361cac9f1df5c5dd7e813", size = 128680 }, -] diff --git a/web/.dockerignore b/web/.dockerignore deleted file mode 100644 index 15434de..0000000 --- a/web/.dockerignore +++ /dev/null @@ -1,28 +0,0 @@ -# build output -dist/ -# generated types -.astro/ - -# dependencies -node_modules/ - -# local only data -local_data/ - -# logs -npm-debug.log* -yarn-debug.log* -yarn-error.log* -pnpm-debug.log* - - -# environment variables -.env.production - -# macOS-specific files -.DS_Store - -# jetbrains setting folder -.idea/ - -*.example \ No newline at end of file diff --git a/web/.env.example b/web/.env.example deleted file mode 100644 index 56f0455..0000000 --- a/web/.env.example +++ /dev/null @@ -1,4 +0,0 @@ -DATABASE_URL="postgresql://kycnot:kycnot@localhost:3399/kycnot?schema=public" -REDIS_URL="redis://localhost:6379" -SOURCE_CODE_URL="https://github.com" -SITE_URL="https://localhost:4321" \ No newline at end of file diff --git a/web/.gitignore b/web/.gitignore deleted file mode 100644 index 3d9f235..0000000 --- a/web/.gitignore +++ /dev/null @@ -1,31 +0,0 @@ -# build output -dist/ -# generated types -.astro/ - -# dependencies -node_modules/ - -# local only data -local_data/ - -# logs -npm-debug.log* -yarn-debug.log* -yarn-error.log* -pnpm-debug.log* - - -# environment variables -.env -.env.production - -# macOS-specific files -.DS_Store - -# jetbrains setting folder -.idea/ - -local_uploads/ -!local_uploads/.gitkeep -uploads/ \ No newline at end of file diff --git a/web/.npmrc b/web/.npmrc deleted file mode 100644 index cffe8cd..0000000 --- a/web/.npmrc +++ /dev/null @@ -1 +0,0 @@ -save-exact=true diff --git a/web/.nvmrc b/web/.nvmrc deleted file mode 100644 index 4099407..0000000 --- a/web/.nvmrc +++ /dev/null @@ -1 +0,0 @@ -23 diff --git a/web/.prettierignore b/web/.prettierignore deleted file mode 100644 index c2c7bde..0000000 --- a/web/.prettierignore +++ /dev/null @@ -1,5 +0,0 @@ -web/public/ -.git/ -package-lock.json -local_data/ -.astro/ diff --git a/web/.prettierrc.mjs b/web/.prettierrc.mjs deleted file mode 100644 index a03aa12..0000000 --- a/web/.prettierrc.mjs +++ /dev/null @@ -1,22 +0,0 @@ -// @ts-check - -/** @type {import("prettier").Config} */ -export default { - plugins: ['prettier-plugin-astro', 'prettier-plugin-tailwindcss'], - overrides: [ - { - files: '*.astro', - options: { - parser: 'astro', - }, - }, - ], - tailwindFunctions: ['cn', 'clsx', 'tv'], - singleQuote: true, - semi: false, - tabWidth: 2, - trailingComma: 'es5', - printWidth: 110, - bracketSpacing: true, - endOfLine: 'lf', -} diff --git a/web/Dockerfile b/web/Dockerfile deleted file mode 100644 index 07585de..0000000 --- a/web/Dockerfile +++ /dev/null @@ -1,27 +0,0 @@ -FROM node:lts AS runtime -WORKDIR /app - -COPY package.json package-lock.json ./ - -COPY .npmrc .npmrc - -RUN npm ci - -COPY . . - -ARG ASTRO_BUILD_MODE=production -# Generate Prisma client -RUN npx prisma generate -# Build the application -RUN npm run build -- --mode ${ASTRO_BUILD_MODE} - -ENV HOST=0.0.0.0 -ENV PORT=4321 -EXPOSE 4321 - -# Add entrypoint script and make it executable -COPY docker-entrypoint.sh /usr/local/bin/ -RUN chmod +x /usr/local/bin/docker-entrypoint.sh - -ENTRYPOINT ["docker-entrypoint.sh"] -CMD ["node", "./dist/server/entry.mjs"] diff --git a/web/README.md b/web/README.md deleted file mode 100644 index adef8cd..0000000 --- a/web/README.md +++ /dev/null @@ -1,29 +0,0 @@ -# KYCnot.me website - -[KYCnot.me](https://kycnot.me) - -## Commands - -All commands are run from the root of the project, from a terminal: - -| Command | Action | -| :------------------------ | :------------------------------------------------------------------- | -| `nvm install` | Installs and uses the correct version of node | -| `npm install` | Installs dependencies | -| `npm run dev` | Starts local dev server at `localhost:4321` | -| `npm run build` | Build your production site to `./dist/` | -| `npm run preview` | Preview your build locally, before deploying | -| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` | -| `npm run astro -- --help` | Get help using the Astro CLI | -| `npm run db-admin` | Runs Prisma Studio (database admin) | -| `npm run db-gen` | Generates the Prisma client without running migrations | -| `npm run db-push` | Updates the database schema with latest changes (development mode). | -| `npm run db-fill` | Fills the database with fake data (development mode) | -| `npm run db-fill-clean` | Cleans existing data and fills with new fake data (development mode) | -| `npm run format` | Formats the code with Prettier | -| `npm run lint` | Lints the code with ESLint | -| `npm run lint-fix` | Lints the code with ESLint and fixes the issues | - -> **Note**: `db-fill` and `db-fill-clean` support the `-- --services=n` flag, where n is the number of fake services to add. It defaults to 10. For example, `npm run db-fill -- --services=5` will add 5 fake services. - -> **Note**: `db-fill` and `db-fill-clean` create default users with tokens: `admin`, `verifier`, `verified`, `normal` (override with `DEV_*****_USER_SECRET_TOKEN` env vars) diff --git a/web/astro.config.mjs b/web/astro.config.mjs deleted file mode 100644 index b33947f..0000000 --- a/web/astro.config.mjs +++ /dev/null @@ -1,159 +0,0 @@ -// @ts-check - -import mdx from '@astrojs/mdx' -import node from '@astrojs/node' -import sitemap from '@astrojs/sitemap' -import tailwindcss from '@tailwindcss/vite' -import { defineConfig, envField } from 'astro/config' -import icon from 'astro-icon' -import { loadEnv } from 'vite' - -// @ts-expect-error process.env actually exists -const { SITE_URL } = loadEnv(process.env.NODE_ENV, process.cwd(), '') -if (!SITE_URL) throw new Error('SITE_URL environment variable is not set') - -export default defineConfig({ - site: SITE_URL, - vite: { - build: { - sourcemap: true, - }, - - plugins: [tailwindcss()], - }, - integrations: [ - icon(), - mdx(), - sitemap({ - filter: (page) => { - const url = new URL(page) - return !url.pathname.startsWith('/admin') && !url.pathname.startsWith('/account/impersonate') - }, - }), - ], - adapter: node({ - mode: 'standalone', - }), - output: 'server', - devToolbar: { - enabled: false, - }, - server: { - open: false, - allowedHosts: [new URL(SITE_URL).hostname], - }, - redirects: { - // #region Redirects from old website - '/pending': '/?verification=verified&verification=approved&verification=community', - '/changelog': '/events', - '/request': '/service-suggestion/new', - '/service/[...slug]/summary': '/service/[...slug]/#scores', - '/service/[...slug]/proof': '/service/[...slug]/#verification', - '/attribute/[...slug]': '/attributes', - '/attr/[...slug]': '/attributes', - // #endregion - }, - env: { - schema: { - // Database (server-only, secret) - DATABASE_URL: envField.string({ - context: 'server', - access: 'secret', - url: true, - startsWith: 'postgresql://', - default: 'postgresql://kycnot:kycnot@database:5432/kycnot?schema=public', - }), - // Public URLs (can be accessed from both server and client) - SOURCE_CODE_URL: envField.string({ - context: 'server', - access: 'public', - url: true, - optional: false, - }), - - REDIS_URL: envField.string({ - context: 'server', - access: 'secret', - url: true, - startsWith: 'redis://', - default: 'redis://redis:6379', - }), - REDIS_USER_SESSION_EXPIRY_SECONDS: envField.number({ - context: 'server', - access: 'secret', - int: true, - gt: 0, - default: 60 * 60 * 24, // 24 hours in seconds - }), - REDIS_IMPERSONATION_SESSION_EXPIRY_SECONDS: envField.number({ - context: 'server', - access: 'secret', - int: true, - gt: 0, - default: 60 * 60 * 24, // 24 hours in seconds - }), - REDIS_PREGENERATED_TOKEN_EXPIRY_SECONDS: envField.number({ - context: 'server', - access: 'secret', - int: true, - gt: 0, - default: 60 * 5, // 5 minutes in seconds - }), - - REDIS_ACTIONS_SESSION_EXPIRY_SECONDS: envField.number({ - context: 'server', - access: 'secret', - int: true, - gt: 0, - default: 60 * 5, // 5 minutes in seconds - }), - - // Development tokens - DEV_ADMIN_USER_SECRET_TOKEN: envField.string({ - context: 'server', - access: 'secret', - min: 1, - default: 'admin', - }), - DEV_VERIFIER_USER_SECRET_TOKEN: envField.string({ - context: 'server', - access: 'secret', - min: 1, - default: 'verifier', - }), - DEV_VERIFIED_USER_SECRET_TOKEN: envField.string({ - context: 'server', - access: 'secret', - min: 1, - default: 'verified', - }), - DEV_NORMAL_USER_SECRET_TOKEN: envField.string({ - context: 'server', - access: 'secret', - min: 1, - default: 'normal', - }), - DEV_SPAM_USER_SECRET_TOKEN: envField.string({ - context: 'server', - access: 'secret', - min: 1, - default: 'spam', - }), - - // Upload directory configuration - UPLOAD_DIR: envField.string({ - context: 'server', - access: 'secret', - min: 1, - default: './local_uploads', - }), - - SITE_URL: envField.string({ - context: 'client', - access: 'public', - url: true, - optional: false, - }), - }, - }, -}) diff --git a/web/docker-entrypoint.sh b/web/docker-entrypoint.sh deleted file mode 100644 index 8396032..0000000 --- a/web/docker-entrypoint.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/sh -set -e - -# Apply migrations -echo "Applying database migrations..." -npx prisma migrate deploy - -# Apply triggers -echo "Applying database triggers..." -for trigger_file in prisma/triggers/*.sql; do - if [ -f "$trigger_file" ]; then - echo "Applying trigger: $trigger_file" - npx prisma db execute --file "$trigger_file" --schema=./prisma/schema.prisma - else - echo "No trigger files found in prisma/triggers/ or $trigger_file is not a file." - fi -done - -# Start the application -echo "Starting the application..." -exec "$@" diff --git a/web/eslint.config.js b/web/eslint.config.js deleted file mode 100644 index 82b9319..0000000 --- a/web/eslint.config.js +++ /dev/null @@ -1,147 +0,0 @@ -// @ts-check -import pluginJs from '@eslint/js' -import stylistic from '@stylistic/eslint-plugin' -import { configs as eslintAstroPluginConfig } from 'eslint-plugin-astro' -import importPlugin from 'eslint-plugin-import' -import globals from 'globals' -import { without } from 'lodash-es' -import tseslint, { configs as tseslintConfigs } from 'typescript-eslint' - -export default tseslint.config( - { - ignores: [ - '**/node_modules/**', - '.astro/**', - 'dist/**', - 'coverage/**', - 'build/**', - 'public/**', - '.prettierrc.mjs', - ], - }, - { - files: ['**/*.{js,ts,mjs,cjs,tsx,jsx,astro}'], - }, - { - settings: { - 'import/resolver': { - typescript: { - alwaysTryTypes: true, - project: 'tsconfig.json', - }, - }, - }, - }, - pluginJs.configs.recommended, - tseslintConfigs.strictTypeChecked, - tseslintConfigs.stylisticTypeChecked, - // eslint-disable-next-line @typescript-eslint/no-unsafe-argument - importPlugin.flatConfigs.recommended, - // eslint-disable-next-line @typescript-eslint/no-unsafe-argument - importPlugin.flatConfigs.typescript, - eslintAstroPluginConfig['flat/recommended'], - eslintAstroPluginConfig['flat/jsx-a11y-strict'], - [ - // These rules don't work with Astro and produce false positives - { - files: ['**/*.astro'], - rules: { - '@typescript-eslint/no-misused-promises': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/no-redundant-type-constituents': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-argument': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - }, - }, - { - rules: { - '@typescript-eslint/no-unsafe-assignment': 'off', - }, - }, - ], - { - languageOptions: { - globals: { - ...globals.browser, - ...globals.node, - }, - parserOptions: { - project: true, - tsconfigRootDir: import.meta.dirname, - }, - }, - plugins: { - '@stylistic': stylistic, - }, - rules: { - '@typescript-eslint/unbound-method': 'off', - '@typescript-eslint/no-unnecessary-type-parameters': 'off', - '@typescript-eslint/no-deprecated': 'warn', - '@typescript-eslint/prefer-nullish-coalescing': 'warn', - '@typescript-eslint/consistent-type-definitions': ['warn', 'type'], - '@typescript-eslint/no-unused-vars': [ - 'warn', - { - args: 'all', - argsIgnorePattern: '^_', - caughtErrors: 'all', - caughtErrorsIgnorePattern: '^_', - destructuredArrayIgnorePattern: '^_', - varsIgnorePattern: '^_', - ignoreRestSiblings: true, - }, - ], - '@typescript-eslint/consistent-type-imports': [ - 'error', - { prefer: 'type-imports', fixStyle: 'separate-type-imports' }, - ], - '@typescript-eslint/sort-type-constituents': 'error', - 'import/order': [ - 'warn', - { - groups: ['builtin', 'external', 'internal', 'parent', 'sibling', 'index', 'object', 'type'], - pathGroups: [ - { - pattern: 'react', - group: 'external', - position: 'before', - }, - ], - pathGroupsExcludedImportTypes: ['react'], - 'newlines-between': 'always', - alphabetize: { - order: 'asc', - caseInsensitive: true, - }, - }, - ], - 'import/first': 'error', - 'import/newline-after-import': 'error', - 'import/no-duplicates': 'error', - 'import/no-unresolved': ['error', { ignore: ['^astro:'] }], - '@typescript-eslint/no-explicit-any': 'warn', - 'no-console': ['warn', { allow: without(Object.keys(console), 'log') }], - 'import/namespace': 'off', - 'object-shorthand': ['warn', 'always', { avoidExplicitReturnArrows: false }], - 'no-useless-rename': 'warn', - curly: ['error', 'multi-line'], - '@stylistic/quotes': [ - 'error', - 'single', - { - avoidEscape: true, - allowTemplateLiterals: false, - }, - ], - }, - }, - { - files: ['**/*.d.ts'], - rules: { - '@typescript-eslint/no-explicit-any': 'off', - }, - } -) diff --git a/web/package-lock.json b/web/package-lock.json deleted file mode 100644 index dcf928a..0000000 --- a/web/package-lock.json +++ /dev/null @@ -1,14561 +0,0 @@ -{ - "name": "kycnot.me", - "version": "0.0.1", - "lockfileVersion": 3, - "requires": true, - "packages": { - "": { - "name": "kycnot.me", - "version": "0.0.1", - "dependencies": { - "@astrojs/check": "0.9.4", - "@astrojs/db": "0.14.14", - "@astrojs/mdx": "4.2.6", - "@astrojs/node": "9.2.1", - "@astrojs/sitemap": "3.4.0", - "@fontsource-variable/space-grotesk": "5.2.7", - "@fontsource/inter": "5.2.5", - "@prisma/client": "6.8.2", - "@tailwindcss/vite": "4.1.7", - "@types/mime-types": "2.1.4", - "@vercel/og": "0.6.8", - "astro": "5.7.13", - "astro-loading-indicator": "0.7.0", - "astro-remote": "0.3.4", - "astro-seo-schema": "5.0.0", - "canvas": "3.1.0", - "clsx": "2.1.1", - "htmx.org": "1.9.12", - "javascript-time-ago": "2.5.11", - "libphonenumber-js": "1.12.8", - "lodash-es": "4.17.21", - "mime-types": "3.0.1", - "object-to-formdata": "4.5.1", - "react": "19.1.0", - "redis": "5.0.1", - "schema-dts": "1.1.5", - "seedrandom": "3.0.5", - "slugify": "1.6.6", - "tailwind-merge": "3.3.0", - "tailwind-variants": "1.0.0", - "tailwindcss": "4.1.7", - "typescript": "5.8.3", - "unique-username-generator": "1.4.0", - "zod-form-data": "2.0.7" - }, - "devDependencies": { - "@eslint/js": "9.27.0", - "@faker-js/faker": "9.8.0", - "@iconify-json/material-symbols": "1.2.21", - "@iconify-json/mdi": "1.2.3", - "@iconify-json/ri": "1.2.5", - "@stylistic/eslint-plugin": "4.2.0", - "@tailwindcss/forms": "0.5.10", - "@tailwindcss/typography": "0.5.16", - "@types/eslint__js": "9.14.0", - "@types/lodash-es": "4.17.12", - "@types/react": "19.1.4", - "@types/seedrandom": "3.0.8", - "@typescript-eslint/parser": "8.32.1", - "astro-icon": "1.1.5", - "date-fns": "4.1.0", - "eslint": "9.27.0", - "eslint-import-resolver-typescript": "4.3.5", - "eslint-plugin-astro": "1.3.1", - "eslint-plugin-import": "2.31.0", - "eslint-plugin-jsx-a11y": "6.10.2", - "globals": "16.1.0", - "prettier": "3.5.3", - "prettier-plugin-astro": "0.14.1", - "prettier-plugin-tailwindcss": "0.6.11", - "prisma": "6.8.2", - "prisma-json-types-generator": "3.4.1", - "tailwind-htmx": "0.1.2", - "ts-essentials": "10.0.4", - "ts-toolbelt": "9.6.0", - "tsx": "4.19.4", - "typescript-eslint": "8.32.1" - } - }, - "node_modules/@ampproject/remapping": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.3.0.tgz", - "integrity": "sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==", - "license": "Apache-2.0", - "dependencies": { - "@jridgewell/gen-mapping": "^0.3.5", - "@jridgewell/trace-mapping": "^0.3.24" - }, - "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/@antfu/install-pkg": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/@antfu/install-pkg/-/install-pkg-1.0.0.tgz", - "integrity": "sha512-xvX6P/lo1B3ej0OsaErAjqgFYzYVcJpamjLAFLYh9vRJngBrMoUG7aVnrGTeqM7yxbyTD5p3F2+0/QUEh8Vzhw==", - "dev": true, - "license": "MIT", - "dependencies": { - "package-manager-detector": "^0.2.8", - "tinyexec": "^0.3.2" - }, - "funding": { - "url": "https://github.com/sponsors/antfu" - } - }, - "node_modules/@antfu/utils": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/@antfu/utils/-/utils-8.1.0.tgz", - "integrity": "sha512-XPR7Jfwp0FFl/dFYPX8ZjpmU4/1mIXTjnZ1ba48BLMyKOV62/tiRjdsFcPs2hsYcSud4tzk7w3a3LjX8Fu3huA==", - "dev": true, - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/antfu" - } - }, - "node_modules/@astrojs/check": { - "version": "0.9.4", - "resolved": "https://registry.npmjs.org/@astrojs/check/-/check-0.9.4.tgz", - "integrity": "sha512-IOheHwCtpUfvogHHsvu0AbeRZEnjJg3MopdLddkJE70mULItS/Vh37BHcI00mcOJcH1vhD3odbpvWokpxam7xA==", - "license": "MIT", - "dependencies": { - "@astrojs/language-server": "^2.15.0", - "chokidar": "^4.0.1", - "kleur": "^4.1.5", - "yargs": "^17.7.2" - }, - "bin": { - "astro-check": "dist/bin.js" - }, - "peerDependencies": { - "typescript": "^5.0.0" - } - }, - "node_modules/@astrojs/compiler": { - "version": "2.11.0", - "resolved": "https://registry.npmjs.org/@astrojs/compiler/-/compiler-2.11.0.tgz", - "integrity": "sha512-zZOO7i+JhojO8qmlyR/URui6LyfHJY6m+L9nwyX5GiKD78YoRaZ5tzz6X0fkl+5bD3uwlDHayf6Oe8Fu36RKNg==", - "license": "MIT" - }, - "node_modules/@astrojs/db": { - "version": "0.14.14", - "resolved": "https://registry.npmjs.org/@astrojs/db/-/db-0.14.14.tgz", - "integrity": "sha512-NSLa7P+MGv9icVWmvV2KVzjUZEWUYQ3q5W5XNTghhrxRGkFkNtAHs+xPBDt+VGhcYtRedzqWXRhHooLLJkKb9g==", - "license": "MIT", - "dependencies": { - "@astrojs/studio": "0.1.9", - "@libsql/client": "^0.15.2", - "async-listen": "^3.1.0", - "deep-diff": "^1.0.2", - "drizzle-orm": "^0.31.2", - "github-slugger": "^2.0.0", - "kleur": "^4.1.5", - "nanoid": "^5.1.5", - "open": "^10.1.0", - "prompts": "^2.4.2", - "yargs-parser": "^21.1.1", - "yocto-spinner": "^0.2.1", - "zod": "^3.24.2" - } - }, - "node_modules/@astrojs/db/node_modules/nanoid": { - "version": "5.1.5", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-5.1.5.tgz", - "integrity": "sha512-Ir/+ZpE9fDsNH0hQ3C68uyThDXzYcim2EqcZ8zn8Chtt1iylPT9xXJB0kPCnqzgcEGikO9RxSrh63MsmVCU7Fw==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "MIT", - "bin": { - "nanoid": "bin/nanoid.js" - }, - "engines": { - "node": "^18 || >=20" - } - }, - "node_modules/@astrojs/internal-helpers": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/@astrojs/internal-helpers/-/internal-helpers-0.6.1.tgz", - "integrity": "sha512-l5Pqf6uZu31aG+3Lv8nl/3s4DbUzdlxTWDof4pEpto6GUJNhhCbelVi9dEyurOVyqaelwmS9oSyOWOENSfgo9A==", - "license": "MIT" - }, - "node_modules/@astrojs/language-server": { - "version": "2.15.4", - "resolved": "https://registry.npmjs.org/@astrojs/language-server/-/language-server-2.15.4.tgz", - "integrity": "sha512-JivzASqTPR2bao9BWsSc/woPHH7OGSGc9aMxXL4U6egVTqBycB3ZHdBJPuOCVtcGLrzdWTosAqVPz1BVoxE0+A==", - "license": "MIT", - "dependencies": { - "@astrojs/compiler": "^2.10.3", - "@astrojs/yaml2ts": "^0.2.2", - "@jridgewell/sourcemap-codec": "^1.4.15", - "@volar/kit": "~2.4.7", - "@volar/language-core": "~2.4.7", - "@volar/language-server": "~2.4.7", - "@volar/language-service": "~2.4.7", - "fast-glob": "^3.2.12", - "muggle-string": "^0.4.1", - "volar-service-css": "0.0.62", - "volar-service-emmet": "0.0.62", - "volar-service-html": "0.0.62", - "volar-service-prettier": "0.0.62", - "volar-service-typescript": "0.0.62", - "volar-service-typescript-twoslash-queries": "0.0.62", - "volar-service-yaml": "0.0.62", - "vscode-html-languageservice": "^5.2.0", - "vscode-uri": "^3.0.8" - }, - "bin": { - "astro-ls": "bin/nodeServer.js" - }, - "peerDependencies": { - "prettier": "^3.0.0", - "prettier-plugin-astro": ">=0.11.0" - }, - "peerDependenciesMeta": { - "prettier": { - "optional": true - }, - "prettier-plugin-astro": { - "optional": true - } - } - }, - "node_modules/@astrojs/markdown-remark": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/@astrojs/markdown-remark/-/markdown-remark-6.3.1.tgz", - "integrity": "sha512-c5F5gGrkczUaTVgmMW9g1YMJGzOtRvjjhw6IfGuxarM6ct09MpwysP10US729dy07gg8y+ofVifezvP3BNsWZg==", - "license": "MIT", - "dependencies": { - "@astrojs/internal-helpers": "0.6.1", - "@astrojs/prism": "3.2.0", - "github-slugger": "^2.0.0", - "hast-util-from-html": "^2.0.3", - "hast-util-to-text": "^4.0.2", - "import-meta-resolve": "^4.1.0", - "js-yaml": "^4.1.0", - "mdast-util-definitions": "^6.0.0", - "rehype-raw": "^7.0.0", - "rehype-stringify": "^10.0.1", - "remark-gfm": "^4.0.1", - "remark-parse": "^11.0.0", - "remark-rehype": "^11.1.1", - "remark-smartypants": "^3.0.2", - "shiki": "^3.0.0", - "smol-toml": "^1.3.1", - "unified": "^11.0.5", - "unist-util-remove-position": "^5.0.0", - "unist-util-visit": "^5.0.0", - "unist-util-visit-parents": "^6.0.1", - "vfile": "^6.0.3" - } - }, - "node_modules/@astrojs/mdx": { - "version": "4.2.6", - "resolved": "https://registry.npmjs.org/@astrojs/mdx/-/mdx-4.2.6.tgz", - "integrity": "sha512-0i/GmOm6d0qq1/SCfcUgY/IjDc/bS0i42u7h85TkPFBmlFOcBZfkYhR5iyz6hZLwidvJOEq5yGfzt9B1Azku4w==", - "license": "MIT", - "dependencies": { - "@astrojs/markdown-remark": "6.3.1", - "@mdx-js/mdx": "^3.1.0", - "acorn": "^8.14.1", - "es-module-lexer": "^1.6.0", - "estree-util-visit": "^2.0.0", - "hast-util-to-html": "^9.0.5", - "kleur": "^4.1.5", - "rehype-raw": "^7.0.0", - "remark-gfm": "^4.0.1", - "remark-smartypants": "^3.0.2", - "source-map": "^0.7.4", - "unist-util-visit": "^5.0.0", - "vfile": "^6.0.3" - }, - "engines": { - "node": "^18.17.1 || ^20.3.0 || >=22.0.0" - }, - "peerDependencies": { - "astro": "^5.0.0" - } - }, - "node_modules/@astrojs/node": { - "version": "9.2.1", - "resolved": "https://registry.npmjs.org/@astrojs/node/-/node-9.2.1.tgz", - "integrity": "sha512-kEHLB37ooW91p7FLGalqa3jVQRIafntfKiZgCnjN1lEYw+j8NP6VJHQbLHmzzbtKUI0J+srGiTnGZmaHErHE5w==", - "license": "MIT", - "dependencies": { - "@astrojs/internal-helpers": "0.6.1", - "send": "^1.1.0", - "server-destroy": "^1.0.1" - }, - "peerDependencies": { - "astro": "^5.3.0" - } - }, - "node_modules/@astrojs/prism": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/@astrojs/prism/-/prism-3.2.0.tgz", - "integrity": "sha512-GilTHKGCW6HMq7y3BUv9Ac7GMe/MO9gi9GW62GzKtth0SwukCu/qp2wLiGpEujhY+VVhaG9v7kv/5vFzvf4NYw==", - "license": "MIT", - "dependencies": { - "prismjs": "^1.29.0" - }, - "engines": { - "node": "^18.17.1 || ^20.3.0 || >=22.0.0" - } - }, - "node_modules/@astrojs/sitemap": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/@astrojs/sitemap/-/sitemap-3.4.0.tgz", - "integrity": "sha512-C5m/xsKvRSILKM3hy47n5wKtTQtJXn8epoYuUmCCstaE9XBt20yInym3Bz2uNbEiNfv11bokoW0MqeXPIvjFIQ==", - "license": "MIT", - "dependencies": { - "sitemap": "^8.0.0", - "stream-replace-string": "^2.0.0", - "zod": "^3.24.2" - } - }, - "node_modules/@astrojs/studio": { - "version": "0.1.9", - "resolved": "https://registry.npmjs.org/@astrojs/studio/-/studio-0.1.9.tgz", - "integrity": "sha512-pMZ+gYVC2XAnHfzp/or9tyEor8yKJyTUflm6oQJAad5+4z0d/033mhJVCU4kKDXXKovAGB4bcHgyW97ixCE6fQ==", - "license": "MIT", - "dependencies": { - "ci-info": "^4.2.0", - "kleur": "^4.1.5", - "yocto-spinner": "^0.2.1" - } - }, - "node_modules/@astrojs/telemetry": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/@astrojs/telemetry/-/telemetry-3.2.1.tgz", - "integrity": "sha512-SSVM820Jqc6wjsn7qYfV9qfeQvePtVc1nSofhyap7l0/iakUKywj3hfy3UJAOV4sGV4Q/u450RD4AaCaFvNPlg==", - "license": "MIT", - "dependencies": { - "ci-info": "^4.2.0", - "debug": "^4.4.0", - "dlv": "^1.1.3", - "dset": "^3.1.4", - "is-docker": "^3.0.0", - "is-wsl": "^3.1.0", - "which-pm-runs": "^1.1.0" - }, - "engines": { - "node": "^18.17.1 || ^20.3.0 || >=22.0.0" - } - }, - "node_modules/@astrojs/yaml2ts": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/@astrojs/yaml2ts/-/yaml2ts-0.2.2.tgz", - "integrity": "sha512-GOfvSr5Nqy2z5XiwqTouBBpy5FyI6DEe+/g/Mk5am9SjILN1S5fOEvYK0GuWHg98yS/dobP4m8qyqw/URW35fQ==", - "license": "MIT", - "dependencies": { - "yaml": "^2.5.0" - } - }, - "node_modules/@babel/helper-string-parser": { - "version": "7.25.9", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.25.9.tgz", - "integrity": "sha512-4A/SCr/2KLd5jrtOMFzaKjVtAei3+2r/NChoBNoZ3EyP/+GlhoaEGoWOZUmFmoITP7zOJyHIMm+DYRd8o3PvHA==", - "license": "MIT", - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/helper-validator-identifier": { - "version": "7.25.9", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.25.9.tgz", - "integrity": "sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ==", - "license": "MIT", - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/parser": { - "version": "7.27.0", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.27.0.tgz", - "integrity": "sha512-iaepho73/2Pz7w2eMS0Q5f83+0RKI7i4xmiYeBmDzfRVbQtTOG7Ts0S4HzJVsTMGI9keU8rNfuZr8DKfSt7Yyg==", - "license": "MIT", - "dependencies": { - "@babel/types": "^7.27.0" - }, - "bin": { - "parser": "bin/babel-parser.js" - }, - "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/@babel/types": { - "version": "7.27.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.27.0.tgz", - "integrity": "sha512-H45s8fVLYjbhFH62dIJ3WtmJ6RSPt/3DRO0ZcT2SUiYiQyz3BLVb9ADEnLl91m74aQPS3AzzeajZHYOalWe3bg==", - "license": "MIT", - "dependencies": { - "@babel/helper-string-parser": "^7.25.9", - "@babel/helper-validator-identifier": "^7.25.9" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@capsizecss/unpack": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/@capsizecss/unpack/-/unpack-2.4.0.tgz", - "integrity": "sha512-GrSU71meACqcmIUxPYOJvGKF0yryjN/L1aCuE9DViCTJI7bfkjgYDPD1zbNDcINJwSSP6UaBZY9GAbYDO7re0Q==", - "license": "MIT", - "dependencies": { - "blob-to-buffer": "^1.2.8", - "cross-fetch": "^3.0.4", - "fontkit": "^2.0.2" - } - }, - "node_modules/@emmetio/abbreviation": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/@emmetio/abbreviation/-/abbreviation-2.3.3.tgz", - "integrity": "sha512-mgv58UrU3rh4YgbE/TzgLQwJ3pFsHHhCLqY20aJq+9comytTXUDNGG/SMtSeMJdkpxgXSXunBGLD8Boka3JyVA==", - "license": "MIT", - "dependencies": { - "@emmetio/scanner": "^1.0.4" - } - }, - "node_modules/@emmetio/css-abbreviation": { - "version": "2.1.8", - "resolved": "https://registry.npmjs.org/@emmetio/css-abbreviation/-/css-abbreviation-2.1.8.tgz", - "integrity": "sha512-s9yjhJ6saOO/uk1V74eifykk2CBYi01STTK3WlXWGOepyKa23ymJ053+DNQjpFcy1ingpaO7AxCcwLvHFY9tuw==", - "license": "MIT", - "dependencies": { - "@emmetio/scanner": "^1.0.4" - } - }, - "node_modules/@emmetio/css-parser": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/@emmetio/css-parser/-/css-parser-0.4.0.tgz", - "integrity": "sha512-z7wkxRSZgrQHXVzObGkXG+Vmj3uRlpM11oCZ9pbaz0nFejvCDmAiNDpY75+wgXOcffKpj4rzGtwGaZxfJKsJxw==", - "license": "MIT", - "dependencies": { - "@emmetio/stream-reader": "^2.2.0", - "@emmetio/stream-reader-utils": "^0.1.0" - } - }, - "node_modules/@emmetio/html-matcher": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/@emmetio/html-matcher/-/html-matcher-1.3.0.tgz", - "integrity": "sha512-NTbsvppE5eVyBMuyGfVu2CRrLvo7J4YHb6t9sBFLyY03WYhXET37qA4zOYUjBWFCRHO7pS1B9khERtY0f5JXPQ==", - "license": "ISC", - "dependencies": { - "@emmetio/scanner": "^1.0.0" - } - }, - "node_modules/@emmetio/scanner": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@emmetio/scanner/-/scanner-1.0.4.tgz", - "integrity": "sha512-IqRuJtQff7YHHBk4G8YZ45uB9BaAGcwQeVzgj/zj8/UdOhtQpEIupUhSk8dys6spFIWVZVeK20CzGEnqR5SbqA==", - "license": "MIT" - }, - "node_modules/@emmetio/stream-reader": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@emmetio/stream-reader/-/stream-reader-2.2.0.tgz", - "integrity": "sha512-fXVXEyFA5Yv3M3n8sUGT7+fvecGrZP4k6FnWWMSZVQf69kAq0LLpaBQLGcPR30m3zMmKYhECP4k/ZkzvhEW5kw==", - "license": "MIT" - }, - "node_modules/@emmetio/stream-reader-utils": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/@emmetio/stream-reader-utils/-/stream-reader-utils-0.1.0.tgz", - "integrity": "sha512-ZsZ2I9Vzso3Ho/pjZFsmmZ++FWeEd/txqybHTm4OgaZzdS8V9V/YYWQwg5TC38Z7uLWUV1vavpLLbjJtKubR1A==", - "license": "MIT" - }, - "node_modules/@emnapi/core": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/@emnapi/core/-/core-1.4.3.tgz", - "integrity": "sha512-4m62DuCE07lw01soJwPiBGC0nAww0Q+RY70VZ+n49yDIO13yyinhbWCeNnaob0lakDtWQzSdtNWzJeOJt2ma+g==", - "license": "MIT", - "optional": true, - "dependencies": { - "@emnapi/wasi-threads": "1.0.2", - "tslib": "^2.4.0" - } - }, - "node_modules/@emnapi/runtime": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.4.0.tgz", - "integrity": "sha512-64WYIf4UYcdLnbKn/umDlNjQDSS8AgZrI/R9+x5ilkUVFxXcA1Ebl+gQLc/6mERA4407Xof0R7wEyEuj091CVw==", - "license": "MIT", - "optional": true, - "dependencies": { - "tslib": "^2.4.0" - } - }, - "node_modules/@emnapi/wasi-threads": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@emnapi/wasi-threads/-/wasi-threads-1.0.2.tgz", - "integrity": "sha512-5n3nTJblwRi8LlXkJ9eBzu+kZR8Yxcc7ubakyQTFzPMtIhFpUBRbsnc2Dv88IZDIbCDlBiWrknhB4Lsz7mg6BA==", - "license": "MIT", - "optional": true, - "dependencies": { - "tslib": "^2.4.0" - } - }, - "node_modules/@esbuild/aix-ppc64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.0.tgz", - "integrity": "sha512-O7vun9Sf8DFjH2UtqK8Ku3LkquL9SZL8OLY1T5NZkA34+wG3OQF7cl4Ql8vdNzM6fzBbYfLaiRLIOZ+2FOCgBQ==", - "cpu": [ - "ppc64" - ], - "license": "MIT", - "optional": true, - "os": [ - "aix" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/android-arm": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.0.tgz", - "integrity": "sha512-PTyWCYYiU0+1eJKmw21lWtC+d08JDZPQ5g+kFyxP0V+es6VPPSUhM6zk8iImp2jbV6GwjX4pap0JFbUQN65X1g==", - "cpu": [ - "arm" - ], - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/android-arm64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.0.tgz", - "integrity": "sha512-grvv8WncGjDSyUBjN9yHXNt+cq0snxXbDxy5pJtzMKGmmpPxeAmAhWxXI+01lU5rwZomDgD3kJwulEnhTRUd6g==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/android-x64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.0.tgz", - "integrity": "sha512-m/ix7SfKG5buCnxasr52+LI78SQ+wgdENi9CqyCXwjVR2X4Jkz+BpC3le3AoBPYTC9NHklwngVXvbJ9/Akhrfg==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/darwin-arm64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.0.tgz", - "integrity": "sha512-mVwdUb5SRkPayVadIOI78K7aAnPamoeFR2bT5nszFUZ9P8UpK4ratOdYbZZXYSqPKMHfS1wdHCJk1P1EZpRdvw==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/darwin-x64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.0.tgz", - "integrity": "sha512-DgDaYsPWFTS4S3nWpFcMn/33ZZwAAeAFKNHNa1QN0rI4pUjgqf0f7ONmXf6d22tqTY+H9FNdgeaAa+YIFUn2Rg==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/freebsd-arm64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.0.tgz", - "integrity": "sha512-VN4ocxy6dxefN1MepBx/iD1dH5K8qNtNe227I0mnTRjry8tj5MRk4zprLEdG8WPyAPb93/e4pSgi1SoHdgOa4w==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/freebsd-x64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.0.tgz", - "integrity": "sha512-mrSgt7lCh07FY+hDD1TxiTyIHyttn6vnjesnPoVDNmDfOmggTLXRv8Id5fNZey1gl/V2dyVK1VXXqVsQIiAk+A==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-arm": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.0.tgz", - "integrity": "sha512-vkB3IYj2IDo3g9xX7HqhPYxVkNQe8qTK55fraQyTzTX/fxaDtXiEnavv9geOsonh2Fd2RMB+i5cbhu2zMNWJwg==", - "cpu": [ - "arm" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-arm64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.0.tgz", - "integrity": "sha512-9QAQjTWNDM/Vk2bgBl17yWuZxZNQIF0OUUuPZRKoDtqF2k4EtYbpyiG5/Dk7nqeK6kIJWPYldkOcBqjXjrUlmg==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-ia32": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.0.tgz", - "integrity": "sha512-43ET5bHbphBegyeqLb7I1eYn2P/JYGNmzzdidq/w0T8E2SsYL1U6un2NFROFRg1JZLTzdCoRomg8Rvf9M6W6Gg==", - "cpu": [ - "ia32" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-loong64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.0.tgz", - "integrity": "sha512-fC95c/xyNFueMhClxJmeRIj2yrSMdDfmqJnyOY4ZqsALkDrrKJfIg5NTMSzVBr5YW1jf+l7/cndBfP3MSDpoHw==", - "cpu": [ - "loong64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-mips64el": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.0.tgz", - "integrity": "sha512-nkAMFju7KDW73T1DdH7glcyIptm95a7Le8irTQNO/qtkoyypZAnjchQgooFUDQhNAy4iu08N79W4T4pMBwhPwQ==", - "cpu": [ - "mips64el" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-ppc64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.0.tgz", - "integrity": "sha512-NhyOejdhRGS8Iwv+KKR2zTq2PpysF9XqY+Zk77vQHqNbo/PwZCzB5/h7VGuREZm1fixhs4Q/qWRSi5zmAiO4Fw==", - "cpu": [ - "ppc64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-riscv64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.0.tgz", - "integrity": "sha512-5S/rbP5OY+GHLC5qXp1y/Mx//e92L1YDqkiBbO9TQOvuFXM+iDqUNG5XopAnXoRH3FjIUDkeGcY1cgNvnXp/kA==", - "cpu": [ - "riscv64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-s390x": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.0.tgz", - "integrity": "sha512-XM2BFsEBz0Fw37V0zU4CXfcfuACMrppsMFKdYY2WuTS3yi8O1nFOhil/xhKTmE1nPmVyvQJjJivgDT+xh8pXJA==", - "cpu": [ - "s390x" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/linux-x64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.0.tgz", - "integrity": "sha512-9yl91rHw/cpwMCNytUDxwj2XjFpxML0y9HAOH9pNVQDpQrBxHy01Dx+vaMu0N1CKa/RzBD2hB4u//nfc+Sd3Cw==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/netbsd-arm64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.0.tgz", - "integrity": "sha512-RuG4PSMPFfrkH6UwCAqBzauBWTygTvb1nxWasEJooGSJ/NwRw7b2HOwyRTQIU97Hq37l3npXoZGYMy3b3xYvPw==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/netbsd-x64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.0.tgz", - "integrity": "sha512-jl+qisSB5jk01N5f7sPCsBENCOlPiS/xptD5yxOx2oqQfyourJwIKLRA2yqWdifj3owQZCL2sn6o08dBzZGQzA==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/openbsd-arm64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.0.tgz", - "integrity": "sha512-21sUNbq2r84YE+SJDfaQRvdgznTD8Xc0oc3p3iW/a1EVWeNj/SdUCbm5U0itZPQYRuRTW20fPMWMpcrciH2EJw==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/openbsd-x64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.0.tgz", - "integrity": "sha512-2gwwriSMPcCFRlPlKx3zLQhfN/2WjJ2NSlg5TKLQOJdV0mSxIcYNTMhk3H3ulL/cak+Xj0lY1Ym9ysDV1igceg==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/sunos-x64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.0.tgz", - "integrity": "sha512-bxI7ThgLzPrPz484/S9jLlvUAHYMzy6I0XiU1ZMeAEOBcS0VePBFxh1JjTQt3Xiat5b6Oh4x7UC7IwKQKIJRIg==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "sunos" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/win32-arm64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.0.tgz", - "integrity": "sha512-ZUAc2YK6JW89xTbXvftxdnYy3m4iHIkDtK3CLce8wg8M2L+YZhIvO1DKpxrd0Yr59AeNNkTiic9YLf6FTtXWMw==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/win32-ia32": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.0.tgz", - "integrity": "sha512-eSNxISBu8XweVEWG31/JzjkIGbGIJN/TrRoiSVZwZ6pkC6VX4Im/WV2cz559/TXLcYbcrDN8JtKgd9DJVIo8GA==", - "cpu": [ - "ia32" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@esbuild/win32-x64": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.0.tgz", - "integrity": "sha512-ZENoHJBxA20C2zFzh6AI4fT6RraMzjYw4xKWemRTRmRVtN9c5DcH9r/f2ihEkMjOW5eGgrwCslG/+Y/3bL+DHQ==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@eslint-community/eslint-utils": { - "version": "4.7.0", - "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.7.0.tgz", - "integrity": "sha512-dyybb3AcajC7uha6CvhdVRJqaKyn7w2YKqKyAN37NKYgZT36w+iRb0Dymmc5qEJ549c/S31cMMSFd75bteCpCw==", - "dev": true, - "license": "MIT", - "dependencies": { - "eslint-visitor-keys": "^3.4.3" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - }, - "peerDependencies": { - "eslint": "^6.0.0 || ^7.0.0 || >=8.0.0" - } - }, - "node_modules/@eslint-community/eslint-utils/node_modules/eslint-visitor-keys": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", - "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/@eslint-community/regexpp": { - "version": "4.12.1", - "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.12.1.tgz", - "integrity": "sha512-CCZCDJuduB9OUkFkY2IgppNZMi2lBQgD2qzwXkEia16cge2pijY/aXi96CJMquDMn3nJdlPV1A5KrJEXwfLNzQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.0.0 || ^14.0.0 || >=16.0.0" - } - }, - "node_modules/@eslint/config-array": { - "version": "0.20.0", - "resolved": "https://registry.npmjs.org/@eslint/config-array/-/config-array-0.20.0.tgz", - "integrity": "sha512-fxlS1kkIjx8+vy2SjuCB94q3htSNrufYTXubwiBFeaQHbH6Ipi43gFJq2zCMt6PHhImH3Xmr0NksKDvchWlpQQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@eslint/object-schema": "^2.1.6", - "debug": "^4.3.1", - "minimatch": "^3.1.2" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/config-array/node_modules/brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/@eslint/config-array/node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, - "node_modules/@eslint/config-helpers": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/@eslint/config-helpers/-/config-helpers-0.2.1.tgz", - "integrity": "sha512-RI17tsD2frtDu/3dmI7QRrD4bedNKPM08ziRYaC5AhkGrzIAJelm9kJU1TznK+apx6V+cqRz8tfpEeG3oIyjxw==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/core": { - "version": "0.14.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.14.0.tgz", - "integrity": "sha512-qIbV0/JZr7iSDjqAc60IqbLdsj9GDt16xQtWD+B78d/HAlvysGdZZ6rpJHGAc2T0FQx1X6thsSPdnoiGKdNtdg==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@types/json-schema": "^7.0.15" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/eslintrc": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-3.3.1.tgz", - "integrity": "sha512-gtF186CXhIl1p4pJNGZw8Yc6RlshoePRvE0X91oPGb3vZ8pM3qOS9W9NGPat9LziaBV7XrJWGylNQXkGcnM3IQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "ajv": "^6.12.4", - "debug": "^4.3.2", - "espree": "^10.0.1", - "globals": "^14.0.0", - "ignore": "^5.2.0", - "import-fresh": "^3.2.1", - "js-yaml": "^4.1.0", - "minimatch": "^3.1.2", - "strip-json-comments": "^3.1.1" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/@eslint/eslintrc/node_modules/brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/@eslint/eslintrc/node_modules/globals": { - "version": "14.0.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-14.0.0.tgz", - "integrity": "sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@eslint/eslintrc/node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, - "node_modules/@eslint/js": { - "version": "9.27.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.27.0.tgz", - "integrity": "sha512-G5JD9Tu5HJEu4z2Uo4aHY2sLV64B7CDMXxFzqzjl3NKd6RVzSXNoE80jk7Y0lJkTTkjiIhBAqmlYwjuBY3tvpA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://eslint.org/donate" - } - }, - "node_modules/@eslint/object-schema": { - "version": "2.1.6", - "resolved": "https://registry.npmjs.org/@eslint/object-schema/-/object-schema-2.1.6.tgz", - "integrity": "sha512-RBMg5FRL0I0gs51M/guSAj5/e14VQ4tpZnQNWwuDT66P14I43ItmPfIZRhO9fUVIPOAQXU47atlywZ/czoqFPA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/plugin-kit": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.3.1.tgz", - "integrity": "sha512-0J+zgWxHN+xXONWIyPWKFMgVuJoZuGiIFu8yxk7RJjxkzpGmyja5wRFqZIVtjDVOQpV+Rw0iOAjYPE2eQyjr0w==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@eslint/core": "^0.14.0", - "levn": "^0.4.1" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@faker-js/faker": { - "version": "9.8.0", - "resolved": "https://registry.npmjs.org/@faker-js/faker/-/faker-9.8.0.tgz", - "integrity": "sha512-U9wpuSrJC93jZBxx/Qq2wPjCuYISBueyVUGK7qqdmj7r/nxaxwW8AQDCLeRO7wZnjj94sh3p246cAYjUKuqgfg==", - "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/fakerjs" - } - ], - "license": "MIT", - "engines": { - "node": ">=18.0.0", - "npm": ">=9.0.0" - } - }, - "node_modules/@fontsource-variable/space-grotesk": { - "version": "5.2.7", - "resolved": "https://registry.npmjs.org/@fontsource-variable/space-grotesk/-/space-grotesk-5.2.7.tgz", - "integrity": "sha512-/f75B8XXMJgqg5AuboxR7Utkd/GnzZhP5gY0FDdx0M8/CoM8NzH1Jn6bm3gX44Gb+TACI/wiXPgTpph28ipi9g==", - "license": "OFL-1.1", - "funding": { - "url": "https://github.com/sponsors/ayuhito" - } - }, - "node_modules/@fontsource/inter": { - "version": "5.2.5", - "resolved": "https://registry.npmjs.org/@fontsource/inter/-/inter-5.2.5.tgz", - "integrity": "sha512-kbsPKj0S4p44JdYRFiW78Td8Ge2sBVxi/PIBwmih+RpSXUdvS9nbs1HIiuUSPtRMi14CqLEZ/fbk7dj7vni1Sg==", - "license": "OFL-1.1", - "funding": { - "url": "https://github.com/sponsors/ayuhito" - } - }, - "node_modules/@humanfs/core": { - "version": "0.19.1", - "resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.1.tgz", - "integrity": "sha512-5DyQ4+1JEUzejeK1JGICcideyfUbGixgS9jNgex5nqkW+cY7WZhxBigmieN5Qnw9ZosSNVC9KQKyb+GUaGyKUA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanfs/node": { - "version": "0.16.6", - "resolved": "https://registry.npmjs.org/@humanfs/node/-/node-0.16.6.tgz", - "integrity": "sha512-YuI2ZHQL78Q5HbhDiBA1X4LmYdXCKCMQIfw0pw7piHJwyREFebJUvrQN4cMssyES6x+vfUbx1CIpaQUKYdQZOw==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@humanfs/core": "^0.19.1", - "@humanwhocodes/retry": "^0.3.0" - }, - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanfs/node/node_modules/@humanwhocodes/retry": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/retry/-/retry-0.3.1.tgz", - "integrity": "sha512-JBxkERygn7Bv/GbN5Rv8Ul6LVknS+5Bp6RgDC/O8gEBU/yeH5Ui5C/OlWrTb6qct7LjjfT6Re2NxB0ln0yYybA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" - } - }, - "node_modules/@humanwhocodes/module-importer": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", - "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=12.22" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" - } - }, - "node_modules/@humanwhocodes/retry": { - "version": "0.4.2", - "resolved": "https://registry.npmjs.org/@humanwhocodes/retry/-/retry-0.4.2.tgz", - "integrity": "sha512-xeO57FpIu4p1Ri3Jq/EXq4ClRm86dVF2z/+kvFnyqVYRavTZmaFaUBbWCOuuTh0o/g7DSsk6kc2vrS4Vl5oPOQ==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" - } - }, - "node_modules/@iconify-json/material-symbols": { - "version": "1.2.21", - "resolved": "https://registry.npmjs.org/@iconify-json/material-symbols/-/material-symbols-1.2.21.tgz", - "integrity": "sha512-78o99N3oYeWY91EvZDl5bAPSPtO3rgkPwuOfgk4iBLbpb2peE6ueZFiMA/RURpy8jf4Pyt9rUtjP34UJIkVAcA==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@iconify/types": "*" - } - }, - "node_modules/@iconify-json/mdi": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/@iconify-json/mdi/-/mdi-1.2.3.tgz", - "integrity": "sha512-O3cLwbDOK7NNDf2ihaQOH5F9JglnulNDFV7WprU2dSoZu3h3cWH//h74uQAB87brHmvFVxIOkuBX2sZSzYhScg==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@iconify/types": "*" - } - }, - "node_modules/@iconify-json/ri": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/@iconify-json/ri/-/ri-1.2.5.tgz", - "integrity": "sha512-kWGimOXMZrlYusjBKKXYOWcKhbOHusFsmrmRGmjS7rH0BpML5A9/fy8KHZqFOwZfC4M6amObQYbh8BqO5cMC3w==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@iconify/types": "*" - } - }, - "node_modules/@iconify/tools": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/@iconify/tools/-/tools-4.1.1.tgz", - "integrity": "sha512-Hybu/HGhv6T8nLQhiG9rKx+ekF7NNpPOEQAy7JRSKht3s3dcFSsPccYzk24Znc9MTxrR6Gak3cg6CPP5dyvS2Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "@iconify/types": "^2.0.0", - "@iconify/utils": "^2.2.0", - "@types/tar": "^6.1.13", - "axios": "^1.7.9", - "cheerio": "1.0.0", - "domhandler": "^5.0.3", - "extract-zip": "^2.0.1", - "local-pkg": "^0.5.1", - "pathe": "^1.1.2", - "svgo": "^3.3.2", - "tar": "^6.2.1" - } - }, - "node_modules/@iconify/types": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@iconify/types/-/types-2.0.0.tgz", - "integrity": "sha512-+wluvCrRhXrhyOmRDJ3q8mux9JkKy5SJ/v8ol2tu4FVjyYvtEzkc/3pK15ET6RKg4b4w4BmTk1+gsCUhf21Ykg==", - "dev": true, - "license": "MIT" - }, - "node_modules/@iconify/utils": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/@iconify/utils/-/utils-2.3.0.tgz", - "integrity": "sha512-GmQ78prtwYW6EtzXRU1rY+KwOKfz32PD7iJh6Iyqw68GiKuoZ2A6pRtzWONz5VQJbp50mEjXh/7NkumtrAgRKA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@antfu/install-pkg": "^1.0.0", - "@antfu/utils": "^8.1.0", - "@iconify/types": "^2.0.0", - "debug": "^4.4.0", - "globals": "^15.14.0", - "kolorist": "^1.8.0", - "local-pkg": "^1.0.0", - "mlly": "^1.7.4" - } - }, - "node_modules/@iconify/utils/node_modules/globals": { - "version": "15.15.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-15.15.0.tgz", - "integrity": "sha512-7ACyT3wmyp3I61S4fG682L0VA2RGD9otkqGJIwNUMF1SWUombIIk+af1unuDYgMm082aHYwD+mzJvv9Iu8dsgg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@iconify/utils/node_modules/local-pkg": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/local-pkg/-/local-pkg-1.0.0.tgz", - "integrity": "sha512-bbgPw/wmroJsil/GgL4qjDzs5YLTBMQ99weRsok1XCDccQeehbHA/I1oRvk2NPtr7KGZgT/Y5tPRnAtMqeG2Kg==", - "dev": true, - "license": "MIT", - "dependencies": { - "mlly": "^1.7.3", - "pkg-types": "^1.3.0" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/sponsors/antfu" - } - }, - "node_modules/@img/sharp-darwin-arm64": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.33.5.tgz", - "integrity": "sha512-UT4p+iz/2H4twwAoLCqfA9UH5pI6DggwKEGuaPy7nCVQ8ZsiY5PIcrRvD1DzuY3qYL07NtIQcWnBSY/heikIFQ==", - "cpu": [ - "arm64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-darwin-arm64": "1.0.4" - } - }, - "node_modules/@img/sharp-darwin-x64": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.33.5.tgz", - "integrity": "sha512-fyHac4jIc1ANYGRDxtiqelIbdWkIuQaI84Mv45KvGRRxSAa7o7d1ZKAOBaYbnepLC1WqxfpimdeWfvqqSGwR2Q==", - "cpu": [ - "x64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-darwin-x64": "1.0.4" - } - }, - "node_modules/@img/sharp-libvips-darwin-arm64": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.0.4.tgz", - "integrity": "sha512-XblONe153h0O2zuFfTAbQYAX2JhYmDHeWikp1LM9Hul9gVPjFY427k6dFEcOL72O01QxQsWi761svJ/ev9xEDg==", - "cpu": [ - "arm64" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "darwin" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-darwin-x64": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.0.4.tgz", - "integrity": "sha512-xnGR8YuZYfJGmWPvmlunFaWJsb9T/AO2ykoP3Fz/0X5XV2aoYBPkX6xqCQvUTKKiLddarLaxpzNe+b1hjeWHAQ==", - "cpu": [ - "x64" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "darwin" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linux-arm": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.0.5.tgz", - "integrity": "sha512-gvcC4ACAOPRNATg/ov8/MnbxFDJqf/pDePbBnuBDcjsI8PssmjoKMAz4LtLaVi+OnSb5FK/yIOamqDwGmXW32g==", - "cpu": [ - "arm" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linux-arm64": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.0.4.tgz", - "integrity": "sha512-9B+taZ8DlyyqzZQnoeIvDVR/2F4EbMepXMc/NdVbkzsJbzkUjhXv/70GQJ7tdLA4YJgNP25zukcxpX2/SueNrA==", - "cpu": [ - "arm64" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linux-s390x": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.0.4.tgz", - "integrity": "sha512-u7Wz6ntiSSgGSGcjZ55im6uvTrOxSIS8/dgoVMoiGE9I6JAfU50yH5BoDlYA1tcuGS7g/QNtetJnxA6QEsCVTA==", - "cpu": [ - "s390x" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linux-x64": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.0.4.tgz", - "integrity": "sha512-MmWmQ3iPFZr0Iev+BAgVMb3ZyC4KeFc3jFxnNbEPas60e1cIfevbtuyf9nDGIzOaW9PdnDciJm+wFFaTlj5xYw==", - "cpu": [ - "x64" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linuxmusl-arm64": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.0.4.tgz", - "integrity": "sha512-9Ti+BbTYDcsbp4wfYib8Ctm1ilkugkA/uscUn6UXK1ldpC1JjiXbLfFZtRlBhjPZ5o1NCLiDbg8fhUPKStHoTA==", - "cpu": [ - "arm64" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linuxmusl-x64": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.0.4.tgz", - "integrity": "sha512-viYN1KX9m+/hGkJtvYYp+CCLgnJXwiQB39damAO7WMdKWlIhmYTfHjwSbQeUK/20vY154mwezd9HflVFM1wVSw==", - "cpu": [ - "x64" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-linux-arm": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm/-/sharp-linux-arm-0.33.5.tgz", - "integrity": "sha512-JTS1eldqZbJxjvKaAkxhZmBqPRGmxgu+qFKSInv8moZ2AmT5Yib3EQ1c6gp493HvrvV8QgdOXdyaIBrhvFhBMQ==", - "cpu": [ - "arm" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-linux-arm": "1.0.5" - } - }, - "node_modules/@img/sharp-linux-arm64": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm64/-/sharp-linux-arm64-0.33.5.tgz", - "integrity": "sha512-JMVv+AMRyGOHtO1RFBiJy/MBsgz0x4AWrT6QoEVVTyh1E39TrCUpTRI7mx9VksGX4awWASxqCYLCV4wBZHAYxA==", - "cpu": [ - "arm64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-linux-arm64": "1.0.4" - } - }, - "node_modules/@img/sharp-linux-s390x": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-linux-s390x/-/sharp-linux-s390x-0.33.5.tgz", - "integrity": "sha512-y/5PCd+mP4CA/sPDKl2961b+C9d+vPAveS33s6Z3zfASk2j5upL6fXVPZi7ztePZ5CuH+1kW8JtvxgbuXHRa4Q==", - "cpu": [ - "s390x" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-linux-s390x": "1.0.4" - } - }, - "node_modules/@img/sharp-linux-x64": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-linux-x64/-/sharp-linux-x64-0.33.5.tgz", - "integrity": "sha512-opC+Ok5pRNAzuvq1AG0ar+1owsu842/Ab+4qvU879ippJBHvyY5n2mxF1izXqkPYlGuP/M556uh53jRLJmzTWA==", - "cpu": [ - "x64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-linux-x64": "1.0.4" - } - }, - "node_modules/@img/sharp-linuxmusl-arm64": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-arm64/-/sharp-linuxmusl-arm64-0.33.5.tgz", - "integrity": "sha512-XrHMZwGQGvJg2V/oRSUfSAfjfPxO+4DkiRh6p2AFjLQztWUuY/o8Mq0eMQVIY7HJ1CDQUJlxGGZRw1a5bqmd1g==", - "cpu": [ - "arm64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-linuxmusl-arm64": "1.0.4" - } - }, - "node_modules/@img/sharp-linuxmusl-x64": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-x64/-/sharp-linuxmusl-x64-0.33.5.tgz", - "integrity": "sha512-WT+d/cgqKkkKySYmqoZ8y3pxx7lx9vVejxW/W4DOFMYVSkErR+w7mf2u8m/y4+xHe7yY9DAXQMWQhpnMuFfScw==", - "cpu": [ - "x64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-linuxmusl-x64": "1.0.4" - } - }, - "node_modules/@img/sharp-wasm32": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-wasm32/-/sharp-wasm32-0.33.5.tgz", - "integrity": "sha512-ykUW4LVGaMcU9lu9thv85CbRMAwfeadCJHRsg2GmeRa/cJxsVY9Rbd57JcMxBkKHag5U/x7TSBpScF4U8ElVzg==", - "cpu": [ - "wasm32" - ], - "license": "Apache-2.0 AND LGPL-3.0-or-later AND MIT", - "optional": true, - "dependencies": { - "@emnapi/runtime": "^1.2.0" - }, - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-win32-ia32": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-win32-ia32/-/sharp-win32-ia32-0.33.5.tgz", - "integrity": "sha512-T36PblLaTwuVJ/zw/LaH0PdZkRz5rd3SmMHX8GSmR7vtNSP5Z6bQkExdSK7xGWyxLw4sUknBuugTelgw2faBbQ==", - "cpu": [ - "ia32" - ], - "license": "Apache-2.0 AND LGPL-3.0-or-later", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-win32-x64": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/@img/sharp-win32-x64/-/sharp-win32-x64-0.33.5.tgz", - "integrity": "sha512-MpY/o8/8kj+EcnxwvrP4aTJSWw/aZ7JIGR4aBeZkZw5B7/Jn+tY9/VNwtcoGmdT7GfggGIU4kygOMSbYnOrAbg==", - "cpu": [ - "x64" - ], - "license": "Apache-2.0 AND LGPL-3.0-or-later", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@isaacs/fs-minipass": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@isaacs/fs-minipass/-/fs-minipass-4.0.1.tgz", - "integrity": "sha512-wgm9Ehl2jpeqP3zw/7mo3kRHFp5MEDhqAdwy1fTGkHAwnkGOVsgpvQhL8B5n1qlb01jV3n/bI0ZfZp5lWA1k4w==", - "license": "ISC", - "dependencies": { - "minipass": "^7.0.4" - }, - "engines": { - "node": ">=18.0.0" - } - }, - "node_modules/@isaacs/fs-minipass/node_modules/minipass": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", - "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", - "license": "ISC", - "engines": { - "node": ">=16 || 14 >=14.17" - } - }, - "node_modules/@jridgewell/gen-mapping": { - "version": "0.3.8", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.8.tgz", - "integrity": "sha512-imAbBGkb+ebQyxKgzv5Hu2nmROxoDOXHh80evxdoXNOrvAnVx7zimzc1Oo5h9RlfV4vPXaE2iM5pOFbvOCClWA==", - "license": "MIT", - "dependencies": { - "@jridgewell/set-array": "^1.2.1", - "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.24" - }, - "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/@jridgewell/resolve-uri": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", - "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", - "license": "MIT", - "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/@jridgewell/set-array": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", - "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", - "license": "MIT", - "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/@jridgewell/sourcemap-codec": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz", - "integrity": "sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==", - "license": "MIT" - }, - "node_modules/@jridgewell/trace-mapping": { - "version": "0.3.25", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", - "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", - "license": "MIT", - "dependencies": { - "@jridgewell/resolve-uri": "^3.1.0", - "@jridgewell/sourcemap-codec": "^1.4.14" - } - }, - "node_modules/@libsql/client": { - "version": "0.15.2", - "resolved": "https://registry.npmjs.org/@libsql/client/-/client-0.15.2.tgz", - "integrity": "sha512-D0No4jqDj5I+buvEyFajBugohzJXCBt9aRHCEXGrJS/9obnAO2z18Os3xgyPsWX0Yw4NQfSYaayRdowqkssmXA==", - "license": "MIT", - "dependencies": { - "@libsql/core": "^0.15.2", - "@libsql/hrana-client": "^0.7.0", - "js-base64": "^3.7.5", - "libsql": "^0.5.4", - "promise-limit": "^2.7.0" - } - }, - "node_modules/@libsql/core": { - "version": "0.15.2", - "resolved": "https://registry.npmjs.org/@libsql/core/-/core-0.15.2.tgz", - "integrity": "sha512-+UIN0OlzWa54MqnHbtaJ3FEJj6k2VrwrjX1sSSxzYlM+dWuadjMwOVp7gHpSYJGKWw0RQWLGge4fbW4TCvIm3A==", - "license": "MIT", - "dependencies": { - "js-base64": "^3.7.5" - } - }, - "node_modules/@libsql/darwin-arm64": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/@libsql/darwin-arm64/-/darwin-arm64-0.5.4.tgz", - "integrity": "sha512-4PnRdklaQg27vAZxtQgKl+xBHimCH2KRgKId+h63gkAtz5yFTMmX+Q4Ez804T1BgrZuB5ujIvueEEuust2ceSQ==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@libsql/darwin-x64": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/@libsql/darwin-x64/-/darwin-x64-0.5.4.tgz", - "integrity": "sha512-r+Z3UXQWxluXKA5cPj5KciNsmSXVTnq9/tmDczngJrogyXwdbbSShYkzov5M+YBlUCKv2VCbNnfxxoIqQnV9Gg==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@libsql/hrana-client": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/@libsql/hrana-client/-/hrana-client-0.7.0.tgz", - "integrity": "sha512-OF8fFQSkbL7vJY9rfuegK1R7sPgQ6kFMkDamiEccNUvieQ+3urzfDFI616oPl8V7T9zRmnTkSjMOImYCAVRVuw==", - "license": "MIT", - "dependencies": { - "@libsql/isomorphic-fetch": "^0.3.1", - "@libsql/isomorphic-ws": "^0.1.5", - "js-base64": "^3.7.5", - "node-fetch": "^3.3.2" - } - }, - "node_modules/@libsql/isomorphic-fetch": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/@libsql/isomorphic-fetch/-/isomorphic-fetch-0.3.1.tgz", - "integrity": "sha512-6kK3SUK5Uu56zPq/Las620n5aS9xJq+jMBcNSOmjhNf/MUvdyji4vrMTqD7ptY7/4/CAVEAYDeotUz60LNQHtw==", - "license": "MIT", - "engines": { - "node": ">=18.0.0" - } - }, - "node_modules/@libsql/isomorphic-ws": { - "version": "0.1.5", - "resolved": "https://registry.npmjs.org/@libsql/isomorphic-ws/-/isomorphic-ws-0.1.5.tgz", - "integrity": "sha512-DtLWIH29onUYR00i0GlQ3UdcTRC6EP4u9w/h9LxpUZJWRMARk6dQwZ6Jkd+QdwVpuAOrdxt18v0K2uIYR3fwFg==", - "license": "MIT", - "dependencies": { - "@types/ws": "^8.5.4", - "ws": "^8.13.0" - } - }, - "node_modules/@libsql/linux-arm64-gnu": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/@libsql/linux-arm64-gnu/-/linux-arm64-gnu-0.5.4.tgz", - "integrity": "sha512-QmGXa3TGM6URe7vCOqdvr4Koay+4h5D6y4gdhnPCvXNYrRHgpq5OwEafP9GFalbO32Y1ppLY4enO2LwY0k63Qw==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@libsql/linux-arm64-musl": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/@libsql/linux-arm64-musl/-/linux-arm64-musl-0.5.4.tgz", - "integrity": "sha512-cx4/7/xUjgNbiRsghRHujSvIqaTNFQC7Oo1gkGXGsh8hBwkdXr1QdOpeitq745sl6OlbInRrW2C7B2juxX3hcQ==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@libsql/linux-x64-gnu": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/@libsql/linux-x64-gnu/-/linux-x64-gnu-0.5.4.tgz", - "integrity": "sha512-oPrE9Zyqd7fElS9uCGW2jn55cautD+gDIflfyF5+W/QYzll5OJ2vyMBZOBgdNopuZHrmHYihbespJn3t0WJDJg==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@libsql/linux-x64-musl": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/@libsql/linux-x64-musl/-/linux-x64-musl-0.5.4.tgz", - "integrity": "sha512-XzyVdVe43MexkAaHzUvsi4tpPhfSDn3UndIYFrIu0lYkkiz4oKjTK7Iq96j2bcOeJv0pBGxiv+8Z9I6yp/aI2A==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@libsql/win32-x64-msvc": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/@libsql/win32-x64-msvc/-/win32-x64-msvc-0.5.4.tgz", - "integrity": "sha512-xWQyAQEsX+odBrMSXTpm3WOFeoJIX7QncCkaZcsaqdEFueOdNDIdcKAQKMoNlwtj1rCxE72RK4byw/Bflf6Jgg==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@mdx-js/mdx": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@mdx-js/mdx/-/mdx-3.1.0.tgz", - "integrity": "sha512-/QxEhPAvGwbQmy1Px8F899L5Uc2KZ6JtXwlCgJmjSTBedwOZkByYcBG4GceIGPXRDsmfxhHazuS+hlOShRLeDw==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "@types/estree-jsx": "^1.0.0", - "@types/hast": "^3.0.0", - "@types/mdx": "^2.0.0", - "collapse-white-space": "^2.0.0", - "devlop": "^1.0.0", - "estree-util-is-identifier-name": "^3.0.0", - "estree-util-scope": "^1.0.0", - "estree-walker": "^3.0.0", - "hast-util-to-jsx-runtime": "^2.0.0", - "markdown-extensions": "^2.0.0", - "recma-build-jsx": "^1.0.0", - "recma-jsx": "^1.0.0", - "recma-stringify": "^1.0.0", - "rehype-recma": "^1.0.0", - "remark-mdx": "^3.0.0", - "remark-parse": "^11.0.0", - "remark-rehype": "^11.0.0", - "source-map": "^0.7.0", - "unified": "^11.0.0", - "unist-util-position-from-estree": "^2.0.0", - "unist-util-stringify-position": "^4.0.0", - "unist-util-visit": "^5.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/@napi-rs/wasm-runtime": { - "version": "0.2.9", - "resolved": "https://registry.npmjs.org/@napi-rs/wasm-runtime/-/wasm-runtime-0.2.9.tgz", - "integrity": "sha512-OKRBiajrrxB9ATokgEQoG87Z25c67pCpYcCwmXYX8PBftC9pBfN18gnm/fh1wurSLEKIAt+QRFLFCQISrb66Jg==", - "license": "MIT", - "optional": true, - "dependencies": { - "@emnapi/core": "^1.4.0", - "@emnapi/runtime": "^1.4.0", - "@tybys/wasm-util": "^0.9.0" - } - }, - "node_modules/@neon-rs/load": { - "version": "0.0.4", - "resolved": "https://registry.npmjs.org/@neon-rs/load/-/load-0.0.4.tgz", - "integrity": "sha512-kTPhdZyTQxB+2wpiRcFWrDcejc4JI6tkPuS7UZCG4l6Zvc5kU/gGQ/ozvHTh1XR5tS+UlfAfGuPajjzQjCiHCw==", - "license": "MIT" - }, - "node_modules/@nodelib/fs.scandir": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", - "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", - "license": "MIT", - "dependencies": { - "@nodelib/fs.stat": "2.0.5", - "run-parallel": "^1.1.9" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/@nodelib/fs.stat": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", - "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", - "license": "MIT", - "engines": { - "node": ">= 8" - } - }, - "node_modules/@nodelib/fs.walk": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", - "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", - "license": "MIT", - "dependencies": { - "@nodelib/fs.scandir": "2.1.5", - "fastq": "^1.6.0" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/@opentelemetry/api": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/api/-/api-1.9.0.tgz", - "integrity": "sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg==", - "license": "Apache-2.0", - "optional": true, - "peer": true, - "engines": { - "node": ">=8.0.0" - } - }, - "node_modules/@oslojs/encoding": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@oslojs/encoding/-/encoding-1.1.0.tgz", - "integrity": "sha512-70wQhgYmndg4GCPxPPxPGevRKqTIJ2Nh4OkiMWmDAVYsTQ+Ta7Sq+rPevXyXGdzr30/qZBnyOalCszoMxlyldQ==", - "license": "MIT" - }, - "node_modules/@pkgr/core": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/@pkgr/core/-/core-0.1.1.tgz", - "integrity": "sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.20.0 || ^14.18.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/unts" - } - }, - "node_modules/@prisma/client": { - "version": "6.8.2", - "resolved": "https://registry.npmjs.org/@prisma/client/-/client-6.8.2.tgz", - "integrity": "sha512-5II+vbyzv4si6Yunwgkj0qT/iY0zyspttoDrL3R4BYgLdp42/d2C8xdi9vqkrYtKt9H32oFIukvyw3Koz5JoDg==", - "hasInstallScript": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18" - }, - "peerDependencies": { - "prisma": "*", - "typescript": ">=5.1.0" - }, - "peerDependenciesMeta": { - "prisma": { - "optional": true - }, - "typescript": { - "optional": true - } - } - }, - "node_modules/@prisma/config": { - "version": "6.8.2", - "resolved": "https://registry.npmjs.org/@prisma/config/-/config-6.8.2.tgz", - "integrity": "sha512-ZJY1fF4qRBPdLQ/60wxNtX+eu89c3AkYEcP7L3jkp0IPXCNphCYxikTg55kPJLDOG6P0X+QG5tCv6CmsBRZWFQ==", - "devOptional": true, - "license": "Apache-2.0", - "dependencies": { - "jiti": "2.4.2" - } - }, - "node_modules/@prisma/debug": { - "version": "6.7.0", - "resolved": "https://registry.npmjs.org/@prisma/debug/-/debug-6.7.0.tgz", - "integrity": "sha512-RabHn9emKoYFsv99RLxvfG2GHzWk2ZI1BuVzqYtmMSIcuGboHY5uFt3Q3boOREM9de6z5s3bQoyKeWnq8Fz22w==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/@prisma/dmmf": { - "version": "6.7.0", - "resolved": "https://registry.npmjs.org/@prisma/dmmf/-/dmmf-6.7.0.tgz", - "integrity": "sha512-Nabzf5H7KUwYV/1u8R5gTQ7x3ffdPIhtxVJsjhnLOjeuem8YzVu39jOgQbiOlfOvjU4sPYkV9wEXc5tIHumdUw==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/@prisma/engines": { - "version": "6.8.2", - "resolved": "https://registry.npmjs.org/@prisma/engines/-/engines-6.8.2.tgz", - "integrity": "sha512-XqAJ//LXjqYRQ1RRabs79KOY4+v6gZOGzbcwDQl0D6n9WBKjV7qdrbd042CwSK0v0lM9MSHsbcFnU2Yn7z8Zlw==", - "devOptional": true, - "hasInstallScript": true, - "license": "Apache-2.0", - "dependencies": { - "@prisma/debug": "6.8.2", - "@prisma/engines-version": "6.8.0-43.2060c79ba17c6bb9f5823312b6f6b7f4a845738e", - "@prisma/fetch-engine": "6.8.2", - "@prisma/get-platform": "6.8.2" - } - }, - "node_modules/@prisma/engines-version": { - "version": "6.8.0-43.2060c79ba17c6bb9f5823312b6f6b7f4a845738e", - "resolved": "https://registry.npmjs.org/@prisma/engines-version/-/engines-version-6.8.0-43.2060c79ba17c6bb9f5823312b6f6b7f4a845738e.tgz", - "integrity": "sha512-Rkik9lMyHpFNGaLpPF3H5q5TQTkm/aE7DsGM5m92FZTvWQsvmi6Va8On3pWvqLHOt5aPUvFb/FeZTmphI4CPiQ==", - "devOptional": true, - "license": "Apache-2.0" - }, - "node_modules/@prisma/engines/node_modules/@prisma/debug": { - "version": "6.8.2", - "resolved": "https://registry.npmjs.org/@prisma/debug/-/debug-6.8.2.tgz", - "integrity": "sha512-4muBSSUwJJ9BYth5N8tqts8JtiLT8QI/RSAzEogwEfpbYGFo9mYsInsVo8dqXdPO2+Rm5OG5q0qWDDE3nyUbVg==", - "devOptional": true, - "license": "Apache-2.0" - }, - "node_modules/@prisma/fetch-engine": { - "version": "6.8.2", - "resolved": "https://registry.npmjs.org/@prisma/fetch-engine/-/fetch-engine-6.8.2.tgz", - "integrity": "sha512-lCvikWOgaLOfqXGacEKSNeenvj0n3qR5QvZUOmPE2e1Eh8cMYSobxonCg9rqM6FSdTfbpqp9xwhSAOYfNqSW0g==", - "devOptional": true, - "license": "Apache-2.0", - "dependencies": { - "@prisma/debug": "6.8.2", - "@prisma/engines-version": "6.8.0-43.2060c79ba17c6bb9f5823312b6f6b7f4a845738e", - "@prisma/get-platform": "6.8.2" - } - }, - "node_modules/@prisma/fetch-engine/node_modules/@prisma/debug": { - "version": "6.8.2", - "resolved": "https://registry.npmjs.org/@prisma/debug/-/debug-6.8.2.tgz", - "integrity": "sha512-4muBSSUwJJ9BYth5N8tqts8JtiLT8QI/RSAzEogwEfpbYGFo9mYsInsVo8dqXdPO2+Rm5OG5q0qWDDE3nyUbVg==", - "devOptional": true, - "license": "Apache-2.0" - }, - "node_modules/@prisma/generator": { - "version": "6.7.0", - "resolved": "https://registry.npmjs.org/@prisma/generator/-/generator-6.7.0.tgz", - "integrity": "sha512-wCsD7QJn1JBKJfv5uOMhwBCvZPGerPJ3EC2HocFPFaHSzVIXLi/zNb/8gpBxervOXTbQRJ2dpqvMsJnwAnPi8A==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/@prisma/generator-helper": { - "version": "6.7.0", - "resolved": "https://registry.npmjs.org/@prisma/generator-helper/-/generator-helper-6.7.0.tgz", - "integrity": "sha512-z4ey7n8eUFx7Ol7RJCoEo9SVK2roy80qLXdrUFlmswcs0e/z03wDl4tpaA02BE2Yi9KCZl2Tkd6oMes81vUefA==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@prisma/debug": "6.7.0", - "@prisma/dmmf": "6.7.0", - "@prisma/generator": "6.7.0" - } - }, - "node_modules/@prisma/get-platform": { - "version": "6.8.2", - "resolved": "https://registry.npmjs.org/@prisma/get-platform/-/get-platform-6.8.2.tgz", - "integrity": "sha512-vXSxyUgX3vm1Q70QwzwkjeYfRryIvKno1SXbIqwSptKwqKzskINnDUcx85oX+ys6ooN2ATGSD0xN2UTfg6Zcow==", - "devOptional": true, - "license": "Apache-2.0", - "dependencies": { - "@prisma/debug": "6.8.2" - } - }, - "node_modules/@prisma/get-platform/node_modules/@prisma/debug": { - "version": "6.8.2", - "resolved": "https://registry.npmjs.org/@prisma/debug/-/debug-6.8.2.tgz", - "integrity": "sha512-4muBSSUwJJ9BYth5N8tqts8JtiLT8QI/RSAzEogwEfpbYGFo9mYsInsVo8dqXdPO2+Rm5OG5q0qWDDE3nyUbVg==", - "devOptional": true, - "license": "Apache-2.0" - }, - "node_modules/@redis/bloom": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@redis/bloom/-/bloom-5.0.1.tgz", - "integrity": "sha512-F7L+rnuJvq/upKaVoEgsf8VT7g5pLQYWRqSUOV3uO4vpVtARzSKJ7CLyJjVsQS+wZVCGxsLMh8DwAIDcny1B+g==", - "license": "MIT", - "engines": { - "node": ">= 18" - }, - "peerDependencies": { - "@redis/client": "^5.0.1" - } - }, - "node_modules/@redis/client": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@redis/client/-/client-5.0.1.tgz", - "integrity": "sha512-k0EJvlMGEyBqUD3orKe0UMZ66fPtfwqPIr+ZSd853sXj2EyhNtPXSx+J6sENXJNgAlEBhvD+57Dwt0qTisKB0A==", - "license": "MIT", - "dependencies": { - "cluster-key-slot": "1.1.2" - }, - "engines": { - "node": ">= 18" - } - }, - "node_modules/@redis/json": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@redis/json/-/json-5.0.1.tgz", - "integrity": "sha512-t94HOTk5myfhvaHZzlUzk2hoUvH2jsjftcnMgJWuHL/pzjAJQoZDCUJzjkoXIUjWXuyJixTguaaDyOZWwqH2Kg==", - "license": "MIT", - "engines": { - "node": ">= 18" - }, - "peerDependencies": { - "@redis/client": "^5.0.1" - } - }, - "node_modules/@redis/search": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@redis/search/-/search-5.0.1.tgz", - "integrity": "sha512-wipK6ZptY7K68B7YLVhP5I/wYCDUU+mDJMyJiUcQLuOs7/eKOBc8lTXKUSssor8QnzZSPy4A5ulcC5PZY22Zgw==", - "license": "MIT", - "engines": { - "node": ">= 18" - }, - "peerDependencies": { - "@redis/client": "^5.0.1" - } - }, - "node_modules/@redis/time-series": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@redis/time-series/-/time-series-5.0.1.tgz", - "integrity": "sha512-k6PgbrakhnohsEWEAdQZYt3e5vSKoIzpKvgQt8//lnWLrTZx+c3ed2sj0+pKIF4FvnSeuXLo4bBWcH0Z7Urg1A==", - "license": "MIT", - "engines": { - "node": ">= 18" - }, - "peerDependencies": { - "@redis/client": "^5.0.1" - } - }, - "node_modules/@resvg/resvg-wasm": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/@resvg/resvg-wasm/-/resvg-wasm-2.4.0.tgz", - "integrity": "sha512-C7c51Nn4yTxXFKvgh2txJFNweaVcfUPQxwEUFw4aWsCmfiBDJsTSwviIF8EcwjQ6k8bPyMWCl1vw4BdxE569Cg==", - "license": "MPL-2.0", - "engines": { - "node": ">= 10" - } - }, - "node_modules/@rollup/pluginutils": { - "version": "5.1.4", - "resolved": "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-5.1.4.tgz", - "integrity": "sha512-USm05zrsFxYLPdWWq+K3STlWiT/3ELn3RcV5hJMghpeAIhxfsUIg6mt12CBJBInWMV4VneoV7SfGv8xIwo2qNQ==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "estree-walker": "^2.0.2", - "picomatch": "^4.0.2" - }, - "engines": { - "node": ">=14.0.0" - }, - "peerDependencies": { - "rollup": "^1.20.0||^2.0.0||^3.0.0||^4.0.0" - }, - "peerDependenciesMeta": { - "rollup": { - "optional": true - } - } - }, - "node_modules/@rollup/pluginutils/node_modules/estree-walker": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz", - "integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==", - "license": "MIT" - }, - "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.40.1.tgz", - "integrity": "sha512-kxz0YeeCrRUHz3zyqvd7n+TVRlNyTifBsmnmNPtk3hQURUyG9eAB+usz6DAwagMusjx/zb3AjvDUvhFGDAexGw==", - "cpu": [ - "arm" - ], - "license": "MIT", - "optional": true, - "os": [ - "android" - ] - }, - "node_modules/@rollup/rollup-android-arm64": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.40.1.tgz", - "integrity": "sha512-PPkxTOisoNC6TpnDKatjKkjRMsdaWIhyuMkA4UsBXT9WEZY4uHezBTjs6Vl4PbqQQeu6oION1w2voYZv9yquCw==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "android" - ] - }, - "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.40.1.tgz", - "integrity": "sha512-VWXGISWFY18v/0JyNUy4A46KCFCb9NVsH+1100XP31lud+TzlezBbz24CYzbnA4x6w4hx+NYCXDfnvDVO6lcAA==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.40.1.tgz", - "integrity": "sha512-nIwkXafAI1/QCS7pxSpv/ZtFW6TXcNUEHAIA9EIyw5OzxJZQ1YDrX+CL6JAIQgZ33CInl1R6mHet9Y/UZTg2Bw==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@rollup/rollup-freebsd-arm64": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.40.1.tgz", - "integrity": "sha512-BdrLJ2mHTrIYdaS2I99mriyJfGGenSaP+UwGi1kB9BLOCu9SR8ZpbkmmalKIALnRw24kM7qCN0IOm6L0S44iWw==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ] - }, - "node_modules/@rollup/rollup-freebsd-x64": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.40.1.tgz", - "integrity": "sha512-VXeo/puqvCG8JBPNZXZf5Dqq7BzElNJzHRRw3vjBE27WujdzuOPecDPc/+1DcdcTptNBep3861jNq0mYkT8Z6Q==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ] - }, - "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.40.1.tgz", - "integrity": "sha512-ehSKrewwsESPt1TgSE/na9nIhWCosfGSFqv7vwEtjyAqZcvbGIg4JAcV7ZEh2tfj/IlfBeZjgOXm35iOOjadcg==", - "cpu": [ - "arm" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.40.1.tgz", - "integrity": "sha512-m39iO/aaurh5FVIu/F4/Zsl8xppd76S4qoID8E+dSRQvTyZTOI2gVk3T4oqzfq1PtcvOfAVlwLMK3KRQMaR8lg==", - "cpu": [ - "arm" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.40.1.tgz", - "integrity": "sha512-Y+GHnGaku4aVLSgrT0uWe2o2Rq8te9hi+MwqGF9r9ORgXhmHK5Q71N757u0F8yU1OIwUIFy6YiJtKjtyktk5hg==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.40.1.tgz", - "integrity": "sha512-jEwjn3jCA+tQGswK3aEWcD09/7M5wGwc6+flhva7dsQNRZZTe30vkalgIzV4tjkopsTS9Jd7Y1Bsj6a4lzz8gQ==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-loongarch64-gnu": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.40.1.tgz", - "integrity": "sha512-ySyWikVhNzv+BV/IDCsrraOAZ3UaC8SZB67FZlqVwXwnFhPihOso9rPOxzZbjp81suB1O2Topw+6Ug3JNegejQ==", - "cpu": [ - "loong64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.40.1.tgz", - "integrity": "sha512-BvvA64QxZlh7WZWqDPPdt0GH4bznuL6uOO1pmgPnnv86rpUpc8ZxgZwcEgXvo02GRIZX1hQ0j0pAnhwkhwPqWg==", - "cpu": [ - "ppc64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.40.1.tgz", - "integrity": "sha512-EQSP+8+1VuSulm9RKSMKitTav89fKbHymTf25n5+Yr6gAPZxYWpj3DzAsQqoaHAk9YX2lwEyAf9S4W8F4l3VBQ==", - "cpu": [ - "riscv64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-riscv64-musl": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.40.1.tgz", - "integrity": "sha512-n/vQ4xRZXKuIpqukkMXZt9RWdl+2zgGNx7Uda8NtmLJ06NL8jiHxUawbwC+hdSq1rrw/9CghCpEONor+l1e2gA==", - "cpu": [ - "riscv64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.40.1.tgz", - "integrity": "sha512-h8d28xzYb98fMQKUz0w2fMc1XuGzLLjdyxVIbhbil4ELfk5/orZlSTpF/xdI9C8K0I8lCkq+1En2RJsawZekkg==", - "cpu": [ - "s390x" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.40.1.tgz", - "integrity": "sha512-XiK5z70PEFEFqcNj3/zRSz/qX4bp4QIraTy9QjwJAb/Z8GM7kVUsD0Uk8maIPeTyPCP03ChdI+VVmJriKYbRHQ==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.40.1.tgz", - "integrity": "sha512-2BRORitq5rQ4Da9blVovzNCMaUlyKrzMSvkVR0D4qPuOy/+pMCrh1d7o01RATwVy+6Fa1WBw+da7QPeLWU/1mQ==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.40.1.tgz", - "integrity": "sha512-b2bcNm9Kbde03H+q+Jjw9tSfhYkzrDUf2d5MAd1bOJuVplXvFhWz7tRtWvD8/ORZi7qSCy0idW6tf2HgxSXQSg==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.40.1.tgz", - "integrity": "sha512-DfcogW8N7Zg7llVEfpqWMZcaErKfsj9VvmfSyRjCyo4BI3wPEfrzTtJkZG6gKP/Z92wFm6rz2aDO7/JfiR/whA==", - "cpu": [ - "ia32" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.40.1.tgz", - "integrity": "sha512-ECyOuDeH3C1I8jH2MK1RtBJW+YPMvSfT0a5NN0nHfQYnDSJ6tUiZH3gzwVP5/Kfh/+Tt7tpWVF9LXNTnhTJ3kA==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@rtsao/scc": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@rtsao/scc/-/scc-1.1.0.tgz", - "integrity": "sha512-zt6OdqaDoOnJ1ZYsCYGt9YmWzDXl4vQdKTyJev62gFhRGKdx7mcT54V9KIjg+d2wi9EXsPvAPKe7i7WjfVWB8g==", - "dev": true, - "license": "MIT" - }, - "node_modules/@rvf/set-get": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/@rvf/set-get/-/set-get-7.0.1.tgz", - "integrity": "sha512-GkTSn9K1GrTYoTUqlUs36k6nJnzjQaFBTTEIqUYmzBcsGsoJM8xG7EAx2WLHWAA4QzFjcwWUSHQ3vM3Fbw50Tg==", - "license": "MIT" - }, - "node_modules/@shikijs/core": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/@shikijs/core/-/core-3.2.1.tgz", - "integrity": "sha512-FhsdxMWYu/C11sFisEp7FMGBtX/OSSbnXZDMBhGuUDBNTdsoZlMSgQv5f90rwvzWAdWIW6VobD+G3IrazxA6dQ==", - "license": "MIT", - "dependencies": { - "@shikijs/types": "3.2.1", - "@shikijs/vscode-textmate": "^10.0.2", - "@types/hast": "^3.0.4", - "hast-util-to-html": "^9.0.5" - } - }, - "node_modules/@shikijs/engine-javascript": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/@shikijs/engine-javascript/-/engine-javascript-3.2.1.tgz", - "integrity": "sha512-eMdcUzN3FMQYxOmRf2rmU8frikzoSHbQDFH2hIuXsrMO+IBOCI9BeeRkCiBkcLDHeRKbOCtYMJK3D6U32ooU9Q==", - "license": "MIT", - "dependencies": { - "@shikijs/types": "3.2.1", - "@shikijs/vscode-textmate": "^10.0.2", - "oniguruma-to-es": "^4.1.0" - } - }, - "node_modules/@shikijs/engine-oniguruma": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/@shikijs/engine-oniguruma/-/engine-oniguruma-3.2.1.tgz", - "integrity": "sha512-wZZAkayEn6qu2+YjenEoFqj0OyQI64EWsNR6/71d1EkG4sxEOFooowKivsWPpaWNBu3sxAG+zPz5kzBL/SsreQ==", - "license": "MIT", - "dependencies": { - "@shikijs/types": "3.2.1", - "@shikijs/vscode-textmate": "^10.0.2" - } - }, - "node_modules/@shikijs/langs": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/@shikijs/langs/-/langs-3.2.1.tgz", - "integrity": "sha512-If0iDHYRSGbihiA8+7uRsgb1er1Yj11pwpX1c6HLYnizDsKAw5iaT3JXj5ZpaimXSWky/IhxTm7C6nkiYVym+A==", - "license": "MIT", - "dependencies": { - "@shikijs/types": "3.2.1" - } - }, - "node_modules/@shikijs/themes": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/@shikijs/themes/-/themes-3.2.1.tgz", - "integrity": "sha512-k5DKJUT8IldBvAm8WcrDT5+7GA7se6lLksR+2E3SvyqGTyFMzU2F9Gb7rmD+t+Pga1MKrYFxDIeyWjMZWM6uBQ==", - "license": "MIT", - "dependencies": { - "@shikijs/types": "3.2.1" - } - }, - "node_modules/@shikijs/types": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/@shikijs/types/-/types-3.2.1.tgz", - "integrity": "sha512-/NTWAk4KE2M8uac0RhOsIhYQf4pdU0OywQuYDGIGAJ6Mjunxl2cGiuLkvu4HLCMn+OTTLRWkjZITp+aYJv60yA==", - "license": "MIT", - "dependencies": { - "@shikijs/vscode-textmate": "^10.0.2", - "@types/hast": "^3.0.4" - } - }, - "node_modules/@shikijs/vscode-textmate": { - "version": "10.0.2", - "resolved": "https://registry.npmjs.org/@shikijs/vscode-textmate/-/vscode-textmate-10.0.2.tgz", - "integrity": "sha512-83yeghZ2xxin3Nj8z1NMd/NCuca+gsYXswywDy5bHvwlWL8tpTQmzGeUuHd9FC3E/SBEMvzJRwWEOz5gGes9Qg==", - "license": "MIT" - }, - "node_modules/@shuding/opentype.js": { - "version": "1.4.0-beta.0", - "resolved": "https://registry.npmjs.org/@shuding/opentype.js/-/opentype.js-1.4.0-beta.0.tgz", - "integrity": "sha512-3NgmNyH3l/Hv6EvsWJbsvpcpUba6R8IREQ83nH83cyakCw7uM1arZKNfHwv1Wz6jgqrF/j4x5ELvR6PnK9nTcA==", - "license": "MIT", - "dependencies": { - "fflate": "^0.7.3", - "string.prototype.codepointat": "^0.2.1" - }, - "bin": { - "ot": "bin/ot" - }, - "engines": { - "node": ">= 8.0.0" - } - }, - "node_modules/@stylistic/eslint-plugin": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@stylistic/eslint-plugin/-/eslint-plugin-4.2.0.tgz", - "integrity": "sha512-8hXezgz7jexGHdo5WN6JBEIPHCSFyyU4vgbxevu4YLVS5vl+sxqAAGyXSzfNDyR6xMNSH5H1x67nsXcYMOHtZA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/utils": "^8.23.0", - "eslint-visitor-keys": "^4.2.0", - "espree": "^10.3.0", - "estraverse": "^5.3.0", - "picomatch": "^4.0.2" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "peerDependencies": { - "eslint": ">=9.0.0" - } - }, - "node_modules/@swc/helpers": { - "version": "0.5.17", - "resolved": "https://registry.npmjs.org/@swc/helpers/-/helpers-0.5.17.tgz", - "integrity": "sha512-5IKx/Y13RsYd+sauPb2x+U/xZikHjolzfuDgTAl/Tdf3Q8rslRvC19NKDLgAJQ6wsqADk10ntlv08nPFw/gO/A==", - "license": "Apache-2.0", - "dependencies": { - "tslib": "^2.8.0" - } - }, - "node_modules/@tailwindcss/forms": { - "version": "0.5.10", - "resolved": "https://registry.npmjs.org/@tailwindcss/forms/-/forms-0.5.10.tgz", - "integrity": "sha512-utI1ONF6uf/pPNO68kmN1b8rEwNXv3czukalo8VtJH8ksIkZXr3Q3VYudZLkCsDd4Wku120uF02hYK25XGPorw==", - "dev": true, - "license": "MIT", - "dependencies": { - "mini-svg-data-uri": "^1.2.3" - }, - "peerDependencies": { - "tailwindcss": ">=3.0.0 || >= 3.0.0-alpha.1 || >= 4.0.0-alpha.20 || >= 4.0.0-beta.1" - } - }, - "node_modules/@tailwindcss/node": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/node/-/node-4.1.7.tgz", - "integrity": "sha512-9rsOpdY9idRI2NH6CL4wORFY0+Q6fnx9XP9Ju+iq/0wJwGD5IByIgFmwVbyy4ymuyprj8Qh4ErxMKTUL4uNh3g==", - "license": "MIT", - "dependencies": { - "@ampproject/remapping": "^2.3.0", - "enhanced-resolve": "^5.18.1", - "jiti": "^2.4.2", - "lightningcss": "1.30.1", - "magic-string": "^0.30.17", - "source-map-js": "^1.2.1", - "tailwindcss": "4.1.7" - } - }, - "node_modules/@tailwindcss/oxide": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide/-/oxide-4.1.7.tgz", - "integrity": "sha512-5SF95Ctm9DFiUyjUPnDGkoKItPX/k+xifcQhcqX5RA85m50jw1pT/KzjdvlqxRja45Y52nR4MR9fD1JYd7f8NQ==", - "hasInstallScript": true, - "license": "MIT", - "dependencies": { - "detect-libc": "^2.0.4", - "tar": "^7.4.3" - }, - "engines": { - "node": ">= 10" - }, - "optionalDependencies": { - "@tailwindcss/oxide-android-arm64": "4.1.7", - "@tailwindcss/oxide-darwin-arm64": "4.1.7", - "@tailwindcss/oxide-darwin-x64": "4.1.7", - "@tailwindcss/oxide-freebsd-x64": "4.1.7", - "@tailwindcss/oxide-linux-arm-gnueabihf": "4.1.7", - "@tailwindcss/oxide-linux-arm64-gnu": "4.1.7", - "@tailwindcss/oxide-linux-arm64-musl": "4.1.7", - "@tailwindcss/oxide-linux-x64-gnu": "4.1.7", - "@tailwindcss/oxide-linux-x64-musl": "4.1.7", - "@tailwindcss/oxide-wasm32-wasi": "4.1.7", - "@tailwindcss/oxide-win32-arm64-msvc": "4.1.7", - "@tailwindcss/oxide-win32-x64-msvc": "4.1.7" - } - }, - "node_modules/@tailwindcss/oxide-android-arm64": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-android-arm64/-/oxide-android-arm64-4.1.7.tgz", - "integrity": "sha512-IWA410JZ8fF7kACus6BrUwY2Z1t1hm0+ZWNEzykKmMNM09wQooOcN/VXr0p/WJdtHZ90PvJf2AIBS/Ceqx1emg==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-darwin-arm64": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-arm64/-/oxide-darwin-arm64-4.1.7.tgz", - "integrity": "sha512-81jUw9To7fimGGkuJ2W5h3/oGonTOZKZ8C2ghm/TTxbwvfSiFSDPd6/A/KE2N7Jp4mv3Ps9OFqg2fEKgZFfsvg==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-darwin-x64": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-x64/-/oxide-darwin-x64-4.1.7.tgz", - "integrity": "sha512-q77rWjEyGHV4PdDBtrzO0tgBBPlQWKY7wZK0cUok/HaGgbNKecegNxCGikuPJn5wFAlIywC3v+WMBt0PEBtwGw==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-freebsd-x64": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-freebsd-x64/-/oxide-freebsd-x64-4.1.7.tgz", - "integrity": "sha512-RfmdbbK6G6ptgF4qqbzoxmH+PKfP4KSVs7SRlTwcbRgBwezJkAO3Qta/7gDy10Q2DcUVkKxFLXUQO6J3CRvBGw==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-linux-arm-gnueabihf": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm-gnueabihf/-/oxide-linux-arm-gnueabihf-4.1.7.tgz", - "integrity": "sha512-OZqsGvpwOa13lVd1z6JVwQXadEobmesxQ4AxhrwRiPuE04quvZHWn/LnihMg7/XkN+dTioXp/VMu/p6A5eZP3g==", - "cpu": [ - "arm" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-linux-arm64-gnu": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-gnu/-/oxide-linux-arm64-gnu-4.1.7.tgz", - "integrity": "sha512-voMvBTnJSfKecJxGkoeAyW/2XRToLZ227LxswLAwKY7YslG/Xkw9/tJNH+3IVh5bdYzYE7DfiaPbRkSHFxY1xA==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-linux-arm64-musl": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-musl/-/oxide-linux-arm64-musl-4.1.7.tgz", - "integrity": "sha512-PjGuNNmJeKHnP58M7XyjJyla8LPo+RmwHQpBI+W/OxqrwojyuCQ+GUtygu7jUqTEexejZHr/z3nBc/gTiXBj4A==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-linux-x64-gnu": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-gnu/-/oxide-linux-x64-gnu-4.1.7.tgz", - "integrity": "sha512-HMs+Va+ZR3gC3mLZE00gXxtBo3JoSQxtu9lobbZd+DmfkIxR54NO7Z+UQNPsa0P/ITn1TevtFxXTpsRU7qEvWg==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-linux-x64-musl": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-musl/-/oxide-linux-x64-musl-4.1.7.tgz", - "integrity": "sha512-MHZ6jyNlutdHH8rd+YTdr3QbXrHXqwIhHw9e7yXEBcQdluGwhpQY2Eku8UZK6ReLaWtQ4gijIv5QoM5eE+qlsA==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-wasm32-wasi": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-wasm32-wasi/-/oxide-wasm32-wasi-4.1.7.tgz", - "integrity": "sha512-ANaSKt74ZRzE2TvJmUcbFQ8zS201cIPxUDm5qez5rLEwWkie2SkGtA4P+GPTj+u8N6JbPrC8MtY8RmJA35Oo+A==", - "bundleDependencies": [ - "@napi-rs/wasm-runtime", - "@emnapi/core", - "@emnapi/runtime", - "@tybys/wasm-util", - "@emnapi/wasi-threads", - "tslib" - ], - "cpu": [ - "wasm32" - ], - "license": "MIT", - "optional": true, - "dependencies": { - "@emnapi/core": "^1.4.3", - "@emnapi/runtime": "^1.4.3", - "@emnapi/wasi-threads": "^1.0.2", - "@napi-rs/wasm-runtime": "^0.2.9", - "@tybys/wasm-util": "^0.9.0", - "tslib": "^2.8.0" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@tailwindcss/oxide-win32-arm64-msvc": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-arm64-msvc/-/oxide-win32-arm64-msvc-4.1.7.tgz", - "integrity": "sha512-HUiSiXQ9gLJBAPCMVRk2RT1ZrBjto7WvqsPBwUrNK2BcdSxMnk19h4pjZjI7zgPhDxlAbJSumTC4ljeA9y0tEw==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide-win32-x64-msvc": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-x64-msvc/-/oxide-win32-x64-msvc-4.1.7.tgz", - "integrity": "sha512-rYHGmvoHiLJ8hWucSfSOEmdCBIGZIq7SpkPRSqLsH2Ab2YUNgKeAPT1Fi2cx3+hnYOrAb0jp9cRyode3bBW4mQ==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 10" - } - }, - "node_modules/@tailwindcss/oxide/node_modules/chownr": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-3.0.0.tgz", - "integrity": "sha512-+IxzY9BZOQd/XuYPRmrvEVjF/nqj5kgT4kEq7VofrDoM1MxoRjEWkrCC3EtLi59TVawxTAn+orJwFQcrqEN1+g==", - "license": "BlueOak-1.0.0", - "engines": { - "node": ">=18" - } - }, - "node_modules/@tailwindcss/oxide/node_modules/minipass": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", - "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", - "license": "ISC", - "engines": { - "node": ">=16 || 14 >=14.17" - } - }, - "node_modules/@tailwindcss/oxide/node_modules/minizlib": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-3.0.2.tgz", - "integrity": "sha512-oG62iEk+CYt5Xj2YqI5Xi9xWUeZhDI8jjQmC5oThVH5JGCTgIjr7ciJDzC7MBzYd//WvR1OTmP5Q38Q8ShQtVA==", - "license": "MIT", - "dependencies": { - "minipass": "^7.1.2" - }, - "engines": { - "node": ">= 18" - } - }, - "node_modules/@tailwindcss/oxide/node_modules/mkdirp": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-3.0.1.tgz", - "integrity": "sha512-+NsyUUAZDmo6YVHzL/stxSu3t9YS1iljliy3BSDrXJ/dkn1KYdmtZODGGjLcc9XLgVVpH4KshHB8XmZgMhaBXg==", - "license": "MIT", - "bin": { - "mkdirp": "dist/cjs/src/bin.js" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/@tailwindcss/oxide/node_modules/tar": { - "version": "7.4.3", - "resolved": "https://registry.npmjs.org/tar/-/tar-7.4.3.tgz", - "integrity": "sha512-5S7Va8hKfV7W5U6g3aYxXmlPoZVAwUMy9AOKyF2fVuZa2UD3qZjg578OrLRt8PcNN1PleVaL/5/yYATNL0ICUw==", - "license": "ISC", - "dependencies": { - "@isaacs/fs-minipass": "^4.0.0", - "chownr": "^3.0.0", - "minipass": "^7.1.2", - "minizlib": "^3.0.1", - "mkdirp": "^3.0.1", - "yallist": "^5.0.0" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/@tailwindcss/oxide/node_modules/yallist": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-5.0.0.tgz", - "integrity": "sha512-YgvUTfwqyc7UXVMrB+SImsVYSmTS8X/tSrtdNZMImM+n7+QTriRXyXim0mBrTXNeqzVF0KWGgHPeiyViFFrNDw==", - "license": "BlueOak-1.0.0", - "engines": { - "node": ">=18" - } - }, - "node_modules/@tailwindcss/typography": { - "version": "0.5.16", - "resolved": "https://registry.npmjs.org/@tailwindcss/typography/-/typography-0.5.16.tgz", - "integrity": "sha512-0wDLwCVF5V3x3b1SGXPCDcdsbDHMBe+lkFzBRaHeLvNi+nrrnZ1lA18u+OTWO8iSWU2GxUOCvlXtDuqftc1oiA==", - "dev": true, - "license": "MIT", - "dependencies": { - "lodash.castarray": "^4.4.0", - "lodash.isplainobject": "^4.0.6", - "lodash.merge": "^4.6.2", - "postcss-selector-parser": "6.0.10" - }, - "peerDependencies": { - "tailwindcss": ">=3.0.0 || insiders || >=4.0.0-alpha.20 || >=4.0.0-beta.1" - } - }, - "node_modules/@tailwindcss/vite": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/vite/-/vite-4.1.7.tgz", - "integrity": "sha512-tYa2fO3zDe41I7WqijyVbRd8oWT0aEID1Eokz5hMT6wShLIHj3yvwj9XbfuloHP9glZ6H+aG2AN/+ZrxJ1Y5RQ==", - "license": "MIT", - "dependencies": { - "@tailwindcss/node": "4.1.7", - "@tailwindcss/oxide": "4.1.7", - "tailwindcss": "4.1.7" - }, - "peerDependencies": { - "vite": "^5.2.0 || ^6" - } - }, - "node_modules/@trysound/sax": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/@trysound/sax/-/sax-0.2.0.tgz", - "integrity": "sha512-L7z9BgrNEcYyUYtF+HaEfiS5ebkh9jXqbszz7pC0hRBPaatV0XjSD3+eHrpqFemQfgwiFF0QPIarnIihIDn7OA==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=10.13.0" - } - }, - "node_modules/@tybys/wasm-util": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/@tybys/wasm-util/-/wasm-util-0.9.0.tgz", - "integrity": "sha512-6+7nlbMVX/PVDCwaIQ8nTOPveOcFLSt8GcXdx8hD0bt39uWxYT88uXzqTd4fTvqta7oeUJqudepapKNt2DYJFw==", - "license": "MIT", - "optional": true, - "dependencies": { - "tslib": "^2.4.0" - } - }, - "node_modules/@types/debug": { - "version": "4.1.12", - "resolved": "https://registry.npmjs.org/@types/debug/-/debug-4.1.12.tgz", - "integrity": "sha512-vIChWdVG3LG1SMxEvI/AK+FWJthlrqlTu7fbrlywTkkaONwk/UAGaULXRlf8vkzFBLVm0zkMdCquhL5aOjhXPQ==", - "license": "MIT", - "dependencies": { - "@types/ms": "*" - } - }, - "node_modules/@types/eslint__js": { - "version": "9.14.0", - "resolved": "https://registry.npmjs.org/@types/eslint__js/-/eslint__js-9.14.0.tgz", - "integrity": "sha512-s0jepCjOJWB/GKcuba4jISaVpBudw3ClXJ3fUK4tugChUMQsp6kSwuA8Dcx6wFd/JsJqcY8n4rEpa5RTHs5ypA==", - "deprecated": "This is a stub types definition. @eslint/js provides its own type definitions, so you do not need this installed.", - "dev": true, - "license": "MIT", - "dependencies": { - "@eslint/js": "*" - } - }, - "node_modules/@types/estree": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.7.tgz", - "integrity": "sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==", - "license": "MIT" - }, - "node_modules/@types/estree-jsx": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/@types/estree-jsx/-/estree-jsx-1.0.5.tgz", - "integrity": "sha512-52CcUVNFyfb1A2ALocQw/Dd1BQFNmSdkuC3BkZ6iqhdMfQz7JWOFRuJFloOzjk+6WijU56m9oKXFAXc7o3Towg==", - "license": "MIT", - "dependencies": { - "@types/estree": "*" - } - }, - "node_modules/@types/fontkit": { - "version": "2.0.8", - "resolved": "https://registry.npmjs.org/@types/fontkit/-/fontkit-2.0.8.tgz", - "integrity": "sha512-wN+8bYxIpJf+5oZdrdtaX04qUuWHcKxcDEgRS9Qm9ZClSHjzEn13SxUC+5eRM+4yXIeTYk8mTzLAWGF64847ew==", - "license": "MIT", - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@types/hast": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@types/hast/-/hast-3.0.4.tgz", - "integrity": "sha512-WPs+bbQw5aCj+x6laNGWLH3wviHtoCv/P3+otBhbOhJgG8qtpdAMlTCxLtsTWA7LH1Oh/bFCHsBn0TPS5m30EQ==", - "license": "MIT", - "dependencies": { - "@types/unist": "*" - } - }, - "node_modules/@types/json-schema": { - "version": "7.0.15", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", - "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", - "dev": true, - "license": "MIT" - }, - "node_modules/@types/json5": { - "version": "0.0.29", - "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", - "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/@types/lodash": { - "version": "4.17.15", - "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.17.15.tgz", - "integrity": "sha512-w/P33JFeySuhN6JLkysYUK2gEmy9kHHFN7E8ro0tkfmlDOgxBDzWEZ/J8cWA+fHqFevpswDTFZnDx+R9lbL6xw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@types/lodash-es": { - "version": "4.17.12", - "resolved": "https://registry.npmjs.org/@types/lodash-es/-/lodash-es-4.17.12.tgz", - "integrity": "sha512-0NgftHUcV4v34VhXm8QBSftKVXtbkBG3ViCjs6+eJ5a6y6Mi/jiFGPc1sC7QK+9BFhWrURE3EOggmWaSxL9OzQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@types/lodash": "*" - } - }, - "node_modules/@types/mdast": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@types/mdast/-/mdast-4.0.4.tgz", - "integrity": "sha512-kGaNbPh1k7AFzgpud/gMdvIm5xuECykRR+JnWKQno9TAXVa6WIVCGTPvYGekIDL4uwCZQSYbUxNBSb1aUo79oA==", - "license": "MIT", - "dependencies": { - "@types/unist": "*" - } - }, - "node_modules/@types/mdx": { - "version": "2.0.13", - "resolved": "https://registry.npmjs.org/@types/mdx/-/mdx-2.0.13.tgz", - "integrity": "sha512-+OWZQfAYyio6YkJb3HLxDrvnx6SWWDbC0zVPfBRzUk0/nqoDyf6dNxQi3eArPe8rJ473nobTMQ/8Zk+LxJ+Yuw==", - "license": "MIT" - }, - "node_modules/@types/mime-types": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/@types/mime-types/-/mime-types-2.1.4.tgz", - "integrity": "sha512-lfU4b34HOri+kAY5UheuFMWPDOI+OPceBSHZKp69gEyTL/mmJ4cnU6Y/rlme3UL3GyOn6Y42hyIEw0/q8sWx5w==", - "license": "MIT" - }, - "node_modules/@types/ms": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@types/ms/-/ms-2.1.0.tgz", - "integrity": "sha512-GsCCIZDE/p3i96vtEqx+7dBUGXrc7zeSK3wwPHIaRThS+9OhWIXRqzs4d6k1SVU8g91DrNRWxWUGhp5KXQb2VA==", - "license": "MIT" - }, - "node_modules/@types/nlcst": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@types/nlcst/-/nlcst-2.0.3.tgz", - "integrity": "sha512-vSYNSDe6Ix3q+6Z7ri9lyWqgGhJTmzRjZRqyq15N0Z/1/UnVsno9G/N40NBijoYx2seFDIl0+B2mgAb9mezUCA==", - "license": "MIT", - "dependencies": { - "@types/unist": "*" - } - }, - "node_modules/@types/node": { - "version": "22.10.9", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.9.tgz", - "integrity": "sha512-Ir6hwgsKyNESl/gLOcEz3krR4CBGgliDqBQ2ma4wIhEx0w+xnoeTq3tdrNw15kU3SxogDjOgv9sqdtLW8mIHaw==", - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" - } - }, - "node_modules/@types/pg": { - "version": "8.6.1", - "resolved": "https://registry.npmjs.org/@types/pg/-/pg-8.6.1.tgz", - "integrity": "sha512-1Kc4oAGzAl7uqUStZCDvaLFqZrW9qWSjXOmBfdgyBP5La7Us6Mg4GBvRlSoaZMhQF/zSj1C8CtKMBkoiT8eL8w==", - "license": "MIT", - "optional": true, - "peer": true, - "dependencies": { - "@types/node": "*", - "pg-protocol": "*", - "pg-types": "^2.2.0" - } - }, - "node_modules/@types/react": { - "version": "19.1.4", - "resolved": "https://registry.npmjs.org/@types/react/-/react-19.1.4.tgz", - "integrity": "sha512-EB1yiiYdvySuIITtD5lhW4yPyJ31RkJkkDw794LaQYrxCSaQV/47y5o1FMC4zF9ZyjUjzJMZwbovEnT5yHTW6g==", - "devOptional": true, - "license": "MIT", - "dependencies": { - "csstype": "^3.0.2" - } - }, - "node_modules/@types/sax": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/@types/sax/-/sax-1.2.7.tgz", - "integrity": "sha512-rO73L89PJxeYM3s3pPPjiPgVVcymqU490g0YO5n5By0k2Erzj6tay/4lr1CHAAU4JyOWd1rpQ8bCf6cZfHU96A==", - "license": "MIT", - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@types/seedrandom": { - "version": "3.0.8", - "resolved": "https://registry.npmjs.org/@types/seedrandom/-/seedrandom-3.0.8.tgz", - "integrity": "sha512-TY1eezMU2zH2ozQoAFAQFOPpvP15g+ZgSfTZt31AUUH/Rxtnz3H+A/Sv1Snw2/amp//omibc+AEkTaA8KUeOLQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/@types/tar": { - "version": "6.1.13", - "resolved": "https://registry.npmjs.org/@types/tar/-/tar-6.1.13.tgz", - "integrity": "sha512-IznnlmU5f4WcGTh2ltRu/Ijpmk8wiWXfF0VA4s+HPjHZgvFggk1YaIkbo5krX/zUCzWF8N/l4+W/LNxnvAJ8nw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@types/node": "*", - "minipass": "^4.0.0" - } - }, - "node_modules/@types/unist": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@types/unist/-/unist-3.0.3.tgz", - "integrity": "sha512-ko/gIFJRv177XgZsZcBwnqJN5x/Gien8qNOn0D5bQU/zAzVf9Zt3BlcUiLqhV9y4ARk0GbT3tnUiPNgnTXzc/Q==", - "license": "MIT" - }, - "node_modules/@types/ws": { - "version": "8.5.13", - "resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.5.13.tgz", - "integrity": "sha512-osM/gWBTPKgHV8XkTunnegTRIsvF6owmf5w+JtAfOw472dptdm0dlGv4xCt6GwQRcC2XVOvvRE/0bAoQcL2QkA==", - "license": "MIT", - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@types/yauzl": { - "version": "2.10.3", - "resolved": "https://registry.npmjs.org/@types/yauzl/-/yauzl-2.10.3.tgz", - "integrity": "sha512-oJoftv0LSuaDZE3Le4DbKX+KS9G36NzOeSap90UIK0yMA/NhKJhqlSGtNDORNRaIbQfzjXDrQa0ytJ6mNRGz/Q==", - "dev": true, - "license": "MIT", - "optional": true, - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@typescript-eslint/eslint-plugin": { - "version": "8.32.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.32.1.tgz", - "integrity": "sha512-6u6Plg9nP/J1GRpe/vcjjabo6Uc5YQPAMxsgQyGC/I0RuukiG1wIe3+Vtg3IrSCVJDmqK3j8adrtzXSENRtFgg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@eslint-community/regexpp": "^4.10.0", - "@typescript-eslint/scope-manager": "8.32.1", - "@typescript-eslint/type-utils": "8.32.1", - "@typescript-eslint/utils": "8.32.1", - "@typescript-eslint/visitor-keys": "8.32.1", - "graphemer": "^1.4.0", - "ignore": "^7.0.0", - "natural-compare": "^1.4.0", - "ts-api-utils": "^2.1.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependencies": { - "@typescript-eslint/parser": "^8.0.0 || ^8.0.0-alpha.0", - "eslint": "^8.57.0 || ^9.0.0", - "typescript": ">=4.8.4 <5.9.0" - } - }, - "node_modules/@typescript-eslint/eslint-plugin/node_modules/ignore": { - "version": "7.0.4", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.4.tgz", - "integrity": "sha512-gJzzk+PQNznz8ysRrC0aOkBNVRBDtE1n53IqyqEf3PXrYwomFs5q4pGMizBMJF+ykh03insJ27hB8gSrD2Hn8A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 4" - } - }, - "node_modules/@typescript-eslint/parser": { - "version": "8.32.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.32.1.tgz", - "integrity": "sha512-LKMrmwCPoLhM45Z00O1ulb6jwyVr2kr3XJp+G+tSEZcbauNnScewcQwtJqXDhXeYPDEjZ8C1SjXm015CirEmGg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/scope-manager": "8.32.1", - "@typescript-eslint/types": "8.32.1", - "@typescript-eslint/typescript-estree": "8.32.1", - "@typescript-eslint/visitor-keys": "8.32.1", - "debug": "^4.3.4" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependencies": { - "eslint": "^8.57.0 || ^9.0.0", - "typescript": ">=4.8.4 <5.9.0" - } - }, - "node_modules/@typescript-eslint/scope-manager": { - "version": "8.32.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.32.1.tgz", - "integrity": "sha512-7IsIaIDeZn7kffk7qXC3o6Z4UblZJKV3UBpkvRNpr5NSyLji7tvTcvmnMNYuYLyh26mN8W723xpo3i4MlD33vA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/types": "8.32.1", - "@typescript-eslint/visitor-keys": "8.32.1" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - } - }, - "node_modules/@typescript-eslint/type-utils": { - "version": "8.32.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.32.1.tgz", - "integrity": "sha512-mv9YpQGA8iIsl5KyUPi+FGLm7+bA4fgXaeRcFKRDRwDMu4iwrSHeDPipwueNXhdIIZltwCJv+NkxftECbIZWfA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/typescript-estree": "8.32.1", - "@typescript-eslint/utils": "8.32.1", - "debug": "^4.3.4", - "ts-api-utils": "^2.1.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependencies": { - "eslint": "^8.57.0 || ^9.0.0", - "typescript": ">=4.8.4 <5.9.0" - } - }, - "node_modules/@typescript-eslint/types": { - "version": "8.32.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.32.1.tgz", - "integrity": "sha512-YmybwXUJcgGqgAp6bEsgpPXEg6dcCyPyCSr0CAAueacR/CCBi25G3V8gGQ2kRzQRBNol7VQknxMs9HvVa9Rvfg==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - } - }, - "node_modules/@typescript-eslint/typescript-estree": { - "version": "8.32.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.32.1.tgz", - "integrity": "sha512-Y3AP9EIfYwBb4kWGb+simvPaqQoT5oJuzzj9m0i6FCY6SPvlomY2Ei4UEMm7+FXtlNJbor80ximyslzaQF6xhg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/types": "8.32.1", - "@typescript-eslint/visitor-keys": "8.32.1", - "debug": "^4.3.4", - "fast-glob": "^3.3.2", - "is-glob": "^4.0.3", - "minimatch": "^9.0.4", - "semver": "^7.6.0", - "ts-api-utils": "^2.1.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependencies": { - "typescript": ">=4.8.4 <5.9.0" - } - }, - "node_modules/@typescript-eslint/utils": { - "version": "8.32.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.32.1.tgz", - "integrity": "sha512-DsSFNIgLSrc89gpq1LJB7Hm1YpuhK086DRDJSNrewcGvYloWW1vZLHBTIvarKZDcAORIy/uWNx8Gad+4oMpkSA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@eslint-community/eslint-utils": "^4.7.0", - "@typescript-eslint/scope-manager": "8.32.1", - "@typescript-eslint/types": "8.32.1", - "@typescript-eslint/typescript-estree": "8.32.1" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependencies": { - "eslint": "^8.57.0 || ^9.0.0", - "typescript": ">=4.8.4 <5.9.0" - } - }, - "node_modules/@typescript-eslint/visitor-keys": { - "version": "8.32.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.32.1.tgz", - "integrity": "sha512-ar0tjQfObzhSaW3C3QNmTc5ofj0hDoNQ5XWrCy6zDyabdr0TWhCkClp+rywGNj/odAFBVzzJrK4tEq5M4Hmu4w==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/types": "8.32.1", - "eslint-visitor-keys": "^4.2.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - } - }, - "node_modules/@ungap/structured-clone": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.2.1.tgz", - "integrity": "sha512-fEzPV3hSkSMltkw152tJKNARhOupqbH96MZWyRjNaYZOMIzbrTeQDG+MTc6Mr2pgzFQzFxAfmhGDNP5QK++2ZA==", - "license": "ISC" - }, - "node_modules/@unrs/resolver-binding-darwin-arm64": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-darwin-arm64/-/resolver-binding-darwin-arm64-1.7.2.tgz", - "integrity": "sha512-vxtBno4xvowwNmO/ASL0Y45TpHqmNkAaDtz4Jqb+clmcVSSl8XCG/PNFFkGsXXXS6AMjP+ja/TtNCFFa1QwLRg==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@unrs/resolver-binding-darwin-x64": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-darwin-x64/-/resolver-binding-darwin-x64-1.7.2.tgz", - "integrity": "sha512-qhVa8ozu92C23Hsmv0BF4+5Dyyd5STT1FolV4whNgbY6mj3kA0qsrGPe35zNR3wAN7eFict3s4Rc2dDTPBTuFQ==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@unrs/resolver-binding-freebsd-x64": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-freebsd-x64/-/resolver-binding-freebsd-x64-1.7.2.tgz", - "integrity": "sha512-zKKdm2uMXqLFX6Ac7K5ElnnG5VIXbDlFWzg4WJ8CGUedJryM5A3cTgHuGMw1+P5ziV8CRhnSEgOnurTI4vpHpg==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ] - }, - "node_modules/@unrs/resolver-binding-linux-arm-gnueabihf": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm-gnueabihf/-/resolver-binding-linux-arm-gnueabihf-1.7.2.tgz", - "integrity": "sha512-8N1z1TbPnHH+iDS/42GJ0bMPLiGK+cUqOhNbMKtWJ4oFGzqSJk/zoXFzcQkgtI63qMcUI7wW1tq2usZQSb2jxw==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-arm-musleabihf": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm-musleabihf/-/resolver-binding-linux-arm-musleabihf-1.7.2.tgz", - "integrity": "sha512-tjYzI9LcAXR9MYd9rO45m1s0B/6bJNuZ6jeOxo1pq1K6OBuRMMmfyvJYval3s9FPPGmrldYA3mi4gWDlWuTFGA==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-arm64-gnu": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm64-gnu/-/resolver-binding-linux-arm64-gnu-1.7.2.tgz", - "integrity": "sha512-jon9M7DKRLGZ9VYSkFMflvNqu9hDtOCEnO2QAryFWgT6o6AXU8du56V7YqnaLKr6rAbZBWYsYpikF226v423QA==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-arm64-musl": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm64-musl/-/resolver-binding-linux-arm64-musl-1.7.2.tgz", - "integrity": "sha512-c8Cg4/h+kQ63pL43wBNaVMmOjXI/X62wQmru51qjfTvI7kmCy5uHTJvK/9LrF0G8Jdx8r34d019P1DVJmhXQpA==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-ppc64-gnu": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-ppc64-gnu/-/resolver-binding-linux-ppc64-gnu-1.7.2.tgz", - "integrity": "sha512-A+lcwRFyrjeJmv3JJvhz5NbcCkLQL6Mk16kHTNm6/aGNc4FwPHPE4DR9DwuCvCnVHvF5IAd9U4VIs/VvVir5lg==", - "cpu": [ - "ppc64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-riscv64-gnu": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-riscv64-gnu/-/resolver-binding-linux-riscv64-gnu-1.7.2.tgz", - "integrity": "sha512-hQQ4TJQrSQW8JlPm7tRpXN8OCNP9ez7PajJNjRD1ZTHQAy685OYqPrKjfaMw/8LiHCt8AZ74rfUVHP9vn0N69Q==", - "cpu": [ - "riscv64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-riscv64-musl": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-riscv64-musl/-/resolver-binding-linux-riscv64-musl-1.7.2.tgz", - "integrity": "sha512-NoAGbiqrxtY8kVooZ24i70CjLDlUFI7nDj3I9y54U94p+3kPxwd2L692YsdLa+cqQ0VoqMWoehDFp21PKRUoIQ==", - "cpu": [ - "riscv64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-s390x-gnu": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-s390x-gnu/-/resolver-binding-linux-s390x-gnu-1.7.2.tgz", - "integrity": "sha512-KaZByo8xuQZbUhhreBTW+yUnOIHUsv04P8lKjQ5otiGoSJ17ISGYArc+4vKdLEpGaLbemGzr4ZeUbYQQsLWFjA==", - "cpu": [ - "s390x" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-x64-gnu": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-x64-gnu/-/resolver-binding-linux-x64-gnu-1.7.2.tgz", - "integrity": "sha512-dEidzJDubxxhUCBJ/SHSMJD/9q7JkyfBMT77Px1npl4xpg9t0POLvnWywSk66BgZS/b2Hy9Y1yFaoMTFJUe9yg==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-x64-musl": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-x64-musl/-/resolver-binding-linux-x64-musl-1.7.2.tgz", - "integrity": "sha512-RvP+Ux3wDjmnZDT4XWFfNBRVG0fMsc+yVzNFUqOflnDfZ9OYujv6nkh+GOr+watwrW4wdp6ASfG/e7bkDradsw==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-wasm32-wasi": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-wasm32-wasi/-/resolver-binding-wasm32-wasi-1.7.2.tgz", - "integrity": "sha512-y797JBmO9IsvXVRCKDXOxjyAE4+CcZpla2GSoBQ33TVb3ILXuFnMrbR/QQZoauBYeOFuu4w3ifWLw52sdHGz6g==", - "cpu": [ - "wasm32" - ], - "dev": true, - "license": "MIT", - "optional": true, - "dependencies": { - "@napi-rs/wasm-runtime": "^0.2.9" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@unrs/resolver-binding-win32-arm64-msvc": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-arm64-msvc/-/resolver-binding-win32-arm64-msvc-1.7.2.tgz", - "integrity": "sha512-gtYTh4/VREVSLA+gHrfbWxaMO/00y+34htY7XpioBTy56YN2eBjkPrY1ML1Zys89X3RJDKVaogzwxlM1qU7egg==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@unrs/resolver-binding-win32-ia32-msvc": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-ia32-msvc/-/resolver-binding-win32-ia32-msvc-1.7.2.tgz", - "integrity": "sha512-Ywv20XHvHTDRQs12jd3MY8X5C8KLjDbg/jyaal/QLKx3fAShhJyD4blEANInsjxW3P7isHx1Blt56iUDDJO3jg==", - "cpu": [ - "ia32" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@unrs/resolver-binding-win32-x64-msvc": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-x64-msvc/-/resolver-binding-win32-x64-msvc-1.7.2.tgz", - "integrity": "sha512-friS8NEQfHaDbkThxopGk+LuE5v3iY0StruifjQEt7SLbA46OnfgMO15sOTkbpJkol6RB+1l1TYPXh0sCddpvA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@vercel/og": { - "version": "0.6.8", - "resolved": "https://registry.npmjs.org/@vercel/og/-/og-0.6.8.tgz", - "integrity": "sha512-e4kQK9mP8ntpo3dACWirGod/hHv4qO5JMj9a/0a2AZto7b4persj5YP7t1Er372gTtYFTYxNhMx34jRvHooglw==", - "license": "MPL-2.0", - "dependencies": { - "@resvg/resvg-wasm": "2.4.0", - "satori": "0.12.2", - "yoga-wasm-web": "0.3.3" - }, - "engines": { - "node": ">=16" - } - }, - "node_modules/@volar/kit": { - "version": "2.4.12", - "resolved": "https://registry.npmjs.org/@volar/kit/-/kit-2.4.12.tgz", - "integrity": "sha512-f9JE8oy9C2rBcCWxUYKUF23hOXz4mwgVXFjk7nHhxzplaoVjEOsKpBm8NI2nBH7Cwu8DRxDwBsbIxMl/8wlLxw==", - "license": "MIT", - "dependencies": { - "@volar/language-service": "2.4.12", - "@volar/typescript": "2.4.12", - "typesafe-path": "^0.2.2", - "vscode-languageserver-textdocument": "^1.0.11", - "vscode-uri": "^3.0.8" - }, - "peerDependencies": { - "typescript": "*" - } - }, - "node_modules/@volar/language-core": { - "version": "2.4.12", - "resolved": "https://registry.npmjs.org/@volar/language-core/-/language-core-2.4.12.tgz", - "integrity": "sha512-RLrFdXEaQBWfSnYGVxvR2WrO6Bub0unkdHYIdC31HzIEqATIuuhRRzYu76iGPZ6OtA4Au1SnW0ZwIqPP217YhA==", - "license": "MIT", - "dependencies": { - "@volar/source-map": "2.4.12" - } - }, - "node_modules/@volar/language-server": { - "version": "2.4.12", - "resolved": "https://registry.npmjs.org/@volar/language-server/-/language-server-2.4.12.tgz", - "integrity": "sha512-KC0YqTXCZMaImMWyAKC+dLB2BXjfz80kqesJkV6oXxJsGEQPfmdqug299idwtrT6FVSmZ7q5UrPfvgKwA0S3JA==", - "license": "MIT", - "dependencies": { - "@volar/language-core": "2.4.12", - "@volar/language-service": "2.4.12", - "@volar/typescript": "2.4.12", - "path-browserify": "^1.0.1", - "request-light": "^0.7.0", - "vscode-languageserver": "^9.0.1", - "vscode-languageserver-protocol": "^3.17.5", - "vscode-languageserver-textdocument": "^1.0.11", - "vscode-uri": "^3.0.8" - } - }, - "node_modules/@volar/language-service": { - "version": "2.4.12", - "resolved": "https://registry.npmjs.org/@volar/language-service/-/language-service-2.4.12.tgz", - "integrity": "sha512-nifOPGYYPnCmxja6/ML/Gl2EgFkUdw4gLbYqbh8FjqX3gSpXSZl/0ebqORjKo1KW56YWHWRZd1jFutEtCiRYhA==", - "license": "MIT", - "dependencies": { - "@volar/language-core": "2.4.12", - "vscode-languageserver-protocol": "^3.17.5", - "vscode-languageserver-textdocument": "^1.0.11", - "vscode-uri": "^3.0.8" - } - }, - "node_modules/@volar/source-map": { - "version": "2.4.12", - "resolved": "https://registry.npmjs.org/@volar/source-map/-/source-map-2.4.12.tgz", - "integrity": "sha512-bUFIKvn2U0AWojOaqf63ER0N/iHIBYZPpNGogfLPQ68F5Eet6FnLlyho7BS0y2HJ1jFhSif7AcuTx1TqsCzRzw==", - "license": "MIT" - }, - "node_modules/@volar/typescript": { - "version": "2.4.12", - "resolved": "https://registry.npmjs.org/@volar/typescript/-/typescript-2.4.12.tgz", - "integrity": "sha512-HJB73OTJDgPc80K30wxi3if4fSsZZAOScbj2fcicMuOPoOkcf9NNAINb33o+DzhBdF9xTKC1gnPmIRDous5S0g==", - "license": "MIT", - "dependencies": { - "@volar/language-core": "2.4.12", - "path-browserify": "^1.0.1", - "vscode-uri": "^3.0.8" - } - }, - "node_modules/@vscode/emmet-helper": { - "version": "2.11.0", - "resolved": "https://registry.npmjs.org/@vscode/emmet-helper/-/emmet-helper-2.11.0.tgz", - "integrity": "sha512-QLxjQR3imPZPQltfbWRnHU6JecWTF1QSWhx3GAKQpslx7y3Dp6sIIXhKjiUJ/BR9FX8PVthjr9PD6pNwOJfAzw==", - "license": "MIT", - "dependencies": { - "emmet": "^2.4.3", - "jsonc-parser": "^2.3.0", - "vscode-languageserver-textdocument": "^1.0.1", - "vscode-languageserver-types": "^3.15.1", - "vscode-uri": "^3.0.8" - } - }, - "node_modules/@vscode/l10n": { - "version": "0.0.18", - "resolved": "https://registry.npmjs.org/@vscode/l10n/-/l10n-0.0.18.tgz", - "integrity": "sha512-KYSIHVmslkaCDyw013pphY+d7x1qV8IZupYfeIfzNA+nsaWHbn5uPuQRvdRFsa9zFzGeudPuoGoZ1Op4jrJXIQ==", - "license": "MIT" - }, - "node_modules/acorn": { - "version": "8.14.1", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.14.1.tgz", - "integrity": "sha512-OvQ/2pUDKmgfCg++xsTX1wGxfTaszcHVcTctW4UJB4hibJx2HXxxO5UmVgyjMa+ZDsiaf5wWLXYpRWMmBI0QHg==", - "license": "MIT", - "bin": { - "acorn": "bin/acorn" - }, - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/acorn-jsx": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", - "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", - "license": "MIT", - "peerDependencies": { - "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" - } - }, - "node_modules/ajv": { - "version": "6.12.6", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", - "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/ansi-align": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/ansi-align/-/ansi-align-3.0.1.tgz", - "integrity": "sha512-IOfwwBF5iczOjp/WeY4YxyjqAFMQoZufdQWDd19SEExbVLNXqvpzSJ/M7Za4/sCPmQ0+GRquoA7bGcINcxew6w==", - "license": "ISC", - "dependencies": { - "string-width": "^4.1.0" - } - }, - "node_modules/ansi-align/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/ansi-align/node_modules/emoji-regex": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", - "license": "MIT" - }, - "node_modules/ansi-align/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "license": "MIT", - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/ansi-align/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "license": "MIT", - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/ansi-regex": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.1.0.tgz", - "integrity": "sha512-7HSX4QQb4CspciLpVFwyRe79O3xsIZDDLER21kERQ71oaPodF8jL725AgJMFAYbooIqolJoRLuM81SpeUkpkvA==", - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/chalk/ansi-regex?sponsor=1" - } - }, - "node_modules/ansi-styles": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.1.tgz", - "integrity": "sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==", - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/anymatch": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", - "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", - "license": "ISC", - "dependencies": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/anymatch/node_modules/picomatch": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", - "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", - "license": "MIT", - "engines": { - "node": ">=8.6" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, - "node_modules/arg": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/arg/-/arg-5.0.2.tgz", - "integrity": "sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg==", - "license": "MIT" - }, - "node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "license": "Python-2.0" - }, - "node_modules/aria-query": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/aria-query/-/aria-query-5.3.2.tgz", - "integrity": "sha512-COROpnaoap1E2F000S62r6A60uHZnmlvomhfyT2DlTcrY1OrBKn2UhH7qn5wTC9zMvD0AY7csdPSNwKP+7WiQw==", - "license": "Apache-2.0", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/array-buffer-byte-length": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.2.tgz", - "integrity": "sha512-LHE+8BuR7RYGDKvnrmcuSq3tDcKv9OFEXQt/HpbZhY7V6h0zlUXutnAD82GiFx9rdieCMjkvtcsPqBwgUl1Iiw==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "is-array-buffer": "^3.0.5" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array-includes": { - "version": "3.1.8", - "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.1.8.tgz", - "integrity": "sha512-itaWrbYbqpGXkGhZPGUulwnhVf5Hpy1xiCFsGqyIGglbBxmG5vSjxQen3/WGOjPpNEv1RtBLKxbmVXm8HpJStQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.2", - "es-object-atoms": "^1.0.0", - "get-intrinsic": "^1.2.4", - "is-string": "^1.0.7" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array-iterate": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/array-iterate/-/array-iterate-2.0.1.tgz", - "integrity": "sha512-I1jXZMjAgCMmxT4qxXfPXa6SthSoE8h6gkSI9BGGNv8mP8G/v0blc+qFnZu6K42vTOiuME596QaLO0TP3Lk0xg==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/array.prototype.findlastindex": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/array.prototype.findlastindex/-/array.prototype.findlastindex-1.2.5.tgz", - "integrity": "sha512-zfETvRFA8o7EiNn++N5f/kaCw221hrpGsDmcpndVupkPzEc1Wuf3VgC0qby1BbHs7f5DVYjgtEU2LLh5bqeGfQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.2", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0", - "es-shim-unscopables": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array.prototype.flat": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.3.tgz", - "integrity": "sha512-rwG/ja1neyLqCuGZ5YYrznA62D4mZXg0i1cIskIUKSiqF3Cje9/wXAls9B9s1Wa2fomMsIv8czB8jZcPmxCXFg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.5", - "es-shim-unscopables": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array.prototype.flatmap": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.3.3.tgz", - "integrity": "sha512-Y7Wt51eKJSyi80hFrJCePGGNo5ktJCslFuboqJsbf57CCPcm5zztluPlc4/aD8sWsKvlwatezpV4U1efk8kpjg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.5", - "es-shim-unscopables": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/arraybuffer.prototype.slice": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.4.tgz", - "integrity": "sha512-BNoCY6SXXPQ7gF2opIP4GBE+Xw7U+pHMYKuzjgCN3GwiaIR09UUeKfheyIry77QtrCBlC0KK0q5/TER/tYh3PQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "array-buffer-byte-length": "^1.0.1", - "call-bind": "^1.0.8", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.5", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.6", - "is-array-buffer": "^3.0.4" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/ast-types-flow": { - "version": "0.0.8", - "resolved": "https://registry.npmjs.org/ast-types-flow/-/ast-types-flow-0.0.8.tgz", - "integrity": "sha512-OH/2E5Fg20h2aPrbe+QL8JZQFko0YZaF+j4mnQ7BGhfavO7OpSLa8a0y9sBwomHdSbkhTS8TQNayBfnW5DwbvQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/astring": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/astring/-/astring-1.9.0.tgz", - "integrity": "sha512-LElXdjswlqjWrPpJFg1Fx4wpkOCxj1TDHlSV4PlaRxHGWko024xICaa97ZkMfs6DRKlCguiAI+rbXv5GWwXIkg==", - "license": "MIT", - "bin": { - "astring": "bin/astring" - } - }, - "node_modules/astro": { - "version": "5.7.13", - "resolved": "https://registry.npmjs.org/astro/-/astro-5.7.13.tgz", - "integrity": "sha512-cRGq2llKOhV3XMcYwQpfBIUcssN6HEK5CRbcMxAfd9OcFhvWE7KUy50zLioAZVVl3AqgUTJoNTlmZfD2eG0G1w==", - "license": "MIT", - "dependencies": { - "@astrojs/compiler": "^2.11.0", - "@astrojs/internal-helpers": "0.6.1", - "@astrojs/markdown-remark": "6.3.1", - "@astrojs/telemetry": "3.2.1", - "@capsizecss/unpack": "^2.4.0", - "@oslojs/encoding": "^1.1.0", - "@rollup/pluginutils": "^5.1.4", - "acorn": "^8.14.1", - "aria-query": "^5.3.2", - "axobject-query": "^4.1.0", - "boxen": "8.0.1", - "ci-info": "^4.2.0", - "clsx": "^2.1.1", - "common-ancestor-path": "^1.0.1", - "cookie": "^1.0.2", - "cssesc": "^3.0.0", - "debug": "^4.4.0", - "deterministic-object-hash": "^2.0.2", - "devalue": "^5.1.1", - "diff": "^5.2.0", - "dlv": "^1.1.3", - "dset": "^3.1.4", - "es-module-lexer": "^1.6.0", - "esbuild": "^0.25.0", - "estree-walker": "^3.0.3", - "flattie": "^1.1.1", - "fontace": "~0.3.0", - "github-slugger": "^2.0.0", - "html-escaper": "3.0.3", - "http-cache-semantics": "^4.1.1", - "js-yaml": "^4.1.0", - "kleur": "^4.1.5", - "magic-string": "^0.30.17", - "magicast": "^0.3.5", - "mrmime": "^2.0.1", - "neotraverse": "^0.6.18", - "p-limit": "^6.2.0", - "p-queue": "^8.1.0", - "package-manager-detector": "^1.1.0", - "picomatch": "^4.0.2", - "prompts": "^2.4.2", - "rehype": "^13.0.2", - "semver": "^7.7.1", - "shiki": "^3.2.1", - "tinyexec": "^0.3.2", - "tinyglobby": "^0.2.12", - "tsconfck": "^3.1.5", - "ultrahtml": "^1.6.0", - "unifont": "~0.5.0", - "unist-util-visit": "^5.0.0", - "unstorage": "^1.15.0", - "vfile": "^6.0.3", - "vite": "^6.3.4", - "vitefu": "^1.0.6", - "xxhash-wasm": "^1.1.0", - "yargs-parser": "^21.1.1", - "yocto-spinner": "^0.2.1", - "zod": "^3.24.2", - "zod-to-json-schema": "^3.24.5", - "zod-to-ts": "^1.2.0" - }, - "bin": { - "astro": "astro.js" - }, - "engines": { - "node": "^18.17.1 || ^20.3.0 || >=22.0.0", - "npm": ">=9.6.5", - "pnpm": ">=7.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/astrodotbuild" - }, - "optionalDependencies": { - "sharp": "^0.33.3" - } - }, - "node_modules/astro-eslint-parser": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/astro-eslint-parser/-/astro-eslint-parser-1.2.1.tgz", - "integrity": "sha512-3oqANMjrvJ+IE5pwlUWsH/4UztmYf/GTL0HPUkWnYBNAHiGVGrOh2EbegxS5niAwlO0w9dRYk0CkCPlJcu8c3Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "@astrojs/compiler": "^2.0.0", - "@typescript-eslint/scope-manager": "^7.0.0 || ^8.0.0", - "@typescript-eslint/types": "^7.0.0 || ^8.0.0", - "astrojs-compiler-sync": "^1.0.0", - "debug": "^4.3.4", - "entities": "^6.0.0", - "eslint-scope": "^8.0.1", - "eslint-visitor-keys": "^4.0.0", - "espree": "^10.0.0", - "fast-glob": "^3.3.3", - "is-glob": "^4.0.3", - "semver": "^7.3.8" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://github.com/sponsors/ota-meshi" - } - }, - "node_modules/astro-eslint-parser/node_modules/entities": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.0.tgz", - "integrity": "sha512-aKstq2TDOndCn4diEyp9Uq/Flu2i1GlLkc6XIDQSDMuaFE3OPW5OphLCyQ5SpSJZTb4reN+kTcYru5yIfXoRPw==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.12" - }, - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" - } - }, - "node_modules/astro-icon": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/astro-icon/-/astro-icon-1.1.5.tgz", - "integrity": "sha512-CJYS5nWOw9jz4RpGWmzNQY7D0y2ZZacH7atL2K9DeJXJVaz7/5WrxeyIxO8KASk1jCM96Q4LjRx/F3R+InjJrw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@iconify/tools": "^4.0.5", - "@iconify/types": "^2.0.0", - "@iconify/utils": "^2.1.30" - } - }, - "node_modules/astro-loading-indicator": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/astro-loading-indicator/-/astro-loading-indicator-0.7.0.tgz", - "integrity": "sha512-oNSUYbHq8Aaol0zcVuBzGz+qrqKsviOvKl1xaaKo3DLkEef7HCzHQAgTgWv4lB1iYFWa5GaieQvlxBO4KjzKZg==", - "license": "MIT", - "peerDependencies": { - "astro": "^4.0.0 || ^5.0.0" - } - }, - "node_modules/astro-remote": { - "version": "0.3.4", - "resolved": "https://registry.npmjs.org/astro-remote/-/astro-remote-0.3.4.tgz", - "integrity": "sha512-jL5skNQLA0YBc1R3bVGXyHew3FqGqsT7AgLzWAVeTLzFkwVMUYvs4/lKJSmS7ygcF1GnHnoKG6++8GL9VtWwGQ==", - "license": "MIT", - "dependencies": { - "entities": "^4.5.0", - "marked": "^12.0.0", - "marked-footnote": "^1.2.2", - "marked-smartypants": "^1.1.6", - "ultrahtml": "^1.5.3" - }, - "engines": { - "node": ">=18.14.1" - } - }, - "node_modules/astro-seo-schema": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/astro-seo-schema/-/astro-seo-schema-5.0.0.tgz", - "integrity": "sha512-rbP9BUxvqH4tdgG5VEYDcoAxUhVKv93TdHRQ5zbYUxee1TKAWsNcAG3nqavX83QTTGqU5anvikMcJZXWhGN9wg==", - "license": "MIT", - "peerDependencies": { - "astro": "^5.0.0", - "schema-dts": "^1.1.0" - } - }, - "node_modules/astro/node_modules/package-manager-detector": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/package-manager-detector/-/package-manager-detector-1.1.0.tgz", - "integrity": "sha512-Y8f9qUlBzW8qauJjd/eu6jlpJZsuPJm2ZAV0cDVd420o4EdpH5RPdoCv+60/TdJflGatr4sDfpAL6ArWZbM5tA==", - "license": "MIT" - }, - "node_modules/astrojs-compiler-sync": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/astrojs-compiler-sync/-/astrojs-compiler-sync-1.0.1.tgz", - "integrity": "sha512-EdJILVkc/Iiw9sLMyb2uppp/vG7YL9TgkwaEumNDflI8s0AhR5XuCFkdbA/AcCGvcBfsRH9ngy/iIP8Uybl82g==", - "dev": true, - "license": "MIT", - "dependencies": { - "synckit": "^0.9.0" - }, - "engines": { - "node": "^18.18.0 || >=20.9.0" - }, - "funding": { - "url": "https://github.com/sponsors/ota-meshi" - }, - "peerDependencies": { - "@astrojs/compiler": ">=0.27.0" - } - }, - "node_modules/async-function": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/async-function/-/async-function-1.0.0.tgz", - "integrity": "sha512-hsU18Ae8CDTR6Kgu9DYf0EbCr/a5iGL0rytQDobUcdpYOKokk8LEjVphnXkDkgpi0wYVsqrXuP0bZxJaTqdgoA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/async-listen": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/async-listen/-/async-listen-3.1.0.tgz", - "integrity": "sha512-TkOhqze98lP+6e7SPbrBpyhTpfvqqX8VYKGn4uckrgPan4WQIHnTaUD2zZzZS18eVVDj4rHPcIZa1PGgvo1DfA==", - "license": "MIT", - "engines": { - "node": ">= 14" - } - }, - "node_modules/asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/available-typed-arrays": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.7.tgz", - "integrity": "sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "possible-typed-array-names": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/axe-core": { - "version": "4.10.2", - "resolved": "https://registry.npmjs.org/axe-core/-/axe-core-4.10.2.tgz", - "integrity": "sha512-RE3mdQ7P3FRSe7eqCWoeQ/Z9QXrtniSjp1wUjt5nRC3WIpz5rSCve6o3fsZ2aCpJtrZjSZgjwXAoTO5k4tEI0w==", - "dev": true, - "license": "MPL-2.0", - "engines": { - "node": ">=4" - } - }, - "node_modules/axios": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.9.0.tgz", - "integrity": "sha512-re4CqKTJaURpzbLHtIi6XpDv20/CnpXOtjRY5/CU32L8gU8ek9UIivcfvSWvmKEngmVbrUtPpdDwWDWL7DNHvg==", - "dev": true, - "license": "MIT", - "dependencies": { - "follow-redirects": "^1.15.6", - "form-data": "^4.0.0", - "proxy-from-env": "^1.1.0" - } - }, - "node_modules/axobject-query": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/axobject-query/-/axobject-query-4.1.0.tgz", - "integrity": "sha512-qIj0G9wZbMGNLjLmg1PT6v2mE9AH2zlnADJD/2tC6E00hgmhUOfEB6greHPAfLRSufHqROIUTkw6E+M3lH0PTQ==", - "license": "Apache-2.0", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/bail": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/bail/-/bail-2.0.2.tgz", - "integrity": "sha512-0xO6mYd7JB2YesxDKplafRpsiOzPt9V02ddPCLbY1xYGPOX24NTyN50qnUxgCPcSoYMhKpAuBTjQoRZCAkUDRw==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true, - "license": "MIT" - }, - "node_modules/base-64": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/base-64/-/base-64-1.0.0.tgz", - "integrity": "sha512-kwDPIFCGx0NZHog36dj+tHiwP4QMzsZ3AgMViUBKI0+V5n4U0ufTCUMhnQ04diaRI8EX/QcPfql7zlhZ7j4zgg==", - "license": "MIT" - }, - "node_modules/base64-js": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", - "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" - }, - "node_modules/bl": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", - "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", - "license": "MIT", - "dependencies": { - "buffer": "^5.5.0", - "inherits": "^2.0.4", - "readable-stream": "^3.4.0" - } - }, - "node_modules/blob-to-buffer": { - "version": "1.2.9", - "resolved": "https://registry.npmjs.org/blob-to-buffer/-/blob-to-buffer-1.2.9.tgz", - "integrity": "sha512-BF033y5fN6OCofD3vgHmNtwZWRcq9NLyyxyILx9hfMy1sXYy4ojFl765hJ2lP0YaN2fuxPaLO2Vzzoxy0FLFFA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" - }, - "node_modules/boolbase": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", - "integrity": "sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==", - "dev": true, - "license": "ISC" - }, - "node_modules/boxen": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/boxen/-/boxen-8.0.1.tgz", - "integrity": "sha512-F3PH5k5juxom4xktynS7MoFY+NUWH5LC4CnH11YB8NPew+HLpmBLCybSAEyb2F+4pRXhuhWqFesoQd6DAyc2hw==", - "license": "MIT", - "dependencies": { - "ansi-align": "^3.0.1", - "camelcase": "^8.0.0", - "chalk": "^5.3.0", - "cli-boxes": "^3.0.0", - "string-width": "^7.2.0", - "type-fest": "^4.21.0", - "widest-line": "^5.0.0", - "wrap-ansi": "^9.0.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/brace-expansion": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", - "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/braces": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", - "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", - "license": "MIT", - "dependencies": { - "fill-range": "^7.1.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/brotli": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/brotli/-/brotli-1.3.3.tgz", - "integrity": "sha512-oTKjJdShmDuGW94SyyaoQvAjf30dZaHnjJ8uAF+u2/vGJkJbJPJAT1gDiOJP5v1Zb6f9KEyW/1HpuaWIXtGHPg==", - "license": "MIT", - "dependencies": { - "base64-js": "^1.1.2" - } - }, - "node_modules/buffer": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", - "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT", - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.1.13" - } - }, - "node_modules/buffer-crc32": { - "version": "0.2.13", - "resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz", - "integrity": "sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": "*" - } - }, - "node_modules/bundle-name": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/bundle-name/-/bundle-name-4.1.0.tgz", - "integrity": "sha512-tjwM5exMg6BGRI+kNmTntNsvdZS1X8BFYS6tnJ2hdH0kVxM6/eVZ2xy+FqStSWvYmtfFMDLIxurorHwDKfDz5Q==", - "license": "MIT", - "dependencies": { - "run-applescript": "^7.0.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/call-bind": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.8.tgz", - "integrity": "sha512-oKlSFMcMwpUg2ednkhQ454wfWiU/ul3CkJe/PEHcTKuiX6RpbehUiFMXu13HalGZxfUwCQzZG747YXBn1im9ww==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.0", - "es-define-property": "^1.0.0", - "get-intrinsic": "^1.2.4", - "set-function-length": "^1.2.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/call-bind-apply-helpers": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.1.tgz", - "integrity": "sha512-BhYE+WDaywFg2TBWYNXAE+8B1ATnThNBqXHP5nQu0jWJdVvY2hvkpyB3qOmtmDePiS5/BDQ8wASEWGMWRG148g==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "function-bind": "^1.1.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/call-bound": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.3.tgz", - "integrity": "sha512-YTd+6wGlNlPxSuri7Y6X8tY2dmm12UMH66RpKMhiX6rsk5wXXnYgbUcOt8kiS31/AjfoTOvCsE+w8nZQLQnzHA==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.1", - "get-intrinsic": "^1.2.6" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/callsites": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", - "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/camelcase": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-8.0.0.tgz", - "integrity": "sha512-8WB3Jcas3swSvjIeA2yvCJ+Miyz5l1ZmB6HFb9R1317dt9LCQoswg/BGrmAmkWVEszSrrg4RwmO46qIm2OEnSA==", - "license": "MIT", - "engines": { - "node": ">=16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/camelize": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/camelize/-/camelize-1.0.1.tgz", - "integrity": "sha512-dU+Tx2fsypxTgtLoE36npi3UqcjSSMNYfkqgmoEhtZrraP5VWq0K7FkWVTYa8eMPtnU/G2txVsfdCJTn9uzpuQ==", - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/canvas": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/canvas/-/canvas-3.1.0.tgz", - "integrity": "sha512-tTj3CqqukVJ9NgSahykNwtGda7V33VLObwrHfzT0vqJXu7J4d4C/7kQQW3fOEGDfZZoILPut5H00gOjyttPGyg==", - "hasInstallScript": true, - "license": "MIT", - "dependencies": { - "node-addon-api": "^7.0.0", - "prebuild-install": "^7.1.1" - }, - "engines": { - "node": "^18.12.0 || >= 20.9.0" - } - }, - "node_modules/ccount": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/ccount/-/ccount-2.0.1.tgz", - "integrity": "sha512-eyrF0jiFpY+3drT6383f1qhkbGsLSifNAjA61IUjZjmLCWjItY6LB9ft9YhoDgwfmclB2zhu51Lc7+95b8NRAg==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/chalk": { - "version": "5.4.1", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.4.1.tgz", - "integrity": "sha512-zgVZuo2WcZgfUEmsn6eO3kINexW8RAE4maiQ8QNs8CtpPCSyMiYsULR3HQYkm3w8FIA3SberyMJMSldGsW+U3w==", - "license": "MIT", - "engines": { - "node": "^12.17.0 || ^14.13 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/character-entities": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/character-entities/-/character-entities-2.0.2.tgz", - "integrity": "sha512-shx7oQ0Awen/BRIdkjkvz54PnEEI/EjwXDSIZp86/KKdbafHh1Df/RYGBhn4hbe2+uKC9FnT5UCEdyPz3ai9hQ==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/character-entities-html4": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/character-entities-html4/-/character-entities-html4-2.1.0.tgz", - "integrity": "sha512-1v7fgQRj6hnSwFpq1Eu0ynr/CDEw0rXo2B61qXrLNdHZmPKgb7fqS1a2JwF0rISo9q77jDI8VMEHoApn8qDoZA==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/character-entities-legacy": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/character-entities-legacy/-/character-entities-legacy-3.0.0.tgz", - "integrity": "sha512-RpPp0asT/6ufRm//AJVwpViZbGM/MkjQFxJccQRHmISF/22NBtsHqAWmL+/pmkPWoIUJdWyeVleTl1wydHATVQ==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/character-reference-invalid": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/character-reference-invalid/-/character-reference-invalid-2.0.1.tgz", - "integrity": "sha512-iBZ4F4wRbyORVsu0jPV7gXkOsGYjGHPmAyv+HiHG8gi5PtC9KI2j1+v8/tlibRvjoWX027ypmG/n0HtO5t7unw==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/cheerio": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0.tgz", - "integrity": "sha512-quS9HgjQpdaXOvsZz82Oz7uxtXiy6UIsIQcpBj7HRw2M63Skasm9qlDocAM7jNuaxdhpPU7c4kJN+gA5MCu4ww==", - "dev": true, - "license": "MIT", - "dependencies": { - "cheerio-select": "^2.1.0", - "dom-serializer": "^2.0.0", - "domhandler": "^5.0.3", - "domutils": "^3.1.0", - "encoding-sniffer": "^0.2.0", - "htmlparser2": "^9.1.0", - "parse5": "^7.1.2", - "parse5-htmlparser2-tree-adapter": "^7.0.0", - "parse5-parser-stream": "^7.1.2", - "undici": "^6.19.5", - "whatwg-mimetype": "^4.0.0" - }, - "engines": { - "node": ">=18.17" - }, - "funding": { - "url": "https://github.com/cheeriojs/cheerio?sponsor=1" - } - }, - "node_modules/cheerio-select": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/cheerio-select/-/cheerio-select-2.1.0.tgz", - "integrity": "sha512-9v9kG0LvzrlcungtnJtpGNxY+fzECQKhK4EGJX2vByejiMX84MFNQw4UxPJl3bFbTMw+Dfs37XaIkCwTZfLh4g==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "boolbase": "^1.0.0", - "css-select": "^5.1.0", - "css-what": "^6.1.0", - "domelementtype": "^2.3.0", - "domhandler": "^5.0.3", - "domutils": "^3.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" - } - }, - "node_modules/chokidar": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-4.0.3.tgz", - "integrity": "sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==", - "license": "MIT", - "dependencies": { - "readdirp": "^4.0.1" - }, - "engines": { - "node": ">= 14.16.0" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/chownr": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", - "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=10" - } - }, - "node_modules/ci-info": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.2.0.tgz", - "integrity": "sha512-cYY9mypksY8NRqgDB1XD1RiJL338v/551niynFTGkZOO2LHuB2OmOYxDIe/ttN9AHwrqdum1360G3ald0W9kCg==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/sibiraj-s" - } - ], - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/cli-boxes": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/cli-boxes/-/cli-boxes-3.0.0.tgz", - "integrity": "sha512-/lzGpEWL/8PfI0BmBOPRwp0c/wFNX1RdUML3jK/RcSBA9T8mZDdQpqYBKtCFTOfQbwPqWEOpjqW+Fnayc0969g==", - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/cliui": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", - "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", - "license": "ISC", - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.1", - "wrap-ansi": "^7.0.0" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/cliui/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/cliui/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/cliui/node_modules/emoji-regex": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", - "license": "MIT" - }, - "node_modules/cliui/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "license": "MIT", - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cliui/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "license": "MIT", - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cliui/node_modules/wrap-ansi": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, - "node_modules/clone": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/clone/-/clone-2.1.2.tgz", - "integrity": "sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==", - "license": "MIT", - "engines": { - "node": ">=0.8" - } - }, - "node_modules/clsx": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/clsx/-/clsx-2.1.1.tgz", - "integrity": "sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/cluster-key-slot": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/cluster-key-slot/-/cluster-key-slot-1.1.2.tgz", - "integrity": "sha512-RMr0FhtfXemyinomL4hrWcYJxmX6deFdCxpJzhDttxgO1+bcCnkk+9drydLVDmAMG7NE6aN/fl4F7ucU/90gAA==", - "license": "Apache-2.0", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/collapse-white-space": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/collapse-white-space/-/collapse-white-space-2.1.0.tgz", - "integrity": "sha512-loKTxY1zCOuG4j9f6EPnuyyYkf58RnhhWTvRoZEokgB+WbdXehfjFviyOVYkqzEWz1Q5kRiZdBYS5SwxbQYwzw==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/color": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/color/-/color-4.2.3.tgz", - "integrity": "sha512-1rXeuUUiGGrykh+CeBdu5Ie7OJwinCgQY0bc7GCRxy5xVHy+moaqkpL/jqQq0MtQOeYcrqEz4abc5f0KtU7W4A==", - "license": "MIT", - "optional": true, - "dependencies": { - "color-convert": "^2.0.1", - "color-string": "^1.9.0" - }, - "engines": { - "node": ">=12.5.0" - } - }, - "node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT" - }, - "node_modules/color-string": { - "version": "1.9.1", - "resolved": "https://registry.npmjs.org/color-string/-/color-string-1.9.1.tgz", - "integrity": "sha512-shrVawQFojnZv6xM40anx4CkoDP+fZsw/ZerEMsW/pyzsRbElpsL/DBVW7q3ExxwusdNXI3lXpuhEZkzs8p5Eg==", - "license": "MIT", - "optional": true, - "dependencies": { - "color-name": "^1.0.0", - "simple-swizzle": "^0.2.2" - } - }, - "node_modules/combined-stream": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "dev": true, - "license": "MIT", - "dependencies": { - "delayed-stream": "~1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/comma-separated-tokens": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/comma-separated-tokens/-/comma-separated-tokens-2.0.3.tgz", - "integrity": "sha512-Fu4hJdvzeylCfQPp9SGWidpzrMs7tTrlu6Vb8XGaRGck8QSNZJJp538Wrb60Lax4fPwR64ViY468OIUTbRlGZg==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/common-ancestor-path": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/common-ancestor-path/-/common-ancestor-path-1.0.1.tgz", - "integrity": "sha512-L3sHRo1pXXEqX8VU28kfgUY+YGsk09hPqZiZmLacNib6XNTCM8ubYeT7ryXQw8asB1sKgcU5lkB7ONug08aB8w==", - "license": "ISC" - }, - "node_modules/concat-map": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", - "dev": true, - "license": "MIT" - }, - "node_modules/confbox": { - "version": "0.1.8", - "resolved": "https://registry.npmjs.org/confbox/-/confbox-0.1.8.tgz", - "integrity": "sha512-RMtmw0iFkeR4YV+fUOSucriAQNb9g8zFR52MWCtl+cCZOFRNL6zeB395vPzFhEjjn4fMxXudmELnl/KF/WrK6w==", - "dev": true, - "license": "MIT" - }, - "node_modules/cookie": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-1.0.2.tgz", - "integrity": "sha512-9Kr/j4O16ISv8zBBhJoi4bXOYNTkFLOqSL3UDB0njXxCXNezjeyVrJyGOWtgfs/q2km1gwBcfH8q1yEGoMYunA==", - "license": "MIT", - "engines": { - "node": ">=18" - } - }, - "node_modules/cookie-es": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/cookie-es/-/cookie-es-1.2.2.tgz", - "integrity": "sha512-+W7VmiVINB+ywl1HGXJXmrqkOhpKrIiVZV6tQuV54ZyQC7MMuBt81Vc336GMLoHBq5hV/F9eXgt5Mnx0Rha5Fg==", - "license": "MIT" - }, - "node_modules/cross-fetch": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-3.2.0.tgz", - "integrity": "sha512-Q+xVJLoGOeIMXZmbUK4HYk+69cQH6LudR0Vu/pRm2YlU/hDV9CiS0gKUMaWY5f2NeUH9C1nV3bsTlCo0FsTV1Q==", - "license": "MIT", - "dependencies": { - "node-fetch": "^2.7.0" - } - }, - "node_modules/cross-fetch/node_modules/node-fetch": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", - "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", - "license": "MIT", - "dependencies": { - "whatwg-url": "^5.0.0" - }, - "engines": { - "node": "4.x || >=6.0.0" - }, - "peerDependencies": { - "encoding": "^0.1.0" - }, - "peerDependenciesMeta": { - "encoding": { - "optional": true - } - } - }, - "node_modules/cross-spawn": { - "version": "7.0.6", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", - "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", - "dev": true, - "license": "MIT", - "dependencies": { - "path-key": "^3.1.0", - "shebang-command": "^2.0.0", - "which": "^2.0.1" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/crossws": { - "version": "0.3.4", - "resolved": "https://registry.npmjs.org/crossws/-/crossws-0.3.4.tgz", - "integrity": "sha512-uj0O1ETYX1Bh6uSgktfPvwDiPYGQ3aI4qVsaC/LWpkIzGj1nUYm5FK3K+t11oOlpN01lGbprFCH4wBlKdJjVgw==", - "license": "MIT", - "dependencies": { - "uncrypto": "^0.1.3" - } - }, - "node_modules/css-background-parser": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/css-background-parser/-/css-background-parser-0.1.0.tgz", - "integrity": "sha512-2EZLisiZQ+7m4wwur/qiYJRniHX4K5Tc9w93MT3AS0WS1u5kaZ4FKXlOTBhOjc+CgEgPiGY+fX1yWD8UwpEqUA==", - "license": "MIT" - }, - "node_modules/css-box-shadow": { - "version": "1.0.0-3", - "resolved": "https://registry.npmjs.org/css-box-shadow/-/css-box-shadow-1.0.0-3.tgz", - "integrity": "sha512-9jaqR6e7Ohds+aWwmhe6wILJ99xYQbfmK9QQB9CcMjDbTxPZjwEmUQpU91OG05Xgm8BahT5fW+svbsQGjS/zPg==", - "license": "MIT" - }, - "node_modules/css-color-keywords": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/css-color-keywords/-/css-color-keywords-1.0.0.tgz", - "integrity": "sha512-FyyrDHZKEjXDpNJYvVsV960FiqQyXc/LlYmsxl2BcdMb2WPx0OGRVgTg55rPSyLSNMqP52R9r8geSp7apN3Ofg==", - "license": "ISC", - "engines": { - "node": ">=4" - } - }, - "node_modules/css-gradient-parser": { - "version": "0.0.16", - "resolved": "https://registry.npmjs.org/css-gradient-parser/-/css-gradient-parser-0.0.16.tgz", - "integrity": "sha512-3O5QdqgFRUbXvK1x5INf1YkBz1UKSWqrd63vWsum8MNHDBYD5urm3QtxZbKU259OrEXNM26lP/MPY3d1IGkBgA==", - "license": "MIT", - "engines": { - "node": ">=16" - } - }, - "node_modules/css-select": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/css-select/-/css-select-5.1.0.tgz", - "integrity": "sha512-nwoRF1rvRRnnCqqY7updORDsuqKzqYJ28+oSMaJMMgOauh3fvwHqMS7EZpIPqK8GL+g9mKxF1vP/ZjSeNjEVHg==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "boolbase": "^1.0.0", - "css-what": "^6.1.0", - "domhandler": "^5.0.2", - "domutils": "^3.0.1", - "nth-check": "^2.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" - } - }, - "node_modules/css-to-react-native": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/css-to-react-native/-/css-to-react-native-3.2.0.tgz", - "integrity": "sha512-e8RKaLXMOFii+02mOlqwjbD00KSEKqblnpO9e++1aXS1fPQOpS1YoqdVHBqPjHNoxeF2mimzVqawm2KCbEdtHQ==", - "license": "MIT", - "dependencies": { - "camelize": "^1.0.0", - "css-color-keywords": "^1.0.0", - "postcss-value-parser": "^4.0.2" - } - }, - "node_modules/css-tree": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.3.1.tgz", - "integrity": "sha512-6Fv1DV/TYw//QF5IzQdqsNDjx/wc8TrMBZsqjL9eW01tWb7R7k/mq+/VXfJCl7SoD5emsJop9cOByJZfs8hYIw==", - "dev": true, - "license": "MIT", - "dependencies": { - "mdn-data": "2.0.30", - "source-map-js": "^1.0.1" - }, - "engines": { - "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0" - } - }, - "node_modules/css-what": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/css-what/-/css-what-6.1.0.tgz", - "integrity": "sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">= 6" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" - } - }, - "node_modules/cssesc": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz", - "integrity": "sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==", - "license": "MIT", - "bin": { - "cssesc": "bin/cssesc" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/csso": { - "version": "5.0.5", - "resolved": "https://registry.npmjs.org/csso/-/csso-5.0.5.tgz", - "integrity": "sha512-0LrrStPOdJj+SPCCrGhzryycLjwcgUSHBtxNA8aIDxf0GLsRh1cKYhB00Gd1lDOS4yGH69+SNn13+TWbVHETFQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "css-tree": "~2.2.0" - }, - "engines": { - "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0", - "npm": ">=7.0.0" - } - }, - "node_modules/csso/node_modules/css-tree": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.2.1.tgz", - "integrity": "sha512-OA0mILzGc1kCOCSJerOeqDxDQ4HOh+G8NbOJFOTgOCzpw7fCBubk0fEyxp8AgOL/jvLgYA/uV0cMbe43ElF1JA==", - "dev": true, - "license": "MIT", - "dependencies": { - "mdn-data": "2.0.28", - "source-map-js": "^1.0.1" - }, - "engines": { - "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0", - "npm": ">=7.0.0" - } - }, - "node_modules/csso/node_modules/mdn-data": { - "version": "2.0.28", - "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.28.tgz", - "integrity": "sha512-aylIc7Z9y4yzHYAJNuESG3hfhC+0Ibp/MAMiaOZgNv4pmEdFyfZhhhny4MNiAfWdBQ1RQ2mfDWmM1x8SvGyp8g==", - "dev": true, - "license": "CC0-1.0" - }, - "node_modules/csstype": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz", - "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==", - "devOptional": true, - "license": "MIT" - }, - "node_modules/damerau-levenshtein": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/damerau-levenshtein/-/damerau-levenshtein-1.0.8.tgz", - "integrity": "sha512-sdQSFB7+llfUcQHUQO3+B8ERRj0Oa4w9POWMI/puGtuf7gFywGmkaLCElnudfTiKZV+NvHqL0ifzdrI8Ro7ESA==", - "dev": true, - "license": "BSD-2-Clause" - }, - "node_modules/data-uri-to-buffer": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/data-uri-to-buffer/-/data-uri-to-buffer-4.0.1.tgz", - "integrity": "sha512-0R9ikRb668HB7QDxT1vkpuUBtqc53YyAwMwGeUFKRojY/NWKvdZ+9UYtRfGmhqNbRkTSVpMbmyhXipFFv2cb/A==", - "license": "MIT", - "engines": { - "node": ">= 12" - } - }, - "node_modules/data-view-buffer": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/data-view-buffer/-/data-view-buffer-1.0.2.tgz", - "integrity": "sha512-EmKO5V3OLXh1rtK2wgXRansaK1/mtVdTUEiEI0W8RkvgT05kfxaH29PliLnpLP73yYO6142Q72QNa8Wx/A5CqQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "es-errors": "^1.3.0", - "is-data-view": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/data-view-byte-length": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/data-view-byte-length/-/data-view-byte-length-1.0.2.tgz", - "integrity": "sha512-tuhGbE6CfTM9+5ANGf+oQb72Ky/0+s3xKUpHvShfiz2RxMFgFPjsXuRLBVMtvMs15awe45SRb83D6wH4ew6wlQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "es-errors": "^1.3.0", - "is-data-view": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/inspect-js" - } - }, - "node_modules/data-view-byte-offset": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/data-view-byte-offset/-/data-view-byte-offset-1.0.1.tgz", - "integrity": "sha512-BS8PfmtDGnrgYdOonGZQdLZslWIeCGFP9tpan0hi1Co2Zr2NKADsvGYA8XxuG/4UWgJ6Cjtv+YJnB6MM69QGlQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "es-errors": "^1.3.0", - "is-data-view": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/date-fns": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-4.1.0.tgz", - "integrity": "sha512-Ukq0owbQXxa/U3EGtsdVBkR1w7KOQ5gIBqdH2hkvknzZPYvBxb/aa6E8L7tmjFtkwZBu3UXBbjIgPo/Ez4xaNg==", - "dev": true, - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/kossnocorp" - } - }, - "node_modules/debug": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.0.tgz", - "integrity": "sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA==", - "license": "MIT", - "dependencies": { - "ms": "^2.1.3" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, - "node_modules/decode-named-character-reference": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/decode-named-character-reference/-/decode-named-character-reference-1.1.0.tgz", - "integrity": "sha512-Wy+JTSbFThEOXQIR2L6mxJvEs+veIzpmqD7ynWxMXGpnk3smkHQOp6forLdHsKpAMW9iJpaBBIxz285t1n1C3w==", - "license": "MIT", - "dependencies": { - "character-entities": "^2.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/decompress-response": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", - "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", - "license": "MIT", - "dependencies": { - "mimic-response": "^3.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/deep-diff": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/deep-diff/-/deep-diff-1.0.2.tgz", - "integrity": "sha512-aWS3UIVH+NPGCD1kki+DCU9Dua032iSsO43LqQpcs4R3+dVv7tX0qBGjiVHJHjplsoUM2XRO/KB92glqc68awg==", - "license": "MIT" - }, - "node_modules/deep-extend": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", - "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", - "license": "MIT", - "engines": { - "node": ">=4.0.0" - } - }, - "node_modules/deep-is": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", - "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/default-browser": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/default-browser/-/default-browser-5.2.1.tgz", - "integrity": "sha512-WY/3TUME0x3KPYdRRxEJJvXRHV4PyPoUsxtZa78lwItwRQRHhd2U9xOscaT/YTf8uCXIAjeJOFBVEh/7FtD8Xg==", - "license": "MIT", - "dependencies": { - "bundle-name": "^4.1.0", - "default-browser-id": "^5.0.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/default-browser-id": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/default-browser-id/-/default-browser-id-5.0.0.tgz", - "integrity": "sha512-A6p/pu/6fyBcA1TRz/GqWYPViplrftcW2gZC9q79ngNCKAeR/X3gcEdXQHl4KNXV+3wgIJ1CPkJQ3IHM6lcsyA==", - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/define-data-property": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", - "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "gopd": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/define-lazy-prop": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/define-lazy-prop/-/define-lazy-prop-3.0.0.tgz", - "integrity": "sha512-N+MeXYoqr3pOgn8xfyRPREN7gHakLYjhsHhWGT3fWAiL4IkAt0iDw14QiiEm2bE30c5XX5q0FtAA3CK5f9/BUg==", - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/define-properties": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", - "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", - "dev": true, - "license": "MIT", - "dependencies": { - "define-data-property": "^1.0.1", - "has-property-descriptors": "^1.0.0", - "object-keys": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/defu": { - "version": "6.1.4", - "resolved": "https://registry.npmjs.org/defu/-/defu-6.1.4.tgz", - "integrity": "sha512-mEQCMmwJu317oSz8CwdIOdwf3xMif1ttiM8LTufzc3g6kR+9Pe236twL8j3IYT1F7GfRgGcW6MWxzZjLIkuHIg==", - "license": "MIT" - }, - "node_modules/delayed-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/depd": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", - "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/dequal": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/dequal/-/dequal-2.0.3.tgz", - "integrity": "sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/destr": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/destr/-/destr-2.0.3.tgz", - "integrity": "sha512-2N3BOUU4gYMpTP24s5rF5iP7BDr7uNTCs4ozw3kf/eKfvWSIu93GEBi5m427YoyJoeOzQ5smuu4nNAPGb8idSQ==", - "license": "MIT" - }, - "node_modules/detect-libc": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.4.tgz", - "integrity": "sha512-3UDv+G9CsCKO1WKMGw9fwq/SWJYbI0c5Y7LU1AXYoDdbhE2AHQ6N6Nb34sG8Fj7T5APy8qXDCKuuIHd1BR0tVA==", - "license": "Apache-2.0", - "engines": { - "node": ">=8" - } - }, - "node_modules/deterministic-object-hash": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/deterministic-object-hash/-/deterministic-object-hash-2.0.2.tgz", - "integrity": "sha512-KxektNH63SrbfUyDiwXqRb1rLwKt33AmMv+5Nhsw1kqZ13SJBRTgZHtGbE+hH3a1mVW1cz+4pqSWVPAtLVXTzQ==", - "license": "MIT", - "dependencies": { - "base-64": "^1.0.0" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/devalue": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/devalue/-/devalue-5.1.1.tgz", - "integrity": "sha512-maua5KUiapvEwiEAe+XnlZ3Rh0GD+qI1J/nb9vrJc3muPXvcF/8gXYTWF76+5DAqHyDUtOIImEuo0YKE9mshVw==", - "license": "MIT" - }, - "node_modules/devlop": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/devlop/-/devlop-1.1.0.tgz", - "integrity": "sha512-RWmIqhcFf1lRYBvNmr7qTNuyCt/7/ns2jbpp1+PalgE/rDQcBT0fioSMUpJ93irlUhC5hrg4cYqe6U+0ImW0rA==", - "license": "MIT", - "dependencies": { - "dequal": "^2.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/dfa": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/dfa/-/dfa-1.2.0.tgz", - "integrity": "sha512-ED3jP8saaweFTjeGX8HQPjeC1YYyZs98jGNZx6IiBvxW7JG5v492kamAQB3m2wop07CvU/RQmzcKr6bgcC5D/Q==", - "license": "MIT" - }, - "node_modules/diff": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-5.2.0.tgz", - "integrity": "sha512-uIFDxqpRZGZ6ThOk84hEfqWoHx2devRFvpTZcTHur85vImfaxUbTW9Ryh4CpCuDnToOP1CEtXKIgytHBPVff5A==", - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.3.1" - } - }, - "node_modules/dlv": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/dlv/-/dlv-1.1.3.tgz", - "integrity": "sha512-+HlytyjlPKnIG8XuRG8WvmBP8xs8P71y+SKKS6ZXWoEgLuePxtDoUEiH7WkdePWrQ5JBpE6aoVqfZfJUQkjXwA==", - "license": "MIT" - }, - "node_modules/doctrine": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", - "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "esutils": "^2.0.2" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/dom-serializer": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-2.0.0.tgz", - "integrity": "sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg==", - "dev": true, - "license": "MIT", - "dependencies": { - "domelementtype": "^2.3.0", - "domhandler": "^5.0.2", - "entities": "^4.2.0" - }, - "funding": { - "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" - } - }, - "node_modules/domelementtype": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz", - "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/fb55" - } - ], - "license": "BSD-2-Clause" - }, - "node_modules/domhandler": { - "version": "5.0.3", - "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-5.0.3.tgz", - "integrity": "sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "domelementtype": "^2.3.0" - }, - "engines": { - "node": ">= 4" - }, - "funding": { - "url": "https://github.com/fb55/domhandler?sponsor=1" - } - }, - "node_modules/domutils": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-3.2.2.tgz", - "integrity": "sha512-6kZKyUajlDuqlHKVX1w7gyslj9MPIXzIFiz/rGu35uC1wMi+kMhQwGhl4lt9unC9Vb9INnY9Z3/ZA3+FhASLaw==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "dom-serializer": "^2.0.0", - "domelementtype": "^2.3.0", - "domhandler": "^5.0.3" - }, - "funding": { - "url": "https://github.com/fb55/domutils?sponsor=1" - } - }, - "node_modules/drizzle-orm": { - "version": "0.31.4", - "resolved": "https://registry.npmjs.org/drizzle-orm/-/drizzle-orm-0.31.4.tgz", - "integrity": "sha512-VGD9SH9aStF2z4QOTnVlVX/WghV/EnuEzTmsH3fSVp2E4fFgc8jl3viQrS/XUJx1ekW4rVVLJMH42SfGQdjX3Q==", - "license": "Apache-2.0", - "peerDependencies": { - "@aws-sdk/client-rds-data": ">=3", - "@cloudflare/workers-types": ">=3", - "@electric-sql/pglite": ">=0.1.1", - "@libsql/client": "*", - "@neondatabase/serverless": ">=0.1", - "@op-engineering/op-sqlite": ">=2", - "@opentelemetry/api": "^1.4.1", - "@planetscale/database": ">=1", - "@prisma/client": "*", - "@tidbcloud/serverless": "*", - "@types/better-sqlite3": "*", - "@types/pg": "*", - "@types/react": ">=18", - "@types/sql.js": "*", - "@vercel/postgres": ">=0.8.0", - "@xata.io/client": "*", - "better-sqlite3": ">=7", - "bun-types": "*", - "expo-sqlite": ">=13.2.0", - "knex": "*", - "kysely": "*", - "mysql2": ">=2", - "pg": ">=8", - "postgres": ">=3", - "react": ">=18", - "sql.js": ">=1", - "sqlite3": ">=5" - }, - "peerDependenciesMeta": { - "@aws-sdk/client-rds-data": { - "optional": true - }, - "@cloudflare/workers-types": { - "optional": true - }, - "@electric-sql/pglite": { - "optional": true - }, - "@libsql/client": { - "optional": true - }, - "@neondatabase/serverless": { - "optional": true - }, - "@op-engineering/op-sqlite": { - "optional": true - }, - "@opentelemetry/api": { - "optional": true - }, - "@planetscale/database": { - "optional": true - }, - "@prisma/client": { - "optional": true - }, - "@tidbcloud/serverless": { - "optional": true - }, - "@types/better-sqlite3": { - "optional": true - }, - "@types/pg": { - "optional": true - }, - "@types/react": { - "optional": true - }, - "@types/sql.js": { - "optional": true - }, - "@vercel/postgres": { - "optional": true - }, - "@xata.io/client": { - "optional": true - }, - "better-sqlite3": { - "optional": true - }, - "bun-types": { - "optional": true - }, - "expo-sqlite": { - "optional": true - }, - "knex": { - "optional": true - }, - "kysely": { - "optional": true - }, - "mysql2": { - "optional": true - }, - "pg": { - "optional": true - }, - "postgres": { - "optional": true - }, - "prisma": { - "optional": true - }, - "react": { - "optional": true - }, - "sql.js": { - "optional": true - }, - "sqlite3": { - "optional": true - } - } - }, - "node_modules/dset": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/dset/-/dset-3.1.4.tgz", - "integrity": "sha512-2QF/g9/zTaPDc3BjNcVTGoBbXBgYfMTTceLaYcFJ/W9kggFUkhxD/hMEeuLKbugyef9SqAx8cpgwlIP/jinUTA==", - "license": "MIT", - "engines": { - "node": ">=4" - } - }, - "node_modules/dunder-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", - "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.1", - "es-errors": "^1.3.0", - "gopd": "^1.2.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/ee-first": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", - "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==", - "license": "MIT" - }, - "node_modules/emmet": { - "version": "2.4.11", - "resolved": "https://registry.npmjs.org/emmet/-/emmet-2.4.11.tgz", - "integrity": "sha512-23QPJB3moh/U9sT4rQzGgeyyGIrcM+GH5uVYg2C6wZIxAIJq7Ng3QLT79tl8FUwDXhyq9SusfknOrofAKqvgyQ==", - "license": "MIT", - "workspaces": [ - "./packages/scanner", - "./packages/abbreviation", - "./packages/css-abbreviation", - "./" - ], - "dependencies": { - "@emmetio/abbreviation": "^2.3.3", - "@emmetio/css-abbreviation": "^2.1.8" - } - }, - "node_modules/emoji-regex": { - "version": "10.4.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-10.4.0.tgz", - "integrity": "sha512-EC+0oUMY1Rqm4O6LLrgjtYDvcVYTy7chDnM4Q7030tP4Kwj3u/pR6gP9ygnp2CJMK5Gq+9Q2oqmrFJAz01DXjw==", - "license": "MIT" - }, - "node_modules/emoji-regex-xs": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex-xs/-/emoji-regex-xs-1.0.0.tgz", - "integrity": "sha512-LRlerrMYoIDrT6jgpeZ2YYl/L8EulRTt5hQcYjy5AInh7HWXKimpqx68aknBFpGL2+/IcogTcaydJEgaTmOpDg==", - "license": "MIT" - }, - "node_modules/encodeurl": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", - "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/encoding-sniffer": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/encoding-sniffer/-/encoding-sniffer-0.2.0.tgz", - "integrity": "sha512-ju7Wq1kg04I3HtiYIOrUrdfdDvkyO9s5XM8QAj/bN61Yo/Vb4vgJxy5vi4Yxk01gWHbrofpPtpxM8bKger9jhg==", - "dev": true, - "license": "MIT", - "dependencies": { - "iconv-lite": "^0.6.3", - "whatwg-encoding": "^3.1.1" - }, - "funding": { - "url": "https://github.com/fb55/encoding-sniffer?sponsor=1" - } - }, - "node_modules/end-of-stream": { - "version": "1.4.4", - "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", - "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", - "license": "MIT", - "dependencies": { - "once": "^1.4.0" - } - }, - "node_modules/enhanced-resolve": { - "version": "5.18.1", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.18.1.tgz", - "integrity": "sha512-ZSW3ma5GkcQBIpwZTSRAI8N71Uuwgs93IezB7mf7R60tC8ZbJideoDNKjHn2O9KIlx6rkGTTEk1xUCK2E1Y2Yg==", - "license": "MIT", - "dependencies": { - "graceful-fs": "^4.2.4", - "tapable": "^2.2.0" - }, - "engines": { - "node": ">=10.13.0" - } - }, - "node_modules/entities": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", - "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.12" - }, - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" - } - }, - "node_modules/es-abstract": { - "version": "1.23.9", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.23.9.tgz", - "integrity": "sha512-py07lI0wjxAC/DcfK1S6G7iANonniZwTISvdPzk9hzeH0IZIshbuuFxLIU96OyF89Yb9hiqWn8M/bY83KY5vzA==", - "dev": true, - "license": "MIT", - "dependencies": { - "array-buffer-byte-length": "^1.0.2", - "arraybuffer.prototype.slice": "^1.0.4", - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.8", - "call-bound": "^1.0.3", - "data-view-buffer": "^1.0.2", - "data-view-byte-length": "^1.0.2", - "data-view-byte-offset": "^1.0.1", - "es-define-property": "^1.0.1", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0", - "es-set-tostringtag": "^2.1.0", - "es-to-primitive": "^1.3.0", - "function.prototype.name": "^1.1.8", - "get-intrinsic": "^1.2.7", - "get-proto": "^1.0.0", - "get-symbol-description": "^1.1.0", - "globalthis": "^1.0.4", - "gopd": "^1.2.0", - "has-property-descriptors": "^1.0.2", - "has-proto": "^1.2.0", - "has-symbols": "^1.1.0", - "hasown": "^2.0.2", - "internal-slot": "^1.1.0", - "is-array-buffer": "^3.0.5", - "is-callable": "^1.2.7", - "is-data-view": "^1.0.2", - "is-regex": "^1.2.1", - "is-shared-array-buffer": "^1.0.4", - "is-string": "^1.1.1", - "is-typed-array": "^1.1.15", - "is-weakref": "^1.1.0", - "math-intrinsics": "^1.1.0", - "object-inspect": "^1.13.3", - "object-keys": "^1.1.1", - "object.assign": "^4.1.7", - "own-keys": "^1.0.1", - "regexp.prototype.flags": "^1.5.3", - "safe-array-concat": "^1.1.3", - "safe-push-apply": "^1.0.0", - "safe-regex-test": "^1.1.0", - "set-proto": "^1.0.0", - "string.prototype.trim": "^1.2.10", - "string.prototype.trimend": "^1.0.9", - "string.prototype.trimstart": "^1.0.8", - "typed-array-buffer": "^1.0.3", - "typed-array-byte-length": "^1.0.3", - "typed-array-byte-offset": "^1.0.4", - "typed-array-length": "^1.0.7", - "unbox-primitive": "^1.1.0", - "which-typed-array": "^1.1.18" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/es-define-property": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", - "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-errors": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", - "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-module-lexer": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.6.0.tgz", - "integrity": "sha512-qqnD1yMU6tk/jnaMosogGySTZP8YtUgAffA9nMN+E/rjxcfRQ6IEk7IiozUjgxKoFHBGjTLnrHB/YC45r/59EQ==", - "license": "MIT" - }, - "node_modules/es-object-atoms": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz", - "integrity": "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-set-tostringtag": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz", - "integrity": "sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.6", - "has-tostringtag": "^1.0.2", - "hasown": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-shim-unscopables": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/es-shim-unscopables/-/es-shim-unscopables-1.1.0.tgz", - "integrity": "sha512-d9T8ucsEhh8Bi1woXCf+TIKDIROLG5WCkxg8geBCbvk22kzwC5G2OnXVMO6FUsvQlgUUXQ2itephWDLqDzbeCw==", - "dev": true, - "license": "MIT", - "dependencies": { - "hasown": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-to-primitive": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.3.0.tgz", - "integrity": "sha512-w+5mJ3GuFL+NjVtJlvydShqE1eN3h3PbI7/5LAsYJP/2qtuMXjfL2LpHSRqo4b4eSF5K/DH1JXKUAHSB2UW50g==", - "dev": true, - "license": "MIT", - "dependencies": { - "is-callable": "^1.2.7", - "is-date-object": "^1.0.5", - "is-symbol": "^1.0.4" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/esast-util-from-estree": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/esast-util-from-estree/-/esast-util-from-estree-2.0.0.tgz", - "integrity": "sha512-4CyanoAudUSBAn5K13H4JhsMH6L9ZP7XbLVe/dKybkxMO7eDyLsT8UHl9TRNrU2Gr9nz+FovfSIjuXWJ81uVwQ==", - "license": "MIT", - "dependencies": { - "@types/estree-jsx": "^1.0.0", - "devlop": "^1.0.0", - "estree-util-visit": "^2.0.0", - "unist-util-position-from-estree": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/esast-util-from-js": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/esast-util-from-js/-/esast-util-from-js-2.0.1.tgz", - "integrity": "sha512-8Ja+rNJ0Lt56Pcf3TAmpBZjmx8ZcK5Ts4cAzIOjsjevg9oSXJnl6SUQ2EevU8tv3h6ZLWmoKL5H4fgWvdvfETw==", - "license": "MIT", - "dependencies": { - "@types/estree-jsx": "^1.0.0", - "acorn": "^8.0.0", - "esast-util-from-estree": "^2.0.0", - "vfile-message": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/esbuild": { - "version": "0.25.0", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.0.tgz", - "integrity": "sha512-BXq5mqc8ltbaN34cDqWuYKyNhX8D/Z0J1xdtdQ8UcIIIyJyz+ZMKUt58tF3SrZ85jcfN/PZYhjR5uDQAYNVbuw==", - "hasInstallScript": true, - "license": "MIT", - "bin": { - "esbuild": "bin/esbuild" - }, - "engines": { - "node": ">=18" - }, - "optionalDependencies": { - "@esbuild/aix-ppc64": "0.25.0", - "@esbuild/android-arm": "0.25.0", - "@esbuild/android-arm64": "0.25.0", - "@esbuild/android-x64": "0.25.0", - "@esbuild/darwin-arm64": "0.25.0", - "@esbuild/darwin-x64": "0.25.0", - "@esbuild/freebsd-arm64": "0.25.0", - "@esbuild/freebsd-x64": "0.25.0", - "@esbuild/linux-arm": "0.25.0", - "@esbuild/linux-arm64": "0.25.0", - "@esbuild/linux-ia32": "0.25.0", - "@esbuild/linux-loong64": "0.25.0", - "@esbuild/linux-mips64el": "0.25.0", - "@esbuild/linux-ppc64": "0.25.0", - "@esbuild/linux-riscv64": "0.25.0", - "@esbuild/linux-s390x": "0.25.0", - "@esbuild/linux-x64": "0.25.0", - "@esbuild/netbsd-arm64": "0.25.0", - "@esbuild/netbsd-x64": "0.25.0", - "@esbuild/openbsd-arm64": "0.25.0", - "@esbuild/openbsd-x64": "0.25.0", - "@esbuild/sunos-x64": "0.25.0", - "@esbuild/win32-arm64": "0.25.0", - "@esbuild/win32-ia32": "0.25.0", - "@esbuild/win32-x64": "0.25.0" - } - }, - "node_modules/escalade": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", - "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/escape-html": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", - "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==", - "license": "MIT" - }, - "node_modules/escape-string-regexp": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz", - "integrity": "sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==", - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/eslint": { - "version": "9.27.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.27.0.tgz", - "integrity": "sha512-ixRawFQuMB9DZ7fjU3iGGganFDp3+45bPOdaRurcFHSXO1e/sYwUX/FtQZpLZJR6SjMoJH8hR2pPEAfDyCoU2Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "@eslint-community/eslint-utils": "^4.2.0", - "@eslint-community/regexpp": "^4.12.1", - "@eslint/config-array": "^0.20.0", - "@eslint/config-helpers": "^0.2.1", - "@eslint/core": "^0.14.0", - "@eslint/eslintrc": "^3.3.1", - "@eslint/js": "9.27.0", - "@eslint/plugin-kit": "^0.3.1", - "@humanfs/node": "^0.16.6", - "@humanwhocodes/module-importer": "^1.0.1", - "@humanwhocodes/retry": "^0.4.2", - "@types/estree": "^1.0.6", - "@types/json-schema": "^7.0.15", - "ajv": "^6.12.4", - "chalk": "^4.0.0", - "cross-spawn": "^7.0.6", - "debug": "^4.3.2", - "escape-string-regexp": "^4.0.0", - "eslint-scope": "^8.3.0", - "eslint-visitor-keys": "^4.2.0", - "espree": "^10.3.0", - "esquery": "^1.5.0", - "esutils": "^2.0.2", - "fast-deep-equal": "^3.1.3", - "file-entry-cache": "^8.0.0", - "find-up": "^5.0.0", - "glob-parent": "^6.0.2", - "ignore": "^5.2.0", - "imurmurhash": "^0.1.4", - "is-glob": "^4.0.0", - "json-stable-stringify-without-jsonify": "^1.0.1", - "lodash.merge": "^4.6.2", - "minimatch": "^3.1.2", - "natural-compare": "^1.4.0", - "optionator": "^0.9.3" - }, - "bin": { - "eslint": "bin/eslint.js" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://eslint.org/donate" - }, - "peerDependencies": { - "jiti": "*" - }, - "peerDependenciesMeta": { - "jiti": { - "optional": true - } - } - }, - "node_modules/eslint-compat-utils": { - "version": "0.6.4", - "resolved": "https://registry.npmjs.org/eslint-compat-utils/-/eslint-compat-utils-0.6.4.tgz", - "integrity": "sha512-/u+GQt8NMfXO8w17QendT4gvO5acfxQsAKirAt0LVxDnr2N8YLCVbregaNc/Yhp7NM128DwCaRvr8PLDfeNkQw==", - "dev": true, - "license": "MIT", - "dependencies": { - "semver": "^7.5.4" - }, - "engines": { - "node": ">=12" - }, - "peerDependencies": { - "eslint": ">=6.0.0" - } - }, - "node_modules/eslint-import-resolver-node": { - "version": "0.3.9", - "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.9.tgz", - "integrity": "sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==", - "dev": true, - "license": "MIT", - "dependencies": { - "debug": "^3.2.7", - "is-core-module": "^2.13.0", - "resolve": "^1.22.4" - } - }, - "node_modules/eslint-import-resolver-node/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "ms": "^2.1.1" - } - }, - "node_modules/eslint-import-resolver-typescript": { - "version": "4.3.5", - "resolved": "https://registry.npmjs.org/eslint-import-resolver-typescript/-/eslint-import-resolver-typescript-4.3.5.tgz", - "integrity": "sha512-QGwhLrwn/WGOsdrWvjhm9n8BvKN/Wr41SQERMV7DQ2hm9+Ozas39CyQUxum///l2G2vefQVr7VbIaCFS5h9g5g==", - "dev": true, - "license": "ISC", - "dependencies": { - "debug": "^4.4.0", - "get-tsconfig": "^4.10.0", - "is-bun-module": "^2.0.0", - "stable-hash": "^0.0.5", - "tinyglobby": "^0.2.13", - "unrs-resolver": "^1.6.3" - }, - "engines": { - "node": "^16.17.0 || >=18.6.0" - }, - "funding": { - "url": "https://opencollective.com/eslint-import-resolver-typescript" - }, - "peerDependencies": { - "eslint": "*", - "eslint-plugin-import": "*", - "eslint-plugin-import-x": "*" - }, - "peerDependenciesMeta": { - "eslint-plugin-import": { - "optional": true - }, - "eslint-plugin-import-x": { - "optional": true - } - } - }, - "node_modules/eslint-module-utils": { - "version": "2.12.0", - "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.12.0.tgz", - "integrity": "sha512-wALZ0HFoytlyh/1+4wuZ9FJCD/leWHQzzrxJ8+rebyReSLk7LApMyd3WJaLVoN+D5+WIdJyDK1c6JnE65V4Zyg==", - "dev": true, - "license": "MIT", - "dependencies": { - "debug": "^3.2.7" - }, - "engines": { - "node": ">=4" - }, - "peerDependenciesMeta": { - "eslint": { - "optional": true - } - } - }, - "node_modules/eslint-module-utils/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "ms": "^2.1.1" - } - }, - "node_modules/eslint-plugin-astro": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-astro/-/eslint-plugin-astro-1.3.1.tgz", - "integrity": "sha512-2XaLCMQm8htW1UvJvy1Zcmg8l0ziskitiUfJTn/w1Mk7r4Mxj0fZeNpN6UTNrm64XBIXSa5h8UCGrg8mdu47+g==", - "dev": true, - "license": "MIT", - "dependencies": { - "@eslint-community/eslint-utils": "^4.2.0", - "@jridgewell/sourcemap-codec": "^1.4.14", - "@typescript-eslint/types": "^7.7.1 || ^8", - "astro-eslint-parser": "^1.0.2", - "eslint-compat-utils": "^0.6.0", - "globals": "^15.0.0", - "postcss": "^8.4.14", - "postcss-selector-parser": "^7.0.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://github.com/sponsors/ota-meshi" - }, - "peerDependencies": { - "eslint": ">=8.57.0" - } - }, - "node_modules/eslint-plugin-astro/node_modules/globals": { - "version": "15.15.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-15.15.0.tgz", - "integrity": "sha512-7ACyT3wmyp3I61S4fG682L0VA2RGD9otkqGJIwNUMF1SWUombIIk+af1unuDYgMm082aHYwD+mzJvv9Iu8dsgg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/eslint-plugin-astro/node_modules/postcss-selector-parser": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-7.1.0.tgz", - "integrity": "sha512-8sLjZwK0R+JlxlYcTuVnyT2v+htpdrjDOKuMcOVdYjt52Lh8hWRYpxBPoKx/Zg+bcjc3wx6fmQevMmUztS/ccA==", - "dev": true, - "license": "MIT", - "dependencies": { - "cssesc": "^3.0.0", - "util-deprecate": "^1.0.2" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/eslint-plugin-import": { - "version": "2.31.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.31.0.tgz", - "integrity": "sha512-ixmkI62Rbc2/w8Vfxyh1jQRTdRTF52VxwRVHl/ykPAmqG+Nb7/kNn+byLP0LxPgI7zWA16Jt82SybJInmMia3A==", - "dev": true, - "license": "MIT", - "dependencies": { - "@rtsao/scc": "^1.1.0", - "array-includes": "^3.1.8", - "array.prototype.findlastindex": "^1.2.5", - "array.prototype.flat": "^1.3.2", - "array.prototype.flatmap": "^1.3.2", - "debug": "^3.2.7", - "doctrine": "^2.1.0", - "eslint-import-resolver-node": "^0.3.9", - "eslint-module-utils": "^2.12.0", - "hasown": "^2.0.2", - "is-core-module": "^2.15.1", - "is-glob": "^4.0.3", - "minimatch": "^3.1.2", - "object.fromentries": "^2.0.8", - "object.groupby": "^1.0.3", - "object.values": "^1.2.0", - "semver": "^6.3.1", - "string.prototype.trimend": "^1.0.8", - "tsconfig-paths": "^3.15.0" - }, - "engines": { - "node": ">=4" - }, - "peerDependencies": { - "eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 || ^9" - } - }, - "node_modules/eslint-plugin-import/node_modules/brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/eslint-plugin-import/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "ms": "^2.1.1" - } - }, - "node_modules/eslint-plugin-import/node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, - "node_modules/eslint-plugin-import/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - } - }, - "node_modules/eslint-plugin-jsx-a11y": { - "version": "6.10.2", - "resolved": "https://registry.npmjs.org/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.10.2.tgz", - "integrity": "sha512-scB3nz4WmG75pV8+3eRUQOHZlNSUhFNq37xnpgRkCCELU3XMvXAxLk1eqWWyE22Ki4Q01Fnsw9BA3cJHDPgn2Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "aria-query": "^5.3.2", - "array-includes": "^3.1.8", - "array.prototype.flatmap": "^1.3.2", - "ast-types-flow": "^0.0.8", - "axe-core": "^4.10.0", - "axobject-query": "^4.1.0", - "damerau-levenshtein": "^1.0.8", - "emoji-regex": "^9.2.2", - "hasown": "^2.0.2", - "jsx-ast-utils": "^3.3.5", - "language-tags": "^1.0.9", - "minimatch": "^3.1.2", - "object.fromentries": "^2.0.8", - "safe-regex-test": "^1.0.3", - "string.prototype.includes": "^2.0.1" - }, - "engines": { - "node": ">=4.0" - }, - "peerDependencies": { - "eslint": "^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9" - } - }, - "node_modules/eslint-plugin-jsx-a11y/node_modules/brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/eslint-plugin-jsx-a11y/node_modules/emoji-regex": { - "version": "9.2.2", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", - "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", - "dev": true, - "license": "MIT" - }, - "node_modules/eslint-plugin-jsx-a11y/node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, - "node_modules/eslint-scope": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-8.3.0.tgz", - "integrity": "sha512-pUNxi75F8MJ/GdeKtVLSbYg4ZI34J6C0C7sbL4YOp2exGwen7ZsuBqKzUhXd0qMQ362yET3z+uPwKeg/0C2XCQ==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "esrecurse": "^4.3.0", - "estraverse": "^5.2.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/eslint-visitor-keys": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", - "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/eslint/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/eslint/node_modules/brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/eslint/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/eslint/node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/eslint/node_modules/glob-parent": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", - "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", - "dev": true, - "license": "ISC", - "dependencies": { - "is-glob": "^4.0.3" - }, - "engines": { - "node": ">=10.13.0" - } - }, - "node_modules/eslint/node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, - "node_modules/espree": { - "version": "10.3.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-10.3.0.tgz", - "integrity": "sha512-0QYC8b24HWY8zjRnDTL6RiHfDbAWn63qb4LMj1Z4b076A4une81+z03Kg7l7mn/48PUTqoLptSXez8oknU8Clg==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "acorn": "^8.14.0", - "acorn-jsx": "^5.3.2", - "eslint-visitor-keys": "^4.2.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/esquery": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.6.0.tgz", - "integrity": "sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "estraverse": "^5.1.0" - }, - "engines": { - "node": ">=0.10" - } - }, - "node_modules/esrecurse": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", - "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "estraverse": "^5.2.0" - }, - "engines": { - "node": ">=4.0" - } - }, - "node_modules/estraverse": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=4.0" - } - }, - "node_modules/estree-util-attach-comments": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/estree-util-attach-comments/-/estree-util-attach-comments-3.0.0.tgz", - "integrity": "sha512-cKUwm/HUcTDsYh/9FgnuFqpfquUbwIqwKM26BVCGDPVgvaCl/nDCCjUfiLlx6lsEZ3Z4RFxNbOQ60pkaEwFxGw==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/estree-util-build-jsx": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/estree-util-build-jsx/-/estree-util-build-jsx-3.0.1.tgz", - "integrity": "sha512-8U5eiL6BTrPxp/CHbs2yMgP8ftMhR5ww1eIKoWRMlqvltHF8fZn5LRDvTKuxD3DUn+shRbLGqXemcP51oFCsGQ==", - "license": "MIT", - "dependencies": { - "@types/estree-jsx": "^1.0.0", - "devlop": "^1.0.0", - "estree-util-is-identifier-name": "^3.0.0", - "estree-walker": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/estree-util-is-identifier-name": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/estree-util-is-identifier-name/-/estree-util-is-identifier-name-3.0.0.tgz", - "integrity": "sha512-hFtqIDZTIUZ9BXLb8y4pYGyk6+wekIivNVTcmvk8NoOh+VeRn5y6cEHzbURrWbfp1fIqdVipilzj+lfaadNZmg==", - "license": "MIT", - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/estree-util-scope": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/estree-util-scope/-/estree-util-scope-1.0.0.tgz", - "integrity": "sha512-2CAASclonf+JFWBNJPndcOpA8EMJwa0Q8LUFJEKqXLW6+qBvbFZuF5gItbQOs/umBUkjviCSDCbBwU2cXbmrhQ==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "devlop": "^1.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/estree-util-to-js": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/estree-util-to-js/-/estree-util-to-js-2.0.0.tgz", - "integrity": "sha512-WDF+xj5rRWmD5tj6bIqRi6CkLIXbbNQUcxQHzGysQzvHmdYG2G7p/Tf0J0gpxGgkeMZNTIjT/AoSvC9Xehcgdg==", - "license": "MIT", - "dependencies": { - "@types/estree-jsx": "^1.0.0", - "astring": "^1.8.0", - "source-map": "^0.7.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/estree-util-visit": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/estree-util-visit/-/estree-util-visit-2.0.0.tgz", - "integrity": "sha512-m5KgiH85xAhhW8Wta0vShLcUvOsh3LLPI2YVwcbio1l7E09NTLL1EyMZFM1OyWowoH0skScNbhOPl4kcBgzTww==", - "license": "MIT", - "dependencies": { - "@types/estree-jsx": "^1.0.0", - "@types/unist": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/estree-walker": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-3.0.3.tgz", - "integrity": "sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0" - } - }, - "node_modules/esutils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/etag": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", - "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/eventemitter3": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-5.0.1.tgz", - "integrity": "sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==", - "license": "MIT" - }, - "node_modules/expand-template": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz", - "integrity": "sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==", - "license": "(MIT OR WTFPL)", - "engines": { - "node": ">=6" - } - }, - "node_modules/extend": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", - "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", - "license": "MIT" - }, - "node_modules/extract-zip": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-2.0.1.tgz", - "integrity": "sha512-GDhU9ntwuKyGXdZBUgTIe+vXnWj0fppUEtMDL0+idd5Sta8TGpHssn/eusA9mrPr9qNDym6SxAYZjNvCn/9RBg==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "debug": "^4.1.1", - "get-stream": "^5.1.0", - "yauzl": "^2.10.0" - }, - "bin": { - "extract-zip": "cli.js" - }, - "engines": { - "node": ">= 10.17.0" - }, - "optionalDependencies": { - "@types/yauzl": "^2.9.1" - } - }, - "node_modules/fast-deep-equal": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "license": "MIT" - }, - "node_modules/fast-glob": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.3.tgz", - "integrity": "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==", - "license": "MIT", - "dependencies": { - "@nodelib/fs.stat": "^2.0.2", - "@nodelib/fs.walk": "^1.2.3", - "glob-parent": "^5.1.2", - "merge2": "^1.3.0", - "micromatch": "^4.0.8" - }, - "engines": { - "node": ">=8.6.0" - } - }, - "node_modules/fast-json-stable-stringify": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", - "dev": true, - "license": "MIT" - }, - "node_modules/fast-levenshtein": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", - "dev": true, - "license": "MIT" - }, - "node_modules/fast-uri": { - "version": "3.0.6", - "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.0.6.tgz", - "integrity": "sha512-Atfo14OibSv5wAp4VWNsFYE1AchQRTv9cBGWET4pZWHzYshFSS9NQI6I57rdKn9croWVMbYFbLhJ+yJvmZIIHw==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/fastify" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/fastify" - } - ], - "license": "BSD-3-Clause" - }, - "node_modules/fastq": { - "version": "1.18.0", - "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.18.0.tgz", - "integrity": "sha512-QKHXPW0hD8g4UET03SdOdunzSouc9N4AuHdsX8XNcTsuz+yYFILVNIX4l9yHABMhiEI9Db0JTTIpu0wB+Y1QQw==", - "license": "ISC", - "dependencies": { - "reusify": "^1.0.4" - } - }, - "node_modules/fd-slicer": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.1.0.tgz", - "integrity": "sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==", - "dev": true, - "license": "MIT", - "dependencies": { - "pend": "~1.2.0" - } - }, - "node_modules/fdir": { - "version": "6.4.4", - "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.4.4.tgz", - "integrity": "sha512-1NZP+GK4GfuAv3PqKvxQRDMjdSRZjnkq7KfhlNrCNNlZ0ygQFpebfrnfnq/W7fpUnAv9aGWmY1zKx7FYL3gwhg==", - "license": "MIT", - "peerDependencies": { - "picomatch": "^3 || ^4" - }, - "peerDependenciesMeta": { - "picomatch": { - "optional": true - } - } - }, - "node_modules/fetch-blob": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/fetch-blob/-/fetch-blob-3.2.0.tgz", - "integrity": "sha512-7yAQpD2UMJzLi1Dqv7qFYnPbaPx7ZfFK6PiIxQ4PfkGPyNyl2Ugx+a/umUonmKqjhM4DnfbMvdX6otXq83soQQ==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/jimmywarting" - }, - { - "type": "paypal", - "url": "https://paypal.me/jimmywarting" - } - ], - "license": "MIT", - "dependencies": { - "node-domexception": "^1.0.0", - "web-streams-polyfill": "^3.0.3" - }, - "engines": { - "node": "^12.20 || >= 14.13" - } - }, - "node_modules/fflate": { - "version": "0.7.4", - "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.7.4.tgz", - "integrity": "sha512-5u2V/CDW15QM1XbbgS+0DfPxVB+jUKhWEKuuFuHncbk3tEEqzmoXL+2KyOFuKGqOnmdIy0/davWF1CkuwtibCw==", - "license": "MIT" - }, - "node_modules/file-entry-cache": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-8.0.0.tgz", - "integrity": "sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "flat-cache": "^4.0.0" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/fill-range": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", - "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", - "license": "MIT", - "dependencies": { - "to-regex-range": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/find-up": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", - "dev": true, - "license": "MIT", - "dependencies": { - "locate-path": "^6.0.0", - "path-exists": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/flat-cache": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-4.0.1.tgz", - "integrity": "sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==", - "dev": true, - "license": "MIT", - "dependencies": { - "flatted": "^3.2.9", - "keyv": "^4.5.4" - }, - "engines": { - "node": ">=16" - } - }, - "node_modules/flatted": { - "version": "3.3.2", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.2.tgz", - "integrity": "sha512-AiwGJM8YcNOaobumgtng+6NHuOqC3A7MixFeDafM3X9cIUM+xUXoS5Vfgf+OihAYe20fxqNM9yPBXJzRtZ/4eA==", - "dev": true, - "license": "ISC" - }, - "node_modules/flattie": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/flattie/-/flattie-1.1.1.tgz", - "integrity": "sha512-9UbaD6XdAL97+k/n+N7JwX46K/M6Zc6KcFYskrYL8wbBV/Uyk0CTAMY0VT+qiK5PM7AIc9aTWYtq65U7T+aCNQ==", - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/follow-redirects": { - "version": "1.15.9", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.9.tgz", - "integrity": "sha512-gew4GsXizNgdoRyqmyfMHyAmXsZDk6mHkSxZFCzW9gwlbtOW44CDtYavM+y+72qD/Vq2l550kMF52DT8fOLJqQ==", - "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://github.com/sponsors/RubenVerborgh" - } - ], - "license": "MIT", - "engines": { - "node": ">=4.0" - }, - "peerDependenciesMeta": { - "debug": { - "optional": true - } - } - }, - "node_modules/fontace": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/fontace/-/fontace-0.3.0.tgz", - "integrity": "sha512-czoqATrcnxgWb/nAkfyIrRp6Q8biYj7nGnL6zfhTcX+JKKpWHFBnb8uNMw/kZr7u++3Y3wYSYoZgHkCcsuBpBg==", - "license": "MIT", - "dependencies": { - "@types/fontkit": "^2.0.8", - "fontkit": "^2.0.4" - } - }, - "node_modules/fontkit": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/fontkit/-/fontkit-2.0.4.tgz", - "integrity": "sha512-syetQadaUEDNdxdugga9CpEYVaQIxOwk7GlwZWWZ19//qW4zE5bknOKeMBDYAASwnpaSHKJITRLMF9m1fp3s6g==", - "license": "MIT", - "dependencies": { - "@swc/helpers": "^0.5.12", - "brotli": "^1.3.2", - "clone": "^2.1.2", - "dfa": "^1.2.0", - "fast-deep-equal": "^3.1.3", - "restructure": "^3.0.0", - "tiny-inflate": "^1.0.3", - "unicode-properties": "^1.4.0", - "unicode-trie": "^2.0.0" - } - }, - "node_modules/for-each": { - "version": "0.3.5", - "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.5.tgz", - "integrity": "sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==", - "dev": true, - "license": "MIT", - "dependencies": { - "is-callable": "^1.2.7" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/form-data": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.1.tgz", - "integrity": "sha512-tzN8e4TX8+kkxGPK8D5u0FNmjPUjw3lwC9lSLxxoB/+GtsJG91CO8bSWy73APlgAZzZbXEYZJuxjkHH2w+Ezhw==", - "dev": true, - "license": "MIT", - "dependencies": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.8", - "mime-types": "^2.1.12" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/form-data/node_modules/mime-db": { - "version": "1.52.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", - "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/form-data/node_modules/mime-types": { - "version": "2.1.35", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", - "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", - "dev": true, - "license": "MIT", - "dependencies": { - "mime-db": "1.52.0" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/formdata-polyfill": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/formdata-polyfill/-/formdata-polyfill-4.0.10.tgz", - "integrity": "sha512-buewHzMvYL29jdeQTVILecSaZKnt/RJWjoZCF5OW60Z67/GmSLBkOFM7qh1PI3zFNtJbaZL5eQu1vLfazOwj4g==", - "license": "MIT", - "dependencies": { - "fetch-blob": "^3.1.2" - }, - "engines": { - "node": ">=12.20.0" - } - }, - "node_modules/fresh": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/fresh/-/fresh-2.0.0.tgz", - "integrity": "sha512-Rx/WycZ60HOaqLKAi6cHRKKI7zxWbJ31MhntmtwMoaTeF7XFH9hhBp8vITaMidfljRQ6eYWCKkaTK+ykVJHP2A==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/fs-constants": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", - "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", - "license": "MIT" - }, - "node_modules/fs-minipass": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", - "integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==", - "dev": true, - "license": "ISC", - "dependencies": { - "minipass": "^3.0.0" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/fs-minipass/node_modules/minipass": { - "version": "3.3.6", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", - "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", - "dev": true, - "license": "ISC", - "dependencies": { - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/fsevents": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", - "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", - "hasInstallScript": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" - } - }, - "node_modules/function-bind": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", - "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", - "dev": true, - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/function.prototype.name": { - "version": "1.1.8", - "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.8.tgz", - "integrity": "sha512-e5iwyodOHhbMr/yNrc7fDYG4qlbIvI5gajyzPnb5TCwyhjApznQh1BMFou9b30SevY43gCJKXycoCBjMbsuW0Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "call-bound": "^1.0.3", - "define-properties": "^1.2.1", - "functions-have-names": "^1.2.3", - "hasown": "^2.0.2", - "is-callable": "^1.2.7" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/functions-have-names": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", - "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", - "dev": true, - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "license": "ISC", - "engines": { - "node": "6.* || 8.* || >= 10.*" - } - }, - "node_modules/get-east-asian-width": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/get-east-asian-width/-/get-east-asian-width-1.3.0.tgz", - "integrity": "sha512-vpeMIQKxczTD/0s2CdEWHcb0eeJe6TFjxb+J5xgX7hScxqrGuyjmv4c1D4A/gelKfyox0gJJwIHF+fLjeaM8kQ==", - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/get-intrinsic": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.7.tgz", - "integrity": "sha512-VW6Pxhsrk0KAOqs3WEd0klDiF/+V7gQOpAvY1jVU/LHmaD/kQO4523aiJuikX/QAKYiW6x8Jh+RJej1almdtCA==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind-apply-helpers": "^1.0.1", - "es-define-property": "^1.0.1", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0", - "function-bind": "^1.1.2", - "get-proto": "^1.0.0", - "gopd": "^1.2.0", - "has-symbols": "^1.1.0", - "hasown": "^2.0.2", - "math-intrinsics": "^1.1.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/get-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", - "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==", - "dev": true, - "license": "MIT", - "dependencies": { - "dunder-proto": "^1.0.1", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/get-stream": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", - "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", - "dev": true, - "license": "MIT", - "dependencies": { - "pump": "^3.0.0" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/get-symbol-description": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.1.0.tgz", - "integrity": "sha512-w9UMqWwJxHNOvoNzSJ2oPF5wvYcvP7jUvYzhp67yEhTi17ZDBBC1z9pTdGuzjD+EFIqLSYRweZjqfiPzQ06Ebg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.6" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/get-tsconfig": { - "version": "4.10.0", - "resolved": "https://registry.npmjs.org/get-tsconfig/-/get-tsconfig-4.10.0.tgz", - "integrity": "sha512-kGzZ3LWWQcGIAmg6iWvXn0ei6WDtV26wzHRMwDSzmAbcXrTEXxHy6IehI6/4eT6VRKyMP1eF1VqwrVUmE/LR7A==", - "devOptional": true, - "license": "MIT", - "dependencies": { - "resolve-pkg-maps": "^1.0.0" - }, - "funding": { - "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" - } - }, - "node_modules/github-from-package": { - "version": "0.0.0", - "resolved": "https://registry.npmjs.org/github-from-package/-/github-from-package-0.0.0.tgz", - "integrity": "sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==", - "license": "MIT" - }, - "node_modules/github-slugger": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/github-slugger/-/github-slugger-2.0.0.tgz", - "integrity": "sha512-IaOQ9puYtjrkq7Y0Ygl9KDZnrf/aiUJYUpVf89y8kyaxbRG7Y1SrX/jaumrv81vc61+kiMempujsM3Yw7w5qcw==", - "license": "ISC" - }, - "node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", - "license": "ISC", - "dependencies": { - "is-glob": "^4.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/globals": { - "version": "16.1.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-16.1.0.tgz", - "integrity": "sha512-aibexHNbb/jiUSObBgpHLj+sIuUmJnYcgXBlrfsiDZ9rt4aF2TFRbyLgZ2iFQuVZ1K5Mx3FVkbKRSgKrbK3K2g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/globalthis": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.4.tgz", - "integrity": "sha512-DpLKbNU4WylpxJykQujfCcwYWiV/Jhm50Goo0wrVILAv5jOr9d+H+UR3PhSCD2rCCEIg0uc+G+muBTwD54JhDQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "define-properties": "^1.2.1", - "gopd": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/gopd": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", - "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/graceful-fs": { - "version": "4.2.11", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", - "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", - "license": "ISC" - }, - "node_modules/graphemer": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz", - "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==", - "dev": true, - "license": "MIT" - }, - "node_modules/h3": { - "version": "1.15.1", - "resolved": "https://registry.npmjs.org/h3/-/h3-1.15.1.tgz", - "integrity": "sha512-+ORaOBttdUm1E2Uu/obAyCguiI7MbBvsLTndc3gyK3zU+SYLoZXlyCP9Xgy0gikkGufFLTZXCXD6+4BsufnmHA==", - "license": "MIT", - "dependencies": { - "cookie-es": "^1.2.2", - "crossws": "^0.3.3", - "defu": "^6.1.4", - "destr": "^2.0.3", - "iron-webcrypto": "^1.2.1", - "node-mock-http": "^1.0.0", - "radix3": "^1.1.2", - "ufo": "^1.5.4", - "uncrypto": "^0.1.3" - } - }, - "node_modules/has-bigints": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.1.0.tgz", - "integrity": "sha512-R3pbpkcIqv2Pm3dUwgjclDRVmWpTJW2DcMzcIhEXEx1oh/CEMObMm3KLmRJOdvhM7o4uQBnwr8pzRK2sJWIqfg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/has-property-descriptors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", - "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-define-property": "^1.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-proto": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.2.0.tgz", - "integrity": "sha512-KIL7eQPfHQRC8+XluaIw7BHUwwqL19bQn4hzNgdr+1wXoU0KKj6rufu47lhY7KbJR2C6T6+PfyN0Ea7wkSS+qQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "dunder-proto": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-symbols": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", - "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-tostringtag": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", - "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-symbols": "^1.0.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/hasown": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", - "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "function-bind": "^1.1.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/hast-util-from-html": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/hast-util-from-html/-/hast-util-from-html-2.0.3.tgz", - "integrity": "sha512-CUSRHXyKjzHov8yKsQjGOElXy/3EKpyX56ELnkHH34vDVw1N1XSQ1ZcAvTyAPtGqLTuKP/uxM+aLkSPqF/EtMw==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "devlop": "^1.1.0", - "hast-util-from-parse5": "^8.0.0", - "parse5": "^7.0.0", - "vfile": "^6.0.0", - "vfile-message": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-from-parse5": { - "version": "8.0.2", - "resolved": "https://registry.npmjs.org/hast-util-from-parse5/-/hast-util-from-parse5-8.0.2.tgz", - "integrity": "sha512-SfMzfdAi/zAoZ1KkFEyyeXBn7u/ShQrfd675ZEE9M3qj+PMFX05xubzRyF76CCSJu8au9jgVxDV1+okFvgZU4A==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "@types/unist": "^3.0.0", - "devlop": "^1.0.0", - "hastscript": "^9.0.0", - "property-information": "^6.0.0", - "vfile": "^6.0.0", - "vfile-location": "^5.0.0", - "web-namespaces": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-is-element": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/hast-util-is-element/-/hast-util-is-element-3.0.0.tgz", - "integrity": "sha512-Val9mnv2IWpLbNPqc/pUem+a7Ipj2aHacCwgNfTiK0vJKl0LF+4Ba4+v1oPHFpf3bLYmreq0/l3Gud9S5OH42g==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-parse-selector": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/hast-util-parse-selector/-/hast-util-parse-selector-4.0.0.tgz", - "integrity": "sha512-wkQCkSYoOGCRKERFWcxMVMOcYE2K1AaNLU8DXS9arxnLOUEWbOXKXiJUNzEpqZ3JOKpnha3jkFrumEjVliDe7A==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-raw": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/hast-util-raw/-/hast-util-raw-9.1.0.tgz", - "integrity": "sha512-Y8/SBAHkZGoNkpzqqfCldijcuUKh7/su31kEBp67cFY09Wy0mTRgtsLYsiIxMJxlu0f6AA5SUTbDR8K0rxnbUw==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "@types/unist": "^3.0.0", - "@ungap/structured-clone": "^1.0.0", - "hast-util-from-parse5": "^8.0.0", - "hast-util-to-parse5": "^8.0.0", - "html-void-elements": "^3.0.0", - "mdast-util-to-hast": "^13.0.0", - "parse5": "^7.0.0", - "unist-util-position": "^5.0.0", - "unist-util-visit": "^5.0.0", - "vfile": "^6.0.0", - "web-namespaces": "^2.0.0", - "zwitch": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-to-estree": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/hast-util-to-estree/-/hast-util-to-estree-3.1.3.tgz", - "integrity": "sha512-48+B/rJWAp0jamNbAAf9M7Uf//UVqAoMmgXhBdxTDJLGKY+LRnZ99qcG+Qjl5HfMpYNzS5v4EAwVEF34LeAj7w==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "@types/estree-jsx": "^1.0.0", - "@types/hast": "^3.0.0", - "comma-separated-tokens": "^2.0.0", - "devlop": "^1.0.0", - "estree-util-attach-comments": "^3.0.0", - "estree-util-is-identifier-name": "^3.0.0", - "hast-util-whitespace": "^3.0.0", - "mdast-util-mdx-expression": "^2.0.0", - "mdast-util-mdx-jsx": "^3.0.0", - "mdast-util-mdxjs-esm": "^2.0.0", - "property-information": "^7.0.0", - "space-separated-tokens": "^2.0.0", - "style-to-js": "^1.0.0", - "unist-util-position": "^5.0.0", - "zwitch": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-to-estree/node_modules/property-information": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/property-information/-/property-information-7.1.0.tgz", - "integrity": "sha512-TwEZ+X+yCJmYfL7TPUOcvBZ4QfoT5YenQiJuX//0th53DE6w0xxLEtfK3iyryQFddXuvkIk51EEgrJQ0WJkOmQ==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/hast-util-to-html": { - "version": "9.0.5", - "resolved": "https://registry.npmjs.org/hast-util-to-html/-/hast-util-to-html-9.0.5.tgz", - "integrity": "sha512-OguPdidb+fbHQSU4Q4ZiLKnzWo8Wwsf5bZfbvu7//a9oTYoqD/fWpe96NuHkoS9h0ccGOTe0C4NGXdtS0iObOw==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "@types/unist": "^3.0.0", - "ccount": "^2.0.0", - "comma-separated-tokens": "^2.0.0", - "hast-util-whitespace": "^3.0.0", - "html-void-elements": "^3.0.0", - "mdast-util-to-hast": "^13.0.0", - "property-information": "^7.0.0", - "space-separated-tokens": "^2.0.0", - "stringify-entities": "^4.0.0", - "zwitch": "^2.0.4" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-to-html/node_modules/property-information": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/property-information/-/property-information-7.0.0.tgz", - "integrity": "sha512-7D/qOz/+Y4X/rzSB6jKxKUsQnphO046ei8qxG59mtM3RG3DHgTK81HrxrmoDVINJb8NKT5ZsRbwHvQ6B68Iyhg==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/hast-util-to-jsx-runtime": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/hast-util-to-jsx-runtime/-/hast-util-to-jsx-runtime-2.3.6.tgz", - "integrity": "sha512-zl6s8LwNyo1P9uw+XJGvZtdFF1GdAkOg8ujOw+4Pyb76874fLps4ueHXDhXWdk6YHQ6OgUtinliG7RsYvCbbBg==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "@types/hast": "^3.0.0", - "@types/unist": "^3.0.0", - "comma-separated-tokens": "^2.0.0", - "devlop": "^1.0.0", - "estree-util-is-identifier-name": "^3.0.0", - "hast-util-whitespace": "^3.0.0", - "mdast-util-mdx-expression": "^2.0.0", - "mdast-util-mdx-jsx": "^3.0.0", - "mdast-util-mdxjs-esm": "^2.0.0", - "property-information": "^7.0.0", - "space-separated-tokens": "^2.0.0", - "style-to-js": "^1.0.0", - "unist-util-position": "^5.0.0", - "vfile-message": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-to-jsx-runtime/node_modules/property-information": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/property-information/-/property-information-7.1.0.tgz", - "integrity": "sha512-TwEZ+X+yCJmYfL7TPUOcvBZ4QfoT5YenQiJuX//0th53DE6w0xxLEtfK3iyryQFddXuvkIk51EEgrJQ0WJkOmQ==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/hast-util-to-parse5": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/hast-util-to-parse5/-/hast-util-to-parse5-8.0.0.tgz", - "integrity": "sha512-3KKrV5ZVI8if87DVSi1vDeByYrkGzg4mEfeu4alwgmmIeARiBLKCZS2uw5Gb6nU9x9Yufyj3iudm6i7nl52PFw==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "comma-separated-tokens": "^2.0.0", - "devlop": "^1.0.0", - "property-information": "^6.0.0", - "space-separated-tokens": "^2.0.0", - "web-namespaces": "^2.0.0", - "zwitch": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-to-text": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/hast-util-to-text/-/hast-util-to-text-4.0.2.tgz", - "integrity": "sha512-KK6y/BN8lbaq654j7JgBydev7wuNMcID54lkRav1P0CaE1e47P72AWWPiGKXTJU271ooYzcvTAn/Zt0REnvc7A==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "@types/unist": "^3.0.0", - "hast-util-is-element": "^3.0.0", - "unist-util-find-after": "^5.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-whitespace": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/hast-util-whitespace/-/hast-util-whitespace-3.0.0.tgz", - "integrity": "sha512-88JUN06ipLwsnv+dVn+OIYOvAuvBMy/Qoi6O7mQHxdPXpjy+Cd6xRkWwux7DKO+4sYILtLBRIKgsdpS2gQc7qw==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hastscript": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/hastscript/-/hastscript-9.0.0.tgz", - "integrity": "sha512-jzaLBGavEDKHrc5EfFImKN7nZKKBdSLIdGvCwDZ9TfzbF2ffXiov8CKE445L2Z1Ek2t/m4SKQ2j6Ipv7NyUolw==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "comma-separated-tokens": "^2.0.0", - "hast-util-parse-selector": "^4.0.0", - "property-information": "^6.0.0", - "space-separated-tokens": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hex-rgb": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/hex-rgb/-/hex-rgb-4.3.0.tgz", - "integrity": "sha512-Ox1pJVrDCyGHMG9CFg1tmrRUMRPRsAWYc/PinY0XzJU4K7y7vjNoLKIQ7BR5UJMCxNN8EM1MNDmHWA/B3aZUuw==", - "license": "MIT", - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/html-escaper": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-3.0.3.tgz", - "integrity": "sha512-RuMffC89BOWQoY0WKGpIhn5gX3iI54O6nRA0yC124NYVtzjmFWBIiFd8M0x+ZdX0P9R4lADg1mgP8C7PxGOWuQ==", - "license": "MIT" - }, - "node_modules/html-void-elements": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/html-void-elements/-/html-void-elements-3.0.0.tgz", - "integrity": "sha512-bEqo66MRXsUGxWHV5IP0PUiAWwoEjba4VCzg0LjFJBpchPaTfyfCKTG6bc5F8ucKec3q5y6qOdGyYTSBEvhCrg==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/htmlparser2": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-9.1.0.tgz", - "integrity": "sha512-5zfg6mHUoaer/97TxnGpxmbR7zJtPwIYFMZ/H5ucTlPZhKvtum05yiPK3Mgai3a0DyVxv7qYqoweaEd2nrYQzQ==", - "dev": true, - "funding": [ - "https://github.com/fb55/htmlparser2?sponsor=1", - { - "type": "github", - "url": "https://github.com/sponsors/fb55" - } - ], - "license": "MIT", - "dependencies": { - "domelementtype": "^2.3.0", - "domhandler": "^5.0.3", - "domutils": "^3.1.0", - "entities": "^4.5.0" - } - }, - "node_modules/htmx.org": { - "version": "1.9.12", - "resolved": "https://registry.npmjs.org/htmx.org/-/htmx.org-1.9.12.tgz", - "integrity": "sha512-VZAohXyF7xPGS52IM8d1T1283y+X4D+Owf3qY1NZ9RuBypyu9l8cGsxUMAG5fEAb/DhT7rDoJ9Hpu5/HxFD3cw==", - "license": "0BSD" - }, - "node_modules/http-cache-semantics": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz", - "integrity": "sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==", - "license": "BSD-2-Clause" - }, - "node_modules/http-errors": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.0.tgz", - "integrity": "sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==", - "license": "MIT", - "dependencies": { - "depd": "2.0.0", - "inherits": "2.0.4", - "setprototypeof": "1.2.0", - "statuses": "2.0.1", - "toidentifier": "1.0.1" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/iconv-lite": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", - "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", - "dev": true, - "license": "MIT", - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/ieee754": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", - "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "BSD-3-Clause" - }, - "node_modules/ignore": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", - "integrity": "sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 4" - } - }, - "node_modules/import-fresh": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.1.tgz", - "integrity": "sha512-TR3KfrTZTYLPB6jUjfx6MF9WcWrHL9su5TObK4ZkYgBdWKPOFoSoQIdEuTuR82pmtxH2spWG9h6etwfr1pLBqQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "parent-module": "^1.0.0", - "resolve-from": "^4.0.0" - }, - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/import-meta-resolve": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/import-meta-resolve/-/import-meta-resolve-4.1.0.tgz", - "integrity": "sha512-I6fiaX09Xivtk+THaMfAwnA3MVA5Big1WHF1Dfx9hFuvNIWpXnorlkzhcQf6ehrqQiiZECRt1poOAkPmer3ruw==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/imurmurhash": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.8.19" - } - }, - "node_modules/inherits": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "license": "ISC" - }, - "node_modules/ini": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", - "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", - "license": "ISC" - }, - "node_modules/inline-style-parser": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/inline-style-parser/-/inline-style-parser-0.2.4.tgz", - "integrity": "sha512-0aO8FkhNZlj/ZIbNi7Lxxr12obT7cL1moPfE4tg1LkX7LlLfC6DeX4l2ZEud1ukP9jNQyNnfzQVqwbwmAATY4Q==", - "license": "MIT" - }, - "node_modules/internal-slot": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.1.0.tgz", - "integrity": "sha512-4gd7VpWNQNB4UKKCFFVcp1AVv+FMOgs9NKzjHKusc8jTMhd5eL1NqQqOpE0KzMds804/yHlglp3uxgluOqAPLw==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "hasown": "^2.0.2", - "side-channel": "^1.1.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/iron-webcrypto": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/iron-webcrypto/-/iron-webcrypto-1.2.1.tgz", - "integrity": "sha512-feOM6FaSr6rEABp/eDfVseKyTMDt+KGpeB35SkVn9Tyn0CqvVsY3EwI0v5i8nMHyJnzCIQf7nsy3p41TPkJZhg==", - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/brc-dd" - } - }, - "node_modules/is-alphabetical": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-alphabetical/-/is-alphabetical-2.0.1.tgz", - "integrity": "sha512-FWyyY60MeTNyeSRpkM2Iry0G9hpr7/9kD40mD/cGQEuilcZYS4okz8SN2Q6rLCJ8gbCt6fN+rC+6tMGS99LaxQ==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/is-alphanumerical": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-alphanumerical/-/is-alphanumerical-2.0.1.tgz", - "integrity": "sha512-hmbYhX/9MUMF5uh7tOXyK/n0ZvWpad5caBA17GsC6vyuCqaWliRG5K1qS9inmUhEMaOBIW7/whAnSwveW/LtZw==", - "license": "MIT", - "dependencies": { - "is-alphabetical": "^2.0.0", - "is-decimal": "^2.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/is-array-buffer": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.5.tgz", - "integrity": "sha512-DDfANUiiG2wC1qawP66qlTugJeL5HyzMpfr8lLK+jMQirGzNod0B12cFB/9q838Ru27sBwfw78/rdoU7RERz6A==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "call-bound": "^1.0.3", - "get-intrinsic": "^1.2.6" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-arrayish": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.3.2.tgz", - "integrity": "sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==", - "license": "MIT", - "optional": true - }, - "node_modules/is-async-function": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-async-function/-/is-async-function-2.1.1.tgz", - "integrity": "sha512-9dgM/cZBnNvjzaMYHVoxxfPj2QXt22Ev7SuuPrs+xav0ukGB0S6d4ydZdEiM48kLx5kDV+QBPrpVnFyefL8kkQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "async-function": "^1.0.0", - "call-bound": "^1.0.3", - "get-proto": "^1.0.1", - "has-tostringtag": "^1.0.2", - "safe-regex-test": "^1.1.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-bigint": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.1.0.tgz", - "integrity": "sha512-n4ZT37wG78iz03xPRKJrHTdZbe3IicyucEtdRsV5yglwc3GyUfbAfpSeD0FJ41NbUNSt5wbhqfp1fS+BgnvDFQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-bigints": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-boolean-object": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.2.2.tgz", - "integrity": "sha512-wa56o2/ElJMYqjCjGkXri7it5FbebW5usLw/nPmCMs5DeZ7eziSYZhSmPRn0txqeW4LnAmQQU7FgqLpsEFKM4A==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "has-tostringtag": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-bun-module": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-bun-module/-/is-bun-module-2.0.0.tgz", - "integrity": "sha512-gNCGbnnnnFAUGKeZ9PdbyeGYJqewpmc2aKHUEMO5nQPWU9lOmv7jcmQIv+qHD8fXW6W7qfuCwX4rY9LNRjXrkQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "semver": "^7.7.1" - } - }, - "node_modules/is-callable": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", - "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-core-module": { - "version": "2.16.1", - "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.16.1.tgz", - "integrity": "sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==", - "dev": true, - "license": "MIT", - "dependencies": { - "hasown": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-data-view": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-data-view/-/is-data-view-1.0.2.tgz", - "integrity": "sha512-RKtWF8pGmS87i2D6gqQu/l7EYRlVdfzemCJN/P3UOs//x1QE7mfhvzHIApBTRf7axvT6DMGwSwBXYCT0nfB9xw==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "get-intrinsic": "^1.2.6", - "is-typed-array": "^1.1.13" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-date-object": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.1.0.tgz", - "integrity": "sha512-PwwhEakHVKTdRNVOw+/Gyh0+MzlCl4R6qKvkhuvLtPMggI1WAHt9sOwZxQLSGpUaDnrdyDsomoRgNnCfKNSXXg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "has-tostringtag": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-decimal": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-decimal/-/is-decimal-2.0.1.tgz", - "integrity": "sha512-AAB9hiomQs5DXWcRB1rqsxGUstbRroFOPPVAomNk/3XHR5JyEZChOyTWe2oayKnsSsr/kcGqF+z6yuH6HHpN0A==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/is-docker": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-3.0.0.tgz", - "integrity": "sha512-eljcgEDlEns/7AXFosB5K/2nCM4P7FQPkGc/DWLy5rmFEWvZayGrik1d9/QIY5nJ4f9YsVvBkA6kJpHn9rISdQ==", - "license": "MIT", - "bin": { - "is-docker": "cli.js" - }, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/is-finalizationregistry": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-finalizationregistry/-/is-finalizationregistry-1.1.1.tgz", - "integrity": "sha512-1pC6N8qWJbWoPtEjgcL2xyhQOP491EQjeUo3qTKcmV8YSDDJrOepfG8pcC7h/QgnQHYSv0mJ3Z/ZWxmatVrysg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/is-generator-function": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-generator-function/-/is-generator-function-1.1.0.tgz", - "integrity": "sha512-nPUB5km40q9e8UfN/Zc24eLlzdSf9OfKByBw9CIdw4H1giPMeA0OIJvbchsCu4npfI2QcMVBsGEBHKZ7wLTWmQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "get-proto": "^1.0.0", - "has-tostringtag": "^1.0.2", - "safe-regex-test": "^1.1.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-glob": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", - "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", - "license": "MIT", - "dependencies": { - "is-extglob": "^2.1.1" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/is-hexadecimal": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-hexadecimal/-/is-hexadecimal-2.0.1.tgz", - "integrity": "sha512-DgZQp241c8oO6cA1SbTEWiXeoxV42vlcJxgH+B3hi1AiqqKruZR3ZGF8In3fj4+/y/7rHvlOZLZtgJ/4ttYGZg==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/is-inside-container": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-inside-container/-/is-inside-container-1.0.0.tgz", - "integrity": "sha512-KIYLCCJghfHZxqjYBE7rEy0OBuTd5xCHS7tHVgvCLkx7StIoaxwNW3hCALgEUjFfeRk+MG/Qxmp/vtETEF3tRA==", - "license": "MIT", - "dependencies": { - "is-docker": "^3.0.0" - }, - "bin": { - "is-inside-container": "cli.js" - }, - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/is-map": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.3.tgz", - "integrity": "sha512-1Qed0/Hr2m+YqxnM09CjA2d/i6YZNfF6R2oRAOj36eUdS6qIV/huPJNSEpKbupewFs+ZsJlxsjjPbc0/afW6Lw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "license": "MIT", - "engines": { - "node": ">=0.12.0" - } - }, - "node_modules/is-number-object": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.1.1.tgz", - "integrity": "sha512-lZhclumE1G6VYD8VHe35wFaIif+CTy5SJIi5+3y4psDgWu4wPDoBhF8NxUOinEc7pHgiTsT6MaBb92rKhhD+Xw==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "has-tostringtag": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-plain-obj": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-4.1.0.tgz", - "integrity": "sha512-+Pgi+vMuUNkJyExiMBt5IlFoMyKnr5zhJ4Uspz58WOhBF5QoIZkFyNHIbBAtHwzVAgk5RtndVNsDRN61/mmDqg==", - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/is-regex": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.2.1.tgz", - "integrity": "sha512-MjYsKHO5O7mCsmRGxWcLWheFqN9DJ/2TmngvjKXihe6efViPqc274+Fx/4fYj/r03+ESvBdTXK0V6tA3rgez1g==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "gopd": "^1.2.0", - "has-tostringtag": "^1.0.2", - "hasown": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-set": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.3.tgz", - "integrity": "sha512-iPAjerrse27/ygGLxw+EBR9agv9Y6uLeYVJMu+QNCoouJ1/1ri0mGrcWpfCqFZuzzx3WjtwxG098X+n4OuRkPg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-shared-array-buffer": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.4.tgz", - "integrity": "sha512-ISWac8drv4ZGfwKl5slpHG9OwPNty4jOWPRIhBpxOoD+hqITiwuipOQ2bNthAzwA3B4fIjO4Nln74N0S9byq8A==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-string": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.1.1.tgz", - "integrity": "sha512-BtEeSsoaQjlSPBemMQIrY1MY0uM6vnS1g5fmufYOtnxLGUZM2178PKbhsk7Ffv58IX+ZtcvoGwccYsh0PglkAA==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "has-tostringtag": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-symbol": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.1.1.tgz", - "integrity": "sha512-9gGx6GTtCQM73BgmHQXfDmLtfjjTUDSyoxTCbp5WtoixAhfgsDirWIcVQ/IHpvI5Vgd5i/J5F7B9cN/WlVbC/w==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "has-symbols": "^1.1.0", - "safe-regex-test": "^1.1.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-typed-array": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.15.tgz", - "integrity": "sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "which-typed-array": "^1.1.16" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-weakmap": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.2.tgz", - "integrity": "sha512-K5pXYOm9wqY1RgjpL3YTkF39tni1XajUIkawTLUo9EZEVUFga5gSQJF8nNS7ZwJQ02y+1YCNYcMh+HIf1ZqE+w==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-weakref": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.1.1.tgz", - "integrity": "sha512-6i9mGWSlqzNMEqpCp93KwRS1uUOodk2OJ6b+sq7ZPDSy2WuI5NFIxp/254TytR8ftefexkWn5xNiHUNpPOfSew==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-weakset": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.4.tgz", - "integrity": "sha512-mfcwb6IzQyOKTs84CQMrOwW4gQcaTOAWJ0zzJCl2WSPDrWk/OzDaImWFH3djXhb24g4eudZfLRozAvPGw4d9hQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "get-intrinsic": "^1.2.6" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-wsl": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-3.1.0.tgz", - "integrity": "sha512-UcVfVfaK4Sc4m7X3dUSoHoozQGBEFeDC+zVo06t98xe8CzHSZZBekNXH+tu0NalHolcJ/QAGqS46Hef7QXBIMw==", - "license": "MIT", - "dependencies": { - "is-inside-container": "^1.0.0" - }, - "engines": { - "node": ">=16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "dev": true, - "license": "MIT" - }, - "node_modules/isexe": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", - "dev": true, - "license": "ISC" - }, - "node_modules/javascript-time-ago": { - "version": "2.5.11", - "resolved": "https://registry.npmjs.org/javascript-time-ago/-/javascript-time-ago-2.5.11.tgz", - "integrity": "sha512-Zeyf5R7oM1fSMW9zsU3YgAYwE0bimEeF54Udn2ixGd8PUwu+z1Yc5t4Y8YScJDMHD6uCx6giLt3VJR5K4CMwbg==", - "license": "MIT", - "dependencies": { - "relative-time-format": "^1.1.6" - } - }, - "node_modules/jiti": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/jiti/-/jiti-2.4.2.tgz", - "integrity": "sha512-rg9zJN+G4n2nfJl5MW3BMygZX56zKPNVEYYqq7adpmMh4Jn2QNEwhvQlFy6jPVdcod7txZtKHWnyZiA3a0zP7A==", - "license": "MIT", - "bin": { - "jiti": "lib/jiti-cli.mjs" - } - }, - "node_modules/js-base64": { - "version": "3.7.7", - "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.7.tgz", - "integrity": "sha512-7rCnleh0z2CkXhH67J8K1Ytz0b2Y+yxTPL+/KOJoa20hfnVQ/3/T6W/KflYI4bRHRagNeXeU2bkNGI3v1oS/lw==", - "license": "BSD-3-Clause" - }, - "node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "license": "MIT", - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/json-buffer": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", - "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "dev": true, - "license": "MIT" - }, - "node_modules/json-stable-stringify-without-jsonify": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", - "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", - "dev": true, - "license": "MIT" - }, - "node_modules/json5": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz", - "integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==", - "dev": true, - "license": "MIT", - "dependencies": { - "minimist": "^1.2.0" - }, - "bin": { - "json5": "lib/cli.js" - } - }, - "node_modules/jsonc-parser": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-2.3.1.tgz", - "integrity": "sha512-H8jvkz1O50L3dMZCsLqiuB2tA7muqbSg1AtGEkN0leAqGjsUzDJir3Zwr02BhqdcITPg3ei3mZ+HjMocAknhhg==", - "license": "MIT" - }, - "node_modules/jsx-ast-utils": { - "version": "3.3.5", - "resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-3.3.5.tgz", - "integrity": "sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "array-includes": "^3.1.6", - "array.prototype.flat": "^1.3.1", - "object.assign": "^4.1.4", - "object.values": "^1.1.6" - }, - "engines": { - "node": ">=4.0" - } - }, - "node_modules/keyv": { - "version": "4.5.4", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", - "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", - "dev": true, - "license": "MIT", - "dependencies": { - "json-buffer": "3.0.1" - } - }, - "node_modules/kleur": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.5.tgz", - "integrity": "sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/kolorist": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/kolorist/-/kolorist-1.8.0.tgz", - "integrity": "sha512-Y+60/zizpJ3HRH8DCss+q95yr6145JXZo46OTpFvDZWLfRCE4qChOyk1b26nMaNpfHHgxagk9dXT5OP0Tfe+dQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/language-subtag-registry": { - "version": "0.3.23", - "resolved": "https://registry.npmjs.org/language-subtag-registry/-/language-subtag-registry-0.3.23.tgz", - "integrity": "sha512-0K65Lea881pHotoGEa5gDlMxt3pctLi2RplBb7Ezh4rRdLEOtgi7n4EwK9lamnUCkKBqaeKRVebTq6BAxSkpXQ==", - "dev": true, - "license": "CC0-1.0" - }, - "node_modules/language-tags": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/language-tags/-/language-tags-1.0.9.tgz", - "integrity": "sha512-MbjN408fEndfiQXbFQ1vnd+1NoLDsnQW41410oQBXiyXDMYH5z505juWa4KUE1LqxRC7DgOgZDbKLxHIwm27hA==", - "dev": true, - "license": "MIT", - "dependencies": { - "language-subtag-registry": "^0.3.20" - }, - "engines": { - "node": ">=0.10" - } - }, - "node_modules/levn": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", - "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "prelude-ls": "^1.2.1", - "type-check": "~0.4.0" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/libphonenumber-js": { - "version": "1.12.8", - "resolved": "https://registry.npmjs.org/libphonenumber-js/-/libphonenumber-js-1.12.8.tgz", - "integrity": "sha512-f1KakiQJa9tdc7w1phC2ST+DyxWimy9c3g3yeF+84QtEanJr2K77wAmBPP22riU05xldniHsvXuflnLZ4oysqA==", - "license": "MIT" - }, - "node_modules/libsql": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/libsql/-/libsql-0.5.4.tgz", - "integrity": "sha512-GEFeWca4SDAQFxjHWJBE6GK52LEtSskiujbG3rqmmeTO9t4sfSBKIURNLLpKDDF7fb7jmTuuRkDAn9BZGITQNw==", - "cpu": [ - "x64", - "arm64", - "wasm32" - ], - "license": "MIT", - "os": [ - "darwin", - "linux", - "win32" - ], - "dependencies": { - "@neon-rs/load": "^0.0.4", - "detect-libc": "2.0.2" - }, - "optionalDependencies": { - "@libsql/darwin-arm64": "0.5.4", - "@libsql/darwin-x64": "0.5.4", - "@libsql/linux-arm64-gnu": "0.5.4", - "@libsql/linux-arm64-musl": "0.5.4", - "@libsql/linux-x64-gnu": "0.5.4", - "@libsql/linux-x64-musl": "0.5.4", - "@libsql/win32-x64-msvc": "0.5.4" - } - }, - "node_modules/libsql/node_modules/detect-libc": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.2.tgz", - "integrity": "sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw==", - "license": "Apache-2.0", - "engines": { - "node": ">=8" - } - }, - "node_modules/lightningcss": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.30.1.tgz", - "integrity": "sha512-xi6IyHML+c9+Q3W0S4fCQJOym42pyurFiJUHEcEyHS0CeKzia4yZDEsLlqOFykxOdHpNy0NmvVO31vcSqAxJCg==", - "license": "MPL-2.0", - "dependencies": { - "detect-libc": "^2.0.3" - }, - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - }, - "optionalDependencies": { - "lightningcss-darwin-arm64": "1.30.1", - "lightningcss-darwin-x64": "1.30.1", - "lightningcss-freebsd-x64": "1.30.1", - "lightningcss-linux-arm-gnueabihf": "1.30.1", - "lightningcss-linux-arm64-gnu": "1.30.1", - "lightningcss-linux-arm64-musl": "1.30.1", - "lightningcss-linux-x64-gnu": "1.30.1", - "lightningcss-linux-x64-musl": "1.30.1", - "lightningcss-win32-arm64-msvc": "1.30.1", - "lightningcss-win32-x64-msvc": "1.30.1" - } - }, - "node_modules/lightningcss-darwin-arm64": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.30.1.tgz", - "integrity": "sha512-c8JK7hyE65X1MHMN+Viq9n11RRC7hgin3HhYKhrMyaXflk5GVplZ60IxyoVtzILeKr+xAJwg6zK6sjTBJ0FKYQ==", - "cpu": [ - "arm64" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/lightningcss-darwin-x64": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.30.1.tgz", - "integrity": "sha512-k1EvjakfumAQoTfcXUcHQZhSpLlkAuEkdMBsI/ivWw9hL+7FtilQc0Cy3hrx0AAQrVtQAbMI7YjCgYgvn37PzA==", - "cpu": [ - "x64" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/lightningcss-freebsd-x64": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-freebsd-x64/-/lightningcss-freebsd-x64-1.30.1.tgz", - "integrity": "sha512-kmW6UGCGg2PcyUE59K5r0kWfKPAVy4SltVeut+umLCFoJ53RdCUWxcRDzO1eTaxf/7Q2H7LTquFHPL5R+Gjyig==", - "cpu": [ - "x64" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "freebsd" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/lightningcss-linux-arm-gnueabihf": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.30.1.tgz", - "integrity": "sha512-MjxUShl1v8pit+6D/zSPq9S9dQ2NPFSQwGvxBCYaBYLPlCWuPh9/t1MRS8iUaR8i+a6w7aps+B4N0S1TYP/R+Q==", - "cpu": [ - "arm" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/lightningcss-linux-arm64-gnu": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.30.1.tgz", - "integrity": "sha512-gB72maP8rmrKsnKYy8XUuXi/4OctJiuQjcuqWNlJQ6jZiWqtPvqFziskH3hnajfvKB27ynbVCucKSm2rkQp4Bw==", - "cpu": [ - "arm64" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/lightningcss-linux-arm64-musl": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.30.1.tgz", - "integrity": "sha512-jmUQVx4331m6LIX+0wUhBbmMX7TCfjF5FoOH6SD1CttzuYlGNVpA7QnrmLxrsub43ClTINfGSYyHe2HWeLl5CQ==", - "cpu": [ - "arm64" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/lightningcss-linux-x64-gnu": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.30.1.tgz", - "integrity": "sha512-piWx3z4wN8J8z3+O5kO74+yr6ze/dKmPnI7vLqfSqI8bccaTGY5xiSGVIJBDd5K5BHlvVLpUB3S2YCfelyJ1bw==", - "cpu": [ - "x64" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/lightningcss-linux-x64-musl": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.30.1.tgz", - "integrity": "sha512-rRomAK7eIkL+tHY0YPxbc5Dra2gXlI63HL+v1Pdi1a3sC+tJTcFrHX+E86sulgAXeI7rSzDYhPSeHHjqFhqfeQ==", - "cpu": [ - "x64" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/lightningcss-win32-arm64-msvc": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-win32-arm64-msvc/-/lightningcss-win32-arm64-msvc-1.30.1.tgz", - "integrity": "sha512-mSL4rqPi4iXq5YVqzSsJgMVFENoa4nGTT/GjO2c0Yl9OuQfPsIfncvLrEW6RbbB24WtZ3xP/2CCmI3tNkNV4oA==", - "cpu": [ - "arm64" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/lightningcss-win32-x64-msvc": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.30.1.tgz", - "integrity": "sha512-PVqXh48wh4T53F/1CCu8PIPCxLzWyCnn/9T5W1Jpmdy5h9Cwd+0YQS6/LwhHXSafuc61/xg9Lv5OrCby6a++jg==", - "cpu": [ - "x64" - ], - "license": "MPL-2.0", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">= 12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/parcel" - } - }, - "node_modules/linebreak": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/linebreak/-/linebreak-1.1.0.tgz", - "integrity": "sha512-MHp03UImeVhB7XZtjd0E4n6+3xr5Dq/9xI/5FptGk5FrbDR3zagPa2DS6U8ks/3HjbKWG9Q1M2ufOzxV2qLYSQ==", - "license": "MIT", - "dependencies": { - "base64-js": "0.0.8", - "unicode-trie": "^2.0.0" - } - }, - "node_modules/linebreak/node_modules/base64-js": { - "version": "0.0.8", - "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-0.0.8.tgz", - "integrity": "sha512-3XSA2cR/h/73EzlXXdU6YNycmYI7+kicTxks4eJg2g39biHR84slg2+des+p7iHYhbRg/udIS4TD53WabcOUkw==", - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/local-pkg": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/local-pkg/-/local-pkg-0.5.1.tgz", - "integrity": "sha512-9rrA30MRRP3gBD3HTGnC6cDFpaE1kVDWxWgqWJUN0RvDNAo+Nz/9GxB+nHOH0ifbVFy0hSA1V6vFDvnx54lTEQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "mlly": "^1.7.3", - "pkg-types": "^1.2.1" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/sponsors/antfu" - } - }, - "node_modules/locate-path": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", - "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", - "dev": true, - "license": "MIT", - "dependencies": { - "p-locate": "^5.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/lodash": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", - "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", - "license": "MIT" - }, - "node_modules/lodash-es": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/lodash-es/-/lodash-es-4.17.21.tgz", - "integrity": "sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw==", - "license": "MIT" - }, - "node_modules/lodash.castarray": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/lodash.castarray/-/lodash.castarray-4.4.0.tgz", - "integrity": "sha512-aVx8ztPv7/2ULbArGJ2Y42bG1mEQ5mGjpdvrbJcJFU3TbYybe+QlLS4pst9zV52ymy2in1KpFPiZnAOATxD4+Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/lodash.isplainobject": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz", - "integrity": "sha512-oSXzaWypCMHkPC3NvBEaPHf0KsA5mvPrOPgQWDsbg8n7orZ290M0BmC/jgRZ4vcJ6DTAhjrsSYgdsW/F+MFOBA==", - "dev": true, - "license": "MIT" - }, - "node_modules/lodash.merge": { - "version": "4.6.2", - "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", - "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/longest-streak": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/longest-streak/-/longest-streak-3.1.0.tgz", - "integrity": "sha512-9Ri+o0JYgehTaVBBDoMqIl8GXtbWg711O3srftcHhZ0dqnETqLaoIK0x17fUw9rFSlK/0NlsKe0Ahhyl5pXE2g==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/lru-cache": { - "version": "10.4.3", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", - "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", - "license": "ISC" - }, - "node_modules/magic-string": { - "version": "0.30.17", - "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.17.tgz", - "integrity": "sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA==", - "license": "MIT", - "dependencies": { - "@jridgewell/sourcemap-codec": "^1.5.0" - } - }, - "node_modules/magicast": { - "version": "0.3.5", - "resolved": "https://registry.npmjs.org/magicast/-/magicast-0.3.5.tgz", - "integrity": "sha512-L0WhttDl+2BOsybvEOLK7fW3UA0OQ0IQ2d6Zl2x/a6vVRs3bAY0ECOSHHeL5jD+SbOpOCUEi0y1DgHEn9Qn1AQ==", - "license": "MIT", - "dependencies": { - "@babel/parser": "^7.25.4", - "@babel/types": "^7.25.4", - "source-map-js": "^1.2.0" - } - }, - "node_modules/markdown-extensions": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/markdown-extensions/-/markdown-extensions-2.0.0.tgz", - "integrity": "sha512-o5vL7aDWatOTX8LzaS1WMoaoxIiLRQJuIKKe2wAw6IeULDHaqbiqiggmx+pKvZDb1Sj+pE46Sn1T7lCqfFtg1Q==", - "license": "MIT", - "engines": { - "node": ">=16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/markdown-table": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/markdown-table/-/markdown-table-3.0.4.tgz", - "integrity": "sha512-wiYz4+JrLyb/DqW2hkFJxP7Vd7JuTDm77fvbM8VfEQdmSMqcImWeeRbHwZjBjIFki/VaMK2BhFi7oUUZeM5bqw==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/marked": { - "version": "12.0.2", - "resolved": "https://registry.npmjs.org/marked/-/marked-12.0.2.tgz", - "integrity": "sha512-qXUm7e/YKFoqFPYPa3Ukg9xlI5cyAtGmyEIzMfW//m6kXwCy2Ps9DYf5ioijFKQ8qyuscrHoY04iJGctu2Kg0Q==", - "license": "MIT", - "bin": { - "marked": "bin/marked.js" - }, - "engines": { - "node": ">= 18" - } - }, - "node_modules/marked-footnote": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/marked-footnote/-/marked-footnote-1.2.4.tgz", - "integrity": "sha512-DB2Kl+wFh6YwZd70qABMY6WUkG1UuyqoNTFoDfGyG79Pz24neYtLBkB+45a7o72V7gkfvbC3CGzIYFobxfMT1Q==", - "license": "MIT", - "peerDependencies": { - "marked": ">=7.0.0" - } - }, - "node_modules/marked-smartypants": { - "version": "1.1.9", - "resolved": "https://registry.npmjs.org/marked-smartypants/-/marked-smartypants-1.1.9.tgz", - "integrity": "sha512-VPeuaUr5IWptI7nJdgQ9ugrLWYGv13NdzEXTtKY3cmB4aRWOI2RzhLlf+xQp6Wnob9SAPO2sNVlfSJr+nflk/A==", - "license": "MIT", - "dependencies": { - "smartypants": "^0.2.2" - }, - "peerDependencies": { - "marked": ">=4 <16" - } - }, - "node_modules/math-intrinsics": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", - "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/mdast-util-definitions": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-definitions/-/mdast-util-definitions-6.0.0.tgz", - "integrity": "sha512-scTllyX6pnYNZH/AIp/0ePz6s4cZtARxImwoPJ7kS42n+MnVsI4XbnG6d4ibehRIldYMWM2LD7ImQblVhUejVQ==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "@types/unist": "^3.0.0", - "unist-util-visit": "^5.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-find-and-replace": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/mdast-util-find-and-replace/-/mdast-util-find-and-replace-3.0.2.tgz", - "integrity": "sha512-Tmd1Vg/m3Xz43afeNxDIhWRtFZgM2VLyaf4vSTYwudTyeuTneoL3qtWMA5jeLyz/O1vDJmmV4QuScFCA2tBPwg==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "escape-string-regexp": "^5.0.0", - "unist-util-is": "^6.0.0", - "unist-util-visit-parents": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-from-markdown": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/mdast-util-from-markdown/-/mdast-util-from-markdown-2.0.2.tgz", - "integrity": "sha512-uZhTV/8NBuw0WHkPTrCqDOl0zVe1BIng5ZtHoDk49ME1qqcjYmmLmOf0gELgcRMxN4w2iuIeVso5/6QymSrgmA==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "@types/unist": "^3.0.0", - "decode-named-character-reference": "^1.0.0", - "devlop": "^1.0.0", - "mdast-util-to-string": "^4.0.0", - "micromark": "^4.0.0", - "micromark-util-decode-numeric-character-reference": "^2.0.0", - "micromark-util-decode-string": "^2.0.0", - "micromark-util-normalize-identifier": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0", - "unist-util-stringify-position": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm/-/mdast-util-gfm-3.1.0.tgz", - "integrity": "sha512-0ulfdQOM3ysHhCJ1p06l0b0VKlhU0wuQs3thxZQagjcjPrlFRqY215uZGHHJan9GEAXd9MbfPjFJz+qMkVR6zQ==", - "license": "MIT", - "dependencies": { - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-gfm-autolink-literal": "^2.0.0", - "mdast-util-gfm-footnote": "^2.0.0", - "mdast-util-gfm-strikethrough": "^2.0.0", - "mdast-util-gfm-table": "^2.0.0", - "mdast-util-gfm-task-list-item": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-autolink-literal": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-autolink-literal/-/mdast-util-gfm-autolink-literal-2.0.1.tgz", - "integrity": "sha512-5HVP2MKaP6L+G6YaxPNjuL0BPrq9orG3TsrZ9YXbA3vDw/ACI4MEsnoDpn6ZNm7GnZgtAcONJyPhOP8tNJQavQ==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "ccount": "^2.0.0", - "devlop": "^1.0.0", - "mdast-util-find-and-replace": "^3.0.0", - "micromark-util-character": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-footnote": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-footnote/-/mdast-util-gfm-footnote-2.1.0.tgz", - "integrity": "sha512-sqpDWlsHn7Ac9GNZQMeUzPQSMzR6Wv0WKRNvQRg0KqHh02fpTz69Qc1QSseNX29bhz1ROIyNyxExfawVKTm1GQ==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "devlop": "^1.1.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0", - "micromark-util-normalize-identifier": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-strikethrough": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-strikethrough/-/mdast-util-gfm-strikethrough-2.0.0.tgz", - "integrity": "sha512-mKKb915TF+OC5ptj5bJ7WFRPdYtuHv0yTRxK2tJvi+BDqbkiG7h7u/9SI89nRAYcmap2xHQL9D+QG/6wSrTtXg==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-table": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-table/-/mdast-util-gfm-table-2.0.0.tgz", - "integrity": "sha512-78UEvebzz/rJIxLvE7ZtDd/vIQ0RHv+3Mh5DR96p7cS7HsBhYIICDBCu8csTNWNO6tBWfqXPWekRuj2FNOGOZg==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "devlop": "^1.0.0", - "markdown-table": "^3.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-gfm-task-list-item": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-task-list-item/-/mdast-util-gfm-task-list-item-2.0.0.tgz", - "integrity": "sha512-IrtvNvjxC1o06taBAVJznEnkiHxLFTzgonUdy8hzFVeDun0uTjxxrRGVaNFqkU1wJR3RBPEfsxmU6jDWPofrTQ==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "devlop": "^1.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-mdx": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-mdx/-/mdast-util-mdx-3.0.0.tgz", - "integrity": "sha512-JfbYLAW7XnYTTbUsmpu0kdBUVe+yKVJZBItEjwyYJiDJuZ9w4eeaqks4HQO+R7objWgS2ymV60GYpI14Ug554w==", - "license": "MIT", - "dependencies": { - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-mdx-expression": "^2.0.0", - "mdast-util-mdx-jsx": "^3.0.0", - "mdast-util-mdxjs-esm": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-mdx-expression": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/mdast-util-mdx-expression/-/mdast-util-mdx-expression-2.0.1.tgz", - "integrity": "sha512-J6f+9hUp+ldTZqKRSg7Vw5V6MqjATc+3E4gf3CFNcuZNWD8XdyI6zQ8GqH7f8169MM6P7hMBRDVGnn7oHB9kXQ==", - "license": "MIT", - "dependencies": { - "@types/estree-jsx": "^1.0.0", - "@types/hast": "^3.0.0", - "@types/mdast": "^4.0.0", - "devlop": "^1.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-mdx-jsx": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/mdast-util-mdx-jsx/-/mdast-util-mdx-jsx-3.2.0.tgz", - "integrity": "sha512-lj/z8v0r6ZtsN/cGNNtemmmfoLAFZnjMbNyLzBafjzikOM+glrjNHPlf6lQDOTccj9n5b0PPihEBbhneMyGs1Q==", - "license": "MIT", - "dependencies": { - "@types/estree-jsx": "^1.0.0", - "@types/hast": "^3.0.0", - "@types/mdast": "^4.0.0", - "@types/unist": "^3.0.0", - "ccount": "^2.0.0", - "devlop": "^1.1.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0", - "parse-entities": "^4.0.0", - "stringify-entities": "^4.0.0", - "unist-util-stringify-position": "^4.0.0", - "vfile-message": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-mdxjs-esm": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/mdast-util-mdxjs-esm/-/mdast-util-mdxjs-esm-2.0.1.tgz", - "integrity": "sha512-EcmOpxsZ96CvlP03NghtH1EsLtr0n9Tm4lPUJUBccV9RwUOneqSycg19n5HGzCf+10LozMRSObtVr3ee1WoHtg==", - "license": "MIT", - "dependencies": { - "@types/estree-jsx": "^1.0.0", - "@types/hast": "^3.0.0", - "@types/mdast": "^4.0.0", - "devlop": "^1.0.0", - "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-phrasing": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/mdast-util-phrasing/-/mdast-util-phrasing-4.1.0.tgz", - "integrity": "sha512-TqICwyvJJpBwvGAMZjj4J2n0X8QWp21b9l0o7eXyVJ25YNWYbJDVIyD1bZXE6WtV6RmKJVYmQAKWa0zWOABz2w==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "unist-util-is": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-to-hast": { - "version": "13.2.0", - "resolved": "https://registry.npmjs.org/mdast-util-to-hast/-/mdast-util-to-hast-13.2.0.tgz", - "integrity": "sha512-QGYKEuUsYT9ykKBCMOEDLsU5JRObWQusAolFMeko/tYPufNkRffBAQjIE+99jbA87xv6FgmjLtwjh9wBWajwAA==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "@types/mdast": "^4.0.0", - "@ungap/structured-clone": "^1.0.0", - "devlop": "^1.0.0", - "micromark-util-sanitize-uri": "^2.0.0", - "trim-lines": "^3.0.0", - "unist-util-position": "^5.0.0", - "unist-util-visit": "^5.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-to-markdown": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/mdast-util-to-markdown/-/mdast-util-to-markdown-2.1.2.tgz", - "integrity": "sha512-xj68wMTvGXVOKonmog6LwyJKrYXZPvlwabaryTjLh9LuvovB/KAH+kvi8Gjj+7rJjsFi23nkUxRQv1KqSroMqA==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "@types/unist": "^3.0.0", - "longest-streak": "^3.0.0", - "mdast-util-phrasing": "^4.0.0", - "mdast-util-to-string": "^4.0.0", - "micromark-util-classify-character": "^2.0.0", - "micromark-util-decode-string": "^2.0.0", - "unist-util-visit": "^5.0.0", - "zwitch": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-to-string": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-to-string/-/mdast-util-to-string-4.0.0.tgz", - "integrity": "sha512-0H44vDimn51F0YwvxSJSm0eCDOJTRlmN0R1yBh4HLj9wiV1Dn0QoXGbvFAWj2hSItVTlCmBF1hqKlIyUBVFLPg==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdn-data": { - "version": "2.0.30", - "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.30.tgz", - "integrity": "sha512-GaqWWShW4kv/G9IEucWScBx9G1/vsFZZJUO+tD26M8J8z3Kw5RDQjaoZe03YAClgeS/SWPOcb4nkFBTEi5DUEA==", - "dev": true, - "license": "CC0-1.0" - }, - "node_modules/merge2": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", - "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", - "license": "MIT", - "engines": { - "node": ">= 8" - } - }, - "node_modules/micromark": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/micromark/-/micromark-4.0.2.tgz", - "integrity": "sha512-zpe98Q6kvavpCr1NPVSCMebCKfD7CA2NqZ+rykeNhONIJBpc1tFKt9hucLGwha3jNTNI8lHpctWJWoimVF4PfA==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "@types/debug": "^4.0.0", - "debug": "^4.0.0", - "decode-named-character-reference": "^1.0.0", - "devlop": "^1.0.0", - "micromark-core-commonmark": "^2.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-chunked": "^2.0.0", - "micromark-util-combine-extensions": "^2.0.0", - "micromark-util-decode-numeric-character-reference": "^2.0.0", - "micromark-util-encode": "^2.0.0", - "micromark-util-normalize-identifier": "^2.0.0", - "micromark-util-resolve-all": "^2.0.0", - "micromark-util-sanitize-uri": "^2.0.0", - "micromark-util-subtokenize": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-core-commonmark": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/micromark-core-commonmark/-/micromark-core-commonmark-2.0.3.tgz", - "integrity": "sha512-RDBrHEMSxVFLg6xvnXmb1Ayr2WzLAWjeSATAoxwKYJV94TeNavgoIdA0a9ytzDSVzBy2YKFK+emCPOEibLeCrg==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "decode-named-character-reference": "^1.0.0", - "devlop": "^1.0.0", - "micromark-factory-destination": "^2.0.0", - "micromark-factory-label": "^2.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-factory-title": "^2.0.0", - "micromark-factory-whitespace": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-chunked": "^2.0.0", - "micromark-util-classify-character": "^2.0.0", - "micromark-util-html-tag-name": "^2.0.0", - "micromark-util-normalize-identifier": "^2.0.0", - "micromark-util-resolve-all": "^2.0.0", - "micromark-util-subtokenize": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-extension-gfm": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm/-/micromark-extension-gfm-3.0.0.tgz", - "integrity": "sha512-vsKArQsicm7t0z2GugkCKtZehqUm31oeGBV/KVSorWSy8ZlNAv7ytjFhvaryUiCUJYqs+NoE6AFhpQvBTM6Q4w==", - "license": "MIT", - "dependencies": { - "micromark-extension-gfm-autolink-literal": "^2.0.0", - "micromark-extension-gfm-footnote": "^2.0.0", - "micromark-extension-gfm-strikethrough": "^2.0.0", - "micromark-extension-gfm-table": "^2.0.0", - "micromark-extension-gfm-tagfilter": "^2.0.0", - "micromark-extension-gfm-task-list-item": "^2.0.0", - "micromark-util-combine-extensions": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-autolink-literal": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-autolink-literal/-/micromark-extension-gfm-autolink-literal-2.1.0.tgz", - "integrity": "sha512-oOg7knzhicgQ3t4QCjCWgTmfNhvQbDDnJeVu9v81r7NltNCVmhPy1fJRX27pISafdjL+SVc4d3l48Gb6pbRypw==", - "license": "MIT", - "dependencies": { - "micromark-util-character": "^2.0.0", - "micromark-util-sanitize-uri": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-footnote": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-footnote/-/micromark-extension-gfm-footnote-2.1.0.tgz", - "integrity": "sha512-/yPhxI1ntnDNsiHtzLKYnE3vf9JZ6cAisqVDauhp4CEHxlb4uoOTxOCJ+9s51bIB8U1N1FJ1RXOKTIlD5B/gqw==", - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-core-commonmark": "^2.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-normalize-identifier": "^2.0.0", - "micromark-util-sanitize-uri": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-strikethrough": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-strikethrough/-/micromark-extension-gfm-strikethrough-2.1.0.tgz", - "integrity": "sha512-ADVjpOOkjz1hhkZLlBiYA9cR2Anf8F4HqZUO6e5eDcPQd0Txw5fxLzzxnEkSkfnD0wziSGiv7sYhk/ktvbf1uw==", - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-util-chunked": "^2.0.0", - "micromark-util-classify-character": "^2.0.0", - "micromark-util-resolve-all": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-table": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-table/-/micromark-extension-gfm-table-2.1.1.tgz", - "integrity": "sha512-t2OU/dXXioARrC6yWfJ4hqB7rct14e8f7m0cbI5hUmDyyIlwv5vEtooptH8INkbLzOatzKuVbQmAYcbWoyz6Dg==", - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-tagfilter": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-tagfilter/-/micromark-extension-gfm-tagfilter-2.0.0.tgz", - "integrity": "sha512-xHlTOmuCSotIA8TW1mDIM6X2O1SiX5P9IuDtqGonFhEK0qgRI4yeC6vMxEV2dgyr2TiD+2PQ10o+cOhdVAcwfg==", - "license": "MIT", - "dependencies": { - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-gfm-task-list-item": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-task-list-item/-/micromark-extension-gfm-task-list-item-2.1.0.tgz", - "integrity": "sha512-qIBZhqxqI6fjLDYFTBIa4eivDMnP+OZqsNwmQ3xNLE4Cxwc+zfQEfbs6tzAo2Hjq+bh6q5F+Z8/cksrLFYWQQw==", - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-mdx-expression": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/micromark-extension-mdx-expression/-/micromark-extension-mdx-expression-3.0.1.tgz", - "integrity": "sha512-dD/ADLJ1AeMvSAKBwO22zG22N4ybhe7kFIZ3LsDI0GlsNr2A3KYxb0LdC1u5rj4Nw+CHKY0RVdnHX8vj8ejm4Q==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "devlop": "^1.0.0", - "micromark-factory-mdx-expression": "^2.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-events-to-acorn": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-extension-mdx-jsx": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/micromark-extension-mdx-jsx/-/micromark-extension-mdx-jsx-3.0.2.tgz", - "integrity": "sha512-e5+q1DjMh62LZAJOnDraSSbDMvGJ8x3cbjygy2qFEi7HCeUT4BDKCvMozPozcD6WmOt6sVvYDNBKhFSz3kjOVQ==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "devlop": "^1.0.0", - "estree-util-is-identifier-name": "^3.0.0", - "micromark-factory-mdx-expression": "^2.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-events-to-acorn": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0", - "vfile-message": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-mdx-md": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/micromark-extension-mdx-md/-/micromark-extension-mdx-md-2.0.0.tgz", - "integrity": "sha512-EpAiszsB3blw4Rpba7xTOUptcFeBFi+6PY8VnJ2hhimH+vCQDirWgsMpz7w1XcZE7LVrSAUGb9VJpG9ghlYvYQ==", - "license": "MIT", - "dependencies": { - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-mdxjs": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/micromark-extension-mdxjs/-/micromark-extension-mdxjs-3.0.0.tgz", - "integrity": "sha512-A873fJfhnJ2siZyUrJ31l34Uqwy4xIFmvPY1oj+Ean5PHcPBYzEsvqvWGaWcfEIr11O5Dlw3p2y0tZWpKHDejQ==", - "license": "MIT", - "dependencies": { - "acorn": "^8.0.0", - "acorn-jsx": "^5.0.0", - "micromark-extension-mdx-expression": "^3.0.0", - "micromark-extension-mdx-jsx": "^3.0.0", - "micromark-extension-mdx-md": "^2.0.0", - "micromark-extension-mdxjs-esm": "^3.0.0", - "micromark-util-combine-extensions": "^2.0.0", - "micromark-util-types": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-extension-mdxjs-esm": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/micromark-extension-mdxjs-esm/-/micromark-extension-mdxjs-esm-3.0.0.tgz", - "integrity": "sha512-DJFl4ZqkErRpq/dAPyeWp15tGrcrrJho1hKK5uBS70BCtfrIFg81sqcTVu3Ta+KD1Tk5vAtBNElWxtAa+m8K9A==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "devlop": "^1.0.0", - "micromark-core-commonmark": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-events-to-acorn": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0", - "unist-util-position-from-estree": "^2.0.0", - "vfile-message": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/micromark-factory-destination": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-factory-destination/-/micromark-factory-destination-2.0.1.tgz", - "integrity": "sha512-Xe6rDdJlkmbFRExpTOmRj9N3MaWmbAgdpSrBQvCFqhezUn4AHqJHbaEnfbVYYiexVSs//tqOdY/DxhjdCiJnIA==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-factory-label": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-factory-label/-/micromark-factory-label-2.0.1.tgz", - "integrity": "sha512-VFMekyQExqIW7xIChcXn4ok29YE3rnuyveW3wZQWWqF4Nv9Wk5rgJ99KzPvHjkmPXF93FXIbBp6YdW3t71/7Vg==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-factory-mdx-expression": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/micromark-factory-mdx-expression/-/micromark-factory-mdx-expression-2.0.3.tgz", - "integrity": "sha512-kQnEtA3vzucU2BkrIa8/VaSAsP+EJ3CKOvhMuJgOEGg9KDC6OAY6nSnNDVRiVNRqj7Y4SlSzcStaH/5jge8JdQ==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "devlop": "^1.0.0", - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-events-to-acorn": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0", - "unist-util-position-from-estree": "^2.0.0", - "vfile-message": "^4.0.0" - } - }, - "node_modules/micromark-factory-space": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-factory-space/-/micromark-factory-space-2.0.1.tgz", - "integrity": "sha512-zRkxjtBxxLd2Sc0d+fbnEunsTj46SWXgXciZmHq0kDYGnck/ZSGj9/wULTV95uoeYiK5hRXP2mJ98Uo4cq/LQg==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-character": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-factory-title": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-factory-title/-/micromark-factory-title-2.0.1.tgz", - "integrity": "sha512-5bZ+3CjhAd9eChYTHsjy6TGxpOFSKgKKJPJxr293jTbfry2KDoWkhBb6TcPVB4NmzaPhMs1Frm9AZH7OD4Cjzw==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-factory-whitespace": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-factory-whitespace/-/micromark-factory-whitespace-2.0.1.tgz", - "integrity": "sha512-Ob0nuZ3PKt/n0hORHyvoD9uZhr+Za8sFoP+OnMcnWK5lngSzALgQYKMr9RJVOWLqQYuyn6ulqGWSXdwf6F80lQ==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-factory-space": "^2.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-util-character": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/micromark-util-character/-/micromark-util-character-2.1.1.tgz", - "integrity": "sha512-wv8tdUTJ3thSFFFJKtpYKOYiGP2+v96Hvk4Tu8KpCAsTMs6yi+nVmGh1syvSCsaxz45J6Jbw+9DD6g97+NV67Q==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-util-chunked": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-chunked/-/micromark-util-chunked-2.0.1.tgz", - "integrity": "sha512-QUNFEOPELfmvv+4xiNg2sRYeS/P84pTW0TCgP5zc9FpXetHY0ab7SxKyAQCNCc1eK0459uoLI1y5oO5Vc1dbhA==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-symbol": "^2.0.0" - } - }, - "node_modules/micromark-util-classify-character": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-classify-character/-/micromark-util-classify-character-2.0.1.tgz", - "integrity": "sha512-K0kHzM6afW/MbeWYWLjoHQv1sgg2Q9EccHEDzSkxiP/EaagNzCm7T/WMKZ3rjMbvIpvBiZgwR3dKMygtA4mG1Q==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-character": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-util-combine-extensions": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-combine-extensions/-/micromark-util-combine-extensions-2.0.1.tgz", - "integrity": "sha512-OnAnH8Ujmy59JcyZw8JSbK9cGpdVY44NKgSM7E9Eh7DiLS2E9RNQf0dONaGDzEG9yjEl5hcqeIsj4hfRkLH/Bg==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-chunked": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-util-decode-numeric-character-reference": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/micromark-util-decode-numeric-character-reference/-/micromark-util-decode-numeric-character-reference-2.0.2.tgz", - "integrity": "sha512-ccUbYk6CwVdkmCQMyr64dXz42EfHGkPQlBj5p7YVGzq8I7CtjXZJrubAYezf7Rp+bjPseiROqe7G6foFd+lEuw==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-symbol": "^2.0.0" - } - }, - "node_modules/micromark-util-decode-string": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-decode-string/-/micromark-util-decode-string-2.0.1.tgz", - "integrity": "sha512-nDV/77Fj6eH1ynwscYTOsbK7rR//Uj0bZXBwJZRfaLEJ1iGBR6kIfNmlNqaqJf649EP0F3NWNdeJi03elllNUQ==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "decode-named-character-reference": "^1.0.0", - "micromark-util-character": "^2.0.0", - "micromark-util-decode-numeric-character-reference": "^2.0.0", - "micromark-util-symbol": "^2.0.0" - } - }, - "node_modules/micromark-util-encode": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-encode/-/micromark-util-encode-2.0.1.tgz", - "integrity": "sha512-c3cVx2y4KqUnwopcO9b/SCdo2O67LwJJ/UyqGfbigahfegL9myoEFoDYZgkT7f36T0bLrM9hZTAaAyH+PCAXjw==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT" - }, - "node_modules/micromark-util-events-to-acorn": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/micromark-util-events-to-acorn/-/micromark-util-events-to-acorn-2.0.3.tgz", - "integrity": "sha512-jmsiEIiZ1n7X1Rr5k8wVExBQCg5jy4UXVADItHmNk1zkwEVhBuIUKRu3fqv+hs4nxLISi2DQGlqIOGiFxgbfHg==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "@types/unist": "^3.0.0", - "devlop": "^1.0.0", - "estree-util-visit": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0", - "vfile-message": "^4.0.0" - } - }, - "node_modules/micromark-util-html-tag-name": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-html-tag-name/-/micromark-util-html-tag-name-2.0.1.tgz", - "integrity": "sha512-2cNEiYDhCWKI+Gs9T0Tiysk136SnR13hhO8yW6BGNyhOC4qYFnwF1nKfD3HFAIXA5c45RrIG1ub11GiXeYd1xA==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT" - }, - "node_modules/micromark-util-normalize-identifier": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-normalize-identifier/-/micromark-util-normalize-identifier-2.0.1.tgz", - "integrity": "sha512-sxPqmo70LyARJs0w2UclACPUUEqltCkJ6PhKdMIDuJ3gSf/Q+/GIe3WKl0Ijb/GyH9lOpUkRAO2wp0GVkLvS9Q==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-symbol": "^2.0.0" - } - }, - "node_modules/micromark-util-resolve-all": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-resolve-all/-/micromark-util-resolve-all-2.0.1.tgz", - "integrity": "sha512-VdQyxFWFT2/FGJgwQnJYbe1jjQoNTS4RjglmSjTUlpUMa95Htx9NHeYW4rGDJzbjvCsl9eLjMQwGeElsqmzcHg==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-util-sanitize-uri": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-sanitize-uri/-/micromark-util-sanitize-uri-2.0.1.tgz", - "integrity": "sha512-9N9IomZ/YuGGZZmQec1MbgxtlgougxTodVwDzzEouPKo3qFWvymFHWcnDi2vzV1ff6kas9ucW+o3yzJK9YB1AQ==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-character": "^2.0.0", - "micromark-util-encode": "^2.0.0", - "micromark-util-symbol": "^2.0.0" - } - }, - "node_modules/micromark-util-subtokenize": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-util-subtokenize/-/micromark-util-subtokenize-2.1.0.tgz", - "integrity": "sha512-XQLu552iSctvnEcgXw6+Sx75GflAPNED1qx7eBJ+wydBb2KCbRZe+NwvIEEMM83uml1+2WSXpBAcp9IUCgCYWA==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "devlop": "^1.0.0", - "micromark-util-chunked": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-util-symbol": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-symbol/-/micromark-util-symbol-2.0.1.tgz", - "integrity": "sha512-vs5t8Apaud9N28kgCrRUdEed4UJ+wWNvicHLPxCa9ENlYuAY31M0ETy5y1vA33YoNPDFTghEbnh6efaE8h4x0Q==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT" - }, - "node_modules/micromark-util-types": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-types/-/micromark-util-types-2.0.1.tgz", - "integrity": "sha512-534m2WhVTddrcKVepwmVEVnUAmtrx9bfIjNoQHRqfnvdaHQiFytEhJoTgpWJvDEXCO5gLTQh3wYC1PgOJA4NSQ==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT" - }, - "node_modules/micromatch": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", - "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", - "license": "MIT", - "dependencies": { - "braces": "^3.0.3", - "picomatch": "^2.3.1" - }, - "engines": { - "node": ">=8.6" - } - }, - "node_modules/micromatch/node_modules/picomatch": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", - "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", - "license": "MIT", - "engines": { - "node": ">=8.6" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, - "node_modules/mime-db": { - "version": "1.54.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", - "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mime-types": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.1.tgz", - "integrity": "sha512-xRc4oEhT6eaBpU1XF7AjpOFD+xQmXNB5OVKwp4tqCuBpHLS/ZbBDrc07mYTDqVMg6PfxUjjNp85O6Cd2Z/5HWA==", - "license": "MIT", - "dependencies": { - "mime-db": "^1.54.0" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mimic-response": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", - "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/mini-svg-data-uri": { - "version": "1.4.4", - "resolved": "https://registry.npmjs.org/mini-svg-data-uri/-/mini-svg-data-uri-1.4.4.tgz", - "integrity": "sha512-r9deDe9p5FJUPZAk3A59wGH7Ii9YrjjWw0jmw/liSbHl2CHiyXj6FcDXDu2K3TjVAXqiJdaw3xxwlZZr9E6nHg==", - "dev": true, - "license": "MIT", - "bin": { - "mini-svg-data-uri": "cli.js" - } - }, - "node_modules/minimatch": { - "version": "9.0.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", - "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.1" - }, - "engines": { - "node": ">=16 || 14 >=14.17" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/minimist": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", - "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/minipass": { - "version": "4.2.8", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-4.2.8.tgz", - "integrity": "sha512-fNzuVyifolSLFL4NzpF+wEF4qrgqaaKX0haXPQEdQ7NKAN+WecoKMHV09YcuL/DHxrUsYQOK3MiuDf7Ip2OXfQ==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=8" - } - }, - "node_modules/minizlib": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.2.tgz", - "integrity": "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==", - "dev": true, - "license": "MIT", - "dependencies": { - "minipass": "^3.0.0", - "yallist": "^4.0.0" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/minizlib/node_modules/minipass": { - "version": "3.3.6", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", - "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", - "dev": true, - "license": "ISC", - "dependencies": { - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "dev": true, - "license": "MIT", - "bin": { - "mkdirp": "bin/cmd.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/mkdirp-classic": { - "version": "0.5.3", - "resolved": "https://registry.npmjs.org/mkdirp-classic/-/mkdirp-classic-0.5.3.tgz", - "integrity": "sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==", - "license": "MIT" - }, - "node_modules/mlly": { - "version": "1.7.4", - "resolved": "https://registry.npmjs.org/mlly/-/mlly-1.7.4.tgz", - "integrity": "sha512-qmdSIPC4bDJXgZTCR7XosJiNKySV7O215tsPtDN9iEO/7q/76b/ijtgRu/+epFXSJhijtTCCGp3DWS549P3xKw==", - "dev": true, - "license": "MIT", - "dependencies": { - "acorn": "^8.14.0", - "pathe": "^2.0.1", - "pkg-types": "^1.3.0", - "ufo": "^1.5.4" - } - }, - "node_modules/mlly/node_modules/pathe": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.2.tgz", - "integrity": "sha512-15Ztpk+nov8DR524R4BF7uEuzESgzUEAV4Ah7CUMNGXdE5ELuvxElxGXndBl32vMSsWa1jpNf22Z+Er3sKwq+w==", - "dev": true, - "license": "MIT" - }, - "node_modules/mrmime": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/mrmime/-/mrmime-2.0.1.tgz", - "integrity": "sha512-Y3wQdFg2Va6etvQ5I82yUhGdsKrcYox6p7FfL1LbK2J4V01F9TGlepTIhnK24t7koZibmg82KGglhA1XK5IsLQ==", - "license": "MIT", - "engines": { - "node": ">=10" - } - }, - "node_modules/ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "license": "MIT" - }, - "node_modules/muggle-string": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/muggle-string/-/muggle-string-0.4.1.tgz", - "integrity": "sha512-VNTrAak/KhO2i8dqqnqnAHOa3cYBwXEZe9h+D5h/1ZqFSTEFHdM65lR7RoIqq3tBBYavsOXV84NoHXZ0AkPyqQ==", - "license": "MIT" - }, - "node_modules/nanoid": { - "version": "3.3.8", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.8.tgz", - "integrity": "sha512-WNLf5Sd8oZxOm+TzppcYk8gVOgP+l58xNy58D0nbUnOxOWRWvlcCV4kUF7ltmI6PsrLl/BgKEyS4mqsGChFN0w==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "MIT", - "bin": { - "nanoid": "bin/nanoid.cjs" - }, - "engines": { - "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" - } - }, - "node_modules/napi-build-utils": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/napi-build-utils/-/napi-build-utils-2.0.0.tgz", - "integrity": "sha512-GEbrYkbfF7MoNaoh2iGG84Mnf/WZfB0GdGEsM8wz7Expx/LlWf5U8t9nvJKXSp3qr5IsEbK04cBGhol/KwOsWA==", - "license": "MIT" - }, - "node_modules/napi-postinstall": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/napi-postinstall/-/napi-postinstall-0.2.3.tgz", - "integrity": "sha512-Mi7JISo/4Ij2tDZ2xBE2WH+/KvVlkhA6juEjpEeRAVPNCpN3nxJo/5FhDNKgBcdmcmhaH6JjgST4xY/23ZYK0w==", - "dev": true, - "license": "MIT", - "bin": { - "napi-postinstall": "lib/cli.js" - }, - "engines": { - "node": "^12.20.0 || ^14.18.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/napi-postinstall" - } - }, - "node_modules/natural-compare": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", - "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", - "dev": true, - "license": "MIT" - }, - "node_modules/neotraverse": { - "version": "0.6.18", - "resolved": "https://registry.npmjs.org/neotraverse/-/neotraverse-0.6.18.tgz", - "integrity": "sha512-Z4SmBUweYa09+o6pG+eASabEpP6QkQ70yHj351pQoEXIs8uHbaU2DWVmzBANKgflPa47A50PtB2+NgRpQvr7vA==", - "license": "MIT", - "engines": { - "node": ">= 10" - } - }, - "node_modules/nlcst-to-string": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/nlcst-to-string/-/nlcst-to-string-4.0.0.tgz", - "integrity": "sha512-YKLBCcUYKAg0FNlOBT6aI91qFmSiFKiluk655WzPF+DDMA02qIyy8uiRqI8QXtcFpEvll12LpL5MXqEmAZ+dcA==", - "license": "MIT", - "dependencies": { - "@types/nlcst": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/node-abi": { - "version": "3.74.0", - "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.74.0.tgz", - "integrity": "sha512-c5XK0MjkGBrQPGYG24GBADZud0NCbznxNx0ZkS+ebUTrmV1qTDxPxSL8zEAPURXSbLRWVexxmP4986BziahL5w==", - "license": "MIT", - "dependencies": { - "semver": "^7.3.5" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/node-addon-api": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-7.1.1.tgz", - "integrity": "sha512-5m3bsyrjFWE1xf7nz7YXdN4udnVtXK6/Yfgn5qnahL6bCkf2yKt4k3nuTKAtT4r3IG8JNR2ncsIMdZuAzJjHQQ==", - "license": "MIT" - }, - "node_modules/node-domexception": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/node-domexception/-/node-domexception-1.0.0.tgz", - "integrity": "sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/jimmywarting" - }, - { - "type": "github", - "url": "https://paypal.me/jimmywarting" - } - ], - "license": "MIT", - "engines": { - "node": ">=10.5.0" - } - }, - "node_modules/node-fetch": { - "version": "3.3.2", - "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-3.3.2.tgz", - "integrity": "sha512-dRB78srN/l6gqWulah9SrxeYnxeddIG30+GOqK/9OlLVyLg3HPnr6SqOWTWOXKRwC2eGYCkZ59NNuSgvSrpgOA==", - "license": "MIT", - "dependencies": { - "data-uri-to-buffer": "^4.0.0", - "fetch-blob": "^3.1.4", - "formdata-polyfill": "^4.0.10" - }, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/node-fetch" - } - }, - "node_modules/node-fetch-native": { - "version": "1.6.6", - "resolved": "https://registry.npmjs.org/node-fetch-native/-/node-fetch-native-1.6.6.tgz", - "integrity": "sha512-8Mc2HhqPdlIfedsuZoc3yioPuzp6b+L5jRCRY1QzuWZh2EGJVQrGppC6V6cF0bLdbW0+O2YpqCA25aF/1lvipQ==", - "license": "MIT" - }, - "node_modules/node-mock-http": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/node-mock-http/-/node-mock-http-1.0.0.tgz", - "integrity": "sha512-0uGYQ1WQL1M5kKvGRXWQ3uZCHtLTO8hln3oBjIusM75WoesZ909uQJs/Hb946i2SS+Gsrhkaa6iAO17jRIv6DQ==", - "license": "MIT" - }, - "node_modules/normalize-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/nth-check": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.1.1.tgz", - "integrity": "sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "boolbase": "^1.0.0" - }, - "funding": { - "url": "https://github.com/fb55/nth-check?sponsor=1" - } - }, - "node_modules/object-inspect": { - "version": "1.13.4", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.4.tgz", - "integrity": "sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/object-keys": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", - "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/object-to-formdata": { - "version": "4.5.1", - "resolved": "https://registry.npmjs.org/object-to-formdata/-/object-to-formdata-4.5.1.tgz", - "integrity": "sha512-QiM9D0NiU5jV6J6tjE1g7b4Z2tcUnKs1OPUi4iMb2zH+7jwlcUrASghgkFk9GtzqNNq8rTQJtT8AzjBAvLoNMw==", - "license": "MIT" - }, - "node_modules/object.assign": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.7.tgz", - "integrity": "sha512-nK28WOo+QIjBkDduTINE4JkF/UJJKyf2EJxvJKfblDpyg0Q+pkOHNTL0Qwy6NP6FhE/EnzV73BxxqcJaXY9anw==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "call-bound": "^1.0.3", - "define-properties": "^1.2.1", - "es-object-atoms": "^1.0.0", - "has-symbols": "^1.1.0", - "object-keys": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/object.fromentries": { - "version": "2.0.8", - "resolved": "https://registry.npmjs.org/object.fromentries/-/object.fromentries-2.0.8.tgz", - "integrity": "sha512-k6E21FzySsSK5a21KRADBd/NGneRegFO5pLHfdQLpRDETUNJueLXs3WCzyQ3tFRDYgbq3KHGXfTbi2bs8WQ6rQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.2", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/object.groupby": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/object.groupby/-/object.groupby-1.0.3.tgz", - "integrity": "sha512-+Lhy3TQTuzXI5hevh8sBGqbmurHbbIjAi0Z4S63nthVLmLxfbj4T54a4CfZrXIrt9iP4mVAPYMo/v99taj3wjQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/object.values": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/object.values/-/object.values-1.2.1.tgz", - "integrity": "sha512-gXah6aZrcUxjWg2zR2MwouP2eHlCBzdV4pygudehaKXSGW4v2AsRQUK+lwwXhii6KFZcunEnmSUoYp5CXibxtA==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "call-bound": "^1.0.3", - "define-properties": "^1.2.1", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/ofetch": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/ofetch/-/ofetch-1.4.1.tgz", - "integrity": "sha512-QZj2DfGplQAr2oj9KzceK9Hwz6Whxazmn85yYeVuS3u9XTMOGMRx0kO95MQ+vLsj/S/NwBDMMLU5hpxvI6Tklw==", - "license": "MIT", - "dependencies": { - "destr": "^2.0.3", - "node-fetch-native": "^1.6.4", - "ufo": "^1.5.4" - } - }, - "node_modules/ohash": { - "version": "2.0.11", - "resolved": "https://registry.npmjs.org/ohash/-/ohash-2.0.11.tgz", - "integrity": "sha512-RdR9FQrFwNBNXAr4GixM8YaRZRJ5PUWbKYbE5eOsrwAjJW0q2REGcf79oYPsLyskQCZG1PLN+S/K1V00joZAoQ==", - "license": "MIT" - }, - "node_modules/on-finished": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.1.tgz", - "integrity": "sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==", - "license": "MIT", - "dependencies": { - "ee-first": "1.1.1" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", - "license": "ISC", - "dependencies": { - "wrappy": "1" - } - }, - "node_modules/oniguruma-parser": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/oniguruma-parser/-/oniguruma-parser-0.5.4.tgz", - "integrity": "sha512-yNxcQ8sKvURiTwP0mV6bLQCYE7NKfKRRWunhbZnXgxSmB1OXa1lHrN3o4DZd+0Si0kU5blidK7BcROO8qv5TZA==", - "license": "MIT" - }, - "node_modules/oniguruma-to-es": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/oniguruma-to-es/-/oniguruma-to-es-4.1.0.tgz", - "integrity": "sha512-SNwG909cSLo4vPyyPbU/VJkEc9WOXqu2ycBlfd1UCXLqk1IijcQktSBb2yRQ2UFPsDhpkaf+C1dtT3PkLK/yWA==", - "license": "MIT", - "dependencies": { - "emoji-regex-xs": "^1.0.0", - "oniguruma-parser": "^0.5.4", - "regex": "^6.0.1", - "regex-recursion": "^6.0.2" - } - }, - "node_modules/open": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/open/-/open-10.1.0.tgz", - "integrity": "sha512-mnkeQ1qP5Ue2wd+aivTD3NHd/lZ96Lu0jgf0pwktLPtx6cTZiH7tyeGRRHs0zX0rbrahXPnXlUnbeXyaBBuIaw==", - "license": "MIT", - "dependencies": { - "default-browser": "^5.2.1", - "define-lazy-prop": "^3.0.0", - "is-inside-container": "^1.0.0", - "is-wsl": "^3.1.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/optionator": { - "version": "0.9.4", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.4.tgz", - "integrity": "sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==", - "dev": true, - "license": "MIT", - "dependencies": { - "deep-is": "^0.1.3", - "fast-levenshtein": "^2.0.6", - "levn": "^0.4.1", - "prelude-ls": "^1.2.1", - "type-check": "^0.4.0", - "word-wrap": "^1.2.5" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/own-keys": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/own-keys/-/own-keys-1.0.1.tgz", - "integrity": "sha512-qFOyK5PjiWZd+QQIh+1jhdb9LpxTF0qs7Pm8o5QHYZ0M3vKqSqzsZaEB6oWlxZ+q2sJBMI/Ktgd2N5ZwQoRHfg==", - "dev": true, - "license": "MIT", - "dependencies": { - "get-intrinsic": "^1.2.6", - "object-keys": "^1.1.1", - "safe-push-apply": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/p-limit": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-6.2.0.tgz", - "integrity": "sha512-kuUqqHNUqoIWp/c467RI4X6mmyuojY5jGutNU0wVTmEOOfcuwLqyMVoAi9MKi2Ak+5i9+nhmrK4ufZE8069kHA==", - "license": "MIT", - "dependencies": { - "yocto-queue": "^1.1.1" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-locate": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", - "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", - "dev": true, - "license": "MIT", - "dependencies": { - "p-limit": "^3.0.2" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-locate/node_modules/p-limit": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", - "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "yocto-queue": "^0.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-locate/node_modules/yocto-queue": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", - "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-queue": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/p-queue/-/p-queue-8.1.0.tgz", - "integrity": "sha512-mxLDbbGIBEXTJL0zEx8JIylaj3xQ7Z/7eEVjcF9fJX4DBiH9oqe+oahYnlKKxm0Ci9TlWTyhSHgygxMxjIB2jw==", - "license": "MIT", - "dependencies": { - "eventemitter3": "^5.0.1", - "p-timeout": "^6.1.2" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-timeout": { - "version": "6.1.4", - "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-6.1.4.tgz", - "integrity": "sha512-MyIV3ZA/PmyBN/ud8vV9XzwTrNtR4jFrObymZYnZqMmW0zA8Z17vnT0rBgFE/TlohB+YCHqXMgZzb3Csp49vqg==", - "license": "MIT", - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/package-manager-detector": { - "version": "0.2.9", - "resolved": "https://registry.npmjs.org/package-manager-detector/-/package-manager-detector-0.2.9.tgz", - "integrity": "sha512-+vYvA/Y31l8Zk8dwxHhL3JfTuHPm6tlxM2A3GeQyl7ovYnSp1+mzAxClxaOr0qO1TtPxbQxetI7v5XqKLJZk7Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/pako": { - "version": "0.2.9", - "resolved": "https://registry.npmjs.org/pako/-/pako-0.2.9.tgz", - "integrity": "sha512-NUcwaKxUxWrZLpDG+z/xZaCgQITkA/Dv4V/T6bw7VON6l1Xz/VnrBqrYjZQ12TamKHzITTfOEIYUj48y2KXImA==", - "license": "MIT" - }, - "node_modules/parent-module": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", - "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", - "dev": true, - "license": "MIT", - "dependencies": { - "callsites": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/parse-css-color": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/parse-css-color/-/parse-css-color-0.2.1.tgz", - "integrity": "sha512-bwS/GGIFV3b6KS4uwpzCFj4w297Yl3uqnSgIPsoQkx7GMLROXfMnWvxfNkL0oh8HVhZA4hvJoEoEIqonfJ3BWg==", - "license": "MIT", - "dependencies": { - "color-name": "^1.1.4", - "hex-rgb": "^4.1.0" - } - }, - "node_modules/parse-entities": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/parse-entities/-/parse-entities-4.0.2.tgz", - "integrity": "sha512-GG2AQYWoLgL877gQIKeRPGO1xF9+eG1ujIb5soS5gPvLQ1y2o8FL90w2QWNdf9I361Mpp7726c+lj3U0qK1uGw==", - "license": "MIT", - "dependencies": { - "@types/unist": "^2.0.0", - "character-entities-legacy": "^3.0.0", - "character-reference-invalid": "^2.0.0", - "decode-named-character-reference": "^1.0.0", - "is-alphanumerical": "^2.0.0", - "is-decimal": "^2.0.0", - "is-hexadecimal": "^2.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/parse-entities/node_modules/@types/unist": { - "version": "2.0.11", - "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.11.tgz", - "integrity": "sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==", - "license": "MIT" - }, - "node_modules/parse-latin": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/parse-latin/-/parse-latin-7.0.0.tgz", - "integrity": "sha512-mhHgobPPua5kZ98EF4HWiH167JWBfl4pvAIXXdbaVohtK7a6YBOy56kvhCqduqyo/f3yrHFWmqmiMg/BkBkYYQ==", - "license": "MIT", - "dependencies": { - "@types/nlcst": "^2.0.0", - "@types/unist": "^3.0.0", - "nlcst-to-string": "^4.0.0", - "unist-util-modify-children": "^4.0.0", - "unist-util-visit-children": "^3.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/parse5": { - "version": "7.2.1", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.2.1.tgz", - "integrity": "sha512-BuBYQYlv1ckiPdQi/ohiivi9Sagc9JG+Ozs0r7b/0iK3sKmrb0b9FdWdBbOdx6hBCM/F9Ir82ofnBhtZOjCRPQ==", - "license": "MIT", - "dependencies": { - "entities": "^4.5.0" - }, - "funding": { - "url": "https://github.com/inikulin/parse5?sponsor=1" - } - }, - "node_modules/parse5-htmlparser2-tree-adapter": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-7.1.0.tgz", - "integrity": "sha512-ruw5xyKs6lrpo9x9rCZqZZnIUntICjQAd0Wsmp396Ul9lN/h+ifgVV1x1gZHi8euej6wTfpqX8j+BFQxF0NS/g==", - "dev": true, - "license": "MIT", - "dependencies": { - "domhandler": "^5.0.3", - "parse5": "^7.0.0" - }, - "funding": { - "url": "https://github.com/inikulin/parse5?sponsor=1" - } - }, - "node_modules/parse5-parser-stream": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/parse5-parser-stream/-/parse5-parser-stream-7.1.2.tgz", - "integrity": "sha512-JyeQc9iwFLn5TbvvqACIF/VXG6abODeB3Fwmv/TGdLk2LfbWkaySGY72at4+Ty7EkPZj854u4CrICqNk2qIbow==", - "dev": true, - "license": "MIT", - "dependencies": { - "parse5": "^7.0.0" - }, - "funding": { - "url": "https://github.com/inikulin/parse5?sponsor=1" - } - }, - "node_modules/path-browserify": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-browserify/-/path-browserify-1.0.1.tgz", - "integrity": "sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==", - "license": "MIT" - }, - "node_modules/path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/path-key": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", - "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/path-parse": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", - "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", - "dev": true, - "license": "MIT" - }, - "node_modules/pathe": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/pathe/-/pathe-1.1.2.tgz", - "integrity": "sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/pend": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz", - "integrity": "sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==", - "dev": true, - "license": "MIT" - }, - "node_modules/pg-int8": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/pg-int8/-/pg-int8-1.0.1.tgz", - "integrity": "sha512-WCtabS6t3c8SkpDBUlb1kjOs7l66xsGdKpIPZsg4wR+B3+u9UAum2odSsF9tnvxg80h4ZxLWMy4pRjOsFIqQpw==", - "license": "ISC", - "optional": true, - "peer": true, - "engines": { - "node": ">=4.0.0" - } - }, - "node_modules/pg-protocol": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/pg-protocol/-/pg-protocol-1.8.0.tgz", - "integrity": "sha512-jvuYlEkL03NRvOoyoRktBK7+qU5kOvlAwvmrH8sr3wbLrOdVWsRxQfz8mMy9sZFsqJ1hEWNfdWKI4SAmoL+j7g==", - "license": "MIT", - "optional": true, - "peer": true - }, - "node_modules/pg-types": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/pg-types/-/pg-types-2.2.0.tgz", - "integrity": "sha512-qTAAlrEsl8s4OiEQY69wDvcMIdQN6wdz5ojQiOy6YRMuynxenON0O5oCpJI6lshc6scgAY8qvJ2On/p+CXY0GA==", - "license": "MIT", - "optional": true, - "peer": true, - "dependencies": { - "pg-int8": "1.0.1", - "postgres-array": "~2.0.0", - "postgres-bytea": "~1.0.0", - "postgres-date": "~1.0.4", - "postgres-interval": "^1.1.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/picocolors": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", - "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", - "license": "ISC" - }, - "node_modules/picomatch": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.2.tgz", - "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, - "node_modules/pkg-types": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/pkg-types/-/pkg-types-1.3.1.tgz", - "integrity": "sha512-/Jm5M4RvtBFVkKWRu2BLUTNP8/M2a+UwuAX+ae4770q1qVGtfjG+WTCupoZixokjmHiry8uI+dlY8KXYV5HVVQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "confbox": "^0.1.8", - "mlly": "^1.7.4", - "pathe": "^2.0.1" - } - }, - "node_modules/pkg-types/node_modules/pathe": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.2.tgz", - "integrity": "sha512-15Ztpk+nov8DR524R4BF7uEuzESgzUEAV4Ah7CUMNGXdE5ELuvxElxGXndBl32vMSsWa1jpNf22Z+Er3sKwq+w==", - "dev": true, - "license": "MIT" - }, - "node_modules/possible-typed-array-names": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.1.0.tgz", - "integrity": "sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/postcss": { - "version": "8.5.3", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz", - "integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==", - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/postcss/" - }, - { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/postcss" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "MIT", - "dependencies": { - "nanoid": "^3.3.8", - "picocolors": "^1.1.1", - "source-map-js": "^1.2.1" - }, - "engines": { - "node": "^10 || ^12 || >=14" - } - }, - "node_modules/postcss-selector-parser": { - "version": "6.0.10", - "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.0.10.tgz", - "integrity": "sha512-IQ7TZdoaqbT+LCpShg46jnZVlhWD2w6iQYAcYXfHARZ7X1t/UGhhceQDs5X0cGqKvYlHNOuv7Oa1xmb0oQuA3w==", - "dev": true, - "license": "MIT", - "dependencies": { - "cssesc": "^3.0.0", - "util-deprecate": "^1.0.2" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/postcss-value-parser": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz", - "integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==", - "license": "MIT" - }, - "node_modules/postgres-array": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/postgres-array/-/postgres-array-2.0.0.tgz", - "integrity": "sha512-VpZrUqU5A69eQyW2c5CA1jtLecCsN2U/bD6VilrFDWq5+5UIEVO7nazS3TEcHf1zuPYO/sqGvUvW62g86RXZuA==", - "license": "MIT", - "optional": true, - "peer": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/postgres-bytea": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/postgres-bytea/-/postgres-bytea-1.0.0.tgz", - "integrity": "sha512-xy3pmLuQqRBZBXDULy7KbaitYqLcmxigw14Q5sj8QBVLqEwXfeybIKVWiqAXTlcvdvb0+xkOtDbfQMOf4lST1w==", - "license": "MIT", - "optional": true, - "peer": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/postgres-date": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/postgres-date/-/postgres-date-1.0.7.tgz", - "integrity": "sha512-suDmjLVQg78nMK2UZ454hAG+OAW+HQPZ6n++TNDUX+L0+uUlLywnoxJKDou51Zm+zTCjrCl0Nq6J9C5hP9vK/Q==", - "license": "MIT", - "optional": true, - "peer": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/postgres-interval": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/postgres-interval/-/postgres-interval-1.2.0.tgz", - "integrity": "sha512-9ZhXKM/rw350N1ovuWHbGxnGh/SNJ4cnxHiM0rxE4VN41wsg8P8zWn9hv/buK00RP4WvlOyr/RBDiptyxVbkZQ==", - "license": "MIT", - "optional": true, - "peer": true, - "dependencies": { - "xtend": "^4.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/prebuild-install": { - "version": "7.1.3", - "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-7.1.3.tgz", - "integrity": "sha512-8Mf2cbV7x1cXPUILADGI3wuhfqWvtiLA1iclTDbFRZkgRQS0NqsPZphna9V+HyTEadheuPmjaJMsbzKQFOzLug==", - "license": "MIT", - "dependencies": { - "detect-libc": "^2.0.0", - "expand-template": "^2.0.3", - "github-from-package": "0.0.0", - "minimist": "^1.2.3", - "mkdirp-classic": "^0.5.3", - "napi-build-utils": "^2.0.0", - "node-abi": "^3.3.0", - "pump": "^3.0.0", - "rc": "^1.2.7", - "simple-get": "^4.0.0", - "tar-fs": "^2.0.0", - "tunnel-agent": "^0.6.0" - }, - "bin": { - "prebuild-install": "bin.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/prelude-ls": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", - "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/prettier": { - "version": "3.5.3", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.5.3.tgz", - "integrity": "sha512-QQtaxnoDJeAkDvDKWCLiwIXkTgRhwYDEQCghU9Z6q03iyek/rxRh/2lC3HB7P8sWT2xC/y5JDctPLBIGzHKbhw==", - "devOptional": true, - "license": "MIT", - "bin": { - "prettier": "bin/prettier.cjs" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/prettier/prettier?sponsor=1" - } - }, - "node_modules/prettier-plugin-astro": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/prettier-plugin-astro/-/prettier-plugin-astro-0.14.1.tgz", - "integrity": "sha512-RiBETaaP9veVstE4vUwSIcdATj6dKmXljouXc/DDNwBSPTp8FRkLGDSGFClKsAFeeg+13SB0Z1JZvbD76bigJw==", - "devOptional": true, - "license": "MIT", - "dependencies": { - "@astrojs/compiler": "^2.9.1", - "prettier": "^3.0.0", - "sass-formatter": "^0.7.6" - }, - "engines": { - "node": "^14.15.0 || >=16.0.0" - } - }, - "node_modules/prettier-plugin-tailwindcss": { - "version": "0.6.11", - "resolved": "https://registry.npmjs.org/prettier-plugin-tailwindcss/-/prettier-plugin-tailwindcss-0.6.11.tgz", - "integrity": "sha512-YxaYSIvZPAqhrrEpRtonnrXdghZg1irNg4qrjboCXrpybLWVs55cW2N3juhspVJiO0JBvYJT8SYsJpc8OQSnsA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=14.21.3" - }, - "peerDependencies": { - "@ianvs/prettier-plugin-sort-imports": "*", - "@prettier/plugin-pug": "*", - "@shopify/prettier-plugin-liquid": "*", - "@trivago/prettier-plugin-sort-imports": "*", - "@zackad/prettier-plugin-twig": "*", - "prettier": "^3.0", - "prettier-plugin-astro": "*", - "prettier-plugin-css-order": "*", - "prettier-plugin-import-sort": "*", - "prettier-plugin-jsdoc": "*", - "prettier-plugin-marko": "*", - "prettier-plugin-multiline-arrays": "*", - "prettier-plugin-organize-attributes": "*", - "prettier-plugin-organize-imports": "*", - "prettier-plugin-sort-imports": "*", - "prettier-plugin-style-order": "*", - "prettier-plugin-svelte": "*" - }, - "peerDependenciesMeta": { - "@ianvs/prettier-plugin-sort-imports": { - "optional": true - }, - "@prettier/plugin-pug": { - "optional": true - }, - "@shopify/prettier-plugin-liquid": { - "optional": true - }, - "@trivago/prettier-plugin-sort-imports": { - "optional": true - }, - "@zackad/prettier-plugin-twig": { - "optional": true - }, - "prettier-plugin-astro": { - "optional": true - }, - "prettier-plugin-css-order": { - "optional": true - }, - "prettier-plugin-import-sort": { - "optional": true - }, - "prettier-plugin-jsdoc": { - "optional": true - }, - "prettier-plugin-marko": { - "optional": true - }, - "prettier-plugin-multiline-arrays": { - "optional": true - }, - "prettier-plugin-organize-attributes": { - "optional": true - }, - "prettier-plugin-organize-imports": { - "optional": true - }, - "prettier-plugin-sort-imports": { - "optional": true - }, - "prettier-plugin-style-order": { - "optional": true - }, - "prettier-plugin-svelte": { - "optional": true - } - } - }, - "node_modules/prisma": { - "version": "6.8.2", - "resolved": "https://registry.npmjs.org/prisma/-/prisma-6.8.2.tgz", - "integrity": "sha512-JNricTXQxzDtRS7lCGGOB4g5DJ91eg3nozdubXze3LpcMl1oWwcFddrj++Up3jnRE6X/3gB/xz3V+ecBk/eEGA==", - "devOptional": true, - "hasInstallScript": true, - "license": "Apache-2.0", - "dependencies": { - "@prisma/config": "6.8.2", - "@prisma/engines": "6.8.2" - }, - "bin": { - "prisma": "build/index.js" - }, - "engines": { - "node": ">=18.18" - }, - "peerDependencies": { - "typescript": ">=5.1.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/prisma-json-types-generator": { - "version": "3.4.1", - "resolved": "https://registry.npmjs.org/prisma-json-types-generator/-/prisma-json-types-generator-3.4.1.tgz", - "integrity": "sha512-VWsuvCyHyOHoyyuishw9hPjoDYx9+sa+v0E0ggHheYkQ5N9tt6EXd9AYaR181WWMG+K+1Ua2tW0yEsl52pe9ew==", - "dev": true, - "license": "MIT", - "dependencies": { - "@prisma/generator-helper": "^6.7.0", - "tslib": "^2.8.1" - }, - "bin": { - "prisma-json-types-generator": "index.js" - }, - "engines": { - "node": ">=14.0" - }, - "funding": { - "url": "https://github.com/arthurfiorette/prisma-json-types-generator?sponsor=1" - }, - "peerDependencies": { - "prisma": "^6.7", - "typescript": "^5.8" - } - }, - "node_modules/prismjs": { - "version": "1.30.0", - "resolved": "https://registry.npmjs.org/prismjs/-/prismjs-1.30.0.tgz", - "integrity": "sha512-DEvV2ZF2r2/63V+tK8hQvrR2ZGn10srHbXviTlcv7Kpzw8jWiNTqbVgjO3IY8RxrrOUF8VPMQQFysYYYv0YZxw==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/promise-limit": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/promise-limit/-/promise-limit-2.7.0.tgz", - "integrity": "sha512-7nJ6v5lnJsXwGprnGXga4wx6d1POjvi5Qmf1ivTRxTjH4Z/9Czja/UCMLVmB9N93GeWOU93XaFaEt6jbuoagNw==", - "license": "ISC" - }, - "node_modules/prompts": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.4.2.tgz", - "integrity": "sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==", - "license": "MIT", - "dependencies": { - "kleur": "^3.0.3", - "sisteransi": "^1.0.5" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/prompts/node_modules/kleur": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/kleur/-/kleur-3.0.3.tgz", - "integrity": "sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/property-information": { - "version": "6.5.0", - "resolved": "https://registry.npmjs.org/property-information/-/property-information-6.5.0.tgz", - "integrity": "sha512-PgTgs/BlvHxOu8QuEN7wi5A0OmXaBcHpmCSTehcs6Uuu9IkDIEo13Hy7n898RHfrQ49vKCoGeWZSaAK01nwVig==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/proxy-from-env": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz", - "integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==", - "dev": true, - "license": "MIT" - }, - "node_modules/pump": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.2.tgz", - "integrity": "sha512-tUPXtzlGM8FE3P0ZL6DVs/3P58k9nk8/jZeQCurTJylQA8qFYzHFfhBJkuqyE0FifOsQ0uKWekiZ5g8wtr28cw==", - "license": "MIT", - "dependencies": { - "end-of-stream": "^1.1.0", - "once": "^1.3.1" - } - }, - "node_modules/punycode": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", - "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/queue-microtask": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", - "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" - }, - "node_modules/radix3": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/radix3/-/radix3-1.1.2.tgz", - "integrity": "sha512-b484I/7b8rDEdSDKckSSBA8knMpcdsXudlE/LNL639wFoHKwLbEkQFZHWEYwDC0wa0FKUcCY+GAF73Z7wxNVFA==", - "license": "MIT" - }, - "node_modules/range-parser": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", - "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/rc": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", - "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", - "license": "(BSD-2-Clause OR MIT OR Apache-2.0)", - "dependencies": { - "deep-extend": "^0.6.0", - "ini": "~1.3.0", - "minimist": "^1.2.0", - "strip-json-comments": "~2.0.1" - }, - "bin": { - "rc": "cli.js" - } - }, - "node_modules/rc/node_modules/strip-json-comments": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", - "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/react": { - "version": "19.1.0", - "resolved": "https://registry.npmjs.org/react/-/react-19.1.0.tgz", - "integrity": "sha512-FS+XFBNvn3GTAWq26joslQgWNoFu08F4kl0J4CgdNKADkdSGXQyTCnKteIAJy96Br6YbpEU1LSzV5dYtjMkMDg==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/readable-stream": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", - "license": "MIT", - "dependencies": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/readdirp": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-4.1.2.tgz", - "integrity": "sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg==", - "license": "MIT", - "engines": { - "node": ">= 14.18.0" - }, - "funding": { - "type": "individual", - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/recma-build-jsx": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/recma-build-jsx/-/recma-build-jsx-1.0.0.tgz", - "integrity": "sha512-8GtdyqaBcDfva+GUKDr3nev3VpKAhup1+RvkMvUxURHpW7QyIvk9F5wz7Vzo06CEMSilw6uArgRqhpiUcWp8ew==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "estree-util-build-jsx": "^3.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/recma-jsx": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/recma-jsx/-/recma-jsx-1.0.0.tgz", - "integrity": "sha512-5vwkv65qWwYxg+Atz95acp8DMu1JDSqdGkA2Of1j6rCreyFUE/gp15fC8MnGEuG1W68UKjM6x6+YTWIh7hZM/Q==", - "license": "MIT", - "dependencies": { - "acorn-jsx": "^5.0.0", - "estree-util-to-js": "^2.0.0", - "recma-parse": "^1.0.0", - "recma-stringify": "^1.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/recma-parse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/recma-parse/-/recma-parse-1.0.0.tgz", - "integrity": "sha512-OYLsIGBB5Y5wjnSnQW6t3Xg7q3fQ7FWbw/vcXtORTnyaSFscOtABg+7Pnz6YZ6c27fG1/aN8CjfwoUEUIdwqWQ==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "esast-util-from-js": "^2.0.0", - "unified": "^11.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/recma-stringify": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/recma-stringify/-/recma-stringify-1.0.0.tgz", - "integrity": "sha512-cjwII1MdIIVloKvC9ErQ+OgAtwHBmcZ0Bg4ciz78FtbT8In39aAYbaA7zvxQ61xVMSPE8WxhLwLbhif4Js2C+g==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "estree-util-to-js": "^2.0.0", - "unified": "^11.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/redis": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/redis/-/redis-5.0.1.tgz", - "integrity": "sha512-J8nqUjrfSq0E8NQkcHDZ4HdEQk5RMYjP3jZq02PE+ERiRxolbDNxPaTT4xh6tdrme+lJ86Goje9yMt9uzh23hQ==", - "license": "MIT", - "dependencies": { - "@redis/bloom": "5.0.1", - "@redis/client": "5.0.1", - "@redis/json": "5.0.1", - "@redis/search": "5.0.1", - "@redis/time-series": "5.0.1" - }, - "engines": { - "node": ">= 18" - } - }, - "node_modules/reflect.getprototypeof": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/reflect.getprototypeof/-/reflect.getprototypeof-1.0.10.tgz", - "integrity": "sha512-00o4I+DVrefhv+nX0ulyi3biSHCPDe+yLv5o/p6d/UVlirijB8E16FtfwSAi4g3tcqrQ4lRAqQSoFEZJehYEcw==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.9", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0", - "get-intrinsic": "^1.2.7", - "get-proto": "^1.0.1", - "which-builtin-type": "^1.2.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/regex": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/regex/-/regex-6.0.1.tgz", - "integrity": "sha512-uorlqlzAKjKQZ5P+kTJr3eeJGSVroLKoHmquUj4zHWuR+hEyNqlXsSKlYYF5F4NI6nl7tWCs0apKJ0lmfsXAPA==", - "license": "MIT", - "dependencies": { - "regex-utilities": "^2.3.0" - } - }, - "node_modules/regex-recursion": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/regex-recursion/-/regex-recursion-6.0.2.tgz", - "integrity": "sha512-0YCaSCq2VRIebiaUviZNs0cBz1kg5kVS2UKUfNIx8YVs1cN3AV7NTctO5FOKBA+UT2BPJIWZauYHPqJODG50cg==", - "license": "MIT", - "dependencies": { - "regex-utilities": "^2.3.0" - } - }, - "node_modules/regex-utilities": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/regex-utilities/-/regex-utilities-2.3.0.tgz", - "integrity": "sha512-8VhliFJAWRaUiVvREIiW2NXXTmHs4vMNnSzuJVhscgmGav3g9VDxLrQndI3dZZVVdp0ZO/5v0xmX516/7M9cng==", - "license": "MIT" - }, - "node_modules/regexp.prototype.flags": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.4.tgz", - "integrity": "sha512-dYqgNSZbDwkaJ2ceRd9ojCGjBq+mOm9LmtXnAnEGyHhN/5R7iDW2TRw3h+o/jCFxus3P2LfWIIiwowAjANm7IA==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "define-properties": "^1.2.1", - "es-errors": "^1.3.0", - "get-proto": "^1.0.1", - "gopd": "^1.2.0", - "set-function-name": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/rehype": { - "version": "13.0.2", - "resolved": "https://registry.npmjs.org/rehype/-/rehype-13.0.2.tgz", - "integrity": "sha512-j31mdaRFrwFRUIlxGeuPXXKWQxet52RBQRvCmzl5eCefn/KGbomK5GMHNMsOJf55fgo3qw5tST5neDuarDYR2A==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "rehype-parse": "^9.0.0", - "rehype-stringify": "^10.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/rehype-parse": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/rehype-parse/-/rehype-parse-9.0.1.tgz", - "integrity": "sha512-ksCzCD0Fgfh7trPDxr2rSylbwq9iYDkSn8TCDmEJ49ljEUBxDVCzCHv7QNzZOfODanX4+bWQ4WZqLCRWYLfhag==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "hast-util-from-html": "^2.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/rehype-raw": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/rehype-raw/-/rehype-raw-7.0.0.tgz", - "integrity": "sha512-/aE8hCfKlQeA8LmyeyQvQF3eBiLRGNlfBJEvWH7ivp9sBqs7TNqBL5X3v157rM4IFETqDnIOO+z5M/biZbo9Ww==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "hast-util-raw": "^9.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/rehype-recma": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/rehype-recma/-/rehype-recma-1.0.0.tgz", - "integrity": "sha512-lqA4rGUf1JmacCNWWZx0Wv1dHqMwxzsDWYMTowuplHF3xH0N/MmrZ/G3BDZnzAkRmxDadujCjaKM2hqYdCBOGw==", - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "@types/hast": "^3.0.0", - "hast-util-to-estree": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/rehype-stringify": { - "version": "10.0.1", - "resolved": "https://registry.npmjs.org/rehype-stringify/-/rehype-stringify-10.0.1.tgz", - "integrity": "sha512-k9ecfXHmIPuFVI61B9DeLPN0qFHfawM6RsuX48hoqlaKSF61RskNjSm1lI8PhBEM0MRdLxVVm4WmTqJQccH9mA==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "hast-util-to-html": "^9.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/relative-time-format": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/relative-time-format/-/relative-time-format-1.1.6.tgz", - "integrity": "sha512-aCv3juQw4hT1/P/OrVltKWLlp15eW1GRcwP1XdxHrPdZE9MtgqFpegjnTjLhi2m2WI9MT/hQQtE+tjEWG1hgkQ==", - "license": "MIT" - }, - "node_modules/remark-gfm": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/remark-gfm/-/remark-gfm-4.0.1.tgz", - "integrity": "sha512-1quofZ2RQ9EWdeN34S79+KExV1764+wCUGop5CPL1WGdD0ocPpu91lzPGbwWMECpEpd42kJGQwzRfyov9j4yNg==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-gfm": "^3.0.0", - "micromark-extension-gfm": "^3.0.0", - "remark-parse": "^11.0.0", - "remark-stringify": "^11.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/remark-mdx": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/remark-mdx/-/remark-mdx-3.1.0.tgz", - "integrity": "sha512-Ngl/H3YXyBV9RcRNdlYsZujAmhsxwzxpDzpDEhFBVAGthS4GDgnctpDjgFl/ULx5UEDzqtW1cyBSNKqYYrqLBA==", - "license": "MIT", - "dependencies": { - "mdast-util-mdx": "^3.0.0", - "micromark-extension-mdxjs": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/remark-parse": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/remark-parse/-/remark-parse-11.0.0.tgz", - "integrity": "sha512-FCxlKLNGknS5ba/1lmpYijMUzX2esxW5xQqjWxw2eHFfS2MSdaHVINFmhjo+qN1WhZhNimq0dZATN9pH0IDrpA==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-from-markdown": "^2.0.0", - "micromark-util-types": "^2.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/remark-rehype": { - "version": "11.1.2", - "resolved": "https://registry.npmjs.org/remark-rehype/-/remark-rehype-11.1.2.tgz", - "integrity": "sha512-Dh7l57ianaEoIpzbp0PC9UKAdCSVklD8E5Rpw7ETfbTl3FqcOOgq5q2LVDhgGCkaBv7p24JXikPdvhhmHvKMsw==", - "license": "MIT", - "dependencies": { - "@types/hast": "^3.0.0", - "@types/mdast": "^4.0.0", - "mdast-util-to-hast": "^13.0.0", - "unified": "^11.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/remark-smartypants": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/remark-smartypants/-/remark-smartypants-3.0.2.tgz", - "integrity": "sha512-ILTWeOriIluwEvPjv67v7Blgrcx+LZOkAUVtKI3putuhlZm84FnqDORNXPPm+HY3NdZOMhyDwZ1E+eZB/Df5dA==", - "license": "MIT", - "dependencies": { - "retext": "^9.0.0", - "retext-smartypants": "^6.0.0", - "unified": "^11.0.4", - "unist-util-visit": "^5.0.0" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/remark-stringify": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/remark-stringify/-/remark-stringify-11.0.0.tgz", - "integrity": "sha512-1OSmLd3awB/t8qdoEOMazZkNsfVTeY4fTsgzcQFdXNq8ToTN4ZGwrMnlda4K6smTFKD+GRV6O48i6Z4iKgPPpw==", - "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-to-markdown": "^2.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/request-light": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/request-light/-/request-light-0.7.0.tgz", - "integrity": "sha512-lMbBMrDoxgsyO+yB3sDcrDuX85yYt7sS8BfQd11jtbW/z5ZWgLZRcEGLsLoYw7I0WSUGQBs8CC8ScIxkTX1+6Q==", - "license": "MIT" - }, - "node_modules/require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/require-from-string": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", - "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/resolve": { - "version": "1.22.10", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.10.tgz", - "integrity": "sha512-NPRy+/ncIMeDlTAsuqwKIiferiawhefFJtkNSW0qZJEqMEb+qBt/77B/jGeeek+F0uOeN05CDa6HXbbIgtVX4w==", - "dev": true, - "license": "MIT", - "dependencies": { - "is-core-module": "^2.16.0", - "path-parse": "^1.0.7", - "supports-preserve-symlinks-flag": "^1.0.0" - }, - "bin": { - "resolve": "bin/resolve" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/resolve-from": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=4" - } - }, - "node_modules/resolve-pkg-maps": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz", - "integrity": "sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==", - "devOptional": true, - "license": "MIT", - "funding": { - "url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1" - } - }, - "node_modules/restructure": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/restructure/-/restructure-3.0.2.tgz", - "integrity": "sha512-gSfoiOEA0VPE6Tukkrr7I0RBdE0s7H1eFCDBk05l1KIQT1UIKNc5JZy6jdyW6eYH3aR3g5b3PuL77rq0hvwtAw==", - "license": "MIT" - }, - "node_modules/retext": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/retext/-/retext-9.0.0.tgz", - "integrity": "sha512-sbMDcpHCNjvlheSgMfEcVrZko3cDzdbe1x/e7G66dFp0Ff7Mldvi2uv6JkJQzdRcvLYE8CA8Oe8siQx8ZOgTcA==", - "license": "MIT", - "dependencies": { - "@types/nlcst": "^2.0.0", - "retext-latin": "^4.0.0", - "retext-stringify": "^4.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/retext-latin": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/retext-latin/-/retext-latin-4.0.0.tgz", - "integrity": "sha512-hv9woG7Fy0M9IlRQloq/N6atV82NxLGveq+3H2WOi79dtIYWN8OaxogDm77f8YnVXJL2VD3bbqowu5E3EMhBYA==", - "license": "MIT", - "dependencies": { - "@types/nlcst": "^2.0.0", - "parse-latin": "^7.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/retext-smartypants": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/retext-smartypants/-/retext-smartypants-6.2.0.tgz", - "integrity": "sha512-kk0jOU7+zGv//kfjXEBjdIryL1Acl4i9XNkHxtM7Tm5lFiCog576fjNC9hjoR7LTKQ0DsPWy09JummSsH1uqfQ==", - "license": "MIT", - "dependencies": { - "@types/nlcst": "^2.0.0", - "nlcst-to-string": "^4.0.0", - "unist-util-visit": "^5.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/retext-stringify": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/retext-stringify/-/retext-stringify-4.0.0.tgz", - "integrity": "sha512-rtfN/0o8kL1e+78+uxPTqu1Klt0yPzKuQ2BfWwwfgIUSayyzxpM1PJzkKt4V8803uB9qSy32MvI7Xep9khTpiA==", - "license": "MIT", - "dependencies": { - "@types/nlcst": "^2.0.0", - "nlcst-to-string": "^4.0.0", - "unified": "^11.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/reusify": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", - "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", - "license": "MIT", - "engines": { - "iojs": ">=1.0.0", - "node": ">=0.10.0" - } - }, - "node_modules/rollup": { - "version": "4.40.1", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.40.1.tgz", - "integrity": "sha512-C5VvvgCCyfyotVITIAv+4efVytl5F7wt+/I2i9q9GZcEXW9BP52YYOXC58igUi+LFZVHukErIIqQSWwv/M3WRw==", - "license": "MIT", - "dependencies": { - "@types/estree": "1.0.7" - }, - "bin": { - "rollup": "dist/bin/rollup" - }, - "engines": { - "node": ">=18.0.0", - "npm": ">=8.0.0" - }, - "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.40.1", - "@rollup/rollup-android-arm64": "4.40.1", - "@rollup/rollup-darwin-arm64": "4.40.1", - "@rollup/rollup-darwin-x64": "4.40.1", - "@rollup/rollup-freebsd-arm64": "4.40.1", - "@rollup/rollup-freebsd-x64": "4.40.1", - "@rollup/rollup-linux-arm-gnueabihf": "4.40.1", - "@rollup/rollup-linux-arm-musleabihf": "4.40.1", - "@rollup/rollup-linux-arm64-gnu": "4.40.1", - "@rollup/rollup-linux-arm64-musl": "4.40.1", - "@rollup/rollup-linux-loongarch64-gnu": "4.40.1", - "@rollup/rollup-linux-powerpc64le-gnu": "4.40.1", - "@rollup/rollup-linux-riscv64-gnu": "4.40.1", - "@rollup/rollup-linux-riscv64-musl": "4.40.1", - "@rollup/rollup-linux-s390x-gnu": "4.40.1", - "@rollup/rollup-linux-x64-gnu": "4.40.1", - "@rollup/rollup-linux-x64-musl": "4.40.1", - "@rollup/rollup-win32-arm64-msvc": "4.40.1", - "@rollup/rollup-win32-ia32-msvc": "4.40.1", - "@rollup/rollup-win32-x64-msvc": "4.40.1", - "fsevents": "~2.3.2" - } - }, - "node_modules/run-applescript": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/run-applescript/-/run-applescript-7.0.0.tgz", - "integrity": "sha512-9by4Ij99JUr/MCFBUkDKLWK3G9HVXmabKz9U5MlIAIuvuzkiOicRYs8XJLxX+xahD+mLiiCYDqF9dKAgtzKP1A==", - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/run-parallel": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", - "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT", - "dependencies": { - "queue-microtask": "^1.2.2" - } - }, - "node_modules/s.color": { - "version": "0.0.15", - "resolved": "https://registry.npmjs.org/s.color/-/s.color-0.0.15.tgz", - "integrity": "sha512-AUNrbEUHeKY8XsYr/DYpl+qk5+aM+DChopnWOPEzn8YKzOhv4l2zH6LzZms3tOZP3wwdOyc0RmTciyi46HLIuA==", - "devOptional": true, - "license": "MIT" - }, - "node_modules/safe-array-concat": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.1.3.tgz", - "integrity": "sha512-AURm5f0jYEOydBj7VQlVvDrjeFgthDdEF5H1dP+6mNpoXOMo1quQqJ4wvJDyRZ9+pO3kGWoOdmV08cSv2aJV6Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "call-bound": "^1.0.2", - "get-intrinsic": "^1.2.6", - "has-symbols": "^1.1.0", - "isarray": "^2.0.5" - }, - "engines": { - "node": ">=0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" - }, - "node_modules/safe-push-apply": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/safe-push-apply/-/safe-push-apply-1.0.0.tgz", - "integrity": "sha512-iKE9w/Z7xCzUMIZqdBsp6pEQvwuEebH4vdpjcDWnyzaI6yl6O9FHvVpmGelvEHNsoY6wGblkxR6Zty/h00WiSA==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "isarray": "^2.0.5" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/safe-regex-test": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.1.0.tgz", - "integrity": "sha512-x/+Cz4YrimQxQccJf5mKEbIa1NzeCRNI5Ecl/ekmlYaampdNLPalVyIcCZNNH3MvmqBugV5TMYZXv0ljslUlaw==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "es-errors": "^1.3.0", - "is-regex": "^1.2.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "dev": true, - "license": "MIT" - }, - "node_modules/sass-formatter": { - "version": "0.7.9", - "resolved": "https://registry.npmjs.org/sass-formatter/-/sass-formatter-0.7.9.tgz", - "integrity": "sha512-CWZ8XiSim+fJVG0cFLStwDvft1VI7uvXdCNJYXhDvowiv+DsbD1nXLiQ4zrE5UBvj5DWZJ93cwN0NX5PMsr1Pw==", - "devOptional": true, - "license": "MIT", - "dependencies": { - "suf-log": "^2.5.3" - } - }, - "node_modules/satori": { - "version": "0.12.2", - "resolved": "https://registry.npmjs.org/satori/-/satori-0.12.2.tgz", - "integrity": "sha512-3C/laIeE6UUe9A+iQ0A48ywPVCCMKCNSTU5Os101Vhgsjd3AAxGNjyq0uAA8kulMPK5n0csn8JlxPN9riXEjLA==", - "license": "MPL-2.0", - "dependencies": { - "@shuding/opentype.js": "1.4.0-beta.0", - "css-background-parser": "^0.1.0", - "css-box-shadow": "1.0.0-3", - "css-gradient-parser": "^0.0.16", - "css-to-react-native": "^3.0.0", - "emoji-regex": "^10.2.1", - "escape-html": "^1.0.3", - "linebreak": "^1.1.0", - "parse-css-color": "^0.2.1", - "postcss-value-parser": "^4.2.0", - "yoga-wasm-web": "^0.3.3" - }, - "engines": { - "node": ">=16" - } - }, - "node_modules/sax": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.1.tgz", - "integrity": "sha512-+aWOz7yVScEGoKNd4PA10LZ8sk0A/z5+nXQG5giUO5rprX9jgYsTdov9qCchZiPIZezbZH+jRut8nPodFAX4Jg==", - "license": "ISC" - }, - "node_modules/schema-dts": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/schema-dts/-/schema-dts-1.1.5.tgz", - "integrity": "sha512-RJr9EaCmsLzBX2NDiO5Z3ux2BVosNZN5jo0gWgsyKvxKIUL5R3swNvoorulAeL9kLB0iTSX7V6aokhla2m7xbg==", - "license": "Apache-2.0" - }, - "node_modules/seedrandom": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/seedrandom/-/seedrandom-3.0.5.tgz", - "integrity": "sha512-8OwmbklUNzwezjGInmZ+2clQmExQPvomqjL7LFqOYqtmuxRgQYqOD3mHaU+MvZn5FLUeVxVfQjwLZW/n/JFuqg==", - "license": "MIT" - }, - "node_modules/semver": { - "version": "7.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.1.tgz", - "integrity": "sha512-hlq8tAfn0m/61p4BVRcPzIGr6LKiMwo4VM6dGi6pt4qcRkmNzTcWq6eCEjEh+qXjkMDvPlOFFSGwQjoEa6gyMA==", - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/send": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/send/-/send-1.2.0.tgz", - "integrity": "sha512-uaW0WwXKpL9blXE2o0bRhoL2EGXIrZxQ2ZQ4mgcfoBxdFmQold+qWsD2jLrfZ0trjKL6vOw0j//eAwcALFjKSw==", - "license": "MIT", - "dependencies": { - "debug": "^4.3.5", - "encodeurl": "^2.0.0", - "escape-html": "^1.0.3", - "etag": "^1.8.1", - "fresh": "^2.0.0", - "http-errors": "^2.0.0", - "mime-types": "^3.0.1", - "ms": "^2.1.3", - "on-finished": "^2.4.1", - "range-parser": "^1.2.1", - "statuses": "^2.0.1" - }, - "engines": { - "node": ">= 18" - } - }, - "node_modules/server-destroy": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/server-destroy/-/server-destroy-1.0.1.tgz", - "integrity": "sha512-rb+9B5YBIEzYcD6x2VKidaa+cqYBJQKnU4oe4E3ANwRRN56yk/ua1YCJT1n21NTS8w6CcOclAKNP3PhdCXKYtQ==", - "license": "ISC" - }, - "node_modules/set-function-length": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", - "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", - "dev": true, - "license": "MIT", - "dependencies": { - "define-data-property": "^1.1.4", - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/set-function-name": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.2.tgz", - "integrity": "sha512-7PGFlmtwsEADb0WYyvCMa1t+yke6daIG4Wirafur5kcf+MhUnPms1UeR0CKQdTZD81yESwMHbtn+TR+dMviakQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "define-data-property": "^1.1.4", - "es-errors": "^1.3.0", - "functions-have-names": "^1.2.3", - "has-property-descriptors": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/set-proto": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/set-proto/-/set-proto-1.0.0.tgz", - "integrity": "sha512-RJRdvCo6IAnPdsvP/7m6bsQqNnn1FCBX5ZNtFL98MmFF/4xAIJTIg1YbHW5DC2W5SKZanrC6i4HsJqlajw/dZw==", - "dev": true, - "license": "MIT", - "dependencies": { - "dunder-proto": "^1.0.1", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/setprototypeof": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", - "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", - "license": "ISC" - }, - "node_modules/sharp": { - "version": "0.33.5", - "resolved": "https://registry.npmjs.org/sharp/-/sharp-0.33.5.tgz", - "integrity": "sha512-haPVm1EkS9pgvHrQ/F3Xy+hgcuMV0Wm9vfIBSiwZ05k+xgb0PkBQpGsAA/oWdDobNaZTH5ppvHtzCFbnSEwHVw==", - "hasInstallScript": true, - "license": "Apache-2.0", - "optional": true, - "dependencies": { - "color": "^4.2.3", - "detect-libc": "^2.0.3", - "semver": "^7.6.3" - }, - "engines": { - "node": "^18.17.0 || ^20.3.0 || >=21.0.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-darwin-arm64": "0.33.5", - "@img/sharp-darwin-x64": "0.33.5", - "@img/sharp-libvips-darwin-arm64": "1.0.4", - "@img/sharp-libvips-darwin-x64": "1.0.4", - "@img/sharp-libvips-linux-arm": "1.0.5", - "@img/sharp-libvips-linux-arm64": "1.0.4", - "@img/sharp-libvips-linux-s390x": "1.0.4", - "@img/sharp-libvips-linux-x64": "1.0.4", - "@img/sharp-libvips-linuxmusl-arm64": "1.0.4", - "@img/sharp-libvips-linuxmusl-x64": "1.0.4", - "@img/sharp-linux-arm": "0.33.5", - "@img/sharp-linux-arm64": "0.33.5", - "@img/sharp-linux-s390x": "0.33.5", - "@img/sharp-linux-x64": "0.33.5", - "@img/sharp-linuxmusl-arm64": "0.33.5", - "@img/sharp-linuxmusl-x64": "0.33.5", - "@img/sharp-wasm32": "0.33.5", - "@img/sharp-win32-ia32": "0.33.5", - "@img/sharp-win32-x64": "0.33.5" - } - }, - "node_modules/shebang-command": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", - "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "dev": true, - "license": "MIT", - "dependencies": { - "shebang-regex": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/shebang-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/shiki": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/shiki/-/shiki-3.2.1.tgz", - "integrity": "sha512-VML/2o1/KGYkEf/stJJ+s9Ypn7jUKQPomGLGYso4JJFMFxVDyPNsjsI3MB3KLjlMOeH44gyaPdXC6rik2WXvUQ==", - "license": "MIT", - "dependencies": { - "@shikijs/core": "3.2.1", - "@shikijs/engine-javascript": "3.2.1", - "@shikijs/engine-oniguruma": "3.2.1", - "@shikijs/langs": "3.2.1", - "@shikijs/themes": "3.2.1", - "@shikijs/types": "3.2.1", - "@shikijs/vscode-textmate": "^10.0.2", - "@types/hast": "^3.0.4" - } - }, - "node_modules/side-channel": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.0.tgz", - "integrity": "sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "object-inspect": "^1.13.3", - "side-channel-list": "^1.0.0", - "side-channel-map": "^1.0.1", - "side-channel-weakmap": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/side-channel-list": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.0.tgz", - "integrity": "sha512-FCLHtRD/gnpCiCHEiJLOwdmFP+wzCmDEkc9y7NsYxeF4u7Btsn1ZuwgwJGxImImHicJArLP4R0yX4c2KCrMrTA==", - "dev": true, - "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "object-inspect": "^1.13.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/side-channel-map": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz", - "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.5", - "object-inspect": "^1.13.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/side-channel-weakmap": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz", - "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.5", - "object-inspect": "^1.13.3", - "side-channel-map": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/simple-concat": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/simple-concat/-/simple-concat-1.0.1.tgz", - "integrity": "sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" - }, - "node_modules/simple-get": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/simple-get/-/simple-get-4.0.1.tgz", - "integrity": "sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT", - "dependencies": { - "decompress-response": "^6.0.0", - "once": "^1.3.1", - "simple-concat": "^1.0.0" - } - }, - "node_modules/simple-swizzle": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/simple-swizzle/-/simple-swizzle-0.2.2.tgz", - "integrity": "sha512-JA//kQgZtbuY83m+xT+tXJkmJncGMTFT+C+g2h2R9uxkYIrE2yy9sgmcLhCnw57/WSD+Eh3J97FPEDFnbXnDUg==", - "license": "MIT", - "optional": true, - "dependencies": { - "is-arrayish": "^0.3.1" - } - }, - "node_modules/sisteransi": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", - "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==", - "license": "MIT" - }, - "node_modules/sitemap": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/sitemap/-/sitemap-8.0.0.tgz", - "integrity": "sha512-+AbdxhM9kJsHtruUF39bwS/B0Fytw6Fr1o4ZAIAEqA6cke2xcoO2GleBw9Zw7nRzILVEgz7zBM5GiTJjie1G9A==", - "license": "MIT", - "dependencies": { - "@types/node": "^17.0.5", - "@types/sax": "^1.2.1", - "arg": "^5.0.0", - "sax": "^1.2.4" - }, - "bin": { - "sitemap": "dist/cli.js" - }, - "engines": { - "node": ">=14.0.0", - "npm": ">=6.0.0" - } - }, - "node_modules/sitemap/node_modules/@types/node": { - "version": "17.0.45", - "resolved": "https://registry.npmjs.org/@types/node/-/node-17.0.45.tgz", - "integrity": "sha512-w+tIMs3rq2afQdsPJlODhoUEKzFP1ayaoyl1CcnwtIlsVe7K7bA1NGm4s3PraqTLlXnbIN84zuBlxBWo1u9BLw==", - "license": "MIT" - }, - "node_modules/slugify": { - "version": "1.6.6", - "resolved": "https://registry.npmjs.org/slugify/-/slugify-1.6.6.tgz", - "integrity": "sha512-h+z7HKHYXj6wJU+AnS/+IH8Uh9fdcX1Lrhg1/VMdf9PwoBQXFcXiAdsy2tSK0P6gKwJLXp02r90ahUCqHk9rrw==", - "license": "MIT", - "engines": { - "node": ">=8.0.0" - } - }, - "node_modules/smartypants": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/smartypants/-/smartypants-0.2.2.tgz", - "integrity": "sha512-TzobUYoEft/xBtb2voRPryAUIvYguG0V7Tt3de79I1WfXgCwelqVsGuZSnu3GFGRZhXR90AeEYIM+icuB/S06Q==", - "license": "BSD-3-Clause", - "bin": { - "smartypants": "bin/smartypants.js", - "smartypantsu": "bin/smartypantsu.js" - } - }, - "node_modules/smol-toml": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/smol-toml/-/smol-toml-1.3.1.tgz", - "integrity": "sha512-tEYNll18pPKHroYSmLLrksq233j021G0giwW7P3D24jC54pQ5W5BXMsQ/Mvw1OJCmEYDgY+lrzT+3nNUtoNfXQ==", - "license": "BSD-3-Clause", - "engines": { - "node": ">= 18" - }, - "funding": { - "url": "https://github.com/sponsors/cyyynthia" - } - }, - "node_modules/source-map": { - "version": "0.7.4", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.4.tgz", - "integrity": "sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA==", - "license": "BSD-3-Clause", - "engines": { - "node": ">= 8" - } - }, - "node_modules/source-map-js": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", - "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/space-separated-tokens": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/space-separated-tokens/-/space-separated-tokens-2.0.2.tgz", - "integrity": "sha512-PEGlAwrG8yXGXRjW32fGbg66JAlOAwbObuqVoJpv/mRgoWDQfgH1wDPvtzWyUSNAXBGSk8h755YDbbcEy3SH2Q==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/stable-hash": { - "version": "0.0.5", - "resolved": "https://registry.npmjs.org/stable-hash/-/stable-hash-0.0.5.tgz", - "integrity": "sha512-+L3ccpzibovGXFK+Ap/f8LOS0ahMrHTf3xu7mMLSpEGU0EO9ucaysSylKo9eRDFNhWve/y275iPmIZ4z39a9iA==", - "dev": true, - "license": "MIT" - }, - "node_modules/statuses": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", - "integrity": "sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/stream-replace-string": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/stream-replace-string/-/stream-replace-string-2.0.0.tgz", - "integrity": "sha512-TlnjJ1C0QrmxRNrON00JvaFFlNh5TTG00APw23j74ET7gkQpTASi6/L2fuiav8pzK715HXtUeClpBTw2NPSn6w==", - "license": "MIT" - }, - "node_modules/string_decoder": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", - "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", - "license": "MIT", - "dependencies": { - "safe-buffer": "~5.2.0" - } - }, - "node_modules/string-width": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-7.2.0.tgz", - "integrity": "sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ==", - "license": "MIT", - "dependencies": { - "emoji-regex": "^10.3.0", - "get-east-asian-width": "^1.0.0", - "strip-ansi": "^7.1.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/string.prototype.codepointat": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/string.prototype.codepointat/-/string.prototype.codepointat-0.2.1.tgz", - "integrity": "sha512-2cBVCj6I4IOvEnjgO/hWqXjqBGsY+zwPmHl12Srk9IXSZ56Jwwmy+66XO5Iut/oQVR7t5ihYdLB0GMa4alEUcg==", - "license": "MIT" - }, - "node_modules/string.prototype.includes": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/string.prototype.includes/-/string.prototype.includes-2.0.1.tgz", - "integrity": "sha512-o7+c9bW6zpAdJHTtujeePODAhkuicdAryFsfVKwA+wGw89wJ4GTY484WTucM9hLtDEOpOvI+aHnzqnC5lHp4Rg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.3" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/string.prototype.trim": { - "version": "1.2.10", - "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.10.tgz", - "integrity": "sha512-Rs66F0P/1kedk5lyYyH9uBzuiI/kNRmwJAR9quK6VOtIpZ2G+hMZd+HQbbv25MgCA6gEffoMZYxlTod4WcdrKA==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "call-bound": "^1.0.2", - "define-data-property": "^1.1.4", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.5", - "es-object-atoms": "^1.0.0", - "has-property-descriptors": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/string.prototype.trimend": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.9.tgz", - "integrity": "sha512-G7Ok5C6E/j4SGfyLCloXTrngQIQU3PWtXGst3yM7Bea9FRURf1S42ZHlZZtsNque2FN2PoUhfZXYLNWwEr4dLQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "call-bound": "^1.0.2", - "define-properties": "^1.2.1", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/string.prototype.trimstart": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.8.tgz", - "integrity": "sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/stringify-entities": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/stringify-entities/-/stringify-entities-4.0.4.tgz", - "integrity": "sha512-IwfBptatlO+QCJUo19AqvrPNqlVMpW9YEL2LIVY+Rpv2qsjCGxaDLNRgeGsQWJhfItebuJhsGSLjaBbNSQ+ieg==", - "license": "MIT", - "dependencies": { - "character-entities-html4": "^2.0.0", - "character-entities-legacy": "^3.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/strip-ansi": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.0.tgz", - "integrity": "sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==", - "license": "MIT", - "dependencies": { - "ansi-regex": "^6.0.1" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/chalk/strip-ansi?sponsor=1" - } - }, - "node_modules/strip-bom": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", - "integrity": "sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=4" - } - }, - "node_modules/strip-json-comments": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", - "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/style-to-js": { - "version": "1.1.16", - "resolved": "https://registry.npmjs.org/style-to-js/-/style-to-js-1.1.16.tgz", - "integrity": "sha512-/Q6ld50hKYPH3d/r6nr117TZkHR0w0kGGIVfpG9N6D8NymRPM9RqCUv4pRpJ62E5DqOYx2AFpbZMyCPnjQCnOw==", - "license": "MIT", - "dependencies": { - "style-to-object": "1.0.8" - } - }, - "node_modules/style-to-object": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/style-to-object/-/style-to-object-1.0.8.tgz", - "integrity": "sha512-xT47I/Eo0rwJmaXC4oilDGDWLohVhR6o/xAQcPQN8q6QBuZVL8qMYL85kLmST5cPjAorwvqIA4qXTRQoYHaL6g==", - "license": "MIT", - "dependencies": { - "inline-style-parser": "0.2.4" - } - }, - "node_modules/suf-log": { - "version": "2.5.3", - "resolved": "https://registry.npmjs.org/suf-log/-/suf-log-2.5.3.tgz", - "integrity": "sha512-KvC8OPjzdNOe+xQ4XWJV2whQA0aM1kGVczMQ8+dStAO6KfEB140JEVQ9dE76ONZ0/Ylf67ni4tILPJB41U0eow==", - "devOptional": true, - "license": "MIT", - "dependencies": { - "s.color": "0.0.15" - } - }, - "node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/supports-preserve-symlinks-flag": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", - "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/svgo": { - "version": "3.3.2", - "resolved": "https://registry.npmjs.org/svgo/-/svgo-3.3.2.tgz", - "integrity": "sha512-OoohrmuUlBs8B8o6MB2Aevn+pRIH9zDALSR+6hhqVfa6fRwG/Qw9VUMSMW9VNg2CFc/MTIfabtdOVl9ODIJjpw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@trysound/sax": "0.2.0", - "commander": "^7.2.0", - "css-select": "^5.1.0", - "css-tree": "^2.3.1", - "css-what": "^6.1.0", - "csso": "^5.0.5", - "picocolors": "^1.0.0" - }, - "bin": { - "svgo": "bin/svgo" - }, - "engines": { - "node": ">=14.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/svgo" - } - }, - "node_modules/svgo/node_modules/commander": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", - "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 10" - } - }, - "node_modules/synckit": { - "version": "0.9.2", - "resolved": "https://registry.npmjs.org/synckit/-/synckit-0.9.2.tgz", - "integrity": "sha512-vrozgXDQwYO72vHjUb/HnFbQx1exDjoKzqx23aXEg2a9VIg2TSFZ8FmeZpTjUCFMYw7mpX4BE2SFu8wI7asYsw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@pkgr/core": "^0.1.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": "^14.18.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/unts" - } - }, - "node_modules/tailwind-htmx": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/tailwind-htmx/-/tailwind-htmx-0.1.2.tgz", - "integrity": "sha512-EJhlT7PWARTucn8mOZ3P5Jnk7GaaY6bD/p3YSg5AumXEXhGcKHP7FpRysjpgjFdY1Y4S5+taBCkWIDJwW7ffIw==", - "dev": true - }, - "node_modules/tailwind-merge": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/tailwind-merge/-/tailwind-merge-3.3.0.tgz", - "integrity": "sha512-fyW/pEfcQSiigd5SNn0nApUOxx0zB/dm6UDU/rEwc2c3sX2smWUNbapHv+QRqLGVp9GWX3THIa7MUGPo+YkDzQ==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/dcastil" - } - }, - "node_modules/tailwind-variants": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/tailwind-variants/-/tailwind-variants-1.0.0.tgz", - "integrity": "sha512-2WSbv4ulEEyuBKomOunut65D8UZwxrHoRfYnxGcQNnHqlSCp2+B7Yz2W+yrNDrxRodOXtGD/1oCcKGNBnUqMqA==", - "license": "MIT", - "dependencies": { - "tailwind-merge": "3.0.2" - }, - "engines": { - "node": ">=16.x", - "pnpm": ">=7.x" - }, - "peerDependencies": { - "tailwindcss": "*" - } - }, - "node_modules/tailwind-variants/node_modules/tailwind-merge": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/tailwind-merge/-/tailwind-merge-3.0.2.tgz", - "integrity": "sha512-l7z+OYZ7mu3DTqrL88RiKrKIqO3NcpEO8V/Od04bNpvk0kiIFndGEoqfuzvj4yuhRkHKjRkII2z+KS2HfPcSxw==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/dcastil" - } - }, - "node_modules/tailwindcss": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-4.1.7.tgz", - "integrity": "sha512-kr1o/ErIdNhTz8uzAYL7TpaUuzKIE6QPQ4qmSdxnoX/lo+5wmUHQA6h3L5yIqEImSRnAAURDirLu/BgiXGPAhg==", - "license": "MIT" - }, - "node_modules/tapable": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.2.1.tgz", - "integrity": "sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/tar": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/tar/-/tar-6.2.1.tgz", - "integrity": "sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==", - "dev": true, - "license": "ISC", - "dependencies": { - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "minipass": "^5.0.0", - "minizlib": "^2.1.1", - "mkdirp": "^1.0.3", - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/tar-fs": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.2.tgz", - "integrity": "sha512-EsaAXwxmx8UB7FRKqeozqEPop69DXcmYwTQwXvyAPF352HJsPdkVhvTaDPYqfNgruveJIJy3TA2l+2zj8LJIJA==", - "license": "MIT", - "dependencies": { - "chownr": "^1.1.1", - "mkdirp-classic": "^0.5.2", - "pump": "^3.0.0", - "tar-stream": "^2.1.4" - } - }, - "node_modules/tar-fs/node_modules/chownr": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.4.tgz", - "integrity": "sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==", - "license": "ISC" - }, - "node_modules/tar-stream": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-2.2.0.tgz", - "integrity": "sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==", - "license": "MIT", - "dependencies": { - "bl": "^4.0.3", - "end-of-stream": "^1.4.1", - "fs-constants": "^1.0.0", - "inherits": "^2.0.3", - "readable-stream": "^3.1.1" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/tar/node_modules/minipass": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-5.0.0.tgz", - "integrity": "sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=8" - } - }, - "node_modules/tiny-inflate": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/tiny-inflate/-/tiny-inflate-1.0.3.tgz", - "integrity": "sha512-pkY1fj1cKHb2seWDy0B16HeWyczlJA9/WW3u3c4z/NiWDsO3DOU5D7nhTLE9CF0yXv/QZFY7sEJmj24dK+Rrqw==", - "license": "MIT" - }, - "node_modules/tinyexec": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-0.3.2.tgz", - "integrity": "sha512-KQQR9yN7R5+OSwaK0XQoj22pwHoTlgYqmUscPYoknOoWCWfj/5/ABTMRi69FrKU5ffPVh5QcFikpWJI/P1ocHA==", - "license": "MIT" - }, - "node_modules/tinyglobby": { - "version": "0.2.13", - "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.13.tgz", - "integrity": "sha512-mEwzpUgrLySlveBwEVDMKk5B57bhLPYovRfPAXD5gA/98Opn0rCDj3GtLwFvCvH5RK9uPCExUROW5NjDwvqkxw==", - "license": "MIT", - "dependencies": { - "fdir": "^6.4.4", - "picomatch": "^4.0.2" - }, - "engines": { - "node": ">=12.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/SuperchupuDev" - } - }, - "node_modules/to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "license": "MIT", - "dependencies": { - "is-number": "^7.0.0" - }, - "engines": { - "node": ">=8.0" - } - }, - "node_modules/toidentifier": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", - "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", - "license": "MIT", - "engines": { - "node": ">=0.6" - } - }, - "node_modules/tr46": { - "version": "0.0.3", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", - "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==", - "license": "MIT" - }, - "node_modules/trim-lines": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/trim-lines/-/trim-lines-3.0.1.tgz", - "integrity": "sha512-kRj8B+YHZCc9kQYdWfJB2/oUl9rA99qbowYYBtr4ui4mZyAQ2JpvVBd/6U2YloATfqBhBTSMhTpgBHtU0Mf3Rg==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/trough": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/trough/-/trough-2.2.0.tgz", - "integrity": "sha512-tmMpK00BjZiUyVyvrBK7knerNgmgvcV/KLVyuma/SC+TQN167GrMRciANTz09+k3zW8L8t60jWO1GpfkZdjTaw==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/ts-api-utils": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/ts-api-utils/-/ts-api-utils-2.1.0.tgz", - "integrity": "sha512-CUgTZL1irw8u29bzrOD/nH85jqyc74D6SshFgujOIA7osm2Rz7dYH77agkx7H4FBNxDq7Cjf+IjaX/8zwFW+ZQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18.12" - }, - "peerDependencies": { - "typescript": ">=4.8.4" - } - }, - "node_modules/ts-essentials": { - "version": "10.0.4", - "resolved": "https://registry.npmjs.org/ts-essentials/-/ts-essentials-10.0.4.tgz", - "integrity": "sha512-lwYdz28+S4nicm+jFi6V58LaAIpxzhg9rLdgNC1VsdP/xiFBseGhF1M/shwCk6zMmwahBZdXcl34LVHrEang3A==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "typescript": ">=4.5.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/ts-toolbelt": { - "version": "9.6.0", - "resolved": "https://registry.npmjs.org/ts-toolbelt/-/ts-toolbelt-9.6.0.tgz", - "integrity": "sha512-nsZd8ZeNUzukXPlJmTBwUAuABDe/9qtVDelJeT/qW0ow3ZS3BsQJtNkan1802aM9Uf68/Y8ljw86Hu0h5IUW3w==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/tsconfck": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/tsconfck/-/tsconfck-3.1.5.tgz", - "integrity": "sha512-CLDfGgUp7XPswWnezWwsCRxNmgQjhYq3VXHM0/XIRxhVrKw0M1if9agzryh1QS3nxjCROvV+xWxoJO1YctzzWg==", - "license": "MIT", - "bin": { - "tsconfck": "bin/tsconfck.js" - }, - "engines": { - "node": "^18 || >=20" - }, - "peerDependencies": { - "typescript": "^5.0.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/tsconfig-paths": { - "version": "3.15.0", - "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.15.0.tgz", - "integrity": "sha512-2Ac2RgzDe/cn48GvOe3M+o82pEFewD3UPbyoUHHdKasHwJKjds4fLXWf/Ux5kATBKN20oaFGu+jbElp1pos0mg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@types/json5": "^0.0.29", - "json5": "^1.0.2", - "minimist": "^1.2.6", - "strip-bom": "^3.0.0" - } - }, - "node_modules/tslib": { - "version": "2.8.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", - "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", - "license": "0BSD" - }, - "node_modules/tsx": { - "version": "4.19.4", - "resolved": "https://registry.npmjs.org/tsx/-/tsx-4.19.4.tgz", - "integrity": "sha512-gK5GVzDkJK1SI1zwHf32Mqxf2tSJkNx+eYcNly5+nHvWqXUJYUkWBQtKauoESz3ymezAI++ZwT855x5p5eop+Q==", - "devOptional": true, - "license": "MIT", - "dependencies": { - "esbuild": "~0.25.0", - "get-tsconfig": "^4.7.5" - }, - "bin": { - "tsx": "dist/cli.mjs" - }, - "engines": { - "node": ">=18.0.0" - }, - "optionalDependencies": { - "fsevents": "~2.3.3" - } - }, - "node_modules/tunnel-agent": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", - "integrity": "sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==", - "license": "Apache-2.0", - "dependencies": { - "safe-buffer": "^5.0.1" - }, - "engines": { - "node": "*" - } - }, - "node_modules/type-check": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", - "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", - "dev": true, - "license": "MIT", - "dependencies": { - "prelude-ls": "^1.2.1" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/type-fest": { - "version": "4.32.0", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.32.0.tgz", - "integrity": "sha512-rfgpoi08xagF3JSdtJlCwMq9DGNDE0IMh3Mkpc1wUypg9vPi786AiqeBBKcqvIkq42azsBM85N490fyZjeUftw==", - "license": "(MIT OR CC0-1.0)", - "engines": { - "node": ">=16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/typed-array-buffer": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.3.tgz", - "integrity": "sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "es-errors": "^1.3.0", - "is-typed-array": "^1.1.14" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/typed-array-byte-length": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.3.tgz", - "integrity": "sha512-BaXgOuIxz8n8pIq3e7Atg/7s+DpiYrxn4vdot3w9KbnBhcRQq6o3xemQdIfynqSeXeDrF32x+WvfzmOjPiY9lg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "for-each": "^0.3.3", - "gopd": "^1.2.0", - "has-proto": "^1.2.0", - "is-typed-array": "^1.1.14" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/typed-array-byte-offset": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.4.tgz", - "integrity": "sha512-bTlAFB/FBYMcuX81gbL4OcpH5PmlFHqlCCpAl8AlEzMz5k53oNDvN8p1PNOWLEmI2x4orp3raOFB51tv9X+MFQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.8", - "for-each": "^0.3.3", - "gopd": "^1.2.0", - "has-proto": "^1.2.0", - "is-typed-array": "^1.1.15", - "reflect.getprototypeof": "^1.0.9" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/typed-array-length": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.7.tgz", - "integrity": "sha512-3KS2b+kL7fsuk/eJZ7EQdnEmQoaho/r6KUef7hxvltNA5DR8NAUM+8wJMbJyZ4G9/7i3v5zPBIMN5aybAh2/Jg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "for-each": "^0.3.3", - "gopd": "^1.0.1", - "is-typed-array": "^1.1.13", - "possible-typed-array-names": "^1.0.0", - "reflect.getprototypeof": "^1.0.6" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/typesafe-path": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/typesafe-path/-/typesafe-path-0.2.2.tgz", - "integrity": "sha512-OJabfkAg1WLZSqJAJ0Z6Sdt3utnbzr/jh+NAHoyWHJe8CMSy79Gm085094M9nvTPy22KzTVn5Zq5mbapCI/hPA==", - "license": "MIT" - }, - "node_modules/typescript": { - "version": "5.8.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", - "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", - "license": "Apache-2.0", - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, - "engines": { - "node": ">=14.17" - } - }, - "node_modules/typescript-auto-import-cache": { - "version": "0.3.5", - "resolved": "https://registry.npmjs.org/typescript-auto-import-cache/-/typescript-auto-import-cache-0.3.5.tgz", - "integrity": "sha512-fAIveQKsoYj55CozUiBoj4b/7WpN0i4o74wiGY5JVUEoD0XiqDk1tJqTEjgzL2/AizKQrXxyRosSebyDzBZKjw==", - "license": "MIT", - "dependencies": { - "semver": "^7.3.8" - } - }, - "node_modules/typescript-eslint": { - "version": "8.32.1", - "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.32.1.tgz", - "integrity": "sha512-D7el+eaDHAmXvrZBy1zpzSNIRqnCOrkwTgZxTu3MUqRWk8k0q9m9Ho4+vPf7iHtgUfrK/o8IZaEApsxPlHTFCg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/eslint-plugin": "8.32.1", - "@typescript-eslint/parser": "8.32.1", - "@typescript-eslint/utils": "8.32.1" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependencies": { - "eslint": "^8.57.0 || ^9.0.0", - "typescript": ">=4.8.4 <5.9.0" - } - }, - "node_modules/ufo": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/ufo/-/ufo-1.5.4.tgz", - "integrity": "sha512-UsUk3byDzKd04EyoZ7U4DOlxQaD14JUKQl6/P7wiX4FNvUfm3XL246n9W5AmqwW5RSFJ27NAuM0iLscAOYUiGQ==", - "license": "MIT" - }, - "node_modules/ultrahtml": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/ultrahtml/-/ultrahtml-1.6.0.tgz", - "integrity": "sha512-R9fBn90VTJrqqLDwyMph+HGne8eqY1iPfYhPzZrvKpIfwkWZbcYlfpsb8B9dTvBfpy1/hqAD7Wi8EKfP9e8zdw==", - "license": "MIT" - }, - "node_modules/unbox-primitive": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.1.0.tgz", - "integrity": "sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.3", - "has-bigints": "^1.0.2", - "has-symbols": "^1.1.0", - "which-boxed-primitive": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/uncrypto": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/uncrypto/-/uncrypto-0.1.3.tgz", - "integrity": "sha512-Ql87qFHB3s/De2ClA9e0gsnS6zXG27SkTiSJwjCc9MebbfapQfuPzumMIUMi38ezPZVNFcHI9sUIepeQfw8J8Q==", - "license": "MIT" - }, - "node_modules/undici": { - "version": "6.21.3", - "resolved": "https://registry.npmjs.org/undici/-/undici-6.21.3.tgz", - "integrity": "sha512-gBLkYIlEnSp8pFbT64yFgGE6UIB9tAkhukC23PmMDCe5Nd+cRqKxSjw5y54MK2AZMgZfJWMaNE4nYUHgi1XEOw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18.17" - } - }, - "node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "license": "MIT" - }, - "node_modules/unicode-properties": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/unicode-properties/-/unicode-properties-1.4.1.tgz", - "integrity": "sha512-CLjCCLQ6UuMxWnbIylkisbRj31qxHPAurvena/0iwSVbQ2G1VY5/HjV0IRabOEbDHlzZlRdCrD4NhB0JtU40Pg==", - "license": "MIT", - "dependencies": { - "base64-js": "^1.3.0", - "unicode-trie": "^2.0.0" - } - }, - "node_modules/unicode-trie": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/unicode-trie/-/unicode-trie-2.0.0.tgz", - "integrity": "sha512-x7bc76x0bm4prf1VLg79uhAzKw8DVboClSN5VxJuQ+LKDOVEW9CdH+VY7SP+vX7xCYQqzzgQpFqz15zeLvAtZQ==", - "license": "MIT", - "dependencies": { - "pako": "^0.2.5", - "tiny-inflate": "^1.0.0" - } - }, - "node_modules/unified": { - "version": "11.0.5", - "resolved": "https://registry.npmjs.org/unified/-/unified-11.0.5.tgz", - "integrity": "sha512-xKvGhPWw3k84Qjh8bI3ZeJjqnyadK+GEFtazSfZv/rKeTkTjOJho6mFqh2SM96iIcZokxiOpg78GazTSg8+KHA==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "bail": "^2.0.0", - "devlop": "^1.0.0", - "extend": "^3.0.0", - "is-plain-obj": "^4.0.0", - "trough": "^2.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unifont": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/unifont/-/unifont-0.5.0.tgz", - "integrity": "sha512-4DueXMP5Hy4n607sh+vJ+rajoLu778aU3GzqeTCqsD/EaUcvqZT9wPC8kgK6Vjh22ZskrxyRCR71FwNOaYn6jA==", - "license": "MIT", - "dependencies": { - "css-tree": "^3.0.0", - "ohash": "^2.0.0" - } - }, - "node_modules/unifont/node_modules/css-tree": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-3.1.0.tgz", - "integrity": "sha512-0eW44TGN5SQXU1mWSkKwFstI/22X2bG1nYzZTYMAWjylYURhse752YgbE4Cx46AC+bAvI+/dYTPRk1LqSUnu6w==", - "license": "MIT", - "dependencies": { - "mdn-data": "2.12.2", - "source-map-js": "^1.0.1" - }, - "engines": { - "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0" - } - }, - "node_modules/unifont/node_modules/mdn-data": { - "version": "2.12.2", - "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.12.2.tgz", - "integrity": "sha512-IEn+pegP1aManZuckezWCO+XZQDplx1366JoVhTpMpBB1sPey/SbveZQUosKiKiGYjg1wH4pMlNgXbCiYgihQA==", - "license": "CC0-1.0" - }, - "node_modules/unique-username-generator": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/unique-username-generator/-/unique-username-generator-1.4.0.tgz", - "integrity": "sha512-Y6CY5vLPeixB5V4t6b/y7KkOPWpbANCIln4O6MRzz2uPIxzDm6KshWxJKMeAxLU2EPyCK+ptw/YeZMkZPFv2bw==", - "license": "MIT" - }, - "node_modules/unist-util-find-after": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/unist-util-find-after/-/unist-util-find-after-5.0.0.tgz", - "integrity": "sha512-amQa0Ep2m6hE2g72AugUItjbuM8X8cGQnFoHk0pGfrFeT9GZhzN5SW8nRsiGKK7Aif4CrACPENkA6P/Lw6fHGQ==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-is": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-is": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-6.0.0.tgz", - "integrity": "sha512-2qCTHimwdxLfz+YzdGfkqNlH0tLi9xjTnHddPmJwtIG9MGsdbutfTc4P+haPD7l7Cjxf/WZj+we5qfVPvvxfYw==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-modify-children": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/unist-util-modify-children/-/unist-util-modify-children-4.0.0.tgz", - "integrity": "sha512-+tdN5fGNddvsQdIzUF3Xx82CU9sMM+fA0dLgR9vOmT0oPT2jH+P1nd5lSqfCfXAw+93NhcXNY2qqvTUtE4cQkw==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "array-iterate": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-position": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/unist-util-position/-/unist-util-position-5.0.0.tgz", - "integrity": "sha512-fucsC7HjXvkB5R3kTCO7kUjRdrS0BJt3M/FPxmHMBOm8JQi2BsHAHFsy27E0EolP8rp0NzXsJ+jNPyDWvOJZPA==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-position-from-estree": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/unist-util-position-from-estree/-/unist-util-position-from-estree-2.0.0.tgz", - "integrity": "sha512-KaFVRjoqLyF6YXCbVLNad/eS4+OfPQQn2yOd7zF/h5T/CSL2v8NpN6a5TPvtbXthAGw5nG+PuTtq+DdIZr+cRQ==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-remove-position": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/unist-util-remove-position/-/unist-util-remove-position-5.0.0.tgz", - "integrity": "sha512-Hp5Kh3wLxv0PHj9m2yZhhLt58KzPtEYKQQ4yxfYFEO7EvHwzyDYnduhHnY1mDxoqr7VUwVuHXk9RXKIiYS1N8Q==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-visit": "^5.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-stringify-position": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/unist-util-stringify-position/-/unist-util-stringify-position-4.0.0.tgz", - "integrity": "sha512-0ASV06AAoKCDkS2+xw5RXJywruurpbC4JZSm7nr7MOt1ojAzvyyaO+UxZf18j8FCF6kmzCZKcAgN/yu2gm2XgQ==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-visit": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-5.0.0.tgz", - "integrity": "sha512-MR04uvD+07cwl/yhVuVWAtw+3GOR/knlL55Nd/wAdblk27GCVt3lqpTivy/tkJcZoNPzTwS1Y+KMojlLDhoTzg==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-is": "^6.0.0", - "unist-util-visit-parents": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-visit-children": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/unist-util-visit-children/-/unist-util-visit-children-3.0.0.tgz", - "integrity": "sha512-RgmdTfSBOg04sdPcpTSD1jzoNBjt9a80/ZCzp5cI9n1qPzLZWF9YdvWGN2zmTumP1HWhXKdUWexjy/Wy/lJ7tA==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-visit-parents": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-6.0.1.tgz", - "integrity": "sha512-L/PqWzfTP9lzzEa6CKs0k2nARxTdZduw3zyh8d2NVBnsyvHjSX4TWse388YrrQKbvI8w20fGjGlhgT96WwKykw==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-is": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unrs-resolver": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/unrs-resolver/-/unrs-resolver-1.7.2.tgz", - "integrity": "sha512-BBKpaylOW8KbHsu378Zky/dGh4ckT/4NW/0SHRABdqRLcQJ2dAOjDo9g97p04sWflm0kqPqpUatxReNV/dqI5A==", - "dev": true, - "hasInstallScript": true, - "license": "MIT", - "dependencies": { - "napi-postinstall": "^0.2.2" - }, - "funding": { - "url": "https://github.com/sponsors/JounQin" - }, - "optionalDependencies": { - "@unrs/resolver-binding-darwin-arm64": "1.7.2", - "@unrs/resolver-binding-darwin-x64": "1.7.2", - "@unrs/resolver-binding-freebsd-x64": "1.7.2", - "@unrs/resolver-binding-linux-arm-gnueabihf": "1.7.2", - "@unrs/resolver-binding-linux-arm-musleabihf": "1.7.2", - "@unrs/resolver-binding-linux-arm64-gnu": "1.7.2", - "@unrs/resolver-binding-linux-arm64-musl": "1.7.2", - "@unrs/resolver-binding-linux-ppc64-gnu": "1.7.2", - "@unrs/resolver-binding-linux-riscv64-gnu": "1.7.2", - "@unrs/resolver-binding-linux-riscv64-musl": "1.7.2", - "@unrs/resolver-binding-linux-s390x-gnu": "1.7.2", - "@unrs/resolver-binding-linux-x64-gnu": "1.7.2", - "@unrs/resolver-binding-linux-x64-musl": "1.7.2", - "@unrs/resolver-binding-wasm32-wasi": "1.7.2", - "@unrs/resolver-binding-win32-arm64-msvc": "1.7.2", - "@unrs/resolver-binding-win32-ia32-msvc": "1.7.2", - "@unrs/resolver-binding-win32-x64-msvc": "1.7.2" - } - }, - "node_modules/unstorage": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/unstorage/-/unstorage-1.15.0.tgz", - "integrity": "sha512-m40eHdGY/gA6xAPqo8eaxqXgBuzQTlAKfmB1iF7oCKXE1HfwHwzDJBywK+qQGn52dta+bPlZluPF7++yR3p/bg==", - "license": "MIT", - "dependencies": { - "anymatch": "^3.1.3", - "chokidar": "^4.0.3", - "destr": "^2.0.3", - "h3": "^1.15.0", - "lru-cache": "^10.4.3", - "node-fetch-native": "^1.6.6", - "ofetch": "^1.4.1", - "ufo": "^1.5.4" - }, - "peerDependencies": { - "@azure/app-configuration": "^1.8.0", - "@azure/cosmos": "^4.2.0", - "@azure/data-tables": "^13.3.0", - "@azure/identity": "^4.6.0", - "@azure/keyvault-secrets": "^4.9.0", - "@azure/storage-blob": "^12.26.0", - "@capacitor/preferences": "^6.0.3", - "@deno/kv": ">=0.9.0", - "@netlify/blobs": "^6.5.0 || ^7.0.0 || ^8.1.0", - "@planetscale/database": "^1.19.0", - "@upstash/redis": "^1.34.3", - "@vercel/blob": ">=0.27.1", - "@vercel/kv": "^1.0.1", - "aws4fetch": "^1.0.20", - "db0": ">=0.2.1", - "idb-keyval": "^6.2.1", - "ioredis": "^5.4.2", - "uploadthing": "^7.4.4" - }, - "peerDependenciesMeta": { - "@azure/app-configuration": { - "optional": true - }, - "@azure/cosmos": { - "optional": true - }, - "@azure/data-tables": { - "optional": true - }, - "@azure/identity": { - "optional": true - }, - "@azure/keyvault-secrets": { - "optional": true - }, - "@azure/storage-blob": { - "optional": true - }, - "@capacitor/preferences": { - "optional": true - }, - "@deno/kv": { - "optional": true - }, - "@netlify/blobs": { - "optional": true - }, - "@planetscale/database": { - "optional": true - }, - "@upstash/redis": { - "optional": true - }, - "@vercel/blob": { - "optional": true - }, - "@vercel/kv": { - "optional": true - }, - "aws4fetch": { - "optional": true - }, - "db0": { - "optional": true - }, - "idb-keyval": { - "optional": true - }, - "ioredis": { - "optional": true - }, - "uploadthing": { - "optional": true - } - } - }, - "node_modules/uri-js": { - "version": "4.4.1", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", - "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "punycode": "^2.1.0" - } - }, - "node_modules/util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", - "license": "MIT" - }, - "node_modules/vfile": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/vfile/-/vfile-6.0.3.tgz", - "integrity": "sha512-KzIbH/9tXat2u30jf+smMwFCsno4wHVdNmzFyL+T/L3UGqqk6JKfVqOFOZEpZSHADH1k40ab6NUIXZq422ov3Q==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "vfile-message": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/vfile-location": { - "version": "5.0.3", - "resolved": "https://registry.npmjs.org/vfile-location/-/vfile-location-5.0.3.tgz", - "integrity": "sha512-5yXvWDEgqeiYiBe1lbxYF7UMAIm/IcopxMHrMQDq3nvKcjPKIhZklUKL+AE7J7uApI4kwe2snsK+eI6UTj9EHg==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "vfile": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/vfile-message": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/vfile-message/-/vfile-message-4.0.2.tgz", - "integrity": "sha512-jRDZ1IMLttGj41KcZvlrYAaI3CfqpLpfpf+Mfig13viT6NKvRzWZ+lXz0Y5D60w6uJIBAOGq9mSHf0gktF0duw==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-stringify-position": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/vite": { - "version": "6.3.4", - "resolved": "https://registry.npmjs.org/vite/-/vite-6.3.4.tgz", - "integrity": "sha512-BiReIiMS2fyFqbqNT/Qqt4CVITDU9M9vE+DKcVAsB+ZV0wvTKd+3hMbkpxz1b+NmEDMegpVbisKiAZOnvO92Sw==", - "license": "MIT", - "dependencies": { - "esbuild": "^0.25.0", - "fdir": "^6.4.4", - "picomatch": "^4.0.2", - "postcss": "^8.5.3", - "rollup": "^4.34.9", - "tinyglobby": "^0.2.13" - }, - "bin": { - "vite": "bin/vite.js" - }, - "engines": { - "node": "^18.0.0 || ^20.0.0 || >=22.0.0" - }, - "funding": { - "url": "https://github.com/vitejs/vite?sponsor=1" - }, - "optionalDependencies": { - "fsevents": "~2.3.3" - }, - "peerDependencies": { - "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", - "jiti": ">=1.21.0", - "less": "*", - "lightningcss": "^1.21.0", - "sass": "*", - "sass-embedded": "*", - "stylus": "*", - "sugarss": "*", - "terser": "^5.16.0", - "tsx": "^4.8.1", - "yaml": "^2.4.2" - }, - "peerDependenciesMeta": { - "@types/node": { - "optional": true - }, - "jiti": { - "optional": true - }, - "less": { - "optional": true - }, - "lightningcss": { - "optional": true - }, - "sass": { - "optional": true - }, - "sass-embedded": { - "optional": true - }, - "stylus": { - "optional": true - }, - "sugarss": { - "optional": true - }, - "terser": { - "optional": true - }, - "tsx": { - "optional": true - }, - "yaml": { - "optional": true - } - } - }, - "node_modules/vitefu": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/vitefu/-/vitefu-1.0.6.tgz", - "integrity": "sha512-+Rex1GlappUyNN6UfwbVZne/9cYC4+R2XDk9xkNXBKMw6HQagdX9PgZ8V2v1WUSK1wfBLp7qbI1+XSNIlB1xmA==", - "license": "MIT", - "workspaces": [ - "tests/deps/*", - "tests/projects/*" - ], - "peerDependencies": { - "vite": "^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0" - }, - "peerDependenciesMeta": { - "vite": { - "optional": true - } - } - }, - "node_modules/volar-service-css": { - "version": "0.0.62", - "resolved": "https://registry.npmjs.org/volar-service-css/-/volar-service-css-0.0.62.tgz", - "integrity": "sha512-JwNyKsH3F8PuzZYuqPf+2e+4CTU8YoyUHEHVnoXNlrLe7wy9U3biomZ56llN69Ris7TTy/+DEX41yVxQpM4qvg==", - "license": "MIT", - "dependencies": { - "vscode-css-languageservice": "^6.3.0", - "vscode-languageserver-textdocument": "^1.0.11", - "vscode-uri": "^3.0.8" - }, - "peerDependencies": { - "@volar/language-service": "~2.4.0" - }, - "peerDependenciesMeta": { - "@volar/language-service": { - "optional": true - } - } - }, - "node_modules/volar-service-emmet": { - "version": "0.0.62", - "resolved": "https://registry.npmjs.org/volar-service-emmet/-/volar-service-emmet-0.0.62.tgz", - "integrity": "sha512-U4dxWDBWz7Pi4plpbXf4J4Z/ss6kBO3TYrACxWNsE29abu75QzVS0paxDDhI6bhqpbDFXlpsDhZ9aXVFpnfGRQ==", - "license": "MIT", - "dependencies": { - "@emmetio/css-parser": "^0.4.0", - "@emmetio/html-matcher": "^1.3.0", - "@vscode/emmet-helper": "^2.9.3", - "vscode-uri": "^3.0.8" - }, - "peerDependencies": { - "@volar/language-service": "~2.4.0" - }, - "peerDependenciesMeta": { - "@volar/language-service": { - "optional": true - } - } - }, - "node_modules/volar-service-html": { - "version": "0.0.62", - "resolved": "https://registry.npmjs.org/volar-service-html/-/volar-service-html-0.0.62.tgz", - "integrity": "sha512-Zw01aJsZRh4GTGUjveyfEzEqpULQUdQH79KNEiKVYHZyuGtdBRYCHlrus1sueSNMxwwkuF5WnOHfvBzafs8yyQ==", - "license": "MIT", - "dependencies": { - "vscode-html-languageservice": "^5.3.0", - "vscode-languageserver-textdocument": "^1.0.11", - "vscode-uri": "^3.0.8" - }, - "peerDependencies": { - "@volar/language-service": "~2.4.0" - }, - "peerDependenciesMeta": { - "@volar/language-service": { - "optional": true - } - } - }, - "node_modules/volar-service-prettier": { - "version": "0.0.62", - "resolved": "https://registry.npmjs.org/volar-service-prettier/-/volar-service-prettier-0.0.62.tgz", - "integrity": "sha512-h2yk1RqRTE+vkYZaI9KYuwpDfOQRrTEMvoHol0yW4GFKc75wWQRrb5n/5abDrzMPrkQbSip8JH2AXbvrRtYh4w==", - "license": "MIT", - "dependencies": { - "vscode-uri": "^3.0.8" - }, - "peerDependencies": { - "@volar/language-service": "~2.4.0", - "prettier": "^2.2 || ^3.0" - }, - "peerDependenciesMeta": { - "@volar/language-service": { - "optional": true - }, - "prettier": { - "optional": true - } - } - }, - "node_modules/volar-service-typescript": { - "version": "0.0.62", - "resolved": "https://registry.npmjs.org/volar-service-typescript/-/volar-service-typescript-0.0.62.tgz", - "integrity": "sha512-p7MPi71q7KOsH0eAbZwPBiKPp9B2+qrdHAd6VY5oTo9BUXatsOAdakTm9Yf0DUj6uWBAaOT01BSeVOPwucMV1g==", - "license": "MIT", - "dependencies": { - "path-browserify": "^1.0.1", - "semver": "^7.6.2", - "typescript-auto-import-cache": "^0.3.3", - "vscode-languageserver-textdocument": "^1.0.11", - "vscode-nls": "^5.2.0", - "vscode-uri": "^3.0.8" - }, - "peerDependencies": { - "@volar/language-service": "~2.4.0" - }, - "peerDependenciesMeta": { - "@volar/language-service": { - "optional": true - } - } - }, - "node_modules/volar-service-typescript-twoslash-queries": { - "version": "0.0.62", - "resolved": "https://registry.npmjs.org/volar-service-typescript-twoslash-queries/-/volar-service-typescript-twoslash-queries-0.0.62.tgz", - "integrity": "sha512-KxFt4zydyJYYI0kFAcWPTh4u0Ha36TASPZkAnNY784GtgajerUqM80nX/W1d0wVhmcOFfAxkVsf/Ed+tiYU7ng==", - "license": "MIT", - "dependencies": { - "vscode-uri": "^3.0.8" - }, - "peerDependencies": { - "@volar/language-service": "~2.4.0" - }, - "peerDependenciesMeta": { - "@volar/language-service": { - "optional": true - } - } - }, - "node_modules/volar-service-yaml": { - "version": "0.0.62", - "resolved": "https://registry.npmjs.org/volar-service-yaml/-/volar-service-yaml-0.0.62.tgz", - "integrity": "sha512-k7gvv7sk3wa+nGll3MaSKyjwQsJjIGCHFjVkl3wjaSP2nouKyn9aokGmqjrl39mi88Oy49giog2GkZH526wjig==", - "license": "MIT", - "dependencies": { - "vscode-uri": "^3.0.8", - "yaml-language-server": "~1.15.0" - }, - "peerDependencies": { - "@volar/language-service": "~2.4.0" - }, - "peerDependenciesMeta": { - "@volar/language-service": { - "optional": true - } - } - }, - "node_modules/vscode-css-languageservice": { - "version": "6.3.4", - "resolved": "https://registry.npmjs.org/vscode-css-languageservice/-/vscode-css-languageservice-6.3.4.tgz", - "integrity": "sha512-qutdhFg4hnlf6IsOynwtfsN8W0Xc7g3SZd+KK9F2moUEjHtkcZoj5p8uH7BSwHx9hSEXjwKgSRRyHTXThfwAkQ==", - "license": "MIT", - "dependencies": { - "@vscode/l10n": "^0.0.18", - "vscode-languageserver-textdocument": "^1.0.12", - "vscode-languageserver-types": "3.17.5", - "vscode-uri": "^3.1.0" - } - }, - "node_modules/vscode-html-languageservice": { - "version": "5.3.3", - "resolved": "https://registry.npmjs.org/vscode-html-languageservice/-/vscode-html-languageservice-5.3.3.tgz", - "integrity": "sha512-AK/jJM0VIWRrlfqkDBMZxNMnxYT5I2uoMVRoNJ5ePSplnSaT9mbYjqJlxxeLvUrOW7MEH0vVIDzU48u44QZE0w==", - "license": "MIT", - "dependencies": { - "@vscode/l10n": "^0.0.18", - "vscode-languageserver-textdocument": "^1.0.12", - "vscode-languageserver-types": "^3.17.5", - "vscode-uri": "^3.1.0" - } - }, - "node_modules/vscode-json-languageservice": { - "version": "4.1.8", - "resolved": "https://registry.npmjs.org/vscode-json-languageservice/-/vscode-json-languageservice-4.1.8.tgz", - "integrity": "sha512-0vSpg6Xd9hfV+eZAaYN63xVVMOTmJ4GgHxXnkLCh+9RsQBkWKIghzLhW2B9ebfG+LQQg8uLtsQ2aUKjTgE+QOg==", - "license": "MIT", - "dependencies": { - "jsonc-parser": "^3.0.0", - "vscode-languageserver-textdocument": "^1.0.1", - "vscode-languageserver-types": "^3.16.0", - "vscode-nls": "^5.0.0", - "vscode-uri": "^3.0.2" - }, - "engines": { - "npm": ">=7.0.0" - } - }, - "node_modules/vscode-json-languageservice/node_modules/jsonc-parser": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.3.1.tgz", - "integrity": "sha512-HUgH65KyejrUFPvHFPbqOY0rsFip3Bo5wb4ngvdi1EpCYWUQDC5V+Y7mZws+DLkr4M//zQJoanu1SP+87Dv1oQ==", - "license": "MIT" - }, - "node_modules/vscode-jsonrpc": { - "version": "8.2.0", - "resolved": "https://registry.npmjs.org/vscode-jsonrpc/-/vscode-jsonrpc-8.2.0.tgz", - "integrity": "sha512-C+r0eKJUIfiDIfwJhria30+TYWPtuHJXHtI7J0YlOmKAo7ogxP20T0zxB7HZQIFhIyvoBPwWskjxrvAtfjyZfA==", - "license": "MIT", - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/vscode-languageserver": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/vscode-languageserver/-/vscode-languageserver-9.0.1.tgz", - "integrity": "sha512-woByF3PDpkHFUreUa7Hos7+pUWdeWMXRd26+ZX2A8cFx6v/JPTtd4/uN0/jB6XQHYaOlHbio03NTHCqrgG5n7g==", - "license": "MIT", - "dependencies": { - "vscode-languageserver-protocol": "3.17.5" - }, - "bin": { - "installServerIntoExtension": "bin/installServerIntoExtension" - } - }, - "node_modules/vscode-languageserver-protocol": { - "version": "3.17.5", - "resolved": "https://registry.npmjs.org/vscode-languageserver-protocol/-/vscode-languageserver-protocol-3.17.5.tgz", - "integrity": "sha512-mb1bvRJN8SVznADSGWM9u/b07H7Ecg0I3OgXDuLdn307rl/J3A9YD6/eYOssqhecL27hK1IPZAsaqh00i/Jljg==", - "license": "MIT", - "dependencies": { - "vscode-jsonrpc": "8.2.0", - "vscode-languageserver-types": "3.17.5" - } - }, - "node_modules/vscode-languageserver-textdocument": { - "version": "1.0.12", - "resolved": "https://registry.npmjs.org/vscode-languageserver-textdocument/-/vscode-languageserver-textdocument-1.0.12.tgz", - "integrity": "sha512-cxWNPesCnQCcMPeenjKKsOCKQZ/L6Tv19DTRIGuLWe32lyzWhihGVJ/rcckZXJxfdKCFvRLS3fpBIsV/ZGX4zA==", - "license": "MIT" - }, - "node_modules/vscode-languageserver-types": { - "version": "3.17.5", - "resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.17.5.tgz", - "integrity": "sha512-Ld1VelNuX9pdF39h2Hgaeb5hEZM2Z3jUrrMgWQAu82jMtZp7p3vJT3BzToKtZI7NgQssZje5o0zryOrhQvzQAg==", - "license": "MIT" - }, - "node_modules/vscode-nls": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/vscode-nls/-/vscode-nls-5.2.0.tgz", - "integrity": "sha512-RAaHx7B14ZU04EU31pT+rKz2/zSl7xMsfIZuo8pd+KZO6PXtQmpevpq3vxvWNcrGbdmhM/rr5Uw5Mz+NBfhVng==", - "license": "MIT" - }, - "node_modules/vscode-uri": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/vscode-uri/-/vscode-uri-3.1.0.tgz", - "integrity": "sha512-/BpdSx+yCQGnCvecbyXdxHDkuk55/G3xwnC0GqY4gmQ3j+A+g8kzzgB4Nk/SINjqn6+waqw3EgbVF2QKExkRxQ==", - "license": "MIT" - }, - "node_modules/web-namespaces": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/web-namespaces/-/web-namespaces-2.0.1.tgz", - "integrity": "sha512-bKr1DkiNa2krS7qxNtdrtHAmzuYGFQLiQ13TsorsdT6ULTkPLKuu5+GsFpDlg6JFjUTwX2DyhMPG2be8uPrqsQ==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/web-streams-polyfill": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/web-streams-polyfill/-/web-streams-polyfill-3.3.3.tgz", - "integrity": "sha512-d2JWLCivmZYTSIoge9MsgFCZrt571BikcWGYkjC1khllbTeDlGqZ2D8vD8E/lJa8WGWbb7Plm8/XJYV7IJHZZw==", - "license": "MIT", - "engines": { - "node": ">= 8" - } - }, - "node_modules/webidl-conversions": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", - "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==", - "license": "BSD-2-Clause" - }, - "node_modules/whatwg-encoding": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", - "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "iconv-lite": "0.6.3" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/whatwg-mimetype": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", - "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - } - }, - "node_modules/whatwg-url": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", - "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", - "license": "MIT", - "dependencies": { - "tr46": "~0.0.3", - "webidl-conversions": "^3.0.0" - } - }, - "node_modules/which": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "dev": true, - "license": "ISC", - "dependencies": { - "isexe": "^2.0.0" - }, - "bin": { - "node-which": "bin/node-which" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/which-boxed-primitive": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.1.1.tgz", - "integrity": "sha512-TbX3mj8n0odCBFVlY8AxkqcHASw3L60jIuF8jFP78az3C2YhmGvqbHBpAjTRH2/xqYunrJ9g1jSyjCjpoWzIAA==", - "dev": true, - "license": "MIT", - "dependencies": { - "is-bigint": "^1.1.0", - "is-boolean-object": "^1.2.1", - "is-number-object": "^1.1.1", - "is-string": "^1.1.1", - "is-symbol": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/which-builtin-type": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/which-builtin-type/-/which-builtin-type-1.2.1.tgz", - "integrity": "sha512-6iBczoX+kDQ7a3+YJBnh3T+KZRxM/iYNPXicqk66/Qfm1b93iu+yOImkg0zHbj5LNOcNv1TEADiZ0xa34B4q6Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.2", - "function.prototype.name": "^1.1.6", - "has-tostringtag": "^1.0.2", - "is-async-function": "^2.0.0", - "is-date-object": "^1.1.0", - "is-finalizationregistry": "^1.1.0", - "is-generator-function": "^1.0.10", - "is-regex": "^1.2.1", - "is-weakref": "^1.0.2", - "isarray": "^2.0.5", - "which-boxed-primitive": "^1.1.0", - "which-collection": "^1.0.2", - "which-typed-array": "^1.1.16" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/which-collection": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.2.tgz", - "integrity": "sha512-K4jVyjnBdgvc86Y6BkaLZEN933SwYOuBFkdmBu9ZfkcAbdVbpITnDmjvZ/aQjRXQrv5EPkTnD1s39GiiqbngCw==", - "dev": true, - "license": "MIT", - "dependencies": { - "is-map": "^2.0.3", - "is-set": "^2.0.3", - "is-weakmap": "^2.0.2", - "is-weakset": "^2.0.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/which-pm-runs": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/which-pm-runs/-/which-pm-runs-1.1.0.tgz", - "integrity": "sha512-n1brCuqClxfFfq/Rb0ICg9giSZqCS+pLtccdag6C2HyufBrh3fBOiy9nb6ggRMvWOVH5GrdJskj5iGTZNxd7SA==", - "license": "MIT", - "engines": { - "node": ">=4" - } - }, - "node_modules/which-typed-array": { - "version": "1.1.18", - "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.18.tgz", - "integrity": "sha512-qEcY+KJYlWyLH9vNbsr6/5j59AXk5ni5aakf8ldzBvGde6Iz4sxZGkJyWSAueTG7QhOvNRYb1lDdFmL5Td0QKA==", - "dev": true, - "license": "MIT", - "dependencies": { - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.8", - "call-bound": "^1.0.3", - "for-each": "^0.3.3", - "gopd": "^1.2.0", - "has-tostringtag": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/widest-line": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/widest-line/-/widest-line-5.0.0.tgz", - "integrity": "sha512-c9bZp7b5YtRj2wOe6dlj32MK+Bx/M/d+9VB2SHM1OtsUHR0aV0tdP6DWh/iMt0kWi1t5g1Iudu6hQRNd1A4PVA==", - "license": "MIT", - "dependencies": { - "string-width": "^7.0.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/word-wrap": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", - "integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/wrap-ansi": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-9.0.0.tgz", - "integrity": "sha512-G8ura3S+3Z2G+mkgNRq8dqaFZAuxfsxpBB8OCTGRTCtp+l/v9nbFNmCUP1BZMts3G1142MsZfn6eeUKrr4PD1Q==", - "license": "MIT", - "dependencies": { - "ansi-styles": "^6.2.1", - "string-width": "^7.0.0", - "strip-ansi": "^7.1.0" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, - "node_modules/wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", - "license": "ISC" - }, - "node_modules/ws": { - "version": "8.18.0", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.18.0.tgz", - "integrity": "sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw==", - "license": "MIT", - "engines": { - "node": ">=10.0.0" - }, - "peerDependencies": { - "bufferutil": "^4.0.1", - "utf-8-validate": ">=5.0.2" - }, - "peerDependenciesMeta": { - "bufferutil": { - "optional": true - }, - "utf-8-validate": { - "optional": true - } - } - }, - "node_modules/xtend": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", - "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", - "license": "MIT", - "optional": true, - "peer": true, - "engines": { - "node": ">=0.4" - } - }, - "node_modules/xxhash-wasm": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/xxhash-wasm/-/xxhash-wasm-1.1.0.tgz", - "integrity": "sha512-147y/6YNh+tlp6nd/2pWq38i9h6mz/EuQ6njIrmW8D1BS5nCqs0P6DG+m6zTGnNz5I+uhZ0SHxBs9BsPrwcKDA==", - "license": "MIT" - }, - "node_modules/y18n": { - "version": "5.0.8", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", - "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", - "license": "ISC", - "engines": { - "node": ">=10" - } - }, - "node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true, - "license": "ISC" - }, - "node_modules/yaml": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.7.0.tgz", - "integrity": "sha512-+hSoy/QHluxmC9kCIJyL/uyFmLmc+e5CFR5Wa+bpIhIj85LVb9ZH2nVnqrHoSvKogwODv0ClqZkmiSSaIH5LTA==", - "license": "ISC", - "bin": { - "yaml": "bin.mjs" - }, - "engines": { - "node": ">= 14" - } - }, - "node_modules/yaml-language-server": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/yaml-language-server/-/yaml-language-server-1.15.0.tgz", - "integrity": "sha512-N47AqBDCMQmh6mBLmI6oqxryHRzi33aPFPsJhYy3VTUGCdLHYjGh4FZzpUjRlphaADBBkDmnkM/++KNIOHi5Rw==", - "license": "MIT", - "dependencies": { - "ajv": "^8.11.0", - "lodash": "4.17.21", - "request-light": "^0.5.7", - "vscode-json-languageservice": "4.1.8", - "vscode-languageserver": "^7.0.0", - "vscode-languageserver-textdocument": "^1.0.1", - "vscode-languageserver-types": "^3.16.0", - "vscode-nls": "^5.0.0", - "vscode-uri": "^3.0.2", - "yaml": "2.2.2" - }, - "bin": { - "yaml-language-server": "bin/yaml-language-server" - }, - "optionalDependencies": { - "prettier": "2.8.7" - } - }, - "node_modules/yaml-language-server/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/yaml-language-server/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "license": "MIT" - }, - "node_modules/yaml-language-server/node_modules/prettier": { - "version": "2.8.7", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.7.tgz", - "integrity": "sha512-yPngTo3aXUUmyuTjeTUT75txrf+aMh9FiD7q9ZE/i6r0bPb22g4FsE6Y338PQX1bmfy08i9QQCB7/rcUAVntfw==", - "license": "MIT", - "optional": true, - "bin": { - "prettier": "bin-prettier.js" - }, - "engines": { - "node": ">=10.13.0" - }, - "funding": { - "url": "https://github.com/prettier/prettier?sponsor=1" - } - }, - "node_modules/yaml-language-server/node_modules/request-light": { - "version": "0.5.8", - "resolved": "https://registry.npmjs.org/request-light/-/request-light-0.5.8.tgz", - "integrity": "sha512-3Zjgh+8b5fhRJBQZoy+zbVKpAQGLyka0MPgW3zruTF4dFFJ8Fqcfu9YsAvi/rvdcaTeWG3MkbZv4WKxAn/84Lg==", - "license": "MIT" - }, - "node_modules/yaml-language-server/node_modules/vscode-jsonrpc": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/vscode-jsonrpc/-/vscode-jsonrpc-6.0.0.tgz", - "integrity": "sha512-wnJA4BnEjOSyFMvjZdpiOwhSq9uDoK8e/kpRJDTaMYzwlkrhG1fwDIZI94CLsLzlCK5cIbMMtFlJlfR57Lavmg==", - "license": "MIT", - "engines": { - "node": ">=8.0.0 || >=10.0.0" - } - }, - "node_modules/yaml-language-server/node_modules/vscode-languageserver": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/vscode-languageserver/-/vscode-languageserver-7.0.0.tgz", - "integrity": "sha512-60HTx5ID+fLRcgdHfmz0LDZAXYEV68fzwG0JWwEPBode9NuMYTIxuYXPg4ngO8i8+Ou0lM7y6GzaYWbiDL0drw==", - "license": "MIT", - "dependencies": { - "vscode-languageserver-protocol": "3.16.0" - }, - "bin": { - "installServerIntoExtension": "bin/installServerIntoExtension" - } - }, - "node_modules/yaml-language-server/node_modules/vscode-languageserver-protocol": { - "version": "3.16.0", - "resolved": "https://registry.npmjs.org/vscode-languageserver-protocol/-/vscode-languageserver-protocol-3.16.0.tgz", - "integrity": "sha512-sdeUoAawceQdgIfTI+sdcwkiK2KU+2cbEYA0agzM2uqaUy2UpnnGHtWTHVEtS0ES4zHU0eMFRGN+oQgDxlD66A==", - "license": "MIT", - "dependencies": { - "vscode-jsonrpc": "6.0.0", - "vscode-languageserver-types": "3.16.0" - } - }, - "node_modules/yaml-language-server/node_modules/vscode-languageserver-types": { - "version": "3.16.0", - "resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.16.0.tgz", - "integrity": "sha512-k8luDIWJWyenLc5ToFQQMaSrqCHiLwyKPHKPQZ5zz21vM+vIVUSvsRpcbiECH4WR88K2XZqc4ScRcZ7nk/jbeA==", - "license": "MIT" - }, - "node_modules/yaml-language-server/node_modules/yaml": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.2.2.tgz", - "integrity": "sha512-CBKFWExMn46Foo4cldiChEzn7S7SRV+wqiluAb6xmueD/fGyRHIhX8m14vVGgeFWjN540nKCNVj6P21eQjgTuA==", - "license": "ISC", - "engines": { - "node": ">= 14" - } - }, - "node_modules/yargs": { - "version": "17.7.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", - "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", - "license": "MIT", - "dependencies": { - "cliui": "^8.0.1", - "escalade": "^3.1.1", - "get-caller-file": "^2.0.5", - "require-directory": "^2.1.1", - "string-width": "^4.2.3", - "y18n": "^5.0.5", - "yargs-parser": "^21.1.1" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/yargs-parser": { - "version": "21.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", - "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", - "license": "ISC", - "engines": { - "node": ">=12" - } - }, - "node_modules/yargs/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/emoji-regex": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", - "license": "MIT" - }, - "node_modules/yargs/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "license": "MIT", - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "license": "MIT", - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/yauzl": { - "version": "2.10.0", - "resolved": "https://registry.npmjs.org/yauzl/-/yauzl-2.10.0.tgz", - "integrity": "sha512-p4a9I6X6nu6IhoGmBqAcbJy1mlC4j27vEPZX9F4L4/vZT3Lyq1VkFHw/V/PUcB9Buo+DG3iHkT0x3Qya58zc3g==", - "dev": true, - "license": "MIT", - "dependencies": { - "buffer-crc32": "~0.2.3", - "fd-slicer": "~1.1.0" - } - }, - "node_modules/yocto-queue": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-1.1.1.tgz", - "integrity": "sha512-b4JR1PFR10y1mKjhHY9LaGo6tmrgjit7hxVIeAmyMw3jegXR4dhYqLaQF5zMXZxY7tLpMyJeLjr1C4rLmkVe8g==", - "license": "MIT", - "engines": { - "node": ">=12.20" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/yocto-spinner": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/yocto-spinner/-/yocto-spinner-0.2.1.tgz", - "integrity": "sha512-lHHxjh0bXaLgdJy3cNnVb/F9myx3CkhrvSOEVTkaUgNMXnYFa2xYPVhtGnqhh3jErY2gParBOHallCbc7NrlZQ==", - "license": "MIT", - "dependencies": { - "yoctocolors": "^2.1.1" - }, - "engines": { - "node": ">=18.19" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/yoctocolors": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/yoctocolors/-/yoctocolors-2.1.1.tgz", - "integrity": "sha512-GQHQqAopRhwU8Kt1DDM8NjibDXHC8eoh1erhGAJPEyveY9qqVeXvVikNKrDz69sHowPMorbPUrH/mx8c50eiBQ==", - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/yoga-wasm-web": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/yoga-wasm-web/-/yoga-wasm-web-0.3.3.tgz", - "integrity": "sha512-N+d4UJSJbt/R3wqY7Coqs5pcV0aUj2j9IaQ3rNj9bVCLld8tTGKRa2USARjnvZJWVx1NDmQev8EknoczaOQDOA==", - "license": "MIT" - }, - "node_modules/zod": { - "version": "3.24.2", - "resolved": "https://registry.npmjs.org/zod/-/zod-3.24.2.tgz", - "integrity": "sha512-lY7CDW43ECgW9u1TcT3IoXHflywfVqDYze4waEz812jR/bZ8FHDsl7pFQoSZTz5N+2NqRXs8GBwnAwo3ZNxqhQ==", - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/colinhacks" - } - }, - "node_modules/zod-form-data": { - "version": "2.0.7", - "resolved": "https://registry.npmjs.org/zod-form-data/-/zod-form-data-2.0.7.tgz", - "integrity": "sha512-O27uzKMx7qc7z51KXER326Fp966jqHGvZX3i18CbvElF/QqVsQQN6Q7BnzepkzeBzTJnU3golibVSagf4dp7RQ==", - "license": "MIT", - "dependencies": { - "@rvf/set-get": "^7.0.0" - }, - "peerDependencies": { - "zod": ">= 3.11.0" - } - }, - "node_modules/zod-to-json-schema": { - "version": "3.24.5", - "resolved": "https://registry.npmjs.org/zod-to-json-schema/-/zod-to-json-schema-3.24.5.tgz", - "integrity": "sha512-/AuWwMP+YqiPbsJx5D6TfgRTc4kTLjsh5SOcd4bLsfUg2RcEXrFMJl1DGgdHy2aCfsIA/cr/1JM0xcB2GZji8g==", - "license": "ISC", - "peerDependencies": { - "zod": "^3.24.1" - } - }, - "node_modules/zod-to-ts": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/zod-to-ts/-/zod-to-ts-1.2.0.tgz", - "integrity": "sha512-x30XE43V+InwGpvTySRNz9kB7qFU8DlyEy7BsSTCHPH1R0QasMmHWZDCzYm6bVXtj/9NNJAZF3jW8rzFvH5OFA==", - "peerDependencies": { - "typescript": "^4.9.4 || ^5.0.2", - "zod": "^3" - } - }, - "node_modules/zwitch": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/zwitch/-/zwitch-2.0.4.tgz", - "integrity": "sha512-bXE4cR/kVZhKZX/RjPEflHaKVhUVl85noU3v6b8apfQEc1x4A+zBxjZ4lN8LqGd6WZ3dl98pY4o717VFmoPp+A==", - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - } - } -} diff --git a/web/package.json b/web/package.json deleted file mode 100644 index fe20ef2..0000000 --- a/web/package.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "name": "kycnot.me", - "type": "module", - "version": "0.0.1", - "scripts": { - "dev": "astro dev", - "build": "astro build --remote", - "preview": "astro preview", - "astro": "astro", - "db-admin": "prisma studio --browser=none", - "db-gen": "prisma generate", - "db-push": "prisma migrate dev", - "db-triggers": "just import-triggers", - "db-update": "prisma migrate dev && just import-triggers", - "db-reset": "prisma migrate reset && prisma migrate dev && just import-triggers && tsx scripts/faker.ts", - "db-fill": "tsx scripts/faker.ts", - "db-fill-clean": "tsx scripts/faker.ts --cleanup", - "format": "prettier --write .", - "lint": "eslint .", - "lint-fix": "eslint . --fix && prettier --write ." - }, - "dependencies": { - "@astrojs/check": "0.9.4", - "@astrojs/db": "0.14.14", - "@astrojs/mdx": "4.2.6", - "@astrojs/node": "9.2.1", - "@astrojs/sitemap": "3.4.0", - "@fontsource-variable/space-grotesk": "5.2.7", - "@fontsource/inter": "5.2.5", - "@prisma/client": "6.8.2", - "@tailwindcss/vite": "4.1.7", - "@types/mime-types": "2.1.4", - "@vercel/og": "0.6.8", - "astro": "5.7.13", - "astro-loading-indicator": "0.7.0", - "astro-remote": "0.3.4", - "astro-seo-schema": "5.0.0", - "canvas": "3.1.0", - "clsx": "2.1.1", - "htmx.org": "1.9.12", - "javascript-time-ago": "2.5.11", - "libphonenumber-js": "1.12.8", - "lodash-es": "4.17.21", - "mime-types": "3.0.1", - "object-to-formdata": "4.5.1", - "react": "19.1.0", - "redis": "5.0.1", - "schema-dts": "1.1.5", - "seedrandom": "3.0.5", - "slugify": "1.6.6", - "tailwind-merge": "3.3.0", - "tailwind-variants": "1.0.0", - "tailwindcss": "4.1.7", - "typescript": "5.8.3", - "unique-username-generator": "1.4.0", - "zod-form-data": "2.0.7" - }, - "devDependencies": { - "@eslint/js": "9.27.0", - "@faker-js/faker": "9.8.0", - "@iconify-json/material-symbols": "1.2.21", - "@iconify-json/mdi": "1.2.3", - "@iconify-json/ri": "1.2.5", - "@stylistic/eslint-plugin": "4.2.0", - "@tailwindcss/forms": "0.5.10", - "@tailwindcss/typography": "0.5.16", - "@types/eslint__js": "9.14.0", - "@types/lodash-es": "4.17.12", - "@types/react": "19.1.4", - "@types/seedrandom": "3.0.8", - "@typescript-eslint/parser": "8.32.1", - "astro-icon": "1.1.5", - "date-fns": "4.1.0", - "eslint": "9.27.0", - "eslint-import-resolver-typescript": "4.3.5", - "eslint-plugin-astro": "1.3.1", - "eslint-plugin-import": "2.31.0", - "eslint-plugin-jsx-a11y": "6.10.2", - "globals": "16.1.0", - "prettier": "3.5.3", - "prettier-plugin-astro": "0.14.1", - "prettier-plugin-tailwindcss": "0.6.11", - "prisma": "6.8.2", - "prisma-json-types-generator": "3.4.1", - "tailwind-htmx": "0.1.2", - "ts-essentials": "10.0.4", - "ts-toolbelt": "9.6.0", - "tsx": "4.19.4", - "typescript-eslint": "8.32.1" - } -} diff --git a/web/prisma/migrations/20250518085822_initial/migration.sql b/web/prisma/migrations/20250518085822_initial/migration.sql deleted file mode 100644 index df254e8..0000000 --- a/web/prisma/migrations/20250518085822_initial/migration.sql +++ /dev/null @@ -1,798 +0,0 @@ --- CreateEnum -CREATE TYPE "CommentStatus" AS ENUM ('PENDING', 'HUMAN_PENDING', 'APPROVED', 'VERIFIED', 'REJECTED'); - --- CreateEnum -CREATE TYPE "OrderIdStatus" AS ENUM ('PENDING', 'APPROVED', 'REJECTED'); - --- CreateEnum -CREATE TYPE "VerificationStatus" AS ENUM ('COMMUNITY_CONTRIBUTED', 'APPROVED', 'VERIFICATION_SUCCESS', 'VERIFICATION_FAILED'); - --- CreateEnum -CREATE TYPE "ServiceInfoBanner" AS ENUM ('NONE', 'NO_LONGER_OPERATIONAL'); - --- CreateEnum -CREATE TYPE "ServiceVisibility" AS ENUM ('PUBLIC', 'UNLISTED', 'HIDDEN'); - --- CreateEnum -CREATE TYPE "Currency" AS ENUM ('MONERO', 'BITCOIN', 'LIGHTNING', 'FIAT', 'CASH'); - --- CreateEnum -CREATE TYPE "EventType" AS ENUM ('WARNING', 'WARNING_SOLVED', 'ALERT', 'ALERT_SOLVED', 'INFO', 'NORMAL', 'UPDATE'); - --- CreateEnum -CREATE TYPE "ServiceUserRole" AS ENUM ('OWNER', 'ADMIN', 'MODERATOR', 'SUPPORT', 'TEAM_MEMBER'); - --- CreateEnum -CREATE TYPE "AccountStatusChange" AS ENUM ('ADMIN_TRUE', 'ADMIN_FALSE', 'VERIFIED_TRUE', 'VERIFIED_FALSE', 'VERIFIER_TRUE', 'VERIFIER_FALSE', 'SPAMMER_TRUE', 'SPAMMER_FALSE'); - --- CreateEnum -CREATE TYPE "NotificationType" AS ENUM ('COMMENT_STATUS_CHANGE', 'REPLY_COMMENT_CREATED', 'COMMUNITY_NOTE_ADDED', 'ROOT_COMMENT_CREATED', 'SUGGESTION_MESSAGE', 'SUGGESTION_STATUS_CHANGE', 'ACCOUNT_STATUS_CHANGE', 'EVENT_CREATED', 'SERVICE_VERIFICATION_STATUS_CHANGE'); - --- CreateEnum -CREATE TYPE "CommentStatusChange" AS ENUM ('MARKED_AS_SPAM', 'UNMARKED_AS_SPAM', 'MARKED_FOR_ADMIN_REVIEW', 'UNMARKED_FOR_ADMIN_REVIEW', 'STATUS_CHANGED_TO_APPROVED', 'STATUS_CHANGED_TO_VERIFIED', 'STATUS_CHANGED_TO_REJECTED', 'STATUS_CHANGED_TO_PENDING'); - --- CreateEnum -CREATE TYPE "ServiceVerificationStatusChange" AS ENUM ('STATUS_CHANGED_TO_COMMUNITY_CONTRIBUTED', 'STATUS_CHANGED_TO_APPROVED', 'STATUS_CHANGED_TO_VERIFICATION_SUCCESS', 'STATUS_CHANGED_TO_VERIFICATION_FAILED'); - --- CreateEnum -CREATE TYPE "ServiceSuggestionStatusChange" AS ENUM ('STATUS_CHANGED_TO_PENDING', 'STATUS_CHANGED_TO_APPROVED', 'STATUS_CHANGED_TO_REJECTED', 'STATUS_CHANGED_TO_WITHDRAWN'); - --- CreateEnum -CREATE TYPE "ServiceSuggestionStatus" AS ENUM ('PENDING', 'APPROVED', 'REJECTED', 'WITHDRAWN'); - --- CreateEnum -CREATE TYPE "ServiceSuggestionType" AS ENUM ('CREATE_SERVICE', 'EDIT_SERVICE'); - --- CreateEnum -CREATE TYPE "AttributeCategory" AS ENUM ('PRIVACY', 'TRUST'); - --- CreateEnum -CREATE TYPE "AttributeType" AS ENUM ('GOOD', 'BAD', 'WARNING', 'INFO'); - --- CreateEnum -CREATE TYPE "VerificationStepStatus" AS ENUM ('PENDING', 'IN_PROGRESS', 'PASSED', 'FAILED'); - --- CreateTable -CREATE TABLE "Comment" ( - "id" SERIAL NOT NULL, - "upvotes" INTEGER NOT NULL DEFAULT 0, - "status" "CommentStatus" NOT NULL DEFAULT 'PENDING', - "suspicious" BOOLEAN NOT NULL DEFAULT false, - "requiresAdminReview" BOOLEAN NOT NULL DEFAULT false, - "communityNote" TEXT, - "verificationNote" TEXT, - "internalNote" TEXT, - "privateContext" TEXT, - "orderId" VARCHAR(100), - "orderIdStatus" "OrderIdStatus" DEFAULT 'PENDING', - "kycRequested" BOOLEAN NOT NULL DEFAULT false, - "fundsBlocked" BOOLEAN NOT NULL DEFAULT false, - "content" TEXT NOT NULL, - "rating" SMALLINT, - "ratingActive" BOOLEAN NOT NULL DEFAULT false, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "authorId" INTEGER NOT NULL, - "serviceId" INTEGER NOT NULL, - "parentId" INTEGER, - - CONSTRAINT "Comment_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "Notification" ( - "id" SERIAL NOT NULL, - "userId" INTEGER NOT NULL, - "type" "NotificationType" NOT NULL, - "read" BOOLEAN NOT NULL DEFAULT false, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "aboutCommentId" INTEGER, - "aboutEventId" INTEGER, - "aboutServiceId" INTEGER, - "aboutServiceSuggestionId" INTEGER, - "aboutServiceSuggestionMessageId" INTEGER, - "aboutAccountStatusChange" "AccountStatusChange", - "aboutCommentStatusChange" "CommentStatusChange", - "aboutServiceVerificationStatusChange" "ServiceVerificationStatusChange", - "aboutSuggestionStatusChange" "ServiceSuggestionStatusChange", - - CONSTRAINT "Notification_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "NotificationPreferences" ( - "id" SERIAL NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "userId" INTEGER NOT NULL, - "enableOnMyCommentStatusChange" BOOLEAN NOT NULL DEFAULT true, - "enableAutowatchMyComments" BOOLEAN NOT NULL DEFAULT true, - "enableNotifyPendingRepliesOnWatch" BOOLEAN NOT NULL DEFAULT false, - - CONSTRAINT "NotificationPreferences_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "NotificationPreferenceOnServiceVerificationChangeFilterFilter" ( - "id" SERIAL NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "verificationStatus" "VerificationStepStatus" NOT NULL, - "notificationPreferencesId" INTEGER NOT NULL, - "currencies" "Currency"[], - "scores" INTEGER[], - - CONSTRAINT "NotificationPreferenceOnServiceVerificationChangeFilterFil_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "Event" ( - "id" SERIAL NOT NULL, - "title" TEXT NOT NULL, - "content" TEXT NOT NULL, - "source" TEXT, - "type" "EventType" NOT NULL, - "visible" BOOLEAN NOT NULL DEFAULT true, - "startedAt" TIMESTAMP(3) NOT NULL, - "endedAt" TIMESTAMP(3), - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "serviceId" INTEGER NOT NULL, - - CONSTRAINT "Event_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "ServiceSuggestion" ( - "id" SERIAL NOT NULL, - "type" "ServiceSuggestionType" NOT NULL, - "status" "ServiceSuggestionStatus" NOT NULL DEFAULT 'PENDING', - "notes" TEXT, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "userId" INTEGER NOT NULL, - "serviceId" INTEGER NOT NULL, - - CONSTRAINT "ServiceSuggestion_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "ServiceSuggestionMessage" ( - "id" SERIAL NOT NULL, - "content" TEXT NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "userId" INTEGER NOT NULL, - "suggestionId" INTEGER NOT NULL, - - CONSTRAINT "ServiceSuggestionMessage_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "Service" ( - "id" SERIAL NOT NULL, - "name" TEXT NOT NULL, - "slug" TEXT NOT NULL, - "description" TEXT NOT NULL, - "kycLevel" INTEGER NOT NULL DEFAULT 4, - "overallScore" INTEGER NOT NULL DEFAULT 0, - "privacyScore" INTEGER NOT NULL DEFAULT 0, - "trustScore" INTEGER NOT NULL DEFAULT 0, - "isRecentlyListed" BOOLEAN NOT NULL DEFAULT false, - "averageUserRating" DOUBLE PRECISION, - "serviceVisibility" "ServiceVisibility" NOT NULL DEFAULT 'PUBLIC', - "serviceInfoBanner" "ServiceInfoBanner" NOT NULL DEFAULT 'NONE', - "serviceInfoBannerNotes" TEXT, - "verificationStatus" "VerificationStatus" NOT NULL DEFAULT 'COMMUNITY_CONTRIBUTED', - "verificationSummary" TEXT, - "verificationProofMd" TEXT, - "verifiedAt" TIMESTAMP(3), - "userSentiment" JSONB, - "userSentimentAt" TIMESTAMP(3), - "referral" TEXT, - "acceptedCurrencies" "Currency"[] DEFAULT ARRAY[]::"Currency"[], - "serviceUrls" TEXT[], - "tosUrls" TEXT[] DEFAULT ARRAY[]::TEXT[], - "onionUrls" TEXT[] DEFAULT ARRAY[]::TEXT[], - "i2pUrls" TEXT[] DEFAULT ARRAY[]::TEXT[], - "imageUrl" TEXT, - "tosReview" JSONB, - "tosReviewAt" TIMESTAMP(3), - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "listedAt" TIMESTAMP(3), - - CONSTRAINT "Service_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "ServiceContactMethod" ( - "id" SERIAL NOT NULL, - "label" TEXT NOT NULL, - "value" TEXT NOT NULL, - "iconId" TEXT NOT NULL, - "info" TEXT NOT NULL, - "serviceId" INTEGER NOT NULL, - - CONSTRAINT "ServiceContactMethod_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "Attribute" ( - "id" SERIAL NOT NULL, - "slug" TEXT NOT NULL, - "title" TEXT NOT NULL, - "description" TEXT NOT NULL, - "privacyPoints" INTEGER NOT NULL DEFAULT 0, - "trustPoints" INTEGER NOT NULL DEFAULT 0, - "category" "AttributeCategory" NOT NULL, - "type" "AttributeType" NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - - CONSTRAINT "Attribute_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "InternalUserNote" ( - "id" SERIAL NOT NULL, - "content" TEXT NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "userId" INTEGER NOT NULL, - "addedByUserId" INTEGER, - - CONSTRAINT "InternalUserNote_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "User" ( - "id" SERIAL NOT NULL, - "name" TEXT NOT NULL, - "displayName" TEXT, - "link" TEXT, - "picture" TEXT, - "spammer" BOOLEAN NOT NULL DEFAULT false, - "verified" BOOLEAN NOT NULL DEFAULT false, - "admin" BOOLEAN NOT NULL DEFAULT false, - "verifier" BOOLEAN NOT NULL DEFAULT false, - "verifiedLink" TEXT, - "secretTokenHash" TEXT NOT NULL, - "totalKarma" INTEGER NOT NULL DEFAULT 0, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - - CONSTRAINT "User_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "CommentVote" ( - "id" SERIAL NOT NULL, - "downvote" BOOLEAN NOT NULL DEFAULT false, - "commentId" INTEGER NOT NULL, - "userId" INTEGER NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - - CONSTRAINT "CommentVote_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "ServiceAttribute" ( - "serviceId" INTEGER NOT NULL, - "attributeId" INTEGER NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - - CONSTRAINT "ServiceAttribute_pkey" PRIMARY KEY ("serviceId","attributeId") -); - --- CreateTable -CREATE TABLE "KarmaTransaction" ( - "id" SERIAL NOT NULL, - "userId" INTEGER NOT NULL, - "action" TEXT NOT NULL, - "points" INTEGER NOT NULL DEFAULT 0, - "commentId" INTEGER, - "suggestionId" INTEGER, - "description" TEXT NOT NULL, - "processed" BOOLEAN NOT NULL DEFAULT false, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - - CONSTRAINT "KarmaTransaction_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "VerificationStep" ( - "id" SERIAL NOT NULL, - "title" TEXT NOT NULL, - "description" TEXT NOT NULL, - "status" "VerificationStepStatus" NOT NULL DEFAULT 'PENDING', - "evidenceMd" TEXT, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "serviceId" INTEGER NOT NULL, - - CONSTRAINT "VerificationStep_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "Category" ( - "id" SERIAL NOT NULL, - "name" TEXT NOT NULL, - "icon" TEXT NOT NULL, - "slug" TEXT NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - - CONSTRAINT "Category_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "ServiceVerificationRequest" ( - "id" SERIAL NOT NULL, - "serviceId" INTEGER NOT NULL, - "userId" INTEGER NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - - CONSTRAINT "ServiceVerificationRequest_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "ServiceScoreRecalculationJob" ( - "id" SERIAL NOT NULL, - "serviceId" INTEGER NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "processedAt" TIMESTAMP(3), - - CONSTRAINT "ServiceScoreRecalculationJob_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "ServiceUser" ( - "id" SERIAL NOT NULL, - "userId" INTEGER NOT NULL, - "serviceId" INTEGER NOT NULL, - "role" "ServiceUserRole" NOT NULL, - "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" TIMESTAMP(3) NOT NULL, - - CONSTRAINT "ServiceUser_pkey" PRIMARY KEY ("id") -); - --- CreateTable -CREATE TABLE "_watchedComments" ( - "A" INTEGER NOT NULL, - "B" INTEGER NOT NULL, - - CONSTRAINT "_watchedComments_AB_pkey" PRIMARY KEY ("A","B") -); - --- CreateTable -CREATE TABLE "_onEventCreatedForServices" ( - "A" INTEGER NOT NULL, - "B" INTEGER NOT NULL, - - CONSTRAINT "_onEventCreatedForServices_AB_pkey" PRIMARY KEY ("A","B") -); - --- CreateTable -CREATE TABLE "_onRootCommentCreatedForServices" ( - "A" INTEGER NOT NULL, - "B" INTEGER NOT NULL, - - CONSTRAINT "_onRootCommentCreatedForServices_AB_pkey" PRIMARY KEY ("A","B") -); - --- CreateTable -CREATE TABLE "_onVerificationChangeForServices" ( - "A" INTEGER NOT NULL, - "B" INTEGER NOT NULL, - - CONSTRAINT "_onVerificationChangeForServices_AB_pkey" PRIMARY KEY ("A","B") -); - --- CreateTable -CREATE TABLE "_AttributeToNotificationPreferenceOnServiceVerificationChangeFi" ( - "A" INTEGER NOT NULL, - "B" INTEGER NOT NULL, - - CONSTRAINT "_AttributeToNotificationPreferenceOnServiceVerification_AB_pkey" PRIMARY KEY ("A","B") -); - --- CreateTable -CREATE TABLE "_ServiceToCategory" ( - "A" INTEGER NOT NULL, - "B" INTEGER NOT NULL, - - CONSTRAINT "_ServiceToCategory_AB_pkey" PRIMARY KEY ("A","B") -); - --- CreateTable -CREATE TABLE "_CategoryToNotificationPreferenceOnServiceVerificationChangeFil" ( - "A" INTEGER NOT NULL, - "B" INTEGER NOT NULL, - - CONSTRAINT "_CategoryToNotificationPreferenceOnServiceVerificationC_AB_pkey" PRIMARY KEY ("A","B") -); - --- CreateIndex -CREATE INDEX "Comment_status_idx" ON "Comment"("status"); - --- CreateIndex -CREATE INDEX "Comment_createdAt_idx" ON "Comment"("createdAt"); - --- CreateIndex -CREATE INDEX "Comment_serviceId_idx" ON "Comment"("serviceId"); - --- CreateIndex -CREATE INDEX "Comment_authorId_idx" ON "Comment"("authorId"); - --- CreateIndex -CREATE INDEX "Comment_upvotes_idx" ON "Comment"("upvotes"); - --- CreateIndex -CREATE INDEX "Comment_rating_idx" ON "Comment"("rating"); - --- CreateIndex -CREATE INDEX "Comment_ratingActive_idx" ON "Comment"("ratingActive"); - --- CreateIndex -CREATE UNIQUE INDEX "Comment_serviceId_orderId_key" ON "Comment"("serviceId", "orderId"); - --- CreateIndex -CREATE INDEX "Notification_userId_idx" ON "Notification"("userId"); - --- CreateIndex -CREATE INDEX "Notification_read_idx" ON "Notification"("read"); - --- CreateIndex -CREATE INDEX "Notification_createdAt_idx" ON "Notification"("createdAt"); - --- CreateIndex -CREATE INDEX "Notification_userId_read_createdAt_idx" ON "Notification"("userId", "read", "createdAt"); - --- CreateIndex -CREATE INDEX "Notification_userId_type_aboutCommentId_idx" ON "Notification"("userId", "type", "aboutCommentId"); - --- CreateIndex -CREATE INDEX "idx_notification_suggestion_message" ON "Notification"("userId", "type", "aboutServiceSuggestionMessageId"); - --- CreateIndex -CREATE INDEX "idx_notification_suggestion_status" ON "Notification"("userId", "type", "aboutServiceSuggestionId"); - --- CreateIndex -CREATE INDEX "idx_notification_account_status" ON "Notification"("userId", "type", "aboutAccountStatusChange"); - --- CreateIndex -CREATE UNIQUE INDEX "NotificationPreferences_userId_key" ON "NotificationPreferences"("userId"); - --- CreateIndex -CREATE UNIQUE INDEX "NotificationPreferenceOnServiceVerificationChangeFilterFilt_key" ON "NotificationPreferenceOnServiceVerificationChangeFilterFilter"("verificationStatus", "notificationPreferencesId"); - --- CreateIndex -CREATE INDEX "Event_visible_idx" ON "Event"("visible"); - --- CreateIndex -CREATE INDEX "Event_startedAt_idx" ON "Event"("startedAt"); - --- CreateIndex -CREATE INDEX "Event_createdAt_idx" ON "Event"("createdAt"); - --- CreateIndex -CREATE INDEX "Event_endedAt_idx" ON "Event"("endedAt"); - --- CreateIndex -CREATE INDEX "Event_type_idx" ON "Event"("type"); - --- CreateIndex -CREATE INDEX "Event_serviceId_idx" ON "Event"("serviceId"); - --- CreateIndex -CREATE INDEX "ServiceSuggestion_userId_idx" ON "ServiceSuggestion"("userId"); - --- CreateIndex -CREATE INDEX "ServiceSuggestion_serviceId_idx" ON "ServiceSuggestion"("serviceId"); - --- CreateIndex -CREATE INDEX "ServiceSuggestionMessage_userId_idx" ON "ServiceSuggestionMessage"("userId"); - --- CreateIndex -CREATE INDEX "ServiceSuggestionMessage_suggestionId_idx" ON "ServiceSuggestionMessage"("suggestionId"); - --- CreateIndex -CREATE INDEX "ServiceSuggestionMessage_createdAt_idx" ON "ServiceSuggestionMessage"("createdAt"); - --- CreateIndex -CREATE UNIQUE INDEX "Service_slug_key" ON "Service"("slug"); - --- CreateIndex -CREATE INDEX "Service_listedAt_idx" ON "Service"("listedAt"); - --- CreateIndex -CREATE INDEX "Service_overallScore_idx" ON "Service"("overallScore"); - --- CreateIndex -CREATE INDEX "Service_privacyScore_idx" ON "Service"("privacyScore"); - --- CreateIndex -CREATE INDEX "Service_trustScore_idx" ON "Service"("trustScore"); - --- CreateIndex -CREATE INDEX "Service_averageUserRating_idx" ON "Service"("averageUserRating"); - --- CreateIndex -CREATE INDEX "Service_name_idx" ON "Service"("name"); - --- CreateIndex -CREATE INDEX "Service_verificationStatus_idx" ON "Service"("verificationStatus"); - --- CreateIndex -CREATE INDEX "Service_kycLevel_idx" ON "Service"("kycLevel"); - --- CreateIndex -CREATE INDEX "Service_createdAt_idx" ON "Service"("createdAt"); - --- CreateIndex -CREATE INDEX "Service_updatedAt_idx" ON "Service"("updatedAt"); - --- CreateIndex -CREATE INDEX "Service_slug_idx" ON "Service"("slug"); - --- CreateIndex -CREATE UNIQUE INDEX "Attribute_slug_key" ON "Attribute"("slug"); - --- CreateIndex -CREATE INDEX "InternalUserNote_userId_idx" ON "InternalUserNote"("userId"); - --- CreateIndex -CREATE INDEX "InternalUserNote_addedByUserId_idx" ON "InternalUserNote"("addedByUserId"); - --- CreateIndex -CREATE INDEX "InternalUserNote_createdAt_idx" ON "InternalUserNote"("createdAt"); - --- CreateIndex -CREATE UNIQUE INDEX "User_name_key" ON "User"("name"); - --- CreateIndex -CREATE UNIQUE INDEX "User_secretTokenHash_key" ON "User"("secretTokenHash"); - --- CreateIndex -CREATE INDEX "User_createdAt_idx" ON "User"("createdAt"); - --- CreateIndex -CREATE INDEX "User_totalKarma_idx" ON "User"("totalKarma"); - --- CreateIndex -CREATE INDEX "CommentVote_commentId_idx" ON "CommentVote"("commentId"); - --- CreateIndex -CREATE INDEX "CommentVote_userId_idx" ON "CommentVote"("userId"); - --- CreateIndex -CREATE UNIQUE INDEX "CommentVote_commentId_userId_key" ON "CommentVote"("commentId", "userId"); - --- CreateIndex -CREATE INDEX "KarmaTransaction_createdAt_idx" ON "KarmaTransaction"("createdAt"); - --- CreateIndex -CREATE INDEX "KarmaTransaction_userId_idx" ON "KarmaTransaction"("userId"); - --- CreateIndex -CREATE INDEX "KarmaTransaction_processed_idx" ON "KarmaTransaction"("processed"); - --- CreateIndex -CREATE INDEX "KarmaTransaction_suggestionId_idx" ON "KarmaTransaction"("suggestionId"); - --- CreateIndex -CREATE INDEX "KarmaTransaction_commentId_idx" ON "KarmaTransaction"("commentId"); - --- CreateIndex -CREATE INDEX "VerificationStep_serviceId_idx" ON "VerificationStep"("serviceId"); - --- CreateIndex -CREATE INDEX "VerificationStep_status_idx" ON "VerificationStep"("status"); - --- CreateIndex -CREATE INDEX "VerificationStep_createdAt_idx" ON "VerificationStep"("createdAt"); - --- CreateIndex -CREATE UNIQUE INDEX "Category_name_key" ON "Category"("name"); - --- CreateIndex -CREATE UNIQUE INDEX "Category_slug_key" ON "Category"("slug"); - --- CreateIndex -CREATE INDEX "Category_name_idx" ON "Category"("name"); - --- CreateIndex -CREATE INDEX "Category_slug_idx" ON "Category"("slug"); - --- CreateIndex -CREATE INDEX "ServiceVerificationRequest_serviceId_idx" ON "ServiceVerificationRequest"("serviceId"); - --- CreateIndex -CREATE INDEX "ServiceVerificationRequest_userId_idx" ON "ServiceVerificationRequest"("userId"); - --- CreateIndex -CREATE INDEX "ServiceVerificationRequest_createdAt_idx" ON "ServiceVerificationRequest"("createdAt"); - --- CreateIndex -CREATE UNIQUE INDEX "ServiceVerificationRequest_serviceId_userId_key" ON "ServiceVerificationRequest"("serviceId", "userId"); - --- CreateIndex -CREATE UNIQUE INDEX "ServiceScoreRecalculationJob_serviceId_key" ON "ServiceScoreRecalculationJob"("serviceId"); - --- CreateIndex -CREATE INDEX "ServiceScoreRecalculationJob_processedAt_idx" ON "ServiceScoreRecalculationJob"("processedAt"); - --- CreateIndex -CREATE INDEX "ServiceScoreRecalculationJob_createdAt_idx" ON "ServiceScoreRecalculationJob"("createdAt"); - --- CreateIndex -CREATE INDEX "ServiceUser_userId_idx" ON "ServiceUser"("userId"); - --- CreateIndex -CREATE INDEX "ServiceUser_serviceId_idx" ON "ServiceUser"("serviceId"); - --- CreateIndex -CREATE INDEX "ServiceUser_role_idx" ON "ServiceUser"("role"); - --- CreateIndex -CREATE UNIQUE INDEX "ServiceUser_userId_serviceId_key" ON "ServiceUser"("userId", "serviceId"); - --- CreateIndex -CREATE INDEX "_watchedComments_B_index" ON "_watchedComments"("B"); - --- CreateIndex -CREATE INDEX "_onEventCreatedForServices_B_index" ON "_onEventCreatedForServices"("B"); - --- CreateIndex -CREATE INDEX "_onRootCommentCreatedForServices_B_index" ON "_onRootCommentCreatedForServices"("B"); - --- CreateIndex -CREATE INDEX "_onVerificationChangeForServices_B_index" ON "_onVerificationChangeForServices"("B"); - --- CreateIndex -CREATE INDEX "_AttributeToNotificationPreferenceOnServiceVerification_B_index" ON "_AttributeToNotificationPreferenceOnServiceVerificationChangeFi"("B"); - --- CreateIndex -CREATE INDEX "_ServiceToCategory_B_index" ON "_ServiceToCategory"("B"); - --- CreateIndex -CREATE INDEX "_CategoryToNotificationPreferenceOnServiceVerificationC_B_index" ON "_CategoryToNotificationPreferenceOnServiceVerificationChangeFil"("B"); - --- AddForeignKey -ALTER TABLE "Comment" ADD CONSTRAINT "Comment_authorId_fkey" FOREIGN KEY ("authorId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "Comment" ADD CONSTRAINT "Comment_serviceId_fkey" FOREIGN KEY ("serviceId") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "Comment" ADD CONSTRAINT "Comment_parentId_fkey" FOREIGN KEY ("parentId") REFERENCES "Comment"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "Notification" ADD CONSTRAINT "Notification_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "Notification" ADD CONSTRAINT "Notification_aboutCommentId_fkey" FOREIGN KEY ("aboutCommentId") REFERENCES "Comment"("id") ON DELETE SET NULL ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "Notification" ADD CONSTRAINT "Notification_aboutEventId_fkey" FOREIGN KEY ("aboutEventId") REFERENCES "Event"("id") ON DELETE SET NULL ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "Notification" ADD CONSTRAINT "Notification_aboutServiceId_fkey" FOREIGN KEY ("aboutServiceId") REFERENCES "Service"("id") ON DELETE SET NULL ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "Notification" ADD CONSTRAINT "Notification_aboutServiceSuggestionId_fkey" FOREIGN KEY ("aboutServiceSuggestionId") REFERENCES "ServiceSuggestion"("id") ON DELETE SET NULL ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "Notification" ADD CONSTRAINT "Notification_aboutServiceSuggestionMessageId_fkey" FOREIGN KEY ("aboutServiceSuggestionMessageId") REFERENCES "ServiceSuggestionMessage"("id") ON DELETE SET NULL ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "NotificationPreferences" ADD CONSTRAINT "NotificationPreferences_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "NotificationPreferenceOnServiceVerificationChangeFilterFilter" ADD CONSTRAINT "NotificationPreferenceOnServiceVerificationChangeFilterFil_fkey" FOREIGN KEY ("notificationPreferencesId") REFERENCES "NotificationPreferences"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "Event" ADD CONSTRAINT "Event_serviceId_fkey" FOREIGN KEY ("serviceId") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceSuggestion" ADD CONSTRAINT "ServiceSuggestion_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceSuggestion" ADD CONSTRAINT "ServiceSuggestion_serviceId_fkey" FOREIGN KEY ("serviceId") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceSuggestionMessage" ADD CONSTRAINT "ServiceSuggestionMessage_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceSuggestionMessage" ADD CONSTRAINT "ServiceSuggestionMessage_suggestionId_fkey" FOREIGN KEY ("suggestionId") REFERENCES "ServiceSuggestion"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceContactMethod" ADD CONSTRAINT "ServiceContactMethod_serviceId_fkey" FOREIGN KEY ("serviceId") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "InternalUserNote" ADD CONSTRAINT "InternalUserNote_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "InternalUserNote" ADD CONSTRAINT "InternalUserNote_addedByUserId_fkey" FOREIGN KEY ("addedByUserId") REFERENCES "User"("id") ON DELETE SET NULL ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "CommentVote" ADD CONSTRAINT "CommentVote_commentId_fkey" FOREIGN KEY ("commentId") REFERENCES "Comment"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "CommentVote" ADD CONSTRAINT "CommentVote_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceAttribute" ADD CONSTRAINT "ServiceAttribute_serviceId_fkey" FOREIGN KEY ("serviceId") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceAttribute" ADD CONSTRAINT "ServiceAttribute_attributeId_fkey" FOREIGN KEY ("attributeId") REFERENCES "Attribute"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "KarmaTransaction" ADD CONSTRAINT "KarmaTransaction_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "KarmaTransaction" ADD CONSTRAINT "KarmaTransaction_commentId_fkey" FOREIGN KEY ("commentId") REFERENCES "Comment"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "KarmaTransaction" ADD CONSTRAINT "KarmaTransaction_suggestionId_fkey" FOREIGN KEY ("suggestionId") REFERENCES "ServiceSuggestion"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "VerificationStep" ADD CONSTRAINT "VerificationStep_serviceId_fkey" FOREIGN KEY ("serviceId") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceVerificationRequest" ADD CONSTRAINT "ServiceVerificationRequest_serviceId_fkey" FOREIGN KEY ("serviceId") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceVerificationRequest" ADD CONSTRAINT "ServiceVerificationRequest_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceUser" ADD CONSTRAINT "ServiceUser_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "ServiceUser" ADD CONSTRAINT "ServiceUser_serviceId_fkey" FOREIGN KEY ("serviceId") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_watchedComments" ADD CONSTRAINT "_watchedComments_A_fkey" FOREIGN KEY ("A") REFERENCES "Comment"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_watchedComments" ADD CONSTRAINT "_watchedComments_B_fkey" FOREIGN KEY ("B") REFERENCES "NotificationPreferences"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_onEventCreatedForServices" ADD CONSTRAINT "_onEventCreatedForServices_A_fkey" FOREIGN KEY ("A") REFERENCES "NotificationPreferences"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_onEventCreatedForServices" ADD CONSTRAINT "_onEventCreatedForServices_B_fkey" FOREIGN KEY ("B") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_onRootCommentCreatedForServices" ADD CONSTRAINT "_onRootCommentCreatedForServices_A_fkey" FOREIGN KEY ("A") REFERENCES "NotificationPreferences"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_onRootCommentCreatedForServices" ADD CONSTRAINT "_onRootCommentCreatedForServices_B_fkey" FOREIGN KEY ("B") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_onVerificationChangeForServices" ADD CONSTRAINT "_onVerificationChangeForServices_A_fkey" FOREIGN KEY ("A") REFERENCES "NotificationPreferences"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_onVerificationChangeForServices" ADD CONSTRAINT "_onVerificationChangeForServices_B_fkey" FOREIGN KEY ("B") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_AttributeToNotificationPreferenceOnServiceVerificationChangeFi" ADD CONSTRAINT "_AttributeToNotificationPreferenceOnServiceVerificationC_A_fkey" FOREIGN KEY ("A") REFERENCES "Attribute"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_AttributeToNotificationPreferenceOnServiceVerificationChangeFi" ADD CONSTRAINT "_AttributeToNotificationPreferenceOnServiceVerificationC_B_fkey" FOREIGN KEY ("B") REFERENCES "NotificationPreferenceOnServiceVerificationChangeFilterFilter"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_ServiceToCategory" ADD CONSTRAINT "_ServiceToCategory_A_fkey" FOREIGN KEY ("A") REFERENCES "Category"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_ServiceToCategory" ADD CONSTRAINT "_ServiceToCategory_B_fkey" FOREIGN KEY ("B") REFERENCES "Service"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_CategoryToNotificationPreferenceOnServiceVerificationChangeFil" ADD CONSTRAINT "_CategoryToNotificationPreferenceOnServiceVerificationCh_A_fkey" FOREIGN KEY ("A") REFERENCES "Category"("id") ON DELETE CASCADE ON UPDATE CASCADE; - --- AddForeignKey -ALTER TABLE "_CategoryToNotificationPreferenceOnServiceVerificationChangeFil" ADD CONSTRAINT "_CategoryToNotificationPreferenceOnServiceVerificationCh_B_fkey" FOREIGN KEY ("B") REFERENCES "NotificationPreferenceOnServiceVerificationChangeFilterFilter"("id") ON DELETE CASCADE ON UPDATE CASCADE; diff --git a/web/prisma/migrations/20250519091940_last_login_at/migration.sql b/web/prisma/migrations/20250519091940_last_login_at/migration.sql deleted file mode 100644 index 21ace98..0000000 --- a/web/prisma/migrations/20250519091940_last_login_at/migration.sql +++ /dev/null @@ -1,2 +0,0 @@ --- AlterTable -ALTER TABLE "User" ADD COLUMN "lastLoginAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP; diff --git a/web/prisma/migrations/migration_lock.toml b/web/prisma/migrations/migration_lock.toml deleted file mode 100644 index 044d57c..0000000 --- a/web/prisma/migrations/migration_lock.toml +++ /dev/null @@ -1,3 +0,0 @@ -# Please do not edit this file manually -# It should be added in your version-control system (e.g., Git) -provider = "postgresql" diff --git a/web/prisma/schema.prisma b/web/prisma/schema.prisma deleted file mode 100644 index 946a589..0000000 --- a/web/prisma/schema.prisma +++ /dev/null @@ -1,590 +0,0 @@ -// This is your Prisma schema file - -datasource db { - provider = "postgres" - url = env("DATABASE_URL") -} - -generator client { - provider = "prisma-client-js" -} - -generator json { - provider = "prisma-json-types-generator" -} - -enum CommentStatus { - PENDING - HUMAN_PENDING - APPROVED - VERIFIED - REJECTED -} - -enum OrderIdStatus { - PENDING - APPROVED - REJECTED -} - -model Comment { - id Int @id @default(autoincrement()) - /// Computed via trigger. Do not update through prisma. - upvotes Int @default(0) - status CommentStatus @default(PENDING) - suspicious Boolean @default(false) - requiresAdminReview Boolean @default(false) - communityNote String? - verificationNote String? - internalNote String? - privateContext String? - orderId String? @db.VarChar(100) - orderIdStatus OrderIdStatus? @default(PENDING) - kycRequested Boolean @default(false) - fundsBlocked Boolean @default(false) - content String - rating Int? @db.SmallInt - ratingActive Boolean @default(false) - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - author User @relation(fields: [authorId], references: [id], onDelete: Cascade) - authorId Int - service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade) - serviceId Int - parentId Int? - parent Comment? @relation("CommentReplies", fields: [parentId], references: [id], onDelete: Cascade) - replies Comment[] @relation("CommentReplies") - karmaTransactions KarmaTransaction[] - votes CommentVote[] - - notificationPreferenceswatchedComments NotificationPreferences[] @relation("watchedComments") - Notification Notification[] - - @@unique([serviceId, orderId], name: "unique_orderId_per_service") - @@index([status]) - @@index([createdAt]) - @@index([serviceId]) - @@index([authorId]) - @@index([upvotes]) - @@index([rating]) - @@index([ratingActive]) -} - -enum VerificationStatus { - COMMUNITY_CONTRIBUTED - // COMMUNITY_VERIFIED - APPROVED - VERIFICATION_SUCCESS - VERIFICATION_FAILED -} - -enum ServiceInfoBanner { - NONE - NO_LONGER_OPERATIONAL -} - -enum ServiceVisibility { - PUBLIC - UNLISTED - HIDDEN -} - -enum Currency { - MONERO - BITCOIN - LIGHTNING - FIAT - CASH -} - -enum EventType { - WARNING - WARNING_SOLVED - ALERT - ALERT_SOLVED - INFO - NORMAL - UPDATE -} - -enum ServiceUserRole { - OWNER - ADMIN - MODERATOR - SUPPORT - TEAM_MEMBER -} - -enum AccountStatusChange { - ADMIN_TRUE - ADMIN_FALSE - VERIFIED_TRUE - VERIFIED_FALSE - VERIFIER_TRUE - VERIFIER_FALSE - SPAMMER_TRUE - SPAMMER_FALSE -} - -enum NotificationType { - COMMENT_STATUS_CHANGE - REPLY_COMMENT_CREATED - COMMUNITY_NOTE_ADDED - /// Comment that is not a reply. May include a rating. - ROOT_COMMENT_CREATED - SUGGESTION_MESSAGE - SUGGESTION_STATUS_CHANGE - // KARMA_UNLOCK // TODO: [KARMA_UNLOCK] Will be added later, when karma unloks are in the database, not in the code. - /// Marked as spammer, promoted to admin, etc. - ACCOUNT_STATUS_CHANGE - EVENT_CREATED - SERVICE_VERIFICATION_STATUS_CHANGE -} - -enum CommentStatusChange { - MARKED_AS_SPAM - UNMARKED_AS_SPAM - MARKED_FOR_ADMIN_REVIEW - UNMARKED_FOR_ADMIN_REVIEW - STATUS_CHANGED_TO_APPROVED - STATUS_CHANGED_TO_VERIFIED - STATUS_CHANGED_TO_REJECTED - STATUS_CHANGED_TO_PENDING -} - -enum ServiceVerificationStatusChange { - STATUS_CHANGED_TO_COMMUNITY_CONTRIBUTED - STATUS_CHANGED_TO_APPROVED - STATUS_CHANGED_TO_VERIFICATION_SUCCESS - STATUS_CHANGED_TO_VERIFICATION_FAILED -} - -enum ServiceSuggestionStatusChange { - STATUS_CHANGED_TO_PENDING - STATUS_CHANGED_TO_APPROVED - STATUS_CHANGED_TO_REJECTED - STATUS_CHANGED_TO_WITHDRAWN -} - -model Notification { - id Int @id @default(autoincrement()) - userId Int - user User @relation("NotificationOwner", fields: [userId], references: [id], onDelete: Cascade) - type NotificationType - read Boolean @default(false) - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - - aboutComment Comment? @relation(fields: [aboutCommentId], references: [id]) - aboutCommentId Int? - aboutEvent Event? @relation(fields: [aboutEventId], references: [id]) - aboutEventId Int? - aboutService Service? @relation(fields: [aboutServiceId], references: [id]) - aboutServiceId Int? - aboutServiceSuggestion ServiceSuggestion? @relation(fields: [aboutServiceSuggestionId], references: [id]) - aboutServiceSuggestionId Int? - aboutServiceSuggestionMessage ServiceSuggestionMessage? @relation(fields: [aboutServiceSuggestionMessageId], references: [id]) - aboutServiceSuggestionMessageId Int? - aboutAccountStatusChange AccountStatusChange? - aboutCommentStatusChange CommentStatusChange? - aboutServiceVerificationStatusChange ServiceVerificationStatusChange? - aboutSuggestionStatusChange ServiceSuggestionStatusChange? - - @@index([userId]) - @@index([read]) - @@index([createdAt]) - @@index([userId, read, createdAt]) - @@index([userId, type, aboutCommentId]) - @@index([userId, type, aboutServiceSuggestionMessageId], map: "idx_notification_suggestion_message") - @@index([userId, type, aboutServiceSuggestionId], map: "idx_notification_suggestion_status") - @@index([userId, type, aboutAccountStatusChange], map: "idx_notification_account_status") -} - -model NotificationPreferences { - id Int @id @default(autoincrement()) - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - - userId Int @unique - user User @relation(fields: [userId], references: [id], onDelete: Cascade) - - enableOnMyCommentStatusChange Boolean @default(true) - enableAutowatchMyComments Boolean @default(true) - enableNotifyPendingRepliesOnWatch Boolean @default(false) - - onEventCreatedForServices Service[] @relation("onEventCreatedForServices") - onRootCommentCreatedForServices Service[] @relation("onRootCommentCreatedForServices") - onVerificationChangeForServices Service[] @relation("onVerificationChangeForServices") - watchedComments Comment[] @relation("watchedComments") - - onServiceVerificationChangeFilter NotificationPreferenceOnServiceVerificationChangeFilterFilter[] -} - -model NotificationPreferenceOnServiceVerificationChangeFilterFilter { - id Int @id @default(autoincrement()) - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - - verificationStatus VerificationStepStatus - notificationPreferences NotificationPreferences @relation(fields: [notificationPreferencesId], references: [id], onDelete: Cascade) - notificationPreferencesId Int - - categories Category[] - attributes Attribute[] - currencies Currency[] - /// 0-10 - scores Int[] - - @@unique([verificationStatus, notificationPreferencesId]) -} - -model Event { - id Int @id @default(autoincrement()) - title String - content String - source String? - type EventType - visible Boolean @default(true) - startedAt DateTime - /// If null, the event is ongoing. If same as startedAt, the event is a one-time event. If startedAt is in the future, the event is upcoming. - endedAt DateTime? - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade) - serviceId Int - Notification Notification[] - - @@index([visible]) - @@index([startedAt]) - @@index([createdAt]) - @@index([endedAt]) - @@index([type]) - @@index([serviceId]) -} - -enum ServiceSuggestionStatus { - PENDING - APPROVED - REJECTED - WITHDRAWN -} - -enum ServiceSuggestionType { - CREATE_SERVICE - EDIT_SERVICE -} - -model ServiceSuggestion { - id Int @id @default(autoincrement()) - type ServiceSuggestionType - status ServiceSuggestionStatus @default(PENDING) - notes String? - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - userId Int - serviceId Int - user User @relation(fields: [userId], references: [id], onDelete: Cascade) - service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade) - messages ServiceSuggestionMessage[] - Notification Notification[] - KarmaTransaction KarmaTransaction[] - - @@index([userId]) - @@index([serviceId]) -} - -model ServiceSuggestionMessage { - id Int @id @default(autoincrement()) - content String - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - userId Int - suggestionId Int - user User @relation(fields: [userId], references: [id], onDelete: Cascade) - suggestion ServiceSuggestion @relation(fields: [suggestionId], references: [id], onDelete: Cascade) - notifications Notification[] - - @@index([userId]) - @@index([suggestionId]) - @@index([createdAt]) -} - -model Service { - id Int @id @default(autoincrement()) - name String - slug String @unique - description String - categories Category[] @relation("ServiceToCategory") - kycLevel Int @default(4) - overallScore Int @default(0) - privacyScore Int @default(0) - trustScore Int @default(0) - /// Computed via trigger. Do not update through prisma. - isRecentlyListed Boolean @default(false) - /// Computed via trigger. Do not update through prisma. - averageUserRating Float? - serviceVisibility ServiceVisibility @default(PUBLIC) - serviceInfoBanner ServiceInfoBanner @default(NONE) - serviceInfoBannerNotes String? - verificationStatus VerificationStatus @default(COMMUNITY_CONTRIBUTED) - verificationSummary String? - verificationRequests ServiceVerificationRequest[] - verificationProofMd String? - /// Computed via trigger when the service status is VERIFICATION_SUCCESS. Do not update through prisma. - verifiedAt DateTime? - /// [UserSentiment] - userSentiment Json? - userSentimentAt DateTime? - referral String? - acceptedCurrencies Currency[] @default([]) - serviceUrls String[] - tosUrls String[] @default([]) - onionUrls String[] @default([]) - i2pUrls String[] @default([]) - imageUrl String? - /// [TosReview] - tosReview Json? - tosReviewAt DateTime? - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - listedAt DateTime? - comments Comment[] - events Event[] - contactMethods ServiceContactMethod[] @relation("ServiceToContactMethod") - attributes ServiceAttribute[] - verificationSteps VerificationStep[] - suggestions ServiceSuggestion[] - - onEventCreatedForServices NotificationPreferences[] @relation("onEventCreatedForServices") - onRootCommentCreatedForServices NotificationPreferences[] @relation("onRootCommentCreatedForServices") - onVerificationChangeForServices NotificationPreferences[] @relation("onVerificationChangeForServices") - Notification Notification[] - affiliatedUsers ServiceUser[] @relation("ServiceUsers") - - @@index([listedAt]) - @@index([overallScore]) - @@index([privacyScore]) - @@index([trustScore]) - @@index([averageUserRating]) - @@index([name]) - @@index([verificationStatus]) - @@index([kycLevel]) - @@index([createdAt]) - @@index([updatedAt]) - @@index([slug]) -} - -model ServiceContactMethod { - id Int @id @default(autoincrement()) - label String - /// Including the protocol (e.g. "mailto:", "tel:", "https://") - value String - iconId String - info String - services Service @relation("ServiceToContactMethod", fields: [serviceId], references: [id], onDelete: Cascade) - serviceId Int -} - -enum AttributeCategory { - PRIVACY - TRUST -} - -enum AttributeType { - GOOD - BAD - WARNING - INFO -} - -model Attribute { - id Int @id @default(autoincrement()) - slug String @unique - title String - /// Markdown - description String - privacyPoints Int @default(0) - trustPoints Int @default(0) - category AttributeCategory - type AttributeType - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - services ServiceAttribute[] - - notificationPreferencesOnServiceVerificationChange NotificationPreferenceOnServiceVerificationChangeFilterFilter[] -} - -model InternalUserNote { - id Int @id @default(autoincrement()) - content String - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - - user User @relation("UserRecievedNotes", fields: [userId], references: [id], onDelete: Cascade) - userId Int - addedByUser User? @relation("UserAddedNotes", fields: [addedByUserId], references: [id], onDelete: SetNull) - addedByUserId Int? - - @@index([userId]) - @@index([addedByUserId]) - @@index([createdAt]) -} - -model User { - id Int @id @default(autoincrement()) - name String @unique - displayName String? - link String? - picture String? - spammer Boolean @default(false) - verified Boolean @default(false) - admin Boolean @default(false) - verifier Boolean @default(false) - verifiedLink String? - secretTokenHash String @unique - /// Computed via trigger. Do not update through prisma. - totalKarma Int @default(0) - - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - lastLoginAt DateTime @default(now()) - comments Comment[] - karmaTransactions KarmaTransaction[] - commentVotes CommentVote[] - suggestions ServiceSuggestion[] - suggestionMessages ServiceSuggestionMessage[] - internalNotes InternalUserNote[] @relation("UserRecievedNotes") - addedInternalNotes InternalUserNote[] @relation("UserAddedNotes") - verificationRequests ServiceVerificationRequest[] - notifications Notification[] @relation("NotificationOwner") - notificationPreferences NotificationPreferences? - serviceAffiliations ServiceUser[] @relation("UserServices") - - @@index([createdAt]) - @@index([totalKarma]) -} - -model CommentVote { - id Int @id @default(autoincrement()) - downvote Boolean @default(false) // false = upvote, true = downvote - comment Comment @relation(fields: [commentId], references: [id], onDelete: Cascade) - commentId Int - user User @relation(fields: [userId], references: [id], onDelete: Cascade) - userId Int - createdAt DateTime @default(now()) - - @@unique([commentId, userId]) // Ensure one vote per user per comment - @@index([commentId]) - @@index([userId]) -} - -model ServiceAttribute { - service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade) - serviceId Int - attribute Attribute @relation(fields: [attributeId], references: [id], onDelete: Cascade) - attributeId Int - createdAt DateTime @default(now()) - - @@id([serviceId, attributeId]) -} - -model KarmaTransaction { - id Int @id @default(autoincrement()) - user User @relation(fields: [userId], references: [id], onDelete: Cascade) - userId Int - action String - points Int @default(0) - comment Comment? @relation(fields: [commentId], references: [id], onDelete: Cascade) - commentId Int? - suggestion ServiceSuggestion? @relation(fields: [suggestionId], references: [id], onDelete: Cascade) - suggestionId Int? - description String - processed Boolean @default(false) - createdAt DateTime @default(now()) - - @@index([createdAt]) - @@index([userId]) - @@index([processed]) - @@index([suggestionId]) - @@index([commentId]) -} - -enum VerificationStepStatus { - PENDING - IN_PROGRESS - PASSED - FAILED -} - -model VerificationStep { - id Int @id @default(autoincrement()) - title String - description String - status VerificationStepStatus @default(PENDING) - evidenceMd String? - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade) - serviceId Int - - @@index([serviceId]) - @@index([status]) - @@index([createdAt]) -} - -model Category { - id Int @id @default(autoincrement()) - name String @unique - icon String - slug String @unique - - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - services Service[] @relation("ServiceToCategory") - - notificationPreferencesOnServiceVerificationChange NotificationPreferenceOnServiceVerificationChangeFilterFilter[] - - @@index([name]) - @@index([slug]) -} - -model ServiceVerificationRequest { - id Int @id @default(autoincrement()) - service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade) - serviceId Int - user User @relation(fields: [userId], references: [id], onDelete: Cascade) - userId Int - createdAt DateTime @default(now()) - updatedAt DateTime @default(now()) @updatedAt - - @@unique([serviceId, userId]) - @@index([serviceId]) - @@index([userId]) - @@index([createdAt]) -} - -model ServiceScoreRecalculationJob { - id Int @id @default(autoincrement()) - serviceId Int @unique - createdAt DateTime @default(now()) - processedAt DateTime? @updatedAt - - @@index([processedAt]) - @@index([createdAt]) -} - -model ServiceUser { - id Int @id @default(autoincrement()) - userId Int - user User @relation("UserServices", fields: [userId], references: [id], onDelete: Cascade) - serviceId Int - service Service @relation("ServiceUsers", fields: [serviceId], references: [id], onDelete: Cascade) - role ServiceUserRole - createdAt DateTime @default(now()) - updatedAt DateTime @updatedAt - - @@unique([userId, serviceId]) - @@index([userId]) - @@index([serviceId]) - @@index([role]) -} diff --git a/web/prisma/triggers/01_karma_tx.sql b/web/prisma/triggers/01_karma_tx.sql deleted file mode 100644 index dcd30d9..0000000 --- a/web/prisma/triggers/01_karma_tx.sql +++ /dev/null @@ -1,265 +0,0 @@ --- This script manages user karma based on comment interactions. It handles karma points --- for comment approvals, verifications, spam status changes, and votes (upvotes/downvotes). --- Karma transactions are recorded, and user karma totals are updated accordingly. - --- Drop existing triggers first -DROP TRIGGER IF EXISTS comment_status_change_trigger ON "Comment"; -DROP TRIGGER IF EXISTS comment_suspicious_change_trigger ON "Comment"; -DROP TRIGGER IF EXISTS comment_upvote_change_trigger ON "Comment"; -DROP TRIGGER IF EXISTS comment_vote_change_trigger ON "CommentVote"; -DROP TRIGGER IF EXISTS suggestion_status_change_trigger ON "ServiceSuggestion"; - --- Drop existing functions -DROP FUNCTION IF EXISTS handle_comment_upvote_change(); -DROP FUNCTION IF EXISTS handle_comment_status_change(); -DROP FUNCTION IF EXISTS handle_comment_approval(); -DROP FUNCTION IF EXISTS handle_comment_verification(); -DROP FUNCTION IF EXISTS handle_comment_spam_status(); -DROP FUNCTION IF EXISTS handle_comment_vote_change(); -DROP FUNCTION IF EXISTS insert_karma_transaction(); -DROP FUNCTION IF EXISTS update_user_karma(); -DROP FUNCTION IF EXISTS handle_suggestion_status_change(); - --- Helper function to insert karma transaction -CREATE OR REPLACE FUNCTION insert_karma_transaction( - p_user_id INT, - p_points INT, - p_action TEXT, - p_comment_id INT, - p_description TEXT, - p_suggestion_id INT DEFAULT NULL -) RETURNS VOID AS $$ -BEGIN - INSERT INTO "KarmaTransaction" ( - "userId", "points", "action", "commentId", - "suggestionId", - "description", "processed", "createdAt" - ) - VALUES ( - p_user_id, p_points, p_action, p_comment_id, - p_suggestion_id, - p_description, true, NOW() - ); -END; -$$ LANGUAGE plpgsql; - --- Helper function to update user karma -CREATE OR REPLACE FUNCTION update_user_karma( - p_user_id INT, - p_karma_change INT -) RETURNS VOID AS $$ -BEGIN - UPDATE "User" - SET "totalKarma" = "totalKarma" + p_karma_change - WHERE id = p_user_id; -END; -$$ LANGUAGE plpgsql; - --- Handle comment approval -CREATE OR REPLACE FUNCTION handle_comment_approval( - NEW RECORD, - OLD RECORD -) RETURNS VOID AS $$ -BEGIN - IF OLD.status = 'PENDING' AND NEW.status = 'APPROVED' THEN - PERFORM insert_karma_transaction( - NEW."authorId", - 1, - 'comment_approved', - NEW.id, - format('Your comment #comment-%s in %s has been approved!', - NEW.id, - (SELECT name FROM "Service" WHERE id = NEW."serviceId")) - ); - PERFORM update_user_karma(NEW."authorId", 1); - END IF; -END; -$$ LANGUAGE plpgsql; - --- Handle comment verification -CREATE OR REPLACE FUNCTION handle_comment_verification( - NEW RECORD, - OLD RECORD -) RETURNS VOID AS $$ -BEGIN - IF NEW.status = 'VERIFIED' AND OLD.status != 'VERIFIED' THEN - PERFORM insert_karma_transaction( - NEW."authorId", - 5, - 'comment_verified', - NEW.id, - format('Your comment #comment-%s in %s has been verified!', - NEW.id, - (SELECT name FROM "Service" WHERE id = NEW."serviceId")) - ); - PERFORM update_user_karma(NEW."authorId", 5); - END IF; -END; -$$ LANGUAGE plpgsql; - --- Handle spam status changes -CREATE OR REPLACE FUNCTION handle_comment_spam_status( - NEW RECORD, - OLD RECORD -) RETURNS VOID AS $$ -BEGIN - -- Handle marking as spam - IF NEW.suspicious = true AND OLD.suspicious = false THEN - PERFORM insert_karma_transaction( - NEW."authorId", - -10, - 'comment_spam', - NEW.id, - format('Your comment #comment-%s in %s has been marked as spam.', - NEW.id, - (SELECT name FROM "Service" WHERE id = NEW."serviceId")) - ); - PERFORM update_user_karma(NEW."authorId", -10); - -- Handle unmarking as spam - ELSIF NEW.suspicious = false AND OLD.suspicious = true THEN - PERFORM insert_karma_transaction( - NEW."authorId", - 10, - 'comment_spam_reverted', - NEW.id, - format('Your comment #comment-%s in %s is no longer marked as spam.', - NEW.id, - (SELECT name FROM "Service" WHERE id = NEW."serviceId")) - ); - PERFORM update_user_karma(NEW."authorId", 10); - END IF; -END; -$$ LANGUAGE plpgsql; - --- Function for handling vote changes -CREATE OR REPLACE FUNCTION handle_comment_vote_change() -RETURNS TRIGGER AS $$ -DECLARE - karma_points INT; - vote_action TEXT; - vote_description TEXT; - comment_author_id INT; - service_name TEXT; - upvote_change INT := 0; -- Variable to track change in upvotes -BEGIN - -- Get comment author and service info - SELECT c."authorId", s.name INTO comment_author_id, service_name - FROM "Comment" c - JOIN "Service" s ON c.id = COALESCE(NEW."commentId", OLD."commentId") AND c."serviceId" = s.id; - - -- Calculate karma impact based on vote type - IF TG_OP = 'INSERT' THEN - -- New vote - karma_points := CASE WHEN NEW.downvote THEN -1 ELSE 1 END; - vote_action := CASE WHEN NEW.downvote THEN 'comment_downvote' ELSE 'comment_upvote' END; - vote_description := format('Your comment #comment-%s in %s received %s', - NEW."commentId", - service_name, - CASE WHEN NEW.downvote THEN 'a downvote' ELSE 'an upvote' END); - upvote_change := CASE WHEN NEW.downvote THEN -1 ELSE 1 END; -- -1 for downvote, +1 for upvote - ELSIF TG_OP = 'DELETE' THEN - -- Removed vote - karma_points := CASE WHEN OLD.downvote THEN 1 ELSE -1 END; - vote_action := 'comment_vote_removed'; - vote_description := format('A vote was removed from your comment #comment-%s in %s', - OLD."commentId", - service_name); - upvote_change := CASE WHEN OLD.downvote THEN 1 ELSE -1 END; -- +1 if downvote removed, -1 if upvote removed - ELSIF TG_OP = 'UPDATE' THEN - -- Changed vote (from upvote to downvote or vice versa) - karma_points := CASE WHEN NEW.downvote THEN -2 ELSE 2 END; - vote_action := CASE WHEN NEW.downvote THEN 'comment_downvote' ELSE 'comment_upvote' END; - vote_description := format('Your comment #comment-%s in %s vote changed to %s', - NEW."commentId", - service_name, - CASE WHEN NEW.downvote THEN 'downvote' ELSE 'upvote' END); - upvote_change := CASE WHEN NEW.downvote THEN -2 ELSE 2 END; -- -2 if upvote->downvote, +2 if downvote->upvote - END IF; - - -- Record karma transaction and update user karma - PERFORM insert_karma_transaction( - comment_author_id, - karma_points, - vote_action, - COALESCE(NEW."commentId", OLD."commentId"), - vote_description - ); - - PERFORM update_user_karma(comment_author_id, karma_points); - - -- Update comment's upvotes count incrementally - UPDATE "Comment" - SET upvotes = upvotes + upvote_change - WHERE id = COALESCE(NEW."commentId", OLD."commentId"); - - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - --- Main function for handling status changes -CREATE OR REPLACE FUNCTION handle_comment_status_change() -RETURNS TRIGGER AS $$ -BEGIN - PERFORM handle_comment_approval(NEW, OLD); - PERFORM handle_comment_verification(NEW, OLD); - PERFORM handle_comment_spam_status(NEW, OLD); - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - --- Create triggers -CREATE TRIGGER comment_status_change_trigger - AFTER UPDATE OF status - ON "Comment" - FOR EACH ROW - EXECUTE FUNCTION handle_comment_status_change(); - -CREATE TRIGGER comment_suspicious_change_trigger - AFTER UPDATE OF suspicious - ON "Comment" - FOR EACH ROW - EXECUTE FUNCTION handle_comment_status_change(); - -CREATE TRIGGER comment_vote_change_trigger - AFTER INSERT OR UPDATE OR DELETE - ON "CommentVote" - FOR EACH ROW - EXECUTE FUNCTION handle_comment_vote_change(); - --- Function to handle suggestion status changes and award karma -CREATE OR REPLACE FUNCTION handle_suggestion_status_change() -RETURNS TRIGGER AS $$ -DECLARE - service_name TEXT; -BEGIN - -- Award karma for first approval - -- Check that OLD.status is not NULL to handle the initial creation case if needed, - -- and ensure it wasn't already APPROVED. - IF OLD.status IS DISTINCT FROM 'APPROVED' AND NEW.status = 'APPROVED' THEN - -- Fetch service name for the description - SELECT name INTO service_name FROM "Service" WHERE id = NEW."serviceId"; - - -- Insert karma transaction, linking it to the suggestion - PERFORM insert_karma_transaction( - NEW."userId", - 10, - 'suggestion_approved', - NULL, -- p_comment_id (not applicable) - format('Your suggestion for service ''%s'' has been approved!', service_name), - NEW.id -- p_suggestion_id - ); - - -- Update user's total karma - PERFORM update_user_karma(NEW."userId", 10); - END IF; - - RETURN NEW; -- Result is ignored since this is an AFTER trigger -END; -$$ LANGUAGE plpgsql; - --- Create triggers -CREATE TRIGGER suggestion_status_change_trigger - AFTER UPDATE OF status - ON "ServiceSuggestion" - FOR EACH ROW - EXECUTE FUNCTION handle_suggestion_status_change(); diff --git a/web/prisma/triggers/02_service_score.sql b/web/prisma/triggers/02_service_score.sql deleted file mode 100644 index 8754201..0000000 --- a/web/prisma/triggers/02_service_score.sql +++ /dev/null @@ -1,264 +0,0 @@ --- This script defines PostgreSQL functions and triggers for managing service scores: --- 1. Automatically calculates and updates privacy, trust, and overall scores --- for services when services or their attributes change. --- 2. Updates the isRecentlyListed flag for services listed within the last 15 days. --- 3. Queues asynchronous score recalculation in "ServiceScoreRecalculationJob" --- when an "Attribute" definition (e.g., points) is updated, ensuring --- efficient handling of widespread score updates. - --- Drop existing triggers first -DROP TRIGGER IF EXISTS service_score_update_trigger ON "Service"; -DROP TRIGGER IF EXISTS service_attribute_change_trigger ON "ServiceAttribute"; -DROP TRIGGER IF EXISTS attribute_change_trigger ON "Attribute"; - --- Drop existing functions -DROP FUNCTION IF EXISTS calculate_service_scores(); -DROP FUNCTION IF EXISTS calculate_privacy_score(); -DROP FUNCTION IF EXISTS calculate_trust_score(); -DROP FUNCTION IF EXISTS calculate_overall_score(); -DROP FUNCTION IF EXISTS recalculate_scores_for_attribute(); - --- Calculate privacy score based on service attributes and properties -CREATE OR REPLACE FUNCTION calculate_privacy_score(service_id INT) -RETURNS INT AS $$ -DECLARE - privacy_score INT := 50; -- Start from middle value (50) - kyc_factor INT; - onion_factor INT := 0; - i2p_factor INT := 0; - monero_factor INT := 0; - open_source_factor INT := 0; - p2p_factor INT := 0; - decentralized_factor INT := 0; - attributes_score INT := 0; -BEGIN - -- Get service data - SELECT - CASE - WHEN "kycLevel" = 0 THEN 25 -- No KYC is best for privacy - WHEN "kycLevel" = 1 THEN 10 -- Minimal KYC - WHEN "kycLevel" = 2 THEN -5 -- Moderate KYC - WHEN "kycLevel" = 3 THEN -15 -- More KYC - WHEN "kycLevel" = 4 THEN -25 -- Full mandatory KYC - ELSE 0 -- Default to no change - END - INTO kyc_factor - FROM "Service" - WHERE "id" = service_id; - - -- Check for onion URLs - IF EXISTS ( - SELECT 1 FROM "Service" - WHERE "id" = service_id AND array_length("onionUrls", 1) > 0 - ) THEN - onion_factor := 5; - END IF; - - -- Check for i2p URLs - IF EXISTS ( - SELECT 1 FROM "Service" - WHERE "id" = service_id AND array_length("i2pUrls", 1) > 0 - ) THEN - i2p_factor := 5; - END IF; - - -- Check for Monero acceptance - IF EXISTS ( - SELECT 1 FROM "Service" - WHERE "id" = service_id AND 'MONERO' = ANY("acceptedCurrencies") - ) THEN - monero_factor := 5; - END IF; - - -- Calculate score from privacy attributes - directly use the points - SELECT COALESCE(SUM(a."privacyPoints"), 0) - INTO attributes_score - FROM "ServiceAttribute" sa - JOIN "Attribute" a ON sa."attributeId" = a."id" - WHERE sa."serviceId" = service_id AND a."category" = 'PRIVACY'; - - -- Calculate final privacy score (base 100) - privacy_score := privacy_score + kyc_factor + onion_factor + i2p_factor + monero_factor + open_source_factor + p2p_factor + decentralized_factor + attributes_score; - - -- Ensure the score is in reasonable bounds (0-100) - privacy_score := GREATEST(0, LEAST(100, privacy_score)); - - RETURN privacy_score; -END; -$$ LANGUAGE plpgsql; - --- Calculate trust score based on service attributes and verification status -CREATE OR REPLACE FUNCTION calculate_trust_score(service_id INT) -RETURNS INT AS $$ -DECLARE - trust_score INT := 50; -- Start from middle value (50) - verification_factor INT; - attributes_score INT := 0; -BEGIN - -- Get verification status factor - SELECT - CASE - WHEN "verificationStatus" = 'VERIFICATION_SUCCESS' THEN 10 - WHEN "verificationStatus" = 'APPROVED' THEN 5 - WHEN "verificationStatus" = 'COMMUNITY_CONTRIBUTED' THEN 0 - WHEN "verificationStatus" = 'VERIFICATION_FAILED' THEN -50 - ELSE 0 - END - INTO verification_factor - FROM "Service" - WHERE id = service_id; - - -- Calculate score from trust attributes - directly use the points - SELECT COALESCE(SUM(a."trustPoints"), 0) - INTO attributes_score - FROM "ServiceAttribute" sa - JOIN "Attribute" a ON sa."attributeId" = a.id - WHERE sa."serviceId" = service_id AND a.category = 'TRUST'; - - -- Apply penalty if service was listed within the last 15 days - IF EXISTS ( - SELECT 1 - FROM "Service" - WHERE id = service_id - AND "listedAt" IS NOT NULL - AND "verificationStatus" = 'APPROVED' - AND (NOW() - "listedAt") <= INTERVAL '15 days' - ) THEN - trust_score := trust_score - 10; - -- Update the isRecentlyListed flag to true - UPDATE "Service" - SET "isRecentlyListed" = TRUE - WHERE id = service_id; - ELSE - -- Update the isRecentlyListed flag to false - UPDATE "Service" - SET "isRecentlyListed" = FALSE - WHERE id = service_id; - END IF; - - -- Calculate final trust score (base 100) - trust_score := trust_score + verification_factor + attributes_score; - - -- Ensure the score is in reasonable bounds (0-100) - trust_score := GREATEST(0, LEAST(100, trust_score)); - - RETURN trust_score; -END; -$$ LANGUAGE plpgsql; - --- Calculate overall score based on weighted average of privacy and trust scores -CREATE OR REPLACE FUNCTION calculate_overall_score(service_id INT, privacy_score INT, trust_score INT) -RETURNS INT AS $$ -DECLARE - overall_score INT; -BEGIN - overall_score := CAST(ROUND(((privacy_score * 0.6) + (trust_score * 0.4)) / 10.0) AS INT); - RETURN GREATEST(0, LEAST(10, overall_score)); -END; -$$ LANGUAGE plpgsql; - --- Main function to calculate all scores for a service -CREATE OR REPLACE FUNCTION calculate_service_scores() -RETURNS TRIGGER AS $$ -DECLARE - privacy_score INT; - trust_score INT; - overall_score INT; - service_id INT; -BEGIN - -- Determine which service ID to use based on the trigger context and table - IF TG_TABLE_NAME = 'Service' THEN - IF TG_OP = 'INSERT' OR TG_OP = 'UPDATE' THEN - service_id := NEW."id"; - END IF; - ELSIF TG_TABLE_NAME = 'ServiceAttribute' THEN - IF TG_OP = 'DELETE' THEN - service_id := OLD."serviceId"; - ELSE -- INSERT or UPDATE - service_id := NEW."serviceId"; - END IF; - END IF; - - -- Calculate each score - privacy_score := calculate_privacy_score(service_id); - trust_score := calculate_trust_score(service_id); - overall_score := calculate_overall_score(service_id, privacy_score, trust_score); - - -- Cap score if service is flagged as scam (verificationStatus = 'VERIFICATION_FAILED') - IF (SELECT "verificationStatus" FROM "Service" WHERE "id" = service_id) = 'VERIFICATION_FAILED' THEN - IF overall_score > 3 THEN - overall_score := 3; - ELSIF overall_score < 0 THEN - overall_score := 0; - END IF; - END IF; - - -- Update the service with the new scores - UPDATE "Service" - SET - "privacyScore" = privacy_score, - "trustScore" = trust_score, - "overallScore" = overall_score - WHERE "id" = service_id; - - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - --- Create trigger to recalculate scores when service is created or updated -CREATE TRIGGER service_score_update_trigger - AFTER INSERT OR UPDATE - ON "Service" - FOR EACH ROW - WHEN (pg_trigger_depth() < 2) -- Prevent recursive triggering - EXECUTE FUNCTION calculate_service_scores(); - --- Create trigger to recalculate scores when service attributes change -CREATE TRIGGER service_attribute_change_trigger - AFTER INSERT OR UPDATE OR DELETE - ON "ServiceAttribute" - FOR EACH ROW - WHEN (pg_trigger_depth() < 2) -- Prevent recursive triggering - EXECUTE FUNCTION calculate_service_scores(); - --- Function to queue score recalculation for all services with a specific attribute -CREATE OR REPLACE FUNCTION queue_service_score_recalculation_for_attribute() -RETURNS TRIGGER AS $$ -DECLARE - service_rec RECORD; -BEGIN - -- Only trigger recalculation if relevant fields changed - IF (TG_OP = 'UPDATE' AND ( - OLD."privacyPoints" != NEW."privacyPoints" OR - OLD."trustPoints" != NEW."trustPoints" OR - OLD."type" != NEW."type" OR - OLD."category" != NEW."category" - )) THEN - -- Find all services that have this attribute and queue a recalculation job - FOR service_rec IN - SELECT DISTINCT sa."serviceId" - FROM "ServiceAttribute" sa - WHERE sa."attributeId" = NEW.id - LOOP - -- Insert a job into the queue table - -- ON CONFLICT clause ensures we don't queue the same service multiple times per transaction - INSERT INTO "ServiceScoreRecalculationJob" ("serviceId", "createdAt", "processedAt") - VALUES (service_rec."serviceId", NOW(), NULL) - ON CONFLICT ("serviceId") DO UPDATE SET "processedAt" = NULL, "createdAt" = NOW(); - - END LOOP; - END IF; - - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - --- Create constraint trigger to queue score recalculation when attributes are updated -DROP TRIGGER IF EXISTS attribute_change_trigger ON "Attribute"; -CREATE CONSTRAINT TRIGGER attribute_change_trigger - AFTER UPDATE - ON "Attribute" - DEFERRABLE INITIALLY DEFERRED - FOR EACH ROW - WHEN (pg_trigger_depth() < 2) - EXECUTE FUNCTION queue_service_score_recalculation_for_attribute(); diff --git a/web/prisma/triggers/03_service_user_rating.sql b/web/prisma/triggers/03_service_user_rating.sql deleted file mode 100644 index e49fec9..0000000 --- a/web/prisma/triggers/03_service_user_rating.sql +++ /dev/null @@ -1,57 +0,0 @@ --- This script defines a PostgreSQL function and trigger to automatically calculate --- and update the average user rating for services based on associated comments. --- The average rating is recalculated whenever comments are added, updated, or deleted. - --- Drop existing triggers first -DROP TRIGGER IF EXISTS comment_average_rating_trigger ON "Comment"; - --- Drop existing functions -DROP FUNCTION IF EXISTS calculate_average_rating(); - --- Calculate average rating based on active comments with approved or verified status -CREATE OR REPLACE FUNCTION calculate_average_rating() -RETURNS TRIGGER AS $$ -DECLARE - affected_service_id INT; - average_user_rating DECIMAL; -BEGIN - -- Determine which service ID to use based on the trigger context - IF TG_OP = 'DELETE' THEN - affected_service_id := OLD."serviceId"; - ELSE -- INSERT or UPDATE - affected_service_id := NEW."serviceId"; - END IF; - - -- Calculate average rating from active comments with approved or verified status - -- Excluding suspicious comments and replies (comments with parentId not null) - - SELECT AVG(rating) INTO average_user_rating - FROM "Comment" - WHERE "serviceId" = affected_service_id - AND "parentId" IS NULL - AND rating IS NOT NULL - AND (status = 'APPROVED' OR status = 'VERIFIED') - AND "ratingActive" = true - AND suspicious = false; - - -- Update the service with the new average rating - UPDATE "Service" - SET "averageUserRating" = average_user_rating - WHERE "id" = affected_service_id; - - -- Return the appropriate record based on operation - IF TG_OP = 'DELETE' THEN - RETURN OLD; - ELSE - RETURN NEW; - END IF; -END; -$$ LANGUAGE plpgsql; - --- Create trigger to recalculate average rating when comments are created, updated, or deleted -CREATE TRIGGER comment_average_rating_trigger - AFTER INSERT OR UPDATE OR DELETE - ON "Comment" - FOR EACH ROW - WHEN (pg_trigger_depth() < 2) -- Prevent recursive triggering - EXECUTE FUNCTION calculate_average_rating(); \ No newline at end of file diff --git a/web/prisma/triggers/04_service_verification_status.sql b/web/prisma/triggers/04_service_verification_status.sql deleted file mode 100644 index c22e900..0000000 --- a/web/prisma/triggers/04_service_verification_status.sql +++ /dev/null @@ -1,48 +0,0 @@ --- This script manages the `listedAt`, `verifiedAt`, and `isRecentlyListed` timestamps --- for services based on changes to their `verificationStatus`. It ensures these timestamps --- are set or cleared appropriately when a service's verification status is updated. - -CREATE OR REPLACE FUNCTION manage_service_timestamps() -RETURNS TRIGGER AS $$ -BEGIN - -- Manage listedAt timestamp - IF NEW."verificationStatus" IN ('APPROVED', 'VERIFICATION_SUCCESS') THEN - -- Set listedAt only on the first time status becomes APPROVED or VERIFICATION_SUCCESS - IF OLD."listedAt" IS NULL THEN - NEW."listedAt" := NOW(); - NEW."isRecentlyListed" := TRUE; - END IF; - ELSIF OLD."verificationStatus" IN ('APPROVED', 'VERIFICATION_SUCCESS') THEN - -- Clear listedAt if the status changes FROM APPROVED or VERIFICATION_SUCCESS to something else - -- The trigger's WHEN clause ensures NEW."verificationStatus" is different. - NEW."listedAt" := NULL; - NEW."isRecentlyListed" := FALSE; - END IF; - - -- Manage verifiedAt timestamp - IF NEW."verificationStatus" = 'VERIFICATION_SUCCESS' THEN - -- Set verifiedAt when status changes TO VERIFICATION_SUCCESS - NEW."verifiedAt" := NOW(); - NEW."isRecentlyListed" := FALSE; - ELSIF OLD."verificationStatus" = 'VERIFICATION_SUCCESS' THEN - -- Clear verifiedAt when status changes FROM VERIFICATION_SUCCESS - -- The trigger's WHEN clause ensures NEW."verificationStatus" is different. - NEW."verifiedAt" := NULL; - NEW."isRecentlyListed" := FALSE; - END IF; - - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - --- Drop the old trigger first if it exists under the old name -DROP TRIGGER IF EXISTS trigger_set_service_listed_at ON "Service"; --- Drop the trigger if it exists under the new name -DROP TRIGGER IF EXISTS trigger_manage_service_timestamps ON "Service"; - -CREATE TRIGGER trigger_manage_service_timestamps -BEFORE UPDATE OF "verificationStatus" ON "Service" -FOR EACH ROW --- Only execute the function if the verificationStatus value has actually changed -WHEN (OLD."verificationStatus" IS DISTINCT FROM NEW."verificationStatus") -EXECUTE FUNCTION manage_service_timestamps(); diff --git a/web/prisma/triggers/05_service_events.sql b/web/prisma/triggers/05_service_events.sql deleted file mode 100644 index 77b01b2..0000000 --- a/web/prisma/triggers/05_service_events.sql +++ /dev/null @@ -1,399 +0,0 @@ --- Service Events Trigger --- This trigger automatically creates events when services are updated --- to track important changes over time - -CREATE OR REPLACE FUNCTION trigger_service_events() -RETURNS TRIGGER AS $$ -DECLARE - change_descriptions TEXT[] := '{}'; - event_title TEXT; - event_content TEXT; - change_type TEXT := NULL; - event_time TIMESTAMP WITH TIME ZONE := transaction_timestamp(); - currency_desc TEXT; -BEGIN - -- Only proceed if this is an UPDATE operation - IF TG_OP <> 'UPDATE' THEN - RETURN NEW; - END IF; - - -- Check for domain/URL changes - IF OLD."serviceUrls" IS DISTINCT FROM NEW."serviceUrls" THEN - change_descriptions := array_append(change_descriptions, - 'Service URLs updated from ' || array_to_string(OLD."serviceUrls", ', ') || - ' to ' || array_to_string(NEW."serviceUrls", ', ') - ); - change_type := COALESCE(change_type, 'Domain change'); - END IF; - - -- Check for KYC level changes - IF OLD."kycLevel" IS DISTINCT FROM NEW."kycLevel" THEN - change_descriptions := array_append(change_descriptions, - 'KYC level changed from ' || OLD."kycLevel"::TEXT || ' to ' || NEW."kycLevel"::TEXT - ); - change_type := COALESCE(change_type, 'KYC update'); - END IF; - - -- Check for verification status changes - IF OLD."verificationStatus" IS DISTINCT FROM NEW."verificationStatus" THEN - change_descriptions := array_append(change_descriptions, - 'Verification status changed from ' || OLD."verificationStatus"::TEXT || ' to ' || NEW."verificationStatus"::TEXT - ); - change_type := COALESCE(change_type, 'Verification update'); - END IF; - - -- Check for description changes - IF OLD.description IS DISTINCT FROM NEW.description THEN - change_descriptions := array_append(change_descriptions, 'Description was updated'); - change_type := COALESCE(change_type, 'Description update'); - END IF; - - -- Check for currency changes - IF OLD."acceptedCurrencies" IS DISTINCT FROM NEW."acceptedCurrencies" THEN - -- Find currencies added - WITH - old_currencies AS (SELECT unnest(OLD."acceptedCurrencies") AS currency), - new_currencies AS (SELECT unnest(NEW."acceptedCurrencies") AS currency), - added_currencies AS ( - SELECT currency FROM new_currencies - EXCEPT - SELECT currency FROM old_currencies - ), - removed_currencies AS ( - SELECT currency FROM old_currencies - EXCEPT - SELECT currency FROM new_currencies - ) - - -- Temp variable for currency description - SELECT - CASE - WHEN (SELECT COUNT(*) FROM added_currencies) > 0 AND (SELECT COUNT(*) FROM removed_currencies) > 0 THEN - 'Currencies updated: added ' || array_to_string(ARRAY(SELECT currency FROM added_currencies), ', ') || - ', removed ' || array_to_string(ARRAY(SELECT currency FROM removed_currencies), ', ') - WHEN (SELECT COUNT(*) FROM added_currencies) > 0 THEN - 'Added currencies: ' || array_to_string(ARRAY(SELECT currency FROM added_currencies), ', ') - WHEN (SELECT COUNT(*) FROM removed_currencies) > 0 THEN - 'Removed currencies: ' || array_to_string(ARRAY(SELECT currency FROM removed_currencies), ', ') - ELSE - 'Currencies changed' - END - INTO currency_desc; - - IF currency_desc IS NOT NULL AND currency_desc <> '' THEN - change_descriptions := array_append(change_descriptions, currency_desc); - change_type := COALESCE(change_type, 'Currency update'); - END IF; - END IF; - - -- If there are changes, create an event - IF array_length(change_descriptions, 1) > 0 THEN - -- Create a title based on number of changes - IF array_length(change_descriptions, 1) = 1 THEN - event_title := COALESCE(change_type, 'Service updated'); -- Ensure title is not null - ELSE - event_title := 'Service updated'; - END IF; - - -- Create content with all changes - event_content := array_to_string(change_descriptions, '. '); - - -- Ensure content is not null or empty - IF event_content IS NULL OR event_content = '' THEN - event_content := 'Service details changed (content unavailable)'; - END IF; - - -- Insert the event - INSERT INTO "Event" ( - "title", - "content", - "type", - "visible", - "startedAt", - "endedAt", - "serviceId" - ) VALUES ( - event_title, - event_content, - 'UPDATE', - TRUE, - event_time, - event_time, - NEW.id - ); - END IF; - - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - --- Create a trigger for service updates -DROP TRIGGER IF EXISTS service_events_trigger ON "Service"; -CREATE TRIGGER service_events_trigger -AFTER UPDATE OF "serviceUrls", "kycLevel", "verificationStatus", "description", "acceptedCurrencies" ON "Service" -FOR EACH ROW -EXECUTE FUNCTION trigger_service_events(); - --- Additional trigger to monitor changes to ServiceAttribute -CREATE OR REPLACE FUNCTION trigger_service_attribute_events() -RETURNS TRIGGER AS $$ -DECLARE - attribute_name TEXT; - service_name TEXT; - event_title TEXT := 'Attribute change'; -- Default title - event_content TEXT; - event_time TIMESTAMP WITH TIME ZONE := transaction_timestamp(); - target_service_id INT; - service_exists BOOLEAN; - service_created_at TIMESTAMP WITH TIME ZONE; - is_new_service BOOLEAN := FALSE; -BEGIN - -- Determine target service ID and operation type - IF TG_OP = 'INSERT' THEN - target_service_id := NEW."serviceId"; - - -- Check if this is a new service (created within the last minute) - -- This helps prevent events when attributes are initially added to a new service - SELECT "createdAt" INTO service_created_at FROM "Service" WHERE id = target_service_id; - IF service_created_at IS NOT NULL AND (event_time - service_created_at) < INTERVAL '1 minute' THEN - is_new_service := TRUE; - RETURN NEW; -- Skip event creation for new services - END IF; - - SELECT title INTO attribute_name FROM "Attribute" WHERE id = NEW."attributeId"; - SELECT name INTO service_name FROM "Service" WHERE id = target_service_id; - IF attribute_name IS NOT NULL AND service_name IS NOT NULL THEN - event_title := 'Attribute added'; - event_content := 'Attribute "' || attribute_name || '" was added to ' || service_name; - ELSE - event_content := 'An attribute was added (details unavailable)'; - END IF; - - ELSIF TG_OP = 'DELETE' THEN - target_service_id := OLD."serviceId"; - -- Check if the service still exists before trying to fetch its name or create an event - SELECT EXISTS (SELECT 1 FROM "Service" WHERE id = target_service_id) INTO service_exists; - IF service_exists THEN - SELECT title INTO attribute_name FROM "Attribute" WHERE id = OLD."attributeId"; - SELECT name INTO service_name FROM "Service" WHERE id = target_service_id; - IF attribute_name IS NOT NULL AND service_name IS NOT NULL THEN - event_title := 'Attribute removed'; - event_content := 'Attribute "' || attribute_name || '" was removed from ' || service_name; - ELSE - -- This case might happen if attribute was deleted concurrently - event_content := 'An attribute was removed (details unavailable)'; - END IF; - ELSE - -- Service was deleted, don't create an event - RETURN OLD; - END IF; - END IF; - - -- Ensure content is not null/empty and insert - IF event_content IS NOT NULL AND event_content <> '' AND target_service_id IS NOT NULL AND NOT is_new_service THEN - -- Re-check service existence right before insert just in case of concurrency on INSERT - IF TG_OP = 'INSERT' THEN - SELECT EXISTS (SELECT 1 FROM "Service" WHERE id = target_service_id) INTO service_exists; - END IF; - - IF service_exists THEN - INSERT INTO "Event" ( - "title", - "content", - "type", - "visible", - "startedAt", - "endedAt", - "serviceId" - ) VALUES ( - event_title, - event_content, - 'UPDATE', - TRUE, - event_time, - event_time, - target_service_id - ); - END IF; - END IF; - - -- Return appropriate record - IF TG_OP = 'INSERT' THEN - RETURN NEW; - ELSE - RETURN OLD; - END IF; -END; -$$ LANGUAGE plpgsql; - --- Create a trigger for service attribute changes -DROP TRIGGER IF EXISTS service_attribute_events_trigger ON "ServiceAttribute"; -CREATE TRIGGER service_attribute_events_trigger -AFTER INSERT OR DELETE ON "ServiceAttribute" -FOR EACH ROW -EXECUTE FUNCTION trigger_service_attribute_events(); - --- Additional trigger to monitor changes to service categories -CREATE OR REPLACE FUNCTION trigger_service_category_events() -RETURNS TRIGGER AS $$ -DECLARE - category_name TEXT; - service_name TEXT; - event_title TEXT := 'Category change'; -- Default title - event_content TEXT; - event_time TIMESTAMP WITH TIME ZONE := transaction_timestamp(); - target_service_id INT; - service_exists BOOLEAN; - service_created_at TIMESTAMP WITH TIME ZONE; - is_new_service BOOLEAN := FALSE; -BEGIN - -- Determine target service ID and operation type - IF TG_OP = 'INSERT' THEN - target_service_id := NEW."A"; - - -- Check if this is a new service (created within the last minute) - -- This helps prevent events when categories are initially added to a new service - SELECT "createdAt" INTO service_created_at FROM "Service" WHERE id = target_service_id; - IF service_created_at IS NOT NULL AND (event_time - service_created_at) < INTERVAL '1 minute' THEN - is_new_service := TRUE; - RETURN NEW; -- Skip event creation for new services - END IF; - - SELECT name INTO category_name FROM "Category" WHERE id = NEW."B"; - SELECT name INTO service_name FROM "Service" WHERE id = target_service_id; - IF category_name IS NOT NULL AND service_name IS NOT NULL THEN - event_title := 'Category added'; - event_content := 'Category "' || category_name || '" was added to ' || service_name; - ELSE - event_content := 'A category was added (details unavailable)'; - END IF; - - ELSIF TG_OP = 'DELETE' THEN - target_service_id := OLD."A"; - -- Check if the service still exists before trying to fetch its name or create an event - SELECT EXISTS (SELECT 1 FROM "Service" WHERE id = target_service_id) INTO service_exists; - IF service_exists THEN - SELECT name INTO category_name FROM "Category" WHERE id = OLD."B"; - SELECT name INTO service_name FROM "Service" WHERE id = target_service_id; - IF category_name IS NOT NULL AND service_name IS NOT NULL THEN - event_title := 'Category removed'; - event_content := 'Category "' || category_name || '" was removed from ' || service_name; - ELSE - -- This case might happen if category was deleted concurrently - event_content := 'A category was removed (details unavailable)'; - END IF; - ELSE - -- Service was deleted, don't create an event - RETURN OLD; - END IF; - END IF; - - -- Ensure content is not null/empty and insert - IF event_content IS NOT NULL AND event_content <> '' AND target_service_id IS NOT NULL AND NOT is_new_service THEN - -- Re-check service existence right before insert just in case of concurrency on INSERT - IF TG_OP = 'INSERT' THEN - SELECT EXISTS (SELECT 1 FROM "Service" WHERE id = target_service_id) INTO service_exists; - END IF; - - IF service_exists THEN - INSERT INTO "Event" ( - "title", - "content", - "type", - "visible", - "startedAt", - "endedAt", - "serviceId" - ) VALUES ( - event_title, - event_content, - 'UPDATE', - TRUE, - event_time, - event_time, - target_service_id - ); - END IF; - END IF; - - -- Return appropriate record - IF TG_OP = 'INSERT' THEN - RETURN NEW; - ELSE - RETURN OLD; - END IF; -END; -$$ LANGUAGE plpgsql; - --- Create a trigger for service category changes (on the junction table) -DROP TRIGGER IF EXISTS service_category_events_trigger ON "_ServiceToCategory"; -CREATE TRIGGER service_category_events_trigger -AFTER INSERT OR DELETE ON "_ServiceToCategory" -FOR EACH ROW -EXECUTE FUNCTION trigger_service_category_events(); - --- Verification Steps Trigger --- This trigger creates events when verification steps are added or status changes -CREATE OR REPLACE FUNCTION trigger_verification_step_events() -RETURNS TRIGGER AS $$ -DECLARE - service_name TEXT; - event_title TEXT; - event_content TEXT; - event_time TIMESTAMP WITH TIME ZONE := transaction_timestamp(); - service_exists BOOLEAN; -BEGIN - -- Check if the service exists - SELECT EXISTS (SELECT 1 FROM "Service" WHERE id = NEW."serviceId") INTO service_exists; - - IF NOT service_exists THEN - -- Service was deleted or doesn't exist, don't create an event - RETURN NEW; - END IF; - - -- Get service name - SELECT name INTO service_name FROM "Service" WHERE id = NEW."serviceId"; - - -- Handle different operations - IF TG_OP = 'INSERT' THEN - event_title := 'Verification step added'; - event_content := '"' || NEW.title || '" was added'; - - ELSIF TG_OP = 'UPDATE' AND OLD.status IS DISTINCT FROM NEW.status THEN - event_title := 'Verification step ' || replace(lower(NEW.status::TEXT), '_', ' '); - event_content := '"' || NEW.title || '" status changed from ' || - replace(lower(OLD.status::TEXT), '_', ' ') || ' to ' || replace(lower(NEW.status::TEXT), '_', ' '); - ELSE - -- No relevant changes, exit - RETURN NEW; - END IF; - - -- Insert the event - INSERT INTO "Event" ( - "title", - "content", - "type", - "visible", - "startedAt", - "endedAt", - "serviceId" - ) VALUES ( - event_title, - event_content, - 'UPDATE', - TRUE, - event_time, - event_time, - NEW."serviceId" - ); - - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - --- Create trigger for verification step changes -DROP TRIGGER IF EXISTS verification_step_events_trigger ON "VerificationStep"; -CREATE TRIGGER verification_step_events_trigger -AFTER INSERT OR UPDATE OF status ON "VerificationStep" -FOR EACH ROW -EXECUTE FUNCTION trigger_verification_step_events(); diff --git a/web/prisma/triggers/06_notifications_comments.sql b/web/prisma/triggers/06_notifications_comments.sql deleted file mode 100644 index 6c5acee..0000000 --- a/web/prisma/triggers/06_notifications_comments.sql +++ /dev/null @@ -1,227 +0,0 @@ --- Function & Trigger for Root Comment Insertions (Approved/Verified) -CREATE OR REPLACE FUNCTION notify_root_comment_inserted() -RETURNS TRIGGER AS $$ -DECLARE - watcher_count INT; -BEGIN - RAISE NOTICE '[notify_root_comment_inserted] Trigger fired for comment ID: %', NEW.id; - WITH watchers AS ( - SELECT np."userId", np."enableNotifyPendingRepliesOnWatch" - FROM "_onRootCommentCreatedForServices" rc - JOIN "NotificationPreferences" np ON rc."A" = np."id" - WHERE rc."B" = NEW."serviceId" - AND np."userId" <> NEW."authorId" - ) - INSERT INTO "Notification" ("userId", "type", "aboutCommentId") - SELECT w."userId", - 'ROOT_COMMENT_CREATED', - NEW."id" - FROM watchers w - WHERE ( - NEW.status IN ('APPROVED', 'VERIFIED') - OR (NEW.status = 'PENDING' AND w."enableNotifyPendingRepliesOnWatch") - ) - ON CONFLICT DO NOTHING; - - RAISE NOTICE '[notify_root_comment_inserted] Inserted % notifications for comment ID: %', FOUND, NEW.id; - - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - -DROP TRIGGER IF EXISTS trg_notify_root_comment_inserted ON "Comment"; -CREATE TRIGGER trg_notify_root_comment_inserted - AFTER INSERT ON "Comment" - FOR EACH ROW - WHEN (NEW."parentId" IS NULL) - EXECUTE FUNCTION notify_root_comment_inserted(); - --- Function & Trigger for Reply Comment Insertions -CREATE OR REPLACE FUNCTION notify_reply_comment_inserted() -RETURNS TRIGGER AS $$ -BEGIN - WITH watchers AS ( - SELECT np."userId", np."enableNotifyPendingRepliesOnWatch" - FROM "_watchedComments" w - JOIN "NotificationPreferences" np ON w."B" = np."id" - WHERE w."A" = NEW."parentId" - AND np."userId" <> NEW."authorId" - ) - INSERT INTO "Notification" ("userId", "type", "aboutCommentId") - SELECT w."userId", - 'REPLY_COMMENT_CREATED', - NEW."id" - FROM watchers w - WHERE ( - NEW.status IN ('APPROVED', 'VERIFIED') - OR (NEW.status = 'PENDING' AND w."enableNotifyPendingRepliesOnWatch") - ) - ON CONFLICT DO NOTHING; - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - -DROP TRIGGER IF EXISTS trg_notify_reply_comment_inserted ON "Comment"; -CREATE TRIGGER trg_notify_reply_comment_inserted - AFTER INSERT ON "Comment" - FOR EACH ROW - WHEN (NEW."parentId" IS NOT NULL) - EXECUTE FUNCTION notify_reply_comment_inserted(); - --- Function & Trigger for Reply Approval/Verification -CREATE OR REPLACE FUNCTION notify_reply_approved() -RETURNS TRIGGER AS $$ -BEGIN - WITH watchers AS ( - SELECT np."userId" - FROM "_watchedComments" w - JOIN "NotificationPreferences" np ON w."B" = np."id" - WHERE w."A" = NEW."parentId" - AND np."userId" <> NEW."authorId" - ) - INSERT INTO "Notification" ("userId", "type", "aboutCommentId") - SELECT w."userId", - 'REPLY_COMMENT_CREATED', - NEW."id" - FROM watchers w - ON CONFLICT DO NOTHING; - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - -DROP TRIGGER IF EXISTS trg_notify_reply_approved ON "Comment"; -CREATE TRIGGER trg_notify_reply_approved - AFTER UPDATE OF status ON "Comment" - FOR EACH ROW - WHEN (NEW."parentId" IS NOT NULL AND NEW.status IN ('APPROVED', 'VERIFIED') AND OLD.status NOT IN ('APPROVED', 'VERIFIED')) - EXECUTE FUNCTION notify_reply_approved(); - -DROP TRIGGER IF EXISTS trg_notify_root_approved ON "Comment"; - -CREATE OR REPLACE FUNCTION notify_root_approved() -RETURNS TRIGGER AS $$ -BEGIN - WITH watchers AS ( - SELECT np."userId" - FROM "_onRootCommentCreatedForServices" rc - JOIN "NotificationPreferences" np ON rc."A" = np."id" - WHERE rc."B" = NEW."serviceId" - AND np."userId" <> NEW."authorId" - AND NOT np."enableNotifyPendingRepliesOnWatch" - ) - INSERT INTO "Notification" ("userId", "type", "aboutCommentId") - SELECT w."userId", - 'ROOT_COMMENT_CREATED', - NEW."id" - FROM watchers w - ON CONFLICT DO NOTHING; - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - -CREATE TRIGGER trg_notify_root_approved - AFTER UPDATE OF status ON "Comment" - FOR EACH ROW - WHEN (NEW."parentId" IS NULL AND NEW.status IN ('APPROVED', 'VERIFIED') AND OLD.status NOT IN ('APPROVED', 'VERIFIED')) - EXECUTE FUNCTION notify_root_approved(); - --- Function & Trigger for Comment Status Changes (Status, Suspicious, AdminReview) -CREATE OR REPLACE FUNCTION notify_comment_status_changed() -RETURNS TRIGGER AS $$ -DECLARE - v_status_change "CommentStatusChange" := NULL; -BEGIN - -- Determine the status change type - IF NEW.status <> OLD.status THEN - IF NEW.status = 'APPROVED' THEN v_status_change := 'STATUS_CHANGED_TO_APPROVED'; - ELSIF NEW.status = 'VERIFIED' THEN v_status_change := 'STATUS_CHANGED_TO_VERIFIED'; - ELSIF NEW.status = 'REJECTED' THEN v_status_change := 'STATUS_CHANGED_TO_REJECTED'; - ELSIF (NEW.status = 'PENDING' OR NEW.status = 'HUMAN_PENDING') AND (OLD.status <> 'PENDING' AND OLD.status <> 'HUMAN_PENDING') THEN v_status_change := 'STATUS_CHANGED_TO_PENDING'; - END IF; - ELSIF NEW.suspicious <> OLD.suspicious THEN - IF NEW.suspicious = true THEN v_status_change := 'MARKED_AS_SPAM'; - ELSE v_status_change := 'UNMARKED_AS_SPAM'; - END IF; - ELSIF NEW."requiresAdminReview" <> OLD."requiresAdminReview" THEN - IF NEW."requiresAdminReview" = true THEN v_status_change := 'MARKED_FOR_ADMIN_REVIEW'; - ELSE v_status_change := 'UNMARKED_FOR_ADMIN_REVIEW'; - END IF; - END IF; - - -- If a relevant status change occurred, notify watchers of THIS comment - IF v_status_change IS NOT NULL THEN - WITH watchers AS ( - -- Get all watchers excluding author - SELECT np."userId" - FROM "_watchedComments" w - JOIN "NotificationPreferences" np ON w."B" = np."id" - WHERE w."A" = NEW."id" - AND np."userId" <> NEW."authorId" - AND np."enableOnMyCommentStatusChange" - - UNION ALL - - -- Add author if they have enabled notifications for their own comments - SELECT np."userId" - FROM "NotificationPreferences" np - WHERE np."userId" = NEW."authorId" - AND np."enableOnMyCommentStatusChange" - ) - INSERT INTO "Notification" ("userId", "type", "aboutCommentId", "aboutCommentStatusChange") - SELECT w."userId", - 'COMMENT_STATUS_CHANGE', - NEW."id", - v_status_change - FROM watchers w - ON CONFLICT DO NOTHING; - END IF; - - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - -DROP TRIGGER IF EXISTS trg_notify_comment_status_changed ON "Comment"; -CREATE TRIGGER trg_notify_comment_status_changed - AFTER UPDATE OF status, suspicious, "requiresAdminReview" ON "Comment" - FOR EACH ROW - WHEN (NEW.status <> OLD.status OR NEW.suspicious <> OLD.suspicious OR NEW."requiresAdminReview" <> OLD."requiresAdminReview") - EXECUTE FUNCTION notify_comment_status_changed(); - --- Function & Trigger for Community Note Added -CREATE OR REPLACE FUNCTION notify_community_note_added() -RETURNS TRIGGER AS $$ -BEGIN - -- Notify watchers of this specific comment (excluding author) - WITH watchers AS ( - SELECT np."userId" - FROM "_watchedComments" w - JOIN "NotificationPreferences" np ON w."B" = np."id" - WHERE w."A" = NEW."id" - AND np."userId" <> NEW."authorId" - ) - INSERT INTO "Notification" ("userId", "type", "aboutCommentId") - SELECT w."userId", - 'COMMUNITY_NOTE_ADDED', - NEW."id" - FROM watchers w - ON CONFLICT DO NOTHING; - - -- Always notify the author - INSERT INTO "Notification" ("userId", "type", "aboutCommentId") - VALUES (NEW."authorId", 'COMMUNITY_NOTE_ADDED', NEW."id") - ON CONFLICT DO NOTHING; - - RETURN NEW; -END; -$$ LANGUAGE plpgsql; - -DROP TRIGGER IF EXISTS trg_notify_community_note_added ON "Comment"; -CREATE TRIGGER trg_notify_community_note_added - AFTER UPDATE OF "communityNote" ON "Comment" - FOR EACH ROW - WHEN (NEW."communityNote" IS NOT NULL AND NEW."communityNote" <> '' AND (OLD."communityNote" IS NULL OR OLD."communityNote" = '')) - EXECUTE FUNCTION notify_community_note_added(); - --- Remove the old monolithic trigger and function definition if they still exist -DROP TRIGGER IF EXISTS comment_notifications_trigger ON "Comment"; -DROP FUNCTION IF EXISTS trigger_comment_notifications(); diff --git a/web/prisma/triggers/07_notifications_service_suggestion.sql b/web/prisma/triggers/07_notifications_service_suggestion.sql deleted file mode 100644 index 4da39fa..0000000 --- a/web/prisma/triggers/07_notifications_service_suggestion.sql +++ /dev/null @@ -1,72 +0,0 @@ -CREATE OR REPLACE FUNCTION trigger_service_suggestion_notifications() -RETURNS TRIGGER AS $$ -DECLARE - suggestion_status_change "ServiceSuggestionStatusChange"; -BEGIN - IF TG_OP = 'INSERT' THEN -- Corresponds to ServiceSuggestionMessage insert - -- Notify suggestion author (if not the sender) - INSERT INTO "Notification" ("userId", "type", "aboutServiceSuggestionId", "aboutServiceSuggestionMessageId") - SELECT s."userId", 'SUGGESTION_MESSAGE', NEW."suggestionId", NEW."id" - FROM "ServiceSuggestion" s - WHERE s."id" = NEW."suggestionId" - AND s."userId" <> NEW."userId" - AND NOT EXISTS ( - SELECT 1 FROM "Notification" n - WHERE n."userId" = s."userId" - AND n."type" = 'SUGGESTION_MESSAGE' - AND n."aboutServiceSuggestionMessageId" = NEW."id" - ); - - -- Notify all admins (except the sender), but only if sender is not admin - INSERT INTO "Notification" ("userId", "type", "aboutServiceSuggestionId", "aboutServiceSuggestionMessageId") - SELECT u."id", 'SUGGESTION_MESSAGE', NEW."suggestionId", NEW."id" - FROM "User" u - WHERE u."admin" = true - AND u."id" <> NEW."userId" - -- Only notify admins if the message sender is not an admin - AND NOT EXISTS (SELECT 1 FROM "User" WHERE "id" = NEW."userId" AND "admin" = true) - AND NOT EXISTS ( - SELECT 1 FROM "Notification" n - WHERE n."userId" = u."id" - AND n."type" = 'SUGGESTION_MESSAGE' - AND n."aboutServiceSuggestionMessageId" = NEW."id" - ); - - ELSIF TG_OP = 'UPDATE' THEN -- Corresponds to ServiceSuggestion status update - -- Notify suggestion author about status change - IF NEW.status <> OLD.status THEN - IF NEW.status = 'PENDING' THEN - suggestion_status_change := 'STATUS_CHANGED_TO_PENDING'; - ELSIF NEW.status = 'APPROVED' THEN - suggestion_status_change := 'STATUS_CHANGED_TO_APPROVED'; - ELSIF NEW.status = 'REJECTED' THEN - suggestion_status_change := 'STATUS_CHANGED_TO_REJECTED'; - ELSIF NEW.status = 'WITHDRAWN' THEN - suggestion_status_change := 'STATUS_CHANGED_TO_WITHDRAWN'; - END IF; - - INSERT INTO "Notification" ("userId", "type", "aboutServiceSuggestionId", "aboutSuggestionStatusChange") - VALUES (NEW."userId", 'SUGGESTION_STATUS_CHANGE', NEW."id", suggestion_status_change); - END IF; - END IF; - - -- Use RETURN NULL for AFTER triggers as the return value is ignored. - RETURN NULL; -END; -$$ LANGUAGE plpgsql; - --- Trigger for new messages -DROP TRIGGER IF EXISTS service_suggestion_message_notifications_trigger ON "ServiceSuggestionMessage"; -CREATE TRIGGER service_suggestion_message_notifications_trigger - AFTER INSERT ON "ServiceSuggestionMessage" - FOR EACH ROW - EXECUTE FUNCTION trigger_service_suggestion_notifications(); - --- Trigger for status updates -DROP TRIGGER IF EXISTS service_suggestion_status_notifications_trigger ON "ServiceSuggestion"; -CREATE TRIGGER service_suggestion_status_notifications_trigger - AFTER UPDATE OF status ON "ServiceSuggestion" - FOR EACH ROW - -- Only run the function if the status actually changed - WHEN (OLD.status IS DISTINCT FROM NEW.status) - EXECUTE FUNCTION trigger_service_suggestion_notifications(); diff --git a/web/prisma/triggers/08_notifications_service_events.sql b/web/prisma/triggers/08_notifications_service_events.sql deleted file mode 100644 index c003e49..0000000 --- a/web/prisma/triggers/08_notifications_service_events.sql +++ /dev/null @@ -1,28 +0,0 @@ -CREATE OR REPLACE FUNCTION trigger_service_events_notifications() -RETURNS TRIGGER AS $$ -BEGIN - -- Handle new Event insertions - IF TG_TABLE_NAME = 'Event' AND TG_OP = 'INSERT' THEN - INSERT INTO "Notification" ("userId", "type", "aboutServiceId", "aboutEventId") - SELECT np."userId", 'EVENT_CREATED', NEW."serviceId", NEW.id - FROM "_onEventCreatedForServices" oes - JOIN "NotificationPreferences" np ON oes."A" = np.id - WHERE oes."B" = NEW."serviceId" - AND NOT EXISTS ( - SELECT 1 FROM "Notification" n - WHERE n."userId" = np."userId" - AND n."type" = 'EVENT_CREATED' - AND n."aboutEventId" = NEW.id - ); - END IF; - - RETURN NULL; -END; -$$ LANGUAGE plpgsql; - --- Trigger for new Events -DROP TRIGGER IF EXISTS eVENT_CREATED_notifications_trigger ON "Event"; -CREATE TRIGGER eVENT_CREATED_notifications_trigger - AFTER INSERT ON "Event" - FOR EACH ROW - EXECUTE FUNCTION trigger_service_events_notifications(); diff --git a/web/prisma/triggers/09_notifications_service_status_updates.sql b/web/prisma/triggers/09_notifications_service_status_updates.sql deleted file mode 100644 index 16655c9..0000000 --- a/web/prisma/triggers/09_notifications_service_status_updates.sql +++ /dev/null @@ -1,37 +0,0 @@ -CREATE OR REPLACE FUNCTION trigger_service_verification_status_change_notifications() -RETURNS TRIGGER AS $$ -DECLARE - v_status_change "ServiceVerificationStatusChange"; -BEGIN - -- Check if verificationStatus actually changed - IF OLD."verificationStatus" IS DISTINCT FROM NEW."verificationStatus" THEN - -- Determine the correct ServiceVerificationStatusChange enum value - SELECT CASE NEW."verificationStatus" - WHEN 'COMMUNITY_CONTRIBUTED' THEN 'STATUS_CHANGED_TO_COMMUNITY_CONTRIBUTED' - WHEN 'APPROVED' THEN 'STATUS_CHANGED_TO_APPROVED' - WHEN 'VERIFICATION_SUCCESS' THEN 'STATUS_CHANGED_TO_VERIFICATION_SUCCESS' - WHEN 'VERIFICATION_FAILED' THEN 'STATUS_CHANGED_TO_VERIFICATION_FAILED' - ELSE NULL - END - INTO v_status_change; - - -- Only insert if we determined a valid status change enum - IF v_status_change IS NOT NULL THEN - INSERT INTO "Notification" ("userId", "type", "aboutServiceId", "aboutServiceVerificationStatusChange") - SELECT np."userId", 'SERVICE_VERIFICATION_STATUS_CHANGE', NEW.id, v_status_change - FROM "_onVerificationChangeForServices" oes - JOIN "NotificationPreferences" np ON oes."A" = np.id -- A -> NotificationPreferences.id - WHERE oes."B" = NEW.id; -- B -> Service.id - END IF; - END IF; - - RETURN NULL; -- Return NULL for AFTER trigger -END; -$$ LANGUAGE plpgsql; - --- Trigger for Service verificationStatus updates -DROP TRIGGER IF EXISTS service_verification_status_change_notifications_trigger ON "Service"; -CREATE TRIGGER service_verification_status_change_notifications_trigger - AFTER UPDATE ON "Service" - FOR EACH ROW - EXECUTE FUNCTION trigger_service_verification_status_change_notifications(); \ No newline at end of file diff --git a/web/prisma/triggers/10_notifications_user_status_change.sql b/web/prisma/triggers/10_notifications_user_status_change.sql deleted file mode 100644 index d968880..0000000 --- a/web/prisma/triggers/10_notifications_user_status_change.sql +++ /dev/null @@ -1,62 +0,0 @@ -CREATE OR REPLACE FUNCTION trigger_user_status_change_notifications() -RETURNS TRIGGER AS $$ -DECLARE - status_change "AccountStatusChange"; -BEGIN - -- Check for admin status change - IF OLD.admin IS DISTINCT FROM NEW.admin THEN - IF NEW.admin = true THEN - status_change := 'ADMIN_TRUE'; - ELSE - status_change := 'ADMIN_FALSE'; - END IF; - INSERT INTO "Notification" ("userId", "type", "aboutAccountStatusChange") - VALUES (NEW.id, 'ACCOUNT_STATUS_CHANGE', status_change); - END IF; - - -- Check for verified status change - IF OLD.verified IS DISTINCT FROM NEW.verified THEN - IF NEW.verified = true THEN - status_change := 'VERIFIED_TRUE'; - ELSE - status_change := 'VERIFIED_FALSE'; - END IF; - INSERT INTO "Notification" ("userId", "type", "aboutAccountStatusChange") - VALUES (NEW.id, 'ACCOUNT_STATUS_CHANGE', status_change); - END IF; - - -- Check for verifier status change - IF OLD.verifier IS DISTINCT FROM NEW.verifier THEN - IF NEW.verifier = true THEN - status_change := 'VERIFIER_TRUE'; - ELSE - status_change := 'VERIFIER_FALSE'; - END IF; - INSERT INTO "Notification" ("userId", "type", "aboutAccountStatusChange") - VALUES (NEW.id, 'ACCOUNT_STATUS_CHANGE', status_change); - END IF; - - -- Check for spammer status change - IF OLD.spammer IS DISTINCT FROM NEW.spammer THEN - IF NEW.spammer = true THEN - status_change := 'SPAMMER_TRUE'; - ELSE - status_change := 'SPAMMER_FALSE'; - END IF; - INSERT INTO "Notification" ("userId", "type", "aboutAccountStatusChange") - VALUES (NEW.id, 'ACCOUNT_STATUS_CHANGE', status_change); - END IF; - - -- Return NULL for AFTER triggers as the return value is ignored. - RETURN NULL; -END; -$$ LANGUAGE plpgsql; - --- Drop the trigger if it exists to ensure a clean setup -DROP TRIGGER IF EXISTS user_status_change_notifications_trigger ON "User"; - --- Create the trigger to fire after updates on specific status columns -CREATE TRIGGER user_status_change_notifications_trigger - AFTER UPDATE OF admin, verified, verifier, spammer ON "User" - FOR EACH ROW - EXECUTE FUNCTION trigger_user_status_change_notifications(); diff --git a/web/public/favicon-dev.svg b/web/public/favicon-dev.svg deleted file mode 100644 index 45ecc30..0000000 --- a/web/public/favicon-dev.svg +++ /dev/null @@ -1,5 +0,0 @@ - - KYCnot.me logo - - diff --git a/web/public/favicon-lightmode.svg b/web/public/favicon-lightmode.svg deleted file mode 100644 index 3adafde..0000000 --- a/web/public/favicon-lightmode.svg +++ /dev/null @@ -1,5 +0,0 @@ - - KYCnot.me logo - - \ No newline at end of file diff --git a/web/public/favicon-stage.svg b/web/public/favicon-stage.svg deleted file mode 100644 index cb164b1..0000000 --- a/web/public/favicon-stage.svg +++ /dev/null @@ -1,12 +0,0 @@ - - KYCnot.me logo - - - \ No newline at end of file diff --git a/web/public/favicon.svg b/web/public/favicon.svg deleted file mode 100644 index 5972705..0000000 --- a/web/public/favicon.svg +++ /dev/null @@ -1,5 +0,0 @@ - - KYCnot.me logo - - \ No newline at end of file diff --git a/web/scripts/faker.ts b/web/scripts/faker.ts deleted file mode 100755 index 19803c0..0000000 --- a/web/scripts/faker.ts +++ /dev/null @@ -1,1333 +0,0 @@ -import crypto from 'crypto' - -import { faker } from '@faker-js/faker' -import { - AttributeCategory, - AttributeType, - CommentStatus, - Currency, - PrismaClient, - ServiceSuggestionStatus, - ServiceSuggestionType, - VerificationStatus, - type Prisma, - EventType, - type User, - ServiceUserRole, -} from '@prisma/client' -import { uniqBy } from 'lodash-es' -import { generateUsername } from 'unique-username-generator' - -import { kycLevels } from '../src/constants/kycLevels' -import { undefinedIfEmpty } from '../src/lib/arrays' -import { transformCase } from '../src/lib/strings' - -// Exit if not in development mode -if (process.env.NODE_ENV === 'production') { - console.error("This script can't run in production mode") - process.exit(1) -} - -/** Duplicate of parseIntWithFallback in src/lib/numbers.ts */ -function parseIntWithFallback(value: unknown, fallback: F = null as F) { - const parsed = Number(value) - if (!Number.isInteger(parsed)) return fallback - return parsed -} - -/** Duplicate of hashUserSecretToken in src/lib/userSecretToken.ts */ -function hashUserSecretToken(token: string): string { - return crypto.createHash('sha512').update(token).digest('hex') -} - -/** Duplicate of generateUserSecretToken in src/lib/userSecretToken.ts */ -export function generateUserSecretToken() { - const LOWERCASE_VOWEL_CHARACTERS = ['a', 'e', 'i', 'o', 'u'] as const - return [ - faker.helpers.arrayElement(LOWERCASE_VOWEL_CHARACTERS), - faker.string.alpha({ length: 1, casing: 'lower', exclude: LOWERCASE_VOWEL_CHARACTERS }), - faker.helpers.arrayElement(LOWERCASE_VOWEL_CHARACTERS), - faker.string.alpha({ length: 1, casing: 'lower', exclude: LOWERCASE_VOWEL_CHARACTERS }), - - faker.helpers.arrayElement(LOWERCASE_VOWEL_CHARACTERS), - faker.string.alpha({ length: 1, casing: 'lower', exclude: LOWERCASE_VOWEL_CHARACTERS }), - faker.helpers.arrayElement(LOWERCASE_VOWEL_CHARACTERS), - faker.string.alpha({ length: 1, casing: 'lower', exclude: LOWERCASE_VOWEL_CHARACTERS }), - - faker.helpers.arrayElement(LOWERCASE_VOWEL_CHARACTERS), - faker.string.alpha({ length: 1, casing: 'lower', exclude: LOWERCASE_VOWEL_CHARACTERS }), - faker.helpers.arrayElement(LOWERCASE_VOWEL_CHARACTERS), - faker.string.alpha({ length: 1, casing: 'lower', exclude: LOWERCASE_VOWEL_CHARACTERS }), - - faker.helpers.arrayElement(LOWERCASE_VOWEL_CHARACTERS), - faker.string.alpha({ length: 1, casing: 'lower', exclude: LOWERCASE_VOWEL_CHARACTERS }), - faker.helpers.arrayElement(LOWERCASE_VOWEL_CHARACTERS), - faker.string.alpha({ length: 1, casing: 'lower', exclude: LOWERCASE_VOWEL_CHARACTERS }), - - faker.string.numeric(1), - faker.string.numeric(1), - faker.string.numeric(1), - faker.string.numeric(1), - ].join('') -} - -/** Duplicate of createAccount in src/lib/accountCreate.ts */ -async function createAccount(preGeneratedToken?: string) { - const token = preGeneratedToken ?? generateUserSecretToken() - const verifiedLink = faker.helpers.maybe(() => faker.internet.url(), { probability: 0.5 }) - - const user = await prisma.user.create({ - data: { - name: `${generateUsername('_')}_${Math.floor(Math.random() * 10000).toString()}`, - secretTokenHash: hashUserSecretToken(token), - notificationPreferences: { create: {} }, - verifiedLink, - verified: !!verifiedLink, - admin: faker.datatype.boolean({ probability: 0.1 }), - verifier: faker.datatype.boolean({ probability: 0.1 }), - }, - include: { - serviceAffiliations: true, - }, - }) - - return { token, user } -} - -// Parse command line arguments -const args = process.argv.slice(2) -const shouldCleanup = args.includes('--cleanup') || args.includes('-c') -const onlyCleanup = args.includes('--only-cleanup') || args.includes('-oc') - -// Parse number of services from --services or -s flag -const servicesArg = args.find((arg) => arg.startsWith('--services=') || arg.startsWith('-s=')) -const numServices = parseIntWithFallback(servicesArg?.split('=')[1], 100) // Default to 100 if not specified - -if (isNaN(numServices) || numServices < 1) { - console.error('❌ Invalid number of services specified. Must be a positive number.') - process.exit(1) -} - -const prisma = new PrismaClient() - -const generateFakeAttribute = () => { - const title = transformCase(faker.lorem.words({ min: 1, max: 4 }), 'sentence') - const slug = `${faker.helpers.slugify(title).toLowerCase()}-${faker.string.numeric({ length: 2 })}` - const type = faker.helpers.arrayElement(Object.values(AttributeType)) - const category = faker.helpers.arrayElement(Object.values(AttributeCategory)) - const attributePointsByType = { - [AttributeType.GOOD]: { min: 0, max: 10 }, - [AttributeType.BAD]: { min: -10, max: 0 }, - [AttributeType.WARNING]: { min: -5, max: 0 }, - [AttributeType.INFO]: { min: 0, max: 0 }, - } as const satisfies Record[0]> - const attributePointsByTypeWrongCategory = { - [AttributeType.GOOD]: { min: 0, max: 1 }, - [AttributeType.BAD]: { min: -1, max: 0 }, - [AttributeType.WARNING]: { min: -1, max: 0 }, - [AttributeType.INFO]: { min: 0, max: 0 }, - } as const satisfies Record[0]> - - return { - title, - slug, - description: faker.lorem.sentences({ min: 1, max: 3 }), - privacyPoints: - category === 'PRIVACY' - ? faker.number.int(attributePointsByType[type]) - : faker.number.int(attributePointsByTypeWrongCategory[type]), - trustPoints: - category === 'TRUST' - ? faker.number.int(attributePointsByType[type]) - : faker.number.int(attributePointsByTypeWrongCategory[type]), - category, - type, - } as const satisfies Prisma.AttributeCreateInput -} - -const categoriesToCreate = [ - { - name: 'Exchange', - slug: 'exchange', - icon: 'ri:arrow-left-right-fill', - }, - { - name: 'VPN', - slug: 'vpn', - icon: 'ri:door-lock-fill', - }, - { - name: 'Email', - slug: 'email', - icon: 'ri:mail-fill', - }, - { - name: 'Hosting', - slug: 'hosting', - icon: 'ri:server-fill', - }, - { - name: 'VPS', - slug: 'vps', - icon: 'ri:function-add-fill', - }, - { - name: 'Gift Cards', - slug: 'gift-cards', - icon: 'ri:gift-line', - }, - { - name: 'Goods', - slug: 'goods', - icon: 'ri:shopping-basket-fill', - }, - { - name: 'Travel', - slug: 'travel', - icon: 'ri:plane-fill', - }, - { - name: 'SMS', - slug: 'sms', - icon: 'ri:message-2-fill', - }, - { - name: 'Store', - slug: 'store', - icon: 'ri:store-2-line', - }, - { - name: 'Tool', - slug: 'tool', - icon: 'ri:tools-fill', - }, - { - name: 'Market', - slug: 'market', - icon: 'ri:price-tag-3-line', - }, - { - name: 'Aggregator', - slug: 'aggregator', - icon: 'ri:list-ordered', - }, - { - name: 'AI', - slug: 'ai', - icon: 'ri:ai-generate-2', - }, - { - name: 'CEX', - slug: 'cex', - icon: 'ri:rotate-lock-fill', - }, - { - name: 'DEX', - slug: 'dex', - icon: 'ri:fediverse-line', - }, -] as const satisfies Prisma.CategoryCreateInput[] - -const serviceNames = [ - 'MajesticBank', - 'eXch', - 'Mullvad VPN', - 'iVPN', - 'Coinbase', - 'Binance', - 'Kraken', - 'Coinbase Pro', - 'Bitfinex', - 'KuCoin', - 'Bitstamp', - 'Gemini', - 'Bitpanda', - 'Bitpanda Pro', - 'MyNymBox', - 'ProtonVPN', - 'Proxystore', - 'WizardSwap', - 'OrangeFren', - 'Trocador', - 'Bisq', - 'Sms4Sats', - 'Vexl', - 'Haveno', - 'BasicSwap Beta', - 'TheLongServiceName Service', - 'TheVeryVeryVeryLongServiceName Service', - 'The Very Very Very Long Service Name Service', - 'The %4W3*ird _?sym[bol$] $#ervice', - 'The Service', - 'Random', - 'Anonymous', - 'Atomic Technologies', - 'France', - '8a9a j9a0', -] - -const serviceDescriptions = [ - "Buy and sell bitcoin for fiat (or other cryptocurrencies) privately and securely using Bisq's peer-to-peer network and open-source desktop software. No registration required.", - 'Bitcoin -> Monero atomic swaps, securely and in a decentralized manner using a state-of-the-art cryptographic protocol and open-source desktop software.', - 'P2P exchange bitcoin for national currencies. Robosats simplifies the peer-to-peer user experience.', - 'Anonymous exchange: Exchange Bitcoin to Monero and vice versa.', - 'Private web Hosting, KVM VPS, Dedicated Servers, Domain Names and VPN.', - 'SMS verification numbers online, pay using the Lightning Network. Cheap, easy, fast and anonymous.', - 'Hosting solutions, servers, domain registrations and dns parking. We do not require any personal information. Pay with Bitcoin and Monero.', - 'Send and receive sms messages via an XMPP client. You can also make and receive phone calls.', - 'VPN with unlimited bandwidth, dedicated servers without hard drives, no logging VPN service that accepts Monero.', - 'Privacy-first automated crytpocurrency swaps without registration.', - 'High-speed VPN available with multiple protocols, with strict no-logs policy and based in Switzerland.', - 'No logs, fully anonymous VPN. Resist Online Surveillance.', - 'Boltz is a non-custodial Bitcoin bridge built to swap between different Bitcoin layers like the Liquid and Lightning Network. Boltz Swaps are non-custodial, which means users can always rest assured to be in full control of their bitcoin throughout the entire flow of a swap.', - 'Iceland-based freedom of speech web hosting provider offering high-quality and secure web hosting solutions to its customers worldwide, with an award-winning customer support team.', - 'Privacy-friendly VPN with strong cryptography, no logs, anonymous payment methods, and Tor and I2P access. They support OpenVPN and WireGuard.', - 'Peach is a mobile application that connects Bitcoin Buyers & Sellers together. Buy or sell bitcoin peer-to-peer, anywhere, at anytime, with the payment method of your choice.', - 'Use GPT4 (and more) without accounts, subscriptions or credit cards. The interface runs on a pay-per-query model via Lightning.', - 'Xchange.me offers a cryptocurrency exchange service that allows you to exchange cryptocurrency through a fast automated process. No registration process or lengthy verification is needed.', - 'Exchange more than 1200+ coins on all available networks, quickly and easily.', - 'Swap between coins with fast and easy user experience, no sign-up required.', - 'Instant swap service, with no mandatory account registration. Fixed and floating rates.', - 'P2P marketplace that accepts Monero. It is similar to MoneroMarket and Facebook Marketplace. Messenger for buyer/seller is included with PGP encryption.', -] - -const tosReviewExamples: PrismaJson.TosReview[] = [ - { - kycLevel: 1, - summary: '**Non-KYC exchange** with strong privacy features, but registered in Belize.', - complexity: 'medium', - contentHash: faker.string.uuid(), - highlights: [ - { - title: 'No KYC Required', - content: 'No KYC or Source of Funds verification required for transactions.', - rating: 'positive', - }, - { - title: 'Privacy Protection', - content: 'No metadata collection (IP addresses, browser information, etc.).', - rating: 'positive', - }, - { - title: 'Tor Support', - content: 'Offers .onion address for enhanced privacy through Tor network.', - rating: 'positive', - }, - { - title: 'Transparency', - content: 'Provides proof of reserves on request, enhancing trust.', - rating: 'positive', - }, - { - title: 'Privacy Coins', - content: 'Supports privacy-focused cryptocurrencies like Monero.', - rating: 'positive', - }, - { - title: 'Jurisdiction Risk', - content: 'Registered in Belize which may have lax regulatory oversight.', - rating: 'negative', - }, - { - title: 'Transaction Risk', - content: 'Mixed pool transactions may lead to frozen funds on major exchanges.', - rating: 'negative', - }, - { - title: 'Privacy Trade-off', - content: 'Aggregated pool reduces risk of frozen funds but compromises privacy.', - rating: 'neutral', - }, - { - title: 'Mobile Security', - content: 'Mobile wallets recommended only if available on F-Droid (reproducible builds).', - rating: 'neutral', - }, - { - title: 'Messaging Security', - content: 'Avoid Telegram bots for exchanges due to lack of end-to-end encryption.', - rating: 'negative', - }, - ], - }, - { - kycLevel: 2, - summary: - 'MajesticBank offers privacy-conscious crypto exchange services, with no mandatory registration, no logging, encryption, and optional JavaScript usage. Ensures anonymity and sovereignty through privacy-oriented features like Tor access and log-free practices.', - complexity: 'low', - contentHash: faker.string.uuid(), - highlights: [ - { - title: 'Anonymous Exchange', - content: 'Registration is not required, supporting anonymous exchanges.', - rating: 'positive', - }, - { - title: 'Limited Data Retention', - content: 'No logs are kept, and exchange data is deleted upon request or after two weeks.', - rating: 'positive', - }, - { - title: 'Strong Encryption', - content: 'Military-grade encryption ensures user data security.', - rating: 'positive', - }, - { - title: 'Optional JavaScript', - content: 'Optional JavaScript enhances security for privacy-conscious users.', - rating: 'positive', - }, - { - title: 'Hidden Transactions', - content: 'Default hidden transaction ID prioritizes user privacy.', - rating: 'positive', - }, - { - title: 'Clean Coin History', - content: 'Clean coin history ensures safe usability of exchanged cryptocurrencies.', - rating: 'positive', - }, - { - title: 'Tor Support', - content: 'Recommended Tor v3 hidden service for secure access supports self-sovereignty.', - rating: 'positive', - }, - ], - }, - { - kycLevel: 3, - summary: - '**SideShift.ai blocks users from certain countries** including the US, North Korea, and others. Restrictions on SideShift Token (XAI) apply particularly for US residents, limiting functionality and access.', - complexity: 'low', - contentHash: faker.string.uuid(), - highlights: [ - { - title: 'No KYC Mentioned', - content: - 'SideShift.ai excludes KYC requirements in the text—potential benefit for anonymity in non-blocked jurisdictions.', - rating: 'positive', - }, - { - title: 'Privacy-First Design', - content: - 'Its absence of direct data collection mentions could imply privacy-first design for eligible users.', - rating: 'positive', - }, - ], - }, - { - kycLevel: 4, - summary: - '**SideShift.ai blocks users from certain countries** including the US, North Korea, and others. Restrictions on SideShift Token (XAI) apply particularly for US residents, limiting functionality and access.', - complexity: 'low', - contentHash: faker.string.uuid(), - highlights: [ - { - title: 'No KYC Mentioned', - content: - 'SideShift.ai excludes KYC requirements in the text—potential benefit for anonymity in non-blocked jurisdictions.', - rating: 'positive', - }, - { - title: 'Privacy-First Design', - content: - 'Its absence of direct data collection mentions could imply privacy-first design for eligible users.', - rating: 'positive', - }, - ], - }, - { - kycLevel: 0, - summary: - '**Kyun! Terms of Service** emphasize data collection with potential privacy risks. Key clauses suggest user tracking, require KYC for services, and describe limited protections for anonymity.', - complexity: 'medium', - contentHash: faker.string.uuid(), - highlights: [ - { - title: 'Tor Integration', - content: 'Integration with Tor for enhanced anonymity.', - rating: 'positive', - }, - { - title: 'Transparency Measures', - content: 'A published canary file and PGP keys provide additional transparency.', - rating: 'positive', - }, - { - title: 'Data Control', - content: 'Privacy Policy indicates a degree of user control over personal data requests.', - rating: 'neutral', - }, - ], - }, -] - -// User sentiment examples for AI-generated summaries -const generateFakeUserSentiment = () => { - const sentiments = ['positive', 'neutral', 'negative'] as const - const sentiment = faker.helpers.arrayElement(sentiments) - - // Generate what users like based on sentiment - const likeCount = - sentiment === 'positive' - ? faker.number.int({ min: 3, max: 6 }) - : sentiment === 'neutral' - ? faker.number.int({ min: 1, max: 4 }) - : faker.number.int({ min: 0, max: 2 }) - - // Generate what users dislike based on sentiment - const dislikeCount = - sentiment === 'negative' - ? faker.number.int({ min: 3, max: 6 }) - : sentiment === 'neutral' - ? faker.number.int({ min: 1, max: 4 }) - : faker.number.int({ min: 0, max: 2 }) - - const whatUsersLike = Array.from({ length: likeCount }, () => - faker.helpers.arrayElement([ - 'Fast transaction times', - 'No KYC required', - 'Excellent support team', - 'Low fees', - 'Multiple currency options', - 'Easy to use interface', - 'Clear documentation', - 'Tor support', - 'Strong privacy policies', - 'No IP logging', - 'Quick verification process', - 'Responsive website', - 'Mobile-friendly design', - 'Reliable uptime', - 'Transparent fee structure', - ]) - ) - - const whatUsersDislike = Array.from({ length: dislikeCount }, () => - faker.helpers.arrayElement([ - 'Slow transaction times', - 'High fees', - 'Poor customer support', - 'Confusing interface', - 'Limited currency options', - 'Website downtime', - 'Hidden fees', - 'No mobile support', - 'Lack of transparency', - 'Limited payment methods', - 'Bugs in the platform', - 'Restrictive limits', - 'Delayed withdrawals', - 'Verification issues', - 'Complicated signup process', - ]) - ) - - // Create summary based on sentiment - let summary = '' - if (sentiment === 'positive') { - summary = faker.helpers.arrayElement([ - `Users overwhelmingly praise this service for its ${faker.helpers.arrayElements(whatUsersLike, 2).join(' and ')}. Many highlight the ${faker.helpers.arrayElement(whatUsersLike)} as a standout feature.`, - `Based on multiple user reviews, this service receives high marks for ${faker.helpers.arrayElements(whatUsersLike, 2).join(' and ')}. Most users report positive experiences with minimal issues.`, - `Community feedback indicates strong satisfaction with this service, particularly regarding ${faker.helpers.arrayElements(whatUsersLike, 2).join(' and ')}.`, - ]) - } else if (sentiment === 'neutral') { - summary = faker.helpers.arrayElement([ - `User sentiment is mixed. While many appreciate the ${faker.helpers.arrayElement(whatUsersLike)}, common complaints include ${faker.helpers.arrayElement(whatUsersDislike)}.`, - `Community feedback shows balanced opinions. Users like the ${faker.helpers.arrayElement(whatUsersLike)} but have concerns about ${faker.helpers.arrayElement(whatUsersDislike)}.`, - `Analysis of reviews indicates neither overwhelmingly positive nor negative sentiment. Users value ${faker.helpers.arrayElement(whatUsersLike)} but criticize ${faker.helpers.arrayElement(whatUsersDislike)}.`, - ]) - } else { - summary = faker.helpers.arrayElement([ - `User reviews highlight significant concerns with this service, primarily regarding ${faker.helpers.arrayElements(whatUsersDislike, 2).join(' and ')}. Few users mention positive aspects.`, - `Community feedback is predominantly negative, with recurring complaints about ${faker.helpers.arrayElements(whatUsersDislike, 2).join(' and ')}.`, - `Analysis of user comments reveals widespread dissatisfaction, especially concerning ${faker.helpers.arrayElements(whatUsersDislike, 2).join(' and ')}.`, - ]) - } - - return { - summary, - sentiment, - whatUsersLike: [...new Set(whatUsersLike)], - whatUsersDislike: [...new Set(whatUsersDislike)], - } -} - -const eventTitles = [ - 'Service maintenance scheduled', - 'Server outage reported', - 'New feature launched', - 'Security update released', - 'Price changes announced', - 'Service temporarily unavailable', - 'Verification process changed', - 'High traffic warning', - 'API changes coming soon', - 'Database maintenance', - 'KYC policy updated', - 'Privacy policy update', - 'New cryptocurrencies added', - 'Lower fees promotion', - 'Important security notification', - 'Partial service disruption', - 'Full service restored', - 'Address format changed', - 'Exchange rate issues fixed', - 'Holiday operating hours', -] - -const generateFakeEvent = (serviceId: number) => { - const type = faker.helpers.arrayElement(Object.values(EventType)) - const visible = faker.datatype.boolean(0.9) // 90% chance of being visible - const startedAt = faker.date.between({ - from: new Date(Date.now() - 90 * 24 * 60 * 60 * 1000), // 90 days ago - to: new Date(Date.now() + 30 * 24 * 60 * 60 * 1000), // 30 days in future - }) - const endedAt = faker.helpers.arrayElement([ - // Option 1: Future date (1-14 days after start) - faker.date.between({ - from: startedAt, - to: new Date(startedAt.getTime() + faker.number.int({ min: 1, max: 14 }) * 24 * 60 * 60 * 1000), - }), - // Option 2: null (ongoing event) - null, - // Option 3: Same date as startedAt (one-time event) - new Date(startedAt), - ]) - - const title = faker.helpers.arrayElement(eventTitles) - - return { - title, - content: faker.lorem.sentence({ min: 1, max: 10 }), - source: faker.helpers.maybe(() => faker.internet.url(), { probability: 0.7 }), - type, - visible, - startedAt, - endedAt, - service: { connect: { id: serviceId } }, - } as const satisfies Prisma.EventCreateInput -} - -const generateFakeService = (users: User[]) => { - const status = faker.helpers.arrayElement(Object.values(VerificationStatus)) - const name = faker.helpers.arrayElement(serviceNames) - const slug = `${faker.helpers.slugify(name).toLowerCase()}-${faker.string.alphanumeric({ length: 6, casing: 'lower' })}` - - return { - name, - slug, - description: faker.helpers.arrayElement(serviceDescriptions), - kycLevel: faker.helpers.arrayElement(kycLevels.map((level) => level.value)), - overallScore: 0, - privacyScore: 0, - trustScore: 0, - verificationStatus: status, - verificationSummary: - status === 'VERIFICATION_SUCCESS' || status === 'VERIFICATION_FAILED' ? faker.lorem.paragraph() : null, - verificationRequests: { - create: uniqBy( - Array.from({ length: faker.number.int({ min: 0, max: 10 }) }, () => ({ - userId: faker.helpers.arrayElement(users).id, - })), - 'userId' - ), - }, - verificationProofMd: - status === 'VERIFICATION_SUCCESS' || status === 'VERIFICATION_FAILED' ? faker.lorem.paragraphs() : null, - referral: `?ref=${faker.string.alphanumeric(6)}`, - acceptedCurrencies: faker.helpers.arrayElements(Object.values(Currency), { min: 1, max: 5 }), - serviceUrls: Array.from({ length: faker.number.int({ min: 1, max: 3 }) }, () => faker.internet.url()), - tosUrls: Array.from({ length: faker.number.int({ min: 0, max: 2 }) }, () => faker.internet.url()), - onionUrls: Array.from( - { length: faker.number.int({ min: 0, max: 2 }) }, - () => `http://${faker.string.alphanumeric({ length: 56, casing: 'lower' })}.onion` - ), - i2pUrls: Array.from( - { length: faker.number.int({ min: 0, max: 2 }) }, - () => `http://${faker.string.alphanumeric({ length: 52, casing: 'lower' })}.b32.i2p` - ), - imageUrl: `https://ui-avatars.com/api/?name=${encodeURIComponent(name)}&background=random&format=svg`, - listedAt: faker.date.past(), - verifiedAt: status === VerificationStatus.VERIFICATION_SUCCESS ? faker.date.past() : null, - tosReview: faker.helpers.arrayElement(tosReviewExamples), - tosReviewAt: faker.date.past(), - userSentiment: Math.random() > 0.2 ? generateFakeUserSentiment() : undefined, - userSentimentAt: faker.date.recent(), - } as const satisfies Prisma.ServiceCreateInput -} - -const commentList = [ - 'This service is amazing!', - "I've had a great experience with this service.", - 'Would recommend to everyone.', - 'Not the best service, but it works.', - "I've had some issues with this service.", - 'Avoid this service at all costs.', - "It's been over 12 hours. Page just says 'Something went wrong. Try to generate new circuit or get back to homepage' entering exchange ID in track says it cannot be found. out $500", - 'Wow man so slow exchange im starting to think i just got scammed', - "takes very long to swap. Waiting for almost 2h using 'Priority' transaction but still waiting. Reasonable service but very slow. Thank you", - 'If you are in a hurry, i advise against using this site. It took 2h to process...', - 'I had to wait 2 hours for my transaction to be processed. I was very disappointed.', - 'Good service, low fees, would use again.', - 'exchange on majesticbank takes 30 minutes after confirmations and slower compared to other eXchange services but trusted too.', - 'scam', - 'test', - 'good morning everyone', - 'shitty service, bad support team, avoid', - 'hey admin, please could you check the service URLs? they seem to have changed', - 'they are now accepting lightning payments, which is great!', - 'I have been using this service for a while now and I must say that it is one of the best I have used. The customer support is excellent and the service is very reliable. I would highly recommend this service to anyone looking for a reliable and trustworthy service.', - 'last time i used this was a long ago, but they were good', - - // Positive, high-quality reviews - 'This service is amazing! The transaction was smooth and support team was very helpful throughout.', - "I've had a great experience with this service. Fast processing times and reasonable fees.", - 'Would definitely recommend to everyone - saved me a lot in fees compared to competitors.', - 'Their new Lightning Network integration is fantastic. Makes transactions so much faster.', - "One of the most reliable services I've used in 5+ years of crypto trading.", - - // Balanced/Mixed reviews - 'Not the best service, but it works well enough for basic transactions.', - "I've had some issues but support helped resolve them quickly.", - 'Exchange rates could be better but service is reliable.', - 'A bit slow sometimes but very secure and trustworthy.', - 'Interface needs work but core functionality is solid.', - - // Negative but legitimate reviews - 'Avoid this service if you need fast transactions. Too slow.', - 'Support took 3 days to respond to my ticket. Not acceptable.', - 'Fees are higher than advertised. Be careful.', - 'Site was down for maintenance during peak hours.', - 'Mobile experience is terrible, desktop only works properly.', - - // Spam/Low quality - 'scam scam scam!!!11', - 'WORST SERVICE EVER!!!!!', - 'test test', - 'first', - 'nice', - 'good', - 'hi admin', - 'check dm', - 'lol', - '+1', - - // Potential scam/fraud - 'DOUBLE YOUR BITCOIN - Send 0.1 BTC to address xyz123...', - 'FREE CRYPTO GIVEAWAY at totally-legit-site.com', - 'DM me for special rates', - 'WhatsApp +123456789 for instant exchange', - 'Guaranteed 100% returns daily!!!', - - // Time-wasting/Trolling - 'Does this work with Dogecoin? Asking for my cat.', - 'Instructions unclear, bought a lambo instead', - 'When moon? When lambo?', - 'This is the way', - 'HODL!!!', - - // Long rambling reviews - "I have been using this service for approximately 2.4 years and I must say that while initially I was skeptical due to the interface design choices particularly the color scheme which reminds me of my grandmother's curtains from the 1970s but that's besides the point because ultimately what matters is functionality and in that regard I can definitively state that based on my extensive experience with various competing services including but not limited to...", - - // Technical issues/bugs - "It's been over 12 hours. Page just says 'Something went wrong. Try to generate new circuit or get back to homepage' entering exchange ID in track says it cannot be found. out $500", - 'Error 404 on confirmation page', - 'API keeps timing out', - 'Cloudflare is blocking access', - 'KYC verification stuck at 99%', - - // Legitimate but poorly written - 'gud service fast n cheap', - 'works ok i guess', - 'better then others maybe', - 'ya its fine whatever', - 'does job', - - // Support questions/issues - 'hey admin, please check support ticket #12345', - 'when will site maintenance end???', - 'need help with transaction', - 'support not responding!!!', - 'how to cancel order??', - - // Requires admin attention - 'The correct name of this service is "MoneroSMS", not "monero sms" (no space)', - 'Since they recommend using a swap service. I don\'t think it can be labled as "support monero".', - 'new tor address is \nhttp://4kanxsg3sbveimuoqgxhaj3clrj2aw7swow5fpc6odqmtclww3ukcqqd.onion/', - - // Feature requests/suggestions - 'Please add support for Monero', - 'Dark mode would be nice', - 'Mobile app when?', - 'Can we get lower fees for high volume?', - 'Add more payment methods please', - - // Time-related complaints - 'Wow man so slow exchange im starting to think i just got scammed', - 'takes very long to swap. Waiting for almost 2h using Priority transaction', - 'If you are in a hurry, avoid - took 2h to process...', - '30+ minutes after confirmation still waiting', - 'Stuck pending for 3 hours now', - - // Competitor mentions/comparisons - 'Much slower than competitor X', - 'Fees higher than service Y', - 'Other exchanges are faster', - 'Better rates on Z exchange', - 'Moving to competitor service', - "To activate your account, you can either deposit $15 to your balance or enter your referral code if you have one. \n(If you'd like to pay in a cryptocurrency other than Bitcoin, currently we recommend using a service like simpleswap.io, morphtoken.com, changenow.io, or godex.io. Manual payment via Bitcoin Cash is also available if you contact support.)", - - // Random/nonsensical - 'potato', - 'asdfghjkl', - 'testing testing 123', - '........................', - '🚀🚀🚀🚀🚀', - - // Old reviews - 'Used this back in 2019, was good then', - 'Last time I checked was months ago', - 'Things have changed since I last used it', - 'Service quality has declined since early days', - 'Not as good as it used to be', -] - -const commentReplyList = [ - // Replies to comments - 'yup', - 'noope', - 'yeah', - 'yes', - 'maybe', - 'thanks', - 'thank you', - 'thx', - 'thx for the help', - 'right', - 'same here', - 'same issue man', - 'same', - 'same problem', - 'same problem here', - 'same problem man', - 'same problem here man', - 'same experience', - 'same experience here', - 'same experience here man', - 'same experience man', - 'same experience here man', -] - -const generateFakeComment = (userId: number, serviceId: number, parentId?: number) => - ({ - upvotes: faker.number.int({ min: 0, max: 100 }), - status: - Math.random() > 0.1 - ? faker.helpers.arrayElement([CommentStatus.APPROVED, CommentStatus.REJECTED, CommentStatus.VERIFIED]) - : CommentStatus.PENDING, - suspicious: Math.random() > 0.2 ? false : faker.datatype.boolean(), - communityNote: Math.random() > 0.2 ? '' : faker.lorem.paragraph(), - internalNote: Math.random() > 0.2 ? '' : faker.lorem.paragraph(), - privateContext: Math.random() > 0.2 ? '' : faker.lorem.paragraph(), - content: - parentId && Math.random() > 0.3 - ? faker.helpers.arrayElement(commentReplyList) - : faker.helpers.arrayElement(commentList), - rating: parentId ? null : Math.random() < 0.33 ? faker.number.int({ min: 1, max: 5 }) : null, - ratingActive: false as boolean, - authorId: userId, - serviceId, - parentId, - }) satisfies Prisma.CommentCreateManyInput - -const generateFakeServiceContactMethod = (serviceId: number) => { - const types = [ - { - label: 'Email', - value: `mailto:${faker.internet.email()}`, - iconId: 'ri:mail-line', - info: faker.lorem.sentence(), - }, - { - label: 'Phone', - value: `tel:${faker.phone.number({ style: 'international' })}`, - iconId: 'ri:phone-line', - info: faker.lorem.sentence(), - }, - { - label: 'WhatsApp', - value: `https://wa.me/${faker.phone.number({ style: 'international' })}`, - iconId: 'ri:whatsapp-line', - info: faker.lorem.sentence(), - }, - { - label: 'Telegram', - value: `https://t.me/${faker.internet.username()}`, - iconId: 'ri:telegram-line', - info: faker.lorem.sentence(), - }, - { - label: 'Website', - value: faker.internet.url(), - iconId: 'ri:global-line', - info: faker.lorem.sentence(), - }, - { - label: 'LinkedIn', - value: `https://www.linkedin.com/company/${faker.helpers.slugify(faker.company.name())}`, - iconId: 'ri:linkedin-box-line', - info: faker.lorem.sentence(), - }, - ] as const satisfies Partial[] - - return { - services: { connect: { id: serviceId } }, - ...faker.helpers.arrayElement(types), - } as const satisfies Prisma.ServiceContactMethodCreateInput -} - -const specialUsersData = { - admin: { - name: 'admin_dev', - envToken: 'DEV_ADMIN_USER_SECRET_TOKEN', - defaultToken: 'admin', - admin: true, - verifier: true, - verified: true, - verifiedLink: 'https://kycnot.me', - totalKarma: 1001, - link: 'https://kycnot.me', - picture: 'https://comments.kycnot.me/api/users/549f290e-0542-4c18-b437-5b64b35758f0/avatar?size=L', - }, - verifier: { - name: 'verifier_dev', - envToken: 'DEV_VERIFIER_USER_SECRET_TOKEN', - defaultToken: 'verifier', - admin: false, - verifier: true, - verified: true, - verifiedLink: 'https://kycnot.me', - totalKarma: 1001, - link: 'https://kycnot.me', - picture: 'https://comments.kycnot.me/api/users/549f290e-0542-4c18-b437-5b64b35758f0/avatar?size=L', - }, - verified: { - name: 'verified_dev', - envToken: 'DEV_VERIFIED_USER_SECRET_TOKEN', - defaultToken: 'verified', - admin: false, - verifier: false, - verified: true, - verifiedLink: 'https://kycnot.me', - totalKarma: 1001, - }, - normal: { - name: 'normal_dev', - envToken: 'DEV_NORMAL_USER_SECRET_TOKEN', - defaultToken: 'normal', - admin: false, - verifier: false, - verified: false, - }, - spam: { - name: 'spam_dev', - envToken: 'DEV_SPAM_USER_SECRET_TOKEN', - defaultToken: 'spam', - admin: false, - verifier: false, - verified: false, - totalKarma: -100, - spammer: true, - }, -} as const satisfies Record< - string, - Omit & { - envToken: string - defaultToken: string - } -> - -const generateFakeServiceSuggestionMessage = (suggestionId: number, userIds: number[]) => - ({ - content: faker.lorem.paragraph(), - user: { connect: { id: faker.helpers.arrayElement(userIds) } }, - suggestion: { connect: { id: suggestionId } }, - }) satisfies Prisma.ServiceSuggestionMessageCreateInput - -const generateFakeServiceSuggestion = ({ - type, - status = ServiceSuggestionStatus.PENDING, - userId, - serviceId, -}: { - type: ServiceSuggestionType - status?: ServiceSuggestionStatus - userId: number - serviceId: number -}) => - ({ - type, - status, - notes: faker.lorem.paragraph(), - user: { connect: { id: userId } }, - service: { connect: { id: serviceId } }, - }) satisfies Prisma.ServiceSuggestionCreateInput - -const generateFakeInternalNote = (userId: number, addedByUserId?: number) => - ({ - content: faker.lorem.paragraph(), - user: { connect: { id: userId } }, - addedByUser: addedByUserId ? { connect: { id: addedByUserId } } : undefined, - }) satisfies Prisma.InternalUserNoteCreateInput - -async function runFaker() { - await prisma.$transaction( - async (tx) => { - // ---- Clean up existing data if requested ---- - if (shouldCleanup || onlyCleanup) { - console.info('🧹 Cleaning up existing data...') - - try { - await tx.commentVote.deleteMany() - await tx.karmaTransaction.deleteMany() - await tx.comment.deleteMany() - await tx.serviceAttribute.deleteMany() - await tx.serviceContactMethod.deleteMany() - await tx.event.deleteMany() - await tx.verificationStep.deleteMany() - await tx.serviceSuggestionMessage.deleteMany() - await tx.serviceSuggestion.deleteMany() - await tx.serviceVerificationRequest.deleteMany() - await tx.service.deleteMany() - await tx.attribute.deleteMany() - await tx.category.deleteMany() - await tx.internalUserNote.deleteMany() - await tx.user.deleteMany() - console.info('✅ Existing data cleaned up') - } catch (error) { - console.error('❌ Error cleaning up data:', error) - throw error - } - if (onlyCleanup) return - } - - // ---- Get or create categories ---- - const categories = await Promise.all( - categoriesToCreate.map(async (cat) => { - const existing = await tx.category.findUnique({ - where: { name: cat.name }, - }) - if (existing) return existing - - return await tx.category.create({ - data: cat, - }) - }) - ) - - // ---- Create users ---- - const specialUsersUntyped = Object.fromEntries( - await Promise.all( - Object.entries(specialUsersData).map(async ([key, userData]) => { - const secretToken = process.env[userData.envToken] ?? userData.defaultToken - const secretTokenHash = hashUserSecretToken(secretToken) - - const { envToken, defaultToken, ...userCreateData } = userData - const user = await tx.user.create({ - data: { - notificationPreferences: { create: {} }, - ...userCreateData, - secretTokenHash, - }, - }) - - console.info(`✅ Created ${user.name} with secret token "${secretToken}"`) - - return [key, user] as const - }) - ) - ) - - const specialUsers = specialUsersUntyped as { - [K in keyof typeof specialUsersData]: (typeof specialUsersUntyped)[K] - } - - let users = await Promise.all( - Array.from({ length: 10 }, async () => { - const { user } = await createAccount() - return user - }) - ) - - // ---- Create attributes ---- - const attributes = await Promise.all( - Array.from({ length: 16 }, async () => { - return await tx.attribute.create({ - data: generateFakeAttribute(), - }) - }) - ) - - // ---- Create services ---- - const services = await Promise.all( - Array.from({ length: numServices }, async () => { - const serviceData = generateFakeService(users) - const randomCategories = faker.helpers.arrayElements(categories, { min: 1, max: 3 }) - - const service = await tx.service.create({ - data: { - ...serviceData, - categories: { - connect: randomCategories.map((cat) => ({ id: cat.id })), - }, - }, - }) - - // Create contact methods for each service - await Promise.all( - Array.from({ length: faker.number.int({ min: 1, max: 3 }) }, () => - tx.serviceContactMethod.create({ - data: generateFakeServiceContactMethod(service.id), - }) - ) - ) - - // Link random attributes to the service - await Promise.all( - faker.helpers.arrayElements(attributes, { min: 2, max: 5 }).map((attr) => - tx.serviceAttribute.create({ - data: { - serviceId: service.id, - attributeId: attr.id, - }, - }) - ) - ) - - // Create events for the service - await Promise.all( - Array.from({ length: faker.number.int({ min: 0, max: 5 }) }, () => - tx.event.create({ - data: generateFakeEvent(service.id), - }) - ) - ) - - return service - }) - ) - - // ---- Create service user affiliations for the service ---- - await Promise.all( - users - .filter((user) => user.verified) - .map(async (user) => { - const servicesToAddAffiliations = uniqBy( - faker.helpers.arrayElements(services, { - min: 1, - max: 3, - }), - 'id' - ) - - return tx.user.update({ - where: { id: user.id }, - data: { - serviceAffiliations: { - createMany: { - data: servicesToAddAffiliations.map((service) => ({ - role: faker.helpers.arrayElement(Object.values(ServiceUserRole)), - serviceId: service.id, - })), - }, - }, - }, - }) - }) - ) - - users = await tx.user.findMany({ - include: { - serviceAffiliations: true, - }, - }) - - // ---- Create comments and replies ---- - await Promise.all( - services.map(async (service) => { - // Create parent comments - const commentCount = faker.number.int({ min: 1, max: 10 }) - const commentData = Array.from({ length: commentCount }, () => - generateFakeComment(faker.helpers.arrayElement(users).id, service.id) - ) - const indexesToUpdate = users.map((user) => { - return commentData.findIndex((comment) => comment.authorId === user.id && comment.rating !== null) - }) - commentData.forEach((comment, index) => { - if (indexesToUpdate.includes(index)) comment.ratingActive = true - }) - - await tx.comment.createMany({ - data: commentData, - }) - - const comments = await tx.comment.findMany({ - where: { - serviceId: service.id, - parentId: null, - }, - orderBy: { - createdAt: 'desc', - }, - take: commentCount, - }) - - const affiliatedUsers = undefinedIfEmpty( - users.filter((user) => - user.serviceAffiliations.some((affiliation) => affiliation.serviceId === service.id) - ) - ) - - // Create replies to comments - await Promise.all( - comments.map(async (comment) => { - const replyCount = faker.number.int({ min: 0, max: 3 }) - return Promise.all( - Array.from({ length: replyCount }, () => { - const user = faker.helpers.arrayElement( - faker.helpers.maybe(() => affiliatedUsers, { probability: 0.3 }) ?? users - ) - - return tx.comment.create({ - data: generateFakeComment(user.id, service.id, comment.id), - }) - }) - ) - }) - ) - }) - ) - - // ---- Create service suggestions for normal_dev user ---- - // First create 3 CREATE_SERVICE suggestions with their services - for (let i = 0; i < 3; i++) { - const serviceData = generateFakeService(users) - const randomCategories = faker.helpers.arrayElements(categories, { min: 1, max: 3 }) - - const service = await tx.service.create({ - data: { - ...serviceData, - verificationStatus: VerificationStatus.COMMUNITY_CONTRIBUTED, - categories: { - connect: randomCategories.map((cat) => ({ id: cat.id })), - }, - }, - }) - - const serviceSuggestion = await tx.serviceSuggestion.create({ - data: generateFakeServiceSuggestion({ - type: ServiceSuggestionType.CREATE_SERVICE, - userId: specialUsers.normal.id, - serviceId: service.id, - }), - }) - - // Create some messages for each suggestion - await Promise.all( - Array.from({ length: faker.number.int({ min: 1, max: 3 }) }, () => - tx.serviceSuggestionMessage.create({ - data: generateFakeServiceSuggestionMessage(serviceSuggestion.id, [ - specialUsers.normal.id, - specialUsers.admin.id, - ]), - }) - ) - ) - } - - // Then create 5 EDIT_SERVICE suggestions - await Promise.all( - services.slice(0, 5).map(async (service) => { - const status = faker.helpers.arrayElement(Object.values(ServiceSuggestionStatus)) - const suggestion = await tx.serviceSuggestion.create({ - data: generateFakeServiceSuggestion({ - type: ServiceSuggestionType.EDIT_SERVICE, - status, - userId: specialUsers.normal.id, - serviceId: service.id, - }), - }) - - // Create some messages for each suggestion - await Promise.all( - Array.from({ length: faker.number.int({ min: 0, max: 3 }) }, () => - tx.serviceSuggestionMessage.create({ - data: generateFakeServiceSuggestionMessage(suggestion.id, [ - specialUsers.normal.id, - specialUsers.admin.id, - ]), - }) - ) - ) - }) - ) - - // ---- Create internal notes for users ---- - await Promise.all( - users.map(async (user) => { - // Create 1-3 notes for each user - const numNotes = faker.number.int({ min: 1, max: 3 }) - return Promise.all( - Array.from({ length: numNotes }, () => - tx.internalUserNote.create({ - data: generateFakeInternalNote( - user.id, - faker.helpers.arrayElement([specialUsers.admin.id, specialUsers.verifier.id]) - ), - }) - ) - ) - }) - ) - - // Add some notes to special users as well - await Promise.all( - Object.values(specialUsers).map(async (user) => { - const numNotes = faker.number.int({ min: 1, max: 3 }) - return Promise.all( - Array.from({ length: numNotes }, () => - tx.internalUserNote.create({ - data: generateFakeInternalNote( - user.id, - faker.helpers.arrayElement([specialUsers.admin.id, specialUsers.verifier.id]) - ), - }) - ) - ) - }) - ) - }, - { - timeout: 1000 * 60 * 10, // 10 minutes - } - ) -} - -async function main() { - try { - await runFaker() - - console.info('✅ Fake data generated successfully') - } catch (error) { - console.error('❌ Error generating fake data:', error) - process.exit(1) - } finally { - await prisma.$disconnect() - } -} - -main().catch((error: unknown) => { - console.error('❌ Fatal error:', error) - process.exit(1) -}) diff --git a/web/src/actions/account.ts b/web/src/actions/account.ts deleted file mode 100644 index 38d3ae8..0000000 --- a/web/src/actions/account.ts +++ /dev/null @@ -1,221 +0,0 @@ -import { ActionError } from 'astro:actions' -import { z } from 'astro:content' - -import { karmaUnlocksById } from '../constants/karmaUnlocks' -import { createAccount } from '../lib/accountCreate' -import { captchaFormSchemaProperties, captchaFormSchemaSuperRefine } from '../lib/captchaValidation' -import { defineProtectedAction } from '../lib/defineProtectedAction' -import { saveFileLocally } from '../lib/fileStorage' -import { handleHoneypotTrap } from '../lib/honeypot' -import { startImpersonating } from '../lib/impersonation' -import { makeKarmaUnlockMessage, makeUserWithKarmaUnlocks } from '../lib/karmaUnlocks' -import { prisma } from '../lib/prisma' -import { redisPreGeneratedSecretTokens } from '../lib/redis/redisPreGeneratedSecretTokens' -import { login, logout, setUserSessionIdCookie } from '../lib/userCookies' -import { - generateUserSecretToken, - hashUserSecretToken, - parseUserSecretToken, - USER_SECRET_TOKEN_REGEX, -} from '../lib/userSecretToken' -import { imageFileSchema } from '../lib/zodUtils' - -export const accountActions = { - login: defineProtectedAction({ - accept: 'form', - permissions: 'guest', - input: z.object({ - token: z.string().regex(USER_SECRET_TOKEN_REGEX).transform(parseUserSecretToken), - redirect: z.string().optional(), - }), - handler: async (input, context) => { - await logout(context) - - const tokenHash = hashUserSecretToken(input.token) - const matchedUser = await prisma.user.findFirst({ - where: { - secretTokenHash: tokenHash, - }, - }) - - if (!matchedUser) { - throw new ActionError({ - code: 'UNAUTHORIZED', - message: 'No user exists with this token', - }) - } - - await login(context, makeUserWithKarmaUnlocks(matchedUser)) - - return { - user: matchedUser, - // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - redirect: input.redirect || context.request.headers.get('referer') || '/', - } - }, - }), - - preGenerateToken: defineProtectedAction({ - accept: 'form', - permissions: 'guest', - handler: async () => { - const token = generateUserSecretToken() - await redisPreGeneratedSecretTokens.storePreGeneratedToken(token) - return { - token, - } as const - }, - }), - - generate: defineProtectedAction({ - accept: 'form', - permissions: 'guest', - input: z - .object({ - token: z.string().regex(USER_SECRET_TOKEN_REGEX).transform(parseUserSecretToken).optional(), - /** @deprecated Honey pot field, do not use */ - message: z.unknown().optional(), - ...captchaFormSchemaProperties, - }) - .superRefine(captchaFormSchemaSuperRefine), - handler: async (input, context) => { - await handleHoneypotTrap({ - input, - honeyPotTrapField: 'message', - userId: context.locals.user?.id, - location: 'account.generate', - }) - - const isValidToken = input.token - ? await redisPreGeneratedSecretTokens.validateAndConsumePreGeneratedToken(input.token) - : true - if (!isValidToken) { - throw new ActionError({ - code: 'BAD_REQUEST', - message: 'Invalid or expired token', - }) - } - - const { token, user: newUser } = await createAccount(input.token) - await setUserSessionIdCookie(context.cookies, newUser.secretTokenHash) - context.locals.user = makeUserWithKarmaUnlocks(newUser) - - return { - token, - user: newUser, - } as const - }, - }), - - impersonate: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - targetUserId: z.coerce.number().int().positive(), - redirect: z.string().optional(), - }), - handler: async (input, context) => { - const adminUser = context.locals.user - - const targetUser = await prisma.user.findUnique({ - where: { id: input.targetUserId }, - }) - - if (!targetUser) { - throw new ActionError({ - code: 'NOT_FOUND', - message: 'Target user not found', - }) - } - - if (targetUser.admin) { - throw new ActionError({ - code: 'FORBIDDEN', - message: 'Cannot impersonate admin user', - }) - } - - await startImpersonating(context, adminUser, makeUserWithKarmaUnlocks(targetUser)) - - return { - adminUser, - impersonatedUser: targetUser, - // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - redirect: input.redirect || context.request.headers.get('referer') || '/', - } - }, - }), - - update: defineProtectedAction({ - accept: 'form', - permissions: 'user', - input: z.object({ - id: z.coerce.number().int().positive(), - displayName: z.string().max(100, 'Display name must be 100 characters or less').optional().nullable(), - link: z - .string() - .url('Must be a valid URL') - .max(255, 'URL must be 255 characters or less') - .optional() - .nullable(), - pictureFile: imageFileSchema, - }), - handler: async (input, context) => { - if (input.id !== context.locals.user.id) { - throw new ActionError({ - code: 'FORBIDDEN', - message: 'You can only update your own profile', - }) - } - - if ( - input.displayName !== undefined && - input.displayName !== context.locals.user.displayName && - !context.locals.user.karmaUnlocks.displayName - ) { - throw new ActionError({ - code: 'FORBIDDEN', - message: makeKarmaUnlockMessage(karmaUnlocksById.displayName), - }) - } - - if ( - input.link !== undefined && - input.link !== context.locals.user.link && - !context.locals.user.karmaUnlocks.websiteLink - ) { - throw new ActionError({ - code: 'FORBIDDEN', - message: makeKarmaUnlockMessage(karmaUnlocksById.websiteLink), - }) - } - - if (input.pictureFile !== undefined && !context.locals.user.karmaUnlocks.profilePicture) { - throw new ActionError({ - code: 'FORBIDDEN', - message: makeKarmaUnlockMessage(karmaUnlocksById.profilePicture), - }) - } - - const pictureUrl = - input.pictureFile && input.pictureFile.size > 0 - ? await saveFileLocally( - input.pictureFile, - input.pictureFile.name, - `users/pictures/${String(context.locals.user.id)}` - ) - : null - - const user = await prisma.user.update({ - where: { id: context.locals.user.id }, - data: { - displayName: input.displayName ?? null, - link: input.link ?? null, - picture: pictureUrl, - }, - }) - - return { user } - }, - }), -} diff --git a/web/src/actions/admin/attribute.ts b/web/src/actions/admin/attribute.ts deleted file mode 100644 index ca25d4b..0000000 --- a/web/src/actions/admin/attribute.ts +++ /dev/null @@ -1,134 +0,0 @@ -import { AttributeCategory, AttributeType } from '@prisma/client' -import { z } from 'astro/zod' -import { ActionError } from 'astro:actions' -import slugify from 'slugify' - -import { defineProtectedAction } from '../../lib/defineProtectedAction' -import { prisma } from '../../lib/prisma' - -import type { Prisma } from '@prisma/client' - -const attributeInputSchema = z.object({ - title: z.string().min(1, 'Title is required'), - description: z.string().min(1, 'Description is required'), - category: z.nativeEnum(AttributeCategory), - type: z.nativeEnum(AttributeType), - privacyPoints: z.coerce.number().int().min(-100).max(100).default(0), - trustPoints: z.coerce.number().int().min(-100).max(100).default(0), - slug: z - .string() - .min(1, 'Slug is required') - .regex(/^[a-z0-9-]+$/, 'Allowed characters: lowercase letters, numbers, and hyphens'), -}) - -const attributeSelect = { - id: true, - slug: true, - title: true, - description: true, - category: true, - type: true, - privacyPoints: true, - trustPoints: true, - createdAt: true, - updatedAt: true, -} satisfies Prisma.AttributeSelect - -export const adminAttributeActions = { - create: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - title: z.string().min(1, 'Title is required'), - description: z.string().min(1, 'Description is required'), - category: z.nativeEnum(AttributeCategory), - type: z.nativeEnum(AttributeType), - privacyPoints: z.coerce.number().int().min(-100).max(100).default(0), - trustPoints: z.coerce.number().int().min(-100).max(100).default(0), - }), - handler: async (input) => { - const slug = slugify(input.title, { lower: true, strict: true }) - - const attribute = await prisma.attribute.create({ - data: { - ...input, - slug, - }, - select: attributeSelect, - }) - return { attribute } - }, - }), - - update: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: attributeInputSchema.extend({ - id: z.coerce.number().int().positive(), - }), - handler: async (input) => { - const { id, title, slug, ...data } = input - - const existingAttribute = await prisma.attribute.findUnique({ - where: { id }, - select: { title: true, slug: true }, - }) - - if (!existingAttribute) { - throw new ActionError({ - code: 'NOT_FOUND', - message: 'Attribute not found', - }) - } - - // Check for slug uniqueness (ignore current attribute) - const slugConflict = await prisma.attribute.findFirst({ - where: { slug, NOT: { id } }, - select: { id: true }, - }) - if (slugConflict) { - throw new ActionError({ - code: 'CONFLICT', - message: 'Slug already in use', - }) - } - - const attribute = await prisma.attribute.update({ - where: { id }, - data: { - title, - slug, - ...data, - }, - select: attributeSelect, - }) - - return { attribute } - }, - }), - - delete: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - id: z.coerce.number().int().positive('Attribute ID must be a positive integer.'), - }), - handler: async ({ id }) => { - try { - await prisma.attribute.delete({ - where: { id }, - }) - return { success: true, message: 'Attribute deleted successfully.' } - } catch (error) { - // Prisma throws an error if the record to delete is not found, - // or if there are related records that prevent deletion (foreign key constraints). - // We can customize the error message based on the type of error if needed. - console.error('Error deleting attribute:', error) - throw new ActionError({ - code: 'INTERNAL_SERVER_ERROR', - message: 'Failed to delete attribute. It might be in use or already deleted.', - }) - } - }, - }), -} diff --git a/web/src/actions/admin/event.ts b/web/src/actions/admin/event.ts deleted file mode 100644 index 7817ffb..0000000 --- a/web/src/actions/admin/event.ts +++ /dev/null @@ -1,129 +0,0 @@ -import { EventType } from '@prisma/client' -import { z } from 'astro/zod' -import { ActionError } from 'astro:actions' - -import { defineProtectedAction } from '../../lib/defineProtectedAction' -import { prisma } from '../../lib/prisma' - -export const adminEventActions = { - create: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z - .object({ - serviceId: z.coerce.number().int().positive(), - title: z.string().min(1), - content: z.string().min(1), - icon: z.string().optional(), - source: z.string().optional(), - type: z.nativeEnum(EventType).default('NORMAL'), - startedAt: z.coerce.date(), - endedAt: z.coerce.date().optional(), - }) - .superRefine((data, ctx) => { - if (data.endedAt && data.startedAt > data.endedAt) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: ['endedAt'], - message: 'Ended at must be after started at', - }) - } - }), - handler: async (input) => { - const event = await prisma.event.create({ - data: { - ...input, - visible: true, - }, - select: { - id: true, - }, - }) - return { event } - }, - }), - - toggle: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - eventId: z.coerce.number().int().positive(), - }), - handler: async (input) => { - const existingEvent = await prisma.event.findUnique({ where: { id: input.eventId } }) - if (!existingEvent) { - throw new ActionError({ - code: 'BAD_REQUEST', - message: 'Event not found', - }) - } - - const event = await prisma.event.update({ - where: { id: input.eventId }, - data: { - visible: !existingEvent.visible, - }, - select: { - id: true, - }, - }) - return { event } - }, - }), - - update: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z - .object({ - eventId: z.coerce.number().int().positive(), - title: z.string().min(1), - content: z.string().min(1), - icon: z.string().optional(), - source: z.string().optional(), - type: z.nativeEnum(EventType).default('NORMAL'), - startedAt: z.coerce.date(), - endedAt: z.coerce.date().optional(), - }) - .superRefine((data, ctx) => { - if (data.endedAt && data.startedAt > data.endedAt) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: ['endedAt'], - message: 'Ended at must be after started at', - }) - } - }), - handler: async (input) => { - const { eventId, ...data } = input - const existingEvent = await prisma.event.findUnique({ where: { id: eventId } }) - if (!existingEvent) { - throw new ActionError({ - code: 'BAD_REQUEST', - message: 'Event not found', - }) - } - - const event = await prisma.event.update({ - where: { id: eventId }, - data, - select: { - id: true, - }, - }) - return { event } - }, - }), - - delete: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - eventId: z.coerce.number().int().positive(), - }), - handler: async (input) => { - const event = await prisma.event.delete({ where: { id: input.eventId } }) - return { event } - }, - }), -} diff --git a/web/src/actions/admin/index.ts b/web/src/actions/admin/index.ts deleted file mode 100644 index 14dff5c..0000000 --- a/web/src/actions/admin/index.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { adminAttributeActions } from './attribute' -import { adminEventActions } from './event' -import { adminServiceActions } from './service' -import { adminServiceSuggestionActions } from './serviceSuggestion' -import { adminUserActions } from './user' -import { verificationStep } from './verificationStep' - -export const adminActions = { - attribute: adminAttributeActions, - event: adminEventActions, - service: adminServiceActions, - serviceSuggestions: adminServiceSuggestionActions, - user: adminUserActions, - verificationStep, -} diff --git a/web/src/actions/admin/service.ts b/web/src/actions/admin/service.ts deleted file mode 100644 index 1492054..0000000 --- a/web/src/actions/admin/service.ts +++ /dev/null @@ -1,234 +0,0 @@ -import { Currency, ServiceVisibility, VerificationStatus } from '@prisma/client' -import { z } from 'astro/zod' -import { ActionError } from 'astro:actions' -import slugify from 'slugify' - -import { defineProtectedAction } from '../../lib/defineProtectedAction' -import { saveFileLocally } from '../../lib/fileStorage' -import { prisma } from '../../lib/prisma' -import { - imageFileSchema, - stringListOfUrlsSchema, - stringListOfUrlsSchemaRequired, - zodCohercedNumber, -} from '../../lib/zodUtils' - -const serviceSchemaBase = z.object({ - id: z.number(), - slug: z - .string() - .regex(/^[a-z0-9-]+$/, 'Allowed characters: lowercase letters, numbers, and hyphens') - .optional(), - name: z.string().min(1).max(20), - description: z.string().min(1), - serviceUrls: stringListOfUrlsSchemaRequired, - tosUrls: stringListOfUrlsSchemaRequired, - onionUrls: stringListOfUrlsSchema, - kycLevel: z.coerce.number().int().min(0).max(4), - attributes: z.array(z.coerce.number().int().positive()), - categories: z.array(z.coerce.number().int().positive()).min(1), - verificationStatus: z.nativeEnum(VerificationStatus), - verificationSummary: z.string().optional().nullable().default(null), - verificationProofMd: z.string().optional().nullable().default(null), - acceptedCurrencies: z.array(z.nativeEnum(Currency)), - referral: z.string().optional().nullable().default(null), - imageFile: imageFileSchema, - overallScore: zodCohercedNumber(z.number().int().min(0).max(10)).optional(), - serviceVisibility: z.nativeEnum(ServiceVisibility), -}) - -const addSlugIfMissing = < - T extends { - slug?: string | null | undefined - name: string - }, ->( - input: T -) => ({ - ...input, - slug: - input.slug ?? - slugify(input.name, { - lower: true, - strict: true, - remove: /[^a-zA-Z0-9\-._]/g, - replacement: '-', - }), -}) - -const contactMethodSchema = z.object({ - id: z.number().optional(), - label: z.string().min(1).max(50), - value: z.string().min(1).max(200), - iconId: z.string().min(1).max(50), - info: z.string().max(200).optional().default(''), - serviceId: z.number(), -}) - -export const adminServiceActions = { - create: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: serviceSchemaBase.omit({ id: true }).transform(addSlugIfMissing), - handler: async (input) => { - const existing = await prisma.service.findUnique({ - where: { - slug: input.slug, - }, - }) - - if (existing) { - throw new ActionError({ - code: 'CONFLICT', - message: 'A service with this slug already exists', - }) - } - - const { imageFile, ...serviceData } = input - const imageUrl = imageFile ? await saveFileLocally(imageFile, imageFile.name) : undefined - - const service = await prisma.service.create({ - data: { - ...serviceData, - categories: { - connect: input.categories.map((id) => ({ id })), - }, - attributes: { - create: input.attributes.map((attributeId) => ({ - attribute: { - connect: { id: attributeId }, - }, - })), - }, - imageUrl, - }, - select: { - id: true, - slug: true, - }, - }) - - return { service } - }, - }), - - update: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: serviceSchemaBase.transform(addSlugIfMissing), - handler: async (input) => { - const { id, categories, attributes, imageFile, ...data } = input - - const existing = await prisma.service.findUnique({ - where: { - slug: input.slug, - NOT: { id }, - }, - }) - - if (existing) { - throw new ActionError({ - code: 'CONFLICT', - message: 'A service with this slug already exists', - }) - } - - const imageUrl = imageFile ? await saveFileLocally(imageFile, imageFile.name) : undefined - - // Get existing attributes and categories to compute differences - const existingService = await prisma.service.findUnique({ - where: { id }, - include: { - categories: true, - attributes: { - include: { - attribute: true, - }, - }, - }, - }) - - if (!existingService) { - throw new ActionError({ - code: 'NOT_FOUND', - message: 'Service not found', - }) - } - - // Find categories to connect and disconnect - const existingCategoryIds = existingService.categories.map((c) => c.id) - const categoriesToAdd = categories.filter((cId) => !existingCategoryIds.includes(cId)) - const categoriesToRemove = existingCategoryIds.filter((cId) => !categories.includes(cId)) - - // Find attributes to connect and disconnect - const existingAttributeIds = existingService.attributes.map((a) => a.attributeId) - const attributesToAdd = attributes.filter((aId) => !existingAttributeIds.includes(aId)) - const attributesToRemove = existingAttributeIds.filter((aId) => !attributes.includes(aId)) - - const service = await prisma.service.update({ - where: { id }, - data: { - ...data, - imageUrl, - categories: { - connect: categoriesToAdd.map((id) => ({ id })), - disconnect: categoriesToRemove.map((id) => ({ id })), - }, - attributes: { - // Connect new attributes - create: attributesToAdd.map((attributeId) => ({ - attribute: { - connect: { id: attributeId }, - }, - })), - // Delete specific attributes that are no longer needed - deleteMany: attributesToRemove.map((attributeId) => ({ - attributeId, - })), - }, - }, - }) - return { service } - }, - }), - - createContactMethod: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: contactMethodSchema.omit({ id: true }), - handler: async (input) => { - const contactMethod = await prisma.serviceContactMethod.create({ - data: input, - }) - return { contactMethod } - }, - }), - - updateContactMethod: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: contactMethodSchema, - handler: async (input) => { - const { id, ...data } = input - const contactMethod = await prisma.serviceContactMethod.update({ - where: { id }, - data, - }) - return { contactMethod } - }, - }), - - deleteContactMethod: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - id: z.number(), - }), - handler: async (input) => { - await prisma.serviceContactMethod.delete({ - where: { id: input.id }, - }) - return { success: true } - }, - }), -} diff --git a/web/src/actions/admin/serviceSuggestion.ts b/web/src/actions/admin/serviceSuggestion.ts deleted file mode 100644 index 55a7f1d..0000000 --- a/web/src/actions/admin/serviceSuggestion.ts +++ /dev/null @@ -1,71 +0,0 @@ -import { ServiceSuggestionStatus } from '@prisma/client' -import { z } from 'astro/zod' -import { ActionError } from 'astro:actions' - -import { defineProtectedAction } from '../../lib/defineProtectedAction' -import { prisma } from '../../lib/prisma' - -export const adminServiceSuggestionActions = { - update: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - suggestionId: z.coerce.number().int().positive(), - status: z.nativeEnum(ServiceSuggestionStatus), - }), - handler: async (input) => { - const suggestion = await prisma.serviceSuggestion.findUnique({ - select: { - id: true, - status: true, - serviceId: true, - }, - where: { id: input.suggestionId }, - }) - - if (!suggestion) { - throw new ActionError({ - code: 'NOT_FOUND', - message: 'Suggestion not found', - }) - } - - await prisma.serviceSuggestion.update({ - where: { id: suggestion.id }, - data: { - status: input.status, - }, - }) - }, - }), - - message: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - suggestionId: z.coerce.number().int().positive(), - content: z.string().min(1).max(1000), - }), - handler: async (input, context) => { - const suggestion = await prisma.serviceSuggestion.findUnique({ - select: { - id: true, - userId: true, - }, - where: { id: input.suggestionId }, - }) - - if (!suggestion) { - throw new Error('Suggestion not found') - } - - await prisma.serviceSuggestionMessage.create({ - data: { - content: input.content, - suggestionId: suggestion.id, - userId: context.locals.user.id, - }, - }) - }, - }), -} diff --git a/web/src/actions/admin/user.ts b/web/src/actions/admin/user.ts deleted file mode 100644 index c253009..0000000 --- a/web/src/actions/admin/user.ts +++ /dev/null @@ -1,288 +0,0 @@ -import { type Prisma, type ServiceUserRole, type PrismaClient } from '@prisma/client' -import { ActionError } from 'astro:actions' -import { z } from 'zod' - -import { defineProtectedAction } from '../../lib/defineProtectedAction' -import { saveFileLocally } from '../../lib/fileStorage' -import { prisma as prismaInstance } from '../../lib/prisma' - -const prisma = prismaInstance as PrismaClient - -const selectUserReturnFields = { - id: true, - name: true, - displayName: true, - link: true, - picture: true, - admin: true, - verified: true, - verifier: true, - verifiedLink: true, - secretTokenHash: true, - totalKarma: true, - createdAt: true, - updatedAt: true, - spammer: true, -} as const satisfies Prisma.UserSelect - -export const adminUserActions = { - search: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - name: z.string().min(1, 'User name is required'), - }), - handler: async (input) => { - const user = await prisma.user.findUnique({ - where: { name: input.name }, - select: selectUserReturnFields, - }) - - return { user } - }, - }), - - update: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - id: z.number().int().positive(), - name: z.string().min(1, 'Name is required').max(255, 'Name must be less than 255 characters'), - link: z - .string() - .url('Invalid URL') - .nullable() - .default(null) // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - .transform((val) => val || null), - picture: z.string().max(255, 'Picture URL must be less than 255 characters').nullable().default(null), - pictureFile: z.instanceof(File).optional(), - verifier: z.boolean().default(false), - admin: z.boolean().default(false), - spammer: z.boolean().default(false), - verifiedLink: z - .string() - .url('Invalid URL') - .nullable() - .default(null) // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - .transform((val) => val || null), - displayName: z - .string() - .max(50, 'Display Name must be less than 50 characters') - .nullable() - .default(null) // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - .transform((val) => val || null), - }), - handler: async ({ id, picture, pictureFile, ...valuesToUpdate }) => { - const user = await prisma.user.findUnique({ - where: { - id, - }, - select: { - id: true, - }, - }) - - if (!user) { - throw new ActionError({ - code: 'BAD_REQUEST', - message: 'User not found', - }) - } - - let pictureUrl = picture ?? null - if (pictureFile && pictureFile.size > 0) { - pictureUrl = await saveFileLocally(pictureFile, pictureFile.name, 'users/pictures/') - } - - const updatedUser = await prisma.user.update({ - where: { id: user.id }, - data: { - ...valuesToUpdate, - verified: !!valuesToUpdate.verifiedLink, - picture: pictureUrl, - }, - select: selectUserReturnFields, - }) - - return { - updatedUser, - } - }, - }), - - internalNotes: { - add: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - userId: z.coerce.number().int().positive(), - content: z.string().min(1).max(1000), - }), - handler: async (input, context) => { - const note = await prisma.internalUserNote.create({ - data: { - content: input.content, - userId: input.userId, - addedByUserId: context.locals.user.id, - }, - select: { - id: true, - }, - }) - - return { note } - }, - }), - - delete: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - noteId: z.coerce.number().int().positive(), - }), - handler: async (input) => { - await prisma.internalUserNote.delete({ - where: { - id: input.noteId, - }, - }) - }, - }), - - update: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - noteId: z.coerce.number().int().positive(), - content: z.string().min(1).max(1000), - }), - handler: async (input, context) => { - const note = await prisma.internalUserNote.update({ - where: { - id: input.noteId, - }, - data: { - content: input.content, - addedByUserId: context.locals.user.id, - }, - select: { - id: true, - }, - }) - - return { note } - }, - }), - }, - - serviceAffiliations: { - add: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - userId: z.coerce.number().int().positive(), - serviceId: z.coerce.number().int().positive(), - role: z.enum(['OWNER', 'ADMIN', 'MODERATOR', 'SUPPORT', 'TEAM_MEMBER']), - }), - handler: async (input) => { - // Check if the user exists - const user = await prisma.user.findUnique({ - where: { id: input.userId }, - select: { id: true }, - }) - - if (!user) { - throw new ActionError({ - code: 'BAD_REQUEST', - message: 'User not found', - }) - } - - // Check if the service exists - const service = await prisma.service.findUnique({ - where: { id: input.serviceId }, - select: { id: true, name: true }, - }) - - if (!service) { - throw new ActionError({ - code: 'BAD_REQUEST', - message: 'Service not found', - }) - } - - try { - // Check if the service affiliation already exists - const existingAffiliation = await prisma.serviceUser.findUnique({ - where: { - userId_serviceId: { - userId: input.userId, - serviceId: input.serviceId, - }, - }, - }) - - let serviceAffiliation - - if (existingAffiliation) { - // Update existing affiliation - serviceAffiliation = await prisma.serviceUser.update({ - where: { - userId_serviceId: { - userId: input.userId, - serviceId: input.serviceId, - }, - }, - data: { - role: input.role as ServiceUserRole, - }, - }) - - return { serviceAffiliation, serviceName: service.name, updated: true } - } else { - // Create new affiliation - serviceAffiliation = await prisma.serviceUser.create({ - data: { - userId: input.userId, - serviceId: input.serviceId, - role: input.role as ServiceUserRole, - }, - }) - - return { serviceAffiliation, serviceName: service.name } - } - } catch (error) { - console.error('Error managing service affiliation:', error) - throw new ActionError({ - code: 'INTERNAL_SERVER_ERROR', - message: 'Error managing service affiliation', - }) - } - }, - }), - - remove: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: z.object({ - id: z.coerce.number().int().positive(), - }), - handler: async (input) => { - const serviceAffiliation = await prisma.serviceUser.delete({ - where: { - id: input.id, - }, - include: { - service: { - select: { - name: true, - }, - }, - }, - }) - - return { serviceAffiliation } - }, - }), - }, -} diff --git a/web/src/actions/admin/verificationStep.ts b/web/src/actions/admin/verificationStep.ts deleted file mode 100644 index 0552e20..0000000 --- a/web/src/actions/admin/verificationStep.ts +++ /dev/null @@ -1,118 +0,0 @@ -import { VerificationStepStatus } from '@prisma/client' -import { z } from 'astro/zod' -import { ActionError } from 'astro:actions' - -import { defineProtectedAction } from '../../lib/defineProtectedAction' -import { prisma } from '../../lib/prisma' - -const verificationStepSchemaBase = z.object({ - title: z.string().min(1, 'Title is required'), - description: z - .string() - .min(1, 'Description is required') - .max(200, 'Description must be 200 characters or less'), - status: z.nativeEnum(VerificationStepStatus), - serviceId: z.coerce.number().int().positive(), - evidenceMd: z.string().optional().nullable().default(null), -}) - -const verificationStepUpdateSchema = z.object({ - id: z.coerce.number().int().positive(), - title: z.string().min(1, 'Title is required').optional(), - description: z - .string() - .min(1, 'Description is required') - .max(200, 'Description must be 200 characters or less') - .optional(), - status: z.nativeEnum(VerificationStepStatus).optional(), - evidenceMd: z.string().optional().nullable(), -}) - -const verificationStepIdSchema = z.object({ - id: z.coerce.number().int().positive(), -}) - -export const verificationStep = { - create: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: verificationStepSchemaBase, - handler: async (input) => { - const { serviceId, title, description, status, evidenceMd } = input - - const service = await prisma.service.findUnique({ - where: { id: serviceId }, - }) - - if (!service) { - throw new ActionError({ - code: 'NOT_FOUND', - message: 'Service not found', - }) - } - - const newVerificationStep = await prisma.verificationStep.create({ - data: { - title, - description, - status, - evidenceMd, - service: { - connect: { id: serviceId }, - }, - }, - }) - - return { verificationStep: newVerificationStep } - }, - }), - - update: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: verificationStepUpdateSchema, - handler: async (input) => { - const { id, ...dataToUpdate } = input - - const existingStep = await prisma.verificationStep.findUnique({ - where: { id }, - }) - - if (!existingStep) { - throw new ActionError({ - code: 'NOT_FOUND', - message: 'Verification step not found', - }) - } - - const updatedVerificationStep = await prisma.verificationStep.update({ - where: { id }, - data: dataToUpdate, - }) - - return { verificationStep: updatedVerificationStep } - }, - }), - - delete: defineProtectedAction({ - accept: 'form', - permissions: 'admin', - input: verificationStepIdSchema, - handler: async ({ id }) => { - const existingStep = await prisma.verificationStep.findUnique({ - where: { id }, - }) - - if (!existingStep) { - throw new ActionError({ - code: 'NOT_FOUND', - message: 'Verification step not found', - }) - } - - await prisma.verificationStep.delete({ where: { id } }) - - return { success: true, deletedId: id } - }, - }), -} diff --git a/web/src/actions/comment.ts b/web/src/actions/comment.ts deleted file mode 100644 index 78e1747..0000000 --- a/web/src/actions/comment.ts +++ /dev/null @@ -1,442 +0,0 @@ -import crypto from 'crypto' - -import { ActionError } from 'astro:actions' -import { z } from 'astro:schema' -import { formatDistanceStrict } from 'date-fns' - -import { karmaUnlocksById } from '../constants/karmaUnlocks' -import { defineProtectedAction } from '../lib/defineProtectedAction' -import { handleHoneypotTrap } from '../lib/honeypot' -import { makeKarmaUnlockMessage } from '../lib/karmaUnlocks' -import { getOrCreateNotificationPreferences } from '../lib/notificationPreferences' -import { prisma } from '../lib/prisma' -import { timeTrapSecretKey } from '../lib/timeTrapSecret' - -import type { CommentStatus, Prisma } from '@prisma/client' - -const COMMENT_RATE_LIMIT_WINDOW_MINUTES = 5 -const MAX_COMMENTS_PER_WINDOW = 1 -const MAX_COMMENTS_PER_WINDOW_VERIFIED_USER = 5 - -export const commentActions = { - vote: defineProtectedAction({ - accept: 'form', - permissions: 'user', - input: z.object({ - commentId: z.coerce.number().int().positive(), - downvote: z.coerce.boolean(), - }), - handler: async (input, context) => { - try { - // Check user karma requirement - if (!context.locals.user.karmaUnlocks.voteComments) { - throw new ActionError({ - code: 'FORBIDDEN', - message: makeKarmaUnlockMessage(karmaUnlocksById.voteComments), - }) - } - - // Handle the vote in a transaction - await prisma.$transaction(async (tx) => { - // Get existing vote if any - const existingVote = await tx.commentVote.findUnique({ - where: { - commentId_userId: { - commentId: input.commentId, - userId: context.locals.user.id, - }, - }, - }) - - if (existingVote) { - // If vote type is the same, remove the vote - if (existingVote.downvote === input.downvote) { - await tx.commentVote.delete({ - where: { id: existingVote.id }, - }) - } else { - // If vote type is different, update the vote - await tx.commentVote.update({ - where: { id: existingVote.id }, - data: { downvote: input.downvote }, - }) - } - } else { - // Create new vote - await tx.commentVote.create({ - data: { - downvote: input.downvote, - commentId: input.commentId, - userId: context.locals.user.id, - }, - }) - } - }) - - return true - } catch (error) { - if (error instanceof ActionError) throw error - - console.error('Error voting on comment:', error) - throw new ActionError({ - code: 'INTERNAL_SERVER_ERROR', - message: 'Error voting on comment', - }) - } - }, - }), - - create: defineProtectedAction({ - accept: 'form', - permissions: 'user', - input: z - .object({ - content: z.string().min(10).max(2000), - serviceId: z.coerce.number().int().positive(), - parentId: z.coerce.number().optional(), - /** @deprecated Honey pot field, do not use */ - message: z.unknown().optional(), - rating: z.coerce.number().int().min(1).max(5).optional(), - encTimestamp: z.string().min(1), // time trap field - internalNote: z.string().max(500).optional(), - issueKycRequested: z.coerce.boolean().optional(), - issueFundsBlocked: z.coerce.boolean().optional(), - issueScam: z.coerce.boolean().optional(), - issueDetails: z.string().max(120).optional(), - orderId: z.string().max(100).optional(), - }) - .superRefine((data, ctx) => { - if (data.rating && data.parentId) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: ['parentId'], - message: 'Ratings cannot be provided for replies', - }) - } - if (!data.parentId) { - if (data.content.length < 30) { - ctx.addIssue({ - code: z.ZodIssueCode.too_small, - minimum: 30, - type: 'string', - inclusive: true, - path: ['content'], - message: 'Content must be at least 30 characters', - }) - } - } - }), - handler: async (input, context) => { - if (context.locals.user.karmaUnlocks.commentsDisabled) { - throw new ActionError({ - code: 'FORBIDDEN', - message: makeKarmaUnlockMessage(karmaUnlocksById.commentsDisabled), - }) - } - - await handleHoneypotTrap({ - input, - honeyPotTrapField: 'message', - userId: context.locals.user.id, - location: 'comment.create', - }) - - // --- Time Trap Validation Start --- - try { - const algorithm = 'aes-256-cbc' - const decodedValue = Buffer.from(input.encTimestamp, 'base64').toString('utf8') - const [ivHex, encryptedHex] = decodedValue.split(':') - - if (!ivHex || !encryptedHex) { - throw new Error('Invalid time trap format.') - } - - const iv = Buffer.from(ivHex, 'hex') - const decipher = crypto.createDecipheriv(algorithm, timeTrapSecretKey, iv) - let decrypted = decipher.update(encryptedHex, 'hex', 'utf8') - decrypted += decipher.final('utf8') - - const originalTimestamp = parseInt(decrypted, 10) - if (isNaN(originalTimestamp)) { - throw new Error('Invalid timestamp data.') - } - - const now = Date.now() - const timeDiff = now - originalTimestamp - const minTimeSeconds = 2 // 2 seconds - const maxTimeMinutes = 60 // 1 hour - - if (timeDiff < minTimeSeconds * 1000 || timeDiff > maxTimeMinutes * 60 * 1000) { - console.warn(`Time trap triggered: ${(timeDiff / 1000).toLocaleString()}s`) - throw new Error('Invalid submission timing.') - } - } catch (err) { - console.error('Time trap validation failed:', err instanceof Error ? err.message : 'Unknown error') - throw new ActionError({ - code: 'BAD_REQUEST', - message: 'Invalid request', - }) - } - // --- Time Trap Validation End --- - - // --- Rate Limit Check Start --- - const isVerifiedUser = context.locals.user.admin || context.locals.user.verified - const maxCommentsPerWindow = isVerifiedUser - ? MAX_COMMENTS_PER_WINDOW_VERIFIED_USER - : MAX_COMMENTS_PER_WINDOW - - const windowStart = new Date(Date.now() - COMMENT_RATE_LIMIT_WINDOW_MINUTES * 60 * 1000) - const recentCommentCount = await prisma.comment.findMany({ - where: { - authorId: context.locals.user.id, - createdAt: { - gte: windowStart, - }, - }, - select: { - id: true, - createdAt: true, - }, - }) - - if (recentCommentCount.length >= maxCommentsPerWindow) { - const oldestCreatedAt = recentCommentCount.reduce((oldestDate, comment) => { - if (!oldestDate) return comment.createdAt - if (comment.createdAt < oldestDate) return comment.createdAt - return oldestDate - }, null) - - console.warn(`Rate limit exceeded for user ${context.locals.user.id.toLocaleString()}`) - throw new ActionError({ - code: 'TOO_MANY_REQUESTS', // Use specific 429 code - message: `Rate limit exceeded. Please wait ${oldestCreatedAt ? `${formatDistanceStrict(oldestCreatedAt, windowStart)} ` : ''}before commenting again.`, - }) - } - // --- Rate Limit Check End --- - - // --- Format Internal Note from Issue Reports --- - let formattedInternalNote: string | null = null - // Track if this is an issue report - const isIssueReport = - input.issueKycRequested === true || input.issueFundsBlocked === true || input.issueScam === true - - if (isIssueReport) { - const issueTypes = [] - if (input.issueKycRequested) issueTypes.push('KYC REQUESTED') - if (input.issueFundsBlocked) issueTypes.push('FUNDS BLOCKED') - if (input.issueScam) issueTypes.push('POTENTIAL SCAM') - - const details = input.issueDetails?.trim() ?? '' - - formattedInternalNote = `[${issueTypes.join(', ')}]${details ? `: ${details}` : ''}` - } else if (input.internalNote?.trim()) { - formattedInternalNote = input.internalNote.trim() - } - - // Determine if admin review is needed (always true for issue reports) - const requiresAdminReview = isIssueReport || !!(formattedInternalNote && !context.locals.user.admin) - - try { - await prisma.$transaction(async (tx) => { - // First deactivate any existing ratings if providing a new rating - if (input.rating) { - await tx.comment.updateMany({ - where: { - serviceId: input.serviceId, - authorId: context.locals.user.id, - rating: { not: null }, - }, - data: { - ratingActive: false, - }, - }) - } - - // Check for existing orderId for this service if provided - if (input.orderId?.trim()) { - const existingOrderId = await tx.comment.findFirst({ - where: { - serviceId: input.serviceId, - orderId: input.orderId.trim(), - }, - select: { id: true }, - }) - - if (existingOrderId) { - throw new ActionError({ - code: 'BAD_REQUEST', - message: 'This Order ID has already been reported for this service.', - }) - } - } - - // Prepare data object with proper type safety - const commentData: Prisma.CommentCreateInput = { - content: input.content, - service: { connect: { id: input.serviceId } }, - author: { connect: { id: context.locals.user.id } }, - - // Change status to HUMAN_PENDING if there's an issue report, this is so that the AI worker does not pick it up for review - status: context.locals.user.admin ? 'APPROVED' : isIssueReport ? 'HUMAN_PENDING' : 'PENDING', - requiresAdminReview, - orderId: input.orderId?.trim() ?? null, - kycRequested: input.issueKycRequested === true, - fundsBlocked: input.issueFundsBlocked === true, - } - - if (input.parentId) { - commentData.parent = { connect: { id: input.parentId } } - } - - if (input.rating) { - commentData.rating = input.rating - commentData.ratingActive = true - } - - if (formattedInternalNote) { - commentData.internalNote = formattedInternalNote - } - - const newComment = await tx.comment.create({ - data: commentData, - }) - - const notiPref = await getOrCreateNotificationPreferences( - context.locals.user.id, - { enableAutowatchMyComments: true }, - tx - ) - - if (notiPref.enableAutowatchMyComments) { - await tx.notificationPreferences.update({ - where: { userId: context.locals.user.id }, - data: { - watchedComments: { connect: { id: newComment.id } }, - }, - }) - } - }) - - return { success: true } - } catch (error) { - if (error instanceof ActionError) throw error - - console.error('Error creating comment:', error) - throw new ActionError({ - code: 'INTERNAL_SERVER_ERROR', - message: 'Error creating comment', - }) - } - }, - }), - - moderate: defineProtectedAction({ - permissions: ['admin', 'verifier'], - input: z.object({ - commentId: z.number(), - userId: z.number(), - action: z.enum([ - 'status', - 'suspicious', - 'requires-admin-review', - 'community-note', - 'internal-note', - 'private-context', - 'order-id-status', - 'kyc-requested', - 'funds-blocked', - ]), - value: z.union([ - z.enum(['PENDING', 'APPROVED', 'VERIFIED', 'REJECTED']), - z.enum(['PENDING', 'APPROVED', 'REJECTED']), - z.boolean(), - z.string(), - ]), - }), - handler: async (input) => { - try { - const comment = await prisma.comment.findUnique({ - where: { id: input.commentId }, - select: { - id: true, - rating: true, - serviceId: true, - createdAt: true, - authorId: true, - }, - }) - - if (!comment) { - throw new ActionError({ - code: 'NOT_FOUND', - message: 'Comment not found', - }) - } - - const updateData: Prisma.CommentUpdateInput = {} - - switch (input.action) { - case 'status': - updateData.status = input.value as CommentStatus - break - case 'suspicious': { - const isSpam = !!input.value - updateData.suspicious = isSpam - updateData.ratingActive = false - - if (!isSpam && comment.rating) { - const newestRatingOrActiveRating = await prisma.comment.findFirst({ - where: { - serviceId: comment.serviceId, - authorId: comment.authorId, - id: { not: input.commentId }, - rating: { not: null }, - OR: [{ createdAt: { gt: comment.createdAt } }, { ratingActive: true }], - }, - }) - updateData.ratingActive = !newestRatingOrActiveRating - } - break - } - case 'requires-admin-review': - updateData.requiresAdminReview = !!input.value - break - case 'community-note': - updateData.communityNote = input.value as string - break - case 'internal-note': - updateData.internalNote = input.value as string - break - case 'private-context': - updateData.privateContext = input.value as string - break - case 'order-id-status': - updateData.orderIdStatus = input.value as 'APPROVED' | 'PENDING' | 'REJECTED' - break - case 'kyc-requested': - updateData.kycRequested = !!input.value - break - case 'funds-blocked': - updateData.fundsBlocked = !!input.value - break - } - - // Update the comment - await prisma.comment.update({ - where: { id: input.commentId }, - data: updateData, - }) - - return { success: true } - } catch (error) { - if (error instanceof ActionError) throw error - - console.error('Error moderating comment:', error) - throw new ActionError({ - code: 'INTERNAL_SERVER_ERROR', - message: 'Error moderating comment', - }) - } - }, - }), -} diff --git a/web/src/actions/index.ts b/web/src/actions/index.ts deleted file mode 100644 index 7b40a69..0000000 --- a/web/src/actions/index.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { accountActions } from './account' -import { adminActions } from './admin' -import { commentActions } from './comment' -import { notificationActions } from './notifications' -import { serviceActions } from './service' -import { serviceSuggestionActions } from './serviceSuggestion' - -/** - * @deprecated Don't import this object, use {@link actions} instead, like: `import { actions } from 'astro:actions'` - * - * @example - * ```ts - * import { actions } from 'astro:actions' - * import { server } from '~/actions' // WRONG!!!! - * - * const result = Astro.getActionResult(actions.admin.attribute.create) - * ``` - */ -export const server = { - account: accountActions, - admin: adminActions, - comment: commentActions, - notification: notificationActions, - service: serviceActions, - serviceSuggestion: serviceSuggestionActions, -} - -// Don't create an object named actions, put the actions in the server object instead. Astro will automatically export the server object as actions. diff --git a/web/src/actions/notifications.ts b/web/src/actions/notifications.ts deleted file mode 100644 index 3ae200c..0000000 --- a/web/src/actions/notifications.ts +++ /dev/null @@ -1,132 +0,0 @@ -import { z } from 'astro:content' - -import { defineProtectedAction } from '../lib/defineProtectedAction' -import { prisma } from '../lib/prisma' - -export const notificationActions = { - updateReadStatus: defineProtectedAction({ - accept: 'form', - permissions: 'user', - input: z.object({ - notificationId: z.literal('all').or(z.coerce.number().int().positive()), - read: z.coerce.boolean(), - }), - handler: async (input, context) => { - await prisma.notification.updateMany({ - where: - input.notificationId === 'all' - ? { userId: context.locals.user.id, read: !input.read } - : { userId: context.locals.user.id, id: input.notificationId }, - data: { - read: input.read, - }, - }) - }, - }), - preferences: { - update: defineProtectedAction({ - accept: 'form', - permissions: 'user', - input: z.object({ - enableOnMyCommentStatusChange: z.coerce.boolean().optional(), - enableAutowatchMyComments: z.coerce.boolean().optional(), - enableNotifyPendingRepliesOnWatch: z.coerce.boolean().optional(), - }), - handler: async (input, context) => { - await prisma.notificationPreferences.upsert({ - where: { userId: context.locals.user.id }, - update: { - enableOnMyCommentStatusChange: input.enableOnMyCommentStatusChange, - enableAutowatchMyComments: input.enableAutowatchMyComments, - enableNotifyPendingRepliesOnWatch: input.enableNotifyPendingRepliesOnWatch, - }, - create: { - userId: context.locals.user.id, - enableOnMyCommentStatusChange: input.enableOnMyCommentStatusChange, - enableAutowatchMyComments: input.enableAutowatchMyComments, - enableNotifyPendingRepliesOnWatch: input.enableNotifyPendingRepliesOnWatch, - }, - }) - }, - }), - - watchComment: defineProtectedAction({ - accept: 'form', - permissions: 'user', - input: z.object({ - commentId: z.coerce.number().int().positive(), - watch: z.coerce.boolean(), - }), - handler: async (input, context) => { - await prisma.notificationPreferences.upsert({ - where: { userId: context.locals.user.id }, - update: { - watchedComments: input.watch - ? { connect: { id: input.commentId } } - : { disconnect: { id: input.commentId } }, - }, - create: { - userId: context.locals.user.id, - watchedComments: input.watch ? { connect: { id: input.commentId } } : undefined, - }, - }) - }, - }), - - watchService: defineProtectedAction({ - accept: 'form', - permissions: 'user', - input: z.object({ - serviceId: z.coerce.number().int().positive(), - watchType: z.enum(['all', 'comments', 'events', 'verification']), - value: z.coerce.boolean(), - }), - handler: async (input, context) => { - await prisma.notificationPreferences.upsert({ - where: { userId: context.locals.user.id }, - update: { - onEventCreatedForServices: - input.watchType === 'events' || input.watchType === 'all' - ? input.value - ? { connect: { id: input.serviceId } } - : { disconnect: { id: input.serviceId } } - : undefined, - onRootCommentCreatedForServices: - input.watchType === 'comments' || input.watchType === 'all' - ? input.value - ? { connect: { id: input.serviceId } } - : { disconnect: { id: input.serviceId } } - : undefined, - onVerificationChangeForServices: - input.watchType === 'verification' || input.watchType === 'all' - ? input.value - ? { connect: { id: input.serviceId } } - : { disconnect: { id: input.serviceId } } - : undefined, - }, - create: { - userId: context.locals.user.id, - onEventCreatedForServices: - input.watchType === 'events' || input.watchType === 'all' - ? input.value - ? { connect: { id: input.serviceId } } - : undefined - : undefined, - onRootCommentCreatedForServices: - input.watchType === 'comments' || input.watchType === 'all' - ? input.value - ? { connect: { id: input.serviceId } } - : undefined - : undefined, - onVerificationChangeForServices: - input.watchType === 'verification' || input.watchType === 'all' - ? input.value - ? { connect: { id: input.serviceId } } - : undefined - : undefined, - }, - }) - }, - }), - }, -} diff --git a/web/src/actions/service.ts b/web/src/actions/service.ts deleted file mode 100644 index 8ff9dfd..0000000 --- a/web/src/actions/service.ts +++ /dev/null @@ -1,104 +0,0 @@ -import { z } from 'astro/zod' -import { ActionError } from 'astro:actions' - -import { defineProtectedAction } from '../lib/defineProtectedAction' -import { prisma } from '../lib/prisma' - -export const serviceActions = { - requestVerification: defineProtectedAction({ - accept: 'form', - permissions: 'user', - input: z.object({ - serviceId: z.coerce.number().int().positive(), - action: z.enum(['request', 'withdraw']), - }), - handler: async (input, context) => { - const service = await prisma.service.findUnique({ - where: { - id: input.serviceId, - }, - select: { - verificationStatus: true, - }, - }) - - if (!service) { - throw new ActionError({ - message: 'Service not found', - code: 'NOT_FOUND', - }) - } - - if ( - service.verificationStatus === 'VERIFICATION_SUCCESS' || - service.verificationStatus === 'VERIFICATION_FAILED' - ) { - throw new ActionError({ - message: 'Service is already verified or marked as scam', - code: 'BAD_REQUEST', - }) - } - - const existingRequest = await prisma.serviceVerificationRequest.findUnique({ - where: { - serviceId_userId: { - serviceId: input.serviceId, - userId: context.locals.user.id, - }, - }, - select: { - id: true, - }, - }) - - switch (input.action) { - case 'withdraw': { - if (!existingRequest) { - throw new ActionError({ - message: 'You have not requested verification for this service', - code: 'BAD_REQUEST', - }) - } - await prisma.serviceVerificationRequest.delete({ - where: { - id: existingRequest.id, - }, - }) - break - } - default: - case 'request': { - if (existingRequest) { - throw new ActionError({ - message: 'You have already requested verification for this service', - code: 'BAD_REQUEST', - }) - } - - await prisma.serviceVerificationRequest.create({ - data: { - serviceId: input.serviceId, - userId: context.locals.user.id, - }, - }) - - await prisma.notificationPreferences.upsert({ - where: { userId: context.locals.user.id }, - update: { - onVerificationChangeForServices: { - connect: { id: input.serviceId }, - }, - }, - create: { - userId: context.locals.user.id, - onVerificationChangeForServices: { - connect: { id: input.serviceId }, - }, - }, - }) - break - } - } - }, - }), -} diff --git a/web/src/actions/serviceSuggestion.ts b/web/src/actions/serviceSuggestion.ts deleted file mode 100644 index 8baa39b..0000000 --- a/web/src/actions/serviceSuggestion.ts +++ /dev/null @@ -1,359 +0,0 @@ -import { - Currency, - ServiceSuggestionStatus, - ServiceSuggestionType, - ServiceVisibility, - VerificationStatus, -} from '@prisma/client' -import { z } from 'astro/zod' -import { ActionError } from 'astro:actions' -import { formatDistanceStrict } from 'date-fns' - -import { captchaFormSchemaProperties, captchaFormSchemaSuperRefine } from '../lib/captchaValidation' -import { defineProtectedAction } from '../lib/defineProtectedAction' -import { saveFileLocally } from '../lib/fileStorage' -import { handleHoneypotTrap } from '../lib/honeypot' -import { prisma } from '../lib/prisma' -import { - imageFileSchemaRequired, - stringListOfUrlsSchema, - stringListOfUrlsSchemaRequired, - zodCohercedNumber, -} from '../lib/zodUtils' - -import type { Prisma } from '@prisma/client' - -const SUGGESTION_MESSAGE_RATE_LIMIT_WINDOW_MINUTES = 1 -const MAX_SUGGESTION_MESSAGES_PER_WINDOW = 5 - -export const SUGGESTION_NOTES_MAX_LENGTH = 1000 -export const SUGGESTION_NAME_MAX_LENGTH = 20 -export const SUGGESTION_SLUG_MAX_LENGTH = 20 -export const SUGGESTION_DESCRIPTION_MAX_LENGTH = 100 -export const SUGGESTION_MESSAGE_CONTENT_MAX_LENGTH = 1000 - -const findPossibleDuplicates = async (input: { name: string }) => { - const possibleDuplicates = await prisma.service.findMany({ - where: { - name: { - contains: input.name, - mode: 'insensitive', - }, - }, - select: { - id: true, - name: true, - slug: true, - description: true, - }, - }) - - return possibleDuplicates -} - -const serializeExtraNotes = >( - input: T, - skipKeys: (keyof T)[] = [] -): string => { - return Object.entries(input) - .filter(([key]) => !skipKeys.includes(key as keyof T)) - .map(([key, value]) => { - let serializedValue = '' - if (typeof value === 'string') { - serializedValue = value - } else if (value === undefined || value === null) { - serializedValue = '' - } else if (typeof value === 'object' && 'toString' in value && typeof value.toString === 'function') { - // eslint-disable-next-line @typescript-eslint/no-base-to-string - serializedValue = value.toString() - } else { - try { - serializedValue = JSON.stringify(value) - } catch (error) { - serializedValue = `Error serializing value: ${error instanceof Error ? error.message : 'Unknown error'}` - } - } - return `- ${key}: ${serializedValue}` - }) - .join('\n') -} - -export const serviceSuggestionActions = { - editService: defineProtectedAction({ - accept: 'form', - permissions: 'not-spammer', - input: z - .object({ - notes: z.string().max(SUGGESTION_NOTES_MAX_LENGTH).optional(), - serviceId: z.coerce.number().int().positive(), - extraNotes: z.string().optional(), - /** @deprecated Honey pot field, do not use */ - message: z.unknown().optional(), - ...captchaFormSchemaProperties, - }) - .superRefine(captchaFormSchemaSuperRefine), - handler: async (input, context) => { - await handleHoneypotTrap({ - input, - honeyPotTrapField: 'message', - userId: context.locals.user.id, - location: 'serviceSuggestion.editService', - }) - - const service = await prisma.service.findUnique({ - select: { - id: true, - slug: true, - }, - where: { id: input.serviceId }, - }) - - if (!service) { - throw new ActionError({ - message: 'Service not found', - code: 'BAD_REQUEST', - }) - } - - // Combine notes and extraNotes if available - const combinedNotes = input.extraNotes - ? `${input.notes ?? ''}\n\nSuggested changes:\n${input.extraNotes}` - : input.notes - - const serviceSuggestion = await prisma.serviceSuggestion.create({ - data: { - type: ServiceSuggestionType.EDIT_SERVICE, - notes: combinedNotes, - status: ServiceSuggestionStatus.PENDING, - userId: context.locals.user.id, - serviceId: service.id, - }, - select: { - id: true, - }, - }) - - return { serviceSuggestion, service } - }, - }), - createService: defineProtectedAction({ - accept: 'form', - permissions: 'not-spammer', - input: z - .object({ - notes: z.string().max(SUGGESTION_NOTES_MAX_LENGTH).optional(), - name: z.string().min(1).max(SUGGESTION_NAME_MAX_LENGTH), - slug: z - .string() - .min(1) - .max(SUGGESTION_SLUG_MAX_LENGTH) - .regex(/^[a-z0-9-]+$/, { - message: 'Slug must contain only lowercase letters, numbers, and hyphens', - }) - .refine( - async (slug) => { - const exists = await prisma.service.findUnique({ - select: { id: true }, - where: { slug }, - }) - return !exists - }, - { message: 'Slug must be unique, try a different one' } - ), - description: z.string().min(1).max(SUGGESTION_DESCRIPTION_MAX_LENGTH), - serviceUrls: stringListOfUrlsSchemaRequired, - tosUrls: stringListOfUrlsSchemaRequired, - onionUrls: stringListOfUrlsSchema, - kycLevel: zodCohercedNumber(z.coerce.number().int().min(0).max(4)), - attributes: z.array(z.coerce.number().int().positive()), - categories: z.array(z.coerce.number().int().positive()).min(1), - acceptedCurrencies: z.array(z.nativeEnum(Currency)).min(1), - imageFile: imageFileSchemaRequired, - /** @deprecated Honey pot field, do not use */ - message: z.unknown().optional(), - skipDuplicateCheck: z - .string() - .optional() - .nullable() - .transform((value) => value === 'true'), - ...captchaFormSchemaProperties, - }) - .superRefine(captchaFormSchemaSuperRefine), - - handler: async (input, context) => { - await handleHoneypotTrap({ - input, - honeyPotTrapField: 'message', - userId: context.locals.user.id, - location: 'serviceSuggestion.createService', - }) - - if (!input.skipDuplicateCheck) { - const possibleDuplicates = await findPossibleDuplicates(input) - - if (possibleDuplicates.length > 0) { - return { - hasDuplicates: true, - possibleDuplicates, - extraNotes: serializeExtraNotes(input, [ - 'skipDuplicateCheck', - 'message', - 'imageFile', - 'captcha-value', - 'captcha-solution-hash', - ]), - serviceSuggestion: undefined, - service: undefined, - } as const - } - } - - const imageUrl = await saveFileLocally(input.imageFile, input.imageFile.name) - - const { serviceSuggestion, service } = await prisma.$transaction(async (tx) => { - const serviceSelect = { - id: true, - slug: true, - } satisfies Prisma.ServiceSelect - - const service = await tx.service.create({ - data: { - name: input.name, - slug: input.slug, - description: input.description, - serviceUrls: input.serviceUrls, - tosUrls: input.tosUrls, - onionUrls: input.onionUrls, - kycLevel: input.kycLevel, - acceptedCurrencies: input.acceptedCurrencies, - imageUrl, - verificationStatus: VerificationStatus.COMMUNITY_CONTRIBUTED, - overallScore: 0, - privacyScore: 0, - trustScore: 0, - listedAt: new Date(), - serviceVisibility: ServiceVisibility.UNLISTED, - categories: { - connect: input.categories.map((id) => ({ id })), - }, - attributes: { - create: input.attributes.map((id) => ({ - attributeId: id, - })), - }, - }, - select: serviceSelect, - }) - - const serviceSuggestion = await tx.serviceSuggestion.create({ - data: { - notes: input.notes, - type: ServiceSuggestionType.CREATE_SERVICE, - status: ServiceSuggestionStatus.PENDING, - userId: context.locals.user.id, - serviceId: service.id, - }, - select: { - id: true, - }, - }) - - return { - hasDuplicates: false, - possibleDuplicates: [], - extraNotes: undefined, - serviceSuggestion, - service, - } as const - }) - - return { - hasDuplicates: false, - possibleDuplicates: [], - extraNotes: undefined, - serviceSuggestion, - service, - } as const - }, - }), - message: defineProtectedAction({ - accept: 'form', - permissions: 'user', - input: z.object({ - suggestionId: z.coerce.number().int().positive(), - content: z.string().min(1).max(SUGGESTION_MESSAGE_CONTENT_MAX_LENGTH), - }), - handler: async (input, context) => { - // --- Rate Limit Check Start --- (Admins are exempt) - if (!context.locals.user.admin) { - const windowStart = new Date(Date.now() - SUGGESTION_MESSAGE_RATE_LIMIT_WINDOW_MINUTES * 60 * 1000) - const recentMessages = await prisma.serviceSuggestionMessage.findMany({ - where: { - userId: context.locals.user.id, - createdAt: { - gte: windowStart, - }, - }, - select: { - id: true, - createdAt: true, - }, - orderBy: { createdAt: 'asc' }, // Get the oldest first to calculate wait time - }) - - if (recentMessages.length >= MAX_SUGGESTION_MESSAGES_PER_WINDOW) { - const oldestMessageInWindow = recentMessages[0] - if (!oldestMessageInWindow) { - console.error( - 'Error determining oldest message for rate limit, but length check passed. User:', - context.locals.user.id - ) - throw new ActionError({ - code: 'INTERNAL_SERVER_ERROR', - message: 'Could not determine rate limit window. Please try again.', - }) - } - const timeToWait = formatDistanceStrict(oldestMessageInWindow.createdAt, windowStart) - console.warn( - `Suggestion message rate limit exceeded for user ${context.locals.user.id.toLocaleString()}` - ) - throw new ActionError({ - code: 'TOO_MANY_REQUESTS', - message: `Rate limit exceeded. Please wait ${timeToWait} before sending another message.`, - }) - } - } - // --- Rate Limit Check End --- - - const suggestion = await prisma.serviceSuggestion.findUnique({ - select: { - id: true, - userId: true, - }, - where: { id: input.suggestionId }, - }) - - if (!suggestion) { - throw new ActionError({ - message: 'Suggestion not found', - code: 'BAD_REQUEST', - }) - } - - if (suggestion.userId !== context.locals.user.id) { - throw new ActionError({ - message: 'Not authorized to send messages', - code: 'UNAUTHORIZED', - }) - } - - await prisma.serviceSuggestionMessage.create({ - data: { - content: input.content, - suggestionId: suggestion.id, - userId: context.locals.user.id, - }, - }) - }, - }), -} diff --git a/web/src/assets/fallback-service-image.jpg b/web/src/assets/fallback-service-image.jpg deleted file mode 100644 index 23fa6af..0000000 Binary files a/web/src/assets/fallback-service-image.jpg and /dev/null differ diff --git a/web/src/assets/logo-mini-full.svg b/web/src/assets/logo-mini-full.svg deleted file mode 100644 index 4f02fdd..0000000 --- a/web/src/assets/logo-mini-full.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - \ No newline at end of file diff --git a/web/src/assets/logo-mini.svg b/web/src/assets/logo-mini.svg deleted file mode 100644 index 305bee5..0000000 --- a/web/src/assets/logo-mini.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - \ No newline at end of file diff --git a/web/src/assets/logo-normal.svg b/web/src/assets/logo-normal.svg deleted file mode 100644 index 29d9f3f..0000000 --- a/web/src/assets/logo-normal.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - \ No newline at end of file diff --git a/web/src/assets/logo-small.svg b/web/src/assets/logo-small.svg deleted file mode 100644 index d80894a..0000000 --- a/web/src/assets/logo-small.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - \ No newline at end of file diff --git a/web/src/components/AdminOnly.astro b/web/src/components/AdminOnly.astro deleted file mode 100644 index 03f8727..0000000 --- a/web/src/components/AdminOnly.astro +++ /dev/null @@ -1,11 +0,0 @@ ---- -import type { AstroChildren } from '../lib/astro' - -type Props = { - children: AstroChildren -} - -// ---- - -{!!Astro.locals.user?.admin && } diff --git a/web/src/components/BadgeSmall.astro b/web/src/components/BadgeSmall.astro deleted file mode 100644 index a38a144..0000000 --- a/web/src/components/BadgeSmall.astro +++ /dev/null @@ -1,162 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { tv, type VariantProps } from 'tailwind-variants' - -import type { Polymorphic } from 'astro/types' - -const badge = tv({ - slots: { - base: 'inline-flex h-4 items-center justify-center gap-0.75 rounded-full px-1.25 text-[10px] font-medium', - icon: 'size-3 shrink-0', - text: 'mx-0.25 overflow-hidden text-ellipsis whitespace-nowrap', - }, - variants: { - color: { - red: '', - orange: '', - amber: '', - yellow: '', - lime: '', - green: '', - emerald: '', - teal: '', - cyan: '', - sky: '', - blue: '', - indigo: '', - violet: '', - purple: '', - fuchsia: '', - pink: '', - rose: '', - slate: '', - gray: '', - zinc: '', - neutral: '', - stone: '', - white: '', - black: '', - }, - variant: { - solid: '', - faded: '', - }, - }, - compoundVariants: [ - // Red - { color: 'red', variant: 'solid', class: { base: 'bg-red-500 text-white' } }, - { color: 'red', variant: 'faded', class: { base: 'bg-red-500/30 text-red-300' } }, - // Orange - { color: 'orange', variant: 'solid', class: { base: 'bg-orange-500 text-white' } }, - { color: 'orange', variant: 'faded', class: { base: 'bg-orange-500/30 text-orange-300' } }, - // Amber - { color: 'amber', variant: 'solid', class: { base: 'bg-amber-500 text-black' } }, - { color: 'amber', variant: 'faded', class: { base: 'bg-amber-500/30 text-amber-300' } }, - // Yellow - { color: 'yellow', variant: 'solid', class: { base: 'bg-yellow-500 text-black' } }, - { color: 'yellow', variant: 'faded', class: { base: 'bg-yellow-500/30 text-yellow-300' } }, - // Lime - { color: 'lime', variant: 'solid', class: { base: 'bg-lime-500 text-black' } }, - { color: 'lime', variant: 'faded', class: { base: 'bg-lime-500/30 text-lime-300' } }, - // Green - { color: 'green', variant: 'solid', class: { base: 'bg-green-500 text-black' } }, - { color: 'green', variant: 'faded', class: { base: 'bg-green-500/30 text-green-300' } }, - // Emerald - { color: 'emerald', variant: 'solid', class: { base: 'bg-emerald-500 text-white' } }, - { color: 'emerald', variant: 'faded', class: { base: 'bg-emerald-500/30 text-emerald-300' } }, - // Teal - { color: 'teal', variant: 'solid', class: { base: 'bg-teal-500 text-white' } }, - { color: 'teal', variant: 'faded', class: { base: 'bg-teal-500/30 text-teal-300' } }, - // Cyan - { color: 'cyan', variant: 'solid', class: { base: 'bg-cyan-500 text-white' } }, - { color: 'cyan', variant: 'faded', class: { base: 'bg-cyan-500/30 text-cyan-300' } }, - // Sky - { color: 'sky', variant: 'solid', class: { base: 'bg-sky-500 text-white' } }, - { color: 'sky', variant: 'faded', class: { base: 'bg-sky-500/30 text-sky-300' } }, - // Blue - { color: 'blue', variant: 'solid', class: { base: 'bg-blue-500 text-white' } }, - { color: 'blue', variant: 'faded', class: { base: 'bg-blue-500/30 text-blue-300' } }, - // Indigo - { color: 'indigo', variant: 'solid', class: { base: 'bg-indigo-500 text-white' } }, - { color: 'indigo', variant: 'faded', class: { base: 'bg-indigo-500/30 text-indigo-300' } }, - // Violet - { color: 'violet', variant: 'solid', class: { base: 'bg-violet-500 text-white' } }, - { color: 'violet', variant: 'faded', class: { base: 'bg-violet-500/30 text-violet-300' } }, - // Purple - { color: 'purple', variant: 'solid', class: { base: 'bg-purple-500 text-white' } }, - { color: 'purple', variant: 'faded', class: { base: 'bg-purple-500/30 text-purple-300' } }, - // Fuchsia - { color: 'fuchsia', variant: 'solid', class: { base: 'bg-fuchsia-500 text-white' } }, - { color: 'fuchsia', variant: 'faded', class: { base: 'bg-fuchsia-500/30 text-fuchsia-300' } }, - // Pink - { color: 'pink', variant: 'solid', class: { base: 'bg-pink-500 text-white' } }, - { color: 'pink', variant: 'faded', class: { base: 'bg-pink-500/30 text-pink-300' } }, - // Rose - { color: 'rose', variant: 'solid', class: { base: 'bg-rose-500 text-white' } }, - { color: 'rose', variant: 'faded', class: { base: 'bg-rose-500/30 text-rose-300' } }, - // Slate - { color: 'slate', variant: 'solid', class: { base: 'bg-slate-500 text-white' } }, - { color: 'slate', variant: 'faded', class: { base: 'bg-slate-500/30 text-slate-300' } }, - // Gray - { color: 'gray', variant: 'solid', class: { base: 'bg-gray-500 text-white' } }, - { color: 'gray', variant: 'faded', class: { base: 'bg-gray-500/30 text-gray-300' } }, - // Zinc - { color: 'zinc', variant: 'solid', class: { base: 'bg-zinc-500 text-white' } }, - { color: 'zinc', variant: 'faded', class: { base: 'bg-zinc-500/30 text-zinc-300' } }, - // Neutral - { color: 'neutral', variant: 'solid', class: { base: 'bg-neutral-500 text-white' } }, - { color: 'neutral', variant: 'faded', class: { base: 'bg-neutral-500/30 text-neutral-300' } }, - // Stone - { color: 'stone', variant: 'solid', class: { base: 'bg-stone-500 text-white' } }, - { color: 'stone', variant: 'faded', class: { base: 'bg-stone-500/30 text-stone-300' } }, - // White - { color: 'white', variant: 'solid', class: { base: 'bg-white text-black' } }, - { color: 'white', variant: 'faded', class: { base: 'bg-white-500/30 text-white-300' } }, - // Black - { color: 'black', variant: 'solid', class: { base: 'bg-black text-white' } }, - { color: 'black', variant: 'faded', class: { base: 'bg-black-500/30 text-black-300' } }, - ], - defaultVariants: { - color: 'gray', - variant: 'solid', - }, -}) - -type Props = Polymorphic< - VariantProps & { - as: Tag - icon?: string - text: string - inlineIcon?: boolean - classNames?: { - icon?: string - text?: string - } - } -> - -const { - as: Tag = 'div', - icon: iconName, - text: textContent, - inlineIcon, - classNames, - - color, - variant, - - class: className, - ...props -} = Astro.props - -const { base, icon: iconSlot, text: textSlot } = badge({ color, variant }) ---- - - - { - !!iconName && ( - - ) - } - {textContent} - diff --git a/web/src/components/BadgeStandard.astro b/web/src/components/BadgeStandard.astro deleted file mode 100644 index b1e2032..0000000 --- a/web/src/components/BadgeStandard.astro +++ /dev/null @@ -1,27 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' - -import { cn } from '../lib/cn' - -import type { Polymorphic } from 'astro/types' - -type Props = Polymorphic<{ - as: Tag - icon: string - text: string - inlineIcon?: boolean -}> - -const { icon, text, class: className, inlineIcon, as: Tag = 'div', ...divProps } = Astro.props ---- - - - - {text} - diff --git a/web/src/components/BaseHead.astro b/web/src/components/BaseHead.astro deleted file mode 100644 index efe2bf2..0000000 --- a/web/src/components/BaseHead.astro +++ /dev/null @@ -1,133 +0,0 @@ ---- -import LoadingIndicator from 'astro-loading-indicator/component' -import { Schema } from 'astro-seo-schema' -import { ClientRouter } from 'astro:transitions' - -import { isNotArray } from '../lib/arrays' -import { DEPLOYMENT_MODE } from '../lib/envVariables' - -import HtmxScript from './HtmxScript.astro' -import { makeOgImageUrl } from './OgImage' -import TailwindJsPluggin from './TailwindJsPluggin.astro' - -import type { ComponentProps } from 'astro/types' -import type { WithContext, BreadcrumbList, ListItem } from 'schema-dts' - -export type BreadcrumArray = [ - ...{ - name: string - url: string - }[], - { - name: string - url?: string - }, -] - -type Props = { - pageTitle: string - /** - * Whether to enable htmx. - * - * @default false - */ - htmx?: boolean - /** - * Page meta description - * - * @default 'KYCnot.me helps you find services without KYC for better privacy and control over your data.' - */ - description?: string - /** - * Open Graph image. - * - If `string` is provided, it will be used as the image URL. - * - If `{ template: string, ...props }` is provided, it will be used to generate an Open Graph image based on the template. - */ - ogImage?: Parameters[0] - - schemas?: ComponentProps['item'][] - - breadcrumbs?: BreadcrumArray | BreadcrumArray[] -} - -const { - pageTitle, - htmx = false, - description = 'KYCnot.me helps you find services without KYC for better privacy and control over your data.', - ogImage, - schemas, - breadcrumbs, -} = Astro.props - -const breadcrumbLists = breadcrumbs?.every(Array.isArray) - ? (breadcrumbs as BreadcrumArray[]) - : breadcrumbs?.every(isNotArray) - ? [breadcrumbs] - : [] - -const modeName = DEPLOYMENT_MODE === 'production' ? '' : DEPLOYMENT_MODE === 'staging' ? 'PRE' : 'DEV' -const fullTitle = `${pageTitle} | KYCnot.me ${modeName}` -const ogImageUrl = makeOgImageUrl(ogImage, Astro.url) ---- - - - - -{DEPLOYMENT_MODE === 'development' && } -{DEPLOYMENT_MODE === 'staging' && } - - - - -{fullTitle} - - - - - - - -{!!ogImageUrl && } - - - - - - -{!!ogImageUrl && } - - - - - - - - - -{htmx && } - - -{schemas?.map((item) => )} - - -{ - breadcrumbLists.map((breadcrumbList) => ( - - ({ - '@type': 'ListItem', - position: index + 1, - name: item.name, - item: item.url ? new URL(item.url, Astro.url).href : undefined, - }) satisfies ListItem - ), - } satisfies WithContext - } - /> - )) -} diff --git a/web/src/components/Button.astro b/web/src/components/Button.astro deleted file mode 100644 index 6a8f95a..0000000 --- a/web/src/components/Button.astro +++ /dev/null @@ -1,176 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { tv, type VariantProps } from 'tailwind-variants' - -import type { HTMLAttributes, Polymorphic } from 'astro/types' - -type Props = Polymorphic< - Required, Tag extends 'label' ? 'for' : never>> & - VariantProps & { - as: Tag - label?: string - icon?: string - endIcon?: string - classNames?: { - label?: string - icon?: string - endIcon?: string - } - dataAstroReload?: boolean - children?: never - disabled?: boolean - } -> - -export type ButtonProps = Props - -const button = tv({ - slots: { - base: 'inline-flex items-center justify-center gap-2 rounded-lg border transition-colors duration-100 focus-visible:ring-2 focus-visible:ring-current focus-visible:ring-offset-2 focus-visible:ring-offset-black focus-visible:outline-hidden', - icon: 'size-4 shrink-0', - label: 'text-left whitespace-nowrap', - endIcon: 'size-4 shrink-0', - }, - variants: { - size: { - sm: { - base: 'h-8 px-3 text-sm', - icon: 'size-4', - endIcon: 'size-4', - }, - md: { - base: 'h-9 px-4 text-sm', - icon: 'size-4', - endIcon: 'size-4', - label: 'font-medium', - }, - lg: { - base: 'h-10 px-5 text-base', - icon: 'size-5', - endIcon: 'size-5', - label: 'font-bold tracking-wider uppercase', - }, - }, - color: { - black: { - base: 'border-night-500 bg-night-800 hover:bg-night-900 hover:text-day-200 focus-visible:bg-night-500 text-white/50 focus-visible:text-white focus-visible:ring-white', - }, - white: { - base: 'border-day-300 bg-day-100 hover:bg-day-200 text-black focus-visible:ring-green-500', - }, - gray: { - base: 'border-day-500 bg-day-400 hover:bg-day-500 text-black focus-visible:ring-white', - }, - success: { - base: 'border-green-600 bg-green-500 text-black hover:bg-green-600', - }, - error: { - base: 'border-red-600 bg-red-500 text-white hover:bg-red-600', - }, - warning: { - base: 'border-yellow-600 bg-yellow-500 text-white hover:bg-yellow-600', - }, - info: { - base: 'border-blue-600 bg-blue-500 text-white hover:bg-blue-600', - }, - }, - shadow: { - true: { - base: 'shadow-lg', - }, - }, - disabled: { - true: { - base: 'cursor-not-allowed', - }, - }, - }, - compoundVariants: [ - { - color: 'black', - shadow: true, - class: 'shadow-black/30', - }, - { - color: 'white', - shadow: true, - class: 'shadow-white/30', - }, - { - color: 'gray', - shadow: true, - class: 'shadow-day-500/30', - }, - { - color: 'success', - shadow: true, - class: 'shadow-green-500/30', - }, - { - color: 'error', - shadow: true, - class: 'shadow-red-500/30', - }, - { - color: 'warning', - shadow: true, - class: 'shadow-yellow-500/30', - }, - { - color: 'info', - shadow: true, - class: 'shadow-blue-500/30', - }, - ], - defaultVariants: { - size: 'md', - color: 'black', - shadow: false, - disabled: false, - }, -}) - -const { - as: Tag = 'button' as 'a' | 'button' | 'label', - label, - icon, - endIcon, - size, - color, - shadow, - class: className, - classNames, - role, - dataAstroReload, - disabled, - ...htmlProps -} = Astro.props - -const { - base, - icon: iconSlot, - label: labelSlot, - endIcon: endIconSlot, -} = button({ size, color, shadow, disabled }) - -const ActualTag = disabled && Tag === 'a' ? 'span' : Tag ---- - - - {!!icon && } - {!!label && {label}} - { - !!endIcon && ( - - {endIcon} - - ) - } - diff --git a/web/src/components/Captcha.astro b/web/src/components/Captcha.astro deleted file mode 100644 index a9cb8fa..0000000 --- a/web/src/components/Captcha.astro +++ /dev/null @@ -1,80 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { isInputError, type ActionAccept, type ActionClient } from 'astro:actions' -import { Image } from 'astro:assets' - -import { CAPTCHA_LENGTH, generateCaptcha } from '../lib/captcha' -import { cn } from '../lib/cn' - -import type { HTMLAttributes } from 'astro/types' -import type { z } from 'astro:content' - -type Props< - TAccept extends ActionAccept, - TInputSchema extends z.ZodType, - TAction extends ActionClient, -> = HTMLAttributes<'div'> & { - action: TAction -} - -const { class: className, action: formAction, autofocus, ...htmlProps } = Astro.props - -const result = Astro.getActionResult(formAction) -const inputErrors = isInputError(result?.error) ? result.error.fields : {} - -const captcha = generateCaptcha() ---- - -{/* eslint-disable astro/jsx-a11y/no-autofocus */} - -
-

- This page requires a visual CAPTCHA to ensure you are a human. If you are unable to complete the CAPTCHA, - please email us for assistance. contact@kycnot.me -

- -
- - - - - -
- - { - inputErrors['captcha-value'] && ( -

{inputErrors['captcha-value'].join(', ')}

- ) - } - - -
diff --git a/web/src/components/Chat.astro b/web/src/components/Chat.astro deleted file mode 100644 index 63ec14d..0000000 --- a/web/src/components/Chat.astro +++ /dev/null @@ -1,86 +0,0 @@ ---- -import { isInputError } from 'astro:actions' - -import { SUGGESTION_MESSAGE_CONTENT_MAX_LENGTH } from '../actions/serviceSuggestion' -import Button from '../components/Button.astro' -import Tooltip from '../components/Tooltip.astro' -import { cn } from '../lib/cn' -import { baseInputClassNames } from '../lib/formInputs' - -import ChatMessages, { type ChatMessage } from './ChatMessages.astro' - -import type { ActionInputNoFormData, AnyAction } from '../lib/astroActions' -import type { HTMLAttributes } from 'astro/types' - -export type Props = - HTMLAttributes<'section'> & { - messages: ChatMessage[] - title?: string - userId: number | null - action: TAction - formData?: TAction extends AnyAction - ? ActionInputNoFormData extends Record - ? Omit, 'content'> - : ActionInputNoFormData - : undefined - } - -const { messages, title, userId, action, formData, class: className, ...htmlProps } = Astro.props - -const result = action ? Astro.getActionResult(action) : undefined -const inputErrors = isInputError(result?.error) ? result.error.fields : {} ---- - -
- {!!title &&

{title}

} - - - - { - !!action && ( - <> -
- {typeof formData === 'object' && - formData !== null && - Object.entries(formData).map(([key, value]) => ( - - ))} - - diff --git a/web/src/components/InputWrapper.astro b/web/src/components/InputWrapper.astro deleted file mode 100644 index 463b8af..0000000 --- a/web/src/components/InputWrapper.astro +++ /dev/null @@ -1,74 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { Markdown } from 'astro-remote' - -import { cn } from '../lib/cn' - -import type { AstroChildren } from '../lib/astro' -import type { MarkdownString } from '../lib/markdown' -import type { HTMLAttributes } from 'astro/types' - -type Props = HTMLAttributes<'div'> & { - children: AstroChildren - label: string - name: string - description?: MarkdownString - descriptionLabel?: string - required?: HTMLAttributes<'input'>['required'] - error?: string[] | string - icon?: string - inputId?: string -} - -const { - label, - name, - description, - descriptionLabel, - required, - error, - icon, - class: className, - inputId, - ...htmlProps -} = Astro.props - -const hasError = !!error && error.length > 0 ---- - -
-
- - {icon && } - {required && '*'} - - { - !!descriptionLabel && ( - {descriptionLabel} - ) - } -
- - - - { - hasError && - (typeof error === 'string' ? ( -

{error}

- ) : ( -
    - {error.map((e) => ( -
  • {e}
  • - ))} -
- )) - } - - { - !!description && ( -
- -
- ) - } -
diff --git a/web/src/components/KarmaUnlocksTable.astro b/web/src/components/KarmaUnlocksTable.astro deleted file mode 100644 index 933f4b7..0000000 --- a/web/src/components/KarmaUnlocksTable.astro +++ /dev/null @@ -1,30 +0,0 @@ ---- -import { orderBy } from 'lodash-es' - -import { karmaUnlocks } from '../constants/karmaUnlocks' - -const karmaUnlocksSorted = orderBy(karmaUnlocks, [ - ({ karma }) => (karma >= 0 ? 1 : 2), - ({ karma }) => Math.abs(karma), - 'id', -]) ---- - - - - - - - - - - { - karmaUnlocksSorted.map((unlock) => ( - - - - - )) - } - -
KarmaUnlock
{unlock.karma.toLocaleString()}{unlock.name}
diff --git a/web/src/components/Logo.astro b/web/src/components/Logo.astro deleted file mode 100644 index 24820ed..0000000 --- a/web/src/components/Logo.astro +++ /dev/null @@ -1,65 +0,0 @@ ---- -import type { HTMLAttributes } from 'astro/types' - -type Props = Omit, 'viewBox' | 'xmlns'> & { - variant?: 'mini-full' | 'mini' | 'normal' | 'small' -} - -const { variant = 'normal', ...htmlProps } = Astro.props ---- - -{ - variant === 'normal' && ( - - - - ) -} - -{ - variant === 'small' && ( - - - - ) -} - -{ - variant === 'mini' && ( - - - - ) -} - -{ - variant === 'mini-full' && ( - - - - ) -} diff --git a/web/src/components/OgImage.tsx b/web/src/components/OgImage.tsx deleted file mode 100644 index dae2906..0000000 --- a/web/src/components/OgImage.tsx +++ /dev/null @@ -1,132 +0,0 @@ -import fs from 'node:fs' -import path from 'node:path' - -import { ImageResponse } from '@vercel/og' - -import { urlWithParams } from '../lib/urls' - -import type { Prettify } from 'ts-essentials' - -export type GenericOgImageProps = Partial> - -////////////////////////////////////////////////////// -// NOTE // -// Use this website to create and preview templates // -// https://og-playground.vercel.app/ // -////////////////////////////////////////////////////// - -const defaultOptions = { - width: 1200, - height: 630, - fonts: [ - { - name: 'Inter', - weight: 400, - style: 'normal', - data: fs.readFileSync( - path.resolve( - process.cwd(), - 'node_modules', - '@fontsource', - 'inter', - 'files', - 'inter-latin-400-normal.woff' - ) - ), - }, - { - name: 'Inter', - weight: 700, - style: 'normal', - data: fs.readFileSync( - path.resolve( - process.cwd(), - 'node_modules', - '@fontsource', - 'inter', - 'files', - 'inter-latin-700-normal.woff' - ) - ), - }, - ], -} as const satisfies ConstructorParameters[1] - -export const ogImageTemplates = { - default: () => { - return new ImageResponse( - ( -
- - - -
- ), - defaultOptions - ) - }, - generic: ({ title }: { title?: string }) => { - return new ImageResponse( - ( -
- {title} - - - -
- ), - defaultOptions - ) - }, -} as const satisfies Record ImageResponse | null> - -type OgImageTemplate = keyof typeof ogImageTemplates -type OgImageProps = Parameters<(typeof ogImageTemplates)[T]>[0] -// eslint-disable-next-line @typescript-eslint/sort-type-constituents -export type OgImageAllTemplatesWithGenericProps = { template: OgImageTemplate } & GenericOgImageProps - -export type OgImageAllTemplatesWithProps = Prettify< - { - // eslint-disable-next-line @typescript-eslint/sort-type-constituents - [K in OgImageTemplate]: { template: K } & Omit, 'template'> - }[OgImageTemplate] -> - -export function makeOgImageUrl( - ogImage: OgImageAllTemplatesWithProps | string | undefined, - baseUrl: URL | string -) { - return typeof ogImage === 'string' - ? new URL(ogImage, baseUrl).href - : urlWithParams(new URL('/ogimage.png', baseUrl), ogImage ?? {}) -} diff --git a/web/src/components/Pagination.astro b/web/src/components/Pagination.astro deleted file mode 100644 index 48d920e..0000000 --- a/web/src/components/Pagination.astro +++ /dev/null @@ -1,134 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' - -import { cn } from '../lib/cn' -import { createPageUrl } from '../lib/urls' - -import type { HTMLAttributes } from 'astro/types' - -type Props = HTMLAttributes<'nav'> & { - currentPage: number - totalPages: number - currentUrl?: URL | string - sortSeed?: string -} - -const { - currentPage, - totalPages, - currentUrl = Astro.url, - sortSeed, - class: className, - ...navProps -} = Astro.props - -const prevPage = currentPage > 1 ? currentPage - 1 : null -const nextPage = currentPage < totalPages ? currentPage + 1 : null - -const getVisiblePages = () => { - const pages: (number | '...')[] = [] - - if (totalPages <= 9) { - return Array.from({ length: totalPages }, (_, i) => i + 1) - } - - // Always show first page - pages.push(1) - - if (currentPage > 4) { - pages.push('...') - } - - // Calculate range around current page - let rangeStart = Math.max(2, currentPage - 2) - let rangeEnd = Math.min(totalPages - 1, currentPage + 2) - - // Adjust range if at the start or end - if (currentPage <= 4) { - rangeEnd = 6 - } - if (currentPage >= totalPages - 3) { - rangeStart = totalPages - 5 - } - - // Add range numbers - for (let i = rangeStart; i <= rangeEnd; i++) { - pages.push(i) - } - - if (currentPage < totalPages - 3) { - pages.push('...') - } - - // Always show last page - pages.push(totalPages) - - return pages -} -const PrevTag = prevPage ? 'a' : 'span' -const NextTag = nextPage ? 'a' : 'span' ---- - - diff --git a/web/src/components/PillsRadioGroup.astro b/web/src/components/PillsRadioGroup.astro deleted file mode 100644 index a41a37a..0000000 --- a/web/src/components/PillsRadioGroup.astro +++ /dev/null @@ -1,41 +0,0 @@ ---- -import { cn } from '../lib/cn' - -import type { HTMLAttributes } from 'astro/types' - -type Props = HTMLAttributes<'div'> & { - name: string - options: { - value: HTMLAttributes<'input'>['value'] - label: string - }[] - selectedValue?: string | null -} - -const { name, options, selectedValue, class: className, ...rest } = Astro.props ---- - -
- { - options.map((option) => ( - - )) - } -
diff --git a/web/src/components/ScoreGauge.astro b/web/src/components/ScoreGauge.astro deleted file mode 100644 index 568b4c1..0000000 --- a/web/src/components/ScoreGauge.astro +++ /dev/null @@ -1,175 +0,0 @@ ---- -import { Schema } from 'astro-seo-schema' - -import { cn } from '../lib/cn' -import { interpolate } from '../lib/numbers' -import { KYCNOTME_SCHEMA_MINI } from '../lib/schema' -import { transformCase } from '../lib/strings' - -import type { HTMLAttributes } from 'astro/types' -import type { Review, WithContext } from 'schema-dts' - -export type Props = HTMLAttributes<'div'> & { - score: number - label: string - total?: number - itemReviewedId?: string -} - -const { score, label, total = 100, class: className, itemReviewedId, ...htmlProps } = Astro.props - -const progress = total === 0 ? 0 : Math.min(Math.max(score / total, 0), 1) - -function makeScoreInfo(score: number, total: number) { - const formattedScore = Math.round(score).toLocaleString() - const angle = interpolate(progress, -100, 100) - const n = score / total - - if (n > 1) return { text: 'Excellent', step: 5, formattedScore, angle: 100 } - if (n >= 0.9 && n <= 1) return { text: 'Excellent', step: 5, formattedScore, angle } - if (n >= 0.8 && n < 0.9) return { text: 'Very Good', step: 5, formattedScore, angle } - if (n >= 0.6 && n < 0.8) return { text: 'Good', step: 4, formattedScore, angle } - if (n >= 0.45 && n < 0.6) return { text: 'Average', step: 3, formattedScore, angle } - if (n >= 0.4 && n < 0.45) return { text: 'Average', step: 3, formattedScore, angle: angle + 5 } - if (n >= 0.2 && n < 0.4) return { text: 'Bad', step: 2, formattedScore, angle: angle + 5 } - if (n >= 0.1 && n < 0.2) return { text: 'Very Bad', step: 1, formattedScore, angle } - if (n >= 0 && n < 0.1) return { text: 'Terrible', step: 1, formattedScore, angle } - if (n < 0) return { text: 'Terrible', step: 1, formattedScore, angle: -100 } - - return { text: '', step: undefined, formattedScore, angle: undefined } -} - -const { text, step, angle, formattedScore } = makeScoreInfo(score, total) ---- - -{ - !!itemReviewedId && ( - - } - /> - ) -} - -
-
2, - })} - > - {formattedScore} -
- -
- {label} -
- - {text} - - -
diff --git a/web/src/components/ScoreSquare.astro b/web/src/components/ScoreSquare.astro deleted file mode 100644 index 84b0a5e..0000000 --- a/web/src/components/ScoreSquare.astro +++ /dev/null @@ -1,106 +0,0 @@ ---- -import { Schema } from 'astro-seo-schema' - -import { cn } from '../lib/cn' -import { KYCNOTME_SCHEMA_MINI } from '../lib/schema' -import { transformCase } from '../lib/strings' - -import type { HTMLAttributes } from 'astro/types' - -export type Props = HTMLAttributes<'div'> & { - score: number - label: string - total?: number - itemReviewedId?: string -} - -const { score, label, total = 10, class: className, itemReviewedId, ...htmlProps } = Astro.props - -export function makeOverallScoreInfo(score: number, total = 10) { - const classNamesByColor = { - red: 'bg-score-1 text-black', - orange: 'bg-score-2 text-black', - yellow: 'bg-score-3 text-black', - blue: 'bg-score-4 text-black', - green: 'bg-score-5 text-black', - } as const satisfies Record - - const formattedScore = Math.round(score).toLocaleString() - const n = score / total - - if (n > 1) return { text: '', classNameBg: classNamesByColor.green, formattedScore } - if (n >= 0.9 && n <= 1) return { text: 'Excellent', classNameBg: classNamesByColor.green, formattedScore } - if (n >= 0.8 && n < 0.9) return { text: 'Very Good', classNameBg: classNamesByColor.blue, formattedScore } - if (n >= 0.7 && n < 0.8) return { text: 'Good', classNameBg: classNamesByColor.blue, formattedScore } - if (n >= 0.6 && n < 0.7) return { text: 'Okay', classNameBg: classNamesByColor.yellow, formattedScore } - if (n >= 0.5 && n < 0.6) { - return { text: 'Acceptable', classNameBg: classNamesByColor.yellow, formattedScore } - } - if (n >= 0.4 && n < 0.5) return { text: 'Bad', classNameBg: classNamesByColor.orange, formattedScore } - if (n >= 0.3 && n < 0.4) return { text: 'Very Bad', classNameBg: classNamesByColor.orange, formattedScore } - if (n >= 0.2 && n < 0.3) return { text: 'Really Bad', classNameBg: classNamesByColor.red, formattedScore } - if (n >= 0 && n < 0.2) return { text: 'Terrible', classNameBg: classNamesByColor.red, formattedScore } - return { text: '', classNameBg: undefined, formattedScore } -} - -const { text, classNameBg, formattedScore } = makeOverallScoreInfo(score, total) ---- - -
- { - !!itemReviewedId && ( - - ) - } - - -
2, - } - )} - > - - {formattedScore} - -
- -
- {label} -
- - {text} -
diff --git a/web/src/components/ServiceCard.astro b/web/src/components/ServiceCard.astro deleted file mode 100644 index d4ca06f..0000000 --- a/web/src/components/ServiceCard.astro +++ /dev/null @@ -1,155 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { Image } from 'astro:assets' - -import defaultImage from '../assets/fallback-service-image.jpg' -import { currencies } from '../constants/currencies' -import { verificationStatusesByValue } from '../constants/verificationStatus' -import { cn } from '../lib/cn' -import { transformCase } from '../lib/strings' - -import { makeOverallScoreInfo } from './ScoreSquare.astro' -import Tooltip from './Tooltip.astro' - -import type { Prisma } from '@prisma/client' -import type { HTMLAttributes } from 'astro/types' - -type Props = HTMLAttributes<'a'> & { - inlineIcons?: boolean - withoutLink?: boolean - service: Prisma.ServiceGetPayload<{ - select: { - name: true - slug: true - description: true - overallScore: true - kycLevel: true - imageUrl: true - verificationStatus: true - acceptedCurrencies: true - categories: { - select: { - name: true - icon: true - } - } - } - }> -} - -const { - inlineIcons = false, - service: { - name = 'Unnamed Service', - slug, - description, - overallScore, - - kycLevel, - imageUrl, - categories, - verificationStatus, - acceptedCurrencies, - }, - class: className, - withoutLink = false, - ...aProps -} = Astro.props - -const statusIcon = { - ...verificationStatusesByValue, - APPROVED: undefined, -}[verificationStatus] - -const Element = withoutLink ? 'div' : 'a' - -const overallScoreInfo = makeOverallScoreInfo(overallScore) ---- - - - -
- {name - -
-

- {name}{ - statusIcon && ( - - - - ) - } -

-
-
- { - categories.map((category) => ( - - - {category.name} - - )) - } -
-
-
- -
-

- {description} -

-
- -
- - {overallScoreInfo.formattedScore} - - - - KYC  {kycLevel.toLocaleString()} - - -
- { - currencies.map((currency) => { - const isAccepted = acceptedCurrencies.includes(currency.id) - - return ( - - - - ) - }) - } -
-
-
diff --git a/web/src/components/ServiceFiltersPill.astro b/web/src/components/ServiceFiltersPill.astro deleted file mode 100644 index 04fd1d6..0000000 --- a/web/src/components/ServiceFiltersPill.astro +++ /dev/null @@ -1,36 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' - -import { cn } from '../lib/cn' - -import type { HTMLAttributes } from 'astro/types' - -type Props = HTMLAttributes<'a'> & { - text: string - searchParamName: string - searchParamValue?: string - icon?: string - iconClass?: string -} - -const { text, searchParamName, searchParamValue, icon, iconClass, class: className, ...aProps } = Astro.props - -const makeUrlWithoutFilter = (filter: string, value?: string) => { - const url = new URL(Astro.url) - url.searchParams.delete(filter, value) - return url.toString() -} ---- - - - {icon && } - {text} - - diff --git a/web/src/components/ServiceLinkButton.astro b/web/src/components/ServiceLinkButton.astro deleted file mode 100644 index 2b77040..0000000 --- a/web/src/components/ServiceLinkButton.astro +++ /dev/null @@ -1,132 +0,0 @@ ---- -import { z } from 'astro/zod' -import { Icon } from 'astro-icon/components' - -import { networksBySlug } from '../constants/networks' -import { cn } from '../lib/cn' - -import type { HTMLAttributes } from 'astro/types' - -type Props = Omit, 'href' | 'rel' | 'target'> & { - url: string - referral: string | null - enableMinWidth?: boolean -} - -const { url: baseUrl, referral, class: className, enableMinWidth = false, ...htmlProps } = Astro.props - -function makeLink(url: string, referral: string | null) { - const hostname = new URL(url).hostname - const urlWithReferral = url + (referral ?? '') - - const onionMatch = /^(?:https?:\/\/)?(.{0,10}).*?(.{0,10})(\.onion)$/.exec(hostname) - if (onionMatch) { - return { - type: 'onion' as const, - url: urlWithReferral, - textBits: onionMatch.length - ? [ - { - style: 'normal' as const, - text: onionMatch[1] ?? '', - }, - { - style: 'irrelevant' as const, - text: '...', - }, - { - style: 'normal' as const, - text: onionMatch[2] ?? '', - }, - { - style: 'irrelevant' as const, - text: onionMatch[3] ?? '', - }, - ] - : [ - { - style: 'normal' as const, - text: hostname, - }, - ], - icon: networksBySlug.onion.icon, - } - } - - const i2pMatch = /^(?:https?:\/\/)?(.{0,10}).*?(.{0,8})((?:\.b32)?\.i2p)$/.exec(hostname) - if (i2pMatch) { - return { - type: 'i2p' as const, - url: urlWithReferral, - textBits: i2pMatch.length - ? [ - { - style: 'normal' as const, - text: i2pMatch[1] ?? '', - }, - { - style: 'irrelevant' as const, - text: '...', - }, - { - style: 'normal' as const, - text: i2pMatch[2] ?? '', - }, - { - style: 'irrelevant' as const, - text: i2pMatch[3] ?? '', - }, - ] - : [ - { - style: 'normal' as const, - text: hostname, - }, - ], - icon: networksBySlug.i2p.icon, - } - } - - return { - type: 'clearnet' as const, - url: urlWithReferral, - textBits: [ - { - style: 'normal' as const, - text: hostname.replace(/^www\./, ''), - }, - ], - icon: networksBySlug.clearnet.icon, - } -} - -const link = makeLink(baseUrl, referral) - -if (!z.string().url().safeParse(link.url).success) { - console.error(`Invalid service URL with referral: ${link.url}`) -} ---- - - - - - { - link.textBits.map((textBit) => ( - {textBit.text} - )) - } - - - diff --git a/web/src/components/ServicesFilters.astro b/web/src/components/ServicesFilters.astro deleted file mode 100644 index 058a77a..0000000 --- a/web/src/components/ServicesFilters.astro +++ /dev/null @@ -1,497 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' - -import { kycLevels } from '../constants/kycLevels' -import { cn } from '../lib/cn' -import { type ServicesFiltersObject, type ServicesFiltersOptions } from '../pages/index.astro' - -import Button from './Button.astro' -import PillsRadioGroup from './PillsRadioGroup.astro' -import { makeOverallScoreInfo } from './ScoreSquare.astro' -import Tooltip from './Tooltip.astro' - -import type { HTMLAttributes } from 'astro/types' - -export type Props = HTMLAttributes<'form'> & { - filters: ServicesFiltersObject - hasDefaultFilters: boolean - options: ServicesFiltersOptions - searchResultsId: string - showFiltersId: string -} - -const { - filters, - hasDefaultFilters, - options, - searchResultsId, - showFiltersId, - class: className, - ...formProps -} = Astro.props ---- - - verification.default) - .map((verification) => verification.slug)} - {...formProps} - class={cn('', className)} -> -
-

FILTERS

- Clear all -
- - -
- - - - -

- - Ties randomly sorted -

-
- - -
- - - - -
- - -
- Type - -
    - { - options.categories?.map((category) => ( -
  • - -
  • - )) - } -
- { - options.categories.filter((category) => category.showAlways).length < options.categories.length && ( - <> - - - - ) - } -
- - -
- Verification -
- { - options.verification.map((verification) => ( - - )) - } -
-
- - -
-
- Currencies - -
-
- { - options.currencies.map((currency) => ( - - )) - } -
-
- - -
- Networks -
- { - options.network.map((network) => ( - - )) - } -
-
- - -
- - - -
- -
-
- { - kycLevels.map((level) => ( - - {level.value} - - - )) - } -
-
- - -
- - - -
- -
-
- - - - 1 - - - 2 - - - 3 - - - 4 - -
-
- - -
-
- Attributes - -
- { - options.attributesByCategory.map(({ category, attributes }) => ( -
- {category} - -
    - {attributes.map((attribute) => { - const inputName = `attr-${attribute.id}` as const - const yesId = `attr-${attribute.id}=yes` as const - const noId = `attr-${attribute.id}=no` as const - const emptyId = `attr-${attribute.id}=empty` as const - const isPositive = attribute.type === 'GOOD' || attribute.type === 'INFO' - - return ( -
  • -
    - - {attribute.title} ({attribute._count?.services}) - - - - - - - - -
    -
  • - ) - })} -
- {attributes.filter((attribute) => attribute.showAlways).length < attributes.length && ( - <> - - - - )} -
- )) - } -
- - -
- - - -
- -
-
- { - [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10].map((score) => { - const info = makeOverallScoreInfo(score) - return ( - - {score.toLocaleString()} - - ) - }) - } -
-
- - - -
-
- - - diff --git a/web/src/components/ServicesSearchResults.astro b/web/src/components/ServicesSearchResults.astro deleted file mode 100644 index e6a8e74..0000000 --- a/web/src/components/ServicesSearchResults.astro +++ /dev/null @@ -1,141 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' - -import { cn } from '../lib/cn' -import { pluralize } from '../lib/pluralize' -import { createPageUrl } from '../lib/urls' - -import Button from './Button.astro' -import ServiceCard from './ServiceCard.astro' - -import type { ServicesFiltersObject } from '../pages/index.astro' -import type { ComponentProps, HTMLAttributes } from 'astro/types' - -type Props = HTMLAttributes<'div'> & { - hasDefaultFilters?: boolean - services: ComponentProps['service'][] | undefined - currentPage?: number - total: number - pageSize: number - sortSeed?: string - filters: ServicesFiltersObject - hadToIncludeCommunityContributed: boolean -} - -const { - services, - hasDefaultFilters = false, - currentPage = 1, - total, - pageSize, - sortSeed, - class: className, - filters, - hadToIncludeCommunityContributed, - ...divProps -} = Astro.props - -const hasScams = filters.verification.includes('VERIFICATION_FAILED') -const hasCommunityContributed = - // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - filters.verification.includes('COMMUNITY_CONTRIBUTED') || hadToIncludeCommunityContributed - -const totalPages = Math.ceil(total / pageSize) || 1 ---- - -
-
- - {total.toLocaleString()} - {pluralize('result', total)} - - - - Loading... - - -
- - { - hasScams && hasCommunityContributed && ( -
- - - Showing SCAM and unverified community-contributed services. - {hadToIncludeCommunityContributed && 'Because there were no other results.'} -
- ) - } - - { - hasScams && !hasCommunityContributed && ( -
- - Showing SCAM services! -
- ) - } - - { - !hasScams && hasCommunityContributed && ( -
- - - {hadToIncludeCommunityContributed - ? 'Showing unverified community-contributed services, because there were no other results. Some might be scams.' - : 'Showing unverified community-contributed services, some might be scams.'} -
- ) - } - - { - !services || services.length === 0 ? ( -
- -

No services found

-

Try adjusting your filters to find more services

- - Clear filters - -
- ) : ( - <> -
- {services.map((service, i) => ( - - ))} -
- -
-
- - Loading more services... -
-
- - ) - } -
diff --git a/web/src/components/SortArrowIcon.astro b/web/src/components/SortArrowIcon.astro deleted file mode 100644 index f376ae3..0000000 --- a/web/src/components/SortArrowIcon.astro +++ /dev/null @@ -1,25 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' - -import { cn } from '../lib/cn' - -type Props = { - active: boolean - sortOrder: 'asc' | 'desc' | null | undefined - class?: string -} - -const { active, sortOrder, class: className }: Props = Astro.props ---- - -{ - active && sortOrder ? ( - sortOrder === 'asc' ? ( - - ) : ( - - ) - ) : ( - - ) -} diff --git a/web/src/components/TailwindJsPluggin.astro b/web/src/components/TailwindJsPluggin.astro deleted file mode 100644 index 585f3d2..0000000 --- a/web/src/components/TailwindJsPluggin.astro +++ /dev/null @@ -1,11 +0,0 @@ ---- - ---- - - diff --git a/web/src/components/TimeFormatted.astro b/web/src/components/TimeFormatted.astro deleted file mode 100644 index 55dd983..0000000 --- a/web/src/components/TimeFormatted.astro +++ /dev/null @@ -1,16 +0,0 @@ ---- -import { omit } from 'lodash-es' - -import { formatDateShort, type FormatDateShortOptions } from '../lib/timeAgo' - -import type { HTMLAttributes } from 'astro/types' - -type Props = FormatDateShortOptions & - Omit, keyof FormatDateShortOptions | 'datetime'> & { - date: Date - } - -const { date, ...props } = Astro.props ---- - - diff --git a/web/src/components/Tooltip.astro b/web/src/components/Tooltip.astro deleted file mode 100644 index eac5576..0000000 --- a/web/src/components/Tooltip.astro +++ /dev/null @@ -1,93 +0,0 @@ ---- -import { cn } from '../lib/cn' - -import type { AstroChildren, AstroComponent, PolymorphicComponent } from '../lib/astro' -import type { HTMLTag } from 'astro/types' - -type Props = PolymorphicComponent & { - children: AstroChildren - text: string - classNames?: { - tooltip?: string - } - color?: 'black' | 'white' | 'zinc-700' - position?: 'bottom' | 'left' | 'right' | 'top' - enabled?: boolean -} - -const { - as: Component = 'span', - text, - classNames, - class: className, - color = 'zinc-700', - position = 'top', - enabled = true, - ...htmlProps -} = Astro.props ---- - - - - { - enabled && ( - - ) - } - diff --git a/web/src/components/VerificationWarningBanner.astro b/web/src/components/VerificationWarningBanner.astro deleted file mode 100644 index 2f3115e..0000000 --- a/web/src/components/VerificationWarningBanner.astro +++ /dev/null @@ -1,69 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { differenceInDays, isPast } from 'date-fns' - -import { verificationStatusesByValue } from '../constants/verificationStatus' -import { cn } from '../lib/cn' - -import TimeFormatted from './TimeFormatted.astro' - -import type { Prisma } from '@prisma/client' - -const RECENTLY_ADDED_DAYS = 7 - -type Props = { - service: Prisma.ServiceGetPayload<{ - select: { - verificationStatus: true - verificationProofMd: true - verificationSummary: true - listedAt: true - createdAt: true - } - }> -} - -const { service } = Astro.props - -const listedDate = service.listedAt ?? service.createdAt -const wasRecentlyAdded = isPast(listedDate) && differenceInDays(new Date(), listedDate) < RECENTLY_ADDED_DAYS ---- - -{ - service.verificationStatus === 'VERIFICATION_FAILED' ? ( -
-

- - This service is a SCAM! - {!!service.verificationProofMd && ( - - Proof - - )} -

- {!!service.verificationSummary && ( -
{service.verificationSummary}
- )} -
- ) : service.verificationStatus === 'COMMUNITY_CONTRIBUTED' ? ( -
- - Community-contributed. Information not reviewed. -
- ) : wasRecentlyAdded ? ( -
- This service was {service.listedAt === null ? 'added ' : 'listed '}{' '} - - {service.verificationStatus !== 'VERIFICATION_SUCCESS' && ' and it is not verified'}. Proceed with - caution. -
- ) : service.verificationStatus !== 'VERIFICATION_SUCCESS' ? ( -
- - Basic checks passed, but not fully verified. -
- ) : null -} diff --git a/web/src/constants/accountStatusChange.ts b/web/src/constants/accountStatusChange.ts deleted file mode 100644 index 7c2eaee..0000000 --- a/web/src/constants/accountStatusChange.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { AccountStatusChange } from '@prisma/client' - -type AccountStatusChangeInfo = { - value: T - label: string - notificationTitle: string -} - -export const { - dataArray: accountStatusChanges, - dataObject: accountStatusChangesById, - getFn: getAccountStatusChangeInfo, - zodEnumById: accountStatusChangesZodEnumById, -} = makeHelpersForOptions( - 'value', - (value): AccountStatusChangeInfo => ({ - value, - label: value ? transformCase(value.replaceAll('_', ' '), 'title') : String(value), - notificationTitle: value ? transformCase(value.replaceAll('_', ' '), 'title') : String(value), - }), - [ - { - value: 'ADMIN_TRUE', - label: 'Admin role granted', - notificationTitle: 'Admin role granted', - }, - { - value: 'ADMIN_FALSE', - label: 'Admin role revoked', - notificationTitle: 'Admin role revoked', - }, - { - value: 'VERIFIED_TRUE', - label: 'Account verified', - notificationTitle: 'Your account is now verified', - }, - { - value: 'VERIFIED_FALSE', - label: 'Account unverified', - notificationTitle: 'Your account is no longer verified', - }, - { - value: 'VERIFIER_TRUE', - label: 'Verifier role granted', - notificationTitle: 'Verifier role granted', - }, - { - value: 'VERIFIER_FALSE', - label: 'Verifier role revoked', - notificationTitle: 'Verifier role revoked', - }, - { - value: 'SPAMMER_TRUE', - label: 'Banned', - notificationTitle: 'Your account has been banned', - }, - { - value: 'SPAMMER_FALSE', - label: 'Unbanned', - notificationTitle: 'Your account is no longer banned', - }, - ] as const satisfies AccountStatusChangeInfo[] -) - -export type AccountStatusChangeType = (typeof accountStatusChanges)[number]['value'] diff --git a/web/src/constants/attributeCategories.ts b/web/src/constants/attributeCategories.ts deleted file mode 100644 index c6c135a..0000000 --- a/web/src/constants/attributeCategories.ts +++ /dev/null @@ -1,60 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { AttributeCategory } from '@prisma/client' - -type AttributeCategoryInfo = { - value: T - slug: string - label: string - icon: string - classNames: { - icon: string - } - order: number -} - -export const { - dataArray: attributeCategories, - dataObject: attributeCategoriesById, - getFn: getAttributeCategoryInfo, - getFnSlug: getAttributeCategoryInfoBySlug, - zodEnumBySlug: attributeCategoriesZodEnumBySlug, - zodEnumById: attributeCategoriesZodEnumById, - keyToSlug: attributeCategoryIdToSlug, - slugToKey: attributeCategorySlugToId, -} = makeHelpersForOptions( - 'value', - (value): AttributeCategoryInfo => ({ - value, - slug: value ? value.toLowerCase() : '', - label: value ? transformCase(value, 'title') : String(value), - icon: 'ri:shield-fill', - classNames: { - icon: 'text-current/60', - }, - order: Infinity, - }), - [ - { - value: 'PRIVACY', - slug: 'privacy', - label: 'Privacy', - icon: 'ri:shield-user-fill', - classNames: { - icon: 'text-blue-500', - }, - order: 1, - }, - { - value: 'TRUST', - slug: 'trust', - label: 'Trust', - icon: 'ri:shield-check-fill', - classNames: { - icon: 'text-green-500', - }, - order: 2, - }, - ] as const satisfies AttributeCategoryInfo[] -) diff --git a/web/src/constants/attributeTypes.ts b/web/src/constants/attributeTypes.ts deleted file mode 100644 index d317947..0000000 --- a/web/src/constants/attributeTypes.ts +++ /dev/null @@ -1,110 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { AttributeType } from '@prisma/client' - -type AttributeTypeInfo = { - value: T - slug: string - label: string - icon: string - order: number - classNames: { - container: string - subcontainer: string - text: string - textLight: string - icon: string - button: string - } -} - -export const { - dataArray: attributeTypes, - dataObject: attributeTypesById, - getFn: getAttributeTypeInfo, - getFnSlug: getAttributeTypeInfoBySlug, - zodEnumBySlug: attributeTypesZodEnumBySlug, - zodEnumById: attributeTypesZodEnumById, - keyToSlug: attributeTypeIdToSlug, - slugToKey: attributeTypeSlugToId, -} = makeHelpersForOptions( - 'value', - (value): AttributeTypeInfo => ({ - value, - slug: value ? value.toLowerCase() : '', - label: value ? transformCase(value, 'title') : String(value), - icon: 'ri:question-line', - order: Infinity, - classNames: { - container: 'bg-current/30', - subcontainer: 'bg-current/5 border-current/30', - text: 'text-current/60', - textLight: 'text-current/40', - icon: 'text-current/60', - button: 'bg-current/80 text-current/100 hover:bg-current/50', - }, - }), - [ - { - value: 'BAD', - slug: 'bad', - label: 'Bad', - icon: 'ri:close-line', - order: 1, - classNames: { - container: 'bg-red-600/30', - subcontainer: 'bg-red-600/5 border-red-600/30', - text: 'text-red-200', - textLight: 'text-red-100', - icon: 'text-red-400', - button: 'bg-red-200 text-red-900 hover:bg-red-50', - }, - }, - { - value: 'WARNING', - slug: 'warning', - label: 'Warning', - icon: 'ri:alert-line', - order: 2, - classNames: { - container: 'bg-yellow-600/30', - subcontainer: 'bg-yellow-600/5 border-yellow-600/30', - text: 'text-yellow-200', - textLight: 'text-amber-100', - icon: 'text-yellow-400', - button: 'bg-amber-100 text-amber-900 hover:bg-amber-50', - }, - }, - { - value: 'GOOD', - slug: 'good', - label: 'Good', - icon: 'ri:check-line', - order: 3, - classNames: { - container: 'bg-green-600/30', - subcontainer: 'bg-green-600/5 border-green-600/30', - text: 'text-green-200', - textLight: 'text-green-100', - icon: 'text-green-400', - button: 'bg-green-200 text-green-900 hover:bg-green-50', - }, - }, - { - value: 'INFO', - slug: 'info', - label: 'Info', - icon: 'ri:information-line', - order: 4, - classNames: { - container: 'bg-blue-600/30', - subcontainer: 'bg-blue-600/5 border-blue-600/30', - text: 'text-blue-200', - textLight: 'text-blue-100', - icon: 'text-blue-400', - button: 'bg-blue-200 text-blue-900 hover:bg-blue-50', - }, - }, - ] as const satisfies AttributeTypeInfo[] -) diff --git a/web/src/constants/characters.ts b/web/src/constants/characters.ts deleted file mode 100644 index 5035758..0000000 --- a/web/src/constants/characters.ts +++ /dev/null @@ -1,92 +0,0 @@ -export const SEARCH_PARAM_CHARACTERS_NO_ESCAPE = [ - 'a', - 'b', - 'c', - 'd', - 'e', - 'f', - 'g', - 'h', - 'i', - 'j', - 'k', - 'l', - 'm', - 'n', - 'o', - 'p', - 'q', - 'r', - 's', - 't', - 'u', - 'v', - 'w', - 'x', - 'y', - 'z', - 'A', - 'B', - 'C', - 'D', - 'E', - 'F', - 'G', - 'H', - 'I', - 'J', - 'K', - 'L', - 'M', - 'N', - 'O', - 'P', - 'Q', - 'R', - 'S', - 'T', - 'U', - 'V', - 'W', - 'X', - 'Y', - 'Z', - '0', - '1', - '2', - '3', - '4', - '5', - '6', - '7', - '8', - '9', - '-', - '_', - '.', - '~', -] as const - -export const LOWERCASE_VOWEL_CHARACTERS = ['a', 'e', 'i', 'o', 'u'] as const -export const LOWERCASE_CONSONANT_CHARACTERS = [ - 'b', - 'c', - 'd', - 'f', - 'g', - 'h', - 'j', - 'k', - 'l', - 'm', - 'n', - 'p', - 'r', - 's', - 't', - 'v', - 'w', - 'y', - 'z', -] as const -export const DIGIT_CHARACTERS = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'] as const diff --git a/web/src/constants/commentStatus.ts b/web/src/constants/commentStatus.ts deleted file mode 100644 index 3c66f1c..0000000 --- a/web/src/constants/commentStatus.ts +++ /dev/null @@ -1,57 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { CommentStatus } from '@prisma/client' - -type CommentStatusInfo = { - id: T - icon: string - label: string - creativeWorkStatus: string | undefined -} - -export const { - dataArray: commentStatus, - dataObject: commentStatusById, - getFn: getCommentStatusInfo, -} = makeHelpersForOptions( - 'id', - (id): CommentStatusInfo => ({ - id, - icon: 'ri:question-line', - label: id ? transformCase(id, 'title') : String(id), - creativeWorkStatus: undefined, - }), - [ - { - id: 'PENDING', - icon: 'ri:question-line', - label: 'Pending', - creativeWorkStatus: 'Deleted', - }, - { - id: 'HUMAN_PENDING', - icon: 'ri:question-line', - label: 'Pending 2', - creativeWorkStatus: 'Deleted', - }, - { - id: 'VERIFIED', - icon: 'ri:check-line', - label: 'Verified', - creativeWorkStatus: 'Verified', - }, - { - id: 'REJECTED', - icon: 'ri:close-line', - label: 'Rejected', - creativeWorkStatus: 'Deleted', - }, - { - id: 'APPROVED', - icon: 'ri:check-line', - label: 'Approved', - creativeWorkStatus: 'Active', - }, - ] as const satisfies CommentStatusInfo[] -) diff --git a/web/src/constants/commentStatusChange.ts b/web/src/constants/commentStatusChange.ts deleted file mode 100644 index d28ae03..0000000 --- a/web/src/constants/commentStatusChange.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { CommentStatusChange } from '@prisma/client' - -type CommentStatusChangeInfo = { - value: T - label: string - notificationTitle: string -} - -export const { - dataArray: commentStatusChanges, - dataObject: commentStatusChangesById, - getFn: getCommentStatusChangeInfo, - zodEnumById: commentStatusChangesZodEnumById, -} = makeHelpersForOptions( - 'value', - (value): CommentStatusChangeInfo => ({ - value, - label: value ? transformCase(value.replaceAll('_', ' '), 'title') : String(value), - notificationTitle: value ? transformCase(value.replaceAll('_', ' '), 'title') : String(value), - }), - [ - { - value: 'MARKED_AS_SPAM', - label: 'Marked as spam', - notificationTitle: 'was marked as spam', - }, - { - value: 'UNMARKED_AS_SPAM', - label: 'Unmarked as spam', - notificationTitle: 'is no longer marked as spam', - }, - { - value: 'MARKED_FOR_ADMIN_REVIEW', - label: 'Marked for admin review', - notificationTitle: 'was marked for admin review', - }, - { - value: 'UNMARKED_FOR_ADMIN_REVIEW', - label: 'Unmarked for admin review', - notificationTitle: 'is no longer marked for admin review', - }, - { - value: 'STATUS_CHANGED_TO_APPROVED', - label: 'Approved', - notificationTitle: 'was approved', - }, - { - value: 'STATUS_CHANGED_TO_VERIFIED', - label: 'Verified', - notificationTitle: 'was verified', - }, - { - value: 'STATUS_CHANGED_TO_REJECTED', - label: 'Rejected', - notificationTitle: 'was rejected', - }, - { - value: 'STATUS_CHANGED_TO_PENDING', - label: 'Pending', - notificationTitle: 'is now pending', - }, - ] as const satisfies CommentStatusChangeInfo[] -) - -export type CommentStatusChangeType = (typeof commentStatusChanges)[number]['value'] diff --git a/web/src/constants/commentStatusFilters.ts b/web/src/constants/commentStatusFilters.ts deleted file mode 100644 index d6c41c8..0000000 --- a/web/src/constants/commentStatusFilters.ts +++ /dev/null @@ -1,143 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { Prisma } from '@prisma/client' - -type CommentStatusFilterInfo = { - value: T - label: string - whereClause: Prisma.CommentWhereInput - styles: { - filter: string - badge: string - } -} - -export const { - dataArray: commentStatusFilters, - dataObject: commentStatusFiltersById, - getFn: getCommentStatusFilterInfo, - zodEnumById: commentStatusFiltersZodEnum, -} = makeHelpersForOptions( - 'value', - (value): CommentStatusFilterInfo => ({ - value, - label: value ? transformCase(value, 'title') : String(value), - whereClause: {}, - styles: { - filter: 'border-zinc-700 transition-colors hover:border-green-500/50', - badge: '', - }, - }), - [ - { - label: 'All', - value: 'all', - whereClause: {}, - styles: { - filter: 'border-green-500 bg-green-500/20 text-green-400', - badge: '', - }, - }, - { - label: 'Pending', - value: 'pending', - whereClause: { - OR: [{ status: 'PENDING' }, { status: 'HUMAN_PENDING' }], - }, - styles: { - filter: 'border-blue-500 bg-blue-500/20 text-blue-400', - badge: 'rounded-sm bg-blue-500/20 px-2 py-0.5 text-[12px] font-medium text-blue-500', - }, - }, - { - label: 'Rejected', - value: 'rejected', - whereClause: { - status: 'REJECTED', - }, - styles: { - filter: 'border-red-500 bg-red-500/20 text-red-400', - badge: 'rounded-sm bg-red-500/20 px-2 py-0.5 text-[12px] font-medium text-red-500', - }, - }, - { - label: 'Suspicious', - value: 'suspicious', - whereClause: { - suspicious: true, - }, - styles: { - filter: 'border-red-500 bg-red-500/20 text-red-400', - badge: 'rounded-sm bg-red-500/20 px-2 py-0.5 text-[12px] font-medium text-red-500', - }, - }, - { - label: 'Verified', - value: 'verified', - whereClause: { - status: 'VERIFIED', - }, - styles: { - filter: 'border-blue-500 bg-blue-500/20 text-blue-400', - badge: 'rounded-sm bg-blue-500/20 px-2 py-0.5 text-[12px] font-medium text-blue-500', - }, - }, - { - label: 'Approved', - value: 'approved', - whereClause: { - status: 'APPROVED', - }, - styles: { - filter: 'border-green-500 bg-green-500/20 text-green-400', - badge: 'rounded-sm bg-green-500/20 px-2 py-0.5 text-[12px] font-medium text-green-500', - }, - }, - { - label: 'Needs Review', - value: 'needs-review', - whereClause: { - requiresAdminReview: true, - }, - styles: { - filter: 'border-yellow-500 bg-yellow-500/20 text-yellow-400', - badge: 'rounded-sm bg-yellow-500/20 px-2 py-0.5 text-[12px] font-medium text-yellow-500', - }, - }, - ] as const satisfies CommentStatusFilterInfo[] -) - -export type CommentStatusFilter = (typeof commentStatusFilters)[number]['value'] - -export function getCommentStatusFilterValue( - comment: Prisma.CommentGetPayload<{ - select: { - status: true - suspicious: true - requiresAdminReview: true - } - }> -): CommentStatusFilter { - if (comment.requiresAdminReview) return 'needs-review' - if (comment.suspicious) return 'suspicious' - - switch (comment.status) { - case 'PENDING': - case 'HUMAN_PENDING': { - return 'pending' - } - case 'VERIFIED': { - return 'verified' - } - case 'REJECTED': { - return 'rejected' - } - case 'APPROVED': { - return 'approved' - } - default: { - return 'all' - } - } -} diff --git a/web/src/constants/currencies.ts b/web/src/constants/currencies.ts deleted file mode 100644 index a31cb3e..0000000 --- a/web/src/constants/currencies.ts +++ /dev/null @@ -1,61 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { Currency } from '@prisma/client' - -type CurrencyInfo = { - id: T - icon: string - name: string - slug: string -} - -export const { - dataArray: currencies, - dataObject: currenciesById, - getFn: getCurrencyInfo, - getFnSlug: getCurrencyInfoBySlug, - zodEnumBySlug: currenciesZodEnumBySlug, - keyToSlug: currencyIdToSlug, - slugToKey: currencySlugToId, -} = makeHelpersForOptions( - 'id', - (id): CurrencyInfo => ({ - id, - icon: 'ri:question-line', - name: id ? transformCase(id, 'title') : String(id), - slug: id ? id.toLowerCase() : '', - }), - [ - { - id: 'MONERO', - icon: 'monero', - name: 'Monero', - slug: 'xmr', - }, - { - id: 'BITCOIN', - icon: 'bitcoin', - name: 'Bitcoin', - slug: 'btc', - }, - { - id: 'LIGHTNING', - icon: 'ri:flashlight-line', - name: 'Lightning', - slug: 'btc-ln', - }, - { - id: 'FIAT', - icon: 'credit-card', - name: 'Fiat', - slug: 'fiat', - }, - { - id: 'CASH', - icon: 'coins', - name: 'Cash', - slug: 'cash', - }, - ] as const satisfies CurrencyInfo[] -) diff --git a/web/src/constants/eventTypes.ts b/web/src/constants/eventTypes.ts deleted file mode 100644 index 7a5350d..0000000 --- a/web/src/constants/eventTypes.ts +++ /dev/null @@ -1,108 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { EventType } from '@prisma/client' - -type EventTypeInfo = { - id: T - slug: string - label: string - description: string - classNames: { - dot: string - } - icon: string -} - -export const { - dataArray: eventTypes, - dataObject: eventTypesById, - getFn: getEventTypeInfo, - getFnSlug: getEventTypeInfoBySlug, - zodEnumBySlug: eventTypesZodEnumBySlug, - zodEnumById: eventTypesZodEnumById, -} = makeHelpersForOptions( - 'id', - (id): EventTypeInfo => ({ - id, - slug: id ? id.toLowerCase() : '', - label: id ? transformCase(id, 'title') : String(id), - description: '', - classNames: { - dot: 'bg-zinc-700 text-zinc-300 ring-zinc-700/50', - }, - icon: 'ri:question-fill', - }), - [ - { - id: 'WARNING', - slug: 'warning', - label: 'Warning', - description: 'Potential issues that users should be aware of', - classNames: { - dot: 'bg-amber-900 text-amber-300 ring-amber-900/50', - }, - icon: 'ri:error-warning-fill', - }, - { - id: 'WARNING_SOLVED', - slug: 'warning-solved', - label: 'Warning Solved', - description: 'A previously reported warning has been solved', - classNames: { - dot: 'bg-green-900 text-green-300 ring-green-900/50', - }, - icon: 'ri:check-fill', - }, - { - id: 'ALERT', - slug: 'alert', - label: 'Alert', - description: 'Critical issues affecting service functionality', - classNames: { - dot: 'bg-red-900 text-red-300 ring-red-900/50', - }, - icon: 'ri:alert-fill', - }, - { - id: 'ALERT_SOLVED', - slug: 'alert-solved', - label: 'Alert Solved', - description: 'A previously reported alert has been solved', - classNames: { - dot: 'bg-green-900 text-green-300 ring-green-900/50', - }, - icon: 'ri:check-fill', - }, - { - id: 'INFO', - slug: 'info', - label: 'Information', - description: 'General information about the service', - classNames: { - dot: 'bg-blue-900 text-blue-300 ring-blue-900/50', - }, - icon: 'ri:information-fill', - }, - { - id: 'NORMAL', - slug: 'normal', - label: 'Normal', - description: 'Regular service update or announcement', - classNames: { - dot: 'bg-zinc-700 text-zinc-300 ring-zinc-700/50', - }, - icon: 'ri:notification-fill', - }, - { - id: 'UPDATE', - slug: 'update', - label: 'Update', - description: 'Service details were updated on kycnot.me', - classNames: { - dot: 'bg-sky-900 text-sky-300 ring-sky-900/50', - }, - icon: 'ri:pencil-fill', - }, - ] as const satisfies EventTypeInfo[] -) diff --git a/web/src/constants/karmaUnlocks.ts b/web/src/constants/karmaUnlocks.ts deleted file mode 100644 index 8d943d3..0000000 --- a/web/src/constants/karmaUnlocks.ts +++ /dev/null @@ -1,89 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -export type KarmaUnlockInfo = { - id: T - name: string - verb: string - description: string - karma: number - icon: string -} - -export const { dataArray: karmaUnlocks, dataObject: karmaUnlocksById } = makeHelpersForOptions( - 'id', - (id): KarmaUnlockInfo => ({ - id, - name: id ? transformCase(id, 'title') : String(id), - description: id ? transformCase(id, 'sentence') : String(id), - karma: 0, - icon: 'ri:question-line', - verb: id ? transformCase(id, 'title') : String(id), - }), - [ - { - id: 'voteComments', - name: 'Vote on comments', - verb: 'vote on comments', - description: 'You can vote on comments', - karma: 20, - icon: 'ri:thumb-up-line', - }, - { - id: 'websiteLink', - name: 'Website link', - verb: 'add a website link', - description: 'You can add a website link to your profile', - karma: 175, - icon: 'ri:link', - }, - { - id: 'displayName', - name: 'Display name', - verb: 'have a display name', - description: 'You can change your display name', - karma: 150, - icon: 'ri:user-smile-line', - }, - { - id: 'profilePicture', - name: 'Profile picture', - verb: 'have a profile picture', - description: 'You can change your profile picture', - karma: 200, - icon: 'ri:image-line', - }, - { - id: 'highKarmaBadge', - name: 'High Karma badge', - verb: 'become a high karma user', - description: 'You are a high karma user', - karma: 500, - icon: 'ri:shield-star-line', - }, - { - id: 'negativeKarmaBadge', - name: 'Negative Karma badge', - verb: 'be a suspicious user', - description: 'You are a suspicious user', - karma: -10, - icon: 'ri:error-warning-line', - }, - { - id: 'untrustedBadge', - name: 'Untrusted badge', - verb: 'be an untrusted user', - description: 'You are an untrusted user', - karma: -30, - icon: 'ri:spam-2-line', - }, - { - id: 'commentsDisabled', - name: 'Comments disabled', - verb: 'cannot comment', - description: 'You cannot comment', - karma: -50, - icon: 'ri:forbid-line', - }, - ] as const satisfies KarmaUnlockInfo[] -) diff --git a/web/src/constants/kycLevels.ts b/web/src/constants/kycLevels.ts deleted file mode 100644 index 5f48e0c..0000000 --- a/web/src/constants/kycLevels.ts +++ /dev/null @@ -1,64 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { parseIntWithFallback } from '../lib/numbers' -import { transformCase } from '../lib/strings' - -type KycLevelInfo = { - id: T - value: number - icon: string - name: string - description: string -} - -export const { - dataArray: kycLevels, - dataObject: kycLevelsById, - getFn: getKycLevelInfo, -} = makeHelpersForOptions( - 'id', - (id): KycLevelInfo => ({ - id, - value: parseIntWithFallback(id, 4), - icon: 'diamond-question', - name: `KYC ${id ? transformCase(id, 'title') : String(id)}`, - description: '', - }), - [ - { - id: '0', - value: 0, - icon: 'anonymous-mask', - name: 'Guaranteed no KYC', - description: 'Terms explicitly state KYC will never be requested.', - }, - { - id: '1', - value: 1, - icon: 'diamond-question', - name: 'No KYC mention', - description: 'No mention of current or future KYC requirements.', - }, - { - id: '2', - value: 2, - icon: 'handcuffs', - name: 'KYC on authorities request', - description: - 'No routine KYC, but may cooperate with authorities, block funds or implement future KYC requirements.', - }, - { - id: '3', - value: 3, - icon: 'gun', - name: 'Shotgun KYC', - description: 'May request KYC and block funds based on automated triggers.', - }, - { - id: '4', - value: 4, - icon: 'fingerprint-detailed', - name: 'Mandatory KYC', - description: 'Required for key features and can be required arbitrarily at any time.', - }, - ] as const satisfies KycLevelInfo<'0' | '1' | '2' | '3' | '4'>[] -) diff --git a/web/src/constants/networks.ts b/web/src/constants/networks.ts deleted file mode 100644 index 99338de..0000000 --- a/web/src/constants/networks.ts +++ /dev/null @@ -1,38 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -type NetworkInfo = { - slug: T - icon: string - name: string -} - -export const { - dataArray: networks, - dataObject: networksBySlug, - getFn: getNetworkInfo, -} = makeHelpersForOptions( - 'slug', - (slug): NetworkInfo => ({ - slug, - icon: 'ri:global-line', - name: slug ? transformCase(slug, 'title') : String(slug), - }), - [ - { - slug: 'clearnet', - icon: 'ri:global-line', - name: 'Clearnet', - }, - { - slug: 'onion', - icon: 'onion', - name: 'Onion', - }, - { - slug: 'i2p', - icon: 'i2p', - name: 'I2P', - }, - ] as const satisfies NetworkInfo[] -) diff --git a/web/src/constants/notificationTypes.ts b/web/src/constants/notificationTypes.ts deleted file mode 100644 index bf6e67e..0000000 --- a/web/src/constants/notificationTypes.ts +++ /dev/null @@ -1,70 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' - -import type { NotificationType } from '@prisma/client' - -type NotificationTypeInfo = { - id: T - label: string - icon: string -} - -export const { - dataArray: notificationTypes, - dataObject: notificationTypeLabels, - getFn: getNotificationTypeInfo, -} = makeHelpersForOptions( - 'id', - (id): NotificationTypeInfo => ({ - id, - label: 'Notification', - icon: 'ri:notification-line', - }), - [ - { - id: 'COMMENT_STATUS_CHANGE', - label: 'Comment status changed', - icon: 'ri:chat-check-line', - }, - { - id: 'REPLY_COMMENT_CREATED', - label: 'New reply', - icon: 'ri:chat-4-line', - }, - { - id: 'ROOT_COMMENT_CREATED', - label: 'New comment/rating', - icon: 'ri:chat-4-line', - }, - { - id: 'SUGGESTION_MESSAGE', - label: 'New message in suggestion', - icon: 'ri:mail-line', - }, - { - id: 'SUGGESTION_STATUS_CHANGE', - label: 'Suggestion status changed', - icon: 'ri:lightbulb-line', - }, - // TODO: [KARMA_UNLOCK] Will be added later, when karma unloks are in the database, not in the code. - // { - // id: 'KARMA_UNLOCK', - // label: 'Karma unlock', - // icon: 'ri:award-line', - // }, - { - id: 'ACCOUNT_STATUS_CHANGE', - label: 'Change in account status', - icon: 'ri:user-settings-line', - }, - { - id: 'EVENT_CREATED', - label: 'New event', - icon: 'ri:calendar-event-line', - }, - { - id: 'SERVICE_VERIFICATION_STATUS_CHANGE', - label: 'Service verification changed', - icon: 'ri:verified-badge-line', - }, - ] as const satisfies NotificationTypeInfo[] -) diff --git a/web/src/constants/project.ts b/web/src/constants/project.ts deleted file mode 100644 index 8fadc87..0000000 --- a/web/src/constants/project.ts +++ /dev/null @@ -1 +0,0 @@ -export const SUPPORT_EMAIL = 'support@kycnot.me' diff --git a/web/src/constants/serviceStatusChange.ts b/web/src/constants/serviceStatusChange.ts deleted file mode 100644 index 4ccc281..0000000 --- a/web/src/constants/serviceStatusChange.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { ServiceVerificationStatusChange } from '@prisma/client' - -type ServiceVerificationStatusChangeInfo = { - value: T - label: string - notificationTitle: string -} - -export const { - dataArray: serviceVerificationStatusChanges, - dataObject: serviceVerificationStatusChangesById, - getFn: getServiceVerificationStatusChangeInfo, - zodEnumById: serviceVerificationStatusChangesZodEnumById, -} = makeHelpersForOptions( - 'value', - (value): ServiceVerificationStatusChangeInfo => ({ - value, - label: value ? transformCase(value.replaceAll('_', ' '), 'title') : String(value), - notificationTitle: value ? transformCase(value.replaceAll('_', ' '), 'title') : String(value), - }), - [ - { - value: 'STATUS_CHANGED_TO_COMMUNITY_CONTRIBUTED', - label: 'status changed to community contributed', - notificationTitle: 'status changed to community contributed', - }, - { - value: 'STATUS_CHANGED_TO_APPROVED', - label: 'status changed to approved', - notificationTitle: 'status changed to approved', - }, - { - value: 'STATUS_CHANGED_TO_VERIFICATION_SUCCESS', - label: 'status changed to verification success', - notificationTitle: 'status changed to verification success', - }, - { - value: 'STATUS_CHANGED_TO_VERIFICATION_FAILED', - label: 'status changed to verification failed', - notificationTitle: 'status changed to verification failed', - }, - ] as const satisfies ServiceVerificationStatusChangeInfo[] -) - -export type ServiceVerificationStatusChangeType = (typeof serviceVerificationStatusChanges)[number]['value'] diff --git a/web/src/constants/serviceSuggestionStatus.ts b/web/src/constants/serviceSuggestionStatus.ts deleted file mode 100644 index 4c73adb..0000000 --- a/web/src/constants/serviceSuggestionStatus.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { ServiceSuggestionStatus } from '@prisma/client' - -type ServiceSuggestionStatusInfo = { - value: T - slug: string - label: string - icon: string - iconClass: string - default: boolean -} - -export const { - dataArray: serviceSuggestionStatuses, - dataObject: serviceSuggestionStatusesById, - getFn: getServiceSuggestionStatusInfo, - getFnSlug: getServiceSuggestionStatusInfoBySlug, - zodEnumBySlug: serviceSuggestionStatusesZodEnumBySlug, - zodEnumById: serviceSuggestionStatusesZodEnumById, - keyToSlug: serviceSuggestionStatusIdToSlug, - slugToKey: serviceSuggestionStatusSlugToId, -} = makeHelpersForOptions( - 'value', - (value): ServiceSuggestionStatusInfo => ({ - value, - slug: value ? value.toLowerCase() : '', - label: value ? transformCase(value, 'title') : String(value), - icon: 'ri:question-line', - iconClass: 'text-current/60', - default: false, - }), - [ - { - value: 'PENDING', - slug: 'pending', - label: 'Pending', - icon: 'ri:time-line', - iconClass: 'text-yellow-400', - default: true, - }, - { - value: 'APPROVED', - slug: 'approved', - label: 'Approved', - icon: 'ri:check-line', - iconClass: 'text-green-400', - default: false, - }, - { - value: 'REJECTED', - slug: 'rejected', - label: 'Rejected', - icon: 'ri:close-line', - iconClass: 'text-red-400', - default: false, - }, - { - value: 'WITHDRAWN', - slug: 'withdrawn', - label: 'Withdrawn', - icon: 'ri:arrow-left-line', - iconClass: 'text-gray-400', - default: false, - }, - ] as const satisfies ServiceSuggestionStatusInfo[] -) diff --git a/web/src/constants/serviceSuggestionType.ts b/web/src/constants/serviceSuggestionType.ts deleted file mode 100644 index 2efe804..0000000 --- a/web/src/constants/serviceSuggestionType.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { ServiceSuggestionType } from '@prisma/client' - -type ServiceSuggestionTypeInfo = { - value: T - slug: string - label: string - icon: string - default: boolean -} - -export const { - dataArray: serviceSuggestionTypes, - dataObject: serviceSuggestionTypesById, - getFn: getServiceSuggestionTypeInfo, - getFnSlug: getServiceSuggestionTypeInfoBySlug, - zodEnumBySlug: serviceSuggestionTypesZodEnumBySlug, - zodEnumById: serviceSuggestionTypesZodEnumById, - keyToSlug: serviceSuggestionTypeIdToSlug, - slugToKey: serviceSuggestionTypeSlugToId, -} = makeHelpersForOptions( - 'value', - (value): ServiceSuggestionTypeInfo => ({ - value, - slug: value ? value.toLowerCase() : '', - label: value ? transformCase(value, 'title') : String(value), - icon: 'ri:question-line', - default: false, - }), - [ - { - value: 'CREATE_SERVICE', - slug: 'create', - label: 'Create', - icon: 'ri:add-line', - default: true, - }, - { - value: 'EDIT_SERVICE', - slug: 'edit', - label: 'Edit', - icon: 'ri:pencil-line', - default: false, - }, - ] as const satisfies ServiceSuggestionTypeInfo[] -) diff --git a/web/src/constants/serviceUserRoles.ts b/web/src/constants/serviceUserRoles.ts deleted file mode 100644 index fbcd570..0000000 --- a/web/src/constants/serviceUserRoles.ts +++ /dev/null @@ -1,73 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type BadgeSmall from '../components/BadgeSmall.astro' -import type { ServiceUserRole } from '@prisma/client' -import type { ComponentProps } from 'astro/types' - -type ServiceUserRoleInfo = { - value: T - slug: string - label: string - icon: string - order: number - color: NonNullable['color']> -} - -export const { - dataArray: serviceUserRoles, - dataObject: serviceUserRolesById, - getFn: getServiceUserRoleInfo, -} = makeHelpersForOptions( - 'value', - (value): ServiceUserRoleInfo => ({ - value, - slug: value ? value.toLowerCase() : '', - label: value ? transformCase(value, 'title').replace('_', ' ') : String(value), - icon: 'ri:user-3-line', - order: Infinity, - color: 'gray', - }), - [ - { - value: 'OWNER', - slug: 'owner', - label: 'Owner', - icon: 'ri:vip-crown-2-fill', - order: 1, - color: 'lime', - }, - { - value: 'ADMIN', - slug: 'admin', - label: 'Admin', - icon: 'ri:shield-star-fill', - order: 2, - color: 'green', - }, - { - value: 'MODERATOR', - slug: 'moderator', - label: 'Moderator', - icon: 'ri:glasses-2-line', - order: 3, - color: 'teal', - }, - { - value: 'SUPPORT', - slug: 'support', - label: 'Support', - icon: 'ri:customer-service-2-fill', - order: 4, - color: 'blue', - }, - { - value: 'TEAM_MEMBER', - slug: 'team_member', - label: 'Team Member', - icon: 'ri:team-fill', - order: 5, - color: 'cyan', - }, - ] as const satisfies ServiceUserRoleInfo[] -) diff --git a/web/src/constants/serviceVisibility.ts b/web/src/constants/serviceVisibility.ts deleted file mode 100644 index 2403658..0000000 --- a/web/src/constants/serviceVisibility.ts +++ /dev/null @@ -1,60 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { ServiceVisibility } from '@prisma/client' - -type ServiceVisibilityInfo = { - value: T - slug: string - label: string - description: string - icon: string - iconClass: string -} - -export const { - dataArray: serviceVisibilities, - dataObject: serviceVisibilitiesById, - getFn: getServiceVisibilityInfo, - getFnSlug: getServiceVisibilityInfoBySlug, - zodEnumBySlug: serviceVisibilitiesZodEnumBySlug, - zodEnumById: serviceVisibilitiesZodEnumById, - keyToSlug: serviceVisibilityIdToSlug, - slugToKey: serviceVisibilitySlugToId, -} = makeHelpersForOptions( - 'value', - (value): ServiceVisibilityInfo => ({ - value, - slug: value ? value.toLowerCase() : '', - label: value ? transformCase(value, 'title') : String(value), - description: '', - icon: 'ri:eye-line', - iconClass: 'text-current/60', - }), - [ - { - value: 'PUBLIC', - slug: 'public', - label: 'Public', - description: 'Listed in search and browse.', - icon: 'ri:global-line', - iconClass: 'text-green-500', - }, - { - value: 'UNLISTED', - slug: 'unlisted', - label: 'Unlisted', - description: 'Only accessible via direct link.', - icon: 'ri:link', - iconClass: 'text-yellow-500', - }, - { - value: 'HIDDEN', - slug: 'hidden', - label: 'Hidden', - description: 'Only visible to moderators.', - icon: 'ri:lock-line', - iconClass: 'text-red-500', - }, - ] as const satisfies ServiceVisibilityInfo[] -) diff --git a/web/src/constants/splashTexts.ts b/web/src/constants/splashTexts.ts deleted file mode 100644 index 775480d..0000000 --- a/web/src/constants/splashTexts.ts +++ /dev/null @@ -1,17 +0,0 @@ -export const splashTexts: string[] = [ - 'Privacy is not a crime.', - 'True financial independence.', - 'Privacy is a human right.', - 'Cypherpunk zone ahead.', - 'KYC? Not me!', - 'Freedom through privacy.', - 'Resist surveillance.', - 'Anonymity is power.', - 'Defend your privacy.', - 'Unbank yourself.', - 'Banking without borders.', - 'Escape the panopticon.', - 'Ditch the gatekeepers.', - 'Own your identity.', - 'Financial privacy matters.', -] diff --git a/web/src/constants/suggestionStatusChange.ts b/web/src/constants/suggestionStatusChange.ts deleted file mode 100644 index 9b5532b..0000000 --- a/web/src/constants/suggestionStatusChange.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { ServiceSuggestionStatusChange } from '@prisma/client' - -type ServiceSuggestionStatusChangeInfo = { - value: T - label: string - notificationTitle: string -} - -export const { - dataArray: serviceSuggestionStatusChanges, - dataObject: serviceSuggestionStatusChangesById, - getFn: getServiceSuggestionStatusChangeInfo, - zodEnumById: serviceSuggestionStatusChangesZodEnumById, -} = makeHelpersForOptions( - 'value', - (value): ServiceSuggestionStatusChangeInfo => ({ - value, - label: value ? transformCase(value.replaceAll('_', ' '), 'title') : String(value), - notificationTitle: value ? transformCase(value.replaceAll('_', ' '), 'title') : String(value), - }), - [ - { - value: 'STATUS_CHANGED_TO_PENDING', - label: 'status changed to pending', - notificationTitle: 'status changed to pending', - }, - { - value: 'STATUS_CHANGED_TO_APPROVED', - label: 'status changed to approved', - notificationTitle: 'status changed to approved', - }, - { - value: 'STATUS_CHANGED_TO_REJECTED', - label: 'status changed to rejected', - notificationTitle: 'status changed to rejected', - }, - { - value: 'STATUS_CHANGED_TO_WITHDRAWN', - label: 'status changed to withdrawn', - notificationTitle: 'status changed to withdrawn', - }, - ] as const satisfies ServiceSuggestionStatusChangeInfo[] -) - -export type ServiceSuggestionStatusChangeType = (typeof serviceSuggestionStatusChanges)[number]['value'] diff --git a/web/src/constants/tosHighlightRating.ts b/web/src/constants/tosHighlightRating.ts deleted file mode 100644 index a4faf0e..0000000 --- a/web/src/constants/tosHighlightRating.ts +++ /dev/null @@ -1,63 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -type TosHighlightRatingInfo = { - id: T - icon: string - name: string - classNames: { - icon: string - borderColor: string - } - order: number -} - -export const { - dataArray: tosHighlightRatings, - dataObject: tosHighlightRatingsById, - getFn: getTosHighlightRatingInfo, -} = makeHelpersForOptions( - 'id', - (id): TosHighlightRatingInfo => ({ - id, - icon: 'ri:question-line', - name: id ? transformCase(id, 'title') : String(id), - classNames: { - icon: 'text-yellow-400', - borderColor: 'border-yellow-500/40', - }, - order: Infinity, - }), - [ - { - id: 'negative', - icon: 'ri:thumb-down-line', - name: 'Negative', - classNames: { - icon: 'text-red-400', - borderColor: 'border-red-500/40', - }, - order: 1, - }, - { - id: 'positive', - icon: 'ri:thumb-up-line', - name: 'Positive', - classNames: { - icon: 'text-green-400', - borderColor: 'border-green-500/40', - }, - order: 2, - }, - { - id: 'neutral', - icon: 'ri:information-line', - name: 'Neutral', - classNames: { - icon: 'text-blue-400', - borderColor: 'border-blue-500/40', - }, - order: 3, - }, - ] as const satisfies TosHighlightRatingInfo[] -) diff --git a/web/src/constants/userSentiment.ts b/web/src/constants/userSentiment.ts deleted file mode 100644 index 26103c0..0000000 --- a/web/src/constants/userSentiment.ts +++ /dev/null @@ -1,63 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -type UserSentimentInfo = { - id: T - icon: string - name: string - classNames: { - icon: string - borderColor: string - background: string - } -} - -export const { - dataArray: userSentiments, - dataObject: userSentimentsById, - getFn: getUserSentimentInfo, -} = makeHelpersForOptions( - 'id', - (id): UserSentimentInfo => ({ - id, - icon: 'ri:emotion-normal-line', - name: id ? transformCase(id, 'title') : String(id), - classNames: { - icon: 'text-yellow-400', - borderColor: 'border-yellow-500/40', - background: 'bg-yellow-950/20', - }, - }), - [ - { - id: 'positive', - icon: 'ri:emotion-happy-line', - name: 'Positive', - classNames: { - icon: 'text-green-400', - borderColor: 'border-green-500/40', - background: 'bg-green-950/20', - }, - }, - { - id: 'neutral', - icon: 'ri:emotion-normal-line', - name: 'Neutral', - classNames: { - icon: 'text-blue-400', - borderColor: 'border-blue-500/40', - background: 'bg-blue-950/20', - }, - }, - { - id: 'negative', - icon: 'ri:emotion-unhappy-line', - name: 'Negative', - classNames: { - icon: 'text-red-400', - borderColor: 'border-red-500/40', - background: 'bg-red-950/20', - }, - }, - ] as const satisfies UserSentimentInfo[] -) diff --git a/web/src/constants/verificationStatus.ts b/web/src/constants/verificationStatus.ts deleted file mode 100644 index 4c0c73d..0000000 --- a/web/src/constants/verificationStatus.ts +++ /dev/null @@ -1,146 +0,0 @@ -import { makeHelpersForOptions } from '../lib/makeHelpersForOptions' -import { transformCase } from '../lib/strings' - -import type { MarkdownString } from '../lib/markdown' -import type { VerificationStatus } from '@prisma/client' - -type VerificationStatusInfo = { - value: T - slug: string - labelShort: string - label: string - icon: string - default: boolean - description: string - privacyPoints: number - trustPoints: number - classNames: { - icon: string - badgeBig: string - button: string - description: string - containerBg: string - } - order: number - verbPast: string -} - -export const READ_MORE_SENTENCE_LINK = - 'Read more about the [suggestion review process](/about#suggestion-review-process).' satisfies MarkdownString - -export const { - dataArray: verificationStatuses, - dataObject: verificationStatusesByValue, - getFn: getVerificationStatusInfo, - getFnSlug: getVerificationStatusInfoBySlug, - zodEnumBySlug: verificationStatusesZodEnumBySlug, - zodEnumById: verificationStatusesZodEnumById, - keyToSlug: verificationStatusIdToSlug, - slugToKey: verificationStatusSlugToId, -} = makeHelpersForOptions( - 'value', - (value): VerificationStatusInfo => ({ - value, - slug: value ? value.toLowerCase() : '', - labelShort: value ? transformCase(value, 'title') : String(value), - label: value ? transformCase(value, 'title') : String(value), - icon: 'ri:loader-line', - default: false, - description: '', - privacyPoints: 0, - trustPoints: 0, - classNames: { - icon: 'text-current', - badgeBig: 'bg-night-400 text-day-100', - button: 'bg-night-400 hover:bg-night-300', - description: 'text-day-200', - containerBg: 'bg-night-600', - }, - order: Infinity, - verbPast: value ? transformCase(value, 'title') : String(value), - }), - [ - { - value: 'VERIFICATION_SUCCESS', - slug: 'verified', - labelShort: 'Verified', - label: 'Verified', - icon: 'ri:verified-badge-fill', - default: true, - description: - 'Thoroughly tested and verified by the team. But things might change, this is not a guarantee.', - privacyPoints: 0, - trustPoints: 5, - classNames: { - icon: 'text-[#40e6c2]', - badgeBig: 'bg-green-800/50 text-green-100', - button: 'bg-green-700 hover:bg-green-600', - description: 'text-green-200', - containerBg: 'bg-green-900/30', - }, - order: 1, - verbPast: 'verified', - }, - { - value: 'APPROVED', - slug: 'approved', - labelShort: 'Approved', - label: 'Approved', - icon: 'ri:check-line', - default: true, - description: - 'Everything checks out at first glance, but not verified nor thoroughly tested by the team.', - privacyPoints: 0, - trustPoints: 5, - classNames: { - icon: 'text-white', - badgeBig: 'bg-night-400 text-day-100', - button: 'bg-night-400 hover:bg-night-300', - description: 'text-day-200', - containerBg: 'bg-night-600', - }, - order: 2, - verbPast: 'approved', - }, - { - value: 'COMMUNITY_CONTRIBUTED', - slug: 'community', - labelShort: 'Community', - label: 'Community Contributed', - icon: 'ri:question-line', - default: false, - description: 'Suggested by the community, but not reviewed by the team yet.', - privacyPoints: 0, - trustPoints: 0, - classNames: { - icon: 'text-yellow-400', - badgeBig: 'bg-amber-800/50 text-amber-100', - button: 'bg-amber-700 hover:bg-amber-600', - description: 'text-amber-200', - containerBg: 'bg-amber-900/30', - }, - order: 3, - verbPast: 'contributed by the community', - }, - { - value: 'VERIFICATION_FAILED', - slug: 'scam', - labelShort: 'Scam', - label: 'Scam', - icon: 'ri:alert-fill', - default: false, - description: 'Confirmed as a SCAM or not what it claims to be.', - privacyPoints: 0, - trustPoints: -30, - classNames: { - icon: 'text-red-500', - badgeBig: 'bg-red-800/50 text-red-100', - button: 'bg-red-700 hover:bg-red-600', - description: 'text-red-200', - containerBg: 'bg-red-900/30', - }, - order: 4, - verbPast: 'marked as a SCAM', - }, - ] as const satisfies VerificationStatusInfo[] -) diff --git a/web/src/env.d.ts b/web/src/env.d.ts deleted file mode 100644 index 6018113..0000000 --- a/web/src/env.d.ts +++ /dev/null @@ -1,44 +0,0 @@ -import type { ErrorBanners } from './lib/errorBanners' -import type { KarmaUnlocks } from './lib/karmaUnlocks' -/* eslint-disable @typescript-eslint/consistent-type-definitions */ -import type { Prisma } from '@prisma/client' -import type * as htmx from 'htmx.org' - -declare global { - namespace App { - interface Locals { - user: (Prisma.UserGetPayload & { karmaUnlocks: KarmaUnlocks }) | null - actualUser: (Prisma.UserGetPayload & { karmaUnlocks: KarmaUnlocks }) | null - banners: ErrorBanners - makeId: (prefix: T) => `${T}-${number}-${string}` - } - } - - interface Window { - htmx?: typeof htmx - } - - namespace PrismaJson { - type TosReview = { - kycLevel: 0 | 1 | 2 | 3 | 4 - /** Less than 200 characters */ - summary: MarkdownString - contentHash: string - complexity: 'high' | 'low' | 'medium' - highlights: { - /** Very short */ - title: string - /** Short */ - content: MarkdownString - rating: 'negative' | 'neutral' | 'positive' - }[] - } - - type UserSentiment = { - summary: MarkdownString - sentiment: 'negative' | 'neutral' | 'positive' - whatUsersLike: string[] - whatUsersDislike: string[] - } - } -} diff --git a/web/src/icons/anonymous-mask.svg b/web/src/icons/anonymous-mask.svg deleted file mode 100644 index 9d058a1..0000000 --- a/web/src/icons/anonymous-mask.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - \ No newline at end of file diff --git a/web/src/icons/bitcoin.svg b/web/src/icons/bitcoin.svg deleted file mode 100644 index c86bd39..0000000 --- a/web/src/icons/bitcoin.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - \ No newline at end of file diff --git a/web/src/icons/coins.svg b/web/src/icons/coins.svg deleted file mode 100644 index 62d2daa..0000000 --- a/web/src/icons/coins.svg +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - \ No newline at end of file diff --git a/web/src/icons/credit-card.svg b/web/src/icons/credit-card.svg deleted file mode 100644 index 03d2c95..0000000 --- a/web/src/icons/credit-card.svg +++ /dev/null @@ -1,6 +0,0 @@ - - - - - \ No newline at end of file diff --git a/web/src/icons/diamond-question.svg b/web/src/icons/diamond-question.svg deleted file mode 100644 index d31d430..0000000 --- a/web/src/icons/diamond-question.svg +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - - - \ No newline at end of file diff --git a/web/src/icons/fingerprint-detailed.svg b/web/src/icons/fingerprint-detailed.svg deleted file mode 100644 index 535a827..0000000 --- a/web/src/icons/fingerprint-detailed.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - \ No newline at end of file diff --git a/web/src/icons/gun.svg b/web/src/icons/gun.svg deleted file mode 100644 index 327a2e9..0000000 --- a/web/src/icons/gun.svg +++ /dev/null @@ -1,6 +0,0 @@ - - - - \ No newline at end of file diff --git a/web/src/icons/handcuffs.svg b/web/src/icons/handcuffs.svg deleted file mode 100644 index 5e83980..0000000 --- a/web/src/icons/handcuffs.svg +++ /dev/null @@ -1,11 +0,0 @@ - - - - - \ No newline at end of file diff --git a/web/src/icons/i2p.svg b/web/src/icons/i2p.svg deleted file mode 100644 index 8392463..0000000 --- a/web/src/icons/i2p.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - \ No newline at end of file diff --git a/web/src/icons/monero.svg b/web/src/icons/monero.svg deleted file mode 100644 index 23e341b..0000000 --- a/web/src/icons/monero.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - \ No newline at end of file diff --git a/web/src/icons/onion.svg b/web/src/icons/onion.svg deleted file mode 100644 index 4c839a9..0000000 --- a/web/src/icons/onion.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - \ No newline at end of file diff --git a/web/src/layouts/BaseLayout.astro b/web/src/layouts/BaseLayout.astro deleted file mode 100644 index 6206597..0000000 --- a/web/src/layouts/BaseLayout.astro +++ /dev/null @@ -1,101 +0,0 @@ ---- -import BaseHead from '../components/BaseHead.astro' -import Footer from '../components/Footer.astro' -import Header from '../components/Header.astro' -import { cn } from '../lib/cn' - -import type { AstroChildren } from '../lib/astro' -import type { ComponentProps } from 'astro/types' - -import '@fontsource-variable/space-grotesk' -import '../styles/global.css' - -type Props = ComponentProps & { - children: AstroChildren - errors?: string[] - success?: string[] - className?: { - body?: string - main?: string - footer?: string - } - showSplashText?: boolean - widthClassName?: - | 'container' - | 'max-w-none' - | 'max-w-screen-2xl' - | 'max-w-screen-lg' - | 'max-w-screen-md' - | 'max-w-screen-sm' - | 'max-w-screen-xl' - | 'max-w-screen-xs' -} - -const { - errors = [], - success = [], - className, - widthClassName = 'max-w-screen-2xl', - showSplashText, - ...baseHeadProps -} = Astro.props - -const actualErrors = [...errors, ...Astro.locals.banners.errors] -const actualSuccess = [...success, ...Astro.locals.banners.successes] ---- - - - - - - - - -
- - { - actualSuccess.length > 0 && ( -
    - {actualSuccess.map((message) => ( -
  • - {message} -
  • - ))} -
- ) - } - - { - actualErrors.length > 0 && ( -
    - {actualErrors.map((error) => ( -
  • - {error} -
  • - ))} -
- ) - } - -
- -
- -
- - diff --git a/web/src/layouts/MarkdownLayout.astro b/web/src/layouts/MarkdownLayout.astro deleted file mode 100644 index 54b69c8..0000000 --- a/web/src/layouts/MarkdownLayout.astro +++ /dev/null @@ -1,72 +0,0 @@ ---- -import { makeOgImageUrl, type OgImageAllTemplatesWithProps } from '../components/OgImage' -import { KYCNOTME_SCHEMA_MINI } from '../lib/schema' - -import BaseLayout from './BaseLayout.astro' - -import type { AstroChildren } from '../lib/astro' -import type { MarkdownLayoutProps } from 'astro' -import type { ComponentProps } from 'astro/types' -import type { Article, WithContext } from 'schema-dts' - -type Props = ComponentProps & - MarkdownLayoutProps<{ - children: AstroChildren - title: string - author: string - pubDate: string - description: string - }> - -const { frontmatter, schemas, ...baseLayoutProps } = Astro.props -const publishDate = frontmatter.pubDate ? new Date(frontmatter.pubDate) : null -const ogImageTemplateData = { - template: 'generic', - title: frontmatter.title, -} satisfies OgImageAllTemplatesWithProps -const weAreAuthor = frontmatter.author.toLowerCase().trim() === 'kycnot.me' ---- - -, - ...(schemas ?? []), - ]} -> -
-

{frontmatter.title}

-

- {frontmatter.author && `by ${frontmatter.author}`} - {frontmatter.pubDate && ` | ${new Date(frontmatter.pubDate).toLocaleDateString()}`} -

- - -
-
diff --git a/web/src/layouts/MiniLayout.astro b/web/src/layouts/MiniLayout.astro deleted file mode 100644 index 5cf11b0..0000000 --- a/web/src/layouts/MiniLayout.astro +++ /dev/null @@ -1,38 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' - -import { cn } from '../lib/cn' - -import BaseLayout from './BaseLayout.astro' - -import type { ComponentProps } from 'astro/types' - -type Props = Omit, 'widthClassName'> & { - layoutHeader: { icon: string; title: string; subtitle: string } -} - -const { layoutHeader, ...baseLayoutProps } = Astro.props ---- - - -
-
- -
- -

- {layoutHeader.title} -

-

{layoutHeader.subtitle}

- - -
-
diff --git a/web/src/lib/accountCreate.ts b/web/src/lib/accountCreate.ts deleted file mode 100644 index ea12faa..0000000 --- a/web/src/lib/accountCreate.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { generateUsername } from 'unique-username-generator' - -import { prisma } from './prisma' -import { generateUserSecretToken, hashUserSecretToken } from './userSecretToken' - -/** - * Generate a random username. - * Format: `adjective_noun_1234` - */ -function generateRandomUsername() { - return `${generateUsername('_')}_${Math.floor(Math.random() * 10000).toString()}` -} - -export async function createAccount(preGeneratedToken?: string) { - const token = preGeneratedToken ?? generateUserSecretToken() - const hash = hashUserSecretToken(token) - const username = generateRandomUsername() - - const user = await prisma.user.create({ - data: { - name: username, - secretTokenHash: hash, - notificationPreferences: { create: {} }, - }, - }) - - return { token, user } -} diff --git a/web/src/lib/arrays.ts b/web/src/lib/arrays.ts deleted file mode 100644 index 4cfb673..0000000 --- a/web/src/lib/arrays.ts +++ /dev/null @@ -1,130 +0,0 @@ -import { z } from 'astro/zod' -import { map, xor, some, every } from 'lodash-es' - -/** - * Returns a tuple of values from a tuple of records. - * - * @example - * TupleValues<'value', [{ value: 'a' }, { value: 'b' }]> // -> ['a', 'b'] - */ -type TupleValues[]> = { - [I in keyof T]: T[I][K] -} - -/** - * Returns a tuple of values from a tuple of records. - * - * @example - * const options = [{ value: 'a' }, { value: 'b' }] - * const values = getTupleValues(options, 'value') // -> ['a', 'b'] - */ -export function getTupleValues[]>( - arr: T, - key: K -): TupleValues { - return map(arr, key) as unknown as TupleValues -} - -/** - * Returns a zod enum from a constant. - * - * @example - * const options = [{ value: 'a' }, { value: 'b' }] - * const zodEnum = zodEnumFromConstant(options, 'value') // -> z.enum(['a', 'b']) - */ -export function zodEnumFromConstant[]>( - arr: T, - key: K -) { - return z.enum(getTupleValues(arr as unknown as [T[number], ...T[number][]], key)) -} - -/** - * Returns a random element from an array. - * - * @example - * const options = ['a', 'b'] - * const randomElement = getRandomElement(options) // -> 'a' or 'b' - */ -export function getRandom(array: readonly T[]): T { - return array[Math.floor(Math.random() * array.length)] as T -} - -/** - * Typed version of Array.prototype.join. - * - * @example - * TypedJoin<['a', 'b']> // -> 'ab' - * TypedJoin<['a', 'b'], '-'> // -> 'a-b' - */ -type TypedJoin< - T extends readonly string[], - Separator extends string = '', - First extends boolean = true, -> = T extends readonly [] - ? '' - : T extends readonly [infer U extends string, ...infer R extends readonly string[]] - ? `${First extends true ? '' : Separator}${U}${TypedJoin}` - : string - -/** - * Joins an array of strings with a separator. - * - * @example - * const options = ['a', 'b'] as const - * const joined = typedJoin(options) // -> 'ab' - * const joinedWithSeparator = typedJoin(options, '-') // -> 'a-b' - */ -export function typedJoin( - array: T, - separator: Separator = '' as Separator -) { - return array.join(separator) as TypedJoin -} - -/** - * Checks if two or more arrays are equal without considering order. - * - * @example - * const a = [1, 2, 3] - * const b = [3, 2, 1] - * areEqualArraysWithoutOrder(a, b) // -> true - */ -export function areEqualArraysWithoutOrder(...arrays: (T[] | null | undefined)[]): boolean { - return xor(...arrays).length === 0 -} - -/** - * Checks if some but not all of the arguments are true. - * - * @example - * someButNotAll(true, false, true) // -> true - * someButNotAll(true, true, true) // -> false - * someButNotAll(false, false, false) // -> false - */ -export const someButNotAll = (...args: boolean[]) => some(args) && !every(args) - -/** - * Returns undefined if the array is empty. - * - * @example - * const a = [1, 2, 3] - * const b = [] - * const c = null - * const d = undefined - * undefinedIfEmpty(a) // -> [1, 2, 3] - * undefinedIfEmpty(b) // -> undefined - * undefinedIfEmpty(c) // -> undefined - * undefinedIfEmpty(d) // -> undefined - */ -export function undefinedIfEmpty(value: T) { - return (value && Array.isArray(value) && value.length > 0 ? value : undefined) as T extends (infer U)[] - ? U[] | undefined - : T extends readonly [...infer U] - ? U | undefined - : undefined -} - -export function isNotArray(value: T | T[]): value is T { - return !Array.isArray(value) -} diff --git a/web/src/lib/astro.ts b/web/src/lib/astro.ts deleted file mode 100644 index fb165d1..0000000 --- a/web/src/lib/astro.ts +++ /dev/null @@ -1,11 +0,0 @@ -/* eslint-disable @typescript-eslint/no-explicit-any */ -/* eslint-disable @typescript-eslint/no-empty-object-type */ -import type { ComponentProps, HTMLTag, Polymorphic } from 'astro/types' - -export type AstroComponent = (args: any) => any - -export type PolymorphicComponent = - (Component extends AstroComponent ? ComponentProps & { as?: Component } : {}) & - (Component extends HTMLTag ? Polymorphic<{ as: Component }> : {}) - -export type AstroChildren = any diff --git a/web/src/lib/astroActions.ts b/web/src/lib/astroActions.ts deleted file mode 100644 index 2eb6849..0000000 --- a/web/src/lib/astroActions.ts +++ /dev/null @@ -1,17 +0,0 @@ -/* eslint-disable @typescript-eslint/no-explicit-any */ -import type { z } from 'astro/zod' -import type { ActionAccept, ActionClient, SafeResult } from 'astro:actions' - -export type AnyAction = ActionClient & string - -export type FormAction = ActionClient & string -export type JsonAction = ActionClient & string - -export type ActionInput = Parameters[0] - -export type ActionOutput = - ReturnType extends Promise> ? TOutput : never - -/** Returns the input type of an action, or the output type if the input type is not a record. */ -export type ActionInputNoFormData = - ActionInput extends Record ? ActionInput : ActionOutput diff --git a/web/src/lib/attributes.ts b/web/src/lib/attributes.ts deleted file mode 100644 index b85ceaf..0000000 --- a/web/src/lib/attributes.ts +++ /dev/null @@ -1,152 +0,0 @@ -import { orderBy } from 'lodash-es' - -import { getAttributeCategoryInfo } from '../constants/attributeCategories' -import { getAttributeTypeInfo } from '../constants/attributeTypes' -import { READ_MORE_SENTENCE_LINK, verificationStatusesByValue } from '../constants/verificationStatus' - -import { formatDateShort } from './timeAgo' - -import type { Prisma } from '@prisma/client' - -export function sortAttributes< - T extends Prisma.AttributeGetPayload<{ - select: { - title: true - privacyPoints: true - trustPoints: true - category: true - type: true - } - }>, ->(attributes: T[]): T[] { - return orderBy( - attributes, - [ - ({ privacyPoints, trustPoints }) => (privacyPoints + trustPoints < 0 ? 1 : 2), - ({ privacyPoints, trustPoints }) => Math.abs(privacyPoints + trustPoints), - ({ type }) => getAttributeTypeInfo(type).order, - ({ category }) => getAttributeCategoryInfo(category).order, - 'title', - ], - ['asc', 'desc', 'asc', 'asc', 'asc'] - ) -} - -export function makeNonDbAttributes( - service: Prisma.ServiceGetPayload<{ - select: { - verificationStatus: true - isRecentlyListed: true - listedAt: true - createdAt: true - } - }>, - { filter = false }: { filter?: boolean } = {} -) { - const nonDbAttributes: (Prisma.AttributeGetPayload<{ - select: { - title: true - type: true - category: true - description: true - privacyPoints: true - trustPoints: true - } - }> & { - show: boolean - links: { - url: string - label: string - icon: string - }[] - })[] = [ - { - title: 'Verified', - show: service.verificationStatus === 'VERIFICATION_SUCCESS', - type: 'GOOD', - category: 'TRUST', - description: `${verificationStatusesByValue.VERIFICATION_SUCCESS.description} ${READ_MORE_SENTENCE_LINK}\n\nCheck out the [proof](#verification).`, - privacyPoints: verificationStatusesByValue.VERIFICATION_SUCCESS.privacyPoints, - trustPoints: verificationStatusesByValue.VERIFICATION_SUCCESS.trustPoints, - links: [ - { - url: '/?verification=verified', - label: 'Search with this', - icon: 'ri:search-line', - }, - ], - }, - { - title: 'Approved', - show: service.verificationStatus === 'APPROVED', - type: 'INFO', - category: 'TRUST', - description: `${verificationStatusesByValue.APPROVED.description} ${READ_MORE_SENTENCE_LINK}`, - privacyPoints: verificationStatusesByValue.APPROVED.privacyPoints, - trustPoints: verificationStatusesByValue.APPROVED.trustPoints, - links: [ - { - url: '/?verification=verified&verification=approved', - label: 'Search with this', - icon: 'ri:search-line', - }, - ], - }, - { - title: 'Community contributed', - show: service.verificationStatus === 'COMMUNITY_CONTRIBUTED', - type: 'WARNING', - category: 'TRUST', - description: `${verificationStatusesByValue.COMMUNITY_CONTRIBUTED.description} ${READ_MORE_SENTENCE_LINK}`, - privacyPoints: verificationStatusesByValue.COMMUNITY_CONTRIBUTED.privacyPoints, - trustPoints: verificationStatusesByValue.COMMUNITY_CONTRIBUTED.trustPoints, - links: [ - { - url: '/?verification=community', - label: 'With this', - icon: 'ri:search-line', - }, - { - url: '/?verification=verified&verification=approved', - label: 'Without this', - icon: 'ri:search-line', - }, - ], - }, - { - title: 'Is SCAM', - show: service.verificationStatus === 'VERIFICATION_FAILED', - type: 'BAD', - category: 'TRUST', - description: `${verificationStatusesByValue.VERIFICATION_FAILED.description} ${READ_MORE_SENTENCE_LINK}\n\nCheck out the [proof](#verification).`, - privacyPoints: verificationStatusesByValue.VERIFICATION_FAILED.privacyPoints, - trustPoints: verificationStatusesByValue.VERIFICATION_FAILED.trustPoints, - links: [ - { - url: '/?verification=scam', - label: 'With this', - icon: 'ri:search-line', - }, - { - url: '/?verification=verified&verification=approved', - label: 'Without this', - icon: 'ri:search-line', - }, - ], - }, - { - title: 'Recently listed', - show: service.isRecentlyListed, - type: 'WARNING', - category: 'TRUST', - description: `Listed on KYCnot.me ${formatDateShort(service.listedAt ?? service.createdAt)}. Proceed with caution.`, - privacyPoints: 0, - trustPoints: -5, - links: [], - }, - ] - - if (filter) return nonDbAttributes.filter(({ show }) => show) - - return nonDbAttributes -} diff --git a/web/src/lib/callActionWithUrlParams.ts b/web/src/lib/callActionWithUrlParams.ts deleted file mode 100644 index 43c7a60..0000000 --- a/web/src/lib/callActionWithUrlParams.ts +++ /dev/null @@ -1,184 +0,0 @@ -import { serialize } from 'object-to-formdata' - -import { urlParamsToFormData, urlParamsToObject } from './urls' - -import type { AstroGlobal } from 'astro' -import type { ActionAccept, ActionClient, SafeResult } from 'astro:actions' -import type { z } from 'astro:schema' - -/** - * Call an Action directly from an Astro page or API endpoint. - * - * The action input is obtained from the URL search params. - * - * Returns a Promise with the action result. - * - * It uses {@link AstroGlobal.callAction} internally. - * - * Example usage: - * - * ```typescript - * import { actions } from 'astro:actions'; - * - * const result = await callActionWithUrlParamsUnhandledErrors(Astro, actions.getPost, 'form'); - * ``` - */ -export function callActionWithUrlParamsUnhandledErrors< - TAccept extends ActionAccept, - TInputSchema extends z.ZodType, - TOutput, - TAction extends - | ActionClient - | ActionClient['orThrow'], - P extends Parameters[0], ->(context: AstroGlobal, action: TAction, accept: P extends FormData ? 'form' : 'json') { - const input = - accept === 'form' - ? urlParamsToFormData(context.url.searchParams) - : urlParamsToObject(context.url.searchParams) - - return context.callAction(action, input as P) -} - -/** - * Call an Action directly from an Astro page or API endpoint. - * - * The action input is obtained from the URL search params. - * - * Returns a Promise with the action result's data. - * - * It stores the errors in {@link context.locals.banners} - * - * It uses {@link AstroGlobal.callAction} internally. - * - * Example usage: - * - * ```typescript - * import { actions } from 'astro:actions'; - * - * const data = await callActionWithUrlParams(Astro, actions.getPost, 'form'); - * ``` - */ -export async function callActionWithUrlParams< - TAccept extends ActionAccept, - TInputSchema extends z.ZodType, - TOutput, - TAction extends - | ActionClient - | ActionClient['orThrow'], - P extends Parameters[0], - // eslint-disable-next-line @typescript-eslint/no-explicit-any - TInputSchema2 extends ReturnType extends Promise> ? I : never, - // eslint-disable-next-line @typescript-eslint/no-explicit-any - TOutput2 extends ReturnType extends Promise> ? O : never, ->(context: AstroGlobal, action: TAction, accept: P extends FormData ? 'form' : 'json') { - const input = - accept === 'form' - ? urlParamsToFormData(context.url.searchParams) - : urlParamsToObject(context.url.searchParams) - - const result = (await context.callAction(action, input as P)) as SafeResult< - TInputSchema2, - Awaited - > - if (result.error) { - context.locals.banners.add({ - uiMessage: result.error.message, - type: 'error', - origin: 'action', - error: result.error, - }) - } - return result.data -} - -/** - * Call an Action directly from an Astro page or API endpoint. - * - * Returns a Promise with the action result. - * - * It uses {@link AstroGlobal.callAction} internally. - * - * Example usage: - * - * ```typescript - * import { actions } from 'astro:actions'; - * - * const input = { id: 123 } - * const result = await callActionWithObjectUnhandledErrors(Astro, actions.getPost, input, 'form'); - * ``` - */ -export function callActionWithObjectUnhandledErrors< - TAccept extends ActionAccept, - TInputSchema extends z.ZodType, - TOutput, - TAction extends - | ActionClient - | ActionClient['orThrow'], - P extends Parameters[0], - TInputSchema2 extends ReturnType extends Promise> ? I : never, ->( - context: AstroGlobal, - action: TAction, - input: [TInputSchema2] extends [FormData] | [never] ? undefined : TInputSchema2, - accept: P extends FormData ? 'form' : 'json' -) { - const parsedInput = accept === 'form' ? serialize(input) : input - - return context.callAction(action, parsedInput as P) -} - -/** - * Call an Action directly from an Astro page or API endpoint. - * - * The action input is a plain object. - * - * Returns a Promise with the action result's data. - * - * It stores the errors in {@link context.locals.banners} - * - * It uses {@link AstroGlobal.callAction} internally. - * - * Example usage: - * - * ```typescript - * import { actions } from 'astro:actions'; - * - * const input = { id: 123 } - * const data = await callActionWithObject(Astro, actions.getPost, input, 'form'); - * ``` - */ -export async function callActionWithObject< - TAccept extends ActionAccept, - TInputSchema extends z.ZodType, - TOutput, - TAction extends - | ActionClient - | ActionClient['orThrow'], - P extends Parameters[0], - // eslint-disable-next-line @typescript-eslint/no-explicit-any - TInputSchema2 extends ReturnType extends Promise> ? I : never, - // eslint-disable-next-line @typescript-eslint/no-explicit-any - TOutput2 extends ReturnType extends Promise> ? O : never, ->( - context: AstroGlobal, - action: TAction, - input: [TInputSchema2] extends [FormData] | [never] ? undefined : TInputSchema2, - accept: P extends FormData ? 'form' : 'json' -) { - const parsedInput = accept === 'form' ? serialize(input) : input - - const result = (await context.callAction(action, parsedInput as P)) as SafeResult< - TInputSchema2, - Awaited - > - if (result.error) { - context.locals.banners.add({ - uiMessage: result.error.message, - type: 'error', - origin: 'action', - error: result.error, - }) - } - return result.data -} diff --git a/web/src/lib/captcha.ts b/web/src/lib/captcha.ts deleted file mode 100644 index 9b4a12b..0000000 --- a/web/src/lib/captcha.ts +++ /dev/null @@ -1,169 +0,0 @@ -import { createHash } from 'crypto' - -import { createCanvas } from 'canvas' - -export const CAPTCHA_LENGTH = 6 -const CAPTCHA_CHARS = 'ABCDEFGHIJKMNOPRSTUVWXYZ123456789' // Notice that ambiguous characters are removed - -/** Hash a captcha value */ -function hashCaptchaValue(value: string): string { - return createHash('sha256').update(value).digest('hex') -} - -/** Generate a captcha image as a data URI */ -export function generateCaptchaImage(text: string) { - const width = 144 - const height = 48 - const canvas = createCanvas(width, height) - const ctx = canvas.getContext('2d') - - // Fill background with gradient - const gradient = ctx.createLinearGradient(0, 0, width, height) - gradient.addColorStop(0, '#1a202c') - gradient.addColorStop(1, '#2d3748') - ctx.fillStyle = gradient - ctx.fillRect(0, 0, width, height) - - // Add grid pattern background - ctx.strokeStyle = 'rgba(255, 255, 255, 0.05)' - ctx.lineWidth = 1 - for (let i = 0; i < width; i += 10) { - ctx.beginPath() - ctx.moveTo(i, 0) - ctx.lineTo(i, height) - ctx.stroke() - } - for (let i = 0; i < height; i += 10) { - ctx.beginPath() - ctx.moveTo(0, i) - ctx.lineTo(width, i) - ctx.stroke() - } - - // Add wavy lines - for (let i = 0; i < 3; i++) { - const r = Math.floor(Math.random() * 200 + 55).toString() - const g = Math.floor(Math.random() * 200 + 55).toString() - const b = Math.floor(Math.random() * 200 + 55).toString() - ctx.strokeStyle = 'rgba(' + r + ', ' + g + ', ' + b + ', 0.5)' - ctx.lineWidth = Math.random() * 3 + 1 - - ctx.beginPath() - const startY = Math.random() * height - let curveX = 0 - let curveY = startY - - ctx.moveTo(curveX, curveY) - - while (curveX < width) { - const nextX = curveX + Math.random() * 20 + 10 - const nextY = startY + Math.sin(curveX / 20) * (Math.random() * 15 + 5) - ctx.quadraticCurveTo(curveX + (nextX - curveX) / 2, curveY + Math.random() * 20 - 10, nextX, nextY) - curveX = nextX - curveY = nextY - } - ctx.stroke() - } - - // Add random dots - for (let i = 0; i < 100; i++) { - const r = Math.floor(Math.random() * 200 + 55).toString() - const g = Math.floor(Math.random() * 200 + 55).toString() - const b = Math.floor(Math.random() * 200 + 55).toString() - const alpha = (Math.random() * 0.5 + 0.1).toString() - ctx.fillStyle = 'rgba(' + r + ', ' + g + ', ' + b + ', ' + alpha + ')' - - ctx.beginPath() - ctx.arc(Math.random() * width, Math.random() * height, Math.random() * 2 + 1, 0, Math.PI * 2) - ctx.fill() - } - - // Draw captcha text with shadow and more distortion - ctx.shadowColor = 'rgba(0, 0, 0, 0.5)' - ctx.shadowBlur = 3 - ctx.shadowOffsetX = 2 - ctx.shadowOffsetY = 2 - - // Calculate text positioning - const fontSize = Math.floor(height * 0.55) - const padding = 15 - const charWidth = (width - padding * 2) / text.length - - // Draw each character with various effects - for (let i = 0; i < text.length; i++) { - const r = Math.floor(Math.random() * 100 + 155).toString() - const g = Math.floor(Math.random() * 100 + 155).toString() - const b = Math.floor(Math.random() * 100 + 155).toString() - ctx.fillStyle = 'rgb(' + r + ', ' + g + ', ' + b + ')' - - // Vary font style for each character - const fontStyle = Math.random() > 0.5 ? 'bold' : 'normal' - const fontFamily = Math.random() > 0.5 ? 'monospace' : 'Arial' - const fontSizeStr = fontSize.toString() - ctx.font = fontStyle + ' ' + fontSizeStr + 'px ' + fontFamily - - // Position with variations - const xPos = padding + i * charWidth + (Math.random() * 8 - 4) - const yPos = height * 0.6 + (Math.random() * 12 - 6) - const rotation = Math.random() * 0.6 - 0.3 - const scale = 0.8 + Math.random() * 0.4 - - ctx.save() - ctx.translate(xPos, yPos) - ctx.rotate(rotation) - ctx.scale(scale, scale) - - // Add slight perspective effect - if (Math.random() > 0.7) { - ctx.transform(1, 0, 0.1, 1, 0, 0) - } else if (Math.random() > 0.5) { - ctx.transform(1, 0, -0.1, 1, 0, 0) - } - - ctx.fillText(text.charAt(i), 0, 0) - ctx.restore() - } - - // Add some noise on top - for (let x = 0; x < width; x += 3) { - for (let y = 0; y < height; y += 3) { - if (Math.random() > 0.95) { - const alpha = (Math.random() * 0.2 + 0.1).toString() - ctx.fillStyle = 'rgba(255, 255, 255, ' + alpha + ')' - ctx.fillRect(x, y, 2, 2) - } - } - } - - return { - src: canvas.toDataURL('image/png'), - width, - height, - format: 'png', - } as const satisfies ImageMetadata -} - -/** Generate a new captcha with solution, its hash, and image data URI */ -export function generateCaptcha() { - const solution = Array.from({ length: CAPTCHA_LENGTH }, () => - CAPTCHA_CHARS.charAt(Math.floor(Math.random() * CAPTCHA_CHARS.length)) - ).join('') - - return { - solution, - solutionHash: hashCaptchaValue(solution), - image: generateCaptchaImage(solution), - } -} - -/** Verify a captcha input against the expected hash */ -export function verifyCaptcha(value: string, solutionHash: string): boolean { - const correctedValue = value - .toUpperCase() - .replace(/[^A-Z0-9]/g, '') - .replace(/0/g, 'O') - .replace(/Q/g, 'O') - .replace(/L/g, 'I') - const valueHash = hashCaptchaValue(correctedValue) - return valueHash === solutionHash -} diff --git a/web/src/lib/captchaValidation.ts b/web/src/lib/captchaValidation.ts deleted file mode 100644 index 01094b9..0000000 --- a/web/src/lib/captchaValidation.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { z, type RefinementCtx } from 'astro/zod' - -import { CAPTCHA_LENGTH, verifyCaptcha } from './captcha' - -export const captchaFormSchemaProperties = { - 'captcha-value': z - .string() - .length(CAPTCHA_LENGTH, `Captcha must be ${CAPTCHA_LENGTH.toLocaleString()} characters long`) - .regex(/^[A-Za-z0-9]+$/, 'Captcha must contain only uppercase letters and numbers'), - 'captcha-solution-hash': z.string().min(1, 'Missing internal captcha data'), -} as const - -export const captchaFormSchemaSuperRefine = ( - value: z.infer>, - ctx: RefinementCtx -) => { - const isValidCaptcha = verifyCaptcha(value['captcha-value'], value['captcha-solution-hash']) - if (!isValidCaptcha) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: ['captcha-value'], - message: 'Incorrect captcha', - }) - } -} - -export const captchaFormSchema = z - .object(captchaFormSchemaProperties) - .superRefine(captchaFormSchemaSuperRefine) diff --git a/web/src/lib/cn.ts b/web/src/lib/cn.ts deleted file mode 100644 index 93654ae..0000000 --- a/web/src/lib/cn.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { clsx, type ClassValue } from 'clsx' -import { extendTailwindMerge } from 'tailwind-merge' - -const twMerge = extendTailwindMerge({ - extend: { - classGroups: { - 'font-family': ['font-title'], - }, - }, -}) - -export function cn(...inputs: ClassValue[]) { - return twMerge(clsx(inputs)) -} diff --git a/web/src/lib/commentsWithReplies.ts b/web/src/lib/commentsWithReplies.ts deleted file mode 100644 index 186ca0f..0000000 --- a/web/src/lib/commentsWithReplies.ts +++ /dev/null @@ -1,174 +0,0 @@ -import { z } from 'zod' - -import type { Prisma } from '@prisma/client' - -export const MAX_COMMENT_DEPTH = 12 - -const commentReplyQuery = { - select: { - id: true, - status: true, - suspicious: true, - upvotes: true, - requiresAdminReview: true, - createdAt: true, - communityNote: true, - internalNote: true, - privateContext: true, - content: true, - serviceId: true, - parentId: true, - rating: true, - ratingActive: true, - orderId: true, - orderIdStatus: true, - kycRequested: true, - fundsBlocked: true, - - author: { - select: { - id: true, - name: true, - verified: true, - admin: true, - verifier: true, - createdAt: true, - displayName: true, - picture: true, - totalKarma: true, - spammer: true, - verifiedLink: true, - - serviceAffiliations: { - select: { - role: true, - service: { - select: { - name: true, - slug: true, - }, - }, - }, - }, - }, - }, - votes: { - select: { - userId: true, - downvote: true, - }, - }, - }, - orderBy: [{ suspicious: 'asc' }, { createdAt: 'desc' }], -} as const satisfies Prisma.CommentFindManyArgs - -export type CommentWithReplies = Record> = - Prisma.CommentGetPayload & - T & { - replies?: CommentWithReplies[] - } - -export type CommentWithRepliesPopulated = CommentWithReplies<{ - isWatchingReplies: boolean -}> - -export const commentSortSchema = z.enum(['newest', 'upvotes', 'status']).default('newest') -export type CommentSortOption = z.infer - -export function makeCommentsNestedQuery({ - depth = 0, - user, - showPending, - serviceId, - sort, -}: { - depth?: number - user: Prisma.UserGetPayload<{ - select: { - id: true - } - }> | null - showPending?: boolean - serviceId: number - sort: CommentSortOption -}) { - const orderByClause: Prisma.CommentOrderByWithRelationInput[] = [] - - switch (sort) { - case 'upvotes': - orderByClause.push({ upvotes: 'desc' }) - break - case 'status': - orderByClause.push({ status: 'asc' }) // PENDING, APPROVED, VERIFIED, REJECTED - break - case 'newest': // Default - default: - orderByClause.push({ createdAt: 'desc' }) - break - } - orderByClause.unshift({ suspicious: 'asc' }) // Always put suspicious comments last within a sort group - - const baseQuery = { - ...commentReplyQuery, - orderBy: orderByClause, - where: { - OR: [ - ...(user ? [{ authorId: user.id } as const satisfies Prisma.CommentWhereInput] : []), - showPending - ? ({ - status: { in: ['APPROVED', 'VERIFIED', 'PENDING', 'HUMAN_PENDING'] }, - } as const satisfies Prisma.CommentWhereInput) - : ({ - status: { in: ['APPROVED', 'VERIFIED'] }, - } as const satisfies Prisma.CommentWhereInput), - ], - parentId: null, - serviceId, - }, - } as const satisfies Prisma.CommentFindManyArgs - - if (depth <= 0) return baseQuery - - return { - ...baseQuery, - select: { - ...baseQuery.select, - replies: makeRepliesQuery(commentReplyQuery, depth - 1), - }, - } -} - -type RepliesQueryRecursive = - | T - | (Omit & { - select: Omit & { - replies: RepliesQueryRecursive - } - }) - -export function makeRepliesQuery( - query: T, - currentDepth: number -): RepliesQueryRecursive { - if (currentDepth <= 0) return query - - return { - ...query, - select: { - ...query.select, - replies: makeRepliesQuery(query, currentDepth - 1), - }, - } -} - -export function makeCommentUrl({ - serviceSlug, - commentId, - origin, -}: { - serviceSlug: string - commentId: number - origin: string -}) { - return `${origin}/service/${serviceSlug}?comment=${commentId.toString()}#comment-${commentId.toString()}` as const -} diff --git a/web/src/lib/contactMethods.ts b/web/src/lib/contactMethods.ts deleted file mode 100644 index d8239d8..0000000 --- a/web/src/lib/contactMethods.ts +++ /dev/null @@ -1,60 +0,0 @@ -import { parsePhoneNumberWithError } from 'libphonenumber-js' - -type Formatter = { - id: string - matcher: RegExp - formatter: (value: string) => string | null -} -const formatters = [ - { - id: 'email', - matcher: /mailto:(.*)/, - formatter: (value) => value, - }, - { - id: 'telephone', - matcher: /tel:(.*)/, - formatter: (value) => { - return parsePhoneNumberWithError(value).formatInternational() - }, - }, - { - id: 'whatsapp', - matcher: /https?:\/\/wa\.me\/(.*)\/?/, - formatter: (value) => { - return parsePhoneNumberWithError(value).formatInternational() - }, - }, - { - id: 'telegram', - matcher: /https?:\/\/t\.me\/(.*)\/?/, - formatter: (value) => `t.me/${value}`, - }, - { - id: 'linkedin', - matcher: /https?:\/\/(?:www\.)?linkedin\.com\/(?:in|company)\/(.*)\/?/, - formatter: (value) => `in/${value}`, - }, - { - id: 'website', - matcher: /https?:\/\/(?:www\.)?((?:[a-zA-Z0-9-]+\.)+[a-zA-Z]+)/, - formatter: (value) => value, - }, -] as const satisfies Formatter[] - -export function formatContactMethod(url: string) { - for (const formatter of formatters) { - const captureGroup = url.match(formatter.matcher)?.[1] - if (!captureGroup) continue - - const formattedValue = formatter.formatter(captureGroup) - if (!formattedValue) continue - - return { - type: formatter.id, - formattedValue, - } as const - } - - return null -} diff --git a/web/src/lib/defineProtectedAction.ts b/web/src/lib/defineProtectedAction.ts deleted file mode 100644 index f23ac72..0000000 --- a/web/src/lib/defineProtectedAction.ts +++ /dev/null @@ -1,124 +0,0 @@ -import { - ActionError, - defineAction, - type ActionAccept, - type ActionAPIContext, - type ActionHandler, -} from 'astro:actions' - -import type { MaybePromise } from 'astro/actions/runtime/utils.js' -import type { z } from 'astro/zod' - -type SpecialUserPermission = 'admin' | 'verified' | 'verifier' -type Permission = SpecialUserPermission | 'guest' | 'not-spammer' | 'user' - -type ActionAPIContextWithUser = ActionAPIContext & { - locals: { - user: NonNullable - } -} - -type ActionHandlerWithUser = TInputSchema extends z.ZodType - ? (input: z.infer, context: ActionAPIContextWithUser) => MaybePromise - : ( - // eslint-disable-next-line @typescript-eslint/no-explicit-any - input: any, - context: ActionAPIContextWithUser - ) => MaybePromise - -export function defineProtectedAction< - P extends Permission | SpecialUserPermission[], - TOutput, - TAccept extends ActionAccept | undefined = undefined, - TInputSchema extends z.ZodType | undefined = TAccept extends 'form' ? z.ZodType : undefined, ->({ - accept, - input: inputSchema, - handler, - permissions, -}: { - input?: TInputSchema - accept?: TAccept - handler: P extends 'guest' - ? ActionHandler - : ActionHandlerWithUser - permissions: P -}) { - return defineAction({ - accept, - input: inputSchema, - handler: ((input, context) => { - if (permissions === 'guest' || (Array.isArray(permissions) && permissions.length === 0)) { - return handler( - input, - // eslint-disable-next-line @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-explicit-any - context as any - ) - } - - if (!context.locals.user) { - throw new ActionError({ - code: 'UNAUTHORIZED', - message: 'You must be logged in to perform this action.', - }) - } - - if (permissions === 'not-spammer' && context.locals.user.spammer) { - throw new ActionError({ - code: 'FORBIDDEN', - message: 'Spammer users are not allowed to perform this action.', - }) - } - - if ( - (permissions === 'verified' || (Array.isArray(permissions) && permissions.includes('verified'))) && - !context.locals.user.verified - ) { - if (context.locals.user.spammer) { - throw new ActionError({ - code: 'FORBIDDEN', - message: 'Spammer users are not allowed to perform this action.', - }) - } - throw new ActionError({ - code: 'FORBIDDEN', - message: 'Verified user privileges required.', - }) - } - - if ( - (permissions === 'verifier' || (Array.isArray(permissions) && permissions.includes('verifier'))) && - !context.locals.user.verifier - ) { - if (context.locals.user.spammer) { - throw new ActionError({ - code: 'FORBIDDEN', - message: 'Spammer users are not allowed to perform this action.', - }) - } - throw new ActionError({ - code: 'FORBIDDEN', - message: 'Verifier privileges required.', - }) - } - - if ( - (permissions === 'admin' || (Array.isArray(permissions) && permissions.includes('admin'))) && - !context.locals.user.admin - ) { - if (context.locals.user.spammer) { - throw new ActionError({ - code: 'FORBIDDEN', - message: 'Spammer users are not allowed to perform this action.', - }) - } - throw new ActionError({ - code: 'FORBIDDEN', - message: 'Admin privileges required.', - }) - } - - return handler(input, context as ActionAPIContextWithUser) - }) as ActionHandler, - }) -} diff --git a/web/src/lib/envVariables.ts b/web/src/lib/envVariables.ts deleted file mode 100644 index 36d7f48..0000000 --- a/web/src/lib/envVariables.ts +++ /dev/null @@ -1,5 +0,0 @@ -import { z } from 'astro/zod' - -const schema = z.enum(['development', 'staging', 'production']) - -export const DEPLOYMENT_MODE = schema.parse(import.meta.env.PROD ? import.meta.env.MODE : 'development') diff --git a/web/src/lib/errorBanners.ts b/web/src/lib/errorBanners.ts deleted file mode 100644 index c2945b9..0000000 --- a/web/src/lib/errorBanners.ts +++ /dev/null @@ -1,228 +0,0 @@ -import type { APIContext, AstroGlobal } from 'astro' -import type { ErrorInferenceObject } from 'astro/actions/runtime/utils.js' -import type { ActionError, SafeResult } from 'astro:actions' - -type MessageObject = - | { - uiMessage: string - type: 'success' - origin: 'action' | 'runtime' | 'url' | `custom_${string}` - error?: undefined - } - | ({ - uiMessage: string - type: 'error' - } & ( - | { - origin: 'action' - // eslint-disable-next-line @typescript-eslint/no-explicit-any - error: ActionError - } - | { origin: 'runtime'; error?: unknown } - | { origin: 'url'; error?: undefined } - | { origin: `custom_${string}`; error?: unknown } - )) - -/** - * Helper class for handling errors and success messages. - * It automatically adds messages from the query string to the messages array. - * - * @example - * ```astro - * --- - * const messages = new ErrorBanners(Astro) - * const data = await messages.try('Oops!', () => fetchData()) - * --- - * - * {data ? data : 'No data'} - * - * ``` - */ -export class ErrorBanners { - private _messages: MessageObject[] = [] - - constructor(messages?: MessageObject[]) { - this._messages = messages ?? [] - } - - /** - * Get all stored messages. - */ - public get get() { - return [...this._messages] - } - - /** - * Get all error messages. - */ - public get errors() { - return this._messages.filter((msg) => msg.type === 'error').map((error) => error.uiMessage) - } - - /** - * Get all success messages. - */ - public get successes() { - return this._messages.filter((msg) => msg.type === 'success').map((success) => success.uiMessage) - } - - /** - * Handler for errors. Intended to be used in `.catch()` blocks. - * - * @example - * ```ts - * const data = await fetchData().catch(messages.handler('Oops!')) - * ``` - * - * @param uiMessage The UI message to display, or function to generate it. - * @returns The handler function. - */ - public handler(uiMessage: string | ((error: unknown) => string)) { - return (error: unknown) => { - const message = typeof uiMessage === 'function' ? uiMessage(error) : uiMessage - console.error(`[ErrorBanners] ${message}`, error) - this._messages.push({ - uiMessage: message, - type: 'error', - error, - origin: 'runtime', - }) - } - } - - /** - * Run a function and catch its errors. - * - * @example - * ```ts - * const items = await messages.try("Oops!", () => fetchItems()) // Item[] | undefined - * const items = await messages.try("Oops!", () => fetchItems(), []) // Item[] - * ``` - * - * @param uiMessage The UI message to display, or function to generate it. - * @param fn The function to execute. - * @param fallback The fallback value. - * @returns The result of the function. - */ - public async try( - uiMessage: string | ((error: unknown) => string), - fn: () => Promise | T, - fallback?: F - ) { - try { - const result = await fn() - return result - } catch (error) { - this.handler(uiMessage)(error) - return fallback as F - } - } - - /** - * Run multiple functions in parallel and catch errors. - * - * @example - * ```ts - * const [categories, posts] = await messages.tryMany([ - * ["Error in categories", () => fetchCategories(), []], - * ["Error in posts", () => fetchPosts()] - * ]) - * ``` - * - * @param operations The operations to run. - * @returns The results of the operations. - */ - public async tryMany>[] | []>( - operations: T - ) { - const results = await Promise.all(operations.map((args) => this.try(...args))) - - return results as unknown as Promise<{ - -readonly [P in keyof T]: Awaited> | T[P][2] - }> - } - - /** - * Add one or multiple messages. - */ - public add(...messages: (MessageObject | null | undefined)[]) { - messages - .filter((message) => message !== null && message !== undefined) - .forEach((message) => { - this._messages.push(message) - if (message.type === 'error') { - console.error(`[ErrorBanners] ${message.uiMessage}`, message.error) - } - }) - } - - /** - * Add a success message. - */ - public addSuccess(message: string) { - this._messages.push({ - uiMessage: message, - type: 'success', - origin: 'runtime', - }) - } - - /** - * Add a success message if the action result is successful. - */ - public addIfSuccess( - actionResult: SafeResult | undefined, - message: string | ((actionResult: TOutput) => string) - ) { - if (actionResult && !actionResult.error) { - const actualMessage = typeof message === 'function' ? message(actionResult.data) : message - this._messages.push({ - uiMessage: actualMessage, - type: 'success', - origin: 'action', - }) - } - } - - /** - * Clear all messages. - */ - public clear() { - this._messages = [] - } -} - -/** - * Generate message objects for {@link ErrorBanners} from the URL. - */ -export function getMessagesFromUrl( - astro: Pick | Readonly, 'url'> -) { - const messages: MessageObject[] = [] - - // Get error messages - messages.push( - ...astro.url.searchParams.getAll('error').map( - (error) => - ({ - uiMessage: error, - type: 'error', - origin: 'url', - }) as const satisfies MessageObject - ) - ) - - // Get success messages - messages.push( - ...astro.url.searchParams.getAll('success').map( - (success) => - ({ - uiMessage: success, - type: 'success', - origin: 'url', - }) as const satisfies MessageObject - ) - ) - - return messages -} diff --git a/web/src/lib/fileStorage.ts b/web/src/lib/fileStorage.ts deleted file mode 100644 index 4b6e90e..0000000 --- a/web/src/lib/fileStorage.ts +++ /dev/null @@ -1,78 +0,0 @@ -import { createHash } from 'crypto' -import fs from 'node:fs/promises' -import path from 'node:path' - -import { UPLOAD_DIR } from 'astro:env/server' - -/** - * Get the configured upload directory with a subdirectory - */ -function getUploadDir(subDir = ''): { fsPath: string; webPath: string } { - // Get the base upload directory from environment variable - let baseUploadDir = UPLOAD_DIR - - // Determine if the path is absolute or relative - const isAbsolutePath = path.isAbsolute(baseUploadDir) - - // If it's a relative path, resolve it relative to the project root - if (!isAbsolutePath) { - baseUploadDir = path.join(process.cwd(), baseUploadDir) - } - - // For the filesystem path, combine the base dir with the subdirectory - const fsPath = path.join(baseUploadDir, subDir) - - // For dynamic uploads, use the endpoint URL - let webPath = `/files${subDir ? `/${subDir}` : ''}` - - // Normalize paths to ensure proper formatting - webPath = path.normalize(webPath).replace(/\\/g, '/') - webPath = sanitizePath(webPath) - - return { - fsPath: path.normalize(fsPath), - webPath, - } -} - -/** - * Generate a hash from file content - */ -async function generateFileHash(file: File): Promise { - const buffer = await file.arrayBuffer() - const hash = createHash('sha1') - hash.update(Buffer.from(buffer)) - return hash.digest('hex').substring(0, 10) // Use first 10 chars of hash -} - -/** - * Save a file locally and return its web-accessible URL path - */ -export async function saveFileLocally( - file: File, - originalFileName: string, - subDir?: string -): Promise { - const fileBuffer = await file.arrayBuffer() - const fileHash = await generateFileHash(file) - - const fileExtension = path.extname(originalFileName) - const fileName = `${fileHash}${fileExtension}` - - // Use the provided subDir or default to 'services/pictures' - const { fsPath: uploadDir, webPath: webUploadPath } = getUploadDir(subDir ?? 'services/pictures') - - await fs.mkdir(uploadDir, { recursive: true }) - const filePath = path.join(uploadDir, fileName) - await fs.writeFile(filePath, Buffer.from(fileBuffer)) - const url = sanitizePath(`${webUploadPath}/${fileName}`) - return url -} - -function sanitizePath(inputPath: string): string { - let sanitized = inputPath.replace(/\\+/g, '/') - // Collapse multiple slashes, but preserve protocol (e.g., http://) - sanitized = sanitized.replace(/([^:])\/+/g, '$1/') - sanitized = sanitized.replace(/\/(\?|#|$)/g, '$1') - return sanitized -} diff --git a/web/src/lib/formInputs.ts b/web/src/lib/formInputs.ts deleted file mode 100644 index 9c940a2..0000000 --- a/web/src/lib/formInputs.ts +++ /dev/null @@ -1,9 +0,0 @@ -export const baseInputClassNames = { - input: - 'bg-night-600 block placeholder:text-sm placeholder:text-day-600 text-day-100 w-full min-w-0 rounded-lg border border-night-400 px-3 leading-none h-9', - div: 'bg-night-600 rounded-lg border border-night-400 text-sm', - error: 'border-red-500 focus:border-red-500 focus:ring-red-500', - disabled: 'cursor-not-allowed', - textarea: 'resize-y min-h-16', - file: 'file:bg-day-700 file:text-day-100 hover:file:bg-day-600 file:mr-4 file:rounded-md file:border-0 file:px-4 file:py-2 file:text-sm file:font-medium h-12 p-1.25', -} as const satisfies Record diff --git a/web/src/lib/honeypot.ts b/web/src/lib/honeypot.ts deleted file mode 100644 index 70fd606..0000000 --- a/web/src/lib/honeypot.ts +++ /dev/null @@ -1,40 +0,0 @@ -import { ActionError } from 'astro:actions' - -import { prisma } from './prisma' - -export const handleHoneypotTrap = async >({ - input, - honeyPotTrapField, - userId, - location, - dontMarkAsSpammer = false, -}: { - input: T - honeyPotTrapField: keyof T - userId: number | null | undefined - location: string - dontMarkAsSpammer?: boolean -}) => { - if (!input[honeyPotTrapField]) return - - if (!dontMarkAsSpammer && !!userId) { - await prisma.user.update({ - where: { - id: userId, - }, - data: { - spammer: true, - internalNotes: { - create: { - content: `Marked as spammer because it fell for the honey pot trap in: ${location}`, - }, - }, - }, - }) - } - - throw new ActionError({ - message: 'Invalid request', - code: 'BAD_REQUEST', - }) -} diff --git a/web/src/lib/impersonation.ts b/web/src/lib/impersonation.ts deleted file mode 100644 index 2bd4e2e..0000000 --- a/web/src/lib/impersonation.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { redisImpersonationSessions } from './redis/redisImpersonationSessions' - -import type { APIContext, AstroCookies } from 'astro' - -const IMPERSONATION_SESSION_COOKIE = 'impersonation_session_id' - -export async function startImpersonating( - context: Pick, - adminUser: NonNullable, - targetUser: NonNullable -) { - const sessionId = await redisImpersonationSessions.store({ - adminId: adminUser.id, - targetId: targetUser.id, - }) - - context.cookies.set(IMPERSONATION_SESSION_COOKIE, sessionId, { - path: '/', - secure: true, - httpOnly: true, - sameSite: 'strict', - maxAge: redisImpersonationSessions.expirationTime, - }) - context.locals.user = targetUser - context.locals.actualUser = adminUser -} - -export async function stopImpersonating(context: Pick) { - const sessionId = context.cookies.get(IMPERSONATION_SESSION_COOKIE)?.value - await redisImpersonationSessions.delete(sessionId) - context.cookies.delete(IMPERSONATION_SESSION_COOKIE) - context.locals.user = context.locals.actualUser - context.locals.actualUser = null -} - -export async function getImpersonationInfo(cookies: AstroCookies) { - const sessionId = cookies.get(IMPERSONATION_SESSION_COOKIE)?.value - return await redisImpersonationSessions.get(sessionId) -} diff --git a/web/src/lib/karmaUnlocks.ts b/web/src/lib/karmaUnlocks.ts deleted file mode 100644 index 8c1c92a..0000000 --- a/web/src/lib/karmaUnlocks.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { karmaUnlocksById, type KarmaUnlockInfo } from '../constants/karmaUnlocks' - -export type KarmaUnlocks = { - [K in keyof typeof karmaUnlocksById]: boolean -} - -export function computeKarmaUnlocks(karma: number) { - return Object.fromEntries( - Object.entries(karmaUnlocksById).map(([key, value]) => [ - key, - value.karma >= 0 ? karma >= value.karma : karma <= value.karma, - ]) - ) as KarmaUnlocks -} - -export function makeUserWithKarmaUnlocks(user: null): null -export function makeUserWithKarmaUnlocks( - user: T -): T & { karmaUnlocks: KarmaUnlocks } -export function makeUserWithKarmaUnlocks( - user: T | null -): (T & { karmaUnlocks: KarmaUnlocks }) | null -export function makeUserWithKarmaUnlocks(user: T | null) { - return user ? { ...user, karmaUnlocks: computeKarmaUnlocks(user.totalKarma) } : null -} - -export function makeKarmaUnlockMessage(karmaUnlock: KarmaUnlockInfo) { - return `You need ${karmaUnlock.karma.toLocaleString()} karma to ${karmaUnlock.verb}.` as const -} diff --git a/web/src/lib/makeHelpersForOptions.ts b/web/src/lib/makeHelpersForOptions.ts deleted file mode 100644 index 38714f6..0000000 --- a/web/src/lib/makeHelpersForOptions.ts +++ /dev/null @@ -1,144 +0,0 @@ -import { uniqBy } from 'lodash-es' - -import { zodEnumFromConstant } from './arrays' -import { typedGroupBy, type TypedGroupBy } from './objects' - -import type { ZodEnum } from 'astro/zod' - -/** - * Creates utility functions to work with an array of options. - * Primarily a `getFn` and `useGetHook`, that return the option object based on the key, or a fallback value if the key is not found. - * - * @param dataArray - Array of objects, must be defined using `as const` to ensure type safety. - * @param key - The key to group the array by - */ -export function makeHelpersForOptions< - K extends string, - Fallback extends Record & - Record & { slug?: string | null | undefined }, - TArray extends readonly (Fallback & Record)[], - HasSlugs extends boolean = TArray extends Record<'slug', string>[] ? true : false, ->(key: K, makeFallback: (key: string | null | undefined) => Fallback, dataArray: TArray) { - const hasDuplicateIds = uniqBy(dataArray, key).length !== dataArray.length - if (hasDuplicateIds) { - throw new Error(`[makeHelpersForOptions] Duplicate ${key} in dataArray`) - } - - const hasSlugs = dataArray.some((item) => 'slug' in item && typeof item.slug === 'string') - const allSlugsAreDefined = dataArray.every((item) => 'slug' in item && typeof item.slug === 'string') - if (hasSlugs) { - if (!allSlugsAreDefined) { - throw new Error('[makeHelpersForOptions] Some slugs are missing in dataArray') - } - - const hasDuplicateSlugs = uniqBy(dataArray, 'slug').length !== dataArray.length - if (hasDuplicateSlugs) { - throw new Error('[makeHelpersForOptions] Duplicate slug in dataArray') - } - } - - const dataObject = typedGroupBy(dataArray, key) - const dataObjectBySlug = ( - allSlugsAreDefined - ? typedGroupBy(dataArray as TArray extends Record<'slug', string>[] ? TArray : never, 'slug') - : undefined - ) as HasSlugs extends true - ? TypedGroupBy<'slug', TArray extends Record<'slug', string>[] ? TArray[number] : never> - : undefined - - function getFn(id: T): Extract> - function getFn(id: T): Extract> | Fallback - function getFn( - id: T - ): Extract> | Fallback { - return typeof id === 'string' && id in dataObject - ? dataObject[id as unknown as keyof typeof dataObject] - : makeFallback(id) - } - - function getFnSlug(slug: T): Extract> - function getFnSlug( - slug: T - ): Extract> | Fallback - function getFnSlug( - slug: T - ): Extract> | Fallback { - return typeof slug === 'string' && dataObjectBySlug && slug in dataObjectBySlug - ? (dataObjectBySlug as NonNullable)[ - slug as unknown as keyof NonNullable - ] - : makeFallback(null) - } - - // const useGetHook: typeof getFn = ((status: any) => { - // return useMemo(() => getFn(status), [status]) - // }) as typeof getFn - - const exposedMakeFallback = , K>>( - id: Parameters[0], - options?: O - ) => { - return { - ...makeFallback(id), - ...options, - } as Fallback & O - } - - const zodEnumById = zodEnumFromConstant(dataArray, key) - const zodEnumBySlug = ( - allSlugsAreDefined - ? zodEnumFromConstant(dataArray as TArray extends Record<'slug', string>[] ? TArray : never, 'slug') - : undefined - ) as HasSlugs extends true ? ZodEnum<[TArray[number]['slug'], ...TArray[number]['slug'][]]> : undefined - - function slugToKey(slug: T): Extract>[K] - function slugToKey( - slug: T - ): Extract>[K] | undefined - function slugToKey( - slug: T - ): Extract>[K] | undefined { - return typeof slug === 'string' && dataObjectBySlug && slug in dataObjectBySlug - ? ((dataObjectBySlug as NonNullable)[ - slug as unknown as keyof NonNullable - ][key] as unknown as Extract>[K]) - : undefined - } - - function keyToSlug(slug: T): Extract>['slug'] - function keyToSlug( - slug: T - ): Extract>['slug'] | undefined - function keyToSlug( - slug: T - ): Extract>['slug'] | undefined { - return typeof slug === 'string' && slug in dataObject - ? (dataObject[slug as unknown as keyof NonNullable][key] as unknown as Extract< - TArray[number], - Record - >['slug']) - : undefined - } - - return { - dataArray, - dataObject, - /** Gets the info by key, if not found, returns a fallback value */ - getFn, - /** Gets the info by key, if not found, returns a fallback value */ - // useGetHook: useGetHook, - /** Generates a fallback value */ - makeFallback: exposedMakeFallback, - zodEnumById, - - dataObjectBySlug, - /** Gets the info by slug, if not found, returns a fallback value */ - getFnSlug, - zodEnumBySlug, - - /** Gets the id by slug, if not found, returns undefined */ - slugToKey, - /** Gets the slug by id, if not found, returns undefined */ - keyToSlug, - } -} diff --git a/web/src/lib/markdown.ts b/web/src/lib/markdown.ts deleted file mode 100644 index f7b5c47..0000000 --- a/web/src/lib/markdown.ts +++ /dev/null @@ -1,5 +0,0 @@ -/** A string containing Markdown. */ -export type MarkdownString = string - -/** A string containing HTML. */ -export type HtmlString = string diff --git a/web/src/lib/notificationPreferences.ts b/web/src/lib/notificationPreferences.ts deleted file mode 100644 index 5e3e327..0000000 --- a/web/src/lib/notificationPreferences.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { prisma } from './prisma' - -import type { Prisma } from '@prisma/client' - -export async function getOrCreateNotificationPreferences( - userId: number, - select: { [K in keyof T]: K extends keyof Prisma.NotificationPreferencesSelect ? T[K] : never }, - tx: Prisma.TransactionClient = prisma -) { - return ( - (await tx.notificationPreferences.findUnique({ where: { userId }, select })) ?? - (await tx.notificationPreferences.create({ data: { userId }, select })) - ) -} diff --git a/web/src/lib/notifications.ts b/web/src/lib/notifications.ts deleted file mode 100644 index 8ced794..0000000 --- a/web/src/lib/notifications.ts +++ /dev/null @@ -1,295 +0,0 @@ -import { accountStatusChangesById } from '../constants/accountStatusChange' -import { commentStatusChangesById } from '../constants/commentStatusChange' -import { eventTypesById } from '../constants/eventTypes' -import { serviceVerificationStatusChangesById } from '../constants/serviceStatusChange' -import { serviceSuggestionStatusChangesById } from '../constants/suggestionStatusChange' - -import { makeCommentUrl } from './commentsWithReplies' - -import type { Prisma } from '@prisma/client' - -export function makeNotificationTitle( - notification: Prisma.NotificationGetPayload<{ - select: { - type: true - aboutAccountStatusChange: true - aboutCommentStatusChange: true - aboutServiceVerificationStatusChange: true - aboutSuggestionStatusChange: true - aboutComment: { - select: { - author: { select: { id: true } } - status: true - parent: { - select: { - author: { - select: { - id: true - } - } - } - } - service: { - select: { - name: true - } - } - } - } - aboutServiceSuggestion: { - select: { - status: true - service: { - select: { - name: true - } - } - } - } - aboutServiceSuggestionMessage: { - select: { - suggestion: { - select: { - service: { - select: { - name: true - } - } - } - } - } - } - aboutEvent: { - select: { - type: true - service: { - select: { - name: true - } - } - } - } - aboutService: { - select: { - name: true - verificationStatus: true - } - } - } - }>, - user: Prisma.UserGetPayload<{ select: { id: true } }> | null -): string { - switch (notification.type) { - case 'COMMENT_STATUS_CHANGE': { - if (!notification.aboutComment) return 'A comment you are watching had a status change' - - if (!notification.aboutCommentStatusChange) { - return `Comment on ${notification.aboutComment.service.name} had a status change` - } - const statusChange = commentStatusChangesById[notification.aboutCommentStatusChange] - const serviceName = notification.aboutComment.service.name - const isOwnComment = !!user && notification.aboutComment.author.id === user.id - const prefix = isOwnComment ? 'Your comment' : 'Watched comment' - - return `${prefix} on ${serviceName} ${statusChange.notificationTitle}` - } - case 'REPLY_COMMENT_CREATED': { - if (!notification.aboutComment) return 'You have a new reply' - const serviceName = notification.aboutComment.service.name - if (!notification.aboutComment.parent) { - return `New reply to a comment on ${serviceName}` - } - const isOwnParentComment = !!user && notification.aboutComment.parent.author.id === user.id - return isOwnParentComment - ? `New reply to your comment on ${serviceName}` - : `New reply to a watched comment on ${serviceName}` - } - case 'COMMUNITY_NOTE_ADDED': { - if (!notification.aboutComment) return 'A community note was added' - const serviceName = notification.aboutComment.service.name - const isOwnComment = !!user && notification.aboutComment.author.id === user.id - return isOwnComment - ? `Community note added to your comment on ${serviceName}` - : `Community note added to a watched comment on ${serviceName}` - } - case 'ROOT_COMMENT_CREATED': { - if (!notification.aboutComment) return 'New comment' - const service = notification.aboutComment.service.name - return notification.aboutComment.status == 'PENDING' - ? `New unmoderated comment on ${service}` - : `New comment on ${service}` - } - case 'SUGGESTION_MESSAGE': { - if (!notification.aboutServiceSuggestionMessage) return 'New message on your suggestion' - const service = notification.aboutServiceSuggestionMessage.suggestion.service.name - return `New message for ${service} suggestion` - } - case 'SUGGESTION_STATUS_CHANGE': { - if (!notification.aboutServiceSuggestion) return 'Suggestion status updated' - const service = notification.aboutServiceSuggestion.service.name - if (!notification.aboutSuggestionStatusChange) { - return `${service} suggestion status updated` - } - const statusChange = serviceSuggestionStatusChangesById[notification.aboutSuggestionStatusChange] - return `${service} suggestion ${statusChange.notificationTitle}` - } - // TODO: [KARMA_UNLOCK] Will be added later, when karma unloks are in the database, not in the code. - // case 'KARMA_UNLOCK': { - // return 'New karma level unlocked' - // } - case 'ACCOUNT_STATUS_CHANGE': { - if (!notification.aboutAccountStatusChange) return 'Your account status has been updated' - const accountStatusChange = accountStatusChangesById[notification.aboutAccountStatusChange] - return accountStatusChange.notificationTitle - } - case 'EVENT_CREATED': { - if (!notification.aboutEvent) return 'New event on a service' - const service = notification.aboutEvent.service.name - const eventType = eventTypesById[notification.aboutEvent.type].label - return `${eventType} event on ${service}` - } - case 'SERVICE_VERIFICATION_STATUS_CHANGE': { - if (!notification.aboutService) return 'Service verification status updated' - const serviceName = notification.aboutService.name - if (!notification.aboutServiceVerificationStatusChange) { - return `${serviceName} verification status updated` - } - const statusChange = - serviceVerificationStatusChangesById[notification.aboutServiceVerificationStatusChange] - return `${serviceName} ${statusChange.notificationTitle}` - } - } -} - -export function makeNotificationContent( - notification: Prisma.NotificationGetPayload<{ - select: { - type: true - aboutComment: { - select: { - content: true - communityNote: true - } - } - aboutServiceSuggestionMessage: { - select: { - content: true - } - } - aboutEvent: { - select: { - title: true - } - } - } - }> -): string | null { - switch (notification.type) { - // TODO: [KARMA_UNLOCK] Will be added later, when karma unloks are in the database, not in the code. - // case 'KARMA_UNLOCK': - case 'SUGGESTION_STATUS_CHANGE': - case 'ACCOUNT_STATUS_CHANGE': - case 'SERVICE_VERIFICATION_STATUS_CHANGE': { - return null - } - case 'COMMENT_STATUS_CHANGE': - case 'REPLY_COMMENT_CREATED': - case 'ROOT_COMMENT_CREATED': { - if (!notification.aboutComment) return null - return notification.aboutComment.content - } - case 'COMMUNITY_NOTE_ADDED': { - if (!notification.aboutComment) return null - return notification.aboutComment.communityNote - } - case 'SUGGESTION_MESSAGE': { - if (!notification.aboutServiceSuggestionMessage) return null - return notification.aboutServiceSuggestionMessage.content - } - case 'EVENT_CREATED': { - if (!notification.aboutEvent) return null - return notification.aboutEvent.title - } - } -} - -export function makeNotificationLink( - notification: Prisma.NotificationGetPayload<{ - select: { - type: true - aboutComment: { - select: { - id: true - service: { - select: { - slug: true - } - } - } - } - aboutServiceSuggestionId: true - aboutServiceSuggestionMessage: { - select: { - id: true - suggestion: { - select: { - id: true - } - } - } - } - aboutEvent: { - select: { - service: { - select: { - slug: true - } - } - } - } - aboutService: { - select: { - slug: true - } - } - } - }>, - origin: string -): string | null { - switch (notification.type) { - case 'COMMENT_STATUS_CHANGE': - case 'REPLY_COMMENT_CREATED': - case 'COMMUNITY_NOTE_ADDED': - case 'ROOT_COMMENT_CREATED': { - if (!notification.aboutComment) return null - return makeCommentUrl({ - serviceSlug: notification.aboutComment.service.slug, - commentId: notification.aboutComment.id, - origin, - }) - } - case 'SUGGESTION_MESSAGE': { - if (!notification.aboutServiceSuggestionMessage) return null - return `${origin}/service-suggestion/${String(notification.aboutServiceSuggestionMessage.suggestion.id)}#message-${String(notification.aboutServiceSuggestionMessage.id)}` - } - case 'SUGGESTION_STATUS_CHANGE': { - if (!notification.aboutServiceSuggestionId) return null - return `${origin}/service-suggestion/${String(notification.aboutServiceSuggestionId)}` - } - // TODO: [KARMA_UNLOCK] Will be added later, when karma unloks are in the database, not in the code. - // case 'KARMA_UNLOCK': { - // return `${origin}/account#karma-unlocks` - // } - case 'ACCOUNT_STATUS_CHANGE': { - return `${origin}/account#account-status` - } - case 'EVENT_CREATED': { - if (!notification.aboutEvent) return null - return `${origin}/service/${notification.aboutEvent.service.slug}#events` - } - case 'SERVICE_VERIFICATION_STATUS_CHANGE': { - if (!notification.aboutService) return null - return `${origin}/service/${notification.aboutService.slug}#verification` - } - } -} diff --git a/web/src/lib/numbers.ts b/web/src/lib/numbers.ts deleted file mode 100644 index 74cea85..0000000 --- a/web/src/lib/numbers.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { round } from 'lodash-es' - -export function parseIntWithFallback(value: unknown, fallback: F = null as F) { - const parsed = Number(value) - if (!Number.isInteger(parsed)) return fallback - return parsed -} - -/** - * Interpolates a value between a start and end value. - * @param value - The value to interpolate. - * @param start - The start value. - * @param end - The end value. - * @returns The interpolated value. - */ -export function interpolate(value: number, start: number, end: number) { - return start + (end - start) * value -} - -export type FormatNumberOptions = Intl.NumberFormatOptions & { - roundDigits?: number - showSign?: boolean - removeTrailingZeros?: boolean -} - -export function formatNumber( - value: number, - { roundDigits = 0, showSign = true, removeTrailingZeros = true, ...formatOptions }: FormatNumberOptions = {} -) { - const rounded = round(value, roundDigits) - const formatted = rounded.toLocaleString(undefined, formatOptions) - const withoutTrailingZeros = removeTrailingZeros ? formatted.replace(/\.0+$/, '') : formatted - const withSign = showSign && value > 0 ? `+${withoutTrailingZeros}` : withoutTrailingZeros - return withSign -} diff --git a/web/src/lib/objects.ts b/web/src/lib/objects.ts deleted file mode 100644 index 7a593ec..0000000 --- a/web/src/lib/objects.ts +++ /dev/null @@ -1,164 +0,0 @@ -/* eslint-disable @typescript-eslint/no-explicit-any */ -import { isEqualWith } from 'lodash-es' - -import { areEqualArraysWithoutOrder } from './arrays' - -import type { Prettify } from 'ts-essentials' -import type TB from 'ts-toolbelt' - -export function removeUndefined(obj: Record) { - return Object.fromEntries(Object.entries(obj).filter(([, v]) => v !== undefined)) -} - -type RemoveUndefinedProps> = { - [key in keyof T]-?: Exclude -} - -/** - * Assigns properties from `obj2` to `obj1`, but only if they are defined in `obj2`. - * @example - * assignDefinedOnly({ a: 1, b: 2}, { a: undefined, b: 3, c: 4 }) // result = { a: 1, b: 3, c: 4 } - */ -export const assignDefinedOnly = , T2 extends Record>( - obj1: T1, - obj2: T2 -) => { - return { ...obj1, ...removeUndefined(obj2) } as Omit, keyof T1> & - Omit & { - [key in keyof T1 & keyof T2]-?: undefined extends T2[key] - ? Exclude | T1[key] - : T2[key] - } -} - -export type Paths = T extends object - ? { - [K in keyof T]: `${Exclude}${'' | `.${Paths}`}` - }[keyof T] - : never - -export type PathValue = TB.Object.Path> - -export type Leaves = T extends object - ? { - [K in keyof T]: `${Exclude}${Leaves extends never ? '' : `.${Leaves}`}` - }[keyof T] - : never - -// Start of paths with nested -type Digit = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 -type NextDigit = [1, 2, 3, 4, 5, 6, 7, 'STOP'] -type Inc = T extends Digit ? NextDigit[T] : 'STOP' -type StringOrNumKeys = TObj extends unknown[] ? 0 : string & keyof TObj -type NestedPath = TValue extends object - ? `${Prefix}.${TDepth extends 'STOP' ? string : NestedFieldPaths}` - : never -type GetValue = T extends unknown[] - ? K extends number - ? T[K] - : never - : K extends keyof T - ? T[K] - : never -type NestedFieldPaths = { - [TKey in StringOrNumKeys]: - | NestedPath, `${TKey}`, TValue, Inc> - | (GetValue extends TValue ? `${TKey}` : never) -}[StringOrNumKeys] -export type PathsWithNested = TData extends any ? NestedFieldPaths : never -// End of paths with nested - -export type TypedGroupBy & Record> = { - [Id in T[K]]: Extract> -} - -/** - * Converts an array of objects to an object with the key as the id and the value as the object. - * @example - * typedGroupBy([ - * { id: 'a', name: 'Letter A' }, - * { id: 'b', name: 'Letter B' } - * ] as const, 'id') - * // result = { - * // a: { id: 'a', name: 'Letter A' }, - * // b: { id: 'b', name: 'Letter B' } - * // } - */ -export const typedGroupBy = & Record>( - array: T[] | readonly T[], - key: K -) => { - return Object.fromEntries(array.map((option) => [option[key], option])) as TypedGroupBy -} - -/** - * Merges two objects, so that each property is the union of that property from each object. - * - If a key is present in only one of the objects, it becomes optional. - * - If an object is undefined, the other object is returned. - * - * To {@link UnionizeTwo} more than two objects, use {@link Unionize}. - * - * @example - * UnionizeTwo<{ a: 1, shared: 1 }, { b: 2, shared: 2 }> // { a?: 1, b?: 2, shared: 1 | 2 } - */ -export type UnionizeTwo< - T1 extends Record | undefined, - T2 extends Record | undefined, -> = keyof T1 extends undefined - ? T2 - : keyof T2 extends undefined - ? T1 - : { - [K in Exclude]+?: - | (K extends keyof T1 ? T1[K] : never) - | (K extends keyof T2 ? T2[K] : never) - } & { - [K in keyof T1 & keyof T2]-?: T1[K] | T2[K] - } - -/** - * Merges multiple objects, so that each property is the union of that property from each object. - * - If a key is present in only one of the objects, it becomes optional. - * - If an object is undefined, it is ignored. - * - If no objects are provided, `undefined` is returned. - * - * Internally, it uses {@link UnionizeTwo} recursively. - * - * @example - * Unionize<[ - * { a: 1, shared: 1 }, - * { b: 2, shared: 2 }, - * { a: 3, shared: 3 } - * ]> - * // result = { - * // a?: 1 | 3, - * // b?: 2, - * // shared: 1 | 2 | 3 - * // } - */ -export type Unionize[]> = Prettify< - T extends [] - ? undefined - : T extends [infer First, ...infer Rest] - ? Rest extends Record[] - ? First extends Record - ? UnionizeTwo> - : undefined - : First - : undefined -> - -/** - * Checks if two objects are equal without considering order in arrays. - * @example - * areEqualObjectsWithoutOrder({ a: [1, 2], b: 3 }, { b: 3, a: [2, 1] }) // true - */ -export function areEqualObjectsWithoutOrder>( - a: T, - b: Record -): b is T { - return isEqualWith(a, b, (a, b) => { - if (Array.isArray(a) && Array.isArray(b)) return areEqualArraysWithoutOrder(a, b) - return undefined - }) -} diff --git a/web/src/lib/onload.ts b/web/src/lib/onload.ts deleted file mode 100644 index f0d7ebc..0000000 --- a/web/src/lib/onload.ts +++ /dev/null @@ -1,8 +0,0 @@ -import type { Tail } from 'ts-essentials' - -export function addOnLoadEventListener( - ...args: Tail>> -) { - document.addEventListener('astro:page-load', ...args) - document.addEventListener('htmx:afterSwap', ...args) -} diff --git a/web/src/lib/parseUrlFilters.ts b/web/src/lib/parseUrlFilters.ts deleted file mode 100644 index 1b1f37f..0000000 --- a/web/src/lib/parseUrlFilters.ts +++ /dev/null @@ -1,311 +0,0 @@ -import { z } from 'astro/zod' -import { isEqual, omit } from 'lodash-es' - -import { areEqualObjectsWithoutOrder } from './objects' -import { getObjectSearchParam, makeObjectSearchParamKeyRegex } from './urls' - -import type { APIContext, AstroGlobal } from 'astro' -import type { ZodError, ZodType, ZodTypeDef } from 'astro/zod' - -type MyZodUnknown = ZodType< - Output, - Def, - Input -> - -type ZodParseFromUrlOptions = { - allOptional?: boolean -} - -/** - * Parses an array of values from a URL with zod. - * - * The wrong values are skipped, and the errors are returned. - * - * @example - * ```ts - * const schema = z.array(z.enum(['S', 'M', 'L', 'XL'])) - * const urlValue = ['wrong', 'M', 'L'] - * const { data, errors } = zodParseArray(schema, urlValue) - * // data: ['M', 'L'] - * // errors: [{ key: 0, error: ZodError }] - * ``` - */ -function zodParseArray(schema: T, urlValue: string[] | readonly string[]) { - const unwrappedSchema = unwrapSchema(schema, { - default: true, - optional: true, - nullable: true, - }) - const itemSchema = - unwrappedSchema instanceof z.ZodArray ? (unwrappedSchema as z.ZodArray).element : undefined - - if (!itemSchema || urlValue.length === 0) { - const parsedArray = schema.safeParse( - schema instanceof z.ZodDefault && urlValue.length === 0 ? undefined : urlValue - ) - return parsedArray.success - ? { - data: parsedArray.data, - errors: [], - } - : { - data: schema instanceof z.ZodOptional ? undefined : [], - errors: [{ key: 0, error: parsedArray.error }], - } - } - - const parsedItems = urlValue.map((item) => itemSchema.safeParse(item)) - - return { - data: parsedItems.filter((parsed) => parsed.success).map((r) => r.data), - errors: parsedItems.filter((parsed) => !parsed.success).map((r, i) => ({ key: i, error: r.error })), - } -} - -/** - * Parses the query params of a URL with zod. - * - * The wrong values are set to `undefined`, and the errors are returned. - * - * @example - * ```ts - * const params = new URLSearchParams('sizes=M&sizes=L&max-price=wrong') - * const schema = { - * sizes: z.array(z.enum(['S', 'M', 'L', 'XL'])), - * 'max-price': z.coerce.number(), - * 'min-price': z.coerce.number().default(0), - * } - * const { data, errors } = zodParseQueryParams(schema, params) - * // data: - * // { - * // sizes: ['M', 'L'], - * // 'max-price': undefined, - * // 'min-price': 0 - * // } - * // errors: [{ key: 'max-price', error: ZodError }] - * ``` - */ -export function zodParseQueryParams, O extends ZodParseFromUrlOptions>( - shape: T, - params: URLSearchParams, - options?: O -) { - const errors: { key: string; error: ZodError }[] = [] - - const data = Object.fromEntries( - Object.entries(shape).map(([key, paramSchema]) => { - const schema = - !(paramSchema instanceof z.ZodDefault || paramSchema instanceof z.ZodEffects) && - options?.allOptional !== false - ? paramSchema.optional() - : paramSchema - const unwrappedSchema = unwrapSchema(schema, { - default: true, - optional: true, - nullable: true, - }) - - if (unwrappedSchema instanceof z.ZodArray) { - const parsed = zodParseArray(schema, params.getAll(key)) - const firstError = parsed.errors[0] - if (firstError) errors.push({ key, error: firstError.error }) - - return [key, parsed.data] - } - // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - const urlStringValue = params.get(key) || undefined - const urlValue = - unwrappedSchema instanceof z.ZodArray - ? params.getAll(key) - : unwrappedSchema instanceof z.ZodObject || unwrappedSchema instanceof z.ZodRecord - ? getObjectSearchParam(params, key) - : urlStringValue - - const parsed = schema.safeParse(urlValue) - if (!parsed.success) { - errors.push({ key, error: parsed.error }) - return [key, paramSchema.safeParse(undefined).data] - } - - return [key, parsed.data] - }) - ) as { - [K in keyof T]: ReturnType< - (O['allOptional'] extends false - ? T[K] - : // eslint-disable-next-line @typescript-eslint/no-explicit-any - T[K] extends z.ZodArray | z.ZodDefault | z.ZodEffects - ? T[K] - : z.ZodOptional)['parse'] - > - } - - return { data, errors } -} - -type CleanUrlOptions = { - removeUneededObjectParams?: boolean - removeParams?: { - [K in T]?: { if: 'another-is-unset'; prop: K } | { if: 'default' } - } -} - -/** - * Parses the query params of the current URL with zod and stores the errors in the context. - * - * Wrong values are set to `undefined`, and the errors stored in `Astro.locals.banners`. - * - * @example - * ```ts - * const schema = { - * sizes: z.array(z.enum(['S', 'M', 'L', 'XL'])), - * 'max-price': z.coerce.number(), - * 'min-price': z.coerce.number().default(0), - * } - * const data = zodParseQueryParamsStoringErrors(schema, Astro) - * // data: - * // { - * // sizes: ['M', 'L'], - * // 'max-price': undefined, - * // 'min-price': 0 - * // } - * // And 1 error stored in Astro.locals.banners (`max-price`). - * ``` - */ -export function zodParseQueryParamsStoringErrors< - K extends string, - T extends Record, - O extends ZodParseFromUrlOptions & { - ignoredKeysForDefaultData?: K[] - cleanUrl?: CleanUrlOptions - }, - C extends Pick | Readonly, 'locals' | 'url'>, ->(shape: T, context: C, options?: O) { - const { data, errors } = zodParseQueryParams(shape, context.url.searchParams, options) - context.locals.banners.add( - ...errors.map( - (error) => - ({ - uiMessage: `Error in the ${error.key} filter. Using default value.`, - type: 'error', - error: error.error, - origin: 'custom_filters', - }) as const - ) - ) - - const defaultDataWithoutIgnoringKeys = zodParseQueryParams(shape, new URLSearchParams(), options).data - const defaultData = omit(defaultDataWithoutIgnoringKeys, options?.ignoredKeysForDefaultData ?? []) - const hasDefaultData = areEqualObjectsWithoutOrder( - omit(data, options?.ignoredKeysForDefaultData ?? []), - defaultData - ) - - const redirectUrl = makeCleanUrl(shape, context.url, options?.cleanUrl, data, defaultData) - - return { data, defaultData, hasDefaultData, errors, schema: shape, redirectUrl } -} - -function unwrapSchema( - schema: T, - options: { - default?: boolean - optional?: boolean - nullable?: boolean - array?: boolean - } = {} -) { - if (options.default && schema instanceof z.ZodDefault) { - return unwrapSchema((schema as z.ZodDefault).removeDefault(), options) - } - if (options.optional && schema instanceof z.ZodOptional) { - return unwrapSchema((schema as z.ZodOptional).unwrap(), options) - } - if (options.nullable && schema instanceof z.ZodNullable) { - return unwrapSchema((schema as z.ZodNullable).unwrap(), options) - } - if (options.array && schema instanceof z.ZodArray) { - return unwrapSchema((schema as z.ZodArray).element, options) - } - - return schema -} - -function makeCleanUrl>( - shape: T, - url: URL, - options?: CleanUrlOptions, - data?: Record, - defaultData?: Record -) { - if (!options) return null - - const paramsToRemove = [ - ...(options.removeUneededObjectParams ? getUneededObjectParams(shape, url) : []), - ...(options.removeParams ? getParamsToRemove(shape, url, options.removeParams, data, defaultData) : []), - ] - if (!paramsToRemove.length) return null - - const cleanUrl = new URL(url) - paramsToRemove.forEach(([key, value]) => { - cleanUrl.searchParams.delete(key, value) - }) - return cleanUrl -} - -function getUneededObjectParams>(shape: T, url: URL) { - const objectParamsRegex = Object.entries(shape) - .filter(([_key, paramSchema]) => { - const schema = unwrapSchema(paramSchema, { - default: true, - optional: true, - nullable: true, - }) - return schema instanceof z.ZodObject || schema instanceof z.ZodRecord - }) - .map(([key]) => makeObjectSearchParamKeyRegex(key)) - if (!objectParamsRegex.length) return [] - - const uneededParams = url.searchParams - .entries() - .filter(([key, value]) => objectParamsRegex.some((regex) => regex.test(key)) && value === '') - .toArray() - - return uneededParams -} - -function getParamsToRemove>( - shape: T, - url: URL, - removeParams: NonNullable['removeParams']>, - data?: Record, - defaultData?: Record -) { - return url.searchParams - .entries() - .filter(([key]) => { - const options = key in removeParams ? removeParams[key as K] : undefined - if (!options) return false - - const paramSchema = key in shape ? shape[key as K] : undefined - if (!paramSchema) return false - - switch (options.if) { - case 'another-is-unset': { - return !url.searchParams - .keys() - .some((key2) => key2 === options.prop || makeObjectSearchParamKeyRegex(options.prop).test(key2)) - } - case 'default': { - const dataValue = data && key in data ? data[key as K] : undefined - const defaultDataValue = defaultData && key in defaultData ? defaultData[key as K] : undefined - return isEqual(dataValue, defaultDataValue) - } - default: { - return false - } - } - }) - .toArray() -} diff --git a/web/src/lib/pluralize.ts b/web/src/lib/pluralize.ts deleted file mode 100644 index 43663cf..0000000 --- a/web/src/lib/pluralize.ts +++ /dev/null @@ -1,125 +0,0 @@ -import { transformCase } from './strings' - -const knownPlurals = { - is: { - singular: 'Is', - plural: 'Are', - }, - service: { - singular: 'Service', - plural: 'Services', - }, - user: { - singular: 'User', - plural: 'Users', - }, - note: { - singular: 'Note', - plural: 'Notes', - }, - result: { - singular: 'Result', - plural: 'Results', - }, - request: { - singular: 'Request', - plural: 'Requests', - }, - something: { - singular: 'Something', - plural: 'Somethings', - }, -} as const satisfies Record< - string, - { - singular: string - plural: string - } -> - -type KnownPlural = keyof typeof knownPlurals - -const synonyms = { - are: 'is', -} as const satisfies Record - -type Synonym = keyof typeof synonyms - -export type KnownPluralOrSynonym = KnownPlural | Synonym - -function isKnownPlural(key: string): key is KnownPlural { - return key in knownPlurals -} - -function isKnownPluralSynonym(key: string): key is Synonym { - return key in synonyms -} - -/** - * Formats name into singular or plural form, and case type. - * - * @param entity - Entity name or synonym. - * @param count - Number of entities. - * @param caseType - Case type to apply to the entity name. - */ -export function pluralize( - entity: T, - count: number | null = 1, - caseType: Exclude[1], 'original'> = 'lower' -) { - return pluralizeGeneric(entity, count, caseType) -} - -/** - * Use {@link pluralize} preferably. - * - * Formats name into singular or plural form, and case type. - * If the provided entity is not from the {@link knownPlurals} object, it will return the string with the case type applied. - * - * @param entity - Entity name or synonym. - * @param count - Number of entities. - * @param caseType - Case type to apply to the entity name. - */ -export function pluralizeGeneric( - entity: T, - count: number | null, - caseType: Exclude[1], 'original'> -): string -export function pluralizeGeneric( - entity: T, - count: number | null, - caseType: Exclude[1], 'original'> -): string -export function pluralizeGeneric( - entity: T, - count: number | null = 1, - caseType: Exclude[1], 'original'> = 'lower' -): string { - const originalEntity = isKnownPluralSynonym(entity) ? synonyms[entity] : entity - if (!isKnownPlural(originalEntity)) { - console.warn(`getEntityName: Unknown entity "${originalEntity}"`) - return transformCase(originalEntity, caseType) - } - const { singular, plural } = knownPlurals[originalEntity] - return pluralizeAny(singular, plural, count, caseType) -} - -/** - * Use {@link pluralize} preferably. - * - * Formats name into singular or plural form, and case type. - * - * @param singular - Singular form of the entity. - * @param plural - Plural form of the entity. - * @param count - Number of entities. - * @param caseType - Case type to apply to the entity name. - */ -export function pluralizeAny( - singular: string, - plural: string, - count: number | null = 1, - caseType: Exclude[1], 'original'> = 'lower' -): string { - const name = count === 1 ? singular : plural - return transformCase(name, caseType) -} diff --git a/web/src/lib/prisma.ts b/web/src/lib/prisma.ts deleted file mode 100644 index ace698a..0000000 --- a/web/src/lib/prisma.ts +++ /dev/null @@ -1,57 +0,0 @@ -/* eslint-disable @typescript-eslint/no-explicit-any */ -import { PrismaClient } from '@prisma/client' - -import type { Prisma } from '@prisma/client' - -const findManyAndCount = { - name: 'findManyAndCount', - model: { - $allModels: { - findManyAndCount( - this: Model, - args: Prisma.Exact> - ): Promise< - [Prisma.Result, number, Args extends { take: number } ? number : undefined] - > { - // eslint-disable-next-line @typescript-eslint/no-unsafe-return - return prisma.$transaction([ - // eslint-disable-next-line @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access - (this as any).findMany(args), - // eslint-disable-next-line @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access - (this as any).count({ where: (args as any).where }), - ]) as any - }, - }, - }, -} - -type FindManyAndCountType = typeof findManyAndCount.model.$allModels.findManyAndCount - -type ModelsWithCustomMethods = { - [Model in keyof PrismaClient]: PrismaClient[Model] extends { - findMany: (...args: any[]) => Promise - } - ? PrismaClient[Model] & { - findManyAndCount: FindManyAndCountType - } - : PrismaClient[Model] -} - -type ExtendedPrismaClient = ModelsWithCustomMethods & PrismaClient - -function prismaClientSingleton(): ExtendedPrismaClient { - const prisma = new PrismaClient().$extends(findManyAndCount) - - return prisma as unknown as ExtendedPrismaClient -} - -declare global { - // eslint-disable-next-line no-var - var prisma: ReturnType | undefined -} - -export const prisma = global.prisma ?? prismaClientSingleton() - -if (process.env.NODE_ENV !== 'production') { - global.prisma = prisma -} diff --git a/web/src/lib/redirectUrls.ts b/web/src/lib/redirectUrls.ts deleted file mode 100644 index 4784947..0000000 --- a/web/src/lib/redirectUrls.ts +++ /dev/null @@ -1,61 +0,0 @@ -export function makeLoginUrl( - currentUrl: URL, - { - redirect, - error, - logout, - message, - }: { - redirect?: URL | string | null - error?: string | null - logout?: boolean - message?: string | null - } = {} -) { - const loginUrl = new URL(currentUrl.origin) - loginUrl.pathname = '/account/login' - - if (error) { - loginUrl.searchParams.set('error', error) - } - - if (logout) { - loginUrl.searchParams.set('logout', 'true') - } - - if (message) { - loginUrl.searchParams.set('message', message) - } - - // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - const redirectUrl = new URL(redirect || currentUrl) - if (redirectUrl.pathname === '/account/login') { - const redirectUrlRedirectParam = redirectUrl.searchParams.get('redirect') - if (redirectUrlRedirectParam) { - loginUrl.searchParams.set('redirect', redirectUrlRedirectParam) - } - } else { - loginUrl.searchParams.set('redirect', redirectUrl.toString()) - } - - return loginUrl.toString() -} - -export function makeUnimpersonateUrl( - currentUrl: URL, - { - redirect, - }: { - redirect?: URL | string | null - } = {} -) { - const url = new URL(currentUrl.origin) - url.pathname = '/account/impersonate' - url.searchParams.set('stop', 'true') - - // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - const redirectUrl = new URL(redirect || currentUrl) - url.searchParams.set('redirect', redirectUrl.toString()) - - return url.toString() -} diff --git a/web/src/lib/redis/redisActionsSessions.ts b/web/src/lib/redis/redisActionsSessions.ts deleted file mode 100644 index 97a7547..0000000 --- a/web/src/lib/redis/redisActionsSessions.ts +++ /dev/null @@ -1,69 +0,0 @@ -import { randomUUID } from 'node:crypto' - -import { deserializeActionResult } from 'astro:actions' -import { z } from 'astro:content' -import { REDIS_ACTIONS_SESSION_EXPIRY_SECONDS } from 'astro:env/server' - -import { RedisGenericManager } from './redisGenericManager' - -const dataSchema = z.object({ - actionName: z.string(), - actionResult: z.union([ - z.object({ - type: z.literal('data'), - contentType: z.literal('application/json+devalue'), - status: z.literal(200), - body: z.string(), - }), - z.object({ - type: z.literal('error'), - contentType: z.literal('application/json'), - status: z.number(), - body: z.string(), - }), - z.object({ - type: z.literal('empty'), - status: z.literal(204), - }), - ]), -}) - -class RedisActionsSessions extends RedisGenericManager { - async store(data: z.input) { - const sessionId = randomUUID() - - const parsedData = dataSchema.parse(data) - await this.redisClient.set(`actions-session:${sessionId}`, JSON.stringify(parsedData), { - EX: this.expirationTime, - }) - - return sessionId - } - - async get(sessionId: string | null | undefined) { - if (!sessionId) return null - - const key = `actions-session:${sessionId}` - - const rawData = await this.redisClient.get(key) - if (!rawData) return null - - const data = dataSchema.parse(JSON.parse(rawData)) - const deserializedActionResult = deserializeActionResult(data.actionResult) - - return { - deserializedActionResult, - ...data, - } - } - - async delete(sessionId: string | null | undefined) { - if (!sessionId) return - - await this.redisClient.del(`actions-session:${sessionId}`) - } -} - -export const redisActionsSessions = await RedisActionsSessions.createAndConnect({ - expirationTime: REDIS_ACTIONS_SESSION_EXPIRY_SECONDS, -}) diff --git a/web/src/lib/redis/redisGenericManager.ts b/web/src/lib/redis/redisGenericManager.ts deleted file mode 100644 index 40afd8f..0000000 --- a/web/src/lib/redis/redisGenericManager.ts +++ /dev/null @@ -1,45 +0,0 @@ -import { REDIS_URL } from 'astro:env/server' -import { createClient } from 'redis' - -type RedisGenericManagerOptions = { - expirationTime: number -} - -export abstract class RedisGenericManager { - protected redisClient - /** The expiration time of the Redis session. In seconds. */ - readonly expirationTime: number - - /** @deprecated Use {@link createAndConnect} instead */ - constructor(options: RedisGenericManagerOptions) { - this.redisClient = createClient({ - url: REDIS_URL, - }) - - this.expirationTime = options.expirationTime - - this.redisClient.on('error', (err) => { - console.error(`[${this.constructor.name}] `, err) - }) - } - - /** Closes the Redis connection */ - async close(): Promise { - await this.redisClient.quit() - } - - /** Connects to the Redis connection */ - async connect(): Promise { - await this.redisClient.connect() - } - - static async createAndConnect( - this: new (options: RedisGenericManagerOptions) => T, - options: RedisGenericManagerOptions - ): Promise { - const instance = new this(options) - - await instance.connect() - return instance - } -} diff --git a/web/src/lib/redis/redisImpersonationSessions.ts b/web/src/lib/redis/redisImpersonationSessions.ts deleted file mode 100644 index 5772966..0000000 --- a/web/src/lib/redis/redisImpersonationSessions.ts +++ /dev/null @@ -1,45 +0,0 @@ -import { randomUUID } from 'node:crypto' - -import { z } from 'astro:content' -import { REDIS_IMPERSONATION_SESSION_EXPIRY_SECONDS } from 'astro:env/server' - -import { RedisGenericManager } from './redisGenericManager' - -const dataSchema = z.object({ - adminId: z.number(), - targetId: z.number(), -}) - -class RedisImpersonationSessions extends RedisGenericManager { - async store(data: z.input) { - const sessionId = randomUUID() - - const parsedData = dataSchema.parse(data) - await this.redisClient.set(`impersonation-session:${sessionId}`, JSON.stringify(parsedData), { - EX: this.expirationTime, - }) - - return sessionId - } - - async get(sessionId: string | null | undefined) { - if (!sessionId) return null - - const key = `impersonation-session:${sessionId}` - - const rawData = await this.redisClient.get(key) - if (!rawData) return null - - return dataSchema.parse(JSON.parse(rawData)) - } - - async delete(sessionId: string | null | undefined) { - if (!sessionId) return - - await this.redisClient.del(`impersonation-session:${sessionId}`) - } -} - -export const redisImpersonationSessions = await RedisImpersonationSessions.createAndConnect({ - expirationTime: REDIS_IMPERSONATION_SESSION_EXPIRY_SECONDS, -}) diff --git a/web/src/lib/redis/redisPreGeneratedSecretTokens.ts b/web/src/lib/redis/redisPreGeneratedSecretTokens.ts deleted file mode 100644 index d9a49cc..0000000 --- a/web/src/lib/redis/redisPreGeneratedSecretTokens.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { REDIS_PREGENERATED_TOKEN_EXPIRY_SECONDS } from 'astro:env/server' - -import { RedisGenericManager } from './redisGenericManager' - -class RedisPreGeneratedSecretTokens extends RedisGenericManager { - /** - * Stores a pre-generated token with expiration - * @param token The pre-generated token - */ - async storePreGeneratedToken(token: string): Promise { - await this.redisClient.set(`pregenerated-user-secret-token:${token}`, '1', { - EX: this.expirationTime, - }) - } - - /** - * Validates and consumes a pre-generated token - * @param token The token to validate - * @returns true if token was valid and consumed, false otherwise - */ - async validateAndConsumePreGeneratedToken(token: string): Promise { - const key = `pregenerated-user-secret-token:${token}` - const exists = await this.redisClient.exists(key) - if (exists) { - await this.redisClient.del(key) - return true - } - return false - } -} - -export const redisPreGeneratedSecretTokens = await RedisPreGeneratedSecretTokens.createAndConnect({ - expirationTime: REDIS_PREGENERATED_TOKEN_EXPIRY_SECONDS, -}) diff --git a/web/src/lib/redis/redisSessions.ts b/web/src/lib/redis/redisSessions.ts deleted file mode 100644 index 80a0102..0000000 --- a/web/src/lib/redis/redisSessions.ts +++ /dev/null @@ -1,78 +0,0 @@ -import { randomBytes } from 'crypto' - -import { REDIS_USER_SESSION_EXPIRY_SECONDS } from 'astro:env/server' - -import { RedisGenericManager } from './redisGenericManager' - -class RedisSessions extends RedisGenericManager { - /** - * Generates a random session ID - */ - private generateSessionId(): string { - return randomBytes(32).toString('hex') - } - - /** - * Creates a new session for a user - * @param userSecretTokenHash The ID of the user - * @returns The generated session ID - */ - async createSession(userSecretTokenHash: string): Promise { - const sessionId = this.generateSessionId() - // Store the session with user ID - await this.redisClient.set(`session:${sessionId}`, userSecretTokenHash, { - EX: this.expirationTime, - }) - - // Store session ID in user's sessions set - await this.redisClient.sAdd(`user:${userSecretTokenHash}:sessions`, sessionId) - - return sessionId - } - - /** - * Gets the user ID associated with a session - * @param sessionId The session ID to look up - * @returns The user ID or null if session not found - */ - async getUserBySessionId(sessionId: string): Promise { - const userSecretTokenHash = await this.redisClient.get(`session:${sessionId}`) - return userSecretTokenHash - } - - /** - * Deletes all sessions for a user - * @param userSecretTokenHash The ID of the user whose sessions should be deleted - */ - async deleteUserSessions(userSecretTokenHash: string): Promise { - // Get all session IDs for the user - const sessionIds = await this.redisClient.sMembers(`user:${userSecretTokenHash}:sessions`) - - if (sessionIds.length > 0) { - // Delete each session - // Delete sessions one by one to avoid type issues with spread operator - for (const sessionId of sessionIds) { - await this.redisClient.del(`session:${sessionId}`) - } - - // Delete the set of user's sessions - await this.redisClient.del(`user:${userSecretTokenHash}:sessions`) - } - } - - /** - * Deletes a specific session - * @param sessionId The session ID to delete - */ - async deleteSession(sessionId: string): Promise { - const userSecretTokenHash = await this.getUserBySessionId(sessionId) - if (userSecretTokenHash) { - await this.redisClient.del(`session:${sessionId}`) - await this.redisClient.sRem(`user:${userSecretTokenHash}:sessions`, sessionId) - } - } -} - -export const redisSessions = await RedisSessions.createAndConnect({ - expirationTime: REDIS_USER_SESSION_EXPIRY_SECONDS, -}) diff --git a/web/src/lib/schema.ts b/web/src/lib/schema.ts deleted file mode 100644 index 44a427a..0000000 --- a/web/src/lib/schema.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { SITE_URL } from 'astro:env/client' - -import type { Organization } from 'schema-dts' - -export const KYCNOTME_SCHEMA_MINI = { - '@type': 'Organization', - name: 'KYCnot.me', - sameAs: SITE_URL, - url: SITE_URL, -} as const satisfies Organization diff --git a/web/src/lib/sortSeed.ts b/web/src/lib/sortSeed.ts deleted file mode 100644 index 03873ff..0000000 --- a/web/src/lib/sortSeed.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { SEARCH_PARAM_CHARACTERS_NO_ESCAPE } from '../constants/characters' -import { getRandom } from '../lib/arrays' - -export const makeSortSeed = () => { - const firstChar = getRandom(SEARCH_PARAM_CHARACTERS_NO_ESCAPE) - const secondChar = getRandom([...SEARCH_PARAM_CHARACTERS_NO_ESCAPE, ''] as const) - return `${firstChar}${secondChar}` -} diff --git a/web/src/lib/strings.ts b/web/src/lib/strings.ts deleted file mode 100644 index ca6dfcd..0000000 --- a/web/src/lib/strings.ts +++ /dev/null @@ -1,68 +0,0 @@ -/* eslint-disable @typescript-eslint/no-explicit-any */ -/** - * Normalize a string by removing accents and converting it to lowercase. - * - * @example - * normalize(' Café') // 'cafe' - */ -const normalize = (str: string): string => { - return str - .normalize('NFD') - .replace(/[\u0300-\u036f]/g, '') - .toLowerCase() - .trim() -} - -/** - * Compare two strings after normalizing them. - */ -export const areSameNormalized = (str1: string, str2: string): boolean => { - return normalize(str1) === normalize(str2) -} - -export type TransformCaseType = 'lower' | 'original' | 'sentence' | 'title' | 'upper' - -/** - * Transform a string to a different case. - * - * @example - * transformCase('hello WORLD', 'lower') // 'hello world' - * transformCase('hello WORLD', 'upper') // 'HELLO WORLD' - * transformCase('hello WORLD', 'sentence') // 'Hello world' - * transformCase('hello WORLD', 'title') // 'Hello World' - * transformCase('hello WORLD', 'original') // 'hello WORLD' - */ -export const transformCase = ( - str: T, - caseType: C -): C extends 'lower' - ? Lowercase - : C extends 'upper' - ? Uppercase - : C extends 'sentence' - ? Capitalize> - : C extends 'title' - ? Capitalize> - : T => { - switch (caseType) { - case 'lower': - // eslint-disable-next-line @typescript-eslint/no-unsafe-return - return str.toLowerCase() as any - case 'upper': - // eslint-disable-next-line @typescript-eslint/no-unsafe-return - return str.toUpperCase() as any - case 'sentence': - // eslint-disable-next-line @typescript-eslint/no-unsafe-return - return (str.charAt(0).toUpperCase() + str.slice(1).toLowerCase()) as any - case 'title': - // eslint-disable-next-line @typescript-eslint/no-unsafe-return - return str - .split(' ') - .map((word) => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase()) - .join(' ') as any - case 'original': - default: - // eslint-disable-next-line @typescript-eslint/no-unsafe-return - return str as any - } -} diff --git a/web/src/lib/timeAgo.ts b/web/src/lib/timeAgo.ts deleted file mode 100644 index 7c5b189..0000000 --- a/web/src/lib/timeAgo.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { addDays, format, isBefore, isToday, isYesterday } from 'date-fns' -import TimeAgo from 'javascript-time-ago' -import en from 'javascript-time-ago/locale/en' - -import { transformCase, type TransformCaseType } from './strings' - -TimeAgo.addDefaultLocale(en) - -export const timeAgo = new TimeAgo('en-US') - -export type FormatDateShortOptions = { - prefix?: boolean - hourPrecision?: boolean - daysUntilDate?: number | null - caseType?: TransformCaseType - hoursShort?: boolean -} - -export function formatDateShort( - date: Date, - { - prefix = true, - hourPrecision = true, - daysUntilDate = null, - caseType, - hoursShort = false, - }: FormatDateShortOptions = {} -) { - const text = (() => { - if (isToday(date)) { - if (hourPrecision) return timeAgo.format(date, hoursShort ? 'twitter-minute-now' : 'round-minute') - return 'today' - } - if (isYesterday(date)) return 'yesterday' - - if (daysUntilDate && isBefore(date, addDays(new Date(), daysUntilDate))) { - return timeAgo.format(date, 'round-minute') - } - - const currentYear = new Date().getFullYear() - const dateYear = date.getFullYear() - const formattedDate = dateYear === currentYear ? format(date, 'MMM d') : format(date, 'MMM d, yyyy') - return prefix ? `on ${formattedDate}` : formattedDate - })() - - if (!caseType) return text - - return transformCase(text, caseType) -} diff --git a/web/src/lib/timeTrapSecret.ts b/web/src/lib/timeTrapSecret.ts deleted file mode 100644 index 5319146..0000000 --- a/web/src/lib/timeTrapSecret.ts +++ /dev/null @@ -1,6 +0,0 @@ -import crypto from 'crypto' - -// Generate a 32-byte secret key once when the module is first loaded -const timeTrapSecretKey = crypto.randomBytes(32) - -export { timeTrapSecretKey } diff --git a/web/src/lib/urls.ts b/web/src/lib/urls.ts deleted file mode 100644 index a35b3c6..0000000 --- a/web/src/lib/urls.ts +++ /dev/null @@ -1,115 +0,0 @@ -import { escapeRegExp } from 'lodash-es' - -export const createPageUrl = ( - page: number, - currentUrl: URL | string, - otherParams?: Record | URLSearchParams -) => { - const url = new URL(currentUrl) - if (otherParams) { - if (otherParams instanceof URLSearchParams) { - otherParams.forEach((value, key) => { - url.searchParams.set(key, value) - }) - } else { - Object.entries(otherParams).forEach(([key, value]) => { - if (value !== undefined && value !== null) { - url.searchParams.set(key, value) - } - }) - } - } - url.searchParams.set('page', page.toString()) - - return url.toString() -} - -export function urlParamsToFormData(params: URLSearchParams) { - const formData = new FormData() - params.forEach((value, key) => { - formData.append(key, value) - }) - return formData -} - -export function urlParamsToObject(params: URLSearchParams) { - return Object.fromEntries(params.entries()) -} - -export function urlWithParams( - url: URL | string, - params: Record, - { clearExisting }: { clearExisting?: boolean } = { clearExisting: false } -) { - const urlObj = new URL(url) - if (clearExisting) { - const keysToDelete = Array.from(urlObj.searchParams.keys()) - keysToDelete.forEach((key) => { - urlObj.searchParams.delete(key) - }) - } - Object.entries(params).forEach(([key, value]) => { - if (Array.isArray(value)) { - value.forEach((v) => { - urlObj.searchParams.append(key, String(v)) - }) - } else if (value === null || value === undefined) { - urlObj.searchParams.delete(key) - } else { - urlObj.searchParams.set(key, String(value)) - } - }) - return urlObj.toString() -} - -export function makeObjectSearchParamKeyRegex(key: string) { - return new RegExp(`^${escapeRegExp(key)}-(.*)$`) -} - -/** - * Parses the value of an object from a URL with zod. Assuming this format: `key[subkey]=value` - * - * Returns an object with the keys as the subkeys and the values as the values. - * Or `undefined` if there are no subkeys. - * - * If there is no subkey (`key=value`), the subkey is set to an empty string. - * - * @example - * ```ts - * const searchParams = new URLSearchParams('tag-en=include&tag-fr=exclude&tag-es=') - * const value = getObjectSearchParam(searchParams, 'tag') - * // value: { en: 'include', fr: 'exclude'} - * ``` - */ -export function getObjectSearchParam( - params: URLSearchParams, - key: string, - { - ignoreEmptyValues = true, - emptyObjectBecomesUndefined = true, - }: { - ignoreEmptyValues?: boolean - emptyObjectBecomesUndefined?: boolean - } = {} -) { - const keyPattern = makeObjectSearchParamKeyRegex(key) - - const entries = Array.from(params.entries()).flatMap(([paramKey, paramValue]) => { - if (ignoreEmptyValues && paramValue === '') return [] - if (paramKey === key) return [['', paramValue]] as const - - const subKey = paramKey.match(keyPattern)?.[1] - if (subKey === undefined) return [] - return [[subKey, paramValue]] as const - }) - - if (entries.length === 0) return emptyObjectBecomesUndefined ? undefined : {} - return Object.fromEntries(entries) -} - -export function urlDomain(url: URL | string) { - if (typeof url === 'string') { - return url.replace(/^(https?:\/\/)?(www\.)?/, '').replace(/\/(index\.html)?$/, '') - } - return url.origin -} diff --git a/web/src/lib/userCookies.ts b/web/src/lib/userCookies.ts deleted file mode 100644 index 4cab300..0000000 --- a/web/src/lib/userCookies.ts +++ /dev/null @@ -1,80 +0,0 @@ -import { stopImpersonating } from './impersonation' -import { prisma } from './prisma' -import { redisSessions } from './redis/redisSessions' - -import type { APIContext, AstroCookies, AstroCookieSetOptions } from 'astro' - -const COOKIE_NAME = 'user_session_id' -const COOKIE_MAX_AGE = 60 * 60 * 24 * 7 // 1 week - -const defaultCookieOptions = { - path: '/', - secure: true, - httpOnly: true, - sameSite: 'strict', - maxAge: COOKIE_MAX_AGE, -} as const satisfies AstroCookieSetOptions - -export function getUserSessionIdCookie(cookies: AstroCookies) { - return cookies.get(COOKIE_NAME)?.value -} - -export async function getUserFromCookies(cookies: AstroCookies) { - const userSessionId = getUserSessionIdCookie(cookies) - if (!userSessionId) return null - - const userSecretTokenHash = await redisSessions.getUserBySessionId(userSessionId) - if (!userSecretTokenHash) return null - - return prisma.user.findFirst({ - where: { - secretTokenHash: userSecretTokenHash, - }, - }) -} - -export async function setUserSessionIdCookie( - cookies: AstroCookies, - userSecretTokenHash: string, - options: AstroCookieSetOptions = {} -) { - const sessId = await redisSessions.createSession(userSecretTokenHash) - cookies.set(COOKIE_NAME, sessId, { - ...defaultCookieOptions, - ...options, - }) -} - -export async function removeUserSessionIdCookie(cookies: AstroCookies) { - const sessionId = cookies.get(COOKIE_NAME)?.value - if (sessionId) { - await redisSessions.deleteSession(sessionId) - } - cookies.delete(COOKIE_NAME, { path: '/' }) -} - -export async function logout(context: Pick) { - await stopImpersonating(context) - - await removeUserSessionIdCookie(context.cookies) - - context.locals.user = null - context.locals.actualUser = null -} - -export async function login( - context: Pick, - user: NonNullable -) { - await stopImpersonating(context) - - await setUserSessionIdCookie(context.cookies, user.secretTokenHash) - - await prisma.user.update({ - where: { id: user.id }, - data: { lastLoginAt: new Date() }, - }) - - context.locals.user = user - context.locals.actualUser = null -} diff --git a/web/src/lib/userSecretToken.ts b/web/src/lib/userSecretToken.ts deleted file mode 100644 index 63a63ee..0000000 --- a/web/src/lib/userSecretToken.ts +++ /dev/null @@ -1,149 +0,0 @@ -import crypto from 'crypto' - -import { z } from 'astro/zod' -import { escapeRegExp } from 'lodash-es' - -import { - DIGIT_CHARACTERS, - LOWERCASE_CONSONANT_CHARACTERS, - LOWERCASE_VOWEL_CHARACTERS, -} from '../constants/characters' - -import { getRandom, typedJoin } from './arrays' -import { DEPLOYMENT_MODE } from './envVariables' -import { transformCase } from './strings' - -const DIGEST = 'sha512' - -const USER_SECRET_TOKEN_LETTERS_SEGMENT_REGEX = - `(?:(?:[${typedJoin(LOWERCASE_VOWEL_CHARACTERS)}${transformCase(typedJoin(LOWERCASE_VOWEL_CHARACTERS), 'upper')}][${typedJoin(LOWERCASE_CONSONANT_CHARACTERS)}${transformCase(typedJoin(LOWERCASE_CONSONANT_CHARACTERS), 'upper')}]){2})` as const -const USER_SECRET_TOKEN_DIGITS_SEGMENT_REGEX = `(?:[${typedJoin(DIGIT_CHARACTERS)}]{4})` as const -const USER_SECRET_TOKEN_SEPARATOR_REGEX = '(?:(-| )+)' - -export const includeDevUsers = DEPLOYMENT_MODE !== 'production' - -const USER_SECRET_TOKEN_DEV_USERS_REGEX = (() => { - const specialUsersData = [ - { - envToken: 'DEV_ADMIN_USER_SECRET_TOKEN', - defaultToken: 'admin', - }, - { - envToken: 'DEV_VERIFIER_USER_SECRET_TOKEN', - defaultToken: 'verifier', - }, - { - envToken: 'DEV_VERIFIED_USER_SECRET_TOKEN', - defaultToken: 'verified', - }, - { - envToken: 'DEV_NORMAL_USER_SECRET_TOKEN', - defaultToken: 'normal', - }, - { - envToken: 'DEV_SPAM_USER_SECRET_TOKEN', - defaultToken: 'spam', - }, - ] as const satisfies { - envToken: string - defaultToken: string - }[] - - const env = - // This file can also be called from faker.ts, where import.meta.env is not available - // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition - (import.meta.env - ? Object.fromEntries(specialUsersData.map(({ envToken }) => [envToken, import.meta.env[envToken]])) - : undefined) ?? process.env - - return `(?:${typedJoin( - specialUsersData.map(({ envToken, defaultToken }) => - typedJoin( - ((env[envToken] as string | undefined) ?? defaultToken).match(/(.{4}|.{1,3}$)/g)?.map( - (segment) => - `${segment - .split('') - .map((char) => `(?:${escapeRegExp(char.toUpperCase())}|${escapeRegExp(char.toLowerCase())})`) - .join('')}${USER_SECRET_TOKEN_SEPARATOR_REGEX}?` - ) ?? [] - ) - ), - '|' - )})` as const -})() - -const USER_SECRET_TOKEN_FULL_REGEX_STRING = - `(?:(?:${USER_SECRET_TOKEN_LETTERS_SEGMENT_REGEX}${USER_SECRET_TOKEN_SEPARATOR_REGEX}?){4}${USER_SECRET_TOKEN_DIGITS_SEGMENT_REGEX})` as const -export const USER_SECRET_TOKEN_REGEX_STRING = - `^(?:${USER_SECRET_TOKEN_FULL_REGEX_STRING}${includeDevUsers ? `|${USER_SECRET_TOKEN_DEV_USERS_REGEX}` : ''})$` as const -export const USER_SECRET_TOKEN_REGEX = new RegExp(USER_SECRET_TOKEN_REGEX_STRING) - -export const userSecretTokenZodSchema = z - .string() - .regex(USER_SECRET_TOKEN_REGEX) - .transform(parseUserSecretToken) - -export function generateUserSecretToken(): string { - const token = [ - getRandom(LOWERCASE_VOWEL_CHARACTERS), - getRandom(LOWERCASE_CONSONANT_CHARACTERS), - getRandom(LOWERCASE_VOWEL_CHARACTERS), - getRandom(LOWERCASE_CONSONANT_CHARACTERS), - - getRandom(LOWERCASE_VOWEL_CHARACTERS), - getRandom(LOWERCASE_CONSONANT_CHARACTERS), - getRandom(LOWERCASE_VOWEL_CHARACTERS), - getRandom(LOWERCASE_CONSONANT_CHARACTERS), - - getRandom(LOWERCASE_VOWEL_CHARACTERS), - getRandom(LOWERCASE_CONSONANT_CHARACTERS), - getRandom(LOWERCASE_VOWEL_CHARACTERS), - getRandom(LOWERCASE_CONSONANT_CHARACTERS), - - getRandom(LOWERCASE_VOWEL_CHARACTERS), - getRandom(LOWERCASE_CONSONANT_CHARACTERS), - getRandom(LOWERCASE_VOWEL_CHARACTERS), - getRandom(LOWERCASE_CONSONANT_CHARACTERS), - - getRandom(DIGIT_CHARACTERS), - getRandom(DIGIT_CHARACTERS), - getRandom(DIGIT_CHARACTERS), - getRandom(DIGIT_CHARACTERS), - ].join('') - - return parseUserSecretToken(token) -} - -export function hashUserSecretToken(token: string): string { - return crypto.createHash(DIGEST).update(token).digest('hex') -} - -export function parseUserSecretToken(token: string): string { - if (!USER_SECRET_TOKEN_REGEX.test(token)) { - throw new Error( - `Invalid user secret token. Token "${token}" does not match regex ${USER_SECRET_TOKEN_REGEX_STRING}` - ) - } - - return token.toLocaleLowerCase().replace(new RegExp(USER_SECRET_TOKEN_SEPARATOR_REGEX, 'g'), '') -} - -export function prettifyUserSecretToken(token: string): string { - const parsedToken = parseUserSecretToken(token) - - const groups = parsedToken.toLocaleUpperCase().match(/.{4}/g) - if (!groups || groups.length !== 5) { - throw new Error('Error while prettifying user secret token') - } - return groups.join('-') -} - -/** - * Verify a token against a stored hash using a constant-time comparison - */ -export function verifyUserSecretToken(token: string, hash: string): boolean { - const correctHash = hashUserSecretToken(token) - - // Use crypto.timingSafeEqual to prevent timing attacks - return crypto.timingSafeEqual(Buffer.from(correctHash, 'hex'), Buffer.from(hash, 'hex')) -} diff --git a/web/src/lib/zodUtils.ts b/web/src/lib/zodUtils.ts deleted file mode 100644 index aeda57b..0000000 --- a/web/src/lib/zodUtils.ts +++ /dev/null @@ -1,72 +0,0 @@ -import { z, type ZodTypeAny } from 'astro/zod' -import { round } from 'lodash-es' - -const addZodPipe = (schema: ZodTypeAny, zodPipe?: ZodTypeAny) => { - return zodPipe ? schema.pipe(zodPipe) : schema -} - -/** - * The difference between this and `z.coerce.number()` is that an empty string won't be coerced to 0. - * - * If you don't accept 0, just use `z.coerce.number().int().positive()` instead. - */ -export const zodCohercedNumber = (zodPipe?: ZodTypeAny) => - addZodPipe(z.number().or(z.string().nonempty()), zodPipe) - -export const zodUrlOptionalProtocol = z.preprocess( - (input) => { - if (typeof input !== 'string') return input - const trimmedVal = input.trim() - return !/^\w+:\/\//i.test(trimmedVal) ? `https://${trimmedVal}` : trimmedVal - }, - z.string().refine((value) => /^(https?):\/\/(?=.*\.[a-z]{2,})[^\s$.?#].[^\s]*$/i.test(value), { - message: 'Invalid URL', - }) -) - -const stringToArrayFactory = (delimiter: RegExp | string = ',') => { - return (input: T) => - typeof input !== 'string' - ? (input ?? undefined) - : input - .split(delimiter) - .map((item) => item.trim()) - .filter((item) => item !== '') -} - -export const stringListOfUrlsSchema = z.preprocess( - stringToArrayFactory(/[\s,\n]+/), - z.array(zodUrlOptionalProtocol).default([]) -) - -export const stringListOfUrlsSchemaRequired = z.preprocess( - stringToArrayFactory(/[\s,\n]+/), - z.array(zodUrlOptionalProtocol).min(1) -) - -export const MAX_IMAGE_SIZE = 5 * 1024 * 1024 // 5MB - -export const ACCEPTED_IMAGE_TYPES = [ - 'image/svg+xml', - 'image/png', - 'image/jpeg', - 'image/jxl', - 'image/avif', - 'image/webp', -] as const satisfies string[] - -export const imageFileSchema = z - .instanceof(File) - .optional() - .nullable() - .transform((file) => (!file || file.size === 0 || !file.name ? undefined : file)) - .refine( - (file) => !file || file.size <= MAX_IMAGE_SIZE, - `Max image size is ${round(MAX_IMAGE_SIZE / 1024 / 1024, 3).toLocaleString()}MB.` - ) - .refine( - (file) => !file || ACCEPTED_IMAGE_TYPES.some((type) => file.type === type), - 'Only SVG, PNG, JPG, JPEG XL, AVIF, WebP formats are supported.' - ) - -export const imageFileSchemaRequired = imageFileSchema.refine((file) => !!file, 'Required') diff --git a/web/src/middleware.ts b/web/src/middleware.ts deleted file mode 100644 index f76f906..0000000 --- a/web/src/middleware.ts +++ /dev/null @@ -1,155 +0,0 @@ -import { getActionContext } from 'astro:actions' -import { defineMiddleware, sequence } from 'astro:middleware' - -import { ErrorBanners, getMessagesFromUrl } from './lib/errorBanners' -import { getImpersonationInfo } from './lib/impersonation' -import { makeUserWithKarmaUnlocks } from './lib/karmaUnlocks' -import { prisma } from './lib/prisma' -import { makeLoginUrl } from './lib/redirectUrls' -import { redisActionsSessions } from './lib/redis/redisActionsSessions' -import { getUserFromCookies } from './lib/userCookies' - -const ACTION_SESSION_COOKIE = 'action-session-id' - -const preventFormResubmitAndStoreActionErrors = defineMiddleware(async (context, next) => { - if (context.isPrerendered) return next() - - const { action, setActionResult, serializeActionResult } = getActionContext(context) - - const sessionId = context.cookies.get(ACTION_SESSION_COOKIE)?.value - const session = await redisActionsSessions.get(sessionId) - - if (session) { - setActionResult(session.actionName, session.actionResult) - - if (session.deserializedActionResult.error) { - context.locals.banners.add({ - uiMessage: session.deserializedActionResult.error.message, - type: 'error', - origin: 'action', - error: session.deserializedActionResult.error, - }) - } - - await redisActionsSessions.delete(sessionId) - context.cookies.delete(ACTION_SESSION_COOKIE) - return next() - } - - if (action) { - const actionResult = await action.handler() - - if (actionResult.error) { - context.locals.banners.add({ - uiMessage: actionResult.error.message, - type: 'error', - origin: 'action', - error: actionResult.error, - }) - } - - if (action.calledFrom === 'form') { - const sessionId = await redisActionsSessions.store({ - actionName: action.name, - actionResult: serializeActionResult(actionResult), - }) - - context.cookies.set(ACTION_SESSION_COOKIE, sessionId, { - path: '/', - httpOnly: true, - secure: true, - sameSite: 'strict', - maxAge: redisActionsSessions.expirationTime, - }) - - if (actionResult.error) { - const referer = context.request.headers.get('Referer') - if (!referer) { - throw new Error('Internal: Referer unexpectedly missing from Action POST request.') - } - return context.redirect(referer) - } - return context.redirect(context.originPathname) - } - } - - return next() -}) - -const authenticate = defineMiddleware(async (context, next) => { - const user = await getUserFromCookies(context.cookies) - context.locals.user = makeUserWithKarmaUnlocks(user) - - return next() -}) - -const impersonate = defineMiddleware(async (context, next) => { - context.locals.actualUser = null - - const user = context.locals.user - if (user?.admin) { - const impersonationInfo = await getImpersonationInfo(context.cookies) - - if (impersonationInfo && impersonationInfo.adminId === user.id) { - const impersonatedUser = await prisma.user.findUnique({ - where: { id: impersonationInfo.targetId }, - }) - - if (impersonatedUser) { - context.locals.actualUser = user - context.locals.user = makeUserWithKarmaUnlocks(impersonatedUser) - } - } - } - - return next() -}) - -const protectRoutes = defineMiddleware(async (context, next) => { - const user = context.locals.user - - if (context.url.pathname.startsWith('/admin')) { - if (!user) { - return Response.redirect(makeLoginUrl(context.url, { message: 'Login as admin to access this page' })) - } - - if (!user.admin) { - const accessDeniedUrl = new URL(context.url.origin) - accessDeniedUrl.pathname = '/access-denied' - accessDeniedUrl.searchParams.set('reasonType', 'admin-required') - accessDeniedUrl.searchParams.set('redirect', context.url.toString()) - return Response.redirect(accessDeniedUrl.toString()) - } - } - - return next() -}) - -const makeIds = defineMiddleware(async (context, next) => { - const prefixCount = new Map() - - context.locals.makeId = (prefix: T) => { - const count = (prefixCount.get(prefix) ?? 0) + 1 - prefixCount.set(prefix, count) - // eslint-disable-next-line @typescript-eslint/restrict-template-expressions - return `${prefix}-${count}-${crypto.randomUUID()}` as const - } - - return next() -}) - -const errors = defineMiddleware(async (context, next) => { - const messagesFromUrl = getMessagesFromUrl(context) - context.locals.banners = new ErrorBanners(messagesFromUrl) - - return next() -}) - -export const onRequest = sequence( - errors, - authenticate, - impersonate, - protectRoutes, - preventFormResubmitAndStoreActionErrors, - makeIds -) diff --git a/web/src/pages/404.astro b/web/src/pages/404.astro deleted file mode 100644 index 8d60c43..0000000 --- a/web/src/pages/404.astro +++ /dev/null @@ -1,101 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' - -import BaseLayout from '../layouts/BaseLayout.astro' ---- - - -

- 404 -

-
-
-
-
-
- -
-

Page not found

-

The page doesn't exist, double check the URL.

- - - Home - -
-
- - diff --git a/web/src/pages/500.astro b/web/src/pages/500.astro deleted file mode 100644 index 59c587e..0000000 --- a/web/src/pages/500.astro +++ /dev/null @@ -1,105 +0,0 @@ ---- -import { z } from 'astro/zod' -import { Icon } from 'astro-icon/components' - -import { SUPPORT_EMAIL } from '../constants/project' -import BaseLayout from '../layouts/BaseLayout.astro' -import { DEPLOYMENT_MODE } from '../lib/envVariables' -import { zodParseQueryParamsStoringErrors } from '../lib/parseUrlFilters' - -type Props = { - error: unknown -} - -const { error } = Astro.props - -const { - data: { message }, -} = zodParseQueryParamsStoringErrors({ message: z.string().optional() }, Astro) ---- - - - -

500

-

- Server Error -

-

- {/* eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing */} - {message || 'Sorry, something crashed on the server.'} -

- { - (DEPLOYMENT_MODE !== 'production' || Astro.locals.user?.admin) && ( -
- {error instanceof Error - ? error.message - : error === undefined - ? // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - message || 'undefined' - : typeof error === 'object' - ? JSON.stringify(error, null, 2) - : String(error as unknown)} -
- ) - } - - -
- - diff --git a/web/src/pages/about.md b/web/src/pages/about.md deleted file mode 100644 index 9e52372..0000000 --- a/web/src/pages/about.md +++ /dev/null @@ -1,211 +0,0 @@ ---- -layout: ../layouts/MarkdownLayout.astro -title: About -author: KYCnot.me -pubDate: 2025-05-15 -description: 'Learn how KYCnot.me website works and about our mission to protect privacy in cryptocurrency.' ---- - -## What is this page? - -KYCnot.me is a directory of trustworthy alternatives for buying, exchanging, trading, and using cryptocurrencies without having to disclose your identity, thus preserving your right to privacy. - -## What is KYC? - -**KYC** stands for _Know Your Customer_, a process designed to protect financial institutions against fraud, corruption, money laundering and terrorist financing. - -The truth is that KYC is a **direct attack on our privacy** and puts us in disadvantage against the governments. **True criminals don't care about KYC policies**. True criminals know perfectly how to avoid such policies. In fact, they normally use the FIAT system and don't even need to use cryptocurrencies. Banks are the biggest money launders, the [HSBC scandal](https://www.reuters.com/business/hsbc-fined-85-mln-anti-money-laundering-failings-2021-12-17/), [Nordea](https://www.reuters.com/article/us-nordea-bnk-moneylaundering-idUSKCN1QL11S) or [Swedbank](https://www.reuters.com/article/us-europe-moneylaundering-swedbank/swedbank-hit-with-record-386-million-fine-over-baltic-money-laundering-breaches-idUSKBN2163LU) are just some examples. - -Chainalysis found that only 0.34% of the transaction volume with cryptocurrencies in 2023 was attributable to criminal activity. Bitcoin's share of this is significantly lower. Illicit transactions with Euros accounted for 1% of the EU's GDP or €110 billion in 2010. [[1]](https://www.chainalysis.com/blog/2024-crypto-crime-report-introduction/) [[2]](https://transparency.eu/priority/financial-flows-crime/) - -KYC only affects small individuals like you and me. It is an annoying procedure that **forces us to trust our personal information to a third party** in order to buy, use or unlock our funds. We should start using cryptocurrencies as they were intended to be used: without barriers. - -## Why does this site exist? - -Crypto was born to free us from banks and governments controlling our money. Simple as that. - -When exchanges require your ID and personal information through KYC, they undermine the core principle of cryptocurrency: privacy. Not everyone possesses an ID, and not everyone resides in a "supported" country. Small businesses often struggle with the burden of compliance and the fear of hefty fines. Moreover, exchanges are [targets for hackers](https://www.reuters.com/business/coinbase-says-cyber-criminals-stole-account-data-some-customers-2025-05-15/?ref=guptadeepak.com), putting your sensitive data at risk of theft. - -KYC turns crypto back into the system we're trying to escape. That's why I built this site - to help you use crypto the way it was meant to be used: privately. - -## Why only Bitcoin and Monero? - -**Bitcoin**: It's the initial spark of the decentralized money. A solid project with a strong community. It is the most well-known and widespread cryptocurrency. - -**Monero**: If you're looking for digital cash that's truly private, Monero is it. It's designed for privacy, works like real cash (fungible), has low fees, and is supported by a dedicated, long-standing community. - -While the main focus is on Bitcoin and Monero, you'll find that many of the listed services also accept other cryptocurrencies, such as Ethereum or Litecoin. - -## User Accounts - -You can [create an account](/account/generate) to suggest new services or share your feedback on service pages. - -User accounts do not require any personal information. Your username will be **randomly** generated to prevent impersonation and protect your privacy. - -When you create an account, you are given a **login key**. Login keys are **displayed only once**. Be sure to **store it securely**, as it **cannot be recovered** if lost. It is recommended to use a password manager like [Bitwarden](https://bitwarden.com) or [KeePassXC](https://keepassxc.org/). - -### User Karma - -Users earn karma by participating in the community. When your comments get approved, or when making contributions. As your karma grows, you'll unlock **special features**, which are detailed on your [user profile page](/account). - -### Verified and Affiliated Users - -Some users are **verified**, this means that the moderators have confirmed that the user is related to a specific link or service. The verification is directly linked to the URL, ensuring that the person behind the username has a legitimate connection to the service they claim to represent. This verification process is reserved for individuals with established reputation. - -Users can also be **affiliated** with a service if they're related to it, such as being an owner or part of the team. If you own a service and want to get verified, just reach out to us. - -## Listings - -### Suggesting a new listing - -To suggest a new listing, visit the [service suggestion form](/service-suggestion/new) and provide the most accurate information possible for higher chances to get approved. - -Once submitted, you get a unique tracking page where you can monitor its status and communicate directly with moderators. - -All new listings begin as **unlisted** — they're only accessible via direct link and won't appear in search results. After a brief admin review to confirm the request isn't spam or inappropriate, the listing will be marked as **Community Contributed**. - -### Suggestion Review Process - -#### First Review - -- A member of the **KYCnot.me team** reviews the submission to ensure it isn't spam or inappropriate. -- If the listing passes this initial check, it becomes **publicly visible** to all users. -- At this stage, the listing is **Community Contributed** and will show a disclaimer. - -#### Second Review (APPROVED) - -- The service is tested and investigated again. -- If it proves to be reliable, it is granted the `APPROVED` status, which means: - - The information is accurate. - - The service works as described (at the time of the testing). - - Basic functionality has been tested. - - Communication with the service's support was successful. - - A brief investigation found no obvious red flags. - -#### Final Review (VERIFIED) - -- After a period of no reported issues, the service will undergo a **third, comprehensive review**. - - The service is tested across different dates and under various conditions. - - The service administrators and support teams will be contacted for additional verification. -- If the service meets all requirements, it is granted the **`VERIFIED`** status. - -#### Failed Verifications - -If the data is not accurate, the service is a scam, or any other checks fail, the service will be rejected and will appear with a disclaimer. - -### Verification Steps - -Services will usually show the verification steps that the admins took to reach the verified (or not) status. Each step will have a description and some evidence attached. - -### Service Attributes - -An attribute is a feature of a service, categorized as: - -- **Good** – A positive feature -- **Warning** – A potential concern -- **Bad** – A significant drawback -- **Information** – Neutral details - -You can view all available attributes on the [Attributes page](/attributes). - -Attributes are classified into two main types: - -1. **Privacy Attributes** – Related to data protection and anonymity. -2. **Trust Attributes** – Related to reliability and security. - -These categories **directly influence** a service's Privacy and Trust scores, which contribute to its **overall rating**. - -### Service Scores - -Scores are calculated **automatically** using clear, fixed rules. We do not change or adjust scores by hand. The scoring system is **open-source** and anyone can review or suggest improvements. - -#### Privacy Score - -The privacy score measures how well a service protects user privacy, using a transparent, rules-based approach: - -1. **Base Score:** Every service starts with a neutral score of 50 points. -2. **KYC Level:** Adjusts the score based on the level of identity verification required: - - KYC Level 0 (No KYC): **+25 points** - - KYC Level 1 (Minimal KYC): **+10 points** - - KYC Level 2 (Moderate KYC): **-5 points** - - KYC Level 3 (More KYC): **-15 points** - - KYC Level 4 (Full mandatory KYC): **-25 points** -3. **Onion URL:** **+5 points** if the service offers at least one Onion (Tor) URL. -4. **I2P URL:** **+5 points** if the service offers at least one I2P URL. -5. **Monero Acceptance:** **+5 points** if the service accepts Monero as a payment method. -6. **Privacy Attributes:** The sum of all privacy points from attributes categorized as 'PRIVACY' is added to the score. -7. **Final Score Range:** The final score is always kept between 0 and 100. - -#### Trust Score - -The trust score represents how reliable and trustworthy a service is, based on objective, transparent criteria. - -1. **Base Score:** Every service begins with a neutral score of 50 points. -2. **Verification Status Adjustment:** - - **Verification Success:** +10 points - - **Approved:** +5 points - - **Community Contributed:** 0 points - - **Verification Failed (SCAM):** -50 points -3. **Trust Attributes:** The total trust points from all attributes categorized as 'TRUST' are added to the score. -4. **Recently Listed Penalty & Flag:** If a service was listed within the last 15 days and its status is `APPROVED`, a penalty of -10 points is applied to the trust score, and the service is flagged as recently listed. -5. **Final Score Range:** The final score is always kept between 0 and 100. - -#### Overall Score - -The overall score is calculated as `(privacy * 0.6) + (trust * 0.4)` and provides a combined measure of privacy and trust. - -### Terms of Service Reviews - -KYCnot.me automatically reviews and summarizes the Terms of Service (ToS) for every service monthly using AI. You get simple, clear summaries that highlight the most important points, so you can quickly see what matters. - -We hash each ToS document and only review it again if it changes. Some services may go a long time without a new review, but we still check and scrape their ToS every month. - -We aim for accuracy, but the AI may sometimes miss details or highlight less relevant information. If you see any error, contact us. - -### Events - -There are two types of events: - -- Automated events: Created by the system whenever something about a service changes, like its description, supported currencies, attributes, verification status... -- Manual events: Added by admins when there's important news, such as a service going offline, being hacked, acquired, shut down, or other major updates. - -You can also take a look at the [global timeline](/events) where you will find all the service's events sorted by date. - -### Reviews and Comments - -Reviews are comments with a one to five star rating for the service. Each user can leave only one review per service; new reviews replace the old one. - -You can also post regular comments to share your experience, ask questions, or discuss the service. - -If you've used the service, you can add an **order ID** or proof—this is only visible to admins for verification. You can also **flag** comments for issues like blocked funds or KYC requirements. - -Some reviews may be spam or fake. Read comments carefully and **always do your own research before making decisions**. - -#### Note on moderation - -**All comments are moderated.** First, an AI checks each comment. If nothing is flagged, the comment is published right away. If something seems off, the comment is held for a human to review. We only remove comments that are spam, nonsense, unsupported accusations, doxxing, or clear rule violations. - -To **see comments waiting for moderation**, toggle the switch in the comments section. These comments show up with a yellow background and a "pending" label. - -## Support the project - -If you like this project, you can support it through these methods: - -- Monero: - - `88V2Xi2mvcu3NdnHkVeZGyPtACg2w3iXZdUMJugUiPvFQHv5mVkih3o43ceVGz6cVs9uTBMt4MRMVW2xFgfGdh8DTCQ7vtp` - -## Contact - -You can contact via direct chat or via email. - -- [SimpleX Chat](https://simplex.chat/contact#/?v=2&smp=smp%3A%2F%2F0YuTwO05YJWS8rkjn9eLJDjQhFKvIYd8d4xG8X1blIU%3D%40smp8.simplex.im%2FcgKHYUYnpAIVoGb9lxb0qEMEpvYIvc1O%23%2F%3Fv%3D1-2%26dh%3DMCowBQYDK2VuAyEAIW_JSq8wOsLKG4Xv4O54uT2D_l8MJBYKQIFj1FjZpnU%253D%26srv%3Dbeccx4yfxxbvyhqypaavemqurytl6hozr47wfc7uuecacjqdvwpw2xid.onion) - -- If you use ProtonMail or Tutanota, you can have E2E encrypted communications with us directly. We also offer a [PGP Key](/pgp). Otherwise, we recommend reaching out via SimpleX chat for encrypted communications. - - [tuta.io](https://tuta.io) - - - [proton.me](https://proton.me) - - -## Disclaimer - -This website is strictly for informational purposes regarding privacy technology in the cryptocurrency space. We unequivocally condemn and do not endorse, support, or facilitate money laundering, terrorist financing, or any other illegal financial activities. The use of any information or service mentioned herein for such purposes is strictly prohibited and contrary to the core principles of this project. - -By using this website, you acknowledge and agree that you are solely responsible for your actions, due diligence, and compliance with all applicable laws. You use the information and any linked services entirely at your own risk. The operators of this website will not be held liable for any losses, damages, or legal consequences arising from your use of this site or any services listed herein. diff --git a/web/src/pages/access-denied.astro b/web/src/pages/access-denied.astro deleted file mode 100644 index 80bc343..0000000 --- a/web/src/pages/access-denied.astro +++ /dev/null @@ -1,75 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { z } from 'astro:content' - -import BaseLayout from '../layouts/BaseLayout.astro' -import { zodParseQueryParamsStoringErrors } from '../lib/parseUrlFilters' -import { makeLoginUrl, makeUnimpersonateUrl } from '../lib/redirectUrls' - -const { - data: { reason, reasonType, redirect }, -} = zodParseQueryParamsStoringErrors( - { - reason: z.string().optional(), - reasonType: z.enum(['admin-required']).optional(), - redirect: z.string().optional(), - }, - Astro -) - -if (reasonType === 'admin-required' && Astro.locals.user?.admin) { - return Astro.redirect(redirect) -} ---- - - - -

- Access denied -

-

- {reason} -

- -
- - - Go to home - - - - Login as different user - - { - Astro.locals.actualUser && ( - - - Unimpersonate - - ) - } -
-
diff --git a/web/src/pages/account/edit.astro b/web/src/pages/account/edit.astro deleted file mode 100644 index b0a0db0..0000000 --- a/web/src/pages/account/edit.astro +++ /dev/null @@ -1,160 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { actions, isInputError } from 'astro:actions' - -import { karmaUnlocksById } from '../../constants/karmaUnlocks' -import BaseLayout from '../../layouts/BaseLayout.astro' -import { makeKarmaUnlockMessage } from '../../lib/karmaUnlocks' -import { makeLoginUrl } from '../../lib/redirectUrls' - -const user = Astro.locals.user -if (!user) { - return Astro.redirect(makeLoginUrl(Astro.url, { message: 'Login to edit your profile' })) -} - -const result = Astro.getActionResult(actions.account.update) -if (result && !result.error) { - return Astro.redirect('/account') -} -const inputErrors = isInputError(result?.error) ? result.error.fields : {} ---- - - -
-
-

Edit Profile

- - - Back to Profile - -
- -
- - -
- - - { - inputErrors.displayName && ( -

{inputErrors.displayName.join(', ')}

- ) - } - { - !user.karmaUnlocks.displayName && ( -

- - {makeKarmaUnlockMessage(karmaUnlocksById.displayName)} - - Learn about karma - -

- ) - } -
- -
- - - {inputErrors.link &&

{inputErrors.link.join(', ')}

} - { - !user.karmaUnlocks.websiteLink && ( -

- - {makeKarmaUnlockMessage(karmaUnlocksById.websiteLink)} - - Learn about karma - -

- ) - } -
- -
- -
- -

- Upload a square image for best results. Supported formats: JPG, PNG, WebP, AVIF, JXL. Max size: - 5MB. -

-
- { - inputErrors.pictureFile && ( -

{inputErrors.pictureFile.join(', ')}

- ) - } - { - !user.karmaUnlocks.profilePicture && ( -

- - You need 200 karma to have a profile picture. - - Learn about karma - -

- ) - } -
- -
- - - Cancel - -
-
-
-
diff --git a/web/src/pages/account/generate.astro b/web/src/pages/account/generate.astro deleted file mode 100644 index 15ccd80..0000000 --- a/web/src/pages/account/generate.astro +++ /dev/null @@ -1,117 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { actions } from 'astro:actions' - -import Button from '../../components/Button.astro' -import Captcha from '../../components/Captcha.astro' -import InputHoneypotTrap from '../../components/InputHoneypotTrap.astro' -import MiniLayout from '../../layouts/MiniLayout.astro' -import { callActionWithObject } from '../../lib/callActionWithUrlParams' -import { prettifyUserSecretToken } from '../../lib/userSecretToken' - -const generateResult = Astro.getActionResult(actions.account.generate) -if (generateResult && !generateResult.error) { - return Astro.rewrite('/account/welcome') -} - -const data = await callActionWithObject(Astro, actions.account.preGenerateToken, undefined, 'form') - -const preGeneratedToken = data?.token -const prettyToken = preGeneratedToken ? prettifyUserSecretToken(preGeneratedToken) : undefined ---- - -{/* eslint-disable astro/jsx-a11y/no-autofocus */} - - - { - Astro.locals.user && ( -
- -

You will be logged out of your current account.

-
- ) - } - -
- {/* Hack to make password managers suggest saving the secret token */} -
- - -
- - - - - - - -
- - - - -
-
-

- - Service Affiliations -

-
- - { - user.serviceAffiliations.length > 0 ? ( - - ) : ( -

No service affiliations yet.

- ) - } -
- -
-
-

- - Karma Unlocks -

- -
-

- Earn karma to unlock features and privileges. Learn about karma -

-
-
- -
-
-

Positive unlocks

- - { - sortBy( - karmaUnlocks.filter((unlock) => unlock.karma >= 0), - 'karma' - ).map((unlock) => ( -
-
- - - -
-

- {unlock.name} -

-

{unlock.karma.toLocaleString()} karma

-
-
-
- {user.karmaUnlocks[unlock.id] ? ( - - Unlocked - - ) : ( - - Locked - - )} -
-
- )) - } -
- -
-

Negative unlocks

- - { - sortBy( - karmaUnlocks.filter((unlock) => unlock.karma < 0), - 'karma' - ) - .reverse() - .map((unlock) => ( -
-
- - - -
-

- {unlock.name} -

-

{unlock.karma.toLocaleString()} karma

-
-
-
- {user.karmaUnlocks[unlock.id] ? ( - - Active - - ) : ( - - Avoided - - )} -
-
- )) - } - -

- - Negative karma leads to restrictions. Keep interactions positive to - avoid penalties. -

-
-
-
- -
-
-
-

- - Recent Comments -

- {user._count.comments.toLocaleString()} comments -
- - { - user.comments.length === 0 ? ( -

No comments yet.

- ) : ( -
- - - - - - - - - - - - {user.comments.map((comment) => ( - - - - - - - - ))} - -
ServiceCommentStatusUpvotesDate
- - {comment.service.name} - - -

{comment.content}

-
- - {comment.status} - - - - {comment.upvotes} - - - -
-
- ) - } -
- - { - user.karmaUnlocks.voteComments || user._count.commentVotes ? ( -
-
-

- - Recent Votes -

- {user._count.commentVotes.toLocaleString()} votes -
- - {user.commentVotes.length === 0 ? ( -

No votes yet.

- ) : ( -
- - - - - - - - - - - {user.commentVotes.map((vote) => ( - - - - - - - ))} - -
ServiceCommentVoteDate
- - {vote.comment.service.name} - - -

{vote.comment.content}

-
- {vote.downvote ? ( - - - - ) : ( - - - - )} - - -
-
- )} -
- ) : ( -
-

- - Recent Votes -

- - - Locked - -
- ) - } - -
-
-

- - Recent Suggestions -

- - View all - -
- - { - user.suggestions.length === 0 ? ( -

No suggestions yet.

- ) : ( -
- - - - - - - - - - - {user.suggestions.map((suggestion) => { - const typeInfo = getServiceSuggestionTypeInfo(suggestion.type) - const statusInfo = getServiceSuggestionStatusInfo(suggestion.status) - - return ( - - - - - - - ) - })} - -
ServiceTypeStatusDate
- - {suggestion.service.name} - - - - - {typeInfo.label} - - - - - {statusInfo.label} - - - -
-
- ) - } -
- -
-
-

- - Recent Karma Transactions -

- {user.totalKarma.toLocaleString()} karma -
- - { - user.karmaTransactions.length === 0 ? ( -

No karma transactions yet.

- ) : ( -
- - - - - - - - - - - {user.karmaTransactions.map((transaction) => ( - - - - - - - ))} - -
ActionDescriptionPointsDate
{transaction.action}{transaction.description}= 0 ? 'text-green-400' : 'text-red-400' - )} - > - {transaction.points >= 0 && '+'} - {transaction.points} - - {new Date(transaction.createdAt).toLocaleDateString()} -
-
- ) - } -
-
- - - diff --git a/web/src/pages/account/login.astro b/web/src/pages/account/login.astro deleted file mode 100644 index cf00f2f..0000000 --- a/web/src/pages/account/login.astro +++ /dev/null @@ -1,82 +0,0 @@ ---- -import { actions } from 'astro:actions' - -import Button from '../../components/Button.astro' -import InputLoginToken from '../../components/InputLoginToken.astro' -import MiniLayout from '../../layouts/MiniLayout.astro' -import { logout } from '../../lib/userCookies' - -const result = Astro.getActionResult(actions.account.login) -if (result && !result.error) { - return Astro.redirect(result.data.redirect) -} - -if (Astro.url.searchParams.get('logout')) { - await logout(Astro) - const url = new URL(Astro.url) - url.searchParams.delete('logout') - return Astro.redirect(url.toString()) -} - -// Redirect if already logged in -if (Astro.locals.user) { - // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - return Astro.redirect(Astro.url.searchParams.get('redirect') || '/') -} - -const message = Astro.url.searchParams.get('message') ---- - - -
- {/* eslint-disable-next-line astro/jsx-a11y/no-autofocus */} - - - - - - - - - - -
-
-
- - -
-
- - -
-
- -
- - -
-
-
-
- - -
-
-

Attributes List

-
- Scroll horizontally to see more → -
-
- -
-
- - - - - - - - - - - - - - { - attributesWithDetails.map((attribute, index) => ( - <> - - - - - - - - - - - - - - )) - } - -
- - Title - - - - Category - - - - Type - - - - - Priv - - - - - - Tr - - - - - - Svcs - - - - Actions -
-
- {attribute.title} -
-
{attribute.slug}
-
- - - {attribute.categoryInfo.label} - - - - - {attribute.typeInfo.label} - - - 0, - 'text-zinc-500': attribute.privacyPoints === 0, - })} - > - {formatNumber(attribute.privacyPoints, { showSign: true })} - - - 0, - 'text-zinc-500': attribute.trustPoints === 0, - })} - > - {formatNumber(attribute.trustPoints, { showSign: true })} - - - - {attribute.serviceCount} - - -
- -
- - -
-
-
-
-
-
- - - - - diff --git a/web/src/pages/admin/comments.astro b/web/src/pages/admin/comments.astro deleted file mode 100644 index ba41076..0000000 --- a/web/src/pages/admin/comments.astro +++ /dev/null @@ -1,237 +0,0 @@ ---- -import { z } from 'astro/zod' - -import CommentModeration from '../../components/CommentModeration.astro' -import { - commentStatusFilters, - commentStatusFiltersZodEnum, - getCommentStatusFilterInfo, - getCommentStatusFilterValue, -} from '../../constants/commentStatusFilters' -import BaseLayout from '../../layouts/BaseLayout.astro' -import { cn } from '../../lib/cn' -import { zodParseQueryParamsStoringErrors } from '../../lib/parseUrlFilters' -import { prisma } from '../../lib/prisma' -import { urlWithParams } from '../../lib/urls' - -const user = Astro.locals.user -if (!user || (!user.admin && !user.verifier)) { - return Astro.rewrite('/404') -} - -const { data: params } = zodParseQueryParamsStoringErrors( - { - status: commentStatusFiltersZodEnum.default('all'), - page: z.number().int().positive().default(1), - }, - Astro -) -const PAGE_SIZE = 20 - -const statusFilter = getCommentStatusFilterInfo(params.status) - -const [comments = [], totalComments = 0] = await Astro.locals.banners.try( - 'Error fetching comments', - async () => - prisma.comment.findManyAndCount({ - where: statusFilter.whereClause, - include: { - author: true, - service: { - select: { - name: true, - slug: true, - }, - }, - parent: { - include: { - author: true, - }, - }, - votes: true, - }, - orderBy: [{ createdAt: 'desc' }, { id: 'asc' }], - skip: (params.page - 1) * PAGE_SIZE, - take: PAGE_SIZE, - }), - [] -) -const totalPages = Math.ceil(totalComments / PAGE_SIZE) ---- - - -
-

> comments.moderate

- - -
- { - commentStatusFilters.map((filter) => ( - - {filter.label} - - )) - } -
-
- - -
- { - comments - .map((comment) => ({ - ...comment, - statusFilterInfo: getCommentStatusFilterInfo(getCommentStatusFilterValue(comment)), - })) - .map((comment) => ( -
-
- {/* Author Info */} - {comment.author.name} - {comment.author.admin && ( - - admin - - )} - {comment.author.verified && !comment.author.admin && ( - - verified - - )} - {comment.author.verifier && !comment.author.admin && ( - - verifier - - )} - - {/* Service Link */} - - - {comment.service.name} - - - {/* Date */} - - {new Date(comment.createdAt).toLocaleString()} - - {/* Status Badges */} - {comment.statusFilterInfo.label} -
- - {/* Parent Comment Context */} - {comment.parent && ( -
-
Replying to {comment.parent.author.name}:
-
{comment.parent.content}
-
- )} - - {/* Comment Content */} -
{comment.content}
- - {/* Notes */} - {comment.communityNote && ( -
-
Community Note
-

{comment.communityNote}

-
- )} - {comment.internalNote && ( -
-
Internal Note
-

{comment.internalNote}

-
- )} - {comment.privateContext && ( -
-
Private Context
-

{comment.privateContext}

-
- )} - - {comment.orderId && ( -
-
Order ID
-
-

{comment.orderId}

- {comment.orderIdStatus && ( - - {comment.orderIdStatus} - - )} -
-
- )} - - {(comment.kycRequested || comment.fundsBlocked) && ( -
-
Issue Flags
-
- {comment.kycRequested && ( - - KYC Requested - - )} - {comment.fundsBlocked && ( - - Funds Blocked - - )} -
-
- )} - - -
- )) - } -
- - - { - totalPages > 1 && ( -
- {params.page > 1 && ( - - Previous - - )} - - Page {params.page} of {totalPages} - - {params.page < totalPages && ( - - Next - - )} -
- ) - } -
diff --git a/web/src/pages/admin/index.astro b/web/src/pages/admin/index.astro deleted file mode 100644 index bb2124b..0000000 --- a/web/src/pages/admin/index.astro +++ /dev/null @@ -1,76 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' - -import BaseLayout from '../../layouts/BaseLayout.astro' - -import type { ComponentProps } from 'astro/types' - -type AdminLink = { - icon: ComponentProps['name'] - title: string - href: string - description: string -} - -const adminLinks: AdminLink[] = [ - { - icon: 'ri:box-3-line', - title: 'Services', - href: '/admin/services', - description: 'Manage your available services', - }, - { - icon: 'ri:file-list-3-line', - title: 'Attributes', - href: '/admin/attributes', - description: 'Configure service attributes', - }, - { - icon: 'ri:user-3-line', - title: 'Users', - href: '/admin/users', - description: 'Manage user accounts', - }, - { - icon: 'ri:chat-settings-line', - title: 'Comments', - href: '/admin/comments', - description: 'Moderate user comments', - }, - { - icon: 'ri:lightbulb-line', - title: 'Service suggestions', - href: '/admin/service-suggestions', - description: 'Review and manage service suggestions', - }, -] ---- - - -

- - Admin Dashboard -

- -
- { - adminLinks.map((link) => ( - -
- -

- {link.title} -

-
-

{link.description}

-
- )) - } -
-
diff --git a/web/src/pages/admin/service-suggestions/[id].astro b/web/src/pages/admin/service-suggestions/[id].astro deleted file mode 100644 index ecfb6ee..0000000 --- a/web/src/pages/admin/service-suggestions/[id].astro +++ /dev/null @@ -1,195 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { actions } from 'astro:actions' - -import Chat from '../../../components/Chat.astro' -import ServiceCard from '../../../components/ServiceCard.astro' -import { getServiceSuggestionStatusInfo } from '../../../constants/serviceSuggestionStatus' -import BaseLayout from '../../../layouts/BaseLayout.astro' -import { cn } from '../../../lib/cn' -import { parseIntWithFallback } from '../../../lib/numbers' -import { prisma } from '../../../lib/prisma' -import { makeLoginUrl } from '../../../lib/redirectUrls' - -const user = Astro.locals.user -if (!user?.admin) { - return Astro.redirect(makeLoginUrl(Astro.url, { message: 'Admin access required' })) -} - -const { id: serviceSuggestionIdRaw } = Astro.params -const serviceSuggestionId = parseIntWithFallback(serviceSuggestionIdRaw) -if (!serviceSuggestionId) { - return Astro.rewrite('/404') -} - -const serviceSuggestion = await Astro.locals.banners.try('Error fetching service suggestion', async () => - prisma.serviceSuggestion.findUnique({ - where: { - id: serviceSuggestionId, - }, - select: { - id: true, - status: true, - notes: true, - createdAt: true, - type: true, - user: { - select: { - id: true, - name: true, - }, - }, - service: { - select: { - id: true, - name: true, - slug: true, - description: true, - overallScore: true, - kycLevel: true, - imageUrl: true, - verificationStatus: true, - acceptedCurrencies: true, - categories: { - select: { - name: true, - icon: true, - }, - }, - }, - }, - messages: { - select: { - id: true, - content: true, - createdAt: true, - user: { - select: { - id: true, - name: true, - picture: true, - }, - }, - }, - orderBy: { - createdAt: 'desc', - }, - }, - }, - }) -) - -if (!serviceSuggestion) { - return Astro.rewrite('/404') -} - -const statusInfo = getServiceSuggestionStatusInfo(serviceSuggestion.status) ---- - - -
- - - Back - - -

Service Suggestion

-
- -
-
- -
- -
-

Suggestion Details

- -
- Status: - - - {statusInfo.label} - - - Submitted by: - - - {serviceSuggestion.user.name} - - - - Submitted at: - {serviceSuggestion.createdAt.toLocaleString()} - - Service page: - - View Service - -
- - { - serviceSuggestion.notes && ( -
-

Notes from user:

-
- {serviceSuggestion.notes} -
-
- ) - } -
-
- -
-
-

Messages

- -
- - - -
-
- - -
-
diff --git a/web/src/pages/admin/service-suggestions/index.astro b/web/src/pages/admin/service-suggestions/index.astro deleted file mode 100644 index db8b5e2..0000000 --- a/web/src/pages/admin/service-suggestions/index.astro +++ /dev/null @@ -1,385 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { actions } from 'astro:actions' -import { z } from 'astro:content' -import { orderBy as lodashOrderBy } from 'lodash-es' - -import SortArrowIcon from '../../../components/SortArrowIcon.astro' -import TimeFormatted from '../../../components/TimeFormatted.astro' -import { - getServiceSuggestionStatusInfo, - serviceSuggestionStatuses, -} from '../../../constants/serviceSuggestionStatus' -import BaseLayout from '../../../layouts/BaseLayout.astro' -import { zodParseQueryParamsStoringErrors } from '../../../lib/parseUrlFilters' -import { prisma } from '../../../lib/prisma' -import { makeLoginUrl } from '../../../lib/redirectUrls' - -import type { Prisma, ServiceSuggestionStatus } from '@prisma/client' - -const user = Astro.locals.user -if (!user?.admin) { - return Astro.redirect(makeLoginUrl(Astro.url, { message: 'Admin access required' })) -} - -const search = Astro.url.searchParams.get('search') ?? '' -const statusEnumValues = serviceSuggestionStatuses.map((s) => s.value) as [string, ...string[]] -const statusParam = Astro.url.searchParams.get('status') -const statusFilter = z - .enum(statusEnumValues) - .nullable() - .parse(statusParam === '' ? null : statusParam) as ServiceSuggestionStatus | null - -const { data: filters } = zodParseQueryParamsStoringErrors( - { - 'sort-by': z.enum(['service', 'status', 'user', 'createdAt', 'messageCount']).default('createdAt'), - 'sort-order': z.enum(['asc', 'desc']).default('desc'), - }, - Astro -) - -const sortBy = filters['sort-by'] -const sortOrder = filters['sort-order'] - -let prismaOrderBy: Prisma.ServiceSuggestionOrderByWithRelationInput = { createdAt: 'desc' } -if (sortBy === 'createdAt') { - prismaOrderBy = { createdAt: sortOrder } -} - -let suggestions = await prisma.serviceSuggestion.findMany({ - where: { - ...(search - ? { - OR: [ - { service: { name: { contains: search, mode: 'insensitive' } } }, - { user: { name: { contains: search, mode: 'insensitive' } } }, - { notes: { contains: search, mode: 'insensitive' } }, - ], - } - : {}), - status: statusFilter ?? undefined, - }, - orderBy: prismaOrderBy, - select: { - id: true, - status: true, - notes: true, - createdAt: true, - user: { - select: { - id: true, - name: true, - }, - }, - service: { - select: { - id: true, - name: true, - slug: true, - description: true, - imageUrl: true, - verificationStatus: true, - categories: { - select: { - name: true, - icon: true, - }, - }, - }, - }, - messages: { - select: { - id: true, - content: true, - createdAt: true, - user: { - select: { - id: true, - name: true, - }, - }, - }, - orderBy: { - createdAt: 'desc', - }, - take: 1, - }, - _count: { - select: { - messages: true, - }, - }, - }, -}) - -let suggestionsWithDetails = suggestions.map((s) => ({ - ...s, - statusInfo: getServiceSuggestionStatusInfo(s.status), - messageCount: s._count.messages, - lastMessage: s.messages[0], -})) - -if (sortBy === 'service') { - suggestionsWithDetails = lodashOrderBy( - suggestionsWithDetails, - [(s) => s.service.name.toLowerCase()], - [sortOrder] - ) -} else if (sortBy === 'status') { - suggestionsWithDetails = lodashOrderBy(suggestionsWithDetails, [(s) => s.statusInfo.label], [sortOrder]) -} else if (sortBy === 'user') { - suggestionsWithDetails = lodashOrderBy( - suggestionsWithDetails, - [(s) => s.user.name.toLowerCase()], - [sortOrder] - ) -} else if (sortBy === 'messageCount') { - suggestionsWithDetails = lodashOrderBy(suggestionsWithDetails, ['messageCount'], [sortOrder]) -} - -const suggestionCount = suggestionsWithDetails.length - -const makeSortUrl = (slug: string) => { - const currentSortBy = filters['sort-by'] - const currentSortOrder = filters['sort-order'] - const newSortOrder = currentSortBy === slug && currentSortOrder === 'asc' ? 'desc' : 'asc' - const searchParams = new URLSearchParams(Astro.url.search) - searchParams.set('sort-by', slug) - searchParams.set('sort-order', newSortOrder) - return `/admin/service-suggestions?${searchParams.toString()}` -} ---- - - -
-

Service Suggestions

-
- {suggestionCount} suggestions -
-
- -
-
-
- - -
-
- - -
-
- -
-
-
- -
-
-

Suggestions List

-
- Scroll horizontally to see more → -
-
-
-
- - - - - - - - - - - - - { - suggestionsWithDetails.map((suggestion) => ( - - - - - - - - - )) - } - -
- - Service - - - - User - - - - Status - - - - Created - - - - Messages - - - Actions -
- -
- {suggestion.service.description} -
-
- - {suggestion.user.name} - - -
- - -
-
- - - - {suggestion.messageCount} - - -
- - - -
-
-
-
-
-
- - diff --git a/web/src/pages/admin/services/[slug]/edit.astro b/web/src/pages/admin/services/[slug]/edit.astro deleted file mode 100644 index ceba794..0000000 --- a/web/src/pages/admin/services/[slug]/edit.astro +++ /dev/null @@ -1,1367 +0,0 @@ ---- -import { - AttributeCategory, - Currency, - EventType, - VerificationStatus, - VerificationStepStatus, -} from '@prisma/client' -import { Icon } from 'astro-icon/components' -import { actions, isInputError } from 'astro:actions' -import { Image } from 'astro:assets' - -import { serviceVisibilities } from '../../../../constants/serviceVisibility' -import BaseLayout from '../../../../layouts/BaseLayout.astro' -import { cn } from '../../../../lib/cn' -import { prisma } from '../../../../lib/prisma' -import { ACCEPTED_IMAGE_TYPES } from '../../../../lib/zodUtils' - -const { slug } = Astro.params - -const serviceResult = Astro.getActionResult(actions.admin.service.update) -const eventCreateResult = Astro.getActionResult(actions.admin.event.create) -const eventToggleResult = Astro.getActionResult(actions.admin.event.toggle) -const eventDeleteResult = Astro.getActionResult(actions.admin.event.delete) -const eventUpdateResult = Astro.getActionResult(actions.admin.event.update) -const verificationStepCreateResult = Astro.getActionResult(actions.admin.verificationStep.create) -const verificationStepUpdateResult = Astro.getActionResult(actions.admin.verificationStep.update) -const verificationStepDeleteResult = Astro.getActionResult(actions.admin.verificationStep.delete) - -Astro.locals.banners.addIfSuccess(serviceResult, 'Service updated successfully') -Astro.locals.banners.addIfSuccess(eventCreateResult, 'Event created successfully') -Astro.locals.banners.addIfSuccess(eventToggleResult, 'Event visibility updated successfully') -Astro.locals.banners.addIfSuccess(eventDeleteResult, 'Event deleted successfully') -Astro.locals.banners.addIfSuccess(eventUpdateResult, 'Event updated successfully') -Astro.locals.banners.addIfSuccess(verificationStepCreateResult, 'Verification step added successfully') -Astro.locals.banners.addIfSuccess(verificationStepUpdateResult, 'Verification step updated successfully') -Astro.locals.banners.addIfSuccess(verificationStepDeleteResult, 'Verification step deleted successfully') - -if (serviceResult && !serviceResult.error && slug !== serviceResult.data.service.slug) { - return Astro.redirect(`/admin/services/${serviceResult.data.service.slug}/edit`) -} - -const serviceInputErrors = isInputError(serviceResult?.error) ? serviceResult.error.fields : {} -const eventInputErrors = isInputError(eventCreateResult?.error) ? eventCreateResult.error.fields : {} -const eventUpdateInputErrors = isInputError(eventUpdateResult?.error) ? eventUpdateResult.error.fields : {} -const verificationStepInputErrors = isInputError(verificationStepCreateResult?.error) - ? verificationStepCreateResult.error.fields - : {} -const verificationStepUpdateInputErrors = isInputError(verificationStepUpdateResult?.error) - ? verificationStepUpdateResult.error.fields - : {} - -if (!slug) return Astro.rewrite('/404') - -const service = await Astro.locals.banners.try('Error fetching service', () => - prisma.service.findUnique({ - where: { slug }, - include: { - attributes: { - select: { - attribute: { - select: { - id: true, - }, - }, - }, - }, - categories: { - select: { - id: true, - }, - }, - events: { - orderBy: { - startedAt: 'desc', - }, - }, - verificationRequests: { - select: { - id: true, - user: { - select: { - id: true, - name: true, - displayName: true, - }, - }, - createdAt: true, - }, - orderBy: { - createdAt: 'desc', - }, - }, - verificationSteps: { - orderBy: { - createdAt: 'desc', - }, - }, - contactMethods: { - orderBy: { - label: 'asc', - }, - }, - _count: { - select: { - verificationRequests: true, - }, - }, - }, - }) -) - -if (!service) return Astro.rewrite('/404') - -const categories = await Astro.locals.banners.try( - 'Error fetching categories', - () => - prisma.category.findMany({ - orderBy: { name: 'asc' }, - }), - [] -) - -const attributes = await Astro.locals.banners.try( - 'Error fetching attributes', - () => - prisma.attribute.findMany({ - orderBy: { category: 'asc' }, - }), - [] -) - -const inputBaseClasses = - 'w-full rounded-md border-zinc-600 bg-zinc-700/80 p-2 text-zinc-200 placeholder-zinc-400 focus:border-sky-500 focus:ring-1 focus:ring-sky-500 text-sm' -const labelBaseClasses = 'block text-sm font-medium text-zinc-300 mb-1' -const errorTextClasses = 'mt-1 text-xs text-red-400' -const checkboxLabelClasses = 'inline-flex items-center text-sm text-zinc-300' -const checkboxInputClasses = - 'rounded-sm border-zinc-500 bg-zinc-700 text-sky-500 focus:ring-sky-500 focus:ring-offset-zinc-800' - -// Button style constants -const buttonPrimaryClasses = - 'inline-flex items-center justify-center rounded-md border border-transparent bg-sky-600 px-3 py-1.5 text-sm font-medium text-white shadow-sm hover:bg-sky-700 focus:outline-none focus:ring-2 focus:ring-sky-500 focus:ring-offset-2 focus:ring-offset-zinc-900' - -const buttonSmallBaseClasses = 'rounded-md px-2 py-1 text-xs font-medium' -const buttonSmallPrimaryClasses = cn( - buttonSmallBaseClasses, - 'text-sky-400 hover:bg-sky-700/30 hover:text-sky-300' -) -const buttonSmallSecondaryClasses = cn( - buttonSmallBaseClasses, - 'text-zinc-400 hover:bg-zinc-700/50 hover:text-zinc-300' -) -const buttonSmallDestructiveClasses = cn( - buttonSmallBaseClasses, - 'text-red-400 hover:bg-red-700/30 hover:text-red-300' -) -const buttonSmallWarningClasses = cn( - buttonSmallBaseClasses, - 'text-yellow-400 hover:bg-yellow-700/30 hover:text-yellow-300' -) ---- - - -
-
-

- Editing {service.name} [{service.id}] -

- - - View Service Page - -
- -
-

- Service Details -

-
- -
- - - {serviceInputErrors.name &&

{serviceInputErrors.name.join(', ')}

} -
- -
- - - { - serviceInputErrors.description && ( -

{serviceInputErrors.description.join(', ')}

- ) - } -
- -
- - - {serviceInputErrors.slug &&

{serviceInputErrors.slug.join(', ')}

} -
- -
-
- - - { - serviceInputErrors.serviceUrls && ( -

{serviceInputErrors.serviceUrls.join(', ')}

- ) - } -
-
- - - { - serviceInputErrors.tosUrls && ( -

{serviceInputErrors.tosUrls.join(', ')}

- ) - } -
-
- - - { - serviceInputErrors.onionUrls && ( -

{serviceInputErrors.onionUrls.join(', ')}

- ) - } -
-
- - - {/* Assuming i2pUrls might have errors, add error display if schema supports it */} - { - /* serviceInputErrors.i2pUrls && ( -

{serviceInputErrors.i2pUrls.join(', ')}

- ) */ - } -
-
- -
-
-
- -
- -

- Leave empty to keep the current image. Square images (e.g., 256x256) recommended. -

-
- { - serviceInputErrors.imageFile && ( -

{serviceInputErrors.imageFile.join(', ')}

- ) - } -
- { - service.imageUrl ? ( -
- Current service image -
- ) : ( -
- -
- ) - } -
-
- -
-
- -
- { - categories.map((category) => ( - - )) - } -
- { - serviceInputErrors.categories && ( -

{serviceInputErrors.categories.join(', ')}

- ) - } -
- -
- - - { - serviceInputErrors.kycLevel && ( -

{serviceInputErrors.kycLevel.join(', ')}

- ) - } -
-
- -
- -
- { - Object.values(AttributeCategory).map((categoryValue) => ( -
-

{categoryValue}

-
- {attributes - .filter((attr) => attr.category === categoryValue) - .map((attr) => ( - - ))} -
- {serviceInputErrors.attributes && ( -

{serviceInputErrors.attributes.join(', ')}

- )} -
- )) - } -
-
- -
-
- - - { - serviceInputErrors.verificationStatus && ( -

{serviceInputErrors.verificationStatus.join(', ')}

- ) - } -
- -
- -
- { - Object.values(Currency).map((currency) => ( - - )) - } -
- { - serviceInputErrors.acceptedCurrencies && ( -

{serviceInputErrors.acceptedCurrencies.join(', ')}

- ) - } -
-
- -
- - - { - serviceInputErrors.verificationSummary && ( -

{serviceInputErrors.verificationSummary.join(', ')}

- ) - } -
- -
- - - { - serviceInputErrors.verificationProofMd && ( -

{serviceInputErrors.verificationProofMd.join(', ')}

- ) - } -
- -
- - - { - serviceInputErrors.referral && ( -

{serviceInputErrors.referral.join(', ')}

- ) - } -
- -
- -
- { - serviceVisibilities.map((visibility) => ( -
- - -
- )) - } -
- { - serviceInputErrors.serviceVisibility && ( -

{serviceInputErrors.serviceVisibility.join(', ')}

- ) - } -
- - -
-
- - -
-

- Events -

-
- - { - service.events.length > 0 && ( -
-

Existing Events

- {service.events.map((event) => ( -
-
-
-
- {event.title} - - {event.type} - - {!event.visible && ( - - Hidden - - )} -
-

{event.content}

-
- Started: {new Date(event.startedAt).toLocaleDateString()} - - Ended: - {event.endedAt - ? event.endedAt === event.startedAt - ? '1-time event' - : new Date(event.endedAt).toLocaleDateString() - : 'Ongoing'} - - {event.source && Source: {event.source}} -
-
-
-
- - -
- -
- - -
-
-
- {/* Edit Event Form - Hidden by default */} - -
- ))} -
- ) - } - -
- -

- - Add New Event -

-
-
- -
- - - {eventInputErrors.title &&

{eventInputErrors.title.join(', ')}

} -
-
- - - { - eventInputErrors.content && ( -

{eventInputErrors.content.join(', ')}

- ) - } -
-
-
- - - { - eventInputErrors.startedAt && ( -

{eventInputErrors.startedAt.join(', ')}

- ) - } -
-
- - - { - eventInputErrors.endedAt && ( -

{eventInputErrors.endedAt.join(', ')}

- ) - } -
-
-
-

End Date Options:

-
    -
  • Leave empty: Event is ongoing.
  • -
  • Same as start date: One-time event.
  • -
  • Future date: Event with specific end date.
  • -
-
-
-
- - - { - eventInputErrors.source && ( -

{eventInputErrors.source.join(', ')}

- ) - } -
-
- - - {eventInputErrors.type &&

{eventInputErrors.type.join(', ')}

} -
-
- -
-
-
-
- - -
-

- Verification Steps -

-
- - { - service.verificationSteps.length > 0 && ( -
-

Submitted Steps

- {service.verificationSteps.map((step) => ( -
-
-
-
- {step.title} - - {step.status.replace('_', ' ')} - -
-

{step.description}

- {step.evidenceMd && ( -

Evidence provided (see edit form)

- )} -

- Created: {new Date(step.createdAt).toLocaleDateString()} -

-
-
- -
- - -
-
-
- - {/* Edit Verification Step Form - Hidden by default */} - -
- ))} -
- ) - } - -
- -

- - Add New Verification Step -

-
-
- -
- - - { - verificationStepInputErrors.title && ( -

{verificationStepInputErrors.title.join(', ')}

- ) - } -
-
- - - { - verificationStepInputErrors.description && ( -

{verificationStepInputErrors.description.join(', ')}

- ) - } -
-
- - - { - verificationStepInputErrors.evidenceMd && ( -

{verificationStepInputErrors.evidenceMd.join(', ')}

- ) - } -
-
- - - { - verificationStepInputErrors.status && ( -

{verificationStepInputErrors.status.join(', ')}

- ) - } -
- -
-
-
-
- -
-

- Verification Requests - - {service._count.verificationRequests} - -

-
- { - service.verificationRequests.length > 0 ? ( -
- - - - - - - - - {service.verificationRequests.map((request) => ( - - - - - ))} - -
UserRequested At
{request.user.displayName ?? request.user.name}{new Date(request.createdAt).toLocaleString()}
-
- ) : ( -

No verification requests yet.

- ) - } -
-
- - -
-

- Contact Methods -

-
- - { - service.contactMethods.length > 0 && ( -
-

Existing Contact Methods

- {service.contactMethods.map((method) => ( -
-
-
-
- - {method.label} -
-

{method.value}

- {method.info &&

{method.info}

} -
-
- -
- - -
-
-
- - {/* Edit Contact Method Form - Hidden by default */} - -
- ))} -
- ) - } - -
- -

- - Add New Contact Method -

-
-
- -
- - -
-
- - -
-
- - -
-
- - -
- -
-
-
-
-
diff --git a/web/src/pages/admin/services/index.astro b/web/src/pages/admin/services/index.astro deleted file mode 100644 index 2a51f56..0000000 --- a/web/src/pages/admin/services/index.astro +++ /dev/null @@ -1,616 +0,0 @@ ---- -import { ServiceVisibility, VerificationStatus, type Prisma } from '@prisma/client' -import { z } from 'astro/zod' -import { Icon } from 'astro-icon/components' -import { Image } from 'astro:assets' - -import defaultImage from '../../../assets/fallback-service-image.jpg' -import SortArrowIcon from '../../../components/SortArrowIcon.astro' -import { getKycLevelInfo } from '../../../constants/kycLevels' -import { getVerificationStatusInfo } from '../../../constants/verificationStatus' -import BaseLayout from '../../../layouts/BaseLayout.astro' -import { cn } from '../../../lib/cn' -import { zodParseQueryParamsStoringErrors } from '../../../lib/parseUrlFilters' -import { prisma } from '../../../lib/prisma' - -const { data: filters } = zodParseQueryParamsStoringErrors( - { - search: z.string().optional(), - verificationStatus: z.nativeEnum(VerificationStatus).optional(), - visibility: z.nativeEnum(ServiceVisibility).optional(), - sort: z.enum(['name', 'createdAt', 'overallScore', 'verificationRequests']).default('name'), - order: z.enum(['asc', 'desc']).default('asc'), - page: z.coerce.number().int().positive().optional().default(1), - }, - Astro -) - -const itemsPerPage = 20 - -const sortProperty = filters.sort -const sortDirection = filters.order - -let orderBy: Prisma.ServiceOrderByWithRelationInput - -switch (sortProperty) { - case 'verificationRequests': - orderBy = { verificationRequests: { _count: sortDirection } } - break - case 'createdAt': // createdAt can be ambiguous without a specific direction - case 'name': - case 'overallScore': - orderBy = { [sortProperty]: sortDirection } - break - default: - orderBy = { name: 'asc' } // Default sort -} - -const whereClause: Prisma.ServiceWhereInput = { - ...(filters.search - ? { - OR: [ - { name: { contains: filters.search, mode: 'insensitive' } }, - { description: { contains: filters.search, mode: 'insensitive' } }, - { serviceUrls: { has: filters.search } }, - { tosUrls: { has: filters.search } }, - { onionUrls: { has: filters.search } }, - { i2pUrls: { has: filters.search } }, - ], - } - : {}), - verificationStatus: filters.verificationStatus ?? undefined, - serviceVisibility: filters.visibility ?? undefined, -} - -const totalServicesCount = await Astro.locals.banners.try( - 'Error counting services', - async () => prisma.service.count({ where: whereClause }), - 0 -) - -const totalPages = Math.ceil(totalServicesCount / itemsPerPage) -const validPage = Math.max(1, Math.min(filters.page, totalPages || 1)) -const skip = (validPage - 1) * itemsPerPage - -const services = await Astro.locals.banners.try( - 'Error fetching services', - async () => - prisma.service.findMany({ - where: whereClause, - select: { - id: true, - name: true, - slug: true, - description: true, - kycLevel: true, - overallScore: true, - privacyScore: true, - trustScore: true, - verificationStatus: true, - imageUrl: true, - serviceUrls: true, - tosUrls: true, - onionUrls: true, - i2pUrls: true, - serviceVisibility: true, - createdAt: true, - categories: { - select: { - id: true, - name: true, - icon: true, - }, - }, - attributes: { - include: { - attribute: true, - }, - }, - _count: { - select: { - verificationRequests: true, - }, - }, - }, - orderBy, - take: itemsPerPage, - skip, - }), - [] -) - -const servicesWithInfo = services.map((service) => { - const verificationStatusInfo = getVerificationStatusInfo(service.verificationStatus) - const kycLevelInfo = getKycLevelInfo(String(service.kycLevel)) - - return { - ...service, - verificationStatusInfo, - kycLevelInfo, - kycColor: - service.kycLevel === 0 - ? '22, 163, 74' // green-600 - : service.kycLevel === 1 - ? '180, 83, 9' // amber-700 - : service.kycLevel === 2 - ? '220, 38, 38' // red-600 - : service.kycLevel === 3 - ? '185, 28, 28' // red-700 - : service.kycLevel === 4 - ? '153, 27, 27' // red-800 - : '107, 114, 128', // gray-500 fallback - formattedDate: new Date(service.createdAt).toLocaleDateString('en-US', { - year: 'numeric', - month: 'short', - day: 'numeric', - }), - } -}) - -const makeSortUrl = (slug: NonNullable<(typeof filters)['sort']>) => { - const newOrder = filters.sort === slug && filters.order === 'asc' ? 'desc' : 'asc' - const searchParams = new URLSearchParams(Astro.url.search) - searchParams.set('sort', slug) - searchParams.set('order', newOrder) - return `/admin/services?${searchParams.toString()}` -} - -const getPaginationUrl = (pageNum: number) => { - const url = new URL(Astro.url) - url.searchParams.set('page', pageNum.toString()) - return url.toString() -} - -const truncate = (text: string, length: number) => { - if (text.length <= length) return text - return text.substring(0, length) + '...' -} ---- - - -
-

Service Management

-
- {totalServicesCount} services - - - New Service - -
-
- - -
-
-
- -
- -
-
- -
- - -
- -
- - -
- -
- -
- - -
-
-
-
- - -
-
-

Services List

-
- Scroll horizontally to see more → -
-
- -
-
- - - - - - - - - - - - - - { - servicesWithInfo.map((service) => ( - - - - - - - - - - )) - } - -
- - Service - - KYC - - Score - - Status - - - Reqs - - - - - Date - - Actions
-
-
- {service.imageUrl ? ( - {service.name} - ) : ( - {service.name} - )} -
-
-
{service.name}
-
- {truncate(service.description, 45)} -
-
- {service.categories.slice(0, 2).map((category) => ( - - - {category.name} - - ))} - {service.categories.length > 2 && ( - - +{service.categories.length - 2} - - )} -
-
-
-
- - {service.kycLevel} - - -
- = 7, - 'text-yellow-400': service.overallScore >= 4 && service.overallScore < 7, - 'text-red-400': service.overallScore < 4, - })} - > - {service.overallScore} - -
- - {service.privacyScore} - - - {service.trustScore} - -
-
-
- - - - {service.verificationStatus.substring(0, 4)} - -
- - {service.serviceVisibility} - -
-
- - {service._count.verificationRequests} - - {service.formattedDate} - -
-
-
-
- - {/* Pagination controls */} - { - totalPages > 1 && ( -
-
- Showing {services.length > 0 ? skip + 1 : 0} to {Math.min(skip + itemsPerPage, totalServicesCount)}{' '} - of {totalServicesCount} services -
- - -
- ) - } -
- - diff --git a/web/src/pages/admin/services/new.astro b/web/src/pages/admin/services/new.astro deleted file mode 100644 index 0482ad7..0000000 --- a/web/src/pages/admin/services/new.astro +++ /dev/null @@ -1,366 +0,0 @@ ---- -import { AttributeCategory, Currency, VerificationStatus } from '@prisma/client' -import { Icon } from 'astro-icon/components' -import { actions, isInputError } from 'astro:actions' - -import BaseLayout from '../../../layouts/BaseLayout.astro' -import { cn } from '../../../lib/cn' -import { prisma } from '../../../lib/prisma' - -const categories = await Astro.locals.banners.try('Failed to fetch categories', () => - prisma.category.findMany({ - orderBy: { name: 'asc' }, - }) -) - -const attributes = await Astro.locals.banners.try('Failed to fetch attributes', () => - prisma.attribute.findMany({ - orderBy: { category: 'asc' }, - }) -) - -const result = Astro.getActionResult(actions.admin.service.create) -Astro.locals.banners.addIfSuccess(result, 'Service created successfully') -if (result && !result.error) { - return Astro.redirect(`/admin/services/${result.data.service.slug}/edit`) -} -const inputErrors = isInputError(result?.error) ? result.error.fields : {} ---- - - -
-
- service.create -
- -
-
- - - { - inputErrors.name && ( -

{inputErrors.name.join(', ')}

- ) - } -
- -
- - - { - inputErrors.description && ( -

{inputErrors.description.join(', ')}

- ) - } -
- -
- - - { - inputErrors.serviceUrls && ( -

{inputErrors.serviceUrls.join(', ')}

- ) - } -
- -
- - - { - inputErrors.tosUrls && ( -

{inputErrors.tosUrls.join(', ')}

- ) - } -
- -
- - - { - inputErrors.onionUrls && ( -

{inputErrors.onionUrls.join(', ')}

- ) - } -
- -
- -
- -

- Upload a square image for best results. Supported formats: JPG, PNG, WebP, SVG. -

-
- { - inputErrors.imageFile && ( -

{inputErrors.imageFile.join(', ')}

- ) - } -
- -
- -
- { - categories?.map((category) => ( - - )) - } -
- { - inputErrors.categories && ( -

{inputErrors.categories.join(', ')}

- ) - } -
- -
- - - { - inputErrors.kycLevel && ( -

{inputErrors.kycLevel.join(', ')}

- ) - } -
- -
- -
- { - Object.values(AttributeCategory).map((category) => ( -
-

{category}

-
- {attributes - ?.filter((attr) => attr.category === category) - .map((attr) => ( - - ))} -
- {inputErrors.attributes && ( -

{inputErrors.attributes.join(', ')}

- )} -
- )) - } -
-
- -
- - - { - inputErrors.verificationStatus && ( -

{inputErrors.verificationStatus.join(', ')}

- ) - } -
- -
- - - { - inputErrors.verificationSummary && ( -

{inputErrors.verificationSummary.join(', ')}

- ) - } -
- -
- - - { - inputErrors.verificationProofMd && ( -

{inputErrors.verificationProofMd.join(', ')}

- ) - } -
- -
- -
- { - Object.values(Currency).map((currency) => ( - - )) - } -
- { - inputErrors.acceptedCurrencies && ( -

{inputErrors.acceptedCurrencies.join(', ')}

- ) - } -
- -
- - - { - inputErrors.overallScore && ( -

{inputErrors.overallScore.join(', ')}

- ) - } -
- -
- - - { - inputErrors.referral && ( -

{inputErrors.referral.join(', ')}

- ) - } -
- - -
-
-
diff --git a/web/src/pages/admin/users/[username].astro b/web/src/pages/admin/users/[username].astro deleted file mode 100644 index 32a394f..0000000 --- a/web/src/pages/admin/users/[username].astro +++ /dev/null @@ -1,626 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { actions, isInputError } from 'astro:actions' - -import Tooltip from '../../../components/Tooltip.astro' -import BaseLayout from '../../../layouts/BaseLayout.astro' -import { prisma } from '../../../lib/prisma' -import { transformCase } from '../../../lib/strings' -import { timeAgo } from '../../../lib/timeAgo' - -const { username } = Astro.params - -if (!username) return Astro.rewrite('/404') - -const updateResult = Astro.getActionResult(actions.admin.user.update) -Astro.locals.banners.addIfSuccess(updateResult, 'User updated successfully') -if (updateResult && !updateResult.error && username !== updateResult.data.updatedUser.name) { - return Astro.redirect(`/admin/users/${updateResult.data.updatedUser.name}`) -} -const updateInputErrors = isInputError(updateResult?.error) ? updateResult.error.fields : {} - -const addAffiliationResult = Astro.getActionResult(actions.admin.user.serviceAffiliations.add) -Astro.locals.banners.addIfSuccess(addAffiliationResult, 'Service affiliation added successfully') - -const removeAffiliationResult = Astro.getActionResult(actions.admin.user.serviceAffiliations.remove) -Astro.locals.banners.addIfSuccess(removeAffiliationResult, 'Service affiliation removed successfully') - -const [user, allServices] = await Astro.locals.banners.tryMany([ - [ - 'Failed to load user profile', - async () => { - if (!username) return null - - return await prisma.user.findUnique({ - where: { name: username }, - select: { - id: true, - name: true, - displayName: true, - picture: true, - link: true, - admin: true, - verified: true, - verifier: true, - spammer: true, - verifiedLink: true, - internalNotes: { - select: { - id: true, - content: true, - createdAt: true, - addedByUser: { - select: { - id: true, - name: true, - }, - }, - }, - orderBy: { - createdAt: 'desc', - }, - }, - serviceAffiliations: { - select: { - id: true, - role: true, - createdAt: true, - service: { - select: { - id: true, - name: true, - slug: true, - }, - }, - }, - orderBy: { - createdAt: 'desc', - }, - }, - }, - }) - }, - null, - ], - [ - 'Failed to load services', - async () => { - return await prisma.service.findMany({ - select: { - id: true, - name: true, - }, - orderBy: { - name: 'asc', - }, - }) - }, - [], - ], -]) - -if (!user) return Astro.rewrite('/404') ---- - - -
-
-

User Profile: {user.name}

- - - Back to Users - -
- -
-
- { - user.picture ? ( - - ) : ( -
- {user.name.charAt(0) || 'A'} -
- ) - } -
-

{user.name}

-
- { - user.admin && ( - - admin - - ) - } - { - user.verified && ( - - verified - - ) - } - { - user.verifier && ( - - verifier - - ) - } -
-
-
- -
- - -
- - - { - updateInputErrors.name && ( -

{updateInputErrors.name.join(', ')}

- ) - } -
- -
- - - { - Array.isArray(updateInputErrors.displayName) && updateInputErrors.displayName.length > 0 && ( -

{updateInputErrors.displayName.join(', ')}

- ) - } -
- -
- - - { - updateInputErrors.link && ( -

{updateInputErrors.link.join(', ')}

- ) - } -
- -
- - - { - updateInputErrors.picture && ( -

{updateInputErrors.picture.join(', ')}

- ) - } -
- -
- - -

- Upload a square image for best results. Supported formats: JPG, PNG, WebP, AVIF, JXL. Max size: - 5MB. -

-
- -
- - - - - Verified - - - - - -
- - { - updateInputErrors.admin && ( -

{updateInputErrors.admin.join(', ')}

- ) - } - { - updateInputErrors.verifier && ( -

{updateInputErrors.verifier.join(', ')}

- ) - } - { - updateInputErrors.spammer && ( -

{updateInputErrors.spammer.join(', ')}

- ) - } - -
- - - { - updateInputErrors.verifiedLink && ( -

{updateInputErrors.verifiedLink.join(', ')}

- ) - } -
- -
- -
-
- { - Astro.locals.user && user.id !== Astro.locals.user.id && ( - - - Impersonate - - ) - } -
- -
-

Internal Notes

- - { - user.internalNotes.length === 0 ? ( -

No internal notes yet.

- ) : ( -
- {user.internalNotes.map((note) => ( -
-
-
- - {note.addedByUser ? note.addedByUser.name : 'System'} - - - {transformCase(timeAgo.format(note.createdAt, 'twitter-minute-now'), 'sentence')} - -
- -
- - -
- - -
-
-
-
-

{note.content}

-
- -
- ))} -
- ) - } - -
- - - -
-
- -
-

Service Affiliations

- - { - user.serviceAffiliations.length === 0 ? ( -

No service affiliations yet.

- ) : ( -
- {user.serviceAffiliations.map((affiliation) => ( -
-
-
- - {affiliation.service.name} - - - {affiliation.role.toLowerCase()} - -
-
- - {transformCase(timeAgo.format(affiliation.createdAt, 'twitter-minute-now'), 'sentence')} - -
-
- -
- - -
-
- ))} -
- ) - } - -
- - -
-
- - -
- -
- - -
-
- -
- -
-
-
-
-
- - - - diff --git a/web/src/pages/admin/users/index.astro b/web/src/pages/admin/users/index.astro deleted file mode 100644 index ec97374..0000000 --- a/web/src/pages/admin/users/index.astro +++ /dev/null @@ -1,377 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { z } from 'astro:content' -import { orderBy as lodashOrderBy } from 'lodash-es' - -import SortArrowIcon from '../../../components/SortArrowIcon.astro' -import TimeFormatted from '../../../components/TimeFormatted.astro' -import Tooltip from '../../../components/Tooltip.astro' -import BaseLayout from '../../../layouts/BaseLayout.astro' -import { zodParseQueryParamsStoringErrors } from '../../../lib/parseUrlFilters' -import { pluralize } from '../../../lib/pluralize' -import { prisma } from '../../../lib/prisma' -import { formatDateShort } from '../../../lib/timeAgo' - -import type { Prisma } from '@prisma/client' - -const { data: filters } = zodParseQueryParamsStoringErrors( - { - 'sort-by': z.enum(['name', 'role', 'createdAt', 'karma']).default('createdAt'), - 'sort-order': z.enum(['asc', 'desc']).default('desc'), - search: z.string().optional(), - role: z.enum(['user', 'admin', 'verifier', 'verified', 'spammer']).optional(), - }, - Astro -) - -// Set up Prisma orderBy with correct typing -const prismaOrderBy = - filters['sort-by'] === 'name' || filters['sort-by'] === 'createdAt' || filters['sort-by'] === 'karma' - ? { - [filters['sort-by'] === 'karma' ? 'totalKarma' : filters['sort-by']]: - filters['sort-order'] === 'asc' ? 'asc' : 'desc', - } - : { createdAt: 'desc' as const } - -// Build where clause based on role filter -const whereClause: Prisma.UserWhereInput = {} - -if (filters.search) { - whereClause.OR = [{ name: { contains: filters.search, mode: 'insensitive' } }] -} - -if (filters.role) { - switch (filters.role) { - case 'user': { - whereClause.admin = false - whereClause.verifier = false - whereClause.verified = false - whereClause.spammer = false - break - } - case 'admin': { - whereClause.admin = true - break - } - case 'verifier': { - whereClause.verifier = true - break - } - case 'verified': { - whereClause.verified = true - break - } - case 'spammer': { - whereClause.spammer = true - break - } - } -} - -// Retrieve users from the database -const dbUsers = await prisma.user.findMany({ - where: whereClause, - select: { - id: true, - name: true, - verified: true, - admin: true, - verifier: true, - spammer: true, - totalKarma: true, - createdAt: true, - updatedAt: true, - internalNotes: { - select: { - id: true, - content: true, - createdAt: true, - }, - }, - _count: { - select: { - suggestions: true, - comments: true, - }, - }, - }, - orderBy: prismaOrderBy, -}) - -const users = - filters['sort-by'] === 'role' - ? lodashOrderBy(dbUsers, [(u) => (u.admin ? 'admin' : 'user')], [filters['sort-order']]) - : dbUsers - -const makeSortUrl = (slug: NonNullable<(typeof filters)['sort-by']>) => { - const currentSortBy = filters['sort-by'] - const currentSortOrder = filters['sort-order'] - const newSortOrder = currentSortBy === slug && currentSortOrder === 'asc' ? 'desc' : 'asc' - const searchParams = new URLSearchParams(Astro.url.search) - searchParams.set('sort-by', slug) - searchParams.set('sort-order', newSortOrder) - return `/admin/users?${searchParams.toString()}` -} ---- - - -
-

User Management

-
- {users.length} users -
-
- -
-
-
- - -
-
- -
- - -
-
-
-
- -
-
-

Users List

-
- Scroll horizontally to see more → -
-
-
-
- - - - - - - - - - - - - - { - users.map((user) => ( - - - - - - - - - - )) - } - -
- - Name - - - Status - - - Role - - - - Karma - - - - Joined - - - Activity - - Actions -
-
{user.name}
- {user.internalNotes.length > 0 && ( - - `${formatDateShort(note.createdAt, { - prefix: false, - hourPrecision: true, - caseType: 'sentence', - })}: ${note.content}` - ) - .join('\n\n')} - > - - {user.internalNotes.length} internal {pluralize('note', user.internalNotes.length)} - - )} -
-
- {user.spammer && ( - - - Spammer - - )} - {user.verified && ( - - - Verified - - )} - {user.verifier && ( - - - Verifier - - )} -
-
- - {user.admin ? 'Admin' : 'User'} - - - = 100 ? 'text-green-400' : user.totalKarma >= 0 ? 'text-zinc-300' : 'text-red-400'}`} - > - {user.totalKarma} - - - - -
-
- Suggestions - - {user._count.suggestions} - -
-
- Comments - - {user._count.comments} - -
-
-
-
- - - - - - -
-
-
-
-
-
- - diff --git a/web/src/pages/attributes.astro b/web/src/pages/attributes.astro deleted file mode 100644 index 7cc6753..0000000 --- a/web/src/pages/attributes.astro +++ /dev/null @@ -1,403 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { Markdown } from 'astro-remote' -import { Picture } from 'astro:assets' -import { z } from 'astro:content' -import { orderBy } from 'lodash-es' - -import BadgeStandard from '../components/BadgeStandard.astro' -import { makeOverallScoreInfo } from '../components/ScoreSquare.astro' -import SortArrowIcon from '../components/SortArrowIcon.astro' -import { getAttributeCategoryInfo } from '../constants/attributeCategories' -import { getAttributeTypeInfo } from '../constants/attributeTypes' -import { getVerificationStatusInfo } from '../constants/verificationStatus' -import BaseLayout from '../layouts/BaseLayout.astro' -import { sortAttributes } from '../lib/attributes' -import { cn } from '../lib/cn' -import { formatNumber } from '../lib/numbers' -import { zodParseQueryParamsStoringErrors } from '../lib/parseUrlFilters' -import { prisma } from '../lib/prisma' - -const { data: filters } = zodParseQueryParamsStoringErrors( - { - 'sort-by': z.enum(['name', 'category', 'type', 'privacy', 'trust']), - 'sort-order': z.enum(['asc', 'desc']).default('asc'), - }, - Astro -) - -const attributes = await Astro.locals.banners.try( - 'Error fetching attributes', - async () => - prisma.attribute.findMany({ - select: { - id: true, - slug: true, - title: true, - description: true, - category: true, - type: true, - privacyPoints: true, - trustPoints: true, - services: { - select: { - service: { - select: { - id: true, - slug: true, - name: true, - imageUrl: true, - overallScore: true, - verificationStatus: true, - }, - }, - }, - }, - }, - }), - [] -) - -const sortBy = filters['sort-by'] -const sortedAttributes = sortBy - ? orderBy( - sortAttributes(attributes), - sortBy === 'type' - ? (attribute) => getAttributeTypeInfo(attribute.type).order - : sortBy === 'category' - ? (attribute) => getAttributeCategoryInfo(attribute.category).order - : sortBy === 'name' - ? 'title' - : sortBy === 'privacy' - ? 'privacyPoints' - : 'trustPoints', - filters['sort-order'] - ) - : sortAttributes(attributes) - -const attributesWithInfo = sortedAttributes.map((attribute) => ({ - ...attribute, - categoryInfo: getAttributeCategoryInfo(attribute.category), - typeInfo: getAttributeTypeInfo(attribute.type), - services: orderBy( - attribute.services.map(({ service }) => ({ - ...service, - verificationStatusInfo: getVerificationStatusInfo(service.verificationStatus), - overallScoreInfo: makeOverallScoreInfo(service.overallScore), - })), - [ - (service) => (service.verificationStatus === 'VERIFICATION_FAILED' ? 1 : -1), - 'overallScore', - () => Math.random(), - ], - ['asc', 'desc', 'asc'] - ), -})) - -const makeSortUrl = (slug: NonNullable<(typeof filters)['sort-by']>) => { - const sortOrder = filters['sort-by'] === slug ? (filters['sort-order'] === 'asc' ? 'desc' : 'asc') : 'asc' - return `/attributes?sort-by=${slug}&sort-order=${sortOrder}` -} ---- - - -

Service attributes

- -

- Characteristics or features of services that affect their scores. -

-

- - - Learn more about attributes - -

- - -
- { - attributesWithInfo.map((attribute) => ( -
-
-

- {attribute.title} -

-
- - -
-
- -
- -
- -
-
- 0, - 'opacity-50': attribute.privacyPoints === 0, - })} - > - {formatNumber(attribute.privacyPoints, { showSign: true })} - - - Privacy - -
- -
- 0, - 'opacity-50': attribute.trustPoints === 0, - })} - > - {formatNumber(attribute.trustPoints, { showSign: true })} - - - Trust - -
-
- - {attribute.services.length > 0 && ( -
- - Show services - - - -
- )} -
- )) - } -
- - - -
diff --git a/web/src/pages/events.astro b/web/src/pages/events.astro deleted file mode 100644 index 04ccb56..0000000 --- a/web/src/pages/events.astro +++ /dev/null @@ -1,474 +0,0 @@ ---- -import { z } from 'astro/zod' -import { Icon } from 'astro-icon/components' -import { Picture } from 'astro:assets' -import { orderBy } from 'lodash-es' - -import Button from '../components/Button.astro' -import FormatTimeInterval from '../components/FormatTimeInterval.astro' -import TimeFormatted from '../components/TimeFormatted.astro' -import { - eventTypes, - eventTypesZodEnumBySlug, - getEventTypeInfo, - getEventTypeInfoBySlug, -} from '../constants/eventTypes' -import { getVerificationStatusInfo } from '../constants/verificationStatus' -import BaseLayout from '../layouts/BaseLayout.astro' -import { cn } from '../lib/cn' -import { zodParseQueryParamsStoringErrors } from '../lib/parseUrlFilters' -import { prisma } from '../lib/prisma' -import { formatDateShort } from '../lib/timeAgo' -import { createPageUrl } from '../lib/urls' - -import type { Prisma } from '@prisma/client' - -const PAGE_SIZE = 100 - -const { data: params, hasDefaultData: hasDefaultFilters } = zodParseQueryParamsStoringErrors( - { - page: z.coerce.number().int().min(1).default(1), - now: z.coerce.date().default(new Date()), - from: z.preprocess((val) => (val === '' ? undefined : val), z.coerce.date().optional()), - to: z.preprocess((val) => (val === '' ? undefined : val), z.coerce.date().optional()), - /** Service's slug */ - service: z.string().optional(), - type: eventTypesZodEnumBySlug.optional(), - }, - Astro -) - -const [services, [dbEvents, totalEvents]] = await Astro.locals.banners.tryMany([ - [ - 'Error fetching services', - async () => - prisma.service.findMany({ - where: { - events: { - some: { - visible: true, - }, - }, - }, - select: { - id: true, - slug: true, - name: true, - imageUrl: true, - verificationStatus: true, - }, - orderBy: { - name: 'asc', - }, - }), - [], - ], - [ - 'Error fetching events', - async () => - prisma.event.findManyAndCount({ - where: { - visible: true, - createdAt: { - lte: params.now, - }, - ...(params.service ? { service: { slug: params.service } } : {}), - ...(params.type ? { type: getEventTypeInfoBySlug(params.type).id } : {}), - ...(params.from || params.to - ? { - OR: [ - ...(params.from - ? ([ - { endedAt: null }, - { endedAt: { gte: params.from } }, - ] satisfies Prisma.EventWhereInput[]) - : []), - ...(params.to - ? ([{ startedAt: { lte: params.to } }] satisfies Prisma.EventWhereInput[]) - : []), - ], - } - : {}), - }, - select: { - id: true, - title: true, - content: true, - source: true, - type: true, - startedAt: true, - endedAt: true, - service: { - select: { - id: true, - slug: true, - name: true, - imageUrl: true, - verificationStatus: true, - }, - }, - }, - orderBy: { - startedAt: 'desc', - }, - skip: (params.page - 1) * PAGE_SIZE, - take: PAGE_SIZE, - }), - [[], 0] as const, - ], -]) - -const events = orderBy( - dbEvents.map((event) => ({ - ...event, - actualEndedAt: event.endedAt ?? params.now, - typeInfo: getEventTypeInfo(event.type), - service: { - ...event.service, - verificationStatusInfo: getVerificationStatusInfo(event.service.verificationStatus), - }, - })), - ['actualEndedAt', 'startedAt'], - 'desc' -) -const totalPages = Math.ceil(totalEvents / PAGE_SIZE) || 1 -const hasMorePages = params.page < totalPages - -const createUrlWithoutFilter = (paramName: keyof typeof params) => { - const url = new URL(Astro.url) - url.searchParams.delete(paramName) - url.searchParams.forEach((value, key) => { - if (value === '') { - url.searchParams.delete(key) - } - }) - return url.toString() -} ---- - - -

- Service Events Timeline -

-
-
-

- FILTERS -

- - - Clear all - -
- - - - - - - - - - - - - -
- - - Page {params.page} of {totalPages} - -
- - -
- - )} - - ) - } - - { - !!notificationPreferences && ( -
-

- - Notification Settings -

- -
- {notificationPreferenceFields.map((field) => ( - - ))} - -
-
-
-
- ) - } - -
diff --git a/web/src/pages/ogimage.png.ts b/web/src/pages/ogimage.png.ts deleted file mode 100644 index 211baa9..0000000 --- a/web/src/pages/ogimage.png.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { ogImageTemplates } from '../components/OgImage' -import { urlParamsToObject } from '../lib/urls' - -import type { APIRoute } from 'astro' - -export const GET: APIRoute = ({ url }) => { - const { template, ...props } = urlParamsToObject(url.searchParams) - - if (!template) return ogImageTemplates.default() - - if (!(template in ogImageTemplates)) { - console.error(`Invalid template: "${template}"`) - return ogImageTemplates.default() - } - - const response = ogImageTemplates[template as keyof typeof ogImageTemplates](props) - // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition - if (!response) { - console.error(`Cannot generate image for template: ${template} and props: ${JSON.stringify(props)}`) - return ogImageTemplates.default() - } - - return response -} diff --git a/web/src/pages/service-suggestion/[id].astro b/web/src/pages/service-suggestion/[id].astro deleted file mode 100644 index a18239e..0000000 --- a/web/src/pages/service-suggestion/[id].astro +++ /dev/null @@ -1,163 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { actions } from 'astro:actions' - -import AdminOnly from '../../components/AdminOnly.astro' -import Chat from '../../components/Chat.astro' -import ServiceCard from '../../components/ServiceCard.astro' -import { getServiceSuggestionStatusInfo } from '../../constants/serviceSuggestionStatus' -import BaseLayout from '../../layouts/BaseLayout.astro' -import { cn } from '../../lib/cn' -import { parseIntWithFallback } from '../../lib/numbers' -import { prisma } from '../../lib/prisma' -import { makeLoginUrl } from '../../lib/redirectUrls' -import { formatDateShort } from '../../lib/timeAgo' - -const user = Astro.locals.user -if (!user) { - return Astro.redirect(makeLoginUrl(Astro.url, { message: 'Login to view service suggestion' })) -} - -const { id: serviceSuggestionIdRaw } = Astro.params -const serviceSuggestionId = parseIntWithFallback(serviceSuggestionIdRaw) -if (!serviceSuggestionId) { - return Astro.rewrite('/404') -} - -const serviceSuggestion = await Astro.locals.banners.try('Error fetching service suggestion', async () => - prisma.serviceSuggestion.findUnique({ - select: { - id: true, - status: true, - notes: true, - createdAt: true, - service: { - select: { - id: true, - name: true, - slug: true, - description: true, - overallScore: true, - kycLevel: true, - imageUrl: true, - verificationStatus: true, - acceptedCurrencies: true, - categories: { - select: { - name: true, - icon: true, - }, - }, - }, - }, - messages: { - select: { - id: true, - content: true, - createdAt: true, - user: { - select: { - id: true, - name: true, - picture: true, - }, - }, - }, - orderBy: { - createdAt: 'desc', - }, - }, - }, - where: { - id: serviceSuggestionId, - userId: user.id, - }, - }) -) - -if (!serviceSuggestion) { - if (user.admin) return Astro.redirect(`/admin/service-suggestions/${serviceSuggestionIdRaw}`) - return Astro.rewrite('/404') -} - -const statusInfo = getServiceSuggestionStatusInfo(serviceSuggestion.status) ---- - - -

Edit service

- - - - - View in admin - - - - - -
-
-
- Status: - - - {statusInfo.label} - -
- -
- Submitted: - - { - formatDateShort(serviceSuggestion.createdAt, { - prefix: false, - hourPrecision: true, - caseType: 'sentence', - }) - } - -
-
- -
-
Notes for moderators:
-
- {serviceSuggestion.notes ?? Empty} -
-
-
- - -
diff --git a/web/src/pages/service-suggestion/edit.astro b/web/src/pages/service-suggestion/edit.astro deleted file mode 100644 index 8eda41d..0000000 --- a/web/src/pages/service-suggestion/edit.astro +++ /dev/null @@ -1,102 +0,0 @@ ---- -import { actions, isInputError } from 'astro:actions' -import { z } from 'astro:content' - -import Captcha from '../../components/Captcha.astro' -import InputHoneypotTrap from '../../components/InputHoneypotTrap.astro' -import InputSubmitButton from '../../components/InputSubmitButton.astro' -import InputTextArea from '../../components/InputTextArea.astro' -import ServiceCard from '../../components/ServiceCard.astro' -import BaseLayout from '../../layouts/BaseLayout.astro' -import { zodParseQueryParamsStoringErrors } from '../../lib/parseUrlFilters' -import { prisma } from '../../lib/prisma' -import { makeLoginUrl } from '../../lib/redirectUrls' - -const user = Astro.locals.user -if (!user) { - return Astro.redirect(makeLoginUrl(Astro.url, { message: 'Login to suggest a new service' })) -} - -const result = Astro.getActionResult(actions.serviceSuggestion.editService) -if (result && !result.error) { - return Astro.redirect(`/service-suggestion/${result.data.serviceSuggestion.id}`) -} -const inputErrors = isInputError(result?.error) ? result.error.fields : {} - -const { data: params } = zodParseQueryParamsStoringErrors( - { - serviceId: z.coerce.number().int().positive(), - notes: z.string().default(''), - }, - Astro -) - -if (!params.serviceId) return Astro.rewrite('/404') - -const service = await Astro.locals.banners.try( - 'Failed to fetch service', - async () => - prisma.service.findUnique({ - select: { - id: true, - name: true, - slug: true, - description: true, - overallScore: true, - kycLevel: true, - imageUrl: true, - verificationStatus: true, - acceptedCurrencies: true, - categories: { - select: { - name: true, - icon: true, - }, - }, - }, - where: { id: params.serviceId }, - }), - null -) - -if (!service) return Astro.rewrite('/404') ---- - - -

Edit service

- - - -
- - - - - - - - - - -
diff --git a/web/src/pages/service-suggestion/index.astro b/web/src/pages/service-suggestion/index.astro deleted file mode 100644 index 464cfa1..0000000 --- a/web/src/pages/service-suggestion/index.astro +++ /dev/null @@ -1,174 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { actions } from 'astro:actions' -import { Picture } from 'astro:assets' -import { z } from 'astro:content' - -import defaultServiceImage from '../../assets/fallback-service-image.jpg' -import Button from '../../components/Button.astro' -import TimeFormatted from '../../components/TimeFormatted.astro' -import Tooltip from '../../components/Tooltip.astro' -import { - getServiceSuggestionStatusInfo, - serviceSuggestionStatuses, -} from '../../constants/serviceSuggestionStatus' -import { getServiceSuggestionTypeInfo } from '../../constants/serviceSuggestionType' -import BaseLayout from '../../layouts/BaseLayout.astro' -import { zodEnumFromConstant } from '../../lib/arrays' -import { cn } from '../../lib/cn' -import { zodParseQueryParamsStoringErrors } from '../../lib/parseUrlFilters' -import { prisma } from '../../lib/prisma' -import { makeLoginUrl } from '../../lib/redirectUrls' - -const user = Astro.locals.user -if (!user) { - return Astro.redirect(makeLoginUrl(Astro.url, { message: 'Login to manage service suggestions' })) -} - -const { data: filters } = zodParseQueryParamsStoringErrors( - { - serviceId: z.array(z.number().int().positive()).default([]), - status: z.array(zodEnumFromConstant(serviceSuggestionStatuses, 'value')).default([]), - }, - Astro -) - -const serviceSuggestions = await Astro.locals.banners.try('Error fetching service suggestions', async () => - prisma.serviceSuggestion.findMany({ - select: { - id: true, - type: true, - status: true, - createdAt: true, - service: { - select: { - id: true, - name: true, - slug: true, - imageUrl: true, - verificationStatus: true, - }, - }, - }, - where: { - id: filters.serviceId.length > 0 ? { in: filters.serviceId } : undefined, - status: filters.status.length > 0 ? { in: filters.status } : undefined, - userId: user.id, - }, - orderBy: { - createdAt: 'desc', - }, - }) -) - -if (!serviceSuggestions) { - return Astro.rewrite('/404') -} - -const createResult = Astro.getActionResult(actions.serviceSuggestion.createService) -const success = !!createResult && !createResult.error ---- - - -
-

Service suggestions

-
- - { - success && ( -
- - Service suggestion submitted successfully! -
- ) - } - - { - serviceSuggestions.length === 0 ? ( -

No suggestions yet.

- ) : ( -
-
-

Service

-

Type

-

Status

-

Created

-

Actions

- - {serviceSuggestions.map((suggestion) => { - const typeInfo = getServiceSuggestionTypeInfo(suggestion.type) - const statusInfo = getServiceSuggestionStatusInfo(suggestion.status) - - return ( - <> - - - {suggestion.service.name} - - - - - - - - - - - - - - -
-
- ) - } -
diff --git a/web/src/pages/service-suggestion/new.astro b/web/src/pages/service-suggestion/new.astro deleted file mode 100644 index a987c96..0000000 --- a/web/src/pages/service-suggestion/new.astro +++ /dev/null @@ -1,308 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { actions, isInputError } from 'astro:actions' - -import { - SUGGESTION_DESCRIPTION_MAX_LENGTH, - SUGGESTION_NAME_MAX_LENGTH, - SUGGESTION_NOTES_MAX_LENGTH, - SUGGESTION_SLUG_MAX_LENGTH, -} from '../../actions/serviceSuggestion' -import Captcha from '../../components/Captcha.astro' -import InputCardGroup from '../../components/InputCardGroup.astro' -import InputCheckboxGroup from '../../components/InputCheckboxGroup.astro' -import InputHoneypotTrap from '../../components/InputHoneypotTrap.astro' -import InputImageFile from '../../components/InputImageFile.astro' -import InputSubmitButton from '../../components/InputSubmitButton.astro' -import InputText from '../../components/InputText.astro' -import InputTextArea from '../../components/InputTextArea.astro' -import { currencies } from '../../constants/currencies' -import { kycLevels } from '../../constants/kycLevels' -import BaseLayout from '../../layouts/BaseLayout.astro' -import { prisma } from '../../lib/prisma' -import { makeLoginUrl } from '../../lib/redirectUrls' - -const user = Astro.locals.user -if (!user) { - return Astro.redirect(makeLoginUrl(Astro.url, { message: 'Login to suggest a new service' })) -} - -const result = Astro.getActionResult(actions.serviceSuggestion.createService) -if (result && !result.error && !result.data.hasDuplicates) { - return Astro.redirect(`/service-suggestion/${result.data.serviceSuggestion.id}`) -} -const inputErrors = isInputError(result?.error) ? result.error.fields : {} - -const [categories, attributes] = await Astro.locals.banners.tryMany([ - [ - 'Failed to fetch categories', - () => - prisma.category.findMany({ - orderBy: { name: 'asc' }, - select: { - id: true, - name: true, - icon: true, - }, - }), - [], - ], - [ - 'Failed to fetch attributes', - () => - prisma.attribute.findMany({ - orderBy: { category: 'asc' }, - select: { - id: true, - title: true, - }, - }), - [], - ], -]) ---- - - -

Service suggestion

- -
- { - result?.data?.hasDuplicates && ( - <> -
- - -

- Possible duplicates found -

- -

Is your service already listed below?

- -
- {result.data.possibleDuplicates.map((duplicate) => { - const editServiceUrl = new URL('/service-suggestion/edit', Astro.url) - editServiceUrl.searchParams.set('serviceId', duplicate.id.toString()) - if (result.data.extraNotes) { - editServiceUrl.searchParams.set('notes', result.data.extraNotes) - } - - return ( -
-
-

{duplicate.name}

-

{duplicate.description}

-
- -
- ) - })} -
- - -

- Review your suggestion -

- - ) - } - - - - - - - - - - - - - ({ - label: kycLevel.name, - value: kycLevel.id.toString(), - icon: kycLevel.icon, - description: `${kycLevel.description}\n\n_KYC Level ${kycLevel.value}/4_`, - }))} - iconSize="md" - cardSize="md" - required - error={inputErrors.kycLevel} - /> - - ({ - label: category.name, - value: category.id.toString(), - icon: category.icon, - }))} - error={inputErrors.categories} - /> - - ({ - label: attribute.title, - value: attribute.id.toString(), - }))} - error={inputErrors.attributes} - /> - - ({ - label: currency.name, - value: currency.id, - icon: currency.icon, - }))} - error={inputErrors.acceptedCurrencies} - required - multiple - /> - - - - - - - - - - - - - - diff --git a/web/src/pages/service/[slug].astro b/web/src/pages/service/[slug].astro deleted file mode 100644 index f6236fd..0000000 --- a/web/src/pages/service/[slug].astro +++ /dev/null @@ -1,1506 +0,0 @@ ---- -import { VerificationStepStatus } from '@prisma/client' -import { Icon } from 'astro-icon/components' -import { Markdown } from 'astro-remote' -import { Schema } from 'astro-seo-schema' -import { actions } from 'astro:actions' -import { Picture } from 'astro:assets' -import { head, orderBy, shuffle, sortBy, tail } from 'lodash-es' - -import AdminOnly from '../../components/AdminOnly.astro' -import BadgeSmall from '../../components/BadgeSmall.astro' -import BadgeStandard from '../../components/BadgeStandard.astro' -import Button from '../../components/Button.astro' -import CommentSection from '../../components/CommentSection.astro' -import CommentSummary from '../../components/CommentSummary.astro' -import DropdownButton from '../../components/DropdownButton.astro' -import DropdownButtonItemForm from '../../components/DropdownButtonItemForm.astro' -import DropdownButtonItemLink from '../../components/DropdownButtonItemLink.astro' -import FormatTimeInterval from '../../components/FormatTimeInterval.astro' -import { makeOgImageUrl, type OgImageAllTemplatesWithProps } from '../../components/OgImage' -import ScoreGauge from '../../components/ScoreGauge.astro' -import ScoreSquare from '../../components/ScoreSquare.astro' -import ServiceLinkButton from '../../components/ServiceLinkButton.astro' -import TimeFormatted from '../../components/TimeFormatted.astro' -import Tooltip from '../../components/Tooltip.astro' -import VerificationWarningBanner from '../../components/VerificationWarningBanner.astro' -import { getAttributeCategoryInfo } from '../../constants/attributeCategories' -import { getAttributeTypeInfo } from '../../constants/attributeTypes' -import { currencies, getCurrencyInfo } from '../../constants/currencies' -import { getEventTypeInfo } from '../../constants/eventTypes' -import { getKycLevelInfo, kycLevels } from '../../constants/kycLevels' -import { serviceVisibilitiesById } from '../../constants/serviceVisibility' -import { getTosHighlightRatingInfo } from '../../constants/tosHighlightRating' -import { getUserSentimentInfo } from '../../constants/userSentiment' -import { getVerificationStatusInfo, verificationStatusesByValue } from '../../constants/verificationStatus' -import BaseLayout from '../../layouts/BaseLayout.astro' -import { someButNotAll, undefinedIfEmpty } from '../../lib/arrays' -import { makeNonDbAttributes, sortAttributes } from '../../lib/attributes' -import { cn } from '../../lib/cn' -import { formatContactMethod } from '../../lib/contactMethods' -import { getOrCreateNotificationPreferences } from '../../lib/notificationPreferences' -import { formatNumber, type FormatNumberOptions } from '../../lib/numbers' -import { pluralize } from '../../lib/pluralize' -import { prisma } from '../../lib/prisma' -import { makeLoginUrl } from '../../lib/redirectUrls' -import { KYCNOTME_SCHEMA_MINI } from '../../lib/schema' -import { transformCase } from '../../lib/strings' -import { urlDomain } from '../../lib/urls' - -import type { BreadcrumArray } from '../../components/BaseHead.astro' -import type { Prisma } from '@prisma/client' -import type { ContactPoint, ListItem, Organization, Review, WebPage, WithContext } from 'schema-dts' - -const { slug } = Astro.params - -const user = Astro.locals.user - -const result = Astro.getActionResult(actions.service.requestVerification) - -const now = new Date() - -const [service, dbNotificationPreferences] = await Astro.locals.banners.tryMany([ - [ - 'Error fetching service', - async () => - prisma.service.findUnique({ - where: { slug }, - select: { - id: true, - slug: true, - name: true, - description: true, - kycLevel: true, - overallScore: true, - privacyScore: true, - trustScore: true, - verificationStatus: true, - serviceVisibility: true, - verificationSummary: true, - verificationProofMd: true, - tosUrls: true, - serviceUrls: true, - onionUrls: true, - i2pUrls: true, - referral: true, - imageUrl: true, - listedAt: true, - createdAt: true, - acceptedCurrencies: true, - tosReview: true, - tosReviewAt: true, - userSentiment: true, - userSentimentAt: true, - averageUserRating: true, - isRecentlyListed: true, - contactMethods: { - select: { - iconId: true, - value: true, - }, - }, - attributes: { - select: { - attribute: { - select: { - id: true, - type: true, - category: true, - title: true, - description: true, - privacyPoints: true, - trustPoints: true, - }, - }, - }, - }, - categories: { - select: { - icon: true, - name: true, - slug: true, - }, - }, - events: { - where: { - visible: true, - }, - select: { - title: true, - content: true, - type: true, - startedAt: true, - endedAt: true, - source: true, - }, - }, - suggestions: { - select: { - id: true, - status: true, - }, - where: { - userId: user?.id, - }, - }, - verificationRequests: { - select: { - id: true, - userId: true, - }, - }, - verificationSteps: { - select: { - title: true, - description: true, - status: true, - evidenceMd: true, - createdAt: true, - updatedAt: true, - }, - }, - _count: { - select: { - comments: { - where: { - ratingActive: true, - status: { - in: ['APPROVED', 'VERIFIED'], - }, - parentId: null, - suspicious: false, - }, - }, - }, - }, - }, - }), - null, - ], - [ - 'Error while fetching notification preferences', - () => - user - ? getOrCreateNotificationPreferences(user.id, { - id: true, - onRootCommentCreatedForServices: { - where: { slug }, - select: { id: true }, - }, - onEventCreatedForServices: { - where: { slug }, - select: { id: true }, - }, - onVerificationChangeForServices: { - where: { slug }, - select: { id: true }, - }, - }) - : null, - null, - ], -]) - -const makeWatchingDetails = ( - dbNotificationPreferences: Prisma.NotificationPreferencesGetPayload<{ - select: { - onRootCommentCreatedForServices: { - select: { id: true } - } - onEventCreatedForServices: { - select: { id: true } - } - onVerificationChangeForServices: { - select: { id: true } - } - } - }> | null, - serviceId: number | undefined -) => { - if (!dbNotificationPreferences || !serviceId) return null - - const comments = dbNotificationPreferences.onRootCommentCreatedForServices.some( - ({ id }) => id === serviceId - ) - const events = dbNotificationPreferences.onEventCreatedForServices.some(({ id }) => id === serviceId) - const verification = dbNotificationPreferences.onVerificationChangeForServices.some( - ({ id }) => id === serviceId - ) - const all = comments && events && verification - - return { - comments, - events, - verification, - all: all ? true : someButNotAll(comments, events, verification) ? null : false, - } as const -} - -const watchingDetails = makeWatchingDetails(dbNotificationPreferences, service?.id) - -if (!service) return Astro.rewrite('/404') - -if (service.serviceVisibility !== 'PUBLIC' && service.serviceVisibility !== 'UNLISTED') { - return Astro.rewrite('/404') -} - -const statusIcon = { - ...verificationStatusesByValue, - APPROVED: undefined, -}[service.verificationStatus] - -const shuffledLinks = { - clearnet: shuffle(service.serviceUrls), - onion: shuffle(service.onionUrls), - i2p: shuffle(service.i2pUrls), -} -const shownLinks = [head(shuffledLinks.clearnet), head(shuffledLinks.onion), head(shuffledLinks.i2p)].filter( - (url) => url !== undefined -) -const hiddenLinks = [ - ...tail(shuffledLinks.clearnet), - ...tail(shuffledLinks.onion), - ...tail(shuffledLinks.i2p), -] - -const kycLevelInfo = getKycLevelInfo(`${service.kycLevel}`) -const userSentiment = service.userSentiment - ? { ...service.userSentiment, info: getUserSentimentInfo(service.userSentiment.sentiment) } - : null - -const attributes = sortAttributes([ - ...makeNonDbAttributes(service, { filter: true }), - ...service.attributes.map(({ attribute }) => ({ - ...attribute, - links: - attribute.type === 'GOOD' || attribute.type === 'INFO' - ? [ - { - url: `/?attr-${attribute.id}=yes`, - label: 'Search with this', - icon: 'ri:search-line', - }, - ] - : [ - { - url: `/?attr-${attribute.id}=yes`, - label: 'With this', - icon: 'ri:search-line', - }, - { - url: `/?attr-${attribute.id}=no`, - label: 'Without this', - icon: 'ri:search-line', - }, - ], - })), -]).map((attribute) => ({ - ...attribute, - categoryInfo: getAttributeCategoryInfo(attribute.category), - typeInfo: getAttributeTypeInfo(attribute.type), -})) - -const statusInfo = getVerificationStatusInfo(service.verificationStatus) - -const hasRequestedVerification = - !!user && service.verificationRequests.some((request) => request.userId === user.id) - -const VerificationRequestElement = user ? 'button' : 'a' - -const getVerificationStepStatusInfo = (status: VerificationStepStatus) => { - switch (status) { - case VerificationStepStatus.PENDING: - return { - text: 'Pending', - icon: 'ri:loader-2-line', - color: 'gray', - timelineIconClass: 'text-gray-400', - } as const - case VerificationStepStatus.IN_PROGRESS: - return { - text: 'In Progress', - icon: 'ri:loader-4-line', - color: 'blue', - timelineIconClass: 'text-blue-400 animate-spin', - } as const - case VerificationStepStatus.PASSED: - return { - text: 'Passed', - icon: 'ri:check-line', - color: 'green', - timelineIconClass: 'text-green-400', - } as const - case VerificationStepStatus.FAILED: - return { - text: 'Failed', - icon: 'ri:close-line', - color: 'red', - timelineIconClass: 'text-red-400', - } as const - default: - return { - text: 'Unknown', - icon: 'ri:question-mark', - color: 'gray', - timelineIconClass: 'text-gray-500', - } as const - } -} -const itemReviewedId = new URL(`/service/${service.slug}`, Astro.url).href - -const ogImageTemplateData = { - template: 'generic', - title: service.name, -} satisfies OgImageAllTemplatesWithProps ---- - - ({ - ...method, - ...(formatContactMethod(method.value) ?? { type: 'unknown', formattedValue: method.value }), - })) - .map(({ type, formattedValue }) => { - switch (type) { - case 'telephone': { - return { - '@type': 'ContactPoint', - telephone: formattedValue, - } - } - case 'email': { - return { - '@type': 'ContactPoint', - email: formattedValue, - } - } - default: { - return null - } - } - }) - .filter((value) => value !== null) - ), - } satisfies WithContext, - - { - '@context': 'https://schema.org', - '@type': 'WebPage', - name: service.name, - url: Astro.url.href, - mainEntity: { - '@id': itemReviewedId, - }, - datePublished: service.listedAt?.toISOString(), - dateCreated: service.createdAt.toISOString(), - image: makeOgImageUrl(ogImageTemplateData, Astro.url), - } satisfies WithContext, - ]} - breadcrumbs={[ - ...service.categories.map( - (category) => - [ - { - name: 'Services', - url: '/', - }, - { - name: category.name, - url: `/service/?categories=${category.slug}`, - }, - { - name: service.name, - url: `/service/${service.slug}`, - }, - ] satisfies BreadcrumArray - ), - ...service.acceptedCurrencies.map((currency) => { - const currencyInfo = getCurrencyInfo(currency) - return [ - { - name: 'Services', - url: '/', - }, - { - name: currencyInfo.name, - url: `/service/?currencies=${currencyInfo.slug}`, - }, - { - name: service.name, - url: `/service/${service.slug}`, - }, - ] satisfies BreadcrumArray - }), - ]} -> - { - service.serviceVisibility === 'UNLISTED' && ( -
- - Unlisted service, only accessible via direct link and won't appear in searches. -
- ) - } - - - { - service.verificationSteps.some((step) => step.status === VerificationStepStatus.FAILED) && ( -
- - - This service has failed one or more verification steps. Review the verification details carefully. - -
- ) - } - -
- { - !!service.imageUrl && ( - - ) - } -

- {service.name}{ - !!statusIcon && ( - - - - ) - } -

- -
- { - user ? ( - - - {!!watchingDetails && ( - - - - )} - - - - {!!watchingDetails && ( - - - - )} - - - - {!!watchingDetails && ( - - - - )} - - - - {!!watchingDetails && ( - - - - )} - - - ) : ( - - - - - ) - } - - -
-
- -
= 3, - })} - > -
    = 3, - })} - aria-label="Categories" - > - { - service.categories.map((category) => ( - - )) - } -
- -
- { - currencies.map((currency) => { - const isAccepted = service.acceptedCurrencies.includes(currency.id) - - return ( - - - - ) - }) - } -
-
- -
- -
- - { - shownLinks.length + hiddenLinks.length > 0 && ( -
    - {shownLinks.map((url) => ( -
  • - 0} - /> -
  • - ))} - - - - {hiddenLinks.length > 0 && ( -
  • - -
  • - )} - - {hiddenLinks.map((url) => ( - - ))} -
- ) - } - - { - service.contactMethods.length > 0 && ( - - ) - } - -

- Scores -

-
-
- - -
- - - - -
-
- } - /> -
- -
- lvl. - {kycLevelInfo.value}/{kycLevels.length - 1} -
-
- -
-
{kycLevelInfo.name}
-
- {kycLevelInfo.description} -
-
-
-
- - { - attributes.length > 0 && ( -
    - {attributes.map((attribute) => { - const baseFormatOptions = { - roundDigits: 2, - showSign: true, - removeTrailingZeros: true, - } as const satisfies FormatNumberOptions - const weights = [ - { - type: 'privacy', - label: 'Privacy', - value: attribute.privacyPoints, - formatOptions: baseFormatOptions, - }, - { - type: 'trust', - label: 'Trust', - value: attribute.trustPoints, - formatOptions: baseFormatOptions, - }, - ] as const satisfies { - type: string - label: string - value: number - formatOptions: FormatNumberOptions - }[] - - return ( -
  • -
    - - - {attribute.title} - - - -
    -
    - -
    - -
    - {weights.map((w) => ( -
    - 0, - 'opacity-50': w.value === 0, - })} - > - {formatNumber(w.value, w.formatOptions)} - - - {w.label} - -
    - ))} -
    - -
    - {attribute.links.map((link) => ( - - - {link.label} - - ))} -
    -
    -
    -
  • - ) - })} -
- ) - } - - - -

- Terms of Service Review -

- { - service.verificationStatus === 'VERIFICATION_SUCCESS' || service.verificationStatus === 'APPROVED' ? ( - service.tosReview ? ( - <> - h.rating === 'positive') - .map( - (h, i) => - ({ - '@type': 'ListItem', - position: i + 1, - name: h.title, - description: h.content, - }) satisfies ListItem - ), - negativeNotes: service.tosReview.highlights - .filter((h) => h.rating === 'negative') - .map( - (h, i) => - ({ - '@type': 'ListItem', - position: i + 1, - name: h.title, - description: h.content, - }) satisfies ListItem - ), - } satisfies WithContext - } - /> - -
-
- {service.tosReview.summary ? ( - - ) : ( -

No summary available

- )} -
-
- -
- {sortBy( - service.tosReview.highlights.map((highlight) => ({ - ...highlight, - ratingInfo: getTosHighlightRatingInfo(highlight.rating), - })), - 'ratingInfo.order' - ).map((highlight) => ( -
-

- - {highlight.title} -

- {!!highlight.content && ( -
- -
- )} -
- ))} -
- -

- {!!service.tosReviewAt && ( - <> - Reviewed - - )} - {!!service.tosReviewAt && !!service.tosUrls.length && 'from'} - {service.tosUrls.map((url) => ( - - {urlDomain(url)} - - ))} -

-

- ToS reviews are AI-generated and should be used as a reference only. -

- - ) : ( -
-

Not reviewed yet

- {service.tosUrls.length > 0 && ( -

- {service.tosUrls.map((url) => ( - - {urlDomain(url)} - - ))} -

- )} -
- ) - ) : ( -
-

Not available on {transformCase(statusInfo.label, 'lower')} services

- {service.tosUrls.length > 0 && ( -

- {service.tosUrls.map((url) => ( - - {urlDomain(url)} - - ))} -

- )} -
- ) - } - -
-

Events

- - View all - - -
- { - service.events.length > 0 ? ( -
    - {orderBy( - service.events.map((event) => ({ - ...event, - actualEndedAt: event.endedAt ?? now, - })), - ['actualEndedAt', 'startedAt'], - 'desc' - ).map((event) => { - const typeInfo = getEventTypeInfo(event.type) - - return ( -
  1. -
    -
    - -
    - -
    -
    - -
    -

    - {event.title} -

    - -

    {event.content}

    - {event.source && ( - - Source - - )} -
    -
  2. - ) - })} -
  3. -
- ) : ( -

No events reported

- ) - } - - - -

- Verification -

-
-
-
-
-
- - {statusInfo.label} -
- -

- {statusInfo.description} -

-
- - { - !!service.verificationSummary && ( -
- -
- ) - } - - { - service.verificationSteps.length > 0 && ( -
-

- - Verification Steps -

-
    - {service.verificationSteps.map((step) => { - const statusInfo = getVerificationStepStatusInfo(step.status) - return ( -
  • -
    - -
    -
    - {step.title} - - - {statusInfo.text} - - -
    -
    -
    -

    - Added - -

    - {step.description && ( -
    {step.description}
    - )} - {step.evidenceMd && ( -
    -
    Evidence:
    -
    - -
    -
    - )} -
    -
    -
  • - ) - })} -
-
- ) - } -
- -
- { - service.verificationStatus !== 'VERIFICATION_SUCCESS' && - service.verificationStatus !== 'VERIFICATION_FAILED' && ( -
- - - { - const url = new URL(Astro.url) - url.hash = '#request-verification-form' - return url - })() - ) - : undefined - } - class="border-night-400 bg-night-800 hover:bg-night-900 flex w-full items-center gap-2 rounded-lg border px-4 py-2 text-sm shadow-sm transition-colors duration-200" - > - - - -

- {service.verificationRequests.length.toLocaleString()}{' '} - {pluralize('request', service.verificationRequests.length)} -

- {result?.error &&

{result.error.message}

} -
- ) - } - - { - service.verificationProofMd && ( -
-
- - { - service.verificationProofMd && ( - <> - - - - ) - } -
- -

- Comments -

-
-
-

About comments

-
    -
  • Comments are visible after approval.
  • -
  • Moderation is light.
  • -
  • Double-check before trusting.
  • -
-
- -
-
- - - { - userSentiment && service.averageUserRating !== null && ( - - ({ - '@type': 'ListItem', - position: index + 1, - name: item, - }) satisfies ListItem - ), - negativeNotes: userSentiment.whatUsersDislike.map( - (item, index) => - ({ - '@type': 'ListItem', - position: index + 1, - name: item, - }) satisfies ListItem - ), - } satisfies WithContext - } - /> - ) - } - -
-
-

- AI Summary -

- { - service.userSentimentAt && ( -
- Updated - -
- ) - } -
- - { - userSentiment ? ( - <> -
- -
- -
-
    - {userSentiment.whatUsersLike.map((item) => ( -
  • - {item} -
  • - ))} -
- -
    - {userSentiment.whatUsersDislike.map((item) => ( -
  • - {item} -
  • - ))} -
-
- - ) : ( -

- Not reviewed yet -

- ) - } -
-
- -
- - diff --git a/web/src/pages/u/[username].astro b/web/src/pages/u/[username].astro deleted file mode 100644 index ad01bc7..0000000 --- a/web/src/pages/u/[username].astro +++ /dev/null @@ -1,912 +0,0 @@ ---- -import { Icon } from 'astro-icon/components' -import { Picture } from 'astro:assets' -import { sortBy } from 'lodash-es' - -import defaultServiceImage from '../../assets/fallback-service-image.jpg' -import AdminOnly from '../../components/AdminOnly.astro' -import BadgeSmall from '../../components/BadgeSmall.astro' -import TimeFormatted from '../../components/TimeFormatted.astro' -import Tooltip from '../../components/Tooltip.astro' -import { karmaUnlocks } from '../../constants/karmaUnlocks' -import { SUPPORT_EMAIL } from '../../constants/project' -import { getServiceSuggestionStatusInfo } from '../../constants/serviceSuggestionStatus' -import { getServiceSuggestionTypeInfo } from '../../constants/serviceSuggestionType' -import { getServiceUserRoleInfo } from '../../constants/serviceUserRoles' -import { verificationStatusesByValue } from '../../constants/verificationStatus' -import BaseLayout from '../../layouts/BaseLayout.astro' -import { cn } from '../../lib/cn' -import { makeUserWithKarmaUnlocks } from '../../lib/karmaUnlocks' -import { prisma } from '../../lib/prisma' -import { KYCNOTME_SCHEMA_MINI } from '../../lib/schema' -import { formatDateShort } from '../../lib/timeAgo' - -import type { ProfilePage, WithContext } from 'schema-dts' - -const username = Astro.params.username -if (!username) return Astro.rewrite('/404') - -const user = await Astro.locals.banners.try('user', async () => { - return makeUserWithKarmaUnlocks( - await prisma.user.findUnique({ - where: { name: Astro.params.username }, - select: { - id: true, - name: true, - displayName: true, - link: true, - picture: true, - spammer: true, - verified: true, - admin: true, - verifier: true, - verifiedLink: true, - totalKarma: true, - createdAt: true, - _count: { - select: { - comments: true, - commentVotes: true, - karmaTransactions: true, - }, - }, - karmaTransactions: { - select: { - id: true, - points: true, - action: true, - description: true, - createdAt: true, - comment: { - select: { - id: true, - content: true, - }, - }, - }, - orderBy: { createdAt: 'desc' }, - take: 5, - }, - suggestions: { - select: { - id: true, - type: true, - status: true, - createdAt: true, - service: { - select: { - id: true, - name: true, - slug: true, - }, - }, - }, - where: { service: { serviceVisibility: 'PUBLIC' } }, - orderBy: { createdAt: 'desc' }, - take: 5, - }, - comments: { - select: { - id: true, - content: true, - createdAt: true, - upvotes: true, - status: true, - service: { - select: { - id: true, - name: true, - slug: true, - }, - }, - }, - orderBy: { createdAt: 'desc' }, - take: 5, - }, - commentVotes: { - select: { - id: true, - downvote: true, - createdAt: true, - comment: { - select: { - id: true, - content: true, - service: { - select: { - id: true, - name: true, - slug: true, - }, - }, - }, - }, - }, - orderBy: { createdAt: 'desc' }, - take: 5, - }, - serviceAffiliations: { - select: { - role: true, - service: { - select: { - id: true, - name: true, - slug: true, - imageUrl: true, - verificationStatus: true, - }, - }, - }, - orderBy: [{ role: 'asc' }, { service: { name: 'asc' } }], - }, - }, - }) - ) -}) - -if (!user) return Astro.rewrite('/404') - -const isCurrentUser = !!Astro.locals.user && user.id === Astro.locals.user.id ---- - -, - ]} - breadcrumbs={[ - { - name: 'Users', - url: '/u', - }, - { - name: user.displayName ?? user.name, - url: `/u/${user.name}`, - }, - ]} -> -
-
- { - user.picture ? ( - - ) : ( -
- -
- ) - } -
-

- {user.name} - {isCurrentUser && (You)} -

- {user.displayName &&

{user.displayName}

} -
- { - user.admin && ( - - admin - - ) - } - { - user.verified && ( - - verified - - ) - } - { - user.verifier && ( - - verifier - - ) - } -
-
- -
- -
-
-
-

Profile Information

-
    -
  • - -
    -

    Username

    -

    {user.name}

    -
    -
  • - -
  • - - - -
    -

    Display Name

    - -

    - {user.displayName ?? Not set} -

    -
    -
  • - - { - !!user.link && ( -
  • - - - -
    -

    Website

    - - {user.link} - -
    -
  • - ) - } - -
  • - -
    -

    Karma

    -

    {user.totalKarma.toLocaleString()}

    -
    -
  • -
-
- -
-

Account Status

-
    -
  • - - - -
    -

    Account Type

    -
    - { - user.admin && ( - - Admin - - ) - } - { - user.verified && ( - - Verified User - - ) - } - { - user.verifier && ( - - Verifier - - ) - } - { - !user.admin && !user.verified && !user.verifier && ( - - Standard User - - ) - } -
    -
    -
  • - -
  • - - - -
    -

    Spam Status

    - { - user.spammer ? ( - - Spammer - - ) : ( - - Not Flagged - - ) - } -
    -
  • - -
  • - -
    -

    Joined

    -

    - { - formatDateShort(user.createdAt, { - prefix: false, - hourPrecision: true, - caseType: 'sentence', - }) - } -

    -
    -
  • - - { - user.verifiedLink && ( -
  • - - - -
    -

    Verified as related to

    - - {user.verifiedLink} - -
    -
  • - ) - } -
-
-
-
-
- -
-
-

- - Service Affiliations -

-
- - { - user.serviceAffiliations.length > 0 ? ( - - ) : ( -

No service affiliations yet.

- ) - } -
- -
-
-

- - Karma Unlocks -

- -
-

- Earn karma to unlock features and privileges. Learn about karma -

-
-
- -
-
-

Positive unlocks

- - { - sortBy( - karmaUnlocks.filter((unlock) => unlock.karma >= 0), - 'karma' - ).map((unlock) => ( -
-
- - - -
-

- {unlock.name} -

-

{unlock.karma.toLocaleString()} karma

-
-
-
- {user.karmaUnlocks[unlock.id] ? ( - - Unlocked - - ) : ( - - Locked - - )} -
-
- )) - } -
- -
-

Negative unlocks

- - { - sortBy( - karmaUnlocks.filter((unlock) => unlock.karma < 0), - 'karma' - ) - .reverse() - .map((unlock) => ( -
-
- - - -
-

- {unlock.name} -

-

{unlock.karma.toLocaleString()} karma

-
-
-
- {user.karmaUnlocks[unlock.id] ? ( - - Active - - ) : ( - - Avoided - - )} -
-
- )) - } - -

- - Negative karma leads to restrictions. Keep interactions positive to - avoid penalties. -

-
-
-
- -
-
-
-

- - Recent Comments -

- {user._count.comments.toLocaleString()} comments -
- - { - user.comments.length === 0 ? ( -

No comments yet.

- ) : ( -
- - - - - - - - - - - - {user.comments.map((comment) => ( - - - - - - - - ))} - -
ServiceCommentStatusUpvotesDate
- - {comment.service.name} - - -

{comment.content}

-
- - {comment.status} - - - - {comment.upvotes} - - - -
-
- ) - } -
- - { - user.karmaUnlocks.voteComments || user._count.commentVotes ? ( -
-
-

- - Recent Votes -

- {user._count.commentVotes.toLocaleString()} votes -
- - {user.commentVotes.length === 0 ? ( -

No votes yet.

- ) : ( -
- - - - - - - - - - - {user.commentVotes.map((vote) => ( - - - - - - - ))} - -
ServiceCommentVoteDate
- - {vote.comment.service.name} - - -

{vote.comment.content}

-
- {vote.downvote ? ( - - - - ) : ( - - - - )} - - -
-
- )} -
- ) : ( -
-

- - Recent Votes -

- - - Locked - -
- ) - } - -
-
-

- - Recent Suggestions -

-
- - { - user.suggestions.length === 0 ? ( -

No suggestions yet.

- ) : ( -
- - - - - - - - - - - {user.suggestions.map((suggestion) => { - const typeInfo = getServiceSuggestionTypeInfo(suggestion.type) - const statusInfo = getServiceSuggestionStatusInfo(suggestion.status) - - return ( - - - - - - - ) - })} - -
ServiceTypeStatusDate
- - {suggestion.service.name} - - - - - {typeInfo.label} - - - - - {statusInfo.label} - - - -
-
- ) - } -
- -
-
-

- - Recent Karma Transactions -

- {user.totalKarma.toLocaleString()} karma -
- - { - user.karmaTransactions.length === 0 ? ( -

No karma transactions yet.

- ) : ( -
- - - - - - - - - - - {user.karmaTransactions.map((transaction) => ( - - - - - - - ))} - -
ActionDescriptionPointsDate
{transaction.action}{transaction.description}= 0 ? 'text-green-400' : 'text-red-400' - )} - > - {transaction.points >= 0 && '+'} - {transaction.points} - - -
-
- ) - } -
-
-
diff --git a/web/src/robots.txt.ts b/web/src/robots.txt.ts deleted file mode 100644 index 5a1c5c0..0000000 --- a/web/src/robots.txt.ts +++ /dev/null @@ -1,14 +0,0 @@ -import type { APIRoute } from 'astro' - -const getRobotsTxt = (sitemapURL: URL) => ` -User-agent: * -Allow: / -Disallow: /admin/ - -Sitemap: ${sitemapURL.href} -` - -export const GET: APIRoute = ({ site }) => { - const sitemapURL = new URL('sitemap-index.xml', site) - return new Response(getRobotsTxt(sitemapURL)) -} diff --git a/web/src/styles/global.css b/web/src/styles/global.css deleted file mode 100644 index fbaa8d3..0000000 --- a/web/src/styles/global.css +++ /dev/null @@ -1,133 +0,0 @@ -@import 'tailwindcss'; - -@plugin "@tailwindcss/forms"; -@plugin 'tailwind-htmx'; -@plugin '@tailwindcss/typography'; - -@custom-variant theme-midnight { - &:where([data-theme='midnight'] *) { - @slot; - } -} - -@custom-variant js { - &:is(.js *) { - @slot; - } -} - -@custom-variant no-js { - &:not(.js *) { - @slot; - } -} - -@layer base { - button:not(:disabled), - [role='button']:not(:disabled), - label[for] { - cursor: pointer; - } - - input[type='checkbox']:not(.unset) { - @apply border-day-300 checked:ring-day-300 cursor-pointer rounded border-2 text-green-600 shadow-sm ring-0 ring-current ring-offset-0 transition-all duration-100 not-checked:bg-zinc-800 checked:border-current focus-visible:ring-2; - } - - input[type='radio']:not(.unset) { - @apply border-day-300 checked:ring-day-300 cursor-pointer rounded-full border-2 text-green-600 shadow-sm ring-0 ring-current ring-offset-0 transition-all duration-100 not-checked:bg-zinc-800 checked:border-current focus-visible:ring-2; - } - - .prose { - @apply prose-headings:font-title; - } -} - -@theme inline { - --font-title: 'Space Grotesk Variable', var(--font-sans), 'sans-serif'; -} - -@theme { - --text-2xs: 0.65rem; -} - -@theme { - --breakpoint-xs: 475px; - --breakpoint-2xs: 375px; -} - -@theme { - --color-score-1: #e26136; - --color-score-2: #eba370; - --color-score-3: #eddb82; - --color-score-4: #8de2d7; - --color-score-5: #3cdd71; - - --color-score-saturate-1: #ff0000; - --color-score-saturate-2: #ff7300; - --color-score-saturate-3: #ffff00; - --color-score-saturate-4: #00ffff; - --color-score-saturate-5: #7cff00; - - --color-day-50: oklch(97.13% 0.002 165.08); - --color-day-100: oklch(94.73% 0.003 165.07); - --color-day-200: oklch(89.62% 0.006 170.43); - --color-day-300: oklch(83.81% 0.01 171.74); - --color-day-400: oklch(74.95% 0.015 169.09); - --color-day-500: oklch(66.18% 0.02 171.17); - --color-day-600: oklch(56.71% 0.022 172.22); - --color-day-700: oklch(46.55% 0.018 170.35); - --color-day-800: oklch(34.77% 0.012 171.06); - --color-day-900: oklch(30.05% 0.01 179.07); - --color-day-950: oklch(27.08% 0.008 196.85); - - --color-night-50: oklch(90.58% 0.009 171.78); - --color-night-100: oklch(80.76% 0.017 178.15); - --color-night-200: oklch(61.23% 0.035 173.55); - --color-night-300: oklch(36.23% 0.018 174.61); - --color-night-400: oklch(33.22% 0.017 172.96); - --color-night-500: oklch(28.79% 0.013 180.38); - --color-night-600: oklch(25.59% 0.012 178.46); - --color-night-700: oklch(22.09% 0.008 182.2); - --color-night-800: oklch(18.65% 0.007 178.83); - --color-night-900: oklch(13.3% 0.002 196.91); - --color-night-950: oklch(11.97% 0.004 145.32); -} - -@layer utilities { - .text-shadow-glow { - text-shadow: - 0 0 16px color-mix(in oklab, currentColor 30%, transparent), - 0 0 4px color-mix(in oklab, currentColor 60%, transparent); - } - .drop-shadow-glow { - filter: drop-shadow(0 0 16px color-mix(in oklab, currentColor 30%, transparent)) - drop-shadow(0 0 4px color-mix(in oklab, currentColor 60%, transparent)); - } -} - -@theme { - --ease-in-sine: cubic-bezier(0.12, 0, 0.39, 0); - --ease-out-sine: cubic-bezier(0.61, 1, 0.88, 1); - --ease-in-out-sine: cubic-bezier(0.37, 0, 0.63, 1); - --ease-in-quad: cubic-bezier(0.11, 0, 0.5, 0); - --ease-out-quad: cubic-bezier(0.5, 1, 0.89, 1); - --ease-in-out-quad: cubic-bezier(0.45, 0, 0.55, 1); - --ease-in-cubic: cubic-bezier(0.32, 0, 0.67, 0); - --ease-out-cubic: cubic-bezier(0.33, 1, 0.68, 1); - --ease-in-out-cubic: cubic-bezier(0.65, 0, 0.35, 1); - --ease-in-quart: cubic-bezier(0.5, 0, 0.75, 0); - --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1); - --ease-in-out-quart: cubic-bezier(0.76, 0, 0.24, 1); - --ease-in-quint: cubic-bezier(0.64, 0, 0.78, 0); - --ease-out-quint: cubic-bezier(0.22, 1, 0.36, 1); - --ease-in-out-quint: cubic-bezier(0.83, 0, 0.17, 1); - --ease-in-expo: cubic-bezier(0.7, 0, 0.84, 0); - --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1); - --ease-in-out-expo: cubic-bezier(0.87, 0, 0.13, 1); - --ease-in-circ: cubic-bezier(0.55, 0, 1, 0.45); - --ease-out-circ: cubic-bezier(0, 0.55, 0.45, 1); - --ease-in-out-circ: cubic-bezier(0.85, 0, 0.15, 1); - --ease-in-back: cubic-bezier(0.36, 0, 0.66, -0.56); - --ease-out-back: cubic-bezier(0.34, 1.56, 0.64, 1); - --ease-in-out-back: cubic-bezier(0.68, -0.6, 0.32, 1.6); -} diff --git a/web/src/types/eslint-plugin-import.d.ts b/web/src/types/eslint-plugin-import.d.ts deleted file mode 100644 index bdff2c6..0000000 --- a/web/src/types/eslint-plugin-import.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -declare module 'eslint-plugin-import' { - export const configs: { - recommended: any - errors: any - warnings: any - typescript: any - } - export const flatConfigs: { - recommended: any - errors: any - warnings: any - typescript: any - } -} diff --git a/web/tsconfig.json b/web/tsconfig.json deleted file mode 100644 index fcd818f..0000000 --- a/web/tsconfig.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "extends": "astro/tsconfigs/strict", - "include": [".astro/types.d.ts", "**/*"], - "exclude": ["dist"], - "compilerOptions": { - "noUncheckedIndexedAccess": true, - "jsx": "react-jsx", - "jsxImportSource": "react" - } -}